1 2020-04-08 Tom Tromey <tromey@adacore.com>
3 * win32-low.c (current_process_handle, current_process_id)
4 (main_thread_id, last_sig, current_event, siginfo_er): Move to
7 2020-04-08 Tom Tromey <tromey@adacore.com>
9 * win32-low.c (get_image_name): Remove.
10 (handle_load_dll): Update.
12 2020-04-08 Tom Tromey <tromey@adacore.com>
14 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
15 No longer static. Change parameters.
16 (child_add_thread, child_fetch_inferior_registers)
17 (child_store_inferior_registers, win32_resume)
18 (win32_get_tib_address): Update.
20 2020-04-08 Tom Tromey <tromey@adacore.com>
22 * win32-low.h (struct win32_target_ops): Use qualified names where
24 * win32-i386-low.c: Add "using namespace".
25 * win32-low.c: Add "using namespace".
26 * win32-arm-low.c: Add "using namespace".
28 2020-04-08 Tom Tromey <tromey@adacore.com>
30 * win32-low.c (delete_thread_info): Don't call CloseHandle.
32 2020-04-08 Tom Tromey <tromey@adacore.com>
34 * win32-low.c (win32_require_context, suspend_one_thread): Use
35 windows_thread_info::suspend.
36 (continue_one_thread): Use windows_thread_info::resume.
37 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
39 2020-04-08 Tom Tromey <tromey@adacore.com>
41 * win32-i386-low.c (update_debug_registers)
42 (i386_prepare_to_resume, i386_thread_added): Update.
44 2020-04-08 Tom Tromey <tromey@adacore.com>
46 * win32-low.c (child_add_thread): Use new.
47 (delete_thread_info): Use delete.
49 2020-04-08 Tom Tromey <tromey@adacore.com>
51 * win32-low.h (struct windows_thread_info): Remove.
53 2020-04-08 Tom Tromey <tromey@adacore.com>
55 * win32-low.h (struct windows_thread_info): Rename from
56 win32_thread_info. Remove typedef.
57 (struct win32_target_ops, win32_require_context): Update.
58 * win32-low.c (win32_get_thread_context)
59 (win32_set_thread_context, win32_prepare_to_resume)
60 (win32_require_context, thread_rec, child_add_thread)
61 (delete_thread_info, continue_one_thread)
62 (child_fetch_inferior_registers, child_store_inferior_registers)
63 (win32_resume, suspend_one_thread, win32_get_tib_address):
65 * win32-i386-low.c (update_debug_registers)
66 (win32_get_current_dr, i386_get_thread_context)
67 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
68 (i386_fetch_inferior_register, i386_store_inferior_register):
70 * win32-arm-low.c (arm_get_thread_context)
71 (arm_fetch_inferior_register, arm_store_inferior_register):
74 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
76 * linux-low.h (struct linux_target_ops): Remove.
77 (the_low_target): Remove.
78 * linux-x86-low.cc (the_low_target): Remove.
79 * linux-aarch64-low.cc (the_low_target): Ditto.
80 * linux-arm-low.cc (the_low_target): Ditto.
81 * linux-bfin-low.cc (the_low_target): Ditto.
82 * linux-cris-low.cc (the_low_target): Ditto.
83 * linux-crisv32-low.cc (the_low_target): Ditto.
84 * linux-ia64-low.cc (the_low_target): Ditto.
85 * linux-m32r-low.cc (the_low_target): Ditto.
86 * linux-m68k-low.cc (the_low_target): Ditto.
87 * linux-mips-low.cc (the_low_target): Ditto.
88 * linux-nios2-low.cc (the_low_target): Ditto.
89 * linux-ppc-low.cc (the_low_target): Ditto.
90 * linux-riscv-low.cc (the_low_target): Ditto.
91 * linux-s390-low.cc (the_low_target): Ditto.
92 * linux-sh-low.cc (the_low_target): Ditto.
93 * linux-sparc-low.cc (the_low_target): Ditto.
94 * linux-tic6x-low.cc (the_low_target): Ditto.
95 * linux-tile-low.cc (the_low_target): Ditto.
96 * linux-xtensa-low.cc (the_low_target): Ditto.
98 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
100 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
101 linux target define the op by overriding the declaration in
102 process_stratum_target.
104 * linux-low.h (struct linux_target_ops): Remove the op.
105 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
106 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
107 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
108 (x86_get_ipa_tdesc_idx): Turn into...
109 (x86_target::get_ipa_tdesc_idx): ...this.
110 (the_low_target): Remove the op field.
111 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
112 (ppc_get_ipa_tdesc_idx): Turn into...
113 (ppc_target::get_ipa_tdesc_idx): ...this.
114 (the_low_target): Remove the op field.
115 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
116 (s390_get_ipa_tdesc_idx): Turn into...
117 (s390_target::get_ipa_tdesc_idx): ...this.
118 (the_low_target): Remove the op field.
120 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
122 Turn the 'get_syscall_trapinfo' linux target op into a method
123 of process_stratum_target.
125 * linux-low.h (struct linux_target_ops): Remove the op.
126 (class linux_process_target) <get_syscall_trapinfo>
127 <gdb_catch_this_syscall>
128 <low_supports_catch_syscall>
129 <low_get_syscall_trapinfo>: Declare.
130 * linux-low.cc (get_syscall_trapinfo): Turn into...
131 (linux_process_target::get_syscall_trapinfo): ...this.
132 (linux_process_target::low_get_syscall_trapinfo): Define.
133 (gdb_catch_this_syscall_p): Turn into...
134 (linux_process_target::gdb_catch_this_syscall): ...this.
135 (linux_process_target::low_supports_catch_syscall): Define.
137 Update the callers below.
139 (linux_process_target::wait_1)
140 (linux_process_target::supports_catch_syscall)
142 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
143 <low_get_syscall_trapinfo>: Declare.
144 (x86_target::low_supports_catch_syscall): Define.
145 (x86_get_syscall_trapinfo): Turn into...
146 (x86_target::low_get_syscall_trapinfo): ...this.
147 (the_low_target): Remove the op field.
148 * linux-aarch64-low.cc (class aarch64_target)
149 <low_supports_catch_syscall>
150 <low_get_syscall_trapinfo>: Declare.
151 (aarch64_target::low_supports_catch_syscall): Define.
152 (aarch64_get_syscall_trapinfo): Turn into...
153 (aarch64_target::low_get_syscall_trapinfo): ...this.
154 (the_low_target): Remove the op field.
155 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
156 <low_get_syscall_trapinfo>: Declare.
157 (arm_target::low_supports_catch_syscall): Define.
158 (arm_get_syscall_trapinfo): Turn into...
159 (arm_target::low_get_syscall_trapinfo): ...this.
160 (the_low_target): Remove the op field.
161 * linux-ppc-low.cc (the_low_target): Remove the op field.
162 * linux-s390-low.cc (the_low_target): Remove the op field.
164 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
166 Remove the 'supports_hardware_single_step' linux target op and
167 override the process_stratum_target's op definition in
168 linux_process_target to return true.
170 * linux-low.h (struct linux_target_ops): Remove the op.
171 (class linux_process_target) <finish_step_over>
172 <maybe_hw_step>: Declare.
173 * linux-low.cc (can_hardware_single_step): Remove.
174 (maybe_hw_step): Turn into...
175 (linux_process_target::maybe_hw_step): ...this.
176 (finish_step_over): Turn into...
177 (linux_process_target::finish_step_over): ...this.
178 (linux_process_target::supports_hardware_single_step): Update
181 Update the callers below.
183 (linux_process_target::single_step)
184 (linux_process_target::resume_one_lwp_throw)
186 * linux-arm-low.cc (class arm_target)
187 <supports_hardware_single_step>: Declare.
188 (arm_supports_hardware_single_step): Turn into...
189 (arm_target::supports_hardware_single_step): ...this.
190 (the_low_target): Remove the op field.
191 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
192 (the_low_target): Remove the op field.
193 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
195 (the_low_target): Remove the op field.
196 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
197 (the_low_target): Remove the op field.
198 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
199 (the_low_target): Remove the op field.
200 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
201 (the_low_target): Remove the op field.
202 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
203 (the_low_target): Remove the op field.
204 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
205 (the_low_target): Remove the op field.
206 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
207 (the_low_target): Remove the op field.
208 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
209 (the_low_target): Remove the op field.
210 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
211 (the_low_target): Remove the op field.
212 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
213 (the_low_target): Remove the op field.
214 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
216 (the_low_target): Remove the op field.
218 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
220 Turn the 'supports_range_stepping' linux target op into a method
221 of linux_process_target.
223 * linux-low.h (struct linux_target_ops): Remove the op.
224 (class linux_process_target) <low_supports_range_stepping>: Declare.
225 * linux-low.cc (linux_process_target::low_supports_range_stepping):
227 (linux_process_target::supports_range_stepping): Update the call
229 * linux-x86-low.cc (class x86_target)
230 <low_supports_range_stepping>: Declare.
231 (x86_supports_range_stepping): Turn into...
232 (x86_target::low_supports_range_stepping): ...this.
233 (the_low_target): Remove the op field.
234 * linux-aarch64-low.cc (class aarch64_target)
235 <low_supports_range_stepping>: Declare.
236 (aarch64_supports_range_stepping): Turn into...
237 (aarch64_target::low_supports_range_stepping): ...this.
238 (the_low_target): Remove the op field.
239 * linux-arm-low.cc (the_low_target): Remove the op field.
240 * linux-bfin-low.cc (the_low_target): Ditto.
241 * linux-crisv32-low.cc (the_low_target): Ditto.
242 * linux-m32r-low.cc (the_low_target): Ditto.
243 * linux-m68k-low.cc (the_low_target): Ditto.
244 * linux-ppc-low.cc (the_low_target): Ditto.
245 * linux-s390-low.cc (the_low_target): Ditto.
246 * linux-sh-low.cc (the_low_target): Ditto.
247 * linux-tic6x-low.cc (the_low_target): Ditto.
248 * linux-tile-low.cc (the_low_target): Ditto.
249 * linux-xtensa-low.cc (the_low_target): Ditto.
251 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
253 Remove the 'emit_ops' linux target ops and let the concrete
254 linux target define the op by overriding the declaration of
255 process_stratum_target.
257 * linux-low.h (struct linux_target_ops): Remove the op.
258 (class linux_process_target) <emit_ops>: Remove.
259 * linux-low.cc (linux_process_target::emit_ops): Remove.
260 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
261 (x86_emit_ops): Turn into...
262 (x86_target::emit_ops): ...this.
263 (the_low_target): Remove the op field.
264 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
265 (aarch64_emit_ops): Turn into...
266 (aarch64_target::emit_ops): ...this.
267 (the_low_target): Remove the op field.
268 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
269 (ppc_emit_ops): Turn into...
270 (ppc_target::emit_ops): ...this.
271 (the_low_target): Remove the op field.
272 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
273 (s390_emit_ops): Turn into...
274 (s390_target::emit_ops): ...this.
275 (the_low_target): Remove the op field.
276 * linux-arm-low.cc (the_low_target): Remove the op field.
277 * linux-bfin-low.cc (the_low_target): Ditto.
278 * linux-crisv32-low.cc (the_low_target): Ditto.
279 * linux-m32r-low.cc (the_low_target): Ditto.
280 * linux-m68k-low.cc (the_low_target): Ditto.
281 * linux-sh-low.cc (the_low_target): Ditto.
282 * linux-tic6x-low.cc (the_low_target): Ditto.
283 * linux-tile-low.cc (the_low_target): Ditto.
284 * linux-xtensa-low.cc (the_low_target): Ditto.
286 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
288 Remove the 'install_fast_tracepoint_jump_pad' and
289 'get_min_fast_tracepoint_insn_len' linux target ops to let the
290 concrete linux target define the ops by overriding the declarations
291 of process_stratum_target.
293 * linux-low.h (struct linux_target_ops): Remove the ops.
294 (class linux_process_target) <supports_fast_tracepoints>
295 <install_fast_tracepoint_jump_pad>
296 <get_min_fast_tracepoint_insn_len>: Remove.
297 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
298 (linux_process_target::install_fast_tracepoint_jump_pad)
299 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
300 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
301 <install_fast_tracepoint_jump_pad>
302 <get_min_fast_tracepoint_insn_len>: Declare.
303 (x86_target::supports_fast_tracepoints): Define.
304 (x86_install_fast_tracepoint_jump_pad): Turn into...
305 (x86_target::install_fast_tracepoint_jump_pad): ...this.
306 (x86_get_min_fast_tracepoint_insn_len): Turn into...
307 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
308 (the_low_target): Remove the op fields.
309 * linux-aarch64-low.cc (class aarch64_target)
310 <supports_fast_tracepoints>
311 <install_fast_tracepoint_jump_pad>
312 <get_min_fast_tracepoint_insn_len>: Declare.
313 (aarch64_target::supports_fast_tracepoints): Define.
314 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
315 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
316 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
317 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
318 (the_low_target): Remove the op fields.
319 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
320 <install_fast_tracepoint_jump_pad>
321 <get_min_fast_tracepoint_insn_len>: Declare.
322 (ppc_target::supports_fast_tracepoints): Define.
323 (ppc_install_fast_tracepoint_jump_pad): Turn into...
324 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
325 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
326 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
327 (the_low_target): Remove the op fields.
328 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
329 <install_fast_tracepoint_jump_pad>
330 <get_min_fast_tracepoint_insn_len>: Declare.
331 (s390_target::supports_fast_tracepoints): Define.
332 (s390_install_fast_tracepoint_jump_pad): Turn into...
333 (s390_target::install_fast_tracepoint_jump_pad): ...this.
334 (s390_get_min_fast_tracepoint_insn_len): Turn into...
335 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
336 (the_low_target): Remove the op fields.
337 * linux-arm-low.cc (the_low_target): Remove the op fields.
338 * linux-bfin-low.cc (the_low_target): Ditto.
339 * linux-crisv32-low.cc (the_low_target): Ditto.
340 * linux-m32r-low.cc (the_low_target): Ditto.
341 * linux-m68k-low.cc (the_low_target): Ditto.
342 * linux-sh-low.cc (the_low_target): Ditto.
343 * linux-tic6x-low.cc (the_low_target): Ditto.
344 * linux-tile-low.cc (the_low_target): Ditto.
345 * linux-xtensa-low.cc (the_low_target): Ditto.
347 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
349 Turn the 'get_thread_area' linux target op into a method of
350 process_stratum_target.
352 * linux-low.h (struct linux_target_ops): Remove the op.
353 (class linux_process_target) <stuck_in_jump_pad>
354 <linux_fast_tracepoint_collecting>
355 <low_get_thread_area>: Declare.
356 * linux-low.cc (supports_fast_tracepoints): Remove.
357 (linux_fast_tracepoint_collecting): Turn into...
358 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
359 (linux_process_target::low_get_thread_area): Define.
360 (stuck_in_jump_pad_callback): Turn into...
361 (linux_process_target::stuck_in_jump_pad): ...this.
363 Update the caller below.
365 (linux_process_target::stabilize_threads)
367 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
369 (x86_get_thread_area): Turn into...
370 (x86_target::low_get_thread_area): ...this.
371 (the_low_target): Remove the op field.
372 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
374 (aarch64_get_thread_area): Turn into...
375 (aarch64_target::low_get_thread_area): ...this.
376 (the_low_target): Remove the op field.
377 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
379 (ppc_get_thread_area): Turn into...
380 (ppc_target::low_get_thread_area): ...this.
381 (the_low_target): Remove the op field.
382 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
384 (s390_get_thread_area): Turn into...
385 (s390_target::low_get_thread_area): ...this.
386 (the_low_target): Remove the op field.
387 * linux-arm-low.cc (the_low_target): Remove the op field.
388 * linux-bfin-low.cc (the_low_target): Ditto.
389 * linux-crisv32-low.cc (the_low_target): Ditto.
390 * linux-m32r-low.cc (the_low_target): Ditto.
391 * linux-m68k-low.cc (the_low_target): Ditto.
392 * linux-sh-low.cc (the_low_target): Ditto.
393 * linux-tic6x-low.cc (the_low_target): Ditto.
394 * linux-tile-low.cc (the_low_target): Ditto.
395 * linux-xtensa-low.cc (the_low_target): Ditto.
397 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
399 Remote the 'supports_tracepoints' linux target op and let the
400 concrete linux target define it by overriding the op declared in
401 process_stratum_target.
403 * linux-low.h (struct linux_target_ops): Remove the op.
404 (class linux_process_target) <supports_tracepoints>: Remove.
405 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
406 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
408 (x86_supports_tracepoints): Turn into...
409 (x86_target::supports_tracepoints): ...this.
410 (the_low_target): Remove the op field.
411 * linux-aarch64-low.cc (class aarch64_target)
412 <supports_tracepoints>: Declare.
413 (aarch64_supports_tracepoints): Turn into...
414 (aarch64_target::supports_tracepoints): ...this.
415 (the_low_target): Remove the op field.
416 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
418 (ppc_supports_tracepoints): Turn into...
419 (ppc_target::supports_tracepoints): ...this.
420 (the_low_target): Remove the op field.
421 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
423 (s390_supports_tracepoints): Turn into...
424 (s390_target::supports_tracepoints): ...this.
425 (the_low_target): Remove the op field.
426 * linux-arm-low.cc (the_low_target): Remove the op field.
427 * linux-bfin-low.cc (the_low_target): Ditto.
428 * linux-crisv32-low.cc (the_low_target): Ditto.
429 * linux-m32r-low.cc (the_low_target): Ditto.
430 * linux-m68k-low.cc (the_low_target): Ditto.
431 * linux-sh-low.cc (the_low_target): Ditto.
432 * linux-tic6x-low.cc (the_low_target): Ditto.
433 * linux-tile-low.cc (the_low_target): Ditto.
434 * linux-xtensa-low.cc (the_low_target): Ditto.
436 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
438 Remove the 'process_qsupported' linux target op and let a concrete
439 linux target define the op by overriding the op declaration in
440 process_stratum_target.
442 * linux-low.h (struct linux_target_ops): Remove the op.
443 (class linux_process_target) <process_qsupported>: Remove.
444 * linux-low.cc (linux_process_target::process_qsupported): Remove.
445 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
446 (x86_linux_process_qsupported): Turn into...
447 (x86_target::process_qsupported): ...this.
448 (the_low_target): Remove the op field.
449 * linux-aarch64-low.cc (the_low_target): Remove the op
451 * linux-arm-low.cc (the_low_target): Ditto.
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-ppc-low.cc (the_low_target): Ditto.
457 * linux-s390-low.cc (the_low_target): Ditto.
458 * linux-sh-low.cc (the_low_target): Ditto.
459 * linux-tic6x-low.cc (the_low_target): Ditto.
460 * linux-tile-low.cc (the_low_target): Ditto.
461 * linux-xtensa-low.cc (the_low_target): Ditto.
463 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
465 Turn the 'prepare_to_resume' linux target op into a method of
466 linux_process_target.
468 * linux-low.h (struct linux_target_ops): Remove the op.
469 (class linux_process_target) <low_prepare_to_resume>: Declare.
470 * linux-low.cc (linux_process_target::low_prepare_to_resume):
473 Update the callers below:
475 (linux_process_target::resume_one_lwp_throw)
476 (linux_process_target::low_prepare_to_resume)
478 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
480 (x86_target::low_prepare_to_resume): Define.
481 (the_low_target): Remove the op field.
482 * linux-aarch64-low.cc (class aarch64_target)
483 <low_prepare_to_resume>: Declare.
484 (aarch64_target::low_prepare_to_resume): Define.
485 (the_low_target): Remove the op field.
486 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
488 (arm_prepare_to_resume): Turn into...
489 (arm_target::low_prepare_to_resume): ...this.
490 (the_low_target): Remove the op field.
491 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
493 (mips_linux_prepare_to_resume): Turn into...
494 (mips_target::low_prepare_to_resume): ...this.
495 (the_low_target): Remove the op field.
496 * linux-bfin-low.cc (the_low_target): Remove the op field.
497 * linux-crisv32-low.cc (the_low_target): Ditto.
498 * linux-m32r-low.cc (the_low_target): Ditto.
499 * linux-m68k-low.cc (the_low_target): Ditto.
500 * linux-ppc-low.cc (the_low_target): Ditto.
501 * linux-s390-low.cc (the_low_target): Ditto.
502 * linux-sh-low.cc (the_low_target): Ditto.
503 * linux-tic6x-low.cc (the_low_target): Ditto.
504 * linux-tile-low.cc (the_low_target): Ditto.
505 * linux-xtensa-low.cc (the_low_target): Ditto.
507 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
509 Turn the 'new_process', 'delete_process', 'new_thread',
510 'delete_thread', and 'new_fork' linux target ops into methods
511 of linux_process_target.
513 * linux-low.h (struct linux_target_ops): Remove the ops.
514 (class linux_process_target) <add_linux_process>
519 <check_zombie_leaders>
525 <low_new_fork>: Declare.
526 * linux-low.cc (delete_lwp): Turn into...
527 (linux_process_target::delete_lwp): ...this.
528 (linux_process_target::low_delete_thread): Define.
529 (linux_add_process): Turn into...
530 (linux_process_target::add_linux_process): ...this.
531 (linux_process_target::low_new_process): Define.
532 (linux_process_target::low_delete_process): Define.
533 (linux_process_target::low_new_fork): Define.
534 (add_lwp): Turn into...
535 (linux_process_target::add_lwp): ...this.
536 (linux_process_target::low_new_thread): Define.
537 (linux_attach_lwp): Turn into...
538 (linux_process_target::attach_lwp): ...this.
539 (linux_detach_one_lwp): Turn into...
540 (linux_process_target::detach_one_lwp): ...this.
541 (linux_detach_lwp_callback): Remove and inline...
542 (linux_process_target::detach): ...here.
543 (check_zombie_leaders): Turn into...
544 (linux_process_target::check_zombie_leaders): ...this.
545 (filter_exit_event): Turn into...
546 (linux_process_target::filter_exit_event): ...this.
548 Update the callers below.
550 (linux_process_target::handle_extended_wait)
551 (linux_process_target::create_inferior)
552 (attach_proc_task_lwp_callback)
553 (linux_process_target::attach)
554 (linux_process_target::detach)
555 (linux_process_target::mourn)
556 * thread-db.cc (attach_thread)
558 * linux-x86-low.cc (class x86_target) <low_new_process>
562 <low_new_fork>: Declare.
563 (x86_linux_new_process): Turn into...
564 (x86_target::low_new_process): ...this.
565 (x86_linux_delete_process): Turn into...
566 (x86_target::low_delete_process): ...this.
567 (x86_target::low_new_thread): Define.
568 (x86_target::low_delete_thread): Define.
569 (x86_linux_new_fork): Turn into...
570 (x86_target::low_new_fork): ...this.
571 (the_low_target): Remove the op fields.
572 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
576 <low_new_fork>: Declare.
577 (aarch64_linux_new_process): Turn into...
578 (aarch64_target::low_new_process): ...this.
579 (aarch64_linux_delete_process): Turn into...
580 (aarch64_target::low_delete_process): ...this.
581 (aarch64_target::low_new_thread): Define.
582 (aarch64_target::low_delete_thread): Define.
583 (aarch64_linux_new_fork): Turn into...
584 (aarch64_target::low_new_fork): ...this.
585 (the_low_target): Remove the op fields.
586 * linux-arm-low.cc (class arm_target) <low_new_process>
590 <low_new_fork>: Declare.
591 (arm_new_process): Turn into...
592 (arm_target::low_new_process): ...this.
593 (arm_delete_process): Turn into...
594 (arm_target::low_delete_process): ...this.
595 (arm_new_thread): Turn into...
596 (arm_target::low_new_thread): ...this.
597 (arm_delete_thread): Turn into...
598 (arm_target::low_delete_thread): ...this.
599 (arm_new_fork): Turn into...
600 (arm_target::low_new_fork): ...this.
601 (the_low_target): Remove the op fields.
602 * linux-mips-low.cc (class mips_target) <low_new_process>
606 <low_new_fork>: Declare.
607 (mips_linux_new_process): Turn into...
608 (mips_target::low_new_process): ...this.
609 (mips_linux_delete_process): Turn into...
610 (mips_target::low_delete_process): ...this.
611 (mips_linux_new_thread): Turn into...
612 (mips_target::low_new_thread): ...this.
613 (mips_linux_delete_thread): Turn into...
614 (mips_target::low_delete_thread): ...this.
615 (mips_linux_new_fork): Turn into...
616 (mips_target::low_new_fork): ...this.
617 (the_low_target): Remove the op fields.
618 * linux-bfin-low.cc (the_low_target): Remove the op fields.
619 * linux-crisv32-low.cc (the_low_target): Ditto.
620 * linux-m32r-low.cc (the_low_target): Ditto.
621 * linux-m68k-low.cc (the_low_target): Ditto.
622 * linux-ppc-low.cc (the_low_target): Ditto.
623 * linux-s390-low.cc (the_low_target): Ditto.
624 * linux-sh-low.cc (the_low_target): Ditto.
625 * linux-tic6x-low.cc (the_low_target): Ditto.
626 * linux-tile-low.cc (the_low_target): Ditto.
627 * linux-xtensa-low.cc (the_low_target): Ditto.
629 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
631 Turn the 'siginfo_fixup' linux target op into a method of
632 linux_process_target.
634 * linux-low.h (struct linux_target_ops): Remove the op.
635 (class linux_process_target) <siginfo_fixup>
636 <low_siginfo_fixup>: Declare.
637 * linux-low.cc (siginfo_fixup): Turn into...
638 (linux_process_target::siginfo_fixup): ...this.
639 (linux_process_target::low_siginfo_fixup): Define.
640 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
641 (x86_siginfo_fixup): Turn into...
642 (x86_target::low_siginfo_fixup): ...this.
643 (the_low_target): Remove the op field.
644 * linux-aarch64-low.cc (class aarch64_target):
645 <low_siginfo_fixup>: Declare.
646 (aarch64_linux_siginfo_fixup): Turn into...
647 (aarch64_target::low_siginfo_fixup): ...this.
648 (the_low_target): Remove the op field.
649 * linux-arm-low.cc (the_low_target): Remove the op field.
650 * linux-bfin-low.cc (the_low_target): Ditto.
651 * linux-crisv32-low.cc (the_low_target): Ditto.
652 * linux-m32r-low.cc (the_low_target): Ditto.
653 * linux-m68k-low.cc (the_low_target): Ditto.
654 * linux-mips-low.cc (the_low_target): Ditto.
655 * linux-ppc-low.cc (the_low_target): Ditto.
656 * linux-s390-low.cc (the_low_target): Ditto.
657 * linux-sh-low.cc (the_low_target): Ditto.
658 * linux-tic6x-low.cc (the_low_target): Ditto.
659 * linux-tile-low.cc (the_low_target): Ditto.
660 * linux-xtensa-low.cc (the_low_target): Ditto.
662 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
664 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
665 linux target ops into methods of linux_process_target.
667 * linux-low.h (struct linux_target_ops): Remove the ops.
668 (class linux_process_target) <low_collect_ptrace_register>
669 <low_store_ptrace_register>: Declare.
670 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
671 (linux_process_target::low_supply_ptrace_register): Define.
673 Update the callers below.
675 (linux_process_target::fetch_register)
676 (linux_process_target::store_register)
678 * linux-x86-low.cc (the_low_target): Remove the op fields.
679 * linux-aarch64-low.cc (the_low_target): Ditto.
680 * linux-arm-low.cc (the_low_target): Ditto.
681 * linux-bfin-low.cc (the_low_target): Ditto.
682 * linux-crisv32-low.cc (the_low_target): Ditto.
683 * linux-m32r-low.cc (the_low_target): Ditto.
684 * linux-m68k-low.cc (the_low_target): Ditto.
685 * linux-sh-low.cc (the_low_target): Ditto.
686 * linux-sparc-low.cc (the_low_target): Ditto.
687 * linux-tic6x-low.cc (the_low_target): Ditto.
688 * linux-tile-low.cc (the_low_target): Ditto.
689 * linux-xtensa-low.cc (the_low_target): Ditto.
690 * linux-mips-low.cc (class mips_target)
691 <low_collect_ptrace_register>
692 <low_supply_ptrace_register>: Declare.
693 (mips_collect_ptrace_register): Turn into ...
694 (mips_target::low_collect_ptrace_register): ...this.
695 (mips_supply_ptrace_register): Turn into...
696 (mips_target::low_supply_ptrace_register): ...this.
697 (the_low_target): Remove the op fields.
698 * linux-ppc-low.cc (class ppc_target)
699 <low_collect_ptrace_register>
700 <low_supply_ptrace_register>: Declare.
701 (ppc_collect_ptrace_register): Turn into ...
702 (ppc_target::low_collect_ptrace_register): ...this.
703 (ppc_supply_ptrace_register): Turn into ...
704 (ppc_target::low_supply_ptrace_register): ...this.
705 (ppc_fill_gregset): Update for the calls to
706 low_collect_ptrace_register.
707 (the_low_target): Remove the op fields.
708 * linux-s390-low.cc (class s390_target)
709 <low_collect_ptrace_register>
710 <low_supply_ptrace_register>: Declare.
711 (s390_collect_ptrace_register): Turn into ...
712 (s390_target::low_collect_ptrace_register): ...this.
713 (s390_supply_ptrace_register): Turn into ...
714 (s390_target::low_supply_ptrace_register): ...this.
715 (s390_fill_gregset): Update for the calls to
716 low_collect_ptrace_register.
717 (the_low_target): Remove the op fields.
719 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
721 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
722 target ops into methods of linux_process_target.
724 * linux-low.h (struct linux_target_ops): Remove the ops.
725 (class linux_process_target) <check_stopped_by_watchpoint>
726 <low_stopped_by_watchpoint>
727 <low_stopped_data_address>: Declare.
728 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
729 (linux_process_target::check_stopped_by_watchpoint): ...this.
730 (linux_process_target::low_stopped_by_watchpoint): Define.
731 (linux_process_target::low_stopped_data_address): Define.
732 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
733 <low_stopped_data_address>: Declare.
734 (x86_stopped_by_watchpoint): Turn into...
735 (x86_target::low_stopped_by_watchpoint): ...this.
736 (x86_stopped_data_address): Turn into...
737 (x86_target::low_stopped_data_address): ...this.
738 (the_low_target): Remove the op fields.
739 * linux-aarch64-low.cc (class aarch64_target)
740 <low_stopped_by_watchpoint>
741 <low_stopped_data_address>: Declare.
742 (aarch64_stopped_by_watchpoint): Turn into...
743 (aarch64_target::low_stopped_by_watchpoint): ...this.
744 (aarch64_stopped_data_address): Turn into...
745 (aarch64_target::low_stopped_data_address): ...this.
746 (the_low_target): Remove the op fields.
747 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
748 <low_stopped_data_address>: Declare.
749 (arm_stopped_by_watchpoint): Turn into...
750 (arm_target::low_stopped_by_watchpoint): ...this.
751 (arm_stopped_data_address): Turn into...
752 (arm_target::low_stopped_data_address): ...this.
753 (the_low_target): Remove the op fields.
754 * linux-crisv32-low.cc (class crisv32_target)
755 <low_stopped_by_watchpoint>
756 <low_stopped_data_address>: Declare.
757 (cris_stopped_by_watchpoint): Turn into...
758 (crisv32_target::low_stopped_by_watchpoint): ...this.
759 (cris_stopped_data_address): Turn into...
760 (crisv32_target::low_stopped_data_address): ...this.
761 (the_low_target): Remove the op fields.
762 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
763 <low_stopped_data_address>: Declare.
764 (mips_stopped_by_watchpoint): Turn into...
765 (mips_target::low_stopped_by_watchpoint): ...this.
766 (mips_stopped_data_address): Turn into...
767 (mips_target::low_stopped_data_address): ...this.
768 (the_low_target): Remove the op fields.
769 * linux-bfin-low.cc (the_low_target): Remove the op fields.
770 * linux-m32r-low.cc (the_low_target): Ditto.
771 * linux-m68k-low.cc (the_low_target): Ditto.
772 * linux-ppc-low.cc (the_low_target): Ditto.
773 * linux-s390-low.cc (the_low_target): Ditto.
774 * linux-sh-low.cc (the_low_target): Ditto.
775 * linux-sparc-low.cc (the_low_target): Ditto.
776 * linux-tic6x-low.cc (the_low_target): Ditto.
777 * linux-tile-low.cc (the_low_target): Ditto.
778 * linux-xtensa-low.cc (the_low_target): Ditto.
780 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
782 Turn the 'insert_point' and 'remove_point' linux target ops into
783 methods of linux_process_target.
785 * linux-low.h (struct linux_target_ops): Remove the ops.
786 (class linux_process_target) <low_insert_point>
787 <low_remove_point>: Declare.
788 * linux-low.cc (linux_process_target::low_insert_point)
789 (linux_process_target::low_remove_point): Define.
790 (linux_process_target::insert_point)
791 (linux_process_target::remove_point): Update for calls to
792 low_insert_point and low_remove_point.
793 * linux-x86-low.cc (class x86_target) <low_insert_point>
794 <low_remove_point>: Declare.
795 (x86_insert_point): Turn into...
796 (x86_target::low_insert_point): ...this.
797 (x86_remove_point): Turn into...
798 (x86_target::low_remove_point): ...this.
799 (the_low_target): Remove the op fields.
800 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
801 <low_remove_point>: Declare.
802 (aarch64_insert_point): Turn into...
803 (aarch64_target::low_insert_point): ...this.
804 (aarch64_remove_point): Turn into...
805 (aarch64_target::low_remove_point): ...this.
806 (the_low_target): Remove the op fields.
807 * linux-arm-low.cc (class arm_target) <low_insert_point>
808 <low_remove_point>: Declare.
809 (arm_insert_point): Turn into...
810 (arm_target::low_insert_point): ...this.
811 (arm_remove_point): Turn into...
812 (arm_target::low_remove_point): ...this.
813 (the_low_target): Remove the op fields.
814 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
815 <low_remove_point>: Declare.
816 (crisv32_insert_point): Turn into...
817 (crisv32_target::low_insert_point): ...this.
818 (crisv32_remove_point): Turn into...
819 (crisv32_target::low_remove_point): ...this.
820 (the_low_target): Remove the op fields.
821 * linux-mips-low.cc (class mips_target) <low_insert_point>
822 <low_remove_point>: Declare.
823 (mips_insert_point): Turn into...
824 (mips_target::low_insert_point): ...this.
825 (mips_remove_point): Turn into...
826 (mips_target::low_remove_point): ...this.
827 (the_low_target): Remove the op fields.
828 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
829 <low_remove_point>: Declare.
830 (ppc_insert_point): Turn into...
831 (ppc_target::low_insert_point): ...this.
832 (ppc_remove_point): Turn into...
833 (ppc_target::low_remove_point): ...this.
834 (the_low_target): Remove the op fields.
835 * linux-bfin-low.cc (the_low_target): Remove the op fields.
836 * linux-m32r-low.cc (the_low_target): Ditto.
837 * linux-m68k-low.cc (the_low_target): Ditto.
838 * linux-s390-low.cc (the_low_target): Ditto.
839 * linux-sh-low.cc (the_low_target): Ditto.
840 * linux-sparc-low.cc (the_low_target): Ditto.
841 * linux-tic6x-low.cc (the_low_target): Ditto.
842 * linux-tile-low.cc (the_low_target): Ditto.
843 * linux-xtensa-low.cc (the_low_target): Ditto.
845 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
847 Remove the 'supports_z_point_type' linux target op and let the
848 concrete linux target define it by overriding the op declared in
849 process_stratum_target.
851 * linux-low.cc (linux_process_target::supports_z_point_type):
853 * linux-low.h (struct linux_target_ops): Remove the op.
854 (class linux_process_target) <supports_z_point_type>: Remove.
855 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
857 (x86_supports_z_point_type): Turn into...
858 (x86_target::supports_z_point_type): ...this.
859 (the_low_target): Remove the op field.
860 * linux-aarch64-low.cc (class aarch64_target)
861 <supports_z_point_type>: Declare.
862 (aarch64_supports_z_point_type): Turn into...
863 (aarch64_target::supports_z_point_type): ...this.
864 (the_low_target): Remove the op field.
865 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
867 (arm_supports_z_point_type): Turn into...
868 (arm_target::supports_z_point_type): ...this.
869 (the_low_target): Remove the op field.
870 * linux-crisv32-low.cc (class crisv32_target)
871 <supports_z_point_type>: Declare.
872 (cris_supports_z_point_type): Turn into...
873 (crisv32_target::supports_z_point_type): ...this.
874 (the_low_target): Remove the op field.
875 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
877 (mips_supports_z_point_type): Turn into...
878 (mips_target::supports_z_point_type): ...this.
879 (the_low_target): Remove the op field.
880 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
882 (ppc_supports_z_point_type): Turn into...
883 (ppc_target::supports_z_point_type): ...this.
884 (the_low_target): Remove the op field.
885 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
887 (s390_supports_z_point_type): Turn into...
888 (s390_target::supports_z_point_type): ...this.
889 (the_low_target): Remove the op field.
890 * linux-bfin-low.cc (the_low_target): Remove the op field.
891 * linux-m32r-low.cc (the_low_target): Ditto.
892 * linux-m68k-low.cc (the_low_target): Ditto.
893 * linux-sh-low.cc (the_low_target): Ditto.
894 * linux-sparc-low.cc (the_low_target): Ditto.
895 * linux-tic6x-low.cc (the_low_target): Ditto.
896 * linux-tile-low.cc (the_low_target): Ditto.
897 * linux-xtensa-low.cc (the_low_target): Ditto.
899 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
901 Turn the 'breakpoint_at' linux target op into a method of
902 linux_process_target.
904 * linux-low.h (struct linux_target_ops): Remove the op.
905 (class linux_process_target) <low_breakpoint_at>: Declare.
907 Update the callers below:
909 * linux-low.cc (linux_process_target::save_stop_reason)
910 (linux_process_target::thread_still_has_status_pending)
911 (linux_process_target::wait_1)
913 * linux-x86-low.cc (class x86_target)
914 <low_breakpoint_at>: Declare.
915 (x86_breakpoint_at): Turn into...
916 (x86_target::low_breakpoint_at): ...this.
917 (the_low_target): Remove the op field.
918 * linux-aarch64-low.cc (class aarch64_target)
919 <low_breakpoint_at>: Declare.
920 (aarch64_breakpoint_at): Turn into...
921 (aarch64_target::low_breakpoint_at): ...this.
922 (the_low_target): Remove the op field.
923 * linux-arm-low.cc (class arm_target)
924 <low_breakpoint_at>: Declare.
925 (arm_target::low_breakpoint_at): Define.
926 (the_low_target): Remove the op field.
927 * linux-bfin-low.cc (class bfin_target)
928 <low_breakpoint_at>: Declare.
929 (bfin_breakpoint_at): Turn into...
930 (bfin_target::low_breakpoint_at): ...this.
931 (the_low_target): Remove the op field.
932 * linux-cris-low.cc (class cris_target)
933 <low_breakpoint_at>: Declare.
934 (cris_breakpoint_at): Turn into...
935 (cris_target::low_breakpoint_at): ...this.
936 (the_low_target): Remove the op field.
937 * linux-crisv32-low.cc (class crisv32_target)
938 <low_breakpoint_at>: Declare.
939 (crisv32_breakpoint_at): Turn into...
940 (crisv32_target::low_breakpoint_at): ...this.
941 (the_low_target): Remove the op field.
942 * linux-ia64-low.cc (class ia64_target)
943 <low_breakpoint_at>: Declare.
944 (ia64_target::low_breakpoint_at): Define.
945 * linux-m32r-low.cc (class m32r_target)
946 <low_breakpoint_at>: Declare.
947 (m32r_breakpoint_at): Turn into...
948 (m32r_target::low_breakpoint_at): ...this.
949 (the_low_target): Remove the op field.
950 * linux-m68k-low.cc (class m68k_target)
951 <low_breakpoint_at>: Declare.
952 (m68k_breakpoint_at): Turn into...
953 (m68k_target::low_breakpoint_at): ...this.
954 (the_low_target): Remove the op field.
955 * linux-mips-low.cc (class mips_target)
956 <low_breakpoint_at>: Declare.
957 (mips_breakpoint_at): Turn into...
958 (mips_target::low_breakpoint_at): ...this.
959 (the_low_target): Remove the op field.
960 * linux-nios2-low.cc (class nios2_target)
961 <low_breakpoint_at>: Declare.
962 (nios2_breakpoint_at): Turn into...
963 (nios2_target::low_breakpoint_at): ...this.
964 (the_low_target): Remove the op field.
965 * linux-ppc-low.cc (class ppc_target)
966 <low_breakpoint_at>: Declare.
967 (ppc_breakpoint_at): Turn into...
968 (ppc_target::low_breakpoint_at): ...this.
969 (the_low_target): Remove the op field.
970 * linux-riscv-low.cc (class riscv_target)
971 <low_breakpoint_at>: Declare.
972 (riscv_breakpoint_at): Turn into...
973 (riscv_target::low_breakpoint_at): ...this.
974 (the_low_target): Remove the op field.
975 * linux-s390-low.cc (class s390_target)
976 <low_breakpoint_at>: Declare.
977 (s390_breakpoint_at): Turn into...
978 (s390_target::low_breakpoint_at): ...this.
979 (the_low_target): Remove the op field.
980 * linux-sh-low.cc (class sh_target)
981 <low_breakpoint_at>: Declare.
982 (sh_breakpoint_at): Turn into...
983 (sh_target::low_breakpoint_at): ...this.
984 (the_low_target): Remove the op field.
985 * linux-sparc-low.cc (class sparc_target)
986 <low_breakpoint_at>: Declare.
987 (sparc_breakpoint_at): Turn into...
988 (sparc_target::low_breakpoint_at): ...this.
989 (the_low_target): Remove the op field.
990 * linux-tic6x-low.cc (class tic6x_target)
991 <low_breakpoint_at>: Declare.
992 (tic6x_breakpoint_at): Turn into...
993 (tic6x_target::low_breakpoint_at): ...this.
994 (the_low_target): Remove the op field.
995 * linux-tile-low.cc (class tile_target)
996 <low_breakpoint_at>: Declare.
997 (tile_breakpoint_at): Turn into...
998 (tile_target::low_breakpoint_at): ...this.
999 (the_low_target): Remove the op field.
1000 * linux-xtensa-low.cc (class xtensa_target)
1001 <low_breakpoint_at>: Declare.
1002 (xtensa_breakpoint_at): Turn into...
1003 (xtensa_target::low_breakpoint_at): ...this.
1004 (the_low_target): Remove the op field.
1006 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1008 Turn the 'decr_pc_after_break' linux_target_ops field into
1009 a method of linux_process_target.
1011 * linux-low.h (struct linux_target_ops)
1012 <decr_pc_after_break>: Remove.
1013 (class linux_process_target) <low_decr_pc_after_break>: New method
1015 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1016 New method implementation.
1018 Update the users below.
1020 (linux_process_target::save_stop_reason)
1021 (linux_process_target::wait_1)
1022 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1024 (x86_target::low_decr_pc_after_break): New method implementation.
1025 (the_low_target): Remove the field.
1026 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1028 (bfin_target::low_decr_pc_after_break): New method implementation.
1029 (the_low_target): Remove the field.
1030 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1032 (m68k_target::low_decr_pc_after_break): New method implementation.
1033 (the_low_target): Remove the field.
1034 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1036 (s390_target::low_decr_pc_after_break): New method implementation.
1037 (the_low_target): Remove the field.
1038 * linux-aarch64-low.cc (the_low_target): Remove the field.
1039 * linux-arm-low.cc (the_low_target): Remove the field.
1040 * linux-cris-low.cc (the_low_target): Remove the field.
1041 * linux-crisv32-low.cc (the_low_target): Remove the field.
1042 * linux-m32r-low.cc (the_low_target): Remove the field.
1043 * linux-mips-low.cc (the_low_target): Remove the field.
1044 * linux-nios2-low.cc (the_low_target): Remove the field.
1045 * linux-ppc-low.cc (the_low_target): Remove the field.
1046 * linux-riscv-low.cc (the_low_target): Remove the field.
1047 * linux-sh-low.cc (the_low_target): Remove the field.
1048 * linux-sparc-low.cc (the_low_target): Remove the field.
1049 * linux-tic6x-low.cc (the_low_target): Remove the field.
1050 * linux-tile-low.cc (the_low_target): Remove the field.
1051 * linux-xtensa-low.cc (the_low_target): Remove the field.
1053 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1055 Remove the 'supports_software_single_step' linux target op and let
1056 the concrete linux target define it by overriding the op in
1057 process_stratum_target.
1058 Turn the 'get_next_pcs' linux target op into a method of
1059 linux_process_target.
1061 * linux-low.h (struct linux_target_ops): Remove the ops.
1062 (class linux_process_target) <supports_software_single_step>:
1064 <low_get_next_pcs>: Declare.
1065 * linux-low.cc (can_software_single_step): Remove.
1066 (linux_process_target::low_get_next_pcs): Define.
1067 (linux_process_target::supports_software_single_step): Remove.
1069 Update the callers below.
1071 (linux_process_target::handle_extended_wait)
1072 (linux_process_target::wait_1)
1073 (linux_process_target::install_software_single_step_breakpoints)
1074 (linux_process_target::single_step)
1075 (linux_process_target::thread_needs_step_over)
1076 (linux_process_target::proceed_one_lwp)
1077 (linux_process_target::supports_range_stepping)
1079 * linux-x86-low.cc (the_low_target): Remove the op field.
1080 * linux-aarch64-low.cc (the_low_target): Ditto.
1081 * linux-bfin-low.cc (the_low_target): Ditto.
1082 * linux-cris-low.cc (the_low_target): Ditto.
1083 * linux-crisv32-low.cc (the_low_target): Ditto.
1084 * linux-m32r-low.cc (the_low_target): Ditto.
1085 * linux-m68k-low.cc (the_low_target): Ditto.
1086 * linux-mips-low.cc (the_low_target): Ditto.
1087 * linux-nios2-low.cc (the_low_target): Ditto.
1088 * linux-ppc-low.cc (the_low_target): Ditto.
1089 * linux-riscv-low.cc (the_low_target): Ditto.
1090 * linux-s390-low.cc (the_low_target): Ditto.
1091 * linux-sh-low.cc (the_low_target): Ditto.
1092 * linux-sparc-low.cc (the_low_target): Ditto.
1093 * linux-tic6x-low.cc (the_low_target): Ditto.
1094 * linux-tile-low.cc (the_low_target): Ditto.
1095 * linux-xtensa-low.cc (the_low_target): Ditto.
1096 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1097 <supports_software_single_step>: Declare.
1098 (arm_target::supports_software_single_step): Define.
1099 (arm_gdbserver_get_next_pcs): Turn into...
1100 (arm_target::low_get_next_pcs): ...this.
1101 (the_low_target): Remove the op field.
1103 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1105 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1106 the concrete linux target define it by overriding the op
1107 in process_stratum_target.
1109 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1111 * linux-low.h (struct linux_target_ops): Remove the op.
1112 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1113 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1115 (x86_sw_breakpoint_from_kind): Turn into...
1116 (x86_target::sw_breakpoint_from_kind): ...this.
1117 (the_low_target): Remove the op field.
1118 * linux-aarch64-low.cc (class aarch64_target)
1119 <sw_breakpoint_from_kind>: Declare.
1120 (aarch64_sw_breakpoint_from_kind): Turn into...
1121 (aarch64_target::sw_breakpoint_from_kind): ...this.
1122 (the_low_target): Remove the op field.
1123 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1125 (arm_target::sw_breakpoint_from_kind): Define.
1126 (the_low_target): Remove the op field.
1127 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1129 (bfin_sw_breakpoint_from_kind): Turn into...
1130 (bfin_target::sw_breakpoint_from_kind): ...this.
1131 (the_low_target): Remove the op field.
1132 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1134 (cris_sw_breakpoint_from_kind): Turn into...
1135 (cris_target::sw_breakpoint_from_kind): ...this.
1136 (the_low_target): Remove the op field.
1137 * linux-crisv32-low.cc (class crisv32_target)
1138 <sw_breakpoint_from_kind>: Declare.
1139 (cris_sw_breakpoint_from_kind): Turn into...
1140 (crisv32_target::sw_breakpoint_from_kind): ...this.
1141 (the_low_target): Remove the op field.
1142 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1144 (ia64_target::sw_breakpoint_from_kind): Define.
1145 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1147 (m32r_sw_breakpoint_from_kind): Turn into...
1148 (m32r_target::sw_breakpoint_from_kind): ...this.
1149 (the_low_target): Remove the op field.
1150 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1152 (m68k_sw_breakpoint_from_kind): Turn into...
1153 (m68k_target::sw_breakpoint_from_kind): ...this.
1154 (the_low_target): Remove the op field.
1155 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1157 (mips_sw_breakpoint_from_kind): Turn into...
1158 (mips_target::sw_breakpoint_from_kind): ...this.
1159 (the_low_target): Remove the op field.
1160 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1162 (nios2_sw_breakpoint_from_kind): Turn into...
1163 (nios2_target::sw_breakpoint_from_kind): ...this.
1164 (the_low_target): Remove the op field.
1165 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1167 (ppc_sw_breakpoint_from_kind): Turn into...
1168 (ppc_target::sw_breakpoint_from_kind): ...this.
1169 (the_low_target): Remove the op field.
1170 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1172 (riscv_sw_breakpoint_from_kind): Turn into...
1173 (riscv_target::sw_breakpoint_from_kind): ...this.
1174 (the_low_target): Remove the op field.
1175 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1177 (s390_sw_breakpoint_from_kind): Turn into...
1178 (s390_target::sw_breakpoint_from_kind): ...this.
1179 (the_low_target): Remove the op field.
1180 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1182 (sh_sw_breakpoint_from_kind): Turn into...
1183 (sh_target::sw_breakpoint_from_kind): ...this.
1184 (the_low_target): Remove the op field.
1185 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1187 (sparc_sw_breakpoint_from_kind): Turn into...
1188 (sparc_target::sw_breakpoint_from_kind): ...this.
1189 (the_low_target): Remove the op field.
1190 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1192 (tic6x_sw_breakpoint_from_kind): Turn into...
1193 (tic6x_target::sw_breakpoint_from_kind): ...this.
1194 (the_low_target): Remove the op field.
1195 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1197 (tile_sw_breakpoint_from_kind): Turn into...
1198 (tile_target::sw_breakpoint_from_kind): ...this.
1199 (the_low_target): Remove the op field.
1200 * linux-xtensa-low.cc (class xtensa_target)
1201 <sw_breakpoint_from_kind>: Declare.
1202 (xtensa_sw_breakpoint_from_kind): Turn into...
1203 (xtensa_target::sw_breakpoint_from_kind): ...this.
1204 (the_low_target): Remove the op field.
1206 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1208 Remove the 'breakpoint_kind_from_pc' and
1209 'breakpoint_kind_from_current_state' linux target ops, and let the
1210 concrete linux target define them by overriding the ops of
1211 process_stratum_target.
1213 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1215 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1216 * linux-low.h (struct linux_target_ops): Remove ops.
1217 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1218 <breakpoint_kind_from_current_state>: Remove.
1219 * linux-x86-low.cc (the_low_target): Remove the op fields.
1220 * linux-bfin-low.cc (the_low_target): Ditto.
1221 * linux-cris-low.cc (the_low_target): Ditto.
1222 * linux-crisv32-low.cc (the_low_target): Ditto.
1223 * linux-m32r-low.cc (the_low_target): Ditto.
1224 * linux-m68k-low.cc (the_low_target): Ditto.
1225 * linux-mips-low.cc (the_low_target): Ditto.
1226 * linux-nios2-low.cc (the_low_target): Ditto.
1227 * linux-ppc-low.cc (the_low_target): Ditto.
1228 * linux-s390-low.cc (the_low_target): Ditto.
1229 * linux-sh-low.cc (the_low_target): Ditto.
1230 * linux-sparc-low.cc (the_low_target): Ditto.
1231 * linux-tic6x-low.cc (the_low_target): Ditto.
1232 * linux-tile-low.cc (the_low_target): Ditto.
1233 * linux-xtensa-low.cc (the_low_target): Ditto.
1234 * linux-aarch64-low.cc (class aarch64_target)
1235 <breakpoint_kind_from_pc>
1236 <breakpoint_kind_from_current_state>: Declare.
1237 (aarch64_breakpoint_kind_from_pc): Turn into...
1238 (aarch64_target::breakpoint_kind_from_pc): ...this.
1239 (aarch64_breakpoint_kind_from_current_state): Turn into...
1240 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1241 (the_low_target): Remove the op fields.
1242 * linux-arm-low.cc (class arm_target):
1243 <breakpoint_kind_from_pc>
1244 <breakpoint_kind_from_current_state>: Declare.
1245 (arm_target::breakpoint_kind_from_pc): Define.
1246 (arm_target::breakpoint_kind_from_current_state): Define.
1247 (the_low_target): Remove the op fields.
1248 * linux-riscv-low.cc (class riscv_target):
1249 <breakpoint_kind_from_pc>: Declare.
1250 (riscv_breakpoint_kind_from_pc): Turn into...
1251 (riscv_target::breakpoint_kind_from_pc): ...this.
1252 (the_low_target): Remove the op fields.
1254 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1256 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1257 of linux_process_target.
1259 * linux-low.h (struct linux_target_ops): Remove the ops.
1260 (class linux_process_target) <low_supports_breakpoints>
1262 <low_set_pc>: Declare.
1263 * linux-low.cc (supports_breakpoints): Turn into...
1264 (linux_process_target::low_supports_breakpoints): ...this.
1265 (linux_process_target::low_get_pc): Define.
1266 (linux_process_target::low_set_pc): Define.
1268 Update the callers below.
1270 (linux_process_target::get_pc)
1271 (linux_process_target::save_stop_reason)
1272 (linux_process_target::maybe_move_out_of_jump_pad)
1273 (linux_process_target::wait_1)
1274 (linux_process_target::resume_one_lwp_throw)
1275 (linux_process_target::resume)
1276 (linux_process_target::proceed_all_lwps)
1277 (linux_process_target::read_pc)
1278 (linux_process_target::write_pc)
1280 * linux-x86-low.cc (class linux_process_target)
1281 <low_supports_breakpoints>
1283 <low_set_pc>: Declare.
1284 (x86_target::low_supports_breakpoints): Define.
1285 (x86_get_pc): Turn into...
1286 (x86_target::low_get_pc): ...this.
1287 (x86_set_pc): Turn into...
1288 (x86_target::low_set_pc): ...this.
1289 (the_low_target): Remove the op fields.
1290 * linux-arm-low.cc (class arm_target)
1291 <low_supports_breakpoints>
1293 <low_set_pc>: Declare.
1294 (arm_target::low_supports_breakpoints)
1295 (arm_target::low_get_pc)
1296 (arm_target::low_set_pc): Define.
1297 (the_low_target): Remove the op fields.
1298 * linux-bfin-low.cc (class bfin_target)
1299 <low_supports_breakpoints>
1301 <low_set_pc>: Declare.
1302 (bfin_target::low_supports_breakpoints)
1303 (bfin_target::low_get_pc)
1304 (bfin_target::low_set_pc): Define.
1305 (the_low_target): Remove the op fields.
1306 * linux-cris-low.cc (class cris_target)
1307 <low_supports_breakpoints>
1309 <low_set_pc>: Declare.
1310 (cris_target::low_supports_breakpoints)
1311 (cris_target::low_get_pc)
1312 (cris_target::low_set_pc): Define.
1313 (the_low_target): Remove the op fields.
1314 * linux-crisv32-low.cc (class crisv32_target)
1315 <low_supports_breakpoints>
1317 <low_set_pc>: Declare.
1318 (crisv32_target::low_supports_breakpoints)
1319 (crisv32_target::low_get_pc)
1320 (crisv32_target::low_set_pc): Define.
1321 (the_low_target): Remove the op fields.
1322 * linux-m32r-low.cc (class m32r_target)
1323 <low_supports_breakpoints>
1325 <low_set_pc>: Declare.
1326 (m32r_target::low_supports_breakpoints)
1327 (m32r_target::low_get_pc)
1328 (m32r_target::low_set_pc): Define.
1329 (the_low_target): Remove the op fields.
1330 * linux-m68k-low.cc (class m68k_target)
1331 <low_supports_breakpoints>
1333 <low_set_pc>: Declare.
1334 (m68k_target::low_supports_breakpoints)
1335 (m68k_target::low_get_pc)
1336 (m68k_target::low_set_pc): Define.
1337 (the_low_target): Remove the op fields.
1338 * linux-nios2-low.cc (class nios2_target)
1339 <low_supports_breakpoints>
1341 <low_set_pc>: Declare.
1342 (nios2_target::low_supports_breakpoints)
1343 (nios2_target::low_get_pc)
1344 (nios2_target::low_set_pc): Define.
1345 (the_low_target): Remove the op fields.
1346 * linux-sh-low.cc (class sh_target)
1347 <low_supports_breakpoints>
1349 <low_set_pc>: Declare.
1350 (sh_target::low_supports_breakpoints)
1351 (sh_target::low_get_pc)
1352 (sh_target::low_set_pc): Define.
1353 (the_low_target): Remove the op fields.
1354 * linux-xtensa-low.cc (class xtensa_target)
1355 <low_supports_breakpoints>
1357 <low_set_pc>: Declare.
1358 (xtensa_target::low_supports_breakpoints)
1359 (xtensa_target::low_get_pc)
1360 (xtensa_target::low_set_pc): Define.
1361 (the_low_target): Remove the op fields.
1362 * linux-sparc-low.cc (class sparc_target)
1363 <low_supports_breakpoints>
1364 <low_get_pc>: Declare.
1365 (sparc_target::low_supports_breakpoints)
1366 (sparc_target::low_get_pc): Define.
1367 (the_low_target): Remove the op fields.
1368 * linux-tile-low.cc (class tile_target)
1369 <low_supports_breakpoints>
1371 <low_set_pc>: Declare.
1372 (tile_target::low_supports_breakpoints)
1373 (tile_target::low_get_pc)
1374 (tile_target::low_set_pc): Define.
1375 (the_low_target): Remove the op fields.
1376 * linux-aarch64-low.cc (class aarch64_target)
1377 <low_supports_breakpoints>
1379 <low_set_pc>: Declare.
1380 (aarch64_target::low_supports_breakpoints): Define.
1381 (aarch64_get_pc): Turn into...
1382 (aarch64_target::low_get_pc): ...this.
1383 (aarch64_set_pc): Turn into...
1384 (aarch64_target::low_set_pc): ...this.
1385 (the_low_target): Remove the op fields.
1386 * linux-mips-low.cc (class mips_target)
1387 <low_supports_breakpoints>
1389 <low_set_pc>: Declare.
1390 (mips_target::low_supports_breakpoints): Define.
1391 (mips_get_pc): Turn into...
1392 (mips_target::low_get_pc): ...this.
1393 (mips_set_pc): Turn into...
1394 (mips_target::low_set_pc): ...this.
1395 (the_low_target): Remove the op fields.
1396 * linux-ppc-low.cc (class ppc_target)
1397 <low_supports_breakpoints>
1399 <low_set_pc>: Declare.
1400 (ppc_target::low_supports_breakpoints): Define.
1401 (ppc_get_pc): Turn into...
1402 (ppc_target::low_get_pc): ...this.
1403 (ppc_set_pc): Turn into...
1404 (ppc_target::low_set_pc): ...this.
1405 (the_low_target): Remove the op fields.
1406 * linux-riscv-low.cc (class riscv_target)
1407 <low_supports_breakpoints>
1409 <low_set_pc>: Declare.
1410 (riscv_target::low_supports_breakpoints): Define.
1411 (riscv_get_pc): Turn into...
1412 (riscv_target::low_get_pc): ...this.
1413 (riscv_set_pc): Turn into...
1414 (riscv_target::low_set_pc): ...this.
1415 (the_low_target): Remove the op fields.
1416 * linux-s390-low.cc (class s390_target)
1417 <low_supports_breakpoints>
1419 <low_set_pc>: Declare.
1420 (s390_target::low_supports_breakpoints): Define.
1421 (s390_get_pc): Turn into...
1422 (s390_target::low_get_pc): ...this.
1423 (s390_set_pc): Turn into...
1424 (s390_target::low_set_pc): ...this.
1425 (the_low_target): Remove the op fields.
1426 * linux-tic6x-low.cc (class tic6x_target)
1427 <low_supports_breakpoints>
1429 <low_set_pc>: Declare.
1430 (tic6x_target::low_supports_breakpoints): Define.
1431 (tic6x_get_pc): Turn into...
1432 (tic6x_target::low_get_pc): ...this.
1433 (tic6x_set_pc): Turn into...
1434 (tic6x_target::low_set_pc): ...this.
1435 (the_low_target): Remove the op fields.
1437 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1439 Turn some more static methods in linux-low into private methods
1440 of linux_process_target.
1442 * linux-low.cc (get_pc): Turn into...
1443 (linux_process_target::get_pc): ...this.
1444 (save_stop_reason): Turn into...
1445 (linux_process_target::save_stop_reason): ...this.
1446 (thread_still_has_status_pending_p): Turn into...
1447 (linux_process_target::thread_still_has_status_pending): ...this.
1448 (status_pending_p_callback): Turn into...
1449 (linux_process_target::status_pending_p_callback): ...this.
1450 (resume_stopped_resumed_lwps): Turn into...
1451 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1452 (install_software_single_step_breakpoints): Turn into...
1453 (linux_process_target::install_software_single_step_breakpoints):
1455 (single_step): Turn into...
1456 (linux_process_target::single_step): ...this.
1457 (linux_resume_one_lwp_throw): Turn into...
1458 (linux_process_target::resume_one_lwp_throw): ...this.
1459 (linux_resume_one_lwp): Turn into...
1460 (linux_process_target::resume_one_lwp): ...this.
1461 (resume_status_pending_p): Turn into...
1462 (linux_process_target::resume_status_pending): ...this.
1463 (need_step_over_p): Turn into...
1464 (linux_process_target::thread_needs_step_over): ...this.
1465 (linux_resume_one_thread): Turn into...
1466 (linux_process_target::resume_one_thread): ...this.
1467 (proceed_one_lwp): Turn into...
1468 (linux_process_target::proceed_one_lwp): ...this.
1469 (unsuspend_and_proceed_one_lwp): Turn into...
1470 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1472 Update the calls/references to the above functions below.
1474 (linux_process_target::handle_extended_wait)
1475 (linux_process_target::filter_event)
1476 (linux_process_target::wait_for_event_filtered)
1477 (linux_process_target::wait_1)
1478 (linux_process_target::move_out_of_jump_pad)
1479 (linux_process_target::start_step_over)
1480 (linux_process_target::resume)
1481 (linux_process_target::proceed_all_lwps)
1482 (regsets_store_inferior_registers)
1483 (linux_process_target::store_register)
1485 * linux-low.h (class linux_process_target)
1488 <thread_still_has_status_pending>
1489 <status_pending_p_callback>
1490 <resume_stopped_resumed_lwps>
1491 <install_software_single_step_breakpoints>
1493 <resume_one_lwp_throw>
1495 <resume_status_pending>
1496 <thread_needs_step_over>
1499 <unsuspend_and_proceed_one_lwp>: Declare.
1501 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1503 Turn the 'fetch_register' linux target op into a method of
1504 linux_process_target.
1506 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1507 (class linux_process_target) <low_fetch_register>: Declare.
1508 * linux-x86-low.cc (the_low_target)
1509 * linux-aarch64-low.cc (the_low_target)
1510 * linux-arm-low.cc (the_low_target)
1511 * linux-bfin-low.cc (the_low_target)
1512 * linux-cris-low.cc (the_low_target)
1513 * linux-crisv32-low.cc (the_low_target)
1514 * linux-m32r-low.cc (the_low_target)
1515 * linux-m68k-low.cc (the_low_target)
1516 * linux-nios2-low.cc (the_low_target)
1517 * linux-ppc-low.cc (the_low_target)
1518 * linux-s390-low.cc (the_low_target)
1519 * linux-sh-low.cc (the_low_target)
1520 * linux-sparc-low.cc (the_low_target)
1521 * linux-tic6x-low.cc (the_low_target)
1522 * linux-tile-low.cc (the_low_target)
1523 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1524 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1526 (ia64_fetch_register): Turn into...
1527 (ia64_target::low_fetch_register): ...this.
1528 (the_low_target): Remove the op field.
1529 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1531 (mips_fetch_register): Turn into...
1532 (mips_target::low_fetch_register): ...this.
1533 (the_low_target): Remove the op field.
1534 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1536 (riscv_fetch_register): Turn into...
1537 (riscv_target::low_fetch_register): ...this.
1538 (the_low_target): Remove the op field.
1540 Update the callers below.
1542 * linux-low.cc (linux_process_target::fetch_registers)
1543 (linux_process_target::low_fetch_register)
1545 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1547 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1548 linux target ops into methods of linux_process_target.
1550 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1551 (class linux_process_target) <fetch_register>
1553 <usr_fetch_inferior_registers>
1554 <usr_store_inferior_registers>
1555 <low_cannot_fetch_register>
1556 <low_cannot_fetch_register> Declare.
1557 * linux-low.cc (fetch_register): Turn into...
1558 (linux_process_target::fetch_register): ...this.
1559 (store_register): Turn into ...
1560 (linux_process_target::store_register): ...this.
1561 (usr_fetch_inferior_registers): Turn into...
1562 (linux_process_target::usr_fetch_inferior_registers): ...this.
1563 (usr_store_inferior_registers): Turn into...
1564 (linux_process_target::usr_store_inferior_registers): ...this.
1565 * linux-x86-low.cc (class x86_target)
1566 <low_cannot_fetch_register>
1567 <low_cannot_store_register>: Declare.
1568 (x86_cannot_store_register): Turn into...
1569 (x86_target::low_cannot_store_register): ...this.
1570 (x86_cannot_fetch_register): Turn into...
1571 (x86_target::low_cannot_fetch_register): ...this.
1572 (the_low_target): Remove the target op fields.
1573 * linux-aarch64-low.cc (class aarch64_target)
1574 <low_cannot_fetch_register>
1575 <low_cannot_store_register>: Declare.
1576 (aarch64_target::low_cannot_fetch_register)
1577 (aarch64_target::low_cannot_store_register): Define.
1578 (the_low_target): Remove the op fields.
1579 * linux-arm-low.cc (class arm_target)
1580 <low_cannot_fetch_register>
1581 <low_cannot_store_register>: Declare.
1582 (arm_cannot_fetch_register): Turn into...
1583 (arm_target::low_cannot_fetch_register): ...this.
1584 (arm_cannot_store_register): Turn into...
1585 (arm_target::low_cannot_store_register): ...this.
1586 (the_low_target): Remove the op fields.
1587 * linux-bfin-low.cc (class bfin_target)
1588 <low_cannot_fetch_register>
1589 <low_cannot_store_register>: Declare.
1590 (bfin_cannot_fetch_register): Turn into...
1591 (bfin_target::low_cannot_fetch_register): ...this.
1592 (bfin_cannot_store_register): Turn into...
1593 (bfin_target::low_cannot_store_register): ...this.
1594 (the_low_target): Remove the op fields.
1595 * linux-cris-low.cc (class cris_target)
1596 <low_cannot_fetch_register>
1597 <low_cannot_store_register>: Declare.
1598 (cris_cannot_fetch_register): Turn into...
1599 (cris_target::low_cannot_fetch_register): ...this.
1600 (cris_cannot_store_register): Turn into...
1601 (cris_target::low_cannot_store_register): ...this.
1602 (the_low_target): Remove the op fields.
1603 * linux-crisv32-low.cc (class crisv32_target)
1604 <low_cannot_fetch_register>
1605 <low_cannot_store_register>: Declare.
1606 (crisv32_target::low_cannot_fetch_register)
1607 (crisv32_target::low_cannot_store_register): Define.
1608 (the_low_target): Remove the op fields.
1609 * linux-ia64-low.cc (class ia64_target)
1610 <low_cannot_fetch_register>
1611 <low_cannot_store_register>: Declare.
1612 (ia64_cannot_fetch_register): Turn into...
1613 (ia64_target::low_cannot_fetch_register): ...this.
1614 (ia64_cannot_store_register): Turn into...
1615 (ia64_target::low_cannot_store_register): ...this.
1616 (the_low_target): Remove the op fields.
1617 * linux-m32r-low.cc (class m32r_target)
1618 <low_cannot_fetch_register>
1619 <low_cannot_store_register>: Declare.
1620 (m32r_cannot_fetch_register): Turn into...
1621 (m32r_target::low_cannot_fetch_register): ...this.
1622 (m32r_cannot_store_register): Turn into...
1623 (m32r_target::low_cannot_store_register): ...this.
1624 (the_low_target): Remove the op fields.
1625 * linux-m68k-low.cc (class m68k_target)
1626 <low_cannot_fetch_register>
1627 <low_cannot_store_register>: Declare.
1628 (m68k_cannot_fetch_register): Turn into...
1629 (m68k_target::low_cannot_fetch_register): ...this.
1630 (m68k_cannot_store_register): Turn into...
1631 (m68k_target::low_cannot_store_register): ...this.
1632 (the_low_target): Remove the op fields.
1633 * linux-mips-low.cc (class mips_target)
1634 <low_cannot_fetch_register>
1635 <low_cannot_store_register>: Declare.
1636 (mips_cannot_fetch_register): Turn into...
1637 (mips_target::low_cannot_fetch_register): ...this.
1638 (mips_cannot_store_register): Turn into...
1639 (mips_target::low_cannot_store_register): ...this.
1640 (get_usrregs_info): Inline at the call sites in
1641 low_cannot_fetch_register and low_cannot_store_register,
1643 (the_low_target): Remove the op fields.
1644 * linux-nios2-low.cc (class nios2_target)
1645 <low_cannot_fetch_register>
1646 <low_cannot_store_register>: Declare.
1647 (nios2_cannot_fetch_register): Turn into...
1648 (nios2_target::low_cannot_fetch_register): ...this.
1649 (nios2_cannot_store_register): Turn into...
1650 (nios2_target::low_cannot_store_register): ...this.
1651 (the_low_target): Remove the op fields.
1652 * linux-ppc-low.cc (class ppc_target)
1653 <low_cannot_fetch_register>
1654 <low_cannot_store_register>: Declare.
1655 (ppc_cannot_fetch_register): Turn into...
1656 (ppc_target::low_cannot_fetch_register): ...this.
1657 (ppc_cannot_store_register): Turn into...
1658 (ppc_target::low_cannot_store_register): ...this.
1659 (the_low_target): Remove the op fields.
1660 * linux-riscv-low.cc (class riscv_target)
1661 <low_cannot_fetch_register>
1662 <low_cannot_store_register>: Declare.
1663 (riscv_target::low_cannot_fetch_register)
1664 (riscv_target::low_cannot_store_register): Define.
1665 (the_low_target): Remove the op fields.
1666 * linux-s390-low.cc (class s390_target)
1667 <low_cannot_fetch_register>
1668 <low_cannot_store_register>: Declare.
1669 (s390_cannot_fetch_register): Turn into...
1670 (s390_target::low_cannot_fetch_register): ...this.
1671 (s390_cannot_store_register): Turn into...
1672 (s390_target::low_cannot_store_register): ...this.
1673 (the_low_target): Remove the op fields.
1674 * linux-sh-low.cc (class sh_target)
1675 <low_cannot_fetch_register>
1676 <low_cannot_store_register>: Declare.
1677 (sh_cannot_fetch_register): Turn into...
1678 (sh_target::low_cannot_fetch_register): ...this.
1679 (sh_cannot_store_register): Turn into...
1680 (sh_target::low_cannot_store_register): ...this.
1681 (the_low_target): Remove the op fields.
1682 * linux-sparc-low.cc (class sparc_target)
1683 <low_cannot_fetch_register>
1684 <low_cannot_store_register>: Declare.
1685 (sparc_cannot_fetch_register): Turn into...
1686 (sparc_target::low_cannot_fetch_register): ...this.
1687 (sparc_cannot_store_register): Turn into...
1688 (sparc_target::low_cannot_store_register): ...this.
1689 (the_low_target): Remove the op fields.
1690 * linux-tic6x-low.cc (class tic6x_target)
1691 <low_cannot_fetch_register>
1692 <low_cannot_store_register>: Declare.
1693 (tic6x_cannot_fetch_register): Turn into...
1694 (tic6x_target::low_cannot_fetch_register): ...this.
1695 (tic6x_cannot_store_register): Turn into...
1696 (tic6x_target::low_cannot_store_register): ...this.
1697 (the_low_target): Remove the op fields.
1698 * linux-tile-low.cc (class tile_target)
1699 <low_cannot_fetch_register>
1700 <low_cannot_store_register>: Declare.
1701 (tile_cannot_fetch_register): Turn into...
1702 (tile_target::low_cannot_fetch_register): ...this.
1703 (tile_cannot_store_register): Turn into...
1704 (tile_target::low_cannot_store_register): ...this.
1705 (the_low_target): Remove the op fields.
1706 * linux-xtensa-low.cc (class xtensa_target)
1707 <low_cannot_fetch_register>
1708 <low_cannot_store_register>: Declare.
1709 (xtensa_target::low_cannot_fetch_register)
1710 (xtensa_target::low_cannot_store_register): Define.
1711 (the_low_target): Remove the op fields.
1713 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1715 Turn the 'regs_info' linux target op into a method of
1716 linux_process_target.
1718 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1719 (class linux_process_target) <get_regs_info>: Define.
1721 Update the callers below.
1723 * linux-low.cc (linux_process_target::fetch_registers)
1724 (linux_process_target::store_registers)
1725 * proc-service.cc (gregset_info)
1727 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1728 (x86_linux_regs_info): Turn into ...
1729 (x86_target::get_regs_info): ...this.
1730 (the_low_target): Remove the op field.
1731 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1733 (aarch64_regs_info): Turn into ...
1734 (aarch64_target::get_regs_info): ...this.
1735 (the_low_target): Remove the op field.
1736 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1737 (arm_regs_info): Turn into ...
1738 (arm_target::get_regs_info): ...this.
1739 (the_low_target): Remove the op field.
1740 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1741 (bfin_regs_info): Turn into ...
1742 (bfin_target::get_regs_info): ...this.
1743 (the_low_target): Remove the op field.
1744 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1745 (cris_regs_info): Turn into ...
1746 (cris_target::get_regs_info): ...this.
1747 (the_low_target): Remove the op field.
1748 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1750 (crisv32_regs_info): Turn into ...
1751 (crisv32_target::get_regs_info): ...this.
1752 (the_low_target): Remove the op field.
1753 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1754 (ia64_regs_info): Turn into ...
1755 (ia64_target::get_regs_info): ...this.
1756 (the_low_target): Remove the op field.
1757 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1758 (m32r_regs_info): Turn into ...
1759 (m32r_target::get_regs_info): ...this.
1760 (the_low_target): Remove the op field.
1761 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1762 (m68k_regs_info): Turn into ...
1763 (m68k_target::get_regs_info): ...this.
1764 (the_low_target): Remove the op field.
1765 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1766 (mips_regs_info): Turn into ...
1767 (mips_target::get_regs_info): ...this.
1768 (the_low_target): Remove the op field.
1769 (get_usrregs_info): Update the call to the op.
1770 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1771 (nios2_regs_info): Turn into ...
1772 (nios2_target::get_regs_info): ...this.
1773 (the_low_target): Remove the op field.
1774 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1775 (ppc_regs_info): Turn into ...
1776 (ppc_target::get_regs_info): ...this.
1777 (the_low_target): Remove the op field.
1778 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1779 (riscv_regs_info): Turn into ...
1780 (riscv_target::get_regs_info): ...this.
1781 (the_low_target): Remove the op field.
1782 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1783 (s390_regs_info): Turn into ...
1784 (s390_target::get_regs_info): ...this.
1785 (the_low_target): Remove the op field.
1786 (s390_collect_ptrace_register)
1787 (s390_supply_ptrace_register)
1788 (s390_fill_gregset): Update the call to the op.
1789 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1790 (sh_regs_info): Turn into ...
1791 (sh_target::get_regs_info): ...this.
1792 (the_low_target): Remove the op field.
1793 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1794 (sparc_regs_info): Turn into ...
1795 (sparc_target::get_regs_info): ...this.
1796 (the_low_target): Remove the op field.
1797 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1798 (tic6x_regs_info): Turn into ...
1799 (tic6x_target::get_regs_info): ...this.
1800 (the_low_target): Remove the op field.
1801 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1802 (tile_regs_info): Turn into ...
1803 (tile_target::get_regs_info): ...this.
1804 (the_low_target): Remove the op field.
1805 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1807 (xtensa_regs_info): Turn into ...
1808 (xtensa_target::get_regs_info): ...this.
1809 (the_low_target): Remove the op field.
1811 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1813 Turn the 'arch_setup' linux target op into a method of
1814 linux_process_target.
1816 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1817 (class linux_process_target) <arch_setup_thread>
1818 <low_arch_setup>: New declarations.
1819 * linux-low.cc (linux_arch_setup): Delete.
1820 (linux_arch_setup_thread): Turn into...
1821 (linux_process_target::arch_setup_thread): ... this.
1823 Update the callers below.
1825 (linux_process_target::handle_extended_wait)
1826 (linux_process_target::post_create_inferior)
1827 (linux_process_target::filter_event)
1829 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1831 (x86_linux_update_xmltarget): Turn into...
1832 (x86_target::update_xmltarget): ...this.
1833 (x86_linux_process_qsupported): Update the call to
1834 x86_linux_update_xmltarget.
1835 (x86_arch_setup): Turn into ...
1836 (x86_target::low_arch_setup): ...this.
1837 (the_low_target): Remove the op field.
1838 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1840 (aarch64_arch_setup): Turn into ...
1841 (aarch64_target::low_arch_setup): ...this.
1842 (the_low_target): Remove the op field.
1843 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1845 (arm_arch_setup): Turn into ...
1846 (arm_target::low_arch_setup): ...this.
1847 (the_low_target): Remove the op field.
1848 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1850 (bfin_arch_setup): Turn into ...
1851 (bfin_target::low_arch_setup): ...this.
1852 (the_low_target): Remove the op field.
1853 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1855 (cris_arch_setup): Turn into ...
1856 (cris_target::low_arch_setup): ...this.
1857 (the_low_target): Remove the op field.
1858 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1860 (crisv32_arch_setup): Turn into ...
1861 (crisv32_target::low_arch_setup): ...this.
1862 (the_low_target): Remove the op field.
1863 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1865 (ia64_arch_setup): Turn into ...
1866 (ia64_target::low_arch_setup): ...this.
1867 (the_low_target): Remove the op field.
1868 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1870 (m32r_arch_setup): Turn into ...
1871 (m32r_target::low_arch_setup): ...this.
1872 (the_low_target): Remove the op field.
1873 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1875 (m68k_arch_setup): Turn into ...
1876 (m68k_target::low_arch_setup): ...this.
1877 (the_low_target): Remove the op field.
1878 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1880 (mips_arch_setup): Turn into ...
1881 (mips_target::low_arch_setup): ...this.
1882 (the_low_target): Remove the op field.
1883 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1885 (nios2_arch_setup): Turn into ...
1886 (nios2_target::low_arch_setup): ...this.
1887 (the_low_target): Remove the op field.
1888 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1890 (ppc_arch_setup): Turn into ...
1891 (ppc_target::low_arch_setup): ...this.
1892 (the_low_target): Remove the op field.
1893 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1895 (riscv_arch_setup): Turn into ...
1896 (riscv_target::low_arch_setup): ...this.
1897 (the_low_target): Remove the op field.
1898 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1900 (s390_arch_setup): Turn into ...
1901 (s390_target::low_arch_setup): ...this.
1902 (the_low_target): Remove the op field.
1903 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1905 (sh_arch_setup): Turn into ...
1906 (sh_target::low_arch_setup): ...this.
1907 (the_low_target): Remove the op field.
1908 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1910 (sparc_arch_setup): Turn into ...
1911 (sparc_target::low_arch_setup): ...this.
1912 (the_low_target): Remove the op field.
1913 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1915 (tic6x_arch_setup): Turn into ...
1916 (tic6x_target::low_arch_setup): ...this.
1917 (the_low_target): Remove the op field.
1918 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1920 (tile_arch_setup): Turn into ...
1921 (tile_target::low_arch_setup): ...this.
1922 (the_low_target): Remove the op field.
1923 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1925 (xtensa_arch_setup): Turn into ...
1926 (xtensa_target::low_arch_setup): ...this.
1927 (the_low_target): Remove the op field.
1929 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1931 * linux-low.h (the_linux_target): New extern declaration.
1932 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1934 (the_linux_target): Remove.
1935 * linux-x86-low.cc (class x86_target): New class.
1936 (the_x86_target): New static object.
1937 (the_linux_target): Define as pointer to the_x86_target.
1938 * linux-aarch64-low.cc (class aarch64_target): New class.
1939 (the_aarch64_target): New static object.
1940 (the_linux_target): Define as pointer to the_aarch64_target.
1941 * linux-arm-low.cc (class arm_target): New class.
1942 (the_arm_target): New static object.
1943 (the_linux_target): Define as pointer to the_arm_target.
1944 * linux-bfin-low.cc (class bfin_target): New class.
1945 (the_bfin_target): New static object.
1946 (the_linux_target): Define as pointer to the_bfin_target.
1947 * linux-cris-low.cc (class cris_target): New class.
1948 (the_cris_target): New static object.
1949 (the_linux_target): Define as pointer to the_cris_target.
1950 * linux-crisv32-low.cc (class crisv32_target): New class.
1951 (the_crisv32_target): New static object.
1952 (the_linux_target): Define as pointer to the_crisv32_target.
1953 * linux-ia64-low.cc (class ia64_target): New class.
1954 (the_ia64_target): New static object.
1955 (the_linux_target): Define as pointer to the_ia64_target.
1956 * linux-m32r-low.cc (class m32r_target): New class.
1957 (the_m32r_target): New static object.
1958 (the_linux_target): Define as pointer to the_m32r_target.
1959 * linux-m68k-low.cc (class m68k_target): New class.
1960 (the_m68k_target): New static object.
1961 (the_linux_target): Define as pointer to the_m68k_target.
1962 * linux-mips-low.cc (class mips_target): New class.
1963 (the_mips_target): New static object.
1964 (the_linux_target): Define as pointer to the_mips_target.
1965 * linux-nios2-low.cc (class nios2_target): New class.
1966 (the_nios2_target): New static object.
1967 (the_linux_target): Define as pointer to the_nios2_target.
1968 * linux-ppc-low.cc (class ppc_target): New class.
1969 (the_ppc_target): New static object.
1970 (the_linux_target): Define as pointer to the_ppc_target.
1971 * linux-riscv-low.cc (class riscv_target): New class.
1972 (the_riscv_target): New static object.
1973 (the_linux_target): Define as pointer to the_riscv_target.
1974 * linux-s390-low.cc (class s390_target): New class.
1975 (the_s390_target): New static object.
1976 (the_linux_target): Define as pointer to the_s390_target.
1977 * linux-sh-low.cc (class sh_target): New class.
1978 (the_sh_target): New static object.
1979 (the_linux_target): Define as pointer to the_sh_target.
1980 * linux-sparc-low.cc (class sparc_target): New class.
1981 (the_sparc_target): New static object.
1982 (the_linux_target): Define as pointer to the_sparc_target.
1983 * linux-tic6x-low.cc (class tic6x_target): New class.
1984 (the_tic6x_target): New static object.
1985 (the_linux_target): Define as pointer to the_tic6x_target.
1986 * linux-tile-low.cc (class tile_target): New class.
1987 (the_tile_target): New static object.
1988 (the_linux_target): Define as pointer to the_tile_target.
1989 * linux-xtensa-low.cc (class xtensa_target): New class.
1990 (the_xtensa_target): New static object.
1991 (the_linux_target): Define as pointer to the_xtensa_target.
1993 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1995 Turn some static functions in linux-low.cc into private methods of
1996 linux_process_target.
1998 * linux-low.cc (handle_extended_wait): Turn into ...
1999 (linux_process_target::handle_extended_wait): ...this. Call
2000 'mourn' on 'this' object instead of 'the_target'.
2001 (maybe_move_out_of_jump_pad): Turn into...
2002 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2003 (linux_low_filter_event): Turn into...
2004 (linux_process_target::filter_event): ...this.
2005 (linux_wait_for_event_filtered): Turn into...
2006 (linux_process_target::wait_for_event_filtered): ...this.
2007 (linux_wait_for_event): Turn into...
2008 (linux_process_target::wait_for_event): ...this.
2009 (linux_wait_1): Turn into...
2010 (linux_process_target::wait_1): ...this.
2011 (wait_for_sigstop): Turn into...
2012 (linux_process_target::wait_for_sigstop): ...this.
2013 (move_out_of_jump_pad_callback): Turn into...
2014 (linux_process_target::move_out_of_jump_pad): ...this.
2015 (stop_all_lwps): Turn into...
2016 (linux_process_target::stop_all_lwps): ...this.
2017 (start_step_over): Turn into...
2018 (linux_process_target::start_step_over): ...this.
2019 (complete_ongoing_step_over): Turn into...
2020 (linux_process_target::complete_ongoing_step_over): ...this.
2021 (proceed_all_lwps): Turn into...
2022 (linux_process_target::proceed_all_lwps): ...this.
2023 (unstop_all_lwps): Turn into...
2024 (linux_process_target::unstop_all_lwps): ...this.
2026 * linux-low.h (class linux_process_target)
2027 <handle_extended_wait>
2028 <maybe_move_out_of_jump_pad>
2030 <wait_for_event_filtered>
2034 <move_out_of_jump_pad>
2037 <complete_ongoing_step_over>
2039 <unstop_all_lwps>: Declare.
2041 Update the callers below.
2043 * linux-low.cc (linux_process_target::attach): Update.
2044 (linux_process_target::stabilize_threads): Ditto.
2045 (linux_process_target::wait): Ditto.
2047 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2049 * linux-low.h (struct linux_target_ops): Update the comment for
2050 'cannot_store_register' to return 0 or 1.
2051 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2054 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
2056 * config.in: Re-generate.
2057 * configure: Re-generate.
2059 2020-03-17 Kamil Rytarowski <n54@gmx.com>
2061 * regcache.cc (find_register_by_number): Update.
2062 * tdesc.cc (init_target_desc): Likewise.
2063 * tdesc.h (target_desc::reg_defs): Likewise.
2065 2020-03-12 Tom Tromey <tom@tromey.com>
2067 * configure: Rebuild.
2068 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2069 (WIN32APILIBS): New subst.
2070 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2072 (gdbsupport/%.o): Remove target.
2073 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2074 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2075 (WIN32APILIBS): New variable.
2076 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2077 (gdbreplay$(EXEEXT)): Likewise.
2079 2020-03-12 Tom Tromey <tom@tromey.com>
2081 * config.in, configure: Rebuild.
2082 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2083 * acinclude.m4: Include gettext-sister.m4.
2084 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2086 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2087 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2089 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2091 * acinclude.m4: Update path to selftest.m4.
2093 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2095 * configure.ac: Don't source bfd/development.sh, move
2096 GDB_AC_COMMON higher.
2097 * configure: Re-generate.
2099 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2101 * configure: Re-generate.
2103 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
2105 * configure: Re-generate.
2107 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2109 * .dir-locals.el: New file.
2111 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2113 * .gitattributes: New file.
2115 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2117 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2118 reply into an S reply.
2119 * server.cc (disable_packet_T): New global.
2120 (captured_main): Set new global when appropriate.
2121 * server.h (disable_packet_T): Declare.
2123 2020-02-21 Tom Tromey <tom@tromey.com>
2125 * Makefile.in (mostlyclean): New target.
2127 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2129 * target.h (struct process_stratum_target): Remove.
2130 (class process_target): Rename to ...
2131 (class process_stratum_target): ... this.
2132 * linux-low.h (class linux_process_target): Derive from
2133 'process_stratum_target'.
2134 * linux-low.cc (linux_target_ops): Remove.
2135 (initialize_low): Set the_target to the singleton instance of
2136 linux_process_target.
2137 * lynx-low.h (class lynx_process_target): Derive from
2138 'process_stratum_target'.
2139 * lynx-low.cc (lynx_target_ops): Remove.
2140 (initialize_low): Set the_target to the singleton instance of
2141 lynx_process_target.
2142 * nto-low.h (class nto_process_target): Derive from
2143 'process_stratum_target'.
2144 * nto-low.cc (nto_target_ops): Remove.
2145 (initialize_low): Set the_target to the singleton instance of
2147 * win32-low.h (class win32_process_target): Derive from
2148 'process_stratum_target'.
2149 * win32-low.cc (win32_target_ops): Remove.
2150 (initialize_low): Set the_target to the singleton instance of
2151 win32_process_target.
2153 Replace 'the_target->pt' with 'the_target' in the uses below.
2155 * hostio.cc (hostio_error)
2160 * linux-aarch32-low.cc (arm_breakpoint_at)
2161 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2162 * linux-arm-low.cc (arm_sigreturn_next_pc)
2164 (arm_get_syscall_trapinfo)
2165 * linux-cris-low.cc (cris_breakpoint_at)
2166 * linux-crisv32-low.cc (cris_breakpoint_at)
2167 * linux-low.cc (handle_extended_wait)
2170 (linux_process_target::breakpoint_kind_from_pc)
2172 * linux-m32r-low.cc (m32r_breakpoint_at)
2173 * linux-mips-low.cc (mips_breakpoint_at)
2174 * linux-nios2-low.cc (nios2_breakpoint_at)
2175 * linux-ppc-low.cc (ppc_breakpoint_at)
2176 * linux-s390-low.cc (s390_get_hwcap)
2177 * linux-sh-low.cc (sh_breakpoint_at)
2178 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2179 (sparc_store_gregset_from_stack)
2180 (sparc_breakpoint_at)
2181 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2182 * linux-tile-low.cc (tile_breakpoint_at)
2183 * linux-x86-low.cc (x86_breakpoint_at)
2184 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2185 * mem-break.cc (bp_size)
2187 (insert_memory_breakpoint)
2188 (set_raw_breakpoint_at)
2189 (delete_raw_breakpoint)
2191 (uninsert_raw_breakpoint)
2192 (reinsert_raw_breakpoint)
2193 (validate_inserted_breakpoint)
2194 * regcache.cc (regcache_read_pc)
2196 * remote-utils.cc (putpkt_binary_1)
2199 (prepare_resume_reply)
2200 * server.cc (handle_general_set)
2203 (handle_qxfer_exec_file)
2204 (handle_qxfer_libraries_svr4)
2205 (handle_qxfer_osdata)
2206 (handle_qxfer_siginfo)
2207 (handle_qxfer_fdpic)
2211 (queue_stop_reply_callback)
2213 * target.cc (prepare_to_access_memory)
2214 (done_accessing_memory)
2215 (read_inferior_memory)
2216 (target_write_memory)
2217 (target_stop_and_wait)
2219 (target_mourn_inferior)
2220 (target_continue_no_signal)
2222 (target_supports_multi_process)
2225 (target_create_inferior)
2226 (target_post_create_inferior)
2228 (target_supports_fork_events)
2229 (target_supports_vfork_events)
2230 (target_supports_exec_events)
2231 (target_handle_new_gdb_connection)
2234 (fetch_inferior_registers)
2235 (store_inferior_registers)
2237 (target_supports_non_stop)
2239 (target_process_qsupported)
2240 (target_supports_catch_syscall)
2241 (target_get_ipa_tdesc_idx)
2242 (target_supports_tracepoints)
2243 (target_supports_fast_tracepoints)
2244 (target_get_min_fast_tracepoint_insn_len)
2245 (target_thread_stopped)
2247 (target_unpause_all)
2248 (target_stabilize_threads)
2249 (target_install_fast_tracepoint_jump_pad)
2251 (target_supports_disable_randomization)
2252 (target_supports_agent)
2253 (target_enable_btrace)
2254 (target_disable_btrace)
2255 (target_read_btrace)
2256 (target_read_btrace_conf)
2257 (target_supports_range_stepping)
2258 (target_supports_stopped_by_sw_breakpoint)
2259 (target_stopped_by_sw_breakpoint)
2260 (target_supports_stopped_by_hw_breakpoint)
2261 (target_supports_hardware_single_step)
2262 (target_stopped_by_hw_breakpoint)
2263 (target_breakpoint_kind_from_pc)
2264 (target_breakpoint_kind_from_current_state)
2265 (target_supports_software_single_step)
2266 (target_core_of_thread)
2267 (target_thread_name)
2268 (target_thread_handle)
2269 * win32-low.cc (do_initial_child_stuff)
2271 Rename target op default definitions listed below.
2273 * target.cc (process_target::post_create_inferior): Rename as ...
2274 (process_stratum_target::post_create_inferior): ... this.
2275 (process_target::prepare_to_access_memory): Rename as ...
2276 (process_stratum_target::prepare_to_access_memory): ... this.
2277 (process_target::done_accessing_memory): Rename as ...
2278 (process_stratum_target::done_accessing_memory): ... this.
2279 (process_target::look_up_symbols): Rename as ...
2280 (process_stratum_target::look_up_symbols): ... this.
2281 (process_target::supports_read_auxv): Rename as ...
2282 (process_stratum_target::supports_read_auxv): ... this.
2283 (process_target::read_auxv): Rename as ...
2284 (process_stratum_target::read_auxv): ... this.
2285 (process_target::supports_z_point_type): Rename as ...
2286 (process_stratum_target::supports_z_point_type): ... this.
2287 (process_target::insert_point): Rename as ...
2288 (process_stratum_target::insert_point): ... this.
2289 (process_target::remove_point): Rename as ...
2290 (process_stratum_target::remove_point): ... this.
2291 (process_target::stopped_by_sw_breakpoint): Rename as ...
2292 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2293 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2294 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2295 (process_target::stopped_by_hw_breakpoint): Rename as ...
2296 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2297 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2298 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2299 (process_target::supports_hardware_single_step): Rename as ...
2300 (process_stratum_target::supports_hardware_single_step): ... this.
2301 (process_target::stopped_by_watchpoint): Rename as ...
2302 (process_stratum_target::stopped_by_watchpoint): ... this.
2303 (process_target::stopped_data_address): Rename as ...
2304 (process_stratum_target::stopped_data_address): ... this.
2305 (process_target::supports_read_offsets): Rename as ...
2306 (process_stratum_target::supports_read_offsets): ... this.
2307 (process_target::read_offsets): Rename as ...
2308 (process_stratum_target::read_offsets): ... this.
2309 (process_target::supports_get_tls_address): Rename as ...
2310 (process_stratum_target::supports_get_tls_address): ... this.
2311 (process_target::get_tls_address): Rename as ...
2312 (process_stratum_target::get_tls_address): ... this.
2313 (process_target::hostio_last_error): Rename as ...
2314 (process_stratum_target::hostio_last_error): ... this.
2315 (process_target::supports_qxfer_osdata): Rename as ...
2316 (process_stratum_target::supports_qxfer_osdata): ... this.
2317 (process_target::qxfer_osdata): Rename as ...
2318 (process_stratum_target::qxfer_osdata): ... this.
2319 (process_target::supports_qxfer_siginfo): Rename as ...
2320 (process_stratum_target::supports_qxfer_siginfo): ... this.
2321 (process_target::qxfer_siginfo): Rename as ...
2322 (process_stratum_target::qxfer_siginfo): ... this.
2323 (process_target::supports_non_stop): Rename as ...
2324 (process_stratum_target::supports_non_stop): ... this.
2325 (process_target::async): Rename as ...
2326 (process_stratum_target::async): ... this.
2327 (process_target::start_non_stop): Rename as ...
2328 (process_stratum_target::start_non_stop): ... this.
2329 (process_target::supports_multi_process): Rename as ...
2330 (process_stratum_target::supports_multi_process): ... this.
2331 (process_target::supports_fork_events): Rename as ...
2332 (process_stratum_target::supports_fork_events): ... this.
2333 (process_target::supports_vfork_events): Rename as ...
2334 (process_stratum_target::supports_vfork_events): ... this.
2335 (process_target::supports_exec_events): Rename as ...
2336 (process_stratum_target::supports_exec_events): ... this.
2337 (process_target::handle_new_gdb_connection): Rename as ...
2338 (process_stratum_target::handle_new_gdb_connection): ... this.
2339 (process_target::handle_monitor_command): Rename as ...
2340 (process_stratum_target::handle_monitor_command): ... this.
2341 (process_target::core_of_thread): Rename as ...
2342 (process_stratum_target::core_of_thread): ... this.
2343 (process_target::supports_read_loadmap): Rename as ...
2344 (process_stratum_target::supports_read_loadmap): ... this.
2345 (process_target::read_loadmap): Rename as ...
2346 (process_stratum_target::read_loadmap): ... this.
2347 (process_target::process_qsupported): Rename as ...
2348 (process_stratum_target::process_qsupported): ... this.
2349 (process_target::supports_tracepoints): Rename as ...
2350 (process_stratum_target::supports_tracepoints): ... this.
2351 (process_target::read_pc): Rename as ...
2352 (process_stratum_target::read_pc): ... this.
2353 (process_target::write_pc): Rename as ...
2354 (process_stratum_target::write_pc): ... this.
2355 (process_target::supports_thread_stopped): Rename as ...
2356 (process_stratum_target::supports_thread_stopped): ... this.
2357 (process_target::thread_stopped): Rename as ...
2358 (process_stratum_target::thread_stopped): ... this.
2359 (process_target::supports_get_tib_address): Rename as ...
2360 (process_stratum_target::supports_get_tib_address): ... this.
2361 (process_target::get_tib_address): Rename as ...
2362 (process_stratum_target::get_tib_address): ... this.
2363 (process_target::pause_all): Rename as ...
2364 (process_stratum_target::pause_all): ... this.
2365 (process_target::unpause_all): Rename as ...
2366 (process_stratum_target::unpause_all): ... this.
2367 (process_target::stabilize_threads): Rename as ...
2368 (process_stratum_target::stabilize_threads): ... this.
2369 (process_target::supports_fast_tracepoints): Rename as ...
2370 (process_stratum_target::supports_fast_tracepoints): ... this.
2371 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2372 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2373 (process_target::emit_ops): Rename as ...
2374 (process_stratum_target::emit_ops): ... this.
2375 (process_target::supports_disable_randomization): Rename as ...
2376 (process_stratum_target::supports_disable_randomization): ... this.
2377 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2378 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2379 (process_target::qxfer_libraries_svr4): Rename as ...
2380 (process_stratum_target::qxfer_libraries_svr4): ... this.
2381 (process_target::supports_agent): Rename as ...
2382 (process_stratum_target::supports_agent): ... this.
2383 (process_target::enable_btrace): Rename as ...
2384 (process_stratum_target::enable_btrace): ... this.
2385 (process_target::disable_btrace): Rename as ...
2386 (process_stratum_target::disable_btrace): ... this.
2387 (process_target::read_btrace): Rename as ...
2388 (process_stratum_target::read_btrace): ... this.
2389 (process_target::read_btrace_conf): Rename as ...
2390 (process_stratum_target::read_btrace_conf): ... this.
2391 (process_target::supports_range_stepping): Rename as ...
2392 (process_stratum_target::supports_range_stepping): ... this.
2393 (process_target::supports_pid_to_exec_file): Rename as ...
2394 (process_stratum_target::supports_pid_to_exec_file): ... this.
2395 (process_target::pid_to_exec_file): Rename as ...
2396 (process_stratum_target::pid_to_exec_file): ... this.
2397 (process_target::supports_multifs): Rename as ...
2398 (process_stratum_target::supports_multifs): ... this.
2399 (process_target::multifs_open): Rename as ...
2400 (process_stratum_target::multifs_open): ... this.
2401 (process_target::multifs_unlink): Rename as ...
2402 (process_stratum_target::multifs_unlink): ... this.
2403 (process_target::multifs_readlink): Rename as ...
2404 (process_stratum_target::multifs_readlink): ... this.
2405 (process_target::breakpoint_kind_from_pc): Rename as ...
2406 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2407 (process_target::breakpoint_kind_from_current_state): Rename as ...
2408 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2409 (process_target::thread_name): Rename as ...
2410 (process_stratum_target::thread_name): ... this.
2411 (process_target::thread_handle): Rename as ...
2412 (process_stratum_target::thread_handle): ... this.
2413 (process_target::supports_software_single_step): Rename as ...
2414 (process_stratum_target::supports_software_single_step): ... this.
2415 (process_target::supports_catch_syscall): Rename as ...
2416 (process_stratum_target::supports_catch_syscall): ... this.
2417 (process_target::get_ipa_tdesc_idx): Rename as ...
2418 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2420 2020-02-20 Pedro Alves <palves@redhat.com>
2422 * target.cc (set_target_ops): Simply copy the given target pointer
2423 instead of creating a copy of the pointed object.
2425 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2427 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2430 * target.h (struct process_stratum_target): Remove the target op.
2431 (class process_target): Add the target op.
2432 (target_get_ipa_tdesc_idx): Update the macro.
2433 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2435 Update the derived classes and callers below.
2437 * linux-low.cc (linux_target_ops): Update.
2438 (linux_get_ipa_tdesc_idx): Turn into ...
2439 (linux_process_target::get_ipa_tdesc_idx): ... this.
2440 * linux-low.h (class linux_process_target): Update.
2441 * lynx-low.cc (lynx_target_ops): Update.
2442 * nto-low.cc (nto_target_ops): Update.
2443 * win32-low.cc (win32_target_ops): Update.
2445 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2447 Turn process_stratum_target's supports_catch_syscall op into a
2448 method of process_target.
2450 * target.h (struct process_stratum_target): Remove the target op.
2451 (class process_target): Add the target op.
2452 (target_supports_catch_syscall): Update the macro.
2453 * target.cc (process_target::supports_catch_syscall): Define.
2455 Update the derived classes and callers below.
2457 * linux-low.cc (linux_target_ops): Update.
2458 (linux_supports_catch_syscall): Turn into ...
2459 (linux_process_target::supports_catch_syscall): ... this.
2460 * linux-low.h (class linux_process_target): Update.
2461 * lynx-low.cc (lynx_target_ops): Update.
2462 * nto-low.cc (nto_target_ops): Update.
2463 * win32-low.cc (win32_target_ops): Update.
2465 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2467 Turn process_stratum_target's supports_software_single_step op
2468 into a method of process_target.
2470 * target.h (struct process_stratum_target): Remove the target op.
2471 (class process_target): Add the target op.
2472 (target_supports_software_single_step): Update the macro.
2473 * target.cc (process_target::supports_software_single_step): Define.
2475 Update the derived classes and callers below.
2477 * linux-low.cc (linux_target_ops): Update.
2478 (linux_supports_software_single_step): Turn into ...
2479 (linux_process_target::supports_software_single_step): ... this.
2480 * linux-low.h (class linux_process_target): Update.
2481 * lynx-low.cc (lynx_target_ops): Update.
2482 * nto-low.cc (nto_target_ops): Update.
2483 * win32-low.cc (win32_target_ops): Update.
2485 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2487 Turn process_stratum_target's thread_name and thread_handle ops
2488 into methods of process_target.
2490 * target.h (struct process_stratum_target): Remove the target ops.
2491 (class process_target): Add the target ops.
2492 (target_thread_name): Update the macro.
2493 (target_thread_handle): Update the macro.
2494 * target.cc (process_target::thread_name): Define.
2495 (process_target::thread_handle): Define.
2497 Update the derived classes and callers below.
2499 * linux-low.cc (linux_target_ops): Update.
2500 (linux_process_target::thread_name): Define.
2501 (linux_process_target::thread_handle): Define.
2502 * linux-low.h (class linux_process_target): Update.
2503 * lynx-low.cc (lynx_target_ops): Update.
2504 * nto-low.cc (nto_target_ops): Update.
2505 * win32-low.cc (win32_target_ops): Update.
2507 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2509 Turn process_stratum_target's breakpoint_kind_from_pc,
2510 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2511 ops into methods of process_target.
2513 * target.h (struct process_stratum_target): Remove the target op.
2514 (class process_target): Add the target op.
2515 (target_breakpoint_kind_from_pc): Update the macro.
2516 (target_breakpoint_kind_from_current_state): Update the macro.
2517 (default_breakpoint_kind_from_pc): Remove declaration.
2518 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2519 (process_target::breakpoint_kind_from_pc): ... this.
2520 (process_target::breakpoint_kind_from_current_state): Define.
2522 Update the derived classes and callers below.
2524 * mem-break.cc (bp_size): Update.
2525 (bp_opcode): Update.
2526 * linux-low.cc (linux_target_ops): Update.
2527 (linux_wait_1): Update.
2528 (linux_breakpoint_kind_from_pc): Turn into ...
2529 (linux_process_target::breakpoint_kind_from_pc): ... this.
2530 (linux_sw_breakpoint_from_kind): Turn into ...
2531 (linux_process_target::sw_breakpoint_from_kind): ... this.
2532 (linux_breakpoint_kind_from_current_state): Turn into ...
2533 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2534 * linux-low.h (class linux_process_target): Update.
2535 * lynx-low.cc (lynx_target_ops): Update.
2536 (lynx_process_target::sw_breakpoint_from_kind): Define.
2537 * lynx-low.h (class lynx_process_target): Update.
2538 * nto-low.cc (nto_target_ops): Update.
2539 (nto_sw_breakpoint_from_kind): Turn into ...
2540 (nto_process_target::sw_breakpoint_from_kind): ... this.
2541 * nto-low.h (class nto_process_target): Update.
2542 * win32-low.cc (win32_target_ops): Update.
2543 (win32_sw_breakpoint_from_kind): Turn into ...
2544 (win32_process_target::sw_breakpoint_from_kind): ... this.
2545 * win32-low.h (class win32_process_target): Update.
2547 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2549 Turn process_stratum_target's multifs_open, multifs_readlink,
2550 multifs_unlink ops into methods of process_target.
2552 * target.h (struct process_stratum_target): Remove the target ops.
2553 (class process_target): Add the target ops. Also add
2555 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2557 (process_target::supports_multifs): Define.
2558 (process_target::multifs_open): Define.
2559 (process_target::multifs_readlink): Define.
2560 (process_target::multifs_unlink): Define.
2562 Update the derived classes and callers below.
2564 * hostio.cc (handle_setfs): Update.
2565 (handle_open): Update.
2566 (handle_unlink): Update.
2567 (handle_readlink): Update.
2568 * linux-low.cc (linux_target_ops): Update.
2569 (linux_process_target::supports_multifs): Define.
2570 (linux_process_target::multifs_open): Define.
2571 (linux_process_target::multifs_readlink): Define.
2572 (linux_process_target::multifs_unlink): Define.
2573 * linux-low.h (class linux_process_target): Update.
2574 * lynx-low.cc (lynx_target_ops): Update.
2575 * nto-low.cc (nto_target_ops): Update.
2576 * win32-low.cc (win32_target_ops): Update.
2578 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2580 Turn process_stratum_target's pid_to_exec_file op into a method
2583 * target.h (struct process_stratum_target): Remove the target op.
2584 (class process_target): Add the target op. Also add
2585 'supports_pid_to_exec_file'.
2586 * target.cc (process_target::pid_to_exec_file): Define.
2587 (process_target::supports_pid_to_exec_file): Define.
2589 Update the derived classes and callers below.
2591 * server.cc (handle_qxfer_exec_file): Update.
2592 (handle_query): Update.
2593 * linux-low.cc (linux_target_ops): Update.
2594 (linux_process_target::supports_pid_to_exec_file): Define.
2595 (linux_process_target::pid_to_exec_file): Define.
2596 * linux-low.h (class linux_process_target): Update.
2597 * lynx-low.cc (lynx_target_ops): Update.
2598 * nto-low.cc (nto_target_ops): Update.
2599 * win32-low.cc (win32_target_ops): Update.
2601 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2603 Turn process_stratum_target's supports_range_stepping op into a
2604 method of process_target.
2606 * target.h (struct process_stratum_target): Remove the target op.
2607 (class process_target): Add the target op.
2608 (target_supports_range_stepping): Update the macro.
2609 * target.cc (process_target::supports_range_stepping): Define.
2611 Update the derived classes and callers below.
2613 * linux-low.cc (linux_target_ops): Update.
2614 (linux_supports_range_stepping): Turn into ...
2615 (linux_process_target::supports_range_stepping): ... this.
2616 * linux-low.h (class linux_process_target): Update.
2617 * lynx-low.cc (lynx_target_ops): Update.
2618 * nto-low.cc (nto_target_ops): Update.
2619 * win32-low.cc (win32_target_ops): Update.
2621 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2623 Turn process_stratum_target's btrace-related ops (enable_btrace,
2624 disable_btrace, read_btrace, read_btrace_conf) into methods of
2627 * target.h (struct process_stratum_target): Remove the target ops.
2628 (class process_target): Add the target ops.
2629 (target_enable_btrace): Update.
2630 (target_disable_btrace): Update.
2631 (target_read_btrace): Update.
2632 (target_read_btrace_conf): Update.
2633 * target.cc (process_target::enable_btrace): Define.
2634 (process_target::disable_btrace): Define.
2635 (process_target::read_btrace): Define.
2636 (process_target::read_btrace_conf): Define.
2638 Update the derived classes and callers below.
2640 * linux-low.cc (linux_target_ops): Update.
2641 (linux_process_target:enable_btrace): Define as a wrapper around
2642 linux_enable_btrace.
2643 (linux_low_disable_btrace): Turn into ...
2644 (linux_process_target::disable_btrace): ... this.
2645 (linux_low_read_btrace): Turn into ...
2646 (linux_process_target::read_btrace): ... this.
2647 (linux_low_btrace_conf): Turn into ...
2648 (linux_process_target::read_btrace_conf): ... this.
2649 * linux-low.h (class linux_process_target): Update.
2650 * lynx-low.cc (lynx_target_ops): Update.
2651 * nto-low.cc (nto_target_ops): Update.
2652 * win32-low.cc (win32_target_ops): Update.
2654 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2656 Turn process_stratum_target's supports_agent op into a method of
2659 * target.h (struct process_stratum_target): Remove the target op.
2660 (class process_target): Add the target op.
2661 (target_supports_agent): Update the macro.
2662 * target.cc (process_target::supports_agent): Define.
2664 Update the derived classes and callers below.
2666 * linux-low.cc (linux_target_ops): Update.
2667 (linux_supports_agent): Turn into ...
2668 (linux_process_target::supports_agent): ... this.
2669 * linux-low.h (class linux_process_target): Update.
2670 * lynx-low.cc (lynx_target_ops): Update.
2671 * nto-low.cc (nto_target_ops): Update.
2672 * win32-low.cc (win32_target_ops): Update.
2674 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2676 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2677 method of process_target.
2679 * target.h (struct process_stratum_target): Remove the target op.
2680 (class process_target): Add the target op. Also add
2681 'supports_qxfer_libraries_svr4'.
2682 * target.cc (process_target::qxfer_libraries_svr4): Define.
2683 (process_target::supports_qxfer_libraries_svr4): Define.
2685 Update the derived classes and callers below.
2687 * server.cc (handle_qxfer_libraries_svr4): Update.
2688 (handle_query): Update.
2689 * linux-low.cc (linux_target_ops): Update.
2690 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2691 (linux_qxfer_libraries_svr4): Turn into ...
2692 (linux_process_target::qxfer_libraries_svr4): ... this.
2693 * linux-low.h (class linux_process_target): Update.
2694 * lynx-low.cc (lynx_target_ops): Update.
2695 * nto-low.cc (nto_target_ops): Update.
2696 * win32-low.cc (win32_target_ops): Update.
2698 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2700 Turn process_stratum_target's supports_disable_randomization op
2701 into a method of process_target.
2703 * target.h (struct process_stratum_target): Remove the target op.
2704 (class process_target): Add the target op.
2705 (target_supports_disable_randomization): Update the macro.
2706 * target.cc (process_target::supports_disable_randomization): Define.
2708 Update the derived classes and callers below.
2710 * linux-low.cc (linux_target_ops): Update.
2711 (linux_supports_disable_randomization): Turn into ...
2712 (linux_process_target::supports_disable_randomization): ... this.
2713 * linux-low.h (class linux_process_target): Update.
2714 * lynx-low.cc (lynx_target_ops): Update.
2715 * nto-low.cc (nto_target_ops): Update.
2716 * win32-low.cc (win32_target_ops): Update.
2718 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2720 Turn process_stratum_target's emit_ops op into a method of
2723 * target.h (struct process_stratum_target): Remove the target op.
2724 (class process_target): Add the target op.
2725 (target_emit_ops): Update the macro.
2726 * target.cc (process_target::emit_ops): Define.
2728 Update the derived classes and callers below.
2730 * linux-low.cc (linux_target_ops): Update.
2731 (linux_emit_ops): Turn into ...
2732 (linux_process_target::emit_ops): ... this.
2733 * linux-low.h (class linux_process_target): Update.
2734 * lynx-low.cc (lynx_target_ops): Update.
2735 * nto-low.cc (nto_target_ops): Update.
2736 * win32-low.cc (win32_target_ops): Update.
2738 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2740 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2741 and get_min_fast_tracepoint_insn_len ops into methods of
2744 * target.h (struct process_stratum_target): Remove the target ops.
2745 (class process_target): Add the target ops. Also add
2746 'supports_fast_tracepoints'.
2747 (target_supports_fast_tracepoints): Update the macro.
2748 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2749 (install_fast_tracepoint_jump_pad): Update and rename the macro
2751 (target_install_fast_tracepoint_jump_pad): ... this.
2752 * target.cc (process_target::supports_fast_tracepoints): Define.
2753 (process_target::install_fast_tracepoint_jump_pad): Define.
2754 (process_target::get_min_fast_tracepoint_insn_len): Define.
2756 Update the derived classes and callers below.
2758 * tracepoint.cc (install_fast_tracepoint): Update.
2759 * linux-low.cc (linux_target_ops): Update.
2760 (linux_process_target::supports_fast_tracepoints): Define.
2761 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2762 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2763 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2764 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2765 * linux-low.h (class linux_process_target): Update.
2766 * lynx-low.cc (lynx_target_ops): Update.
2767 * nto-low.cc (nto_target_ops): Update.
2768 * win32-low.cc (win32_target_ops): Update.
2770 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2772 Turn process_stratum_target's stabilize_threads op into a
2773 method of process_target.
2775 * target.h (struct process_stratum_target): Remove the target op.
2776 (class process_target): Add the target op.
2777 (target_stabilize_threads): Update the macro.
2778 * target.cc (process_target::stabilize_threads): Define.
2780 Update the derived classes and callers below.
2782 * server.cc (handle_status): Update.
2783 * tracepoint.cc (cmd_qtdp): Update.
2784 (cmd_qtstart): Update.
2785 * linux-low.cc (linux_target_ops): Update.
2786 (linux_stabilize_threads): Turn into ...
2787 (linux_process_target::stabilize_threads): ... this.
2788 (linux_wait_1): Update.
2789 * linux-low.h (class linux_process_target): Update.
2790 * lynx-low.cc (lynx_target_ops): Update.
2791 * nto-low.cc (nto_target_ops): Update.
2792 * win32-low.cc (win32_target_ops): Update.
2794 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2796 Turn process_stratum_target's pause_all and unpause_all ops
2797 into methods of process_target.
2799 * target.h (struct process_stratum_target): Remove the target ops.
2800 (class process_target): Add the target ops.
2801 (pause_all): Update the macro and rename to...
2802 (target_pause_all): ... this.
2803 (unpause_all): Update the macro and rename to...
2804 (target_unpause_all): ... this.
2805 * target.cc (process_target::pause_all): Define.
2806 (process_target::unpause_all): Define.
2808 Update the derived classes and callers below.
2810 * server.cc (handle_status): Update.
2811 * tracepoint.cc (clear_installed_tracepoints): Update.
2813 (cmd_qtstart): Update.
2814 (stop_tracing): Update.
2815 (cmd_qtstatus): Update.
2816 (upload_fast_traceframes): Update.
2817 (run_inferior_command): Update.
2818 * linux-low.cc (linux_target_ops): Update.
2819 (linux_pause_all): Turn into ...
2820 (linux_process_target::pause_all): ... this.
2821 (linux_unpause_all): Turn into ...
2822 (linux_process_target::unpause_all): ... this.
2823 (linux_process_target::prepare_to_access_memory): Update.
2824 (linux_process_target::done_accessing_memory): Update.
2825 * linux-low.h (class linux_process_target): Update.
2826 * lynx-low.cc (lynx_target_ops): Update.
2827 * nto-low.cc (nto_target_ops): Update.
2828 * win32-low.cc (win32_target_ops): Update.
2830 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2832 Turn process_stratum_target's get_tib_address op into a method of
2835 * target.h (struct process_stratum_target): Remove the target op.
2836 (class process_target): Add the target op. Also add
2837 'supports_get_tib_address'.
2838 * target.cc (process_target::get_tib_address): Define.
2839 (process_target::supports_get_tib_address): Define.
2841 Update the derived classes and callers below.
2843 * server.cc (handle_query): Update.
2844 * linux-low.cc (win32_target_ops): Update.
2845 * lynx-low.cc (lynx_target_ops): Update.
2846 * nto-low.cc (nto_target_ops): Update.
2847 * win32-low.cc (win32_target_ops): Update.
2848 (win32_process_target::supports_get_tib_address): Define.
2849 (win32_get_tib_address): Turn into ...
2850 (win32_process_target::get_tib_address): ... this.
2851 * win32-low.h (class win32_process_target): Update.
2853 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2855 Turn process_stratum_target's thread_stopped op into a method of
2858 * target.h (struct process_stratum_target): Remove the target op.
2859 (class process_target): Add the target op. Also add
2860 'supports_thread_stopped'.
2861 (target_thread_stopped): Update the macro.
2862 * target.cc (process_target::thread_stopped): Define.
2863 (process_target::supports_thread_stopped): Define.
2864 (prepare_to_access_memory): Update.
2866 Update the derived classes and callers below.
2868 * server.cc (queue_stop_reply_callback): Update.
2869 * linux-low.cc (linux_target_ops): Update.
2870 (linux_process_target::supports_thread_stopped): Define.
2871 (linux_thread_stopped): Turn into ...
2872 (linux_process_target::thread_stopped): ... this.
2873 * linux-low.h (class linux_process_target): Update.
2874 * lynx-low.cc (lynx_target_ops): Update.
2875 * nto-low.cc (nto_target_ops): Update.
2876 * win32-low.cc (win32_target_ops): Update.
2878 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2880 Turn process_stratum_target's read_pc and write_pc ops into
2881 methods of process_target.
2883 * target.h (struct process_stratum_target): Remove the target ops.
2884 (class process_target): Add the target ops.
2885 * target.cc (process_target::read_pc): Define.
2886 (process_target::write_pc): Define.
2888 Update the derived classes and callers below.
2890 * regcache.cc (regcache_read_pc): Update.
2891 (regcache_write_pc): Update.
2892 * linux-low.cc (linux_target_ops): Update.
2893 (linux_read_pc): Turn into ...
2894 (linux_process_target::read_pc): ... this.
2895 (linux_write_pc): Turn into ...
2896 (linux_process_target::write_pc): ... this.
2897 * linux-low.h (class linux_process_target): Update.
2898 * lynx-low.cc (lynx_target_ops): Update.
2899 * nto-low.cc (nto_target_ops): Update.
2900 * win32-low.cc (win32_target_ops): Update.
2902 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2904 Turn process_stratum_target's supports_tracepoints op into a
2905 method of process_target.
2907 * target.h (struct process_stratum_target): Remove the target op.
2908 (class process_target): Add the target op.
2909 (target_supports_tracepoints): Update the macro.
2910 * target.cc (process_target::supports_tracepoints): Define.
2912 Update the derived classes and callers below.
2914 * linux-low.cc (linux_target_ops): Update.
2915 (linux_supports_tracepoints): Turn into ...
2916 (linux_process_target::supports_tracepoints): ... this.
2917 * linux-low.h (class linux_process_target): Update.
2918 * lynx-low.cc (lynx_target_ops): Update.
2919 * nto-low.cc (nto_target_ops): Update.
2920 * win32-low.cc (win32_target_ops): Update.
2922 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2924 Turn process_stratum_target's process_qsupported op into a method
2927 * target.h (struct process_stratum_target): Remove the target op.
2928 (class process_target): Add the target op.
2929 (target_process_qsupported): Update the macro.
2930 * target.cc (process_target::process_qsupported): Define.
2932 Update the derived classes and callers below.
2934 * linux-low.cc (linux_target_ops): Update.
2935 (linux_process_qsupported): Turn into ...
2936 (linux_process_target::process_qsupported): ... this.
2937 * linux-low.h (class linux_process_target): Update.
2938 * lynx-low.cc (lynx_target_ops): Update.
2939 * nto-low.cc (nto_target_ops): Update.
2940 * win32-low.cc (win32_target_ops): Update.
2942 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2944 Turn process_stratum_target's read_loadmap op into a method of
2947 * target.h (struct process_stratum_target): Remove the target op.
2948 (class process_target): Add the target op. Also add
2949 'supports_read_loadmap'.
2950 * target.cc (process_target::read_loadmap): Define.
2951 (process_target::supports_read_loadmap): Define.
2953 Update the derived classes and callers below.
2955 * server.cc (handle_qxfer_fdpic): Update.
2956 (handle_query): Update.
2957 * linux-low.cc (linux_target_ops): Update.
2958 (linux_process_target::supports_read_loadmap): Define.
2959 (linux_read_loadmap): Turn into ...
2960 (linux_process_target::read_loadmap): ... this.
2961 * linux-low.h (class linux_process_target): Update.
2962 * lynx-low.cc (lynx_target_ops): Update.
2963 * nto-low.cc (nto_target_ops): Update.
2964 * win32-low.cc (win32_target_ops): Update.
2966 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2968 Turn process_stratum_target's core_of_thread op into a method of
2971 * target.h (struct process_stratum_target): Remove the target op.
2972 (class process_target): Add the target op.
2973 (target_core_of_thread): Update the macro.
2974 * target.cc (process_target::core_of_thread): Define.
2976 Update the derived classes and callers below.
2978 * linux-low.cc (linux_target_ops): Update.
2979 (linux_process_target::core_of_thread): Define.
2980 * linux-low.h (class linux_process_target): Update.
2981 * lynx-low.cc (lynx_target_ops): Update.
2982 * nto-low.cc (nto_target_ops): Update.
2983 * win32-low.cc (win32_target_ops): Update.
2985 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2987 Turn process_stratum_target's handle_monitor_command op into a
2988 method of process_target.
2990 * target.h (struct process_stratum_target): Remove the target op.
2991 (class process_target): Add the target op.
2992 (target_handle_monitor_command): Update the macro.
2993 * target.cc (process_target::handle_monitor_command): Define.
2995 Update the derived classes and callers below.
2997 * server.cc (handle_query): Update.
2998 * linux-low.cc (linux_target_ops): Update.
2999 (linux_process_target::handle_monitor_command): Define.
3000 * linux-low.h (class linux_process_target): Update.
3001 * lynx-low.cc (lynx_target_ops): Update.
3002 * nto-low.cc (nto_target_ops): Update.
3003 * win32-low.cc (win32_target_ops): Update.
3005 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3007 Turn process_stratum_target's handle_new_gdb_connection op into a
3008 method of process_target.
3010 * target.h (struct process_stratum_target): Remove the target op.
3011 (class process_target): Add the target op.
3012 (target_handle_new_gdb_connection): Update the macro.
3013 * target.cc (process_target::handle_new_gdb_connection): Define.
3015 Update the derived classes and callers below.
3017 * linux-low.cc (linux_target_ops): Update.
3018 (linux_handle_new_gdb_connection): Turn into ...
3019 (linux_process_target::handle_new_gdb_connection): ... this.
3020 * linux-low.h (class linux_process_target): Update.
3021 * lynx-low.cc (lynx_target_ops): Update.
3022 * nto-low.cc (nto_target_ops): Update.
3023 * win32-low.cc (win32_target_ops): Update.
3025 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3027 Turn process_stratum_target's supports_fork_events,
3028 supports_vfork_events, and supports_exec_events ops into methods
3031 * target.h (struct process_stratum_target): Remove the target ops.
3032 (class process_target): Add the target ops.
3033 (target_supports_fork_events): Update the macro.
3034 (target_supports_vfork_events): Update the macro.
3035 (target_supports_exec_events): Update the macro.
3036 * target.cc (process_target::supports_fork_events): Define.
3037 (process_target::supports_vfork_events): Define.
3038 (process_target::supports_exec_events): Define.
3040 Update the derived classes and callers below.
3042 * linux-low.cc (linux_target_ops): Update.
3043 (linux_supports_fork_events): Turn into ...
3044 (linux_process_target::supports_fork_events): ... this.
3045 (linux_supports_vfork_events): Turn into ...
3046 (linux_process_target::supports_vfork_events): ... this.
3047 (linux_supports_exec_events): Turn into ...
3048 (linux_process_target::supports_exec_events): ... this.
3049 * linux-low.h (class linux_process_target): Update.
3050 * lynx-low.cc (lynx_target_ops): Update.
3051 * nto-low.cc (nto_target_ops): Update.
3052 * win32-low.cc (win32_target_ops): Update.
3054 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3056 Turn process_stratum_target's supports_multi_process op into a
3057 method of process_target.
3059 * target.h (struct process_stratum_target): Remove the target op.
3060 (class process_target): Add the target op.
3061 * target.cc (process_target::supports_multi_process): Define.
3062 (target_supports_multi_process): Update.
3064 Update the derived classes and callers below.
3066 * linux-low.cc (linux_target_ops): Update.
3067 (linux_supports_multi_process): Turn into ...
3068 (linux_process_target::supports_multi_process): ... this.
3069 * linux-low.h (class linux_process_target): Update.
3070 * lynx-low.cc (lynx_target_ops): Update.
3071 * nto-low.cc (nto_target_ops): Update.
3072 * win32-low.cc (win32_target_ops): Update.
3074 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3076 Turn process_stratum_target's supports_non_stop, async, and
3077 start_non_stop ops into methods of process_target.
3079 * target.h (struct process_stratum_target): Remove the target ops.
3080 (class process_target): Add the target ops.
3081 (target_supports_non_stop): Update the macro.
3082 (target_async): Update the macro.
3083 (start_non_stop): Remove declaration.
3084 * target.cc (process_target::supports_non_stop): Define.
3085 (process_target::async): Define.
3086 (process_target::start_non_stop): Define.
3087 (start_non_stop): Remove.
3089 Update the derived classes and callers below.
3091 * server.cc (handle_qxfer_siginfo): Update.
3092 (handle_query): Update.
3093 * linux-low.cc (linux_target_ops): Update.
3094 (linux_supports_non_stop): Turn into ...
3095 (linux_process_target::supports_non_stop): ... this.
3096 (linux_async): Turn into ...
3097 (linux_process_target::async): ... this.
3098 (linux_start_non_stop): Turn into ...
3099 (linux_process_target::start_non_stop): ... this.
3100 * linux-low.h (class linux_process_target): Update.
3101 * lynx-low.cc (lynx_target_ops): Update.
3102 * nto-low.cc (nto_target_ops): Update.
3103 (nto_supports_non_stop): Remove; rely on the default behavior
3105 * win32-low.cc (win32_target_ops): Update.
3107 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3109 Turn process_stratum_target's qxfer_siginfo op into a method of
3112 * target.h (struct process_stratum_target): Remove the target op.
3113 (class process_target): Add the target op. Also add
3114 'supports_qxfer_siginfo'.
3115 * target.cc (process_target::qxfer_siginfo): Define.
3116 (process_target::supports_qxfer_siginfo): Define.
3118 Update the derived classes and callers below.
3120 * server.cc (handle_qxfer_siginfo): Update.
3121 (handle_query): Update.
3122 * linux-low.cc (linux_target_ops): Update.
3123 (linux_process_target::supports_qxfer_siginfo): Define.
3124 (linux_xfer_siginfo): Turn into ...
3125 (linux_process_target::qxfer_siginfo): ... this.
3126 * linux-low.h (class linux_process_target): Update.
3127 * lynx-low.cc (lynx_target_ops): Update.
3128 * nto-low.cc (nto_target_ops): Update.
3129 * win32-low.cc (win32_target_ops): Update.
3131 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3133 Turn process_stratum_target's qxfer_osdata op into a method of
3136 * target.h (struct process_stratum_target): Remove the target op.
3137 (class process_target): Add the target op. Also add
3138 'supports_qxfer_osdata'.
3139 * target.cc (process_target::qxfer_osdata): Define.
3140 (process_target::supports_qxfer_osdata): Define.
3142 Update the derived classes and callers below.
3144 * server.cc (handle_qxfer_osdata): Update.
3145 (handle_query): Update.
3146 * linux-low.cc (linux_target_ops): Update.
3147 (linux_process_target::supports_qxfer_osdata): Define.
3148 (linux_qxfer_osdata): Turn into ...
3149 (linux_process_target::qxfer_osdata): ... this.
3150 * linux-low.h (class linux_process_target): Update.
3151 * lynx-low.cc (lynx_target_ops): Update.
3152 * nto-low.cc (nto_target_ops): Update.
3153 * win32-low.cc (win32_target_ops): Update.
3155 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3157 Turn process_stratum_target's hostio_last_error op into a
3158 method of process_target.
3160 * target.h (struct process_stratum_target): Remove the target op.
3161 (class process_target): Add the target op.
3162 * target.cc: Add "hostio.h" to includes.
3163 (process_target::hostio_last_error): Define.
3165 Update the derived classes and callers below.
3167 * hostio.cc (hostio_error): Update.
3168 * linux-low.cc: Remove "hostio.h" from includes.
3169 (linux_target_ops): Update.
3170 * lynx-low.cc (lynx_target_ops): Update.
3171 * nto-low.cc (nto_target_ops): Update.
3172 * win32-low.h (class win32_process_target): Update.
3173 * win32-low.cc (win32_target_ops): Update.
3174 (wince_hostio_last_error): Turn into ...
3175 (win32_process_target::hostio_last_error): ... this.
3177 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3179 Turn process_stratum_target's get_tls_address op into a method of
3182 * target.h (struct process_stratum_target): Remove the target op.
3183 (class process_target): Add the target op. Also add
3184 'supports_get_tls_address'.
3185 * target.cc (process_target::get_tls_address): Define.
3186 (process_target::supports_get_tls_address): Define.
3188 Update the derived classes and callers below.
3190 * server.cc (handle_query): Update.
3191 * linux-low.cc (linux_target_ops): Update.
3192 (linux_process_target::supports_get_tls_address): Define.
3193 (linux_process_target::get_tls_address): Define.
3194 * linux-low.h (class linux_process_target): Update.
3195 * lynx-low.cc (lynx_target_ops): Update.
3196 * nto-low.cc (nto_target_ops): Update.
3197 * win32-low.cc (win32_target_ops): Update.
3199 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3201 Turn process_stratum_target's read_offsets op into a method of
3204 * target.h (struct process_stratum_target): Remove the target op.
3205 (class process_target): Add the target op. Also add
3206 'supports_read_offsets'.
3207 * target.cc (process_target::read_offsets): Define.
3208 (process_target::supports_read_offsets): Define.
3210 Update the derived classes and callers below.
3212 * server.cc (handle_query): Update.
3213 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3214 (linux_target_ops): Update.
3215 (linux_process_target::supports_read_offsets): Define.
3216 (linux_read_offsets): Turn into ...
3217 (linux_process_target::read_offsets): ... this.
3218 * linux-low.h (class linux_process_target): Update.
3219 * lynx-low.cc (lynx_target_ops): Update.
3220 * nto-low.cc (nto_target_ops): Update.
3221 * win32-low.cc (win32_target_ops): Update.
3223 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3225 Turn process_stratum_target's stopped_by_watchpoint and
3226 stopped_data_address ops into methods of process_target.
3228 * target.h (struct process_stratum_target): Remove the target ops.
3229 (class process_target): Add the target ops.
3230 * target.cc (process_target::stopped_by_watchpoint): Define.
3231 (process_target::stopped_data_address): Define.
3233 Update the derived classes and callers below.
3235 * remote-utils.cc (prepare_resume_reply): Update.
3236 * linux-low.cc (linux_target_ops): Update.
3237 (linux_stopped_by_watchpoint): Turn into ...
3238 (linux_process_target::stopped_by_watchpoint): ... this.
3239 (linux_stopped_data_address): Turn into ...
3240 (linux_process_target::stopped_data_address): ... this.
3241 * linux-low.h (class linux_process_target): Update.
3242 * lynx-low.cc (lynx_target_ops): Update.
3243 * nto-low.cc (nto_target_ops): Update.
3244 (nto_stopped_by_watchpoint): Turn into ...
3245 (nto_process_target::stopped_by_watchpoint): ... this.
3246 (nto_stopped_data_address): Turn into ...
3247 (nto_process_target::stopped_data_address): ... this.
3248 * nto-low.h (class nto_process_target): Update.
3249 * win32-low.cc (win32_target_ops): Update.
3250 (win32_stopped_by_watchpoint): Turn into ...
3251 (win32_process_target::stopped_by_watchpoint): ... this.
3252 (win32_stopped_data_address): Turn into ...
3253 (win32_process_target::stopped_data_address): ... this.
3254 * win32-low.h (class win32_process_target): Update.
3256 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3258 Turn process_stratum_target's supports_hardware_single_step op into
3259 a method of process_target.
3261 * target.h (struct process_stratum_target): Remove the target op.
3262 (class process_target): Add the target op.
3263 (target_supports_hardware_single_step): Update the macro.
3264 (target_can_do_hardware_single_step): Remove declaration.
3265 * target.cc (process_target::supports_hardware_single_step): Define.
3266 (target_can_do_hardware_single_step): Remove.
3268 Update the derived classes and callers below.
3270 * linux-low.h (class linux_process_target): Update.
3271 * linux-low.cc (linux_target_ops): Update.
3272 (linux_supports_hardware_single_step): Turn into ...
3273 (linux_process_target::supports_hardware_single_step): ... this.
3274 * lynx-low.h (class lynx_process_target): Update.
3275 * lynx-low.cc (lynx_target_ops): Update.
3276 (lynx_process_target::supports_hardware_single_step): Define.
3277 * nto-low.h (class nto_process_target): Update.
3278 * nto-low.cc (nto_target_ops): Update.
3279 (nto_process_target::supports_hardware_single_step): Define.
3280 * win32-low.h (class win32_process_target): Update.
3281 * win32-low.cc (win32_target_ops): Update.
3282 (win32_process_target::supports_hardware_single_step): Define.
3284 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3286 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3287 ops into methods of process_target.
3289 * target.h (struct process_stratum_target): Remove the target ops.
3290 (class process_target): Add the target ops.
3291 (target_stopped_by_hw_breakpoint): Update the macro.
3292 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3293 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3294 (process_target::supports_stopped_by_hw_breakpoint): Define.
3296 Update the derived classes and callers below.
3298 * linux-low.cc (linux_target_ops): Update.
3299 (linux_stopped_by_hw_breakpoint): Turn into ...
3300 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3301 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3302 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3303 * linux-low.h (class linux_process_target): Update.
3304 * lynx-low.cc (lynx_target_ops): Update.
3305 * nto-low.cc (nto_target_ops): Update.
3306 * win32-low.cc (win32_target_ops): Update.
3308 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3310 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3311 ops into methods of process_target.
3313 * target.h (struct process_stratum_target): Remove the target ops.
3314 (class process_target): Add the target ops.
3315 (target_stopped_by_sw_breakpoint): Update the macro.
3316 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3317 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3318 (process_target::supports_stopped_by_sw_breakpoint): Define.
3320 Update the derived classes and callers below.
3322 * linux-low.cc (linux_target_ops): Update.
3323 (linux_stopped_by_sw_breakpoint): Turn into ...
3324 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3325 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3326 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3327 * linux-low.h (class linux_process_target): Update.
3328 * lynx-low.cc (lynx_target_ops): Update.
3329 * nto-low.cc (nto_target_ops): Update.
3330 * win32-low.cc (win32_target_ops): Update.
3332 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3334 Turn process_stratum_target's insert_point and remove_point ops
3335 into methods of process_target.
3337 * target.h (struct process_stratum_target): Remove the target ops.
3338 (class process_target): Add the target ops.
3339 * target.cc (process_target::insert_point): Define.
3340 (process_target::remove_point): Define.
3342 Update the derived classes and callers below.
3344 * mem-break.cc (set_raw_breakpoint_at): Update.
3345 (delete_raw_breakpoint): Update.
3346 (uninsert_raw_breakpoint): Update.
3347 (reinsert_raw_breakpoint): Update.
3348 * linux-low.cc (linux_target_ops): Update.
3349 (linux_insert_point): Turn into ...
3350 (linux_process_target::insert_point): ... this.
3351 (linux_remove_point): Turn into ...
3352 (linux_process_target::remove_point): ... this.
3353 * linux-low.h (class linux_process_target): Update.
3354 * lynx-low.cc (lynx_target_ops): Update.
3355 * nto-low.cc (nto_target_ops): Update.
3356 (nto_insert_point): Turn into ...
3357 (nto_process_target::insert_point): ... this.
3358 (nto_remove_point): Turn into ...
3359 (nto_process_target::remove_point): ... this.
3360 * nto-low.h (class nto_process_target): Update.
3361 * win32-low.cc (win32_target_ops): Update.
3362 (win32_insert_point): Turn into ...
3363 (win32_process_target::insert_point): ... this.
3364 (win32_remove_point): Turn into ...
3365 (win32_process_target::remove_point): ... this.
3366 * win32-low.h (class win32_process_target): Update.
3368 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3370 Turn process_stratum_target's supports_z_point_type op into a
3371 method of process_target.
3373 * target.h (struct process_stratum_target): Remove the target op.
3374 (class process_target): Add the target op.
3375 * target.cc (process_target::supports_z_point_type): Define.
3377 Update the derived classes and callers below.
3379 * mem-break.cc (z_type_supported): Update.
3380 * linux-low.cc (linux_target_ops): Update.
3381 (linux_supports_z_point_type): Turn into ...
3382 (linux_process_target::supports_z_point_type): ... this.
3383 * linux-low.h (class linux_process_target): Update.
3384 * lynx-low.cc (lynx_target_ops): Update.
3385 * nto-low.cc (nto_target_ops): Update.
3386 (nto_supports_z_point_type): Turn into ...
3387 (nto_process_target::supports_z_point_type): ... this.
3388 * nto-low.h (class nto_process_target): Update.
3389 * win32-low.cc (win32_target_ops): Update.
3390 (win32_supports_z_point_type): Turn into ...
3391 (win32_process_target::supports_z_point_type): ... this.
3392 * win32-low.h (class win32_process_target): Update.
3394 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3396 Turn process_stratum_target's read_auxv op into a method of
3399 * target.h (class process_stratum_target): Remove the target op.
3400 (struct process_target): Add the target op. Also add
3401 'supports_read_auxv'.
3402 * target.cc (process_target::read_auxv): Define.
3403 (process_target::supports_read_auxv): Define.
3405 Update the derived classes and callers below.
3407 * server.cc (handle_qxfer_auxv): Update.
3408 (handle_query): Update.
3409 * linux-low.cc (linux_target_ops): Update.
3410 (linux_process_target::supports_read_auxv): Define.
3411 (linux_read_auxv): Turn into ...
3412 (linux_process_target::read_auxv): ... this.
3413 * linux-low.h (class linux_process_target): Update.
3414 * lynx-low.cc (lynx_target_ops): Update.
3415 * nto-low.cc (nto_target_ops): Update.
3416 (nto_process_target::supports_read_auxv): Define.
3417 (nto_read_auxv): Turn into ...
3418 (nto_process_target::read_auxv): ... this.
3419 * nto-low.h (class nto_process_target): Update.
3420 * win32-low.cc (win32_target_ops): Update.
3422 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3424 Turn process_stratum_target's request_interrupt op into a method of
3427 * target.h (struct process_stratum_target): Remove the target op.
3428 (class process_target): Add the target op.
3430 Update the derived classes and callers below.
3432 * remote-utils.cc (putpkt_binary_1): Update.
3433 (input_interrupt): Update.
3435 * server.cc (handle_v_requests): Update.
3436 * linux-low.cc (linux_target_ops): Update.
3437 (linux_request_interrupt): Turn into ...
3438 (linux_process_target::request_interrupt): ... this.
3439 * linux-low.h (class linux_process_target): Update.
3440 * lynx-low.cc (lynx_target_ops): Update.
3441 (lynx_request_interrupt): Turn into ...
3442 (lynx_process_target::request_interrupt): ... this.
3443 * lynx-low.h (class lynx_process_target): Update.
3444 * nto-low.cc (nto_target_ops): Update.
3445 (nto_request_interrupt): Turn into ...
3446 (nto_process_target::request_interrupt): ... this.
3447 * nto-low.h (class nto_process_target): Update.
3448 * win32-low.cc (win32_target_ops): Update.
3449 (win32_request_interrupt): Turn into ...
3450 (win32_process_target::request_interrupt): ... this.
3451 * win32-low.h (class win32_process_target): Update.
3453 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3455 Turn process_stratum_target's look_up_symbols op into a method of
3458 * target.h (struct process_stratum_target): Remove the target op.
3459 (class process_target): Add the target op.
3460 * target.cc (process_target::look_up_symbols): Define.
3462 Update the derived classes and callers below.
3464 * server.cc (handle_query): Update.
3465 * linux-low.cc (linux_target_ops): Update.
3466 (linux_look_up_symbols): Turn into ...
3467 (linux_process_target::look_up_symbols): ... this.
3468 * linux-low.h (class linux_process_target): Update.
3469 * lynx-low.cc (lynx_target_ops): Update.
3470 * nto-low.cc (nto_target_ops): Update.
3471 * win32-low.cc (win32_target_ops): Update.
3473 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3475 Turn process_stratum_target's read_memory and write_memory
3476 ops into methods of process_target.
3478 * target.h (struct process_stratum_target): Remove the target ops.
3479 (class process_target): Add the target ops.
3481 Update the derived classes and callers below.
3483 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3484 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3485 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3486 (arm_get_syscall_trapinfo): Update.
3487 * linux-cris-low.cc (cris_breakpoint_at): Update.
3488 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3489 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3490 * linux-mips-low.cc (mips_breakpoint_at): Update.
3491 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3492 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3493 * linux-sh-low.cc (sh_breakpoint_at): Update.
3494 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3495 (sparc_store_gregset_from_stack): Update.
3496 (sparc_breakpoint_at): Update.
3497 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3498 * linux-tile-low.cc (tile_breakpoint_at): Update.
3499 * linux-x86-low.cc (x86_breakpoint_at): Update.
3500 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3501 * mem-brea.cc (insert_memory_breakpoint): Update.
3502 (validate_inserted_breakpoint): Update.
3503 * target.cc (read_inferior_memory): Update.
3504 (target_write_memory): Update.
3505 * linux-low.cc (linux_target_ops): Update.
3506 (linux_read_memory): Make a wrapper around the read_memory target
3508 (linux_process_target::read_memory): Rename from linux_read_memory.
3509 (linux_write_memory): Turn into ...
3510 (linux_process_target::write_memory): ... this.
3511 * linux-low.h (class linux_process_target): Update.
3512 * lynx-low.cc (lynx_target_ops): Update.
3513 (lynx_read_memory): Turn into ...
3514 (lynx_process_target::read_memory): ... this.
3515 (lynx_write_memory): Turn into ...
3516 (lynx_process_target::write_memory): ... this.
3517 * lynx-low.h (class lynx_process_target): Update.
3518 * nto-low.cc (nto_target_ops): Update.
3519 (nto_read_memory): Turn into ...
3520 (nto_process_target::read_memory): ... this.
3521 (nto_write_memory): Turn into ...
3522 (nto_process_target::write_memory): ... this.
3523 * nto-low.h (class nto_process_target): Update.
3524 * win32-low.cc (win32_target_ops): Update.
3525 (win32_read_inferior_memory): Turn into ...
3526 (win32_process_target::read_memory): ... this.
3527 (win32_write_inferior_memory): Turn into ...
3528 (win32_process_target::write_memory): ... this.
3529 * win32-low.h (class win32_process_target): Update.
3531 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3533 Turn process_stratum_target's prepare_to_access_memory and
3534 done_accessing_memory ops into methods of process_target.
3536 * target.h (struct process_stratum_target): Remove the target ops.
3537 (class process_target): Add the target ops.
3538 * target.cc (process_target::prepare_to_access_memory): Define.
3539 (process_target::done_accessing_memory): Define.
3540 (prepare_to_access_memory): Update.
3541 (done_accessing_memory): Update.
3543 Update the derived classes and callers below.
3545 * linux-low.cc (linux_target_ops): Update.
3546 (linux_prepare_to_access_memory): Turn into ...
3547 (linux_process_target::prepare_to_access_memory): ... this.
3548 (linux_done_accessing_memory): Turn into ...
3549 (linux_process_target::done_accessing_memory): ... this.
3550 * linux-low.h (class linux_process_target): Update.
3551 * lynx-low.cc (lynx_target_ops): Update.
3552 * nto-low.cc (nto_target_ops): Update.
3553 * win32-low.cc (win32_target_ops): Update.
3555 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3557 Turn process_stratum_target's fetch_registers and store_registers
3558 ops into methods of process_target.
3560 * target.h (struct process_stratum_target): Remove the target ops.
3561 (class process_target): Add the target ops.
3562 (fetch_inferior_registers): Update the macro.
3563 (store_inferior_registers): Update the macro.
3565 Update the derived classes and callers below.
3567 * linux-low.cc (linux_target_ops): Update.
3568 (linux_fetch_registers): Turn into ...
3569 (linux_process_target::fetch_registers): ... this.
3570 (linux_store_registers): Turn into ...
3571 (linux_process_target::store_registers): ... this.
3572 * linux-low.h (class linux_process_target): Update.
3573 * lynx-low.cc (lynx_target_ops): Update.
3574 (lynx_fetch_registers): Turn into ...
3575 (lynx_process_target::fetch_registers): ... this.
3576 (lynx_store_registers): Turn into ...
3577 (lynx_process_target::store_registers): ... this.
3578 * lynx-low.h (class lynx_process_target): Update.
3579 * nto-low.cc (nto_target_ops): Update.
3580 (nto_fetch_registers): Turn into ...
3581 (nto_process_target::fetch_registers): ... this.
3582 (nto_store_registers): Turn into ...
3583 (nto_process_target::store_registers): ... this.
3584 * nto-low.h (class nto_process_target): Update.
3585 * win32-low.cc (win32_target_ops): Update.
3586 (win32_fetch_inferior_registers): Turn into ...
3587 (win32_process_target::fetch_registers): ... this.
3588 (win32_store_inferior_registers): Turn into ...
3589 (win32_process_target::store_registers): ... this.
3590 * win32-low.h (class win32_process_target): Update.
3592 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3594 Turn process_stratum_target's wait op into a method of
3597 * target.h (struct process_stratum_target): Remove the target op.
3598 (class process_target): Add the target op.
3600 Update the derived classes and callers below.
3602 * target.cc (target_wait): Update.
3603 * linux-low.cc (linux_target_ops): Update.
3604 (linux_wait): Turn into ...
3605 (linux_process_target::wait): ... this.
3606 * linux-low.h (class linux_process_target): Update.
3607 * lynx-low.cc (lynx_target_ops): Update.
3608 (lynx_wait): Turn into ...
3609 (lynx_process_target::wait): ... this.
3610 * lynx-low.h (class lynx_process_target): Update.
3611 * nto-low.cc (nto_target_ops): Update.
3612 (nto_wait): Turn into ...
3613 (nto_process_target::wait): ... this.
3614 * nto-low.h (class nto_process_target): Update.
3615 * win32-low.cc (win32_target_ops): Update.
3616 (win32_wait): Turn into ...
3617 (win32_process_target::wait): ... this.
3618 (do_initial_child_stuff): Update.
3619 * win32-low.h (class win32_process_target): Update.
3621 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3623 Turn process_stratum_target's resume op into a method of
3626 * target.h (struct process_stratum_target): Remove the target op.
3627 (class process_target): Add the target op.
3629 Update the derived classes and callers below.
3631 * server.cc (resume): Update.
3632 * target.cc (target_stop_and_wait): Update.
3633 (target_continue_no_signal): Update.
3634 (target_continue): Update.
3635 * linux-low.cc (linux_target_ops): Update.
3636 (linux_resume): Turn into ...
3637 (linux_process_target::resume): ... this.
3638 * linux-low.h (class linux_process_target): Update.
3639 * lynx-low.cc (lynx_target_ops): Update.
3640 (lynx_resume): Turn into ...
3641 (lynx_process_target::resume): ... this.
3642 * lynx-low.h (class lynx_process_target): Update.
3643 * nto-low.cc (nto_target_ops): Update.
3644 (nto_resume): Turn into ...
3645 (nto_process_target::resume): ... this.
3646 * nto-low.h (class nto_process_target): Update.
3647 * win32-low.cc (win32_target_ops): Update.
3648 (win32_resume): Turn into ...
3649 (win32_process_target::resume): ... this.
3650 (win32_process_target::detach): Update.
3651 (do_initial_child_stuff): Update.
3652 * win32-low.h (class win32_process_target): Update.
3654 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3656 Turn process_stratum_target's thread_alive op into a method of
3659 * target.h (struct process_stratum_target): Remove the target op.
3660 (class process_target): Add the target op.
3661 (mythread_alive): Update the macro.
3663 Update the derived classes and callers below.
3665 * linux-low.cc (linux_target_ops): Update.
3666 (linux_thread_alive): Turn into ...
3667 (linux_process_target::thread_alive): ... this.
3668 (wait_for_sigstop): Update.
3669 * linux-low.h (class linux_process_target): Update.
3670 * lynx-low.cc (lynx_target_ops): Update.
3671 (lynx_thread_alive): Turn into ...
3672 (lynx_process_target::thread_alive): ... this.
3673 * lynx-low.h (class lynx_process_target): Update.
3674 * nto-low.cc (nto_target_ops): Update.
3675 (nto_thread_alive): Turn into ...
3676 (nto_process_target::thread_alive): ... this.
3677 * nto-low.h (class nto_process_target): Update.
3678 * win32-low.cc (win32_target_ops): Update.
3679 (win32_thread_alive): Turn into ...
3680 (win32_process_target::thread_alive): ... this.
3681 * win32-low.h (class win32_process_target): Update.
3683 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3685 Turn process_stratum_target's join op into a method of
3688 * target.h (struct process_stratum_target): Remove the target op.
3689 (class process_target): Add the target op.
3690 (join_inferior): Update the macro.
3692 Update the derived classes and callers below.
3694 * linux-low.cc (linux_target_ops): Update.
3695 (linux_join): Turn into ...
3696 (linux_process_target::join): ... this.
3697 * linux-low.h (class linux_process_target): Update.
3698 * lynx-low.cc (lynx_target_ops): Update.
3699 (lynx_join): Turn into ...
3700 (lynx_process_target::join): ... this.
3701 * lynx-low.h (class lynx_process_target): Update.
3702 * nto-low.cc (nto_target_ops): Update.
3703 (nto_process_target::join): Define.
3704 * nto-low.h (class nto_process_target): Update.
3705 * win32-low.cc (win32_target_ops): Update.
3706 (win32_join): Turn into ...
3707 (win32_process_target::join): ... this.
3708 * win32-low.h (class win32_process_target): Update.
3710 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3712 Turn process_stratum_target's mourn op into a method of
3715 * target.h (struct process_stratum_target): Remove the target op.
3716 (class process_target): Add the target op.
3718 Update the derived classes and callers below.
3720 * target.cc (target_mourn_inferior): Update.
3721 * linux-low.cc (linux_target_ops): Update.
3722 (linux_mourn): Turn into ...
3723 (linux_process_target::mourn): ... this.
3724 (handle_extended_wait): Update.
3725 (linux_process_target::kill): Update.
3726 (linux_process_target::detach): Update.
3727 * linux-low.h (class linux_process_target): Update.
3728 * lynx-low.cc (lynx_target_ops): Update.
3729 (lynx_mourn): Turn into ...
3730 (lynx_process_target::mourn): ... this.
3731 * lynx-low.h (class lynx_process_target): Update.
3732 * nto-low.cc (nto_target_ops): Update.
3733 (nto_mourn): Turn into ...
3734 (nto_process_target::mourn): ... this.
3735 * nto-low.h (class nto_process_target): Update.
3736 * win32-low.cc (win32_target_ops): Update.
3737 (win32_mourn): Turn into ...
3738 (win32_process_target::mourn): ... this.
3739 * win32-low.h (class win32_process_target): Update.
3741 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3743 Turn process_stratum_target's detach op into a method of
3746 * target.h (struct process_stratum_target): Remove the target op.
3747 (class process_target): Add the target op.
3748 (detach_inferior): Update the macro.
3750 Update the derived classes and callers below.
3752 * linux-low.cc (linux_target_ops): Update.
3753 (linux_detach): Turn into ...
3754 (linux_process_target::detach): ... this.
3755 * linux-low.h (class linux_process_target): Update.
3756 * lynx-low.cc (lynx_target_ops): Update.
3757 (lynx_detach): Turn into ...
3758 (lynx_process_target::detach): ... this.
3759 * lynx-low.h (class lynx_process_target): Update.
3760 * nto-low.cc (nto_target_ops): Update.
3761 (nto_detach): Turn into ...
3762 (nto_process_target::detach): ... this.
3763 * nto-low.h (class nto_process_target): Update.
3764 * win32-low.cc (win32_target_ops): Update.
3765 (win32_detach): Turn into ...
3766 (win32_process_target::detach): ... this.
3767 * win32-low.h (class win32_process_target): Update.
3769 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3771 Turn process_stratum_target's kill op into a method of
3774 * target.h (struct process_stratum_target): Remove the target op.
3775 (class process_target): Add the target op.
3777 Update the derived classes and callers below.
3779 * target.cc (kill_inferior): Update.
3780 * linux-low.cc (linux_target_ops): Update.
3781 (linux_kill): Turn into ...
3782 (linux_process_target::kill): ... this.
3783 * linux-low.h (class linux_process_target): Update.
3784 * lynx-low.cc (lynx_target_ops): Update.
3785 (lynx_kill): Turn into ...
3786 (lynx_process_target::kill): ... this.
3787 * lynx-low.h (class lynx_process_target): Update.
3788 * nto-low.cc (nto_target_ops): Update.
3789 (nto_kill): Turn into ...
3790 (nto_process_target::kill): ... this.
3791 * nto-low.h (class nto_process_target): Update.
3792 * win32-low.cc (win32_target_ops): Update.
3793 (win32_kill): Turn into ...
3794 (win32_process_target::kill): ... this.
3795 * win32-low.h (class win32_process_target): Update.
3797 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3799 Turn process_stratum_target's attach op into a method of
3802 * target.h (struct process_stratum_target): Remove the target op.
3803 (class process_target): Add the target op.
3804 (myattach): Update the macro.
3806 Update the derived classes and callers below.
3808 * linux-low.cc (linux_target_ops): Update.
3809 (linux_attach): Turn into ...
3810 (linux_process_target::attach): ... this.
3811 * linux-low.h (class linux_process_target): Update.
3812 * lynx-low.cc (lynx_target_ops): Update.
3813 (lynx_attach): Turn into ...
3814 (lynx_process_target::attach): ... this.
3815 * lynx-low.h (class lynx_process_target): Update.
3816 * nto-low.cc (nto_target_ops): Update.
3817 (nto_attach): Turn into ...
3818 (nto_process_target::attach): ... this.
3819 * nto-low.h (class nto_process_target): Update.
3820 * win32-low.cc (win32_target_ops): Update.
3821 (win32_attach): Turn into ...
3822 (win32_process_target::attach): ... this.
3823 * win32-low.h (class win32_process_target): Update.
3825 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3827 Turn process_stratum_target's post_create_inferior op into a method
3830 * target.h (struct process_stratum_target): Remove the target op.
3831 (class process_target): Add the target op.
3832 (target_post_create_inferior): Update the macro.
3833 * target.cc (process_target::post_create_inferior): Define.
3835 Update the derived classes and callers below.
3837 * linux-low.cc (linux_target_ops): Update.
3838 (linux_post_create_inferior): Turn into ...
3839 (linux_process_target::post_create_inferior): ... this.
3840 * linux-low.h (class linux_process_target): Update.
3841 * lynx-low.cc (lynx_target_ops): Update.
3842 * nto-low.cc (nto_target_ops): Update.
3843 * win32-low.cc (win32_target_ops): Update.
3845 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3847 Turn process_stratum_target's create_inferior op into a method of
3850 * target.h (struct process_stratum_target): Remove the target op.
3851 (class process_target): Add the target op.
3852 (create_inferior): Rename the macro to ...
3853 (target_create_inferior): ... this.
3855 Update the derived classes and callers below.
3857 * server.cc (handle_v_run): Update.
3858 (captured_main): Update.
3859 (process_serial_event): Update.
3860 * linux-low.cc (linux_target_ops): Update.
3861 (linux_create_inferior): Turn into ...
3862 (linux_process_target::create_inferior): ... this.
3863 * linux-low.h (class linux_process_target): Update.
3864 * lynx-low.cc (lynx_target_ops): Update.
3865 (lynx_create_inferior): Turn into ...
3866 (lynx_process_target::create_inferior): ... this.
3867 * lynx-low.h (class lynx_process_target): Update.
3868 * nto-low.cc (nto_target_ops): Update.
3869 (nto_create_inferior): Turn into ...
3870 (nto_process_target::create_inferior): ... this.
3871 * nto-low.h (class nto_process_target): Update.
3872 * win32-low.cc (win32_target_ops): Update.
3873 (win32_create_inferior): Turn into ...
3874 (win32_process_target::create_inferior): ... this.
3875 * win32-low.h (class win32_process_target): Update.
3877 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3879 * target.h (class process_target): New class definition.
3880 (struct process_stratum_target) <pt>: New field with type
3882 * linux-low.h (class linux_process_target): Define as a derived
3883 class of 'process_target'.
3884 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3886 * lynx-low.h (class lynx_process_target): Define as a derived
3887 class of 'process_target'.
3888 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3890 * nto-low.h (class nto_process_target): Define as a derived
3891 class of 'process_target'.
3892 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3894 * win32-low.h (class win32_process_target): Define as a derived
3895 class of 'process_target'.
3896 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3899 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3901 * configure: Regenerate.
3903 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
3904 Andrew Burgess <andrew.burgess@embecosm.com>
3906 * linux-riscv-low.cc: New file.
3907 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3908 and nat/riscv-linux-tdesc.c.
3909 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3910 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3913 2020-02-14 Tom Tromey <tom@tromey.com>
3915 * acinclude.m4: Don't include acx_configure_dir.m4.
3916 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3917 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3918 (all, install-only, uninstall, clean-info, clean)
3919 (maintainer-clean): Don't recurse.
3920 (subdir_do, all-lib): Remove.
3921 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3923 (generated_files): Update.
3924 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3925 * configure: Rebuild.
3926 * configure.ac: Don't configure gnulib or libiberty.
3929 2020-02-14 Eli Zaretskii <eliz@gnu.org>
3931 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3932 preparing the command line for CreateProcess.
3933 (win32_create_inferior): Reflect the program name in debugging
3934 output that shows the process and its command line.
3936 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3938 * Makefile.in: Rename source files from .c to .cc.
3939 * %.c: Rename to %.cc.
3940 * configure.ac: Rename server.c to server.cc.
3941 * configure: Re-generate.
3943 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3945 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3947 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
3949 * win32-low.c (win32_create_inferior): Set signal_pid.
3951 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
3952 Pedro Alves <palves@redhat.com>
3954 Skip building gdbserver in a cross-configuration.
3955 * configure.srv: Set $gdbserver_host depending on whether $target
3956 is $host. Use $gdbserver_host instead of $host.
3958 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3960 * configure: Re-generate.
3962 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3964 * configure: Re-generate.
3966 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3968 * acinclude.m4: Update warning.m4 path.
3970 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3972 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3973 (handle_exception): Set siginfo_er.
3974 (win32_xfer_siginfo): New function.
3976 2020-02-07 Tom Tromey <tom@tromey.com>
3977 Pedro Alves <palves@redhat.com>
3979 * README: Update build documentation.
3980 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
3982 * configure.ac: Update paths.
3983 * configure: Rebuild.
3984 * acinclude.m4: Update paths.
3985 * Makefile.in: Update include paths.
3986 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
3987 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
3988 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
3989 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
3990 (%-generated.c): Update paths.
3991 * Move entire directory from ../gdb/gdbserver.
3993 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
3995 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
3997 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3999 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4000 assignment instead of srv_linux_obj.
4002 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
4004 * server.c (handle_qxfer_libraries): Write segment-address with
4007 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
4009 * Makefile.in (install-strip): New target.
4010 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4011 * aclocal.m4: Regenerate.
4012 * configure: Regenerate.
4013 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4015 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4017 * Makefile.in (SFILES): Adjust paths to point to real files.
4018 (OBS): Move waitstatus.o to target/waitstatus.o.
4019 (TAGS): Transform paths appropriately.
4021 (nat/%.o): ... this pattern rule.
4023 (target/%.o): ... this pattern rule.
4024 * configure.srv: Adjust paths throughout to include nat/ prefix
4025 with the revant files.
4026 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4027 * configure: Regenerate.
4029 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4031 * Makefile.in (TAGS): Remove config files from the recipe.
4033 2020-01-14 Tom Tromey <tom@tromey.com>
4035 * configure: Rebuild.
4036 * configure.ac: Remove any checks that were added to common.m4.
4037 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4040 2020-01-14 Tom Tromey <tom@tromey.com>
4042 * server.h: Include config.h.
4043 * gdbreplay.c: Include config.h.
4044 * configure: Rebuild.
4045 * configure.ac: Don't source common.host.
4046 * acinclude.m4: Update path.
4047 * Makefile.in (INCSUPPORT): New variable.
4048 (INCLUDE_CFLAGS): Add INCSUPPORT.
4049 (SFILES): Update paths.
4050 (version-generated.c): Update path to create-version.sh.
4051 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4053 2020-01-14 Tom Tromey <tom@tromey.com>
4055 * configure.ac (LIBS): Use WIN32APILIBS.
4056 (USE_WIN32API): Don't define.
4057 * configure: Rebuild.
4059 2020-01-14 Tom Tromey <tom@tromey.com>
4061 * configure: Rebuild.
4063 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4065 * Makefile.in (%-generated.c): Remove rule for files from
4068 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4070 * configure: Re-generate.
4072 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4074 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4076 * tracepoint.c (stop_tracing, flush_trace_buffer,
4077 about_to_request_buffer_space, get_trace_state_variable_value,
4078 set_trace_state_variable_value, gdb_collect): Add declaration.
4080 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4082 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4083 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4084 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4085 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4086 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4089 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4091 * inferiors.c: Include gdbsupport/common-inferior.h.
4093 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4095 * hostio-errno.c: Include hostio.h.
4097 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4099 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4102 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4104 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4105 * linux-arm-tdesc.h: Include arch/arm.h.
4107 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4109 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4111 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4113 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4114 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4116 2020-01-10 Pedro Alves <palves@redhat.com>
4118 * fork-child.c (post_fork_inferior): Pass target down to
4120 * inferiors.c (switch_to_thread): Add process_stratum_target
4122 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4123 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4124 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4125 * remote-utils.c (prepare_resume_reply): Pass the target to
4127 * target.c (the_target): Now a process_stratum_target.
4128 (done_accessing_memory): Pass the target to switch_to_thread.
4129 (set_target_ops): Ajust to use process_stratum_target.
4130 * target.h (struct target_ops): Rename to ...
4131 (struct process_stratum_target): ... this.
4132 (the_target, set_target_ops): Adjust.
4133 (prepare_to_access_memory): Adjust comment.
4134 * win32-low.c (child_xfer_memory): Adjust to use
4135 process_stratum_target.
4136 (win32_target_ops): Now a process_stratum_target.
4138 2020-01-06 Eli Zaretskii <eliz@gnu.org>
4139 Pedro Alves <palves@redhat.com>
4141 * win32-low.c (get_child_debug_event): Extract the fatal exception
4142 from the exit status and convert to the equivalent Posix signal
4144 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4145 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4147 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
4149 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4151 2020-01-01 Joel Brobecker <brobecker@adacore.com>
4153 * server.c (gdbserver_version): Change copyright year to 2020.
4154 * gdbreplay.c (gdbreplay_version): Likewise.
4156 2019-12-19 Christian Biesinger <cbiesinger@google.com>
4158 * configure: Regenerate.
4159 * configure.ac: Quote variable arguments of test.
4161 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4163 * Makefile.in: Fix build with GNU Make 3.81
4165 2019-12-16 Tom Tromey <tromey@adacore.com>
4167 * server.c (get_exec_file): Constify result.
4169 2019-12-10 Christian Biesinger <cbiesinger@google.com>
4171 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4172 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4173 * config.in: Regenerate.
4174 * configure: Regenerate.
4175 * configure.ac: Don't check for strerror.
4176 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4177 Call safe_strerror instead of strerror.
4178 * server.h (strerror): Remove this now-unnecessary declaration.
4179 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4181 (gdb_agent_helper_thread): Likewise.
4182 * utils.c (perror_with_name): Likewise.
4184 2019-11-26 Tom Tromey <tom@tromey.com>
4186 * configure, config.in: Rebuild.
4188 2019-11-26 Tom Tromey <tom@tromey.com>
4190 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4191 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4193 * configure, config.in: Rebuild.
4195 2019-11-26 Tom Tromey <tom@tromey.com>
4197 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4198 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4199 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4200 * acinclude.m4: Include ax_pthread.m4.
4201 * config.in, configure: Rebuild.
4203 2019-11-26 Christian Biesinger <cbiesinger@google.com>
4205 * debug.c (debug_set_output): Call safe_strerror instead of
4207 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4208 (linux_kill_one_lwp): Likewise.
4209 (linux_detach_one_lwp): Likewise.
4210 (linux_wait_for_event_filtered): Likewise.
4211 (store_register): Likewise.
4212 * lynx-low.c (lynx_attach): Likewise.
4213 * mem-break.c (insert_memory_breakpoint): Likewise.
4214 (remove_memory_breakpoint): Likewise.
4215 (delete_fast_tracepoint_jump): Likewise.
4216 (set_fast_tracepoint_jump): Likewise.
4217 (uninsert_fast_tracepoint_jumps_at): Likewise.
4218 (reinsert_fast_tracepoint_jumps_at): Likewise.
4219 * nto-low.c (nto_xfer_memory): Likewise.
4220 (nto_resume): Likewise.
4222 2019-11-20 Luis Machado <luis.machado@linaro.org>
4224 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4225 instead of register count.
4226 * tdesc.c (tdesc_contains_feature): New function.
4227 * tdesc.h (tdesc_contains_feature): New prototype.
4229 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4231 * Makefile.in: Add safe-strerror.c.
4232 * configure: Regenerate.
4233 * configure.ac: Don't source common.host.
4235 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4237 * config.in: Regenerate.
4238 * configure: Regenerate.
4240 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4242 * ax.c (ax_printf): Handle size_t_arg.
4244 2019-11-06 Christian Biesinger <cbiesinger@google.com>
4246 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4247 * mi/mi-main.c (output_cores): Likewise.
4248 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4249 (linux_xfer_osdata_modules): Likewise.
4250 * remote.c (register_remote_support_xml): Likewise.
4251 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4252 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4254 2019-11-01 Christian Biesinger <cbiesinger@google.com>
4256 * configure: Regenerate.
4257 * configure.ac: Remove check for strerror_r.
4259 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4261 * config.in: Regenerate.
4262 * configure: Regenerate.
4263 * configure.ac: Also check for strerror_r.
4265 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4267 * ax.h (debug_agent): Remove duplicate declaration.
4269 2019-10-26 Tom de Vries <tdevries@suse.de>
4271 * linux-aarch64-low.c: Fix typos in comments.
4272 * linux-arm-low.c: Same.
4273 * linux-low.c: Same.
4274 * linux-ppc-low.c: Same.
4275 * proc-service.c: Same.
4278 * tracepoint.c: Same.
4279 * win32-low.c: Same.
4281 2019-10-25 Tom Tromey <tromey@adacore.com>
4283 * utils.c (xstrdup): Remove.
4285 2019-10-23 Tom Tromey <tom@tromey.com>
4287 * configure, config.in: Rebuild.
4289 2019-10-23 Tom Tromey <tom@tromey.com>
4291 * configure: Rebuild.
4292 * acinclude.m4: Use m4_include, not sinclude.
4294 2019-10-17 Tom Tromey <tromey@adacore.com>
4296 * configure: Rebuild.
4297 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4298 in AC_CONFIG_FILES invocation.
4299 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4302 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4304 * server.c: Include xml-builtin.h.
4305 (get_xml_features): Don't declare xml_builtins here.
4307 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4309 * Makefile.in: Remove references to vec-ipa.o.
4311 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4313 * Makefile.in: Remove references to vec.c.
4315 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4317 * server.c (server_waiting): Change to bool.
4318 (extended_protocol): Likewise.
4319 (response_needed): Likewise.
4320 (exit_requested): Likewise.
4321 (run_once): Likewise.
4322 (report_no_resumed): Likewise.
4323 (non_stop): Likewise.
4324 (disable_packet_vCont): Likewise.
4325 (disable_packet_Tthread): Likewise.
4326 (disable_packet_qC): Likewise.
4327 (disable_packet_qfThreadInfo): Likewise.
4328 (handle_general_set): Update.
4329 (handle_detach): Update.
4330 (handle_monitor_command): Update.
4331 (handle_query): Update.
4332 (captured_main): Update.
4333 (process_serial_event): Update.
4334 * server.h (server_waiting): Change to bool.
4335 (disable_packet_vCont): Likewise.
4336 (disable_packet_Tthread): Likewise.
4337 (disable_packet_qC): Likewise.
4338 (disable_packet_qfThreadInfo): Likewise.
4339 (run_once): Likewise.
4340 (non_stop): Likewise.
4341 * target.c (target_stop_and_wait): Update.
4343 2019-10-02 Tom Tromey <tromey@adacore.com>
4345 * Makefile.in (SFILES): Add common-inferior.c.
4346 (OBS): Add common-inferior.o.
4347 * server.c (startup_with_shell): Don't define.
4349 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4351 * linux-low.c (linux_low_read_btrace): Update for change to
4354 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4356 * debug.c (debug_threads): Remove comment in favor of the header.
4357 * debug.h (using_threads): Add declaration.
4358 (debug_threads): Add comment.
4359 * linux-aarch64-low.c: Include debug.h and remove declaration of
4361 * nto-low.c: Likewise.
4362 * remote-utils.c: Likewise.
4363 * thread-db.c: Likewise.
4365 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4367 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4368 and powerpc-cell64l-ipa.o.
4369 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4370 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4371 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4374 * spu-low.c: Remove file.
4376 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4377 (parse_spufs_run): Remove.
4378 (ppc_get_pc): Remove Cell/B.E. support.
4379 (ppc_set_pc): Likewise.
4380 (ppc_breakpoint_at): Likewise.
4381 (ppc_arch_setup): Likewise.
4382 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4383 tdesc_powerpc_cell32l.
4384 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4385 or init_registers_powerpc_cell32l.
4386 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4387 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4388 or init_registers_powerpc_cell32l.
4389 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4390 (init_registers_powerpc_cell32l): Remove prototype.
4391 (init_registers_powerpc_cell64l): Likewise.
4393 * target.h (struct target_ops): Remove qxfer_spu member.
4394 * server.c (handle_qxfer_spu): Remove.
4395 (qxfer_packets): Remove entry for "spu".
4396 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4397 * linux-low.c (SPUFS_MAGIC): Remove.
4398 (spu_enumerate_spu_ids): Remove.
4399 (linux_qxfer_spu): Remove.
4400 (linux_target_ops): Remove qxfer_spu member.
4401 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4402 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4403 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4405 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4407 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4408 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4409 * config.in: Regenerate.
4410 * configure: Regenerate.
4412 2019-08-15 Tom Tromey <tromey@adacore.com>
4414 * target.c (target_write_memory): Use gdb::byte_vector.
4416 2019-08-15 Tom Tromey <tromey@adacore.com>
4418 * tracepoint.c (write_inferior_data_pointer)
4419 (write_inferior_integer, write_inferior_int8)
4420 (write_inferior_uinteger, m_tracepoint_action_download)
4421 (r_tracepoint_action_download, x_tracepoint_action_download)
4422 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4423 (download_agent_expr, download_tracepoint_1)
4424 (download_trace_state_variables, upload_fast_traceframes): Update.
4425 * server.c (gdb_write_memory): Update.
4426 * remote-utils.c (relocate_instruction): Update.
4427 * proc-service.c (ps_pdwrite): Update.
4428 * mem-break.c (remove_memory_breakpoint)
4429 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4430 (uninsert_fast_tracepoint_jumps_at)
4431 (reinsert_fast_tracepoint_jumps_at): Update.
4432 * linux-x86-low.c (append_insns)
4433 (i386_install_fast_tracepoint_jump_pad)
4434 (amd64_write_goto_address, i386_write_goto_address): Update.
4435 * linux-s390-low.c (append_insns, s390_write_goto_address):
4437 * linux-ppc-low.c (ppc_relocate_instruction)
4438 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4439 (ppc_write_goto_address): Update.
4440 * linux-aarch64-low.c (append_insns): Update.
4441 * target.h (struct target_ops): Update.
4442 (write_inferior_memory): Don't declare.
4443 * target.c (target_write_memory): Rename from
4444 write_inferior_memory. Remove old target_write_memory.
4446 2019-08-15 Tom Tromey <tromey@adacore.com>
4448 * target.c (write_inferior_memory): Use std::vector.
4450 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4453 * configure.ac: Drop enable-libmcheck support.
4454 * configure, config.in: Rebuild.
4455 * acinclude.m4: Don't include it.
4457 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4459 * configure.srv: Remove Arm xml files.
4461 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4463 * configure.srv: Add new files. Remove xml generated files.
4464 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4466 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4467 * linux-aarch32-tdesc.c: New file.
4468 * linux-aarch32-tdesc.h: New file.
4469 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4470 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4471 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4472 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4473 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4474 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4475 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4476 (arm_read_description): Call arm_linux_read_description.
4477 (initialize_low_arch): Don't init registers.
4478 * linux-arm-tdesc.c: New file.
4479 * linux-arm-tdesc.h: New file.
4481 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4483 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4484 Move counter inside for.
4485 (arm_read_description): Check ptrace earlier.
4486 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4488 2019-07-09 Tom Tromey <tom@tromey.com>
4490 * configure: Rebuild.
4491 * configure.ac: Change common to gdbsupport.
4492 * acinclude.m4: Change common to gdbsupport.
4493 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4494 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4495 common to gdbsupport.
4496 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4497 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4498 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4499 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4500 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4501 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4502 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4503 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4504 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4505 common to gdbsupport.
4507 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4509 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4511 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4513 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4515 * configure.srv: Remove legacy xml.
4516 * linux-aarch64-low.c (initialize_low_arch): Remove
4517 initialize_low_tdesc call.
4518 * linux-aarch64-tdesc-selftest.c: Remove file.
4519 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4520 * linux-x86-low.c (initialize_low_arch): Remove
4521 initialize_low_tdesc call.
4522 * linux-x86-tdesc-selftest.c: Remove file.
4523 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4525 2019-06-20 Tom de Vries <tdevries@suse.de>
4527 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4528 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4530 2019-06-19 Tom de Vries <tdevries@suse.de>
4532 * debug.h (debug_write): Change return type to ssize_t.
4533 * debug.c (debug_write): Same.
4535 2019-06-14 Tom Tromey <tom@tromey.com>
4537 * configure.ac: Use new path to gnulib.
4538 * configure: Rebuild.
4539 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4542 2019-06-11 Tom Tromey <tom@tromey.com>
4544 * Makefile.in (SFILES): Add alloc.c.
4546 (IPA_OBJS): Add alloc-ipa.o.
4547 (alloc-ipa.o): New target.
4548 (%.o: ../%.c): New pattern rule.
4550 2019-06-10 Tom Tromey <tromey@adacore.com>
4552 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4553 end warning with a newline.
4554 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4556 * thread-db.c (attach_thread): Don't end warning with a newline.
4557 (thread_db_notice_clone): Likewise.
4558 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4560 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4561 end warning with a newline.
4563 2019-06-04 Pedro Alves <palves@redhat.com>
4565 * server.c (captured_main): Use make_unique_xstrdup.
4567 2019-06-02 Tom Tromey <tom@tromey.com>
4569 * gdbreplay.c (fromhex): Remove.
4570 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4572 2019-05-29 Tom Tromey <tromey@adacore.com>
4574 * configure: Rebuild.
4576 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4578 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4579 sign extension code on 32-bit builds.
4581 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4584 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4586 2019-04-19 Tom Tromey <tom@tromey.com>
4588 * server.c (struct vstop_notif): Derive from notif_event.
4590 (queue_stop_reply): Update.
4591 (remove_all_on_match_ptid): Change type. Rewrite.
4592 (discard_queued_stop_replies): Rewrite.
4593 (in_queued_stop_replies_ptid): Change type.
4594 (in_queued_stop_replies): Rewrite.
4595 (notif_stop): Update.
4596 (queue_stop_reply_callback): Update.
4597 (captured_main): Don't call initialize_notif.
4598 (push_stop_notification): Update.
4599 * notif.c (notif_write_event, handle_notif_ack)
4600 (notif_event_enque, notif_push): Update.
4601 (notif_event_xfree, initialize_notif): Remove.
4602 * notif.h (struct notif_event): Include <list>, not
4604 (struct notif_server) <queue>: Now a std::list.
4605 (notif_event_p): Remove typedef.
4606 (initialize_notif): Don't declare.
4607 (struct notif_event): Add virtual destructor.
4609 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4611 * ax.c (ax_vdebug): Call debug_printf.
4612 * debug.c (debug_write): New function.
4613 * debug.h (debug_write): New declaration.
4614 * linux-low.c (sigchld_handler): Call debug_write.
4616 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4618 * debug.c (debug_set_output): New function.
4619 (debug_vprintf): Send output to debug_file.
4620 (debug_flush): Likewise.
4621 * debug.h (debug_set_output): New declaration.
4622 * server.c (handle_monitor_command): Add debug-file option.
4623 (captured_main): Likewise.
4625 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4627 * debug.c (remote_debug): Add definition.
4628 * debug.h (remote_debug): Add declaration.
4629 * hostio.c (remote_debug): Remove declaration.
4630 * remote-utils.c (struct ui_file): Likewise.
4631 (remote_debug): Likewise.
4632 * remote-utils.h (remote_debug): Likewise,
4633 * server.c (remote_debug): Remove definition.
4635 2019-04-10 Kevin Buettner <kevinb@redhat.com>
4637 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4638 when using a 64-bit gdbserver.
4640 2019-04-09 Tom Tromey <tromey@adacore.com>
4642 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4644 2019-04-08 Tom Tromey <tom@tromey.com>
4646 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4648 (linux_resume_one_lwp): Likewise.
4650 2019-04-08 Tom Tromey <tom@tromey.com>
4652 * gdbreplay.c: Update.
4653 * linux-low.c: Update.
4656 2019-04-08 Tom Tromey <tom@tromey.com>
4658 * server.c: Use C++ exception handling.
4659 * linux-low.c: Use C++ exception handling.
4660 * gdbreplay.c: Use C++ exception handling.
4662 2019-04-08 Tom Tromey <tom@tromey.com>
4664 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4665 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4666 (captured_main, main): Update.
4667 * gdbreplay.c (main): Update.
4669 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4671 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4672 value in argument pointer, return 1 if the entry is found and 0
4673 otherwise. Move comment.
4674 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4675 * linux-low.h (linux_get_auxv): Declare.
4676 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4678 2019-04-05 Tom Tromey <tromey@adacore.com>
4680 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4683 2019-03-28 Alan Hayward <alan.hayward@arm.com>
4685 * linux-low.c (AT_HWCAP2): Add define if not already included.
4687 2019-03-26 Alan Hayward <alan.hayward@arm.com>
4689 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4690 (aarch64_arch_setup): Call linux_get_hwcap.
4691 * linux-arm-low.c (arm_get_hwcap): Remove function.
4692 (arm_read_description): Call linux_get_hwcap.
4693 * linux-low.c (linux_get_auxv): New function.
4694 (linux_get_hwcap): Likewise.
4695 (linux_get_hwcap2): Likewise.
4696 * linux-low.h (linux_get_hwcap): New declaration.
4697 (linux_get_hwcap2): Likewise.
4698 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4699 (ppc_arch_setup): Call linux_get_hwcap.
4700 * linux-s390-low.c (s390_get_hwcap): Remove function.
4701 (s390_arch_setup): Call linux_get_hwcap.
4703 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4704 Jiong Wang <jiong.wang@arm.com>
4706 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4707 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4709 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4711 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4712 Jiong Wang <jiong.wang@arm.com>
4714 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4715 (aarch64_get_hwcap): New function.
4716 (aarch64_arch_setup): Read APIA hwcap.
4718 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4719 Jiong Wang <jiong.wang@arm.com>
4721 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4722 (initialize_low_tracepoint): Likewise.
4723 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4724 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4725 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4726 (aarch64_linux_read_description): Likewise.
4727 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4729 2019-03-12 John Baldwin <jhb@FreeBSD.org>
4731 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4732 i386_create_target_description for 'segments' parameter.
4733 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4734 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4735 * win32-i386-low.c (i386_arch_setup): Likewise.
4737 2019-03-12 Tom Tromey <tromey@adacore.com>
4739 * linux-low.c (iterate_over_lwps): Update.
4741 2019-03-06 Tom Tromey <tom@tromey.com>
4743 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4744 (captured_main): Use SCOPE_EXIT.
4746 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4748 * configure.srv: Use '$enable_unittest' instead of '$development'
4749 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4752 2019-02-27 Tom Tromey <tromey@adacore.com>
4754 * gdbreplay.c (logchar): Handle \r\n.
4756 2019-02-07 Alan Hayward <alan.hayward@arm.com>
4758 * linux-low.c (linux_attach): Add process before lwp.
4759 * server.c (attach_inferior): Check if already attached.
4761 2019-02-07 Tom Tromey <tom@tromey.com>
4763 * x86-tdesc.h: Rename include guard.
4764 * x86-low.h: Add include guard.
4765 * wincecompat.h: Rename include guard.
4766 * win32-low.h: Add include guard.
4767 * utils.h: Rename include guard.
4768 * tracepoint.h: Rename include guard.
4769 * tdesc.h: Rename include guard.
4770 * target.h: Rename include guard.
4771 * server.h: Rename include guard.
4772 * remote-utils.h: Rename include guard.
4773 * regcache.h: Rename include guard.
4774 * nto-low.h: Rename include guard.
4775 * notif.h: Add include guard.
4776 * mem-break.h: Rename include guard.
4777 * lynx-low.h: Add include guard.
4778 * linux-x86-tdesc.h: Add include guard.
4779 * linux-s390-tdesc.h: Add include guard.
4780 * linux-ppc-tdesc-init.h: Add include guard.
4781 * linux-low.h: Add include guard.
4782 * linux-aarch64-tdesc.h: Add include guard.
4783 * linux-aarch32-low.h: Add include guard.
4784 * inferiors.h: Rename include guard.
4785 * i387-fp.h: Rename include guard.
4786 * hostio.h: Rename include guard.
4787 * gdbthread.h: Rename include guard.
4788 * gdb_proc_service.h: Rename include guard.
4789 * event-loop.h: Rename include guard.
4790 * dll.h: Rename include guard.
4791 * debug.h: Rename include guard.
4792 * ax.h: Rename include guard.
4794 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4797 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4798 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4800 2019-01-25 Tom Tromey <tom@tromey.com>
4802 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4804 2019-01-25 Tom Tromey <tom@tromey.com>
4806 * win32-low.c: Fix common/ includes.
4807 * win32-i386-low.c: Fix common/ includes.
4808 * tracepoint.c: Fix common/ includes.
4809 * thread-db.c: Fix common/ includes.
4810 * target.h: Fix common/ includes.
4811 * symbol.c: Fix common/ includes.
4812 * spu-low.c: Fix common/ includes.
4813 * server.h: Fix common/ includes.
4814 * server.c: Fix common/ includes.
4815 * remote-utils.c: Fix common/ includes.
4816 * regcache.h: Fix common/ includes.
4817 * regcache.c: Fix common/ includes.
4818 * nto-x86-low.c: Fix common/ includes.
4819 * notif.h: Fix common/ includes.
4820 * mem-break.h: Fix common/ includes.
4821 * lynx-low.c: Fix common/ includes.
4822 * lynx-i386-low.c: Fix common/ includes.
4823 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4824 * linux-x86-low.c: Fix common/ includes.
4825 * linux-low.c: Fix common/ includes.
4826 * inferiors.h: Fix common/ includes.
4827 * i387-fp.c: Fix common/ includes.
4828 * hostio.c: Fix common/ includes.
4829 * hostio-errno.c: Fix common/ includes.
4830 * gdbthread.h: Fix common/ includes.
4831 * gdbreplay.c: Fix common/ includes.
4832 * fork-child.c: Fix common/ includes.
4833 * event-loop.c: Fix common/ includes.
4835 (enum gdb_agent_op): Fix common/ includes.
4837 2019-01-21 Tom Tromey <tom@tromey.com>
4839 * tracepoint.c: Fix includes.
4840 * remote-utils.c: Fix includes.
4841 * linux-x86-low.c: Fix includes.
4843 2019-01-01 Joel Brobecker <brobecker@adacore.com>
4845 * gdbreplay.c (gdbreplay_version): Update copyright year in
4847 * server.c (gdbserver_version): Likewise.
4849 2018-12-05 Alan Hayward <alan.hayward@arm.com>
4851 * linux-low.c (add_lwp): Switch ordering.
4853 2018-11-29 Tom Tromey <tom@tromey.com>
4855 * win32-low.c (win32_join): Take pid, not process.
4856 * target.h (struct target_ops) <join>: Change argument type.
4857 (join_inferior): Change argument name.
4858 * spu-low.c (spu_join): Take pid, not process.
4859 * server.c (handle_detach): Preserve pid before destroying
4861 * lynx-low.c (lynx_join): Take pid, not process.
4862 * linux-low.c (linux_join): Take pid, not process.
4864 2018-11-23 Alan Hayward <alan.hayward@arm.com>
4866 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4867 (aarch64_cannot_fetch_register): Likewise.
4868 (struct linux_target_ops): Update references.
4870 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4872 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4874 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4876 * configure.srv (ipa_ppc_linux_regobj): Add
4877 powerpc-isa207-htm-vsx32l-ipa.o and
4878 powerpc-isa207-htm-vsx64l-ipa.o.
4879 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4880 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4881 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4882 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4883 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4884 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4885 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4886 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4887 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4888 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4889 (init_registers_powerpc_isa207_htm_vsx32l)
4890 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4891 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4892 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4893 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4894 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4895 (ppc_store_tm_ctarregset): New functions.
4896 (ppc_regsets): Add entries for HTM regsets.
4897 (ppc_arch_setup): Set htm in features struct when needed. Set
4898 sizes for the HTM regsets.
4899 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4900 (initialize_low_arch): Call
4901 init_registers_powerpc_isa207_htm_vsx32l and
4902 init_registers_powerpc_isa207_htm_vsx64l.
4903 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4904 PPC_TDESC_ISA207_HTM_VSX.
4905 (initialize_low_tracepoint): Call
4906 init_registers_powerpc_isa207_htm_vsx32l and
4907 init_registers_powerpc_isa207_htm_vsx64l.
4909 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4911 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4912 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4913 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4914 (ppc_store_pmuregset): New functions.
4915 (ppc_regsets): Add entries for ebb and pmu regsets.
4916 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4917 pmu regsets are available. Set sizes for these regsets.
4919 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4921 * configure.srv (ipa_ppc_linux_regobj): Add
4922 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4923 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4924 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4925 rs6000/powerpc-isa207-vsx32l.xml, and
4926 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4927 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4928 <PPC_TDESC_ISA207_VSX>: New enum value.
4929 (init_registers_powerpc_isa207_vsx32l): Declare.
4930 (init_registers_powerpc_isa207_vsx64l): Declare.
4931 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4932 (ppc_store_tarregset): New function.
4933 (ppc_regsets): Add entry for the TAR regset.
4934 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4935 size for the TAR regsets.
4936 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4937 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4938 and init_registers_powerpc_isa207_vsx64l.
4939 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4940 (initialize_low_tracepoint): Call
4941 init_registers_powerpc_isa207_vsx32l and
4942 init_registers_powerpc_isa207_vsx64l.
4944 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4945 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4947 * configure.srv (ipa_ppc_linux_regobj): Add
4948 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4949 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4950 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4951 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4952 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4953 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4954 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4955 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4956 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4957 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4958 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4959 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4960 (ppc_hwcap): Add comment.
4961 (ppc_hwcap2): New global.
4962 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4963 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4964 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4965 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4966 when needed. Set sizes for the the DSCR and PPR regsets.
4967 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4968 (initialize_low_arch): Call
4969 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4970 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4971 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4972 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4973 (initialize_low_tracepoint): Call
4974 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4975 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4977 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4979 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
4981 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
4982 Simon Marchi <simark@simark.ca>
4984 * acinclude.m4: Include "../selftest.m4".
4985 * configure: Regenerate.
4986 * configure.ac: Use "GDB_AC_SELFTEST".
4987 * configure.srv: Use "$enable_unittests" instead of
4988 "$development" when checking whether unit tests have been
4990 * server.c (captured_main): Update message informing that
4991 selftests have been disabled.
4993 2018-10-04 Tom Tromey <tom@tromey.com>
4995 * configure: Rebuild.
4997 2018-10-04 Tom Tromey <tom@tromey.com>
4999 * server.c (handle_status): Rename inner "thread".
5000 (process_serial_event): Declare "res" in 'm' case.
5001 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5002 (iterate_over_lwps): Rename inner "thread".
5003 (linux_qxfer_libraries_svr4): Rename inner "len".
5004 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5006 2018-10-01 Gary Benson <gbenson@redhat.com>
5008 * gdb_proc_service.h: Moved common code to
5009 common/gdb_proc_service.h.
5011 2018-10-01 Gary Benson <gbenson@redhat.com>
5013 * gdb_proc_service.h: Synchronize comments and whitespace with
5014 GDB's version of this file.
5016 2018-09-25 Tom Tromey <tom@tromey.com>
5018 * configure: Rebuild.
5019 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5021 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5023 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5024 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5025 ($(IPA_LIB)): Sort IPA_OBJS.
5027 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5029 * Makefile.in: Remove references to $(ADD_DEPS).
5031 2018-09-16 Tom Tromey <tom@tromey.com>
5033 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5035 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5038 2018-09-05 Tom Tromey <tom@tromey.com>
5040 * configure: Rebuild.
5042 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5045 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5047 2018-08-27 Tom Tromey <tom@tromey.com>
5050 * configure: Rebuild.
5052 2018-08-27 Tom Tromey <tom@tromey.com>
5054 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5055 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5056 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5057 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5058 (s390x_emit_stack_adjust): Add casts to unsigned char.
5060 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5064 * server.h (struct client_state) <disable_randomization>:
5067 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5069 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5071 (mips_supply_ptrace_register): Likewise.
5073 2018-07-22 Tom Tromey <tom@tromey.com>
5075 * configure: Rebuild.
5077 2018-07-22 Tom Tromey <tom@tromey.com>
5079 * win32-low.c (win32_create_inferior): Remove unused variables.
5080 * gdbreplay.c (remote_open): Remove unused variable.
5081 * remote-utils.c (remote_prepare): Remove unused variable.
5082 * x86-tdesc.h (X86_TDESC_H): Define.
5083 (amd64_expedite_regs): Define conditionally.
5084 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5085 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5086 * remote-utils.c (readchar): Remove unused variable.
5088 2018-07-13 Pedro Alves <palves@redhat.com>
5090 * linux-low.c (linux_kill): Change parameter to process_info
5091 pointer instead of pid. Adjust.
5092 * lynx-low.c (lynx_kill): Likewise.
5093 * nto-low.c (nto_kill): Likewise.
5094 * spu-low.c (spu_kill): Likewise.
5095 * win32-low.c (win32_kill): Likewise.
5096 * server.c (handle_v_kill, kill_inferior_callback)
5097 (detach_or_kill_for_exit): Adjust.
5098 * target.c (kill_inferior): Change parameter to process_info
5099 pointer instead of pid. Adjust.
5100 * target.h (struct target_ops) <kill>: Change parameter to
5101 process_info pointer instead of pid. Adjust all implementations
5103 (kill_inferior): Likewise.
5105 2018-07-13 Pedro Alves <palves@redhat.com>
5107 * linux-low.c (linux_detach, linux_join): Change parameter to
5108 process_info pointer instead of pid. Adjust.
5109 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5110 * nto-low.c (nto_detach): Likewise.
5111 * spu-low.c (spu_detach, spu_join): Likewise.
5112 * win32-low.c (win32_detach, win32_join): Likewise.
5113 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5114 * target.h (struct target_ops) <detach, join>: Change parameter to
5115 process_info pointer instead of pid. Adjust all implementations
5117 (detach_inferior, join_inferior): Rename 'pid' parameter to
5120 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5121 Jan Kratochvil <jan.kratochvil@redhat.com>
5122 Paul Fertser <fercerpav@gmail.com>
5123 Tsutomu Seki <sekiriki@gmail.com>
5125 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5126 (OBS): Add 'common/netstuff.o'.
5127 (GDBREPLAY_OBS): Likewise.
5128 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5129 (remote_open): Implement support for IPv6
5131 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5133 (handle_accept_event): Accept connections from IPv6 sources.
5134 (remote_prepare): Handle IPv6-style hostnames; implement
5135 support for IPv6 connections.
5136 (remote_open): Implement support for printing connections from
5139 2018-07-11 Pedro Alves <palves@redhat.com>
5142 * mem-break.c (any_persistent_commands): Add process_info
5143 parameter and use it instead of relying on the current process.
5144 Change return type to bool.
5145 * mem-break.h (any_persistent_commands): Add process_info
5146 parameter and change return type to bool.
5147 * server.c (handle_detach): Remove require_running_or_return call.
5148 Look up the process_info for the process we're about to detach.
5149 If not found, return back error to GDB. Adjust
5150 any_persistent_commands call to pass down a process pointer.
5152 2018-07-11 Pedro Alves <palves@redhat.com>
5154 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5155 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5156 instead of collect_register_by_name.
5157 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5158 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5160 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5161 Pedro Alves <palves@redhat.com>
5163 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5165 2018-07-03 Tom Tromey <tom@tromey.com>
5167 * linux-low.c: Update.
5168 * lynx-low.c: Update.
5169 * mem-break.c: Update.
5170 * nto-low.c: Update.
5171 * remote-utils.c: Update.
5173 * spu-low.c: Update.
5175 * win32-low.c: Update.
5177 2018-07-03 Tom Tromey <tom@tromey.com>
5181 2018-07-03 Tom Tromey <tom@tromey.com>
5183 * linux-low.c: Update.
5185 2018-07-03 Tom Tromey <tom@tromey.com>
5189 2018-07-03 Tom Tromey <tom@tromey.com>
5191 * linux-low.c: Update.
5192 * linux-mips-low.c: Update.
5193 * lynx-low.c: Update.
5194 * nto-low.c: Update.
5195 * remote-utils.c: Update.
5197 * spu-low.c: Update.
5199 * thread-db.c: Update.
5201 2018-07-03 Tom Tromey <tom@tromey.com>
5203 * linux-low.c: Update.
5204 * linux-mips-low.c: Update.
5205 * lynx-low.c: Update.
5206 * mem-break.c: Update.
5207 * nto-low.c: Update.
5208 * remote-utils.c: Update.
5210 * spu-low.c: Update.
5212 * tracepoint.c: Update.
5214 2018-07-03 Tom Tromey <tom@tromey.com>
5216 * linux-low.c: Update.
5217 * linux-ppc-low.c: Update.
5218 * linux-x86-low.c: Update.
5219 * proc-service.c: Update.
5221 * spu-low.c: Update.
5222 * thread-db.c: Update.
5223 * win32-low.c: Update.
5225 2018-07-03 Tom Tromey <tom@tromey.com>
5227 * linux-low.c: Update.
5228 * lynx-low.c: Update.
5229 * nto-low.c: Update.
5230 * remote-utils.c: Update.
5231 * spu-low.c: Update.
5232 * thread-db.c: Update.
5233 * win32-low.c: Update.
5235 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5237 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5238 parameter in call to 'amd64_create_target_description'.
5240 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5242 * x86-tdesc.h: Remove executable permission flag.
5244 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5246 * configure.ac: Remove AC_PREREQ, add missing quoting.
5247 * configure: Re-generate.
5248 * config.in: Re-generate.
5249 * aclocal.m4: Re-generate.
5251 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5253 * tracepoint.h (current_traceframe): Remove declaration.
5255 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5257 * linux-aarch64-low.c (is_sve_tdesc): New function.
5258 (aarch64_sve_regs_copy_to_regcache): Likewise.
5259 (aarch64_sve_regs_copy_from_regcache): Likewise.
5260 (aarch64_regs_info): Add SVE checks.
5261 (initialize_low_arch): Initialize SVE.
5263 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5265 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5267 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5269 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5270 (initialize_low_tracepoint): Likewise
5271 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5272 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5274 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5276 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5278 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5280 * server.h (PBUFSIZ): Increase size
5282 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5284 * regcache.c (regcache::raw_compare): New function.
5285 * regcache.h (regcache::raw_compare): New declaration.
5287 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5289 * regcache.c (new_register_cache): Use new.
5290 (free_register_cache): Use delete.
5291 (register_data): Use const.
5292 (supply_register): Move body inside regcache.
5293 (regcache::raw_supply): New override function.
5294 (collect_register): Move body inside regcache.
5295 (regcache::raw_collect): New override function.
5296 (regcache::get_register_status): New override function.
5297 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5299 2018-06-09 Tom Tromey <tom@tromey.com>
5301 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5303 (event_queue): Use std::queue.
5304 (gdb_event_xfree): Remove.
5305 (initialize_event_loop, process_event, wait_for_event): Update.
5307 2018-06-08 Stan Cox <scox@redhat.com>
5309 * win32-low.c (win32_create_inferior): last_ptid and last_status
5310 moved to client_state.
5312 2018-06-08 Pedro Alves <palves@redhat.com>
5314 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5315 common/common-exceptions.o, common/common-utils.o,
5316 common/errors.o, common/print-utils.o and utils.o.
5317 * gdbreplay.c: Include "common-defs.h" instead of the two
5318 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5319 string.h or alloca.h.
5320 (perror_with_name): Delete.
5321 (remote_open): Use xstrdup instead of strdup.
5322 (main): Rename to ...
5323 (captured_main): ... this.
5326 2018-06-08 Tom Tromey <tom@tromey.com>
5328 * linux-low.c (linux_low_read_btrace): Update.
5330 2018-06-04 Stan Cox <scox@redhat.com>
5332 * server.h (struct client_state): New.
5333 * server.c (cont_thread, general_thread, multi_process)
5334 (report_fork_events, report_vfork_events, report_exec_events)
5335 (report_thread_events, swbreak_feature, hwbreak_feature)
5336 (vCont_supported, disable_randomization, pass_signals)
5337 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5338 Moved to client_state.
5339 * remote-utils.c (remote_debug, noack_mode)
5340 (transport_is_reliable): Moved to client_state.
5341 * tracepoint.c (current_traceframe): Moved to client_state.
5344 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5345 linux-low.c, remote-utils.h, target.c: Use client_state.
5347 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5349 * configure.srv: Add new c/h file.
5351 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5353 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5356 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5358 * gdb.arch/mips-fpregset-core.exp: New test.
5359 * gdb.arch/mips-fpregset-core.c: New test source.
5361 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5364 * hostio.c (require_int): Do not report overflow for integers
5365 between 0xfffffff and 0x7fffffff.
5367 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5369 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5370 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5371 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5373 (the_low_target): Wire them.
5375 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5377 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5378 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5379 mode. Call collect_register_by_name with vscr using
5380 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5381 (ppc_store_vrregset): Add and set vscr_offset variable as in
5382 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5385 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5387 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5388 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5389 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5391 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5393 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5394 (ppc_store_vsxregset): Likewise.
5395 (ppc_fill_vrregset): Likewise.
5396 (ppc_store_vrregset): Likewise.
5397 (ppc_fill_evrregset): Likewise.
5398 (ppc_store_evrregset): Likewise.
5399 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5400 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5403 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5405 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5406 wordsize of the inferior. Call ppc_linux_target_wordsize.
5408 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5410 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5411 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5412 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5413 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5414 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5415 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5416 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5417 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5418 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5419 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5420 (tdesc_powerpc_e500l): Remove.
5421 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5422 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5423 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5424 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5426 (ppc_arch_setup): Remove target description matching code. Fill a
5427 ppc_linux_features struct and call ppc_linux_match_description
5430 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5432 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5433 width of the requested register exceeds the width of the
5435 (mips_cannot_store_register): Likewise.
5437 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5439 * linux-mips-low.c (mips_fetch_register): New function. Update
5441 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5442 (the_low_target): Wire `mips_fetch_register'.
5444 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5446 * lynx-i386-low.c (LYNXOS_178): New macro.
5447 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5448 the layout on LynxOS-178.
5449 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5450 handle floating point registers that are not supported by
5453 2018-05-10 Tom Tromey <tom@tromey.com>
5455 * configure: Rebuild.
5457 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5460 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5461 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5462 Use it to set the expedite_regs field in the given tdesc.
5463 * x86-tdesc.h: New file.
5464 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5465 Adjust following the addition of the new expedite_regs parameter
5466 to init_target_desc.
5467 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5468 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5469 (i386_linux_read_description, amd64_linux_read_description):
5470 Adjust following the addition of the new expedite_regs parameter
5471 to init_target_desc.
5472 * lynx-i386-low.c: #include "x86-tdesc.h".
5473 (lynx_i386_arch_setup): Adjust following the addition of the new
5474 expedite_regs parameter to init_target_desc.
5475 * nto-x86-low.c: #include "x86-tdesc.h".
5476 (nto_x86_arch_setup): Adjust following the addition of the new
5477 expedite_regs parameter to init_target_desc.
5478 * win32-i386-low.c: #include "x86-tdesc.h".
5479 (i386_arch_setup): Adjust following the addition of the new
5480 expedite_regs parameter to init_target_desc.
5482 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5485 * win32-low.c (win32_create_inferior): Add call to my_wait
5486 setting last_status global.
5488 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5491 * win32-low.c (create_process): Only call gdb_tilde_expand if
5492 inferior_cwd is not NULL.
5494 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5496 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5497 registers to the cache if their values have changed.
5498 (i387_xsave_to_cache): Provide default values for x87 control
5499 registers when these features are available, but disabled.
5500 * regcache.c (supply_register_by_name_zeroed): New function.
5501 * regcache.h (supply_register_by_name_zeroed): Declare new
5504 2018-05-07 Tom Tromey <tom@tromey.com>
5506 * configure: Rebuild.
5508 2018-05-04 Tom Tromey <tom@tromey.com>
5510 * configure: Rebuild.
5512 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5513 Pedro Alves <palves@redhat.com>
5515 * linux-aarch64-low.c (aarch64_stopped_data_address):
5518 2018-04-27 Tom Tromey <tom@tromey.com>
5520 * configure: Rebuild.
5522 2018-04-23 Tom Tromey <tom@tromey.com>
5524 * configure: Rebuild.
5526 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5528 * Makefile.in (depcomp): Add "..".
5529 (all_deps_files): New and use it.
5531 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5533 * configure.srv (aarch64*-*-linux*): Don't include xml.
5534 (i[34567]86-*-cygwin*): Likewise.
5535 (i[34567]86-*-linux*): Likewise.
5536 (i[34567]86-*-lynxos*): Likewise.
5537 (i[34567]86-*-mingw32ce*): Likewise.
5538 (i[34567]86-*-mingw*): Likewise.
5539 (i[34567]86-*-nto*): Likewise.
5540 (tic6x-*-uclinux): Likewise.
5541 (x86_64-*-linux*): Likewise.
5542 (x86_64-*-mingw*): Likewise.
5543 (x86_64-*-cygwin*): Likewise.
5545 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5547 * tdesc.c: Remove xml parameter.
5549 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5551 * server.c (get_features_xml): Remove cast.
5552 * tdesc.c (void target_desc::accept): Fill in function.
5553 (tdesc_get_features_xml): Remove old xml creation.
5554 (print_xml_feature::visit_pre): Add xml vistor.
5555 * tdesc.h (struct target_desc): Make xmltarget mutable.
5556 (tdesc_get_features_xml): Remove declaration.
5558 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5560 * tdesc.c (tdesc_architecture_name): Add new function.
5561 (tdesc_osabi_name): Likewise.
5562 (tdesc_get_features_xml): Use new functions.
5564 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5566 * tdesc.c (tdesc_create_flags): Remove.
5567 (tdesc_add_flag): Likewise.
5568 (tdesc_named_type): Likewise.
5569 (tdesc_create_union): Likewise.
5570 (tdesc_create_struct): Likewise.
5571 (tdesc_create_vector): Likewise.
5572 (tdesc_add_bitfield): Likewise.
5573 (tdesc_add_field): Likewise.
5574 (tdesc_set_struct_size): Likewise.
5576 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5578 * tdesc.c (~target_desc): Remove implictly deleted items.
5579 (init_target_desc): Iterate all features.
5580 (tdesc_get_features_xml): Use vector.
5581 (tdesc_create_feature): Create feature.
5582 * tdesc.h (tdesc_feature) Remove
5583 (target_desc): Add features.
5585 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5587 * Makefile.in: Add common/tdesc.c
5588 * tdesc.c (init_target_desc): init all reg_defs from register
5590 (tdesc_create_reg): Create tdesc_reg.
5591 * tdesc.h (tdesc_feature): Add register vector.
5593 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5595 * tdesc.h (struct target_desc) <features>: Change type to
5596 std::vector<std::string>.
5597 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5599 (tdesc_get_features_xml): Likewise.
5600 (tdesc_create_feature): Likewise.
5602 2018-03-26 Alan Hayward <alan.hayward@arm.com>
5604 * regcache.c (find_register_by_number): Return a ref.
5605 (find_regno): Use references.
5606 (register_size): Likewise.
5607 (register_data): Likewise.
5608 * tdesc.c (target_desc::~target_desc): Remove free calls.
5609 (target_desc::operator==): Use std::vector compare.
5610 (init_target_desc): Use reference.
5611 (tdesc_create_reg): Use reg constructors.
5612 * tdesc.h (struct target_desc): Replace pointer with object.
5614 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5616 * regcache.c (find_register_by_number): Make static.
5617 (find_regno): Use find_register_by_number
5618 * regcache.h (struct reg): Remove declaration.
5620 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5622 * tdesc.c (target_desc::~target_desc): Move to here.
5623 (target_desc::operator==): Likewise.
5624 * tdesc.h (target_desc::~target_desc): Move from here.
5625 (target_desc::operator==): Likewise.
5627 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5629 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5631 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5633 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5635 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5636 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5637 and init_registers_s390_gs_linux64.
5639 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5641 * linux-s390-low.c (s390_fill_gs): Remove function.
5642 (s390_fill_gsbc): Remove function.
5643 (s390_regsets): Set fill functions for the guarded storage regsets
5646 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5648 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5649 the word size. Add comment.
5650 (s390_get_wordsize): New function.
5651 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5652 pswm with it. Instead, use s390_get_wordsize to determine the
5653 word size first and derive the correct tdesc from that directly.
5655 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5657 * Makefile.in: Include silent-rules.mk.
5658 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5659 (COMPILE): Add ECHO_CXX.
5660 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5661 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5662 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5663 (version-generated.c): Add ECHO_GEN.
5664 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5665 (IPAGENT_COMPILE): Add ECHO_CXX.
5666 (%-generated.c): Add ECHO_REGDAT.
5668 2018-03-14 Tom Tromey <tom@tromey.com>
5671 * ax.c (ax_printf): Special case for NULL.
5673 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5675 * linux-low.c (linux_qxfer_libraries_svr4): Use
5676 xml_escape_text_append.
5678 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5680 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5682 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5684 * server.c (handle_general_set): Remove unnecessary xstrdup.
5686 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5688 * server.c (parse_debug_format_options): Adjust to
5689 delim_string_to_char_ptr_vec changes.
5690 * thread-db.c (thread_db_load_search): Adjust to
5691 dirnames_to_char_ptr_vec changes.
5693 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5695 * target.h (target_enable_btrace, target_disable_btrace)
5696 (target_read_btrace, target_read_btrace_conf): Turn macro into
5697 inline function. Throw error if target method is not defined.
5698 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5699 check for btrace target method. Be prepared to handle exceptions
5700 from btrace target methods.
5702 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5704 * server.c (captured_main): Change order of error message printed
5705 when the current working directory cannot be found.
5707 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5709 * server.c: Include "filenames.h" and "pathstuff.h".
5710 (program_name): Delete variable.
5711 (program_path): New anonymous class.
5712 (get_exec_wrapper): Use "program_path" instead of
5714 (handle_v_run): Likewise.
5715 (captured_main): Likewise.
5716 (process_serial_event): Likewise.
5718 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5720 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5721 (OBJS): Add "pathstuff.o".
5722 * server.c (current_directory): New global variable.
5723 (captured_main): Initialize "current_directory".
5725 2018-02-26 Alan Hayward <alan.hayward@arm.com>
5727 * tdesc.c: Use common/tdesc.h.
5728 * tdesc.h: Likewise.
5730 2018-02-20 Alan Hayward <alan.hayward@arm.com>
5731 Simon Marchi <simon.marchi@ericsson.com>
5733 * Makefile.in: Switch order of make rules.
5735 2018-02-19 Alan Hayward <alan.hayward@arm.com>
5737 * Makefile.in: Add common directory in build.
5738 * configure.ac: Add common reference.
5739 * configure: Regenerate.
5741 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5743 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5744 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5745 * spu-low.c (spu_target_ops): Likewise.
5746 * win32-low.c (win32_target_ops): Likewise.
5747 * server.c (supported_btrace_packets): Report packets unconditionally.
5748 * target.h (target_ops) <supports_btrace>: Remove.
5749 (target_supports_btrace): Remove.
5751 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5753 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5754 (handle_btrace_disable): Change return type to void. Use exceptions
5756 (handle_btrace_general_set): Catch exception and copy message to
5759 2018-02-08 Tom Tromey <tom@tromey.com>
5761 * linux-low.c (install_software_single_step_breakpoints): Use
5762 make_scoped_restore.
5763 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5764 (do_restore_current_thread_cleanup): Remove.
5765 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5768 2018-02-08 Tom Tromey <tom@tromey.com>
5770 * mem-break.c (set_raw_breakpoint_at): Use
5771 gdb::unique_xmalloc_ptr.
5773 2018-01-30 Pedro Alves <palves@redhat.com>
5776 * target.c (target_terminal::terminal_state): Rename to ...
5777 (target_terminal::m_terminal_state): ... this.
5779 2018-01-19 James Clarke <jrtc27@jrtc27.com>
5781 * linux-low.c (handle_extended_wait): Surround call to
5782 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5784 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5786 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5787 linux_ptrace_attach_fail_reason_string now returning an
5789 (linux_attach): Likewise.
5790 * thread-db.c (attach_thread): Likewise.
5792 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5795 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5796 checking for fs_base/gs_base fields in struct user_regs_struct.
5797 * configure: Regenerate.
5799 2018-01-16 Yao Qi <yao.qi@linaro.org>
5802 * linux-low.c (fetch_register): Call supply_register instead of
5805 2018-01-08 Yao Qi <yao.qi@linaro.org>
5806 Simon Marchi <simon.marchi@ericsson.com>
5808 * Makefile.in (OBS): Remove selftest.o.
5809 * configure.ac: Set srv_selftest_objs if $development is true.
5810 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5811 * configure: Re-generated.
5812 * server.c (captured_main): Wrap variable selftest_filter with
5815 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5817 * server.c (parse_debug_format_options): Return std::string.
5818 (handle_monitor_command, captured_main): Adjust.
5820 2018-01-05 Pedro Alves <palves@redhat.com>
5823 * server.c (captured_main): Pass quiet=false to
5824 save_original_signals_state.
5826 2018-01-01 Joel Brobecker <brobecker@adacore.com>
5828 * gdbreplay.c (gdbreplay_version): Update copyright year in
5830 * server.c (gdbserver_version): Likewise.
5832 2017-12-08 Tom Tromey <tom@tromey.com>
5834 * ax.c (ax_printf): Update.
5836 2017-12-07 Yao Qi <yao.qi@linaro.org>
5838 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5839 aarch64_linux_read_description.
5840 * linux-amd64-ipa.c (idx2mask): New array.
5841 (get_ipa_tdesc): Move idx2mask out.
5842 (initialize_low_tracepoint): Initialize target descriptions.
5843 * linux-i386-ipa.c (idx2mask): New array.
5844 (get_ipa_tdesc): Move idx2mask out.
5845 (initialize_low_tracepoint): Initialize target descriptions.
5847 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5849 * tdesc.c (struct tdesc_type): Change return type.
5850 (tdesc_add_flag): Change parameter type.
5851 (tdesc_add_bitfield): Likewise.
5852 (tdesc_add_field): Likewise.
5853 (tdesc_set_struct_size): Likewise.
5855 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5857 * regcache.c (registers_to_string): Remove unused variable.
5859 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5861 * inferiors.c (for_each_inferior_with_data): Remove.
5862 * inferiors.h (for_each_inferior_with_data): Remove.
5863 * server.c (handle_qxfer_threads_worker): Change parameter type.
5864 (handle_qxfer_threads_proper): Use for_each_thread.
5866 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5868 * inferiors.c (for_each_inferior): Remove.
5869 (clear_inferiors): Use for_each_thread.
5870 * inferiors.h (for_each_inferior): Remove.
5871 * linux-low.c (linux_wait_for_event_filtered): Use
5873 (linux_stabilize_threads): Likewise.
5874 * regcache.c (regcache_release): Likewise.
5875 * server.c (gdb_wants_all_threads_stopped): Likewise.
5876 (clear_pending_status_callback): Remove.
5877 (handle_status): Use for_each_thread.
5878 (captured_main): Likewise.
5879 * win32-low.c (child_init_thread_list): Likewise.
5880 (win32_clear_inferiors): Likewise.
5881 (fake_breakpoint_event): Likewise.
5883 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5885 * inferiors.h (find_inferior): Remove.
5886 * inferiors.c (find_inferior): Remove.
5888 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5890 * linux-low.c (resume_status_pending_p): Update comment.
5891 (need_step_over_p): Update comment.
5893 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5895 * linux-low.c (proceed_one_lwp): Return void, change parameter
5897 (unsuspend_and_proceed_one_lwp): Likewise.
5898 (proceed_all_lwps): Use for_each_thread.
5899 (unstop_all_lwps): Likewise.
5901 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5903 * linux-low.c (linux_resume_one_thread): Return void, take
5905 (linux_resume): Use for_each_thread.
5907 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5909 * linux-low.c (send_sigstop_callback): Return void, change
5910 parameter type. Rename to...
5911 (send_sigstop): ... this.
5912 (suspend_and_send_sigstop_callback): Return void, change parameter
5914 (suspend_and_send_sigstop): ... this.
5915 (stop_all_lwps): Use for_each_thread.
5917 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5919 * linux-low.c (lwp_running): Return bool, remove unused
5921 (linux_stabilize_threads): Use find_thread.
5923 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5925 * linux-low.c (select_singlestep_lwp_callback): Remove.
5926 (count_events_callback): Remove.
5927 (select_event_lwp_callback): Remove.
5928 (select_event_lwp): Use find_thread/for_each_thread.
5930 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5932 * linux-low.c (not_stopped_callback): Return bool, take filter
5934 (linux_wait_for_event_filtered): Use find_thread.
5935 (linux_wait_1): Likewise.
5937 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5939 * linux-low.c (same_lwp): Remove.
5940 (find_lwp_pid): Use find_thread.
5942 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5944 * linux-low.c (delete_lwp_callback): Remove.
5945 (linux_mourn): Use for_each_thread.
5947 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5949 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5950 args parameter, don't check for pid.
5951 (linux_detach): Use for_each_thread.
5953 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5955 * linux-low.c (struct counter): Remove.
5956 (second_thread_of_pid_p): Remove.
5957 (last_thread_of_process_p): Use find_thread.
5959 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5961 * inferiors.c (find_inferior_in_random): Remove.
5962 * inferiors.h (find_inferior_in_random): Remove.
5963 * linux-low.c (status_pending_p_callback): Return bool, accept
5964 parameter ptid directly.
5965 (linux_wait_for_event_filtered): Use find_thread_in_random.
5966 (linux_wait_1): Likewise.
5968 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5970 * inferiors.c (find_inferior_id): Remove.
5971 (find_thread_ptid): Move implemention from find_inferior_id to
5973 * inferiors.h (find_inferior_id): Remove.
5974 * server.c (handle_status): Use find_thread_ptid.
5975 (process_serial_event): Likewise.
5976 * thread-db.c (find_one_thread): Likewise.
5977 (thread_db_thread_handle): Likewise.
5978 * win32-low.c (thread_rec): Likewise.
5979 (child_delete_thread): Likewise.
5980 (win32_thread_alive): Likewise.
5981 (get_child_debug_event): Likewise.
5983 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5985 * linux-mips-low.c (update_watch_registers_callback): Return
5986 void, remove pid_p parameter, don't check for pid.
5987 (mips_insert_point, mips_remove_point): Use for_each_thread.
5989 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5991 * lynx.low (lynx_delete_thread_callback): Remove.
5992 (lynx_mourn): Use for_each_thread.
5994 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5996 * regcache.c (regcache_invalidate_one): Remove.
5997 (regcache_invalidate_pid): use for_each_thread.
5999 2017-11-26 Tom Tromey <tom@tromey.com>
6001 * linux-low.c (linux_create_inferior): Update.
6003 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6005 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6007 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6009 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6010 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6011 * linux-aarch64-tdesc-selftest.c: New file.
6012 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6014 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6016 * configure.srv: Add new file.
6017 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6018 * linux-aarch64-tdesc-selftest.c: New file.
6019 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6021 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6023 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6024 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6025 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6027 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6029 * configure.srv: Add new files.
6030 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6031 aarch64_linux_read_description.
6032 * linux-aarch64-low.c (aarch64_linux_read_description):
6033 Merge with aarch64_arch_setup.
6034 (aarch64_arch_setup): Call aarch64_linux_read_description.
6035 * linux-aarch64-tdesc.c: New file.
6036 * linux-aarch64-tdesc.h: New file.
6038 2017-11-24 Yao Qi <yao.qi@linaro.org>
6040 * configure.srv: Set $srv_regobj for tic6x-linux.
6041 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6042 (tic6x_read_description): Move some code to tic6x_arch_setup.
6043 (tic6x_tdesc_test): New function.
6044 (initialize_low_arch): Call selftests::register_test.
6046 2017-11-22 Yao Qi <yao.qi@linaro.org>
6048 * remote-utils.c (prepare_resume_reply): Use memcpy.
6050 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6052 * linux-low.c (kill_one_lwp_callback): Return void, take
6053 argument directly, don't filter on pid.
6054 (linux_kill): Use for_each_thread.
6056 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6058 * linux-low.c (need_step_over_p): Return bool, remove dummy
6060 (linux_resume, proceed_all_lwps): Use find_thread.
6062 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6064 * linux-low.c (resume_status_pending_p): Return bool, remove
6066 (linux_resume): Use find_thread.
6068 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6070 * linux-low.c (struct thread_resume_array): Remove.
6071 (linux_set_resume_request): Return void, take arguments
6073 (linux_resume): Use for_each_thread.
6075 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6077 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6078 return bool, remove data argument.
6079 (linux_stabilize_threads): Use find_thread.
6081 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6083 * linux-low.c (unsuspend_one_lwp): Remove.
6084 (unsuspend_all_lwps): Use for_each_thread, inline code from
6087 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6089 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6090 * linux-low.c (struct iterate_over_lwps_args): Remove.
6091 (iterate_over_lwps_filter): Remove.
6092 (iterate_over_lwps): Use find_thread.
6094 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6096 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6097 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6098 code from reset_lwp_ptrace_options_callback.
6100 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6102 * linux-arm-low.c (struct update_registers_data): Remove.
6103 (update_registers_callback): Return void, take arguments
6104 directly, don't check thread's pid.
6105 (arm_insert_point, arm_remove_point): Use for_each_thread.
6107 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6109 * win32-low.c (continue_one_thread): Return void, take argument
6111 (child_continue): Use for_each_thread.
6113 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6115 * win32-i386-low.c (update_debug_registers_callback): Rename
6117 (update_debug_registers): ... this, return void, remove pid_p arg.
6118 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6120 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6122 * inferiors.h (struct process_info): Add constructor, initialize
6124 <syscalls_to_catch>: Change type to std::vector<int>.
6125 * inferiors.c (add_process): Allocate process_info with new.
6126 (remove_process): Free process_info with delete.
6127 * linux-low.c (handle_extended_wait): Adjust.
6128 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6129 * server.c (handle_general_set): Adjust.
6131 2017-11-16 Pedro Alves <palves@redhat.com>
6133 * remote-utils.c (remote_close): Block SIGIO signals instead of
6134 uninstalling the SIGIO handler.
6136 2017-11-16 Alan Hayward <alan.hayward@arm.com>
6138 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6140 2017-11-16 Yao Qi <yao.qi@linaro.org>
6142 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6143 (tic6x_store_gregset): Likewise.
6144 (tic6x_usrregs_info): Move it up.
6146 2017-11-15 Alan Hayward <alan.hayward@arm.com>
6148 * Makefile.in: Update arch rules.
6149 * configure.srv: Explicitly mark arch/ files.
6151 2017-11-13 Andreas Schwab <schwab@suse.de>
6153 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6155 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6157 2017-11-06 Pedro Alves <palves@redhat.com>
6159 * config.in, configure: Regenerate.
6161 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6163 * target.c (struct thread_search): Remove.
6164 (thread_search_callback): Remove.
6165 (prepare_to_access_memory): Use for_each_thread instead of
6166 find_inferior. Inline code from thread_search_callback.
6168 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6170 * server.c (struct visit_actioned_threads_data): Remove.
6171 (visit_actioned_threads): Change prototype to take arguments
6173 (resume): Use find_thread instead of find_inferior.
6175 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6177 * server.c (queue_stop_reply_callback): Change prototype, return
6179 (find_status_pending_thread_callback): Remove.
6180 (handle_status): Replace find_inferior with find_thread and
6183 2017-10-25 Alan Hayward <alan.hayward@arm.com>
6185 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6187 (aarch64_store_gregset): Likewise.
6188 (aarch64_fill_fpregset): Likewise.
6189 (aarch64_store_fpregset): Likewise.
6191 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6193 * gdbthread.h (find_thread, for_each_thread): New functions.
6194 * inferiors.c (thread_of_pid): Remove.
6195 (find_any_thread_of_pid): Use find_thread.
6196 * linux-low.c (num_lwps): Use for_each_thread.
6198 2017-10-17 Yao Qi <yao.qi@linaro.org>
6200 * Makefile.in: Remove one rule.
6201 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6203 2017-10-17 Yao Qi <yao.qi@linaro.org>
6205 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6206 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6208 2017-10-17 Yao Qi <yao.qi@linaro.org>
6210 * configure.srv: Rename arm.o with arch/arm.o.
6212 2017-10-17 Yao Qi <yao.qi@linaro.org>
6214 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6215 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6216 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6217 (arch-i386.o, arch-amd64.o): Remove rules.
6218 (arch/%.o): New rule.
6219 Update POSTCOMPILE and COMPILE.pre.
6220 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6221 * configure: Re-generated.
6222 * configure.srv: Replace arch-i386.o with arch/i386.o.
6223 Replace arch-amd64.o with arch/amd64.o.
6225 2017-10-16 Yao Qi <yao.qi@linaro.org>
6227 * configure: Regenerated.
6229 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6231 * inferiors.h: (struct inferior_list): Remove.
6232 (struct inferior_list_entry); Remove.
6233 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6234 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6235 get_first_inferior): Remove.
6236 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6237 find_inferior_id, find_inferior_in_random): Change signature.
6238 * inferiors.c (all_threads): Change type to
6239 std::list<thread_info *>.
6240 (get_thread): Remove macro.
6241 (find_inferior, find_inferior_id): Change signature, implement
6243 (find_inferior_in_random): Change signature, implement using
6244 find_thread_in_random.
6245 (for_each_inferior, for_each_inferior_with_data): Change
6246 signature, implement using for_each_thread.
6247 (add_inferior_to_list, remove_inferior): Remove.
6248 (add_thread, get_first_thread, thread_of_pid,
6249 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6250 (get_first_inferior, one_inferior_p, clear_inferior_list):
6252 (clear_inferiors, get_thread_process): Update.
6253 * gdbthread.h: Include <list>.
6254 (struct thread_info) <entry>: Remove field.
6256 (all_threads): Change type to std::list<thread_info *>.
6257 (get_first_inferior): Add doc.
6258 (find_thread, for_each_thread, find_thread_in_random): New
6260 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6261 * linux-arm-low.c (update_registers_callback): Update.
6262 * linux-low.c (second_thread_of_pid_p): Update.
6263 (kill_one_lwp_callback, linux_detach_lwp_callback,
6264 delete_lwp_callback, status_pending_p_callback, same_lwp,
6265 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6266 iterate_over_lwps, not_stopped_callback,
6267 resume_stopped_resumed_lwps, count_events_callback,
6268 select_singlestep_lwp_callback, select_event_lwp_callback,
6269 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6270 suspend_and_send_sigstop_callback, wait_for_sigstop,
6271 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6272 lwp_running, linux_set_resume_request, resume_status_pending_p,
6273 need_step_over_p, start_step_over, linux_resume_one_thread,
6274 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6275 reset_lwp_ptrace_options_callback): Update.
6276 * linux-mips-low.c (update_watch_registers_callback): Update.
6277 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6279 (free_register_cache_thread_one): Remove.
6280 (regcache_release): Update.
6281 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6282 handle_qxfer_threads_worker): Update.
6283 (handle_query): Update, use list iterator.
6284 (visit_actioned_threads, handle_pending_status,
6285 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6286 clear_pending_status_callback, set_pending_status_callback,
6287 find_status_pending_thread_callback, handle_status,
6288 process_serial_event): Update.
6289 * target.c (thread_search_callback): Update.
6290 * thread-db.c (thread_db_get_tls_address): Update.
6291 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6293 * win32-i386-low.c (update_debug_registers_callback): Update.
6294 * win32-low.c (delete_thread_info, child_delete_thread,
6295 continue_one_thread, suspend_one_thread,
6296 get_child_debug_event): Adjust.
6298 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6300 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6301 * inferiors.h: Include <list>.
6302 (struct process_info) <entry>: Remove field.
6304 (pid_of): Change macro to function.
6305 (ptid_of, lwpid_of): Remove macro.
6306 (all_processes): Change type to std::list<process_info *>.
6307 (ALL_PROCESSES): Remove macro.
6308 (for_each_process, find_process): New function.
6309 * inferiors.c (all_processes): Change type to
6310 std::list<process_info *>.
6311 (find_thread_process): Adjust.
6312 (add_process): Likewise.
6313 (remove_process): Likewise.
6314 (find_process_pid): Likewise.
6315 (get_first_process): Likewise.
6316 (started_inferior_callback): Remove.
6317 (have_started_inferiors_p): Adjust.
6318 (attached_inferior_callback): Remove.
6319 (have_attached_inferiors_p): Adjust.
6320 * linux-low.c (check_zombie_leaders): Likewise.
6321 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6322 (x86_linux_update_xmltarget): Adjust.
6323 * server.c (handle_query): Likewise.
6324 (gdb_reattached_process): Remove.
6325 (handle_status): Adjust.
6326 (kill_inferior_callback): Likewise.
6327 (detach_or_kill_inferior): Remove.
6328 (print_started_pid): Likewise.
6329 (print_attached_pid): Likewise.
6330 (detach_or_kill_for_exit): Update.
6331 (process_serial_event): Likewise.
6332 * linux-arm-low.c (arm_new_fork): Likewise.
6334 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6336 * dll.h: Include <list>.
6337 (struct dll_info): Add constructor.
6338 <entry>: Remove field.
6339 (all_dlls): Change type to std::list<dll_info>.
6340 * dll.c: Include <algorithm>.
6341 (get_dll): Remove macro.
6342 (all_dlls): Change type to std::list<dll_info *>.
6343 (free_one_dll): Remove.
6344 (match_dll): Likewise.
6345 (loaded_dll): Adjust.
6346 (unloaded_dll): Adjust to all_dlls type change, use
6347 std::find_if. Inline code from match_dll.
6348 (clear_dlls): Adjust to all_dlls type change.
6349 * server.c (emit_dll_description): Remove.
6350 (handle_qxfer_libraries): Adjust to all_dlls type change,
6351 integrate emit_dll_description's functionality.
6353 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6355 * linux-low.h (struct linux_target_ops) <delete_process>: New
6357 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6358 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6359 (struct linux_target_ops): Add delete_process callback.
6360 * linux-arm-low.c (arm_delete_process): New.
6361 (struct linux_target_ops): Add delete_process callback.
6362 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6363 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6364 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6365 * linux-mips-low.c (mips_linux_delete_process): New.
6366 (struct linux_target_ops): Add delete_process callback.
6367 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6368 * linux-s390-low.c (struct linux_target_ops): Likewise.
6369 * linux-sh-low.c (struct linux_target_ops): Likewise.
6370 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6371 * linux-tile-low.c (struct linux_target_ops): Likewise.
6372 * linux-x86-low.c (x86_linux_delete_process): New.
6373 (struct linux_target_ops): Add delete_process callback.
6374 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6376 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6378 * linux-aarch64-low.c (the_low_target): Add thread delete
6380 * linux-arm-low.c (arm_delete_thread): New function.
6381 (the_low_target): Add thread delete callback.
6382 * linux-bfin-low.c (the_low_target): Likewise.
6383 * linux-crisv32-low.c (the_low_target): Likewise.
6384 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6386 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6388 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6389 * linux-mips-low.c (mips_linux_delete_thread): New function.
6390 (the_low_target): Add thread delete callback.
6391 * linux-ppc-low.c (the_low_target): Likewise.
6392 * linux-s390-low.c (the_low_target): Likewise.
6393 * linux-sh-low.c (the_low_target): Likewise.
6394 * linux-tic6x-low.c (the_low_target): Likewise.
6395 * linux-tile-low.c (the_low_target): Likewise.
6396 * linux-x86-low.c (the_low_target): Likewise.
6397 * linux-xtensa-low.c (the_low_target): Likewise.
6399 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6401 * win32-low.c: Include "common-inferior.h".
6403 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6405 * inferiors.c (set_inferior_cwd): New function.
6406 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6407 (handle_query): Inform that QSetWorkingDir is supported.
6408 * win32-low.c (create_process): Pass the inferior's cwd to
6411 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6413 * inferiors.c (current_inferior_cwd): New global variable.
6414 (get_inferior_cwd): New function.
6415 * inferiors.h (struct process_info) <cwd>: New field.
6417 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6419 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6420 (OBS): Add gdb_tilde_expand.o.
6422 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6424 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6425 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6427 2017-09-29 Pedro Alves <palves@redhat.com>
6429 * ax.c (gdb_parse_agent_expr): Constify.
6430 * ax.h (gdb_parse_agent_expr): Constify.
6431 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6433 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6434 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6435 * remote-utils.h (read_ptid): Constify.
6436 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6437 (process_point_options, process_serial_event): Constify.
6438 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6439 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6440 (cmd_qtbuffer): Constify.
6442 2017-09-29 Pedro Alves <palves@redhat.com>
6444 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6447 2017-09-29 Pedro Alves <palves@redhat.com>
6449 * linux-low.c (handle_extended_wait): Pass parent thread instead
6450 of process to thread_db_notice_clone.
6451 * linux-low.h (thread_db_notice_clone): Replace parent process
6452 parameter with parent thread parameter.
6453 * thread-db.c (find_one_thread): Add comment.
6454 (thread_db_notice_clone): Replace parent process parameter with
6455 parent thread parameter. Temporarily switch to the parent thread.
6457 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6459 * gdbthread.h: Include "common-gdbthread.h".
6460 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6461 "if" when validating the ptid.
6462 * remote-utils.c: Include "gdbthread.h".
6463 (prepare_resume_reply): Use "switch_to_thread".
6464 * target.c (done_accessing_memory): Likewise.
6466 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6468 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6469 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6470 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6471 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6472 s390x-gs-linux64-ipa.o to ipa_obj.
6473 * linux-s390-low.c (HWCAP_S390_GS): New define.
6474 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6476 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6477 (s390_arch_setup): Check for guarded-storage support and choose
6479 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6480 init_registers_s390x_gs_linux64.
6481 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6483 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6484 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6486 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6488 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6490 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6492 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6493 (thread_db_thread_handle): Declare.
6494 * linux-low.c (linux_target_ops): Initialize thread_handle.
6495 * server.c (handle_qxfer_threads_worker): Add support for
6497 * target.h (struct target_ops): Add new function pointer,
6499 (target_thread_handle): Define.
6500 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6502 (thread_db_thread_handle): New function.
6504 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6506 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6507 * linux-low.h (thread_db_notice_clone): Declare.
6508 * thread-db.c (thread_db_notice_clone): New function.
6510 2017-09-21 Pedro Alves <palves@redhat.com>
6512 * server.c (gdb_read_memory, handle_status, process_serial_event)
6513 (handle_serial_event, handle_target_event): Adjust to
6514 set_desired_thread prototype change.
6515 * target.c (set_desired_thread): Remove 'use_general' parameter
6517 * target.h (set_desired_thread): Remove 'use_general' parameter.
6519 2017-09-20 Tom Tromey <tom@tromey.com>
6521 * target.c (target_terminal::terminal_state): Define.
6522 (target_terminal::init): Rename from target_terminal_init.
6523 (target_terminal::inferior): Rename from
6524 target_terminal_inferior.
6525 (target_terminal::ours): Rename from target_terminal_ours.
6526 (target_terminal::ours_for_output, target_terminal::info): New.
6528 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6530 * server.c (accumulate_file_name_length): Remove.
6531 (emit_dll_description): Adjust to std::string change.
6532 (handle_qxfer_libraries): Use std::string to hold document.
6534 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6536 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6537 return type of xml_escape_text.
6538 * server.c (emit_dll_description): Likewise.
6540 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6542 * server.c (captured_main): Accept argument for --selftest.
6543 Update run_tests call.
6544 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6545 when registering selftests.
6547 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6549 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6550 instead of "VEC" for "target_desc.reg_defs".
6551 (regcache_cpy): Likewise.
6552 (registers_to_string): Likewise.
6553 (registers_from_string): Likewise.
6554 (find_regno): Likewise.
6555 (supply_regblock): Likewise.
6556 (regcache_raw_read_unsigned): Likewise.
6557 * tdesc.c (init_target_desc): Likewise.
6558 (tdesc_create_reg): Likewise.
6559 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6560 (struct target_desc) <reg_defs>: Convert to "std::vector".
6561 (target_desc): Do not initialize "reg_defs".
6562 (~target_desc): Update code to use "std::vector" instead of "VEC"
6563 for "target_desc.reg_defs".
6564 (operator==): Likewise.
6566 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6568 * inferiors.h (thread_to_gdb_id): Remove.
6569 * inferiors.c (thread_to_gdb_id): Remove.
6570 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6571 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6572 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6574 * nto-low.c (nto_fetch_registers, nto_store_registers,
6575 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6577 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6579 * inferiors.h (gdb_id_to_thread_id): Remove.
6580 * inferiors.c (gdb_id_to_thread_id): Remove.
6581 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6582 removal. Move pid declaration closer to where it's used.
6584 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6586 * server.c (handle_detach): New function.
6587 (process_serial_event): Move code out, call handle_detach.
6589 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6591 * server.c (require_running): Rename to ...
6592 (require_running_or_return): ... this ...
6593 (require_running_or_break): ... and this.
6594 (handle_query, process_serial_event): Adjust.
6596 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6598 * linux-low.c (linux_set_resume_request): Remove unused
6601 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6603 * server.c (first_thread_of): Remove.
6604 (process_serial_event): Replace usage of first_thread_of with
6605 find_any_thread_of_pid.
6606 * tracepoint.c (same_process_p): Remove.
6607 (gdb_agent_about_to_close): Replace usage of same_process_p with
6608 find_any_thread_of_pid.
6609 * linux-x86-low.c (same_process_callback): Remove.
6610 (x86_arch_setup_process_callback): Replace usage of
6611 same_process_callback with find_any_thread_of_pid.
6612 * thread-db.c (any_thread_of): Remove.
6613 (switch_to_process): Replace usage of any_thread_of with
6614 find_any_thread_of_pid.
6615 * inferiors.c (thread_pid_matches_callback): Remove.
6616 (find_thread_process): Adjust to use find_any_thread_of_pid.
6618 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6620 * regcache.c (get_thread_regcache): Guard calls to "memset"
6623 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6625 * linux-low.c (handle_extended_wait): Use
6626 "allocate_target_description" instead of "XNEW".
6627 * linux-x86-low.c (initialize_low_arch): Likewise.
6629 2017-09-05 Yao Qi <yao.qi@linaro.org>
6631 * configure.srv (srv_i386_regobj): Remove.
6632 (srv_amd64_regobj): Remove.
6633 (srv_regobj): Set it to "" for x86 non-linux targets.
6634 * linux-x86-tdesc.c (i386_linux_read_description):
6635 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6636 (init_registers_i386): Remove the declaration.
6637 (tdesc_i386): Remove the declaration.
6638 (lynx_i386_arch_setup): Call i386_create_target_description.
6639 * nto-x86-low.c: Likewise.
6640 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6641 [!__x86_64__]: include arch/i386.h.
6642 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6644 2017-09-05 Yao Qi <yao.qi@linaro.org>
6646 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6647 i386/amd64-XXX-linux from it.
6649 2017-09-05 Yao Qi <yao.qi@linaro.org>
6651 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6653 (ipa_amd64_linux_regobj): Remove.
6654 (ipa_x32_linux_regobj): Remove.
6656 2017-09-05 Yao Qi <yao.qi@linaro.org>
6658 * Makefile.in (arch-amd64.o): New rule.
6659 * configure.srv: Append arch-amd64.o.
6660 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6661 (get_ipa_tdesc): Call amd64_linux_read_description.
6662 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6663 and init_registers_amd64_XXX.
6664 * linux-x86-low.c (x86_linux_read_description): Call
6665 amd64_linux_read_description.
6666 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6667 (initialize_low_arch): Don't call init_registers_x32_XXX and
6668 init_registers_amd64_XXX.
6669 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6670 and tdesc_amd64_XXX.
6671 [__x86_64__] (amd64_tdesc_test): New function.
6672 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6673 and init_registers_amd64_XXX.
6674 * linux-x86-tdesc.c: Include arch/amd64.h.
6675 (xcr0_to_tdesc_idx): New function.
6676 (i386_linux_read_description): New function.
6677 (amd64_get_ipa_tdesc_idx): New function.
6678 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6679 (amd64_get_ipa_tdesc): Declare.
6681 2017-09-05 Yao Qi <yao.qi@linaro.org>
6683 * configure.srv (srv_i386_linux_xmlfiles): Remove
6684 i386/i386-XXX-linux.xml from it.
6686 2017-09-05 Yao Qi <yao.qi@linaro.org>
6688 * configure.srv: Set srv_i386_linux_regobj empty if $development
6690 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6691 initialize_low_tdesc.
6692 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6693 with #if initialize_low_tdesc.
6694 * linux-x86-tdesc-selftest.c: New file.
6695 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6697 2017-09-05 Yao Qi <yao.qi@linaro.org>
6699 * Makefile.in (arch-i386.o): New rule.
6700 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6701 (x86_64-*-linux*): Likewise.
6702 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6703 include arch/i386.h.
6704 (i386_linux_read_description): Remove code and call
6705 i386_create_target_description.
6706 * tdesc.c (allocate_target_description): New function.
6707 * tdesc.h (set_tdesc_architecture): Remove declaration.
6708 (set_tdesc_osabi): Likewise.
6710 2017-09-05 Yao Qi <yao.qi@linaro.org>
6712 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6713 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6714 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6716 * server.c (get_features_xml): Call tdesc_get_features_xml.
6717 * tdesc.c (set_tdesc_architecture): New function.
6718 (set_tdesc_osabi): New function.
6719 (tdesc_get_features_xml): New function.
6720 (tdesc_create_feature): Add an argument.
6721 * tdesc.h (struct target_desc) <features>: New field.
6722 <arch, osabi>: New field.
6723 (~target_desc): xfree features, arch, and osabi.
6724 (target_desc::oerator==): Don't compare .xmltarget.
6725 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6726 (set_tdesc_osabi): Likewise.
6727 (tdesc_get_features_xml): Likewise.
6729 2017-09-05 Yao Qi <yao.qi@linaro.org>
6731 * linux-x86-tdesc.c: Include selftest.h.
6732 (i386_tdesc_test): New function.
6733 (initialize_low_tdesc): Call selftests::register_test.
6734 * tdesc.h: Include regdef.h.
6735 (target_desc): Override operator == and !=.
6737 2017-09-05 Yao Qi <yao.qi@linaro.org>
6739 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6740 (ipa_obj): Likewise.
6741 * linux-i386-ipa.c: Include common/x86-xstate.h
6742 (get_ipa_tdesc): Call i386_linux_read_description.
6743 (initialize_low_tracepoint): Don't call init_registers_XXX
6744 functions, call initialize_low_tdesc instead.
6745 * linux-x86-low.c (x86_linux_read_description): Call
6746 i386_linux_read_description.
6747 (initialize_low_arch): Don't call init_registers_i386_XXX
6748 functions, call initialize_low_tdesc.
6749 * linux-x86-tdesc.c: New file.
6750 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6751 (i386_get_ipa_tdesc_idx): Declare.
6752 (i386_get_ipa_tdesc): Declare.
6753 (initialize_low_tdesc): Declare.
6755 2017-09-05 Yao Qi <yao.qi@linaro.org>
6757 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6760 2017-09-05 Yao Qi <yao.qi@linaro.org>
6762 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6763 * regcache.c (get_thread_regcache): Use VEC_length.
6764 (init_register_cache): Likewise.
6765 (regcache_cpy): Likewise.
6766 (registers_to_string): Iterate reg_defs via VEC_iterate.
6767 (find_regno): Likewise.
6768 (find_register_by_number): Use VEC_index.
6769 (register_size): Call find_register_by_number.
6770 (register_data): Call find_register_by_number.
6771 (supply_regblock): Use VEC_length.
6772 (regcache_raw_read_unsigned): Likewise.
6773 * tdesc.c (init_target_desc): Iterate reg_defs via
6775 (default_description): Update initializer.
6776 (copy_target_description): Don't update field num_registers.
6777 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6778 <num_registers>: Remove.
6780 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6782 * Makefile.in (.SECONDARY): Define target.
6784 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6786 * linux-low.c (linux_wait_1): Adjust.
6787 * server.c (queue_stop_reply_callback): Adjust.
6789 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6791 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6792 QEnvironmentUnset and QEnvironmentReset packets.
6793 (handle_query): Inform remote that QEnvironmentHexEncoded,
6794 QEnvironmentUnset and QEnvironmentReset are supported.
6796 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6798 * inferiors.h (inferior_target_data): Rename to ...
6799 (thread_target_data): ... this.
6800 (inferior_regcache_data): Rename to ...
6801 (thread_regcache_data): ... this.
6802 (set_inferior_regcache_data): Rename to ...
6803 (set_thread_regcache_data): ... this.
6804 * inferiors.c (inferior_target_data): Rename to ...
6805 (thread_target_data): ... this.
6806 (inferior_regcache_data): Rename to ...
6807 (thread_regcache_data): ... this.
6808 (set_inferior_regcache_data): Rename to ...
6809 (set_thread_regcache_data): ... this.
6810 (free_one_thread): Update.
6811 * linux-low.h (get_thread_lwp): Update.
6812 * regcache.c (get_thread_regcache): Update.
6813 (regcache_invalidate_thread): Update.
6814 (free_register_cache_thread): Update.
6815 * win32-i386-low.c (update_debug_registers_callback): Update.
6816 (win32_get_current_dr): Update.
6817 * win32-low.c (thread_rec): Update.
6818 (delete_thread_info): Update.
6819 (continue_one_thread): Update.
6820 (suspend_one_thread): Update.
6822 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6824 * inferiors.c (set_inferior_target_data): Remove.
6825 * inferiors.h (set_inferior_target_data): Remove.
6827 2017-08-18 Yao Qi <yao.qi@linaro.org>
6829 * Makefile.in (OBS): Add selftest.o.
6830 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6831 * configure, config.in: Re-generated.
6832 * server.c: Include common/sefltest.h.
6833 (captured_main): Handle option --selftest.
6835 2017-08-09 Yao Qi <yao.qi@linaro.org>
6837 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6838 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6839 i386-avx-mpx.o and i386-mmx.o.
6840 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6841 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6842 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6843 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6844 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6845 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6846 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6847 i386/amd64-avx-mpx.xml.
6849 2017-08-09 Yao Qi <yao.qi@linaro.org>
6851 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6852 and x32-avx-avx512.o.
6853 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6854 i386/x32-avx-avx512.xml.
6856 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6858 * tracepoint.h (enum class fast_tpoint_collect_result): New
6860 (fast_tracepoint_collecting): Change return type to
6861 fast_tpoint_collect_result.
6862 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6863 * linux-low.h: Include tracepoint.h.
6864 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6865 fast_tpoint_collect_result.
6866 * linux-low.c (handle_tracepoints): Adjust.
6867 (linux_fast_tracepoint_collecting): Change return type to
6868 fast_tpoint_collect_result.
6869 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6870 linux_wait_1, stuck_in_jump_pad_callback,
6871 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6872 proceed_one_lwp): Adjust to type change.
6874 2017-07-10 Yao Qi <yao.qi@linaro.org>
6876 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6878 2017-06-29 Yao Qi <yao.qi@linaro.org>
6880 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6882 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6884 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6886 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6888 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6890 * linux-low.c (linux_create_inferior): Adjust code to access the
6891 environment information via 'gdb_environ' class.
6892 * lynx-low.c (lynx_create_inferior): Likewise.
6893 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6894 (get_environ): Return a pointer to 'our_environ'.
6895 (captured_main): Initialize 'our_environ'.
6896 * server.h (get_environ): Adjust prototype.
6897 * spu-low.c (spu_create_inferior): Adjust code to access the
6898 environment information via 'gdb_environ' class.
6900 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6902 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6903 usage of "register" keyword.
6905 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6907 * configure: Re-generate.
6909 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6911 * configure: Re-generate.
6913 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6915 * Makefile.in (COMPILE.pre): Add "-x c++".
6917 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6919 * fork-child.c: Conditionally include <signal.h>.
6921 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6923 * server.c (handle_general_set): Handle new packet
6924 "QStartupWithShell".
6925 (handle_query): Add "QStartupWithShell" to the list of supported
6927 (gdbserver_usage): Add help text explaining the
6928 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6930 (captured_main): Recognize and act upon the presence of the new
6933 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6934 Pedro Alves <palves@redhat.com>
6936 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6937 * configure: Regenerate.
6938 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6940 (i[34567]86-*-lynxos*): Likewise.
6941 (spu*-*-*): Likewise.
6942 * fork-child.c: New file.
6943 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6945 (linux_ptrace_fun): New function.
6946 (linux_create_inferior): Adjust function prototype to reflect
6947 change on "target.h". Adjust function code to use
6949 (linux_request_interrupt): Delete "signal_pid".
6950 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6951 (lynx_ptrace_fun): New function.
6952 (lynx_create_inferior): Adjust function prototype to reflect
6953 change on "target.h". Adjust function code to use
6955 * nto-low.c (nto_create_inferior): Adjust function prototype and
6956 code to reflect change on "target.h". Update comments.
6957 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6958 "common-terminal.h" and "environ.h".
6959 (terminal_fd): Moved to fork-child.c.
6960 (old_foreground_pgrp): Likewise.
6961 (restore_old_foreground_pgrp): Likewise.
6962 (last_status): Make it global.
6963 (last_ptid): Likewise.
6964 (our_environ): New variable.
6965 (startup_with_shell): Likewise.
6966 (program_name): Likewise.
6967 (program_argv): Rename to...
6968 (program_args): ...this.
6969 (wrapper_argv): New variable.
6970 (start_inferior): Delete function.
6971 (get_exec_wrapper): New function.
6972 (get_exec_file): Likewise.
6973 (get_environ): Likewise.
6974 (prefork_hook): Likewise.
6975 (post_fork_inferior): Likewise.
6976 (postfork_hook): Likewise.
6977 (postfork_child_hook): Likewise.
6978 (handle_v_run): Update code to deal with arguments coming from the
6979 remote host. Update calls from "start_inferior" to
6981 (captured_main): Likewise. Initialize environment variable. Call
6983 * server.h (post_fork_inferior): New prototype.
6984 (get_environ): Likewise.
6985 (last_status): Declare.
6986 (last_ptid): Likewise.
6987 (signal_pid): Likewise.
6988 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6989 (spu_ptrace_fun): New function.
6990 (spu_create_inferior): Adjust function prototype to reflect change
6991 on "target.h". Adjust function code to use "fork_inferior".
6992 * target.c (target_terminal_init): New function.
6993 (target_terminal_inferior): Likewise.
6994 (target_terminal_ours): Likewise.
6995 * target.h: Include <vector>.
6996 (struct target_ops) <create_inferior>: Update prototype.
6997 (create_inferior): Update macro.
6998 * utils.c (gdb_flush_out_err): New function.
6999 * win32-low.c (win32_create_inferior): Adjust function prototype
7000 and code to reflect change on "target.h".
7002 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7004 * inferiors.c (switch_to_thread): New function.
7006 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7008 * Makefile.in (SFILE): Add "common/job-control.c".
7009 (OBS): Add "job-control.o".
7011 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7013 * Makefile: Remove "@host_makefile_frag@".
7015 2017-05-05 Pedro Alves <palves@redhat.com>
7017 * configure: Regenerate.
7019 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7021 * configure: Regenerate.
7023 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7025 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7026 software_single_step change of return type to
7027 std::vector<CORE_ADDR>.
7028 * linux-low.c (install_software_single_step_breakpoints):
7030 * linux-low.h (install_software_single_step_breakpoints):
7033 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7035 * remote-utils.c: Include "gdb_termios.h" instead of
7037 * terminal.h: Delete file.
7039 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7041 * server.c: Include <vector>.
7042 <program_argv, wrapper_argv>: Convert to std::vector.
7043 (start_inferior): Rewrite function to use C++.
7044 (handle_v_run): Likewise. Update code that calculates the argv
7045 based on the vRun packet; use C++.
7046 (captured_main): Likewise.
7048 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7050 * server.c (handle_v_cont): Initialize thread_resume::thread
7053 2017-04-05 Pedro Alves <palves@redhat.com>
7055 * configure: Regenerate.
7057 2017-04-05 Pedro Alves <palves@redhat.com>
7059 * gdbreplay.c (sync_error): Constify.
7060 * linux-x86-low.c (push_opcode): Constify.
7062 2017-04-05 Pedro Alves <palves@redhat.com>
7064 * win32-low.c (get_child_debug_event)
7065 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7066 Report TARGET_WAITKIND_SPURIOUS instead.
7068 2017-04-05 Pedro Alves <palves@redhat.com>
7070 * remote-utils.c (remote_prepare, remote_open): Constify.
7071 * remote-utils.h (remote_prepare, remote_open): Constify.
7072 * server.c (captured_main): Constify 'port' handling.
7074 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7076 * Makefile.in (clean): Clear .deps.
7078 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7080 * .gitignore: Remove generated files, replace with wildcard.
7081 * (clean): Replace removal of generated files with wildcard.
7082 (version.c): Replace with...
7083 (version-generated.c): ...this.
7084 (xml-builtin.c): Replace with...
7085 (xml-builtin-generated.c): ...this.
7086 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7087 (%.c: *regformats*): Replace with...
7088 (%-generated.c: *regformats*): ...this.
7090 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7092 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7093 (xtensa_fill_gregset): Call collect_register_by_name for
7095 (xtensa_store_gregset): Call supply_register_by_name for
7098 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7100 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7101 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7102 (xtensa_store_gregset): Call supply_register for all registers in
7103 a0_regnum..a0_regnum + C0_NREGS range.
7105 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7107 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7108 (ax-ipa.o: ax.c): Remove.
7109 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7110 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7111 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7112 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7113 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7115 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7117 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7118 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7119 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7120 (errors-ipa.o: ../common/errors.c): Remove.
7121 (format-ipa.o: ../common/format.c): Remove.
7122 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7124 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7126 * Makefile.in (%-ipa.o: %.c): New rule.
7127 (tracepoint-ipa.o: tracepoint.c): Remove.
7128 (utils-ipa.o: utils.c): Remove.
7129 (remote-utils-ipa.o: remote-utils.c): Remove.
7130 (regcache-ipa.o: regcache.c): Remove.
7131 (i386-linux-ipa.o: i386-linux.c): Remove.
7132 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7133 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7134 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7135 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7136 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7137 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7138 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7139 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7140 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7141 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7142 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7143 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7144 (aarch64-ipa.o: aarch64.c): Remove.
7145 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7146 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7147 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7148 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7149 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7150 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7151 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7152 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7153 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7154 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7155 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7156 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7157 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7158 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7159 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7160 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7161 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7162 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7163 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7164 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7165 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7166 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7167 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7168 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7169 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7170 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7171 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7172 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7173 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7174 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7175 (tdesc-ipa.o: tdesc.c): Remove.
7176 (x32-linux-ipa.o: x32-linux.c): Remove.
7177 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7178 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7180 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7182 * Makefile.in (%.o: ../arch/%.c): New rule.
7183 (arm.o: ../arch/arm.c): Remove.
7184 (arm-linux.o: ../arch/arm-linux.c): Remove.
7185 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7186 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7188 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7190 * Makefile.in (%.o: ../nat/%.c): New rule.
7191 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7192 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7193 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7194 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7195 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7196 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7197 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7198 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7199 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7200 (linux-personality.o: ../nat/linux-personality.c): Remove.
7201 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7202 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7203 (x86-linux.o: ../nat/x86-linux.c): Remove.
7204 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7205 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7207 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7209 * Makefile.in (%.o: ../common/%.c): New rule.
7210 (signals.o: ../common/signals.c): Remove.
7211 (print-utils.o: ../common/print-utils.c): Remove.
7212 (rsp-low.o: ../common/rsp-low.c): Remove.
7213 (common-utils.o: ../common/common-utils.c): Remove.
7214 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7215 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7216 (vec.o: ../common/vec.c): Remove.
7217 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7218 (xml-utils.o: ../common/xml-utils.c): Remove.
7219 (ptid.o: ../common/ptid.c): Remove.
7220 (buffer.o: ../common/buffer.c): Remove.
7221 (format.o: ../common/format.c): Remove.
7222 (filestuff.o: ../common/filestuff.c): Remove.
7223 (agent.o: ../common/agent.c): Remove.
7224 (errors.o: ../common/errors.c): Remove.
7225 (environ.o: ../common/environ.c): Remove.
7226 (common-debug.o: ../common/common-debug.c): Remove.
7227 (cleanups.o: ../common/cleanups.c): Remove.
7228 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7229 (fileio.o: ../common/fileio.c): Remove.
7230 (common-regcache.o: ../common/common-regcache.c): Remove.
7231 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7232 (new-op.o: ../common/new-op.c): Remove.
7233 (btrace-common.o: ../common/btrace-common.c): Remove.
7235 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7237 * Makefile.in (%.o: ../target/%.c): New rule.
7238 (waitstatus.o: ../target/waitstatus.c): Remove.
7240 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7243 (%.c: ../regformats/%.dat,
7244 (%.c: ../regformats/arm/%.dat,
7245 (%.c: ../regformats/i386/%.dat,
7246 (%.c: ../regformats/rs6000/%.dat): New rules.
7247 (aarch64.c): Remove.
7248 (reg-arm.c): Remove.
7249 (arm-with-iwmmxt.c): Remove.
7250 (arm-with-vfpv2.c): Remove.
7251 (arm-with-vfpv3.c): Remove.
7252 (arm-with-neon.c): Remove.
7253 (reg-bfin.c): Remove.
7254 (reg-cris.c): Remove.
7255 (reg-crisv32.c): Remove.
7257 (i386-linux.c): Remove.
7258 (i386-avx.c): Remove.
7259 (i386-avx-linux.c): Remove.
7260 (i386-avx-avx512.c): Remove.
7261 (i386-avx-avx512-linux.c): Remove.
7262 (i386-mpx.c): Remove.
7263 (i386-mpx-linux.c): Remove.
7264 (i386-avx-mpx-avx512-pku.c): Remove.
7265 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7266 (i386-avx-mpx.c): Remove.
7267 (i386-avx-mpx-linux.c): Remove.
7268 (i386-mmx.c): Remove.
7269 (i386-mmx-linux.c): Remove.
7270 (reg-ia64.c): Remove.
7271 (reg-m32r.c): Remove.
7272 (reg-m68k.c): Remove.
7274 (mips-linux.c): Remove.
7275 (mips-dsp-linux.c): Remove.
7276 (mips64-linux.c): Remove.
7277 (mips64-dsp-linux.c): Remove.
7278 (nios2-linux.c): Remove.
7279 (powerpc-32.c): Remove.
7280 (powerpc-32l.c): Remove.
7281 (powerpc-altivec32l.c): Remove.
7282 (powerpc-cell32l.c): Remove.
7283 (powerpc-vsx32l.c): Remove.
7284 (powerpc-isa205-32l.c): Remove.
7285 (powerpc-isa205-altivec32l.c): Remove.
7286 (powerpc-isa205-vsx32l.c): Remove.
7287 (powerpc-e500l.c): Remove.
7288 (powerpc-64l.c): Remove.
7289 (powerpc-altivec64l.c): Remove.
7290 (powerpc-cell64l.c): Remove.
7291 (powerpc-vsx64l.c): Remove.
7292 (powerpc-isa205-64l.c): Remove.
7293 (powerpc-isa205-altivec64l.c): Remove.
7294 (powerpc-isa205-vsx64l.c): Remove.
7295 (s390-linux32.c): Remove.
7296 (s390-linux32v1.c): Remove.
7297 (s390-linux32v2.c): Remove.
7298 (s390-linux64.c): Remove.
7299 (s390-linux64v1.c): Remove.
7300 (s390-linux64v2.c): Remove.
7301 (s390-te-linux64.c): Remove.
7302 (s390-vx-linux64.c): Remove.
7303 (s390-tevx-linux64.c): Remove.
7304 (s390x-linux64.c): Remove.
7305 (s390x-linux64v1.c): Remove.
7306 (s390x-linux64v2.c): Remove.
7307 (s390x-te-linux64.c): Remove.
7308 (s390x-vx-linux64.c): Remove.
7309 (s390x-tevx-linux64.c): Remove.
7310 (tic6x-c64xp-linux.c): Remove.
7311 (tic6x-c64x-linux.c): Remove.
7312 (tic6x-c62x-linux.c): Remove.
7314 (reg-sparc64.c): Remove.
7315 (reg-spu.c): Remove.
7317 (amd64-linux.c): Remove.
7318 (amd64-avx.c): Remove.
7319 (amd64-avx-linux.c): Remove.
7320 (amd64-avx-avx512.c): Remove.
7321 (amd64-avx-avx512-linux.c): Remove.
7322 (amd64-mpx.c): Remove.
7323 (amd64-mpx-linux.c): Remove.
7324 (amd64-avx-mpx-avx512-pku.c): Remove.
7325 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7326 (amd64-avx-mpx.c): Remove.
7327 (amd64-avx-mpx-linux.c): Remove.
7329 (x32-linux.c): Remove.
7330 (x32-avx.c): Remove.
7331 (x32-avx-linux.c): Remove.
7332 (x32-avx-avx512.c): Remove.
7333 (x32-avx-avx512-linux.c): Remove.
7334 (reg-xtensa.c): Remove.
7335 (reg-tilegx.c): Remove.
7336 (reg-tilegx32.c): Remove.
7338 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7340 * Makefile.in (SFILES): Add "common/environ.c".
7341 (OBJS): Add "common/environ.h".
7343 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7345 * configure.ac: Check if the fs_base and gs_base members of
7346 `struct user_regs_struct' exist.
7347 * config.in: Regenerated.
7348 * configure: Likewise.
7350 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7352 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7354 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7355 (get_next_pcs_syscall_next_pc): Likewise.
7357 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7359 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7360 * nto-x86-low.c: Likewise.
7362 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7364 * Makefile.in: Include disable-implicit-rules.mk.
7366 2016-11-23 Pedro Alves <palves@redhat.com>
7368 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7369 (debug_vprintf): Use std::chrono::steady_clock instead of
7370 gettimeofday. Use '.' instead of ':'.
7371 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7372 (get_timestamp): Use std::chrono::steady_clock instead of
7375 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7377 * Makefile.in: Fix whitespace formatting.
7379 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7381 * Makefile.in (SFILES, OBS): Flatten list and order
7384 2016-11-23 Pedro Alves <palves@redhat.com>
7386 * event-loop.c (handle_file_event): Use warning.
7387 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7388 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7391 2016-11-23 Pedro Alves <palves@redhat.com>
7393 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7395 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7396 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7397 debug_printf and debug_flush for debug output.
7398 * server.c (handle_general_set): Likewise.
7399 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7402 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7404 * Makefile.in (.c.o): Replace rule with ...
7405 (%.o: %.c): ... this one.
7407 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7409 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7410 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7412 * configure.ac: Remove checks for the make program.
7413 * configure: Re-generate.
7415 2016-10-28 Pedro Alves <palves@redhat.com>
7417 * Makefile.in (CXX_DIALECT): Get from configure.
7418 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7419 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7420 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7421 * config.in: Regenerate.
7422 * configure: Regenerate.
7424 2016-10-27 Yao Qi <yao.qi@linaro.org>
7426 * linux-low.c (linux_supports_range_stepping): Return true if
7427 can_software_single_step return true.
7429 2016-10-27 Yao Qi <yao.qi@linaro.org>
7431 * inferiors.c (find_inferior_in_random): New function.
7432 * inferiors.h (find_inferior_in_random): Declare.
7433 * linux-low.c (linux_wait_for_event_filtered): Call
7434 find_inferior_in_random instead of find_inferior.
7436 2016-10-27 Yao Qi <yao.qi@linaro.org>
7438 * linux-low.c (linux_wait_1): If single-step breakpoints are
7439 inserted, remove them.
7441 2016-10-26 Pedro Alves <palves@redhat.com>
7443 * linux-low.c (handle_extended_wait): Link parent/child fork
7445 (linux_wait_1): Unlink them.
7446 (linux_set_resume_request): Ignore resume requests for
7447 already-resumed and unhandled fork child threads.
7448 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7449 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7451 (handle_v_requests) <vCont>: Don't call require_running.
7452 * server.h (in_queued_stop_replies): New declaration.
7454 2016-10-24 Yao Qi <yao.qi@linaro.org>
7457 * linux-aarch64-low.c (append_insns): Cast the return value to
7460 2016-10-10 Yao Qi <yao.qi@linaro.org>
7462 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7464 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7466 * target.c (target_supports_multi_process): New function, moved
7468 * target.h (target_supports_multi_process): ... here. Remove
7471 2016-10-05 Tom Tromey <tom@tromey.com>
7474 * tracepoint.c (handle_tracepoint_bkpts): Check
7475 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7477 2016-10-05 Yao Qi <yao.qi@linaro.org>
7479 * configure.srv: Update the path of arm-*.xml files.
7481 2016-10-05 Terry Guo <terry.guo@arm.com>
7482 Yao Qi <yao.qi@linaro.org>
7484 * Makefile.in: Adjust the path of rules.
7485 * configure.srv: Update the path of xml files.
7486 * regformats/arm-with-iwmmxt.dat: Regenerated.
7487 * regformats/arm-with-neon.dat: Likewise.
7488 * regformats/arm-with-vfpv2.dat: Likewise.
7489 * regformats/arm-with-vfpv3.dat Likewise.
7491 2016-09-30 Yao Qi <yao.qi@linaro.org>
7494 * target.c (target_stop_and_wait): Don't call
7495 target_continue_no_signal, use resume_stop instead.
7497 2016-09-26 Yao Qi <yao.qi@linaro.org>
7499 * linux-low.c (linux_wait_1): Call debug_exit.
7501 2016-09-23 Pedro Alves <palves@redhat.com>
7503 * Makefile.in (SFILES): Add common/new-op.c.
7504 (OBS): Add common/new-op.o.
7505 (new-op.o): New rule.
7507 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7509 * .gitinore: Ignore more files.
7511 2016-09-21 Yao Qi <yao.qi@linaro.org>
7513 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7516 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7518 * server.c (start_inferior): Call target_mourn_inferior instead of
7519 mourn_inferior; pass ptid_t argument to it.
7521 (handle_target_event): Likewise.
7522 * target.c (target_mourn_inferior): New function.
7523 * target.h (mourn_inferior): Delete macro.
7525 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7527 * linux-low.c (lwp_is_stepping): New function.
7529 2016-09-06 Carl Love <cel@us.ibm.com>
7531 * server.c (start_inferior): Fixed comment, requested comment change
7532 didn't get updated correctly. Removed reference to ptrace () call as
7533 it is only true on Linux systems.
7535 2016-09-06 Carl Love <cel@us.ibm.com>
7537 * server.c (start_inferior): Do not call
7538 function target_post_create_inferior () if the
7539 inferior process has already exited.
7541 2016-09-05 Pedro Alves <palves@redhat.com>
7543 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7544 (COMPILE.pre, CC_LD): Use CXX directly.
7545 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7546 * acinclude.m4: Don't include build-with-cxx.m4.
7547 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7548 * configure: Regenerate.
7550 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7553 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7554 call writing data to own_buf.
7556 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7558 * target.c (mywait): Call target_wait instead of
7560 (target_wait): New function.
7562 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7564 * server.c (start_inferior): New variable 'ptid'. Replace calls
7565 to the_target->resume by target_continue{,_no_signal}, depending
7567 * target.c (target_stop_and_wait): Call target_continue_no_signal
7568 instead of the_target->resume.
7569 (target_continue): New function.
7571 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7573 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7575 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7578 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7580 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7581 * linux-arm-low.c (ps_get_thread_area): Likewise.
7582 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7583 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7584 * linux-mips-low.c (ps_get_thread_area): Likewise.
7585 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7586 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7587 * linux-x86-low.c (ps_get_thread_area): Likewise.
7588 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7590 2016-08-19 Pedro Alves <palves@redhat.com>
7592 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7594 2016-08-19 Pedro Alves <palves@redhat.com>
7596 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7597 comment. Use memcpy instead of casting through unsigned long.
7599 2016-08-19 Pedro Alves <palves@redhat.com>
7601 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7602 allocating around 0x80000000.
7604 2016-08-19 Pedro Alves <palves@redhat.com>
7607 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7608 (x32-avx512-linux-ipa.o): New rules.
7609 * configure.ac (x86_64-*-linux*): New x32 check.
7610 * configure.srv (ipa_x32_linux_regobj): New.
7611 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7612 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7614 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7616 * configure: Regenerate.
7618 2016-08-09 Pedro Alves <palves@redhat.com>
7621 * Makefile.in (OBS): Add signals-state-save-restore.o.
7622 (signals-state-save-restore.o): New rule.
7623 * config.in: Regenerate.
7624 * configure: Regenerate.
7625 * linux-low.c: Include "signals-state-save-restore.h".
7626 (linux_create_inferior): Call
7627 restore_original_signals_state.
7628 * server.c: Include "dispositions-save-restore.h".
7629 (captured_main): Call save_original_signals_state.
7631 2016-08-05 Pedro Alves <palves@redhat.com>
7633 * configure: Regenerate.
7635 2016-08-04 Yao Qi <yao.qi@linaro.org>
7637 * linux-low.c (regsets_fetch_inferior_registers): Check
7638 errno is ESRCH or not.
7640 2016-08-02 Yao Qi <yao.qi@linaro.org>
7642 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7643 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7644 (thread_db_load_search): Update.
7645 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7646 td_ta_set_event and td_ta_event_getmsg.
7648 2016-07-26 Pedro Alves <palves@redhat.com>
7651 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7652 of unsigned long for 64-bit registers and use uint32_t instead of
7653 unsigned int for 32-bit registers.
7655 2016-07-26 Pedro Alves <palves@redhat.com>
7657 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7660 2016-07-21 Tom Tromey <tom@tromey.com>
7662 * configure: Rebuild.
7664 2016-07-21 Yao Qi <yao.qi@linaro.org>
7666 * mem-break.c (find_gdb_breakpoint): Cast bp to
7667 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7669 2016-07-21 Yao Qi <yao.qi@linaro.org>
7671 * server.c (handle_v_requests): Support s and S actions
7672 if target_supports_software_single_step return true.
7674 2016-07-21 Yao Qi <yao.qi@linaro.org>
7676 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7677 is resume_step, call maybe_hw_step.
7678 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7680 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7682 (proceed_one_lwp): If resume request is resume_step, install
7683 reinsert breakpoints and call maybe_hw_step.
7685 2016-07-21 Yao Qi <yao.qi@linaro.org>
7687 * linux-low.c (proceed_one_lwp): Declare.
7688 (linux_resume_one_thread): Remove local variable 'step'.
7689 Lift code enqueue signal. Call proceed_one_lwp instead of
7690 linux_resume_one_lwp.
7692 2016-07-21 Yao Qi <yao.qi@linaro.org>
7694 * linux-low.c (linux_resume_one_thread): Call
7695 enqueue_pending_signal.
7697 2016-07-21 Yao Qi <yao.qi@linaro.org>
7699 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7700 * inferiors.c (do_restore_current_thread_cleanup): New function.
7701 (make_cleanup_restore_current_thread): Likewise.
7702 * linux-low.c (install_software_single_step_breakpoints): Call
7703 make_cleanup_restore_current_thread. Switch current_thread to
7706 2016-07-21 Yao Qi <yao.qi@linaro.org>
7708 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7709 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7710 (clone_one_breakpoint): Likewise.
7711 (delete_reinsert_breakpoints): Change parameter to thread.
7713 (has_reinsert_breakpoints): Likewise.
7714 (uninsert_reinsert_breakpoints): Likewise.
7715 (reinsert_reinsert_breakpoints): Likewise.
7716 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7717 (delete_reinsert_breakpoints): Likewise.
7718 (reinsert_reinsert_breakpoints): Likewise.
7719 (uninsert_reinsert_breakpoints): Likewise.
7720 (has_reinsert_breakpoints): Likewise.
7722 2016-07-21 Yao Qi <yao.qi@linaro.org>
7724 * inferiors.c (get_thread_process): Make parameter const.
7725 * inferiors.h (get_thread_process): Update declaration.
7726 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7727 Add new parameters child_thread and parent_thread. Callers
7729 * mem-break.h (clone_all_breakpoints): Update declaration.
7731 2016-07-21 Yao Qi <yao.qi@linaro.org>
7733 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7734 <command_list, handler>: Remove.
7735 (struct gdb_breakpoint): New.
7736 (struct other_breakpoint): New.
7737 (struct reinsert_breakpoint): New.
7738 (is_gdb_breakpoint): New function.
7739 (any_persistent_commands): Update command_list if
7740 is_gdb_breakpoint returns true.
7741 (set_breakpoint): Create breakpoints according to their types.
7742 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7743 (set_gdb_breakpoint_1): Likewise.
7744 (set_gdb_breakpoint): Likewise.
7745 (clear_breakpoint_conditions): Change parameter type to
7746 'struct gdb_breakpoint *'.
7747 (clear_breakpoint_commands): Likewise.
7748 (clear_breakpoint_conditions_and_commands): Likewise.
7749 (add_condition_to_breakpoint): Likewise.
7750 (add_breakpoint_condition): Likewise.
7751 (add_commands_to_breakpoint): Likewise.
7752 (check_breakpoints): Check other_breakpoint.
7753 (clone_one_breakpoint): Clone breakpopint according to its type.
7754 * mem-break.h (struct gdb_breakpoint): Declare.
7755 (set_gdb_breakpoint): Update declaration.
7756 (clear_breakpoint_conditions_and_commands): Likewise.
7757 (add_breakpoint_condition): Likewise.
7758 (add_breakpoint_commands): Likewise.
7759 * server.c (process_point_options): Change parameter type to
7760 'struct gdb_breakpoint *'.
7762 2016-07-21 Yao Qi <yao.qi@linaro.org>
7764 * mem-break.c (set_breakpoint_at): Rename it to ...
7765 (set_breakpoint_type_at): ... it.
7766 (set_breakpoint_at): Call set_breakpoint_type_at.
7767 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7768 * mem-break.h (set_breakpoint_at): Update comments.
7770 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7772 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7774 (nios2_store_gregset): Likewise.
7776 2016-07-01 Pedro Alves <palves@redhat.com>
7777 Antoine Tremblay <antoine.tremblay@ericsson.com>
7779 * linux-low.c: Change interface to take the target lwp_info
7780 pointer directly and return void. Handle detaching from a zombie
7782 (linux_detach_lwp_callback): New function.
7783 (linux_detach): Detach from the leader thread after detaching from
7786 2016-06-28 Yao Qi <yao.qi@linaro.org>
7788 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7789 for variable new_offset.
7790 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7791 (aarch64_ftrace_insn_reloc_cb): Likewise.
7792 (aarch64_ftrace_insn_reloc_tb): Likewise.
7793 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7794 PRIx64 instead of PRIx32.
7796 2016-06-28 Yao Qi <yao.qi@linaro.org>
7798 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7799 (the_low_target): Install arm_get_syscall_trapinfo.
7801 2016-06-28 Yao Qi <yao.qi@linaro.org>
7803 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7805 (the_low_target): Install aarch64_get_syscall_trapinfo.
7807 2016-06-28 Yao Qi <yao.qi@linaro.org>
7809 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7811 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7812 Remove parameter sysno.
7813 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7816 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7818 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7819 (s390_emit_ne_goto): Likewise.
7820 (s390_emit_lt_goto): Likewise.
7821 (s390_emit_le_goto): Likewise.
7822 (s390_emit_gt_goto): Likewise.
7823 (s390_emit_ge_goto): Likewise.
7824 (s390x_emit_eq_goto): Likewise.
7825 (s390x_emit_ne_goto): Likewise.
7826 (s390x_emit_lt_goto): Likewise.
7827 (s390x_emit_le_goto): Likewise.
7828 (s390x_emit_gt_goto): Likewise.
7829 (s390x_emit_ge_goto): Likewise.
7830 (s390_emit_ops_impl): Mark variable static.
7831 (s390x_emit_ops): Likewise.
7833 2016-06-17 Yao Qi <yao.qi@linaro.org>
7835 * linux-low.c (handle_extended_wait): Call
7836 uninsert_reinsert_breakpoints for the parent process. Remove
7837 reinsert breakpoints from the child process. Reinsert them to
7838 the parent process when vfork is done.
7839 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7840 (reinsert_reinsert_breakpoints): New function.
7841 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7842 (reinsert_reinsert_breakpoints): Declare.
7844 2016-06-17 Yao Qi <yao.qi@linaro.org>
7846 * linux-low.c (handle_extended_wait): If the parent is doing
7847 step-over, remove the reinsert breakpoints from the forked child.
7849 2016-06-17 Yao Qi <yao.qi@linaro.org>
7851 * linux-low.c (unsuspend_all_lwps): Declare.
7852 (linux_low_filter_event): If thread exited, call finish_step_over.
7853 If step-over is finished, unsuspend other threads.
7855 2016-06-17 Yao Qi <yao.qi@linaro.org>
7857 * linux-low.c (linux_resume_one_lwp_throw): Assert
7858 has_reinsert_breakpoints returns false.
7859 * mem-break.c (delete_disabled_breakpoints): Assert
7860 bp type isn't reinsert_breakpoint.
7862 2016-06-17 Yao Qi <yao.qi@linaro.org>
7864 * linux-low.c (maybe_hw_step): New function.
7865 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7866 (finish_step_over): Switch current_thread to lwp temporarily,
7867 and assert has_reinsert_breakpoints returns true.
7868 (proceed_one_lwp): Call maybe_hw_step.
7869 * mem-break.c (has_reinsert_breakpoints): New function.
7870 * mem-break.h (has_reinsert_breakpoints): Declare.
7872 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7874 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7876 2016-05-17 Yao Qi <yao.qi@linaro.org>
7878 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7879 instead of find_inferior.
7881 2016-05-05 Yao Qi <yao.qi@linaro.org>
7883 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7884 Initialize res to zero.
7886 2016-05-05 Yao Qi <yao.qi@linaro.org>
7888 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7891 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7893 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7894 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7895 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7897 2016-04-28 Par Olsson <par.olsson@windriver.com>
7898 Simon Marchi <simon.marchi@ericsson.com>
7900 * tracepoint.c (write_inferior_int8): New function.
7901 (cmd_qtenable_disable): Write enable flag using
7902 write_inferior_int8.
7904 2016-04-25 Yao Qi <yao.qi@linaro.org>
7906 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7907 (need_step_over_p): Return zero if the LWP has pending signals
7908 can be delivered on software single step target.
7910 2016-04-25 Yao Qi <yao.qi@linaro.org>
7912 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7913 return instead of error.
7915 2016-04-22 Yao Qi <yao.qi@linaro.org>
7917 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7920 2016-04-22 Yao Qi <yao.qi@linaro.org>
7922 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7923 signal when stepping over breakpoint with software single
7926 2016-04-21 Pedro Alves <palves@redhat.com>
7928 * linux-s390-low.c (s390_collect_ptrace_register)
7929 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7931 (s390_check_regset): Use void * instead of gdb_byte *.
7933 2016-04-20 Pedro Alves <palves@redhat.com>
7935 * configure: Renegerate.
7937 2016-04-20 Yao Qi <yao.qi@linaro.org>
7939 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7940 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7942 (arm_store_gregset): Likewise.
7944 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7946 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7947 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7948 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7949 (amd64-avx-mpx-linux.c): New rules.
7950 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7951 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7952 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7953 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7954 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7955 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7956 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7957 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7958 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7959 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7960 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7961 * linux-x86-low.c (x86_linux_read_description): Add case for
7962 X86_XSTATE_AVX_MPX_MASK.
7963 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7964 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7965 init_registers_i386_avx_mpx_linux.
7966 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7967 (initialize_low_tracepoint): Call
7968 init_registers_i386_avx_mpx_linux.
7969 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7970 (initialize_low_tracepoint): Call
7971 init_registers_amd64_avx_mpx_linux.
7972 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7973 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7974 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
7977 2016-04-18 Pedro Alves <palves@redhat.com>
7979 * configure: Regenerate.
7981 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
7983 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
7984 (aarch64_emit_sub): Likewise.
7986 2016-04-12 Pedro Alves <palves@redhat.com>
7988 * utils.c (prepare_to_throw_exception): Delete.
7990 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
7992 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
7994 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
7996 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
7998 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8000 * linux-aarch64-ipa.c: Add <elf.h> include.
8001 * linux-ppc-ipa.c: Add <elf.h> include.
8002 * linux-s390-ipa.c: Add <elf.h> include.
8004 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8006 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8007 (get_raw_reg_ptr): Likewise.
8008 (get_trace_state_variable_value_ptr): Likewise.
8009 (set_trace_state_variable_value_ptr): Likewise.
8010 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8013 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8014 Marcin Kościelnicki <koriakin@0x04.net>
8017 * linux-ppc-low.c (emit_insns): New function.
8018 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8019 (ppc_emit_prologue): New function.
8020 (ppc_emit_epilogue): New function.
8021 (ppc_emit_add): New function.
8022 (ppc_emit_sub): New function.
8023 (ppc_emit_mul): New function.
8024 (ppc_emit_lsh): New function.
8025 (ppc_emit_rsh_signed): New function.
8026 (ppc_emit_rsh_unsigned): New function.
8027 (ppc_emit_ext): New function.
8028 (ppc_emit_zero_ext): New function.
8029 (ppc_emit_log_not): New function.
8030 (ppc_emit_bit_and): New function.
8031 (ppc_emit_bit_or): New function.
8032 (ppc_emit_bit_xor): New function.
8033 (ppc_emit_bit_not): New function.
8034 (ppc_emit_equal): New function.
8035 (ppc_emit_less_signed): New function.
8036 (ppc_emit_less_unsigned): New function.
8037 (ppc_emit_ref): New function.
8038 (ppc_emit_const): New function.
8039 (ppc_emit_reg): New function.
8040 (ppc_emit_pop): New function.
8041 (ppc_emit_stack_flush): New function.
8042 (ppc_emit_swap): New function.
8043 (ppc_emit_stack_adjust): New function.
8044 (ppc_emit_call): New function.
8045 (ppc_emit_int_call_1): New function.
8046 (ppc_emit_void_call_2): New function.
8047 (ppc_emit_if_goto): New function.
8048 (ppc_emit_goto): New function.
8049 (ppc_emit_eq_goto): New function.
8050 (ppc_emit_ne_goto): New function.
8051 (ppc_emit_lt_goto): New function.
8052 (ppc_emit_le_goto): New function.
8053 (ppc_emit_gt_goto): New function.
8054 (ppc_emit_ge_goto): New function.
8055 (ppc_write_goto_address): New function.
8056 (ppc_emit_ops_impl): New static variable.
8057 (ppc64v1_emit_prologue): New function.
8058 (ppc64v2_emit_prologue): New function.
8059 (ppc64_emit_epilogue): New function.
8060 (ppc64_emit_add): New function.
8061 (ppc64_emit_sub): New function.
8062 (ppc64_emit_mul): New function.
8063 (ppc64_emit_lsh): New function.
8064 (ppc64_emit_rsh_signed): New function.
8065 (ppc64_emit_rsh_unsigned): New function.
8066 (ppc64_emit_ext): New function.
8067 (ppc64_emit_zero_ext): New function.
8068 (ppc64_emit_log_not): New function.
8069 (ppc64_emit_bit_and): New function.
8070 (ppc64_emit_bit_or): New function.
8071 (ppc64_emit_bit_xor): New function.
8072 (ppc64_emit_bit_not): New function.
8073 (ppc64_emit_equal): New function.
8074 (ppc64_emit_less_signed): New function.
8075 (ppc64_emit_less_unsigned): New function.
8076 (ppc64_emit_ref): New function.
8077 (ppc64_emit_const): New function.
8078 (ppc64v1_emit_reg): New function.
8079 (ppc64v2_emit_reg): New function.
8080 (ppc64_emit_pop): New function.
8081 (ppc64_emit_stack_flush): New function.
8082 (ppc64_emit_swap): New function.
8083 (ppc64v1_emit_call): New function.
8084 (ppc64v2_emit_call): New function.
8085 (ppc64v1_emit_int_call_1): New function.
8086 (ppc64v2_emit_int_call_1): New function.
8087 (ppc64v1_emit_void_call_2): New function.
8088 (ppc64v2_emit_void_call_2): New function.
8089 (ppc64_emit_if_goto): New function.
8090 (ppc64_emit_eq_goto): New function.
8091 (ppc64_emit_ne_goto): New function.
8092 (ppc64_emit_lt_goto): New function.
8093 (ppc64_emit_le_goto): New function.
8094 (ppc64_emit_gt_goto): New function.
8095 (ppc64_emit_ge_goto): New function.
8096 (ppc64v1_emit_ops_impl): New static variable.
8097 (ppc64v2_emit_ops_impl): New static variable.
8098 (ppc_emit_ops): New function.
8099 (linux_low_target): Wire in ppc_emit_ops.
8101 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8102 Marcin Kościelnicki <koriakin@0x04.net>
8105 * Makefile.in: Add powerpc-*-ipa.o
8106 * configure.srv: Add ipa_obj for powerpc*-linux.
8107 * linux-ppc-ipa.c: New file.
8108 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8110 (PPC_FIELD): New macro.
8111 (PPC_SEXT): New macro.
8112 (PPC_OP6): New macro.
8113 (PPC_BO): New macro.
8114 (PPC_LI): New macro.
8115 (PPC_BD): New macro.
8116 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8117 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8118 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8119 (ppc_get_thread_area): New function.
8120 (is_elfv2_inferior): New function.
8121 (gen_ds_form): New function.
8122 (GEN_STD): New macro.
8123 (GEN_STDU): New macro.
8124 (GEN_LD): New macro.
8125 (GEN_LDU): New macro.
8126 (gen_d_form): New function.
8127 (GEN_ADDI): New macro.
8128 (GEN_ADDIS): New macro.
8129 (GEN_LI): New macro.
8130 (GEN_LIS): New macro.
8131 (GEN_ORI): New macro.
8132 (GEN_ORIS): New macro.
8133 (GEN_LWZ): New macro.
8134 (GEN_STW): New macro.
8135 (GEN_STWU): New macro.
8136 (gen_xfx_form): New function.
8137 (GEN_MFSPR): New macro.
8138 (GEN_MTSPR): New macro.
8139 (GEN_MFCR): New macro.
8140 (GEN_MTCR): New macro.
8141 (GEN_SYNC): New macro.
8142 (GEN_LWSYNC): New macro.
8143 (gen_x_form): New function.
8144 (GEN_OR): New macro.
8145 (GEN_MR): New macro.
8146 (GEN_LWARX): New macro.
8147 (GEN_STWCX): New macro.
8148 (GEN_CMPW): New macro.
8149 (gen_md_form): New function.
8150 (GEN_RLDICL): New macro.
8151 (GEN_RLDICR): New macro.
8152 (gen_i_form): New function.
8154 (GEN_BL): New macro.
8155 (gen_b_form): New function.
8156 (GEN_BNE): New macro.
8157 (GEN_LOAD): New macro.
8158 (GEN_STORE): New macro.
8159 (gen_limm): New function.
8160 (gen_atomic_xchg): New function.
8161 (gen_call): New function.
8162 (ppc_relocate_instruction): New function.
8163 (ppc_install_fast_tracepoint_jump_pad): New function.
8164 (ppc_get_min_fast_tracepoint_insn_len): New function.
8165 (ppc_get_ipa_tdesc_idx): New function.
8166 (the_low_target): Wire in the new functions.
8167 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8169 * linux-ppc-tdesc.h: New file.
8171 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8173 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8174 (alloc_jump_pad_buffer): New function.
8175 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8176 (alloc_jump_pad_buffer): New function.
8177 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8178 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8179 (alloc_jump_pad_buffer): New function.
8180 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8181 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8182 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8183 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8185 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8187 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8188 * linux-amd64-ipa.c: Likewise.
8189 * linux-i386-ipa.c: Likewise.
8190 * linux-s390-ipa.c: Likewise.
8191 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8192 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8193 set_trace_state_variable_value_ptr.
8194 (struct ipa_sym_addresses): Likewise.
8195 (symbol_list): Likewise.
8196 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8197 accessing gdb_collect directly.
8198 (gdb_collect_ptr_type): New typedef.
8199 (get_raw_reg_ptr_type): New typedef.
8200 (get_trace_state_variable_value_ptr_type): New typedef.
8201 (set_trace_state_variable_value_ptr_type): New typedef.
8202 (gdb_collect_ptr): New global.
8203 (get_raw_reg_ptr): New global.
8204 (get_trace_state_variable_value_ptr): New global.
8205 (set_trace_state_variable_value_ptr): New global.
8206 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8207 accessing get_raw_reg directly.
8208 (get_get_tsv_func_addr): Likewise for
8209 get_trace_state_variable_value_ptr.
8210 (get_set_tsv_func_addr): Likewise for
8211 set_trace_state_variable_value_ptr.
8212 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8214 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8216 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8218 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8220 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8222 (relocate_instruction): Remove own_buf.
8223 * server.c (own_buf): Make global.
8224 (handle_v_requests): Make global.
8225 * server.h (own_buf): New declaration.
8226 (handle_v_requests): New prototype.
8228 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8231 * linux-s390-low.c (add_insns): New function.
8232 (s390_emit_prologue): New function.
8233 (s390_emit_epilogue): New function.
8234 (s390_emit_add): New function.
8235 (s390_emit_sub): New function.
8236 (s390_emit_mul): New function.
8237 (s390_emit_lsh): New function.
8238 (s390_emit_rsh_signed): New function.
8239 (s390_emit_rsh_unsigned): New function.
8240 (s390_emit_ext): New function.
8241 (s390_emit_log_not): New function.
8242 (s390_emit_bit_and): New function.
8243 (s390_emit_bit_or): New function.
8244 (s390_emit_bit_xor): New function.
8245 (s390_emit_bit_not): New function.
8246 (s390_emit_equal): New function.
8247 (s390_emit_less_signed): New function.
8248 (s390_emit_less_unsigned): New function.
8249 (s390_emit_ref): New function.
8250 (s390_emit_if_goto): New function.
8251 (s390_emit_goto): New function.
8252 (s390_write_goto_address): New function.
8253 (s390_emit_litpool): New function.
8254 (s390_emit_const): New function.
8255 (s390_emit_call): New function.
8256 (s390_emit_reg): New function.
8257 (s390_emit_pop): New function.
8258 (s390_emit_stack_flush): New function.
8259 (s390_emit_zero_ext): New function.
8260 (s390_emit_swap): New function.
8261 (s390_emit_stack_adjust): New function.
8262 (s390_emit_set_r2): New function.
8263 (s390_emit_int_call_1): New function.
8264 (s390_emit_void_call_2): New function.
8265 (s390_emit_eq_goto): New function.
8266 (s390_emit_ne_goto): New function.
8267 (s390_emit_lt_goto): New function.
8268 (s390_emit_le_goto): New function.
8269 (s390_emit_gt_goto): New function.
8270 (s390_emit_ge_goto): New function.
8271 (s390x_emit_prologue): New function.
8272 (s390x_emit_epilogue): New function.
8273 (s390x_emit_add): New function.
8274 (s390x_emit_sub): New function.
8275 (s390x_emit_mul): New function.
8276 (s390x_emit_lsh): New function.
8277 (s390x_emit_rsh_signed): New function.
8278 (s390x_emit_rsh_unsigned): New function.
8279 (s390x_emit_ext): New function.
8280 (s390x_emit_log_not): New function.
8281 (s390x_emit_bit_and): New function.
8282 (s390x_emit_bit_or): New function.
8283 (s390x_emit_bit_xor): New function.
8284 (s390x_emit_bit_not): New function.
8285 (s390x_emit_equal): New function.
8286 (s390x_emit_less_signed): New function.
8287 (s390x_emit_less_unsigned): New function.
8288 (s390x_emit_ref): New function.
8289 (s390x_emit_if_goto): New function.
8290 (s390x_emit_const): New function.
8291 (s390x_emit_call): New function.
8292 (s390x_emit_reg): New function.
8293 (s390x_emit_pop): New function.
8294 (s390x_emit_stack_flush): New function.
8295 (s390x_emit_zero_ext): New function.
8296 (s390x_emit_swap): New function.
8297 (s390x_emit_stack_adjust): New function.
8298 (s390x_emit_int_call_1): New function.
8299 (s390x_emit_void_call_2): New function.
8300 (s390x_emit_eq_goto): New function.
8301 (s390x_emit_ne_goto): New function.
8302 (s390x_emit_lt_goto): New function.
8303 (s390x_emit_le_goto): New function.
8304 (s390x_emit_gt_goto): New function.
8305 (s390x_emit_ge_goto): New function.
8306 (s390_emit_ops): New function.
8307 (struct linux_target_ops): Fill in emit_ops hook.
8309 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8312 * Makefile.in: Add s390 IPA files.
8313 * configure.srv: Build IPA for s390.
8314 * linux-s390-ipa.c: New file.
8315 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8316 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8317 (tdesc_s390_linux32): Likewise.
8318 (init_registers_s390_linux32v1): Likewise.
8319 (tdesc_s390_linux32v1): Likewise.
8320 (init_registers_s390_linux32v2): Likewise.
8321 (tdesc_s390_linux32v2): Likewise.
8322 (init_registers_s390_linux64): Likewise.
8323 (tdesc_s390_linux64): Likewise.
8324 (init_registers_s390_linux64v1): Likewise.
8325 (tdesc_s390_linux64v1): Likewise.
8326 (init_registers_s390_linux64v2): Likewise.
8327 (tdesc_s390_linux64v2): Likewise.
8328 (init_registers_s390_te_linux64): Likewise.
8329 (tdesc_s390_te_linux64): Likewise.
8330 (init_registers_s390_vx_linux64): Likewise.
8331 (tdesc_s390_vx_linux64): Likewise.
8332 (init_registers_s390_tevx_linux64): Likewise.
8333 (tdesc_s390_tevx_linux64): Likewise.
8334 (init_registers_s390x_linux64): Likewise.
8335 (tdesc_s390x_linux64): Likewise.
8336 (init_registers_s390x_linux64v1): Likewise.
8337 (tdesc_s390x_linux64v1): Likewise.
8338 (init_registers_s390x_linux64v2): Likewise.
8339 (tdesc_s390x_linux64v2): Likewise.
8340 (init_registers_s390x_te_linux64): Likewise.
8341 (tdesc_s390x_te_linux64): Likewise.
8342 (init_registers_s390x_vx_linux64): Likewise.
8343 (tdesc_s390x_vx_linux64): Likewise.
8344 (init_registers_s390x_tevx_linux64): Likewise.
8345 (tdesc_s390x_tevx_linux64): Likewise.
8346 (have_hwcap_s390_vx): New static variable.
8347 (s390_arch_setup): Fill have_hwcap_s390_vx.
8348 (s390_get_thread_area): New function.
8349 (s390_ft_entry_gpr_esa): New const.
8350 (s390_ft_entry_gpr_zarch): New const.
8351 (s390_ft_entry_misc): New const.
8352 (s390_ft_entry_fr): New const.
8353 (s390_ft_entry_vr): New const.
8354 (s390_ft_main_31): New const.
8355 (s390_ft_main_64): New const.
8356 (s390_ft_exit_fr): New const.
8357 (s390_ft_exit_vr): New const.
8358 (s390_ft_exit_misc): New const.
8359 (s390_ft_exit_gpr_esa): New const.
8360 (s390_ft_exit_gpr_zarch): New const.
8361 (append_insns): New function.
8362 (s390_relocate_instruction): New function.
8363 (s390_install_fast_tracepoint_jump_pad): New function.
8364 (s390_get_min_fast_tracepoint_insn_len): New function.
8365 (s390_get_ipa_tdesc_idx): New function.
8366 (struct linux_target_ops): Wire in the above functions.
8367 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8368 * linux-s390-tdesc.h: New file.
8370 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8372 * linux-s390-low.c (s390_supports_tracepoints): New function.
8373 (struct linux_target_ops): Fill supports_tracepoints hook.
8375 2016-03-18 Yao Qi <yao.qi@linaro.org>
8377 * linux-low.c (lwp_signal_can_be_delivered): New function.
8378 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8380 2016-03-18 Yao Qi <yao.qi@linaro.org>
8382 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8383 0 if signal is enqueued. Remove 'signal' from one debugging
8384 message. Move one debugging message to some lines below.
8385 Remove code setting 'signal' to 0.
8387 2016-03-18 Yao Qi <yao.qi@linaro.org>
8389 * linux-low.c (linux_low_filter_event): Remove redundant
8390 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8392 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8394 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8395 (struct linux_target_ops): Wire in the above.
8397 2016-03-03 Yao Qi <yao.qi@linaro.org>
8399 * linux-low.c: Update comments to start_step_over.
8401 2016-03-03 Yao Qi <yao.qi@linaro.org>
8404 * linux-low.c (handle_extended_wait): Set child suspended
8405 if event_lwp->bp_reinsert isn't zero.
8407 2016-03-02 Yao Qi <yao.qi@linaro.org>
8409 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8410 enqueue_pending_signal.
8412 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8414 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8417 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8419 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8420 (s390_regmap_3264) [!__s390x__]: New global.
8421 (s390_collect_ptrace_register): Skip map entries containing -1.
8422 (s390_supply_ptrace_register): Ditto.
8423 (s390_fill_gprs_high): New function.
8424 (s390_store_gprs_high): New function.
8425 (s390_regsets): Add NT_S390_HIGH_GPRS.
8426 (s390_get_hwcap): Enable on 31-bit.
8427 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8428 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8429 Detect NT_S390_HIGH_GPRS.
8430 (s390_usrregs_info_3264): Enable on 31-bit.
8431 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8432 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8434 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8437 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8438 * configure.srv: Ditto.
8439 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8440 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8441 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8442 (init_registers_amd64_linux): Remove prototype.
8443 (tdesc_amd64_linux): Remove declaration.
8444 (get_ipa_tdesc): New function.
8445 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8446 initialize remaining tdescs.
8447 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8448 (init_registers_i386_linux): Remove prototype.
8449 (tdesc_i386_linux): Remove declaration.
8450 (get_ipa_tdesc): New function.
8451 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8452 initialize remaining tdescs.
8453 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8454 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8455 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8456 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8457 (x86_get_ipa_tdesc_idx): New function.
8458 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8459 * linux-x86-tdesc.h: New file.
8460 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8461 (target_get_ipa_tdesc_idx): New macro.
8462 * tracepoint.c (ipa_tdesc_idx): New macro.
8463 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8464 (symbol_list): Add ipa_tdesc_idx.
8465 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8466 (ipa_tdesc): Remove.
8467 (ipa_tdesc_idx): New variable.
8468 (get_context_regcache): Use get_ipa_tdesc.
8469 (gdb_collect): Ditto.
8471 * tracepoint.h (get_ipa_tdesc): New prototype.
8472 (ipa_tdesc): Remove.
8474 2016-02-24 Pedro Alves <palves@redhat.com>
8476 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8477 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8478 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8479 Factor out common code between the USE_SIGTRAP_SIGINFO and
8480 !USE_SIGTRAP_SIGINFO blocks.
8481 (linux_low_filter_event): Call save_stop_reason instead of
8482 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8484 (linux_wait_1): Update comments.
8486 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8488 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8489 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8490 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8491 ppc_insert_point, ppc_remove_point.
8493 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8495 * linux-s390-low.c (s390_supports_z_point_type): New function.
8496 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8498 2016-02-16 Yao Qi <yao.qi@linaro.org>
8500 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8501 PC. Get pc from regcache_read_pc.
8503 2016-02-12 Yao Qi <yao.qi@linaro.org>
8505 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8506 or linux_get_pc_32bit.
8507 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8509 2016-02-12 Yao Qi <yao.qi@linaro.org>
8511 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8512 arm_linux_get_next_pcs_fixup.
8514 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8516 * tracepoint.c (x_tracepoint_action_download): Change
8517 write_inferior_data_ptr to write_inferior_data_pointer.
8518 (cmd_qtstart): Likewise.
8519 (write_inferior_data_ptr): Remove.
8520 (download_agent_expr): Change write_inferior_data_ptr to
8521 write_inferior_data_pointer.
8522 (download_tracepoint_1): Likewise.
8523 (download_tracepoint): Likewise.
8524 (download_trace_state_variables): Likewise.
8526 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8527 Marcin Kościelnicki <koriakin@0x04.net>
8529 * tracepoint.c (struct tracepoint_action_ops): Remove.
8530 (struct tracepoint_action): Remove ops.
8531 (m_tracepoint_action_download, r_tracepoint_action_download)
8532 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8533 size and offset accordingly.
8534 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8535 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8536 (tracepoint_action_send, tracepoint_action_download): New functions.
8537 Helpers for trace action handlers.
8538 (add_tracepoint_action): Remove setup actions ops.
8539 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8541 2016-02-10 Yao Qi <yao.qi@linaro.org>
8543 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8545 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8547 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8549 * configure: Regenerate.
8551 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8553 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8554 void * to gdb_byte *.
8555 * linux-low.c (siginfo_fixup): Likewise.
8556 (linux_xfer_siginfo): Likewise.
8557 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8559 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8561 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8563 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8565 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8567 * linux-x86-low.c [__x86_64__]: Include
8568 "nat/amd64-linux-siginfo.h".
8569 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8570 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8571 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8572 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8573 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8574 (cpt_si_fd, si_timerid, si_overrun): Move from
8575 nat/amd64-linux-siginfo.c.
8576 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8578 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8580 * server.c (skip_to_semicolon): Remove.
8581 (process_point_options): Use strchrnul instead of
8584 2016-01-26 Yao Qi <yao.qi@linaro.org>
8586 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8587 * linux-low.c (install_software_single_step_breakpoints): Don't
8588 call regcache_read_pc.
8589 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8592 2016-01-26 Yao Qi <yao.qi@linaro.org>
8594 * linux-low.c (install_software_single_step_breakpoints): Call
8595 regcache_read_pc instead of get_pc.
8597 2016-01-26 Yao Qi <yao.qi@linaro.org>
8599 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8600 (unblock_async_io): Rename to ...
8601 (block_unblock_async_io): ... it. New function.
8602 (enable_async_io): Don't install SIGIO handler. Unblock it
8604 (disable_async_io): Don't ignore SIGIO. Block it instead.
8605 (initialize_async_io): Install SIGIO handler. Don't call
8608 2016-01-26 Yao Qi <yao.qi@linaro.org>
8610 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8611 first character is '\003', call *the_target->request_interrupt.
8613 2016-01-25 Yao Qi <yao.qi@linaro.org>
8615 * remote-utils.c (new_thread_notify): Remove.
8616 (dead_thread_notify): Likewise.
8617 * remote-utils.h (new_thread_notify): Remove declaration.
8618 (dead_thread_notify): Likewise.
8620 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8622 * gdb.trace/pending.exp: Fix expected message on continue.
8624 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8626 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8627 it works properly on big-endian machines where sizeof (CORE_ADDR)
8630 2016-01-21 Pedro Alves <palves@redhat.com>
8632 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8633 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8634 * configure: Regenerate.
8636 2016-01-21 Yao Qi <yao.qi@linaro.org>
8638 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8639 is_thumb and set it according to CPSR saved on the stack.
8640 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8641 arm_sigreturn_next_pc.
8643 2016-01-18 Yao Qi <yao.qi@linaro.org>
8645 * linux-low.c (linux_set_pc_64bit): New function.
8646 (linux_get_pc_64bit): New function.
8647 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8649 * linux-sparc-low.c (debug_threads): Remove declaration.
8650 (sparc_get_pc): Remove.
8651 (the_low_target): Use linux_get_pc_64bit instead of
8653 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8654 (the_low_target): Use linux_get_pc_64bit and
8657 2016-01-18 Yao Qi <yao.qi@linaro.org>
8659 * linux-arm-low.c (debug_threads): Remove declaration.
8660 (arm_get_pc, arm_set_pc): Remove.
8661 (the_low_target): Use linux_get_pc_32bit and
8663 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8664 (the_low_target): Use linux_get_pc_32bit and
8666 * linux-cris-low.c (debug_threads): Remove declaration.
8667 (cris_get_pc, cris_set_pc,): Remove.
8668 (the_low_target): Use linux_get_pc_32bit and
8670 * linux-crisv32-low.c (debug_threads): Remove declaration.
8671 (cris_get_pc, cris_set_pc): Remove.
8672 (the_low_target): Use linux_get_pc_32bit and
8674 * linux-low.c: Include inttypes.h.
8675 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8676 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8677 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8678 (the_low_target): Use linux_get_pc_32bit and
8680 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8681 (the_low_target): Use linux_get_pc_32bit and
8683 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8684 (the_low_target): Use linux_get_pc_32bit and
8686 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8687 (the_low_target): Use linux_get_pc_32bit and
8689 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8690 (the_low_target): Use linux_get_pc_32bit and
8693 2016-01-18 Gary Benson <gbenson@redhat.com>
8695 * configure.ac (AC_FUNC_FORK): New check.
8696 * config.in: Regenerate.
8697 * configure: Likewise.
8699 2016-01-14 Yao Qi <yao.qi@linaro.org>
8701 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8702 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8703 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8704 arm_get_next_pcs_ctor.
8706 2016-01-12 Josh Stone <jistone@redhat.com>
8707 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8709 * inferiors.h: Include "gdb_vecs.h".
8710 (struct process_info): Add syscalls_to_catch.
8711 * inferiors.c (remove_process): Free syscalls_to_catch.
8712 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8713 syscall_return stops.
8714 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8715 * server.c (handle_general_set): Handle QCatchSyscalls.
8716 (handle_query): Report support for QCatchSyscalls.
8717 * target.h (struct target_ops): Add supports_catch_syscall.
8718 (target_supports_catch_syscall): New macro.
8719 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8720 (struct lwp_info): Add syscall_state.
8721 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8722 Maintain syscall_state and syscalls_to_catch across exec.
8723 (get_syscall_trapinfo): New function, proxy to the_low_target.
8724 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8725 (linux_low_filter_event): Toggle syscall_state entry/return for
8726 syscall traps, and set it ignored for all others.
8727 (gdb_catching_syscalls_p): New function.
8728 (gdb_catch_this_syscall_p): New function.
8729 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8730 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8731 (linux_supports_catch_syscall): New function.
8732 (linux_target_ops): Install it.
8733 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8734 (the_low_target): Install it.
8736 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8738 * acinclude.m4: Include new ../warning.m4 file.
8739 * configure: Regenerated.
8740 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8742 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8744 * ax.c (is_goto_target): Mark static.
8745 * linux-low.c (register_addr): Likewise.
8746 (linux_fetch_registers, linux_store_registers): Likewise.
8747 * mem-break.c (any_persistent_commands): Fix old prototype.
8748 (add_commands_to_breakpoint): Mark static.
8749 * regcache.c (find_register_by_name): Delete unused func.
8750 * remote-utils.c (hex_or_minus_one): Mark static.
8751 * server.c (monitor_show_help): Mark static.
8752 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8753 handle_v_requests): Likewise.
8755 2016-01-12 Pedro Alves <palves@redhat.com>
8757 Remove use of the registered trademark symbol throughout.
8759 2016-01-08 Yao Qi <yao.qi@linaro.org>
8761 * remote-utils.c (getpkt): If c is '\003', call target hook
8764 2016-01-06 Yao Qi <yao.qi@linaro.org>
8766 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8767 linux-aarch32-low.c.
8768 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8769 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8770 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8771 (thumb2_breakpoint): Declare.
8772 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8773 linux-aarch32-low.h.
8774 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8775 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8776 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8778 2016-01-01 Joel Brobecker <brobecker@adacore.com>
8780 * gdbreplay.c (gdbreplay_version): Change copyright year in
8782 * server.c (gdbserver_version): Likewise.
8784 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8786 * server.c (crc32_table): Delete.
8787 (crc32): Use libiberty's xcrc32 function.
8789 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8791 * lynx-low.c (lynx_delete_thread_callback): New function.
8792 (lynx_mourn): Properly delete our process and all of its
8793 threads. Remove call to clear_inferiors.
8795 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8797 * target.c (thread_search_callback): Add check that
8798 the thread_stopped target callback is not NULL before
8801 2015-12-21 Yao Qi <yao.qi@linaro.org>
8803 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8806 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8808 * server.c (handle_query): Call target_supports_software_single_step.
8810 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8812 * linux-low.c (single_step): New function.
8813 (linux_resume_one_lwp_throw): Call single_step.
8814 (start_step_over): Likewise.
8816 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8818 * Makefile.in (SFILES): Append arch/arm-linux.c,
8819 arch/arm-get-next-pcs.c.
8820 (arm-linux.o): New rule.
8821 (arm-get-next-pcs.o): New rule.
8822 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8824 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8825 to linux-aarch32-low.c.
8826 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8827 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8828 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8829 (thumb2_breakpoint_len): Likewise.
8830 (arm_is_thumb_mode): Make non-static.
8831 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8832 from linux-aarch32-low.c.
8833 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8834 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8835 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8836 (thumb2_breakpoint_len): Likewise.
8837 (arm_is_thumb_mode): New declaration.
8838 * linux-arm-low.c: Include arch/arm-linux.h
8839 aarch/arm-get-next-pcs.h, sys/syscall.h.
8840 (get_next_pcs_ops): New struct.
8841 (get_next_pcs_addr_bits_remove): New function.
8842 (get_next_pcs_is_thumb): New function.
8843 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8844 (arm_sigreturn_next_pc): Likewise.
8845 (get_next_pcs_syscall_next_pc): Likewise.
8846 (arm_gdbserver_get_next_pcs): Likewise.
8847 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8849 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8850 * server.h: Include gdb_vecs.h.
8852 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8854 * Makefile.in (SFILES): Append common/common-regcache.c.
8855 (OBS): Append common-regcache.o.
8856 (common-regcache.o): New rule.
8857 * regcache.c (init_register_cache): Initialize cache to
8859 (regcache_raw_read_unsigned): New function.
8860 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8861 register_status enum.
8863 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8865 * linux-aarch64-low.c (the_low_targets): Rename
8866 breakpoint_reinsert_addr to get_next_pcs.
8867 * linux-arm-low.c (the_low_targets): Likewise.
8868 * linux-bfin-low.c (the_low_targets): Likewise.
8869 * linux-cris-low.c (the_low_targets): Likewise.
8870 * linux-crisv32-low.c (the_low_targets): Likewise.
8871 * linux-low.c (can_software_single_step): Likewise.
8872 (install_software_single_step_breakpoints): New function.
8873 (start_step_over): Use install_software_single_step_breakpoints.
8874 * linux-low.h: New CORE_ADDR vector.
8875 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8877 * linux-mips-low.c (the_low_targets): Likewise.
8878 * linux-nios2-low.c (the_low_targets): Likewise.
8879 * linux-sparc-low.c (the_low_targets): Likewise.
8881 2015-12-17 Pedro Alves <palves@redhat.com>
8883 * linux-low.c (linux_kill_one_lwp): Remove references to
8885 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8887 (linux_init_signals): Delete.
8888 (initialize_low): Adjust.
8889 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8891 2015-12-16 Pedro Alves <palves@redhat.com>
8893 * configure.ac (compiler warning flags): When testing a
8894 -Wno-foo option, check whether -Wfoo works instead.
8895 * configure: Regenerate.
8897 2015-12-11 Don Breazeal <donb@codesourcery.com>
8899 * server.c (process_serial_event): Don't exit from gdbserver
8900 in remote mode if there are still active inferiors.
8902 2015-12-11 Yao Qi <yao.qi@linaro.org>
8904 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8905 arm_breakpoint_at if the process is 32-bit.
8907 2015-12-11 Yao Qi <yao.qi@linaro.org>
8909 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8912 2015-12-07 Yao Qi <yao.qi@linaro.org>
8914 * configure.srv: Append arm.o to srv_tgtobj for
8915 aarch64*-*-linux* target.
8916 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8917 from linux-arm-low.c.
8918 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8919 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8920 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8921 (thumb2_breakpoint_len): Likewise.
8922 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8923 (arm_breakpoint_kinds): Likewise.
8924 (arm_breakpoint_kind_from_pc): Likewise.
8925 (arm_sw_breakpoint_from_kind): Likewise.
8926 (arm_breakpoint_kind_from_current_state): Likewise.
8927 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8928 (arm_sw_breakpoint_from_kind): Declare.
8929 (arm_breakpoint_kind_from_current_state): Declare.
8930 (arm_breakpoint_at): Declare.
8931 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8932 arm_sw_breakpoint_from_kind if process is 32-bit.
8933 (aarch64_breakpoint_kind_from_pc): New function.
8934 (aarch64_breakpoint_kind_from_current_state): New function.
8935 (the_low_target): Initialize fields breakpoint_kind_from_pc
8936 and breakpoint_kind_from_current_state.
8937 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8938 linux-aarch32-low.c.
8939 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8940 (arm_breakpoint, arm_breakpoint_len): Likewise.
8941 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8942 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8943 (arm_is_thumb_mode): Likewise.
8944 (arm_breakpoint_at): Likewise.
8945 (arm_breakpoint_kind_from_pc): Likewise.
8946 (arm_sw_breakpoint_from_kind): Likewise.
8947 (arm_breakpoint_kind_from_current_state): Likewise.
8950 2015-08-04 Yao Qi <yao.qi@linaro.org>
8952 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8953 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8954 * server.c (extended_protocol): Remove "static".
8955 * server.h (extended_protocol): Declare it.
8957 2015-12-04 Josh Stone <jistone@redhat.com>
8959 * target.h (struct target_ops) <arch_setup>: Rename to ...
8960 (struct target_ops) <post_create_inferior>: ... this.
8961 (target_arch_setup): Rename to ...
8962 (target_post_create_inferior): ... this, calling post_create_inferior.
8963 * server.c (start_inferior): Update target_arch_setup calls to
8964 target_post_create_inferior.
8965 * linux-low.c (linux_low_ptrace_options): Forward declare.
8966 (linux_arch_setup): Update its comment for general use.
8967 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8968 (struct linux_target_ops): Use linux_post_create_inferior.
8969 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8970 to post_create_inferior.
8971 * nto-low.c (struct nto_target_ops): Likewise.
8972 * spu-low.c (struct spu_target_ops): Likewise.
8973 * win32-low.c (struct win32_target_ops): Likewise.
8975 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
8977 * linux-arm-low.c: Remove duplicate arch/arm.h include.
8979 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8981 * linux-arm-low.c (arm_reinsert_addr): Remove function.
8982 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
8983 * linux-cris-low.c (cris_reinsert_addr> Remove function.
8984 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8985 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
8986 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8987 * linux-mips-low.c (mips_reinsert_addr): Remove function.
8988 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8989 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
8990 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8991 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
8992 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8994 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8996 * linux-low.c (linux_look_up_symbols): Don't call
8997 linux_supports_traceclone.
8998 * linux-low.h (thread_db_init): Remove use_events argument.
8999 * thread-db.c (thread_db_use_event): Remove global variable.
9000 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9001 (struct thread_db) <td_create_bp>: Remove field.
9002 (thread_db_create_event): Remove function.
9003 (thread_db_enable_reporting): Likewise.
9004 (find_one_thread): Don't check for thread_db_use_events.
9005 (attach_thread): Likewise.
9006 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9007 (try_thread_db_load_1): Don't check for thread_db_use_events.
9008 (thread_db_init): Remove use_events argument and thread events
9010 (remove_thread_event_breakpoints): Remove function.
9011 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9013 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9015 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9017 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9018 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9019 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9020 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9021 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9023 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9025 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9026 * linux-low.c (can_hardware_single_step): Use
9027 supports_hardware_single_step.
9028 (can_software_single_step): New function.
9029 (start_step_over): Call can_software_single_step.
9030 (linux_supports_hardware_single_step): New function.
9031 (struct target_ops) <supports_software_single_step>: Initialize.
9032 * linux-low.h (struct linux_target_ops)
9033 <supports_hardware_single_step>: Initialize.
9034 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9035 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9036 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9037 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9038 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9039 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9040 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9041 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9042 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9043 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9045 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9046 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9048 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9049 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9050 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9052 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9053 * target.h (struct target_ops): <supports_software_single_step>:
9055 (target_supports_software_single_step): New macro.
9057 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9059 * linux-low.c (linux_wait_1): Fix pc advance condition.
9060 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9061 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9063 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9065 * linux-arm-low.c (arm_is_thumb_mode): New function.
9066 (arm_breakpoint_at): Use arm_is_thumb_mode.
9067 (arm_breakpoint_kind_from_current_state): New function.
9068 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9070 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9071 (linux_breakpoint_kind_from_current_state): New function.
9072 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9073 * linux-low.h (struct linux_target_ops)
9074 <breakpoint_kind_from_current_state>: New field.
9075 * target.h (struct target_ops): Likewise.
9076 (target_breakpoint_kind_from_current_state): New macro.
9078 2015-11-30 Pedro Alves <palves@redhat.com>
9080 * linux-low.c (linux_resume): Wake up the event loop before
9083 2015-11-30 Pedro Alves <palves@redhat.com>
9085 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9087 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9089 * target.c (struct thread_search): New structure.
9090 (thread_search_callback): New function.
9091 (prev_general_thread): New global.
9092 (prepare_to_access_memory, done_accessing_memory): New functions.
9093 * target.h (prepare_to_access_memory, done_accessing_memory):
9094 Replace macros with function declarations.
9096 2015-11-30 Pedro Alves <palves@redhat.com>
9099 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9100 report TARGET_WAITKIND_NO_RESUMED.
9101 * remote-utils.c (prepare_resume_reply): Handle
9102 TARGET_WAITKIND_NO_RESUMED.
9103 * server.c (report_no_resumed): New global.
9104 (handle_query) <qSupported>: Handle "no-resumed+". Report
9105 "no-resumed+" support.
9106 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9107 return error if the client doesn't support no-resumed events.
9108 (push_stop_notification): New function.
9109 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9110 events if the client supports them.
9112 2015-11-30 Pedro Alves <palves@redhat.com>
9114 * linux-low.c (thread_still_has_status_pending_p): Don't check
9116 (lwp_resumed): New function.
9117 (status_pending_p_callback): Return early if the LWP is not
9118 supposed to be resumed.
9120 2015-11-30 Pedro Alves <palves@redhat.com>
9122 * linux-low.c (handle_extended_wait): Assert that the LWP's
9123 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9124 thread create events, leave the new child's status pending.
9125 (linux_low_filter_event): If GDB wants to hear about thread exit
9126 events, leave the LWP marked dead and don't delete it.
9127 (linux_wait_for_event_filtered): Don't check for thread exit.
9128 (filter_exit_event): New function.
9129 (linux_wait_1): Use it, when returning an exit event.
9130 (linux_resume_one_lwp_throw): Assert that the LWP's
9131 waitstatus is TARGET_WAITKIND_IGNORE.
9132 * remote-utils.c (prepare_resume_reply): Handle
9133 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9134 * server.c (report_thread_events): New global.
9135 (handle_general_set): Handle QThreadEvents.
9136 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9137 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9138 TARGET_WAITKIND_THREAD_EXITED.
9139 * server.h (report_thread_events): Declare.
9141 2015-11-30 Pedro Alves <palves@redhat.com>
9143 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9144 the thread's last_resume_kind was resume_stop.
9146 2015-11-30 Pedro Alves <palves@redhat.com>
9148 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9151 2015-11-30 Pedro Alves <palves@redhat.com>
9153 * server.c (handle_v_requests): Handle vCtrlC.
9155 2015-11-30 Pedro Alves <palves@redhat.com>
9157 * gdbthread.h (find_any_thread_of_pid): Declare.
9158 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9160 * server.c (handle_query): If current_thread is NULL, look for
9161 another thread of the selected process.
9163 2015-11-26 Daniel Colascione <dancol@dancol.org>
9164 Simon Marchi <simon.marchi@ericsson.com>
9166 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9167 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9169 * target.h (struct target_ops) <thread_name>: New field.
9170 (target_thread_name): New macro.
9172 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9174 * regcache.h (regcache_invalidate_pid): Add declaration.
9175 * regcache.c (regcache_invalidate_pid): New function, extracted
9176 from regcache_invalidate.
9177 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9178 Add trivial documentation comment.
9179 * lynx-low.c: Use regcache_invalidate_pid instead of
9180 regcache_invalidate.
9182 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9184 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9185 and Elf64_auxv_t if the target is Android.
9187 2015-11-22 Doug Evans <xdje42@gmail.com>
9189 * target.h: #include <sys/types.h>.
9191 2015-11-19 Pedro Alves <palves@redhat.com>
9193 * linux-low.c (linux_process_qsupported): Change prototype.
9195 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9197 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9198 and adjust to loop over all features.
9199 * server.c (handle_query) <qSupported>: Adjust to call
9200 target_process_qsupported once, passing it a vector of unprocessed
9202 * target.h (struct target_ops) <process_qsupported>: Change
9204 (target_process_qsupported): Adjust.
9206 2015-11-19 Pedro Alves <palves@redhat.com>
9208 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9210 * configure: Regenerate.
9212 2015-11-19 Pedro Alves <palves@redhat.com>
9214 * configure: Regenerate.
9216 2015-11-19 Yao Qi <yao.qi@linaro.org>
9218 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9221 2015-11-19 Yao Qi <yao.qi@linaro.org>
9223 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9224 (struct aarch64_operand): Move enum out.
9226 2015-11-19 Yao Qi <yao.qi@linaro.org>
9228 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9229 struct user_fpsimd_state *.
9230 (aarch64_store_fpregset): Likewise.
9232 2015-11-19 Yao Qi <yao.qi@linaro.org>
9234 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9235 struct user_pt_regs *.
9236 (aarch64_store_gregset): Likewise.
9238 2015-11-18 Pedro Alves <palves@redhat.com>
9240 * Makefile.in (all_object_files): Add $IPA_OBJS.
9242 2015-11-17 Pedro Alves <palves@redhat.com>
9244 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9245 GDB_SIGNAL_0 and gdb_signal_to_string.
9247 2015-11-17 Pedro Alves <palves@redhat.com>
9249 * win32-low.c (handle_output_debug_string): Remove parameter.
9250 (win32_kill): Remove our_status local and adjust call to
9251 handle_output_debug_string.
9252 (get_child_debug_event): Adjust call to
9253 handle_output_debug_string.
9255 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9257 * linux-mips-low.c (mips_fill_gregset): Add cast.
9258 (mips_store_gregset): Likewise.
9259 (mips_fill_fpregset): Likewise.
9260 (mips_store_fpregset): Likewise.
9262 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9264 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9267 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9269 * linux-mips-low.c (mips_linux_new_thread): Change type of
9270 watch_type to enum target_hw_bp_type.
9272 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9274 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9275 Change return type to arm_hwbp_type.
9277 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9279 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9280 (arm_store_gregset): Likewise.
9281 * linux-arm-low.c (arm_get_hwcap): Likewise.
9282 (arm_read_description): Likewise.
9284 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9286 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9288 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9290 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9291 (ppc_fill_vsxregset): Likewise.
9292 (ppc_store_vsxregset): Likewise.
9293 (ppc_fill_vrregset): Likewise.
9294 (ppc_store_vrregset): Likewise.
9295 (ppc_fill_evrregset): Likewise.
9296 (ppc_store_evrregset): Likewise.
9298 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9300 * linux-ppc-low.c (ppc_usrregs_info): Remove
9301 forward-declaration.
9302 (ppc_arch_setup): Move lower in file.
9304 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9306 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9307 (ps_pdwrite): Likewise.
9309 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9311 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9312 to after assert checks.
9314 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9316 * proc-service.c (ps_pdread): Add/adjust casts.
9317 (ps_pdwrite): Add/adjust casts.
9319 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9321 * server.c (handle_search_memory_1): Cast return value of
9324 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9326 * server.c (write_qxfer_response): Change type of data to
9329 2015-10-29 Pedro Alves <palves@redhat.com>
9331 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9333 2015-10-29 Pedro Alves <palves@redhat.com>
9335 * tracepoint.c (clear_installed_tracepoints): Add casts.
9337 2015-10-29 Pedro Alves <palves@redhat.com>
9339 * server.c (handle_v_cont, process_serial_event): Add enum
9340 gdb_signal casts to signal parsing code.
9342 2015-10-29 Pedro Alves <palves@redhat.com>
9344 * linux-low.h (NULL_REGSET): Define.
9345 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9346 * linux-arm-low.c (arm_regsets): Likewise.
9347 * linux-crisv32-low.c (cris_regsets): Likewise.
9348 * linux-m68k-low.c (m68k_regsets): Likewise.
9349 * linux-mips-low.c (mips_regsets): Likewise.
9350 * linux-nios2-low.c (nios2_regsets): Likewise.
9351 * linux-ppc-low.c (ppc_regsets): Likewise.
9352 * linux-s390-low.c (s390_regsets): Likewise.
9353 * linux-sh-low.c (sh_regsets): Likewise.
9354 * linux-sparc-low.c (sparc_regsets): Likewise.
9355 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9356 * linux-tile-low.c (tile_regsets): Likewise.
9357 * linux-x86-low.c (x86_regsets): Likewise.
9358 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9360 2015-10-29 Pedro Alves <palves@redhat.com>
9362 * linux-low.h (NULL_REGSET): Define.
9363 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9364 * linux-arm-low.c (arm_regsets): Likewise.
9365 * linux-crisv32-low.c (cris_regsets): Likewise.
9366 * linux-m68k-low.c (m68k_regsets): Likewise.
9367 * linux-mips-low.c (mips_regsets): Likewise.
9368 * linux-nios2-low.c (nios2_regsets): Likewise.
9369 * linux-ppc-low.c (ppc_regsets): Likewise.
9370 * linux-s390-low.c (s390_regsets): Likewise.
9371 * linux-sh-low.c (sh_regsets): Likewise.
9372 * linux-sparc-low.c (sparc_regsets): Likewise.
9373 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9374 * linux-tile-low.c (tile_regsets): Likewise.
9375 * linux-x86-low.c (x86_regsets): Likewise.
9376 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9378 2015-10-26 Doug Evans <dje@google.com>
9380 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9382 2015-10-26 Doug Evans <dje@google.com>
9384 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9386 2015-10-26 Doug Evans <dje@google.com>
9388 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9390 (attach_thread, find_new_threads_callback): Ditto.
9392 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9394 * mem-break.h (set_breakpoint_data): Remove.
9396 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9398 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9399 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9400 (initialize_low): Remove set_breakpoint_data call.
9401 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9402 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9403 (initialize_low): Remove set_breakpoint_data call.
9404 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9405 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9406 (initialize_low): Remove set_breakpoint_data call.
9408 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9410 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9411 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9412 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9413 * target.h (target_breakpoint_kind_from_pc): New macro.
9415 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9417 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9418 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9419 the default breakpoint kind.
9421 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9423 * linux-arm-low.c (arm_supports_z_point_type): Add software
9426 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9428 * linux-arm-low.c: Refactor breakpoint definitions.
9429 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9430 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9432 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9434 * Makefile.in: Add arm.c/o.
9435 * configure.srv: Likewise.
9436 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9437 (arm_breakpoint_kind_from_pc): New function.
9438 (arm_sw_breakpoint_from_kind): Return proper kind.
9439 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9441 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9443 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9445 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9446 (struct raw_breakpoint) <size>: Remove.
9447 (struct raw_breakpoint) <kind>: Add.
9448 (bp_size): New function.
9449 (bp_opcode): Likewise.
9450 (find_raw_breakpoint_at): Adjust for kind.
9451 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9452 (remove_memory_breakpoint): Adjust for kind call bp_size.
9453 (set_raw_breakpoint_at): Adjust for kind.
9454 (set_breakpoint): Likewise.
9455 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9456 (delete_raw_breakpoint): Adjust for kind.
9457 (delete_breakpoint): Likewise.
9458 (find_gdb_breakpoint): Likewise.
9459 (set_gdb_breakpoint_1): Likewise.
9460 (set_gdb_breakpoint): Likewise.
9461 (delete_gdb_breakpoint_1): Likewise.
9462 (delete_gdb_breakpoint): Likewise.
9463 (uninsert_raw_breakpoint): Likewise.
9464 (reinsert_raw_breakpoint): Likewise.
9465 (set_breakpoint_data): Remove.
9466 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9467 (check_mem_read): Adjust for kind call bp_size.
9468 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9469 (clone_one_breakpoint): Adjust for kind.
9470 * mem-break.h (set_gdb_breakpoint): Likewise.
9471 (delete_gdb_breakpoint): Likewise.
9472 * server.c (process_serial_event): Likewise.
9474 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9476 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9477 (struct linux_target_ops) <breakpoint>: Remove.
9478 (struct linux_target_ops) <breakpoint_len>: Remove.
9479 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9480 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9481 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9482 (arm_sw_breakpoint_from_kind): New function.
9483 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9484 (struct linux_target_ops) <breakpoint>: Remove.
9485 (struct linux_target_ops) <breakpoint_len>: Remove.
9486 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9487 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9488 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9489 (struct linux_target_ops) <breakpoint>: Remove.
9490 (struct linux_target_ops) <breakpoint_len>: Remove.
9491 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9492 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9493 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9494 (struct linux_target_ops) <breakpoint>: Remove.
9495 (struct linux_target_ops) <breakpoint_len>: Remove.
9496 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9497 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9498 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9499 and sw_breakpoint_from_kind to increment the pc.
9500 (linux_breakpoint_kind_from_pc): New function.
9501 (linux_sw_breakpoint_from_kind): New function.
9502 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9503 (initialize_low): Call breakpoint_kind_from_pc and
9504 sw_breakpoint_from_kind to replace breakpoint_data/len.
9505 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9507 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9508 * linux-m32r-low.c (m32r_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-m68k-low.c (m68k_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-mips-low.c (mips_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-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9524 (struct linux_target_ops) <breakpoint>: Remove.
9525 (struct linux_target_ops) <breakpoint_len>: Remove.
9526 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9527 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9528 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9529 (struct linux_target_ops) <breakpoint>: Remove.
9530 (struct linux_target_ops) <breakpoint_len>: Remove.
9531 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9532 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9533 * linux-s390-low.c (s390_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-sh-low.c (sh_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-sparc-low.c (sparc_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-tic6x-low.c (tic6x_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-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9554 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9555 (struct linux_target_ops) <breakpoint>: Remove.
9556 (struct linux_target_ops) <breakpoint_len>: Remove.
9557 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9558 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9559 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9560 (struct linux_target_ops) <breakpoint>: Remove.
9561 (struct linux_target_ops) <breakpoint_len>: Remove.
9562 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9563 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9565 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9567 * linux-cris-low.c (cris_get_pc): Remove void arg.
9569 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9571 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9574 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9576 * inferiors.c (thread_pid_matches_callback): New function.
9577 (find_thread_process): New function.
9578 (remove_thread): Reset current_thread.
9579 (remove_process): Assert threads have been removed first.
9581 2015-10-15 Yao Qi <yao.qi@linaro.org>
9583 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9585 (aarch64_remove_point): Likewise.
9586 * regcache.c (regcache_register_size): New function.
9588 2015-10-12 Yao Qi <yao.qi@linaro.org>
9590 * linux-aarch64-low.c: Update all callers as emit_load_store
9591 is renamed to aarch64_emit_load_store.
9593 2015-10-12 Yao Qi <yao.qi@linaro.org>
9595 * linux-aarch64-low.c: Update all callers of function renaming
9596 from emit_insn to aarch64_emit_insn.
9598 2015-10-12 Yao Qi <yao.qi@linaro.org>
9600 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9601 arch/aarch64-insn.h.
9602 (struct aarch64_memory_operand): Likewise.
9604 (emit_insn): Move to arch/aarch64-insn.c.
9605 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9606 (emit_load_store): Move to arch/aarch64-insn.c.
9607 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9608 (can_encode_int32): Remove.
9610 2015-10-12 Yao Qi <yao.qi@linaro.org>
9612 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9613 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9614 (aarch64_relocate_instruction): Likewise.
9615 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9616 (struct aarch64_insn_visitor): Likewise.
9618 2015-10-12 Yao Qi <yao.qi@linaro.org>
9620 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9621 (struct aarch64_insn_visitor): New.
9622 (struct aarch64_insn_relocation_data): New.
9623 (aarch64_ftrace_insn_reloc_b): New function.
9624 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9625 (aarch64_ftrace_insn_reloc_cb): Likewise.
9626 (aarch64_ftrace_insn_reloc_tb): Likewise.
9627 (aarch64_ftrace_insn_reloc_adr): Likewise.
9628 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9629 (aarch64_ftrace_insn_reloc_others): Likewise.
9631 (aarch64_relocate_instruction): Use visitor.
9633 2015-10-12 Yao Qi <yao.qi@linaro.org>
9635 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9636 int. Add argument buf.
9637 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9638 aarch64_relocate_instruction.
9640 2015-10-12 Yao Qi <yao.qi@linaro.org>
9642 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9643 argument insn. Remove local variable insn. Don't call
9645 (aarch64_install_fast_tracepoint_jump_pad): Call
9648 2015-09-30 Yao Qi <yao.qi@linaro.org>
9650 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9651 (emit_load_store_pair): Likewise.
9653 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9655 * dll.c (match_dll): Add cast(s).
9656 (unloaded_dll): Likewise.
9657 * linux-low.c (second_thread_of_pid_p): Likewise.
9658 (delete_lwp_callback): Likewise.
9659 (count_events_callback): Likewise.
9660 (select_event_lwp_callback): Likewise.
9661 (linux_set_resume_request): Likewise.
9662 * server.c (accumulate_file_name_length): Likewise.
9663 (emit_dll_description): Likewise.
9664 (handle_qxfer_threads_worker): Likewise.
9665 (visit_actioned_threads): Likewise.
9666 * thread-db.c (any_thread_of): Likewise.
9667 * tracepoint.c (same_process_p): Likewise.
9668 (match_blocktype): Likewise.
9669 (build_traceframe_info_xml): Likewise.
9671 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9673 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9675 (gdb_unparse_agent_expr): Likewise.
9676 * hostio.c (require_data): Likewise.
9677 (handle_pread): Likewise.
9678 * linux-low.c (disable_regset): Likewise.
9679 (fetch_register): Likewise.
9680 (store_register): Likewise.
9681 (get_dynamic): Likewise.
9682 (linux_qxfer_libraries_svr4): Likewise.
9683 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9684 (set_fast_tracepoint_jump): Likewise.
9685 (uninsert_fast_tracepoint_jumps_at): Likewise.
9686 (reinsert_fast_tracepoint_jumps_at): Likewise.
9687 (validate_inserted_breakpoint): Likewise.
9688 (clone_agent_expr): Likewise.
9689 * regcache.c (init_register_cache): Likewise.
9690 * remote-utils.c (putpkt_binary_1): Likewise.
9691 (decode_M_packet): Likewise.
9692 (decode_X_packet): Likewise.
9693 (look_up_one_symbol): Likewise.
9694 (relocate_instruction): Likewise.
9695 (monitor_output): Likewise.
9696 * server.c (handle_search_memory): Likewise.
9697 (handle_qxfer_exec_file): Likewise.
9698 (handle_qxfer_libraries): Likewise.
9699 (handle_qxfer): Likewise.
9700 (handle_query): Likewise.
9701 (handle_v_cont): Likewise.
9702 (handle_v_run): Likewise.
9703 (captured_main): Likewise.
9704 * target.c (write_inferior_memory): Likewise.
9705 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9706 * tracepoint.c (init_trace_buffer): Likewise.
9707 (add_tracepoint_action): Likewise.
9708 (add_traceframe): Likewise.
9709 (add_traceframe_block): Likewise.
9710 (cmd_qtdpsrc): Likewise.
9711 (cmd_qtdv): Likewise.
9712 (cmd_qtstatus): Likewise.
9713 (response_source): Likewise.
9714 (response_tsv): Likewise.
9715 (cmd_qtnotes): Likewise.
9716 (gdb_collect): Likewise.
9717 (initialize_tracepoint): Likewise.
9719 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9721 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9722 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9723 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9725 (enum aarch64_condition_codes): New enum.
9726 (w0): New static global.
9729 (struct aarch64_memory_operand) <type>: New
9730 MEMORY_OPERAND_POSTINDEX type.
9731 (postindex_memory_operand): New helper function.
9732 (emit_ret): New function.
9733 (emit_load_store_pair): New function, factored out of emit_stp
9734 with support for MEMORY_OPERAND_POSTINDEX.
9735 (emit_stp): Rewrite using emit_load_store_pair.
9736 (emit_ldp): New function.
9737 (emit_load_store): Likewise.
9738 (emit_ldr): Mention post-index instruction in comment.
9739 (emit_ldrh): New function.
9740 (emit_ldrb): New function.
9741 (emit_ldrsw): Mention post-index instruction in comment.
9742 (emit_str): Likewise.
9743 (emit_subs): New function.
9744 (emit_cmp): Likewise.
9745 (emit_and): Likewise.
9746 (emit_orr): Likewise.
9747 (emit_orn): Likewise.
9748 (emit_eor): Likewise.
9749 (emit_mvn): Likewise.
9750 (emit_lslv): Likewise.
9751 (emit_lsrv): Likewise.
9752 (emit_asrv): Likewise.
9753 (emit_mul): Likewise.
9754 (emit_sbfm): Likewise.
9755 (emit_sbfx): Likewise.
9756 (emit_ubfm): Likewise.
9757 (emit_ubfx): Likewise.
9758 (emit_csinc): Likewise.
9759 (emit_cset): Likewise.
9760 (emit_nop): Likewise.
9761 (emit_ops_insns): New helper function.
9762 (emit_pop): Likewise.
9763 (emit_push): Likewise.
9764 (aarch64_emit_prologue): New function.
9765 (aarch64_emit_epilogue): Likewise.
9766 (aarch64_emit_add): Likewise.
9767 (aarch64_emit_sub): Likewise.
9768 (aarch64_emit_mul): Likewise.
9769 (aarch64_emit_lsh): Likewise.
9770 (aarch64_emit_rsh_signed): Likewise.
9771 (aarch64_emit_rsh_unsigned): Likewise.
9772 (aarch64_emit_ext): Likewise.
9773 (aarch64_emit_log_not): Likewise.
9774 (aarch64_emit_bit_and): Likewise.
9775 (aarch64_emit_bit_or): Likewise.
9776 (aarch64_emit_bit_xor): Likewise.
9777 (aarch64_emit_bit_not): Likewise.
9778 (aarch64_emit_equal): Likewise.
9779 (aarch64_emit_less_signed): Likewise.
9780 (aarch64_emit_less_unsigned): Likewise.
9781 (aarch64_emit_ref): Likewise.
9782 (aarch64_emit_if_goto): Likewise.
9783 (aarch64_emit_goto): Likewise.
9784 (aarch64_write_goto_address): Likewise.
9785 (aarch64_emit_const): Likewise.
9786 (aarch64_emit_call): Likewise.
9787 (aarch64_emit_reg): Likewise.
9788 (aarch64_emit_pop): Likewise.
9789 (aarch64_emit_stack_flush): Likewise.
9790 (aarch64_emit_zero_ext): Likewise.
9791 (aarch64_emit_swap): Likewise.
9792 (aarch64_emit_stack_adjust): Likewise.
9793 (aarch64_emit_int_call_1): Likewise.
9794 (aarch64_emit_void_call_2): Likewise.
9795 (aarch64_emit_eq_goto): Likewise.
9796 (aarch64_emit_ne_goto): Likewise.
9797 (aarch64_emit_lt_goto): Likewise.
9798 (aarch64_emit_le_goto): Likewise.
9799 (aarch64_emit_gt_goto): Likewise.
9800 (aarch64_emit_ge_got): Likewise.
9801 (aarch64_emit_ops_impl): New static global variable.
9802 (aarch64_emit_ops): New target function, return
9803 &aarch64_emit_ops_impl.
9804 (struct linux_target_ops): Install it.
9806 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9808 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9809 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9811 * linux-aarch64-ipa.c: New file.
9812 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9814 (aarch64_get_thread_area): New target method.
9815 (extract_signed_bitfield): New helper function.
9816 (aarch64_decode_ldr_literal): New function.
9817 (enum aarch64_opcodes): New enum.
9818 (struct aarch64_register): New struct.
9819 (struct aarch64_operand): New struct.
9820 (x0): New static global.
9829 (aarch64_register): New helper function.
9830 (register_operand): Likewise.
9831 (immediate_operand): Likewise.
9832 (struct aarch64_memory_operand): New struct.
9833 (offset_memory_operand): New helper function.
9834 (preindex_memory_operand): Likewise.
9835 (enum aarch64_system_control_registers): New enum.
9836 (ENCODE): New macro.
9837 (emit_insn): New helper function.
9838 (emit_b): New function.
9839 (emit_bcond): Likewise.
9840 (emit_cb): Likewise.
9841 (emit_tb): Likewise.
9842 (emit_blr): Likewise.
9843 (emit_stp): Likewise.
9844 (emit_ldp_q_offset): Likewise.
9845 (emit_stp_q_offset): Likewise.
9846 (emit_load_store): Likewise.
9847 (emit_ldr): Likewise.
9848 (emit_ldrsw): Likewise.
9849 (emit_str): Likewise.
9850 (emit_ldaxr): Likewise.
9851 (emit_stxr): Likewise.
9852 (emit_stlr): Likewise.
9853 (emit_data_processing_reg): Likewise.
9854 (emit_data_processing): Likewise.
9855 (emit_add): Likewise.
9856 (emit_sub): Likewise.
9857 (emit_mov): Likewise.
9858 (emit_movk): Likewise.
9859 (emit_mov_addr): Likewise.
9860 (emit_mrs): Likewise.
9861 (emit_msr): Likewise.
9862 (emit_sevl): Likewise.
9863 (emit_wfe): Likewise.
9864 (append_insns): Likewise.
9865 (can_encode_int32_in): New helper function.
9866 (aarch64_relocate_instruction): New function.
9867 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9868 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9869 (struct linux_target_ops): Install aarch64_get_thread_area,
9870 aarch64_install_fast_tracepoint_jump_pad and
9871 aarch64_get_min_fast_tracepoint_insn_len.
9873 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9875 * Makefile.in (aarch64-insn.o): New rule.
9876 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9878 2015-09-21 Yao Qi <yao.qi@linaro.org>
9880 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9882 2015-09-21 Yao Qi <yao.qi@linaro.org>
9884 * tracepoint.c (max_jump_pad_size): Remove.
9886 2015-09-18 Yao Qi <yao.qi@linaro.org>
9888 * linux-aarch64-low.c: Don't include sys/uio.h.
9889 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9891 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
9893 * tracepoint.c (eval_result_type): Change prototype.
9894 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9896 2015-09-15 Pedro Alves <palves@redhat.com>
9898 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9899 Check whether to report exec events instead of checking whether
9900 multiprocess is enabled.
9902 2015-09-15 Pedro Alves <palves@redhat.com>
9905 * remote-utils.c (prepare_resume_reply): Merge
9906 TARGET_WAITKIND_VFORK_DONE switch case with the
9907 TARGET_WAITKIND_FORKED case.
9909 2015-09-15 Yao Qi <yao.qi@linaro.org>
9911 * server.c (handle_query): Check string comparison using
9912 "else if" instead of "if".
9914 2015-09-15 Yao Qi <yao.qi@linaro.org>
9916 * server.c (vCont_supported): New global variable.
9917 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9918 matches. Append ";vContSupported+" to own_buf.
9919 (handle_v_requests): Append ";s;S" to own_buf if target supports
9920 hardware single step or vCont_supported is false.
9921 (capture_main): Set vCont_supported to zero.
9923 2015-09-15 Yao Qi <yao.qi@linaro.org>
9925 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9927 (linux_supports_hardware_single_step): ... New function.
9928 (linux_target_ops): Update.
9929 * lynx-low.c (lynx_target_ops): Set field
9930 supports_hardware_single_step to target_can_do_hardware_single_step.
9931 * nto-low.c (nto_target_ops): Likewise.
9932 * spu-low.c (spu_target_ops): Likewise.
9933 * win32-low.c (win32_target_ops): Likewise.
9934 * target.c (target_can_do_hardware_single_step): New function.
9935 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9936 Remove. <supports_hardware_single_step>: New field.
9937 (target_supports_conditional_breakpoints): Remove.
9938 (target_supports_hardware_single_step): New macro.
9939 (target_can_do_hardware_single_step): Declare.
9940 * server.c (handle_query): Use target_supports_hardware_single_step
9941 instead of target_supports_conditional_breakpoints.
9943 2015-09-15 Yao Qi <yao.qi@linaro.org>
9945 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9947 (struct linux_target_ops the_low_target): Install
9948 aarch64_linux_siginfo_fixup.
9950 2015-09-11 Don Breazeal <donb@codesourcery.com>
9951 Luis Machado <lgustavo@codesourcery.com>
9953 * linux-low.c (linux_mourn): Static declaration.
9954 (linux_arch_setup): Move in front of
9955 handle_extended_wait.
9956 (linux_arch_setup_thread): New function.
9957 (handle_extended_wait): Handle exec events. Call
9958 linux_arch_setup_thread. Make event_lwp argument a
9959 pointer-to-a-pointer.
9960 (check_zombie_leaders): Do not check stopped threads.
9961 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9962 (linux_low_filter_event): Add lwp and thread for exec'ing
9963 non-leader thread if leader thread has been deleted.
9964 Refactor code into linux_arch_setup_thread and call it.
9965 Pass child lwp pointer by reference to handle_extended_wait.
9966 (linux_wait_for_event_filtered): Update comment.
9967 (linux_wait_1): Prevent clobbering exec event status.
9968 (linux_supports_exec_events): New function.
9969 (linux_target_ops) <supports_exec_events>: Initialize new member.
9970 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9972 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9973 * server.c (report_exec_events): New global variable.
9974 (handle_query): Handle qSupported query for exec-events feature.
9975 (captured_main): Initialize report_exec_events.
9976 * server.h (report_exec_events): Declare new global variable.
9977 * target.h (struct target_ops) <supports_exec_events>: New
9979 (target_supports_exec_events): New macro.
9980 * win32-low.c (win32_target_ops) <supports_exec_events>:
9981 Initialize new member.
9983 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
9985 * linux-low.c (linux_low_enable_btrace): Remove.
9986 (linux_target_ops): Replace linux_low_enable_btrace with
9987 linux_enable_btrace.
9989 2015-09-03 Yao Qi <yao.qi@linaro.org>
9991 * linux-aarch64-low.c (aarch64_insert_point): Call
9992 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
9995 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
9997 * linux-low.c (check_stopped_by_breakpoint): Use
9998 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10000 2015-08-27 Pedro Alves <palves@redhat.com>
10002 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10004 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10006 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10007 the XNEW-family equivalent.
10008 (compile_bytecodes): Likewise.
10009 * dll.c (loaded_dll): Likewise.
10010 * event-loop.c (append_callback_event): Likewise.
10011 (create_file_handler): Likewise.
10012 (create_file_event): Likewise.
10013 * hostio.c (handle_open): Likewise.
10014 * inferiors.c (add_thread): Likewise.
10015 (add_process): Likewise.
10016 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10017 * linux-arm-low.c (arm_new_process): Likewise.
10018 (arm_new_thread): Likewise.
10019 * linux-low.c (add_to_pid_list): Likewise.
10020 (linux_add_process): Likewise.
10021 (handle_extended_wait): Likewise.
10022 (add_lwp): Likewise.
10023 (enqueue_one_deferred_signal): Likewise.
10024 (enqueue_pending_signal): Likewise.
10025 (linux_resume_one_lwp_throw): Likewise.
10026 (linux_resume_one_thread): Likewise.
10027 (linux_read_memory): Likewise.
10028 (linux_write_memory): Likewise.
10029 * linux-mips-low.c (mips_linux_new_process): Likewise.
10030 (mips_linux_new_thread): Likewise.
10031 (mips_add_watchpoint): Likewise.
10032 * linux-x86-low.c (initialize_low_arch): Likewise.
10033 * lynx-low.c (lynx_add_process): Likewise.
10034 * mem-break.c (set_raw_breakpoint_at): Likewise.
10035 (set_breakpoint): Likewise.
10036 (add_condition_to_breakpoint): Likewise.
10037 (add_commands_to_breakpoint): Likewise.
10038 (clone_agent_expr): Likewise.
10039 (clone_one_breakpoint): Likewise.
10040 * regcache.c (new_register_cache): Likewise.
10041 * remote-utils.c (look_up_one_symbol): Likewise.
10042 * server.c (queue_stop_reply): Likewise.
10043 (start_inferior): Likewise.
10044 (queue_stop_reply_callback): Likewise.
10045 (handle_target_event): Likewise.
10046 * spu-low.c (fetch_ppc_memory): Likewise.
10047 (store_ppc_memory): Likewise.
10048 * target.c (set_target_ops): Likewise.
10049 * thread-db.c (thread_db_load_search): Likewise.
10050 (try_thread_db_load_1): Likewise.
10051 * tracepoint.c (add_tracepoint): Likewise.
10052 (add_tracepoint_action): Likewise.
10053 (create_trace_state_variable): Likewise.
10054 (cmd_qtdpsrc): Likewise.
10055 (cmd_qtro): Likewise.
10056 (add_while_stepping_state): Likewise.
10057 * win32-low.c (child_add_thread): Likewise.
10058 (get_image_name): Likewise.
10060 2015-08-25 Yao Qi <yao.qi@linaro.org>
10062 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10064 2015-08-25 Yao Qi <yao.qi@linaro.org>
10066 * Makefile.in (aarch64-linux.o): New rule.
10067 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10069 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10070 (aarch64_init_debug_reg_state): Make it extern.
10071 (aarch64_linux_prepare_to_resume): Remove.
10073 2015-08-25 Yao Qi <yao.qi@linaro.org>
10075 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10076 lwp_arch_private_info and ptid_of_lwp.
10078 2015-08-25 Yao Qi <yao.qi@linaro.org>
10080 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10081 Find proc_info by find_process_pid. All callers updated.
10083 2015-08-25 Yao Qi <yao.qi@linaro.org>
10085 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10087 (debug_reg_change_callback): Remove.
10088 (aarch64_notify_debug_reg_change): Remove.
10090 2015-08-25 Yao Qi <yao.qi@linaro.org>
10092 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10093 Call current_lwp_ptid.
10095 2015-08-25 Yao Qi <yao.qi@linaro.org>
10097 * linux-aarch64-low.c (debug_reg_change_callback): Use
10100 2015-08-25 Yao Qi <yao.qi@linaro.org>
10102 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10104 2015-08-25 Yao Qi <yao.qi@linaro.org>
10106 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10108 2015-08-25 Yao Qi <yao.qi@linaro.org>
10110 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10113 2015-08-25 Yao Qi <yao.qi@linaro.org>
10115 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10117 (debug_reg_change_callback): Remove argument entry and add argument
10118 lwp. Remove local variable thread. Don't print thread id in the
10119 debugging output. Don't check whether pid of thread equals to pid.
10120 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10121 iterate_over_lwps instead find_inferior.
10123 2015-08-24 Pedro Alves <palves@redhat.com>
10125 * inferiors.c (get_first_process): New function.
10126 * inferiors.h (get_first_process): New declaration.
10127 * remote-utils.c (read_ptid): Default to the first process in the
10128 list, instead of to the current thread's process.
10130 2015-08-24 Pedro Alves <palves@redhat.com>
10132 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10133 * event-loop.c: Likewise.
10134 * remote-utils.c: Likewise.
10135 * tracepoint.c: Likewise.
10137 2015-08-24 Pedro Alves <palves@redhat.com>
10139 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10142 2015-08-21 Pedro Alves <palves@redhat.com>
10144 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10145 instead of literal 1.
10147 2015-08-21 Pedro Alves <palves@redhat.com>
10149 * tdesc.c (default_description): Explicitly zero-initialize.
10151 2015-08-21 Pedro Alves <palves@redhat.com>
10154 * inferiors.c (remove_thread): Discard any pending stop reply for
10156 * server.c (remove_all_on_match_pid): Rename to ...
10157 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10159 (discard_queued_stop_replies): Change parameter to a ptid. Now
10161 (handle_v_kill, kill_inferior_callback, captured_main)
10162 (process_serial_event): Adjust.
10163 * server.h (discard_queued_stop_replies): Declare.
10165 2015-08-21 Pedro Alves <palves@redhat.com>
10167 * linux-low.c (wait_for_sigstop): Always switch to no thread
10168 selected if the previously current thread dies.
10169 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10170 process instead of the current thread's.
10171 * remote-utils.c (input_interrupt): Don't check if there's no
10173 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10174 current thread to the general thread fails, error out.
10175 (handle_qxfer_auxv, handle_qxfer_libraries)
10176 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10177 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10178 (handle_query): Check if there's a thread selected instead of
10179 checking whether there's any thread in the thread list.
10180 (handle_qxfer_threads, handle_qxfer_btrace)
10181 (handle_qxfer_btrace_conf): Don't error out early if there's no
10182 thread in the thread list.
10183 (handle_v_cont, myresume): Don't set the current thread to the
10185 (process_serial_event) <Hg handling>: Also set thread_id if the
10186 previous general thread is still alive.
10187 (process_serial_event) <g/G handling>: If setting the current
10188 thread to the general thread fails, error out.
10189 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10190 thread's lwp instead of the current thread's.
10191 * target.c (set_desired_thread): If the desired thread was not
10192 found, leave the current thread pointing to NULL. Return an int
10193 (boolean) indicating success.
10194 * target.h (set_desired_thread): Change return type to int.
10196 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10198 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10199 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10201 (ps_get_thread_area): New function.
10203 2015-08-19 Gary Benson <gbenson@redhat.com>
10205 * hostio.c (handle_pread): Do not attempt to read more data
10206 than hostio_reply_with_data can fit in a packet.
10208 2015-08-18 Joel Brobecker <brobecker@adacore.com>
10210 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10212 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10214 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10216 2015-08-06 Pedro Alves <palves@redhat.com>
10218 * tracepoint.c (expr_eval_result): Now an int.
10220 2015-08-06 Pedro Alves <palves@redhat.com>
10222 * gdbthread.h (struct regcache): Forward declare.
10223 (struct thread_info) <regcache_data>: Now a struct regcache
10225 * inferiors.c (inferior_regcache_data)
10226 (set_inferior_regcache_data): Now work with struct regcache
10228 * inferiors.h (struct regcache): Forward declare.
10229 (inferior_regcache_data, set_inferior_regcache_data): Now work
10230 with struct regcache pointers.
10231 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10232 (free_register_cache_thread): Remove struct regcache pointer
10235 2015-08-06 Pedro Alves <palves@redhat.com>
10237 * server.c (captured_main): On error, print the exception message
10238 to stderr, and if run_once is set, throw a quit.
10240 2015-08-06 Pedro Alves <palves@redhat.com>
10242 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10243 the current thread.
10245 2015-08-06 Pedro Alves <palves@redhat.com>
10247 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10248 reading beyond the passed in buffer length.
10250 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10252 * tracepoint.c (symbol_list) <required>: Remove.
10254 2015-08-06 Pedro Alves <palves@redhat.com>
10256 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10257 count if stopping and suspending threads.
10258 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10259 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10260 (linux_detach): Complete an ongoing step-over.
10261 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10263 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10264 (linux_wait_1): If passing a signal to the inferior after
10265 finishing a step-over, unsuspend and re-resume all lwps. If we
10266 see a single-step event but the thread should be continuing, don't
10267 pass the trap to gdb.
10268 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10269 internal_error instead of gdb_assert.
10270 (enqueue_pending_signal): New function.
10271 (check_ptrace_stopped_lwp_gone): Add debug output.
10272 (start_step_over): Use internal_error instead of gdb_assert.
10273 (complete_ongoing_step_over): New function.
10274 (linux_resume_one_thread): Don't resume a suspended thread.
10275 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10278 2015-08-06 Pedro Alves <palves@redhat.com>
10280 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10281 (linux_thread_alive): Use lwp_is_marked_dead.
10282 (extended_event_reported): Delete.
10283 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10284 instead of extended_event_reported.
10285 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10287 (lwp_is_marked_dead): New function.
10288 (lwp_running): Use lwp_is_marked_dead.
10289 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10292 2015-08-06 Pedro Alves <palves@redhat.com>
10294 * linux-low.c (linux_wait_1): Move fork event output out of the
10295 !report_to_gdb check. Pass event_child->waitstatus to
10296 target_waitstatus_to_string instead of ourstatus.
10298 2015-08-04 Yao Qi <yao.qi@linaro.org>
10300 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10301 if current_thread is 32 bit.
10303 2015-08-04 Yao Qi <yao.qi@linaro.org>
10305 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10306 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10307 * server.c (extended_protocol): Remove "static".
10308 * server.h (extended_protocol): Declare it.
10310 2015-08-04 Yao Qi <yao.qi@linaro.org>
10312 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10313 both aarch64 and aarch32.
10314 (aarch64_set_pc): Likewise.
10316 2015-08-04 Yao Qi <yao.qi@linaro.org>
10318 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10319 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10320 arm-with-neon.xml to srv_xmlfiles.
10321 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10322 (is_64bit_tdesc): New function.
10323 (aarch64_linux_read_description): New function.
10324 (aarch64_arch_setup): Call aarch64_linux_read_description.
10325 (regs_info): Rename to regs_info_aarch64.
10326 (aarch64_regs_info): Return right regs_info.
10327 (initialize_low_arch): Call initialize_low_arch_aarch32.
10329 2015-08-04 Yao Qi <yao.qi@linaro.org>
10331 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10332 * linux-aarch32-low.c: New file.
10333 * linux-aarch32-low.h: New file.
10334 * linux-arm-low.c (arm_fill_gregset): Move it to
10335 linux-aarch32-low.c.
10336 (arm_store_gregset): Likewise.
10337 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10338 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10339 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10340 (regs_info): Rename to regs_info_arm.
10341 (arm_regs_info): Return regs_info_aarch32 if
10342 have_ptrace_getregset is 1 and target description is
10343 arm_with_neon or arm_with_vfpv3.
10344 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10345 Call initialize_low_arch_aarch32 instead.
10347 2015-08-04 Yao Qi <yao.qi@linaro.org>
10349 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10350 * linux-low.c: ... here.
10351 * linux-low.h (have_ptrace_getregset): Declare it.
10353 2015-08-04 Pedro Alves <palves@redhat.com>
10355 * thread-db.c (struct thread_db): Use new typedefs.
10356 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10358 (disable_thread_event_reporting): Cast result of dlsym to
10359 destination function pointer type.
10360 (thread_db_mourn): Use td_ta_delete_ftype.
10362 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10364 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10366 (CDX_BREAKPOINT): Define for R2.
10367 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10368 (the_low_target): Add comments.
10370 2015-07-30 Yao Qi <yao.qi@linaro.org>
10372 * linux-arm-low.c (arm_hwcap): Remove it.
10373 (arm_read_description): New local variable arm_hwcap. Don't
10374 set arm_hwcap to zero.
10376 2015-07-30 Yao Qi <yao.qi@linaro.org>
10378 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10379 Use regcache->tdesc instead.
10380 (arm_store_wmmxregset): Likewise.
10381 (arm_fill_vfpregset): Likewise.
10382 (arm_store_vfpregset): Likewise.
10384 2015-07-30 Yao Qi <yao.qi@linaro.org>
10386 * linux-arm-low.c: Include arch/arm.h.
10387 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10388 (arm_store_gregset): Likewise.
10390 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10392 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10393 ptrace's 4th parameter.
10395 2015-07-27 Yao Qi <yao.qi@linaro.org>
10397 * configure.srv (case aarch64*-*-linux*): Don't set
10400 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10402 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10404 * linux-arm-low.c: Likewise.
10405 * linux-cris-low.c: Likewise.
10406 * linux-crisv32-low.c: Likewise.
10407 * linux-low.c: Likewise.
10408 * linux-m68k-low.c: Likewise.
10409 * linux-mips-low.c: Likewise.
10410 * linux-nios2-low.c: Likewise.
10411 * linux-s390-low.c: Likewise.
10412 * linux-sparc-low.c: Likewise.
10413 * linux-tic6x-low.c: Likewise.
10414 * linux-tile-low.c: Likewise.
10415 * linux-x86-low.c: Likewise.
10417 2015-07-24 Pedro Alves <palves@redhat.com>
10419 * config.in: Regenerate.
10420 * configure: Regenerate.
10422 2015-07-24 Pedro Alves <palves@redhat.com>
10424 * acinclude.m4: Include ../ptrace.m4.
10425 * configure.ac: Call GDB_AC_PTRACE.
10426 * config.in, configure: Regenerate.
10428 2015-07-24 Yao Qi <yao.qi@linaro.org>
10430 * linux-low.c (linux_create_inferior): Remove setting to
10431 proc->priv->new_inferior.
10432 (linux_attach): Likewise.
10433 (linux_low_filter_event): Likewise.
10434 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10436 2015-07-24 Yao Qi <yao.qi@linaro.org>
10438 * linux-low.c (linux_arch_setup): New function.
10439 (linux_low_filter_event): If proc->tdesc is NULL and
10440 proc->attached is true, call the_low_target.arch_setup.
10441 Otherwise, keep status pending, and return.
10442 (linux_resume_one_lwp_throw): Don't call get_pc if
10443 thread->while_stepping isn't NULL. Don't call
10444 get_thread_regcache if proc->tdesc is NULL.
10445 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10446 (linux_target_ops): Install arch_setup.
10447 * server.c (start_inferior): Call the_target->arch_setup.
10448 * target.h (struct target_ops) <arch_setup>: New field.
10449 (target_arch_setup): New marco.
10450 * lynx-low.c (lynx_target_ops): Update.
10451 * nto-low.c (nto_target_ops): Update.
10452 * spu-low.c (spu_target_ops): Update.
10453 * win32-low.c (win32_target_ops): Update.
10455 2015-07-24 Yao Qi <yao.qi@linaro.org>
10457 * linux-low.c (linux_add_process): Don't set
10458 proc->priv->new_inferior.
10459 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10460 (linux_attach): Likewise.
10462 2015-07-24 Yao Qi <yao.qi@linaro.org>
10464 * server.c (start_inferior): Code refactor.
10466 2015-07-24 Yao Qi <yao.qi@linaro.org>
10468 * server.c (process_serial_event): Set general_thread.
10470 2015-07-21 Yao Qi <yao.qi@linaro.org>
10472 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10473 aarch64_linux_get_debug_reg_capacity.
10475 2015-07-17 Yao Qi <yao.qi@linaro.org>
10477 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10478 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10479 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10480 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10481 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10482 (AARCH64_HWP_ALIGNMENT): Likewise.
10483 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10484 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10485 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10486 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10487 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10488 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10489 (struct aarch64_debug_reg_state): Likewise.
10490 (struct arch_lwp_info): Likewise.
10491 (aarch64_align_watchpoint): Likewise.
10492 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10493 (aarch64_watchpoint_length): Likewise.
10494 (aarch64_point_encode_ctrl_reg): Likewise
10495 (aarch64_point_is_aligned): Likewise.
10496 (aarch64_align_watchpoint): Likewise.
10497 (aarch64_linux_set_debug_regs):
10498 (aarch64_dr_state_insert_one_point): Likewise.
10499 (aarch64_dr_state_remove_one_point): Likewise.
10500 (aarch64_handle_breakpoint): Likewise.
10501 (aarch64_handle_aligned_watchpoint): Likewise.
10502 (aarch64_handle_unaligned_watchpoint): Likewise.
10503 (aarch64_handle_watchpoint): Likewise.
10505 2015-07-17 Yao Qi <yao.qi@linaro.org>
10507 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10508 and don't aarch64_get_debug_reg_state. All callers update.
10509 (aarch64_handle_aligned_watchpoint): Likewise.
10510 (aarch64_handle_unaligned_watchpoint): Likewise.
10511 (aarch64_handle_watchpoint): Likewise.
10512 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10513 (aarch64_remove_point): Likewise.
10515 2015-07-17 Yao Qi <yao.qi@linaro.org>
10517 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10519 (aarch64_handle_unaligned_watchpoint): Likewise.
10521 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10523 Revert the previous 3 commits:
10524 Move gdb_regex* to common/
10525 Move linux_find_memory_regions_full & co.
10526 gdbserver build-id attribute generator
10528 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10529 Jan Kratochvil <jan.kratochvil@redhat.com>
10531 gdbserver build-id attribute generator.
10532 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10533 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10534 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10536 (get_dynamic): Use find_pdhr to traverse program headers.
10537 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10538 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10539 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10540 (get_hex_build_id): New.
10541 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10542 to reply XML document.
10544 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10545 Jan Kratochvil <jan.kratochvil@redhat.com>
10547 * target.c: Include target/target-utils.h and fcntl.h.
10548 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10549 (target_fileio_read_stralloc): New functions.
10551 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10553 * Makefile.in (OBS): Add gdb_regex.o.
10554 (gdb_regex.o): New.
10555 * config.in: Rebuilt.
10556 * configure: Rebuilt.
10558 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10559 Jan Kratochvil <jan.kratochvil@redhat.com>
10561 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10562 * Makefile.in (OBS): Add target-utils.o.
10563 (linux-maps.o, target-utils.o): New.
10564 * configure.srv (srv_linux_obj): Add linux-maps.o.
10566 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10568 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10569 function, return 1.
10570 (the_low_target): Install it.
10572 2015-07-14 Pedro Alves <palves@redhat.com>
10574 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10575 Instead, ignore ECHILD, and throw an error for other errnos.
10577 2015-07-10 Pedro Alves <palves@redhat.com>
10579 * event-loop.c (struct callback_event) <data>: Change type to
10580 gdb_client_data instance instead of gdb_client_data pointer.
10581 (append_callback_event): Adjust.
10583 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10585 * linux-aarch64-low.c: Add comments for each linux_target_ops
10586 method. Remove comments already covered in target_ops and
10587 linux_target_ops definitions.
10588 (the_low_target): Add comments for each unimplemented method.
10590 2015-07-09 Yao Qi <yao.qi@linaro.org>
10592 * linux-aarch64-low.c (aarch64_regmap): Remove.
10593 (aarch64_usrregs_info): Remove.
10594 (regs_info): Set field usrregs to NULL.
10596 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10598 * linux-low.c: Include "rsp-low.h"
10599 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10600 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10601 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10602 (handle_btrace_enable_pt): New.
10603 (handle_btrace_general_set): Support "pt".
10604 (handle_btrace_conf_general_set): Support "pt:size".
10606 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10608 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10611 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10613 * linux-aarch64-low.c: Remove comment about endianness.
10614 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10615 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10618 2015-06-24 Gary Benson <gbenson@redhat.com>
10620 * linux-i386-ipa.c (stdint.h): Do not include.
10621 * lynx-i386-low.c (stdint.h): Likewise.
10622 * lynx-ppc-low.c (stdint.h): Likewise.
10623 * mem-break.c (stdint.h): Likewise.
10624 * thread-db.c (stdint.h): Likewise.
10625 * tracepoint.c (stdint.h): Likewise.
10626 * win32-low.c (stdint.h): Likewise.
10628 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10630 * server.c (write_qxfer_response): Update call to
10631 remote_escape_output.
10633 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10634 Jan Kratochvil <jan.kratochvil@redhat.com>
10636 Merge multiple hex conversions.
10637 * gdbreplay.c (tohex): Rename to 'fromhex'.
10638 (logchar): Use fromhex.
10640 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10642 * server.c (handle_qxfer_libraries): Set `version' attribute for
10645 2015-06-10 Gary Benson <gbenson@redhat.com>
10647 * target.h (struct target_ops) <multifs_open>: New field.
10648 <multifs_unlink>: Likewise.
10649 <multifs_readlink>: Likewise.
10650 * linux-low.c (nat/linux-namespaces.h): New include.
10651 (linux_target_ops): Initialize the_target->multifs_open,
10652 the_target->multifs_unlink and the_target->multifs_readlink.
10653 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10654 * hostio.c (hostio_fs_pid): New static variable.
10655 (hostio_handle_new_gdb_connection): New function.
10656 (handle_setfs): Likewise.
10657 (handle_open): Use the_target->multifs_open as appropriate.
10658 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10659 (handle_readlink): Use the_target->multifs_readlink as
10661 (handle_vFile): Handle vFile:setfs packets.
10662 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10663 after target_handle_new_gdb_connection.
10665 2015-06-10 Gary Benson <gbenson@redhat.com>
10667 * configure.ac (AC_CHECK_FUNCS): Add setns.
10668 * config.in: Regenerate.
10669 * configure: Likewise.
10670 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10671 (linux-namespaces.o): New rule.
10672 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10674 2015-06-09 Gary Benson <gbenson@redhat.com>
10676 * hostio.c (handle_open): Process mode argument with
10677 fileio_to_host_mode.
10679 2015-06-01 Yao Qi <yao.qi@linaro.org>
10681 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10682 * linux-x86-low.c: Likewise.
10684 2015-05-28 Don Breazeal <donb@codesourcery.com>
10686 * linux-low.c (handle_extended_wait): Initialize
10687 thread_info.last_resume_kind for new fork children.
10689 2015-05-15 Pedro Alves <palves@redhat.com>
10691 * target.h (target_handle_new_gdb_connection): Rewrite using if
10692 wrapped in do/while.
10694 2015-05-14 Joel Brobecker <brobecker@adacore.com>
10696 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10697 * configure, config.in: Regenerate.
10698 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10701 2015-05-12 Don Breazeal <donb@codesourcery.com>
10703 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10704 PTRACE_EVENT_VFORK_DONE.
10705 (linux_low_ptrace_options, extended_event_reported): Add vfork
10707 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10708 and "vforkdone" for RSP 'T' Stop Reply Packet.
10709 * server.h (report_vfork_events): Declare
10712 2015-05-12 Don Breazeal <donb@codesourcery.com>
10714 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10715 (the_low_target) <new_fork>: Initialize new member.
10716 * linux-arm-low.c (arm_new_fork): New function.
10717 (the_low_target) <new_fork>: Initialize new member.
10718 * linux-low.c (handle_extended_wait): Call new target function
10720 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10721 * linux-mips-low.c (mips_add_watchpoint): New function
10722 extracted from mips_insert_point.
10723 (the_low_target) <new_fork>: Initialize new member.
10724 (mips_linux_new_fork): New function.
10725 (mips_insert_point): Call mips_add_watchpoint.
10726 * linux-x86-low.c (x86_linux_new_fork): New function.
10727 (the_low_target) <new_fork>: Initialize new member.
10729 2015-05-12 Don Breazeal <donb@codesourcery.com>
10731 * linux-low.c (handle_extended_wait): Implement return value,
10732 rename argument 'event_child' to 'event_lwp', handle
10733 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10734 (linux_low_ptrace_options): New function.
10735 (linux_low_filter_event): Call linux_low_ptrace_options,
10736 use different argument fo linux_enable_event_reporting,
10737 use return value from handle_extended_wait.
10738 (extended_event_reported): New function.
10739 (linux_wait_1): Call extended_event_reported and set
10740 status to report fork events.
10741 (linux_write_memory): Add pid to debug message.
10742 (reset_lwp_ptrace_options_callback): New function.
10743 (linux_handle_new_gdb_connection): New function.
10744 (linux_target_ops): Initialize new structure member.
10745 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10746 * lynx-low.c: Initialize new structure member.
10747 * remote-utils.c (prepare_resume_reply): Implement stop reason
10748 "fork" for "T" stop message.
10749 * server.c (handle_query): Call handle_new_gdb_connection.
10750 * server.h (report_fork_events): Declare global flag.
10751 * target.h (struct target_ops) <handle_new_gdb_connection>:
10753 (target_handle_new_gdb_connection): New macro.
10754 * win32-low.c: Initialize new structure member.
10756 2015-05-12 Don Breazeal <donb@codesourcery.com>
10758 * mem-break.c (APPEND_TO_LIST): Define macro.
10759 (clone_agent_expr): New function.
10760 (clone_one_breakpoint): New function.
10761 (clone_all_breakpoints): New function.
10762 * mem-break.h: Declare new functions.
10764 2015-05-12 Don Breazeal <donb@codesourcery.com>
10766 * linux-low.c (linux_supports_fork_events): New function.
10767 (linux_supports_vfork_events): New function.
10768 (linux_target_ops): Initialize new structure members.
10769 (initialize_low): Call linux_check_ptrace_features.
10770 * lynx-low.c (lynx_target_ops): Initialize new structure
10772 * server.c (report_fork_events, report_vfork_events):
10774 (handle_query): Add new features to qSupported packet and
10776 (captured_main): Initialize new global variables.
10777 * target.h (struct target_ops) <supports_fork_events>:
10779 <supports_vfork_events>: New member.
10780 (target_supports_fork_events): New macro.
10781 (target_supports_vfork_events): New macro.
10782 * win32-low.c (win32_target_ops): Initialize new structure
10785 2015-05-12 Gary Benson <gbenson@redhat.com>
10787 * server.c (handle_qxfer_exec_file): Use current process
10790 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10792 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10793 Remove HAVE_PTRACE_GETREGS conditionals.
10794 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10795 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10797 2015-05-08 Yao Qi <yao.qi@linaro.org>
10799 * linux-low.c (linux_supports_conditional_breakpoints): New
10801 (linux_target_ops): Install new target method.
10802 * lynx-low.c (lynx_target_ops): Install NULL hook for
10803 supports_conditional_breakpoints.
10804 * nto-low.c (nto_target_ops): Likewise.
10805 * spu-low.c (spu_target_ops): Likewise.
10806 * win32-low.c (win32_target_ops): Likewise.
10807 * server.c (handle_query): Check
10808 target_supports_conditional_breakpoints.
10809 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10811 (target_supports_conditional_breakpoints): New macro.
10813 2015-05-06 Pedro Alves <palves@redhat.com>
10816 * server.c (start_inferior): If the process exits, mourn it.
10818 2015-04-21 Gary Benson <gbenson@redhat.com>
10820 * hostio.c (fileio_open_flags_to_host): Factored out to
10821 fileio_to_host_openflags in common/fileio.c. Single use
10824 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10826 * linux-xtensa-low.c (xtensa_fill_gregset)
10827 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10830 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10832 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10833 (regs_info): Replace usrregs pointer with NULL.
10835 2015-04-17 Gary Benson <gbenson@redhat.com>
10837 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10838 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10839 * server.c (handle_qxfer_exec_file): New function.
10840 (qxfer_packets): Add exec-file entry.
10841 (handle_query): Report qXfer:exec-file:read as supported packet.
10843 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10845 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10847 2015-04-09 Gary Benson <gbenson@redhat.com>
10849 * hostio-errno.c (errno_to_fileio_error): Remove function.
10850 Update caller to use remote_fileio_to_fio_error.
10852 2015-04-09 Yao Qi <yao.qi@linaro.org>
10854 * linux-low.c (linux_insert_point): Call
10855 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10856 (linux_remove_point): Call remove_memory_breakpoint if type is
10858 * linux-x86-low.c (x86_insert_point): Don't call
10859 insert_memory_breakpoint.
10860 (x86_remove_point): Don't call remove_memory_breakpoint.
10862 2015-04-01 Pedro Alves <palves@redhat.com>
10863 Cleber Rosa <crosa@redhat.com>
10865 * server.c (gdbserver_usage): Reorganize and extend the usage
10868 2015-03-24 Pedro Alves <palves@redhat.com>
10870 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10871 output. Also dump TRAP_TRACE.
10872 (linux_low_filter_event): In debug output, distinguish a
10873 resume_stop SIGSTOP from a delayed SIGSTOP.
10875 2015-03-24 Gary Benson <gbenson@redhat.com>
10877 * linux-x86-low.c (x86_linux_new_thread): Moved to
10879 (x86_linux_prepare_to_resume): Likewise.
10881 2015-03-24 Gary Benson <gbenson@redhat.com>
10883 * Makefile.in (x86-linux-dregs.o): New rule.
10884 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10885 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10886 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10887 (x86_linux_dr_get): Likewise.
10888 (x86_linux_dr_set): Likewise.
10889 (update_debug_registers_callback): Likewise.
10890 (x86_linux_dr_set_addr): Likewise.
10891 (x86_linux_dr_get_addr): Likewise.
10892 (x86_linux_dr_set_control): Likewise.
10893 (x86_linux_dr_get_control): Likewise.
10894 (x86_linux_dr_get_status): Likewise.
10895 (x86_linux_update_debug_registers): Likewise.
10897 2015-03-24 Gary Benson <gbenson@redhat.com>
10899 * linux-x86-low.c (x86_linux_update_debug_registers):
10900 New function, factored out from...
10901 (x86_linux_prepare_to_resume): ...this.
10903 2015-03-24 Gary Benson <gbenson@redhat.com>
10905 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10906 (x86_linux_dr_set): Likewise.
10907 (update_debug_registers_callback): Likewise.
10908 (x86_linux_dr_set_addr): Likewise.
10909 (x86_linux_dr_get_addr): Likewise.
10910 (x86_linux_dr_set_control): Likewise.
10911 (x86_linux_dr_get_control): Likewise.
10912 (x86_linux_dr_get_status): Likewise.
10913 (x86_linux_prepare_to_resume): Likewise.
10915 2015-03-24 Gary Benson <gbenson@redhat.com>
10917 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10918 Use perror_with_name. Pass string through gettext.
10919 (x86_linux_dr_set): Likewise.
10921 2015-03-24 Gary Benson <gbenson@redhat.com>
10923 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10924 (x86_linux_dr_set_addr): ...this.
10925 (x86_dr_low_get_addr): Rename to...
10926 (x86_linux_dr_get_addr): ...this.
10927 (x86_dr_low_set_control): Rename to...
10928 (x86_linux_dr_set_control): ...this.
10929 (x86_dr_low_get_control): Rename to...
10930 (x86_linux_dr_get_control): ...this.
10931 (x86_dr_low_get_status): Rename to...
10932 (x86_linux_dr_get_status): ...this.
10933 (x86_dr_low): Update with new function names.
10935 2015-03-24 Gary Benson <gbenson@redhat.com>
10937 * Makefile.in (x86-linux.o): New rule.
10938 * configure.srv: Add x86-linux.o to relevant targets.
10939 * linux-low.c (lwp_set_arch_private_info): New function.
10940 (lwp_arch_private_info): Likewise.
10941 * linux-x86-low.c: Include nat/x86-linux.h.
10942 (arch_lwp_info): Removed structure.
10943 (update_debug_registers_callback):
10944 Use lwp_set_debug_registers_changed.
10945 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10946 and lwp_set_debug_registers_changed.
10947 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10949 2015-03-24 Gary Benson <gbenson@redhat.com>
10951 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10952 * linux-arm-low.c (arm_new_thread): Likewise.
10953 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10954 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10955 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10956 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10958 2015-03-24 Gary Benson <gbenson@redhat.com>
10960 * linux-low.c (ptid_of_lwp): New function.
10961 (lwp_is_stopped): Likewise.
10962 (lwp_stop_reason): Likewise.
10963 * linux-x86-low.c (update_debug_registers_callback):
10964 Use lwp_is_stopped.
10965 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10968 2015-03-24 Gary Benson <gbenson@redhat.com>
10970 * linux-low.h (linux_stop_lwp): Remove declaration.
10972 2015-03-24 Gary Benson <gbenson@redhat.com>
10974 * linux-low.h: Include nat/linux-nat.h.
10975 * linux-low.c (iterate_over_lwps_args): New structure.
10976 (iterate_over_lwps_filter): New function.
10977 (iterate_over_lwps): Likewise.
10978 * linux-x86-low.c (update_debug_registers_callback):
10979 Update signature to what iterate_over_lwps expects.
10980 Remove PID check that iterate_over_lwps now performs.
10981 (x86_dr_low_set_addr): Use iterate_over_lwps.
10982 (x86_dr_low_set_control): Likewise.
10984 2015-03-24 Gary Benson <gbenson@redhat.com>
10986 * linux-x86-low.c (x86_debug_reg_state): New function.
10987 (x86_linux_prepare_to_resume): Use the above.
10989 2015-03-24 Gary Benson <gbenson@redhat.com>
10991 * linux-low.c (current_lwp_ptid): New function.
10992 * linux-x86-low.c: Include nat/linux-nat.h.
10993 (x86_dr_low_get_addr): Use current_lwp_ptid.
10994 (x86_dr_low_get_control): Likewise.
10995 (x86_dr_low_get_status): Likewise.
10997 2015-03-20 Pedro Alves <palves@redhat.com>
10999 * tracepoint.c (cmd_qtstatus): Make "str" const.
11001 2015-03-20 Pedro Alves <palves@redhat.com>
11003 * server.c (handle_general_set): Make "req_str" const.
11005 2015-03-19 Pedro Alves <palves@redhat.com>
11007 * linux-low.c (linux_resume_one_lwp): Rename to ...
11008 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11009 instead call perror_with_name.
11010 (check_ptrace_stopped_lwp_gone): New function.
11011 (linux_resume_one_lwp): Reimplement as wrapper around
11012 linux_resume_one_lwp_throw that swallows errors if the LWP is
11015 2015-03-19 Pedro Alves <palves@redhat.com>
11017 * linux-low.c (count_events_callback, select_event_lwp_callback):
11018 No longer check whether the thread has resume_stop as last resume
11021 2015-03-19 Pedro Alves <palves@redhat.com>
11023 * linux-low.c (count_events_callback, select_event_lwp_callback):
11024 Use the lwp's status_pending_p field, not the thread's.
11026 2015-03-19 Pedro Alves <palves@redhat.com>
11028 * linux-low.c (select_event_lwp_callback): Update comments to
11029 no longer mention SIGTRAP.
11031 2015-03-18 Gary Benson <gbenson@redhat.com>
11033 * server.c (handle_query): Do not report vFile:fstat as supported.
11035 2015-03-11 Gary Benson <gbenson@redhat.com>
11037 * hostio.c (sys/types.h): New include.
11038 (sys/stat.h): Likewise.
11039 (common-remote-fileio.h): Likewise.
11040 (handle_fstat): New function.
11041 (handle_vFile): Handle vFile:fstat packets.
11043 2015-03-11 Gary Benson <gbenson@redhat.com>
11045 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11046 struct stat.st_blocks and struct stat.st_blksize.
11047 * configure: Regenerate.
11048 * config.in: Likewise.
11049 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11050 (OBS): Add common-remote-fileio.o.
11051 (common-remote-fileio.o): New rule.
11053 2015-03-09 Pedro Alves <palves@redhat.com>
11055 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11056 'struct sockaddr' pointer in 'accept' call.
11058 2015-03-09 Pedro Alves <palves@redhat.com>
11061 2015-03-07 Pedro Alves <palves@redhat.com>
11062 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11063 or <winsock2.h> here. Instead include "gdb_socket.h".
11064 (remote_open): Use union gdb_sockaddr_u.
11065 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11066 or <winsock2.h> here. Instead include "gdb_socket.h".
11067 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11068 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11070 (init_named_socket, gdb_agent_helper_thread): Use union
11073 2015-03-07 Pedro Alves <palves@redhat.com>
11075 * configure.ac (build_warnings): Move
11076 -Wdeclaration-after-statement to the C-specific set.
11077 * configure: Regenerate.
11079 2015-03-07 Pedro Alves <palves@redhat.com>
11081 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11082 or <winsock2.h> here. Instead include "gdb_socket.h".
11083 (remote_open): Use union gdb_sockaddr_u.
11084 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11085 or <winsock2.h> here. Instead include "gdb_socket.h".
11086 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11087 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11089 (init_named_socket, gdb_agent_helper_thread): Use union
11092 2015-03-07 Pedro Alves <palves@redhat.com>
11094 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11097 2015-03-06 Yao Qi <yao.qi@linaro.org>
11099 * linux-aarch64-low.c (aarch64_insert_point): Use
11100 show_debug_regs as a boolean.
11101 (aarch64_remove_point): Likewise.
11103 2015-03-05 Pedro Alves <palves@redhat.com>
11105 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11106 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11107 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11108 * nto-low.c (nto_target_ops): Likewise.
11109 * spu-low.c (spu_target_ops): Likewise.
11110 * win32-low.c (win32_target_ops): Likewise.
11112 2015-03-04 Pedro Alves <palves@redhat.com>
11114 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
11115 Decide whether a breakpoint triggered based on the SIGTRAP's
11117 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11118 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
11119 (linux_low_filter_event): Check for breakpoints before checking
11121 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11123 (linux_stopped_by_sw_breakpoint)
11124 (linux_supports_stopped_by_sw_breakpoint)
11125 (linux_stopped_by_hw_breakpoint)
11126 (linux_supports_stopped_by_hw_breakpoint): New functions.
11127 (linux_target_ops): Install new target methods.
11129 2015-03-04 Pedro Alves <palves@redhat.com>
11131 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11132 * server.c (swbreak_feature, hwbreak_feature): New globals.
11133 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11134 (captured_main): Clear swbreak_feature and hwbreak_feature.
11135 * server.h (swbreak_feature, hwbreak_feature): Declare.
11136 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11137 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11138 supports_stopped_by_hw_breakpoint>: New fields.
11139 (target_supports_stopped_by_sw_breakpoint)
11140 (target_stopped_by_sw_breakpoint)
11141 (target_supports_stopped_by_hw_breakpoint)
11142 (target_stopped_by_hw_breakpoint): Declare.
11144 2015-03-04 Pedro Alves <palves@redhat.com>
11146 enum lwp_stop_reason -> enum target_stop_reason
11147 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11148 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11149 (linux_wait_1, stuck_in_jump_pad_callback)
11150 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11151 (linux_stopped_by_watchpoint):
11152 * linux-low.h (enum lwp_stop_reason): Delete.
11153 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11154 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11156 2015-03-04 Yao Qi <yao.qi@linaro.org>
11158 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11160 2015-03-03 Gary Benson <gbenson@redhat.com>
11162 * hostio.c (handle_vFile): Fix prefix lengths.
11164 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11166 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11169 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11171 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11172 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11173 (clean): Add "rm -f" for above C files.
11174 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11175 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11176 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11177 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11178 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11179 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11180 (init_registers_s390x_vx_linux64)
11181 (init_registers_s390x_tevx_linux64)
11182 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11183 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11185 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11186 (s390_store_vxrs_high): New functions.
11187 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11189 (s390_arch_setup): Add logic for selecting one of the new target
11190 descriptions. Activate the new vector regsets if applicable.
11191 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11192 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11193 and init_registers_s390x_tevx_linux64.
11195 2015-03-01 Pedro Alves <palves@redhat.com>
11197 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11200 2015-02-27 Pedro Alves <palves@redhat.com>
11202 * linux-x86-low.c (u_debugreg_offset): New function.
11203 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11205 2015-02-27 Pedro Alves <palves@redhat.com>
11207 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11208 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11209 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11210 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11211 (ps_lsetfpregs, ps_getpid)
11212 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11213 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11214 (ps_lsetxregs, ps_plog): Declare.
11216 2015-02-27 Pedro Alves <palves@redhat.com>
11218 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11219 IP_AGENT_EXPORT_FUNC.
11220 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11221 IP_AGENT_EXPORT_FUNC.
11222 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11223 (IP_AGENT_EXPORT): Delete.
11224 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11225 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11226 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11227 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11228 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11229 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11230 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11231 (traceframe_read_count, traceframe_write_count)
11232 (traceframes_created, trace_state_variables, get_raw_reg)
11233 (get_trace_state_variable_value, set_trace_state_variable_value)
11234 (ust_loaded, helper_thread_id, cmd_buf): Use
11235 IPA_SYM_EXPORTED_NAME.
11236 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11237 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11238 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11239 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11240 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11241 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11242 EXTERN_C_PUSH/EXTERN_C_POP.
11243 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11244 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11245 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11246 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11247 (traceframe_write_count, traceframe_read_count)
11248 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11249 (about_to_request_buffer_space, get_trace_state_variable_value)
11250 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11251 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11252 EXTERN_C_PUSH/EXTERN_C_POP.
11253 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11254 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11255 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11256 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11257 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11258 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11259 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11260 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11262 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11263 (IP_AGENT_EXPORT_VAR_DECL): Define.
11264 (tracing): Declare.
11265 (gdb_agent_get_raw_reg): Declare.
11267 2015-02-27 Tom Tromey <tromey@redhat.com>
11268 Pedro Alves <palves@redhat.com>
11270 Rename symbols whose names are reserved C++ keywords throughout.
11272 2015-02-27 Pedro Alves <palves@redhat.com>
11274 * Makefile.in (COMPILER): New, get it from autoconf.
11275 (CXX): Get from autoconf instead.
11276 (COMPILE.pre): Use COMPILER.
11277 (CC-LD): Rename to ...
11278 (CC_LD): ... this. Use COMPILER.
11279 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11280 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11281 * acinclude.m4: Include build-with-cxx.m4.
11282 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11283 Disable -Werror by default if building in C++ mode.
11284 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11285 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11286 the C++ compiler. Save/restore CXXFLAGS too.
11287 * configure: Regenerate.
11289 2015-02-27 Pedro Alves <palves@redhat.com>
11291 * acinclude.m4: Include libiberty.m4.
11292 * configure.ac: Call libiberty_INIT.
11293 * config.in, configure: Regenerate.
11295 2015-02-26 Pedro Alves <palves@redhat.com>
11297 * linux-low.c (linux_wait_1): When incrementing the PC past a
11298 program breakpoint always use the_low_target.breakpoint_len as
11299 increment, rather than the maximum between that and
11300 the_low_target.decr_pc_after_break.
11302 2015-02-23 Pedro Alves <palves@redhat.com>
11304 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11305 thread was doing a step-over; always adjust the PC if
11306 we stepped over a permanent breakpoint.
11307 (linux_wait_1): If we stepped over breakpoint that was on top of a
11308 permanent breakpoint, manually advance the PC past it.
11310 2015-02-23 Pedro Alves <palves@redhat.com>
11312 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11314 (x86_fill_gregset, x86_store_gregset): Use it when handling
11317 2015-02-20 Pedro Alves <palves@redhat.com>
11319 * thread-db.c: Include "nat/linux-procfs.h".
11320 (thread_db_init): Skip listing new threads if the kernel supports
11321 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11323 2015-02-20 Pedro Alves <palves@redhat.com>
11325 * linux-low.c (status_pending_p_callback): Use ptid_match.
11327 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11329 PR breakpoints/16812
11330 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11331 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11332 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11334 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11336 PR breakpoints/15956
11337 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11339 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11341 * linux-low.c (linux_low_btrace_conf): Print size.
11342 * server.c (handle_btrace_conf_general_set): New.
11343 (hanle_general_set): Call handle_btrace_conf_general_set.
11344 (handle_query): Report Qbtrace-conf:bts:size as supported.
11346 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11348 * linux-low.c (linux_low_enable_btrace): Update parameters.
11349 (linux_low_btrace_conf): New.
11350 (linux_target_ops)<to_btrace_conf>: Initialize.
11351 * server.c (current_btrace_conf): New.
11352 (handle_btrace_enable): Rename to ...
11353 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
11354 to target_enable_btrace. Update comment. Update users.
11355 (handle_qxfer_btrace_conf): New.
11356 (qxfer_packets): Add btrace-conf entry.
11357 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11358 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11359 (target_ops)<read_btrace_conf>: New.
11360 (target_enable_btrace): Update parameters.
11361 (target_read_btrace_conf): New.
11363 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11365 * server.c (handle_btrace_general_set): Remove call to
11366 target_supports_btrace.
11367 (supported_btrace_packets): New.
11368 (handle_query): Call supported_btrace_packets.
11369 * target.h: include btrace-common.h.
11370 (btrace_target_info): Removed.
11371 (supports_btrace, target_supports_btrace): Update parameters.
11373 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11375 * Makefile.in (SFILES): Add common/btrace-common.c.
11376 (OBS): Add common/btrace-common.o.
11377 (btrace-common.o): Add build rules.
11378 * linux-low: Include btrace-common.h.
11379 (linux_low_read_btrace): Use struct btrace_data. Call
11380 btrace_data_init and btrace_data_fini.
11382 2015-02-06 Pedro Alves <palves@redhat.com>
11384 * thread-db.c (find_new_threads_callback): Add debug output.
11386 2015-02-04 Pedro Alves <palves@redhat.com>
11388 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11389 (resume_stopped_resumed_lwps): New function.
11390 (linux_wait_for_event_filtered): Use it.
11392 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11394 * Makefile.in (SFILES): Add linux-personality.c.
11395 (linux-personality.o): New rule.
11396 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11397 list of objects to be built.
11398 * linux-low.c: Include nat/linux-personality.h.
11399 (linux_create_inferior): Remove code to disable address space
11400 randomization (moved to ../nat/linux-personality.c). Create
11401 cleanup to disable address space randomization.
11403 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11405 * Makefile.in (posix-strerror.o): New rule.
11406 (mingw-strerror.o): Likewise.
11407 * configure: Regenerated.
11408 * configure.ac: Source file ../common/common.host. Initialize new
11409 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11411 2015-01-14 Yao Qi <yao@codesourcery.com>
11413 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11414 (ppc-linux.o): New rule.
11415 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11416 * configure.ac: AC_CHECK_FUNCS(getauxval).
11417 * config.in: Re-generated.
11418 * configure: Re-generated.
11419 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11420 ppc64_64bit_inferior_p
11422 2015-01-14 Yao Qi <yao@codesourcery.com>
11424 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11425 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11426 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11427 (PT_ORIG_R3, PT_TRAP): Likewise.
11428 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11429 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11430 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11432 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11434 * i387-fp.c (i387_cache_to_xsave): In look over
11435 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11436 zmmh_low_space field by use of zmmh_high_space.
11438 2015-01-09 Pedro Alves <palves@redhat.com>
11440 * linux-low.c (step_over_bkpt): Move higher up in the file.
11441 (handle_extended_wait): Don't store the stop_pc here.
11442 (get_stop_pc): Adjust comments and rename to ...
11443 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11444 stopped for a software breakpoint or hardware breakpoint.
11445 (thread_still_has_status_pending_p): New function.
11446 (status_pending_p_callback): Use
11447 thread_still_has_status_pending_p. If the event is no longer
11448 interesting, resume the LWP.
11449 (handle_tracepoints): Add assert.
11450 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11451 (wstatus_maybe_breakpoint): New function.
11452 (cancel_breakpoint): Delete function.
11453 (check_stopped_by_watchpoint): New function, factored out from
11454 linux_low_filter_event.
11455 (lp_status_maybe_breakpoint): Delete function.
11456 (linux_low_filter_event): Remove filter_ptid argument.
11457 Leave thread group exits pending here. Store the LWP's stop PC.
11458 Always leave events pending.
11459 (linux_wait_for_event_filtered): Pull all events out of the
11460 kernel, and leave them all pending.
11461 (count_events_callback, select_event_lwp_callback): Consider all
11463 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11464 (select_event_lwp): Only give preference to the stepping LWP in
11465 all-stop mode. Adjust comments.
11466 (ignore_event): New function.
11467 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11468 references to cancel_breakpoints. Adjust to renames. Also give
11469 equal priority to all LWPs that have had events in non-stop mode.
11470 If reporting a software breakpoint event, unadjust the LWP's PC.
11471 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11472 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11474 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11475 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11476 (linux_stopped_by_watchpoint): Adjust.
11477 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11478 * linux-low.h (enum lwp_stop_reason): New.
11479 (struct lwp_info) <stop_pc>: Adjust comment.
11480 <stopped_by_watchpoint>: Delete field.
11481 <stop_reason>: New field.
11482 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11483 * mem-break.c (software_breakpoint_inserted_here)
11484 (hardware_breakpoint_inserted_here): New function.
11485 * mem-break.h (software_breakpoint_inserted_here)
11486 (hardware_breakpoint_inserted_here): Declare.
11487 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11488 (cancel_breakpoints): Delete.
11489 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11490 (upload_fast_traceframes): Remove references to
11491 cancel_breakpoints.
11493 2015-01-09 Pedro Alves <palves@redhat.com>
11495 * thread-db.c (find_new_threads_callback): Ignore thread if the
11496 kernel thread ID is -1.
11498 2015-01-09 Pedro Alves <palves@redhat.com>
11500 * linux-low.c (linux_attach_fail_reason_string): Move to
11501 nat/linux-ptrace.c, and rename.
11502 (linux_attach_lwp): Update comment.
11503 (attach_proc_task_lwp_callback): New function.
11504 (linux_attach): Adjust to rename and use
11505 linux_proc_attach_tgid_threads.
11506 (linux_attach_fail_reason_string): Delete declaration.
11508 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11510 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11511 * server.c (gdbserver_version): Likewise.
11513 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11515 * remote-utils.c: Include ctype.h.
11516 (input_interrupt): Explicitly handle the case when the char
11517 received is the NUL byte. Improve the printing of non-ASCII
11520 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11522 * linux-low.c (linux_low_filter_event): Update call to
11523 linux_enable_event_reporting following the addition of
11524 a new parameter to that function.
11526 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11529 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11530 (AARCH64_FPCR_REGNO): Likewise.
11531 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11532 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11533 (aarch64_store_fpregset): Likewise.
11535 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11537 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11538 Remove FIXME comment about assumption about N.
11540 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11542 * configure.ac: If large-file support is disabled in GDBserver,
11543 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11544 * configure: Regenerate.
11546 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11548 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11549 warning upon ENODATA from ptrace.
11550 * linux-s390-low.c (s390_store_tdb): New.
11551 (s390_regsets): Add regset for NT_S390_TDB.
11553 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11555 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11556 without a fill_function.
11557 * linux-s390-low.c (s390_fill_last_break): Remove.
11558 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11559 (s390_arch_setup): Use regset's size instead of fill_function for
11560 loop end condition.
11562 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11564 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11565 the regset's store function when ptrace returned an error.
11566 * regcache.c (get_thread_regcache): Invalidate register cache
11567 before fetching inferior's registers.
11569 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11571 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11572 while-loop as for-loop.
11573 (regsets_store_inferior_registers): Likewise.
11575 2014-11-28 Yao Qi <yao@codesourcery.com>
11577 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11578 * config.in, configure: Re-generate.
11579 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11582 2014-11-21 Yao Qi <yao@codesourcery.com>
11584 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11585 (AC_CHECK_HEADERS): Remove malloc.h.
11586 * configure: Re-generated.
11587 * config.in: Re-generated.
11588 * server.h: Don't include alloca.h and malloc.h.
11589 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11590 Don't include malloc.h.
11592 2014-11-17 Joel Brobecker <brobecker@adacore.com>
11594 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11595 corresponding ERRNO check in same block.
11597 2014-11-12 Pedro Alves <palves@redhat.com>
11599 * server.c (cont_thread): Update comment.
11600 (start_inferior, attach_inferior): No longer clear cont_thread.
11601 (handle_v_cont): No longer set cont_thread.
11602 (captured_main): Clear cont_thread each time a GDB connects.
11604 2014-11-12 Pedro Alves <palves@redhat.com>
11606 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11607 thread, and don't resume all threads if the Hc thread has exited.
11609 2014-11-12 Pedro Alves <palves@redhat.com>
11611 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11612 the process group instead of to a specific LWP.
11614 2014-10-15 Pedro Alves <palves@redhat.com>
11617 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11619 (arm_set_thread_context): Delete.
11620 (the_low_target): Adjust.
11621 * win32-i386-low.c (debug_registers_changed)
11622 (debug_registers_used): Delete.
11623 (update_debug_registers_callback): New function.
11624 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11625 needing to update their debug registers.
11626 (win32_get_current_dr): New function.
11627 (x86_dr_low_get_addr, x86_dr_low_get_control)
11628 (x86_dr_low_get_status): Fetch the debug register from the thread
11630 (i386_initial_stuff): Adjust.
11631 (i386_get_thread_context): Remove current_event parameter. Don't
11632 clear debug_registers_changed nor copy DR values to
11634 (i386_set_thread_context): Delete.
11635 (i386_prepare_to_resume): New function.
11636 (i386_thread_added): Mark the thread as needing to update irs
11638 (the_low_target): Remove i386_set_thread_context and install
11639 i386_prepare_to_resume.
11640 * win32-low.c (win32_get_thread_context): Adjust.
11641 (win32_set_thread_context): Use SetThreadContext
11643 (win32_prepare_to_resume): New function.
11644 (win32_require_context): New function, factored out from ...
11645 (thread_rec): ... this.
11646 (continue_one_thread): Call win32_prepare_to_resume on each thread
11647 we're about to continue.
11648 (win32_resume): Call win32_prepare_to_resume on the event thread.
11649 * win32-low.h (struct win32_thread_info)
11650 <debug_registers_changed>: New field.
11651 (struct win32_target_ops): Change prototype of set_thread_context,
11652 delete set_thread_context and add prepare_to_resume.
11653 (win32_require_context): New declaration.
11655 2014-10-08 Gary Benson <gbenson@redhat.com>
11657 * server.h: Do not include common-exceptions.h.
11659 2014-10-08 Gary Benson <gbenson@redhat.com>
11661 * server.h: Do not include cleanups.h.
11663 2014-09-30 James Hogan <james.hogan@imgtec.com>
11665 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11666 mips64-dsp-linux.c.
11668 2014-09-23 Yao Qi <yao@codesourcery.com>
11670 * linux-low.c (lp_status_maybe_breakpoint): New function.
11671 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11672 (count_events_callback): Likewise.
11673 (select_event_lwp_callback): Likewise.
11674 (cancel_breakpoints_callback): Likewise.
11676 2014-09-19 Don Breazeal <donb@codesourcery.com>
11678 * linux-low.c (handle_extended_wait): Call
11679 linux_ptrace_get_extended_event.
11680 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11681 linux_is_extended_waitstatus.
11683 2014-09-16 Joel Brobecker <brobecker@adacore.com>
11685 * Makefile.in (CPPFLAGS): Define.
11686 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11687 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11689 2014-09-16 Gary Benson <gbenson@redhat.com>
11691 * inferiors.h (current_inferior): Renamed as...
11692 (current_thread): New variable. All uses updated.
11693 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11694 (maybe_move_out_of_jump_pad): Likewise.
11695 (cancel_breakpoint): Likewise.
11696 (linux_low_filter_event): Likewise.
11697 (wait_for_sigstop): Likewise.
11698 (linux_resume_one_lwp): Likewise.
11699 (need_step_over_p): Likewise.
11700 (start_step_over): Likewise.
11701 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11702 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11703 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11704 and save_inferior as saved_thread.
11705 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11707 (regcache_invalidate_thread): Likewise.
11708 * remote-utils.c (prepare_resume_reply): Likewise.
11709 * thread-db.c (thread_db_get_tls_address): Likewise.
11710 (disable_thread_event_reporting): Likewise.
11711 (remove_thread_event_breakpoints): Likewise.
11712 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11714 * target.h (set_desired_inferior): Renamed as...
11715 (set_desired_thread): New declaration. All uses updated.
11716 * server.c (myresume): Updated comment to reference thread instead
11718 (handle_serial_event): Likewise.
11719 (handle_target_event): Likewise.
11721 2014-09-12 Tom Tromey <tromey@redhat.com>
11722 Gary Benson <gbenson@redhat.com>
11724 * regcache.h: Include common-regcache.h.
11725 (regcache_read_pc): Don't declare.
11726 * regcache.c (get_thread_regcache_for_ptid): New function.
11728 2014-09-11 Tom Tromey <tromey@redhat.com>
11729 Gary Benson <gbenson@redhat.com>
11731 * symbol.c: New file.
11732 * Makefile.in (SFILES): Add symbol.c.
11733 (OBS): Add symbol.o.
11735 2014-09-11 Gary Benson <gbenson@redhat.com>
11737 * target.c (target_stop_ptid, target_continue_ptid): New
11740 2014-09-11 Tom Tromey <tromey@redhat.com>
11741 Gary Benson <gbenson@redhat.com>
11743 * target.h: Include target/target.h.
11744 * target.c (target_read_memory, target_read_uint32)
11745 (target_write_memory): New functions.
11747 2014-09-11 Gary Benson <gbenson@redhat.com>
11749 * server.h (debug_hw_points): Don't declare.
11750 * server.c (debug_hw_points): Don't define. Replace all uses
11751 with show_debug_regs.
11752 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11753 all uses with show_debug_regs.
11755 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11757 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11758 endianness into account.
11759 (ppc_supply_ptrace_register): Likewise.
11761 2014-09-03 James Hogan <james.hogan@imgtec.com>
11763 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11764 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11766 2014-09-03 Gary Benson <gbenson@redhat.com>
11768 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11769 ALL_DEBUG_ADDRESS_REGISTERS.
11771 2014-09-02 Gary Benson <gbenson@redhat.com>
11773 * i386-low.h: Renamed as...
11774 * x86-low.h: New file. All type, function and variable name
11775 prefixes changed from "i386_" to "x86_". All references updated.
11776 * i386-low.c: Renamed as...
11777 * x86-low.c: New file. All type, function and variable name
11778 prefixes changed from "i386_" to "x86_". All references updated.
11780 2014-09-02 Gary Benson <gbenson@redhat.com>
11782 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11783 (x86_linux_new_thread): Likewise.
11785 2014-08-29 Gary Benson <gbenson@redhat.com>
11787 * server.h (setjmp.h): Do not include.
11788 (toplevel): Do not declare.
11789 (common-exceptions.h): Include.
11790 (cleanups.h): Likewise.
11791 * server.c (toplevel): Do not define.
11792 (exit_code): New static global.
11793 (detach_or_kill_for_exit_cleanup): New function.
11794 (main): New function. Original main renamed to...
11795 (captured_main): New function.
11796 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11798 2014-08-29 Gary Benson <gbenson@redhat.com>
11800 * Makefile.in (SFILES): Add common/common-exceptions.c.
11801 (OBS): Add common-exceptions.o.
11802 (common-exceptions.o): New rule.
11803 * utils.c (prepare_to_throw_exception): New function.
11805 2014-08-29 Gary Benson <gbenson@redhat.com>
11807 * config.in: Regenerate.
11808 * configure: Likewise.
11810 2014-08-29 Gary Benson <gbenson@redhat.com>
11812 * Makefile.in (SFILES): Add common/cleanups.c.
11814 (cleanups.o): New rule.
11816 2014-08-29 Gary Benson <gbenson@redhat.com>
11818 * utils.c (internal_vwarning): New function.
11820 2014-08-28 Gary Benson <gbenson@redhat.com>
11822 * utils.h (fatal): Remove declaration.
11823 * utils.c (fatal): Remove function.
11825 2014-08-28 Gary Benson <gbenson@redhat.com>
11827 * tracepoint.c (gdb_agent_init): Replace fatal with
11829 (initialize_tracepoint): Likewise.
11831 2014-08-28 Gary Benson <gbenson@redhat.com>
11833 * remote-utils.c (remote_prepare): Replace fatal with error.
11835 2014-08-28 Gary Benson <gbenson@redhat.com>
11837 * linux-low.c (linux_async): Replace fatal with warning.
11838 Tidy up and return.
11839 (linux_start_non_stop): Return -1 if linux_async failed.
11841 2014-08-28 Gary Benson <gbenson@redhat.com>
11843 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11845 (i386_dr_low_get_addr): Remove vague comment.
11846 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11849 2014-08-28 Gary Benson <gbenson@redhat.com>
11851 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11852 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11854 (linux_resume_one_lwp): Likewise.
11855 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11857 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11858 with internal_error.
11859 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11860 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11861 (find_register_by_name): Replace fatal with internal_error.
11862 (find_regno): Likewise.
11863 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11864 * thread-db.c (thread_db_create_event): Likewise.
11865 (thread_db_load_search): Likewise.
11866 (try_thread_db_load_1): Likewise.
11867 * tracepoint.c (get_jump_space_head): Replace fatal with
11869 (claim_trampoline_space): Likewise.
11870 (have_fast_tracepoint_trampoline_buffer): Likewise.
11871 (cmd_qtstart): Likewise.
11872 (stop_tracing): Likewise.
11873 (fast_tracepoint_collecting): Likewise.
11874 (target_malloc): Likewise.
11875 (download_tracepoint): Likewise.
11876 (download_trace_state_variables): Replace check with gdb_assert.
11877 (upload_fast_traceframes): Replace fatal with internal_error.
11879 2014-08-19 Tom Tromey <tromey@redhat.com>
11880 Gary Benson <gbenson@redhat.com>
11882 * Makefile.in (SFILES): Add common/common-debug.c.
11883 (OBS): Add common-debug.o.
11884 (common-debug.o): New rule.
11885 * debug.h (debug_printf): Don't declare.
11886 * debug.c (debug_printf): Renamed and rewritten as...
11887 (debug_vprintf): New function.
11889 2014-08-19 Gary Benson <gbenson@redhat.com>
11891 * utils.h: Do not include print-utils.h.
11893 2014-08-19 Tom Tromey <tromey@redhat.com>
11894 Gary Benson <gbenson@redhat.com>
11896 * server.h: Add static assertion.
11897 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11899 2014-08-19 Tom Tromey <tromey@redhat.com>
11900 Gary Benson <gbenson@redhat.com>
11902 * Makefile.in (SFILES): Add common/errors.c.
11903 (OBS): Add errors.o.
11904 (IPA_OBS): Add errors-ipa.o.
11905 (errors.o): New rule.
11906 (errors-ipa.o): Likewise.
11907 * utils.h (perror_with_name, error, warning): Don't declare.
11908 * utils.c (warning): Renamed and rewritten as...
11909 (vwarning): New function.
11910 (error): Renamed and rewritten as...
11911 (verror): New function.
11912 (internal_error): Renamed and rewritten as...
11913 (internal_verror): New function.
11915 2014-08-07 Gary Benson <gbenson@redhat.com>
11917 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11918 * configure: Regenerate.
11919 * config.in: Likewise.
11920 * server.h: Do not include errno.h.
11921 * event-loop.c: Likewise.
11922 * hostio-errno.c: Likewise.
11923 * linux-low.c: Likewise.
11924 * remote-utils.c: Likewise.
11925 * spu-low.c: Likewise.
11926 * utils.c: Likewise.
11927 * gdbreplay.c: Unconditionally include errno.h.
11929 2014-08-07 Gary Benson <gbenson@redhat.com>
11931 * server.h: Do not include string.h.
11932 * event-loop.c: Likewise.
11933 * linux-low.c: Likewise.
11934 * regcache.c: Likewise.
11935 * remote-utils.c: Likewise.
11936 * spu-low.c: Likewise.
11937 * utils.c: Likewise.
11939 2014-08-07 Gary Benson <gbenson@redhat.com>
11941 * server.h: Do not include gdb_assert.h.
11943 2014-08-07 Gary Benson <gbenson@redhat.com>
11945 * server.h: Do not include common-utils.h.
11947 2014-08-07 Gary Benson <gbenson@redhat.com>
11949 * server.h: Do not include ptid.h.
11950 * notif.h: Likewise.
11952 2014-08-07 Gary Benson <gbenson@redhat.com>
11954 * server.h: Do not include gdb_locale.h.
11956 2014-08-07 Gary Benson <gbenson@redhat.com>
11958 * server.h: Do not include gdb/signals.h.
11959 * win32-low.c: Likewise.
11961 2014-08-07 Gary Benson <gbenson@redhat.com>
11963 * server.h: Do not include pathmax.h.
11965 2014-08-07 Gary Benson <gbenson@redhat.com>
11967 * server.h: Do not include libiberty.h.
11968 * linux-bfin-low.c: Likewise.
11970 2014-08-07 Gary Benson <gbenson@redhat.com>
11972 * server.h: Do not include ansidecl.h.
11974 2014-08-07 Gary Benson <gbenson@redhat.com>
11976 * linux-x86-low.c: Do not include stddef.h.
11977 * lynx-ppc-low.c: Likewise.
11978 * tracepoint.c: Likewise.
11980 2014-08-07 Gary Benson <gbenson@redhat.com>
11982 * server.h: Do not include stdarg.h.
11983 * nto-low.c: Likewise.
11985 2014-08-07 Gary Benson <gbenson@redhat.com>
11987 * server.h: Do not include stdlib.h.
11988 * inferiors.c: Likewise.
11989 * linux-low.c: Likewise.
11990 * regcache.c: Likewise.
11991 * spu-low.c: Likewise.
11992 * tracepoint.c: Likewise.
11993 * utils.c: Likewise.
11995 2014-08-07 Gary Benson <gbenson@redhat.com>
11997 * server.h: Do not include stdio.h.
11998 * linux-low.c: Likewise.
11999 * remote-utils.c: Likewise.
12000 * spu-low.c: Likewise.
12001 * utils.c: Likewise.
12002 * wincecompat.c: Likewise.
12004 2014-08-06 Gary Benson <gbenson@redhat.com>
12006 * regcache.c (init_register_cache): Move conditionals inside if.
12008 2014-08-06 Gary Benson <gbenson@redhat.com>
12010 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12012 2014-07-31 Gary Benson <gbenson@redhat.com>
12014 * ax.h: Do not include server.h.
12015 * gdbthread.h: Likewise.
12016 * lynx-low.h: Likewise.
12017 * notif.h: Likewise.
12019 2014-07-30 Gary Benson <gbenson@redhat.com>
12021 * server.h: Include common-defs.h.
12022 Do not include config.h or build-gnulib-gdbserver/config.h.
12024 2014-07-30 Gary Benson <gbenson@redhat.com>
12026 * hostio-errno.c: Move server.h to top of includes list.
12027 * inferiors.c: Likewise.
12028 * linux-x86-low.c: Likewise.
12029 * notif.c: Include server.h.
12031 2014-07-24 Tom Tromey <tromey@redhat.com>
12032 Gary Benson <gbenson@redhat.com>
12034 * server.h (CORE_ADDR): Now unsigned.
12036 2014-07-16 Pedro Alves <palves@redhat.com>
12038 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12040 2014-07-15 Pedro Alves <palves@redhat.com>
12042 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12045 2014-07-11 Pedro Alves <palves@redhat.com>
12047 * linux-low.c (kill_wait_lwp): New function, based on
12048 kill_one_lwp_callback, but use my_waitpid directly.
12049 (kill_one_lwp_callback, linux_kill): Use it.
12051 2014-06-23 Pedro Alves <palves@redhat.com>
12053 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12054 before setting DR0..DR3.
12056 2014-06-20 Gary Benson <gbenson@redhat.com>
12058 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12059 * configure: Regenerated.
12060 * config.in: Likewise.
12062 2014-06-20 Gary Benson <gbenson@redhat.com>
12064 * Makefile.in (SFILES): Update locations for files moved
12065 from common to nat.
12066 (object file files): Reordered.
12068 2014-06-20 Gary Benson <gbenson@redhat.com>
12070 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12071 (i386_dr_low_set_addr): Likewise.
12072 (i386_dr_low_get_addr): Likewise.
12073 (i386_dr_low_can_set_control): Likewise.
12074 (i386_dr_low_set_control): Likewise.
12075 (i386_dr_low_get_control): Likewise.
12076 (i386_dr_low_get_status): Likewise.
12077 (i386_get_debug_register_length): Likewise.
12078 * linux-x86-low.c (i386_dr_low_set_addr):
12079 Changed signature. Made static.
12080 (i386_dr_low_get_addr): Likewise.
12081 (i386_dr_low_set_control): Likewise.
12082 (i386_dr_low_get_control): Likewise.
12083 (i386_dr_low_get_status): Likewise.
12084 (i386_dr_low): New global variable.
12085 * win32-i386-low.c (i386_dr_low_set_addr):
12086 Changed signature. Made static.
12087 (i386_dr_low_get_addr): Likewise.
12088 (i386_dr_low_set_control): Likewise.
12089 (i386_dr_low_get_control): Likewise.
12090 (i386_dr_low_get_status): Likewise.
12091 (i386_dr_low): New global variable.
12093 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12095 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12096 * Makefile.in (AR, AR_FLAGS): Define.
12097 * configure: Regenerate.
12099 2014-06-19 Gary Benson <gbenson@redhat.com>
12101 * Makefile.in (i386-dregs.o): New rule.
12102 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12103 * i386-low.c (target.h): Remove include.
12104 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12105 (DR_CONTROL_SHIFT): Likewise.
12106 (DR_CONTROL_SIZE): Likewise.
12107 (DR_RW_EXECUTE): Likewise.
12108 (DR_RW_WRITE): Likewise.
12109 (DR_RW_READ): Likewise.
12110 (DR_RW_IORW): Likewise.
12111 (DR_LEN_1): Likewise.
12112 (DR_LEN_2): Likewise.
12113 (DR_LEN_4): Likewise.
12114 (DR_LEN_8): Likewise.
12115 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12116 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12117 (DR_ENABLE_SIZE): Likewise.
12118 (DR_LOCAL_SLOWDOWN): Likewise.
12119 (DR_GLOBAL_SLOWDOWN): Likewise.
12120 (DR_CONTROL_RESERVED): Likewise.
12121 (I386_DR_CONTROL_MASK): Likewise.
12122 (I386_DR_VACANT): Likewise.
12123 (I386_DR_LOCAL_ENABLE): Likewise.
12124 (I386_DR_GLOBAL_ENABLE): Likewise.
12125 (I386_DR_DISABLE): Likewise.
12126 (I386_DR_SET_RW_LEN): Likewise.
12127 (I386_DR_GET_RW_LEN): Likewise.
12128 (I386_DR_WATCH_HIT): Likewise.
12129 (i386_wp_op_t): Likewise.
12130 (i386_show_dr): Likewise.
12131 (i386_length_and_rw_bits): Likewise.
12132 (i386_insert_aligned_watchpoint): Likewise.
12133 (i386_remove_aligned_watchpoint): Likewise.
12134 (i386_handle_nonaligned_watchpoint): Likewise.
12135 i386_update_inferior_debug_regs(): Likewise.
12136 (i386_dr_insert_watchpoint): Likewise.
12137 (i386_dr_remove_watchpoint): Likewise.
12138 (i386_dr_region_ok_for_watchpoint): Likewise.
12139 (i386_dr_stopped_data_address): Likewise.
12140 (i386_dr_stopped_by_watchpoint): Likewise.
12142 2014-06-19 Gary Benson <gbenson@redhat.com>
12144 * i386-low.c (i386_dr_show): Renamed to
12145 i386_show_dr and made static. All uses updated.
12146 (i386_dr_length_and_rw_bits): Renamed to
12147 i386_length_and_rw_bits and made static.
12149 (i386_dr_insert_aligned_watchpoint): Renamed to
12150 i386_insert_aligned_watchpoint and made static.
12152 (i386_dr_remove_aligned_watchpoint): Renamed to
12153 i386_remove_aligned_watchpoint and made static.
12155 (i386_dr_update_inferior_debug_regs): Renamed to
12156 i386_update_inferior_debug_regs and made static.
12159 2014-06-18 Gary Benson <gbenson@redhat.com>
12161 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12162 (i386_dr_low_can_set_control): Likewise.
12163 (i386_get_debug_register_length): Likewise.
12164 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12165 (i386_dr_low_can_set_control): Likewise.
12166 (i386_get_debug_register_length): Likewise.
12168 2014-06-17 Gary Benson <gbenson@redhat.com>
12170 * i386-low.h (i386-dregs.h): New include.
12171 (DR_FIRSTADDR): Now in i386-dregs.h.
12172 (DR_LASTADDR): Likewise.
12173 (DR_NADDR): Likewise.
12174 (DR_STATUS): Likewise.
12175 (DR_CONTROL): Likewise.
12176 (i386_debug_reg_state): Likewise.
12177 (i386_dr_insert_watchpoint): Likewise.
12178 (i386_dr_remove_watchpoint): Likewise.
12179 (i386_dr_region_ok_for_watchpoint): Likewise.
12180 (i386_dr_stopped_data_address): Likewise.
12181 (i386_dr_stopped_by_watchpoint): Likewise.
12182 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12184 2014-06-18 Gary Benson <gbenson@redhat.com>
12186 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12187 i386_dr_insert_watchpoint.
12188 (i386_low_remove_watchpoint): Renamed to
12189 i386_dr_remove_watchpoint.
12190 (i386_low_region_ok_for_watchpoint): Renamed to
12191 i386_dr_region_ok_for_watchpoint.
12192 (i386_low_stopped_data_address): Renamed to
12193 i386_dr_stopped_data_address.
12194 (i386_low_stopped_by_watchpoint): Renamed to
12195 i386_dr_stopped_by_watchpoint.
12196 * i386-low.c (i386_show_dr): Renamed to
12197 i386_dr_show and made nonstatic. All uses updated.
12198 (i386_length_and_rw_bits): Renamed to
12199 i386_dr_length_and_rw_bits and made nonstatic.
12201 (i386_insert_aligned_watchpoint): Renamed to
12202 i386_dr_insert_aligned_watchpoint and made nonstatic.
12204 (i386_remove_aligned_watchpoint): Renamed to
12205 i386_dr_remove_aligned_watchpoint and made nonstatic.
12207 (i386_update_inferior_debug_regs): Renamed to
12208 i386_dr_update_inferior_debug_regs and made nonstatic.
12210 (i386_low_insert_watchpoint): Renamed to
12211 i386_dr_insert_watchpoint. All uses updated.
12212 (i386_low_remove_watchpoint): Renamed to
12213 i386_dr_remove_watchpoint. All uses updated.
12214 (i386_low_region_ok_for_watchpoint): Renamed to
12215 i386_dr_region_ok_for_watchpoint. All uses updated.
12216 (i386_low_stopped_data_address): Renamed to
12217 i386_dr_stopped_data_address. All uses updated.
12218 (i386_low_stopped_by_watchpoint): Renamed to
12219 i386_dr_stopped_by_watchpoint. All uses updated.
12221 2014-06-18 Gary Benson <gbenson@redhat.com>
12223 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12224 (i386_dr_low_can_set_control): Likewise.
12225 (i386_insert_aligned_watchpoint): New check.
12227 2014-06-18 Gary Benson <gbenson@redhat.com>
12229 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12232 2014-06-18 Gary Benson <gbenson@redhat.com>
12234 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12235 instead of fatal and error.
12236 (i386_handle_nonaligned_watchpoint): Likewise.
12238 2014-06-18 Gary Benson <gbenson@redhat.com>
12240 * i386-low.c (i386_get_debug_register_length): New macro.
12241 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12242 (i386_show_dr): Use debug_printf instead of fprintf. Use
12243 phex to format values.
12245 2014-06-18 Gary Benson <gbenson@redhat.com>
12247 * i386-low.h: Comment changes.
12248 * i386-low.c: Likewise.
12250 2014-06-18 Gary Benson <gbenson@redhat.com>
12252 * i386-low.c: Whitespace changes.
12254 2014-06-12 Tom Tromey <tromey@redhat.com>
12256 * utils.c (freeargv): Remove.
12258 2014-06-12 Tom Tromey <tromey@redhat.com>
12260 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12261 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12262 (parse_debug_format_options): Likewise.
12263 (gdbserver_usage): Likewise.
12264 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12265 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12266 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12268 ($(LIBGNU)): Depend on libiberty.
12269 (all-lib): Recurse into all subdirs.
12270 (install-only): Invoke "install" target in subdirs.
12271 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12273 * configure: Rebuild.
12274 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12275 for vasprintf, vsnprintf, or gettimeofday.
12276 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12279 2014-06-05 Joel Brobecker <brobecker@adacore.com>
12281 * development.sh: Delete.
12282 * Makefile.in (config.status): Adjust dependency on development.sh.
12283 * configure.ac: Adjust development.sh source call.
12284 * configure: Regenerate.
12286 2014-06-02 Pedro Alves <palves@redhat.com>
12288 * ax.c (gdb_free_agent_expr): New function.
12289 * ax.h (gdb_free_agent_expr): New declaration.
12290 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12292 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12294 (clear_breakpoint_conditions_and_commands): New function.
12295 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12296 (clear_breakpoint_conditions_and_commands): New declaration.
12298 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12300 * linux-aarch64-low.c (asm/ptrace.h): Include.
12302 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12304 Fix TLS access for -static -pthread.
12305 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12306 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12307 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12309 2014-05-20 Pedro Alves <palves@redhat.com>
12311 * linux-aarch64-low.c (aarch64_insert_point)
12312 (aarch64_remove_point): No longer check whether the type is
12313 supported here. Adjust to new interface.
12314 (the_low_target): Install aarch64_supports_z_point_type as
12315 supports_z_point_type method.
12316 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12317 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12318 instead of a Z packet char. Adjust.
12319 (arm_supports_z_point_type): New function.
12320 (arm_insert_point, arm_remove_point): Adjust to new interface.
12321 (the_low_target): Install arm_supports_z_point_type.
12322 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12323 (cris_insert_point, cris_remove_point): Adjust to new interface.
12324 Don't check whether the type is supported here.
12325 (the_low_target): Install cris_supports_z_point_type.
12326 * linux-low.c (linux_supports_z_point_type): New function.
12327 (linux_insert_point, linux_remove_point): Adjust to new interface.
12328 * linux-low.h (struct linux_target_ops) <insert_point,
12329 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12330 raw_breakpoint pointer parameter.
12331 <supports_z_point_type>: New method.
12332 * linux-mips-low.c (mips_supports_z_point_type): New function.
12333 (mips_insert_point, mips_remove_point): Adjust to new interface.
12334 Use mips_supports_z_point_type.
12335 (the_low_target): Install mips_supports_z_point_type.
12336 * linux-ppc-low.c (the_low_target): Install NULL as
12337 supports_z_point_type method.
12338 * linux-s390-low.c (the_low_target): Install NULL as
12339 supports_z_point_type method.
12340 * linux-sparc-low.c (the_low_target): Install NULL as
12341 supports_z_point_type method.
12342 * linux-x86-low.c (x86_supports_z_point_type): New function.
12343 (x86_insert_point): Adjust to new insert_point interface. Use
12344 insert_memory_breakpoint. Adjust to new
12345 i386_low_insert_watchpoint interface.
12346 (x86_remove_point): Adjust to remove_point interface. Use
12347 remove_memory_breakpoint. Adjust to new
12348 i386_low_remove_watchpoint interface.
12349 (the_low_target): Install x86_supports_z_point_type.
12350 * lynx-low.c (lynx_target_ops): Install NULL as
12351 supports_z_point_type callback.
12352 * nto-low.c (nto_supports_z_point_type): New.
12353 (nto_insert_point, nto_remove_point): Adjust to new interface.
12354 (nto_target_ops): Install nto_supports_z_point_type.
12355 * mem-break.c: Adjust intro comment.
12356 (struct raw_breakpoint) <raw_type, size>: New fields.
12357 <inserted>: Update comment.
12358 <shlib_disabled>: Delete field.
12359 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12360 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12361 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12362 (raw_bkpt_type_to_target_hw_bp_type): New function.
12363 (find_enabled_raw_code_breakpoint_at): New function.
12364 (find_raw_breakpoint_at): New type and size parameters. Use them.
12365 (insert_memory_breakpoint): New function, based off
12366 set_raw_breakpoint_at.
12367 (remove_memory_breakpoint): New function.
12368 (set_raw_breakpoint_at): Reimplement.
12369 (set_breakpoint): New, based on set_breakpoint_at.
12370 (set_breakpoint_at): Reimplement.
12371 (delete_raw_breakpoint): Go through the_target->remove_point
12372 instead of assuming memory breakpoints.
12373 (find_gdb_breakpoint_at): Delete.
12374 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12375 (find_gdb_breakpoint): New function.
12376 (set_gdb_breakpoint_at): Delete.
12377 (z_type_supported): New function.
12378 (set_gdb_breakpoint_1): New function, loosely based off
12379 set_gdb_breakpoint_at.
12380 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12381 (delete_gdb_breakpoint_at): Delete.
12382 (delete_gdb_breakpoint_1): New function, loosely based off
12383 delete_gdb_breakpoint_at.
12384 (delete_gdb_breakpoint): New function.
12385 (clear_gdb_breakpoint_conditions): Rename to ...
12386 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12388 (add_condition_to_breakpoint): Make static.
12389 (add_breakpoint_condition): Take a struct breakpoint pointer
12390 instead of an address. Adjust.
12391 (gdb_condition_true_at_breakpoint): Rename to ...
12392 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12394 (gdb_condition_true_at_breakpoint): Reimplement.
12395 (add_breakpoint_commands): Take a struct breakpoint pointer
12396 instead of an address. Adjust.
12397 (gdb_no_commands_at_breakpoint): Rename to ...
12398 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12399 parameter. Return true if no breakpoint was found. Change debug
12401 (gdb_no_commands_at_breakpoint): Reimplement.
12402 (run_breakpoint_commands): Rename to ...
12403 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12404 and change return type to boolean.
12405 (run_breakpoint_commands): New function.
12406 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12407 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12408 breakpoint. Go through the_target->remove_point instead of
12409 assuming memory breakpoint.
12410 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12411 software and hardware breakpoints.
12412 (reinsert_raw_breakpoint): Go through the_target->insert_point
12413 instead of assuming memory breakpoint.
12414 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12415 software and hardware breakpoints.
12416 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12417 Check both software and hardware breakpoints.
12418 (validate_inserted_breakpoint): Assert the breakpoint is a
12419 software breakpoint. Set the inserted flag to -1 instead of
12420 setting shlib_disabled.
12421 (delete_disabled_breakpoints): Adjust.
12422 (validate_breakpoints): Only validate software breakpoints.
12423 Adjust to inserted flag change.
12424 (check_mem_read, check_mem_write): Skip breakpoint types other
12425 than software breakpoints. Adjust to inserted flag change.
12426 * mem-break.h (enum raw_bkpt_type): New enum.
12427 (raw_breakpoint, struct process_info): Forward declare.
12428 (Z_packet_to_target_hw_bp_type): Delete declaration.
12429 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12430 (set_gdb_breakpoint, delete_gdb_breakpoint)
12431 (clear_breakpoint_conditions): New declarations.
12432 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12433 (breakpoint_inserted_here): Update comment.
12434 (add_breakpoint_condition, add_breakpoint_commands): Replace
12435 address parameter with a breakpoint pointer parameter.
12436 (gdb_breakpoint_here): Update comment.
12437 (delete_gdb_breakpoint_at): Delete.
12438 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12439 * server.c (process_point_options): Take a struct breakpoint
12440 pointer instead of an address. Adjust.
12441 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12442 delete_gdb_breakpoint.
12443 * spu-low.c (spu_target_ops): Install NULL as
12444 supports_z_point_type method.
12445 * target.h: Include mem-break.h.
12446 (struct target_ops) <prepare_to_access_memory>: Update comment.
12447 <supports_z_point_type>: New field.
12448 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12449 instead of a char. Also take a raw breakpoint pointer.
12450 * win32-arm-low.c (the_low_target): Install NULL as
12451 supports_z_point_type.
12452 * win32-i386-low.c (i386_supports_z_point_type): New function.
12453 (i386_insert_point, i386_remove_point): Adjust to new interface.
12454 (the_low_target): Install i386_supports_z_point_type.
12455 * win32-low.c (win32_supports_z_point_type): New function.
12456 (win32_insert_point, win32_remove_point): Adjust to new interface.
12457 (win32_target_ops): Install win32_supports_z_point_type.
12458 * win32-low.h (struct win32_target_ops):
12459 <supports_z_point_type>: New method.
12460 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12461 instead of a char. Also take a raw breakpoint pointer.
12463 2014-05-20 Pedro Alves <palves@redhat.com>
12465 * mem-break.h: Include break-common.h.
12466 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12467 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12468 (Z_packet_to_target_hw_bp_type): New declaration.
12469 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12470 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12471 (Z_PACKET_ACCESS_WP): Delete macros.
12472 (Z_packet_to_hw_type): Delete function.
12473 * i386-low.h: Don't include break-common.h here.
12474 (Z_packet_to_hw_type): Delete declaration.
12475 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12476 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12477 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12478 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12479 * linux-aarch64-low.c: Don't include break-common.h here.
12480 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12481 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12482 (Z_packet_to_target_hw_bp_type): Delete function.
12483 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12485 (mips_insert_point, mips_remove_point): Use
12486 Z_packet_to_target_hw_bp_type.
12488 2014-05-20 Pedro Alves <palves@redhat.com>
12490 * linux-aarch64-low.c: Include break-common.h.
12491 (enum target_point_type): Delete.
12492 (Z_packet_to_point_type): Rename to ...
12493 (Z_packet_to_target_hw_bp_type): ... this, and return a
12494 target_hw_bp_type instead.
12495 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12496 instead of an enum target_point_type.
12497 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12499 (aarch64_dr_state_insert_one_point)
12500 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12501 (aarch64_handle_aligned_watchpoint)
12502 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12503 Take an enum target_hw_bp_type instead of an enum
12505 (aarch64_supports_z_point_type): New function.
12506 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12507 use Z_packet_to_target_hw_bp_type.
12509 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12511 * configure.ac: Only use -Werror by default when DEVELOPMENT
12513 * configure: Regenerate.
12515 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12517 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12518 * linux-x86-low.c (X86_64_USER_REGS): New.
12519 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12521 2014-04-28 Yao Qi <yao@codesourcery.com>
12523 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12526 2014-04-25 Pedro Alves <palves@redhat.com>
12529 * linux-low.c (linux_attach_fail_reason_string): New function.
12530 (linux_attach_lwp): Delete.
12531 (linux_attach_lwp_1): Rename to ...
12532 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12533 argument. Remove "initial" parameter. Return int instead of
12534 void. Don't error or warn here.
12535 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12536 failure to attach to the tgid. Call warning when failing to
12538 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12539 argument. Remove "initial" parameter. Return int instead of
12540 void. Don't error or warn here.
12541 (linux_attach_fail_reason_string): New declaration.
12542 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12543 interface change. Use linux_attach_fail_reason_string.
12545 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12546 Walfred Tedeschi <walfred.tedeschi@intel.com>
12548 * Makefile.in: Added rules to handle new files
12549 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12550 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12551 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12552 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12553 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12554 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12555 x32-avx512-linux.o.
12556 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12557 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12558 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12559 i386/x32-avx512.xml.
12560 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12561 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12562 i386/x32-avx512-linux.xml.
12563 * i387-fp.c (num_avx512_k_registers): New constant for number
12565 (num_avx512_zmmh_low_registers): New constant for number of
12566 lower ZMM registers (0-15).
12567 (num_avx512_zmmh_high_registers): New constant for number of
12568 higher ZMM registers (16-31).
12569 (num_avx512_ymmh_registers): New contant for number of higher
12570 YMM registers (ymm16-31 added by avx521 on x86_64).
12571 (num_avx512_xmm_registers): New constant for number of higher
12572 XMM registers (xmm16-31 added by AVX512 on x86_64).
12573 (struct i387_xsave): Add space for AVX512 registers.
12574 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12575 Add code to handle AVX512 registers.
12576 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12577 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12578 prototypei from generated file.
12579 (tdesc_amd64_avx512_linux): Likewise.
12580 (init_registers_x32_avx512_linux): Likewise.
12581 (tdesc_x32_avx512_linux): Likewise.
12582 (init_registers_i386_avx512_linux): Likewise.
12583 (tdesc_i386_avx512_linux): Likewise.
12584 (x86_64_regmap): Add AVX512 registers.
12585 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12587 (initialize_low_arch): Add code to initialize AVX512 registers.
12589 2014-04-23 Pedro Alves <palves@redhat.com>
12591 * mem-break.c (find_gdb_breakpoint_at): Make static.
12592 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12594 2014-04-23 Pedro Alves <palves@redhat.com>
12596 * i386-low.c: Don't include break-common.h here.
12597 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12598 prototype to take target_hw_bp_type as argument instead of a Z
12600 * i386-low.h: Include break-common.h here.
12601 (Z_packet_to_hw_type): Declare.
12602 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12604 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12605 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12606 (x86_remove_point): Convert the packet number to a
12607 target_hw_bp_type before calling i386_low_remove_watchpoint.
12608 * win32-i386-low.c (i386_insert_point): Convert the packet number
12609 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12610 (i386_remove_point): Convert the packet number to a
12611 target_hw_bp_type before calling i386_low_remove_watchpoint.
12613 2014-04-23 Pedro Alves <palves@redhat.com>
12615 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12617 2014-04-10 Pedro Alves <palves@redhat.com>
12619 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12620 Check if the condition or command is NULL before checking if the
12621 breakpoint is known. On success, return true.
12622 * mem-break.h (add_breakpoint_condition): Document return.
12623 (add_breakpoint_commands): Add describing comment.
12624 * server.c (skip_to_semicolon): New function.
12625 (process_point_options): Use it.
12627 2014-04-09 Pedro Alves <palves@redhat.com>
12629 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12632 2014-02-27 Pedro Alves <palves@redhat.com>
12635 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12637 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12639 (last_thread_of_process_p): Take a PID argument instead of a
12641 (linux_wait_for_lwp): Delete.
12642 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12644 (linux_low_filter_event): New function, party factored out from
12645 linux_wait_for_event.
12646 (linux_wait_for_event): Rename to ...
12647 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12648 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12649 sigsuspend. Check for zombie leaders.
12650 (linux_wait_for_event): Reimplement as wrapper around
12651 linux_wait_for_event_filtered.
12652 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12653 a normal or signal exit is seen, it's the whole process exiting.
12654 (wait_for_sigstop): No longer a for_each_inferior callback.
12655 Rewrite on top of linux_wait_for_event_filtered.
12656 (stop_all_lwps): Call wait_for_sigstop directly.
12657 * server.c (resume, handle_target_event): Handle
12658 TARGET_WAITKIND_NO_RESUMED.
12660 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12662 * win32-low.c (psapi_get_dll_name,
12663 * win32_CreateToolhelp32Snapshot): Delete.
12664 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12665 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12667 (handle_load_dll): Add function description.
12668 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12670 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12672 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12674 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12675 base address when calling win32_add_one_solib.
12676 (handle_load_dll): Delete local variable load_addr.
12677 Remove 0x1000 offset applied to DLL base address when calling
12678 win32_add_one_solib.
12679 (handle_unload_dll): Add comment.
12681 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12683 * win32-low.c (win32_add_all_dlls): Renames
12684 win32_ensure_ntdll_loaded. Rewrite function documentation.
12685 Adjust implementation to always load all DLLs.
12686 Add 0x1000 offset to DLL base address when calling
12687 win32_add_one_solib.
12688 (child_initialization_done): New static global.
12689 (do_initial_child_stuff): Set child_initialization_done to
12690 zero during child initialization, and 1 after. Replace call
12691 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12693 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12694 (handle_unload_dll): Add function documentation.
12695 (get_child_debug_event): Ignore load and unload DLL events
12696 during child initialization.
12698 2014-02-20 Doug Evans <dje@google.com>
12700 Remove global all_lwps.
12701 * inferiors.h (ptid_of): Move here from linux-low.h.
12702 (pid_of, lwpid_of): Ditto.
12703 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12704 parameter is a struct thread_info * now.
12705 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12706 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12707 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12709 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12710 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12711 * linux-arm-low.c (update_registers_callback): Update, "entry"
12712 parameter is a struct thread_info * now.
12713 Fetch lwpid from current_inferior directly.
12714 (arm_insert_point): Pass &all_threads to find_inferior instead of
12716 (arm_remove_point): Ditto.
12717 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12718 (arm_prepare_to_resume): Fetch pid from thread.
12719 (arm_read_description): Fetch lwpid from current_inferior directly.
12720 * linux-low.c (all_lwps): Delete.
12721 (delete_lwp): Delete call to remove_inferior.
12722 (handle_extended_wait): Fetch lwpid from thread.
12723 (add_lwp): Don't set lwp->entry.id. Remove call to
12724 add_inferior_to_list.
12725 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12726 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12727 (kill_one_lwp_callback): Ditto.
12728 (linux_kill): Don't dereference NULL pointer.
12729 Fetch ptid,lwpid from thread.
12730 (get_detach_signal): Fetch ptid from thread.
12731 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12732 Simplify call to regcache_invalidate_thread.
12733 (delete_lwp_callback): Update, "entry" parameter is a
12734 struct thread_info * now. Fetch pid from thread.
12735 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12736 (status_pending_p_callback): Update, "entry" parameter is a
12737 struct thread_info * now. Fetch ptid from thread.
12738 (find_lwp_pid): Update, "entry" parameter is a
12739 struct thread_info * now.
12740 (linux_wait_for_lwp): Fetch pid from thread.
12741 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12742 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12743 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12744 (dequeue_one_deferred_signal): Ditto.
12745 (cancel_breakpoint): Fetch ptid from current_inferior.
12746 (linux_wait_for_event): Pass &all_threads to find_inferior,
12747 not &all_lwps. Fetch ptid, lwpid from thread.
12748 (count_events_callback): Update, "entry" parameter is a
12749 struct thread_info * now.
12750 (select_singlestep_lwp_callback): Ditto.
12751 (select_event_lwp_callback): Ditto.
12752 (cancel_breakpoints_callback): Ditto.
12753 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12755 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12756 (unsuspend_one_lwp): Update, "entry" parameter is a
12757 struct thread_info * now.
12758 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12760 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12761 Fetch lwpid from thread, not lwp.
12762 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12763 Pass &all_threads to find_inferior, not &all_lwps.
12764 (send_sigstop): Fetch lwpid from thread, not lwp.
12765 (send_sigstop_callback): Update, "entry" parameter is a
12766 struct thread_info * now.
12767 (suspend_and_send_sigstop_callback): Ditto.
12768 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12769 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12770 struct thread_info * now.
12771 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12773 (lwp_running): Update, "entry" parameter is a
12774 struct thread_info * now.
12775 (stop_all_lwps): Fetch ptid from thread.
12776 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12777 (linux_resume_one_lwp): Fetch lwpid from thread.
12778 (linux_set_resume_request): Update, "entry" parameter is a
12779 struct thread_info * now. Fetch pid, lwpid from thread.
12780 (resume_status_pending_p): Update, "entry" parameter is a
12781 struct thread_info * now.
12782 (need_step_over_p): Ditto. Fetch lwpid from thread.
12783 (start_step_over): Fetch lwpid from thread.
12784 (linux_resume_one_thread): Update, "entry" parameter is a
12785 struct thread_info * now. Fetch lwpid from thread.
12786 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12787 (proceed_one_lwp): Update, "entry" parameter is a
12788 struct thread_info * now. Fetch lwpid from thread.
12789 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12790 struct thread_info * now.
12791 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12792 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12793 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12795 (regsets_store_inferior_registers): Ditto.
12796 (fetch_register, store_register): Ditto.
12797 (linux_read_memory, linux_write_memory): Ditto.
12798 (linux_request_interrupt): Ditto.
12799 (linux_read_auxv): Ditto.
12800 (linux_xfer_siginfo): Ditto.
12801 (linux_qxfer_spu): Ditto.
12802 (linux_qxfer_libraries_svr4): Ditto.
12803 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12804 moved to inferiors.h.
12806 (get_thread_lwp): Update.
12807 (struct lwp_info): Delete member "entry". Simplify comment for
12809 (all_lwps): Delete.
12810 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12811 current_inferior directly.
12812 (update_watch_registers_callback): Update, "entry" parameter is a
12813 struct thread_info * now. Fetch pid from thread.
12814 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12815 (mips_insert_point): Fetch lwpid from current_inferior.
12816 Pass &all_threads to find_inferior, not &all_lwps.
12817 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12818 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12820 (mips_stopped_data_address): Ditto.
12821 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12823 * linux-tile-low.c (tile_arch_setup): Ditto.
12824 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12825 (update_debug_registers_callback): Update, "entry" parameter is a
12826 struct thread_info * now. Fetch pid from thread.
12827 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12828 Pass &all_threads to find_inferior, not &all_lwps.
12829 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12830 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12831 Pass &all_threads to find_inferior, not &all_lwps.
12832 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12833 (i386_dr_low_get_status): Ditto.
12834 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12835 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12836 (x86_linux_read_description): Ditto.
12837 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12839 2014-02-20 Doug Evans <dje@google.com>
12841 * inferiors.c (get_first_inferior): Fix buglet.
12843 2014-02-19 Doug Evans <dje@google.com>
12845 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12846 * inferiors.c (add_thread): Change result type to struct thread_info *.
12847 All callers updated.
12848 (add_lwp): Call add_thread here instead of in callers.
12849 All callers updated.
12850 * linux-low.h (get_lwp_thread): Rewrite.
12851 (struct lwp_info): New member "thread".
12853 2014-02-19 Doug Evans <dje@google.com>
12855 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12856 All callers updated.
12858 2014-02-19 Doug Evans <dje@google.com>
12860 * inferiors.c (add_thread): Fix whitespace.
12862 2014-02-19 Doug Evans <dje@google.com>
12864 * dll.c (clear_dlls): Replace accessing list implemention details
12866 * gdbthread.h (get_first_thread): Declare.
12867 * inferiors.c (for_each_inferior_with_data): New function.
12868 (get_first_thread): New function.
12869 (find_thread_ptid): Simplify.
12870 (get_first_inferior): New function.
12871 (clear_list): Delete.
12872 (one_inferior_p): New function.
12873 (clear_inferior_list): New function.
12874 (clear_inferiors): Update.
12875 * inferiors.h (for_each_inferior_with_data): Declare.
12876 (clear_inferior_list): Declare.
12877 (one_inferior_p): Declare.
12878 (get_first_inferior): Declare.
12879 * linux-low.c (linux_wait_for_event): Replace accessing list
12880 implemention details with API function.
12881 * server.c (target_running): Ditto.
12882 (accumulate_file_name_length): New function.
12883 (emit_dll_description): New function.
12884 (handle_qxfer_libraries): Replace accessing list implemention
12885 details with API function.
12886 (handle_qxfer_threads_worker): New function.
12887 (handle_qxfer_threads_proper): Replace accessing list implemention
12888 details with API function.
12889 (handle_query): Ditto.
12890 (visit_actioned_threads_callback_ftype): New typedef.
12891 (visit_actioned_threads_data): New struct.
12892 (visit_actioned_threads): Rewrite to be find_inferior callback.
12893 (resume): Call find_inferior.
12894 (handle_status): Replace accessing list implemention
12895 details with API function.
12896 (process_serial_event): Replace accessing list implemention details
12898 * target.c (set_desired_inferior): Replace accessing list implemention
12899 details with API function.
12900 * tracepoint.c (same_process_p): New function.
12901 (gdb_agent_about_to_close): Replace accessing list implemention
12902 details with API function.
12903 * win32-low.c (child_delete_thread): Replace accessing list
12904 implemention details with API function.
12905 (match_dll_by_basename): New function.
12906 (dll_is_loaded_by_basename): New function.
12907 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12908 details call to dll_is_loaded_by_basename.
12910 2014-02-19 Doug Evans <dje@google.com>
12912 * dll.h (struct dll_info): Add comment.
12913 * gdbthread.h (struct thread_info): Add comment.
12914 (current_ptid): Simplify.
12915 * inferiors.c (add_process): Update.
12916 (remove_process): Update.
12917 * inferiors.h (struct process_info): Rename member "head" to "entry".
12918 * linux-low.c (delete_lwp): Update.
12920 (last_thread_of_process_p): Update.
12921 (kill_one_lwp_callback, linux_kill): Update.
12922 (status_pending_p_callback): Update.
12923 (wait_for_sigstop): Update. Simplify read of ptid.
12924 (start_step_over): Update.
12925 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12926 (get_lwp_thread): Update.
12927 (struct lwp_info): Rename member "head" to "entry".
12928 * regcache.h (inferior_list_entry): Delete.
12929 * server.c (kill_inferior_callback): Update.
12930 (detach_or_kill_inferior_callback): Update.
12931 (print_started_pid): Update.
12932 (print_attached_pid): Update.
12933 (process_serial_event): Simplify read of ptid.
12934 * thread-db.c (thread_db_create_event): Update.
12935 (thread_db_get_tls_address): Update.
12936 * win32-low.c (current_inferior_ptid): Simplify.
12938 2014-02-19 Tom Tromey <tromey@redhat.com>
12940 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12942 (target_supports_btrace): Update.
12944 2014-02-14 Yao Qi <yao@codesourcery.com>
12946 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12947 (rsp-low-ipa.o): New target.
12949 2014-02-12 Tom Tromey <tromey@redhat.com>
12951 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12952 convert_ascii_to_int.
12953 * regcache.c (registers_to_string): Likewise.
12954 * remote-utils.c (decode_M_packet): Likewise.
12955 * server.c (process_serial_event): Likewise.
12957 2014-02-12 Tom Tromey <tromey@redhat.com>
12959 * server.c (handle_query, handle_v_run): Use hex2bin, not
12961 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12963 2014-02-12 Tom Tromey <tromey@redhat.com>
12965 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12966 convert_int_to_ascii.
12967 * regcache.c (registers_to_string, collect_register_as_string):
12969 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12971 * server.c (process_serial_event): Likewise.
12972 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12973 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
12975 2014-02-12 Tom Tromey <tromey@redhat.com>
12977 * remote-utils.c (look_up_one_symbol, monitor_output): Use
12978 bin2hex, not hexify.
12979 * tracepoint.c (cmd_qtstatus): Likewise.
12981 2014-02-12 Tom Tromey <tromey@redhat.com>
12983 * remote-utils.c (monitor_output): Pass explicit length to
12986 2014-02-12 Tom Tromey <tromey@redhat.com>
12988 * tracepoint.c: Include rsp-low.h.
12989 * server.c: Include rsp-low.h.
12990 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
12991 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
12993 * remote-utils.c: Include rsp-low.h.
12994 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
12995 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
12996 (convert_int_to_ascii, convert_ascii_to_int): Move to
12998 * regcache.c: Include rsp-low.h.
12999 * ax.c: Include rsp-low.h.
13000 * Makefile.in (SFILES): Add common/rsp-low.c.
13001 (OBS): Add rsp-low.o.
13002 (rsp-low.o): New target.
13004 2014-02-12 Tom Tromey <tromey@redhat.com>
13006 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13007 Include print-utils.h.
13008 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13009 (plongest, thirty_two, phex_nz): Remove.
13010 * Makefile.in (SFILES): Add common/print-utils.c.
13011 (OBS): Add print-utils.o.
13012 (print-utils-ipa.o): New target.
13013 (print-utils.o): New target.
13014 (IPA_OBJS): Add print-utils-ipa.o.
13016 2014-02-06 Tom Tromey <tromey@redhat.com>
13018 * Makefile.in (SFILES): Fix indentation.
13020 2014-02-05 Doug Evans <dje@google.com>
13022 * linux-low.c (linux_wait_for_event): Improve comment.
13023 (linux_wait_1): Keep current_inferior in sync with event_child.
13025 2014-01-22 Doug Evans <dje@google.com>
13027 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13029 2014-01-22 Doug Evans <dje@google.com>
13031 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13032 * configure: Regenerate.
13033 * config.in: Regenerate.
13034 * Makefile.in (SFILES): Add debug.c.
13035 (OBS): Add debug.o.
13036 * debug.c: New file.
13037 * debug.h: New file.
13038 * linux-aarch64-low.c (*): Update all debugging printfs to use
13039 debug_printf instead of fprintf.
13040 * linux-arm-low.c (*): Ditto.
13041 * linux-cris-low.c (*): Ditto.
13042 * linux-crisv32-low.c (*): Ditto.
13043 * linux-m32r-low.c (*): Ditto.
13044 * linux-sparc-low.c (*): Ditto.
13045 * linux-x86.c (*): Ditto.
13046 * linux-low.c (*): Ditto.
13047 (linux_wait_1): Add calls to debug_enter, debug_exit.
13048 (linux_wait): Remove redundant debugging printf.
13049 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13050 (linux_resume, unstop_all_lwps): Ditto.
13051 * mem-break.c (*): Update all debugging printfs to use
13052 debug_printf instead of fprintf.
13053 * remote-utils.c (*): Ditto.
13054 * thread-db.c (*): Ditto.
13055 * server.c #include <ctype.h>, "gdb_vecs.h".
13056 (debug_threads): Moved to debug.c.
13057 (*): Update all debugging printfs to use debug_printf instead of
13059 (start_inferior): Replace call to fflush with call to debug_flush.
13060 (monitor_show_help): Mention set debug-format.
13061 (parse_debug_format_options): New function.
13062 (handle_monitor_command): Handle "monitor set debug-format".
13063 (gdbserver_usage): Mention --debug-format.
13064 (main): Parse --debug-format.
13065 * server.h (debug_threads): Declaration moved to debug.h.
13066 #include "debug.h".
13067 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13068 trace_debug_1 that uses debug_printf.
13069 (tracepoint_look_up_symbols): Update all debugging printfs to use
13070 debug_printf instead of fprintf.
13072 2014-01-20 Baruch Siach <baruch@tkos.co.il>
13074 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13077 2014-01-17 Pedro Alves <palves@redhat.com>
13080 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13081 defined after including gdb_proc_service.h.
13083 2014-01-16 Doug Evans <dje@google.com>
13085 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13086 (match_dll): Use it.
13088 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13090 * target.h (target_ops) <read_btrace>: Change parameters and
13091 return type to allow error reporting.
13092 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13093 trace reading errors on.
13094 * linux-low.c (linux_low_read_btrace): Pass trace reading
13096 (linux_low_disable_btrace): New.
13098 2014-01-15 Doug Evans <dje@google.com>
13100 * inferiors.c (thread_id_to_gdb_id): Delete.
13101 * inferiors.h (thread_id_to_gdb_id): Delete.
13103 2014-01-13 Eli Zaretskii <eliz@gnu.org>
13105 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13106 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13109 2014-01-08 Pedro Alves <palves@redhat.com>
13111 * server.c (handle_status): Don't discard previous queued stop
13112 replies or thread's pending status here.
13113 (main) <disconnection>: Do it here instead.
13115 2014-01-08 Pedro Alves <palves@redhat.com>
13117 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13118 * server.c (visit_actioned_threads, handle_pending_status): New
13120 (handle_v_cont): Factor out parts to ...
13121 (resume): ... this new function. If in all-stop, and a thread
13122 being resumed has a pending status, report it without actually
13124 (myresume): Adjust to use the new 'resume' function.
13125 (clear_pending_status_callback, set_pending_status_callback)
13126 (find_status_pending_thread_callback): New functions.
13127 (handle_status): Handle the case of multiple threads having
13128 interesting statuses to report. Report threads' real last signal
13129 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13130 with an interesting thread to report the status for, instead of
13131 always reporting the status of the first thread.
13133 2014-01-01 Joel Brobecker <brobecker@adacore.com>
13135 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13136 * gdbreplay.c (gdbreplay_version): Likewise.
13138 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13140 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13141 iov.iov_len with the real length in use.
13143 2013-12-13 Joel Brobecker <brobecker@adacore.com>
13145 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13146 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13147 for all targets that use win32-low.c.
13148 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13149 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13151 2013-12-13 Pedro Alves <palves@redhat.com>
13153 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13154 if equal to TARGET_WAITKIND_LOADED.
13155 * win32-low.c (cached_status): New static global.
13156 (win32_wait): Add declaration.
13157 (do_initial_child_stuff): Flush all initial pending debug events
13158 up to the initial breakpoint.
13159 (win32_wait): If CACHED_STATUS was set, return that instead
13160 of doing a real wait. Remove the code resuming the execution
13161 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13162 during the initial phase. Also remove the code changing
13163 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13164 TARGET_WAITKIND_STOPPED.
13166 2013-12-11 Yao Qi <yao@codesourcery.com>
13168 * notif.c (handle_notif_ack): Return 0 if no notification
13171 2013-11-20 Doug Evans <dje@google.com>
13173 * linux-low.c (linux_set_resume_request): Fix comment.
13175 2013-11-20 Doug Evans <dje@google.com>
13177 * linux-low.c (resume_status_pending_p): Tweak comment.
13179 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13181 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13182 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13183 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13184 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13185 (srv_amd64_regobj): Add amd64-mpx.o.
13186 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13187 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13188 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13189 * i387-fp.c (num_pl_bnd_register) Added constant.
13190 (num_pl_bnd_cfg_registers) Added constant.
13191 (struct i387_xsave) Added reserved area and MPX fields.
13192 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13193 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13195 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13196 (init_registers_amd64_mpx_linux): Declare new function.
13197 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13198 (x86_64_regmap): Add MPX registers.
13199 (x86_linux_read_description): Add MPX case.
13200 (initialize_low_arch): Initialize MPX targets.
13202 2013-11-18 Tom Tromey <tromey@redhat.com>
13204 * configure: Rebuild.
13205 * configure.ac: Don't check for stdlib.h.
13206 * gdbreplay.c: Unconditionally include stdlib.h.
13208 2013-11-18 Tom Tromey <tromey@redhat.com>
13210 * config.in: Rebuild.
13211 * configure: Rebuild.
13212 * configure.ac: Don't use AC_HEADER_DIRENT.
13214 2013-11-18 Tom Tromey <tromey@redhat.com>
13216 * server.h: Don't check HAVE_STRING_H.
13217 * gdbreplay.c: Don't check HAVE_STRING_H.
13218 * configure: Rebuild.
13220 2013-11-18 Tom Tromey <tromey@redhat.com>
13222 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13225 2013-11-08 Tom Tromey <tromey@redhat.com>
13227 * configure, config.in: Rebuild.
13228 * configure.ac: Remove unused configury.
13230 2013-11-08 Tom Tromey <tromey@redhat.com>
13232 * acinclude.m4: Include common.m4, codeset.m4.
13233 * configure, config.in: Rebuild.
13234 * configure.ac: Use GDB_AC_COMMON.
13236 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13238 * linux-s390-low.c (HWCAP_S390_TE): New define.
13239 (s390_arch_setup): Consider the TE field in the HWCAP for
13240 determining 'have_regset_tdb'.
13242 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13245 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13248 2013-10-02 Pedro Alves <palves@redhat.com>
13250 * server.c (process_serial_event): Don't output "GDBserver
13251 exiting" if GDB is connected through stdio.
13252 * target.c (mywait): Likewise, be silent if GDB is connected
13255 2013-10-01 Joel Brobecker <brobecker@adacore.com>
13257 * lynx-low.c (lynx_add_threads_after_attach): New function.
13258 (lynx_attach): Remove call to add_thread. Add call to
13259 lynx_add_threads_after_attach instead.
13261 2013-09-28 Mike Frysinger <vapier@gentoo.org>
13263 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13264 * config.in, configure: Regenerated.
13266 2013-09-18 Yao Qi <yao@codesourcery.com>
13269 * server.c (start_inferior): Clear 'resume_info'.
13271 2013-09-16 Jiong Wang <jiwang@tilera.com>
13273 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13276 2013-09-16 Jiong Wang <jiwang@tilera.com>
13278 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13279 linux-tile-low.o to srv_tgtobj.
13281 2013-09-16 Will Newton <will.newton@linaro.org>
13283 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13286 2013-09-06 Pedro Alves <palves@redhat.com>
13288 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13289 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13290 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13291 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13292 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13293 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13295 2013-09-06 Pedro Alves <palves@redhat.com>
13297 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13298 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13300 2013-09-06 Pedro Alves <palves@redhat.com>
13302 * linux-amd64-ipa.c: Include tracepoint.h.
13303 * linux-i386-ipa.c: Include tracepoint.h.
13305 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13307 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13308 (ps_get_thread_area): New function.
13310 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13312 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13313 (initialize_low_arch): Call init_registers_crisv32 rather than
13314 init_register_crisv32.
13316 2013-09-05 Pedro Alves <palves@redhat.com>
13318 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13320 * hostio.h: ... this new file.
13321 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13322 win32-low.c: Include hostio.h.
13324 2013-09-05 Pedro Alves <palves@redhat.com>
13326 * server.h (gdb_client_data, handler_func, callback_handler_func)
13327 (delete_file_handler, add_file_handler, append_callback_event)
13328 (delete_callback_event, start_event_loop, initialize_event_loop):
13329 Move to event-loop.h and include it.
13330 * event-loop.h: New file.
13332 2013-09-05 Pedro Alves <palves@redhat.com>
13334 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13335 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13336 (loaded_dll, unloaded_dll): Move to ...
13337 * dll.h: ... this new file.
13338 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13340 2013-09-05 Pedro Alves <palves@redhat.com>
13342 * server.h (current_process, get_thread_process, all_processes)
13343 (add_inferior_to_list, for_each_inferior, current_inferior)
13344 (remove_inferior, add_process, remove_process, find_process_pid)
13345 (have_started_inferiors_p, have_attached_inferiors_p)
13346 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13347 (clear_inferiors, find_inferior, find_inferior_id)
13348 (inferior_target_data, set_inferior_target_data)
13349 (inferior_regcache_data, set_inferior_regcache_data): Move to
13350 inferiors.h, and include it.
13351 * inferiors.h: New file.
13353 2013-09-05 Pedro Alves <palves@redhat.com>
13355 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13359 2013-09-05 Pedro Alves <palves@redhat.com>
13361 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13363 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13364 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13365 (handle_tracepoint_general_set, handle_tracepoint_query)
13366 (tracepoint_finished_step, tracepoint_was_hit)
13367 (release_while_stepping_state_list, current_traceframe)
13368 (in_readonly_region, traceframe_read_mem)
13369 (fetch_traceframe_registers, traceframe_read_sdata)
13370 (traceframe_read_info, struct fast_tpoint_collect_status)
13371 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13372 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13373 (supply_fast_tracepoint_registers)
13374 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13375 (ipa_tdesc, claim_trampoline_space)
13376 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13377 (agent_mem_read, agent_get_trace_state_variable_value)
13378 (agent_set_trace_state_variable_value, agent_tsv_read)
13379 (agent_mem_read_string, get_raw_reg_func_addr)
13380 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13381 * tracepoint.h: ... this new file.
13383 2013-09-05 Pedro Alves <palves@redhat.com>
13385 * server.h (perror_with_name, error, fatal, warning, paddress)
13386 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13388 * utils.h: New file.
13390 2013-09-05 Pedro Alves <palves@redhat.com>
13392 * server.h (remote_debug, noack_mode, transport_is_reliable)
13393 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13394 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13395 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13396 (write_enn, initialize_async_io, enable_async_io)
13397 (disable_async_io, check_remote_input_interrupt_request)
13398 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13399 (dead_thread_notify, prepare_resume_reply)
13400 (decode_address_to_semicolon, decode_address, decode_m_packet)
13401 (decode_M_packet, decode_X_packet, decode_xfer_write)
13402 (decode_search_memory_packet, unhexify, hexify)
13403 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13404 (look_up_one_symbol, relocate_instruction)
13405 (monitor_output): Move to remote-utils.h, and include it.
13406 * remote-utils.h: New file.
13408 2013-09-05 Pedro Alves <palves@redhat.com>
13410 * server.h (_): Delete.
13412 2013-09-02 Pedro Alves <palves@redhat.com>
13414 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13415 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13417 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13419 2013-09-02 Pierre Muller <muller@sourceware.org>
13421 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13422 or WriteProcessMemory complete successfully and handle
13423 ERROR_PARTIAL_COPY error.
13425 2013-09-02 Pedro Alves <palves@redhat.com>
13427 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13428 error instead of EIO.
13430 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13433 * linux-low.c: Include filestuff.h.
13434 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13435 * lynx-low.c: Include filestuff.h.
13436 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13437 * server.c: Include filestuff.h.
13438 (main): Call notice_open_fds.
13439 * spu-low.c: Include filestuff.h.
13440 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13442 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13444 * Makefile.in: Explain why ../target and ../nat are not
13445 listed as include file search paths.
13446 (linux-waitpid.o): New object file rule.
13447 * configure.srv (srv_native_linux_obj): New variable.
13448 Replace all occurrences of linux native object files with
13449 $srv_native_linux_obj.
13450 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13451 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13452 (linux_enable_event_reporting): Remove declaration.
13453 (my_waitpid): Moved to common/linux-waitpid.c.
13454 (linux_wait_for_event): Pass ptid when calling
13455 linux_enable_event_reporting.
13456 (linux_supports_tracefork_flag): Remove.
13457 (linux_enable_event_reporting): Likewise.
13458 (linux_tracefork_grandchild): Remove.
13459 (STACK_SIZE): Moved to common/linux-ptrace.c.
13460 (linux_tracefork_child): Remove.
13461 (linux_test_for_tracefork): Remove.
13462 (linux_look_up_symbols): Call linux_supports_traceclone.
13463 (initialize_low): Remove call to linux_test_for_tracefork.
13464 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13465 common/linux-ptrace.h.
13466 (PTRACE_TYPE_ARG4): Likewise.
13467 Include linux-ptrace.h.
13469 2013-08-21 Pedro Alves <palves@redhat.com>
13471 * config.in: Renegerate.
13473 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13475 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13476 (SFILES): Remove $(srcdir)/common/target-common.c and
13477 add $(srcdir)/target/waitstatus.c.
13478 (OBS): Remove target-common.o and add waitstatus.o.
13479 (server_h): Remove $(srcdir)/../common/target-common.h and
13480 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13481 and $(srcdir)/../target/waitstatus.h.
13482 (target-common.o): Remove.
13483 (waitstatus.o): New target object file.
13484 * target.h: Do not include target-common.h and
13485 include target/resume.h, target/wait.h and
13486 target/waitstatus.h.
13488 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13490 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13491 to PTRACE_TYPE_ARG3.
13492 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13493 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13495 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13496 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13498 2013-07-27 Jie Zhang <jie@codesourcery.com>
13499 Daniel Jacobowitz <dan@codesourcery.com>
13500 Yao Qi <yao@codesourcery.com>
13502 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13503 (mips-linux-watch.o): New rule.
13504 (mips_linux_watch_h): New variable.
13505 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13507 * linux-mips-low.c: Include mips-linux-watch.h.
13508 (struct arch_process_info, struct arch_lwp_info): New.
13509 (update_watch_registers_callback): New function.
13510 (mips_linux_new_process, mips_linux_new_thread) New functions.
13511 (mips_linux_prepare_to_resume, mips_insert_point): New
13513 (mips_remove_point, mips_stopped_by_watchpoint): New
13515 (rsp_bp_type_to_target_hw_bp_type): New function.
13516 (mips_stopped_data_address): New function.
13517 (the_low_target): Add watchpoint support functions.
13519 2013-07-27 Yao Qi <yao@codesourcery.com>
13521 * i386-low.c: Include break-common.h.
13522 (enum target_hw_bp_type): Remove.
13524 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13526 * Makefile.in (SFILES): /common/target-common.c.
13527 (OBS): Add target-common.o.
13528 (server_h): Add $(srcdir)/../common/target-common.h.
13529 (target-common.o): New target.
13530 * server.c (queue_stop_reply_callback): Free
13531 status string after use.
13532 * target.c (target_waitstatus_to_string): Remove.
13533 * target.h: Include target-common.h.
13534 (resume_kind): Likewise.
13535 (target_waitkind): Likewise.
13536 (target_waitstatus): Likewise.
13537 (TARGET_WNOHANG): Likewise.
13539 2013-07-04 Yao Qi <yao@codesourcery.com>
13541 * Makefile.in (host_alias): Use @host_noncanonical@.
13542 (target_alias): Use @target_noncanonical@.
13543 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13544 ACX_NONCANONICAL_HOST.
13545 * configure: Regenerated.
13548 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13550 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13551 * configure: Rebuild.
13552 * Makefile.in (version_host, version_target): Get from configure.
13553 (version.c): Use $(version_host) and $(version_target).
13555 2013-07-03 Pedro Alves <palves@redhat.com>
13557 * Makefile.in (config.status): Depend on development.sh.
13558 * acinclude.m4: Include libmcheck.m4.
13559 * configure: Regenerate.
13561 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13563 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13564 attribute inside the parentheses.
13565 (winapi_DebugSetProcessKillOnExit): Ditto.
13566 (winapi_DebugBreakProcess): Ditto.
13567 (winapi_GenerateConsoleCtrlEvent): Ditto.
13569 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13571 * notif.h (notif_event): Add a dummy member to avoid compiler
13574 2013-07-01 Pedro Alves <palves@redhat.com>
13576 * hostio.c (HOSTIO_PATH_MAX): Define.
13577 (require_filename, handle_open, handle_unlink, handle_readlink):
13580 2013-07-01 Pedro Alves <palves@redhat.com>
13582 * server.h: Include "pathmax.h".
13583 * linux-low.c: Don't include sys/param.h.
13584 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13586 * win32-low.c: Don't include sys/param.h.
13587 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13589 2013-07-01 Pedro Alves <palves@redhat.com>
13591 * event-loop.c: Don't check HAVE_UNISTD_H before including
13593 * gdbreplay.c: Likewise.
13594 * remote-utils.c: Likewise.
13595 * server.c: Likewise.
13596 * configure.ac: Don't check for unistd.h.
13597 * configure: Regenerate.
13599 2013-06-28 Tom Tromey <tromey@redhat.com>
13601 * Makefile.in (version.c): Use version.in, not
13604 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13606 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13607 * configure: Rebuild.
13608 * Makefile.in (version_host, version_target): Get from configure.
13609 (version.c): Use $(version_host) and $(version_target).
13611 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13613 Fix trace-status to output user name without trailing colon.
13614 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13616 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13618 Fix trace-status to output proper start-time and stop-time.
13619 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13620 output start time and stop time in hex as gdb expects.
13622 2013-06-26 Pedro Alves <pedro@codesourcery.com>
13624 * tracepoint.c (build_traceframe_info_xml): Output trace state
13625 variables present in the trace buffer.
13627 2013-06-24 Tom Tromey <tromey@redhat.com>
13629 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13631 (version.o): Remove.
13632 * gdbreplay.c: Include version.h.
13633 (version, host_name): Don't declare.
13634 * server.h: Include version.h.
13635 (version, host_name): Don't declare.
13637 2013-06-12 Pedro Alves <palves@redhat.com>
13639 * linux-x86-low.c (linux_is_elf64): Delete global.
13640 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13641 with local linux_pid_exe_is_elf_64_file use.
13643 2013-06-11 Pedro Alves <palves@redhat.com>
13645 * linux-low.c (regset_disabled, disable_regset): New functions.
13646 (regsets_fetch_inferior_registers)
13647 (regsets_store_inferior_registers): Use them.
13648 (initialize_regsets_info); Don't allocate the disabled_regsets
13650 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13653 2013-06-11 Pedro Alves <palves@redhat.com>
13655 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13658 2013-06-11 Pedro Alves <palves@redhat.com>
13660 * linux-x86-low.c (initialize_low_arch): Call
13661 init_registers_x32_avx_linux.
13663 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13665 Fix compatibility with Android Bionic.
13666 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13669 2013-06-07 Pedro Alves <palves@redhat.com>
13672 * Makefile.in (OBS): Add tdesc.o.
13673 (IPA_OBJS): Add tdesc-ipa.o.
13674 (tdesc-ipa.o): New rule.
13675 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13677 * linux-low.c (new_inferior): Delete.
13678 (disabled_regsets, num_regsets): Delete.
13679 (linux_add_process): Adjust to set the new per-process
13681 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13682 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13683 was a stop. When calling arch_setup, switch the current inferior
13684 to the thread that got an event.
13685 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13686 (regsets_fetch_inferior_registers)
13687 (regsets_store_inferior_registers): New regsets_info parameter.
13689 (linux_register_in_regsets): New regs_info parameter. Adjust to
13691 (register_addr, fetch_register, store_register): New usrregs_info
13692 parameter. Adjust to use it.
13693 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13694 parameter regs_info. Adjust to use it.
13695 (linux_fetch_registers): Get the current inferior's regs_info, and
13697 (linux_store_registers): Ditto.
13698 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13699 (initialize_low): Don't initialize the target_regsets here. Call
13700 initialize_low_arch.
13701 * linux-low.h (target_regsets): Delete declaration.
13702 (struct regsets_info): New.
13703 (struct usrregs_info): New.
13704 (struct regs_info): New.
13705 (struct process_info_private) <new_inferior>: New field.
13706 (struct linux_target_ops): Delete the num_regs, regmap, and
13707 regset_bitmap fields. New field regs_info.
13708 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13709 * i387-fp.c (num_xmm_registers): Delete.
13710 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13711 calls to new interface.
13712 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13713 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13714 Infer the number of xmm registers from the regcache's target
13716 * i387-fp.h (num_xmm_registers): Delete.
13717 * inferiors.c (add_thread): Don't install the thread's regcache
13719 * proc-service.c (gregset_info): Fetch the current inferior's
13720 regs_info. Adjust to use it.
13721 * regcache.c: Include tdesc.h.
13722 (register_bytes, reg_defs, num_registers)
13723 (gdbserver_expedite_regs): Delete.
13724 (get_thread_regcache): If the thread doesn't have a regcache yet,
13725 create one, instead of aborting gdbserver.
13726 (regcache_invalidate_one): Rename to ...
13727 (regcache_invalidate_thread): ... this.
13728 (regcache_invalidate_one): New.
13729 (regcache_invalidate): Only invalidate registers of the current
13731 (init_register_cache): Add target_desc parameter, and use it.
13732 (new_register_cache): Ditto. Assert the target description has a
13733 non zero registers_size.
13734 (regcache_cpy): Add assertions. Adjust.
13735 (realloc_register_cache, set_register_cache): Delete.
13736 (registers_to_string, registers_from_string): Adjust.
13737 (find_register_by_name, find_regno, find_register_by_number)
13738 (register_cache_size): Add target_desc parameter, and use it.
13739 (free_register_cache_thread, free_register_cache_thread_one)
13740 (regcache_release, register_cache_size): New.
13741 (register_size): Add target_desc parameter, and use it.
13742 (register_data, supply_register, supply_register_zeroed)
13743 (supply_regblock, supply_register_by_name, collect_register)
13744 (collect_register_as_string, collect_register_by_name): Adjust.
13745 * regcache.h (struct target_desc): Forward declare.
13746 (struct regcache) <tdesc>: New field.
13747 (init_register_cache, new_register_cache): Add target_desc
13749 (regcache_invalidate_thread): Declare.
13750 (regcache_invalidate_one): Delete declaration.
13751 (regcache_release): Declare.
13752 (find_register_by_number, register_cache_size, register_size)
13753 (find_regno): Add target_desc parameter.
13754 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13756 * remote-utils.c: Include tdesc.h.
13757 (outreg, prepare_resume_reply): Adjust.
13758 * server.c: Include tdesc.h.
13759 (gdbserver_xmltarget): Delete declaration.
13760 (get_features_xml, process_serial_event): Adjust.
13761 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13763 (struct process_info) <tdesc>: New field.
13764 (ipa_tdesc): Declare.
13765 * tdesc.c: New file.
13766 * tdesc.h: New file.
13767 * tracepoint.c: Include tdesc.h.
13768 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13769 (get_context_regcache): Adjust to pass ipa_tdesc down.
13770 (do_action_at_tracepoint): Adjust to get the register cache size
13771 from the context regcache's description.
13772 (traceframe_walk_blocks): Adjust to get the register cache size
13773 from the current trace frame's description.
13774 (traceframe_get_pc): Adjust to get current trace frame's
13775 description and pass it down.
13776 (gdb_collect): Adjust to get the register cache size from the
13778 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13779 (gdbserver_xmltarget): Delete.
13780 (initialize_low_tracepoint): Set the ipa's target description.
13781 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13782 (initialize_low_tracepoint): Set the ipa's target description.
13783 * linux-x86-low.c: Include tdesc.h.
13784 [__x86_64__] (is_64bit_tdesc): New.
13785 (ps_get_thread_area, x86_get_thread_area): Use it.
13786 (i386_cannot_store_register): Rename to ...
13787 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13788 (i386_cannot_fetch_register): Rename to ...
13789 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13790 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13792 (target_regsets): Rename to ...
13793 (x86_regsets): ... this.
13794 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13796 (x86_siginfo_fixup): Use is_64bit_tdesc.
13797 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13798 (tdesc_x32_avx_linux, tdesc_x32_linux)
13799 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13801 (x86_linux_update_xmltarget): Delete.
13802 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13803 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13804 (AMD64_LINUX_USER64_CS): New.
13805 (x86_linux_read_description): New, based on
13806 x86_linux_update_xmltarget.
13807 (same_process_callback): New.
13808 (x86_arch_setup_process_callback): New.
13809 (x86_linux_update_xmltarget): New.
13810 (x86_regsets_info): New.
13811 (amd64_linux_regs_info): New.
13812 (i386_linux_usrregs_info): New.
13813 (i386_linux_regs_info): New.
13814 (x86_linux_regs_info): New.
13815 (x86_arch_setup): Reimplement.
13816 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13817 (x86_emit_ops): Ditto.
13818 (the_low_target): Adjust. Install x86_linux_regs_info,
13819 x86_cannot_fetch_register, and x86_cannot_store_register.
13820 (initialize_low_arch): New.
13821 * linux-ia64-low.c (tdesc_ia64): Declare.
13822 (ia64_fetch_register): Adjust.
13823 (ia64_usrregs_info, regs_info): New globals.
13824 (ia64_regs_info): New function.
13825 (the_low_target): Adjust.
13826 (initialize_low_arch): New function.
13827 * linux-sparc-low.c (tdesc_sparc64): Declare.
13828 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13830 (sparc_arch_setup): New function.
13831 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13832 (the_low_target): Adjust.
13833 (initialize_low_arch): New function.
13834 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13835 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13836 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13837 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13838 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13839 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13840 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13841 (tdesc_powerpc_isa205_vsx64l): Declare.
13842 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13843 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13844 (ppc_set_pc, ppc_get_hwcap): Adjust.
13845 (ppc_usrregs_info): Forward declare.
13846 (!__powerpc64__) ppc_regmap_adjusted: New global.
13847 (ppc_arch_setup): Adjust to the current process'es target
13849 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13850 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13851 (ppc_store_evrregset): Adjust.
13852 (target_regsets): Rename to ...
13853 (ppc_regsets): ... this, and make static.
13854 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13855 (ppc_regs_info): New function.
13856 (the_low_target): Adjust.
13857 (initialize_low_arch): New function.
13858 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13859 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13860 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13861 (tdesc_s390x_linux64v2): Declare.
13862 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13863 (s390_fill_gregset, s390_store_last_break): Adjust.
13864 (target_regsets): Rename to ...
13865 (s390_regsets): ... this, and make static.
13866 (s390_get_pc, s390_set_pc): Adjust.
13867 (s390_get_hwcap): New target_desc parameter, and use it.
13868 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13869 (s390_arch_setup): Adjust to set the current process'es target
13870 description. Don't adjust the regmap.
13871 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13872 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13873 (regs_info_3264): New globals.
13874 (s390_regs_info): New function.
13875 (the_low_target): Adjust.
13876 (initialize_low_arch): New function.
13877 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13878 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13879 [__mips64] (init_registers_mips_linux)
13880 (init_registers_mips_dsp_linux): Delete defines.
13881 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13882 (have_dsp): New global.
13883 (mips_read_description): New, based on mips_arch_setup.
13884 (mips_arch_setup): Reimplement.
13885 (get_usrregs_info): New function.
13886 (mips_cannot_fetch_register, mips_cannot_store_register)
13887 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13888 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13889 (target_regsets): Rename to ...
13890 (mips_regsets): ... this, and make static.
13891 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13892 (dsp_regs_info, regs_info): New globals.
13893 (mips_regs_info): New function.
13894 (the_low_target): Adjust.
13895 (initialize_low_arch): New function.
13896 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13897 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13899 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13900 (arm_read_description): New, with bits factored from
13902 (arm_arch_setup): Reimplement.
13903 (target_regsets): Rename to ...
13904 (arm_regsets): ... this, and make static.
13905 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13906 (arm_regs_info): New function.
13907 (the_low_target): Adjust.
13908 (initialize_low_arch): New function.
13909 * linux-m68k-low.c (tdesc_m68k): Declare.
13910 (target_regsets): Rename to ...
13911 (m68k_regsets): ... this, and make static.
13912 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13913 (m68k_regs_info): New function.
13914 (m68k_arch_setup): New function.
13915 (the_low_target): Adjust.
13916 (initialize_low_arch): New function.
13917 * linux-sh-low.c (tdesc_sharch): Declare.
13918 (target_regsets): Rename to ...
13919 (sh_regsets): ... this, and make static.
13920 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13921 (sh_regs_info, sh_arch_setup): New functions.
13922 (the_low_target): Adjust.
13923 (initialize_low_arch): New function.
13924 * linux-bfin-low.c (tdesc_bfin): Declare.
13925 (bfin_arch_setup): New function.
13926 (bfin_usrregs_info, regs_info): New globals.
13927 (bfin_regs_info): New function.
13928 (the_low_target): Adjust.
13929 (initialize_low_arch): New function.
13930 * linux-cris-low.c (tdesc_cris): Declare.
13931 (cris_arch_setup): New function.
13932 (cris_usrregs_info, regs_info): New globals.
13933 (cris_regs_info): New function.
13934 (the_low_target): Adjust.
13935 (initialize_low_arch): New function.
13936 * linux-cris-low.c (tdesc_crisv32): Declare.
13937 (cris_arch_setup): New function.
13938 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13939 (cris_regs_info): New function.
13940 (the_low_target): Adjust.
13941 (initialize_low_arch): New function.
13942 * linux-m32r-low.c (tdesc_m32r): Declare.
13943 (m32r_arch_setup): New function.
13944 (m32r_usrregs_info, regs_info): New globals.
13945 (m32r_regs_info): Adjust.
13946 (initialize_low_arch): New function.
13947 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13948 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13949 (tic6x_usrregs_info): Forward declare.
13950 (tic6x_read_description): New function, based on ...
13951 (tic6x_arch_setup): ... this. Reimplement.
13952 (target_regsets): Rename to ...
13953 (tic6x_regsets): ... this, and make static.
13954 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13955 (tic6x_regs_info): New function.
13956 (the_low_target): Adjust.
13957 (initialize_low_arch): New function.
13958 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13959 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13960 (target_regsets): Rename to ...
13961 (xtensa_regsets): ... this, and make static.
13962 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13964 (xtensa_arch_setup, xtensa_regs_info): New functions.
13965 (the_low_target): Adjust.
13966 (initialize_low_arch): New function.
13967 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13968 (nios2_arch_setup): Set the current process'es tdesc.
13969 (target_regsets): Rename to ...
13970 (nios2_regsets): ... this.
13971 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13972 (nios2_regs_info): New function.
13973 (the_low_target): Adjust.
13974 (initialize_low_arch): New function.
13975 * linux-aarch64-low.c (tdesc_aarch64): Declare.
13976 (aarch64_arch_setup): Set the current process'es tdesc.
13977 (target_regsets): Rename to ...
13978 (aarch64_regsets): ... this.
13979 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
13980 (aarch64_regs_info): New function.
13981 (the_low_target): Adjust.
13982 (initialize_low_arch): New function.
13983 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
13985 (target_regsets): Rename to ...
13986 (tile_regsets): ... this.
13987 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
13988 (tile_regs_info): New function.
13989 (tile_arch_setup): Set the current process'es tdesc.
13990 (the_low_target): Adjust.
13991 (initialize_low_arch): New function.
13992 * spu-low.c (tdesc_spu): Declare.
13993 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
13994 * win32-arm-low.c (tdesc_arm): Declare.
13995 (arm_arch_setup): New function.
13996 (the_low_target): Install arm_arch_setup instead of
13997 init_registers_arm.
13998 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
13999 (init_windows_x86): Rename to ...
14000 (i386_arch_setup): ... this. Set `win32_tdesc'.
14001 (the_low_target): Adjust.
14002 * win32-low.c (win32_tdesc): New global.
14003 (child_add_thread): Don't create the thread cache here.
14004 (do_initial_child_stuff): Set the new process'es tdesc.
14005 * win32-low.h (struct target_desc): Forward declare.
14006 (win32_tdesc): Declare.
14007 * lynx-i386-low.c (tdesc_i386): Declare global.
14008 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14009 * lynx-low.c (lynx_tdesc): New global.
14010 (lynx_add_process): Set the new process'es tdesc.
14011 * lynx-low.h (struct target_desc): Forward declare.
14012 (lynx_tdesc): Declare global.
14013 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14014 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14015 * nto-low.c (nto_tdesc): New global.
14016 (do_attach): Set the new process'es tdesc.
14017 * nto-low.h (struct target_desc): Forward declare.
14018 (nto_tdesc): Declare.
14019 * nto-x86-low.c (tdesc_i386): Declare.
14020 (nto_x86_arch_setup): Set `nto_tdesc'.
14022 2013-06-04 Gary Benson <gbenson@redhat.com>
14024 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14025 to qSupported response when appropriate.
14026 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14027 with nonzero-length annex.
14028 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14029 arguments supplied in annex.
14031 2013-05-31 Doug Evans <dje@google.com>
14034 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14035 64 bits in 64-cross-32 environment.
14037 2013-05-28 Pedro Alves <palves@redhat.com>
14039 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14040 (aarch64-without-fpu.c): Delete rule.
14041 * configure.srv (aarch64*-*-linux*): Remove references to
14042 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14043 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14046 2013-05-24 Pedro Alves <palves@redhat.com>
14048 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14049 instead of strchr/decode_address. Error if the range isn't split
14050 with a ','. Don't assume there's be a ':' in the action.
14052 2013-05-23 Yao Qi <yao@codesourcery.com>
14053 Pedro Alves <palves@redhat.com>
14055 * linux-low.c (lwp_in_step_range): New function.
14056 (linux_wait_1): If the thread was range stepping and stopped
14057 outside the stepping range, report the stop to GDB. Otherwise,
14058 continue stepping. Add range stepping debug output.
14059 (linux_set_resume_request): Copy the step range from the resume
14060 request to the lwp.
14061 (linux_supports_range_stepping): New.
14062 (linux_target_ops) <supports_range_stepping>: Set to
14063 linux_supports_range_stepping.
14064 * linux-low.h (struct linux_target_ops)
14065 <supports_range_stepping>: New field.
14066 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14067 * linux-x86-low.c (x86_supports_range_stepping): New.
14068 (the_low_target) <supports_range_stepping>: Set to
14069 x86_supports_range_stepping.
14070 * server.c (handle_v_cont): Handle 'r' action.
14071 (handle_v_requests): Append ";r" if the target supports range
14073 * target.h (struct thread_resume) <step_range_start,
14074 step_range_end>: New fields.
14075 (struct target_ops) <supports_range_stepping>:
14077 (target_supports_range_stepping): New macro.
14079 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14081 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14082 confusion in comment.
14084 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14086 * lynx-low.c (struct process_info_private): New type.
14087 (lynx_add_process): New function.
14088 (lynx_create_inferior, lynx_attach): Replace calls to
14089 add_process by calls to lynx_add_process.
14090 (lynx_resume): If PTID is null, then try using
14091 current_process()->private->last_wait_event_ptid.
14093 (lynx_clear_inferiors): Delete. The contents of that function
14094 has been inlined in lynx_mourn;
14095 (lynx_wait_1): Save the ptid in the process's private data.
14096 (lynx_mourn): Free the process' private data. Replace call
14097 to lynx_clear_inferiors by call to clear_inferiors.
14099 2013-05-17 Yao Qi <yao@codesourcery.com>
14101 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14104 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
14106 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14107 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14108 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14109 PT_TEXT_END_ADDR guards. Update comments.
14110 (linux_target_op) <read_offsets>: Conditionally define to
14111 linux_read_offsets if the target is UCLIBC and if it defines
14112 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14114 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14115 Andrew Jenner <andrew@codesourcery.com>
14117 * Makefile.in (SFILES): Add linux-nios2-low.c.
14118 (clean): Add action to delete nios2-linux.c.
14119 (nios2-linux.c): New rule.
14120 * configure.srv: Add nios2*-*-linux*.
14121 * linux-nios2-low.c: New.
14123 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14125 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14127 2013-04-25 Hui Zhu <hui@codesourcery.com>
14130 * ax.c (ax_printf): Add fflush.
14132 2013-04-22 Tom Tromey <tromey@redhat.com>
14134 * Makefile.in (SFILES): Add filestuff.c.
14135 (OBS): Add filestuff.o.
14136 (filestuff.o): New target.
14137 * config.in, configure: Rebuild.
14138 * configure.ac: Check for fdwalk, pipe2.
14140 2013-04-17 Pedro Alves <palves@redhat.com>
14142 * configure.ac (USE_THREAD_DB): Delete variable.
14143 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14144 Don't AC_SUBST USE_THREAD_DB.
14145 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14146 * config.in, configure: Regenerate.
14148 2013-04-16 Pedro Alves <palves@redhat.com>
14150 * linux-low.h (struct lwp_info) <thread_known>: Move under
14151 the USE_THREAD_DB #ifdef.
14153 2013-04-16 Pedro Alves <palves@redhat.com>
14155 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14156 (linux-low.o): Delete rule.
14157 * linux-low.h: Always include "gdb_thread_db.h" instead of
14158 conditionally including thread_db.h.
14159 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14162 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14164 * Makefile.in (install-only): Fix make install regression.
14166 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14168 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14169 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14171 * gdbserver.1: Remove.
14173 2013-03-22 Pedro Alves <palves@redhat.com>
14175 * linux-low.c (handle_extended_wait): Don't call
14176 linux_enable_event_reporting.
14178 2013-03-15 Tony Theodore <tonyt@logyst.com>
14181 * Makefile.in (SHELL): Use @SHELL@.
14183 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14185 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14188 2013-03-13 Joel Brobecker <brobecker@adacore.com>
14190 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14191 Remove extraneous NULL element.
14193 2013-03-13 Yao Qi <yao@codesourcery.com>
14195 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14196 'V' block in trace frame.
14198 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14200 * target.h (struct target_ops): Add btrace ops.
14201 (target_supports_btrace): New macro.
14202 (target_enable_btrace): New macro.
14203 (target_disable_btrace): New macro.
14204 (target_read_btrace): New macro.
14205 * gdbthread.h (struct thread_info): Add btrace field.
14206 * server.c: Include btrace-common.h.
14207 (handle_btrace_general_set): New function.
14208 (handle_btrace_enable): New function.
14209 (handle_btrace_disable): New function.
14210 (handle_general_set): Call handle_btrace_general_set.
14211 (handle_qxfer_btrace): New function.
14212 (struct qxfer qxfer_packets[]): Add btrace entry.
14213 * inferiors.c (remove_thread): Disable btrace.
14214 * linux-low: Include linux-btrace.h.
14215 (linux_low_enable_btrace): New function.
14216 (linux_low_read_btrace): New function.
14217 (linux_target_ops): Add btrace ops.
14218 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14219 Add srv_linux_btrace=yes.
14220 (x86_64-*-linux*): Add linux-btrace.o.
14221 Add srv_linux_btrace=yes.
14222 * configure.ac: Define HAVE_LINUX_BTRACE.
14223 * config.in: Regenerated.
14224 * configure: Regenerated.
14226 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14228 * server.c (handle_qxfer): Preserve error message if -3 is
14230 (qxfer): Document the -3 return value.
14232 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14234 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14235 (linux_btrace_h): New variable.
14236 (linux-btrace.o): New rule.
14238 2013-03-08 Stan Shebs <stan@codesourcery.com>
14239 Hafiz Abid Qadeer <abidh@codesourcery.com>
14241 * tracepoint.c (trace_buffer_size): New global.
14242 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14243 (init_trace_buffer): Change to one-argument function. Allocate
14244 trace buffer memory.
14245 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14246 handle QTBuffer:size packet.
14247 (cmd_bigqtbuffer_size): New function.
14248 (initialize_tracepoint): Call init_trace_buffer with
14249 DEFAULT_TRACE_BUFFER_SIZE.
14250 * server.c (handle_query): Add QTBuffer:size in the
14253 2013-03-07 Yao Qi <yao@codesourcery.com>
14255 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14256 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14258 (cmd_qtsp): Adjust condition. Do post increment.
14259 Set cur_action and cur_step_action back to 0.
14261 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14264 * linux-low.c (linux_write_memory): Return early success if LEN is
14267 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
14269 * configure.srv: Add x86_64-*-cygwin* as target.
14271 2013-02-28 Tom Tromey <tromey@redhat.com>
14273 * configure.ac: Invoke AC_SYS_LARGEFILE.
14274 * configure, config.in: Rebuild.
14276 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
14278 * win32-low.c: Throughout, fix format strings and casts of
14279 printf-like functions to avoid type related warnings on all
14281 (get_child_debug_event): Print dwDebugEventCode as hex since
14282 that's how it's usually documented.
14284 2013-02-28 Yao Qi <yao@codesourcery.com>
14286 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14289 2013-02-27 Jiong Wang <jiwang@tilera.com>
14291 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14292 (reg-tilegx32.c): New rule.
14293 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14294 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14295 different register info initializer according to elf class.
14296 (init_registers_tilgx32): New function. The tilegx32 register info
14298 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14299 (tile_store_gregset): Likewise.
14301 2013-02-27 Yao Qi <yao@codesourcery.com>
14303 * server.c (process_point_options): Print debug message when
14304 debug_threads is true.
14306 2013-02-26 Yao Qi <yao@codesourcery.com>
14308 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14310 2013-02-19 Pedro Alves <palves@redhat.com>
14311 Kai Tietz <ktietz@redhat.com>
14315 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14316 instead of strtoul to extract address from packet.
14317 (process_serial_event) <'z'>: Likewise.
14319 2013-02-18 Yao Qi <yao@codesourcery.com>
14321 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14323 2013-02-14 Pedro Alves <palves@redhat.com>
14327 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14328 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14330 2013-02-14 Pedro Alves <palves@redhat.com>
14332 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14334 2013-02-14 Pedro Alves <palves@redhat.com>
14336 * tracepoint.c (save_string): Delete.
14337 (add_tracepoint_action): Use savestring instead of save_string.
14339 2013-02-12 Pedro Alves <palves@redhat.com>
14341 * linux-xtensa-low.c: Ditto.
14342 * xtensa-xtregs.c: Ditto.
14344 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14346 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14349 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14351 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14352 aarch64_num_wp_regs and aarch64_num_bp_regs to
14353 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14355 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14357 * linux-aarch64-low.c (ps_get_thread_area): Replace
14358 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14360 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14361 Marcus Shawcroft <marcus.shawcroft@arm.com>
14362 Nigel Stephens <nigel.stephens@arm.com>
14363 Yufeng Zhang <yufeng.zhang@arm.com>
14365 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14366 (aarch64.c, aarch64-without-fpu.c): New targets.
14367 * configure.srv (aarch64*-*-linux*): New.
14368 * linux-aarch64-low.c: New file.
14370 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14372 * linux-low.c (handle_extended_wait, linux_create_inferior)
14373 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14374 (dequeue_one_deferred_signal, linux_resume_one_thread)
14375 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14376 (linux_tracefork_grandchild, linux_test_for_tracefork)
14377 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14378 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14379 where the argument is 0.
14381 2013-01-25 Yao Qi <yao@codesourcery.com>
14383 * event-loop.c: Include "queue.h".
14384 (gdb_event_p): New typedef.
14385 (struct gdb_event) <next_event>: Remove.
14386 (event_queue): Change to QUEUE(gdb_event_p).
14387 (async_queue_event): Remove.
14388 (gdb_event_xfree): New.
14389 (initialize_event_loop): New.
14390 (process_event): Use API from QUEUE.
14391 (wait_for_event): Likewise.
14392 * server.c (main): Call initialize_event_loop.
14393 * server.h (initialize_event_loop): Declare.
14395 2013-01-18 Yao Qi <yao@codesourcery.com>
14397 * ax.h (struct eval_agent_expr_context): New.
14398 (gdb_eval_agent_expr): Update declaration.
14399 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14400 TFRAME. Add new argument CTX.
14401 * server.h (struct eval_agent_expr_context): Declare.
14402 (agent_mem_read, agent_tsv_read): Update declaration.
14403 (agent_mem_read_string): Likewise.
14404 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14405 (add_traceframe_block): Add new argument TPOINT.
14406 Increase TPOINT->traceframe_usage.
14407 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14408 eval_tracepoint_agent_expr.
14409 (condition_true_at_tracepoint): Likewise.
14410 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14411 (agent_mem_read_string, agent_tsv_read): Likewise.
14413 2013-01-16 Yao Qi <yao@codesourcery.com>
14415 * linux-low.c (linux_resume_one_lwp): Don't check
14416 'lwp->bp_reinsert != 0'.
14418 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14419 Pedro Alves <palves@redhat.com>
14421 * lynx-low.c (ptrace_request_to_str): Define a temporary
14422 macro and use it to simplify this function's implementation.
14424 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14426 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14429 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14431 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14433 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14435 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14437 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14439 * lynx-low.c (lynx_resume): Use the resume_info parameter
14440 to determine the ptid for the lynx_ptrace call, unless
14441 it is equal to minus_one_ptid, in which case we use the
14442 ptid of the current_inferior.
14443 (lynx_wait_1): After having received a thread create/exit
14444 event, resume the inferior's execution using the signaling
14445 thread's ptid, rather than the old ptid.
14447 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14449 * lynx-low.c (lynx_resume): Delete variable ret.
14451 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14453 * gdbreplay.c (gdbreplay_version): Update copyright year.
14454 * server.c (gdbserver_version): Likewise.
14456 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14458 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14461 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14463 * lynx-low.c (ptrace_request_to_str): Add handling for
14464 PTRACE_GETTRACESIG.
14466 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14468 * lynx-low.c (lynx_attach): Delete variable new_process.
14470 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14472 * lynx-low.c (lynx_create_inferior): Delete variable
14475 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14477 * lynx-low.c (ptrace_request_to_str): Do not handle
14478 PTRACE_GETTHREADLIST if this macro does not exist.
14480 2012-12-15 Yao Qi <yao@codesourcery.com>
14482 * Makefile.in (OBS): Add notif.o.
14483 * notif.c, notif.h: New.
14484 * server.c: Include "notif.h".
14485 (struct vstop_notif) <next>: Remove.
14487 (queue_stop_reply): Update.
14488 (push_event, send_next_stop_reply): Remove.
14489 (discard_queued_stop_replies): Update.
14490 (notif_stop): New variable.
14491 (handle_v_stopped): Remove.
14492 (handle_v_requests): Don't call handle_v_stopped. Call
14493 handle_ack_notif instead.
14494 (queue_stop_reply_callback): Call notif_event_enque instead
14495 of queue_stop_reply.
14496 (handle_status): Don't call send_next_stop_reply, call
14497 notif_write_event instead.
14498 (kill_inferior_callback): Likewise.
14499 (detach_or_kill_inferior_callback): Likewise.
14500 (main): Call initialize_notif.
14501 (process_serial_event): Call QUEUE_is_empty.
14502 (handle_target_event): Call notif_push instead of push event.
14503 * server.h (push_event): Remove declaration.
14505 2012-12-10 Tom Tromey <tromey@redhat.com>
14507 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14508 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14511 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14512 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14513 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14514 (amd64-linux-ipa.o, ax.o): Rewrite.
14515 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14516 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14517 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14518 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14519 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14520 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14521 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14522 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14523 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14524 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14525 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14526 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14527 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14528 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14529 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14530 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14531 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14532 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14533 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14534 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14535 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14536 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14537 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14538 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14539 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14540 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14541 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14542 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14543 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14544 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14545 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14546 (reg-tilegx.o): Remove.
14547 (all_object_files): New macro.
14548 Include .deps files.
14549 * aclocal.m4, configure: Rebuild.
14550 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14551 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14552 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14554 2012-12-05 Tom Tromey <tromey@redhat.com>
14557 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14559 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14561 * configure.ac: Check for linux/perf_event.h.
14562 * config.in: Regenerated.
14563 * configure: Regenerated.
14565 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14567 * hostio.c (handle_readlink): Decrease buffer size
14568 parameter passed to readlink by one byte.
14570 2012-11-26 Yao Qi <yao@codesourcery.com>
14572 * configure.ac (build_warnings): Append '-Wempty-body'.
14573 * configure: Regenerated.
14574 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14577 2012-11-15 Pierre Muller <muller@sourceware.org>
14579 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14580 * config.in: Regenerate.
14581 * configure: Regenerate.
14582 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14583 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14584 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14585 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14587 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14588 instead of <sys/wait.h> header.
14589 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14591 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
14593 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14594 (various make rules): Remove -DGDBSERVER
14596 2012-11-09 Yao Qi <yao@codesourcery.com>
14598 * spu-low.c (current_ptid): Move it to ..
14599 * gdbthread.h: ... here. New.
14600 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14601 * server.c (myresume, process_serial_event): Likewise.
14602 * thread-db.c (thread_db_find_new_threads): Likewise.
14603 * tracepoint.c (run_inferior_command): Likewise.
14605 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
14607 * server.c (handle_search_memory_1): Include access length in
14610 2012-09-05 Michael Brandt <michael.brandt@axis.com>
14612 * linux-crisv32-low.c: Fix compile errors.
14614 2012-09-04 Yao Qi <yao@codesourcery.com>
14616 * tracepoint.c (cmd_qtsv): Adjust debug message.
14617 Don't check CUR_TPOINT.
14619 2012-08-28 Yao Qi <yao@codesourcery.com>
14621 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14622 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14623 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14624 Remove declarations of xmalloc, xreallloc, xstrdup and
14626 * Makefile.in (libiberty_h): New.
14627 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14628 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14630 2012-08-23 Yao Qi <yao@codesourcery.com>
14632 * server.h: Remove declaration of 'xsnprintf'.
14634 2012-08-22 Keith Seitz <keiths@redhat.com>
14636 * server.h: Include build-gnulib-gbserver/config.h.
14637 * gdbreplay.c: Likewise.
14639 2012-08-08 Doug Evans <dje@google.com>
14641 * Makefile.in (SFILES): Add gdb_vecs.c.
14642 (OBS): Add gdb_vecs.o.
14643 (gdb_vecs_h, host_defs_h): New variables.
14644 (thread-db.o): Add $(gdb_vecs_h) dependency.
14645 (gdb_vecs.o): New rule.
14646 * thread-db.c: #include "gdb_vecs.h".
14647 (thread_db_load_search): Use a vector to iterate over path elements.
14648 Handle text appearing after "$pdir".
14650 * configure.ac: Add check for strstr.
14651 * config.in: Regenerate.
14652 * configure: Regenerate.
14654 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14656 * hostio.c (handle_pread): If pread fails, fall back to attempting
14658 (handle_pwrite): Likewise for pwrite.
14660 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14662 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14663 between unsupported TYPE and unimplementable ADDR/LEN combination.
14664 (arm_insert_point): Act on new return value.
14666 2012-07-31 Pedro Alves <palves@redhat.com>
14668 * server.c (process_point_options): Only skip tokens if we find
14669 one that is unrecognized. Don't treat 'X' specially while
14670 skipping unrecognized tokens.
14672 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14674 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14675 to 4-byte-align HW breakpoint addresses for Thumb.
14677 2012-07-27 Yao Qi <yao@codesourcery.com>
14681 * server.h: Declare gdb_agent_about_to_close.
14682 * target.c (kill_inferior): Include "agent.h".
14683 New. Send command 'kill'.
14684 * target.h (kill_inferior): Removed macro.
14685 * tracepoint.c (gdb_agent_about_to_close): New.
14686 (gdb_agent_helper_thread): Handle command 'close'.
14687 Wait endlessly until the inferior stops.
14688 Install gdb_agent_remove_socket to atexit hook.
14689 (agent_socket_name): New static variable.
14690 (gdb_agent_socket_init): Replace local variable 'name' with
14691 'agent_socket_name'.
14692 (gdb_agent_remove_socket): New.
14694 2012-07-27 Yao Qi <yao@codesourcery.com>
14696 * server.c (process_point_options): Stop at 'X' when parsing.
14698 2012-07-19 Michael Eager <eager@eagercon.com>
14700 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
14702 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14703 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14704 hardware breakpoint.
14706 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14708 * gdbserver/linux-low.c (initialize_low): Call
14709 linux_ptrace_init_warnings.
14711 2012-07-02 Doug Evans <dje@google.com>
14713 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14716 2012-07-02 Stan Shebs <stan@codesourcery.com>
14718 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14719 (ax.o): Add it to build rule.
14721 (OBS): Add format.o.
14722 (IPA_OBS): Add format.o.
14723 * server.c (handle_query): Claim support for breakpoint commands.
14724 (process_point_options): Add command case.
14725 (process_serial_event): Leave running if there are printfs in
14727 * mem-break.h (any_persistent_commands): Declare.
14728 (add_breakpoint_commands): Declare.
14729 (gdb_no_commands_at_breakpoint): Declare.
14730 (run_breakpoint_commands): Declare.
14731 * mem-break.c (struct point_command_list): New struct.
14732 (struct breakpoint): New field command_list.
14733 (any_persistent_commands): New function.
14734 (add_commands_to_breakpoint): New function.
14735 (add_breakpoint_commands): New function.
14736 (gdb_no_commands_at_breakpoint): New function.
14737 (run_breakpoint_commands): New function.
14738 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14740 * ax.c: Include format.h.
14741 (ax_printf): New function.
14742 (gdb_eval_agent_expr): Add printf opcode.
14744 2012-06-13 Yao Qi <yao@codesourcery.com>
14746 * server.c (start_inferior): Remove duplicated writes to fields
14747 'last_resume_kind' and 'last_status' of 'current_inferior'.
14749 2012-06-12 Yao Qi <yao@codesourcery.com>
14750 Pedro Alves <palves@redhat.com>
14752 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14754 * server.c (handle_v_cont): Extend comment.
14756 2012-06-11 Yao Qi <yao@codesourcery.com>
14758 * linux-low.c (linux_attach): Add 'static'.
14760 2012-06-06 Yao Qi <yao@codesourcery.com>
14762 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14764 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14766 Fix gcc -flto compilation warning.
14767 * server.c (main): Make variable multi_mode and attach volatile.
14769 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14771 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14772 if the platform doesn't know about it.
14774 2012-05-30 Jeff Kenton <jkenton@tilera.com>
14776 * Makefile.in (SFILES): Add linux-tile-low.c.
14777 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14778 * configure.srv: Handle tilegx-*-linux*.
14779 * linux-tile-low.c: New file.
14781 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14783 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14785 2012-05-24 Pedro Alves <palves@redhat.com>
14789 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
14791 2012-05-24 Pedro Alves <palves@redhat.com>
14795 Replace target_signal with gdb_signal throughout.
14797 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14799 * linux-low.c (linux_store_registers): Avoid the copying sequence
14800 when no data has been retrieved by ptrace.
14802 2012-05-22 Will Deacon <will.deacon@arm.com>
14804 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14805 Include asm/ptrace.h.
14806 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14809 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14811 * linux-low.c (linux_store_registers): Don't re-retrieve data
14812 with ptrace that has already been obtained from /proc. Always
14813 copy any data retrieved with ptrace to the buffer supplied.
14815 2012-05-11 Yao Qi <yao@codesourcery.com>
14816 Pedro Alves <palves@redhat.com>
14818 * linux-low.c (enum stopping_threads_kind): New.
14819 (stopping_threads): Change type to `enum stopping_threads_kind'.
14820 (handle_extended_wait): If stopping and suspending threads, leave
14821 the new_lwp suspended too.
14822 (linux_wait_for_event): Adjust.
14823 (stop_all_lwps): Set `stopping_threads' to
14824 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14825 whether we're suspending threads or just stopping them. Assert no
14828 2012-04-29 Yao Qi <yao@codesourcery.com>
14830 * server.h: Move some code to ...
14831 * gdbthread.h: ... here. New.
14832 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14833 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14834 (nto-low.o, win32-low.o): Likewise.
14835 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14836 * regcache.c, remote-utils.c, server.c: Likewise.
14837 * target.c, tracepoint.c, win32-low.c: Likewise.
14839 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14841 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14842 (PTRACE_ARG4_TYPE): Likewise.
14843 (PTRACE_XFER_TYPE): Likewise.
14844 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14845 ptrace to PTRACE_ARG3_TYPE.
14846 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14847 (PTRACE_ARG4_TYPE): Likewise.
14848 (PTRACE_XFER_TYPE): Likewise.
14849 (linux_detach_one_lwp): Cast fourth argument of
14850 ptrace to long then PTRACE_ARG4_TYPE.
14851 (regsets_fetch_inferior_registers): Cast third argument of
14852 ptrace to long then PTRACE_ARG3_TYPE.
14853 (regsets_store_inferior_registers): Likewise.
14855 2012-04-20 Pedro Alves <palves@redhat.com>
14857 * configure: Regenerate.
14859 2012-04-19 Pedro Alves <palves@redhat.com>
14861 * Makefile.in (GNULIB_BUILDDIR): New.
14862 (LIBGNU, INCGNU, GNULIB_H): Adjust.
14863 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14864 (all, install-only, uninstall, clean-info, all-lib, clean): No
14865 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14866 (maintainer-clean realclean distclean): Use subdir_do.
14868 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
14869 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
14870 * acinclude.m4: Include acx_configure_dir.m4.
14871 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14872 calls. Call AC_PROG_RANLIB. Configure gnulib using
14875 (GNULIB_STDINT_H): Adjust.
14876 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14877 * gdbreplay.c: Include build-gnulib/config.h.
14878 * server.h: Likewise.
14879 * aclocal.m4: Regenerate.
14880 * config.in: Regenerate.
14881 * configure: Regenerate.
14883 2012-04-19 Pedro Alves <palves@redhat.com>
14885 * Makefile.in (LIBGNU, INCGNU): Adjust.
14886 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14887 (all, install-only, uninstall, clean-info, all-lib, clean)
14888 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14889 * configure.ac: Adjust AC_OUTPUT output.
14890 * aclocal.m4: Regenerate.
14891 * configure: Regenerate.
14893 2012-04-19 Pedro Alves <palves@redhat.com>
14895 * Makefile.in (generated_files): New.
14896 (server_h): Remove the explicit dependency on config.h, and depend
14897 on $generated_files.
14899 2012-04-19 Pedro Alves <palves@redhat.com>
14901 * Makefile.in (INCGNU): Add -Ignulib.
14903 2012-04-19 Pedro Alves <palves@redhat.com>
14905 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14906 (INCGNU): ... this, and spell out -I here.
14907 (GNULIB_LIB): Rename to ...
14908 (LIBGNU): ... this.
14909 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14911 2012-04-19 Pedro Alves <palves@redhat.com>
14913 * config.in: Regenerate.
14915 2012-04-19 Pedro Alves <palves@redhat.com>
14917 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14918 * server.h (memmem): Remove declaration.
14919 * config.in: Regenerate.
14920 * configure: Regenerate.
14922 2012-04-19 Yao Qi <yao@codesourcery.com>
14924 * Makefile.in (SFILES): Add common/vec.c.
14928 2012-04-19 Yao Qi <yao@codesourcery.com>
14930 * remote-utils.c (prepare_resume_reply): Replace with macro
14931 target_core_of_thread.
14932 * server.c (handle_qxfer_threads_proper): Likewise.
14933 * target.h (traget_core_of_thread): New macro.
14935 2012-04-18 Pedro Alves <palves@redhat.com>
14937 * aclocal.m4: Regenerate.
14938 * configure: Regenerate.
14940 2012-04-16 Yao Qi <yao@codesourcery.com>
14942 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14943 duplicated on address.
14945 2012-04-16 Yao Qi <yao@codesourcery.com>
14947 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14948 (struct tracepoint_action_ops) <send>: New field.
14949 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14950 (agent_expr_send, x_tracepoint_action_send): New.
14951 (l_tracepoint_action_send): New.
14952 (cmd_qtdp): Download and install tracepoint
14953 according to `use_agent'.
14954 (run_inferior_command): Add one more parameter `len'.
14956 (tracepoint_send_agent): New.
14957 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14959 2012-04-16 Yao Qi <yao@codesourcery.com>
14961 * tracepoint.c (download_tracepoints): Moved to ...
14962 (cmd_qtstart): ... here.
14964 2012-04-14 Yao Qi <yao@codesourcery.com>
14966 * tracepoint.c: Include inttypes.h.
14967 (struct collect_memory_action): Use sized types.
14968 (struct tracepoint): Likewise.
14969 (cmd_qtdp, stop_tracing): Update print specifiers.
14970 (cmd_qtp, response_tracepoint): Likewise.
14971 (collect_data_at_tracepoint): Likewise.
14972 (collect_data_at_step): Likewise.
14974 2012-04-14 Yao Qi <yao@codesourcery.com>
14976 Import gnulib module inttypes.
14977 * aclocal.m4, config.in, configure: Regenerated.
14979 2012-04-14 Yao Qi <yao@codesourcery.com>
14981 * Makefile.in (maintainer-clean, realclean, distclean): Remove
14982 Makefile and config.status at last.
14984 2012-04-13 Yao Qi <yao@codesourcery.com>
14986 * tracepoint.c: Include stdint.h unconditionally.
14988 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14990 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
14991 on BFD_HAVE_SYS_PROCFS_TYPE.
14992 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
14993 * configure: Regenerate.
14994 * config.in: Likewise.
14996 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
14998 * Makefile.in (clean): Also remove x32.c x32-linux.c
14999 x32-avx.c x32-avx-linux.c.
15000 (x32.o): New target.
15002 (x32-linux.o): Likewise.
15003 (x32-linux.c): Likewise.
15004 (x32-avx.o): Likewise.
15005 (x32-avx.c): Likewise.
15006 (x32-avx-linux.o): Likewise.
15007 (x32-avx-linux.c): Likewise.
15009 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15010 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15011 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15012 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15013 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15014 i386/x32-avx-linux.xml.
15016 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15017 (init_registers_x32_avx_linux): Likwise.
15018 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15019 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15021 2012-04-13 Pedro Alves <palves@redhat.com>
15023 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15024 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15025 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15026 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15029 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15031 * linux-x86-low.c (compat_x32_clock_t): New.
15032 (compat_x32_siginfo_t): Likewise.
15033 (compat_x32_siginfo_from_siginfo): Likewise.
15034 (siginfo_from_compat_x32_siginfo): Likewise.
15035 (linux_is_elf64): Likewise.
15036 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15037 and siginfo_from_compat_x32_siginfo for x32.
15038 (x86_arch_setup): Set linux_is_elf64.
15040 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15043 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15045 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15046 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15047 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15048 compatible with process.
15050 2012-04-12 Yao Qi <yao@codesourcery.com>
15052 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15053 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15054 (install-only, install-info, clean): Handle sub dir gnulib.
15055 (all-lib, am--refresh): New targets.
15056 (memmem.o): Remove target.
15057 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15058 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15059 (AC_REPLACE_FUNCS): Remove memmem.
15060 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15061 (AC_OUTPUT): Generate Makefile in gnulib/.
15062 * aclocal.m4, config.in, configure: Regenerated.
15064 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15066 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15068 2012-04-05 Pedro Alves <palves@redhat.com>
15070 -Werror=strict-aliasing
15072 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15075 2012-04-04 Pedro Alves <palves@redhat.com>
15077 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15078 (sparc_store_gregset_from_stack, sparc_store_gregset)
15079 (sparc_breakpoint_at): Fix formatting.
15081 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15083 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15085 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15086 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15087 * config.in: Regenerate.
15088 * configure: Likewise.
15090 2012-03-29 Pedro Alves <palves@redhat.com>
15092 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15093 Correct ptrace arguments.
15095 2012-03-28 Pedro Alves <palves@redhat.com>
15097 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15098 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15099 (IA64_FR1_REGNUM): New defines.
15100 (ia64_fetch_register): New.
15101 (the_low_target): Install it.
15102 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15104 * linux-low.c (linux_fetch_registers): Try the
15105 the_low_target.fetch_register hook first.
15107 * linux-arm-low.c (the_low_target): Adjust.
15108 * linux-bfin-low.c (the_low_target): Adjust.
15109 * linux-cris-low.c (the_low_target): Adjust.
15110 * linux-crisv32-low.c (the_low_target): Adjust.
15111 * linux-m32r-low.c (the_low_target): Adjust.
15112 * linux-m68k-low.c (the_low_target): Adjust.
15113 * linux-mips-low.c (the_low_target): Adjust.
15114 * linux-ppc-low.c (the_low_target): Adjust.
15115 * linux-s390-low.c (the_low_target): Adjust.
15116 * linux-sh-low.c (the_low_target): Adjust.
15117 * linux-sparc-low.c (the_low_target): Adjust.
15118 * linux-tic6x-low.c (the_low_target): Adjust.
15119 * linux-x86-low.c (the_low_target): Adjust.
15120 * linux-xtensa-low.c (the_low_target): Adjust.
15122 2012-03-26 Pedro Alves <palves@redhat.com>
15124 * server.c (handle_qxfer_libraries): Don't bail early if
15125 the_target->qxfer_libraries_svr4 is not NULL.
15127 2012-03-26 Pedro Alves <palves@redhat.com>
15129 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15131 2012-03-23 Pedro Alves <palves@redhat.com>
15133 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15134 "library-list-svr4" element's start tag when the the DSO list is
15137 2012-03-23 Pedro Alves <palves@redhat.com>
15139 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15140 a variable whose type size is the same as the inferior's pointer
15143 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15145 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15147 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15148 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15149 * linux-low.h: Include <signal.h>.
15150 (struct siginfo): Remove forward declaration.
15151 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15154 2012-03-21 Mike Frysinger <vapier@gentoo.org>
15156 * .gitignore: Ignore more files.
15158 2012-03-19 Pedro Alves <palves@redhat.com>
15159 Jan Kratochvil <jan.kratochvil@redhat.com>
15161 * server.c (cont_thread, general_thread): Add describing comments.
15162 (start_inferior): Clear `cont_thread'.
15163 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15166 2012-03-15 Yao Qi <yao@codesourcery.com>
15168 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15170 (cmd_qtdp): ... here.
15172 2012-03-15 Yao Qi <yao@codesourcery.com>
15174 * tracepoint.c (struct tracepoint_action_ops): New.
15175 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15176 (m_tracepoint_action_download): New.
15177 (r_tracepoint_action_download): New.
15178 (x_tracepoint_action_download): New.
15179 (l_tracepoint_action_download): New.
15180 (add_tracepoint_action): Install `action->ops' according type.
15181 (download_tracepoint_1): Move code `download' function pointer
15182 of various tracepoint_action_ops.
15184 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15186 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15187 linux_ptrace_attach_warnings.
15189 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15191 * Makefile.in (linux-ptrace.o): New.
15192 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15193 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15194 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15195 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15196 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15198 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15200 2012-03-08 Yao Qi <yao@codesourcery.com>
15201 Pedro Alves <palves@redhat.com>
15203 Fix PR server/13392.
15204 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15205 offset of JMP insn.
15206 * tracepoint.c (remove_tracepoint): New.
15207 (cmd_qtdp): Call remove_tracepoint when failed to install.
15209 2012-03-07 Pedro Alves <palves@redhat.com>
15211 * linux-low.c (get_detach_signal): New.
15212 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15213 Pass on pending signals to PTRACE_DETACH. Check the result of the
15215 * server.c (program_signals, program_signals_p): New.
15216 (handle_general_set): Handle QProgramSignals.
15217 * server.h (program_signals, program_signals_p): Declare.
15219 2012-03-05 Pedro Alves <palves@redhat.com>
15220 Jan Kratochvil <jan.kratochvil@redhat.com>
15222 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15225 2012-03-03 Yao Qi <yao@codesourcery.com>
15227 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15228 agent_look_up_symbols.
15230 2012-03-03 Yao Qi <yao@codesourcery.com>
15232 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15233 (linux-x86-low.o): Likewise.
15234 * server.h: Remove in_process_agent_loaded.
15235 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15239 2012-03-03 Yao Qi <yao@codesourcery.com>
15241 * tracepoint.c (gdb_agent_capability): New global.
15242 (in_process_agent_loaded_ust): Renamed to
15243 `in_process_agent_supports_ust'.
15245 (in_process_agent_supports_ust): Call agent_capability_check.
15246 (clear_installed_tracepoints): Assert that agent supports
15249 2012-03-03 Yao Qi <yao@codesourcery.com>
15251 * linux-low.c (linux_supports_agent): New.
15252 (linux_target_ops): Initialize field `supports_agent' with
15253 linux_supports_agent.
15254 * target.h (struct target_ops) <supports_agent>: New.
15255 (target_supports_agent): New macro.
15256 * server.c (handle_general_set): Handle packet 'QAgent'.
15257 (handle_query): Send `QAgent+'.
15258 * Makefile.in (server.o): Depends on agent.h.
15260 2012-03-03 Yao Qi <yao@codesourcery.com>
15262 * Makefile.in (OBS): Add agent.o.
15263 Add new rule for agent.o.
15264 Track dependence of tracepoint.c on agent.h.
15265 * tracepoint.c (run_inferior_command_1):
15266 (run_inferior_command): Call agent_run_command.
15267 (gdb_ust_connect_sync_socket): Deleted. Move it to
15269 (resume_thread, stop_thread): Likewise.
15270 (gdb_ust_socket_init): Renamed to ...
15271 (gdb_agent_socket_init): ... New.
15272 (gdb_ust_thread): Renamed to ...
15273 (gdb_agent_helper_thread): ... New.
15274 (gdb_ust_init): Move some code to ...
15275 (gdb_agent_init): ... here. New.
15276 [HAVE_UST]: Call gdb_ust_init.
15277 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15278 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15279 * config.in, configure: Regenerated.
15281 2012-03-02 Pedro Alves <palves@redhat.com>
15283 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15284 * linux-low.c (struct simple_pid_list): New.
15285 (stopped_pids): New a struct simple_pid_list pointer.
15286 (add_to_pid_list, pull_pid_from_list): New.
15287 (handle_extended_wait): Don't assume the first signal new children
15288 report is SIGSTOP. Adjust call to pull_pid_from_list.
15289 (linux_wait_for_lwp): Adjust.
15291 2012-03-02 Yao Qi <yao@codesourcery.com>
15293 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15296 2012-03-02 Yao Qi <yao@codesourcery.com>
15298 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15299 `stop_pc' and `tpoint'. Update caller.
15301 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15303 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15304 * linux-low.c (use_linux_regsets): New macro.
15305 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15306 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15307 (linux_register_in_regsets): New function.
15308 (usr_fetch_inferior_registers): Skip registers covered by
15310 (usr_store_inferior_registers): Likewise.
15311 (usr_fetch_inferior_registers): New macro.
15312 (usr_store_inferior_registers): Likewise.
15313 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15314 (linux_store_registers): Likewise.
15315 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15317 (init_registers_mips64_dsp_linux): Likewise.
15318 (init_registers_mips_linux): New macro.
15319 (init_registers_mips_dsp_linux): Likewise.
15320 (mips_dsp_num_regs): Likewise.
15321 (DSP_BASE, DSP_CONTROL): New fallback macros.
15322 (mips_base_regs): New macro.
15323 (mips_regmap): Use it. Fix the size.
15324 (mips_dsp_regmap): New variable.
15325 (mips_dsp_regset_bitmap): Likewise.
15326 (mips_arch_setup): New function.
15327 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15329 (mips_cannot_store_register): Likewise.
15330 (the_low_target): Update .arch_setup, .num_regs and .regmap
15331 initializers. Add .regset_bitmap initializer.
15332 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15334 * linux-bfin-low.c (the_low_target): Likewise.
15335 * linux-cris-low.c (the_low_target): Likewise.
15336 * linux-crisv32-low.c (the_low_target): Likewise.
15337 * linux-ia64-low.c (the_low_target): Likewise.
15338 * linux-m32r-low.c (the_low_target): Likewise.
15339 * linux-m68k-low.c (the_low_target): Likewise.
15340 * linux-ppc-low.c (the_low_target): Likewise.
15341 * linux-s390-low.c (the_low_target): Likewise.
15342 * linux-sh-low.c (the_low_target): Likewise.
15343 * linux-sparc-low.c (the_low_target): Likewise.
15344 * linux-tic6x-low.c (the_low_target): Likewise.
15345 * linux-x86-low.c (the_low_target): Likewise.
15346 * linux-xtensa-low.c (the_low_target): Likewise.
15347 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15348 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15349 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15351 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15352 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15354 2012-02-29 Yao Qi <yao@codesourcery.com>
15355 Pedro Alves <palves@redhat.com>
15357 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15358 `step_over_finished' is true.
15360 2012-02-27 Pedro Alves <palves@redhat.com>
15362 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15363 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15365 2012-02-27 Pedro Alves <palves@redhat.com>
15368 * linux-low.c (pid_is_stopped): New.
15369 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15371 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15373 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15376 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15378 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15380 2012-02-24 Luis Machado <lgustavo@codesourcery>
15382 * server.c (handle_query): Advertise support for target-side
15383 breakpoint condition evaluation.
15384 (process_point_options): New function.
15385 (process_serial_event): When inserting a breakpoint, check for
15386 a target-side condition that should be evaluated.
15388 * mem-break.c: Include regcache.h and ax.h.
15389 (point_cond_list_t): New data structure.
15390 (breakpoint) <cond_list>: New field.
15391 (find_gdb_breakpoint_at): Make non-static.
15392 (delete_gdb_breakpoint_at): Clear any target-side
15394 (clear_gdb_breakpoint_conditions): New function.
15395 (add_condition_to_breakpoint): Likewise.
15396 (add_breakpoint_condition): Likewise.
15397 (gdb_condition_true_at_breakpoint): Likewise.
15398 (gdb_breakpoint_here): Return result directly instead
15399 of going through a local variable.
15401 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15402 (clear_gdb_breakpoint_conditions): Likewise.
15403 (add_breakpoint_condition): Likewise.
15404 (gdb_condition_true_at_breakpoint): Likewise.
15406 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15407 (need_step_over_p): Take target-side breakpoint condition into
15410 2012-02-24 Luis Machado <lgustavo@codesourcery>
15412 * server.h: Include tracepoint.h.
15413 (agent_mem_read, agent_get_trace_state_variable_value,
15414 agent_set_trace_state_variable_value,
15415 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15416 get_set_tsv_func_addr): New prototypes.
15418 * ax.h: New include file.
15419 * ax.c: New source file.
15421 * tracepoint.c: Include ax.h.
15422 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15423 agent_expr, eval_result_type): Move to ax.h.
15424 (parse_agent_expr): Rename to ...
15425 (gdb_parse_agent_expr): ... this, make it non-static and move
15427 (unparse_agent_expr) Rename to ...
15428 (gdb_unparse_agent_expr): ... this, make it non-static and move
15430 (eval_agent_expr): Rename to ...
15431 (eval_tracepoint_agent_expr): ... this.
15432 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15433 forward declarations.
15434 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15435 (agent_get_trace_state_variable_value): New function.
15436 (agent_set_trace_state_variable_value): New function.
15437 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15438 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15439 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15440 (condition_true_at_tracepoint): Likewise.
15441 (parse_agent_expr): Rename to ...
15442 (gdb_parse_agent_expr): ... this and move to ax.c.
15443 (unparse_agent_expr): Rename to ...
15444 (gdb_unparse_agent_expr): ... this and move to ax.c.
15445 (gdb_agent_op_name): Move to ax.c.
15446 (eval_agent_expr): Rename to ...
15447 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15449 (eval_tracepoint_agent_expr): New function.
15450 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15452 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15454 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15455 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15456 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15457 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15458 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15459 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15460 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15461 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15462 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15463 (compile_bytecodes): Remove forward declaration.
15464 (is_goto_target): Move to ax.c.
15465 (compile_bytecodes): Move to ax.c and call
15466 agent_get_trace_state_variable_value (...) and
15467 agent_set_trace_state_variable_value (...).
15469 * Makefile.in: Update ax.c and IPA dependencies.
15471 2012-02-24 Pedro Alves <palves@redhat.com>
15473 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15474 (cmd_bigqtbuffer_circular): ... this. Only handle
15475 'QTBuffer:circular:'.
15476 (handle_tracepoint_general_set): Adjust.
15478 2012-02-16 Yao Qi <yao@codesourcery.com>
15480 * inferiors.c: Move code to ...
15481 * dll.c: .... here. New.
15482 * server.h: Declare clear_dlls.
15483 * Makefile.in (SFILES): Add dll.c.
15487 2012-02-11 Yao Qi <yao@codesourcery.com>
15489 * server.c: (handle_monitor_command): Add a new parameter
15491 (handle_query): Update caller.
15493 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15495 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15496 * configure, config.in: Regenerate.
15497 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15500 2012-02-02 Pedro Alves <palves@redhat.com>
15502 Try SIGKILL first, then PTRACE_KILL.
15503 * linux-low.c (linux_kill_one_lwp): New.
15504 (linux_kill_one_lwp): Rename to ...
15505 (kill_one_lwp_callback): ... this. Use the new
15506 linux_kill_one_lwp.
15508 2012-02-02 Pedro Alves <palves@redhat.com>
15510 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15513 2012-01-27 Pedro Alves <palves@redhat.com>
15515 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15516 (elf_64_file_p): Make static.
15517 (linux_pid_exe_is_elf_64_file): New.
15518 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15519 Delete declarations.
15520 (linux_pid_exe_is_elf_64_file): Declare.
15521 * linux-x86-low.c (x86_arch_setup): Use
15522 linux_pid_exe_is_elf_64_file.
15524 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15526 * linux-low.c (linux_wait_for_event_1): Rename to ...
15527 (linux_wait_for_event): ... here and merge it with former
15528 linux_wait_for_event - new variable wait_ptid, use it.
15529 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15531 2012-01-23 Pedro Alves <palves@redhat.com>
15533 * server.c (main): Avoid yet another case of infinite loop while
15534 detaching/killing after a longjmp.
15536 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15539 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15541 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15543 * hostio.c (handle_readlink): New function.
15544 (handle_vFile): Call it to handle "vFile:readlink" packets.
15546 2012-01-20 Pedro Alves <palves@redhat.com>
15547 Ulrich Weigand <ulrich.weigand@linaro.org>
15549 * server.c (handle_v_requests): Only support vAttach and vRun to
15550 start multiple processes when in extended protocol mode.
15552 2012-01-17 Pedro Alves <palves@redhat.com>
15554 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15555 memalign plus mprotect to allocate the scratch buffer.
15557 2012-01-13 Pedro Alves <palves@redhat.com>
15559 * server.c (attach_inferior): Clear `cont_thread'.
15561 2012-01-13 Pedro Alves <palves@redhat.com>
15563 * server.c (main): Avoid infinite loop while detaching/killing
15566 2012-01-09 Doug Evans <dje@google.com>
15568 * server.c (start_inferior): Set last_ptid in --wrapper case.
15570 2012-01-06 Yao Qi <yao@codesourcery.com>
15572 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15574 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15576 2012-01-04 Yao Qi <yao@codesourcery.com>
15578 * tracepoint.c (cmd_qtdp): Print debug message
15579 for static tracepoint.
15581 2012-01-04 Yao Qi <yao@codesourcery.com>
15583 * tracepoint.c (trace_vdebug): Differentiate debug message
15584 between gdbserver and IPA.
15586 2012-01-03 Yao Qi <yao@codesourcery.com>
15588 * tracepoint.c (tracepoint_was_hit): Don't collect for
15591 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15593 * terminal.h: Reformat copyright header.
15595 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15597 * server.c (gdbserver_version): Update copyright year.
15598 * gdbreplay.c (gdbreplay_version): Likewise.
15600 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15602 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15605 2011-12-18 Hui Zhu <teawater@gmail.com>
15606 * linux-low.c (linux_create_inferior): Save return value to ret.
15608 2011-12-18 Hui Zhu <teawater@gmail.com>
15610 * linux-low.c (linux_create_inferior): Save return value to ret.
15612 2011-12-16 Doug Evans <dje@google.com>
15614 * linux-low.c (linux_create_inferior): If stdio connection,
15615 redirect stdin from /dev/null, stdout to stderr.
15616 * remote-utils.c (remote_is_stdio): New static global.
15617 (remote_connection_is_stdio): New function.
15618 (remote_prepare): Handle stdio connection.
15619 (remote_open): Ditto.
15620 (remote_close): Don't close stdin for stdio connections.
15621 (read_prim,write_prim): New functions. Replace all calls to
15622 read/write to these.
15623 * server.c (main): Watch for "-" argument. Move call to
15624 remote_prepare before start_inferior.
15625 * server.h (STDIO_CONNECTION_NAME): New macro.
15626 (remote_connection_is_stdio): Declare.
15628 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15629 in debugging output.
15631 2011-12-15 Yao Qi <yao@codesourcery.com>
15633 * tracepoint.c: Include sys/syscall.h.
15634 (gdb_ust_thread): Remove preprocessor conditional.
15636 2011-12-14 Pedro Alves <pedro@codesourcery.com>
15638 * linux-low.c (linux_detach_one_lwp): Call
15639 the_low_target.prepare_to_resume before detaching.
15641 2011-12-14 Yao Qi <yao@codesourcery.com>
15643 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15646 2011-12-14 Yao Qi <yao@codesourcery.com>
15648 * i386-low.c (i386_low_stopped_data_address): Initialize local
15649 variable `control'.
15651 2011-12-13 Pedro Alves <pedro@codesourcery.com>
15655 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15656 DR_CONTROL unless necessary. Extend comments.
15657 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15658 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15660 2011-12-13 Yao Qi <yao@codesourcery.com>
15662 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15664 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15666 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15668 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15669 Print new debug message for such case.
15671 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15673 Fix overlapping memcpy.
15674 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15675 the read_inferior_memory transfer.
15676 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15677 write_inferior_memory transfer.
15678 (set_fast_tracepoint_jump): New variable buf. Use it for the
15679 read_inferior_memory and write_inferior_memory transfers.
15680 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15681 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15682 Use it for the write_inferior_memory transfer.
15683 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15686 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15688 * linux-low.c (fetch_register, store_register): Make code
15689 consistent, fix formatting.
15691 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15693 * linux-low.c (usr_store_inferior_registers): Factor out code
15694 to handle individual registers into...
15695 (store_register): ... this new function.
15697 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15699 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15700 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15701 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15702 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15703 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15704 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15705 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15706 (srv_xmlfiles): Add new XML files.
15708 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15710 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15711 (init_registers_s390_linux32v1): Add prototype.
15712 (init_registers_s390_linux32v2): Likewise.
15713 (init_registers_s390_linux64v1): Likewise.
15714 (init_registers_s390_linux64v2): Likewise.
15715 (init_registers_s390x_linux64v1): Likewise.
15716 (init_registers_s390x_linux64v2): Likewise.
15717 (s390_num_regs): Increment to 52.
15718 (s390_regmap): Add orig_r2 register.
15719 (s390_num_regs_3264): Increment to 68.
15720 (s390_regmap_3264): Add orig_r2 register.
15721 (s390_collect_ptrace_register): Handle orig_r2 register.
15722 (s390_supply_ptrace_register): Likewise.
15723 (s390_fill_last_break): New function.
15724 (s390_store_last_break): Likewise.
15725 (s390_fill_system_call): New function.
15726 (s390_store_system_call): Likewise.
15727 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15729 (s390_check_regset): New function.
15730 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15731 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15732 Update target_regsets for available register sets.
15734 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15735 Jan Kratochvil <jan.kratochvil@redhat.com>
15737 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15738 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15740 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15741 * linux-low.h (struct process_info_private): New member r_debug.
15742 * server.c (handle_qxfer_libraries): Call
15743 the_target->qxfer_libraries_svr4.
15744 (handle_qxfer_libraries_svr4): New function.
15745 (qxfer_packets): New entry "libraries-svr4".
15746 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15747 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15748 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15749 PACKET_qXfer_libraries_svr4.
15751 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15753 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15754 PSW address/mask between 8-byte and 16-byte formats.
15755 (s390_supply_ptrace_register): Likewise.
15756 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15757 basic addressing mode bit.
15759 2011-11-24 Stan Shebs <stan@codesourcery.com>
15761 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15763 2011-11-17 Stan Shebs <stan@codesourcery.com>
15765 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15766 (tracing_start_time): New global.
15767 (tracing_stop_time): New global.
15768 (tracing_user_name): New global.
15769 (tracing_notes): New global.
15770 (tracing_stop_note): New global.
15771 (cmd_qtstart): Set traceframe_usage, start_time.
15772 (stop_tracing): Set stop_time.
15773 (cmd_qtstatus): Report additional status.
15774 (cmd_qtp): New function.
15775 (handle_tracepoint_query): Call it.
15776 (cmd_qtnotes): New function.
15777 (handle_tracepoint_general_set): Call it.
15778 (get_timestamp): Rename from tsv_get_timestamp.
15780 2011-11-14 Stan Shebs <stan@codesourcery.com>
15781 Kwok Cheung Yeung <kcy@codesourcery.com>
15783 * linux-x86-low.c (small_jump_insn): New.
15784 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15785 trampoline and error message, build a trampoline and issue a small
15786 jump instruction to it.
15787 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15788 trampoline and error message.
15789 (x86_get_min_fast_tracepoint_insn_len): New.
15790 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15791 * linux-low.h (struct linux_target_ops): Add arguments to
15792 install_fast_tracepoint_jump_pad operation, add new operation.
15793 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15795 (linux_get_min_fast_tracepoint_insn_len): New function.
15796 (linux_target_op): Add new operation.
15797 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15798 (gdb_trampoline_buffer_end): Ditto.
15799 (gdb_trampoline_buffer_error): Ditto.
15800 (struct ipa_sym_addresses): Add fields for new IPA variables.
15801 (symbol_list): Add entries for new IPA variables.
15802 (struct tracepoint): Add fields to hold the address range of the
15803 trampoline used by the tracepoint.
15804 (trampoline_buffer_head): New static variable.
15805 (trampoline_buffer_tail): Ditto.
15806 (claim_trampoline_space): New function.
15807 (have_fast_tracepoint_trampoline_buffer): New function.
15808 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15810 (install_fast_tracepoint): Ditto, also add error buffer argument.
15811 (cmd_qtminftpilen): New function.
15812 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15813 (fast_tracepoint_from_trampoline_address): New function.
15814 (fast_tracepoint_collecting): Handle trampoline as part of jump
15816 (set_trampoline_buffer_space): New function.
15817 (initialize_tracepoint): Initialize new IPA variables.
15818 * target.h (struct target_ops): Add arguments to
15819 install_fast_tracepoint_jump_pad operation, add new
15820 get_min_fast_tracepoint_insn_len operation.
15821 (target_get_min_fast_tracepoint_insn_len): New.
15822 (install_fast_tracepoint_jump_pad): Add arguments.
15823 * server.h (IPA_BUFSIZ): Define.
15824 * linux-i386-ipa.c: Include extra header files.
15825 (initialize_fast_tracepoint_trampoline_buffer): New function.
15826 (initialize_low_tracepoint): Call it.
15827 * server.h (set_trampoline_buffer_space): Declare.
15828 (claim_trampoline_space): Ditto.
15829 (have_fast_tracepoint_trampoline_buffer): Ditto.
15831 2011-11-14 Yao Qi <yao@codesourcery.com>
15833 * server.c (handle_query): Handle InstallInTrace for qSupported.
15834 * tracepoint.c (add_tracepoint): Sort list.
15835 (install_tracepoint, download_tracepoint): New.
15836 (cmd_qtdp): Call them to install and download tracepoints.
15837 (sort_tracepoints): Removed.
15838 (cmd_qtstart): Update.
15840 2011-11-14 Yao Qi <yao@codesourcery.com>
15842 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15843 * mem-break.h: Declare.
15844 * tracepoint.c (cmd_qtstart): Move some code to ...
15845 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15847 (download_tracepoints): Move some code to ...
15848 (download_tracepoint_1): ... here. New.
15850 2011-11-08 Yao Qi <yao@codesourcery.com>
15852 * remote-utils.c (relocate_instruction): A comment fix.
15854 2011-11-07 Joel Brobecker <brobecker@adacore.com>
15856 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15857 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15858 dr_status_mirror and dr_control_mirror from debug_reg_state.
15859 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15860 (i386_initial_stuff): Remove use of deleted globals.
15861 (i386_get_thread_context, i386_set_thread_context,
15862 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15863 from debug_reg_state.
15865 2011-11-05 Yao Qi <yao@codesourcery.com>
15867 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15868 address as TPOINT's.
15870 2011-11-02 Stan Shebs <stan@codesourcery.com>
15872 * tracepoint.c (agent_mem_read_string): New function.
15873 (eval_agent_expr): Call it for tracenz.
15874 * server.c (handle_query): Report support for tracenz.
15876 2011-11-02 Yao Qi <yao@codesourcery.com>
15878 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15880 2011-11-02 Yao Qi <yao@codesourcery.com>
15882 * target.h: Fix a typo in comment.
15884 2011-10-31 Pedro Alves <pedro@codesourcery.com>
15886 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15887 clobber the breakpoints' shadows with fast tracepoint jumps.
15888 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15889 * target.c (write_inferior_memory): Also pass MYADDR down to
15892 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15894 * configure.ac: Check support for personality routine.
15895 * configure: Regenerate.
15896 * config.in: Likewise.
15897 * linux-low.c: Include <sys/personality.h>.
15898 Define ADDR_NO_RANDOMIZE if necessary.
15899 (linux_create_inferior): Disable address space randomization when
15900 forking inferior, if requested.
15901 (linux_supports_disable_randomization): New function.
15902 (linux_target_ops): Install it.
15903 * server.h (disable_randomization): Declare.
15904 * server.c (disable_randomization): New global variable.
15905 (handle_general_set): Handle QDisableRandomization.
15906 (handle_query): Likewise for qSupported.
15907 (main): Support --disable-randomization and --no-disable-randomization
15908 command line arguments.
15909 * target.h (struct target_ops): Add supports_disable_randomization.
15910 (target_supports_disable_randomization): New macro.
15912 2011-09-29 Mike Frysinger <vapier@gentoo.org>
15914 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15916 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15917 [!PT_GETDSBT] (target_loadmap): New definition.
15918 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15919 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15920 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15921 and PT_GETDSBT to LINUX_LOADMAP.
15922 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15923 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15925 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15927 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15928 (arm_linux_hwbp_cap): New static variable.
15929 (arm_linux_get_hwbp_cap): Replace by ...
15930 (arm_linux_init_hwbp_cap): ... this new function.
15931 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15932 (arm_linux_get_hw_watchpoint_count): Likewise.
15933 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15934 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15935 (arm_prepare_to_resume): Use perror_with_name instead of error.
15937 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15939 * linux-arm-low.c: Include <signal.h>.
15940 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15941 (struct arm_linux_hwbp_cap): New data type.
15942 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15943 (struct arm_linux_hw_breakpoint): New data type.
15944 (MAX_BPTS, MAX_WPTS): Define.
15945 (struct arch_process_info, struct arch_lwp_info): New data types.
15946 (arm_linux_get_hwbp_cap): New function.
15947 (arm_linux_get_hw_breakpoint_count): Likewise.
15948 (arm_linux_get_hw_watchpoint_count): Likewise.
15949 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15950 (arm_hwbp_control_initialize): Likewise.
15951 (arm_hwbp_control_is_enabled): Likewise.
15952 (arm_hwbp_control_is_initialized): Likewise.
15953 (arm_hwbp_control_disable): Likewise.
15954 (arm_linux_hw_breakpoint_equal): Likewise.
15955 (arm_linux_hw_point_initialize): Likewise.
15956 (struct update_registers_data): New data structure.
15957 (update_registers_callback: New function.
15958 (arm_insert_point): Likewise.
15959 (arm_remove_point): Likewise.
15960 (arm_stopped_by_watchpoint): Likewise.
15961 (arm_stopped_data_address): Likewise.
15962 (arm_new_process): Likewise.
15963 (arm_new_thread): Likewise.
15964 (arm_prepare_to_resume): Likewise.
15965 (the_low_target): Register arm_insert_point, arm_remove_point,
15966 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15967 arm_new_thread, and arm_prepare_to_resume.
15969 2011-09-15 Stan Shebs <stan@codesourcery.com>
15971 * server.h (struct emit_ops): Add compare-goto fields.
15972 * tracepoint.c (gdb_agent_op_sizes): New table.
15973 (emit_eq_goto): New function.
15974 (emit_ne_goto): New function.
15975 (emit_lt_goto): New function.
15976 (emit_le_goto): New function.
15977 (emit_gt_goto): New function.
15978 (emit_ge_goto): New function.
15979 (is_goto_target): New function.
15980 (compile_bytecodes): Recognize special cases of compare-goto
15981 combinations and call specialized emitters for them.
15982 * linux-x86-low.c (amd64_emit_eq_goto): New function.
15983 (amd64_emit_ne_goto): New function.
15984 (amd64_emit_lt_goto): New function.
15985 (amd64_emit_le_goto): New function.
15986 (amd64_emit_gt_goto): New function.
15987 (amd64_emit_ge_goto): New function.
15988 (amd64_emit_ops): Add the new functions.
15989 (i386_emit_eq_goto): New function.
15990 (i386_emit_ne_goto): New function.
15991 (i386_emit_lt_goto): New function.
15992 (i386_emit_le_goto): New function.
15993 (i386_emit_gt_goto): New function.
15994 (i386_emit_ge_goto): New function.
15995 (i386_emit_ops): Add the new functions.
15997 2011-09-08 Stan Shebs <stan@codesourcery.com>
15999 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16000 (i386_emit_epilogue): Restore %ebx.
16002 2011-08-31 Jie Zhang <jzhang918@gmail.com>
16004 * server.c (step_thread): Remove definition.
16005 (process_serial_event): Don't handle Hs.
16006 * server.h (step_thread): Remove declaration.
16007 * target.c (set_desired_inferior): Remove use of step_thread.
16009 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16011 * linux-low.c: Include linux-procfs.h.
16012 (linux_attach_lwp_1): Update comments.
16013 (linux_attach): Scan for existing threads when attaching to a
16014 process that is the tgid.
16015 * Makefile.in: Update dependencies.
16017 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16019 * configure.srv: Add linux-procfs.o dependencies.
16021 2011-08-14 Yao Qi <yao@codesourcery.com>
16023 * target.h (struct target_ops): Fix indent.
16024 * win32-low.c (win32_target_ops): Fix comment.
16026 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
16027 Yao Qi <yao@codesourcery.com>
16029 * Makefile.in (clean): Remove tic6x-*.c files.
16030 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16031 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16032 (tic6x-c64xp-linux.c): Likewise.
16033 * configure.srv: Add support for tic6x-*-uclinux.
16034 * linux-tic6x-low.c: New.
16035 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16037 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
16038 Yao Qi <yao@codesourcery.com>
16040 * target.h (struct target_ops): Add read_loadmap.
16041 * linux-low.c (struct target_loadseg): New type.
16042 (struct target_loadmap): New type.
16043 (linux_read_loadmap): New function.
16044 (linux_target_ops): Add linux_read_loadmap.
16045 * server.c (handle_query): Support qXfer:fdpic:read packet.
16046 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16049 2011-08-05 Eli Zaretskii <eliz@gnu.org>
16051 * win32-low.c: Include <stdint.h>.
16053 2011-07-22 Pedro Alves <pedro@codesourcery.com>
16055 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16056 to the inferior here.
16057 (i386_remove_aligned_watchpoint): Ditto.
16058 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16059 fit part of the watchpoint in the debug registers.
16060 (i386_update_inferior_debug_regs): New.
16061 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16062 registers, and only update the inferior on success.
16063 (i386_low_remove_watchpoint): Ditto.
16065 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16067 * linux-low.c (compare_ints, unique, list_threads, show_process,
16068 linux_core_of_thread): Delete.
16069 (linux_target_ops): Change linux_core_of_thread to
16070 linux_common_core_of_thread.
16071 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16072 * utils.c (malloc_failure): Change type of argument.
16073 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16074 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16075 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16076 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16077 (IPA_OBJS): Add common-utils-ipa.o.
16078 (ptid_h, linux_osdata_h): New macros.
16079 (server_h): Add common/common-utils.h, common/xml-utils.h,
16080 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16082 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16083 ptid.o, buffer.o): New rules.
16084 (linux-low.o): Add common/linux-osdata.h as a dependency.
16085 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16086 * configure.ac: Add AC_HEADER_DIRENT check.
16087 * config.in: Regenerate.
16088 * configure: Regenerate.
16089 * remote-utils.c (xml_escape_text): Delete.
16090 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16091 buffer_xml_printf): Move to common/buffer.c.
16092 * server.c (main): Remove call to initialize_inferiors.
16093 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16094 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16095 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16096 internal_error, gdb_assert, gdb_assert_fail): Delete.
16097 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16098 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16100 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16101 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16102 initialize_inferiors): Delete.
16104 2011-07-20 Pedro Alves <pedro@codesourcery.com>
16106 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16109 2011-05-31 Pedro Alves <pedro@codesourcery.com>
16111 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16113 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16115 2011-05-26 Yao Qi <yao@codesourcery.com>
16117 * Makefile.in (thread-db.o): Track dependence to
16118 common/gdb_thread_db.h.
16119 * thread-db.c: include gdb_thread_db.h from right place.
16121 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16123 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16124 __FILE__ and __LINE__ to internal_error.
16126 2011-05-13 Doug Evans <dje@google.com>
16128 * thread-db.c (try_thread_db_load_from_sdir): New function.
16129 (try_thread_db_load_from_dir): New function.
16130 (thread_db_load_search): Handle $sdir, ignore $pdir.
16131 Remove trying of system directories if search of
16132 libthread-db-search-path fails, that is now done via $sdir.
16134 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16136 * server.c (handle_query): Add EnableDisableTracepoints to the list
16137 of supported features.
16138 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
16140 (cmd_qtenable_disable): New.
16141 (cmd_qtstart): Install tracepoints even if disabled.
16142 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16143 receiving a QTEnable or QTDisable packet.
16144 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16145 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16147 (gdb_probe): Skip data collection if static tracepoint is disabled.
16149 2011-05-10 Doug Evans <dje@google.com>
16151 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16153 2011-05-04 Doug Evans <dje@google.com>
16155 * linux-low.c (linux_join): Skip process lookup.
16156 * spu-low.c (spu_join): Ditto.
16157 * server.c (join_inferiors_callback): Delete.
16158 (process_serial_event): For 'D' packet (detach) call join_inferior
16161 2011-05-04 Joseph Myers <joseph@codesourcery.com>
16163 * README: Don't mention xscale*-*-linux*.
16164 * configure.srv (xscale*-*-linux*): Don't handle target.
16166 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16168 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16170 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16171 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16172 (i386_emit_void_call_2): Likewise.
16174 2011-04-26 Yao Qi <yao@codesourcery.com>
16176 * linux-low.c: Move common macros to linux-ptrace.h.
16177 Include linux-ptrace.h.
16178 * Makefile.in (linux_ptrace_h): New.
16179 (linux-low.o): Depends on linux-ptrace.h.
16181 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16183 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16184 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16185 (remote_prepare): New function with most of the TCP code from ...
16186 (remote_open): ... here. Detect PORT here unconditionally. Move also
16187 setting transport_is_reliable.
16188 * server.c (run_once): New variable.
16189 (gdbserver_usage): Document it.
16190 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16191 the first run if RUN_ONCE.
16192 * server.h (run_once, remote_prepare): New declarations.
16194 2011-04-19 Tom Tromey <tromey@redhat.com>
16196 * win32-low.c (handle_load_dll): Remove duplicate "the".
16198 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16200 Remove support for old Cygwin 1.5 versions.
16201 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16202 function to avoid warning.
16203 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16206 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16208 * gdbserver/server.h (Macro _): Define it if not available.
16210 2011-03-14 Michael Snyder <msnyder@vmware.com>
16212 * hostio.c (handle_close): Remove unnecessary null test.
16214 2011-03-10 Joel Brobecker <brobecker@adacore.com>
16216 * Makefile.in (maintainer-clean realclean distclean): Remove
16217 "make ... subdir_do" command.
16219 2011-03-10 Michael Snyder <msnyder@vmware.com>
16221 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16223 * server.c (handle_v_run): Free alloced buffer on early return.
16225 2011-03-09 Yao Qi <yao@codesourcery.com>
16228 2011-03-04 Yao Qi <yao@codesourcery.com>
16230 * Makefile.in: Remove GNU make feature --directory.
16232 2011-03-05 Yao Qi <yao@codesourcery.com>
16234 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16235 (subdir_do): New make target. Copied from gdb/Makefile.
16236 (maintainer-clean, realclean, distclean, clean): Call corresponding
16237 make targets in common/Makefile.
16239 2011-02-11 Yao Qi <yao@codesourcery.com>
16241 * configure.ac: Call AC_PROG_RANLIB.
16242 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16243 * configure: Regenerate.
16245 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16247 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16249 2011-03-06 Yao Qi <yao@codesourcery.com>
16251 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16253 2011-03-05 Yao Qi <yao@codesourcery.com>
16255 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16256 (subdir_do): New make target. Copied from gdb/Makefile.
16257 (maintainer-clean, realclean, distclean, clean): Call corresponding
16258 make targets in common/Makefile.
16260 2011-03-04 Yao Qi <yao@codesourcery.com>
16262 * Makefile.in: Remove GNU make feature --directory.
16264 2011-03-04 Michael Snyder <msnyder@vmware.com>
16266 * server.c (queue_stop_reply): Call xmalloc not malloc.
16268 2011-03-02 Michael Snyder <msnyder@vmware.com>
16270 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16272 2011-02-28 Michael Snyder <msnyder@vmware.com>
16274 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16275 (cmd_qtframe): Ditto.
16276 (cmd_qtbuffer): Ditto.
16277 (cmd_bigqtbuffer): Ditto.
16279 * utils.c (decimal2str): Initialize 'width' to nine, then
16280 don't mess with it.
16282 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16284 * hostio.c (require_data): Free *data, not data.
16286 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16288 * hostio.c (require_data): Use free, not xfree.
16290 2011-02-27 Michael Snyder <msnyder@vmware.com>
16292 * server.c (handle_query): Discard unused value.
16294 * hostio.c (require_data): Free malloc memory before returning
16297 2011-02-26 Michael Snyder <msnyder@vmware.com>
16299 * linux-low.c (list_threads): Call closedir for dirent.
16301 2011-02-27 Michael Snyder <msnyder@vmware.com>
16303 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16304 a case statement falls through.
16306 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16308 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16311 2011-02-26 Michael Snyder <msnyder@vmware.com>
16313 * utils.c (decimal2str): Eliminate dead code and dead param.
16314 (pulongest): Drop dead param from call to decimal2str.
16317 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16319 Revert the following patch (not approved yet):
16320 2011-02-21 Hui Zhu <teawater@gmail.com>
16321 * tracepoint.c (tp_printf): New function.
16322 (eval_agent_expr): Handle gdb_agent_op_printf.
16324 2011-02-21 Hui Zhu <teawater@gmail.com>
16326 * tracepoint.c (tp_printf): New function.
16327 (eval_agent_expr): Handle gdb_agent_op_printf.
16329 2011-02-18 Tom Tromey <tromey@redhat.com>
16331 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16332 (tracepoint.o): Likewise.
16333 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16334 (gdb_agent_op_names): Likewise.
16336 2011-02-18 Tom Tromey <tromey@redhat.com>
16338 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16339 gdb_agent_op_rot>: New constants.
16340 (gdb_agent_op_names): Add pick and roll.
16341 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16344 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16346 * aclocal.m4: Regenerated with aclocal-1.11.1.
16348 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16350 * server.c (handle_qxfer_traceframe_info): New.
16351 (qxfer_packets): Register "traceframe-info".
16352 (handle_query): Report support for qXfer:traceframe-info:read+.
16353 * tracepoint.c (match_blocktype): New.
16354 (traceframe_find_block_type): Rename to ...
16355 (traceframe_walk_blocks): ... this. Add callback filter argument,
16357 (traceframe_find_block_type): New, reimplemented on top of
16358 traceframe_walk_blocks.
16359 (build_traceframe_info_xml): New.
16360 (traceframe_read_info): New.
16361 * server.h (traceframe_read_info): Declare.
16363 2011-02-11 Yao Qi <yao@codesourcery.com>
16365 * configure.ac: Call AC_PROG_RANLIB.
16366 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16367 * configure: Regenerate.
16369 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16371 * server.c (gdb_read_memory): Change return semantics to allow
16373 (handle_search_memory_1): Adjust.
16374 (process_serial_event) <'m' packet>: Handle partial transfers.
16375 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16377 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16379 * regcache.c (init_register_cache): Initialize
16380 regcache->register_status.
16381 (free_register_cache): Release regcache->register_status.
16382 (regcache_cpy): Copy register_status.
16383 (registers_to_string): Print 'x's for unavailable registers.
16384 (supply_register): Mark the register's status valid or
16385 unavailable, depending on whether a buffer was passed in or not.
16386 (supply_register_zeroed): New.
16387 (supply_regblock): Mark the registers' status valid or
16388 unavailable, depending on whether a buffer was passed in or not.
16389 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16390 (struct regcache): New `register_status' field.
16391 (supply_register_zeroed): Declare.
16392 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16393 supply_register_zeroed, rather than passing a NULL buffer to
16395 * tracepoint.c (fetch_traceframe_registers): Update comment.
16397 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16399 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16402 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16404 * server.h (decode_xfer_write): Change prototype.
16405 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16406 and don't extract the annex here.
16407 * server.c (decode_xfer_read): Remove `annex' parameter,
16408 and don't extract the annex here.
16409 (decode_xfer): New.
16410 (struct qxfer): New.
16411 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16412 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16413 (handle_qxfer_statictrace): New functions, abstracted out from
16414 handle_query, and made to use the struct qxfer interface.
16415 (handle_threads_qxfer_proper): Rename to ...
16416 (handle_qxfer_threads_proper): ... this.
16417 (handle_threads_qxfer): Rename to ...
16418 (handle_qxfer_threads): ... this. Adjust.
16419 (qxfer_packets): New array.
16420 (handle_qxfer): New function.
16421 (handle_query): Use handle_qxfer.
16423 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16425 * gdbreplay.c: Shorten lines of >= 80 columns.
16426 * linux-low.c: Ditto.
16427 * linux-ppc-low.c: Ditto.
16428 * linux-s390-low.c: Ditto.
16429 * linux-sparc-low.c: Ditto.
16430 * linux-x86-low.c: Ditto.
16431 * linux-xtensa-low.c: Ditto.
16432 * mem-break.c: Ditto.
16433 * nto-low.c: Ditto.
16434 * regcache.h: Ditto.
16435 * remote-utils.c: Ditto.
16438 * thread-db.c: Ditto.
16439 * tracepoint.c: Ditto.
16441 * win32-low.h: Ditto.
16443 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16445 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16448 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16450 * server.c (gdbserver_version): Update copyright year in version
16452 * gdbreplay.c (gdbreplay_version): Ditto.
16454 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16456 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16457 * linux-bfin-low.c: New file.
16458 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16459 PT_DATA_ADDR for BFIN targets.
16460 * Makefile.in (SFILES): Add linux-bfin-low.c.
16461 (clean): Remove reg-bfin.c.
16462 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16463 * README: Mention supported Blackfin targets.
16465 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16467 * .gitignore: New file.
16469 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16471 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16473 2010-10-22 Jie Zhang <jie@codesourcery.com>
16475 * Makefile.in: Add FLAGS_TO_PASS variable.
16476 (install): Remove dependency of install-only and recursively
16477 invoke make for install-only.
16479 2010-10-04 Doug Evans <dje@google.com>
16481 * Makefile.in (uninstall): Use $(DESTDIR).
16483 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16487 * linux-x86-low.c (compat_siginfo_from_siginfo)
16488 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16489 si_code is < 0. Check for si_code == SI_TIMER before checking for
16492 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16494 * lynx-i386-low.c: New file.
16495 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16497 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16499 * lynx-low.c (ptrace_request_to_str): Remove handling for
16500 request values that have been removed in LynxOS 5.x.
16502 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16504 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16507 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16509 * configure.ac: Add --enable-inprocess-agent option.
16510 * configure: Rebuilt.
16512 2010-09-06 Yao Qi <yao@codesourcery.com>
16514 * linux-low.c (linux_kill): Remove unused variable.
16515 (linux_stabilize_threads): Likewise.
16516 * server.c (start_inferior): Likewise.
16517 (queue_stop_reply_callback): Likewise.
16518 * tracepoint.c (do_action_at_tracepoint): Likewise.
16520 2010-09-06 Yao Qi <yao@codesourcery.com>
16522 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16525 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16527 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16529 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16531 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16534 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16536 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16537 gdbserver/lynx-ppc-low.c: New files.
16538 * Makefile.in (lynx_low_h): New variable.
16539 (lynx-low.o, lynx-ppc-low.o): New rules.
16540 * configure.ac: On LynxOS, link with -lnetinet.
16541 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16542 * configure: regenerate.
16544 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16546 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16547 * configure.ac: Add check for vasprintf and vsnprintf.
16548 * configure, config.in: Regenerate.
16549 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16551 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16553 * gdbreplay.c: Move include of alloca.h up, next to include of
16555 * server.h: Add include of malloc.h.
16556 * mem-break.c: Remove include of malloc.h.
16557 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16559 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16561 * Makefile.in (memmem.o): Build with -Wno-error.
16563 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16565 * utils.c (xsnprintf): Make non-static.
16566 * server.h: Add xsnprintf declaration.
16567 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16568 replace calls to snprintf by calls to xsnprintf throughout.
16570 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16572 * configure.ac: Add configure check for alloca.
16573 * configure, config.in: Regenerate.
16574 * server.h: Include alloca.h if it exists.
16575 * gdbreplay.c: Include alloca.h if it exists.
16577 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16579 * linux-low.c (__SIGRTMIN): Define if not already defined.
16580 (linux_create_inferior): Check for __ANDROID__ rather than
16582 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16583 are already deferred.
16584 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16585 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16586 stopped and already has a pending signal to report.
16587 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16588 a pending signal to report or is moving out of a jump pad.
16589 (linux_init_signals): Check for __ANDROID__ rather than
16592 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16594 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16595 debug_threads check. Avoid a linear search when not doing debug
16598 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16600 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16601 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16602 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16603 (process_event): Change local fd's type to gdb_fildes_t.
16604 (create_file_handler): Adjust prototype.
16605 (delete_file_handler): Adjust prototype.
16606 (handle_file_event): Adjust prototype. Use pfildes.
16607 (create_file_event): Adjsut prototype.
16608 * remote-utils.c (remote_desc, listen_desc): Change type to
16610 * server.h: New gdb_fildes_t typedef.
16611 [USE_WIN32API]: Include winsock2.h.
16612 (delete_file_handler, add_file_handler): Adjust prototypes.
16613 (pfildes): Declare.
16614 * utils.c (pfildes): New.
16616 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16618 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16619 * configure: Regenerate.
16621 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16623 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16624 (linux_done_accessing_memory): ... this.
16625 (linux_target_ops): Adjust.
16626 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16627 * nto-low.c (nto_target_ops): Adjust comment.
16628 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16629 * spu-low.c (spu_target_ops): Adjust comment.
16630 * target.h (target_ops): Rename unprepare_to_access_memory field
16631 to done_accessing_memory.
16632 (unprepare_to_access_memory): Rename to ...
16633 (done_accessing_memory): ... this.
16635 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16637 * linux-low.c (linux_prepare_to_access_memory): New.
16638 (linux_unprepare_to_access_memory): New.
16639 (linux_target_ops): Install them.
16640 * server.c (read_memory): Rename to ...
16641 (gdb_read_memory): ... this. Use
16642 prepare_to_access_memory/prepare_to_access_memory.
16643 (write_memory): Rename to ...
16644 (gdb_write_memory): ... this. Use
16645 prepare_to_access_memory/prepare_to_access_memory.
16646 (handle_search_memory_1): Adjust.
16647 (process_serial_event): Adjust.
16648 * target.h (struct target_ops): New fields
16649 prepare_to_access_memory and unprepare_to_access_memory.
16650 (prepare_to_access_memory, unprepare_to_access_memory): New.
16651 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16652 prepare_to_access_memory/prepare_to_access_memory.
16653 * nto-low.c (nto_target_ops): Adjust.
16654 * spu-low.c (spu_target_ops): Adjust.
16655 * win32-low.c (win32_target_ops): Adjust.
16657 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16659 * Makefile.in (WARN_CFLAGS): Get it from configure.
16660 (WERROR_CFLAGS): New.
16661 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16662 * configure.ac: Introduce --enable-werror, which adds -Werror to
16663 the compiler command line. Enabled by default. Disable with
16664 --disable-werror. Add -Wdeclaration-after-statement
16665 Wpointer-arith and -Wformat-nonliteral to warning flags.
16666 * configure: Regenerate.
16668 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16670 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16672 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16674 * gdbreplay.c (remote_error): New.
16676 (expect): Use gdbchar. Check for error reading from GDB.
16677 Clarify sync error output.
16678 (play): Check for errors writing to GDB.
16679 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16680 * remote-utils.c (getpkt): Check for errors writing to the remote
16683 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16685 * linux-low.c (linux_wait_1): Move non-debugging code out of
16686 `debug_threads' control.
16688 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16690 * linux-low.c (linux_wait_1): Don't set last_status here.
16691 * server.c (push_event, queue_stop_reply_callback): Assert we're
16692 not pushing a TARGET_WAITKIND_IGNORE event.
16693 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16694 (myresume, handle_target_event): Set the thread's last_resume_kind
16695 and last_status from the target returned status.
16697 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16701 * linux-x86-low.c (update_debug_registers_callback): New.
16702 (i386_dr_low_set_addr): Use it.
16703 (i386_dr_low_get_addr): New.
16704 (i386_dr_low_set_control): Use update_debug_registers_callback.
16705 (i386_dr_low_get_control): New.
16706 (i386_dr_low_get_status): Adjust.
16707 * linux-low.c (linux_stop_lwp): New.
16708 * linux-low.h (linux_stop_lwp): Declare.
16710 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16711 argument instead of a i386_debug_reg_state.
16712 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16713 a i386_debug_reg_state.
16714 (i386_insert_aligned_watchpoint): Adjust.
16715 (i386_remove_aligned_watchpoint): Adjust.
16716 (i386_low_stopped_data_address): Read the debug registers from the
16717 inferior instead of from the mirrors.
16718 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16719 (i386_dr_low_get_addr): Declare.
16720 (i386_dr_low_get_control): Declare.
16721 (i386_dr_low_get_status): Change prototype.
16723 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16724 (i386_dr_low_get_addr): New.
16725 (i386_dr_low_get_control): New.
16726 (i386_dr_low_get_status): Adjust prototype. Return
16728 (i386_initial_stuff): Clear dr_status_mirror and
16730 (i386_get_thread_context): Adjust.
16731 (i386_set_thread_context): Adjust.
16732 (i386_thread_added): Adjust.
16734 2010-08-24 Pedro Alves <pedro@codesourcery.com>
16736 * linux-low.h (linux_thread_area): Delete declaration.
16738 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16740 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16741 after its termination.
16743 2010-08-09 Pedro Alves <pedro@codesourcery.com>
16745 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16746 (gdb_wants_all_stopped): Delete.
16747 (linux_wait_1): Don't call them.
16748 * server.c (handle_v_cont): Tag all threads as want-stopped.
16749 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16750 stopped as "client-wants-stopped".
16752 2010-07-31 Pedro Alves <pedro@codesourcery.com>
16754 * Makefile.in (signals_h): New.
16755 (server_h): Depend on it.
16756 (server.o): Don't depend on $(signals_def).
16757 (signals.o): Depend on $(signals_def).
16759 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16761 * Makefile.in (signals_def): New.
16762 (server_h): Append include/gdb/signals.h and signals_def.
16763 (server.o): Append signals_def.
16765 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16767 * server.c (handle_target_event): Use target_signal_to_host for
16768 resume_info.sig initialization.
16769 * target.h (struct thread_resume) <sig>: New comment.
16771 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16773 * server.c (handle_query): strcpy() the returned string from paddress()
16774 instead of sprintf().
16775 * utils.c (paddress): Return phex_nz().
16777 2010-07-07 Joel Brobecker <brobecker@adacore.com>
16779 * server.c (handle_v_cont): Call mourn_inferior if process
16781 (myresume): Likewise.
16783 2010-07-01 Pedro Alves <pedro@codesourcery.com>
16785 Static tracepoints, and integration with UST.
16787 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16788 * mem-break.c (uninsert_all_breakpoints)
16789 (reinsert_all_breakpoints): New.
16790 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16791 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16792 (gdb_agent_ust_loaded, helper_thread_id)
16793 (gdb_agent_helper_thread_id): New macros.
16794 (struct ipa_sym_addresses): Add addr_ust_loaded,
16795 addr_helper_thread_id, addr_cmd_buf.
16796 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16797 (in_process_agent_loaded_ust): New.
16798 (write_e_ust_not_loaded): New.
16799 (maybe_write_ipa_ust_not_loaded): New.
16800 (struct collect_static_trace_data_action): New.
16801 (enum tracepoint_type) <static_tracepoint>: New.
16802 (struct tracepoint) <handle>: Mention static tracepoints.
16803 (struct static_tracepoint_ctx): New.
16804 (CMD_BUF_SIZE): New.
16805 (add_tracepoint_action): Handle static tracepoint actions.
16806 (unprobe_marker_at): New.
16807 (clear_installed_tracepoints): Handle static tracepoints.
16808 (cmd_qtdp): Handle static tracepoints.
16809 (probe_marker_at): New.
16810 (cmd_qtstart): Handle static tracepoints.
16811 (response_tracepoint): Handle static tracepoints.
16812 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16813 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16814 (get_context_regcache): Handle static tracepoints.
16815 (do_action_at_tracepoint): Handle static tracepoint actions.
16816 (traceframe_find_block_type): Handle static trace data blocks.
16817 (traceframe_read_sdata): New.
16818 (download_tracepoints): Download static tracepoint actions.
16819 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16820 (GDB_PROBE_NAME): New.
16822 (GET_UST_SYM): New.
16825 (ust_marker_to_static_tracepoint): New.
16827 (collect_ust_data_at_tracepoint): New.
16828 (gdb_ust_probe): New.
16829 (UNIX_PATH_MAX, SOCK_DIR): New.
16830 (gdb_ust_connect_sync_socket): New.
16831 (resume_thread, stop_thread): New.
16832 (run_inferior_command): New.
16833 (init_named_socket): New.
16834 (gdb_ust_socket_init): New.
16835 (cstr_to_hexstr): New.
16837 (first_marker, next_marker): New.
16838 (response_ust_marker): New.
16839 (cmd_qtfstm, cmd_qtsstm): New.
16840 (unprobe_marker_at, probe_marker_at): New.
16841 (cmd_qtstmat, gdb_ust_thread): New.
16842 (gdb_ust_init): New.
16843 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16844 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16845 (ST_REGENTRY): New.
16846 (x86_64_st_collect_regmap): New.
16847 (X86_64_NUM_ST_COLLECT_GREGS): New.
16848 (AMD64_RIP_REGNUM): New.
16849 (supply_static_tracepoint_registers): New.
16850 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16851 (ST_REGENTRY): New.
16852 (i386_st_collect_regmap): New.
16853 (i386_NUM_ST_COLLECT_GREGS): New.
16854 (supply_static_tracepoint_registers): New.
16855 * server.c (handle_query): Handle qXfer:statictrace:read.
16856 <qSupported>: Report support for StaticTracepoints, and
16857 qXfer:statictrace:read features.
16858 * server.h (traceframe_read_sdata)
16859 (supply_static_tracepoint_registers): Declare.
16860 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16861 (unpack_varlen_hex): Include in IPA build.
16862 * Makefile.in (ustlibs, ustinc): New.
16863 (IPA_OBJS): Add remote-utils-ipa.o.
16864 ($(IPA_LIB)): Link -ldl and -lpthread.
16866 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16867 * config.in, configure: Regenerate.
16869 2010-06-20 Ian Lance Taylor <iant@google.com>
16870 Pedro Alves <pedro@codesourcery.com>
16872 * linux-x86-low.c (always_true): Delete.
16873 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16874 trying to fool the compiler with always_true.
16876 2010-06-20 Pedro Alves <pedro@codesourcery.com>
16878 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16879 conditions in gdbserver.
16881 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16883 * spu-low.c (spu_read_memory): Wrap around local store limit.
16884 (spu_write_memory): Likewise.
16886 2010-06-15 Pedro Alves <pedro@codesourcery.com>
16888 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16889 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16891 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16893 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16894 uses with LONGEST uses.
16896 2010-06-14 Stan Shebs <stan@codesourcery.com>
16897 Pedro Alves <pedro@codesourcery.com>
16901 * linux-x86-low.c: Include limits.h.
16903 (always_true): New.
16906 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16907 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16908 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16909 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16910 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16911 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16912 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16913 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16914 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16915 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16916 (amd64_emit_void_call_2): New.
16917 (amd64_emit_ops): New.
16918 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16919 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16920 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16921 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16922 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16923 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16924 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16925 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16926 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16927 (i386_emit_stack_adjust, i386_emit_int_call_1)
16928 (i386_emit_void_call_2): New.
16929 (i386_emit_ops): New.
16930 (x86_emit_ops): New.
16931 (the_low_target): Install x86_emit_ops.
16932 * server.h (struct emit_ops): New.
16933 (get_raw_reg_func_addr): Declare.
16934 (current_insn_ptr, emit_error): Declare.
16935 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16936 (set_trace_state_variable_value): New defines.
16937 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16938 addr_get_trace_state_variable_value and
16939 addr_set_trace_state_variable_value.
16940 (symbol_list): New fields for get_raw_reg,
16941 get_trace_state_variable_value and set_trace_state_variable_value.
16942 (condfn): New typedef.
16943 (struct tracepoint): New field `compiled_cond'.
16944 (do_action_at_tracepoint): Clear compiled_cond.
16945 (get_trace_state_variable_value, set_trace_state_variable_value):
16947 (condition_true_at_tracepoint): If there's a compiled condition,
16949 (current_insn_ptr, emit_error): New globals.
16950 (struct bytecode_address): New.
16951 (get_raw_reg_func_addr): New.
16952 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16953 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16954 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16955 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16956 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16957 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16958 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16959 (compile_tracepoint_condition, compile_bytecodes): New.
16960 * target.h (emit_ops): Forward declare.
16961 (struct target_ops): New field emit_ops.
16962 (target_emit_ops): New.
16963 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16964 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16965 * linux-low.c (linux_emit_ops): New.
16966 (linux_target_ops): Install it.
16967 * linux-low.h (struct linux_target_ops): New field emit_ops.
16969 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16971 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16972 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16974 2010-06-01 Pedro Alves <pedro@codesourcery.com>
16975 Stan Shebs <stan@codesourcery.com>
16977 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
16978 (all): Depend on $(extra_libraries).
16979 (install-only): Install the IPA.
16980 (IPA_OBJS, IPA_LIB): New.
16981 (clean): Remove the IPA lib.
16982 (IPAGENT_CFLAGS): New.
16983 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
16984 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
16985 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
16986 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
16987 * configure.ac: Check for atomic builtins support in the compiler.
16988 (IPA_DEPFILES, extra_libraries): Define.
16989 * configure.srv (ipa_obj): Add description.
16990 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
16991 (i[34567]86-*-linux*): Set ipa_obj.
16992 (x86_64-*-linux*): Set ipa_obj.
16993 * linux-low.c (stabilizing_threads): New.
16994 (supports_fast_tracepoints): New.
16995 (linux_detach): Stabilize threads before detaching.
16996 (handle_tracepoints): Handle internal tracing breakpoints. Assert
16997 the lwp is either not stabilizing, or is moving out of a jump pad.
16998 (linux_fast_tracepoint_collecting): New.
16999 (maybe_move_out_of_jump_pad): New.
17000 (enqueue_one_deferred_signal): New.
17001 (dequeue_one_deferred_signal): New.
17002 (linux_wait_for_event_1): If moving out of a jump pad, defer
17003 pending signals to later.
17004 (linux_stabilize_threads): New.
17005 (linux_wait_1): Check if threads need moving out of jump pads, and
17007 (stuck_in_jump_pad_callback): New.
17008 (move_out_of_jump_pad_callback): New.
17009 (lwp_running): New.
17010 (linux_resume_one_lwp): Handle moving out of jump pads.
17011 (linux_set_resume_request): Dequeue deferred signals.
17012 (need_step_over_p): Also step over fast tracepoint jumps.
17013 (start_step_over): Also uninsert fast tracepoint jumps.
17014 (finish_step_over): Also reinsert fast tracepoint jumps.
17015 (linux_install_fast_tracepoint_jump): New.
17016 (linux_target_ops): Install linux_stabilize_threads and
17017 linux_install_fast_tracepoint_jump_pad.
17018 * linux-low.h (linux_target_ops) <get_thread_area,
17019 install_fast_tracepoint_jump_pad>: New fields.
17020 (struct lwp_info) <collecting_fast_tracepoint,
17021 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17022 (linux_get_thread_area): Declare.
17023 * linux-x86-low.c (jump_insn): New.
17024 (x86_get_thread_area): New.
17025 (append_insns): New.
17026 (push_opcode): New.
17027 (amd64_install_fast_tracepoint_jump_pad): New.
17028 (i386_install_fast_tracepoint_jump_pad): New.
17029 (x86_install_fast_tracepoint_jump_pad): New.
17030 (the_low_target): Install x86_get_thread_area and
17031 x86_install_fast_tracepoint_jump_pad.
17032 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17033 (struct fast_tracepoint_jump): New.
17034 (fast_tracepoint_jump_insn): New.
17035 (fast_tracepoint_jump_shadow): New.
17036 (find_fast_tracepoint_jump_at): New.
17037 (fast_tracepoint_jump_here): New.
17038 (delete_fast_tracepoint_jump): New.
17039 (set_fast_tracepoint_jump): New.
17040 (uninsert_fast_tracepoint_jumps_at): New.
17041 (reinsert_fast_tracepoint_jumps_at): New.
17042 (set_breakpoint_at): Use write_inferior_memory.
17043 (uninsert_raw_breakpoint): Use write_inferior_memory.
17044 (check_mem_read): Mask out fast tracepoint jumps.
17045 (check_mem_write): Mask out fast tracepoint jumps.
17046 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17047 (set_fast_tracepoint_jump): Declare.
17048 (delete_fast_tracepoint_jump)
17049 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17050 (reinsert_fast_tracepoint_jumps_at): Declare.
17051 * regcache.c: Don't compile many functions when building the
17052 in-process agent library.
17053 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17054 the register buffer in the heap.
17055 (free_register_cache): If the register buffer isn't owned by the
17056 regcache, don't free it.
17057 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17058 pre-existing register caches.
17059 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17061 (convert_ascii_to_int): : Constify `from' parameter type.
17062 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17063 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17064 the needed buffer in-place.
17065 (relocate_instruction): New.
17066 * server.c (handle_query) <qSymbols>: If the target supports
17067 tracepoints, give it a chance of looking up symbols. Report
17068 support for fast tracepoints.
17069 (handle_status): Stabilize threads.
17070 (process_serial_event): Adjust.
17071 * server.h (struct fast_tracepoint_jump): Forward declare.
17072 (struct process_info) <fast_tracepoint_jumps>: New field.
17073 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17074 (decode_X_packet, decode_M_packet): Adjust.
17075 (relocate_instruction): Declare.
17076 (in_process_agent_loaded): Declare.
17077 (tracepoint_look_up_symbols): Declare.
17078 (struct fast_tpoint_collect_status): Declare.
17079 (fast_tracepoint_collecting): Declare.
17080 (force_unlock_trace_buffer): Declare.
17081 (handle_tracepoint_bkpts): Declare.
17082 (initialize_low_tracepoint)
17083 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17084 * target.h (struct target_ops) <stabilize_threads,
17085 install_fast_tracepoint_jump_pad>: New fields.
17086 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17087 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17088 [HAVE_STDINT_H]: Include stdint.h.
17089 (trace_debug_1): Rename to ...
17090 (trace_vdebug): ... this.
17091 (trace_debug): Rename to ...
17092 (trace_debug_1): ... this. Add `level' parameter.
17093 (trace_debug): New.
17094 (ATTR_USED, ATTR_NOINLINE): New.
17095 (IP_AGENT_EXPORT): New.
17096 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17097 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17098 (about_to_request_buffer_space, trace_buffer_is_full)
17099 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17100 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17101 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17102 (traceframe_write_count, traceframes_created)
17103 (trace_state_variables)
17104 New renaming defines.
17105 (struct ipa_sym_addresses): New.
17106 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17107 (symbol_list): New.
17108 (ipa_sym_addrs): New.
17109 (all_tracepoint_symbols_looked_up): New.
17110 (in_process_agent_loaded): New.
17111 (write_e_ipa_not_loaded): New.
17112 (maybe_write_ipa_not_loaded): New.
17113 (tracepoint_look_up_symbols): New.
17114 (debug_threads) [IN_PROCESS_AGENT]: New.
17115 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17116 (UNKNOWN_SIDE_EFFECTS): New.
17117 (stop_tracing): New.
17118 (flush_trace_buffer): New.
17119 (stop_tracing_bkpt): New.
17120 (flush_trace_buffer_bkpt): New.
17121 (read_inferior_integer): New.
17122 (read_inferior_uinteger): New.
17123 (read_inferior_data_pointer): New.
17124 (write_inferior_data_pointer): New.
17125 (write_inferior_integer): New.
17126 (write_inferior_uinteger): New.
17127 (struct collect_static_trace_data_action): Delete.
17128 (enum tracepoint_type): New.
17129 (struct tracepoint) <type>: New field `type'.
17130 <actions_str, step_actions, step_actions_str>: Only include in
17132 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17133 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17134 (tracepoints): Use IP_AGENT_EXPORT.
17135 (last_tracepoint): Don't include in the IPA.
17136 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17137 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17138 (alloced_trace_state_variables): New.
17139 (trace_state_variables): Use IP_AGENT_EXPORT.
17140 (traceframe_t): Delete unused variable.
17141 (circular_trace_buffer): Don't include in the IPA.
17142 (trace_buffer_start): Delete.
17143 (struct trace_buffer_control): New.
17144 (trace_buffer_free): Delete.
17145 (struct ipa_trace_buffer_control): New.
17146 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17147 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17149 (trace_buffer_ctrl): New.
17150 (TRACE_BUFFER_CTRL_CURR): New.
17151 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17152 Reimplement as macros.
17153 (trace_buffer_wrap): Delete.
17154 (traceframe_write_count, traceframe_read_count)
17155 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17156 (struct tracepoint_hit_ctx) <type>: New field.
17157 (struct fast_tracepoint_ctx): New.
17158 (memory_barrier): New.
17160 (record_tracepoint_error): Update atomically in the IPA.
17161 (clear_inferior_trace_buffer): New.
17162 (about_to_request_buffer_space): New.
17163 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17164 updating the same buffer.
17165 (add_tracepoint): Default the tracepoint's type to trap
17166 tracepoint, and orig_size to -1.
17167 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17168 internal variables.
17169 (create_trace_state_variable): New parameter `gdb'. Handle it.
17170 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17171 (cmd_qtdp): Handle fast tracepoints.
17172 (cmd_qtdv): Adjust.
17173 (max_jump_pad_size): New.
17174 (gdb_jump_pad_head): New.
17175 (get_jump_space_head): New.
17176 (claim_jump_space): New.
17177 (sort_tracepoints): New.
17178 (MAX_JUMP_SIZE): New.
17179 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17181 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17182 support. Upload fast traceframes, and delete internal IPA
17184 (stop_tracing_handler): New.
17185 (flush_trace_buffer_handler): New.
17186 (cmd_qtstop): Upload fast tracepoints.
17187 (response_tracepoint): Handle fast tracepoints.
17188 (tracepoint_finished_step): Upload fast traceframes. Set the
17189 tracepoint hit context's tracepoint type.
17190 (handle_tracepoint_bkpts): New.
17191 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17192 type. Add comment about fast tracepoints.
17193 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17194 non-existing action_str field.
17195 (get_context_regcache): Handle fast tracepoints.
17196 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17198 (fast_tracepoint_from_jump_pad_address): New.
17199 (fast_tracepoint_from_ipa_tpoint_address): New.
17200 (collecting_t): New.
17201 (force_unlock_trace_buffer): New.
17202 (fast_tracepoint_collecting): New.
17204 (gdb_collect): New.
17205 (write_inferior_data_ptr): New.
17206 (target_tp_heap): New.
17207 (target_malloc): New.
17208 (download_agent_expr): New.
17210 (download_tracepoints): New.
17211 (download_trace_state_variables): New.
17212 (upload_fast_traceframes): New.
17213 (IPA_FIRST_TRACEFRAME): New.
17214 (IPA_NEXT_TRACEFRAME_1): New.
17215 (IPA_NEXT_TRACEFRAME): New.
17216 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17217 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17218 (gdb_jump_pad_buffer_end): New.
17219 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17220 (initialize_tracepoint): Adjust.
17221 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17222 buffer. Initialize the low module.
17223 * utils.c (PREFIX, TOOLNAME): New.
17224 (malloc_failure): Use PREFIX.
17225 (error): In the IPA, an error causes an exit.
17226 (fatal, warning): Use PREFIX.
17227 (internal_error): Use TOOLNAME.
17228 (NUMCELLS): Increase to 10.
17229 * configure, config.in: Regenerate.
17231 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17233 * server.c (handle_query) <qSupported>: Do two passes over the
17234 qSupported string to avoid nesting strtok.
17236 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17238 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17240 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17241 -Wl,--dynamic-list.
17242 * configure: Regenerate.
17243 * proc-service.list: New.
17245 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17247 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17250 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17252 * gdbreplay.c (remote_open): Check error return from socket() call by
17253 its equality to -1 not by it being negative.
17254 * remote-utils.c (remote_open): Likewise.
17256 2010-05-23 Pedro Alves <pedro@codesourcery.com>
17258 * config.h: Regenerate.
17260 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17262 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17263 doesn't provide PTRACE_GET_THREAD_AREA.
17265 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17267 * linux-m68k-low.c: Include <asm/ptrace.h>
17268 (ps_get_thread_area): Implement.
17270 2010-05-03 Doug Evans <dje@google.com>
17272 * event-loop.c (struct callback_event): New struct.
17273 (callback_list): New global.
17274 (append_callback_event, delete_callback_event): New functions.
17275 (process_callback): New function.
17276 (start_event_loop): Call it.
17277 * remote-utils.c (NOT_SCHEDULED): Define.
17278 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17279 moved out of readchar.
17280 (readchar): Rewrite. Call reschedule before returning.
17281 (reset_readchar): New function.
17282 (remote_close): Call it.
17283 (process_remaining, reschedule): New functions.
17284 * server.h (callback_handler_func): New typedef.
17285 (append_callback_event, delete_callback_event): Declare.
17287 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17289 * proc-service.c (ps_pglobal_lookup): Use
17290 thread_db_look_up_one_symbol.
17291 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17292 parameter. Use it instead of all_symbols_looked_up.
17293 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17295 (all_symbols_looked_up): Don't declare.
17296 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17297 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17299 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17300 Set all_symbols_looked_up here.
17301 (thread_db_look_up_one_symbol): New.
17302 (thread_db_get_tls_address): Adjust.
17303 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17304 thread_db object on the heap, and tentatively set it in the
17306 (thread_db_init): Don't set all_symbols_looked_up here.
17307 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17309 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17311 * linux-low.c (linux_kill, linux_detach): Adjust.
17312 (status_pending_p_callback): Remove redundant statement. Check
17313 for !TARGET_WAITIKIND_IGNORE, instead of
17314 TARGET_WAITKIND_STOPPED.
17315 (handle_tracepoints): Make sure LWP is locked. Adjust.
17316 (linux_wait_for_event_1): Adjust.
17317 (linux_cancel_breakpoints): New.
17318 (unsuspend_one_lwp): New.
17319 (unsuspend_all_lwps): New.
17320 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17321 (send_sigstop_callback): Change return type to int, add new
17322 `except' parameter and handle it.
17323 (suspend_and_send_sigstop_callback): New.
17324 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17325 pass them down. If SUSPEND, also increment the lwp's suspend
17327 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17328 (need_step_over_p): Don't consider suspended LWPs.
17329 (start_step_over): Adjust.
17330 (proceed_one_lwp): Change return type to int, add new `except'
17331 parameter and handle it.
17332 (unsuspend_and_proceed_one_lwp): New.
17333 (proceed_all_lwps): Use find_inferior instead of
17335 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17336 also decrement the suspend count of LWPs. Pass `except' down,
17337 instead of hacking its suspend count.
17338 (linux_pause_all): Add `freeze' parameter. Adjust.
17339 (linux_unpause_all): New.
17340 (linux_target_ops): Install linux_unpause_all.
17341 * server.c (handle_status): Adjust.
17342 * target.h (struct target_ops): New fields `unpause_all' and
17343 `cancel_breakpoints'. Add new parameter to `pause_all'.
17344 (pause_all): Add new `freeze' parameter.
17345 (unpause_all): New.
17346 (cancel_breakpoints): New.
17347 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17348 cancel breakpoints.
17349 (cmd_qtstart): Pause threads.
17350 (stop_tracing): Pause threads, and cancel breakpoints.
17351 * win32-low.c (win32_target_ops): Adjust.
17353 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17355 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17356 the inferior right away from here...
17357 (linux_wait_1): ... to here, and adjust to check the thread's
17358 last_resume_kind instead of the lwp's step or stop_expected flags.
17360 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17362 * README: Use consistent `GDB' and `GDBserver' spellings.
17364 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17366 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17367 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17368 (linux_detach_one_lwp): Assume the lwp is stopped.
17369 (any_thread_of): Delete.
17370 (linux_detach): Stop all lwps here. Don't blindly delete all
17372 (delete_lwp_callback): New.
17373 (linux_mourn): Delete all lwps of the process that is gone.
17374 (linux_wait_1): Don't delete the last lwp of the process here.
17375 * mem-break.h (mark_breakpoints_out): Declare.
17376 * mem-break.c (mark_breakpoints_out): New.
17377 (free_all_breakpoints): Use it.
17378 * server.c (handle_target_event): If the process is gone, mark
17380 * thread-db.c (struct thread_db) <create_bp>: New field.
17381 (thread_db_enable_reporting): Fix prototype. Store a thread event
17382 breakpoint reference in the thread_db struct.
17383 (thread_db_load_search): Clear the thread_db object.
17384 (try_thread_db_load_1): Ditto.
17385 (switch_to_process): New.
17386 (disable_thread_event_reporting): Use it.
17387 (remove_thread_event_breakpoints): New.
17388 (thread_db_detach, thread_db_mourn): Use it.
17390 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17392 * linux-low.c (linux_enable_event_reporting): New.
17393 (linux_wait_for_event_1, handle_extended_wait): Use it.
17395 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17397 * linux-low.c (linux_kill_one_lwp, linux_kill)
17398 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17399 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17400 SIGSTOP even if the LWP is stopped.
17401 (send_sigstop_callback): New.
17402 (stop_all_lwps): Use send_sigstop_callback instead.
17403 (linux_resume_one_thread): Adjust.
17404 (proceed_one_lwp): Still proceed an LWP that the client has
17405 requested to stop, if we haven't reported it as stopped yet. Make
17406 sure that LWPs the client want stopped, have a pending SIGSTOP.
17408 2010-04-26 Doug Evans <dje@google.com>
17410 * server.c (handle_general_set): Make static.
17412 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17413 Print received char after testing for error/eof instead of before.
17414 (input_interrupt): Tweak comment.
17416 2010-04-23 Doug Evans <dje@google.com>
17418 * server.c (start_inferior): Print inferior argv if --debug.
17420 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17422 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17423 * nto-x86-low.c: Include server.h
17425 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17427 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17428 be consistent with other sources of this directory.
17429 (init_registers_amd64): Correct name of source file of this function
17432 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17434 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17435 64-bit executables.
17437 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17439 * win32-i386-low.c: Add 64-bit support.
17440 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17441 (init_registers_amd64): Declare.
17442 (mappings): Add 64-bit version of array.
17443 (init_windows_x86): New function.
17444 (the_low_target): Change init_arch field to init_windows_x86.
17446 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17448 * win32-low.c: Adapt to support also 64-bit architecture.
17449 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17450 (get_image_name): Use SIZE_T type for local variable `done'.
17451 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17452 (toolhelp_get_dll_name): Idem.
17453 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17454 Use uintptr_t typecast to avoid warning.
17455 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17456 (handle_exception): Use phex_nz to avoid warning.
17457 (win32_wait): Remove unused local variable `process'.
17459 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17461 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17464 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17466 * configure.ac: Use `ws2_32' library for srv_mingw.
17467 * configure: Regenerate.
17468 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17469 * remote-utils.c: Likewise.
17471 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17473 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17474 if __x86_64__ is defined.
17476 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17478 * configure: Regenerate.
17480 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17482 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17483 * target.h (target_ops): New get_tib_address field.
17484 * win32-low.h (win32_thread_info): Add thread_local_base field.
17485 * win32-low.c (child_add_thread): Add tlb argument.
17486 Set thread_local_base field to TLB.
17487 (get_child_debug_event): Adapt to child_add_thread change.
17488 (win32_get_tib_address): New function.
17489 (win32_target_ops): Set get_tib_address field to
17490 win32_get_tib_address.
17491 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17493 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17495 * linux-low.c (linux_mourn): Also remove the process.
17496 * server.c (handle_target_event): Don't remove the process here.
17497 * nto-low.c (nto_mourn): New.
17498 (nto_target_ops): Install it.
17499 * spu-low.c (spu_mourn): New.
17500 (spu_target_ops): Install it.
17501 * win32-low.c (win32_mourn): New.
17502 (win32_target_ops): Install it.
17504 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17506 * server.h (buffer_xml_printf): Remove redundant `;'.
17508 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17510 * regcache.c (set_register_cache): Invalidate regcaches before
17511 changing the register cache layout.
17512 (regcache_invalidate_one): Allow a NULL regcache.
17513 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17514 regcaches before changing the register cache layout or the target
17517 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17519 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17520 variable warning on Linux/x86-64.
17522 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17524 GDBserver disconnected tracing support.
17526 * linux-low.c (linux_remove_process): Delete.
17527 (add_lwp): Don't set last_resume_kind here.
17528 (linux_kill): Use `mourn'.
17529 (linux_detach): Use `thread_db_detach', and `mourn'.
17530 (linux_mourn): New.
17531 (linux_attach_lwp_1): Adjust comment.
17532 (linux_attach): last_resume_kind moved the thread_info; adjust.
17533 (status_pending_p_callback): Adjust.
17534 (linux_wait_for_event_1): Adjust.
17535 (count_events_callback, select_singlestep_lwp_callback)
17536 (select_event_lwp_callback, cancel_breakpoints_callback)
17537 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17538 (proceed_one_lwp): Adjust.
17539 (linux_async): Add debug output.
17540 (linux_thread_stopped): New.
17541 (linux_pause_all): New.
17542 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17544 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17545 (thread_db_free): Delete declaration.
17546 (thread_db_detach, thread_db_mourn): Declare.
17547 * thread-db.c (thread_db_init): Use thread_db_mourn.
17548 (thread_db_free): Delete, split in two.
17549 (disable_thread_event_reporting): New.
17550 (thread_db_detach): New.
17551 (thread_db_mourn): New.
17553 * server.h (struct thread_info) <last_resume_kind>: New field.
17554 <attached>: Add comment.
17555 <gdb_detached>: New field.
17556 (handler_func): Change return type to int.
17557 (handle_serial_event, handle_target_event): Ditto.
17558 (gdb_connected): Declare.
17560 (disconnected_tracing): Declare.
17561 (stop_tracing): Declare.
17563 * server.c (handle_query) <qSupported>: Report support for
17564 disconnected tracing.
17565 (queue_stop_reply_callback): Account for running threads.
17566 (gdb_wants_thread_stopped): New.
17567 (gdb_wants_all_threads_stopped): New.
17568 (gdb_reattached_process): New.
17569 (handle_status): Clear the `gdb_detached' flag of all processes.
17570 In all-stop, stop all threads.
17571 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17572 (process_serial_event): If the remote connection breaks, or if an
17573 exit was forced with "monitor exit", force an event loop exit.
17574 Handle disconnected tracing on detach.
17575 (handle_serial_event): Adjust.
17576 (handle_target_event): If GDB isn't connected, forward events back
17577 to the inferior, unless the last process exited, in which case,
17578 exit gdbserver. Adjust interface.
17580 * remote-utils.c (remote_open): Don't block in accept. Instead
17581 register an event loop source on the listen socket file
17582 descriptor. Refactor bits into ...
17583 (listen_desc): ... this new global.
17584 (gdb_connected): ... this new function.
17585 (enable_async_notification): ... this new function.
17586 (handle_accept_event): ... this new function.
17587 (remote_close): Clear remote_desc.
17589 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17591 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17593 (mourn_inferior): Define.
17594 (target_process_qsupported): Avoid the dangling else problem.
17595 (thread_stopped): Define.
17596 (pause_all): Define.
17597 (target_waitstatus_to_string): Declare.
17598 * target.c (target_waitstatus_to_string): New.
17600 * tracepoint.c (tracing): Make extern.
17601 (disconnected_tracing): New.
17602 (stop_tracing): Make extern. Handle tracing stops due to GDB
17604 (cmd_qtdisconnected): New.
17605 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17606 (handle_tracepoint_general_set): Handle QTDisconnected.
17608 * event-loop.c (event_handler_func): Change return type to int.
17609 (process_event): Bail out if the event handler wants the event
17611 (handle_file_event): Ditto.
17612 (start_event_loop): Bail out if the event handler wants the event
17615 * nto-low.c (nto_target_ops): Adjust.
17616 * spu-low.c (spu_wait): Don't remove the process here.
17617 (spu_target_ops): Adjust.
17618 * win32-low.c (win32_wait): Don't remove the process here.
17619 (win32_target_ops): Adjust.
17621 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17623 * regcache.c (realloc_register_cache): Invalidate inferior's
17624 regcache before recreating it.
17626 2010-04-09 Pedro Alves <pedro@codesourcery.com>
17628 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17630 2010-04-09 Stan Shebs <stan@codesourcery.com>
17631 Pedro Alves <pedro@codesourcery.com>
17633 * server.h (LONGEST): New.
17634 (struct thread_info) <while_stepping>: New field.
17635 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17637 (initialize_tracepoint, handle_tracepoint_general_set)
17638 (handle_tracepoint_query, tracepoint_finished_step)
17639 (tracepoint_was_hit, release_while_stepping_state_list):
17640 (current_traceframe): Declare.
17641 * server.c (handle_general_set): Handle tracepoint packets.
17642 (read_memory): New.
17643 (write_memory): New.
17644 (handle_search_memory_1): Use read_memory.
17645 (handle_query): Report support for conditional tracepoints, trace
17646 state variables, and tracepoint sources. Handle tracepoint
17648 (main): Initialize the tracepoints module.
17649 (process_serial_event): Handle traceframe reads/writes.
17651 * linux-low.c (handle_tracepoints): New.
17652 (linux_wait_1): Call it.
17653 (linux_resume_one_lwp): Handle while-stepping.
17654 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17655 (linux_target_ops): Install them.
17656 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17658 * linux-x86-low.c (x86_supports_tracepoints): New.
17659 (the_low_target). Install it.
17661 * mem-break.h (delete_breakpoint): Declare.
17662 * mem-break.c (delete_breakpoint): Make external.
17664 * target.h (struct target_ops): Add `supports_tracepoints',
17665 `read_pc', and `write_pc' fields.
17666 (target_supports_tracepoints): Define.
17667 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17670 * regcache.h (struct regcache) <registers_owned>: New field.
17671 (init_register_cache, regcache_cpy): Declare.
17672 (regcache_read_pc, regcache_write_pc): Declare.
17673 (register_cache_size): Declare.
17674 (supply_regblock): Declare.
17675 * regcache.c (init_register_cache): New.
17676 (new_register_cache): Use it.
17677 (regcache_cpy): New.
17678 (register_cache_size): New.
17679 (supply_regblock): New.
17680 (regcache_read_pc, regcache_write_pc): New.
17682 * tracepoint.c: New.
17684 * Makefile.in (OBS): Add tracepoint.o.
17685 (tracepoint.o): New rule.
17687 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17689 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17691 (i386-mmx.c): Likewise.
17692 (i386-mmx-linux.o): Likewise.
17693 (i386-mmx-linux.c): Likewise.
17695 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17696 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17697 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17698 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17700 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17701 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17702 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17704 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17706 * Makefile.in (clean): Updated.
17708 (i386-avx.c): Likewise.
17709 (i386-avx-linux.o): Likewise.
17710 (i386-avx-linux.c): Likewise.
17711 (amd64-avx.o): Likewise.
17712 (amd64-avx.c): Likewise.
17713 (amd64-avx-linux.o): Likewise.
17714 (amd64-avx-linux.c): Likewise.
17716 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17717 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17718 (srv_amd64_regobj): Add amd64-avx.o.
17719 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17720 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17721 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17722 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17723 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17724 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17725 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17727 * i387-fp.c: Include "i386-xstate.h".
17729 (i387_cache_to_xsave): Likewise.
17730 (i387_xsave_to_cache): Likewise.
17731 (x86_xcr0): Likewise.
17733 * i387-fp.h (i387_cache_to_xsave): Likewise.
17734 (i387_xsave_to_cache): Likewise.
17735 (x86_xcr0): Likewise.
17737 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17738 * linux-crisv32-low.c (target_regsets): Likewise.
17739 * linux-m68k-low.c (target_regsets): Likewise.
17740 * linux-mips-low.c (target_regsets): Likewise.
17741 * linux-ppc-low.c (target_regsets): Likewise.
17742 * linux-s390-low.c (target_regsets): Likewise.
17743 * linux-sh-low.c (target_regsets): Likewise.
17744 * linux-sparc-low.c (target_regsets): Likewise.
17745 * linux-xtensa-low.c (target_regsets): Likewise.
17747 * linux-low.c: Include <sys/uio.h>.
17748 (regsets_fetch_inferior_registers): Support nt_type.
17749 (regsets_store_inferior_registers): Likewise.
17750 (linux_process_qsupported): New.
17751 (linux_target_ops): Add linux_process_qsupported.
17753 * linux-low.h (regset_info): Add nt_type.
17754 (linux_target_ops): Add process_qsupported.
17756 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17758 (init_registers_i386_avx_linux): New.
17759 (init_registers_amd64_avx_linux): Likewise.
17760 (xmltarget_i386_linux_no_xml): Likewise.
17761 (xmltarget_amd64_linux_no_xml): Likewise.
17762 (PTRACE_GETREGSET): Likewise.
17763 (PTRACE_SETREGSET): Likewise.
17764 (x86_fill_xstateregset): Likewise.
17765 (x86_store_xstateregset): Likewise.
17766 (use_xml): Likewise.
17767 (x86_linux_update_xmltarget): Likewise.
17768 (x86_linux_process_qsupported): Likewise.
17769 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17770 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17771 init_registers_i386_linux here. Call
17772 x86_linux_update_xmltarget.
17773 (the_low_target): Add x86_linux_process_qsupported.
17775 * server.c (handle_query): Call target_process_qsupported.
17777 * target.h (target_ops): Add process_qsupported.
17778 (target_process_qsupported): New.
17780 2010-04-03 Pedro Alves <pedro@codesourcery.com>
17782 * inferiors.c (add_thread): Set last_status kind to
17783 TARGET_WAITKIND_IGNORE.
17784 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17785 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17786 (linux_wait_1): Move `thread' local definition to block that uses
17787 it. Don't NULL initialize `event_child'.
17788 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17789 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17790 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17792 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17794 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17795 an extended waitstatus, or by a watchpoint.
17796 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17797 thread was stepping or has been stopped by a watchpoint.
17799 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17801 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17802 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17803 of another, then delete the previous, and validate all
17805 (validate_inserted_breakpoint): New.
17806 (delete_disabled_breakpoints): New.
17807 (validate_breakpoints): New.
17808 (check_mem_read): Validate breakpoints before trusting their
17809 shadow. Delete disabled breakpoints.
17810 (check_mem_write): Validate breakpoints before trusting they
17811 should be inserted. Delete disabled breakpoints.
17812 * mem-break.h (validate_breakpoints):
17813 * server.c (handle_query): Validate breakpoints when we see a
17816 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17818 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17819 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17820 if we could tell there's a GDB breakpoint at stop_pc.
17821 (need_step_over_p): Don't do a step over if we find a GDB
17822 breakpoint at the resume PC.
17824 * mem-break.c (struct raw_breakpoint): New.
17825 (enum bkpt_type): New type `gdb_breakpoint'.
17826 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17827 fields. New field `raw'.
17828 (find_raw_breakpoint_at): New.
17829 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17830 breakpoint instead.
17831 (set_breakpoint_at): Adjust.
17832 (delete_raw_breakpoint): New.
17833 (release_breakpoint): New.
17834 (delete_breakpoint): Rename to...
17835 (delete_breakpoint_1): ... this. Add proc parameter. Use
17836 release_breakpoint. Return ENOENT.
17837 (delete_breakpoint): Reimplement.
17838 (find_breakpoint_at): Delete.
17839 (find_gdb_breakpoint_at): New.
17840 (delete_breakpoint_at): Delete.
17841 (set_gdb_breakpoint_at): New.
17842 (delete_gdb_breakpoint_at): New.
17843 (gdb_breakpoint_here): New.
17844 (set_reinsert_breakpoint): Use release_breakpoint.
17845 (uninsert_breakpoint): Rename to ...
17846 (uninsert_raw_breakpoint): ... this.
17847 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17848 (reinsert_raw_breakpoint): Change parameter type to
17850 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17852 (check_breakpoints): Adjust. Use release_breakpoint.
17853 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17854 (breakpoint_inserted_here): Ditto.
17855 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17856 Don't trust the breakpoint's shadow if it is not inserted.
17857 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17858 (delete_all_breakpoints): Adjust.
17859 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17860 use delete_breakpoint_1.
17862 * mem-break.h (breakpoints_supported): Delete declaration.
17863 (set_gdb_breakpoint_at): Declare.
17864 (gdb_breakpoint_here): Declare.
17865 (delete_breakpoint_at): Delete.
17866 (delete_gdb_breakpoint_at): Declare.
17868 * server.h (struct raw_breakpoint): Forward declare.
17869 (struct process_info): New field `raw_breakpoints'.
17871 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17874 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17876 * linux-low.c (status_pending_p_callback): Fix comment.
17877 (linux_wait_for_event_1): Move most of the internal breakpoint
17878 handling from here...
17879 (linux_wait_1): ... to here.
17880 (count_events_callback): New.
17881 (select_singlestep_lwp_callback): New.
17882 (select_event_lwp_callback): New.
17883 (cancel_breakpoints_callback): New.
17884 (select_event_lwp): New.
17885 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17886 priority to all LWPs that have had events that should be reported
17887 to the client. Cancel breakpoints when about to reporting the
17888 event to the client, not while stopping lwps. No longer cancel
17889 finished single-steps here.
17890 (cancel_finished_single_step): Delete.
17891 (cancel_finished_single_steps): Delete.
17893 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17895 * mem-break.c (enum bkpt_type): New.
17896 (struct breakpoint): New field `type'.
17897 (set_breakpoint_at): Change return type to struct breakpoint
17898 pointer. Set type to `other_breakpoint' by default.
17899 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17900 in the breakpoint list.
17901 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17902 (reinsert_breakpoint): Rename to ...
17903 (reinsert_raw_breakpoint): ... this.
17904 (reinsert_breakpoints_at): Adjust.
17905 * mem-break.h (struct breakpoint): Declare.
17906 (set_breakpoint_at): Change return type to struct breakpoint
17909 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17911 * server.c (handle_query): Assign, not compare.
17913 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17915 Teach linux gdbserver to step-over-breakpoints.
17917 * linux-low.c (can_hardware_single_step): New.
17918 (supports_breakpoints): New.
17919 (handle_extended_wait): If stopping threads, read the stop pc of
17920 the new cloned LWP.
17922 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17923 low target doesn't support retrieving the PC.
17924 (add_lwp): Set last_resume_kind to resume_continue.
17925 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17926 (linux_attach): Don't clear stop_expected. Set the lwp's
17927 last_resume_kind to resume_stop.
17928 (linux_detach_one_lwp): Don't check for removed breakpoints.
17929 (check_removed_breakpoint): Delete.
17930 (status_pending_p): Rename to ...
17931 (status_pending_p_callback): ... this. Don't check for removed
17932 breakpoints. Don't consider threads that are stopped from GDB's
17934 (linux_wait_for_lwp): Always read the stop_pc here.
17935 (cancel_breakpoint): New.
17936 (step_over_bkpt): New global.
17937 (linux_wait_for_event_1): Implement stepping over breakpoints.
17938 (gdb_wants_lwp_stopped): New.
17939 (gdb_wants_all_stopped): New.
17940 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17941 single-step traps here. Store the thread's last reported target
17943 (send_sigstop): Don't clear stop_expected. Always set it,
17945 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17946 (cancel_finished_single_step): New.
17947 (cancel_finished_single_steps): New.
17948 (wait_for_sigstop): Don't cancel finished single-step traps here.
17949 (linux_resume_one_lwp): Don't check for removed breakpoints.
17950 Don't set `step' on non-hardware step archs.
17951 (linux_set_resume_request): Ignore resume_stop requests if already
17952 stopping or stopped. Set the lwp's last_resume_kind.
17953 (resume_status_pending_p): Don't check for removed breakpoints.
17954 (need_step_over_p): New.
17955 (start_step_over): New.
17956 (finish_step_over): New.
17957 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17958 requests. Clear the thread's last reported target waitstatus.
17959 Don't use the `suspended' flag. Don't consider pending breakpoints.
17960 (linux_resume): Start a step-over if necessary.
17961 (proceed_one_lwp): New.
17962 (proceed_all_lwps): New.
17963 (unstop_all_lwps): New.
17964 * linux-low.h (struct lwp_info): Rewrite comment for the
17965 `suspended' flag. Add the `stop_pc' field. Delete the
17966 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17967 Add `'last_resume_kind' and `need_step_over' fields.
17968 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17969 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17970 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17971 (set_raw_breakpoint_at): New.
17972 (set_breakpoint_at): Rewrite to use it.
17973 (reinsert_breakpoint_handler): Delete.
17974 (set_reinsert_breakpoint): New.
17975 (reinsert_breakpoint_by_bp): Delete.
17976 (delete_reinsert_breakpoints): New.
17977 (uninsert_breakpoint): Rewrite.
17978 (uninsert_breakpoints_at): New.
17979 (reinsert_breakpoint): Rewrite.
17980 (reinsert_breakpoints_at): New.
17981 (check_breakpoints): Rewrite.
17982 (breakpoint_here): New.
17983 (breakpoint_inserted_here): New.
17984 (check_mem_read): Adjust.
17985 * mem-break.h (breakpoints_supported, breakpoint_here)
17986 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
17987 (reinsert_breakpoint_by_bp): Delete declaration.
17988 (delete_reinsert_breakpoints): Declare.
17989 (reinsert_breakpoint): Delete declaration.
17990 (reinsert_breakpoints_at): Declare.
17991 (uninsert_breakpoint): Delete declaration.
17992 (uninsert_breakpoints_at): Declare.
17993 (check_breakpoints): Adjust prototype.
17994 * server.h: Adjust include order.
17995 (struct thread_info): Declare here. Add a `last_status' field.
17997 2010-03-23 Michael Snyder <msnyder@vmware.com>
17999 * server.c (crc32): New function.
18000 (handle_query): Add handling for 'qCRC:' request.
18002 2010-03-23 Pedro Alves <pedro@codesourcery.com>
18004 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18005 lwp had been stopped by a watchpoint.
18007 2010-03-16 Pedro Alves <pedro@codesourcery.com>
18009 * server.h (internal_error): Declare.
18010 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18011 * utils.c (internal_error): New function.
18013 2010-03-15 Andreas Schwab <schwab@redhat.com>
18015 * configure.srv: Fix typo setting srv_regobj.
18017 2010-03-15 Pedro Alves <pedro@codesourcery.com>
18019 * linux-low.c (fetch_register): Avoid passing a non string literal
18021 (usr_store_inferior_registers): Ditto.
18023 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18025 * linux-low.c (linux_write_memory): Bail out early if peeking
18028 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18030 * linux-low.h (struct lwp_info): New fields
18031 `stopped_by_watchpoint' and `stopped_data_address'.
18032 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18033 here, and cache them in the lwp object.
18034 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18036 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18038 (linux_stopped_by_watchpoint): Rewrite.
18039 (linux_stopped_data_address): Rewrite.
18041 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
18043 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18044 switching the current inferior, not before.
18046 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18048 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18049 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18050 i386-linux.c and amd64-linux.c.
18051 (reg-i386.o): Removed.
18052 (reg-i386.c): Likewise.
18053 (reg-i386-linux.o): Likewise.
18054 (reg-i386-linux.c): Likewise.
18055 (reg-x86-64.o): Likewise.
18056 (reg-x86-64.c): Likewise.
18057 (reg-x86-64-linux.o): Likewise.
18058 (reg-x86-64-linux.c): Likewise.
18060 (i386.c): Likewise.
18061 (i386-linux.o): Likewise.
18062 (i386-linux.c): Likewise.
18063 (amd64.o): Likewise.
18064 (amd64.c): Likewise.
18065 (amd64-linux.o): Likewise.
18066 (amd64-linux.c): Likewise.
18068 * configure.srv (srv_i386_regobj): New.
18069 (srv_i386_linux_regobj): Likewise.
18070 (srv_amd64_regobj): Likewise.
18071 (srv_amd64_linux_regobj): Likewise.
18072 (srv_i386_32bit_xmlfiles): Likewise.
18073 (srv_i386_64bit_xmlfiles): Likewise.
18074 (srv_i386_xmlfiles): Likewise.
18075 (srv_amd64_xmlfiles): Likewise.
18076 (srv_i386_linux_xmlfiles): Likewise.
18077 (srv_amd64_linux_xmlfiles): Likewise.
18078 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18079 srv_xmlfiles to $srv_i386_xmlfiles.
18080 (i[34567]86-*-mingw32ce*): Likewise.
18081 (i[34567]86-*-mingw*): Likewise.
18082 (i[34567]86-*-nto*): Likewise.
18083 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18084 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18085 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18086 (x86_64-*-linux*): Likewise.
18088 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18089 (init_registers_amd64_linux): New.
18090 (x86_arch_setup): Replace init_registers_x86_64_linux with
18091 init_registers_amd64_linux.
18093 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18095 * configure.ac: Check for libdl. If it is not available link against
18096 static libthread_db.
18097 * configure: Regenerate.
18099 2010-02-22 Pedro Alves <pedro@codesourcery.com>
18103 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18104 handing a read watchpoint.
18105 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18107 2010-02-12 Doug Evans <dje@google.com>
18109 * linux-low.c (linux_supports_tracefork_flag): Document.
18110 (linux_look_up_symbols): Add comment.
18112 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18114 * regcache.c (supply_register): Clear regcache if buf is NULL.
18116 2010-02-02 Nicolas Roche <roche@sourceware.org>
18117 Joel Brobecker <brobecker@adacore.com>
18119 * inferiors.c (find_inferior): Add function documentation.
18120 (unloaded_dll): Handle the case where the unloaded dll has not
18121 been previously registered in the dll list.
18123 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18125 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18126 (thumb2_breakpoint): New.
18127 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18129 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18131 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18132 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18135 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18137 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18139 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18141 * linux-s390-low.c (s390_collect_ptrace_register)
18142 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18144 2010-01-21 Doug Evans <dje@google.com>
18146 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18147 (PTRACE_ARG4_TYPE): New macro.
18148 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18149 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18150 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18151 (usr_store_inferior_registers): Ditto.
18152 (linux_read_memory, linux_write_memory): Ditto.
18153 (linux_test_for_tracefork): Ditto.
18155 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18156 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18158 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18160 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18163 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18165 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18166 prototype to take a regcache. Adjust.
18168 2010-01-20 Pedro Alves <pedro@codesourcery.com>
18170 * regcache.h (struct thread_info): Forward declare.
18171 (struct regcache): New.
18172 (new_register_cache): Adjust prototype.
18173 (get_thread_regcache): Declare.
18174 (free_register_cache): Adjust prototype.
18175 (registers_to_string, registers_from_string): Ditto.
18176 (supply_register, supply_register_by_name, collect_register)
18177 (collect_register_as_string, collect_register_by_name): Ditto.
18178 * regcache.c (struct inferior_regcache_data): Delete.
18179 (get_regcache): Rename to ...
18180 (get_thread_regcache): ... this. Adjust. Switch inferior before
18181 fetching registers.
18182 (regcache_invalidate_one): Adjust.
18183 (regcache_invalidate): Fix prototype.
18184 (new_register_cache): Return the new register cache.
18185 (free_register_cache): Change prototype.
18186 (realloc_register_cache): Adjust.
18187 (registers_to_string): Change prototype to take a regcache. Adjust.
18188 (registers_from_string): Ditto.
18189 (register_data): Ditto.
18190 (supply_register): Ditto.
18191 (supply_register_by_name): Ditto.
18192 (collect_register): Ditto.
18193 (collect_register_as_string): Ditto.
18194 (collect_register_by_name): Ditto.
18195 * server.c (process_serial_event): Adjust.
18196 * linux-low.h (regset_fill_func, regset_store_func): Change
18198 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18200 * linux-low.c (get_stop_pc): Adjust.
18201 (check_removed_breakpoint): Adjust.
18202 (linux_wait_for_event): Adjust.
18203 (linux_resume_one_lwp): Adjust.
18204 (fetch_register): Add regcache parameter. Adjust.
18205 (usr_store_inferior_registers): Ditto.
18206 (regsets_fetch_inferior_registers): Ditto.
18207 (regsets_store_inferior_registers): Ditto.
18208 (linux_fetch_registers, linux_store_registers): Ditto.
18209 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18211 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18213 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18214 prototype to take a regcache.
18215 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18216 * remote-utils.c (convert_ascii_to_int, outreg)
18217 (prepare_resume_reply): Change prototype to take a regcache.
18219 * target.h (struct target_ops) <fetch_registers, store_registers>:
18220 Change prototype to take a regcache.
18221 (fetch_inferior_registers, store_inferior_registers): Change
18222 prototype to take a regcache. Adjust.
18223 * proc-service.c (ps_lgetregs): Adjust.
18224 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18225 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18226 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18227 take a regcache. Adjust.
18228 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18229 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18230 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18231 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18232 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18233 (cris_cannot_fetch_register):
18234 (cris_breakpoint_at): Change prototype to take a regcache.
18236 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18237 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18238 to take a regcache. Adjust.
18239 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18241 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18242 take a regcache. Adjust.
18243 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18244 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18245 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18246 * linux-mips-low.c (mips_get_pc):
18247 (mips_set_pc): Change prototype to take a regcache. Adjust.
18248 (mips_reinsert_addr): Adjust.
18249 (mips_collect_register): Change prototype to take a regcache.
18251 (mips_supply_register):
18252 (mips_collect_register_32bit, mips_supply_register_32bit)
18253 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18254 (mips_store_fpregset): Ditto.
18255 * linux-ppc-low.c (ppc_supply_ptrace_register)
18256 (ppc_supply_ptrace_register): Ditto.
18257 (parse_spufs_run): Adjust.
18258 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18259 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18260 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18261 take a regcache. Adjust.
18262 * linux-s390-low.c (s390_collect_ptrace_register)
18263 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18264 (s390_set_pc): Change prototype to take a regcache. Adjust.
18265 (s390_arch_setup): Adjust.
18266 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18267 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18268 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18269 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18270 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18272 (sparc_breakpoint_at): Adjust.
18273 * linux-xtensa-low.c (xtensa_fill_gregset):
18274 (xtensa_store_gregset):
18275 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18276 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18277 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18278 prototype to take a regcache. Adjust.
18279 * win32-arm-low.c (arm_fetch_inferior_register)
18280 (arm_store_inferior_register): Change prototype to take a
18282 * win32-i386-low.c (i386_fetch_inferior_register)
18283 (i386_store_inferior_register): Change prototype to take a
18285 * win32-low.c (child_fetch_inferior_registers)
18286 (child_store_inferior_registers): Change prototype to take a
18288 (win32_wait): Adjust.
18289 (win32_fetch_inferior_registers): Change prototype to take a
18291 (win32_store_inferior_registers): Adjust.
18292 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18293 store_inferior_register>: Change prototype to take a regcache.
18295 2010-01-20 Doug Evans <dje@google.com>
18297 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18299 (linux_wait_for_event1, linux_init_signals): Ditto.
18300 (W_STOPCODE): Provide definition if missing.
18302 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18304 * linux-low.c (linux_core_of_thread): New.
18305 (compare_ints, show_process, list_threads): New.
18306 (linux_qxfer_osdata): Report threads and cores.
18307 (linux_target_op): Register linux_core_of_thread.
18308 * remote-utils.c (prepare_resume_reply): Report the core.
18309 (buffer_xml_printf): Support %d specifier.
18310 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18312 (handle_query): Handle qXfer:threads. Announce availability
18314 * target.h (struct target_ops): New field core_of_thread.
18316 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18318 * Makefile.in (clean): Remove new generated files.
18319 (reg-s390.o, reg-s390.c): Remove rules.
18320 (reg-s390x.o, reg-s390x.c): Likewise.
18321 (s390-linux32.o, s390-linux32.c): Add rules.
18322 (s390-linux64.o, s390-linux64.c): Likewise.
18323 (s390x-linux64.o, s390x-linux64.c): Likewise.
18324 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18325 * linux-s390-low.c: Include <elf.h>.
18326 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18327 (init_registers_s390): Remove prototype.
18328 (init_registers_s390x): Likewise.
18329 (init_registers_s390_linux32): Add prototype.
18330 (init_registers_s390_linux64): Likewise.
18331 (init_registers_s390x_linux64): Likewise.
18332 (s390_num_regs_3264): New define.
18333 (s390_regmap_3264): New global variable.
18334 (s390_cannot_fetch_register): Remove obsolete check.
18335 (s390_cannot_store_register): Likewise.
18336 (s390_collect_ptrace_register): Handle upper/lower register halves.
18337 (s390_supply_ptrace_register): Likewise.
18338 (s390_fill_gregset): Update to register number changes.
18339 (s390_get_hwcap): New routine.
18340 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18341 Install appropriate regmap and register set.
18343 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18345 * server.c (gdbserver_version): Update copyright year to 2010.
18346 * gdbreplay.c (gdbreplay_version): Likewise.
18348 2009-12-28 Doug Evans <dje@google.com>
18350 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18351 elf/external.h. Include <elf.h> instead but only if necessary.
18353 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18355 * linux-low.c (linux_remove_process): Remove `detaching'
18356 parameter. Don't release/detach from thread_db here.
18357 (linux_kill): Release/detach from thread_db here, ...
18358 (linux_detach): ... and here, before actually detaching.
18359 (linux_wait_1): ... and here, when a process exits.
18360 * thread-db.c (any_thread_of): New.
18361 (thread_db_free): Switch the current inferior to a thread of the
18364 2009-12-21 Doug Evans <dje@google.com>
18366 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18368 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18369 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18370 warning ifndef __NR_tkill. Move setting of errno there too.
18371 Delete unnecessary resetting of errno after syscall.
18372 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18374 * configure.ac: Check for dladdr.
18375 * config.in: Regenerate.
18376 * configure: Regenerate.
18377 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18378 (try_thread_db_load): Update.
18380 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18382 2009-12-18 Doug Evans <dje@google.com>
18384 * event-loop.c: Include unistd.h if it exists.
18386 * linux-low.c (my_waitpid): Move definition away from being in
18387 between linux_tracefork_child/linux_test_for_tracefork.
18389 * gdb_proc_service.h (psaddr_t): Fix type.
18390 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18391 signature to match glibc.
18393 2009-12-16 Doug Evans <dje@google.com>
18395 * linux-low.c (linux_read_memory): Fix argument to read.
18397 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18399 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18400 events, don't leave current_inferior pointing at null.
18402 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18404 * win32-low.c (LOG): Delete.
18405 (OUTMSG): Output to stderr.
18406 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18407 on compile time LOG macro.
18408 (win32_wait): Fix debug output.
18410 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18412 * win32-low.c (win32_add_one_solib): If the dll name is
18413 "ntdll.dll", prepend the system directory to the dll path.
18415 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18417 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18419 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18420 Vladimir Prus <vladimir@codesourcery.com>
18422 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18423 * configure.ac: Check for __mcoldfire__ and set
18424 gdb_cv_m68k_is_coldfire.
18425 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18426 reg-cf.o and reg-m68k.o.
18427 * configure: Regenerated.
18429 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18431 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18432 Pass it to thread_db_free.
18433 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18434 proper `detaching' argument to linux_remove_process.
18435 * linux-low.h (thread_db_free): Add `detaching' parameter.
18436 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18438 (thread_db_free): Add `detaching' parameter. Only
18439 call td_ta_clear_event if detaching from process.
18441 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18443 * thread-db.c (thread_db_free): Fix typo.
18445 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18448 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18450 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18452 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18453 with an i686 compiler.
18454 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18456 * configure: Rebuilt.
18458 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18462 * server.c (handle_search_memory_1): Correct read_addr initialization
18463 in loop for searching subsequent chunks.
18465 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18467 * configure.ac: New --with-libthread-db option.
18468 * thread-db.c: Allow direct dependence on libthread_db.
18469 (thread_db_free): Adjust.
18470 * config.in: Regenerate.
18471 * configure: Likewise.
18473 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18476 * thread-db.c (attach_thread): New function.
18477 (maybe_attach_thread): Return success/failure.
18478 (find_new_threads_callback): Adjust.
18479 (thread_db_find_new_threads): Loop until no new threads.
18481 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18483 * proc-service.c (ps_lgetregs): Formatting.
18485 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18487 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18488 * configure.ac: Adjust.
18489 * linux-low.h (struct process_info_private): Move members to struct
18491 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18492 * linux-low.c (linux_remove_process): Adjust.
18493 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18494 * server.c (handle_query): Move code ...
18495 (handle_monitor_command): ... here. New function.
18496 * target.h (struct target_ops): New member.
18497 * thread-db.c (struct thread_db): New.
18498 (libthread_db_search_path): New variable.
18499 (thread_db_create_event, thread_db_enable_reporting)
18500 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18501 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18502 (try_thread_db_load_1, dladdr_to_soname): New functions.
18503 (try_thread_db_load, thread_db_load_search): New functions.
18504 (thread_db_init): Search for libthread_db.
18505 (thread_db_free): New function.
18506 (thread_db_handle_monitor_command): Likewise.
18507 * config.in: Regenerate.
18508 * configure: Regenerate.
18510 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18512 * spu-low.c (spu_kill): Wait for inferior to terminate.
18513 Call clear_inferiors.
18514 (spu_detach): Call clear_inferiors.
18516 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18518 * aclocal.m4: Regenerate.
18519 * config.in: Likewise.
18520 * configure: Likewise.
18522 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18524 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18525 (parse_spufs_run): New function.
18526 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18527 (ppc_breakpoint_at): Handle SPU breakpoints.
18529 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18531 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18532 (SPUFS_MAGIC): Define.
18533 (spu_enumerate_spu_ids): New function.
18534 (linux_qxfer_spu): New function.
18535 (linux_target_ops): Install linux_qxfer_spu.
18537 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18539 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18540 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18541 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18542 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18543 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18544 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18545 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18546 (init_registers_powerpc_cell32l): Add prototype.
18547 (init_registers_powerpc_cell64l): Likewise.
18548 (ppc_arch_setup): Detect Cell/B.E. architecture.
18550 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18552 * Makefile.in (datarootdir): New variable.
18554 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18556 * linux-low.c (linux_write_memory): Update debugging output.
18557 * Makefile.in (clean): Add new descriptions.
18558 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18559 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18560 * configure.srv: Add new files for arm*-*-linux*.
18561 * linux-arm-low.c: Add new declarations.
18562 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18563 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18564 (HWCAP_VFPv3D16): New.
18565 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18566 instead of __IWMMXT__.
18567 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18568 (arm_arch_setup): New.
18569 (target_regsets): Remove #ifdef. Add VFP regset.
18570 (the_low_target): Use arm_arch_setup.
18572 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18574 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18575 the main thread again.
18577 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18579 Adding Neutrino gdbserver.
18580 * configure: Regenerated.
18581 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18582 * configure.srv (i[34567]86-*-nto*): New target.
18583 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18584 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18585 (nto_comctrl) [__QNX__]: New function.
18586 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18588 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
18590 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18593 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18594 Pedro Alves <pedro@codesourcery.com>
18596 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18597 don't support CONTEXT_EXTENDED_REGISTERS.
18598 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18599 (the_low_target): Install them.
18600 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18601 failing with ERROR_PIPE_NOT_CONNECTED.
18603 2009-06-30 Doug Evans <dje@google.com>
18604 Pierre Muller <muller@ics.u-strasbg.fr>
18606 Add h/w watchpoint support to x86-linux, win32-i386.
18607 * Makefile.in (SFILES): Add i386-low.c
18608 (i386_low_h): Define.
18609 (i386-low.o): Add dependencies.
18610 (linux-x86-low.o): Add i386-low.h dependency.
18611 (win32-i386-low.o): Ditto.
18612 * i386-low.c: New file.
18613 * i386-low.h: New file.
18614 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18615 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18616 * linux-low.c (linux_add_process): Initialize arch_private.
18617 (linux_remove_process): Free arch_private.
18618 (add_lwp): Initialize arch_private.
18619 (delete_lwp): Free arch_private.
18620 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18622 * linux-low.h (process_info_private): New member arch_private.
18623 (lwp_info): New member arch_private.
18624 (linux_target_ops): New members new_process, new_thread,
18626 (ptid_of): New macro.
18627 * linux-x86-low.c: Include stddef.h, i386-low.h.
18628 (arch_process_info): New struct.
18629 (arch_lwp_info): New struct.
18630 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18631 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18632 (i386_dr_low_get_status): New function.
18633 (x86_insert_point, x86_remove_point): New functions.
18634 (x86_stopped_by_watchpoint): New function.
18635 (x86_stopped_data_address): New function.
18636 (x86_linux_new_process, x86_linux_new_thread): New functions.
18637 (x86_linux_prepare_to_resume): New function.
18638 (the_low_target): Add entries for insert_point, remove_point,
18639 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18641 * server.c (debug_hw_points): New global.
18642 (monitor_show_help): Document set debug-hw-points.
18643 (handle_query): Process "set debug-hw-points".
18644 * server.h (debug_hw_points): Declare.
18645 (paddress): Declare.
18646 * utils.c (NUMCELLS, CELLSIZE): New macros.
18647 (get_sell, xsnprintf, paddress): New functions.
18648 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18649 remove_point, stopped_by_watchpoint, stopped_data_address.
18650 * win32-i386-low.c: Include i386-low.h.
18651 (debug_reg_state): Replaces dr.
18652 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18653 (i386_dr_low_get_status): New function.
18654 (i386_insert_point, i386_remove_point): New functions.
18655 (i386_stopped_by_watchpoint): New function.
18656 (i386_stopped_data_address): New function.
18657 (i386_initial_stuff): Update.
18658 (get_thread_context,set_thread_context,i386_thread_added): Update.
18659 (the_low_target): Add entries for insert_point,
18660 remove_point, stopped_by_watchpoint, stopped_data_address.
18661 * win32-low.c (win32_insert_watchpoint): New function.
18662 (win32_remove_watchpoint): New function.
18663 (win32_stopped_by_watchpoint): New function.
18664 (win32_stopped_data_address): New function.
18665 (win32_target_ops): Add entries for insert_watchpoint,
18666 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18667 * win32-low.h (win32_target_ops): New members insert_point,
18668 remove_point, stopped_by_watchpoint, stopped_data_address.
18670 2009-06-25 Pedro Alves <pedro@codesourcery.com>
18672 * server.c (process_serial_event): Re-return unsupported, not
18673 error, if the type isn't recognized. Re-allow supporting only
18674 insert or remove packets. Also call require_running for
18675 breakpoints. Add missing break statement to default case. Tidy.
18676 * target.h (struct target_ops): Rename insert_watchpoint to
18677 insert_point, and remove_watchpoint to remove_point.
18679 * linux-low.h (struct linux_target_ops): Likewise.
18680 * linux-low.c (linux_insert_watchpoint): Rename to ...
18681 (linux_insert_point): ... this. Adjust.
18682 (linux_remove_watchpoint): Rename to ...
18683 (linux_remove_point): ... this. Adjust.
18684 (linux_target_ops): Adjust.
18685 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18686 (cris_insert_point): ... this.
18687 (cris_remove_watchpoint): Rename to ...
18688 (cris_remove_point): ... this.
18689 (the_low_target): Adjust.
18691 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18693 * server.c (handle_v_kill): Pass signal_pid to
18694 kill_inferior if multi_process is zero.
18696 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18698 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18699 * target.h (target_ops): Comment for *_watchpoint to make it clear
18700 the functions can get types '0' and '1'.
18702 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18704 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18705 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18706 * regcache.c (get_regcache): Likewise.
18707 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18708 * win32-low.c (child_fetch_inferior_registers): Remove check for
18711 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18712 Pedro Alves <pedro@codesourcery.com>
18714 * target.h (struct target_ops) <supports_multi_process>: New
18716 (target_supports_multi_process): New.
18717 * server.c (handle_query): Even if GDB reports support, only
18718 enable multi-process if the target also supports it. Report
18719 multi-process support only if the target backend supports it.
18720 * linux-low.c (linux_supports_multi_process): New function.
18721 (linux_target_ops): Install it as target_supports_multi_process
18724 2009-05-24 Doug Evans <dje@google.com>
18726 Global renaming of find_thread_pid to find_thread_ptid.
18727 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18728 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18729 All callers updated.
18731 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18732 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18735 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18736 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18737 (linux_resume_one_lwp): Ditto.
18739 2009-05-23 Doug Evans <dje@google.com>
18741 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18742 from struct inferior_list_entry * to struct lwp_info *.
18743 All callers updated.
18745 2009-05-13 Doug Evans <dje@google.com>
18747 * linux-x86-low.c: Don't include assert.h.
18748 (x86_siginfo_fixup): Use fatal, not assert.
18749 (x86_arch_setup): Fix comment.
18751 2009-05-12 Doug Evans <dje@google.com>
18753 Biarch support for i386/amd64 gdbserver.
18754 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18755 Add linux-x86-low.c.
18756 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18757 (linux-x86-low.o): Add.
18758 * linux-x86-64-low.c: Delete.
18759 * linux-i386-low.c: Delete.
18760 * linux-x86-low.c: New file.
18761 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18763 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18765 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18766 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18767 (linux_child_pid_to_exec_file): New function.
18768 (elf_64_header_p, elf_64_file_p): New functions.
18769 (siginfo_fixup): New function.
18770 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18771 give target a chance to convert layout.
18772 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18773 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18775 2009-05-07 Doug Evans <dje@google.com>
18777 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18778 (regsets_store_inferior_registers): Ditto.
18780 2009-05-06 Pedro Alves <pedro@codesourcery.com>
18784 * linux-low.c (must_set_ptrace_flags): Delete.
18785 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18787 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18788 `lwp->must_set_ptrace_flags' instead.
18789 (linux_wait_for_event_1): Set ptrace options here.
18790 (linux_wait_1): ... not here.
18792 2009-04-30 Doug Evans <dje@google.com>
18794 * inferiors.c (started_inferior_callback): New function.
18795 (attached_inferior_callback): New function.
18796 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18797 * server.c (print_started_pid, print_attached_pid): New functions.
18798 (detach_or_kill_for_exit): New function.
18799 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18800 * server.h (have_started_inferiors_p): Declare.
18801 (have_attached_inferiors_p): Declare.
18803 * inferiors.c (remove_process): Fix memory leak, free process.
18804 * linux-low.c (linux_remove_process): New function.
18805 (linux_kill): Call it instead of remove_process.
18806 (linux_detach, linux_wait_1): Ditto.
18808 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18810 * configure.srv: Add x86 Windows CE target.
18812 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18814 * inferiors.c (get_thread_process): Make global.
18815 * server.h (get_thread_process): Add prototype.
18816 * thread-db.c (find_one_thread): Use get_thread_process
18817 instead of current_process.
18818 (thread_db_get_tls_address): Do not crash if called when
18819 thread layer is not yet initialized.
18821 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18823 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18824 * spu-low.c (current_tid): Rename to ...
18825 (current_ptid): ... this.
18826 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18827 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18828 ptid_get_lwp (current_ptid) instead of current_tid.
18829 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18830 instead of current_tid. Use find_process_pid to verify pid
18831 argument is valid. Pass proper argument to remove_process.
18832 (spu_thread_alive): Compare current_ptid instead of current_tid.
18833 (spu_resume): Likewise.
18835 2009-04-02 Pedro Alves <pedro@codesourcery.com>
18837 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18840 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18842 Implement the multiprocess extensions, and add linux multiprocess
18845 * server.h (ULONGEST): Declare.
18846 (struct ptid, ptid_t): New.
18847 (minus_one_ptid, null_ptid): Declare.
18848 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18849 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18850 (struct inferior_list_entry): Change `id' type from unsigned from
18852 (struct sym_cache, struct breakpoint, struct
18853 process_info_private): Forward declare.
18854 (struct process_info): Declare.
18855 (current_process): Declare.
18856 (all_processes): Declare.
18857 (initialize_inferiors): Declare.
18858 (add_thread): Adjust to use ptid_t.
18859 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18860 (add_process, remove_process, find_thread_pid): Declare.
18861 (find_inferior_id): Adjust to use ptid_t.
18862 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18863 (multi_process): Declare.
18864 (push_event): Adjust to use ptid_t.
18865 (read_ptid, write_ptid): Declare.
18866 (prepare_resume_reply): Adjust to use ptid_t.
18867 (clear_symbol_cache): Declare.
18868 * inferiors.c (all_processes): New.
18869 (null_ptid, minus_one_ptid): New.
18870 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18871 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18872 (add_thread): Change unsigned long to ptid. Remove gdb_id
18874 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18875 (gdb_id_to_thread): Rename to ...
18876 (find_thread_pid): ... this. Change unsigned long to ptid.
18877 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18878 (loaded_dll, pull_pid_from_list): Adjust.
18879 (add_process, remove_process, find_process_pid)
18880 (get_thread_process, current_process, initialize_inferiors): New.
18881 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18882 (struct target_waitstatus) <related_pid>: Ditto.
18883 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18884 return type to int.
18885 (struct target_ops) <join>: Add `pid' argument.
18886 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18887 (struct target_ops) <wait>: Add `ptid' field. Change return type
18889 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18890 (mywait): Add `ptid' argument. Change return type to ptid_t.
18891 (target_pid_to_str): Declare.
18892 * target.c (set_desired_inferior): Adjust to use ptids.
18893 (mywait): Add new `ptid' argument. Adjust.
18894 (target_pid_to_str): New.
18895 * mem-break.h (free_all_breakpoints): Declare.
18896 * mem-break.c (breakpoints): Delelete.
18897 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18898 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18899 to use per-process breakpoint list.
18900 (free_all_breakpoints): New.
18901 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18902 (symbol_cache, all_symbols_looked_up): Delete.
18904 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18906 (prepare_resume_reply): Change ptid argument's type from unsigned
18907 long to ptid_t. Adjust. Implement W;process and X;process.
18908 (free_sym_cache, clear_symbol_cache): New.
18909 (look_up_one_symbol): Adjust to per-process symbol cache. *
18910 * server.c (cont_thread, general_thread, step_thread): Change type
18912 (attached): Delete.
18913 (multi_process): New.
18914 (last_ptid): Change type to ptid_t.
18915 (struct vstop_notif) <ptid>: Change type to ptid_t.
18916 (queue_stop_reply, push_event): Change `ptid' argument's type to
18918 (discard_queued_stop_replies): Add `pid' argument.
18919 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18920 changes. Don't reference the `attached' global.
18921 (attach_inferior): Adjust to mywait interface changes.
18922 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18923 features. Handle and report "multiprocess+". Handle
18925 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18927 (handle_v_kill): New.
18928 (handle_v_stopped): Adjust to use target_pid_to_str.
18929 (handle_v_requests): Allow multiple attaches and runs when
18930 multiprocess extensions are in effect. Handle "vKill".
18931 (myresume): Adjust to use ptids.
18932 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18933 (handle_status): Adjust to discard_queued_stop_replies interface
18935 (first_thread_of, kill_inferior_callback)
18936 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18937 (main): Call initialize_inferiors. Adjust to use ptids, killing
18938 and detaching from all inferiors. Handle multiprocess packet
18940 * linux-low.h: Include gdb_proc_service.h.
18941 (struct process_info_private): New.
18942 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18943 <lwpid_of>: Use ptid_get_lwp.
18944 (get_lwp_thread): Adjust.
18945 (struct lwp_info): Add `dead' member.
18946 (find_lwp_pid): Declare.
18947 * linux-low.c (thread_db_active): Delete.
18948 (new_inferior): Adjust comment.
18949 (inferior_pid): Delete.
18950 (linux_add_process): New.
18951 (handle_extended_wait): Adjust.
18952 (add_lwp): Change unsigned long to ptid.
18953 (linux_create_inferior): Add process to processes table. Adjust
18954 to use ptids. Don't set new_inferior here.
18955 (linux_attach_lwp): Rename to ...
18956 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18957 it. Adjust to use ptids.
18958 (linux_attach_lwp): New.
18959 (linux_attach): Add process to processes table. Don't set
18961 (struct counter): New.
18962 (second_thread_of_pid_p, last_thread_of_process_p): New.
18963 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18964 multiple processes.
18965 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18966 processes. Remove process from process table.
18967 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18968 to multiple processes.
18969 (any_thread_of): New.
18970 (linux_detach): Add `pid' argument, and handle it. Remove process
18971 from processes table.
18972 (linux_join): Add `pid' argument. Handle it.
18973 (linux_thread_alive): Change unsighed long argument to ptid_t.
18974 Consider dead lwps as not being alive.
18975 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
18976 threads we're not interested in.
18977 (same_lwp, find_lwp_pid): New.
18978 (linux_wait_for_lwp): Change `pid' argument's type from int to
18980 (linux_wait_for_event): Rename to ...
18981 (linux_wait_for_event_1): ... this. Change `pid' argument's type
18982 from int to ptid_t. Adjust.
18983 (linux_wait_for_event): New.
18984 (linux_wait_1): Add `ptid' argument. Change return type to
18985 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
18986 that exit from the process table.
18987 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
18989 (mark_lwp_dead): New.
18990 (wait_for_sigstop): Adjust to use ptids. If a process exits while
18991 stopping all threads, mark its main lwp as dead.
18992 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
18994 (fetch_register, usr_store_inferior_registers)
18995 (regsets_fetch_inferior_registers)
18996 (regsets_store_inferior_registers, linux_read_memory)
18997 (linux_write_memory): Inline `inferior_pid'.
18998 (linux_look_up_symbols): Adjust to use per-process
18999 `thread_db_active'.
19000 (linux_request_interrupt): Adjust to use ptids.
19001 (linux_read_auxv): Inline `inferior_pid'.
19002 (initialize_low): Don't reference thread_db_active.
19003 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19004 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19005 (ps_getpid): Return the pid of the current inferior.
19006 * thread-db.c (proc_handle, thread_agent): Delete.
19007 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19009 (find_one_thread): Change argument type to ptid_t. Adjust to
19011 (maybe_attach_thread): Adjust to per-process data and ptids.
19012 (thread_db_find_new_threads): Ditto.
19013 (thread_db_init): Ditto.
19014 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19015 processes table. Adjust to use ptids.
19016 (spu_kill, spu_detach): Adjust interface. Remove process from
19018 (spu_join, spu_thread_alive): Adjust interface.
19019 (spu_wait): Adjust interface. Remove process from processes
19020 table. Adjust to use ptids.
19021 * win32-low.c (current_inferior_tid): Delete.
19022 (current_inferior_ptid): New.
19023 (debug_event_ptid): New.
19024 (thread_rec): Take a ptid. Adjust.
19025 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19026 (child_delete_thread): Ditto.
19027 (do_initial_child_stuff): Add `attached' argument. Add process to
19029 (child_fetch_inferior_registers, child_store_inferior_registers):
19031 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19032 (win32_attach): Pass 1 to do_initial_child_stuff.
19033 (win32_kill): Adjust interface. Remove process from processes
19035 (win32_detach): Ditto.
19036 (win32_join): Adjust interface.
19037 (win32_thread_alive): Take a ptid.
19038 (win32_resume): Adjust to use ptids.
19039 (get_child_debug_event): Ditto.
19040 (win32_wait): Adjust interface. Remove exiting process from
19043 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19045 Non-stop mode support.
19047 * server.h (non_stop): Declare.
19048 (gdb_client_data, handler_func): Declare.
19049 (delete_file_handler, add_file_handler, start_event_loop):
19051 (handle_serial_event, handle_target_event, push_event)
19052 (putpkt_notif): Declare.
19053 * target.h (enum resume_kind): New.
19054 (struct thread_resume): Replace `step' field by `kind' field.
19055 (TARGET_WNOHANG): Define.
19056 (struct target_ops) <wait>: Add `options' argument.
19057 <supports_non_stop, async, start_non_stop>: New fields.
19058 (target_supports_non_stop, target_async): New.
19059 (start_non_stop): Declare.
19060 (mywait): Add `options' argument.
19061 * target.c (mywait): Add `options' argument. Print child exit
19062 notifications here.
19063 (start_non_stop): New.
19064 * server.c (non_stop, own_buf, mem_buf): New globals.
19065 (struct vstop_notif): New.
19066 (notif_queue): New global.
19067 (queue_stop_reply, push_event, discard_queued_stop_replies)
19068 (send_next_stop_reply): New.
19069 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19071 (attach_inferior): In non-stop mode, don't wait for the target
19073 (handle_general_set): Handle QNonStop.
19074 (handle_query): When handling qC, return the current general
19075 thread, instead of the first thread of the list.
19076 (handle_query): If the backend supports non-stop mode, include
19077 QNonStop+ in the qSupported query response.
19078 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19080 (handle_v_attach, handle_v_run): Handle non-stop mode.
19081 (handle_v_stopped): New.
19082 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19083 (myresume): Adjust to use resume_kind. Handle non-stop.
19084 (queue_stop_reply_callback): New.
19085 (handle_status): Handle non-stop mode.
19086 (main): Clear non_stop flag on reconnection. Use the event-loop.
19087 Refactor serial protocol handling from here ...
19088 (process_serial_event): ... to this new function. When GDB
19089 selects any thread, select one here. In non-stop mode, wait until
19090 GDB acks all pending events before exiting.
19091 (handle_serial_event, handle_target_event): New.
19092 * remote-utils.c (remote_open): Install remote_desc in the event
19094 (remote_close): Remove remote_desc from the event loop.
19095 (putpkt_binary): Rename to...
19096 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19097 (putpkt_binary): New as wrapper around putpkt_binary_1.
19098 (putpkt_notif): New.
19099 (prepare_resume_reply): In non-stop mode, don't change the
19101 * event-loop.c: New.
19102 * Makefile.in (OBJ): Add event-loop.o.
19103 (event-loop.o): New rule.
19105 * linux-low.h (pid_of): Moved here.
19107 (get_lwp_thread): Use lwpid_of.
19108 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19109 * linux-low.c (pid_of): Delete.
19110 (inferior_pid): Use lwpid_of.
19111 (linux_event_pipe): New.
19112 (target_is_async_p): New.
19114 (handle_extended_wait): Use lwpid_of.
19115 (add_lwp): Don't set lwpid field.
19116 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19117 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19118 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19119 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19120 first. Adjust to linux_wait_for_event interface changes. Use
19122 (linux_detach): Don't delete the main lwp here.
19123 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19124 (status_pending_p): Don't consider explicitly suspended lwps.
19125 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19126 pointer. Add OPTIONS argument. Change return type to int. Use
19127 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19128 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19129 pointer. Add status pointer argument. Return a pid instead of a
19130 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19131 changes. In non-stop mode, don't switch to a random thread.
19132 (linux_wait): Rename to...
19133 (linux_wait_1): ... this. Add target_options argument, and handle
19134 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19135 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19136 clean exit and signal exit code. Don't stop all threads in
19137 non-stop mode. In all-stop mode, only stop all threads when
19138 reporting a stop to GDB. Handle explicit thread stop requests.
19139 (async_file_flush, async_file_mark): New.
19141 (send_sigstop): Use lwpid_of.
19142 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19143 interface changes. In non-stop mode, don't switch to a random
19145 (linux_resume_one_lwp): Use lwpid_of.
19146 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19147 (linux_resume_one_thread): ... this. Handle resume_stop. In
19148 non-stop mode, don't look for pending flag in all threads.
19149 (resume_status_pending_p): Don't consider explicitly suspended
19151 (my_waitpid): Reimplement. Emulate __WALL.
19152 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19154 (sigchld_handler, linux_supports_non_stop, linux_async)
19155 (linux_start_non_stop): New.
19156 (linux_target_ops): Register linux_supports_non_stop, linux_async
19157 and linux_start_non_stop.
19158 (initialize_low): Install SIGCHLD handler.
19159 * thread-db.c (thread_db_create_event, find_one_thread)
19160 (thread_db_get_tls_address): Use lwpid_of.
19161 * win32-low.c (win32_detach): Adjust to use resume_kind.
19162 (win32_wait): Add `options' argument.
19163 * spu-low.c (spu_resume): Adjust to use resume_kind.
19164 (spu_wait): Add `options' argument.
19166 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19168 Decouple target code from remote protocol.
19170 * target.h (enum target_waitkind): New.
19171 (struct target_waitstatus): New.
19172 (struct target_ops) <wait>: Return an unsigned long. Take a
19173 target_waitstatus pointer instead of a char pointer.
19174 (mywait): Likewise.
19175 * target.c (mywait): Change prototype to return an unsigned long.
19176 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19177 * server.h (thread_from_wait, old_thread_from_wait): Delete
19179 (prepare_resume_reply): Change prototype to take a
19181 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19182 (last_status, last_ptid): New.
19183 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19184 pid instead of a signal.
19185 (attach_inferior): Remove "status" and "signal" parameters.
19187 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19189 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19190 (handle_v_requests, myresume): Remove "status" and "signal"
19191 parameters. Adjust.
19192 (handle_status): New.
19193 (main): Delete local `status'. Adjust.
19194 * remote-utils.c: Include target.h.
19195 (prepare_resume_reply): Change prototype to take a
19196 target_waitstatus. Adjust.
19198 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19200 * spu-low.c (spu_wait): Adjust.
19201 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19203 (win32_wait): Adjust.
19205 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19207 * target.h (struct thread_resume): Delete leave_stopped member.
19208 (struct target_ops): Add a `n' argument to the `resume' callback.
19209 * server.c (start_inferior): Adjust.
19210 (handle_v_cont, myresume): Adjust.
19211 * linux-low.c (check_removed_breakpoint): Adjust to resume
19212 interface change, and to removed leave_stopped field.
19213 (resume_ptr): Delete.
19214 (struct thread_resume_array): New.
19215 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19216 resume interface change.
19217 (linux_continue_one_thread, linux_queue_one_thread)
19218 (resume_status_pending_p): Check if the resume field is NULL
19219 instead of checking the leave_stopped member.
19220 (linux_resume): Adjust to the target resume interface change.
19221 * spu-low.c (spu_resume): Adjust to the target resume interface
19223 * win32-low.c (win32_detach, win32_resume): Ditto.
19225 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19227 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19229 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19231 (linux_continue_one_thread): Only preserve the stepping flag if
19232 there's a pending breakpoint.
19234 2009-03-31 Pedro Alves <pedro@codesourcery.com>
19236 * server.c (main): After the inferior having exited, call
19237 remote_close before exiting gdbserver.
19239 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19241 Fix size of FPSCR in Power 7 processors.
19242 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19243 (PPC_FEATURE_HAS_DFP): New #define.
19244 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19247 2009-03-23 Pedro Alves <pedro@codesourcery.com>
19249 * server.c (handle_query) Whitespace and formatting.
19251 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19253 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19254 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19255 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19256 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19257 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19258 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19259 Makefile.in, configure.ac: Fix whitespace throughout.
19260 * configure: Regenerate.
19262 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19264 * inferiors.c (find_inferior): Make it safe for the callback
19265 function to delete the currently iterated inferior.
19267 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19269 * Makefile.in (linuw_low_h): Move higher.
19270 (thread-db.o): Depend on $(linux_low_h).
19272 2009-03-17 Pedro Alves <pedro@codesourcery.com>
19274 Rename "process" to "lwp" throughout.
19276 * linux-low.c (all_processes): Rename to...
19277 (all_lwps): ... this.
19278 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19279 (add_process): Rename to ...
19280 (add_lwp): ... this. Adjust.
19281 (linux_create_inferior): Adjust.
19282 (linux_attach_lwp): Adjust.
19283 (linux_attach): Adjust.
19284 (linux_kill_one_process): Rename to ...
19285 (linux_kill_one_lwp): ... this. Adjust.
19286 (linux_kill): Adjust.
19287 (linux_detach_one_process): Rename to ...
19288 (linux_detach_one_lwp): ... this. Adjust.
19289 (linux_detach): Adjust.
19290 (check_removed_breakpoint): Adjust.
19291 (status_pending_p): Adjust.
19292 (linux_wait_for_process): Rename to ...
19293 (linux_wait_for_lwp): ... this. Adjust.
19294 (linux_wait_for_event): Adjust.
19295 (send_sigstop): Adjust.
19296 (wait_for_sigstop): Adjust.
19297 (stop_all_processes): Rename to ...
19298 (stop_all_lwps): ... this.
19299 (linux_resume_one_process): Rename to ...
19300 (linux_resume_one_lwp): ... this. Adjust.
19301 (linux_set_resume_request, linux_continue_one_thread)
19302 (linux_queue_one_thread, resume_status_pending_p)
19303 (usr_store_inferior_registers, regsets_store_inferior_registers)
19304 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19306 * linux-low.h (get_process): Rename to ...
19307 (get_lwp): ... this. Adjust.
19308 (get_thread_process): Rename to ...
19309 (get_thread_lwp): ... this. Adjust.
19310 (get_process_thread): Rename to ...
19311 (get_lwp_thread): ... this. Adjust.
19312 (struct process_info): Rename to ...
19313 (struct lwp_info): ... this.
19314 (all_processes): Rename to ...
19315 (all_lwps): ... this.
19316 * proc-service.c (ps_lgetregs): Adjust.
19317 * thread-db.c (thread_db_create_event, find_one_thread)
19318 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19320 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19322 * server.c (handle_query): Handle "qAttached".
19324 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19326 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19327 GPLv3, update license URL.
19329 2009-03-01 Doug Evans <dje@google.com>
19331 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19332 (server_h): Add gdb_signals.h.
19333 (signals.o): Update.
19334 * server.h (target_signal_from_host,target_signal_to_host_p)
19335 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19337 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19339 * remote-utils.c (getpkt): Also generate remote-debug
19340 information if noack_mode is set.
19342 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19344 * server.c (handle_query): Report qXfer:siginfo:read and
19345 qXfer:siginfo:write as supported and handle them.
19346 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19347 * linux-low.c (linux_xfer_siginfo): New.
19348 (linux_target_ops): Set it.
19350 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19352 * server.c (gdbserver_usage): Mention --remote-debug.
19353 (main): Accept '--remote-debug' switch.
19355 2009-01-18 Doug Evans <dje@google.com>
19357 * regcache.c (new_register_cache): No need to check result of xcalloc.
19358 * server.c (handle_search_memory): Back out calls to xmalloc,
19359 result is checked and error is returned to user upon failure.
19360 (handle_query): Ditto. Add more checks for result of malloc.
19361 (handle_v_cont): Check result of malloc, report error back to
19363 (handle_v_run): Ditto. Call freeargv.
19364 * server.h (freeargv): Declare.
19365 * utils.c (freeargv): New fn.
19367 2009-01-15 Doug Evans <dje@google.com>
19369 * gdbreplay.c (perror_with_name): Make arg const char *.
19370 * server.h (target_signal_to_name): Make return type const char *.
19371 * thread-db.c (thread_db_err_str): Make return type const char *.
19372 * utils.c (perror_with_name): Make arg const char *.
19374 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19376 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19377 when handling a EXIT_PROCESS_DEBUG_EVENT.
19379 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19381 * gdbreplay.c (gdbreplay_version): Update copyright year.
19382 * server.c (gdbserver_version): Likewise.
19384 2009-01-05 Doug Evans <dje@google.com>
19386 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19387 (handle_extended_wait): Improve comment.
19389 2008-12-13 Doug Evans <dje@google.com>
19391 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19392 * server.h (ATTR_MALLOC): New macro.
19393 (xmalloc,xcalloc,xstrdup): Declare.
19394 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19395 * inferiors.c: Ditto.
19396 * linux-low.c: Ditto.
19397 * mem-break.c: Ditto.
19398 * regcache.c: Ditto.
19399 * remote-utils.c: Ditto.
19402 * win32-low.c: Ditto.
19404 2008-12-12 Doug Evans <dje@google.com>
19406 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19407 in debugging printf.
19409 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19411 2008-12-09 Doug Evans <dje@google.com>
19413 * linux-low.h (struct process_info): Delete member tid, unused.
19414 * thread-db.c (find_one_thread): Update.
19415 (maybe_attach_thread): Update.
19417 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19419 * target.h (struct target_ops): Add qxfer_osdata member.
19420 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19422 (linux_qxfer_osdata): New functions.
19423 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19425 * server.c (handle_query): Handle "qXfer:osdata:read:".
19426 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19427 (buffer_xml_printf): New functions.
19428 * server.h (struct buffer): New.
19429 (buffer_grow_str, buffer_grow_str0): New macros.
19430 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19431 (buffer_xml_printf): Declare.
19433 2008-11-24 Doug Evans <dje@google.com>
19435 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19437 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19439 * server.c (handle_v_run): Always use the supplied argument list.
19441 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19443 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19444 (xtensa_regmap_table): Add entry for scompare1.
19446 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19448 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19449 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19450 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19451 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19452 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19453 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19454 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19455 XML target descriptions.
19456 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19457 when inferior is running on an ISA 2.05 or later processor. Add
19458 special case to return offset for full 64-bit slot of FPSCR when
19461 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19463 * Makefile.in (SFILES, clean): Added sparc64 files.
19464 (reg-sparc64.o, reg-sparc64.c): New.
19465 * configure.srv (sparc*-*-linux*): New configuration.
19466 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19467 syscall arguments for SPARC.
19468 (regsets_store_inferior_registers): Likewise.
19469 * linux-sparc-low.c: New file.
19471 2008-10-21 Doug Evans <dje@google.com>
19473 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19474 (READLINE_DIR,READLINE_DEP): Delete.
19475 (INTERNAL_CFLAGS): Update.
19476 (LINTFLAGS): Update.
19478 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19480 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19481 whole argv from the last run, not just argv[0].
19483 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19485 * regcache.c (new_register_cache): Return NULL if the register
19486 cache size isn't known yet.
19487 (free_register_cache): Avoid dereferencing a NULL regcache.
19489 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19491 * configure.srv: Merge MIPS and MIPS64.
19493 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19495 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19497 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19499 * Makefile.in: Add required vsx dependencies.
19501 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19502 Declare init_registers_powerpc_vsx32l.
19503 Declare init_registers_powerpc_vsx64l.
19504 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19505 (ppc_arch_setup): Check for VSX in hwcap.
19506 (ppc_fill_vsxregset): New function.
19507 (ppc_store_vsxregset): New function.
19508 Add new VSX entry in regset_info target_regsets.
19510 * configure.srv: Add new VSX dependencies.
19512 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19514 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19515 (remote_open): Set or clear transport_is_reliable.
19516 (putpkt_binary): Don't expect acks in noack mode.
19517 (getpkt): Don't send ack/nac in noack mode.
19518 * server.c (handle_general_set): Handle QStartNoAckMode.
19519 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19521 (main): Reset noack_mode on every connection.
19522 * server.h (noack_mode): Declare.
19524 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19526 * Makefile.in (GDBREPLAY_OBS): New variable.
19527 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19529 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19530 Daniel Jacobowitz <dan@codesourcery.com>
19532 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19533 (usr_store_inferior_registers): Likewise.
19534 (regsets_store_inferior_registers): Likewise.
19536 2008-07-31 Rolf Jansen <rj@surtec.com>
19537 Pedro Alves <pedro@codesourcery.com>
19539 * configure.ac: Check for memmem declaration.
19540 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19541 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19542 (disable_packet_qfThreadInfo): Unconditionally compile.
19543 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19544 * configure, config.in: Regenerate.
19546 2008-07-28 Doug Kwan <dougkwan@google.com>
19548 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19549 (linux_write_memory): Remove declaration of errno.
19551 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19553 * linux-low.c (handle_extended_wait): Do not use "status"
19554 variable uninitialized.
19556 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19558 * server.c (handle_v_attach): Inhibit reporting dll changes.
19560 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19562 * remote-utils.c (prepare_resume_reply): If requested, don't
19563 output "thread:TID" in the T stop reply.
19565 * server.c (disable_packet_vCont, disable_packet_Tthread)
19566 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19567 (handle_query): If requested, disable support for qC, qfThreadInfo
19569 (handle_v_requests): If requested, disable support for vCont.
19570 (gdbserver_show_disableable): New.
19571 (main): Handle --disable-packet and --disable-packet=LIST.
19573 * server.h (disable_packet_vCont, disable_packet_Tthread)
19574 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19576 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19578 * server.c (gdbserver_usage): Mention --version.
19580 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19582 * Makefile.in (gdbreplay.o): New rule.
19584 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19586 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19587 message, not gdbserver.
19589 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
19590 Nathan Sidwell <nathan@codesourcery.com>
19591 Joseph Myers <joseph@codesourcery.com>
19593 * acinclude.m4: Include ../../config/acx.m4.
19594 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19595 * configure, config.in: Regenerate.
19596 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19597 * server.c (gdbserver_version): Print PKGVERSION.
19598 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19599 (main): Adjust gdbserver_usage calls.
19600 * gdbreplay.c (version, host_name): Add declarations.
19601 (gdbreplay_version, gdbreplay_usage): New.
19602 (main): Accept --version and --help options.
19604 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19606 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19607 (arm_breakpoint_at): Handle Thumb.
19608 (the_low_target): Add comment.
19610 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19612 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19614 2008-05-09 Doug Evans <dje@google.com>
19616 * server.h (decode_search_memory_packet): Declare.
19617 * remote-utils.c (decode_search_memory_packet): New fn.
19618 * server.c (handle_search_memory_1): New fn.
19619 (handle_search_memory): New fn.
19620 (handle_query): Process qSearch:memory packets.
19622 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19624 * regcache.c (registers_length): Remove.
19625 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19626 full register packet.
19627 * regcache.h (registers_length): Remove prototype.
19628 * server.h (PBUFSIZ): Define to 16384.
19630 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19632 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19633 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19634 powerpc-64l.o, and powerpc-altivec64l.o.
19635 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19636 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19637 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19638 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19639 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19642 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19643 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19644 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19645 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19646 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19647 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19648 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19649 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19650 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19651 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19654 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19655 (init_registers_powerpc_32l): ... this new prototype.
19656 (init_registers_powerpc_32): Remove, replace by ...
19657 (init_registers_powerpc_altivec32l): ... this new prototype.
19658 (init_registers_powerpc_e500): Remove, replace by ...
19659 (init_registers_powerpc_e500l): ... this new prototype.
19660 (init_registers_ppc64): Remove, replace by ...
19661 (init_registers_powerpc_64l): ... this new prototype.
19662 (init_registers_powerpc_64): Remove, replace by ...
19663 (init_registers_powerpc_altivec64l): ... this new prototype.
19664 (ppc_num_regs): Set to 73.
19665 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19666 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19667 (ppc_cannot_store_register): Handle orig_r3 and trap.
19668 (ppc_arch_setup): Update init_registers_... calls.
19669 (ppc_fill_gregset): Handle orig_r3 and trap.
19671 * inferiors.c (clear_inferiors): Reset current_inferior.
19673 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
19675 * acinclude.m4: Add override.m4.
19676 * configure: Regenerate.
19678 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19680 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19681 initial call to init_register_ppc64.
19683 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19685 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19686 single powerpc*-*-linux* case.
19687 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19689 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19691 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
19692 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
19694 * linux-ppc-low.c: Include <elf.h>.
19695 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19696 (ppc_hwcap): New global variable.
19697 (ppc_regmap): Remove __SPE__ #ifdef sections.
19698 (ppc_regmap_e500): New global variable.
19699 (ppc_cannot_store_register): Update __SPE__ special case.
19700 (ppc_get_hwcap): New function.
19701 (ppc_arch_setup): Use it to determine whether inferior supports
19702 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19703 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19704 Do not access registers if target does not support AltiVec.
19705 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19706 Do not access registers if target does not support SPE.
19707 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19709 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19711 * linux-low.c (disabled_regsets, num_regsets): New.
19712 (use_regsets_p): Delete.
19713 (linux_wait_for_process): Clear disabled_regsets.
19714 (regsets_fetch_inferior_registers): Check and set it.
19715 (regsets_store_inferior_registers): Likewise.
19716 (linux_fetch_registers, linux_store_registers): Do not use
19718 (initialize_low): Allocate disabled_regsets.
19720 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19722 * Makefile.in (LIBOBJS): New.
19723 (OBS): Use LIBOBJS.
19724 (memmem.o): New rule.
19725 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19726 * configure: Regenerated.
19728 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19730 * server.c (handle_query): Never return "unsupported" for
19731 qXfer:features:read queries.
19733 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19735 * server.c (get_features_xml): Fix inverted condition.
19736 (handle_query): Always support qXfer:feature:read.
19738 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19740 * server.c (wrapper_argv): New.
19741 (start_inferior): Handle wrapper_argv. If set, expect an extra
19743 (gdbserver_usage): Document --wrapper.
19744 (main): Parse --wrapper.
19746 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19748 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19749 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19750 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19751 (ppc_set_pc): Likewise.
19752 (ppc_arch_setup): New function.
19753 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19754 of collect_register.
19755 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
19757 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19759 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19760 instead of linux-ppc64-low.o.
19761 * linux-ppc64-low.c: Remove file.
19762 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19763 (linux-ppc64-low.o): Remove rule.
19765 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19766 (init_registers_powerpc_64): Likewise.
19767 (ppc_regmap): Conditionally define depending on __powerpc64__.
19768 (ppc_cannot_store_register): Do not special-case "fpscr" when
19769 compiled on __powerpc64__.
19770 (ppc_collect_ptrace_register): New function.
19771 (ppc_supply_ptrace_register): New function.
19772 (ppc_breakpoint): Change type to "unsigned int".
19773 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19774 (the_low_target): Conditionally provide initializers for the
19775 arch_setup member depending on __powerpc64__. Install
19776 collect_ptrace_register and supply_ptrace_register members.
19778 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19780 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19781 * server.c (gdbserver_xmltarget): Define.
19782 (get_features_xml): Use it to replace "target.xml" and arch_string.
19784 * configure.srv: Remove srv_xmltarget. Add XML files that were
19785 mentioned there to srv_xmlfiles instead. Remove conditional tests
19786 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19787 srv_xmlfiles and srv_regobj to include all possible choices.
19788 * configure.ac (srv_xmltarget): Remove.
19789 (srv_xmlfiles): Do not add "target.xml".
19790 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19791 checks for supplementary target information.
19792 * configure: Regenerate.
19793 * Makefile.in (XML_TARGET): Remove.
19794 (target.xml): Remove rule.
19795 (clean): Do not clean up target.xml.
19796 (.PRECIOUS): Do not mention target.xml.
19798 * target.h (struct target_ops): Remove arch_string member.
19799 * linux-low.c (linux_arch_string): Remove.
19800 (linux_target_ops): Remove arch_string initializer.
19801 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19802 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19803 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19804 * spu-low.c (spu_arch_string): Remove.
19805 (spu_target_ops): Remove arch_string initializer.
19806 * win32-low.c (win32_arch_string): Remove.
19807 (win32_target_ops): Remove arch_string initializer.
19808 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19809 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19810 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19812 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19814 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19815 by collect_ptrace_register and supply_ptrace_register hooks.
19816 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19817 instead of checking for the_low_target.left_pad_xfer.
19818 (usr_store_inferior_registers): Use collect_ptrace_register callback
19819 instead of checking for the_low_target.left_pad_xfer.
19821 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19822 (s390_supply_ptrace_register): Likewise.
19823 (s390_fill_gregset): Call s390_collect_ptrace_register.
19824 (the_low_target): Update.
19826 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19827 (ppc_supply_ptrace_register): Likewise.
19828 (the_low_target): Update.
19830 * linux-i386-low.c (the_low_target): Update.
19831 * linux-x86-64-low.c (the_low_target): Update.
19833 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19835 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19836 reg-s390.o and reg-s390x.o.
19838 * linux-low.c (new_inferior): New global variable.
19839 (linux_create_inferior, linux_attach): Set it.
19840 (linux_wait_for_process): Call the_low_target.arch_setup after the
19841 target has stopped for the first time.
19842 (initialize_low): Do not call the_low_target.arch_setup.
19844 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19845 (s390_set_pc): Likewise.
19846 (s390_arch_setup): New function.
19847 (the_low_target): Use s390_arch_setup as arch_setup routine.
19849 * regcache.c (realloc_register_cache): New function.
19850 (set_register_cache): Call it for each existing regcache.
19852 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19854 * server.h (init_registers): Remove prototype.
19856 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19857 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19858 instead of init_registers ().
19859 * linux-arm-low.c (init_registers_arm): Add prototype.
19860 (init_registers_arm_with_iwmmxt): Likewise.
19861 (the_low_target): Add initializer for arch_setup field.
19862 * linux-cris-low.c (init_registers_cris): Add prototype.
19863 (the_low_target): Add initializer for arch_setup field.
19864 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19865 (the_low_target): Add initializer for arch_setup field.
19866 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19867 (the_low_target): Add initializer for arch_setup field.
19868 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19869 (the_low_target): Add initializer for arch_setup field.
19870 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19871 (the_low_target): Add initializer for arch_setup field.
19872 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19873 (the_low_target): Add initializer for arch_setup field.
19874 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19875 (init_registers_mips64_linux): Likewise.
19876 (the_low_target): Add initializer for arch_setup field.
19877 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19878 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19879 (the_low_target): Add initializer for arch_setup field.
19880 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19881 (init_registers_powerpc_64): Likewise.
19882 (the_low_target): Add initializer for arch_setup field.
19883 * linux-s390-low.c (init_registers_s390): Add prototype.
19884 (init_registers_s390x): Likewise.
19885 (the_low_target): Add initializer for arch_setup field.
19886 * linux-sh-low.c (init_registers_sh): Add prototype.
19887 (the_low_target): Add initializer for arch_setup field.
19888 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19889 (the_low_target): Add initializer for arch_setup field.
19890 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19891 (the_low_target): Add initializer for arch_setup field.
19893 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19894 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19895 instead of init_registers ().
19896 * win32-arm-low.c (init_registers_arm): Add prototype.
19897 (the_low_target): Add initializer for arch_setup field.
19898 * win32-i386-low.c (init_registers_i386): Add prototype.
19899 (the_low_target): Add initializer for arch_setup field.
19901 * spu-low.c (init_registers_spu): Add prototype.
19902 (initialize_low): Call initialie_registers_spu () instead of
19903 initialize_registers ().
19905 2008-02-19 Pedro Alves <pedro@codesourcery.com>
19907 * server.c (handle_v_requests): When handling the vRun and vAttach
19908 packets, if already debugging a process, don't kill it. Return an
19911 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19913 * server.c (handle_query): Correct length check.
19915 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19917 * win32-low.c (do_initial_child_stuff): Add process handle
19918 parameter. Set current_process_handle and current_process_id from the
19919 parameters. Clear globals.
19920 (win32_create_inferior): Don't set current_process_handle and
19921 current_process_id here. Instead pass them on the call to
19922 do_initial_child_stuff.
19923 (win32_attach): Likewise.
19924 (win32_clear_inferiors): New.
19925 (win32_kill): Don't close the current process handle or the
19926 current thread handle here. Instead call win32_clear_inferiors.
19927 (win32_detach): Don't open a new handle to the process. Call
19928 win32_clear_inferiors.
19929 (win32_join): Don't rely on current_process_handle; open a new
19930 handle using the process id.
19931 (win32_wait): Call win32_clear_inferiors when the inferior process
19934 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19936 * server.c (monitor_show_help): Add "exit".
19938 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19940 * Makefile.in (SFILES): Add linux-xtensa-low.c.
19941 (clean): Add reg-xtensa.c.
19942 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
19943 * configure.srv (xtensa*-*-linux*) New target.
19944 * linux-xtensa-low.c: New.
19945 * xtensa-xtregs.c: New.
19947 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19949 * hostio.c: Don't include errno.h.
19950 (errno_to_fileio_errno): Move to hostio-errno.
19951 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19952 error number outputting to the target->hostio_last_error callback.
19953 (hostio_packet_error): Use FILEIO_EINVAL directly.
19954 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19955 calls to hostio_error.
19956 * hostio-errno.c: New.
19957 * server.h (hostio_last_error_from_errno): Declare.
19958 * target.h (target_ops): Add hostio_last_error member.
19959 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19960 as hostio_last_error handler.
19961 * spu-low.c (spu_target_ops): Likewise.
19962 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19963 (wince_hostio_last_error): New functions.
19964 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19965 as hostio_last_error handler.
19966 (win32_target_ops) [!_WIN32_WCE]: Register
19967 hostio_last_error_from_errno as hostio_last_error handler.
19968 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19969 (hostio-errno.o): New rule.
19970 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19971 * configure.srv (srv_hostio_err_objs): New variable. Default to
19973 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19974 * configure: Regenerate.
19976 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19978 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
19979 (linux_kill, linux_detach): Clean up the process list.
19980 * remote-utils.c (remote_open): Improve port number parsing.
19981 (putpkt_binary, input_interrupt): Only send interrupts if the target
19983 * server.c (extended_protocol): Make static.
19984 (attached): Define earlier.
19985 (exit_requested, response_needed, program_argv): New variables.
19986 (target_running): New.
19987 (start_inferior): Clear attached here.
19988 (attach_inferior): Set attached here.
19989 (require_running): Define.
19990 (handle_query): Use require_running and target_running. Implement
19992 (handle_v_attach, handle_v_run): New.
19993 (handle_v_requests): Use require_running. Handle vAttach and vRun.
19994 (gdbserver_usage): Update.
19995 (main): Redo argument parsing. Handle --debug and --multi. Handle
19996 --attach along with other options or after the port. Save
19997 program_argv. Support no initial program. Resynchronize
19998 communication with GDB after an error. Handle "monitor exit".
19999 Use require_running and target_running. Always allow the extended
20000 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20001 restart in extended mode.
20002 * README: Refer to the GDB manual. Update --attach usage.
20004 2007-12-20 Andreas Schwab <schwab@suse.de>
20006 * linux-low.c (STACK_SIZE): Define.
20007 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20008 (linux_test_for_tracefork): Likewise.
20010 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20012 * linux-low.c (linux_wait_for_event): Update messages. Do not
20013 reinsert auto-delete breakpoints.
20014 * mem-break.c (struct breakpoint): Change return type of handler to
20016 (set_breakpoint_at): Update handler type.
20017 (reinsert_breakpoint_handler): Return 1 instead of calling
20019 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20021 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20022 * mem-break.h (set_breakpoint_at): Update handler type.
20023 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20024 * win32-low.c (auto_delete_breakpoint): New.
20025 (get_child_debug_event): Use it.
20027 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20029 * configure.ac: Check for pread and pwrite.
20030 * hostio.c (handle_pread): Fall back to lseek and read.
20031 (handle_pwrite): Fall back to lseek and write.
20032 * config.in, configure: Regenerated.
20034 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20036 * server.c (myresume): Add own_buf argument.
20037 (main): Update calls.
20039 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20041 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20042 * remote-utils.c (remote_open): Do not call disable_async_io.
20043 (block_async_io): Delete.
20044 (unblock_async_io): Make static.
20045 (initialize_async_io): New.
20046 * server.c (handle_v_cont): Handle async I/O here.
20047 (myresume): Likewise. Move other common resume tasks here...
20048 (main): ... from here. Call initialize_async_io. Disable async
20049 I/O before the main loop.
20050 * server.h (initialize_async_io): Declare.
20051 (block_async_io, unblock_async_io): Delete prototypes.
20052 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20054 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20056 * remote-utils.c (readchar): Allow binary data in received messages.
20058 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20060 * win32-low.c (attaching): New global.
20061 (win32_create_inferior): Clear the `attaching' global.
20062 (win32_attach): Set the `attaching' global.
20063 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20064 attaching. Only set a breakpoint at the entry point if not
20067 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20069 * server.c (main): Don't report dll events on the initial
20070 connection on attaches.
20072 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20074 * server.c (main): Relax numerical bases supported for the pid of
20075 the --attach command line argument.
20077 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20079 * win32-low.c (win32_attach): Call OpenProcess before
20080 DebugActiveProcess, not after. Add last error output to error
20083 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20085 * win32-low.c (win32_get_thread_context)
20086 (win32_set_thread_context): New functions.
20087 (thread_rec): Use win32_get_thread_context.
20088 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20089 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20092 2007-12-03 Leo Zayas
20093 Pedro Alves <pedro_alves@portugalmail.pt>
20095 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20097 (child_add_thread): Minor cleanup.
20098 (child_continue): Resume artificially suspended threads before
20099 calling ContinueDebugEvent.
20100 (suspend_one_thread): New.
20101 (fake_breakpoint_event): New.
20102 (get_child_debug_event): Change return type to int. Check here if
20103 gdb sent an interrupt request. If a soft interrupt was requested,
20104 fake a breakpoint event. Return 0 if there is no event to handle,
20106 (win32_wait): Don't check here if gdb sent an interrupt request.
20107 Ensure there is a valid event to handle.
20108 (win32_request_interrupt): Add soft interruption method as last
20111 2007-12-03 Leo Zayas
20112 Pedro Alves <pedro_alves@portugalmail.pt>
20114 * win32-low.h (win32_thread_info): Add descriptions to the
20115 structure members. Replace `suspend_count' counter by a
20117 * win32-low.c (thread_rec): Update condition of when to get the
20118 context from the inferior. Rely on ContextFlags being set if it
20119 has already been retrieved. Only suspend the inferior thread if
20120 we haven't already. Warn if that fails.
20121 (continue_one_thread): s/suspend_count/suspended/. Only call
20122 ResumeThread once. Warn if that fails.
20124 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20126 * win32-low.c (win32_wait): Don't read from the inferior when it
20127 has already exited.
20129 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20131 * Makefile.in (win32_low_h): New variable.
20132 (win32-low.o): Add dependency on $(win32_low_h).
20133 (win32-arm-low.o, win32-i386-low.o): New rules.
20135 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20137 * hostio.c: Correct copyright year.
20139 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20141 * Makefile.in (OBS): Add hostio.o.
20142 (hostio.o): New rule.
20143 * server.h (handle_vFile): Declare.
20144 * hostio.c: New file.
20145 * server.c (handle_v_requests): Take packet_len and new_packet_len
20146 for binary packets. Call handle_vFile.
20147 (main): Update call to handle_v_requests.
20149 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20151 * linux-low.c: Include <sched.h>.
20153 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20155 * linux-low.c (linux_tracefork_grandchild): New.
20156 (linux_tracefork_child): Use clone.
20157 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20159 2007-10-31 Joel Brobecker <brobecker@adacore.com>
20161 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20163 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20165 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20167 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20169 * inferiors.c (change_inferior_id): Delete.
20170 (add_pid_to_list, pull_pid_from_list): New.
20171 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20172 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20173 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20174 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20175 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20176 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20177 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20178 (using_threads): Always set to 1.
20179 (handle_extended_wait): New.
20180 (add_process): Do not set TID.
20181 (linux_create_inferior): Set must_set_ptrace_flags.
20182 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20183 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20184 (linux_thread_alive): Rename TID argument to LWPID.
20185 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20186 (linux_wait_for_event): Do not use TID or check using_threads. Update
20187 call to dead_thread_notify. Call handle_extended_wait.
20188 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20189 (send_sigstop): Delete sigstop_sent.
20190 (wait_for_sigstop): Avoid TID.
20191 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20192 (linux_test_for_tracefork): New.
20193 (linux_lookup_signals): Use thread_db_active and
20194 linux_supports_tracefork_flag.
20195 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20196 * linux-low.h (get_process_thread): Avoid TID.
20197 (struct process_ifo): Move thread_known and tid to the end. Remove
20199 (linux_attach_lwp, thread_db_init): Update prototypes.
20200 * server.h (change_inferior_id): Delete prototype.
20201 (add_pid_to_list, pull_pid_from_list): New prototypes.
20202 * thread-db.c (thread_db_use_events): New.
20203 (find_first_thread): Rename to...
20204 (find_one_thread): ...this. Update callers and messages. Do not
20205 call fatal. Check thread_db_use_events. Do not call
20206 change_inferior_id or new_thread_notify.
20207 (maybe_attach_thread): Update. Do not call new_thread_notify.
20208 (thread_db_init): Set thread_db_use_events. Check use_events.
20209 * utils.c (fatal, warning): Correct message prefix.
20211 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20213 * Makefile.in (clean): Remove new files.
20214 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20215 (powerpc-64.o, powerpc-64.c): New rules.
20216 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20217 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20219 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20221 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20222 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20223 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20224 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20225 (target_regsets): Add AltiVec and SPE register sets.
20226 * configure.ac: Check for AltiVec and SPE.
20227 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20228 (ppc_fill_vrregset, ppc_store_vrregset): New.
20229 (target_regsets): Add AltiVec register set.
20230 * configure: Regenerated.
20232 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20234 * linux-low.c (O_LARGEFILE): Define.
20235 (linux_read_memory): Use /proc/PID/mem.
20236 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20237 * configure, config.in: Regenerated.
20239 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20241 * linux-low.c (linux_wait_for_event): Do not pass signals while
20244 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20246 * win32-low.c (create_process): New.
20247 (win32_create_inferior): Use create_process instead of
20248 CreateProcess. If create_process failed retry appending an ".exe"
20249 suffix. Store the GetLastError result immediatelly after
20250 create_process calls and use it on the call to error.
20252 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20254 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20256 2007-08-23 Joel Brobecker <brobecker@adacore.com>
20258 * configure.ac: Switch license to GPLv3.
20260 2007-08-01 Michael Snyder <msnyder@access-company.com>
20262 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20264 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20266 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20268 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20269 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20270 CloseToolhelp32Snapshot.
20271 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20272 CloseToolhelp32Snapshot.
20274 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
20276 * server.c (main): Check for inferior exit before main loop.
20278 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20280 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20281 instead of on tmp_desc.
20283 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20284 Daniel Jacobowitz <dan@codesourcery.com>
20286 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20287 (add_thread): Minor cleanups.
20288 (clear_inferiors): Move lower in the file. Clear the DLL
20290 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20291 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20292 (xml_escape_text): New.
20293 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20295 (handle_v_cont): Report errors.
20296 (gdbserver_version): Update.
20297 (main): Correct size of own_buf. Do not report initial DLL events.
20298 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20299 (unloaded_dll, xml_escape_text): New.
20300 * win32-low.c (enum target_waitkind): Update comments.
20301 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20302 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20303 (win32_EnumProcessModules, win32_GetModuleInformation)
20304 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20305 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20306 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20307 (win32_Module32First, win32_Module32Next, load_toolhelp)
20308 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20309 (get_child_debug_event): Handle DLL events.
20310 (win32_wait): Likewise.
20312 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20314 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20315 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20317 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20319 * win32-low.c (handle_output_debug_string): Ignore event if not
20322 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20324 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20326 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20328 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20330 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20332 * inferiors.c (change_inferior_id): Add comment.
20333 * linux-low.c (check_removed_breakpoint): Add an early
20334 prototype. Improve debug output.
20335 (linux_attach): Doc update.
20336 (linux_detach_one_process, linux_detach): Clean up before releasing
20338 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20339 * linux-low.h (struct process_info): Doc improvement.
20340 * mem-break.c (delete_all_breakpoints): New.
20341 * mem-break.h (delete_all_breakpoints): New prototype.
20342 * thread-db.c (find_first_thread): New.
20343 (thread_db_create_event): Call it instead of
20344 thread_db_find_new_threads. Clean up unused variables.
20345 (maybe_attach_thread): Remove first thread handling.
20346 (thread_db_find_new_threads): Use find_first_thread.
20347 (thread_db_get_tls_address): Likewise.
20349 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20351 * thread-db.c (thread_db_find_new_threads): Add prototype.
20352 (thread_db_create_event): Check for the main thread before adding
20354 (maybe_attach_thread): Only enable event reporting if TID == 0.
20355 (thread_db_get_tls_address): Check for new threads.
20357 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20359 * linux-low.c (linux_create_inferior): Try execv before execvp.
20360 * spu-low.c (spu_create_inferior): Likewise.
20362 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20364 * linux-low.c (linux_create_inferior): Change execv to execvp.
20365 * spu-low.c (spu_create_inferior): Likewies.
20367 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20369 * Makefile.in (clean): Clean new files instead of deleted ones.
20370 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20371 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20373 * configure.srv: Specify XML files and new regformats for MIPS and
20375 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20376 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20377 an entry for the restart register.
20378 (mips_cannot_fetch_register, mips_cannot_store_register)
20379 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20380 register names to match the XML descriptions.
20381 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20382 restart register instead of $0.
20384 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20385 Markus Deuling <deuling@de.ibm.com>
20387 * remote-utils.c (decode_xfer_write): New function.
20388 * server.h (decode_xfer_write): Add prototype.
20389 * server.c (handle_query): Add PACKET_LEN argument. Support
20390 qXfer:spu:read and qXfer:spu:write packets.
20391 (main): Pass packet_len to handle_query.
20392 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20393 * target.h (target_ops): Add qxfer_spu.
20395 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20397 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20398 accessing non-seekable spufs files.
20400 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20402 * server.c (handle_query): Add reply for qC packet.
20404 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20405 Leo Zayas <lerele@champenstudios@com>
20407 * server.h (check_remote_input_interrupt_request): New function.
20408 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20409 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20410 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20411 (check_remote_input_interrupt_request): New function.
20412 * server.h (check_remote_input_interrupt_request): Declare.
20413 * win32-low.c (winapi_DebugBreakProcess,
20414 winapi_GenerateConsoleCtrlEvent): New typedefs.
20415 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20417 (win32_wait): Check for remote interrupt request
20418 with check_remote_input_interrupt_request.
20419 (win32_request_interrupt): New function.
20420 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20422 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20424 * win32-low.c (debug_registers_changed,
20425 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20426 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20427 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20428 (thread_rec): Get context using the low target.
20429 (child_add_thread): Call thread_added on the low target,
20430 which does the same thing.
20432 (do_initial_child_stuff): Remove debug registers references.
20433 Set context using the low target. Resume threads after
20434 setting the contexts.
20435 (child_continue): Remove dead variable. Remove debug
20436 registers references.
20437 (child_fetch_inferior_registers): Go through the low target.
20438 (do_child_store_inferior_registers): Remove.
20439 (child_store_inferior_registers): Go through the low target.
20440 (win32_resume): Remove debug registers references.
20441 Set context using the low target.
20442 (handle_exception): Change return type to void. Don't record
20443 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20444 first chance exception.
20445 (get_child_debug_event): Change return type to void. Remove
20446 goto loop. Always return after waiting for debug event.
20447 (win32_wait): Convert to switch statement. Handle spurious
20450 * win32-i386-low.c (debug_registers_changed,
20451 debug_registers_used): New.
20452 (initial_stuff): Rename to ...
20453 (i386_initial_stuff): ... this. Clear debug registers
20455 (store_debug_registers): Delete.
20456 (i386_get_thread_context): New.
20457 (load_debug_registers): Delete.
20458 (i386_set_thread_context): New.
20459 (i386_thread_added): New.
20460 (single_step): Rename to ...
20461 (i386_single_step): ... this.
20462 (do_fetch_inferior_registers): Rename to ...
20463 (i386_fetch_inferior_register): ... this.
20464 (i386_store_inferior_register): New.
20465 (the_low_target): Adapt to new interface.
20467 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20468 (arm_get_thread_context): New.
20469 (arm_set_thread_context): New.
20471 (do_fetch_inferior_registers): Rename to ...
20472 (arm_fetch_inferior_register): ... this.
20473 (arm_store_inferior_register): New.
20474 (arm_wince_breakpoint): Reimplement as unsigned long.
20475 (arm_wince_breakpoint_len): Define.
20476 (the_low_target): Adapt to new interface.
20478 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20479 load_debug_registers. Add get_thread_context, set_thread_context,
20480 thread_added and store_inferior_register. Rename
20481 fetch_inferior_registers to fetch_inferior_register.
20482 (regptr): Remove declaration.
20484 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20486 * linux-low.c (linux_detach): Change return type to int. Return 0.
20487 * spu-low.c (spu_detach): Likewise.
20489 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20491 * target.h (target_ops): Change return type of detach to int.
20493 (join_inferior): New.
20494 * server.c (main): Don't skip detach support on mingw32.
20495 If the inferior doesn't support detaching return error.
20496 Call join_inferior instead of using waitpid.
20497 * linux-low.c (linux_join): New.
20498 (linux_target_op): Add linux_join.
20499 * spu-low.c (spu_join): New.
20500 (spu_target_ops): Add spu_join.
20501 * win32-low.c (win32_detach): Adapt to new interface.
20502 Reopen current_process_handle before detaching. Issue a child
20503 resume before detaching.
20505 (win32_target_op): Add win32_join.
20507 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20509 * win32-low.c (win32-attach): Fix return value.
20510 * target.h (target_ops): Describe ATTACH return values.
20512 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20514 * win32-low.c (GETPROCADDRESS): Define.
20515 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20516 (winapi_DebugSetProcessKillOnExit): Likewise.
20517 (win32_create_inferior): Force usage of ansi CreateProcessA.
20518 (win32_attach): Use GETPROCADDRESS.
20519 (win32_detach): Likewise.
20521 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20523 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20525 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20527 * win32-low.c: Commit leftover changes from 2007-03-29.
20529 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20531 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20532 fields short instead of int. Add explicit padding.
20533 (i387_cache_to_fsave): Remove unnecessary casts.
20534 (i387_fsave_to_cache): Doc fix.
20535 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20537 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20539 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20540 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20542 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20544 * configure.srv (arm*-*-mingw32ce*): Move near the other
20547 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20549 * configure.ac: Add errno checking.
20550 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20551 sys/file.h and malloc.h.
20552 (AC_CHECK_DECLS): Add perror.
20553 (srv_mingwce): Handle.
20554 * configure.srv (i[34567]86-*-cygwin*): Add
20555 win32-i386-low.o to srv_tgtobj.
20556 (i[34567]86-*-mingw*): Likewise.
20557 (arm*-*-mingw32ce*): Add case.
20558 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20559 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20560 [__MINGW32CE__] (strerror): New function.
20561 [__MINGW32CE__] (errno): Define to GetLastError.
20562 [__MINGW32CE__] (COUNTOF): New macro.
20563 (remote_open): Remove extra close call.
20564 * mem-break.c (delete_breakpoint_at): New function.
20565 * mem-break.h (delete_breakpoint_at): Declare.
20566 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20567 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20568 [USE_WIN32API] (read, write): Add char* casts.
20569 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20570 * server.h: Include wincecompat.h on Windows CE.
20571 [HAVE_ERRNO_H]: Check.
20572 (perror): Declare if not declared.
20573 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20574 (perror_with_name): Remove errno declaration.
20575 * wincecompat.h: New.
20576 * wincecompat.c: New.
20577 * win32-low.h: New.
20578 * win32-arm-low.c: New.
20579 * win32-i386-low.c: New.
20580 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20581 (OUTMSG2): Make it safe.
20583 (COUNTOF): New macro.
20584 (NUM_REGS): Get it from the low target.
20585 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20586 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20587 (thread_rec): Let low target handle debug registers.
20588 (child_add_thread): Likewise.
20589 (child_init_thread_list): Likewise.
20590 (continue_one_thread): Likewise.
20592 (do_child_fetch_inferior_registers): Move to ...
20593 * win32-i386-low.c: ... here, and rename to ...
20594 (do_fetch_inferior_registers): ... this.
20595 * win32-low.c (child_fetch_inferior_registers):
20596 Go through the low target.
20597 (do_child_store_inferior_registers): Use regptr.
20598 (strwinerror): New function.
20599 (win32_create_inferior): Handle Windows CE.
20600 Use strwinerror instead of strerror on Windows error
20601 codes. Add program to the error output.
20602 Don't close the main thread handle on Windows CE.
20603 (win32_attach): Use coredll.dll on Windows CE.
20604 (win32_kill): Close current process and current
20606 (win32_detach): Use coredll.dll on Windows CE.
20607 (win32_resume): Let low target handle debug registers, and
20609 (handle_exception): Add/Remove initial breakpoint. Avoid
20610 non-existant WSTOPSIG on Windows CE.
20611 (win32_read_inferior_memory): Cast to remove warning.
20612 (win32_arch_string): Go through the low target.
20613 (initialize_low): Call set_breakpoint_data with the low
20614 target's breakpoint.
20615 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20616 FOP_REGNUM, mappings): Move to ...
20617 * win32-i386-low.c: ... here.
20618 * win32-low.c (win32_thread_info): Move to ...
20619 * win32-low.h: ... here.
20620 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20621 win32-arm-low.c and wincecompat.c.
20622 (all:): Add $EXEEXT.
20623 (install-only:): Likewise.
20624 (gdbserver:): Likewise.
20625 (gdbreplay:): Likewise.
20626 * config.in: Regenerate.
20627 * configure: Regenerate.
20629 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20631 * win32-low.c: Rename typedef thread_info to
20632 win32_thread_info throughout.
20634 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20636 * win32-i386-low.c: Rename to ...
20637 * win32-low.c: ... this.
20638 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20639 * Makefile.in: Likewise.
20641 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20643 * remote-utils.c (monitor_output): Constify msg parameter.
20644 * server.h (monitor_output): Likewise.
20645 * win32-i386-low.c (handle_output_debug_string): New.
20646 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20647 handle_output_debug_string.
20648 (get_child_debug_event): Likewise.
20650 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20652 * server.c (main): Correct strtoul check.
20654 2007-03-27 Jon Ringle <jon@ringle.org>
20656 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20658 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20660 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20662 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20664 * terminal.h: Check HAVE_SGTTY_H.
20666 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
20668 * remote-utils.c (remote_open): Print out the assigned port number.
20670 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20672 * remote-utils.c (monitor_output): New function.
20673 * server.c (debug_threads): Define here.
20674 (monitor_show_help): New function.
20675 (handle_query): Handle qRcmd.
20676 (main): Do not handle 'd' packet.
20677 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20678 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20681 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20683 * Makefile.in (EXEEXT): New.
20684 (clean): Use $(EXEEXT).
20686 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20688 * target.h (target_ops): Rename send_signal to request_interrupt,
20689 and remove enum target_signal parameter.
20690 * linux-low.c (linux_request_interrupt): Rename from
20691 linux_send_signal, and always send SIGINT.
20692 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20693 and always send SIGINT.
20694 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20696 (input_interrupt): Likewise.
20698 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20700 * server.c (get_features_xml): Check if target implemented
20702 * win32-i386-low.c (win32_arch_string): New.
20703 (win32_target_ops): Add win32_arch_string as arch_string member.
20705 2007-02-22 Markus Deuling <deuling@de.ibm.com>
20707 * spu-low.c (spu_arch_string): New.
20708 (spu_target_ops): Add spu_arch_string.
20710 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20712 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20713 * configure.ac: Do not check for terminal.h.
20714 * configure, config.in: Regenerated.
20716 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20718 * Makefile.in (OBS): Add $(XML_BUILTIN).
20719 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20721 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20722 (arm-with-iwmmxt.c): New.
20723 * config.in, configure: Regenerate.
20724 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20725 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20726 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20727 (arm*-*-linux*): Add iWMMXt and regset support.
20728 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20729 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20730 (arm_store_wmmxregset, target_regsets): New.
20731 * server.c (get_features_xml): Take annex argument. Check builtin
20733 (handle_query): Handle multiple annexes.
20735 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20737 * remote-utils.c [USE_WIN32API] (read, write): Define.
20738 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20741 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20743 * linux-i386-low.c (the_low_target): Set arch_string.
20744 * linux-x86-64-low.c (the_low_target): Likewise.
20745 * linux-low.c (linux_arch_string): New.
20746 (linux_target_ops): Add it.
20747 * linux-low.h (struct linux_target_ops): Add arch_string.
20748 * server.c (write_qxfer_response): Use const void * for DATA.
20749 (get_features_xml): New.
20750 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20751 * target.h (struct target_ops): Add arch_string method.
20753 2007-01-03 Denis Pilat <denis.pilat@st.com>
20754 Daniel Jacobowitz <dan@codesourcery.com>
20756 * linux-low.c (linux_kill): Handle being called with no threads.
20757 * win32-i386-low.c (win32_kill): Likewise.
20758 (get_child_debug_event): Clear current_process_handle.
20760 2006-12-30 Denis PILAT <denis.pilat@st.com>
20761 Daniel Jacobowitz <dan@codesourcery.com>
20763 * remote-utils.c (remote_open): Check the type of specified
20764 serial port devices before opening them.
20765 * server.c (main): Kill the inferior if an error occurs during
20766 the first remote_open.
20768 2006-12-05 Markus Deuling <deuling@de.ibm.com>
20770 * README: Update supported targets.
20772 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20774 * Makefile.in (clean): Remove reg-mips64.c.
20775 (reg-mips64.c, reg-mips64.o): New rules.
20776 * configure.srv: Handle mips64. Include regset support for mips.
20777 * linux-mips-low.c (union mips_register): New.
20778 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20779 (mips_breakpoint, mips_breakpoint_at): Use int.
20780 (mips_collect_register, mips_supply_register)
20781 (mips_collect_register_32bit, mips_supply_register_32bit)
20782 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20783 (mips_store_fpregset, target_regsets): New.
20784 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20786 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20788 * configure.srv: Add target "spu*-*-*".
20789 * Makefile.in (clean): Remove reg-spu.c.
20790 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20791 * spu-low.c: New file.
20793 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20795 * configure.ac: Correct td_thr_tls_get_addr test.
20796 * configure: Regenerated.
20798 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20800 * linux-low.c (linux_wait_for_event): Reformat. Use the
20801 pass_signals array.
20802 * remote-utils.c (decode_address_to_semicolon): New.
20803 * server.c (pass_signals, handle_general_set): New.
20804 (handle_query): Mention QPassSignals for qSupported.
20805 (main): Call handle_general_set.
20806 * server.h (pass_signals, decode_address_to_semicolon): New.
20808 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20810 * server.c (handle_query): Correct error handling for read_auxv.
20812 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20814 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20815 and srv_linux_thread_db to yes.
20816 * linux-s390-low.c (s390_fill_gregset): New function.
20817 (target_regsets): Define data structure.
20819 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20821 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20822 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20823 * config.in, configure: Regenerated.
20824 * inferiors.c (gdb_id_to_thread): New function.
20825 (gdb_id_to_thread_id): Use it.
20826 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20827 * linux-low.h (struct process_info): Add th member.
20828 (thread_db_get_tls_address): New prototype.
20829 * remote-utils.c (decode_address): Make non-static.
20830 * server.c (handle_query): Handle qGetTLSAddr.
20831 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20832 * target.h (struct target_ops): Add get_tls_address.
20833 * thread-db.c (maybe_attach_thread): Save the thread handle.
20834 (thread_db_get_tls_address): New.
20836 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20838 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20839 (linux_resume_one_process): Take a siginfo_t *. Update all
20840 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20841 (struct pending_signals): Add a siginfo_t.
20842 (linux_wait_for_process): Always set last_status.
20843 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20844 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20845 * linux-low.h (struct process_info): Add last_status.
20847 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20849 * remote-utils.c (try_rle): New function.
20850 (putpkt_binary): Use it.
20852 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20854 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20855 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20856 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20857 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20858 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20861 2006-08-08 Richard Sandiford <richard@codesourcery.com>
20863 * server.c (terminal_fd): New variable.
20864 (old_foreground_pgrp): Likewise.
20865 (restore_old_foreground_pgrp): New function.
20866 (start_inferior): Record the terminal file descriptor in terminal_fd
20867 and its original foreground group in old_foreground_pgrp. Register
20868 restore_old_foreground_pgrp with atexit().
20870 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20872 * server.c (handle_query): Correct qPart to qXfer.
20874 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20876 * configure.ac: Check for more headers which are missing on
20877 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20878 * configure.srv: Add Cygwin and mingw32.
20879 * remote-utils.c: Don't include headers unconditionally which
20880 are missing on mingw32. Include <winsock.h> for mingw32.
20881 (remote_open): Adjust for mingw32 support. Flush
20882 standard error after writing to it.
20883 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20884 (unblock_async_io, enable_async_io, disable_async_io)
20885 (readchar, getpkt): Update for Winsock support.
20886 (prepare_resume_reply): Expect a protocol signal number.
20887 * server.c: Disable <sys/wait.h> on mingw32.
20888 (start_inferior): Adjust for mingw32 support. Flush
20889 standard error after writing to it.
20890 (attach_inferior): Likewise. Use protocol signal
20892 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20894 * win32-i386-low.c: New file.
20895 * Makefile.in (XM_CLIBS): Set.
20896 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20897 (win32-i386-low.o): New dependency rule.
20898 * linux-low.c (linux_wait): Use target signal numbers.
20899 * target.h (struct target_ops): Doc fix.
20900 * server.h (target_signal_to_name): New prototype.
20901 * gdbreplay.c: Don't include headers unconditionally which
20902 are missing on mingw32. Include <winsock.h> for mingw32.
20903 (remote_close, remote_open): Adjust for Winsock support.
20904 * configure, config.in: Regenerated.
20906 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20908 * server.c (decode_xfer_read, write_qxfer_response): New.
20909 (handle_query): Take a packet length argument. Handle
20910 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20911 the qSupported response.
20912 (main): Update call to handle_query.
20914 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20916 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20917 (putpkt_binary): Renamed from putpkt and adjusted for binary
20919 (putpkt): New wrapper for putpkt_binary.
20920 (readchar): Don't mask off the high bit.
20921 (decode_X_packet): New function.
20922 * server.c (main): Call putpkt_binary if a handler sets the packet
20923 length. Save the length of the incoming packet. Handle 'X'.
20924 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20926 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20928 * server.c (handle_query): Handle qSupported.
20930 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20932 * remote-utils.c (all_symbols_looked_up): New variable.
20933 (look_up_one_symbol): Check it.
20934 * server.h (look_up_one_symbol): New declaration.
20935 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20937 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20939 * Makefile.in (linux-arm-low.o): Update dependencies.
20940 * linux-arm-low.c: Include "gdb_proc_service.h".
20941 (PTRACE_GET_THREAD_AREA): Define.
20942 (ps_get_thread_area): New function.
20944 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20946 * configure.srv (m68k*-*-uclinux*): New target.
20947 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20948 (linux_resume_one_process): Remove extraneous cast.
20949 (linux_read_offsets): New.
20950 (linux_target_op): Add linux_read_offsets on mmuless systems.
20951 * server.c (handle_query): Add qOffsets logic.
20952 * target.h (struct target_ops): Add read_offsets.
20954 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20956 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20957 (PTRACE_GET_THREAD_AREA): Define.
20958 (ps_get_thread_area): New function.
20959 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20960 (linux-x86-64-low.o): Update.
20962 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20964 * configure.ac: Remove checks for prfpregset_t.
20965 * gdb_proc_service.h: New file.
20966 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20967 new "gdb_proc_service.h".
20968 * proc-service.c: Likewise.
20969 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20970 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20971 * Makefile.in (gdb_proc_service_h): Updated.
20972 * configure, config.in: Regenerated.
20974 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20976 * remote-utils.c (prepare_resume_reply): Move declaration
20977 of gdb_id_from_wait to the top of the block.
20979 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
20981 * linux-low.c (regsets_store_inferior_registers): Read the regset
20982 from the target before filling it.
20984 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20986 * server.c (attach_inferior): Return SIGTRAP for a successful
20989 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
20991 * Makefile.in (OBS): Add version.o.
20992 (STAGESTUFF): Delete.
20993 (version.o): Add dependencies.
20994 (version.c): Replace rule.
20995 (clean): Remove version.c.
20996 * server.c (gdbserver_version): New.
20997 (gdbserver_usage): Use printf.
20998 (main): Handle --version and --help.
20999 * server.h (version, host_name): Add declarations.
21001 2005-12-23 Eli Zaretskii <eliz@gnu.org>
21013 * linux-x86-64-low.c:
21015 * linux-s390-low.c:
21016 * linux-ppc64-low.c:
21018 * linux-mips-low.c:
21019 * linux-m68k-low.c:
21020 * linux-m32r-low.c:
21023 * linux-ia64-low.c:
21024 * linux-i386-low.c:
21025 * linux-crisv32-low.c:
21037 * gdbserver.1: Add (C) after Copyright. Update the FSF
21040 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21042 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21043 (arm_breakpoint_at): Recognize both breakpoints.
21044 (the_low_target): Use the correct breakpoint instruction.
21046 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21048 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21049 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21050 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21051 (the_low_target): Update.
21053 2005-10-25 Andreas Schwab <schwab@suse.de>
21055 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21057 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21058 (ia64_num_regs): Reduce to 462.
21060 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21062 * acinclude.m4: Correct quoting.
21063 * aclocal.m4: Regenerated.
21065 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21066 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21067 (thread_db_init): Call thread_db_err_str.
21068 * configure.ac: Check for TD_VERSION.
21069 * config.in, configure: Regenerated.
21071 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21073 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21075 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21077 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21078 is not available. Define HAVE_PTRACE_GETREGS if it is.
21079 * config.in, configure: Regenerated.
21080 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21081 * linux-i386-low.c, linux-m68k-low.c: Update to use
21082 HAVE_PTRACE_GETREGS.
21083 * linux-low.c (regsets_fetch_inferior_registers)
21084 (regsets_store_inferior_registers): Only return 0 if we processed
21086 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21087 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21089 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21091 * inferiors.c (struct thread_info): Add gdb_id.
21092 (add_thread): Add gdb_id argument.
21093 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21094 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21095 calls to add_thread.
21096 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21097 * server.c (handle_query): Use thread_to_gdb_id.
21098 (handle_v_cont, main): Use gdb_id_to_thread_id.
21099 * server.h (add_thread): Update prototype.
21100 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21103 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21105 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21106 left-padded registers.
21107 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21108 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21110 2005-07-01 Steve Ellcey <sje@cup.hp.com>
21112 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21113 * configure: Regenerate.
21114 * config.in: Regenerate.
21115 * server.h (NEED_DECLARATION_STRERROR):
21116 Replace with !HAVE_DECL_STRERROR.
21118 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21120 * linux-low.c (linux_wait, linux_send_signal): Don't test
21121 an unsigned long variable for > 0 if it could be MAX_ULONG.
21122 * server.c (myresume): Likewise.
21123 * target.c (set_desired_inferior): Likewise.
21125 2005-06-13 Mark Kettenis <kettenis@gnu.org>
21127 * configure.ac: Simplify and improve check for socklen_t.
21128 * configure, config.in: Regenerate.
21130 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21132 * acconfig.h: Remove.
21133 * configure.ac: Add a test for socklen_t. Use three-argument
21134 AC_DEFINE throughout.
21135 * config.in: Regenerated using autoheader 2.59.
21136 * configure: Regenerated.
21138 * gdbreplay.c (socklen_t): Provide a default.
21139 (remote_open): Use socklen_t.
21140 * remote-utils.c (socklen_t): Provide a default.
21141 (remote_open): Use socklen_t.
21142 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21145 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21147 * linux-low.c (linux_read_memory, linux_write_memory)
21148 (linux_read_auxv): Likewise.
21149 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21150 (check_mem_write): Likewise.
21151 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21153 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21154 (registers_from_string, register_data): Likewise.
21155 * server.c (handle_query, main): Likewise.
21156 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21157 (decode_M_packet): Likewise.
21158 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21159 * target.h (struct target_ops): Update read_memory, write_memory,
21161 (read_inferior_memory, write_inferior_memory): Update.
21162 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21163 to unsigned char *.
21164 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21165 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21166 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21167 linux-s390-low.c, linux-sh-low.c: Update for changes in
21168 read_inferior_memory and the_low_target->breakpoint.
21170 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21172 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21173 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21174 * configure.srv: Add powerpc64-*-linux*.
21175 * linux-ppc64-low.c: New file.
21177 2005-05-23 Orjan Friberg <orjanf@axis.com>
21179 * linux-cris-low.c: New file with support for CRIS.
21180 * linux-crisv32-low.c: Ditto for CRISv32.
21181 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21182 (clean): Add reg-cris.c and reg-crisv32.c.
21183 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
21184 reg-crisv32.o, and reg-crisv32.c to make rules.
21185 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21186 recognized targets.
21188 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21190 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21191 of sizeof (PTRACE_XFER_TYPE).
21192 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21194 2005-05-12 Orjan Friberg <orjanf@axis.com>
21196 * target.h (struct target_ops): Add insert_watchpoint,
21197 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21198 pointers for hardware watchpoint support.
21199 * linux-low.h (struct linux_target_ops): Ditto.
21200 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21201 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21202 to linux_target_ops.
21203 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21205 * server.c (main): Recognize 'Z' and 'z' packets.
21207 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21209 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21210 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21211 (the_low_target): Add new members.
21213 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21215 * proc-service.c (ps_lgetregs): Search all_processes instead of
21218 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21220 * server.c (start_inferior): Change return type to int.
21221 (attach_inferior): Change sigptr to int *.
21222 (handle_v_cont, handle_v_requests): Change signal to int *.
21223 (main): Change signal to int.
21225 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
21227 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21228 * configure.srv: Add m32r*-*-linux*.
21229 * linux-m32r-low.c: New file.
21231 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21233 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21235 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21237 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21238 Take unsigned long arguments for PIDs.
21239 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21240 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21241 (wait_for_sigstop, linux_resume_one_process)
21242 (regsets_fetch_inferior_registers, linux_send_signal)
21243 (linux_read_auxv): Likewise. Update the types of variables holding
21244 PIDs. Update format string specifiers.
21245 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21246 * remote-utils.c (prepare_resume_reply): Likewise.
21247 * server.c (cont_thread, general_thread, step_thread)
21248 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21250 (handle_query): Update format specifiers.
21251 (handle_v_cont, main): Use strtoul for thread IDs.
21252 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21253 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21254 (general_thread, step_thread, thread_from_wait)
21255 (old_thread_from_wait): Update.
21256 * target.h (struct thread_resume): Use unsigned long for THREAD.
21257 (struct target_ops): Use unsigned long for arguments to attach and
21260 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21262 * acinclude.m4: Include bfd/bfd.m4 directly.
21263 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21264 <agriffis@toolchain.org>.
21265 * aclocal.m4, configure: Regenerated.
21267 2005-01-07 Andrew Cagney <cagney@gnu.org>
21269 * configure.ac: Rename configure.in, require autoconf 2.59.
21270 * configure: Re-generate.
21272 2004-12-08 Daniel Jacobowitz <dan@debian.org>
21274 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21275 LIBS when finished.
21276 * aclocal.m4: Regenerated.
21277 * configure: Regenerated.
21279 2004-11-21 Andreas Schwab <schwab@suse.de>
21281 * linux-m68k-low.c (m68k_num_gregs): Define.
21282 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21283 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21284 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21285 (m68k_breakpoint_at): New. Add to the_low_target.
21287 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21288 srv_linux_thread_db to yes.
21290 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21292 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21293 (ARCH_SET_FS): Likewise.
21294 (ARCH_GET_FS): Likewise.
21295 (ARCH_GET_GS): Likewise.
21297 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21299 * linux-i386-low.c (ps_get_thread_area): New.
21300 * linux-x86-64-low.c (ps_get_thread_area): New.
21301 * linux-low.c: Include <sys/syscall.h>.
21302 (linux_kill_one_process): Don't kill the first thread here.
21303 (linux_kill): Kill the first thread here.
21304 (kill_lwp): New function.
21305 (send_sigstop, linux_send_signal): Use it.
21306 * proc-service.c: Clean up #ifdefs.
21307 (fpregset_info): Delete.
21308 (ps_lgetregs): Update and enable implementation.
21309 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21311 * remote-utils.c (struct sym_cache, symbol_cache): New.
21312 (input_interrupt): Print a clearer message.
21313 (async_io_enabled): New variable.
21314 (enable_async_io, disable_async_io): Use it. Update comments.
21315 (look_up_one_symbol): Use the symbol cache.
21316 * thread-db.c (thread_db_look_up_symbols): New function.
21317 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21319 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21321 * configure.in: Test for -rdynamic.
21322 * configure: Regenerated.
21323 * Makefile (INTERNAL_LDFLAGS): New.
21324 (gdbserver, gdbreplay): Use it.
21326 2004-09-02 Andrew Cagney <cagney@gnu.org>
21328 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21330 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21332 * linux-low.c (linux_wait): Clear all_processes list also.
21334 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21336 * linux-low.c: Include <errno.h>. Remove extern declaration of
21339 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21341 * gdbreplay.c, server.h, utils.c: Update copyright years.
21343 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21345 * server.c (main): Print child status or termination signal from
21346 variable 'signal', not 'sig'.
21348 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21350 * linux-low.c (linux_read_memory): Change return type to
21351 int. Check for and return error from ptrace().
21352 * target.c (read_inferior_memory): Change return type to int. Pass
21353 back return status from the_target->read_memory().
21354 * target.h (struct target_ops): Adapt *read_memory() prototype.
21356 (read_inferior_memory): Adapt prototype.
21357 * server.c (main): Return an error packet if
21358 read_inferior_memory() returns an error.
21360 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21362 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21363 Unify with other clean targets.
21365 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21367 * server.c (handle_v_cont): Call set_desired_inferior.
21369 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21371 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21373 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21375 * linux-low.c (linux_wait): Unblock async I/O.
21376 (linux_resume): Block and enable async I/O.
21377 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21378 * server.h (block_async_io, unblock_async_io): Add prototypes.
21380 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21382 * remote-utils.c (remote_open): Print a status notice after
21383 opening a TCP port.
21384 * server.c (attach_inferior): Print a status notice after
21387 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21389 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21391 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21393 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21395 * server.c, target.h: Update copyright years.
21397 2004-02-25 Roland McGrath <roland@redhat.com>
21399 * target.h (struct target_ops): New member `read_auxv'.
21400 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21401 * linux-low.c (linux_read_auxv): New function.
21402 (linux_target_ops): Initialize `read_auxv' member to that.
21404 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21406 Committed by Jim Blandy <jimb@redhat.com>.
21408 * linux-s390-low.c (s390_num_regs): Update.
21409 (s390_regmap): Remove control registers. Use __s390x__ predefine
21410 instead of GPR_SIZE to distiguish s390 and s390x targets.
21412 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21414 * linux-low.c: Update copyright year.
21415 (check_removed_breakpoint): Clear pending_is_breakpoint.
21416 (linux_set_resume_request, linux_queue_one_thread)
21417 (resume_status_pending_p): New functions.
21418 (linux_continue_one_thread): Use process->resume.
21419 (linux_resume): Only resume threads if there are no pending events.
21420 * linux-low.h (struct process_info): Add resume request
21423 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21425 * regcache.c (new_register_cache): Clear the allocated register
21426 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21428 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21430 * linux-low.c (linux_resume): Take a struct thread_resume *
21432 (linux_wait): Update call.
21433 (resume_ptr): New static variable.
21434 (linux_continue_one_thread): Renamed from
21435 linux_continue_one_process. Use resume_ptr.
21436 (linux_resume): Use linux_continue_one_thread.
21437 * server.c (handle_v_cont, handle_v_requests): New functions.
21438 (myresume): New function.
21439 (main): Handle 'v' case.
21440 * target.h (struct thread_resume): New type.
21441 (struct target_ops): Change argument of "resume" to struct
21443 (myresume): Delete macro.
21445 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21447 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21448 (uninstall): Support DESTDIR.
21450 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21452 * configure.srv: Add xscale*linux copy of arm*linux entry.
21454 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21456 * linux-arm-low.c (arm_reinsert_addr): New function.
21457 (the_low_target): Add arm_reinsert_addr.
21459 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21461 * mem-break.c: Remove whitespace at end of file.
21463 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21465 * configure.in: Check whether we need to prototype strerror.
21466 * server.h: Optionally prototype strerror.
21467 * gdbreplay.c (perror_with_name): Use strerror.
21468 * linux-low.c (linux_attach_lwp): Use strerror.
21469 * utils.c (perror_with_name): Use strerror.
21470 * config.in, configure: Regenerated.
21472 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21474 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21475 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21477 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21479 * Makefile.in (SFILES): Update.
21480 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21481 low-sun3.c: Remove files.
21483 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21485 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21486 (linux_detach_one_process, linux_detach): New functions.
21487 (linux_target_ops): Add linux_detach.
21488 * server.c (main): Handle 'D' packet.
21489 * target.h (struct target_ops): Add "detach" member.
21490 (detach_inferior): Define.
21492 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21494 From Kelley Cook <kelleycook@wideopenwest.com>:
21495 * configure.srv: Accept i[34567]86 variants.
21497 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21499 * linux-low.c (linux_wait_for_event): Correct comment typos.
21500 (linux_resume_one_process): Call check_removed_breakpoint.
21501 (linux_send_signal): New function.
21502 (linux_target_ops): Add linux_send_signal.
21503 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21505 * target.h (struct target_ops): Add send_signal.
21507 2003-05-29 Jim Blandy <jimb@redhat.com>
21509 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21510 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21511 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21512 away part of the register's value.
21514 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21516 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21517 (linux_wait_for_event, linux_init_signals): Likewise.
21519 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21521 * configure.in: Check for stdlib.h.
21522 * configure: Regenerated.
21523 * config.in: Regenerated.
21525 2003-01-04 Andreas Schwab <schwab@suse.de>
21527 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21529 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21531 * Makefile.in: Remove obsolete code.
21533 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21535 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21536 defined(PT_FPR0_HI).
21538 2002-11-17 Stuart Hughes <seh@zee2.com>
21540 * linux-arm-low.c (arm_num_regs): Increase.
21541 (arm_regmap): Include status register.
21543 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21545 * linux-low.c (register_addr): Remove incorrect -1 check.
21547 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21549 * linux-low.c (linux_create_inferior): Call setpgid. Return
21551 (unstopped_p, linux_signal_pid): Remove.
21552 (linux_target_ops): Remove linux_signal_pid.
21553 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21554 global instead of target method.
21555 * target.h (struct target_ops): Remove signal_pid. Update comment
21556 for create_inferior.
21557 * server.c (signal_pid): New variable.
21558 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21559 gdbserver. Set the child to be the foreground process group.
21560 (attach_inferior): Set signal_pid.
21562 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21564 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21566 2002-08-20 Jim Blandy <jimb@redhat.com>
21568 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21571 2002-08-01 Andrew Cagney <cagney@redhat.com>
21573 * Makefile.in: Make chill references obsolete.
21575 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21577 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21578 * configure: Regenerate.
21579 * config.in: Regenerate.
21581 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21583 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21584 (perror_with_name, remote_close, remote_open, expect, play): Static.
21586 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21588 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
21589 byte offsets instead of an array of indexes.
21590 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21592 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
21594 * regcache.c: Add comment.
21596 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
21598 * thread-db.c: New file.
21599 * proc-service.c: New file.
21600 * acinclude.m4: New file.
21601 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21602 proc-service.o, and thread-db.o.
21603 (linux-low.o): Add USE_THREAD_DB.
21604 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21605 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21606 * aclocal.m4: Regenerated.
21607 * config.in: Regenerated.
21608 * configure: Regenerated.
21609 * configure.in: Check for proc_service.h, sys/procfs.h,
21610 thread_db.h, and linux/elf.h headrs.
21611 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21612 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21613 Check for -lthread_db and thread support.
21614 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21615 PowerPC, and SuperH.
21616 * i387-fp.c: Constify arguments.
21617 * i387-fp.h: Likewise.
21618 * inferiors.c: (struct thread_info): Renamed from
21619 `struct inferior_info'. Remove PID member. Use generic inferior
21620 list header. All uses updated.
21621 (inferiors, signal_pid): Removed.
21622 (all_threads): New variable.
21623 (get_thread): Define.
21624 (add_inferior_to_list): New function.
21625 (for_each_inferior): New function.
21626 (change_inferior_id): New function.
21627 (add_inferior): Removed.
21628 (remove_inferior): New function.
21629 (add_thread): New function.
21630 (free_one_thread): New function.
21631 (remove_thread): New function.
21632 (clear_inferiors): Use for_each_inferior and free_one_thread.
21633 (find_inferior): New function.
21634 (find_inferior_id): New function.
21635 (inferior_target_data): Update argument type.
21636 (set_inferior_target_data): Likewise.
21637 (inferior_regcache_data): Likewise.
21638 (set_inferior_regcache_data): Likewise.
21639 * linux-low.c (linux_bp_reinsert): Remove.
21640 (all_processes, stopping_threads, using_thrads)
21641 (struct pending_signals, debug_threads, pid_of): New.
21642 (inferior_pid): Replace with macro.
21643 (struct inferior_linux_data): Remove.
21644 (get_stop_pc, add_process): New functions.
21645 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21646 Use add_process and add_thread.
21647 (linux_attach_lwp): New function, based on old linux_attach. Use
21648 add_process and add_thread. Set stop_expected for new threads.
21649 (linux_attach): New function.
21650 (linux_kill_one_process): New function.
21651 (linux_kill): Kill all LWPs.
21652 (linux_thread_alive): Use find_inferior_id.
21653 (check_removed_breakpoints, status_pending_p): New functions.
21654 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21655 Update. Use WNOHANG. Wait for cloned processes also. Update process
21656 struct for the found process.
21657 (linux_wait_for_event): New function.
21658 (linux_wait): Use it. Support LWPs.
21659 (send_sigstop, wait_for_sigstop, stop_all_processes)
21660 (linux_resume_one_process, linux_continue_one_process): New functions.
21661 (linux_resume): Support LWPs.
21662 (REGISTER_RAW_SIZE): Remove.
21663 (fetch_register): Use register_size instead. Call supply_register.
21664 (usr_store_inferior_registers): Likewise. Call collect_register.
21665 Fix recursive case.
21666 (regsets_fetch_inferior_registers): Improve error message.
21667 (regsets_store_inferior_registers): Add debugging.
21668 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21669 (unstopped_p, linux_signal_pid): New functions.
21670 (linux_target_ops): Add linux_signal_pid.
21671 (linux_init_signals): New function.
21672 (initialize_low): Call it. Initialize using_threads.
21673 * regcache.c (inferior_regcache_data): Add valid
21675 (get_regcache): Fetch registers lazily. Add fetch argument
21676 and update all callers.
21677 (regcache_invalidate_one, regcache_invalidate): New
21679 (new_register_cache): Renamed from create_register_cache.
21680 Return the new regcache.
21681 (free_register_cache): Change argument to a void *.
21682 (registers_to_string, registers_from_string): Call get_regcache
21683 with fetch flag set.
21684 (register_data): Make static. Pass fetch flag to get_regcache.
21685 (supply_register): Call get_regcache with fetch flag clear.
21686 (collect_register): Call get_regcache with fetch flag set.
21687 (collect_register_as_string): New function.
21688 * regcache.h: Update.
21689 * remote-utils.c (putpkt): Flush after debug output and use
21691 Handle input interrupts while waiting for an ACK.
21692 (input_interrupt): Use signal_pid method.
21693 (getpkt): Flush after debug output and use stderr.
21694 (outreg): Use collect_register_as_string.
21695 (new_thread_notify, dead_thread_notify): New functions.
21696 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21697 and general_thread.
21698 (look_up_one_symbol): Flush after debug output.
21699 * server.c (step_thread, server_waiting): New variables.
21700 (start_inferior): Don't use signal_pid. Update call to mywait.
21701 (attach_inferior): Update call to mywait.
21702 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21703 (main): Don't fetch/store registers explicitly. Use
21704 set_desired_inferior. Support proposed ``Hs'' packet. Update
21706 * server.h: Update.
21707 (struct inferior_list, struct_inferior_list_entry): New.
21708 * target.c (set_desired_inferior): New.
21709 (write_inferior_memory): Constify.
21710 (mywait): New function.
21711 * target.h: Update.
21712 (struct target_ops): New signal_pid method.
21713 (mywait): Removed macro, added prototype.
21715 * linux-low.h (regset_func): Removed.
21716 (regset_fill_func, regset_store_func): New.
21717 (enum regset_type): New.
21718 (struct regset_info): Add type field. Use new operation types.
21719 (struct linux_target_ops): stop_pc renamed to get_pc.
21720 Add decr_pc_after_break and breakpoint_at.
21721 (get_process, get_thread_proess, get_process_thread)
21722 (strut process_info, all_processes, linux_attach_lwp)
21723 (thread_db_init): New.
21725 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21726 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21727 (the_low_target): Add new members.
21728 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21729 (i386_store_fpxregset): Constify.
21730 (target_regsets): Add new kind identifier.
21731 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21732 (i386_set_pc): Add debugging.
21733 (i386_breakpoint_at): New function.
21734 (the_low_target): Add new members.
21735 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21736 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21737 (mips_breakpoint_at): New.
21738 (the_low_target): Add new members.
21739 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21740 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21741 (the_low_target): Add new members.
21742 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21743 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21744 (the_low_target): Add new members.
21745 * linux-x86-64-low.c (target_regsets): Add new kind
21748 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
21750 From Martin Pool <mbp@samba.org>:
21751 * server.c (gdbserver_usage): New function.
21754 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
21756 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21757 stop_at -> stop_pc.
21759 2002-05-04 Andrew Cagney <ac131313@redhat.com>
21761 * Makefile.in: Remove obsolete code.
21763 2002-04-24 Michal Ludvig <mludvig@suse.cz>
21765 * linux-low.c (regsets_fetch_inferior_registers),
21766 (regsets_store_inferior_registers): Removed cast to int from
21768 * regcache.h: Added declaration of struct inferior_info.
21770 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21772 * inferiors.c (struct inferior_info): Add regcache_data.
21773 (add_inferior): Call create_register_cache.
21774 (clear_inferiors): Call free_register_cache.
21775 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21776 * regcache.c (struct inferior_regcache_data): New.
21777 (registers): Remove.
21778 (get_regcache): New function.
21779 (create_register_cache, free_register_cache): New functions.
21780 (set_register_cache): Don't initialize the register cache here.
21781 (registers_to_string, registers_from_string, register_data): Call
21783 * regcache.h: Add prototypes.
21784 * server.h: Likewise.
21786 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21788 * mem-break.c: New file.
21789 * mem-break.h: New file.
21790 * Makefile.in: Add mem-break.o rule; update server.h
21792 * inferiors.c (struct inferior_info): Add target_data
21794 (clear_inferiors): Free target_data member if set.
21795 (inferior_target_data, set_inferior_target_data): New functions.
21796 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21797 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21798 * linux-low.c (linux_bp_reinsert): New variable.
21799 (struct inferior_linux_data): New.
21800 (linux_create_inferior): Use set_inferior_target_data.
21801 (linux_attach): Likewise. Call add_inferior.
21802 (linux_wait_for_one_inferior): New function.
21803 (linux_wait): Call it.
21804 (linux_write_memory): Add const.
21805 (initialize_low): Call set_breakpoint_data.
21806 * linux-low.h (struct linux_target_ops): Add breakpoint
21808 * server.c (attach_inferior): Remove extra add_inferior
21810 * server.h: Include mem-break.h. Update inferior.c
21812 * target.c (read_inferior_memory)
21813 (write_inferior_memory): New functions.
21814 * target.h (read_inferior_memory)
21815 (write_inferior_memory): Change macros to prototypes.
21816 (struct target_ops): Update comments. Add const to write_memory
21819 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
21821 * linux-low.c (usr_store_inferior_registers): Support
21822 registers which are allowed to fail to store.
21823 * linux-low.h (linux_target_ops): Likewise.
21824 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21825 (ppc_cannot_store_register): FPSCR may not be storable.
21827 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21829 * server.h: Include <string.h> if HAVE_STRING_H.
21830 * ChangeLog: Correct paths in last ChangeLog entry.
21832 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21834 * linux-low.h: Remove obsolete prototypes.
21835 (struct linux_target_ops): New.
21836 (extern the_low_target): New.
21837 * linux-low.c (num_regs, regmap): Remove declarations.
21838 (register_addr): Use the_low_target explicitly.
21839 (fetch_register): Likewise.
21840 (usr_fetch_inferior_registers): Likewise.
21841 (usr_store_inferior_registers): Likewise.
21842 * linux-arm-low.c (num_regs): Remove.
21843 (arm_num_regs): Define.
21844 (arm_regmap): Renamed from regmap, made static.
21845 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21847 (arm_cannot_store_register): Renamed from cannot_store_register,
21849 (the_low_target): New.
21850 * linux-i386-low.c (num_regs): Remove.
21851 (i386_num_regs): Define.
21852 (i386_regmap): Renamed from regmap, made static.
21853 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21855 (i386_cannot_store_register): Renamed from cannot_store_register,
21857 (the_low_target): New.
21858 * linux-ia64-low.c (num_regs): Remove.
21859 (ia64_num_regs): Define.
21860 (ia64_regmap): Renamed from regmap, made static.
21861 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21863 (ia64_cannot_store_register): Renamed from cannot_store_register,
21865 (the_low_target): New.
21866 * linux-m68k-low.c (num_regs): Remove.
21867 (m68k_num_regs): Define.
21868 (m68k_regmap): Renamed from regmap, made static.
21869 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21871 (m68k_cannot_store_register): Renamed from cannot_store_register,
21873 (the_low_target): New.
21874 * linux-mips-low.c (num_regs): Remove.
21875 (mips_num_regs): Define.
21876 (mips_regmap): Renamed from regmap, made static.
21877 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21879 (mips_cannot_store_register): Renamed from cannot_store_register,
21881 (the_low_target): New.
21882 * linux-ppc-low.c (num_regs): Remove.
21883 (ppc_num_regs): Define.
21884 (ppc_regmap): Renamed from regmap, made static.
21885 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21887 (ppc_cannot_store_register): Renamed from cannot_store_register,
21889 (the_low_target): New.
21890 * linux-s390-low.c (num_regs): Remove.
21891 (s390_num_regs): Define.
21892 (s390_regmap): Renamed from regmap, made static.
21893 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21895 (s390_cannot_store_register): Renamed from cannot_store_register,
21897 (the_low_target): New.
21898 * linux-sh-low.c (num_regs): Remove.
21899 (sh_num_regs): Define.
21900 (sh_regmap): Renamed from regmap, made static.
21901 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21903 (sh_cannot_store_register): Renamed from cannot_store_register,
21905 (the_low_target): New.
21906 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21907 (the_low_target): New.
21909 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21911 * Makefile.in: Add stamp-h target.
21912 * configure.in: Create stamp-h.
21913 * configure: Regenerated.
21915 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21917 * inferiors.c: New file.
21918 * target.c: New file.
21919 * target.h: New file.
21920 * Makefile.in: Add target.o and inferiors.o. Update
21922 * linux-low.c (inferior_pid): New static variable,
21923 moved from server.c.
21924 (linux_create_inferior): Renamed from create_inferior.
21925 Call add_inferior. Return 0 on success instead of a PID.
21926 (linux_attach): Renamed from myattach.
21927 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21928 (linux_thread_alive): Renamed from mythread_alive.
21929 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21931 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21932 (regsets_store_inferior_registers): Correct error message.
21933 Add missing ``return 0''.
21934 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21935 (linux_store_registers): Renamed from store_inferior_registers.
21936 (linux_read_memory): Renamed from read_inferior_memory.
21937 (linux_write_memory): Renamed from write_inferior_memory.
21938 (linux_target_ops): New structure.
21939 (initialize_low): Call set_target_ops ().
21940 * remote-utils.c (unhexify): New function.
21941 (hexify): New function.
21942 (input_interrupt): Send signals to ``signal_pid''.
21943 * server.c (inferior_pid): Remove.
21944 (start_inferior): Update create_inferior call.
21945 (attach_inferior): Call add_inferior.
21946 (handle_query): New function.
21947 (main): Call handle_query for `q' packets.
21948 * server.h: Include "target.h". Remove obsolete prototypes.
21949 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21951 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21953 * Makefile.in: Add WARN_CFLAGS. Update configury
21955 * configure.in: Check for <string.h>
21956 * configure: Regenerate.
21957 * config.in: Regenerate.
21958 * gdbreplay.c: Include needed system headers.
21959 (remote_open): Remove strchr prototype.
21960 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21961 * regcache.c (supply_register): Change buf argument to const void *.
21962 (supply_register_by_name): Likewise.
21963 (collect_register): Change buf argument to void *.
21964 (collect_register_by_name): Likewise.
21965 * regcache.h: Add missing prototypes.
21966 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21967 * server.c (handle_query): New function.
21968 (attached): New static variable, moved out of main.
21969 (main): Quiet longjmp clobber warnings.
21970 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21971 * utils.c (error): Remove NORETURN.