1 2020-04-08 Tom Tromey <tromey@adacore.com>
3 * win32-low.h (struct windows_thread_info): Rename from
4 win32_thread_info. Remove typedef.
5 (struct win32_target_ops, win32_require_context): Update.
6 * win32-low.c (win32_get_thread_context)
7 (win32_set_thread_context, win32_prepare_to_resume)
8 (win32_require_context, thread_rec, child_add_thread)
9 (delete_thread_info, continue_one_thread)
10 (child_fetch_inferior_registers, child_store_inferior_registers)
11 (win32_resume, suspend_one_thread, win32_get_tib_address):
13 * win32-i386-low.c (update_debug_registers)
14 (win32_get_current_dr, i386_get_thread_context)
15 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
16 (i386_fetch_inferior_register, i386_store_inferior_register):
18 * win32-arm-low.c (arm_get_thread_context)
19 (arm_fetch_inferior_register, arm_store_inferior_register):
22 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
24 * linux-low.h (struct linux_target_ops): Remove.
25 (the_low_target): Remove.
26 * linux-x86-low.cc (the_low_target): Remove.
27 * linux-aarch64-low.cc (the_low_target): Ditto.
28 * linux-arm-low.cc (the_low_target): Ditto.
29 * linux-bfin-low.cc (the_low_target): Ditto.
30 * linux-cris-low.cc (the_low_target): Ditto.
31 * linux-crisv32-low.cc (the_low_target): Ditto.
32 * linux-ia64-low.cc (the_low_target): Ditto.
33 * linux-m32r-low.cc (the_low_target): Ditto.
34 * linux-m68k-low.cc (the_low_target): Ditto.
35 * linux-mips-low.cc (the_low_target): Ditto.
36 * linux-nios2-low.cc (the_low_target): Ditto.
37 * linux-ppc-low.cc (the_low_target): Ditto.
38 * linux-riscv-low.cc (the_low_target): Ditto.
39 * linux-s390-low.cc (the_low_target): Ditto.
40 * linux-sh-low.cc (the_low_target): Ditto.
41 * linux-sparc-low.cc (the_low_target): Ditto.
42 * linux-tic6x-low.cc (the_low_target): Ditto.
43 * linux-tile-low.cc (the_low_target): Ditto.
44 * linux-xtensa-low.cc (the_low_target): Ditto.
46 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
48 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
49 linux target define the op by overriding the declaration in
50 process_stratum_target.
52 * linux-low.h (struct linux_target_ops): Remove the op.
53 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
54 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
55 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
56 (x86_get_ipa_tdesc_idx): Turn into...
57 (x86_target::get_ipa_tdesc_idx): ...this.
58 (the_low_target): Remove the op field.
59 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
60 (ppc_get_ipa_tdesc_idx): Turn into...
61 (ppc_target::get_ipa_tdesc_idx): ...this.
62 (the_low_target): Remove the op field.
63 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
64 (s390_get_ipa_tdesc_idx): Turn into...
65 (s390_target::get_ipa_tdesc_idx): ...this.
66 (the_low_target): Remove the op field.
68 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
70 Turn the 'get_syscall_trapinfo' linux target op into a method
71 of process_stratum_target.
73 * linux-low.h (struct linux_target_ops): Remove the op.
74 (class linux_process_target) <get_syscall_trapinfo>
75 <gdb_catch_this_syscall>
76 <low_supports_catch_syscall>
77 <low_get_syscall_trapinfo>: Declare.
78 * linux-low.cc (get_syscall_trapinfo): Turn into...
79 (linux_process_target::get_syscall_trapinfo): ...this.
80 (linux_process_target::low_get_syscall_trapinfo): Define.
81 (gdb_catch_this_syscall_p): Turn into...
82 (linux_process_target::gdb_catch_this_syscall): ...this.
83 (linux_process_target::low_supports_catch_syscall): Define.
85 Update the callers below.
87 (linux_process_target::wait_1)
88 (linux_process_target::supports_catch_syscall)
90 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
91 <low_get_syscall_trapinfo>: Declare.
92 (x86_target::low_supports_catch_syscall): Define.
93 (x86_get_syscall_trapinfo): Turn into...
94 (x86_target::low_get_syscall_trapinfo): ...this.
95 (the_low_target): Remove the op field.
96 * linux-aarch64-low.cc (class aarch64_target)
97 <low_supports_catch_syscall>
98 <low_get_syscall_trapinfo>: Declare.
99 (aarch64_target::low_supports_catch_syscall): Define.
100 (aarch64_get_syscall_trapinfo): Turn into...
101 (aarch64_target::low_get_syscall_trapinfo): ...this.
102 (the_low_target): Remove the op field.
103 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
104 <low_get_syscall_trapinfo>: Declare.
105 (arm_target::low_supports_catch_syscall): Define.
106 (arm_get_syscall_trapinfo): Turn into...
107 (arm_target::low_get_syscall_trapinfo): ...this.
108 (the_low_target): Remove the op field.
109 * linux-ppc-low.cc (the_low_target): Remove the op field.
110 * linux-s390-low.cc (the_low_target): Remove the op field.
112 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
114 Remove the 'supports_hardware_single_step' linux target op and
115 override the process_stratum_target's op definition in
116 linux_process_target to return true.
118 * linux-low.h (struct linux_target_ops): Remove the op.
119 (class linux_process_target) <finish_step_over>
120 <maybe_hw_step>: Declare.
121 * linux-low.cc (can_hardware_single_step): Remove.
122 (maybe_hw_step): Turn into...
123 (linux_process_target::maybe_hw_step): ...this.
124 (finish_step_over): Turn into...
125 (linux_process_target::finish_step_over): ...this.
126 (linux_process_target::supports_hardware_single_step): Update
129 Update the callers below.
131 (linux_process_target::single_step)
132 (linux_process_target::resume_one_lwp_throw)
134 * linux-arm-low.cc (class arm_target)
135 <supports_hardware_single_step>: Declare.
136 (arm_supports_hardware_single_step): Turn into...
137 (arm_target::supports_hardware_single_step): ...this.
138 (the_low_target): Remove the op field.
139 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
140 (the_low_target): Remove the op field.
141 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
143 (the_low_target): Remove the op field.
144 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
145 (the_low_target): Remove the op field.
146 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
147 (the_low_target): Remove the op field.
148 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
149 (the_low_target): Remove the op field.
150 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
151 (the_low_target): Remove the op field.
152 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
153 (the_low_target): Remove the op field.
154 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
155 (the_low_target): Remove the op field.
156 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
157 (the_low_target): Remove the op field.
158 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
159 (the_low_target): Remove the op field.
160 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
161 (the_low_target): Remove the op field.
162 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
164 (the_low_target): Remove the op field.
166 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
168 Turn the 'supports_range_stepping' linux target op into a method
169 of linux_process_target.
171 * linux-low.h (struct linux_target_ops): Remove the op.
172 (class linux_process_target) <low_supports_range_stepping>: Declare.
173 * linux-low.cc (linux_process_target::low_supports_range_stepping):
175 (linux_process_target::supports_range_stepping): Update the call
177 * linux-x86-low.cc (class x86_target)
178 <low_supports_range_stepping>: Declare.
179 (x86_supports_range_stepping): Turn into...
180 (x86_target::low_supports_range_stepping): ...this.
181 (the_low_target): Remove the op field.
182 * linux-aarch64-low.cc (class aarch64_target)
183 <low_supports_range_stepping>: Declare.
184 (aarch64_supports_range_stepping): Turn into...
185 (aarch64_target::low_supports_range_stepping): ...this.
186 (the_low_target): Remove the op field.
187 * linux-arm-low.cc (the_low_target): Remove the op field.
188 * linux-bfin-low.cc (the_low_target): Ditto.
189 * linux-crisv32-low.cc (the_low_target): Ditto.
190 * linux-m32r-low.cc (the_low_target): Ditto.
191 * linux-m68k-low.cc (the_low_target): Ditto.
192 * linux-ppc-low.cc (the_low_target): Ditto.
193 * linux-s390-low.cc (the_low_target): Ditto.
194 * linux-sh-low.cc (the_low_target): Ditto.
195 * linux-tic6x-low.cc (the_low_target): Ditto.
196 * linux-tile-low.cc (the_low_target): Ditto.
197 * linux-xtensa-low.cc (the_low_target): Ditto.
199 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
201 Remove the 'emit_ops' linux target ops and let the concrete
202 linux target define the op by overriding the declaration of
203 process_stratum_target.
205 * linux-low.h (struct linux_target_ops): Remove the op.
206 (class linux_process_target) <emit_ops>: Remove.
207 * linux-low.cc (linux_process_target::emit_ops): Remove.
208 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
209 (x86_emit_ops): Turn into...
210 (x86_target::emit_ops): ...this.
211 (the_low_target): Remove the op field.
212 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
213 (aarch64_emit_ops): Turn into...
214 (aarch64_target::emit_ops): ...this.
215 (the_low_target): Remove the op field.
216 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
217 (ppc_emit_ops): Turn into...
218 (ppc_target::emit_ops): ...this.
219 (the_low_target): Remove the op field.
220 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
221 (s390_emit_ops): Turn into...
222 (s390_target::emit_ops): ...this.
223 (the_low_target): Remove the op field.
224 * linux-arm-low.cc (the_low_target): Remove the op field.
225 * linux-bfin-low.cc (the_low_target): Ditto.
226 * linux-crisv32-low.cc (the_low_target): Ditto.
227 * linux-m32r-low.cc (the_low_target): Ditto.
228 * linux-m68k-low.cc (the_low_target): Ditto.
229 * linux-sh-low.cc (the_low_target): Ditto.
230 * linux-tic6x-low.cc (the_low_target): Ditto.
231 * linux-tile-low.cc (the_low_target): Ditto.
232 * linux-xtensa-low.cc (the_low_target): Ditto.
234 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
236 Remove the 'install_fast_tracepoint_jump_pad' and
237 'get_min_fast_tracepoint_insn_len' linux target ops to let the
238 concrete linux target define the ops by overriding the declarations
239 of process_stratum_target.
241 * linux-low.h (struct linux_target_ops): Remove the ops.
242 (class linux_process_target) <supports_fast_tracepoints>
243 <install_fast_tracepoint_jump_pad>
244 <get_min_fast_tracepoint_insn_len>: Remove.
245 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
246 (linux_process_target::install_fast_tracepoint_jump_pad)
247 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
248 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
249 <install_fast_tracepoint_jump_pad>
250 <get_min_fast_tracepoint_insn_len>: Declare.
251 (x86_target::supports_fast_tracepoints): Define.
252 (x86_install_fast_tracepoint_jump_pad): Turn into...
253 (x86_target::install_fast_tracepoint_jump_pad): ...this.
254 (x86_get_min_fast_tracepoint_insn_len): Turn into...
255 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
256 (the_low_target): Remove the op fields.
257 * linux-aarch64-low.cc (class aarch64_target)
258 <supports_fast_tracepoints>
259 <install_fast_tracepoint_jump_pad>
260 <get_min_fast_tracepoint_insn_len>: Declare.
261 (aarch64_target::supports_fast_tracepoints): Define.
262 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
263 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
264 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
265 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
266 (the_low_target): Remove the op fields.
267 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
268 <install_fast_tracepoint_jump_pad>
269 <get_min_fast_tracepoint_insn_len>: Declare.
270 (ppc_target::supports_fast_tracepoints): Define.
271 (ppc_install_fast_tracepoint_jump_pad): Turn into...
272 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
273 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
274 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
275 (the_low_target): Remove the op fields.
276 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
277 <install_fast_tracepoint_jump_pad>
278 <get_min_fast_tracepoint_insn_len>: Declare.
279 (s390_target::supports_fast_tracepoints): Define.
280 (s390_install_fast_tracepoint_jump_pad): Turn into...
281 (s390_target::install_fast_tracepoint_jump_pad): ...this.
282 (s390_get_min_fast_tracepoint_insn_len): Turn into...
283 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
284 (the_low_target): Remove the op fields.
285 * linux-arm-low.cc (the_low_target): Remove the op fields.
286 * linux-bfin-low.cc (the_low_target): Ditto.
287 * linux-crisv32-low.cc (the_low_target): Ditto.
288 * linux-m32r-low.cc (the_low_target): Ditto.
289 * linux-m68k-low.cc (the_low_target): Ditto.
290 * linux-sh-low.cc (the_low_target): Ditto.
291 * linux-tic6x-low.cc (the_low_target): Ditto.
292 * linux-tile-low.cc (the_low_target): Ditto.
293 * linux-xtensa-low.cc (the_low_target): Ditto.
295 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
297 Turn the 'get_thread_area' linux target op into a method of
298 process_stratum_target.
300 * linux-low.h (struct linux_target_ops): Remove the op.
301 (class linux_process_target) <stuck_in_jump_pad>
302 <linux_fast_tracepoint_collecting>
303 <low_get_thread_area>: Declare.
304 * linux-low.cc (supports_fast_tracepoints): Remove.
305 (linux_fast_tracepoint_collecting): Turn into...
306 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
307 (linux_process_target::low_get_thread_area): Define.
308 (stuck_in_jump_pad_callback): Turn into...
309 (linux_process_target::stuck_in_jump_pad): ...this.
311 Update the caller below.
313 (linux_process_target::stabilize_threads)
315 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
317 (x86_get_thread_area): Turn into...
318 (x86_target::low_get_thread_area): ...this.
319 (the_low_target): Remove the op field.
320 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
322 (aarch64_get_thread_area): Turn into...
323 (aarch64_target::low_get_thread_area): ...this.
324 (the_low_target): Remove the op field.
325 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
327 (ppc_get_thread_area): Turn into...
328 (ppc_target::low_get_thread_area): ...this.
329 (the_low_target): Remove the op field.
330 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
332 (s390_get_thread_area): Turn into...
333 (s390_target::low_get_thread_area): ...this.
334 (the_low_target): Remove the op field.
335 * linux-arm-low.cc (the_low_target): Remove the op field.
336 * linux-bfin-low.cc (the_low_target): Ditto.
337 * linux-crisv32-low.cc (the_low_target): Ditto.
338 * linux-m32r-low.cc (the_low_target): Ditto.
339 * linux-m68k-low.cc (the_low_target): Ditto.
340 * linux-sh-low.cc (the_low_target): Ditto.
341 * linux-tic6x-low.cc (the_low_target): Ditto.
342 * linux-tile-low.cc (the_low_target): Ditto.
343 * linux-xtensa-low.cc (the_low_target): Ditto.
345 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
347 Remote the 'supports_tracepoints' linux target op and let the
348 concrete linux target define it by overriding the op declared in
349 process_stratum_target.
351 * linux-low.h (struct linux_target_ops): Remove the op.
352 (class linux_process_target) <supports_tracepoints>: Remove.
353 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
354 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
356 (x86_supports_tracepoints): Turn into...
357 (x86_target::supports_tracepoints): ...this.
358 (the_low_target): Remove the op field.
359 * linux-aarch64-low.cc (class aarch64_target)
360 <supports_tracepoints>: Declare.
361 (aarch64_supports_tracepoints): Turn into...
362 (aarch64_target::supports_tracepoints): ...this.
363 (the_low_target): Remove the op field.
364 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
366 (ppc_supports_tracepoints): Turn into...
367 (ppc_target::supports_tracepoints): ...this.
368 (the_low_target): Remove the op field.
369 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
371 (s390_supports_tracepoints): Turn into...
372 (s390_target::supports_tracepoints): ...this.
373 (the_low_target): Remove the op field.
374 * linux-arm-low.cc (the_low_target): Remove the op field.
375 * linux-bfin-low.cc (the_low_target): Ditto.
376 * linux-crisv32-low.cc (the_low_target): Ditto.
377 * linux-m32r-low.cc (the_low_target): Ditto.
378 * linux-m68k-low.cc (the_low_target): Ditto.
379 * linux-sh-low.cc (the_low_target): Ditto.
380 * linux-tic6x-low.cc (the_low_target): Ditto.
381 * linux-tile-low.cc (the_low_target): Ditto.
382 * linux-xtensa-low.cc (the_low_target): Ditto.
384 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
386 Remove the 'process_qsupported' linux target op and let a concrete
387 linux target define the op by overriding the op declaration in
388 process_stratum_target.
390 * linux-low.h (struct linux_target_ops): Remove the op.
391 (class linux_process_target) <process_qsupported>: Remove.
392 * linux-low.cc (linux_process_target::process_qsupported): Remove.
393 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
394 (x86_linux_process_qsupported): Turn into...
395 (x86_target::process_qsupported): ...this.
396 (the_low_target): Remove the op field.
397 * linux-aarch64-low.cc (the_low_target): Remove the op
399 * linux-arm-low.cc (the_low_target): Ditto.
400 * linux-bfin-low.cc (the_low_target): Ditto.
401 * linux-crisv32-low.cc (the_low_target): Ditto.
402 * linux-m32r-low.cc (the_low_target): Ditto.
403 * linux-m68k-low.cc (the_low_target): Ditto.
404 * linux-ppc-low.cc (the_low_target): Ditto.
405 * linux-s390-low.cc (the_low_target): Ditto.
406 * linux-sh-low.cc (the_low_target): Ditto.
407 * linux-tic6x-low.cc (the_low_target): Ditto.
408 * linux-tile-low.cc (the_low_target): Ditto.
409 * linux-xtensa-low.cc (the_low_target): Ditto.
411 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
413 Turn the 'prepare_to_resume' linux target op into a method of
414 linux_process_target.
416 * linux-low.h (struct linux_target_ops): Remove the op.
417 (class linux_process_target) <low_prepare_to_resume>: Declare.
418 * linux-low.cc (linux_process_target::low_prepare_to_resume):
421 Update the callers below:
423 (linux_process_target::resume_one_lwp_throw)
424 (linux_process_target::low_prepare_to_resume)
426 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
428 (x86_target::low_prepare_to_resume): Define.
429 (the_low_target): Remove the op field.
430 * linux-aarch64-low.cc (class aarch64_target)
431 <low_prepare_to_resume>: Declare.
432 (aarch64_target::low_prepare_to_resume): Define.
433 (the_low_target): Remove the op field.
434 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
436 (arm_prepare_to_resume): Turn into...
437 (arm_target::low_prepare_to_resume): ...this.
438 (the_low_target): Remove the op field.
439 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
441 (mips_linux_prepare_to_resume): Turn into...
442 (mips_target::low_prepare_to_resume): ...this.
443 (the_low_target): Remove the op field.
444 * linux-bfin-low.cc (the_low_target): Remove the op field.
445 * linux-crisv32-low.cc (the_low_target): Ditto.
446 * linux-m32r-low.cc (the_low_target): Ditto.
447 * linux-m68k-low.cc (the_low_target): Ditto.
448 * linux-ppc-low.cc (the_low_target): Ditto.
449 * linux-s390-low.cc (the_low_target): Ditto.
450 * linux-sh-low.cc (the_low_target): Ditto.
451 * linux-tic6x-low.cc (the_low_target): Ditto.
452 * linux-tile-low.cc (the_low_target): Ditto.
453 * linux-xtensa-low.cc (the_low_target): Ditto.
455 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
457 Turn the 'new_process', 'delete_process', 'new_thread',
458 'delete_thread', and 'new_fork' linux target ops into methods
459 of linux_process_target.
461 * linux-low.h (struct linux_target_ops): Remove the ops.
462 (class linux_process_target) <add_linux_process>
467 <check_zombie_leaders>
473 <low_new_fork>: Declare.
474 * linux-low.cc (delete_lwp): Turn into...
475 (linux_process_target::delete_lwp): ...this.
476 (linux_process_target::low_delete_thread): Define.
477 (linux_add_process): Turn into...
478 (linux_process_target::add_linux_process): ...this.
479 (linux_process_target::low_new_process): Define.
480 (linux_process_target::low_delete_process): Define.
481 (linux_process_target::low_new_fork): Define.
482 (add_lwp): Turn into...
483 (linux_process_target::add_lwp): ...this.
484 (linux_process_target::low_new_thread): Define.
485 (linux_attach_lwp): Turn into...
486 (linux_process_target::attach_lwp): ...this.
487 (linux_detach_one_lwp): Turn into...
488 (linux_process_target::detach_one_lwp): ...this.
489 (linux_detach_lwp_callback): Remove and inline...
490 (linux_process_target::detach): ...here.
491 (check_zombie_leaders): Turn into...
492 (linux_process_target::check_zombie_leaders): ...this.
493 (filter_exit_event): Turn into...
494 (linux_process_target::filter_exit_event): ...this.
496 Update the callers below.
498 (linux_process_target::handle_extended_wait)
499 (linux_process_target::create_inferior)
500 (attach_proc_task_lwp_callback)
501 (linux_process_target::attach)
502 (linux_process_target::detach)
503 (linux_process_target::mourn)
504 * thread-db.cc (attach_thread)
506 * linux-x86-low.cc (class x86_target) <low_new_process>
510 <low_new_fork>: Declare.
511 (x86_linux_new_process): Turn into...
512 (x86_target::low_new_process): ...this.
513 (x86_linux_delete_process): Turn into...
514 (x86_target::low_delete_process): ...this.
515 (x86_target::low_new_thread): Define.
516 (x86_target::low_delete_thread): Define.
517 (x86_linux_new_fork): Turn into...
518 (x86_target::low_new_fork): ...this.
519 (the_low_target): Remove the op fields.
520 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
524 <low_new_fork>: Declare.
525 (aarch64_linux_new_process): Turn into...
526 (aarch64_target::low_new_process): ...this.
527 (aarch64_linux_delete_process): Turn into...
528 (aarch64_target::low_delete_process): ...this.
529 (aarch64_target::low_new_thread): Define.
530 (aarch64_target::low_delete_thread): Define.
531 (aarch64_linux_new_fork): Turn into...
532 (aarch64_target::low_new_fork): ...this.
533 (the_low_target): Remove the op fields.
534 * linux-arm-low.cc (class arm_target) <low_new_process>
538 <low_new_fork>: Declare.
539 (arm_new_process): Turn into...
540 (arm_target::low_new_process): ...this.
541 (arm_delete_process): Turn into...
542 (arm_target::low_delete_process): ...this.
543 (arm_new_thread): Turn into...
544 (arm_target::low_new_thread): ...this.
545 (arm_delete_thread): Turn into...
546 (arm_target::low_delete_thread): ...this.
547 (arm_new_fork): Turn into...
548 (arm_target::low_new_fork): ...this.
549 (the_low_target): Remove the op fields.
550 * linux-mips-low.cc (class mips_target) <low_new_process>
554 <low_new_fork>: Declare.
555 (mips_linux_new_process): Turn into...
556 (mips_target::low_new_process): ...this.
557 (mips_linux_delete_process): Turn into...
558 (mips_target::low_delete_process): ...this.
559 (mips_linux_new_thread): Turn into...
560 (mips_target::low_new_thread): ...this.
561 (mips_linux_delete_thread): Turn into...
562 (mips_target::low_delete_thread): ...this.
563 (mips_linux_new_fork): Turn into...
564 (mips_target::low_new_fork): ...this.
565 (the_low_target): Remove the op fields.
566 * linux-bfin-low.cc (the_low_target): Remove the op fields.
567 * linux-crisv32-low.cc (the_low_target): Ditto.
568 * linux-m32r-low.cc (the_low_target): Ditto.
569 * linux-m68k-low.cc (the_low_target): Ditto.
570 * linux-ppc-low.cc (the_low_target): Ditto.
571 * linux-s390-low.cc (the_low_target): Ditto.
572 * linux-sh-low.cc (the_low_target): Ditto.
573 * linux-tic6x-low.cc (the_low_target): Ditto.
574 * linux-tile-low.cc (the_low_target): Ditto.
575 * linux-xtensa-low.cc (the_low_target): Ditto.
577 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
579 Turn the 'siginfo_fixup' linux target op into a method of
580 linux_process_target.
582 * linux-low.h (struct linux_target_ops): Remove the op.
583 (class linux_process_target) <siginfo_fixup>
584 <low_siginfo_fixup>: Declare.
585 * linux-low.cc (siginfo_fixup): Turn into...
586 (linux_process_target::siginfo_fixup): ...this.
587 (linux_process_target::low_siginfo_fixup): Define.
588 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
589 (x86_siginfo_fixup): Turn into...
590 (x86_target::low_siginfo_fixup): ...this.
591 (the_low_target): Remove the op field.
592 * linux-aarch64-low.cc (class aarch64_target):
593 <low_siginfo_fixup>: Declare.
594 (aarch64_linux_siginfo_fixup): Turn into...
595 (aarch64_target::low_siginfo_fixup): ...this.
596 (the_low_target): Remove the op field.
597 * linux-arm-low.cc (the_low_target): Remove the op field.
598 * linux-bfin-low.cc (the_low_target): Ditto.
599 * linux-crisv32-low.cc (the_low_target): Ditto.
600 * linux-m32r-low.cc (the_low_target): Ditto.
601 * linux-m68k-low.cc (the_low_target): Ditto.
602 * linux-mips-low.cc (the_low_target): Ditto.
603 * linux-ppc-low.cc (the_low_target): Ditto.
604 * linux-s390-low.cc (the_low_target): Ditto.
605 * linux-sh-low.cc (the_low_target): Ditto.
606 * linux-tic6x-low.cc (the_low_target): Ditto.
607 * linux-tile-low.cc (the_low_target): Ditto.
608 * linux-xtensa-low.cc (the_low_target): Ditto.
610 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
612 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
613 linux target ops into methods of linux_process_target.
615 * linux-low.h (struct linux_target_ops): Remove the ops.
616 (class linux_process_target) <low_collect_ptrace_register>
617 <low_store_ptrace_register>: Declare.
618 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
619 (linux_process_target::low_supply_ptrace_register): Define.
621 Update the callers below.
623 (linux_process_target::fetch_register)
624 (linux_process_target::store_register)
626 * linux-x86-low.cc (the_low_target): Remove the op fields.
627 * linux-aarch64-low.cc (the_low_target): Ditto.
628 * linux-arm-low.cc (the_low_target): Ditto.
629 * linux-bfin-low.cc (the_low_target): Ditto.
630 * linux-crisv32-low.cc (the_low_target): Ditto.
631 * linux-m32r-low.cc (the_low_target): Ditto.
632 * linux-m68k-low.cc (the_low_target): Ditto.
633 * linux-sh-low.cc (the_low_target): Ditto.
634 * linux-sparc-low.cc (the_low_target): Ditto.
635 * linux-tic6x-low.cc (the_low_target): Ditto.
636 * linux-tile-low.cc (the_low_target): Ditto.
637 * linux-xtensa-low.cc (the_low_target): Ditto.
638 * linux-mips-low.cc (class mips_target)
639 <low_collect_ptrace_register>
640 <low_supply_ptrace_register>: Declare.
641 (mips_collect_ptrace_register): Turn into ...
642 (mips_target::low_collect_ptrace_register): ...this.
643 (mips_supply_ptrace_register): Turn into...
644 (mips_target::low_supply_ptrace_register): ...this.
645 (the_low_target): Remove the op fields.
646 * linux-ppc-low.cc (class ppc_target)
647 <low_collect_ptrace_register>
648 <low_supply_ptrace_register>: Declare.
649 (ppc_collect_ptrace_register): Turn into ...
650 (ppc_target::low_collect_ptrace_register): ...this.
651 (ppc_supply_ptrace_register): Turn into ...
652 (ppc_target::low_supply_ptrace_register): ...this.
653 (ppc_fill_gregset): Update for the calls to
654 low_collect_ptrace_register.
655 (the_low_target): Remove the op fields.
656 * linux-s390-low.cc (class s390_target)
657 <low_collect_ptrace_register>
658 <low_supply_ptrace_register>: Declare.
659 (s390_collect_ptrace_register): Turn into ...
660 (s390_target::low_collect_ptrace_register): ...this.
661 (s390_supply_ptrace_register): Turn into ...
662 (s390_target::low_supply_ptrace_register): ...this.
663 (s390_fill_gregset): Update for the calls to
664 low_collect_ptrace_register.
665 (the_low_target): Remove the op fields.
667 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
669 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
670 target ops into methods of linux_process_target.
672 * linux-low.h (struct linux_target_ops): Remove the ops.
673 (class linux_process_target) <check_stopped_by_watchpoint>
674 <low_stopped_by_watchpoint>
675 <low_stopped_data_address>: Declare.
676 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
677 (linux_process_target::check_stopped_by_watchpoint): ...this.
678 (linux_process_target::low_stopped_by_watchpoint): Define.
679 (linux_process_target::low_stopped_data_address): Define.
680 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
681 <low_stopped_data_address>: Declare.
682 (x86_stopped_by_watchpoint): Turn into...
683 (x86_target::low_stopped_by_watchpoint): ...this.
684 (x86_stopped_data_address): Turn into...
685 (x86_target::low_stopped_data_address): ...this.
686 (the_low_target): Remove the op fields.
687 * linux-aarch64-low.cc (class aarch64_target)
688 <low_stopped_by_watchpoint>
689 <low_stopped_data_address>: Declare.
690 (aarch64_stopped_by_watchpoint): Turn into...
691 (aarch64_target::low_stopped_by_watchpoint): ...this.
692 (aarch64_stopped_data_address): Turn into...
693 (aarch64_target::low_stopped_data_address): ...this.
694 (the_low_target): Remove the op fields.
695 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
696 <low_stopped_data_address>: Declare.
697 (arm_stopped_by_watchpoint): Turn into...
698 (arm_target::low_stopped_by_watchpoint): ...this.
699 (arm_stopped_data_address): Turn into...
700 (arm_target::low_stopped_data_address): ...this.
701 (the_low_target): Remove the op fields.
702 * linux-crisv32-low.cc (class crisv32_target)
703 <low_stopped_by_watchpoint>
704 <low_stopped_data_address>: Declare.
705 (cris_stopped_by_watchpoint): Turn into...
706 (crisv32_target::low_stopped_by_watchpoint): ...this.
707 (cris_stopped_data_address): Turn into...
708 (crisv32_target::low_stopped_data_address): ...this.
709 (the_low_target): Remove the op fields.
710 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
711 <low_stopped_data_address>: Declare.
712 (mips_stopped_by_watchpoint): Turn into...
713 (mips_target::low_stopped_by_watchpoint): ...this.
714 (mips_stopped_data_address): Turn into...
715 (mips_target::low_stopped_data_address): ...this.
716 (the_low_target): Remove the op fields.
717 * linux-bfin-low.cc (the_low_target): Remove the op fields.
718 * linux-m32r-low.cc (the_low_target): Ditto.
719 * linux-m68k-low.cc (the_low_target): Ditto.
720 * linux-ppc-low.cc (the_low_target): Ditto.
721 * linux-s390-low.cc (the_low_target): Ditto.
722 * linux-sh-low.cc (the_low_target): Ditto.
723 * linux-sparc-low.cc (the_low_target): Ditto.
724 * linux-tic6x-low.cc (the_low_target): Ditto.
725 * linux-tile-low.cc (the_low_target): Ditto.
726 * linux-xtensa-low.cc (the_low_target): Ditto.
728 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
730 Turn the 'insert_point' and 'remove_point' linux target ops into
731 methods of linux_process_target.
733 * linux-low.h (struct linux_target_ops): Remove the ops.
734 (class linux_process_target) <low_insert_point>
735 <low_remove_point>: Declare.
736 * linux-low.cc (linux_process_target::low_insert_point)
737 (linux_process_target::low_remove_point): Define.
738 (linux_process_target::insert_point)
739 (linux_process_target::remove_point): Update for calls to
740 low_insert_point and low_remove_point.
741 * linux-x86-low.cc (class x86_target) <low_insert_point>
742 <low_remove_point>: Declare.
743 (x86_insert_point): Turn into...
744 (x86_target::low_insert_point): ...this.
745 (x86_remove_point): Turn into...
746 (x86_target::low_remove_point): ...this.
747 (the_low_target): Remove the op fields.
748 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
749 <low_remove_point>: Declare.
750 (aarch64_insert_point): Turn into...
751 (aarch64_target::low_insert_point): ...this.
752 (aarch64_remove_point): Turn into...
753 (aarch64_target::low_remove_point): ...this.
754 (the_low_target): Remove the op fields.
755 * linux-arm-low.cc (class arm_target) <low_insert_point>
756 <low_remove_point>: Declare.
757 (arm_insert_point): Turn into...
758 (arm_target::low_insert_point): ...this.
759 (arm_remove_point): Turn into...
760 (arm_target::low_remove_point): ...this.
761 (the_low_target): Remove the op fields.
762 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
763 <low_remove_point>: Declare.
764 (crisv32_insert_point): Turn into...
765 (crisv32_target::low_insert_point): ...this.
766 (crisv32_remove_point): Turn into...
767 (crisv32_target::low_remove_point): ...this.
768 (the_low_target): Remove the op fields.
769 * linux-mips-low.cc (class mips_target) <low_insert_point>
770 <low_remove_point>: Declare.
771 (mips_insert_point): Turn into...
772 (mips_target::low_insert_point): ...this.
773 (mips_remove_point): Turn into...
774 (mips_target::low_remove_point): ...this.
775 (the_low_target): Remove the op fields.
776 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
777 <low_remove_point>: Declare.
778 (ppc_insert_point): Turn into...
779 (ppc_target::low_insert_point): ...this.
780 (ppc_remove_point): Turn into...
781 (ppc_target::low_remove_point): ...this.
782 (the_low_target): Remove the op fields.
783 * linux-bfin-low.cc (the_low_target): Remove the op fields.
784 * linux-m32r-low.cc (the_low_target): Ditto.
785 * linux-m68k-low.cc (the_low_target): Ditto.
786 * linux-s390-low.cc (the_low_target): Ditto.
787 * linux-sh-low.cc (the_low_target): Ditto.
788 * linux-sparc-low.cc (the_low_target): Ditto.
789 * linux-tic6x-low.cc (the_low_target): Ditto.
790 * linux-tile-low.cc (the_low_target): Ditto.
791 * linux-xtensa-low.cc (the_low_target): Ditto.
793 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
795 Remove the 'supports_z_point_type' linux target op and let the
796 concrete linux target define it by overriding the op declared in
797 process_stratum_target.
799 * linux-low.cc (linux_process_target::supports_z_point_type):
801 * linux-low.h (struct linux_target_ops): Remove the op.
802 (class linux_process_target) <supports_z_point_type>: Remove.
803 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
805 (x86_supports_z_point_type): Turn into...
806 (x86_target::supports_z_point_type): ...this.
807 (the_low_target): Remove the op field.
808 * linux-aarch64-low.cc (class aarch64_target)
809 <supports_z_point_type>: Declare.
810 (aarch64_supports_z_point_type): Turn into...
811 (aarch64_target::supports_z_point_type): ...this.
812 (the_low_target): Remove the op field.
813 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
815 (arm_supports_z_point_type): Turn into...
816 (arm_target::supports_z_point_type): ...this.
817 (the_low_target): Remove the op field.
818 * linux-crisv32-low.cc (class crisv32_target)
819 <supports_z_point_type>: Declare.
820 (cris_supports_z_point_type): Turn into...
821 (crisv32_target::supports_z_point_type): ...this.
822 (the_low_target): Remove the op field.
823 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
825 (mips_supports_z_point_type): Turn into...
826 (mips_target::supports_z_point_type): ...this.
827 (the_low_target): Remove the op field.
828 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
830 (ppc_supports_z_point_type): Turn into...
831 (ppc_target::supports_z_point_type): ...this.
832 (the_low_target): Remove the op field.
833 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
835 (s390_supports_z_point_type): Turn into...
836 (s390_target::supports_z_point_type): ...this.
837 (the_low_target): Remove the op field.
838 * linux-bfin-low.cc (the_low_target): Remove the op field.
839 * linux-m32r-low.cc (the_low_target): Ditto.
840 * linux-m68k-low.cc (the_low_target): Ditto.
841 * linux-sh-low.cc (the_low_target): Ditto.
842 * linux-sparc-low.cc (the_low_target): Ditto.
843 * linux-tic6x-low.cc (the_low_target): Ditto.
844 * linux-tile-low.cc (the_low_target): Ditto.
845 * linux-xtensa-low.cc (the_low_target): Ditto.
847 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
849 Turn the 'breakpoint_at' linux target op into a method of
850 linux_process_target.
852 * linux-low.h (struct linux_target_ops): Remove the op.
853 (class linux_process_target) <low_breakpoint_at>: Declare.
855 Update the callers below:
857 * linux-low.cc (linux_process_target::save_stop_reason)
858 (linux_process_target::thread_still_has_status_pending)
859 (linux_process_target::wait_1)
861 * linux-x86-low.cc (class x86_target)
862 <low_breakpoint_at>: Declare.
863 (x86_breakpoint_at): Turn into...
864 (x86_target::low_breakpoint_at): ...this.
865 (the_low_target): Remove the op field.
866 * linux-aarch64-low.cc (class aarch64_target)
867 <low_breakpoint_at>: Declare.
868 (aarch64_breakpoint_at): Turn into...
869 (aarch64_target::low_breakpoint_at): ...this.
870 (the_low_target): Remove the op field.
871 * linux-arm-low.cc (class arm_target)
872 <low_breakpoint_at>: Declare.
873 (arm_target::low_breakpoint_at): Define.
874 (the_low_target): Remove the op field.
875 * linux-bfin-low.cc (class bfin_target)
876 <low_breakpoint_at>: Declare.
877 (bfin_breakpoint_at): Turn into...
878 (bfin_target::low_breakpoint_at): ...this.
879 (the_low_target): Remove the op field.
880 * linux-cris-low.cc (class cris_target)
881 <low_breakpoint_at>: Declare.
882 (cris_breakpoint_at): Turn into...
883 (cris_target::low_breakpoint_at): ...this.
884 (the_low_target): Remove the op field.
885 * linux-crisv32-low.cc (class crisv32_target)
886 <low_breakpoint_at>: Declare.
887 (crisv32_breakpoint_at): Turn into...
888 (crisv32_target::low_breakpoint_at): ...this.
889 (the_low_target): Remove the op field.
890 * linux-ia64-low.cc (class ia64_target)
891 <low_breakpoint_at>: Declare.
892 (ia64_target::low_breakpoint_at): Define.
893 * linux-m32r-low.cc (class m32r_target)
894 <low_breakpoint_at>: Declare.
895 (m32r_breakpoint_at): Turn into...
896 (m32r_target::low_breakpoint_at): ...this.
897 (the_low_target): Remove the op field.
898 * linux-m68k-low.cc (class m68k_target)
899 <low_breakpoint_at>: Declare.
900 (m68k_breakpoint_at): Turn into...
901 (m68k_target::low_breakpoint_at): ...this.
902 (the_low_target): Remove the op field.
903 * linux-mips-low.cc (class mips_target)
904 <low_breakpoint_at>: Declare.
905 (mips_breakpoint_at): Turn into...
906 (mips_target::low_breakpoint_at): ...this.
907 (the_low_target): Remove the op field.
908 * linux-nios2-low.cc (class nios2_target)
909 <low_breakpoint_at>: Declare.
910 (nios2_breakpoint_at): Turn into...
911 (nios2_target::low_breakpoint_at): ...this.
912 (the_low_target): Remove the op field.
913 * linux-ppc-low.cc (class ppc_target)
914 <low_breakpoint_at>: Declare.
915 (ppc_breakpoint_at): Turn into...
916 (ppc_target::low_breakpoint_at): ...this.
917 (the_low_target): Remove the op field.
918 * linux-riscv-low.cc (class riscv_target)
919 <low_breakpoint_at>: Declare.
920 (riscv_breakpoint_at): Turn into...
921 (riscv_target::low_breakpoint_at): ...this.
922 (the_low_target): Remove the op field.
923 * linux-s390-low.cc (class s390_target)
924 <low_breakpoint_at>: Declare.
925 (s390_breakpoint_at): Turn into...
926 (s390_target::low_breakpoint_at): ...this.
927 (the_low_target): Remove the op field.
928 * linux-sh-low.cc (class sh_target)
929 <low_breakpoint_at>: Declare.
930 (sh_breakpoint_at): Turn into...
931 (sh_target::low_breakpoint_at): ...this.
932 (the_low_target): Remove the op field.
933 * linux-sparc-low.cc (class sparc_target)
934 <low_breakpoint_at>: Declare.
935 (sparc_breakpoint_at): Turn into...
936 (sparc_target::low_breakpoint_at): ...this.
937 (the_low_target): Remove the op field.
938 * linux-tic6x-low.cc (class tic6x_target)
939 <low_breakpoint_at>: Declare.
940 (tic6x_breakpoint_at): Turn into...
941 (tic6x_target::low_breakpoint_at): ...this.
942 (the_low_target): Remove the op field.
943 * linux-tile-low.cc (class tile_target)
944 <low_breakpoint_at>: Declare.
945 (tile_breakpoint_at): Turn into...
946 (tile_target::low_breakpoint_at): ...this.
947 (the_low_target): Remove the op field.
948 * linux-xtensa-low.cc (class xtensa_target)
949 <low_breakpoint_at>: Declare.
950 (xtensa_breakpoint_at): Turn into...
951 (xtensa_target::low_breakpoint_at): ...this.
952 (the_low_target): Remove the op field.
954 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
956 Turn the 'decr_pc_after_break' linux_target_ops field into
957 a method of linux_process_target.
959 * linux-low.h (struct linux_target_ops)
960 <decr_pc_after_break>: Remove.
961 (class linux_process_target) <low_decr_pc_after_break>: New method
963 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
964 New method implementation.
966 Update the users below.
968 (linux_process_target::save_stop_reason)
969 (linux_process_target::wait_1)
970 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
972 (x86_target::low_decr_pc_after_break): New method implementation.
973 (the_low_target): Remove the field.
974 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
976 (bfin_target::low_decr_pc_after_break): New method implementation.
977 (the_low_target): Remove the field.
978 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
980 (m68k_target::low_decr_pc_after_break): New method implementation.
981 (the_low_target): Remove the field.
982 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
984 (s390_target::low_decr_pc_after_break): New method implementation.
985 (the_low_target): Remove the field.
986 * linux-aarch64-low.cc (the_low_target): Remove the field.
987 * linux-arm-low.cc (the_low_target): Remove the field.
988 * linux-cris-low.cc (the_low_target): Remove the field.
989 * linux-crisv32-low.cc (the_low_target): Remove the field.
990 * linux-m32r-low.cc (the_low_target): Remove the field.
991 * linux-mips-low.cc (the_low_target): Remove the field.
992 * linux-nios2-low.cc (the_low_target): Remove the field.
993 * linux-ppc-low.cc (the_low_target): Remove the field.
994 * linux-riscv-low.cc (the_low_target): Remove the field.
995 * linux-sh-low.cc (the_low_target): Remove the field.
996 * linux-sparc-low.cc (the_low_target): Remove the field.
997 * linux-tic6x-low.cc (the_low_target): Remove the field.
998 * linux-tile-low.cc (the_low_target): Remove the field.
999 * linux-xtensa-low.cc (the_low_target): Remove the field.
1001 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1003 Remove the 'supports_software_single_step' linux target op and let
1004 the concrete linux target define it by overriding the op in
1005 process_stratum_target.
1006 Turn the 'get_next_pcs' linux target op into a method of
1007 linux_process_target.
1009 * linux-low.h (struct linux_target_ops): Remove the ops.
1010 (class linux_process_target) <supports_software_single_step>:
1012 <low_get_next_pcs>: Declare.
1013 * linux-low.cc (can_software_single_step): Remove.
1014 (linux_process_target::low_get_next_pcs): Define.
1015 (linux_process_target::supports_software_single_step): Remove.
1017 Update the callers below.
1019 (linux_process_target::handle_extended_wait)
1020 (linux_process_target::wait_1)
1021 (linux_process_target::install_software_single_step_breakpoints)
1022 (linux_process_target::single_step)
1023 (linux_process_target::thread_needs_step_over)
1024 (linux_process_target::proceed_one_lwp)
1025 (linux_process_target::supports_range_stepping)
1027 * linux-x86-low.cc (the_low_target): Remove the op field.
1028 * linux-aarch64-low.cc (the_low_target): Ditto.
1029 * linux-bfin-low.cc (the_low_target): Ditto.
1030 * linux-cris-low.cc (the_low_target): Ditto.
1031 * linux-crisv32-low.cc (the_low_target): Ditto.
1032 * linux-m32r-low.cc (the_low_target): Ditto.
1033 * linux-m68k-low.cc (the_low_target): Ditto.
1034 * linux-mips-low.cc (the_low_target): Ditto.
1035 * linux-nios2-low.cc (the_low_target): Ditto.
1036 * linux-ppc-low.cc (the_low_target): Ditto.
1037 * linux-riscv-low.cc (the_low_target): Ditto.
1038 * linux-s390-low.cc (the_low_target): Ditto.
1039 * linux-sh-low.cc (the_low_target): Ditto.
1040 * linux-sparc-low.cc (the_low_target): Ditto.
1041 * linux-tic6x-low.cc (the_low_target): Ditto.
1042 * linux-tile-low.cc (the_low_target): Ditto.
1043 * linux-xtensa-low.cc (the_low_target): Ditto.
1044 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1045 <supports_software_single_step>: Declare.
1046 (arm_target::supports_software_single_step): Define.
1047 (arm_gdbserver_get_next_pcs): Turn into...
1048 (arm_target::low_get_next_pcs): ...this.
1049 (the_low_target): Remove the op field.
1051 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1053 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1054 the concrete linux target define it by overriding the op
1055 in process_stratum_target.
1057 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1059 * linux-low.h (struct linux_target_ops): Remove the op.
1060 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1061 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1063 (x86_sw_breakpoint_from_kind): Turn into...
1064 (x86_target::sw_breakpoint_from_kind): ...this.
1065 (the_low_target): Remove the op field.
1066 * linux-aarch64-low.cc (class aarch64_target)
1067 <sw_breakpoint_from_kind>: Declare.
1068 (aarch64_sw_breakpoint_from_kind): Turn into...
1069 (aarch64_target::sw_breakpoint_from_kind): ...this.
1070 (the_low_target): Remove the op field.
1071 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1073 (arm_target::sw_breakpoint_from_kind): Define.
1074 (the_low_target): Remove the op field.
1075 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1077 (bfin_sw_breakpoint_from_kind): Turn into...
1078 (bfin_target::sw_breakpoint_from_kind): ...this.
1079 (the_low_target): Remove the op field.
1080 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1082 (cris_sw_breakpoint_from_kind): Turn into...
1083 (cris_target::sw_breakpoint_from_kind): ...this.
1084 (the_low_target): Remove the op field.
1085 * linux-crisv32-low.cc (class crisv32_target)
1086 <sw_breakpoint_from_kind>: Declare.
1087 (cris_sw_breakpoint_from_kind): Turn into...
1088 (crisv32_target::sw_breakpoint_from_kind): ...this.
1089 (the_low_target): Remove the op field.
1090 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1092 (ia64_target::sw_breakpoint_from_kind): Define.
1093 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1095 (m32r_sw_breakpoint_from_kind): Turn into...
1096 (m32r_target::sw_breakpoint_from_kind): ...this.
1097 (the_low_target): Remove the op field.
1098 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1100 (m68k_sw_breakpoint_from_kind): Turn into...
1101 (m68k_target::sw_breakpoint_from_kind): ...this.
1102 (the_low_target): Remove the op field.
1103 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1105 (mips_sw_breakpoint_from_kind): Turn into...
1106 (mips_target::sw_breakpoint_from_kind): ...this.
1107 (the_low_target): Remove the op field.
1108 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1110 (nios2_sw_breakpoint_from_kind): Turn into...
1111 (nios2_target::sw_breakpoint_from_kind): ...this.
1112 (the_low_target): Remove the op field.
1113 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1115 (ppc_sw_breakpoint_from_kind): Turn into...
1116 (ppc_target::sw_breakpoint_from_kind): ...this.
1117 (the_low_target): Remove the op field.
1118 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1120 (riscv_sw_breakpoint_from_kind): Turn into...
1121 (riscv_target::sw_breakpoint_from_kind): ...this.
1122 (the_low_target): Remove the op field.
1123 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1125 (s390_sw_breakpoint_from_kind): Turn into...
1126 (s390_target::sw_breakpoint_from_kind): ...this.
1127 (the_low_target): Remove the op field.
1128 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1130 (sh_sw_breakpoint_from_kind): Turn into...
1131 (sh_target::sw_breakpoint_from_kind): ...this.
1132 (the_low_target): Remove the op field.
1133 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1135 (sparc_sw_breakpoint_from_kind): Turn into...
1136 (sparc_target::sw_breakpoint_from_kind): ...this.
1137 (the_low_target): Remove the op field.
1138 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1140 (tic6x_sw_breakpoint_from_kind): Turn into...
1141 (tic6x_target::sw_breakpoint_from_kind): ...this.
1142 (the_low_target): Remove the op field.
1143 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1145 (tile_sw_breakpoint_from_kind): Turn into...
1146 (tile_target::sw_breakpoint_from_kind): ...this.
1147 (the_low_target): Remove the op field.
1148 * linux-xtensa-low.cc (class xtensa_target)
1149 <sw_breakpoint_from_kind>: Declare.
1150 (xtensa_sw_breakpoint_from_kind): Turn into...
1151 (xtensa_target::sw_breakpoint_from_kind): ...this.
1152 (the_low_target): Remove the op field.
1154 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1156 Remove the 'breakpoint_kind_from_pc' and
1157 'breakpoint_kind_from_current_state' linux target ops, and let the
1158 concrete linux target define them by overriding the ops of
1159 process_stratum_target.
1161 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1163 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1164 * linux-low.h (struct linux_target_ops): Remove ops.
1165 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1166 <breakpoint_kind_from_current_state>: Remove.
1167 * linux-x86-low.cc (the_low_target): Remove the op fields.
1168 * linux-bfin-low.cc (the_low_target): Ditto.
1169 * linux-cris-low.cc (the_low_target): Ditto.
1170 * linux-crisv32-low.cc (the_low_target): Ditto.
1171 * linux-m32r-low.cc (the_low_target): Ditto.
1172 * linux-m68k-low.cc (the_low_target): Ditto.
1173 * linux-mips-low.cc (the_low_target): Ditto.
1174 * linux-nios2-low.cc (the_low_target): Ditto.
1175 * linux-ppc-low.cc (the_low_target): Ditto.
1176 * linux-s390-low.cc (the_low_target): Ditto.
1177 * linux-sh-low.cc (the_low_target): Ditto.
1178 * linux-sparc-low.cc (the_low_target): Ditto.
1179 * linux-tic6x-low.cc (the_low_target): Ditto.
1180 * linux-tile-low.cc (the_low_target): Ditto.
1181 * linux-xtensa-low.cc (the_low_target): Ditto.
1182 * linux-aarch64-low.cc (class aarch64_target)
1183 <breakpoint_kind_from_pc>
1184 <breakpoint_kind_from_current_state>: Declare.
1185 (aarch64_breakpoint_kind_from_pc): Turn into...
1186 (aarch64_target::breakpoint_kind_from_pc): ...this.
1187 (aarch64_breakpoint_kind_from_current_state): Turn into...
1188 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1189 (the_low_target): Remove the op fields.
1190 * linux-arm-low.cc (class arm_target):
1191 <breakpoint_kind_from_pc>
1192 <breakpoint_kind_from_current_state>: Declare.
1193 (arm_target::breakpoint_kind_from_pc): Define.
1194 (arm_target::breakpoint_kind_from_current_state): Define.
1195 (the_low_target): Remove the op fields.
1196 * linux-riscv-low.cc (class riscv_target):
1197 <breakpoint_kind_from_pc>: Declare.
1198 (riscv_breakpoint_kind_from_pc): Turn into...
1199 (riscv_target::breakpoint_kind_from_pc): ...this.
1200 (the_low_target): Remove the op fields.
1202 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1204 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1205 of linux_process_target.
1207 * linux-low.h (struct linux_target_ops): Remove the ops.
1208 (class linux_process_target) <low_supports_breakpoints>
1210 <low_set_pc>: Declare.
1211 * linux-low.cc (supports_breakpoints): Turn into...
1212 (linux_process_target::low_supports_breakpoints): ...this.
1213 (linux_process_target::low_get_pc): Define.
1214 (linux_process_target::low_set_pc): Define.
1216 Update the callers below.
1218 (linux_process_target::get_pc)
1219 (linux_process_target::save_stop_reason)
1220 (linux_process_target::maybe_move_out_of_jump_pad)
1221 (linux_process_target::wait_1)
1222 (linux_process_target::resume_one_lwp_throw)
1223 (linux_process_target::resume)
1224 (linux_process_target::proceed_all_lwps)
1225 (linux_process_target::read_pc)
1226 (linux_process_target::write_pc)
1228 * linux-x86-low.cc (class linux_process_target)
1229 <low_supports_breakpoints>
1231 <low_set_pc>: Declare.
1232 (x86_target::low_supports_breakpoints): Define.
1233 (x86_get_pc): Turn into...
1234 (x86_target::low_get_pc): ...this.
1235 (x86_set_pc): Turn into...
1236 (x86_target::low_set_pc): ...this.
1237 (the_low_target): Remove the op fields.
1238 * linux-arm-low.cc (class arm_target)
1239 <low_supports_breakpoints>
1241 <low_set_pc>: Declare.
1242 (arm_target::low_supports_breakpoints)
1243 (arm_target::low_get_pc)
1244 (arm_target::low_set_pc): Define.
1245 (the_low_target): Remove the op fields.
1246 * linux-bfin-low.cc (class bfin_target)
1247 <low_supports_breakpoints>
1249 <low_set_pc>: Declare.
1250 (bfin_target::low_supports_breakpoints)
1251 (bfin_target::low_get_pc)
1252 (bfin_target::low_set_pc): Define.
1253 (the_low_target): Remove the op fields.
1254 * linux-cris-low.cc (class cris_target)
1255 <low_supports_breakpoints>
1257 <low_set_pc>: Declare.
1258 (cris_target::low_supports_breakpoints)
1259 (cris_target::low_get_pc)
1260 (cris_target::low_set_pc): Define.
1261 (the_low_target): Remove the op fields.
1262 * linux-crisv32-low.cc (class crisv32_target)
1263 <low_supports_breakpoints>
1265 <low_set_pc>: Declare.
1266 (crisv32_target::low_supports_breakpoints)
1267 (crisv32_target::low_get_pc)
1268 (crisv32_target::low_set_pc): Define.
1269 (the_low_target): Remove the op fields.
1270 * linux-m32r-low.cc (class m32r_target)
1271 <low_supports_breakpoints>
1273 <low_set_pc>: Declare.
1274 (m32r_target::low_supports_breakpoints)
1275 (m32r_target::low_get_pc)
1276 (m32r_target::low_set_pc): Define.
1277 (the_low_target): Remove the op fields.
1278 * linux-m68k-low.cc (class m68k_target)
1279 <low_supports_breakpoints>
1281 <low_set_pc>: Declare.
1282 (m68k_target::low_supports_breakpoints)
1283 (m68k_target::low_get_pc)
1284 (m68k_target::low_set_pc): Define.
1285 (the_low_target): Remove the op fields.
1286 * linux-nios2-low.cc (class nios2_target)
1287 <low_supports_breakpoints>
1289 <low_set_pc>: Declare.
1290 (nios2_target::low_supports_breakpoints)
1291 (nios2_target::low_get_pc)
1292 (nios2_target::low_set_pc): Define.
1293 (the_low_target): Remove the op fields.
1294 * linux-sh-low.cc (class sh_target)
1295 <low_supports_breakpoints>
1297 <low_set_pc>: Declare.
1298 (sh_target::low_supports_breakpoints)
1299 (sh_target::low_get_pc)
1300 (sh_target::low_set_pc): Define.
1301 (the_low_target): Remove the op fields.
1302 * linux-xtensa-low.cc (class xtensa_target)
1303 <low_supports_breakpoints>
1305 <low_set_pc>: Declare.
1306 (xtensa_target::low_supports_breakpoints)
1307 (xtensa_target::low_get_pc)
1308 (xtensa_target::low_set_pc): Define.
1309 (the_low_target): Remove the op fields.
1310 * linux-sparc-low.cc (class sparc_target)
1311 <low_supports_breakpoints>
1312 <low_get_pc>: Declare.
1313 (sparc_target::low_supports_breakpoints)
1314 (sparc_target::low_get_pc): Define.
1315 (the_low_target): Remove the op fields.
1316 * linux-tile-low.cc (class tile_target)
1317 <low_supports_breakpoints>
1319 <low_set_pc>: Declare.
1320 (tile_target::low_supports_breakpoints)
1321 (tile_target::low_get_pc)
1322 (tile_target::low_set_pc): Define.
1323 (the_low_target): Remove the op fields.
1324 * linux-aarch64-low.cc (class aarch64_target)
1325 <low_supports_breakpoints>
1327 <low_set_pc>: Declare.
1328 (aarch64_target::low_supports_breakpoints): Define.
1329 (aarch64_get_pc): Turn into...
1330 (aarch64_target::low_get_pc): ...this.
1331 (aarch64_set_pc): Turn into...
1332 (aarch64_target::low_set_pc): ...this.
1333 (the_low_target): Remove the op fields.
1334 * linux-mips-low.cc (class mips_target)
1335 <low_supports_breakpoints>
1337 <low_set_pc>: Declare.
1338 (mips_target::low_supports_breakpoints): Define.
1339 (mips_get_pc): Turn into...
1340 (mips_target::low_get_pc): ...this.
1341 (mips_set_pc): Turn into...
1342 (mips_target::low_set_pc): ...this.
1343 (the_low_target): Remove the op fields.
1344 * linux-ppc-low.cc (class ppc_target)
1345 <low_supports_breakpoints>
1347 <low_set_pc>: Declare.
1348 (ppc_target::low_supports_breakpoints): Define.
1349 (ppc_get_pc): Turn into...
1350 (ppc_target::low_get_pc): ...this.
1351 (ppc_set_pc): Turn into...
1352 (ppc_target::low_set_pc): ...this.
1353 (the_low_target): Remove the op fields.
1354 * linux-riscv-low.cc (class riscv_target)
1355 <low_supports_breakpoints>
1357 <low_set_pc>: Declare.
1358 (riscv_target::low_supports_breakpoints): Define.
1359 (riscv_get_pc): Turn into...
1360 (riscv_target::low_get_pc): ...this.
1361 (riscv_set_pc): Turn into...
1362 (riscv_target::low_set_pc): ...this.
1363 (the_low_target): Remove the op fields.
1364 * linux-s390-low.cc (class s390_target)
1365 <low_supports_breakpoints>
1367 <low_set_pc>: Declare.
1368 (s390_target::low_supports_breakpoints): Define.
1369 (s390_get_pc): Turn into...
1370 (s390_target::low_get_pc): ...this.
1371 (s390_set_pc): Turn into...
1372 (s390_target::low_set_pc): ...this.
1373 (the_low_target): Remove the op fields.
1374 * linux-tic6x-low.cc (class tic6x_target)
1375 <low_supports_breakpoints>
1377 <low_set_pc>: Declare.
1378 (tic6x_target::low_supports_breakpoints): Define.
1379 (tic6x_get_pc): Turn into...
1380 (tic6x_target::low_get_pc): ...this.
1381 (tic6x_set_pc): Turn into...
1382 (tic6x_target::low_set_pc): ...this.
1383 (the_low_target): Remove the op fields.
1385 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1387 Turn some more static methods in linux-low into private methods
1388 of linux_process_target.
1390 * linux-low.cc (get_pc): Turn into...
1391 (linux_process_target::get_pc): ...this.
1392 (save_stop_reason): Turn into...
1393 (linux_process_target::save_stop_reason): ...this.
1394 (thread_still_has_status_pending_p): Turn into...
1395 (linux_process_target::thread_still_has_status_pending): ...this.
1396 (status_pending_p_callback): Turn into...
1397 (linux_process_target::status_pending_p_callback): ...this.
1398 (resume_stopped_resumed_lwps): Turn into...
1399 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1400 (install_software_single_step_breakpoints): Turn into...
1401 (linux_process_target::install_software_single_step_breakpoints):
1403 (single_step): Turn into...
1404 (linux_process_target::single_step): ...this.
1405 (linux_resume_one_lwp_throw): Turn into...
1406 (linux_process_target::resume_one_lwp_throw): ...this.
1407 (linux_resume_one_lwp): Turn into...
1408 (linux_process_target::resume_one_lwp): ...this.
1409 (resume_status_pending_p): Turn into...
1410 (linux_process_target::resume_status_pending): ...this.
1411 (need_step_over_p): Turn into...
1412 (linux_process_target::thread_needs_step_over): ...this.
1413 (linux_resume_one_thread): Turn into...
1414 (linux_process_target::resume_one_thread): ...this.
1415 (proceed_one_lwp): Turn into...
1416 (linux_process_target::proceed_one_lwp): ...this.
1417 (unsuspend_and_proceed_one_lwp): Turn into...
1418 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1420 Update the calls/references to the above functions below.
1422 (linux_process_target::handle_extended_wait)
1423 (linux_process_target::filter_event)
1424 (linux_process_target::wait_for_event_filtered)
1425 (linux_process_target::wait_1)
1426 (linux_process_target::move_out_of_jump_pad)
1427 (linux_process_target::start_step_over)
1428 (linux_process_target::resume)
1429 (linux_process_target::proceed_all_lwps)
1430 (regsets_store_inferior_registers)
1431 (linux_process_target::store_register)
1433 * linux-low.h (class linux_process_target)
1436 <thread_still_has_status_pending>
1437 <status_pending_p_callback>
1438 <resume_stopped_resumed_lwps>
1439 <install_software_single_step_breakpoints>
1441 <resume_one_lwp_throw>
1443 <resume_status_pending>
1444 <thread_needs_step_over>
1447 <unsuspend_and_proceed_one_lwp>: Declare.
1449 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1451 Turn the 'fetch_register' linux target op into a method of
1452 linux_process_target.
1454 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1455 (class linux_process_target) <low_fetch_register>: Declare.
1456 * linux-x86-low.cc (the_low_target)
1457 * linux-aarch64-low.cc (the_low_target)
1458 * linux-arm-low.cc (the_low_target)
1459 * linux-bfin-low.cc (the_low_target)
1460 * linux-cris-low.cc (the_low_target)
1461 * linux-crisv32-low.cc (the_low_target)
1462 * linux-m32r-low.cc (the_low_target)
1463 * linux-m68k-low.cc (the_low_target)
1464 * linux-nios2-low.cc (the_low_target)
1465 * linux-ppc-low.cc (the_low_target)
1466 * linux-s390-low.cc (the_low_target)
1467 * linux-sh-low.cc (the_low_target)
1468 * linux-sparc-low.cc (the_low_target)
1469 * linux-tic6x-low.cc (the_low_target)
1470 * linux-tile-low.cc (the_low_target)
1471 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1472 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1474 (ia64_fetch_register): Turn into...
1475 (ia64_target::low_fetch_register): ...this.
1476 (the_low_target): Remove the op field.
1477 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1479 (mips_fetch_register): Turn into...
1480 (mips_target::low_fetch_register): ...this.
1481 (the_low_target): Remove the op field.
1482 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1484 (riscv_fetch_register): Turn into...
1485 (riscv_target::low_fetch_register): ...this.
1486 (the_low_target): Remove the op field.
1488 Update the callers below.
1490 * linux-low.cc (linux_process_target::fetch_registers)
1491 (linux_process_target::low_fetch_register)
1493 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1495 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1496 linux target ops into methods of linux_process_target.
1498 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1499 (class linux_process_target) <fetch_register>
1501 <usr_fetch_inferior_registers>
1502 <usr_store_inferior_registers>
1503 <low_cannot_fetch_register>
1504 <low_cannot_fetch_register> Declare.
1505 * linux-low.cc (fetch_register): Turn into...
1506 (linux_process_target::fetch_register): ...this.
1507 (store_register): Turn into ...
1508 (linux_process_target::store_register): ...this.
1509 (usr_fetch_inferior_registers): Turn into...
1510 (linux_process_target::usr_fetch_inferior_registers): ...this.
1511 (usr_store_inferior_registers): Turn into...
1512 (linux_process_target::usr_store_inferior_registers): ...this.
1513 * linux-x86-low.cc (class x86_target)
1514 <low_cannot_fetch_register>
1515 <low_cannot_store_register>: Declare.
1516 (x86_cannot_store_register): Turn into...
1517 (x86_target::low_cannot_store_register): ...this.
1518 (x86_cannot_fetch_register): Turn into...
1519 (x86_target::low_cannot_fetch_register): ...this.
1520 (the_low_target): Remove the target op fields.
1521 * linux-aarch64-low.cc (class aarch64_target)
1522 <low_cannot_fetch_register>
1523 <low_cannot_store_register>: Declare.
1524 (aarch64_target::low_cannot_fetch_register)
1525 (aarch64_target::low_cannot_store_register): Define.
1526 (the_low_target): Remove the op fields.
1527 * linux-arm-low.cc (class arm_target)
1528 <low_cannot_fetch_register>
1529 <low_cannot_store_register>: Declare.
1530 (arm_cannot_fetch_register): Turn into...
1531 (arm_target::low_cannot_fetch_register): ...this.
1532 (arm_cannot_store_register): Turn into...
1533 (arm_target::low_cannot_store_register): ...this.
1534 (the_low_target): Remove the op fields.
1535 * linux-bfin-low.cc (class bfin_target)
1536 <low_cannot_fetch_register>
1537 <low_cannot_store_register>: Declare.
1538 (bfin_cannot_fetch_register): Turn into...
1539 (bfin_target::low_cannot_fetch_register): ...this.
1540 (bfin_cannot_store_register): Turn into...
1541 (bfin_target::low_cannot_store_register): ...this.
1542 (the_low_target): Remove the op fields.
1543 * linux-cris-low.cc (class cris_target)
1544 <low_cannot_fetch_register>
1545 <low_cannot_store_register>: Declare.
1546 (cris_cannot_fetch_register): Turn into...
1547 (cris_target::low_cannot_fetch_register): ...this.
1548 (cris_cannot_store_register): Turn into...
1549 (cris_target::low_cannot_store_register): ...this.
1550 (the_low_target): Remove the op fields.
1551 * linux-crisv32-low.cc (class crisv32_target)
1552 <low_cannot_fetch_register>
1553 <low_cannot_store_register>: Declare.
1554 (crisv32_target::low_cannot_fetch_register)
1555 (crisv32_target::low_cannot_store_register): Define.
1556 (the_low_target): Remove the op fields.
1557 * linux-ia64-low.cc (class ia64_target)
1558 <low_cannot_fetch_register>
1559 <low_cannot_store_register>: Declare.
1560 (ia64_cannot_fetch_register): Turn into...
1561 (ia64_target::low_cannot_fetch_register): ...this.
1562 (ia64_cannot_store_register): Turn into...
1563 (ia64_target::low_cannot_store_register): ...this.
1564 (the_low_target): Remove the op fields.
1565 * linux-m32r-low.cc (class m32r_target)
1566 <low_cannot_fetch_register>
1567 <low_cannot_store_register>: Declare.
1568 (m32r_cannot_fetch_register): Turn into...
1569 (m32r_target::low_cannot_fetch_register): ...this.
1570 (m32r_cannot_store_register): Turn into...
1571 (m32r_target::low_cannot_store_register): ...this.
1572 (the_low_target): Remove the op fields.
1573 * linux-m68k-low.cc (class m68k_target)
1574 <low_cannot_fetch_register>
1575 <low_cannot_store_register>: Declare.
1576 (m68k_cannot_fetch_register): Turn into...
1577 (m68k_target::low_cannot_fetch_register): ...this.
1578 (m68k_cannot_store_register): Turn into...
1579 (m68k_target::low_cannot_store_register): ...this.
1580 (the_low_target): Remove the op fields.
1581 * linux-mips-low.cc (class mips_target)
1582 <low_cannot_fetch_register>
1583 <low_cannot_store_register>: Declare.
1584 (mips_cannot_fetch_register): Turn into...
1585 (mips_target::low_cannot_fetch_register): ...this.
1586 (mips_cannot_store_register): Turn into...
1587 (mips_target::low_cannot_store_register): ...this.
1588 (get_usrregs_info): Inline at the call sites in
1589 low_cannot_fetch_register and low_cannot_store_register,
1591 (the_low_target): Remove the op fields.
1592 * linux-nios2-low.cc (class nios2_target)
1593 <low_cannot_fetch_register>
1594 <low_cannot_store_register>: Declare.
1595 (nios2_cannot_fetch_register): Turn into...
1596 (nios2_target::low_cannot_fetch_register): ...this.
1597 (nios2_cannot_store_register): Turn into...
1598 (nios2_target::low_cannot_store_register): ...this.
1599 (the_low_target): Remove the op fields.
1600 * linux-ppc-low.cc (class ppc_target)
1601 <low_cannot_fetch_register>
1602 <low_cannot_store_register>: Declare.
1603 (ppc_cannot_fetch_register): Turn into...
1604 (ppc_target::low_cannot_fetch_register): ...this.
1605 (ppc_cannot_store_register): Turn into...
1606 (ppc_target::low_cannot_store_register): ...this.
1607 (the_low_target): Remove the op fields.
1608 * linux-riscv-low.cc (class riscv_target)
1609 <low_cannot_fetch_register>
1610 <low_cannot_store_register>: Declare.
1611 (riscv_target::low_cannot_fetch_register)
1612 (riscv_target::low_cannot_store_register): Define.
1613 (the_low_target): Remove the op fields.
1614 * linux-s390-low.cc (class s390_target)
1615 <low_cannot_fetch_register>
1616 <low_cannot_store_register>: Declare.
1617 (s390_cannot_fetch_register): Turn into...
1618 (s390_target::low_cannot_fetch_register): ...this.
1619 (s390_cannot_store_register): Turn into...
1620 (s390_target::low_cannot_store_register): ...this.
1621 (the_low_target): Remove the op fields.
1622 * linux-sh-low.cc (class sh_target)
1623 <low_cannot_fetch_register>
1624 <low_cannot_store_register>: Declare.
1625 (sh_cannot_fetch_register): Turn into...
1626 (sh_target::low_cannot_fetch_register): ...this.
1627 (sh_cannot_store_register): Turn into...
1628 (sh_target::low_cannot_store_register): ...this.
1629 (the_low_target): Remove the op fields.
1630 * linux-sparc-low.cc (class sparc_target)
1631 <low_cannot_fetch_register>
1632 <low_cannot_store_register>: Declare.
1633 (sparc_cannot_fetch_register): Turn into...
1634 (sparc_target::low_cannot_fetch_register): ...this.
1635 (sparc_cannot_store_register): Turn into...
1636 (sparc_target::low_cannot_store_register): ...this.
1637 (the_low_target): Remove the op fields.
1638 * linux-tic6x-low.cc (class tic6x_target)
1639 <low_cannot_fetch_register>
1640 <low_cannot_store_register>: Declare.
1641 (tic6x_cannot_fetch_register): Turn into...
1642 (tic6x_target::low_cannot_fetch_register): ...this.
1643 (tic6x_cannot_store_register): Turn into...
1644 (tic6x_target::low_cannot_store_register): ...this.
1645 (the_low_target): Remove the op fields.
1646 * linux-tile-low.cc (class tile_target)
1647 <low_cannot_fetch_register>
1648 <low_cannot_store_register>: Declare.
1649 (tile_cannot_fetch_register): Turn into...
1650 (tile_target::low_cannot_fetch_register): ...this.
1651 (tile_cannot_store_register): Turn into...
1652 (tile_target::low_cannot_store_register): ...this.
1653 (the_low_target): Remove the op fields.
1654 * linux-xtensa-low.cc (class xtensa_target)
1655 <low_cannot_fetch_register>
1656 <low_cannot_store_register>: Declare.
1657 (xtensa_target::low_cannot_fetch_register)
1658 (xtensa_target::low_cannot_store_register): Define.
1659 (the_low_target): Remove the op fields.
1661 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1663 Turn the 'regs_info' linux target op into a method of
1664 linux_process_target.
1666 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1667 (class linux_process_target) <get_regs_info>: Define.
1669 Update the callers below.
1671 * linux-low.cc (linux_process_target::fetch_registers)
1672 (linux_process_target::store_registers)
1673 * proc-service.cc (gregset_info)
1675 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1676 (x86_linux_regs_info): Turn into ...
1677 (x86_target::get_regs_info): ...this.
1678 (the_low_target): Remove the op field.
1679 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1681 (aarch64_regs_info): Turn into ...
1682 (aarch64_target::get_regs_info): ...this.
1683 (the_low_target): Remove the op field.
1684 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1685 (arm_regs_info): Turn into ...
1686 (arm_target::get_regs_info): ...this.
1687 (the_low_target): Remove the op field.
1688 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1689 (bfin_regs_info): Turn into ...
1690 (bfin_target::get_regs_info): ...this.
1691 (the_low_target): Remove the op field.
1692 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1693 (cris_regs_info): Turn into ...
1694 (cris_target::get_regs_info): ...this.
1695 (the_low_target): Remove the op field.
1696 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1698 (crisv32_regs_info): Turn into ...
1699 (crisv32_target::get_regs_info): ...this.
1700 (the_low_target): Remove the op field.
1701 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1702 (ia64_regs_info): Turn into ...
1703 (ia64_target::get_regs_info): ...this.
1704 (the_low_target): Remove the op field.
1705 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1706 (m32r_regs_info): Turn into ...
1707 (m32r_target::get_regs_info): ...this.
1708 (the_low_target): Remove the op field.
1709 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1710 (m68k_regs_info): Turn into ...
1711 (m68k_target::get_regs_info): ...this.
1712 (the_low_target): Remove the op field.
1713 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1714 (mips_regs_info): Turn into ...
1715 (mips_target::get_regs_info): ...this.
1716 (the_low_target): Remove the op field.
1717 (get_usrregs_info): Update the call to the op.
1718 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1719 (nios2_regs_info): Turn into ...
1720 (nios2_target::get_regs_info): ...this.
1721 (the_low_target): Remove the op field.
1722 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1723 (ppc_regs_info): Turn into ...
1724 (ppc_target::get_regs_info): ...this.
1725 (the_low_target): Remove the op field.
1726 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1727 (riscv_regs_info): Turn into ...
1728 (riscv_target::get_regs_info): ...this.
1729 (the_low_target): Remove the op field.
1730 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1731 (s390_regs_info): Turn into ...
1732 (s390_target::get_regs_info): ...this.
1733 (the_low_target): Remove the op field.
1734 (s390_collect_ptrace_register)
1735 (s390_supply_ptrace_register)
1736 (s390_fill_gregset): Update the call to the op.
1737 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1738 (sh_regs_info): Turn into ...
1739 (sh_target::get_regs_info): ...this.
1740 (the_low_target): Remove the op field.
1741 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1742 (sparc_regs_info): Turn into ...
1743 (sparc_target::get_regs_info): ...this.
1744 (the_low_target): Remove the op field.
1745 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1746 (tic6x_regs_info): Turn into ...
1747 (tic6x_target::get_regs_info): ...this.
1748 (the_low_target): Remove the op field.
1749 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1750 (tile_regs_info): Turn into ...
1751 (tile_target::get_regs_info): ...this.
1752 (the_low_target): Remove the op field.
1753 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1755 (xtensa_regs_info): Turn into ...
1756 (xtensa_target::get_regs_info): ...this.
1757 (the_low_target): Remove the op field.
1759 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1761 Turn the 'arch_setup' linux target op into a method of
1762 linux_process_target.
1764 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1765 (class linux_process_target) <arch_setup_thread>
1766 <low_arch_setup>: New declarations.
1767 * linux-low.cc (linux_arch_setup): Delete.
1768 (linux_arch_setup_thread): Turn into...
1769 (linux_process_target::arch_setup_thread): ... this.
1771 Update the callers below.
1773 (linux_process_target::handle_extended_wait)
1774 (linux_process_target::post_create_inferior)
1775 (linux_process_target::filter_event)
1777 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1779 (x86_linux_update_xmltarget): Turn into...
1780 (x86_target::update_xmltarget): ...this.
1781 (x86_linux_process_qsupported): Update the call to
1782 x86_linux_update_xmltarget.
1783 (x86_arch_setup): Turn into ...
1784 (x86_target::low_arch_setup): ...this.
1785 (the_low_target): Remove the op field.
1786 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1788 (aarch64_arch_setup): Turn into ...
1789 (aarch64_target::low_arch_setup): ...this.
1790 (the_low_target): Remove the op field.
1791 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1793 (arm_arch_setup): Turn into ...
1794 (arm_target::low_arch_setup): ...this.
1795 (the_low_target): Remove the op field.
1796 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1798 (bfin_arch_setup): Turn into ...
1799 (bfin_target::low_arch_setup): ...this.
1800 (the_low_target): Remove the op field.
1801 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1803 (cris_arch_setup): Turn into ...
1804 (cris_target::low_arch_setup): ...this.
1805 (the_low_target): Remove the op field.
1806 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1808 (crisv32_arch_setup): Turn into ...
1809 (crisv32_target::low_arch_setup): ...this.
1810 (the_low_target): Remove the op field.
1811 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1813 (ia64_arch_setup): Turn into ...
1814 (ia64_target::low_arch_setup): ...this.
1815 (the_low_target): Remove the op field.
1816 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1818 (m32r_arch_setup): Turn into ...
1819 (m32r_target::low_arch_setup): ...this.
1820 (the_low_target): Remove the op field.
1821 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1823 (m68k_arch_setup): Turn into ...
1824 (m68k_target::low_arch_setup): ...this.
1825 (the_low_target): Remove the op field.
1826 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1828 (mips_arch_setup): Turn into ...
1829 (mips_target::low_arch_setup): ...this.
1830 (the_low_target): Remove the op field.
1831 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1833 (nios2_arch_setup): Turn into ...
1834 (nios2_target::low_arch_setup): ...this.
1835 (the_low_target): Remove the op field.
1836 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1838 (ppc_arch_setup): Turn into ...
1839 (ppc_target::low_arch_setup): ...this.
1840 (the_low_target): Remove the op field.
1841 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1843 (riscv_arch_setup): Turn into ...
1844 (riscv_target::low_arch_setup): ...this.
1845 (the_low_target): Remove the op field.
1846 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1848 (s390_arch_setup): Turn into ...
1849 (s390_target::low_arch_setup): ...this.
1850 (the_low_target): Remove the op field.
1851 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1853 (sh_arch_setup): Turn into ...
1854 (sh_target::low_arch_setup): ...this.
1855 (the_low_target): Remove the op field.
1856 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1858 (sparc_arch_setup): Turn into ...
1859 (sparc_target::low_arch_setup): ...this.
1860 (the_low_target): Remove the op field.
1861 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1863 (tic6x_arch_setup): Turn into ...
1864 (tic6x_target::low_arch_setup): ...this.
1865 (the_low_target): Remove the op field.
1866 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1868 (tile_arch_setup): Turn into ...
1869 (tile_target::low_arch_setup): ...this.
1870 (the_low_target): Remove the op field.
1871 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1873 (xtensa_arch_setup): Turn into ...
1874 (xtensa_target::low_arch_setup): ...this.
1875 (the_low_target): Remove the op field.
1877 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1879 * linux-low.h (the_linux_target): New extern declaration.
1880 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1882 (the_linux_target): Remove.
1883 * linux-x86-low.cc (class x86_target): New class.
1884 (the_x86_target): New static object.
1885 (the_linux_target): Define as pointer to the_x86_target.
1886 * linux-aarch64-low.cc (class aarch64_target): New class.
1887 (the_aarch64_target): New static object.
1888 (the_linux_target): Define as pointer to the_aarch64_target.
1889 * linux-arm-low.cc (class arm_target): New class.
1890 (the_arm_target): New static object.
1891 (the_linux_target): Define as pointer to the_arm_target.
1892 * linux-bfin-low.cc (class bfin_target): New class.
1893 (the_bfin_target): New static object.
1894 (the_linux_target): Define as pointer to the_bfin_target.
1895 * linux-cris-low.cc (class cris_target): New class.
1896 (the_cris_target): New static object.
1897 (the_linux_target): Define as pointer to the_cris_target.
1898 * linux-crisv32-low.cc (class crisv32_target): New class.
1899 (the_crisv32_target): New static object.
1900 (the_linux_target): Define as pointer to the_crisv32_target.
1901 * linux-ia64-low.cc (class ia64_target): New class.
1902 (the_ia64_target): New static object.
1903 (the_linux_target): Define as pointer to the_ia64_target.
1904 * linux-m32r-low.cc (class m32r_target): New class.
1905 (the_m32r_target): New static object.
1906 (the_linux_target): Define as pointer to the_m32r_target.
1907 * linux-m68k-low.cc (class m68k_target): New class.
1908 (the_m68k_target): New static object.
1909 (the_linux_target): Define as pointer to the_m68k_target.
1910 * linux-mips-low.cc (class mips_target): New class.
1911 (the_mips_target): New static object.
1912 (the_linux_target): Define as pointer to the_mips_target.
1913 * linux-nios2-low.cc (class nios2_target): New class.
1914 (the_nios2_target): New static object.
1915 (the_linux_target): Define as pointer to the_nios2_target.
1916 * linux-ppc-low.cc (class ppc_target): New class.
1917 (the_ppc_target): New static object.
1918 (the_linux_target): Define as pointer to the_ppc_target.
1919 * linux-riscv-low.cc (class riscv_target): New class.
1920 (the_riscv_target): New static object.
1921 (the_linux_target): Define as pointer to the_riscv_target.
1922 * linux-s390-low.cc (class s390_target): New class.
1923 (the_s390_target): New static object.
1924 (the_linux_target): Define as pointer to the_s390_target.
1925 * linux-sh-low.cc (class sh_target): New class.
1926 (the_sh_target): New static object.
1927 (the_linux_target): Define as pointer to the_sh_target.
1928 * linux-sparc-low.cc (class sparc_target): New class.
1929 (the_sparc_target): New static object.
1930 (the_linux_target): Define as pointer to the_sparc_target.
1931 * linux-tic6x-low.cc (class tic6x_target): New class.
1932 (the_tic6x_target): New static object.
1933 (the_linux_target): Define as pointer to the_tic6x_target.
1934 * linux-tile-low.cc (class tile_target): New class.
1935 (the_tile_target): New static object.
1936 (the_linux_target): Define as pointer to the_tile_target.
1937 * linux-xtensa-low.cc (class xtensa_target): New class.
1938 (the_xtensa_target): New static object.
1939 (the_linux_target): Define as pointer to the_xtensa_target.
1941 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1943 Turn some static functions in linux-low.cc into private methods of
1944 linux_process_target.
1946 * linux-low.cc (handle_extended_wait): Turn into ...
1947 (linux_process_target::handle_extended_wait): ...this. Call
1948 'mourn' on 'this' object instead of 'the_target'.
1949 (maybe_move_out_of_jump_pad): Turn into...
1950 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
1951 (linux_low_filter_event): Turn into...
1952 (linux_process_target::filter_event): ...this.
1953 (linux_wait_for_event_filtered): Turn into...
1954 (linux_process_target::wait_for_event_filtered): ...this.
1955 (linux_wait_for_event): Turn into...
1956 (linux_process_target::wait_for_event): ...this.
1957 (linux_wait_1): Turn into...
1958 (linux_process_target::wait_1): ...this.
1959 (wait_for_sigstop): Turn into...
1960 (linux_process_target::wait_for_sigstop): ...this.
1961 (move_out_of_jump_pad_callback): Turn into...
1962 (linux_process_target::move_out_of_jump_pad): ...this.
1963 (stop_all_lwps): Turn into...
1964 (linux_process_target::stop_all_lwps): ...this.
1965 (start_step_over): Turn into...
1966 (linux_process_target::start_step_over): ...this.
1967 (complete_ongoing_step_over): Turn into...
1968 (linux_process_target::complete_ongoing_step_over): ...this.
1969 (proceed_all_lwps): Turn into...
1970 (linux_process_target::proceed_all_lwps): ...this.
1971 (unstop_all_lwps): Turn into...
1972 (linux_process_target::unstop_all_lwps): ...this.
1974 * linux-low.h (class linux_process_target)
1975 <handle_extended_wait>
1976 <maybe_move_out_of_jump_pad>
1978 <wait_for_event_filtered>
1982 <move_out_of_jump_pad>
1985 <complete_ongoing_step_over>
1987 <unstop_all_lwps>: Declare.
1989 Update the callers below.
1991 * linux-low.cc (linux_process_target::attach): Update.
1992 (linux_process_target::stabilize_threads): Ditto.
1993 (linux_process_target::wait): Ditto.
1995 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1997 * linux-low.h (struct linux_target_ops): Update the comment for
1998 'cannot_store_register' to return 0 or 1.
1999 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2002 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
2004 * config.in: Re-generate.
2005 * configure: Re-generate.
2007 2020-03-17 Kamil Rytarowski <n54@gmx.com>
2009 * regcache.cc (find_register_by_number): Update.
2010 * tdesc.cc (init_target_desc): Likewise.
2011 * tdesc.h (target_desc::reg_defs): Likewise.
2013 2020-03-12 Tom Tromey <tom@tromey.com>
2015 * configure: Rebuild.
2016 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2017 (WIN32APILIBS): New subst.
2018 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2020 (gdbsupport/%.o): Remove target.
2021 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2022 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2023 (WIN32APILIBS): New variable.
2024 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2025 (gdbreplay$(EXEEXT)): Likewise.
2027 2020-03-12 Tom Tromey <tom@tromey.com>
2029 * config.in, configure: Rebuild.
2030 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2031 * acinclude.m4: Include gettext-sister.m4.
2032 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2034 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2035 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2037 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2039 * acinclude.m4: Update path to selftest.m4.
2041 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2043 * configure.ac: Don't source bfd/development.sh, move
2044 GDB_AC_COMMON higher.
2045 * configure: Re-generate.
2047 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2049 * configure: Re-generate.
2051 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
2053 * configure: Re-generate.
2055 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2057 * .dir-locals.el: New file.
2059 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2061 * .gitattributes: New file.
2063 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2065 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2066 reply into an S reply.
2067 * server.cc (disable_packet_T): New global.
2068 (captured_main): Set new global when appropriate.
2069 * server.h (disable_packet_T): Declare.
2071 2020-02-21 Tom Tromey <tom@tromey.com>
2073 * Makefile.in (mostlyclean): New target.
2075 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2077 * target.h (struct process_stratum_target): Remove.
2078 (class process_target): Rename to ...
2079 (class process_stratum_target): ... this.
2080 * linux-low.h (class linux_process_target): Derive from
2081 'process_stratum_target'.
2082 * linux-low.cc (linux_target_ops): Remove.
2083 (initialize_low): Set the_target to the singleton instance of
2084 linux_process_target.
2085 * lynx-low.h (class lynx_process_target): Derive from
2086 'process_stratum_target'.
2087 * lynx-low.cc (lynx_target_ops): Remove.
2088 (initialize_low): Set the_target to the singleton instance of
2089 lynx_process_target.
2090 * nto-low.h (class nto_process_target): Derive from
2091 'process_stratum_target'.
2092 * nto-low.cc (nto_target_ops): Remove.
2093 (initialize_low): Set the_target to the singleton instance of
2095 * win32-low.h (class win32_process_target): Derive from
2096 'process_stratum_target'.
2097 * win32-low.cc (win32_target_ops): Remove.
2098 (initialize_low): Set the_target to the singleton instance of
2099 win32_process_target.
2101 Replace 'the_target->pt' with 'the_target' in the uses below.
2103 * hostio.cc (hostio_error)
2108 * linux-aarch32-low.cc (arm_breakpoint_at)
2109 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2110 * linux-arm-low.cc (arm_sigreturn_next_pc)
2112 (arm_get_syscall_trapinfo)
2113 * linux-cris-low.cc (cris_breakpoint_at)
2114 * linux-crisv32-low.cc (cris_breakpoint_at)
2115 * linux-low.cc (handle_extended_wait)
2118 (linux_process_target::breakpoint_kind_from_pc)
2120 * linux-m32r-low.cc (m32r_breakpoint_at)
2121 * linux-mips-low.cc (mips_breakpoint_at)
2122 * linux-nios2-low.cc (nios2_breakpoint_at)
2123 * linux-ppc-low.cc (ppc_breakpoint_at)
2124 * linux-s390-low.cc (s390_get_hwcap)
2125 * linux-sh-low.cc (sh_breakpoint_at)
2126 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2127 (sparc_store_gregset_from_stack)
2128 (sparc_breakpoint_at)
2129 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2130 * linux-tile-low.cc (tile_breakpoint_at)
2131 * linux-x86-low.cc (x86_breakpoint_at)
2132 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2133 * mem-break.cc (bp_size)
2135 (insert_memory_breakpoint)
2136 (set_raw_breakpoint_at)
2137 (delete_raw_breakpoint)
2139 (uninsert_raw_breakpoint)
2140 (reinsert_raw_breakpoint)
2141 (validate_inserted_breakpoint)
2142 * regcache.cc (regcache_read_pc)
2144 * remote-utils.cc (putpkt_binary_1)
2147 (prepare_resume_reply)
2148 * server.cc (handle_general_set)
2151 (handle_qxfer_exec_file)
2152 (handle_qxfer_libraries_svr4)
2153 (handle_qxfer_osdata)
2154 (handle_qxfer_siginfo)
2155 (handle_qxfer_fdpic)
2159 (queue_stop_reply_callback)
2161 * target.cc (prepare_to_access_memory)
2162 (done_accessing_memory)
2163 (read_inferior_memory)
2164 (target_write_memory)
2165 (target_stop_and_wait)
2167 (target_mourn_inferior)
2168 (target_continue_no_signal)
2170 (target_supports_multi_process)
2173 (target_create_inferior)
2174 (target_post_create_inferior)
2176 (target_supports_fork_events)
2177 (target_supports_vfork_events)
2178 (target_supports_exec_events)
2179 (target_handle_new_gdb_connection)
2182 (fetch_inferior_registers)
2183 (store_inferior_registers)
2185 (target_supports_non_stop)
2187 (target_process_qsupported)
2188 (target_supports_catch_syscall)
2189 (target_get_ipa_tdesc_idx)
2190 (target_supports_tracepoints)
2191 (target_supports_fast_tracepoints)
2192 (target_get_min_fast_tracepoint_insn_len)
2193 (target_thread_stopped)
2195 (target_unpause_all)
2196 (target_stabilize_threads)
2197 (target_install_fast_tracepoint_jump_pad)
2199 (target_supports_disable_randomization)
2200 (target_supports_agent)
2201 (target_enable_btrace)
2202 (target_disable_btrace)
2203 (target_read_btrace)
2204 (target_read_btrace_conf)
2205 (target_supports_range_stepping)
2206 (target_supports_stopped_by_sw_breakpoint)
2207 (target_stopped_by_sw_breakpoint)
2208 (target_supports_stopped_by_hw_breakpoint)
2209 (target_supports_hardware_single_step)
2210 (target_stopped_by_hw_breakpoint)
2211 (target_breakpoint_kind_from_pc)
2212 (target_breakpoint_kind_from_current_state)
2213 (target_supports_software_single_step)
2214 (target_core_of_thread)
2215 (target_thread_name)
2216 (target_thread_handle)
2217 * win32-low.cc (do_initial_child_stuff)
2219 Rename target op default definitions listed below.
2221 * target.cc (process_target::post_create_inferior): Rename as ...
2222 (process_stratum_target::post_create_inferior): ... this.
2223 (process_target::prepare_to_access_memory): Rename as ...
2224 (process_stratum_target::prepare_to_access_memory): ... this.
2225 (process_target::done_accessing_memory): Rename as ...
2226 (process_stratum_target::done_accessing_memory): ... this.
2227 (process_target::look_up_symbols): Rename as ...
2228 (process_stratum_target::look_up_symbols): ... this.
2229 (process_target::supports_read_auxv): Rename as ...
2230 (process_stratum_target::supports_read_auxv): ... this.
2231 (process_target::read_auxv): Rename as ...
2232 (process_stratum_target::read_auxv): ... this.
2233 (process_target::supports_z_point_type): Rename as ...
2234 (process_stratum_target::supports_z_point_type): ... this.
2235 (process_target::insert_point): Rename as ...
2236 (process_stratum_target::insert_point): ... this.
2237 (process_target::remove_point): Rename as ...
2238 (process_stratum_target::remove_point): ... this.
2239 (process_target::stopped_by_sw_breakpoint): Rename as ...
2240 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2241 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2242 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2243 (process_target::stopped_by_hw_breakpoint): Rename as ...
2244 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2245 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2246 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2247 (process_target::supports_hardware_single_step): Rename as ...
2248 (process_stratum_target::supports_hardware_single_step): ... this.
2249 (process_target::stopped_by_watchpoint): Rename as ...
2250 (process_stratum_target::stopped_by_watchpoint): ... this.
2251 (process_target::stopped_data_address): Rename as ...
2252 (process_stratum_target::stopped_data_address): ... this.
2253 (process_target::supports_read_offsets): Rename as ...
2254 (process_stratum_target::supports_read_offsets): ... this.
2255 (process_target::read_offsets): Rename as ...
2256 (process_stratum_target::read_offsets): ... this.
2257 (process_target::supports_get_tls_address): Rename as ...
2258 (process_stratum_target::supports_get_tls_address): ... this.
2259 (process_target::get_tls_address): Rename as ...
2260 (process_stratum_target::get_tls_address): ... this.
2261 (process_target::hostio_last_error): Rename as ...
2262 (process_stratum_target::hostio_last_error): ... this.
2263 (process_target::supports_qxfer_osdata): Rename as ...
2264 (process_stratum_target::supports_qxfer_osdata): ... this.
2265 (process_target::qxfer_osdata): Rename as ...
2266 (process_stratum_target::qxfer_osdata): ... this.
2267 (process_target::supports_qxfer_siginfo): Rename as ...
2268 (process_stratum_target::supports_qxfer_siginfo): ... this.
2269 (process_target::qxfer_siginfo): Rename as ...
2270 (process_stratum_target::qxfer_siginfo): ... this.
2271 (process_target::supports_non_stop): Rename as ...
2272 (process_stratum_target::supports_non_stop): ... this.
2273 (process_target::async): Rename as ...
2274 (process_stratum_target::async): ... this.
2275 (process_target::start_non_stop): Rename as ...
2276 (process_stratum_target::start_non_stop): ... this.
2277 (process_target::supports_multi_process): Rename as ...
2278 (process_stratum_target::supports_multi_process): ... this.
2279 (process_target::supports_fork_events): Rename as ...
2280 (process_stratum_target::supports_fork_events): ... this.
2281 (process_target::supports_vfork_events): Rename as ...
2282 (process_stratum_target::supports_vfork_events): ... this.
2283 (process_target::supports_exec_events): Rename as ...
2284 (process_stratum_target::supports_exec_events): ... this.
2285 (process_target::handle_new_gdb_connection): Rename as ...
2286 (process_stratum_target::handle_new_gdb_connection): ... this.
2287 (process_target::handle_monitor_command): Rename as ...
2288 (process_stratum_target::handle_monitor_command): ... this.
2289 (process_target::core_of_thread): Rename as ...
2290 (process_stratum_target::core_of_thread): ... this.
2291 (process_target::supports_read_loadmap): Rename as ...
2292 (process_stratum_target::supports_read_loadmap): ... this.
2293 (process_target::read_loadmap): Rename as ...
2294 (process_stratum_target::read_loadmap): ... this.
2295 (process_target::process_qsupported): Rename as ...
2296 (process_stratum_target::process_qsupported): ... this.
2297 (process_target::supports_tracepoints): Rename as ...
2298 (process_stratum_target::supports_tracepoints): ... this.
2299 (process_target::read_pc): Rename as ...
2300 (process_stratum_target::read_pc): ... this.
2301 (process_target::write_pc): Rename as ...
2302 (process_stratum_target::write_pc): ... this.
2303 (process_target::supports_thread_stopped): Rename as ...
2304 (process_stratum_target::supports_thread_stopped): ... this.
2305 (process_target::thread_stopped): Rename as ...
2306 (process_stratum_target::thread_stopped): ... this.
2307 (process_target::supports_get_tib_address): Rename as ...
2308 (process_stratum_target::supports_get_tib_address): ... this.
2309 (process_target::get_tib_address): Rename as ...
2310 (process_stratum_target::get_tib_address): ... this.
2311 (process_target::pause_all): Rename as ...
2312 (process_stratum_target::pause_all): ... this.
2313 (process_target::unpause_all): Rename as ...
2314 (process_stratum_target::unpause_all): ... this.
2315 (process_target::stabilize_threads): Rename as ...
2316 (process_stratum_target::stabilize_threads): ... this.
2317 (process_target::supports_fast_tracepoints): Rename as ...
2318 (process_stratum_target::supports_fast_tracepoints): ... this.
2319 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2320 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2321 (process_target::emit_ops): Rename as ...
2322 (process_stratum_target::emit_ops): ... this.
2323 (process_target::supports_disable_randomization): Rename as ...
2324 (process_stratum_target::supports_disable_randomization): ... this.
2325 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2326 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2327 (process_target::qxfer_libraries_svr4): Rename as ...
2328 (process_stratum_target::qxfer_libraries_svr4): ... this.
2329 (process_target::supports_agent): Rename as ...
2330 (process_stratum_target::supports_agent): ... this.
2331 (process_target::enable_btrace): Rename as ...
2332 (process_stratum_target::enable_btrace): ... this.
2333 (process_target::disable_btrace): Rename as ...
2334 (process_stratum_target::disable_btrace): ... this.
2335 (process_target::read_btrace): Rename as ...
2336 (process_stratum_target::read_btrace): ... this.
2337 (process_target::read_btrace_conf): Rename as ...
2338 (process_stratum_target::read_btrace_conf): ... this.
2339 (process_target::supports_range_stepping): Rename as ...
2340 (process_stratum_target::supports_range_stepping): ... this.
2341 (process_target::supports_pid_to_exec_file): Rename as ...
2342 (process_stratum_target::supports_pid_to_exec_file): ... this.
2343 (process_target::pid_to_exec_file): Rename as ...
2344 (process_stratum_target::pid_to_exec_file): ... this.
2345 (process_target::supports_multifs): Rename as ...
2346 (process_stratum_target::supports_multifs): ... this.
2347 (process_target::multifs_open): Rename as ...
2348 (process_stratum_target::multifs_open): ... this.
2349 (process_target::multifs_unlink): Rename as ...
2350 (process_stratum_target::multifs_unlink): ... this.
2351 (process_target::multifs_readlink): Rename as ...
2352 (process_stratum_target::multifs_readlink): ... this.
2353 (process_target::breakpoint_kind_from_pc): Rename as ...
2354 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2355 (process_target::breakpoint_kind_from_current_state): Rename as ...
2356 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2357 (process_target::thread_name): Rename as ...
2358 (process_stratum_target::thread_name): ... this.
2359 (process_target::thread_handle): Rename as ...
2360 (process_stratum_target::thread_handle): ... this.
2361 (process_target::supports_software_single_step): Rename as ...
2362 (process_stratum_target::supports_software_single_step): ... this.
2363 (process_target::supports_catch_syscall): Rename as ...
2364 (process_stratum_target::supports_catch_syscall): ... this.
2365 (process_target::get_ipa_tdesc_idx): Rename as ...
2366 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2368 2020-02-20 Pedro Alves <palves@redhat.com>
2370 * target.cc (set_target_ops): Simply copy the given target pointer
2371 instead of creating a copy of the pointed object.
2373 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2375 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2378 * target.h (struct process_stratum_target): Remove the target op.
2379 (class process_target): Add the target op.
2380 (target_get_ipa_tdesc_idx): Update the macro.
2381 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2383 Update the derived classes and callers below.
2385 * linux-low.cc (linux_target_ops): Update.
2386 (linux_get_ipa_tdesc_idx): Turn into ...
2387 (linux_process_target::get_ipa_tdesc_idx): ... this.
2388 * linux-low.h (class linux_process_target): Update.
2389 * lynx-low.cc (lynx_target_ops): Update.
2390 * nto-low.cc (nto_target_ops): Update.
2391 * win32-low.cc (win32_target_ops): Update.
2393 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2395 Turn process_stratum_target's supports_catch_syscall op into a
2396 method of process_target.
2398 * target.h (struct process_stratum_target): Remove the target op.
2399 (class process_target): Add the target op.
2400 (target_supports_catch_syscall): Update the macro.
2401 * target.cc (process_target::supports_catch_syscall): Define.
2403 Update the derived classes and callers below.
2405 * linux-low.cc (linux_target_ops): Update.
2406 (linux_supports_catch_syscall): Turn into ...
2407 (linux_process_target::supports_catch_syscall): ... this.
2408 * linux-low.h (class linux_process_target): Update.
2409 * lynx-low.cc (lynx_target_ops): Update.
2410 * nto-low.cc (nto_target_ops): Update.
2411 * win32-low.cc (win32_target_ops): Update.
2413 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2415 Turn process_stratum_target's supports_software_single_step op
2416 into a method of process_target.
2418 * target.h (struct process_stratum_target): Remove the target op.
2419 (class process_target): Add the target op.
2420 (target_supports_software_single_step): Update the macro.
2421 * target.cc (process_target::supports_software_single_step): Define.
2423 Update the derived classes and callers below.
2425 * linux-low.cc (linux_target_ops): Update.
2426 (linux_supports_software_single_step): Turn into ...
2427 (linux_process_target::supports_software_single_step): ... this.
2428 * linux-low.h (class linux_process_target): Update.
2429 * lynx-low.cc (lynx_target_ops): Update.
2430 * nto-low.cc (nto_target_ops): Update.
2431 * win32-low.cc (win32_target_ops): Update.
2433 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2435 Turn process_stratum_target's thread_name and thread_handle ops
2436 into methods of process_target.
2438 * target.h (struct process_stratum_target): Remove the target ops.
2439 (class process_target): Add the target ops.
2440 (target_thread_name): Update the macro.
2441 (target_thread_handle): Update the macro.
2442 * target.cc (process_target::thread_name): Define.
2443 (process_target::thread_handle): Define.
2445 Update the derived classes and callers below.
2447 * linux-low.cc (linux_target_ops): Update.
2448 (linux_process_target::thread_name): Define.
2449 (linux_process_target::thread_handle): Define.
2450 * linux-low.h (class linux_process_target): Update.
2451 * lynx-low.cc (lynx_target_ops): Update.
2452 * nto-low.cc (nto_target_ops): Update.
2453 * win32-low.cc (win32_target_ops): Update.
2455 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2457 Turn process_stratum_target's breakpoint_kind_from_pc,
2458 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2459 ops into methods of process_target.
2461 * target.h (struct process_stratum_target): Remove the target op.
2462 (class process_target): Add the target op.
2463 (target_breakpoint_kind_from_pc): Update the macro.
2464 (target_breakpoint_kind_from_current_state): Update the macro.
2465 (default_breakpoint_kind_from_pc): Remove declaration.
2466 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2467 (process_target::breakpoint_kind_from_pc): ... this.
2468 (process_target::breakpoint_kind_from_current_state): Define.
2470 Update the derived classes and callers below.
2472 * mem-break.cc (bp_size): Update.
2473 (bp_opcode): Update.
2474 * linux-low.cc (linux_target_ops): Update.
2475 (linux_wait_1): Update.
2476 (linux_breakpoint_kind_from_pc): Turn into ...
2477 (linux_process_target::breakpoint_kind_from_pc): ... this.
2478 (linux_sw_breakpoint_from_kind): Turn into ...
2479 (linux_process_target::sw_breakpoint_from_kind): ... this.
2480 (linux_breakpoint_kind_from_current_state): Turn into ...
2481 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2482 * linux-low.h (class linux_process_target): Update.
2483 * lynx-low.cc (lynx_target_ops): Update.
2484 (lynx_process_target::sw_breakpoint_from_kind): Define.
2485 * lynx-low.h (class lynx_process_target): Update.
2486 * nto-low.cc (nto_target_ops): Update.
2487 (nto_sw_breakpoint_from_kind): Turn into ...
2488 (nto_process_target::sw_breakpoint_from_kind): ... this.
2489 * nto-low.h (class nto_process_target): Update.
2490 * win32-low.cc (win32_target_ops): Update.
2491 (win32_sw_breakpoint_from_kind): Turn into ...
2492 (win32_process_target::sw_breakpoint_from_kind): ... this.
2493 * win32-low.h (class win32_process_target): Update.
2495 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2497 Turn process_stratum_target's multifs_open, multifs_readlink,
2498 multifs_unlink ops into methods of process_target.
2500 * target.h (struct process_stratum_target): Remove the target ops.
2501 (class process_target): Add the target ops. Also add
2503 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2505 (process_target::supports_multifs): Define.
2506 (process_target::multifs_open): Define.
2507 (process_target::multifs_readlink): Define.
2508 (process_target::multifs_unlink): Define.
2510 Update the derived classes and callers below.
2512 * hostio.cc (handle_setfs): Update.
2513 (handle_open): Update.
2514 (handle_unlink): Update.
2515 (handle_readlink): Update.
2516 * linux-low.cc (linux_target_ops): Update.
2517 (linux_process_target::supports_multifs): Define.
2518 (linux_process_target::multifs_open): Define.
2519 (linux_process_target::multifs_readlink): Define.
2520 (linux_process_target::multifs_unlink): Define.
2521 * linux-low.h (class linux_process_target): Update.
2522 * lynx-low.cc (lynx_target_ops): Update.
2523 * nto-low.cc (nto_target_ops): Update.
2524 * win32-low.cc (win32_target_ops): Update.
2526 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2528 Turn process_stratum_target's pid_to_exec_file op into a method
2531 * target.h (struct process_stratum_target): Remove the target op.
2532 (class process_target): Add the target op. Also add
2533 'supports_pid_to_exec_file'.
2534 * target.cc (process_target::pid_to_exec_file): Define.
2535 (process_target::supports_pid_to_exec_file): Define.
2537 Update the derived classes and callers below.
2539 * server.cc (handle_qxfer_exec_file): Update.
2540 (handle_query): Update.
2541 * linux-low.cc (linux_target_ops): Update.
2542 (linux_process_target::supports_pid_to_exec_file): Define.
2543 (linux_process_target::pid_to_exec_file): Define.
2544 * linux-low.h (class linux_process_target): Update.
2545 * lynx-low.cc (lynx_target_ops): Update.
2546 * nto-low.cc (nto_target_ops): Update.
2547 * win32-low.cc (win32_target_ops): Update.
2549 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2551 Turn process_stratum_target's supports_range_stepping op into a
2552 method of process_target.
2554 * target.h (struct process_stratum_target): Remove the target op.
2555 (class process_target): Add the target op.
2556 (target_supports_range_stepping): Update the macro.
2557 * target.cc (process_target::supports_range_stepping): Define.
2559 Update the derived classes and callers below.
2561 * linux-low.cc (linux_target_ops): Update.
2562 (linux_supports_range_stepping): Turn into ...
2563 (linux_process_target::supports_range_stepping): ... this.
2564 * linux-low.h (class linux_process_target): Update.
2565 * lynx-low.cc (lynx_target_ops): Update.
2566 * nto-low.cc (nto_target_ops): Update.
2567 * win32-low.cc (win32_target_ops): Update.
2569 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2571 Turn process_stratum_target's btrace-related ops (enable_btrace,
2572 disable_btrace, read_btrace, read_btrace_conf) into methods of
2575 * target.h (struct process_stratum_target): Remove the target ops.
2576 (class process_target): Add the target ops.
2577 (target_enable_btrace): Update.
2578 (target_disable_btrace): Update.
2579 (target_read_btrace): Update.
2580 (target_read_btrace_conf): Update.
2581 * target.cc (process_target::enable_btrace): Define.
2582 (process_target::disable_btrace): Define.
2583 (process_target::read_btrace): Define.
2584 (process_target::read_btrace_conf): Define.
2586 Update the derived classes and callers below.
2588 * linux-low.cc (linux_target_ops): Update.
2589 (linux_process_target:enable_btrace): Define as a wrapper around
2590 linux_enable_btrace.
2591 (linux_low_disable_btrace): Turn into ...
2592 (linux_process_target::disable_btrace): ... this.
2593 (linux_low_read_btrace): Turn into ...
2594 (linux_process_target::read_btrace): ... this.
2595 (linux_low_btrace_conf): Turn into ...
2596 (linux_process_target::read_btrace_conf): ... this.
2597 * linux-low.h (class linux_process_target): Update.
2598 * lynx-low.cc (lynx_target_ops): Update.
2599 * nto-low.cc (nto_target_ops): Update.
2600 * win32-low.cc (win32_target_ops): Update.
2602 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2604 Turn process_stratum_target's supports_agent op into a method of
2607 * target.h (struct process_stratum_target): Remove the target op.
2608 (class process_target): Add the target op.
2609 (target_supports_agent): Update the macro.
2610 * target.cc (process_target::supports_agent): Define.
2612 Update the derived classes and callers below.
2614 * linux-low.cc (linux_target_ops): Update.
2615 (linux_supports_agent): Turn into ...
2616 (linux_process_target::supports_agent): ... this.
2617 * linux-low.h (class linux_process_target): Update.
2618 * lynx-low.cc (lynx_target_ops): Update.
2619 * nto-low.cc (nto_target_ops): Update.
2620 * win32-low.cc (win32_target_ops): Update.
2622 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2624 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2625 method of process_target.
2627 * target.h (struct process_stratum_target): Remove the target op.
2628 (class process_target): Add the target op. Also add
2629 'supports_qxfer_libraries_svr4'.
2630 * target.cc (process_target::qxfer_libraries_svr4): Define.
2631 (process_target::supports_qxfer_libraries_svr4): Define.
2633 Update the derived classes and callers below.
2635 * server.cc (handle_qxfer_libraries_svr4): Update.
2636 (handle_query): Update.
2637 * linux-low.cc (linux_target_ops): Update.
2638 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2639 (linux_qxfer_libraries_svr4): Turn into ...
2640 (linux_process_target::qxfer_libraries_svr4): ... this.
2641 * linux-low.h (class linux_process_target): Update.
2642 * lynx-low.cc (lynx_target_ops): Update.
2643 * nto-low.cc (nto_target_ops): Update.
2644 * win32-low.cc (win32_target_ops): Update.
2646 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2648 Turn process_stratum_target's supports_disable_randomization op
2649 into a method of process_target.
2651 * target.h (struct process_stratum_target): Remove the target op.
2652 (class process_target): Add the target op.
2653 (target_supports_disable_randomization): Update the macro.
2654 * target.cc (process_target::supports_disable_randomization): Define.
2656 Update the derived classes and callers below.
2658 * linux-low.cc (linux_target_ops): Update.
2659 (linux_supports_disable_randomization): Turn into ...
2660 (linux_process_target::supports_disable_randomization): ... this.
2661 * linux-low.h (class linux_process_target): Update.
2662 * lynx-low.cc (lynx_target_ops): Update.
2663 * nto-low.cc (nto_target_ops): Update.
2664 * win32-low.cc (win32_target_ops): Update.
2666 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2668 Turn process_stratum_target's emit_ops op into a method of
2671 * target.h (struct process_stratum_target): Remove the target op.
2672 (class process_target): Add the target op.
2673 (target_emit_ops): Update the macro.
2674 * target.cc (process_target::emit_ops): Define.
2676 Update the derived classes and callers below.
2678 * linux-low.cc (linux_target_ops): Update.
2679 (linux_emit_ops): Turn into ...
2680 (linux_process_target::emit_ops): ... this.
2681 * linux-low.h (class linux_process_target): Update.
2682 * lynx-low.cc (lynx_target_ops): Update.
2683 * nto-low.cc (nto_target_ops): Update.
2684 * win32-low.cc (win32_target_ops): Update.
2686 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2688 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2689 and get_min_fast_tracepoint_insn_len ops into methods of
2692 * target.h (struct process_stratum_target): Remove the target ops.
2693 (class process_target): Add the target ops. Also add
2694 'supports_fast_tracepoints'.
2695 (target_supports_fast_tracepoints): Update the macro.
2696 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2697 (install_fast_tracepoint_jump_pad): Update and rename the macro
2699 (target_install_fast_tracepoint_jump_pad): ... this.
2700 * target.cc (process_target::supports_fast_tracepoints): Define.
2701 (process_target::install_fast_tracepoint_jump_pad): Define.
2702 (process_target::get_min_fast_tracepoint_insn_len): Define.
2704 Update the derived classes and callers below.
2706 * tracepoint.cc (install_fast_tracepoint): Update.
2707 * linux-low.cc (linux_target_ops): Update.
2708 (linux_process_target::supports_fast_tracepoints): Define.
2709 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2710 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2711 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2712 (linux_process_target::get_min_fast_tracepoint_insn_len): ... 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 stabilize_threads op into a
2721 method of process_target.
2723 * target.h (struct process_stratum_target): Remove the target op.
2724 (class process_target): Add the target op.
2725 (target_stabilize_threads): Update the macro.
2726 * target.cc (process_target::stabilize_threads): Define.
2728 Update the derived classes and callers below.
2730 * server.cc (handle_status): Update.
2731 * tracepoint.cc (cmd_qtdp): Update.
2732 (cmd_qtstart): Update.
2733 * linux-low.cc (linux_target_ops): Update.
2734 (linux_stabilize_threads): Turn into ...
2735 (linux_process_target::stabilize_threads): ... this.
2736 (linux_wait_1): Update.
2737 * linux-low.h (class linux_process_target): Update.
2738 * lynx-low.cc (lynx_target_ops): Update.
2739 * nto-low.cc (nto_target_ops): Update.
2740 * win32-low.cc (win32_target_ops): Update.
2742 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2744 Turn process_stratum_target's pause_all and unpause_all ops
2745 into methods of process_target.
2747 * target.h (struct process_stratum_target): Remove the target ops.
2748 (class process_target): Add the target ops.
2749 (pause_all): Update the macro and rename to...
2750 (target_pause_all): ... this.
2751 (unpause_all): Update the macro and rename to...
2752 (target_unpause_all): ... this.
2753 * target.cc (process_target::pause_all): Define.
2754 (process_target::unpause_all): Define.
2756 Update the derived classes and callers below.
2758 * server.cc (handle_status): Update.
2759 * tracepoint.cc (clear_installed_tracepoints): Update.
2761 (cmd_qtstart): Update.
2762 (stop_tracing): Update.
2763 (cmd_qtstatus): Update.
2764 (upload_fast_traceframes): Update.
2765 (run_inferior_command): Update.
2766 * linux-low.cc (linux_target_ops): Update.
2767 (linux_pause_all): Turn into ...
2768 (linux_process_target::pause_all): ... this.
2769 (linux_unpause_all): Turn into ...
2770 (linux_process_target::unpause_all): ... this.
2771 (linux_process_target::prepare_to_access_memory): Update.
2772 (linux_process_target::done_accessing_memory): Update.
2773 * linux-low.h (class linux_process_target): Update.
2774 * lynx-low.cc (lynx_target_ops): Update.
2775 * nto-low.cc (nto_target_ops): Update.
2776 * win32-low.cc (win32_target_ops): Update.
2778 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2780 Turn process_stratum_target's get_tib_address op into a method of
2783 * target.h (struct process_stratum_target): Remove the target op.
2784 (class process_target): Add the target op. Also add
2785 'supports_get_tib_address'.
2786 * target.cc (process_target::get_tib_address): Define.
2787 (process_target::supports_get_tib_address): Define.
2789 Update the derived classes and callers below.
2791 * server.cc (handle_query): Update.
2792 * linux-low.cc (win32_target_ops): Update.
2793 * lynx-low.cc (lynx_target_ops): Update.
2794 * nto-low.cc (nto_target_ops): Update.
2795 * win32-low.cc (win32_target_ops): Update.
2796 (win32_process_target::supports_get_tib_address): Define.
2797 (win32_get_tib_address): Turn into ...
2798 (win32_process_target::get_tib_address): ... this.
2799 * win32-low.h (class win32_process_target): Update.
2801 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2803 Turn process_stratum_target's thread_stopped op into a method of
2806 * target.h (struct process_stratum_target): Remove the target op.
2807 (class process_target): Add the target op. Also add
2808 'supports_thread_stopped'.
2809 (target_thread_stopped): Update the macro.
2810 * target.cc (process_target::thread_stopped): Define.
2811 (process_target::supports_thread_stopped): Define.
2812 (prepare_to_access_memory): Update.
2814 Update the derived classes and callers below.
2816 * server.cc (queue_stop_reply_callback): Update.
2817 * linux-low.cc (linux_target_ops): Update.
2818 (linux_process_target::supports_thread_stopped): Define.
2819 (linux_thread_stopped): Turn into ...
2820 (linux_process_target::thread_stopped): ... this.
2821 * linux-low.h (class linux_process_target): Update.
2822 * lynx-low.cc (lynx_target_ops): Update.
2823 * nto-low.cc (nto_target_ops): Update.
2824 * win32-low.cc (win32_target_ops): Update.
2826 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2828 Turn process_stratum_target's read_pc and write_pc ops into
2829 methods of process_target.
2831 * target.h (struct process_stratum_target): Remove the target ops.
2832 (class process_target): Add the target ops.
2833 * target.cc (process_target::read_pc): Define.
2834 (process_target::write_pc): Define.
2836 Update the derived classes and callers below.
2838 * regcache.cc (regcache_read_pc): Update.
2839 (regcache_write_pc): Update.
2840 * linux-low.cc (linux_target_ops): Update.
2841 (linux_read_pc): Turn into ...
2842 (linux_process_target::read_pc): ... this.
2843 (linux_write_pc): Turn into ...
2844 (linux_process_target::write_pc): ... this.
2845 * linux-low.h (class linux_process_target): Update.
2846 * lynx-low.cc (lynx_target_ops): Update.
2847 * nto-low.cc (nto_target_ops): Update.
2848 * win32-low.cc (win32_target_ops): Update.
2850 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2852 Turn process_stratum_target's supports_tracepoints op into a
2853 method of process_target.
2855 * target.h (struct process_stratum_target): Remove the target op.
2856 (class process_target): Add the target op.
2857 (target_supports_tracepoints): Update the macro.
2858 * target.cc (process_target::supports_tracepoints): Define.
2860 Update the derived classes and callers below.
2862 * linux-low.cc (linux_target_ops): Update.
2863 (linux_supports_tracepoints): Turn into ...
2864 (linux_process_target::supports_tracepoints): ... this.
2865 * linux-low.h (class linux_process_target): Update.
2866 * lynx-low.cc (lynx_target_ops): Update.
2867 * nto-low.cc (nto_target_ops): Update.
2868 * win32-low.cc (win32_target_ops): Update.
2870 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2872 Turn process_stratum_target's process_qsupported op into a method
2875 * target.h (struct process_stratum_target): Remove the target op.
2876 (class process_target): Add the target op.
2877 (target_process_qsupported): Update the macro.
2878 * target.cc (process_target::process_qsupported): Define.
2880 Update the derived classes and callers below.
2882 * linux-low.cc (linux_target_ops): Update.
2883 (linux_process_qsupported): Turn into ...
2884 (linux_process_target::process_qsupported): ... this.
2885 * linux-low.h (class linux_process_target): Update.
2886 * lynx-low.cc (lynx_target_ops): Update.
2887 * nto-low.cc (nto_target_ops): Update.
2888 * win32-low.cc (win32_target_ops): Update.
2890 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2892 Turn process_stratum_target's read_loadmap op into a method of
2895 * target.h (struct process_stratum_target): Remove the target op.
2896 (class process_target): Add the target op. Also add
2897 'supports_read_loadmap'.
2898 * target.cc (process_target::read_loadmap): Define.
2899 (process_target::supports_read_loadmap): Define.
2901 Update the derived classes and callers below.
2903 * server.cc (handle_qxfer_fdpic): Update.
2904 (handle_query): Update.
2905 * linux-low.cc (linux_target_ops): Update.
2906 (linux_process_target::supports_read_loadmap): Define.
2907 (linux_read_loadmap): Turn into ...
2908 (linux_process_target::read_loadmap): ... this.
2909 * linux-low.h (class linux_process_target): Update.
2910 * lynx-low.cc (lynx_target_ops): Update.
2911 * nto-low.cc (nto_target_ops): Update.
2912 * win32-low.cc (win32_target_ops): Update.
2914 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2916 Turn process_stratum_target's core_of_thread op into a method of
2919 * target.h (struct process_stratum_target): Remove the target op.
2920 (class process_target): Add the target op.
2921 (target_core_of_thread): Update the macro.
2922 * target.cc (process_target::core_of_thread): Define.
2924 Update the derived classes and callers below.
2926 * linux-low.cc (linux_target_ops): Update.
2927 (linux_process_target::core_of_thread): Define.
2928 * linux-low.h (class linux_process_target): Update.
2929 * lynx-low.cc (lynx_target_ops): Update.
2930 * nto-low.cc (nto_target_ops): Update.
2931 * win32-low.cc (win32_target_ops): Update.
2933 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2935 Turn process_stratum_target's handle_monitor_command op into a
2936 method of process_target.
2938 * target.h (struct process_stratum_target): Remove the target op.
2939 (class process_target): Add the target op.
2940 (target_handle_monitor_command): Update the macro.
2941 * target.cc (process_target::handle_monitor_command): Define.
2943 Update the derived classes and callers below.
2945 * server.cc (handle_query): Update.
2946 * linux-low.cc (linux_target_ops): Update.
2947 (linux_process_target::handle_monitor_command): Define.
2948 * linux-low.h (class linux_process_target): Update.
2949 * lynx-low.cc (lynx_target_ops): Update.
2950 * nto-low.cc (nto_target_ops): Update.
2951 * win32-low.cc (win32_target_ops): Update.
2953 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2955 Turn process_stratum_target's handle_new_gdb_connection op into a
2956 method of process_target.
2958 * target.h (struct process_stratum_target): Remove the target op.
2959 (class process_target): Add the target op.
2960 (target_handle_new_gdb_connection): Update the macro.
2961 * target.cc (process_target::handle_new_gdb_connection): Define.
2963 Update the derived classes and callers below.
2965 * linux-low.cc (linux_target_ops): Update.
2966 (linux_handle_new_gdb_connection): Turn into ...
2967 (linux_process_target::handle_new_gdb_connection): ... this.
2968 * linux-low.h (class linux_process_target): Update.
2969 * lynx-low.cc (lynx_target_ops): Update.
2970 * nto-low.cc (nto_target_ops): Update.
2971 * win32-low.cc (win32_target_ops): Update.
2973 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2975 Turn process_stratum_target's supports_fork_events,
2976 supports_vfork_events, and supports_exec_events ops into methods
2979 * target.h (struct process_stratum_target): Remove the target ops.
2980 (class process_target): Add the target ops.
2981 (target_supports_fork_events): Update the macro.
2982 (target_supports_vfork_events): Update the macro.
2983 (target_supports_exec_events): Update the macro.
2984 * target.cc (process_target::supports_fork_events): Define.
2985 (process_target::supports_vfork_events): Define.
2986 (process_target::supports_exec_events): Define.
2988 Update the derived classes and callers below.
2990 * linux-low.cc (linux_target_ops): Update.
2991 (linux_supports_fork_events): Turn into ...
2992 (linux_process_target::supports_fork_events): ... this.
2993 (linux_supports_vfork_events): Turn into ...
2994 (linux_process_target::supports_vfork_events): ... this.
2995 (linux_supports_exec_events): Turn into ...
2996 (linux_process_target::supports_exec_events): ... this.
2997 * linux-low.h (class linux_process_target): Update.
2998 * lynx-low.cc (lynx_target_ops): Update.
2999 * nto-low.cc (nto_target_ops): Update.
3000 * win32-low.cc (win32_target_ops): Update.
3002 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3004 Turn process_stratum_target's supports_multi_process op into a
3005 method of process_target.
3007 * target.h (struct process_stratum_target): Remove the target op.
3008 (class process_target): Add the target op.
3009 * target.cc (process_target::supports_multi_process): Define.
3010 (target_supports_multi_process): Update.
3012 Update the derived classes and callers below.
3014 * linux-low.cc (linux_target_ops): Update.
3015 (linux_supports_multi_process): Turn into ...
3016 (linux_process_target::supports_multi_process): ... this.
3017 * linux-low.h (class linux_process_target): Update.
3018 * lynx-low.cc (lynx_target_ops): Update.
3019 * nto-low.cc (nto_target_ops): Update.
3020 * win32-low.cc (win32_target_ops): Update.
3022 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3024 Turn process_stratum_target's supports_non_stop, async, and
3025 start_non_stop ops into methods of process_target.
3027 * target.h (struct process_stratum_target): Remove the target ops.
3028 (class process_target): Add the target ops.
3029 (target_supports_non_stop): Update the macro.
3030 (target_async): Update the macro.
3031 (start_non_stop): Remove declaration.
3032 * target.cc (process_target::supports_non_stop): Define.
3033 (process_target::async): Define.
3034 (process_target::start_non_stop): Define.
3035 (start_non_stop): Remove.
3037 Update the derived classes and callers below.
3039 * server.cc (handle_qxfer_siginfo): Update.
3040 (handle_query): Update.
3041 * linux-low.cc (linux_target_ops): Update.
3042 (linux_supports_non_stop): Turn into ...
3043 (linux_process_target::supports_non_stop): ... this.
3044 (linux_async): Turn into ...
3045 (linux_process_target::async): ... this.
3046 (linux_start_non_stop): Turn into ...
3047 (linux_process_target::start_non_stop): ... this.
3048 * linux-low.h (class linux_process_target): Update.
3049 * lynx-low.cc (lynx_target_ops): Update.
3050 * nto-low.cc (nto_target_ops): Update.
3051 (nto_supports_non_stop): Remove; rely on the default behavior
3053 * win32-low.cc (win32_target_ops): Update.
3055 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3057 Turn process_stratum_target's qxfer_siginfo op into a method of
3060 * target.h (struct process_stratum_target): Remove the target op.
3061 (class process_target): Add the target op. Also add
3062 'supports_qxfer_siginfo'.
3063 * target.cc (process_target::qxfer_siginfo): Define.
3064 (process_target::supports_qxfer_siginfo): Define.
3066 Update the derived classes and callers below.
3068 * server.cc (handle_qxfer_siginfo): Update.
3069 (handle_query): Update.
3070 * linux-low.cc (linux_target_ops): Update.
3071 (linux_process_target::supports_qxfer_siginfo): Define.
3072 (linux_xfer_siginfo): Turn into ...
3073 (linux_process_target::qxfer_siginfo): ... this.
3074 * linux-low.h (class linux_process_target): Update.
3075 * lynx-low.cc (lynx_target_ops): Update.
3076 * nto-low.cc (nto_target_ops): Update.
3077 * win32-low.cc (win32_target_ops): Update.
3079 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3081 Turn process_stratum_target's qxfer_osdata op into a method of
3084 * target.h (struct process_stratum_target): Remove the target op.
3085 (class process_target): Add the target op. Also add
3086 'supports_qxfer_osdata'.
3087 * target.cc (process_target::qxfer_osdata): Define.
3088 (process_target::supports_qxfer_osdata): Define.
3090 Update the derived classes and callers below.
3092 * server.cc (handle_qxfer_osdata): Update.
3093 (handle_query): Update.
3094 * linux-low.cc (linux_target_ops): Update.
3095 (linux_process_target::supports_qxfer_osdata): Define.
3096 (linux_qxfer_osdata): Turn into ...
3097 (linux_process_target::qxfer_osdata): ... this.
3098 * linux-low.h (class linux_process_target): Update.
3099 * lynx-low.cc (lynx_target_ops): Update.
3100 * nto-low.cc (nto_target_ops): Update.
3101 * win32-low.cc (win32_target_ops): Update.
3103 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3105 Turn process_stratum_target's hostio_last_error op into a
3106 method of process_target.
3108 * target.h (struct process_stratum_target): Remove the target op.
3109 (class process_target): Add the target op.
3110 * target.cc: Add "hostio.h" to includes.
3111 (process_target::hostio_last_error): Define.
3113 Update the derived classes and callers below.
3115 * hostio.cc (hostio_error): Update.
3116 * linux-low.cc: Remove "hostio.h" from includes.
3117 (linux_target_ops): Update.
3118 * lynx-low.cc (lynx_target_ops): Update.
3119 * nto-low.cc (nto_target_ops): Update.
3120 * win32-low.h (class win32_process_target): Update.
3121 * win32-low.cc (win32_target_ops): Update.
3122 (wince_hostio_last_error): Turn into ...
3123 (win32_process_target::hostio_last_error): ... this.
3125 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3127 Turn process_stratum_target's get_tls_address op into a method of
3130 * target.h (struct process_stratum_target): Remove the target op.
3131 (class process_target): Add the target op. Also add
3132 'supports_get_tls_address'.
3133 * target.cc (process_target::get_tls_address): Define.
3134 (process_target::supports_get_tls_address): Define.
3136 Update the derived classes and callers below.
3138 * server.cc (handle_query): Update.
3139 * linux-low.cc (linux_target_ops): Update.
3140 (linux_process_target::supports_get_tls_address): Define.
3141 (linux_process_target::get_tls_address): Define.
3142 * linux-low.h (class linux_process_target): Update.
3143 * lynx-low.cc (lynx_target_ops): Update.
3144 * nto-low.cc (nto_target_ops): Update.
3145 * win32-low.cc (win32_target_ops): Update.
3147 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3149 Turn process_stratum_target's read_offsets op into a method of
3152 * target.h (struct process_stratum_target): Remove the target op.
3153 (class process_target): Add the target op. Also add
3154 'supports_read_offsets'.
3155 * target.cc (process_target::read_offsets): Define.
3156 (process_target::supports_read_offsets): Define.
3158 Update the derived classes and callers below.
3160 * server.cc (handle_query): Update.
3161 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3162 (linux_target_ops): Update.
3163 (linux_process_target::supports_read_offsets): Define.
3164 (linux_read_offsets): Turn into ...
3165 (linux_process_target::read_offsets): ... this.
3166 * linux-low.h (class linux_process_target): Update.
3167 * lynx-low.cc (lynx_target_ops): Update.
3168 * nto-low.cc (nto_target_ops): Update.
3169 * win32-low.cc (win32_target_ops): Update.
3171 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3173 Turn process_stratum_target's stopped_by_watchpoint and
3174 stopped_data_address ops into methods of process_target.
3176 * target.h (struct process_stratum_target): Remove the target ops.
3177 (class process_target): Add the target ops.
3178 * target.cc (process_target::stopped_by_watchpoint): Define.
3179 (process_target::stopped_data_address): Define.
3181 Update the derived classes and callers below.
3183 * remote-utils.cc (prepare_resume_reply): Update.
3184 * linux-low.cc (linux_target_ops): Update.
3185 (linux_stopped_by_watchpoint): Turn into ...
3186 (linux_process_target::stopped_by_watchpoint): ... this.
3187 (linux_stopped_data_address): Turn into ...
3188 (linux_process_target::stopped_data_address): ... this.
3189 * linux-low.h (class linux_process_target): Update.
3190 * lynx-low.cc (lynx_target_ops): Update.
3191 * nto-low.cc (nto_target_ops): Update.
3192 (nto_stopped_by_watchpoint): Turn into ...
3193 (nto_process_target::stopped_by_watchpoint): ... this.
3194 (nto_stopped_data_address): Turn into ...
3195 (nto_process_target::stopped_data_address): ... this.
3196 * nto-low.h (class nto_process_target): Update.
3197 * win32-low.cc (win32_target_ops): Update.
3198 (win32_stopped_by_watchpoint): Turn into ...
3199 (win32_process_target::stopped_by_watchpoint): ... this.
3200 (win32_stopped_data_address): Turn into ...
3201 (win32_process_target::stopped_data_address): ... this.
3202 * win32-low.h (class win32_process_target): Update.
3204 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3206 Turn process_stratum_target's supports_hardware_single_step op into
3207 a method of process_target.
3209 * target.h (struct process_stratum_target): Remove the target op.
3210 (class process_target): Add the target op.
3211 (target_supports_hardware_single_step): Update the macro.
3212 (target_can_do_hardware_single_step): Remove declaration.
3213 * target.cc (process_target::supports_hardware_single_step): Define.
3214 (target_can_do_hardware_single_step): Remove.
3216 Update the derived classes and callers below.
3218 * linux-low.h (class linux_process_target): Update.
3219 * linux-low.cc (linux_target_ops): Update.
3220 (linux_supports_hardware_single_step): Turn into ...
3221 (linux_process_target::supports_hardware_single_step): ... this.
3222 * lynx-low.h (class lynx_process_target): Update.
3223 * lynx-low.cc (lynx_target_ops): Update.
3224 (lynx_process_target::supports_hardware_single_step): Define.
3225 * nto-low.h (class nto_process_target): Update.
3226 * nto-low.cc (nto_target_ops): Update.
3227 (nto_process_target::supports_hardware_single_step): Define.
3228 * win32-low.h (class win32_process_target): Update.
3229 * win32-low.cc (win32_target_ops): Update.
3230 (win32_process_target::supports_hardware_single_step): Define.
3232 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3234 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3235 ops into methods of process_target.
3237 * target.h (struct process_stratum_target): Remove the target ops.
3238 (class process_target): Add the target ops.
3239 (target_stopped_by_hw_breakpoint): Update the macro.
3240 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3241 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3242 (process_target::supports_stopped_by_hw_breakpoint): Define.
3244 Update the derived classes and callers below.
3246 * linux-low.cc (linux_target_ops): Update.
3247 (linux_stopped_by_hw_breakpoint): Turn into ...
3248 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3249 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3250 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3251 * linux-low.h (class linux_process_target): Update.
3252 * lynx-low.cc (lynx_target_ops): Update.
3253 * nto-low.cc (nto_target_ops): Update.
3254 * win32-low.cc (win32_target_ops): Update.
3256 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3258 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3259 ops into methods of process_target.
3261 * target.h (struct process_stratum_target): Remove the target ops.
3262 (class process_target): Add the target ops.
3263 (target_stopped_by_sw_breakpoint): Update the macro.
3264 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3265 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3266 (process_target::supports_stopped_by_sw_breakpoint): Define.
3268 Update the derived classes and callers below.
3270 * linux-low.cc (linux_target_ops): Update.
3271 (linux_stopped_by_sw_breakpoint): Turn into ...
3272 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3273 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3274 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3275 * linux-low.h (class linux_process_target): Update.
3276 * lynx-low.cc (lynx_target_ops): Update.
3277 * nto-low.cc (nto_target_ops): Update.
3278 * win32-low.cc (win32_target_ops): Update.
3280 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3282 Turn process_stratum_target's insert_point and remove_point ops
3283 into methods of process_target.
3285 * target.h (struct process_stratum_target): Remove the target ops.
3286 (class process_target): Add the target ops.
3287 * target.cc (process_target::insert_point): Define.
3288 (process_target::remove_point): Define.
3290 Update the derived classes and callers below.
3292 * mem-break.cc (set_raw_breakpoint_at): Update.
3293 (delete_raw_breakpoint): Update.
3294 (uninsert_raw_breakpoint): Update.
3295 (reinsert_raw_breakpoint): Update.
3296 * linux-low.cc (linux_target_ops): Update.
3297 (linux_insert_point): Turn into ...
3298 (linux_process_target::insert_point): ... this.
3299 (linux_remove_point): Turn into ...
3300 (linux_process_target::remove_point): ... this.
3301 * linux-low.h (class linux_process_target): Update.
3302 * lynx-low.cc (lynx_target_ops): Update.
3303 * nto-low.cc (nto_target_ops): Update.
3304 (nto_insert_point): Turn into ...
3305 (nto_process_target::insert_point): ... this.
3306 (nto_remove_point): Turn into ...
3307 (nto_process_target::remove_point): ... this.
3308 * nto-low.h (class nto_process_target): Update.
3309 * win32-low.cc (win32_target_ops): Update.
3310 (win32_insert_point): Turn into ...
3311 (win32_process_target::insert_point): ... this.
3312 (win32_remove_point): Turn into ...
3313 (win32_process_target::remove_point): ... this.
3314 * win32-low.h (class win32_process_target): Update.
3316 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3318 Turn process_stratum_target's supports_z_point_type op into a
3319 method of process_target.
3321 * target.h (struct process_stratum_target): Remove the target op.
3322 (class process_target): Add the target op.
3323 * target.cc (process_target::supports_z_point_type): Define.
3325 Update the derived classes and callers below.
3327 * mem-break.cc (z_type_supported): Update.
3328 * linux-low.cc (linux_target_ops): Update.
3329 (linux_supports_z_point_type): Turn into ...
3330 (linux_process_target::supports_z_point_type): ... this.
3331 * linux-low.h (class linux_process_target): Update.
3332 * lynx-low.cc (lynx_target_ops): Update.
3333 * nto-low.cc (nto_target_ops): Update.
3334 (nto_supports_z_point_type): Turn into ...
3335 (nto_process_target::supports_z_point_type): ... this.
3336 * nto-low.h (class nto_process_target): Update.
3337 * win32-low.cc (win32_target_ops): Update.
3338 (win32_supports_z_point_type): Turn into ...
3339 (win32_process_target::supports_z_point_type): ... this.
3340 * win32-low.h (class win32_process_target): Update.
3342 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3344 Turn process_stratum_target's read_auxv op into a method of
3347 * target.h (class process_stratum_target): Remove the target op.
3348 (struct process_target): Add the target op. Also add
3349 'supports_read_auxv'.
3350 * target.cc (process_target::read_auxv): Define.
3351 (process_target::supports_read_auxv): Define.
3353 Update the derived classes and callers below.
3355 * server.cc (handle_qxfer_auxv): Update.
3356 (handle_query): Update.
3357 * linux-low.cc (linux_target_ops): Update.
3358 (linux_process_target::supports_read_auxv): Define.
3359 (linux_read_auxv): Turn into ...
3360 (linux_process_target::read_auxv): ... this.
3361 * linux-low.h (class linux_process_target): Update.
3362 * lynx-low.cc (lynx_target_ops): Update.
3363 * nto-low.cc (nto_target_ops): Update.
3364 (nto_process_target::supports_read_auxv): Define.
3365 (nto_read_auxv): Turn into ...
3366 (nto_process_target::read_auxv): ... this.
3367 * nto-low.h (class nto_process_target): Update.
3368 * win32-low.cc (win32_target_ops): Update.
3370 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3372 Turn process_stratum_target's request_interrupt op into a method of
3375 * target.h (struct process_stratum_target): Remove the target op.
3376 (class process_target): Add the target op.
3378 Update the derived classes and callers below.
3380 * remote-utils.cc (putpkt_binary_1): Update.
3381 (input_interrupt): Update.
3383 * server.cc (handle_v_requests): Update.
3384 * linux-low.cc (linux_target_ops): Update.
3385 (linux_request_interrupt): Turn into ...
3386 (linux_process_target::request_interrupt): ... this.
3387 * linux-low.h (class linux_process_target): Update.
3388 * lynx-low.cc (lynx_target_ops): Update.
3389 (lynx_request_interrupt): Turn into ...
3390 (lynx_process_target::request_interrupt): ... this.
3391 * lynx-low.h (class lynx_process_target): Update.
3392 * nto-low.cc (nto_target_ops): Update.
3393 (nto_request_interrupt): Turn into ...
3394 (nto_process_target::request_interrupt): ... this.
3395 * nto-low.h (class nto_process_target): Update.
3396 * win32-low.cc (win32_target_ops): Update.
3397 (win32_request_interrupt): Turn into ...
3398 (win32_process_target::request_interrupt): ... this.
3399 * win32-low.h (class win32_process_target): Update.
3401 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3403 Turn process_stratum_target's look_up_symbols op into a method of
3406 * target.h (struct process_stratum_target): Remove the target op.
3407 (class process_target): Add the target op.
3408 * target.cc (process_target::look_up_symbols): Define.
3410 Update the derived classes and callers below.
3412 * server.cc (handle_query): Update.
3413 * linux-low.cc (linux_target_ops): Update.
3414 (linux_look_up_symbols): Turn into ...
3415 (linux_process_target::look_up_symbols): ... this.
3416 * linux-low.h (class linux_process_target): Update.
3417 * lynx-low.cc (lynx_target_ops): Update.
3418 * nto-low.cc (nto_target_ops): Update.
3419 * win32-low.cc (win32_target_ops): Update.
3421 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3423 Turn process_stratum_target's read_memory and write_memory
3424 ops into methods of process_target.
3426 * target.h (struct process_stratum_target): Remove the target ops.
3427 (class process_target): Add the target ops.
3429 Update the derived classes and callers below.
3431 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3432 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3433 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3434 (arm_get_syscall_trapinfo): Update.
3435 * linux-cris-low.cc (cris_breakpoint_at): Update.
3436 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3437 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3438 * linux-mips-low.cc (mips_breakpoint_at): Update.
3439 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3440 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3441 * linux-sh-low.cc (sh_breakpoint_at): Update.
3442 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3443 (sparc_store_gregset_from_stack): Update.
3444 (sparc_breakpoint_at): Update.
3445 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3446 * linux-tile-low.cc (tile_breakpoint_at): Update.
3447 * linux-x86-low.cc (x86_breakpoint_at): Update.
3448 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3449 * mem-brea.cc (insert_memory_breakpoint): Update.
3450 (validate_inserted_breakpoint): Update.
3451 * target.cc (read_inferior_memory): Update.
3452 (target_write_memory): Update.
3453 * linux-low.cc (linux_target_ops): Update.
3454 (linux_read_memory): Make a wrapper around the read_memory target
3456 (linux_process_target::read_memory): Rename from linux_read_memory.
3457 (linux_write_memory): Turn into ...
3458 (linux_process_target::write_memory): ... this.
3459 * linux-low.h (class linux_process_target): Update.
3460 * lynx-low.cc (lynx_target_ops): Update.
3461 (lynx_read_memory): Turn into ...
3462 (lynx_process_target::read_memory): ... this.
3463 (lynx_write_memory): Turn into ...
3464 (lynx_process_target::write_memory): ... this.
3465 * lynx-low.h (class lynx_process_target): Update.
3466 * nto-low.cc (nto_target_ops): Update.
3467 (nto_read_memory): Turn into ...
3468 (nto_process_target::read_memory): ... this.
3469 (nto_write_memory): Turn into ...
3470 (nto_process_target::write_memory): ... this.
3471 * nto-low.h (class nto_process_target): Update.
3472 * win32-low.cc (win32_target_ops): Update.
3473 (win32_read_inferior_memory): Turn into ...
3474 (win32_process_target::read_memory): ... this.
3475 (win32_write_inferior_memory): Turn into ...
3476 (win32_process_target::write_memory): ... this.
3477 * win32-low.h (class win32_process_target): Update.
3479 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3481 Turn process_stratum_target's prepare_to_access_memory and
3482 done_accessing_memory ops into methods of process_target.
3484 * target.h (struct process_stratum_target): Remove the target ops.
3485 (class process_target): Add the target ops.
3486 * target.cc (process_target::prepare_to_access_memory): Define.
3487 (process_target::done_accessing_memory): Define.
3488 (prepare_to_access_memory): Update.
3489 (done_accessing_memory): Update.
3491 Update the derived classes and callers below.
3493 * linux-low.cc (linux_target_ops): Update.
3494 (linux_prepare_to_access_memory): Turn into ...
3495 (linux_process_target::prepare_to_access_memory): ... this.
3496 (linux_done_accessing_memory): Turn into ...
3497 (linux_process_target::done_accessing_memory): ... this.
3498 * linux-low.h (class linux_process_target): Update.
3499 * lynx-low.cc (lynx_target_ops): Update.
3500 * nto-low.cc (nto_target_ops): Update.
3501 * win32-low.cc (win32_target_ops): Update.
3503 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3505 Turn process_stratum_target's fetch_registers and store_registers
3506 ops into methods of process_target.
3508 * target.h (struct process_stratum_target): Remove the target ops.
3509 (class process_target): Add the target ops.
3510 (fetch_inferior_registers): Update the macro.
3511 (store_inferior_registers): Update the macro.
3513 Update the derived classes and callers below.
3515 * linux-low.cc (linux_target_ops): Update.
3516 (linux_fetch_registers): Turn into ...
3517 (linux_process_target::fetch_registers): ... this.
3518 (linux_store_registers): Turn into ...
3519 (linux_process_target::store_registers): ... this.
3520 * linux-low.h (class linux_process_target): Update.
3521 * lynx-low.cc (lynx_target_ops): Update.
3522 (lynx_fetch_registers): Turn into ...
3523 (lynx_process_target::fetch_registers): ... this.
3524 (lynx_store_registers): Turn into ...
3525 (lynx_process_target::store_registers): ... this.
3526 * lynx-low.h (class lynx_process_target): Update.
3527 * nto-low.cc (nto_target_ops): Update.
3528 (nto_fetch_registers): Turn into ...
3529 (nto_process_target::fetch_registers): ... this.
3530 (nto_store_registers): Turn into ...
3531 (nto_process_target::store_registers): ... this.
3532 * nto-low.h (class nto_process_target): Update.
3533 * win32-low.cc (win32_target_ops): Update.
3534 (win32_fetch_inferior_registers): Turn into ...
3535 (win32_process_target::fetch_registers): ... this.
3536 (win32_store_inferior_registers): Turn into ...
3537 (win32_process_target::store_registers): ... this.
3538 * win32-low.h (class win32_process_target): Update.
3540 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3542 Turn process_stratum_target's wait op into a method of
3545 * target.h (struct process_stratum_target): Remove the target op.
3546 (class process_target): Add the target op.
3548 Update the derived classes and callers below.
3550 * target.cc (target_wait): Update.
3551 * linux-low.cc (linux_target_ops): Update.
3552 (linux_wait): Turn into ...
3553 (linux_process_target::wait): ... this.
3554 * linux-low.h (class linux_process_target): Update.
3555 * lynx-low.cc (lynx_target_ops): Update.
3556 (lynx_wait): Turn into ...
3557 (lynx_process_target::wait): ... this.
3558 * lynx-low.h (class lynx_process_target): Update.
3559 * nto-low.cc (nto_target_ops): Update.
3560 (nto_wait): Turn into ...
3561 (nto_process_target::wait): ... this.
3562 * nto-low.h (class nto_process_target): Update.
3563 * win32-low.cc (win32_target_ops): Update.
3564 (win32_wait): Turn into ...
3565 (win32_process_target::wait): ... this.
3566 (do_initial_child_stuff): Update.
3567 * win32-low.h (class win32_process_target): Update.
3569 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3571 Turn process_stratum_target's resume op into a method of
3574 * target.h (struct process_stratum_target): Remove the target op.
3575 (class process_target): Add the target op.
3577 Update the derived classes and callers below.
3579 * server.cc (resume): Update.
3580 * target.cc (target_stop_and_wait): Update.
3581 (target_continue_no_signal): Update.
3582 (target_continue): Update.
3583 * linux-low.cc (linux_target_ops): Update.
3584 (linux_resume): Turn into ...
3585 (linux_process_target::resume): ... this.
3586 * linux-low.h (class linux_process_target): Update.
3587 * lynx-low.cc (lynx_target_ops): Update.
3588 (lynx_resume): Turn into ...
3589 (lynx_process_target::resume): ... this.
3590 * lynx-low.h (class lynx_process_target): Update.
3591 * nto-low.cc (nto_target_ops): Update.
3592 (nto_resume): Turn into ...
3593 (nto_process_target::resume): ... this.
3594 * nto-low.h (class nto_process_target): Update.
3595 * win32-low.cc (win32_target_ops): Update.
3596 (win32_resume): Turn into ...
3597 (win32_process_target::resume): ... this.
3598 (win32_process_target::detach): Update.
3599 (do_initial_child_stuff): Update.
3600 * win32-low.h (class win32_process_target): Update.
3602 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3604 Turn process_stratum_target's thread_alive op into a method of
3607 * target.h (struct process_stratum_target): Remove the target op.
3608 (class process_target): Add the target op.
3609 (mythread_alive): Update the macro.
3611 Update the derived classes and callers below.
3613 * linux-low.cc (linux_target_ops): Update.
3614 (linux_thread_alive): Turn into ...
3615 (linux_process_target::thread_alive): ... this.
3616 (wait_for_sigstop): Update.
3617 * linux-low.h (class linux_process_target): Update.
3618 * lynx-low.cc (lynx_target_ops): Update.
3619 (lynx_thread_alive): Turn into ...
3620 (lynx_process_target::thread_alive): ... this.
3621 * lynx-low.h (class lynx_process_target): Update.
3622 * nto-low.cc (nto_target_ops): Update.
3623 (nto_thread_alive): Turn into ...
3624 (nto_process_target::thread_alive): ... this.
3625 * nto-low.h (class nto_process_target): Update.
3626 * win32-low.cc (win32_target_ops): Update.
3627 (win32_thread_alive): Turn into ...
3628 (win32_process_target::thread_alive): ... this.
3629 * win32-low.h (class win32_process_target): Update.
3631 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3633 Turn process_stratum_target's join op into a method of
3636 * target.h (struct process_stratum_target): Remove the target op.
3637 (class process_target): Add the target op.
3638 (join_inferior): Update the macro.
3640 Update the derived classes and callers below.
3642 * linux-low.cc (linux_target_ops): Update.
3643 (linux_join): Turn into ...
3644 (linux_process_target::join): ... this.
3645 * linux-low.h (class linux_process_target): Update.
3646 * lynx-low.cc (lynx_target_ops): Update.
3647 (lynx_join): Turn into ...
3648 (lynx_process_target::join): ... this.
3649 * lynx-low.h (class lynx_process_target): Update.
3650 * nto-low.cc (nto_target_ops): Update.
3651 (nto_process_target::join): Define.
3652 * nto-low.h (class nto_process_target): Update.
3653 * win32-low.cc (win32_target_ops): Update.
3654 (win32_join): Turn into ...
3655 (win32_process_target::join): ... this.
3656 * win32-low.h (class win32_process_target): Update.
3658 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3660 Turn process_stratum_target's mourn op into a method of
3663 * target.h (struct process_stratum_target): Remove the target op.
3664 (class process_target): Add the target op.
3666 Update the derived classes and callers below.
3668 * target.cc (target_mourn_inferior): Update.
3669 * linux-low.cc (linux_target_ops): Update.
3670 (linux_mourn): Turn into ...
3671 (linux_process_target::mourn): ... this.
3672 (handle_extended_wait): Update.
3673 (linux_process_target::kill): Update.
3674 (linux_process_target::detach): Update.
3675 * linux-low.h (class linux_process_target): Update.
3676 * lynx-low.cc (lynx_target_ops): Update.
3677 (lynx_mourn): Turn into ...
3678 (lynx_process_target::mourn): ... this.
3679 * lynx-low.h (class lynx_process_target): Update.
3680 * nto-low.cc (nto_target_ops): Update.
3681 (nto_mourn): Turn into ...
3682 (nto_process_target::mourn): ... this.
3683 * nto-low.h (class nto_process_target): Update.
3684 * win32-low.cc (win32_target_ops): Update.
3685 (win32_mourn): Turn into ...
3686 (win32_process_target::mourn): ... this.
3687 * win32-low.h (class win32_process_target): Update.
3689 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3691 Turn process_stratum_target's detach op into a method of
3694 * target.h (struct process_stratum_target): Remove the target op.
3695 (class process_target): Add the target op.
3696 (detach_inferior): Update the macro.
3698 Update the derived classes and callers below.
3700 * linux-low.cc (linux_target_ops): Update.
3701 (linux_detach): Turn into ...
3702 (linux_process_target::detach): ... this.
3703 * linux-low.h (class linux_process_target): Update.
3704 * lynx-low.cc (lynx_target_ops): Update.
3705 (lynx_detach): Turn into ...
3706 (lynx_process_target::detach): ... this.
3707 * lynx-low.h (class lynx_process_target): Update.
3708 * nto-low.cc (nto_target_ops): Update.
3709 (nto_detach): Turn into ...
3710 (nto_process_target::detach): ... this.
3711 * nto-low.h (class nto_process_target): Update.
3712 * win32-low.cc (win32_target_ops): Update.
3713 (win32_detach): Turn into ...
3714 (win32_process_target::detach): ... this.
3715 * win32-low.h (class win32_process_target): Update.
3717 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3719 Turn process_stratum_target's kill op into a method of
3722 * target.h (struct process_stratum_target): Remove the target op.
3723 (class process_target): Add the target op.
3725 Update the derived classes and callers below.
3727 * target.cc (kill_inferior): Update.
3728 * linux-low.cc (linux_target_ops): Update.
3729 (linux_kill): Turn into ...
3730 (linux_process_target::kill): ... this.
3731 * linux-low.h (class linux_process_target): Update.
3732 * lynx-low.cc (lynx_target_ops): Update.
3733 (lynx_kill): Turn into ...
3734 (lynx_process_target::kill): ... this.
3735 * lynx-low.h (class lynx_process_target): Update.
3736 * nto-low.cc (nto_target_ops): Update.
3737 (nto_kill): Turn into ...
3738 (nto_process_target::kill): ... this.
3739 * nto-low.h (class nto_process_target): Update.
3740 * win32-low.cc (win32_target_ops): Update.
3741 (win32_kill): Turn into ...
3742 (win32_process_target::kill): ... this.
3743 * win32-low.h (class win32_process_target): Update.
3745 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3747 Turn process_stratum_target's attach op into a method of
3750 * target.h (struct process_stratum_target): Remove the target op.
3751 (class process_target): Add the target op.
3752 (myattach): Update the macro.
3754 Update the derived classes and callers below.
3756 * linux-low.cc (linux_target_ops): Update.
3757 (linux_attach): Turn into ...
3758 (linux_process_target::attach): ... this.
3759 * linux-low.h (class linux_process_target): Update.
3760 * lynx-low.cc (lynx_target_ops): Update.
3761 (lynx_attach): Turn into ...
3762 (lynx_process_target::attach): ... this.
3763 * lynx-low.h (class lynx_process_target): Update.
3764 * nto-low.cc (nto_target_ops): Update.
3765 (nto_attach): Turn into ...
3766 (nto_process_target::attach): ... this.
3767 * nto-low.h (class nto_process_target): Update.
3768 * win32-low.cc (win32_target_ops): Update.
3769 (win32_attach): Turn into ...
3770 (win32_process_target::attach): ... this.
3771 * win32-low.h (class win32_process_target): Update.
3773 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3775 Turn process_stratum_target's post_create_inferior op into a method
3778 * target.h (struct process_stratum_target): Remove the target op.
3779 (class process_target): Add the target op.
3780 (target_post_create_inferior): Update the macro.
3781 * target.cc (process_target::post_create_inferior): Define.
3783 Update the derived classes and callers below.
3785 * linux-low.cc (linux_target_ops): Update.
3786 (linux_post_create_inferior): Turn into ...
3787 (linux_process_target::post_create_inferior): ... this.
3788 * linux-low.h (class linux_process_target): Update.
3789 * lynx-low.cc (lynx_target_ops): Update.
3790 * nto-low.cc (nto_target_ops): Update.
3791 * win32-low.cc (win32_target_ops): Update.
3793 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3795 Turn process_stratum_target's create_inferior op into a method of
3798 * target.h (struct process_stratum_target): Remove the target op.
3799 (class process_target): Add the target op.
3800 (create_inferior): Rename the macro to ...
3801 (target_create_inferior): ... this.
3803 Update the derived classes and callers below.
3805 * server.cc (handle_v_run): Update.
3806 (captured_main): Update.
3807 (process_serial_event): Update.
3808 * linux-low.cc (linux_target_ops): Update.
3809 (linux_create_inferior): Turn into ...
3810 (linux_process_target::create_inferior): ... this.
3811 * linux-low.h (class linux_process_target): Update.
3812 * lynx-low.cc (lynx_target_ops): Update.
3813 (lynx_create_inferior): Turn into ...
3814 (lynx_process_target::create_inferior): ... this.
3815 * lynx-low.h (class lynx_process_target): Update.
3816 * nto-low.cc (nto_target_ops): Update.
3817 (nto_create_inferior): Turn into ...
3818 (nto_process_target::create_inferior): ... this.
3819 * nto-low.h (class nto_process_target): Update.
3820 * win32-low.cc (win32_target_ops): Update.
3821 (win32_create_inferior): Turn into ...
3822 (win32_process_target::create_inferior): ... this.
3823 * win32-low.h (class win32_process_target): Update.
3825 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3827 * target.h (class process_target): New class definition.
3828 (struct process_stratum_target) <pt>: New field with type
3830 * linux-low.h (class linux_process_target): Define as a derived
3831 class of 'process_target'.
3832 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3834 * lynx-low.h (class lynx_process_target): Define as a derived
3835 class of 'process_target'.
3836 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3838 * nto-low.h (class nto_process_target): Define as a derived
3839 class of 'process_target'.
3840 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3842 * win32-low.h (class win32_process_target): Define as a derived
3843 class of 'process_target'.
3844 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3847 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3849 * configure: Regenerate.
3851 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
3852 Andrew Burgess <andrew.burgess@embecosm.com>
3854 * linux-riscv-low.cc: New file.
3855 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3856 and nat/riscv-linux-tdesc.c.
3857 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3858 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3861 2020-02-14 Tom Tromey <tom@tromey.com>
3863 * acinclude.m4: Don't include acx_configure_dir.m4.
3864 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3865 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3866 (all, install-only, uninstall, clean-info, clean)
3867 (maintainer-clean): Don't recurse.
3868 (subdir_do, all-lib): Remove.
3869 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3871 (generated_files): Update.
3872 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3873 * configure: Rebuild.
3874 * configure.ac: Don't configure gnulib or libiberty.
3877 2020-02-14 Eli Zaretskii <eliz@gnu.org>
3879 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3880 preparing the command line for CreateProcess.
3881 (win32_create_inferior): Reflect the program name in debugging
3882 output that shows the process and its command line.
3884 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3886 * Makefile.in: Rename source files from .c to .cc.
3887 * %.c: Rename to %.cc.
3888 * configure.ac: Rename server.c to server.cc.
3889 * configure: Re-generate.
3891 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3893 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3895 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
3897 * win32-low.c (win32_create_inferior): Set signal_pid.
3899 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
3900 Pedro Alves <palves@redhat.com>
3902 Skip building gdbserver in a cross-configuration.
3903 * configure.srv: Set $gdbserver_host depending on whether $target
3904 is $host. Use $gdbserver_host instead of $host.
3906 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3908 * configure: Re-generate.
3910 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3912 * configure: Re-generate.
3914 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3916 * acinclude.m4: Update warning.m4 path.
3918 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3920 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3921 (handle_exception): Set siginfo_er.
3922 (win32_xfer_siginfo): New function.
3924 2020-02-07 Tom Tromey <tom@tromey.com>
3925 Pedro Alves <palves@redhat.com>
3927 * README: Update build documentation.
3928 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
3930 * configure.ac: Update paths.
3931 * configure: Rebuild.
3932 * acinclude.m4: Update paths.
3933 * Makefile.in: Update include paths.
3934 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
3935 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
3936 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
3937 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
3938 (%-generated.c): Update paths.
3939 * Move entire directory from ../gdb/gdbserver.
3941 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
3943 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
3945 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3947 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
3948 assignment instead of srv_linux_obj.
3950 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
3952 * server.c (handle_qxfer_libraries): Write segment-address with
3955 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
3957 * Makefile.in (install-strip): New target.
3958 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
3959 * aclocal.m4: Regenerate.
3960 * configure: Regenerate.
3961 * configure.ac: Add AM_PROG_INSTALL_STRIP.
3963 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
3965 * Makefile.in (SFILES): Adjust paths to point to real files.
3966 (OBS): Move waitstatus.o to target/waitstatus.o.
3967 (TAGS): Transform paths appropriately.
3969 (nat/%.o): ... this pattern rule.
3971 (target/%.o): ... this pattern rule.
3972 * configure.srv: Adjust paths throughout to include nat/ prefix
3973 with the revant files.
3974 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
3975 * configure: Regenerate.
3977 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
3979 * Makefile.in (TAGS): Remove config files from the recipe.
3981 2020-01-14 Tom Tromey <tom@tromey.com>
3983 * configure: Rebuild.
3984 * configure.ac: Remove any checks that were added to common.m4.
3985 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
3988 2020-01-14 Tom Tromey <tom@tromey.com>
3990 * server.h: Include config.h.
3991 * gdbreplay.c: Include config.h.
3992 * configure: Rebuild.
3993 * configure.ac: Don't source common.host.
3994 * acinclude.m4: Update path.
3995 * Makefile.in (INCSUPPORT): New variable.
3996 (INCLUDE_CFLAGS): Add INCSUPPORT.
3997 (SFILES): Update paths.
3998 (version-generated.c): Update path to create-version.sh.
3999 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4001 2020-01-14 Tom Tromey <tom@tromey.com>
4003 * configure.ac (LIBS): Use WIN32APILIBS.
4004 (USE_WIN32API): Don't define.
4005 * configure: Rebuild.
4007 2020-01-14 Tom Tromey <tom@tromey.com>
4009 * configure: Rebuild.
4011 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4013 * Makefile.in (%-generated.c): Remove rule for files from
4016 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4018 * configure: Re-generate.
4020 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4022 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4024 * tracepoint.c (stop_tracing, flush_trace_buffer,
4025 about_to_request_buffer_space, get_trace_state_variable_value,
4026 set_trace_state_variable_value, gdb_collect): Add declaration.
4028 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4030 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4031 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4032 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4033 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4034 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4037 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4039 * inferiors.c: Include gdbsupport/common-inferior.h.
4041 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4043 * hostio-errno.c: Include hostio.h.
4045 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4047 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4050 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4052 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4053 * linux-arm-tdesc.h: Include arch/arm.h.
4055 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4057 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4059 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4061 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4062 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4064 2020-01-10 Pedro Alves <palves@redhat.com>
4066 * fork-child.c (post_fork_inferior): Pass target down to
4068 * inferiors.c (switch_to_thread): Add process_stratum_target
4070 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4071 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4072 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4073 * remote-utils.c (prepare_resume_reply): Pass the target to
4075 * target.c (the_target): Now a process_stratum_target.
4076 (done_accessing_memory): Pass the target to switch_to_thread.
4077 (set_target_ops): Ajust to use process_stratum_target.
4078 * target.h (struct target_ops): Rename to ...
4079 (struct process_stratum_target): ... this.
4080 (the_target, set_target_ops): Adjust.
4081 (prepare_to_access_memory): Adjust comment.
4082 * win32-low.c (child_xfer_memory): Adjust to use
4083 process_stratum_target.
4084 (win32_target_ops): Now a process_stratum_target.
4086 2020-01-06 Eli Zaretskii <eliz@gnu.org>
4087 Pedro Alves <palves@redhat.com>
4089 * win32-low.c (get_child_debug_event): Extract the fatal exception
4090 from the exit status and convert to the equivalent Posix signal
4092 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4093 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4095 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
4097 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4099 2020-01-01 Joel Brobecker <brobecker@adacore.com>
4101 * server.c (gdbserver_version): Change copyright year to 2020.
4102 * gdbreplay.c (gdbreplay_version): Likewise.
4104 2019-12-19 Christian Biesinger <cbiesinger@google.com>
4106 * configure: Regenerate.
4107 * configure.ac: Quote variable arguments of test.
4109 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4111 * Makefile.in: Fix build with GNU Make 3.81
4113 2019-12-16 Tom Tromey <tromey@adacore.com>
4115 * server.c (get_exec_file): Constify result.
4117 2019-12-10 Christian Biesinger <cbiesinger@google.com>
4119 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4120 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4121 * config.in: Regenerate.
4122 * configure: Regenerate.
4123 * configure.ac: Don't check for strerror.
4124 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4125 Call safe_strerror instead of strerror.
4126 * server.h (strerror): Remove this now-unnecessary declaration.
4127 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4129 (gdb_agent_helper_thread): Likewise.
4130 * utils.c (perror_with_name): Likewise.
4132 2019-11-26 Tom Tromey <tom@tromey.com>
4134 * configure, config.in: Rebuild.
4136 2019-11-26 Tom Tromey <tom@tromey.com>
4138 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4139 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4141 * configure, config.in: Rebuild.
4143 2019-11-26 Tom Tromey <tom@tromey.com>
4145 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4146 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4147 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4148 * acinclude.m4: Include ax_pthread.m4.
4149 * config.in, configure: Rebuild.
4151 2019-11-26 Christian Biesinger <cbiesinger@google.com>
4153 * debug.c (debug_set_output): Call safe_strerror instead of
4155 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4156 (linux_kill_one_lwp): Likewise.
4157 (linux_detach_one_lwp): Likewise.
4158 (linux_wait_for_event_filtered): Likewise.
4159 (store_register): Likewise.
4160 * lynx-low.c (lynx_attach): Likewise.
4161 * mem-break.c (insert_memory_breakpoint): Likewise.
4162 (remove_memory_breakpoint): Likewise.
4163 (delete_fast_tracepoint_jump): Likewise.
4164 (set_fast_tracepoint_jump): Likewise.
4165 (uninsert_fast_tracepoint_jumps_at): Likewise.
4166 (reinsert_fast_tracepoint_jumps_at): Likewise.
4167 * nto-low.c (nto_xfer_memory): Likewise.
4168 (nto_resume): Likewise.
4170 2019-11-20 Luis Machado <luis.machado@linaro.org>
4172 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4173 instead of register count.
4174 * tdesc.c (tdesc_contains_feature): New function.
4175 * tdesc.h (tdesc_contains_feature): New prototype.
4177 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4179 * Makefile.in: Add safe-strerror.c.
4180 * configure: Regenerate.
4181 * configure.ac: Don't source common.host.
4183 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4185 * config.in: Regenerate.
4186 * configure: Regenerate.
4188 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4190 * ax.c (ax_printf): Handle size_t_arg.
4192 2019-11-06 Christian Biesinger <cbiesinger@google.com>
4194 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4195 * mi/mi-main.c (output_cores): Likewise.
4196 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4197 (linux_xfer_osdata_modules): Likewise.
4198 * remote.c (register_remote_support_xml): Likewise.
4199 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4200 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4202 2019-11-01 Christian Biesinger <cbiesinger@google.com>
4204 * configure: Regenerate.
4205 * configure.ac: Remove check for strerror_r.
4207 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4209 * config.in: Regenerate.
4210 * configure: Regenerate.
4211 * configure.ac: Also check for strerror_r.
4213 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4215 * ax.h (debug_agent): Remove duplicate declaration.
4217 2019-10-26 Tom de Vries <tdevries@suse.de>
4219 * linux-aarch64-low.c: Fix typos in comments.
4220 * linux-arm-low.c: Same.
4221 * linux-low.c: Same.
4222 * linux-ppc-low.c: Same.
4223 * proc-service.c: Same.
4226 * tracepoint.c: Same.
4227 * win32-low.c: Same.
4229 2019-10-25 Tom Tromey <tromey@adacore.com>
4231 * utils.c (xstrdup): Remove.
4233 2019-10-23 Tom Tromey <tom@tromey.com>
4235 * configure, config.in: Rebuild.
4237 2019-10-23 Tom Tromey <tom@tromey.com>
4239 * configure: Rebuild.
4240 * acinclude.m4: Use m4_include, not sinclude.
4242 2019-10-17 Tom Tromey <tromey@adacore.com>
4244 * configure: Rebuild.
4245 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4246 in AC_CONFIG_FILES invocation.
4247 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4250 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4252 * server.c: Include xml-builtin.h.
4253 (get_xml_features): Don't declare xml_builtins here.
4255 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4257 * Makefile.in: Remove references to vec-ipa.o.
4259 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4261 * Makefile.in: Remove references to vec.c.
4263 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4265 * server.c (server_waiting): Change to bool.
4266 (extended_protocol): Likewise.
4267 (response_needed): Likewise.
4268 (exit_requested): Likewise.
4269 (run_once): Likewise.
4270 (report_no_resumed): Likewise.
4271 (non_stop): Likewise.
4272 (disable_packet_vCont): Likewise.
4273 (disable_packet_Tthread): Likewise.
4274 (disable_packet_qC): Likewise.
4275 (disable_packet_qfThreadInfo): Likewise.
4276 (handle_general_set): Update.
4277 (handle_detach): Update.
4278 (handle_monitor_command): Update.
4279 (handle_query): Update.
4280 (captured_main): Update.
4281 (process_serial_event): Update.
4282 * server.h (server_waiting): Change to bool.
4283 (disable_packet_vCont): Likewise.
4284 (disable_packet_Tthread): Likewise.
4285 (disable_packet_qC): Likewise.
4286 (disable_packet_qfThreadInfo): Likewise.
4287 (run_once): Likewise.
4288 (non_stop): Likewise.
4289 * target.c (target_stop_and_wait): Update.
4291 2019-10-02 Tom Tromey <tromey@adacore.com>
4293 * Makefile.in (SFILES): Add common-inferior.c.
4294 (OBS): Add common-inferior.o.
4295 * server.c (startup_with_shell): Don't define.
4297 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4299 * linux-low.c (linux_low_read_btrace): Update for change to
4302 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4304 * debug.c (debug_threads): Remove comment in favor of the header.
4305 * debug.h (using_threads): Add declaration.
4306 (debug_threads): Add comment.
4307 * linux-aarch64-low.c: Include debug.h and remove declaration of
4309 * nto-low.c: Likewise.
4310 * remote-utils.c: Likewise.
4311 * thread-db.c: Likewise.
4313 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4315 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4316 and powerpc-cell64l-ipa.o.
4317 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4318 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4319 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4322 * spu-low.c: Remove file.
4324 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4325 (parse_spufs_run): Remove.
4326 (ppc_get_pc): Remove Cell/B.E. support.
4327 (ppc_set_pc): Likewise.
4328 (ppc_breakpoint_at): Likewise.
4329 (ppc_arch_setup): Likewise.
4330 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4331 tdesc_powerpc_cell32l.
4332 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4333 or init_registers_powerpc_cell32l.
4334 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4335 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4336 or init_registers_powerpc_cell32l.
4337 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4338 (init_registers_powerpc_cell32l): Remove prototype.
4339 (init_registers_powerpc_cell64l): Likewise.
4341 * target.h (struct target_ops): Remove qxfer_spu member.
4342 * server.c (handle_qxfer_spu): Remove.
4343 (qxfer_packets): Remove entry for "spu".
4344 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4345 * linux-low.c (SPUFS_MAGIC): Remove.
4346 (spu_enumerate_spu_ids): Remove.
4347 (linux_qxfer_spu): Remove.
4348 (linux_target_ops): Remove qxfer_spu member.
4349 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4350 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4351 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4353 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4355 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4356 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4357 * config.in: Regenerate.
4358 * configure: Regenerate.
4360 2019-08-15 Tom Tromey <tromey@adacore.com>
4362 * target.c (target_write_memory): Use gdb::byte_vector.
4364 2019-08-15 Tom Tromey <tromey@adacore.com>
4366 * tracepoint.c (write_inferior_data_pointer)
4367 (write_inferior_integer, write_inferior_int8)
4368 (write_inferior_uinteger, m_tracepoint_action_download)
4369 (r_tracepoint_action_download, x_tracepoint_action_download)
4370 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4371 (download_agent_expr, download_tracepoint_1)
4372 (download_trace_state_variables, upload_fast_traceframes): Update.
4373 * server.c (gdb_write_memory): Update.
4374 * remote-utils.c (relocate_instruction): Update.
4375 * proc-service.c (ps_pdwrite): Update.
4376 * mem-break.c (remove_memory_breakpoint)
4377 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4378 (uninsert_fast_tracepoint_jumps_at)
4379 (reinsert_fast_tracepoint_jumps_at): Update.
4380 * linux-x86-low.c (append_insns)
4381 (i386_install_fast_tracepoint_jump_pad)
4382 (amd64_write_goto_address, i386_write_goto_address): Update.
4383 * linux-s390-low.c (append_insns, s390_write_goto_address):
4385 * linux-ppc-low.c (ppc_relocate_instruction)
4386 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4387 (ppc_write_goto_address): Update.
4388 * linux-aarch64-low.c (append_insns): Update.
4389 * target.h (struct target_ops): Update.
4390 (write_inferior_memory): Don't declare.
4391 * target.c (target_write_memory): Rename from
4392 write_inferior_memory. Remove old target_write_memory.
4394 2019-08-15 Tom Tromey <tromey@adacore.com>
4396 * target.c (write_inferior_memory): Use std::vector.
4398 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4401 * configure.ac: Drop enable-libmcheck support.
4402 * configure, config.in: Rebuild.
4403 * acinclude.m4: Don't include it.
4405 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4407 * configure.srv: Remove Arm xml files.
4409 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4411 * configure.srv: Add new files. Remove xml generated files.
4412 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4414 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4415 * linux-aarch32-tdesc.c: New file.
4416 * linux-aarch32-tdesc.h: New file.
4417 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4418 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4419 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4420 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4421 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4422 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4423 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4424 (arm_read_description): Call arm_linux_read_description.
4425 (initialize_low_arch): Don't init registers.
4426 * linux-arm-tdesc.c: New file.
4427 * linux-arm-tdesc.h: New file.
4429 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4431 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4432 Move counter inside for.
4433 (arm_read_description): Check ptrace earlier.
4434 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4436 2019-07-09 Tom Tromey <tom@tromey.com>
4438 * configure: Rebuild.
4439 * configure.ac: Change common to gdbsupport.
4440 * acinclude.m4: Change common to gdbsupport.
4441 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4442 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4443 common to gdbsupport.
4444 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4445 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4446 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4447 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4448 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4449 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4450 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4451 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4452 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4453 common to gdbsupport.
4455 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4457 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4459 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4461 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4463 * configure.srv: Remove legacy xml.
4464 * linux-aarch64-low.c (initialize_low_arch): Remove
4465 initialize_low_tdesc call.
4466 * linux-aarch64-tdesc-selftest.c: Remove file.
4467 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4468 * linux-x86-low.c (initialize_low_arch): Remove
4469 initialize_low_tdesc call.
4470 * linux-x86-tdesc-selftest.c: Remove file.
4471 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4473 2019-06-20 Tom de Vries <tdevries@suse.de>
4475 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4476 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4478 2019-06-19 Tom de Vries <tdevries@suse.de>
4480 * debug.h (debug_write): Change return type to ssize_t.
4481 * debug.c (debug_write): Same.
4483 2019-06-14 Tom Tromey <tom@tromey.com>
4485 * configure.ac: Use new path to gnulib.
4486 * configure: Rebuild.
4487 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4490 2019-06-11 Tom Tromey <tom@tromey.com>
4492 * Makefile.in (SFILES): Add alloc.c.
4494 (IPA_OBJS): Add alloc-ipa.o.
4495 (alloc-ipa.o): New target.
4496 (%.o: ../%.c): New pattern rule.
4498 2019-06-10 Tom Tromey <tromey@adacore.com>
4500 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4501 end warning with a newline.
4502 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4504 * thread-db.c (attach_thread): Don't end warning with a newline.
4505 (thread_db_notice_clone): Likewise.
4506 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4508 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4509 end warning with a newline.
4511 2019-06-04 Pedro Alves <palves@redhat.com>
4513 * server.c (captured_main): Use make_unique_xstrdup.
4515 2019-06-02 Tom Tromey <tom@tromey.com>
4517 * gdbreplay.c (fromhex): Remove.
4518 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4520 2019-05-29 Tom Tromey <tromey@adacore.com>
4522 * configure: Rebuild.
4524 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4526 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4527 sign extension code on 32-bit builds.
4529 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4532 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4534 2019-04-19 Tom Tromey <tom@tromey.com>
4536 * server.c (struct vstop_notif): Derive from notif_event.
4538 (queue_stop_reply): Update.
4539 (remove_all_on_match_ptid): Change type. Rewrite.
4540 (discard_queued_stop_replies): Rewrite.
4541 (in_queued_stop_replies_ptid): Change type.
4542 (in_queued_stop_replies): Rewrite.
4543 (notif_stop): Update.
4544 (queue_stop_reply_callback): Update.
4545 (captured_main): Don't call initialize_notif.
4546 (push_stop_notification): Update.
4547 * notif.c (notif_write_event, handle_notif_ack)
4548 (notif_event_enque, notif_push): Update.
4549 (notif_event_xfree, initialize_notif): Remove.
4550 * notif.h (struct notif_event): Include <list>, not
4552 (struct notif_server) <queue>: Now a std::list.
4553 (notif_event_p): Remove typedef.
4554 (initialize_notif): Don't declare.
4555 (struct notif_event): Add virtual destructor.
4557 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4559 * ax.c (ax_vdebug): Call debug_printf.
4560 * debug.c (debug_write): New function.
4561 * debug.h (debug_write): New declaration.
4562 * linux-low.c (sigchld_handler): Call debug_write.
4564 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4566 * debug.c (debug_set_output): New function.
4567 (debug_vprintf): Send output to debug_file.
4568 (debug_flush): Likewise.
4569 * debug.h (debug_set_output): New declaration.
4570 * server.c (handle_monitor_command): Add debug-file option.
4571 (captured_main): Likewise.
4573 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4575 * debug.c (remote_debug): Add definition.
4576 * debug.h (remote_debug): Add declaration.
4577 * hostio.c (remote_debug): Remove declaration.
4578 * remote-utils.c (struct ui_file): Likewise.
4579 (remote_debug): Likewise.
4580 * remote-utils.h (remote_debug): Likewise,
4581 * server.c (remote_debug): Remove definition.
4583 2019-04-10 Kevin Buettner <kevinb@redhat.com>
4585 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4586 when using a 64-bit gdbserver.
4588 2019-04-09 Tom Tromey <tromey@adacore.com>
4590 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4592 2019-04-08 Tom Tromey <tom@tromey.com>
4594 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4596 (linux_resume_one_lwp): Likewise.
4598 2019-04-08 Tom Tromey <tom@tromey.com>
4600 * gdbreplay.c: Update.
4601 * linux-low.c: Update.
4604 2019-04-08 Tom Tromey <tom@tromey.com>
4606 * server.c: Use C++ exception handling.
4607 * linux-low.c: Use C++ exception handling.
4608 * gdbreplay.c: Use C++ exception handling.
4610 2019-04-08 Tom Tromey <tom@tromey.com>
4612 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4613 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4614 (captured_main, main): Update.
4615 * gdbreplay.c (main): Update.
4617 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4619 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4620 value in argument pointer, return 1 if the entry is found and 0
4621 otherwise. Move comment.
4622 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4623 * linux-low.h (linux_get_auxv): Declare.
4624 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4626 2019-04-05 Tom Tromey <tromey@adacore.com>
4628 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4631 2019-03-28 Alan Hayward <alan.hayward@arm.com>
4633 * linux-low.c (AT_HWCAP2): Add define if not already included.
4635 2019-03-26 Alan Hayward <alan.hayward@arm.com>
4637 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4638 (aarch64_arch_setup): Call linux_get_hwcap.
4639 * linux-arm-low.c (arm_get_hwcap): Remove function.
4640 (arm_read_description): Call linux_get_hwcap.
4641 * linux-low.c (linux_get_auxv): New function.
4642 (linux_get_hwcap): Likewise.
4643 (linux_get_hwcap2): Likewise.
4644 * linux-low.h (linux_get_hwcap): New declaration.
4645 (linux_get_hwcap2): Likewise.
4646 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4647 (ppc_arch_setup): Call linux_get_hwcap.
4648 * linux-s390-low.c (s390_get_hwcap): Remove function.
4649 (s390_arch_setup): Call linux_get_hwcap.
4651 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4652 Jiong Wang <jiong.wang@arm.com>
4654 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4655 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4657 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4659 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4660 Jiong Wang <jiong.wang@arm.com>
4662 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4663 (aarch64_get_hwcap): New function.
4664 (aarch64_arch_setup): Read APIA hwcap.
4666 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4667 Jiong Wang <jiong.wang@arm.com>
4669 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4670 (initialize_low_tracepoint): Likewise.
4671 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4672 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4673 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4674 (aarch64_linux_read_description): Likewise.
4675 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4677 2019-03-12 John Baldwin <jhb@FreeBSD.org>
4679 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4680 i386_create_target_description for 'segments' parameter.
4681 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4682 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4683 * win32-i386-low.c (i386_arch_setup): Likewise.
4685 2019-03-12 Tom Tromey <tromey@adacore.com>
4687 * linux-low.c (iterate_over_lwps): Update.
4689 2019-03-06 Tom Tromey <tom@tromey.com>
4691 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4692 (captured_main): Use SCOPE_EXIT.
4694 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4696 * configure.srv: Use '$enable_unittest' instead of '$development'
4697 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4700 2019-02-27 Tom Tromey <tromey@adacore.com>
4702 * gdbreplay.c (logchar): Handle \r\n.
4704 2019-02-07 Alan Hayward <alan.hayward@arm.com>
4706 * linux-low.c (linux_attach): Add process before lwp.
4707 * server.c (attach_inferior): Check if already attached.
4709 2019-02-07 Tom Tromey <tom@tromey.com>
4711 * x86-tdesc.h: Rename include guard.
4712 * x86-low.h: Add include guard.
4713 * wincecompat.h: Rename include guard.
4714 * win32-low.h: Add include guard.
4715 * utils.h: Rename include guard.
4716 * tracepoint.h: Rename include guard.
4717 * tdesc.h: Rename include guard.
4718 * target.h: Rename include guard.
4719 * server.h: Rename include guard.
4720 * remote-utils.h: Rename include guard.
4721 * regcache.h: Rename include guard.
4722 * nto-low.h: Rename include guard.
4723 * notif.h: Add include guard.
4724 * mem-break.h: Rename include guard.
4725 * lynx-low.h: Add include guard.
4726 * linux-x86-tdesc.h: Add include guard.
4727 * linux-s390-tdesc.h: Add include guard.
4728 * linux-ppc-tdesc-init.h: Add include guard.
4729 * linux-low.h: Add include guard.
4730 * linux-aarch64-tdesc.h: Add include guard.
4731 * linux-aarch32-low.h: Add include guard.
4732 * inferiors.h: Rename include guard.
4733 * i387-fp.h: Rename include guard.
4734 * hostio.h: Rename include guard.
4735 * gdbthread.h: Rename include guard.
4736 * gdb_proc_service.h: Rename include guard.
4737 * event-loop.h: Rename include guard.
4738 * dll.h: Rename include guard.
4739 * debug.h: Rename include guard.
4740 * ax.h: Rename include guard.
4742 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4745 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4746 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4748 2019-01-25 Tom Tromey <tom@tromey.com>
4750 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4752 2019-01-25 Tom Tromey <tom@tromey.com>
4754 * win32-low.c: Fix common/ includes.
4755 * win32-i386-low.c: Fix common/ includes.
4756 * tracepoint.c: Fix common/ includes.
4757 * thread-db.c: Fix common/ includes.
4758 * target.h: Fix common/ includes.
4759 * symbol.c: Fix common/ includes.
4760 * spu-low.c: Fix common/ includes.
4761 * server.h: Fix common/ includes.
4762 * server.c: Fix common/ includes.
4763 * remote-utils.c: Fix common/ includes.
4764 * regcache.h: Fix common/ includes.
4765 * regcache.c: Fix common/ includes.
4766 * nto-x86-low.c: Fix common/ includes.
4767 * notif.h: Fix common/ includes.
4768 * mem-break.h: Fix common/ includes.
4769 * lynx-low.c: Fix common/ includes.
4770 * lynx-i386-low.c: Fix common/ includes.
4771 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4772 * linux-x86-low.c: Fix common/ includes.
4773 * linux-low.c: Fix common/ includes.
4774 * inferiors.h: Fix common/ includes.
4775 * i387-fp.c: Fix common/ includes.
4776 * hostio.c: Fix common/ includes.
4777 * hostio-errno.c: Fix common/ includes.
4778 * gdbthread.h: Fix common/ includes.
4779 * gdbreplay.c: Fix common/ includes.
4780 * fork-child.c: Fix common/ includes.
4781 * event-loop.c: Fix common/ includes.
4783 (enum gdb_agent_op): Fix common/ includes.
4785 2019-01-21 Tom Tromey <tom@tromey.com>
4787 * tracepoint.c: Fix includes.
4788 * remote-utils.c: Fix includes.
4789 * linux-x86-low.c: Fix includes.
4791 2019-01-01 Joel Brobecker <brobecker@adacore.com>
4793 * gdbreplay.c (gdbreplay_version): Update copyright year in
4795 * server.c (gdbserver_version): Likewise.
4797 2018-12-05 Alan Hayward <alan.hayward@arm.com>
4799 * linux-low.c (add_lwp): Switch ordering.
4801 2018-11-29 Tom Tromey <tom@tromey.com>
4803 * win32-low.c (win32_join): Take pid, not process.
4804 * target.h (struct target_ops) <join>: Change argument type.
4805 (join_inferior): Change argument name.
4806 * spu-low.c (spu_join): Take pid, not process.
4807 * server.c (handle_detach): Preserve pid before destroying
4809 * lynx-low.c (lynx_join): Take pid, not process.
4810 * linux-low.c (linux_join): Take pid, not process.
4812 2018-11-23 Alan Hayward <alan.hayward@arm.com>
4814 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4815 (aarch64_cannot_fetch_register): Likewise.
4816 (struct linux_target_ops): Update references.
4818 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4820 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4822 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4824 * configure.srv (ipa_ppc_linux_regobj): Add
4825 powerpc-isa207-htm-vsx32l-ipa.o and
4826 powerpc-isa207-htm-vsx64l-ipa.o.
4827 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4828 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4829 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4830 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4831 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4832 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4833 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4834 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4835 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4836 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4837 (init_registers_powerpc_isa207_htm_vsx32l)
4838 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4839 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4840 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4841 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4842 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4843 (ppc_store_tm_ctarregset): New functions.
4844 (ppc_regsets): Add entries for HTM regsets.
4845 (ppc_arch_setup): Set htm in features struct when needed. Set
4846 sizes for the HTM regsets.
4847 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4848 (initialize_low_arch): Call
4849 init_registers_powerpc_isa207_htm_vsx32l and
4850 init_registers_powerpc_isa207_htm_vsx64l.
4851 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4852 PPC_TDESC_ISA207_HTM_VSX.
4853 (initialize_low_tracepoint): Call
4854 init_registers_powerpc_isa207_htm_vsx32l and
4855 init_registers_powerpc_isa207_htm_vsx64l.
4857 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4859 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4860 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4861 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4862 (ppc_store_pmuregset): New functions.
4863 (ppc_regsets): Add entries for ebb and pmu regsets.
4864 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4865 pmu regsets are available. Set sizes for these regsets.
4867 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4869 * configure.srv (ipa_ppc_linux_regobj): Add
4870 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4871 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4872 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4873 rs6000/powerpc-isa207-vsx32l.xml, and
4874 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4875 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4876 <PPC_TDESC_ISA207_VSX>: New enum value.
4877 (init_registers_powerpc_isa207_vsx32l): Declare.
4878 (init_registers_powerpc_isa207_vsx64l): Declare.
4879 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4880 (ppc_store_tarregset): New function.
4881 (ppc_regsets): Add entry for the TAR regset.
4882 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4883 size for the TAR regsets.
4884 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4885 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4886 and init_registers_powerpc_isa207_vsx64l.
4887 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4888 (initialize_low_tracepoint): Call
4889 init_registers_powerpc_isa207_vsx32l and
4890 init_registers_powerpc_isa207_vsx64l.
4892 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4893 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4895 * configure.srv (ipa_ppc_linux_regobj): Add
4896 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4897 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4898 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4899 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4900 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4901 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4902 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4903 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4904 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4905 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4906 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4907 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4908 (ppc_hwcap): Add comment.
4909 (ppc_hwcap2): New global.
4910 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4911 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4912 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4913 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4914 when needed. Set sizes for the the DSCR and PPR regsets.
4915 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4916 (initialize_low_arch): Call
4917 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4918 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4919 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4920 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4921 (initialize_low_tracepoint): Call
4922 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4923 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4925 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4927 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
4929 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
4930 Simon Marchi <simark@simark.ca>
4932 * acinclude.m4: Include "../selftest.m4".
4933 * configure: Regenerate.
4934 * configure.ac: Use "GDB_AC_SELFTEST".
4935 * configure.srv: Use "$enable_unittests" instead of
4936 "$development" when checking whether unit tests have been
4938 * server.c (captured_main): Update message informing that
4939 selftests have been disabled.
4941 2018-10-04 Tom Tromey <tom@tromey.com>
4943 * configure: Rebuild.
4945 2018-10-04 Tom Tromey <tom@tromey.com>
4947 * server.c (handle_status): Rename inner "thread".
4948 (process_serial_event): Declare "res" in 'm' case.
4949 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
4950 (iterate_over_lwps): Rename inner "thread".
4951 (linux_qxfer_libraries_svr4): Rename inner "len".
4952 * gdbthread.h (find_thread_in_random): Rename inner "thread".
4954 2018-10-01 Gary Benson <gbenson@redhat.com>
4956 * gdb_proc_service.h: Moved common code to
4957 common/gdb_proc_service.h.
4959 2018-10-01 Gary Benson <gbenson@redhat.com>
4961 * gdb_proc_service.h: Synchronize comments and whitespace with
4962 GDB's version of this file.
4964 2018-09-25 Tom Tromey <tom@tromey.com>
4966 * configure: Rebuild.
4967 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
4969 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4971 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
4972 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
4973 ($(IPA_LIB)): Sort IPA_OBJS.
4975 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4977 * Makefile.in: Remove references to $(ADD_DEPS).
4979 2018-09-16 Tom Tromey <tom@tromey.com>
4981 * remote-utils.c (remote_open): Use GNU style for metasyntactic
4983 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
4986 2018-09-05 Tom Tromey <tom@tromey.com>
4988 * configure: Rebuild.
4990 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4993 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
4995 2018-08-27 Tom Tromey <tom@tromey.com>
4998 * configure: Rebuild.
5000 2018-08-27 Tom Tromey <tom@tromey.com>
5002 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5003 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5004 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5005 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5006 (s390x_emit_stack_adjust): Add casts to unsigned char.
5008 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5012 * server.h (struct client_state) <disable_randomization>:
5015 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5017 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5019 (mips_supply_ptrace_register): Likewise.
5021 2018-07-22 Tom Tromey <tom@tromey.com>
5023 * configure: Rebuild.
5025 2018-07-22 Tom Tromey <tom@tromey.com>
5027 * win32-low.c (win32_create_inferior): Remove unused variables.
5028 * gdbreplay.c (remote_open): Remove unused variable.
5029 * remote-utils.c (remote_prepare): Remove unused variable.
5030 * x86-tdesc.h (X86_TDESC_H): Define.
5031 (amd64_expedite_regs): Define conditionally.
5032 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5033 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5034 * remote-utils.c (readchar): Remove unused variable.
5036 2018-07-13 Pedro Alves <palves@redhat.com>
5038 * linux-low.c (linux_kill): Change parameter to process_info
5039 pointer instead of pid. Adjust.
5040 * lynx-low.c (lynx_kill): Likewise.
5041 * nto-low.c (nto_kill): Likewise.
5042 * spu-low.c (spu_kill): Likewise.
5043 * win32-low.c (win32_kill): Likewise.
5044 * server.c (handle_v_kill, kill_inferior_callback)
5045 (detach_or_kill_for_exit): Adjust.
5046 * target.c (kill_inferior): Change parameter to process_info
5047 pointer instead of pid. Adjust.
5048 * target.h (struct target_ops) <kill>: Change parameter to
5049 process_info pointer instead of pid. Adjust all implementations
5051 (kill_inferior): Likewise.
5053 2018-07-13 Pedro Alves <palves@redhat.com>
5055 * linux-low.c (linux_detach, linux_join): Change parameter to
5056 process_info pointer instead of pid. Adjust.
5057 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5058 * nto-low.c (nto_detach): Likewise.
5059 * spu-low.c (spu_detach, spu_join): Likewise.
5060 * win32-low.c (win32_detach, win32_join): Likewise.
5061 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5062 * target.h (struct target_ops) <detach, join>: Change parameter to
5063 process_info pointer instead of pid. Adjust all implementations
5065 (detach_inferior, join_inferior): Rename 'pid' parameter to
5068 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5069 Jan Kratochvil <jan.kratochvil@redhat.com>
5070 Paul Fertser <fercerpav@gmail.com>
5071 Tsutomu Seki <sekiriki@gmail.com>
5073 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5074 (OBS): Add 'common/netstuff.o'.
5075 (GDBREPLAY_OBS): Likewise.
5076 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5077 (remote_open): Implement support for IPv6
5079 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5081 (handle_accept_event): Accept connections from IPv6 sources.
5082 (remote_prepare): Handle IPv6-style hostnames; implement
5083 support for IPv6 connections.
5084 (remote_open): Implement support for printing connections from
5087 2018-07-11 Pedro Alves <palves@redhat.com>
5090 * mem-break.c (any_persistent_commands): Add process_info
5091 parameter and use it instead of relying on the current process.
5092 Change return type to bool.
5093 * mem-break.h (any_persistent_commands): Add process_info
5094 parameter and change return type to bool.
5095 * server.c (handle_detach): Remove require_running_or_return call.
5096 Look up the process_info for the process we're about to detach.
5097 If not found, return back error to GDB. Adjust
5098 any_persistent_commands call to pass down a process pointer.
5100 2018-07-11 Pedro Alves <palves@redhat.com>
5102 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5103 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5104 instead of collect_register_by_name.
5105 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5106 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5108 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5109 Pedro Alves <palves@redhat.com>
5111 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5113 2018-07-03 Tom Tromey <tom@tromey.com>
5115 * linux-low.c: Update.
5116 * lynx-low.c: Update.
5117 * mem-break.c: Update.
5118 * nto-low.c: Update.
5119 * remote-utils.c: Update.
5121 * spu-low.c: Update.
5123 * win32-low.c: Update.
5125 2018-07-03 Tom Tromey <tom@tromey.com>
5129 2018-07-03 Tom Tromey <tom@tromey.com>
5131 * linux-low.c: Update.
5133 2018-07-03 Tom Tromey <tom@tromey.com>
5137 2018-07-03 Tom Tromey <tom@tromey.com>
5139 * linux-low.c: Update.
5140 * linux-mips-low.c: Update.
5141 * lynx-low.c: Update.
5142 * nto-low.c: Update.
5143 * remote-utils.c: Update.
5145 * spu-low.c: Update.
5147 * thread-db.c: Update.
5149 2018-07-03 Tom Tromey <tom@tromey.com>
5151 * linux-low.c: Update.
5152 * linux-mips-low.c: Update.
5153 * lynx-low.c: Update.
5154 * mem-break.c: Update.
5155 * nto-low.c: Update.
5156 * remote-utils.c: Update.
5158 * spu-low.c: Update.
5160 * tracepoint.c: Update.
5162 2018-07-03 Tom Tromey <tom@tromey.com>
5164 * linux-low.c: Update.
5165 * linux-ppc-low.c: Update.
5166 * linux-x86-low.c: Update.
5167 * proc-service.c: Update.
5169 * spu-low.c: Update.
5170 * thread-db.c: Update.
5171 * win32-low.c: Update.
5173 2018-07-03 Tom Tromey <tom@tromey.com>
5175 * linux-low.c: Update.
5176 * lynx-low.c: Update.
5177 * nto-low.c: Update.
5178 * remote-utils.c: Update.
5179 * spu-low.c: Update.
5180 * thread-db.c: Update.
5181 * win32-low.c: Update.
5183 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5185 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5186 parameter in call to 'amd64_create_target_description'.
5188 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5190 * x86-tdesc.h: Remove executable permission flag.
5192 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5194 * configure.ac: Remove AC_PREREQ, add missing quoting.
5195 * configure: Re-generate.
5196 * config.in: Re-generate.
5197 * aclocal.m4: Re-generate.
5199 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5201 * tracepoint.h (current_traceframe): Remove declaration.
5203 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5205 * linux-aarch64-low.c (is_sve_tdesc): New function.
5206 (aarch64_sve_regs_copy_to_regcache): Likewise.
5207 (aarch64_sve_regs_copy_from_regcache): Likewise.
5208 (aarch64_regs_info): Add SVE checks.
5209 (initialize_low_arch): Initialize SVE.
5211 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5213 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5215 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5217 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5218 (initialize_low_tracepoint): Likewise
5219 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5220 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5222 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5224 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5226 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5228 * server.h (PBUFSIZ): Increase size
5230 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5232 * regcache.c (regcache::raw_compare): New function.
5233 * regcache.h (regcache::raw_compare): New declaration.
5235 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5237 * regcache.c (new_register_cache): Use new.
5238 (free_register_cache): Use delete.
5239 (register_data): Use const.
5240 (supply_register): Move body inside regcache.
5241 (regcache::raw_supply): New override function.
5242 (collect_register): Move body inside regcache.
5243 (regcache::raw_collect): New override function.
5244 (regcache::get_register_status): New override function.
5245 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5247 2018-06-09 Tom Tromey <tom@tromey.com>
5249 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5251 (event_queue): Use std::queue.
5252 (gdb_event_xfree): Remove.
5253 (initialize_event_loop, process_event, wait_for_event): Update.
5255 2018-06-08 Stan Cox <scox@redhat.com>
5257 * win32-low.c (win32_create_inferior): last_ptid and last_status
5258 moved to client_state.
5260 2018-06-08 Pedro Alves <palves@redhat.com>
5262 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5263 common/common-exceptions.o, common/common-utils.o,
5264 common/errors.o, common/print-utils.o and utils.o.
5265 * gdbreplay.c: Include "common-defs.h" instead of the two
5266 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5267 string.h or alloca.h.
5268 (perror_with_name): Delete.
5269 (remote_open): Use xstrdup instead of strdup.
5270 (main): Rename to ...
5271 (captured_main): ... this.
5274 2018-06-08 Tom Tromey <tom@tromey.com>
5276 * linux-low.c (linux_low_read_btrace): Update.
5278 2018-06-04 Stan Cox <scox@redhat.com>
5280 * server.h (struct client_state): New.
5281 * server.c (cont_thread, general_thread, multi_process)
5282 (report_fork_events, report_vfork_events, report_exec_events)
5283 (report_thread_events, swbreak_feature, hwbreak_feature)
5284 (vCont_supported, disable_randomization, pass_signals)
5285 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5286 Moved to client_state.
5287 * remote-utils.c (remote_debug, noack_mode)
5288 (transport_is_reliable): Moved to client_state.
5289 * tracepoint.c (current_traceframe): Moved to client_state.
5292 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5293 linux-low.c, remote-utils.h, target.c: Use client_state.
5295 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5297 * configure.srv: Add new c/h file.
5299 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5301 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5304 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5306 * gdb.arch/mips-fpregset-core.exp: New test.
5307 * gdb.arch/mips-fpregset-core.c: New test source.
5309 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5312 * hostio.c (require_int): Do not report overflow for integers
5313 between 0xfffffff and 0x7fffffff.
5315 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5317 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5318 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5319 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5321 (the_low_target): Wire them.
5323 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5325 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5326 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5327 mode. Call collect_register_by_name with vscr using
5328 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5329 (ppc_store_vrregset): Add and set vscr_offset variable as in
5330 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5333 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5335 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5336 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5337 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5339 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5341 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5342 (ppc_store_vsxregset): Likewise.
5343 (ppc_fill_vrregset): Likewise.
5344 (ppc_store_vrregset): Likewise.
5345 (ppc_fill_evrregset): Likewise.
5346 (ppc_store_evrregset): Likewise.
5347 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5348 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5351 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5353 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5354 wordsize of the inferior. Call ppc_linux_target_wordsize.
5356 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5358 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5359 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5360 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5361 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5362 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5363 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5364 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5365 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5366 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5367 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5368 (tdesc_powerpc_e500l): Remove.
5369 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5370 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5371 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5372 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5374 (ppc_arch_setup): Remove target description matching code. Fill a
5375 ppc_linux_features struct and call ppc_linux_match_description
5378 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5380 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5381 width of the requested register exceeds the width of the
5383 (mips_cannot_store_register): Likewise.
5385 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5387 * linux-mips-low.c (mips_fetch_register): New function. Update
5389 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5390 (the_low_target): Wire `mips_fetch_register'.
5392 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5394 * lynx-i386-low.c (LYNXOS_178): New macro.
5395 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5396 the layout on LynxOS-178.
5397 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5398 handle floating point registers that are not supported by
5401 2018-05-10 Tom Tromey <tom@tromey.com>
5403 * configure: Rebuild.
5405 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5408 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5409 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5410 Use it to set the expedite_regs field in the given tdesc.
5411 * x86-tdesc.h: New file.
5412 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5413 Adjust following the addition of the new expedite_regs parameter
5414 to init_target_desc.
5415 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5416 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5417 (i386_linux_read_description, amd64_linux_read_description):
5418 Adjust following the addition of the new expedite_regs parameter
5419 to init_target_desc.
5420 * lynx-i386-low.c: #include "x86-tdesc.h".
5421 (lynx_i386_arch_setup): Adjust following the addition of the new
5422 expedite_regs parameter to init_target_desc.
5423 * nto-x86-low.c: #include "x86-tdesc.h".
5424 (nto_x86_arch_setup): Adjust following the addition of the new
5425 expedite_regs parameter to init_target_desc.
5426 * win32-i386-low.c: #include "x86-tdesc.h".
5427 (i386_arch_setup): Adjust following the addition of the new
5428 expedite_regs parameter to init_target_desc.
5430 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5433 * win32-low.c (win32_create_inferior): Add call to my_wait
5434 setting last_status global.
5436 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5439 * win32-low.c (create_process): Only call gdb_tilde_expand if
5440 inferior_cwd is not NULL.
5442 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5444 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5445 registers to the cache if their values have changed.
5446 (i387_xsave_to_cache): Provide default values for x87 control
5447 registers when these features are available, but disabled.
5448 * regcache.c (supply_register_by_name_zeroed): New function.
5449 * regcache.h (supply_register_by_name_zeroed): Declare new
5452 2018-05-07 Tom Tromey <tom@tromey.com>
5454 * configure: Rebuild.
5456 2018-05-04 Tom Tromey <tom@tromey.com>
5458 * configure: Rebuild.
5460 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5461 Pedro Alves <palves@redhat.com>
5463 * linux-aarch64-low.c (aarch64_stopped_data_address):
5466 2018-04-27 Tom Tromey <tom@tromey.com>
5468 * configure: Rebuild.
5470 2018-04-23 Tom Tromey <tom@tromey.com>
5472 * configure: Rebuild.
5474 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5476 * Makefile.in (depcomp): Add "..".
5477 (all_deps_files): New and use it.
5479 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5481 * configure.srv (aarch64*-*-linux*): Don't include xml.
5482 (i[34567]86-*-cygwin*): Likewise.
5483 (i[34567]86-*-linux*): Likewise.
5484 (i[34567]86-*-lynxos*): Likewise.
5485 (i[34567]86-*-mingw32ce*): Likewise.
5486 (i[34567]86-*-mingw*): Likewise.
5487 (i[34567]86-*-nto*): Likewise.
5488 (tic6x-*-uclinux): Likewise.
5489 (x86_64-*-linux*): Likewise.
5490 (x86_64-*-mingw*): Likewise.
5491 (x86_64-*-cygwin*): Likewise.
5493 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5495 * tdesc.c: Remove xml parameter.
5497 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5499 * server.c (get_features_xml): Remove cast.
5500 * tdesc.c (void target_desc::accept): Fill in function.
5501 (tdesc_get_features_xml): Remove old xml creation.
5502 (print_xml_feature::visit_pre): Add xml vistor.
5503 * tdesc.h (struct target_desc): Make xmltarget mutable.
5504 (tdesc_get_features_xml): Remove declaration.
5506 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5508 * tdesc.c (tdesc_architecture_name): Add new function.
5509 (tdesc_osabi_name): Likewise.
5510 (tdesc_get_features_xml): Use new functions.
5512 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5514 * tdesc.c (tdesc_create_flags): Remove.
5515 (tdesc_add_flag): Likewise.
5516 (tdesc_named_type): Likewise.
5517 (tdesc_create_union): Likewise.
5518 (tdesc_create_struct): Likewise.
5519 (tdesc_create_vector): Likewise.
5520 (tdesc_add_bitfield): Likewise.
5521 (tdesc_add_field): Likewise.
5522 (tdesc_set_struct_size): Likewise.
5524 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5526 * tdesc.c (~target_desc): Remove implictly deleted items.
5527 (init_target_desc): Iterate all features.
5528 (tdesc_get_features_xml): Use vector.
5529 (tdesc_create_feature): Create feature.
5530 * tdesc.h (tdesc_feature) Remove
5531 (target_desc): Add features.
5533 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5535 * Makefile.in: Add common/tdesc.c
5536 * tdesc.c (init_target_desc): init all reg_defs from register
5538 (tdesc_create_reg): Create tdesc_reg.
5539 * tdesc.h (tdesc_feature): Add register vector.
5541 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5543 * tdesc.h (struct target_desc) <features>: Change type to
5544 std::vector<std::string>.
5545 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5547 (tdesc_get_features_xml): Likewise.
5548 (tdesc_create_feature): Likewise.
5550 2018-03-26 Alan Hayward <alan.hayward@arm.com>
5552 * regcache.c (find_register_by_number): Return a ref.
5553 (find_regno): Use references.
5554 (register_size): Likewise.
5555 (register_data): Likewise.
5556 * tdesc.c (target_desc::~target_desc): Remove free calls.
5557 (target_desc::operator==): Use std::vector compare.
5558 (init_target_desc): Use reference.
5559 (tdesc_create_reg): Use reg constructors.
5560 * tdesc.h (struct target_desc): Replace pointer with object.
5562 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5564 * regcache.c (find_register_by_number): Make static.
5565 (find_regno): Use find_register_by_number
5566 * regcache.h (struct reg): Remove declaration.
5568 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5570 * tdesc.c (target_desc::~target_desc): Move to here.
5571 (target_desc::operator==): Likewise.
5572 * tdesc.h (target_desc::~target_desc): Move from here.
5573 (target_desc::operator==): Likewise.
5575 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5577 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5579 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5581 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5583 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5584 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5585 and init_registers_s390_gs_linux64.
5587 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5589 * linux-s390-low.c (s390_fill_gs): Remove function.
5590 (s390_fill_gsbc): Remove function.
5591 (s390_regsets): Set fill functions for the guarded storage regsets
5594 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5596 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5597 the word size. Add comment.
5598 (s390_get_wordsize): New function.
5599 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5600 pswm with it. Instead, use s390_get_wordsize to determine the
5601 word size first and derive the correct tdesc from that directly.
5603 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5605 * Makefile.in: Include silent-rules.mk.
5606 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5607 (COMPILE): Add ECHO_CXX.
5608 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5609 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5610 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5611 (version-generated.c): Add ECHO_GEN.
5612 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5613 (IPAGENT_COMPILE): Add ECHO_CXX.
5614 (%-generated.c): Add ECHO_REGDAT.
5616 2018-03-14 Tom Tromey <tom@tromey.com>
5619 * ax.c (ax_printf): Special case for NULL.
5621 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5623 * linux-low.c (linux_qxfer_libraries_svr4): Use
5624 xml_escape_text_append.
5626 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5628 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5630 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5632 * server.c (handle_general_set): Remove unnecessary xstrdup.
5634 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5636 * server.c (parse_debug_format_options): Adjust to
5637 delim_string_to_char_ptr_vec changes.
5638 * thread-db.c (thread_db_load_search): Adjust to
5639 dirnames_to_char_ptr_vec changes.
5641 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5643 * target.h (target_enable_btrace, target_disable_btrace)
5644 (target_read_btrace, target_read_btrace_conf): Turn macro into
5645 inline function. Throw error if target method is not defined.
5646 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5647 check for btrace target method. Be prepared to handle exceptions
5648 from btrace target methods.
5650 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5652 * server.c (captured_main): Change order of error message printed
5653 when the current working directory cannot be found.
5655 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5657 * server.c: Include "filenames.h" and "pathstuff.h".
5658 (program_name): Delete variable.
5659 (program_path): New anonymous class.
5660 (get_exec_wrapper): Use "program_path" instead of
5662 (handle_v_run): Likewise.
5663 (captured_main): Likewise.
5664 (process_serial_event): Likewise.
5666 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5668 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5669 (OBJS): Add "pathstuff.o".
5670 * server.c (current_directory): New global variable.
5671 (captured_main): Initialize "current_directory".
5673 2018-02-26 Alan Hayward <alan.hayward@arm.com>
5675 * tdesc.c: Use common/tdesc.h.
5676 * tdesc.h: Likewise.
5678 2018-02-20 Alan Hayward <alan.hayward@arm.com>
5679 Simon Marchi <simon.marchi@ericsson.com>
5681 * Makefile.in: Switch order of make rules.
5683 2018-02-19 Alan Hayward <alan.hayward@arm.com>
5685 * Makefile.in: Add common directory in build.
5686 * configure.ac: Add common reference.
5687 * configure: Regenerate.
5689 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5691 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5692 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5693 * spu-low.c (spu_target_ops): Likewise.
5694 * win32-low.c (win32_target_ops): Likewise.
5695 * server.c (supported_btrace_packets): Report packets unconditionally.
5696 * target.h (target_ops) <supports_btrace>: Remove.
5697 (target_supports_btrace): Remove.
5699 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5701 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5702 (handle_btrace_disable): Change return type to void. Use exceptions
5704 (handle_btrace_general_set): Catch exception and copy message to
5707 2018-02-08 Tom Tromey <tom@tromey.com>
5709 * linux-low.c (install_software_single_step_breakpoints): Use
5710 make_scoped_restore.
5711 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5712 (do_restore_current_thread_cleanup): Remove.
5713 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5716 2018-02-08 Tom Tromey <tom@tromey.com>
5718 * mem-break.c (set_raw_breakpoint_at): Use
5719 gdb::unique_xmalloc_ptr.
5721 2018-01-30 Pedro Alves <palves@redhat.com>
5724 * target.c (target_terminal::terminal_state): Rename to ...
5725 (target_terminal::m_terminal_state): ... this.
5727 2018-01-19 James Clarke <jrtc27@jrtc27.com>
5729 * linux-low.c (handle_extended_wait): Surround call to
5730 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5732 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5734 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5735 linux_ptrace_attach_fail_reason_string now returning an
5737 (linux_attach): Likewise.
5738 * thread-db.c (attach_thread): Likewise.
5740 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5743 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5744 checking for fs_base/gs_base fields in struct user_regs_struct.
5745 * configure: Regenerate.
5747 2018-01-16 Yao Qi <yao.qi@linaro.org>
5750 * linux-low.c (fetch_register): Call supply_register instead of
5753 2018-01-08 Yao Qi <yao.qi@linaro.org>
5754 Simon Marchi <simon.marchi@ericsson.com>
5756 * Makefile.in (OBS): Remove selftest.o.
5757 * configure.ac: Set srv_selftest_objs if $development is true.
5758 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5759 * configure: Re-generated.
5760 * server.c (captured_main): Wrap variable selftest_filter with
5763 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5765 * server.c (parse_debug_format_options): Return std::string.
5766 (handle_monitor_command, captured_main): Adjust.
5768 2018-01-05 Pedro Alves <palves@redhat.com>
5771 * server.c (captured_main): Pass quiet=false to
5772 save_original_signals_state.
5774 2018-01-01 Joel Brobecker <brobecker@adacore.com>
5776 * gdbreplay.c (gdbreplay_version): Update copyright year in
5778 * server.c (gdbserver_version): Likewise.
5780 2017-12-08 Tom Tromey <tom@tromey.com>
5782 * ax.c (ax_printf): Update.
5784 2017-12-07 Yao Qi <yao.qi@linaro.org>
5786 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5787 aarch64_linux_read_description.
5788 * linux-amd64-ipa.c (idx2mask): New array.
5789 (get_ipa_tdesc): Move idx2mask out.
5790 (initialize_low_tracepoint): Initialize target descriptions.
5791 * linux-i386-ipa.c (idx2mask): New array.
5792 (get_ipa_tdesc): Move idx2mask out.
5793 (initialize_low_tracepoint): Initialize target descriptions.
5795 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5797 * tdesc.c (struct tdesc_type): Change return type.
5798 (tdesc_add_flag): Change parameter type.
5799 (tdesc_add_bitfield): Likewise.
5800 (tdesc_add_field): Likewise.
5801 (tdesc_set_struct_size): Likewise.
5803 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5805 * regcache.c (registers_to_string): Remove unused variable.
5807 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5809 * inferiors.c (for_each_inferior_with_data): Remove.
5810 * inferiors.h (for_each_inferior_with_data): Remove.
5811 * server.c (handle_qxfer_threads_worker): Change parameter type.
5812 (handle_qxfer_threads_proper): Use for_each_thread.
5814 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5816 * inferiors.c (for_each_inferior): Remove.
5817 (clear_inferiors): Use for_each_thread.
5818 * inferiors.h (for_each_inferior): Remove.
5819 * linux-low.c (linux_wait_for_event_filtered): Use
5821 (linux_stabilize_threads): Likewise.
5822 * regcache.c (regcache_release): Likewise.
5823 * server.c (gdb_wants_all_threads_stopped): Likewise.
5824 (clear_pending_status_callback): Remove.
5825 (handle_status): Use for_each_thread.
5826 (captured_main): Likewise.
5827 * win32-low.c (child_init_thread_list): Likewise.
5828 (win32_clear_inferiors): Likewise.
5829 (fake_breakpoint_event): Likewise.
5831 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5833 * inferiors.h (find_inferior): Remove.
5834 * inferiors.c (find_inferior): Remove.
5836 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5838 * linux-low.c (resume_status_pending_p): Update comment.
5839 (need_step_over_p): Update comment.
5841 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5843 * linux-low.c (proceed_one_lwp): Return void, change parameter
5845 (unsuspend_and_proceed_one_lwp): Likewise.
5846 (proceed_all_lwps): Use for_each_thread.
5847 (unstop_all_lwps): Likewise.
5849 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5851 * linux-low.c (linux_resume_one_thread): Return void, take
5853 (linux_resume): Use for_each_thread.
5855 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5857 * linux-low.c (send_sigstop_callback): Return void, change
5858 parameter type. Rename to...
5859 (send_sigstop): ... this.
5860 (suspend_and_send_sigstop_callback): Return void, change parameter
5862 (suspend_and_send_sigstop): ... this.
5863 (stop_all_lwps): Use for_each_thread.
5865 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5867 * linux-low.c (lwp_running): Return bool, remove unused
5869 (linux_stabilize_threads): Use find_thread.
5871 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5873 * linux-low.c (select_singlestep_lwp_callback): Remove.
5874 (count_events_callback): Remove.
5875 (select_event_lwp_callback): Remove.
5876 (select_event_lwp): Use find_thread/for_each_thread.
5878 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5880 * linux-low.c (not_stopped_callback): Return bool, take filter
5882 (linux_wait_for_event_filtered): Use find_thread.
5883 (linux_wait_1): Likewise.
5885 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5887 * linux-low.c (same_lwp): Remove.
5888 (find_lwp_pid): Use find_thread.
5890 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5892 * linux-low.c (delete_lwp_callback): Remove.
5893 (linux_mourn): Use for_each_thread.
5895 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5897 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5898 args parameter, don't check for pid.
5899 (linux_detach): Use for_each_thread.
5901 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5903 * linux-low.c (struct counter): Remove.
5904 (second_thread_of_pid_p): Remove.
5905 (last_thread_of_process_p): Use find_thread.
5907 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5909 * inferiors.c (find_inferior_in_random): Remove.
5910 * inferiors.h (find_inferior_in_random): Remove.
5911 * linux-low.c (status_pending_p_callback): Return bool, accept
5912 parameter ptid directly.
5913 (linux_wait_for_event_filtered): Use find_thread_in_random.
5914 (linux_wait_1): Likewise.
5916 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5918 * inferiors.c (find_inferior_id): Remove.
5919 (find_thread_ptid): Move implemention from find_inferior_id to
5921 * inferiors.h (find_inferior_id): Remove.
5922 * server.c (handle_status): Use find_thread_ptid.
5923 (process_serial_event): Likewise.
5924 * thread-db.c (find_one_thread): Likewise.
5925 (thread_db_thread_handle): Likewise.
5926 * win32-low.c (thread_rec): Likewise.
5927 (child_delete_thread): Likewise.
5928 (win32_thread_alive): Likewise.
5929 (get_child_debug_event): Likewise.
5931 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5933 * linux-mips-low.c (update_watch_registers_callback): Return
5934 void, remove pid_p parameter, don't check for pid.
5935 (mips_insert_point, mips_remove_point): Use for_each_thread.
5937 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5939 * lynx.low (lynx_delete_thread_callback): Remove.
5940 (lynx_mourn): Use for_each_thread.
5942 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5944 * regcache.c (regcache_invalidate_one): Remove.
5945 (regcache_invalidate_pid): use for_each_thread.
5947 2017-11-26 Tom Tromey <tom@tromey.com>
5949 * linux-low.c (linux_create_inferior): Update.
5951 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
5953 * spu-low.c (spu_create_inferior): Fix typo in argument name.
5955 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5957 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
5958 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5959 * linux-aarch64-tdesc-selftest.c: New file.
5960 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5962 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5964 * configure.srv: Add new file.
5965 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5966 * linux-aarch64-tdesc-selftest.c: New file.
5967 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5969 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5971 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
5972 * linux-aarch64-low.c (initialize_low_arch): Remove init.
5973 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
5975 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5977 * configure.srv: Add new files.
5978 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
5979 aarch64_linux_read_description.
5980 * linux-aarch64-low.c (aarch64_linux_read_description):
5981 Merge with aarch64_arch_setup.
5982 (aarch64_arch_setup): Call aarch64_linux_read_description.
5983 * linux-aarch64-tdesc.c: New file.
5984 * linux-aarch64-tdesc.h: New file.
5986 2017-11-24 Yao Qi <yao.qi@linaro.org>
5988 * configure.srv: Set $srv_regobj for tic6x-linux.
5989 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
5990 (tic6x_read_description): Move some code to tic6x_arch_setup.
5991 (tic6x_tdesc_test): New function.
5992 (initialize_low_arch): Call selftests::register_test.
5994 2017-11-22 Yao Qi <yao.qi@linaro.org>
5996 * remote-utils.c (prepare_resume_reply): Use memcpy.
5998 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6000 * linux-low.c (kill_one_lwp_callback): Return void, take
6001 argument directly, don't filter on pid.
6002 (linux_kill): Use for_each_thread.
6004 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6006 * linux-low.c (need_step_over_p): Return bool, remove dummy
6008 (linux_resume, proceed_all_lwps): Use find_thread.
6010 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6012 * linux-low.c (resume_status_pending_p): Return bool, remove
6014 (linux_resume): Use find_thread.
6016 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6018 * linux-low.c (struct thread_resume_array): Remove.
6019 (linux_set_resume_request): Return void, take arguments
6021 (linux_resume): Use for_each_thread.
6023 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6025 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6026 return bool, remove data argument.
6027 (linux_stabilize_threads): Use find_thread.
6029 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6031 * linux-low.c (unsuspend_one_lwp): Remove.
6032 (unsuspend_all_lwps): Use for_each_thread, inline code from
6035 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6037 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6038 * linux-low.c (struct iterate_over_lwps_args): Remove.
6039 (iterate_over_lwps_filter): Remove.
6040 (iterate_over_lwps): Use find_thread.
6042 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6044 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6045 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6046 code from reset_lwp_ptrace_options_callback.
6048 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6050 * linux-arm-low.c (struct update_registers_data): Remove.
6051 (update_registers_callback): Return void, take arguments
6052 directly, don't check thread's pid.
6053 (arm_insert_point, arm_remove_point): Use for_each_thread.
6055 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6057 * win32-low.c (continue_one_thread): Return void, take argument
6059 (child_continue): Use for_each_thread.
6061 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6063 * win32-i386-low.c (update_debug_registers_callback): Rename
6065 (update_debug_registers): ... this, return void, remove pid_p arg.
6066 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6068 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6070 * inferiors.h (struct process_info): Add constructor, initialize
6072 <syscalls_to_catch>: Change type to std::vector<int>.
6073 * inferiors.c (add_process): Allocate process_info with new.
6074 (remove_process): Free process_info with delete.
6075 * linux-low.c (handle_extended_wait): Adjust.
6076 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6077 * server.c (handle_general_set): Adjust.
6079 2017-11-16 Pedro Alves <palves@redhat.com>
6081 * remote-utils.c (remote_close): Block SIGIO signals instead of
6082 uninstalling the SIGIO handler.
6084 2017-11-16 Alan Hayward <alan.hayward@arm.com>
6086 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6088 2017-11-16 Yao Qi <yao.qi@linaro.org>
6090 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6091 (tic6x_store_gregset): Likewise.
6092 (tic6x_usrregs_info): Move it up.
6094 2017-11-15 Alan Hayward <alan.hayward@arm.com>
6096 * Makefile.in: Update arch rules.
6097 * configure.srv: Explicitly mark arch/ files.
6099 2017-11-13 Andreas Schwab <schwab@suse.de>
6101 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6103 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6105 2017-11-06 Pedro Alves <palves@redhat.com>
6107 * config.in, configure: Regenerate.
6109 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6111 * target.c (struct thread_search): Remove.
6112 (thread_search_callback): Remove.
6113 (prepare_to_access_memory): Use for_each_thread instead of
6114 find_inferior. Inline code from thread_search_callback.
6116 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6118 * server.c (struct visit_actioned_threads_data): Remove.
6119 (visit_actioned_threads): Change prototype to take arguments
6121 (resume): Use find_thread instead of find_inferior.
6123 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6125 * server.c (queue_stop_reply_callback): Change prototype, return
6127 (find_status_pending_thread_callback): Remove.
6128 (handle_status): Replace find_inferior with find_thread and
6131 2017-10-25 Alan Hayward <alan.hayward@arm.com>
6133 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6135 (aarch64_store_gregset): Likewise.
6136 (aarch64_fill_fpregset): Likewise.
6137 (aarch64_store_fpregset): Likewise.
6139 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6141 * gdbthread.h (find_thread, for_each_thread): New functions.
6142 * inferiors.c (thread_of_pid): Remove.
6143 (find_any_thread_of_pid): Use find_thread.
6144 * linux-low.c (num_lwps): Use for_each_thread.
6146 2017-10-17 Yao Qi <yao.qi@linaro.org>
6148 * Makefile.in: Remove one rule.
6149 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6151 2017-10-17 Yao Qi <yao.qi@linaro.org>
6153 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6154 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6156 2017-10-17 Yao Qi <yao.qi@linaro.org>
6158 * configure.srv: Rename arm.o with arch/arm.o.
6160 2017-10-17 Yao Qi <yao.qi@linaro.org>
6162 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6163 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6164 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6165 (arch-i386.o, arch-amd64.o): Remove rules.
6166 (arch/%.o): New rule.
6167 Update POSTCOMPILE and COMPILE.pre.
6168 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6169 * configure: Re-generated.
6170 * configure.srv: Replace arch-i386.o with arch/i386.o.
6171 Replace arch-amd64.o with arch/amd64.o.
6173 2017-10-16 Yao Qi <yao.qi@linaro.org>
6175 * configure: Regenerated.
6177 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6179 * inferiors.h: (struct inferior_list): Remove.
6180 (struct inferior_list_entry); Remove.
6181 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6182 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6183 get_first_inferior): Remove.
6184 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6185 find_inferior_id, find_inferior_in_random): Change signature.
6186 * inferiors.c (all_threads): Change type to
6187 std::list<thread_info *>.
6188 (get_thread): Remove macro.
6189 (find_inferior, find_inferior_id): Change signature, implement
6191 (find_inferior_in_random): Change signature, implement using
6192 find_thread_in_random.
6193 (for_each_inferior, for_each_inferior_with_data): Change
6194 signature, implement using for_each_thread.
6195 (add_inferior_to_list, remove_inferior): Remove.
6196 (add_thread, get_first_thread, thread_of_pid,
6197 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6198 (get_first_inferior, one_inferior_p, clear_inferior_list):
6200 (clear_inferiors, get_thread_process): Update.
6201 * gdbthread.h: Include <list>.
6202 (struct thread_info) <entry>: Remove field.
6204 (all_threads): Change type to std::list<thread_info *>.
6205 (get_first_inferior): Add doc.
6206 (find_thread, for_each_thread, find_thread_in_random): New
6208 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6209 * linux-arm-low.c (update_registers_callback): Update.
6210 * linux-low.c (second_thread_of_pid_p): Update.
6211 (kill_one_lwp_callback, linux_detach_lwp_callback,
6212 delete_lwp_callback, status_pending_p_callback, same_lwp,
6213 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6214 iterate_over_lwps, not_stopped_callback,
6215 resume_stopped_resumed_lwps, count_events_callback,
6216 select_singlestep_lwp_callback, select_event_lwp_callback,
6217 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6218 suspend_and_send_sigstop_callback, wait_for_sigstop,
6219 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6220 lwp_running, linux_set_resume_request, resume_status_pending_p,
6221 need_step_over_p, start_step_over, linux_resume_one_thread,
6222 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6223 reset_lwp_ptrace_options_callback): Update.
6224 * linux-mips-low.c (update_watch_registers_callback): Update.
6225 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6227 (free_register_cache_thread_one): Remove.
6228 (regcache_release): Update.
6229 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6230 handle_qxfer_threads_worker): Update.
6231 (handle_query): Update, use list iterator.
6232 (visit_actioned_threads, handle_pending_status,
6233 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6234 clear_pending_status_callback, set_pending_status_callback,
6235 find_status_pending_thread_callback, handle_status,
6236 process_serial_event): Update.
6237 * target.c (thread_search_callback): Update.
6238 * thread-db.c (thread_db_get_tls_address): Update.
6239 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6241 * win32-i386-low.c (update_debug_registers_callback): Update.
6242 * win32-low.c (delete_thread_info, child_delete_thread,
6243 continue_one_thread, suspend_one_thread,
6244 get_child_debug_event): Adjust.
6246 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6248 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6249 * inferiors.h: Include <list>.
6250 (struct process_info) <entry>: Remove field.
6252 (pid_of): Change macro to function.
6253 (ptid_of, lwpid_of): Remove macro.
6254 (all_processes): Change type to std::list<process_info *>.
6255 (ALL_PROCESSES): Remove macro.
6256 (for_each_process, find_process): New function.
6257 * inferiors.c (all_processes): Change type to
6258 std::list<process_info *>.
6259 (find_thread_process): Adjust.
6260 (add_process): Likewise.
6261 (remove_process): Likewise.
6262 (find_process_pid): Likewise.
6263 (get_first_process): Likewise.
6264 (started_inferior_callback): Remove.
6265 (have_started_inferiors_p): Adjust.
6266 (attached_inferior_callback): Remove.
6267 (have_attached_inferiors_p): Adjust.
6268 * linux-low.c (check_zombie_leaders): Likewise.
6269 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6270 (x86_linux_update_xmltarget): Adjust.
6271 * server.c (handle_query): Likewise.
6272 (gdb_reattached_process): Remove.
6273 (handle_status): Adjust.
6274 (kill_inferior_callback): Likewise.
6275 (detach_or_kill_inferior): Remove.
6276 (print_started_pid): Likewise.
6277 (print_attached_pid): Likewise.
6278 (detach_or_kill_for_exit): Update.
6279 (process_serial_event): Likewise.
6280 * linux-arm-low.c (arm_new_fork): Likewise.
6282 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6284 * dll.h: Include <list>.
6285 (struct dll_info): Add constructor.
6286 <entry>: Remove field.
6287 (all_dlls): Change type to std::list<dll_info>.
6288 * dll.c: Include <algorithm>.
6289 (get_dll): Remove macro.
6290 (all_dlls): Change type to std::list<dll_info *>.
6291 (free_one_dll): Remove.
6292 (match_dll): Likewise.
6293 (loaded_dll): Adjust.
6294 (unloaded_dll): Adjust to all_dlls type change, use
6295 std::find_if. Inline code from match_dll.
6296 (clear_dlls): Adjust to all_dlls type change.
6297 * server.c (emit_dll_description): Remove.
6298 (handle_qxfer_libraries): Adjust to all_dlls type change,
6299 integrate emit_dll_description's functionality.
6301 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6303 * linux-low.h (struct linux_target_ops) <delete_process>: New
6305 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6306 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6307 (struct linux_target_ops): Add delete_process callback.
6308 * linux-arm-low.c (arm_delete_process): New.
6309 (struct linux_target_ops): Add delete_process callback.
6310 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6311 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6312 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6313 * linux-mips-low.c (mips_linux_delete_process): New.
6314 (struct linux_target_ops): Add delete_process callback.
6315 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6316 * linux-s390-low.c (struct linux_target_ops): Likewise.
6317 * linux-sh-low.c (struct linux_target_ops): Likewise.
6318 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6319 * linux-tile-low.c (struct linux_target_ops): Likewise.
6320 * linux-x86-low.c (x86_linux_delete_process): New.
6321 (struct linux_target_ops): Add delete_process callback.
6322 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6324 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6326 * linux-aarch64-low.c (the_low_target): Add thread delete
6328 * linux-arm-low.c (arm_delete_thread): New function.
6329 (the_low_target): Add thread delete callback.
6330 * linux-bfin-low.c (the_low_target): Likewise.
6331 * linux-crisv32-low.c (the_low_target): Likewise.
6332 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6334 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6336 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6337 * linux-mips-low.c (mips_linux_delete_thread): New function.
6338 (the_low_target): Add thread delete callback.
6339 * linux-ppc-low.c (the_low_target): Likewise.
6340 * linux-s390-low.c (the_low_target): Likewise.
6341 * linux-sh-low.c (the_low_target): Likewise.
6342 * linux-tic6x-low.c (the_low_target): Likewise.
6343 * linux-tile-low.c (the_low_target): Likewise.
6344 * linux-x86-low.c (the_low_target): Likewise.
6345 * linux-xtensa-low.c (the_low_target): Likewise.
6347 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6349 * win32-low.c: Include "common-inferior.h".
6351 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6353 * inferiors.c (set_inferior_cwd): New function.
6354 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6355 (handle_query): Inform that QSetWorkingDir is supported.
6356 * win32-low.c (create_process): Pass the inferior's cwd to
6359 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6361 * inferiors.c (current_inferior_cwd): New global variable.
6362 (get_inferior_cwd): New function.
6363 * inferiors.h (struct process_info) <cwd>: New field.
6365 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6367 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6368 (OBS): Add gdb_tilde_expand.o.
6370 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6372 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6373 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6375 2017-09-29 Pedro Alves <palves@redhat.com>
6377 * ax.c (gdb_parse_agent_expr): Constify.
6378 * ax.h (gdb_parse_agent_expr): Constify.
6379 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6381 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6382 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6383 * remote-utils.h (read_ptid): Constify.
6384 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6385 (process_point_options, process_serial_event): Constify.
6386 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6387 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6388 (cmd_qtbuffer): Constify.
6390 2017-09-29 Pedro Alves <palves@redhat.com>
6392 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6395 2017-09-29 Pedro Alves <palves@redhat.com>
6397 * linux-low.c (handle_extended_wait): Pass parent thread instead
6398 of process to thread_db_notice_clone.
6399 * linux-low.h (thread_db_notice_clone): Replace parent process
6400 parameter with parent thread parameter.
6401 * thread-db.c (find_one_thread): Add comment.
6402 (thread_db_notice_clone): Replace parent process parameter with
6403 parent thread parameter. Temporarily switch to the parent thread.
6405 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6407 * gdbthread.h: Include "common-gdbthread.h".
6408 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6409 "if" when validating the ptid.
6410 * remote-utils.c: Include "gdbthread.h".
6411 (prepare_resume_reply): Use "switch_to_thread".
6412 * target.c (done_accessing_memory): Likewise.
6414 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6416 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6417 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6418 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6419 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6420 s390x-gs-linux64-ipa.o to ipa_obj.
6421 * linux-s390-low.c (HWCAP_S390_GS): New define.
6422 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6424 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6425 (s390_arch_setup): Check for guarded-storage support and choose
6427 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6428 init_registers_s390x_gs_linux64.
6429 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6431 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6432 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6434 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6436 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6438 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6440 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6441 (thread_db_thread_handle): Declare.
6442 * linux-low.c (linux_target_ops): Initialize thread_handle.
6443 * server.c (handle_qxfer_threads_worker): Add support for
6445 * target.h (struct target_ops): Add new function pointer,
6447 (target_thread_handle): Define.
6448 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6450 (thread_db_thread_handle): New function.
6452 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6454 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6455 * linux-low.h (thread_db_notice_clone): Declare.
6456 * thread-db.c (thread_db_notice_clone): New function.
6458 2017-09-21 Pedro Alves <palves@redhat.com>
6460 * server.c (gdb_read_memory, handle_status, process_serial_event)
6461 (handle_serial_event, handle_target_event): Adjust to
6462 set_desired_thread prototype change.
6463 * target.c (set_desired_thread): Remove 'use_general' parameter
6465 * target.h (set_desired_thread): Remove 'use_general' parameter.
6467 2017-09-20 Tom Tromey <tom@tromey.com>
6469 * target.c (target_terminal::terminal_state): Define.
6470 (target_terminal::init): Rename from target_terminal_init.
6471 (target_terminal::inferior): Rename from
6472 target_terminal_inferior.
6473 (target_terminal::ours): Rename from target_terminal_ours.
6474 (target_terminal::ours_for_output, target_terminal::info): New.
6476 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6478 * server.c (accumulate_file_name_length): Remove.
6479 (emit_dll_description): Adjust to std::string change.
6480 (handle_qxfer_libraries): Use std::string to hold document.
6482 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6484 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6485 return type of xml_escape_text.
6486 * server.c (emit_dll_description): Likewise.
6488 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6490 * server.c (captured_main): Accept argument for --selftest.
6491 Update run_tests call.
6492 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6493 when registering selftests.
6495 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6497 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6498 instead of "VEC" for "target_desc.reg_defs".
6499 (regcache_cpy): Likewise.
6500 (registers_to_string): Likewise.
6501 (registers_from_string): Likewise.
6502 (find_regno): Likewise.
6503 (supply_regblock): Likewise.
6504 (regcache_raw_read_unsigned): Likewise.
6505 * tdesc.c (init_target_desc): Likewise.
6506 (tdesc_create_reg): Likewise.
6507 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6508 (struct target_desc) <reg_defs>: Convert to "std::vector".
6509 (target_desc): Do not initialize "reg_defs".
6510 (~target_desc): Update code to use "std::vector" instead of "VEC"
6511 for "target_desc.reg_defs".
6512 (operator==): Likewise.
6514 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6516 * inferiors.h (thread_to_gdb_id): Remove.
6517 * inferiors.c (thread_to_gdb_id): Remove.
6518 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6519 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6520 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6522 * nto-low.c (nto_fetch_registers, nto_store_registers,
6523 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6525 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6527 * inferiors.h (gdb_id_to_thread_id): Remove.
6528 * inferiors.c (gdb_id_to_thread_id): Remove.
6529 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6530 removal. Move pid declaration closer to where it's used.
6532 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6534 * server.c (handle_detach): New function.
6535 (process_serial_event): Move code out, call handle_detach.
6537 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6539 * server.c (require_running): Rename to ...
6540 (require_running_or_return): ... this ...
6541 (require_running_or_break): ... and this.
6542 (handle_query, process_serial_event): Adjust.
6544 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6546 * linux-low.c (linux_set_resume_request): Remove unused
6549 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6551 * server.c (first_thread_of): Remove.
6552 (process_serial_event): Replace usage of first_thread_of with
6553 find_any_thread_of_pid.
6554 * tracepoint.c (same_process_p): Remove.
6555 (gdb_agent_about_to_close): Replace usage of same_process_p with
6556 find_any_thread_of_pid.
6557 * linux-x86-low.c (same_process_callback): Remove.
6558 (x86_arch_setup_process_callback): Replace usage of
6559 same_process_callback with find_any_thread_of_pid.
6560 * thread-db.c (any_thread_of): Remove.
6561 (switch_to_process): Replace usage of any_thread_of with
6562 find_any_thread_of_pid.
6563 * inferiors.c (thread_pid_matches_callback): Remove.
6564 (find_thread_process): Adjust to use find_any_thread_of_pid.
6566 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6568 * regcache.c (get_thread_regcache): Guard calls to "memset"
6571 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6573 * linux-low.c (handle_extended_wait): Use
6574 "allocate_target_description" instead of "XNEW".
6575 * linux-x86-low.c (initialize_low_arch): Likewise.
6577 2017-09-05 Yao Qi <yao.qi@linaro.org>
6579 * configure.srv (srv_i386_regobj): Remove.
6580 (srv_amd64_regobj): Remove.
6581 (srv_regobj): Set it to "" for x86 non-linux targets.
6582 * linux-x86-tdesc.c (i386_linux_read_description):
6583 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6584 (init_registers_i386): Remove the declaration.
6585 (tdesc_i386): Remove the declaration.
6586 (lynx_i386_arch_setup): Call i386_create_target_description.
6587 * nto-x86-low.c: Likewise.
6588 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6589 [!__x86_64__]: include arch/i386.h.
6590 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6592 2017-09-05 Yao Qi <yao.qi@linaro.org>
6594 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6595 i386/amd64-XXX-linux from it.
6597 2017-09-05 Yao Qi <yao.qi@linaro.org>
6599 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6601 (ipa_amd64_linux_regobj): Remove.
6602 (ipa_x32_linux_regobj): Remove.
6604 2017-09-05 Yao Qi <yao.qi@linaro.org>
6606 * Makefile.in (arch-amd64.o): New rule.
6607 * configure.srv: Append arch-amd64.o.
6608 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6609 (get_ipa_tdesc): Call amd64_linux_read_description.
6610 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6611 and init_registers_amd64_XXX.
6612 * linux-x86-low.c (x86_linux_read_description): Call
6613 amd64_linux_read_description.
6614 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6615 (initialize_low_arch): Don't call init_registers_x32_XXX and
6616 init_registers_amd64_XXX.
6617 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6618 and tdesc_amd64_XXX.
6619 [__x86_64__] (amd64_tdesc_test): New function.
6620 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6621 and init_registers_amd64_XXX.
6622 * linux-x86-tdesc.c: Include arch/amd64.h.
6623 (xcr0_to_tdesc_idx): New function.
6624 (i386_linux_read_description): New function.
6625 (amd64_get_ipa_tdesc_idx): New function.
6626 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6627 (amd64_get_ipa_tdesc): Declare.
6629 2017-09-05 Yao Qi <yao.qi@linaro.org>
6631 * configure.srv (srv_i386_linux_xmlfiles): Remove
6632 i386/i386-XXX-linux.xml from it.
6634 2017-09-05 Yao Qi <yao.qi@linaro.org>
6636 * configure.srv: Set srv_i386_linux_regobj empty if $development
6638 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6639 initialize_low_tdesc.
6640 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6641 with #if initialize_low_tdesc.
6642 * linux-x86-tdesc-selftest.c: New file.
6643 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6645 2017-09-05 Yao Qi <yao.qi@linaro.org>
6647 * Makefile.in (arch-i386.o): New rule.
6648 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6649 (x86_64-*-linux*): Likewise.
6650 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6651 include arch/i386.h.
6652 (i386_linux_read_description): Remove code and call
6653 i386_create_target_description.
6654 * tdesc.c (allocate_target_description): New function.
6655 * tdesc.h (set_tdesc_architecture): Remove declaration.
6656 (set_tdesc_osabi): Likewise.
6658 2017-09-05 Yao Qi <yao.qi@linaro.org>
6660 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6661 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6662 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6664 * server.c (get_features_xml): Call tdesc_get_features_xml.
6665 * tdesc.c (set_tdesc_architecture): New function.
6666 (set_tdesc_osabi): New function.
6667 (tdesc_get_features_xml): New function.
6668 (tdesc_create_feature): Add an argument.
6669 * tdesc.h (struct target_desc) <features>: New field.
6670 <arch, osabi>: New field.
6671 (~target_desc): xfree features, arch, and osabi.
6672 (target_desc::oerator==): Don't compare .xmltarget.
6673 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6674 (set_tdesc_osabi): Likewise.
6675 (tdesc_get_features_xml): Likewise.
6677 2017-09-05 Yao Qi <yao.qi@linaro.org>
6679 * linux-x86-tdesc.c: Include selftest.h.
6680 (i386_tdesc_test): New function.
6681 (initialize_low_tdesc): Call selftests::register_test.
6682 * tdesc.h: Include regdef.h.
6683 (target_desc): Override operator == and !=.
6685 2017-09-05 Yao Qi <yao.qi@linaro.org>
6687 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6688 (ipa_obj): Likewise.
6689 * linux-i386-ipa.c: Include common/x86-xstate.h
6690 (get_ipa_tdesc): Call i386_linux_read_description.
6691 (initialize_low_tracepoint): Don't call init_registers_XXX
6692 functions, call initialize_low_tdesc instead.
6693 * linux-x86-low.c (x86_linux_read_description): Call
6694 i386_linux_read_description.
6695 (initialize_low_arch): Don't call init_registers_i386_XXX
6696 functions, call initialize_low_tdesc.
6697 * linux-x86-tdesc.c: New file.
6698 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6699 (i386_get_ipa_tdesc_idx): Declare.
6700 (i386_get_ipa_tdesc): Declare.
6701 (initialize_low_tdesc): Declare.
6703 2017-09-05 Yao Qi <yao.qi@linaro.org>
6705 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6708 2017-09-05 Yao Qi <yao.qi@linaro.org>
6710 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6711 * regcache.c (get_thread_regcache): Use VEC_length.
6712 (init_register_cache): Likewise.
6713 (regcache_cpy): Likewise.
6714 (registers_to_string): Iterate reg_defs via VEC_iterate.
6715 (find_regno): Likewise.
6716 (find_register_by_number): Use VEC_index.
6717 (register_size): Call find_register_by_number.
6718 (register_data): Call find_register_by_number.
6719 (supply_regblock): Use VEC_length.
6720 (regcache_raw_read_unsigned): Likewise.
6721 * tdesc.c (init_target_desc): Iterate reg_defs via
6723 (default_description): Update initializer.
6724 (copy_target_description): Don't update field num_registers.
6725 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6726 <num_registers>: Remove.
6728 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6730 * Makefile.in (.SECONDARY): Define target.
6732 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6734 * linux-low.c (linux_wait_1): Adjust.
6735 * server.c (queue_stop_reply_callback): Adjust.
6737 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6739 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6740 QEnvironmentUnset and QEnvironmentReset packets.
6741 (handle_query): Inform remote that QEnvironmentHexEncoded,
6742 QEnvironmentUnset and QEnvironmentReset are supported.
6744 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6746 * inferiors.h (inferior_target_data): Rename to ...
6747 (thread_target_data): ... this.
6748 (inferior_regcache_data): Rename to ...
6749 (thread_regcache_data): ... this.
6750 (set_inferior_regcache_data): Rename to ...
6751 (set_thread_regcache_data): ... this.
6752 * inferiors.c (inferior_target_data): Rename to ...
6753 (thread_target_data): ... this.
6754 (inferior_regcache_data): Rename to ...
6755 (thread_regcache_data): ... this.
6756 (set_inferior_regcache_data): Rename to ...
6757 (set_thread_regcache_data): ... this.
6758 (free_one_thread): Update.
6759 * linux-low.h (get_thread_lwp): Update.
6760 * regcache.c (get_thread_regcache): Update.
6761 (regcache_invalidate_thread): Update.
6762 (free_register_cache_thread): Update.
6763 * win32-i386-low.c (update_debug_registers_callback): Update.
6764 (win32_get_current_dr): Update.
6765 * win32-low.c (thread_rec): Update.
6766 (delete_thread_info): Update.
6767 (continue_one_thread): Update.
6768 (suspend_one_thread): Update.
6770 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6772 * inferiors.c (set_inferior_target_data): Remove.
6773 * inferiors.h (set_inferior_target_data): Remove.
6775 2017-08-18 Yao Qi <yao.qi@linaro.org>
6777 * Makefile.in (OBS): Add selftest.o.
6778 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6779 * configure, config.in: Re-generated.
6780 * server.c: Include common/sefltest.h.
6781 (captured_main): Handle option --selftest.
6783 2017-08-09 Yao Qi <yao.qi@linaro.org>
6785 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6786 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6787 i386-avx-mpx.o and i386-mmx.o.
6788 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6789 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6790 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6791 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6792 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6793 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6794 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6795 i386/amd64-avx-mpx.xml.
6797 2017-08-09 Yao Qi <yao.qi@linaro.org>
6799 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6800 and x32-avx-avx512.o.
6801 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6802 i386/x32-avx-avx512.xml.
6804 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6806 * tracepoint.h (enum class fast_tpoint_collect_result): New
6808 (fast_tracepoint_collecting): Change return type to
6809 fast_tpoint_collect_result.
6810 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6811 * linux-low.h: Include tracepoint.h.
6812 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6813 fast_tpoint_collect_result.
6814 * linux-low.c (handle_tracepoints): Adjust.
6815 (linux_fast_tracepoint_collecting): Change return type to
6816 fast_tpoint_collect_result.
6817 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6818 linux_wait_1, stuck_in_jump_pad_callback,
6819 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6820 proceed_one_lwp): Adjust to type change.
6822 2017-07-10 Yao Qi <yao.qi@linaro.org>
6824 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6826 2017-06-29 Yao Qi <yao.qi@linaro.org>
6828 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6830 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6832 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6834 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6836 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6838 * linux-low.c (linux_create_inferior): Adjust code to access the
6839 environment information via 'gdb_environ' class.
6840 * lynx-low.c (lynx_create_inferior): Likewise.
6841 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6842 (get_environ): Return a pointer to 'our_environ'.
6843 (captured_main): Initialize 'our_environ'.
6844 * server.h (get_environ): Adjust prototype.
6845 * spu-low.c (spu_create_inferior): Adjust code to access the
6846 environment information via 'gdb_environ' class.
6848 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6850 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6851 usage of "register" keyword.
6853 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6855 * configure: Re-generate.
6857 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6859 * configure: Re-generate.
6861 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6863 * Makefile.in (COMPILE.pre): Add "-x c++".
6865 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6867 * fork-child.c: Conditionally include <signal.h>.
6869 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6871 * server.c (handle_general_set): Handle new packet
6872 "QStartupWithShell".
6873 (handle_query): Add "QStartupWithShell" to the list of supported
6875 (gdbserver_usage): Add help text explaining the
6876 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6878 (captured_main): Recognize and act upon the presence of the new
6881 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6882 Pedro Alves <palves@redhat.com>
6884 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6885 * configure: Regenerate.
6886 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6888 (i[34567]86-*-lynxos*): Likewise.
6889 (spu*-*-*): Likewise.
6890 * fork-child.c: New file.
6891 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6893 (linux_ptrace_fun): New function.
6894 (linux_create_inferior): Adjust function prototype to reflect
6895 change on "target.h". Adjust function code to use
6897 (linux_request_interrupt): Delete "signal_pid".
6898 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6899 (lynx_ptrace_fun): New function.
6900 (lynx_create_inferior): Adjust function prototype to reflect
6901 change on "target.h". Adjust function code to use
6903 * nto-low.c (nto_create_inferior): Adjust function prototype and
6904 code to reflect change on "target.h". Update comments.
6905 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6906 "common-terminal.h" and "environ.h".
6907 (terminal_fd): Moved to fork-child.c.
6908 (old_foreground_pgrp): Likewise.
6909 (restore_old_foreground_pgrp): Likewise.
6910 (last_status): Make it global.
6911 (last_ptid): Likewise.
6912 (our_environ): New variable.
6913 (startup_with_shell): Likewise.
6914 (program_name): Likewise.
6915 (program_argv): Rename to...
6916 (program_args): ...this.
6917 (wrapper_argv): New variable.
6918 (start_inferior): Delete function.
6919 (get_exec_wrapper): New function.
6920 (get_exec_file): Likewise.
6921 (get_environ): Likewise.
6922 (prefork_hook): Likewise.
6923 (post_fork_inferior): Likewise.
6924 (postfork_hook): Likewise.
6925 (postfork_child_hook): Likewise.
6926 (handle_v_run): Update code to deal with arguments coming from the
6927 remote host. Update calls from "start_inferior" to
6929 (captured_main): Likewise. Initialize environment variable. Call
6931 * server.h (post_fork_inferior): New prototype.
6932 (get_environ): Likewise.
6933 (last_status): Declare.
6934 (last_ptid): Likewise.
6935 (signal_pid): Likewise.
6936 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6937 (spu_ptrace_fun): New function.
6938 (spu_create_inferior): Adjust function prototype to reflect change
6939 on "target.h". Adjust function code to use "fork_inferior".
6940 * target.c (target_terminal_init): New function.
6941 (target_terminal_inferior): Likewise.
6942 (target_terminal_ours): Likewise.
6943 * target.h: Include <vector>.
6944 (struct target_ops) <create_inferior>: Update prototype.
6945 (create_inferior): Update macro.
6946 * utils.c (gdb_flush_out_err): New function.
6947 * win32-low.c (win32_create_inferior): Adjust function prototype
6948 and code to reflect change on "target.h".
6950 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6952 * inferiors.c (switch_to_thread): New function.
6954 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6956 * Makefile.in (SFILE): Add "common/job-control.c".
6957 (OBS): Add "job-control.o".
6959 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6961 * Makefile: Remove "@host_makefile_frag@".
6963 2017-05-05 Pedro Alves <palves@redhat.com>
6965 * configure: Regenerate.
6967 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6969 * configure: Regenerate.
6971 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6973 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
6974 software_single_step change of return type to
6975 std::vector<CORE_ADDR>.
6976 * linux-low.c (install_software_single_step_breakpoints):
6978 * linux-low.h (install_software_single_step_breakpoints):
6981 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6983 * remote-utils.c: Include "gdb_termios.h" instead of
6985 * terminal.h: Delete file.
6987 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6989 * server.c: Include <vector>.
6990 <program_argv, wrapper_argv>: Convert to std::vector.
6991 (start_inferior): Rewrite function to use C++.
6992 (handle_v_run): Likewise. Update code that calculates the argv
6993 based on the vRun packet; use C++.
6994 (captured_main): Likewise.
6996 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
6998 * server.c (handle_v_cont): Initialize thread_resume::thread
7001 2017-04-05 Pedro Alves <palves@redhat.com>
7003 * configure: Regenerate.
7005 2017-04-05 Pedro Alves <palves@redhat.com>
7007 * gdbreplay.c (sync_error): Constify.
7008 * linux-x86-low.c (push_opcode): Constify.
7010 2017-04-05 Pedro Alves <palves@redhat.com>
7012 * win32-low.c (get_child_debug_event)
7013 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7014 Report TARGET_WAITKIND_SPURIOUS instead.
7016 2017-04-05 Pedro Alves <palves@redhat.com>
7018 * remote-utils.c (remote_prepare, remote_open): Constify.
7019 * remote-utils.h (remote_prepare, remote_open): Constify.
7020 * server.c (captured_main): Constify 'port' handling.
7022 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7024 * Makefile.in (clean): Clear .deps.
7026 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7028 * .gitignore: Remove generated files, replace with wildcard.
7029 * (clean): Replace removal of generated files with wildcard.
7030 (version.c): Replace with...
7031 (version-generated.c): ...this.
7032 (xml-builtin.c): Replace with...
7033 (xml-builtin-generated.c): ...this.
7034 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7035 (%.c: *regformats*): Replace with...
7036 (%-generated.c: *regformats*): ...this.
7038 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7040 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7041 (xtensa_fill_gregset): Call collect_register_by_name for
7043 (xtensa_store_gregset): Call supply_register_by_name for
7046 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7048 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7049 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7050 (xtensa_store_gregset): Call supply_register for all registers in
7051 a0_regnum..a0_regnum + C0_NREGS range.
7053 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7055 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7056 (ax-ipa.o: ax.c): Remove.
7057 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7058 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7059 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7060 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7061 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7063 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7065 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7066 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7067 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7068 (errors-ipa.o: ../common/errors.c): Remove.
7069 (format-ipa.o: ../common/format.c): Remove.
7070 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7072 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7074 * Makefile.in (%-ipa.o: %.c): New rule.
7075 (tracepoint-ipa.o: tracepoint.c): Remove.
7076 (utils-ipa.o: utils.c): Remove.
7077 (remote-utils-ipa.o: remote-utils.c): Remove.
7078 (regcache-ipa.o: regcache.c): Remove.
7079 (i386-linux-ipa.o: i386-linux.c): Remove.
7080 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7081 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7082 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7083 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7084 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7085 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7086 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7087 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7088 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7089 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7090 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7091 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7092 (aarch64-ipa.o: aarch64.c): Remove.
7093 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7094 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7095 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7096 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7097 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7098 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7099 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7100 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7101 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7102 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7103 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7104 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7105 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7106 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7107 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7108 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7109 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7110 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7111 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7112 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7113 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7114 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7115 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7116 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7117 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7118 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7119 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7120 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7121 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7122 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7123 (tdesc-ipa.o: tdesc.c): Remove.
7124 (x32-linux-ipa.o: x32-linux.c): Remove.
7125 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7126 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7128 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7130 * Makefile.in (%.o: ../arch/%.c): New rule.
7131 (arm.o: ../arch/arm.c): Remove.
7132 (arm-linux.o: ../arch/arm-linux.c): Remove.
7133 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7134 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7136 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7138 * Makefile.in (%.o: ../nat/%.c): New rule.
7139 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7140 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7141 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7142 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7143 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7144 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7145 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7146 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7147 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7148 (linux-personality.o: ../nat/linux-personality.c): Remove.
7149 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7150 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7151 (x86-linux.o: ../nat/x86-linux.c): Remove.
7152 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7153 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7155 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7157 * Makefile.in (%.o: ../common/%.c): New rule.
7158 (signals.o: ../common/signals.c): Remove.
7159 (print-utils.o: ../common/print-utils.c): Remove.
7160 (rsp-low.o: ../common/rsp-low.c): Remove.
7161 (common-utils.o: ../common/common-utils.c): Remove.
7162 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7163 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7164 (vec.o: ../common/vec.c): Remove.
7165 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7166 (xml-utils.o: ../common/xml-utils.c): Remove.
7167 (ptid.o: ../common/ptid.c): Remove.
7168 (buffer.o: ../common/buffer.c): Remove.
7169 (format.o: ../common/format.c): Remove.
7170 (filestuff.o: ../common/filestuff.c): Remove.
7171 (agent.o: ../common/agent.c): Remove.
7172 (errors.o: ../common/errors.c): Remove.
7173 (environ.o: ../common/environ.c): Remove.
7174 (common-debug.o: ../common/common-debug.c): Remove.
7175 (cleanups.o: ../common/cleanups.c): Remove.
7176 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7177 (fileio.o: ../common/fileio.c): Remove.
7178 (common-regcache.o: ../common/common-regcache.c): Remove.
7179 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7180 (new-op.o: ../common/new-op.c): Remove.
7181 (btrace-common.o: ../common/btrace-common.c): Remove.
7183 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7185 * Makefile.in (%.o: ../target/%.c): New rule.
7186 (waitstatus.o: ../target/waitstatus.c): Remove.
7188 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7191 (%.c: ../regformats/%.dat,
7192 (%.c: ../regformats/arm/%.dat,
7193 (%.c: ../regformats/i386/%.dat,
7194 (%.c: ../regformats/rs6000/%.dat): New rules.
7195 (aarch64.c): Remove.
7196 (reg-arm.c): Remove.
7197 (arm-with-iwmmxt.c): Remove.
7198 (arm-with-vfpv2.c): Remove.
7199 (arm-with-vfpv3.c): Remove.
7200 (arm-with-neon.c): Remove.
7201 (reg-bfin.c): Remove.
7202 (reg-cris.c): Remove.
7203 (reg-crisv32.c): Remove.
7205 (i386-linux.c): Remove.
7206 (i386-avx.c): Remove.
7207 (i386-avx-linux.c): Remove.
7208 (i386-avx-avx512.c): Remove.
7209 (i386-avx-avx512-linux.c): Remove.
7210 (i386-mpx.c): Remove.
7211 (i386-mpx-linux.c): Remove.
7212 (i386-avx-mpx-avx512-pku.c): Remove.
7213 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7214 (i386-avx-mpx.c): Remove.
7215 (i386-avx-mpx-linux.c): Remove.
7216 (i386-mmx.c): Remove.
7217 (i386-mmx-linux.c): Remove.
7218 (reg-ia64.c): Remove.
7219 (reg-m32r.c): Remove.
7220 (reg-m68k.c): Remove.
7222 (mips-linux.c): Remove.
7223 (mips-dsp-linux.c): Remove.
7224 (mips64-linux.c): Remove.
7225 (mips64-dsp-linux.c): Remove.
7226 (nios2-linux.c): Remove.
7227 (powerpc-32.c): Remove.
7228 (powerpc-32l.c): Remove.
7229 (powerpc-altivec32l.c): Remove.
7230 (powerpc-cell32l.c): Remove.
7231 (powerpc-vsx32l.c): Remove.
7232 (powerpc-isa205-32l.c): Remove.
7233 (powerpc-isa205-altivec32l.c): Remove.
7234 (powerpc-isa205-vsx32l.c): Remove.
7235 (powerpc-e500l.c): Remove.
7236 (powerpc-64l.c): Remove.
7237 (powerpc-altivec64l.c): Remove.
7238 (powerpc-cell64l.c): Remove.
7239 (powerpc-vsx64l.c): Remove.
7240 (powerpc-isa205-64l.c): Remove.
7241 (powerpc-isa205-altivec64l.c): Remove.
7242 (powerpc-isa205-vsx64l.c): Remove.
7243 (s390-linux32.c): Remove.
7244 (s390-linux32v1.c): Remove.
7245 (s390-linux32v2.c): Remove.
7246 (s390-linux64.c): Remove.
7247 (s390-linux64v1.c): Remove.
7248 (s390-linux64v2.c): Remove.
7249 (s390-te-linux64.c): Remove.
7250 (s390-vx-linux64.c): Remove.
7251 (s390-tevx-linux64.c): Remove.
7252 (s390x-linux64.c): Remove.
7253 (s390x-linux64v1.c): Remove.
7254 (s390x-linux64v2.c): Remove.
7255 (s390x-te-linux64.c): Remove.
7256 (s390x-vx-linux64.c): Remove.
7257 (s390x-tevx-linux64.c): Remove.
7258 (tic6x-c64xp-linux.c): Remove.
7259 (tic6x-c64x-linux.c): Remove.
7260 (tic6x-c62x-linux.c): Remove.
7262 (reg-sparc64.c): Remove.
7263 (reg-spu.c): Remove.
7265 (amd64-linux.c): Remove.
7266 (amd64-avx.c): Remove.
7267 (amd64-avx-linux.c): Remove.
7268 (amd64-avx-avx512.c): Remove.
7269 (amd64-avx-avx512-linux.c): Remove.
7270 (amd64-mpx.c): Remove.
7271 (amd64-mpx-linux.c): Remove.
7272 (amd64-avx-mpx-avx512-pku.c): Remove.
7273 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7274 (amd64-avx-mpx.c): Remove.
7275 (amd64-avx-mpx-linux.c): Remove.
7277 (x32-linux.c): Remove.
7278 (x32-avx.c): Remove.
7279 (x32-avx-linux.c): Remove.
7280 (x32-avx-avx512.c): Remove.
7281 (x32-avx-avx512-linux.c): Remove.
7282 (reg-xtensa.c): Remove.
7283 (reg-tilegx.c): Remove.
7284 (reg-tilegx32.c): Remove.
7286 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7288 * Makefile.in (SFILES): Add "common/environ.c".
7289 (OBJS): Add "common/environ.h".
7291 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7293 * configure.ac: Check if the fs_base and gs_base members of
7294 `struct user_regs_struct' exist.
7295 * config.in: Regenerated.
7296 * configure: Likewise.
7298 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7300 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7302 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7303 (get_next_pcs_syscall_next_pc): Likewise.
7305 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7307 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7308 * nto-x86-low.c: Likewise.
7310 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7312 * Makefile.in: Include disable-implicit-rules.mk.
7314 2016-11-23 Pedro Alves <palves@redhat.com>
7316 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7317 (debug_vprintf): Use std::chrono::steady_clock instead of
7318 gettimeofday. Use '.' instead of ':'.
7319 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7320 (get_timestamp): Use std::chrono::steady_clock instead of
7323 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7325 * Makefile.in: Fix whitespace formatting.
7327 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7329 * Makefile.in (SFILES, OBS): Flatten list and order
7332 2016-11-23 Pedro Alves <palves@redhat.com>
7334 * event-loop.c (handle_file_event): Use warning.
7335 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7336 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7339 2016-11-23 Pedro Alves <palves@redhat.com>
7341 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7343 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7344 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7345 debug_printf and debug_flush for debug output.
7346 * server.c (handle_general_set): Likewise.
7347 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7350 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7352 * Makefile.in (.c.o): Replace rule with ...
7353 (%.o: %.c): ... this one.
7355 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7357 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7358 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7360 * configure.ac: Remove checks for the make program.
7361 * configure: Re-generate.
7363 2016-10-28 Pedro Alves <palves@redhat.com>
7365 * Makefile.in (CXX_DIALECT): Get from configure.
7366 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7367 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7368 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7369 * config.in: Regenerate.
7370 * configure: Regenerate.
7372 2016-10-27 Yao Qi <yao.qi@linaro.org>
7374 * linux-low.c (linux_supports_range_stepping): Return true if
7375 can_software_single_step return true.
7377 2016-10-27 Yao Qi <yao.qi@linaro.org>
7379 * inferiors.c (find_inferior_in_random): New function.
7380 * inferiors.h (find_inferior_in_random): Declare.
7381 * linux-low.c (linux_wait_for_event_filtered): Call
7382 find_inferior_in_random instead of find_inferior.
7384 2016-10-27 Yao Qi <yao.qi@linaro.org>
7386 * linux-low.c (linux_wait_1): If single-step breakpoints are
7387 inserted, remove them.
7389 2016-10-26 Pedro Alves <palves@redhat.com>
7391 * linux-low.c (handle_extended_wait): Link parent/child fork
7393 (linux_wait_1): Unlink them.
7394 (linux_set_resume_request): Ignore resume requests for
7395 already-resumed and unhandled fork child threads.
7396 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7397 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7399 (handle_v_requests) <vCont>: Don't call require_running.
7400 * server.h (in_queued_stop_replies): New declaration.
7402 2016-10-24 Yao Qi <yao.qi@linaro.org>
7405 * linux-aarch64-low.c (append_insns): Cast the return value to
7408 2016-10-10 Yao Qi <yao.qi@linaro.org>
7410 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7412 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7414 * target.c (target_supports_multi_process): New function, moved
7416 * target.h (target_supports_multi_process): ... here. Remove
7419 2016-10-05 Tom Tromey <tom@tromey.com>
7422 * tracepoint.c (handle_tracepoint_bkpts): Check
7423 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7425 2016-10-05 Yao Qi <yao.qi@linaro.org>
7427 * configure.srv: Update the path of arm-*.xml files.
7429 2016-10-05 Terry Guo <terry.guo@arm.com>
7430 Yao Qi <yao.qi@linaro.org>
7432 * Makefile.in: Adjust the path of rules.
7433 * configure.srv: Update the path of xml files.
7434 * regformats/arm-with-iwmmxt.dat: Regenerated.
7435 * regformats/arm-with-neon.dat: Likewise.
7436 * regformats/arm-with-vfpv2.dat: Likewise.
7437 * regformats/arm-with-vfpv3.dat Likewise.
7439 2016-09-30 Yao Qi <yao.qi@linaro.org>
7442 * target.c (target_stop_and_wait): Don't call
7443 target_continue_no_signal, use resume_stop instead.
7445 2016-09-26 Yao Qi <yao.qi@linaro.org>
7447 * linux-low.c (linux_wait_1): Call debug_exit.
7449 2016-09-23 Pedro Alves <palves@redhat.com>
7451 * Makefile.in (SFILES): Add common/new-op.c.
7452 (OBS): Add common/new-op.o.
7453 (new-op.o): New rule.
7455 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7457 * .gitinore: Ignore more files.
7459 2016-09-21 Yao Qi <yao.qi@linaro.org>
7461 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7464 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7466 * server.c (start_inferior): Call target_mourn_inferior instead of
7467 mourn_inferior; pass ptid_t argument to it.
7469 (handle_target_event): Likewise.
7470 * target.c (target_mourn_inferior): New function.
7471 * target.h (mourn_inferior): Delete macro.
7473 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7475 * linux-low.c (lwp_is_stepping): New function.
7477 2016-09-06 Carl Love <cel@us.ibm.com>
7479 * server.c (start_inferior): Fixed comment, requested comment change
7480 didn't get updated correctly. Removed reference to ptrace () call as
7481 it is only true on Linux systems.
7483 2016-09-06 Carl Love <cel@us.ibm.com>
7485 * server.c (start_inferior): Do not call
7486 function target_post_create_inferior () if the
7487 inferior process has already exited.
7489 2016-09-05 Pedro Alves <palves@redhat.com>
7491 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7492 (COMPILE.pre, CC_LD): Use CXX directly.
7493 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7494 * acinclude.m4: Don't include build-with-cxx.m4.
7495 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7496 * configure: Regenerate.
7498 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7501 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7502 call writing data to own_buf.
7504 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7506 * target.c (mywait): Call target_wait instead of
7508 (target_wait): New function.
7510 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7512 * server.c (start_inferior): New variable 'ptid'. Replace calls
7513 to the_target->resume by target_continue{,_no_signal}, depending
7515 * target.c (target_stop_and_wait): Call target_continue_no_signal
7516 instead of the_target->resume.
7517 (target_continue): New function.
7519 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7521 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7523 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7526 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7528 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7529 * linux-arm-low.c (ps_get_thread_area): Likewise.
7530 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7531 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7532 * linux-mips-low.c (ps_get_thread_area): Likewise.
7533 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7534 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7535 * linux-x86-low.c (ps_get_thread_area): Likewise.
7536 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7538 2016-08-19 Pedro Alves <palves@redhat.com>
7540 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7542 2016-08-19 Pedro Alves <palves@redhat.com>
7544 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7545 comment. Use memcpy instead of casting through unsigned long.
7547 2016-08-19 Pedro Alves <palves@redhat.com>
7549 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7550 allocating around 0x80000000.
7552 2016-08-19 Pedro Alves <palves@redhat.com>
7555 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7556 (x32-avx512-linux-ipa.o): New rules.
7557 * configure.ac (x86_64-*-linux*): New x32 check.
7558 * configure.srv (ipa_x32_linux_regobj): New.
7559 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7560 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7562 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7564 * configure: Regenerate.
7566 2016-08-09 Pedro Alves <palves@redhat.com>
7569 * Makefile.in (OBS): Add signals-state-save-restore.o.
7570 (signals-state-save-restore.o): New rule.
7571 * config.in: Regenerate.
7572 * configure: Regenerate.
7573 * linux-low.c: Include "signals-state-save-restore.h".
7574 (linux_create_inferior): Call
7575 restore_original_signals_state.
7576 * server.c: Include "dispositions-save-restore.h".
7577 (captured_main): Call save_original_signals_state.
7579 2016-08-05 Pedro Alves <palves@redhat.com>
7581 * configure: Regenerate.
7583 2016-08-04 Yao Qi <yao.qi@linaro.org>
7585 * linux-low.c (regsets_fetch_inferior_registers): Check
7586 errno is ESRCH or not.
7588 2016-08-02 Yao Qi <yao.qi@linaro.org>
7590 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7591 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7592 (thread_db_load_search): Update.
7593 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7594 td_ta_set_event and td_ta_event_getmsg.
7596 2016-07-26 Pedro Alves <palves@redhat.com>
7599 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7600 of unsigned long for 64-bit registers and use uint32_t instead of
7601 unsigned int for 32-bit registers.
7603 2016-07-26 Pedro Alves <palves@redhat.com>
7605 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7608 2016-07-21 Tom Tromey <tom@tromey.com>
7610 * configure: Rebuild.
7612 2016-07-21 Yao Qi <yao.qi@linaro.org>
7614 * mem-break.c (find_gdb_breakpoint): Cast bp to
7615 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7617 2016-07-21 Yao Qi <yao.qi@linaro.org>
7619 * server.c (handle_v_requests): Support s and S actions
7620 if target_supports_software_single_step return true.
7622 2016-07-21 Yao Qi <yao.qi@linaro.org>
7624 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7625 is resume_step, call maybe_hw_step.
7626 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7628 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7630 (proceed_one_lwp): If resume request is resume_step, install
7631 reinsert breakpoints and call maybe_hw_step.
7633 2016-07-21 Yao Qi <yao.qi@linaro.org>
7635 * linux-low.c (proceed_one_lwp): Declare.
7636 (linux_resume_one_thread): Remove local variable 'step'.
7637 Lift code enqueue signal. Call proceed_one_lwp instead of
7638 linux_resume_one_lwp.
7640 2016-07-21 Yao Qi <yao.qi@linaro.org>
7642 * linux-low.c (linux_resume_one_thread): Call
7643 enqueue_pending_signal.
7645 2016-07-21 Yao Qi <yao.qi@linaro.org>
7647 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7648 * inferiors.c (do_restore_current_thread_cleanup): New function.
7649 (make_cleanup_restore_current_thread): Likewise.
7650 * linux-low.c (install_software_single_step_breakpoints): Call
7651 make_cleanup_restore_current_thread. Switch current_thread to
7654 2016-07-21 Yao Qi <yao.qi@linaro.org>
7656 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7657 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7658 (clone_one_breakpoint): Likewise.
7659 (delete_reinsert_breakpoints): Change parameter to thread.
7661 (has_reinsert_breakpoints): Likewise.
7662 (uninsert_reinsert_breakpoints): Likewise.
7663 (reinsert_reinsert_breakpoints): Likewise.
7664 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7665 (delete_reinsert_breakpoints): Likewise.
7666 (reinsert_reinsert_breakpoints): Likewise.
7667 (uninsert_reinsert_breakpoints): Likewise.
7668 (has_reinsert_breakpoints): Likewise.
7670 2016-07-21 Yao Qi <yao.qi@linaro.org>
7672 * inferiors.c (get_thread_process): Make parameter const.
7673 * inferiors.h (get_thread_process): Update declaration.
7674 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7675 Add new parameters child_thread and parent_thread. Callers
7677 * mem-break.h (clone_all_breakpoints): Update declaration.
7679 2016-07-21 Yao Qi <yao.qi@linaro.org>
7681 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7682 <command_list, handler>: Remove.
7683 (struct gdb_breakpoint): New.
7684 (struct other_breakpoint): New.
7685 (struct reinsert_breakpoint): New.
7686 (is_gdb_breakpoint): New function.
7687 (any_persistent_commands): Update command_list if
7688 is_gdb_breakpoint returns true.
7689 (set_breakpoint): Create breakpoints according to their types.
7690 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7691 (set_gdb_breakpoint_1): Likewise.
7692 (set_gdb_breakpoint): Likewise.
7693 (clear_breakpoint_conditions): Change parameter type to
7694 'struct gdb_breakpoint *'.
7695 (clear_breakpoint_commands): Likewise.
7696 (clear_breakpoint_conditions_and_commands): Likewise.
7697 (add_condition_to_breakpoint): Likewise.
7698 (add_breakpoint_condition): Likewise.
7699 (add_commands_to_breakpoint): Likewise.
7700 (check_breakpoints): Check other_breakpoint.
7701 (clone_one_breakpoint): Clone breakpopint according to its type.
7702 * mem-break.h (struct gdb_breakpoint): Declare.
7703 (set_gdb_breakpoint): Update declaration.
7704 (clear_breakpoint_conditions_and_commands): Likewise.
7705 (add_breakpoint_condition): Likewise.
7706 (add_breakpoint_commands): Likewise.
7707 * server.c (process_point_options): Change parameter type to
7708 'struct gdb_breakpoint *'.
7710 2016-07-21 Yao Qi <yao.qi@linaro.org>
7712 * mem-break.c (set_breakpoint_at): Rename it to ...
7713 (set_breakpoint_type_at): ... it.
7714 (set_breakpoint_at): Call set_breakpoint_type_at.
7715 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7716 * mem-break.h (set_breakpoint_at): Update comments.
7718 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7720 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7722 (nios2_store_gregset): Likewise.
7724 2016-07-01 Pedro Alves <palves@redhat.com>
7725 Antoine Tremblay <antoine.tremblay@ericsson.com>
7727 * linux-low.c: Change interface to take the target lwp_info
7728 pointer directly and return void. Handle detaching from a zombie
7730 (linux_detach_lwp_callback): New function.
7731 (linux_detach): Detach from the leader thread after detaching from
7734 2016-06-28 Yao Qi <yao.qi@linaro.org>
7736 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7737 for variable new_offset.
7738 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7739 (aarch64_ftrace_insn_reloc_cb): Likewise.
7740 (aarch64_ftrace_insn_reloc_tb): Likewise.
7741 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7742 PRIx64 instead of PRIx32.
7744 2016-06-28 Yao Qi <yao.qi@linaro.org>
7746 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7747 (the_low_target): Install arm_get_syscall_trapinfo.
7749 2016-06-28 Yao Qi <yao.qi@linaro.org>
7751 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7753 (the_low_target): Install aarch64_get_syscall_trapinfo.
7755 2016-06-28 Yao Qi <yao.qi@linaro.org>
7757 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7759 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7760 Remove parameter sysno.
7761 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7764 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7766 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7767 (s390_emit_ne_goto): Likewise.
7768 (s390_emit_lt_goto): Likewise.
7769 (s390_emit_le_goto): Likewise.
7770 (s390_emit_gt_goto): Likewise.
7771 (s390_emit_ge_goto): Likewise.
7772 (s390x_emit_eq_goto): Likewise.
7773 (s390x_emit_ne_goto): Likewise.
7774 (s390x_emit_lt_goto): Likewise.
7775 (s390x_emit_le_goto): Likewise.
7776 (s390x_emit_gt_goto): Likewise.
7777 (s390x_emit_ge_goto): Likewise.
7778 (s390_emit_ops_impl): Mark variable static.
7779 (s390x_emit_ops): Likewise.
7781 2016-06-17 Yao Qi <yao.qi@linaro.org>
7783 * linux-low.c (handle_extended_wait): Call
7784 uninsert_reinsert_breakpoints for the parent process. Remove
7785 reinsert breakpoints from the child process. Reinsert them to
7786 the parent process when vfork is done.
7787 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7788 (reinsert_reinsert_breakpoints): New function.
7789 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7790 (reinsert_reinsert_breakpoints): Declare.
7792 2016-06-17 Yao Qi <yao.qi@linaro.org>
7794 * linux-low.c (handle_extended_wait): If the parent is doing
7795 step-over, remove the reinsert breakpoints from the forked child.
7797 2016-06-17 Yao Qi <yao.qi@linaro.org>
7799 * linux-low.c (unsuspend_all_lwps): Declare.
7800 (linux_low_filter_event): If thread exited, call finish_step_over.
7801 If step-over is finished, unsuspend other threads.
7803 2016-06-17 Yao Qi <yao.qi@linaro.org>
7805 * linux-low.c (linux_resume_one_lwp_throw): Assert
7806 has_reinsert_breakpoints returns false.
7807 * mem-break.c (delete_disabled_breakpoints): Assert
7808 bp type isn't reinsert_breakpoint.
7810 2016-06-17 Yao Qi <yao.qi@linaro.org>
7812 * linux-low.c (maybe_hw_step): New function.
7813 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7814 (finish_step_over): Switch current_thread to lwp temporarily,
7815 and assert has_reinsert_breakpoints returns true.
7816 (proceed_one_lwp): Call maybe_hw_step.
7817 * mem-break.c (has_reinsert_breakpoints): New function.
7818 * mem-break.h (has_reinsert_breakpoints): Declare.
7820 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7822 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7824 2016-05-17 Yao Qi <yao.qi@linaro.org>
7826 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7827 instead of find_inferior.
7829 2016-05-05 Yao Qi <yao.qi@linaro.org>
7831 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7832 Initialize res to zero.
7834 2016-05-05 Yao Qi <yao.qi@linaro.org>
7836 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7839 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7841 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7842 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7843 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7845 2016-04-28 Par Olsson <par.olsson@windriver.com>
7846 Simon Marchi <simon.marchi@ericsson.com>
7848 * tracepoint.c (write_inferior_int8): New function.
7849 (cmd_qtenable_disable): Write enable flag using
7850 write_inferior_int8.
7852 2016-04-25 Yao Qi <yao.qi@linaro.org>
7854 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7855 (need_step_over_p): Return zero if the LWP has pending signals
7856 can be delivered on software single step target.
7858 2016-04-25 Yao Qi <yao.qi@linaro.org>
7860 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7861 return instead of error.
7863 2016-04-22 Yao Qi <yao.qi@linaro.org>
7865 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7868 2016-04-22 Yao Qi <yao.qi@linaro.org>
7870 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7871 signal when stepping over breakpoint with software single
7874 2016-04-21 Pedro Alves <palves@redhat.com>
7876 * linux-s390-low.c (s390_collect_ptrace_register)
7877 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7879 (s390_check_regset): Use void * instead of gdb_byte *.
7881 2016-04-20 Pedro Alves <palves@redhat.com>
7883 * configure: Renegerate.
7885 2016-04-20 Yao Qi <yao.qi@linaro.org>
7887 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7888 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7890 (arm_store_gregset): Likewise.
7892 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7894 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7895 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7896 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7897 (amd64-avx-mpx-linux.c): New rules.
7898 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7899 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7900 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7901 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7902 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7903 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7904 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7905 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7906 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7907 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7908 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7909 * linux-x86-low.c (x86_linux_read_description): Add case for
7910 X86_XSTATE_AVX_MPX_MASK.
7911 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7912 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7913 init_registers_i386_avx_mpx_linux.
7914 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7915 (initialize_low_tracepoint): Call
7916 init_registers_i386_avx_mpx_linux.
7917 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7918 (initialize_low_tracepoint): Call
7919 init_registers_amd64_avx_mpx_linux.
7920 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7921 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7922 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
7925 2016-04-18 Pedro Alves <palves@redhat.com>
7927 * configure: Regenerate.
7929 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
7931 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
7932 (aarch64_emit_sub): Likewise.
7934 2016-04-12 Pedro Alves <palves@redhat.com>
7936 * utils.c (prepare_to_throw_exception): Delete.
7938 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
7940 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
7942 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
7944 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
7946 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
7948 * linux-aarch64-ipa.c: Add <elf.h> include.
7949 * linux-ppc-ipa.c: Add <elf.h> include.
7950 * linux-s390-ipa.c: Add <elf.h> include.
7952 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7954 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
7955 (get_raw_reg_ptr): Likewise.
7956 (get_trace_state_variable_value_ptr): Likewise.
7957 (set_trace_state_variable_value_ptr): Likewise.
7958 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
7961 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
7962 Marcin Kościelnicki <koriakin@0x04.net>
7965 * linux-ppc-low.c (emit_insns): New function.
7966 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
7967 (ppc_emit_prologue): New function.
7968 (ppc_emit_epilogue): New function.
7969 (ppc_emit_add): New function.
7970 (ppc_emit_sub): New function.
7971 (ppc_emit_mul): New function.
7972 (ppc_emit_lsh): New function.
7973 (ppc_emit_rsh_signed): New function.
7974 (ppc_emit_rsh_unsigned): New function.
7975 (ppc_emit_ext): New function.
7976 (ppc_emit_zero_ext): New function.
7977 (ppc_emit_log_not): New function.
7978 (ppc_emit_bit_and): New function.
7979 (ppc_emit_bit_or): New function.
7980 (ppc_emit_bit_xor): New function.
7981 (ppc_emit_bit_not): New function.
7982 (ppc_emit_equal): New function.
7983 (ppc_emit_less_signed): New function.
7984 (ppc_emit_less_unsigned): New function.
7985 (ppc_emit_ref): New function.
7986 (ppc_emit_const): New function.
7987 (ppc_emit_reg): New function.
7988 (ppc_emit_pop): New function.
7989 (ppc_emit_stack_flush): New function.
7990 (ppc_emit_swap): New function.
7991 (ppc_emit_stack_adjust): New function.
7992 (ppc_emit_call): New function.
7993 (ppc_emit_int_call_1): New function.
7994 (ppc_emit_void_call_2): New function.
7995 (ppc_emit_if_goto): New function.
7996 (ppc_emit_goto): New function.
7997 (ppc_emit_eq_goto): New function.
7998 (ppc_emit_ne_goto): New function.
7999 (ppc_emit_lt_goto): New function.
8000 (ppc_emit_le_goto): New function.
8001 (ppc_emit_gt_goto): New function.
8002 (ppc_emit_ge_goto): New function.
8003 (ppc_write_goto_address): New function.
8004 (ppc_emit_ops_impl): New static variable.
8005 (ppc64v1_emit_prologue): New function.
8006 (ppc64v2_emit_prologue): New function.
8007 (ppc64_emit_epilogue): New function.
8008 (ppc64_emit_add): New function.
8009 (ppc64_emit_sub): New function.
8010 (ppc64_emit_mul): New function.
8011 (ppc64_emit_lsh): New function.
8012 (ppc64_emit_rsh_signed): New function.
8013 (ppc64_emit_rsh_unsigned): New function.
8014 (ppc64_emit_ext): New function.
8015 (ppc64_emit_zero_ext): New function.
8016 (ppc64_emit_log_not): New function.
8017 (ppc64_emit_bit_and): New function.
8018 (ppc64_emit_bit_or): New function.
8019 (ppc64_emit_bit_xor): New function.
8020 (ppc64_emit_bit_not): New function.
8021 (ppc64_emit_equal): New function.
8022 (ppc64_emit_less_signed): New function.
8023 (ppc64_emit_less_unsigned): New function.
8024 (ppc64_emit_ref): New function.
8025 (ppc64_emit_const): New function.
8026 (ppc64v1_emit_reg): New function.
8027 (ppc64v2_emit_reg): New function.
8028 (ppc64_emit_pop): New function.
8029 (ppc64_emit_stack_flush): New function.
8030 (ppc64_emit_swap): New function.
8031 (ppc64v1_emit_call): New function.
8032 (ppc64v2_emit_call): New function.
8033 (ppc64v1_emit_int_call_1): New function.
8034 (ppc64v2_emit_int_call_1): New function.
8035 (ppc64v1_emit_void_call_2): New function.
8036 (ppc64v2_emit_void_call_2): New function.
8037 (ppc64_emit_if_goto): New function.
8038 (ppc64_emit_eq_goto): New function.
8039 (ppc64_emit_ne_goto): New function.
8040 (ppc64_emit_lt_goto): New function.
8041 (ppc64_emit_le_goto): New function.
8042 (ppc64_emit_gt_goto): New function.
8043 (ppc64_emit_ge_goto): New function.
8044 (ppc64v1_emit_ops_impl): New static variable.
8045 (ppc64v2_emit_ops_impl): New static variable.
8046 (ppc_emit_ops): New function.
8047 (linux_low_target): Wire in ppc_emit_ops.
8049 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8050 Marcin Kościelnicki <koriakin@0x04.net>
8053 * Makefile.in: Add powerpc-*-ipa.o
8054 * configure.srv: Add ipa_obj for powerpc*-linux.
8055 * linux-ppc-ipa.c: New file.
8056 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8058 (PPC_FIELD): New macro.
8059 (PPC_SEXT): New macro.
8060 (PPC_OP6): New macro.
8061 (PPC_BO): New macro.
8062 (PPC_LI): New macro.
8063 (PPC_BD): New macro.
8064 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8065 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8066 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8067 (ppc_get_thread_area): New function.
8068 (is_elfv2_inferior): New function.
8069 (gen_ds_form): New function.
8070 (GEN_STD): New macro.
8071 (GEN_STDU): New macro.
8072 (GEN_LD): New macro.
8073 (GEN_LDU): New macro.
8074 (gen_d_form): New function.
8075 (GEN_ADDI): New macro.
8076 (GEN_ADDIS): New macro.
8077 (GEN_LI): New macro.
8078 (GEN_LIS): New macro.
8079 (GEN_ORI): New macro.
8080 (GEN_ORIS): New macro.
8081 (GEN_LWZ): New macro.
8082 (GEN_STW): New macro.
8083 (GEN_STWU): New macro.
8084 (gen_xfx_form): New function.
8085 (GEN_MFSPR): New macro.
8086 (GEN_MTSPR): New macro.
8087 (GEN_MFCR): New macro.
8088 (GEN_MTCR): New macro.
8089 (GEN_SYNC): New macro.
8090 (GEN_LWSYNC): New macro.
8091 (gen_x_form): New function.
8092 (GEN_OR): New macro.
8093 (GEN_MR): New macro.
8094 (GEN_LWARX): New macro.
8095 (GEN_STWCX): New macro.
8096 (GEN_CMPW): New macro.
8097 (gen_md_form): New function.
8098 (GEN_RLDICL): New macro.
8099 (GEN_RLDICR): New macro.
8100 (gen_i_form): New function.
8102 (GEN_BL): New macro.
8103 (gen_b_form): New function.
8104 (GEN_BNE): New macro.
8105 (GEN_LOAD): New macro.
8106 (GEN_STORE): New macro.
8107 (gen_limm): New function.
8108 (gen_atomic_xchg): New function.
8109 (gen_call): New function.
8110 (ppc_relocate_instruction): New function.
8111 (ppc_install_fast_tracepoint_jump_pad): New function.
8112 (ppc_get_min_fast_tracepoint_insn_len): New function.
8113 (ppc_get_ipa_tdesc_idx): New function.
8114 (the_low_target): Wire in the new functions.
8115 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8117 * linux-ppc-tdesc.h: New file.
8119 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8121 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8122 (alloc_jump_pad_buffer): New function.
8123 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8124 (alloc_jump_pad_buffer): New function.
8125 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8126 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8127 (alloc_jump_pad_buffer): New function.
8128 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8129 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8130 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8131 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8133 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8135 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8136 * linux-amd64-ipa.c: Likewise.
8137 * linux-i386-ipa.c: Likewise.
8138 * linux-s390-ipa.c: Likewise.
8139 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8140 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8141 set_trace_state_variable_value_ptr.
8142 (struct ipa_sym_addresses): Likewise.
8143 (symbol_list): Likewise.
8144 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8145 accessing gdb_collect directly.
8146 (gdb_collect_ptr_type): New typedef.
8147 (get_raw_reg_ptr_type): New typedef.
8148 (get_trace_state_variable_value_ptr_type): New typedef.
8149 (set_trace_state_variable_value_ptr_type): New typedef.
8150 (gdb_collect_ptr): New global.
8151 (get_raw_reg_ptr): New global.
8152 (get_trace_state_variable_value_ptr): New global.
8153 (set_trace_state_variable_value_ptr): New global.
8154 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8155 accessing get_raw_reg directly.
8156 (get_get_tsv_func_addr): Likewise for
8157 get_trace_state_variable_value_ptr.
8158 (get_set_tsv_func_addr): Likewise for
8159 set_trace_state_variable_value_ptr.
8160 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8162 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8164 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8166 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8168 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8170 (relocate_instruction): Remove own_buf.
8171 * server.c (own_buf): Make global.
8172 (handle_v_requests): Make global.
8173 * server.h (own_buf): New declaration.
8174 (handle_v_requests): New prototype.
8176 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8179 * linux-s390-low.c (add_insns): New function.
8180 (s390_emit_prologue): New function.
8181 (s390_emit_epilogue): New function.
8182 (s390_emit_add): New function.
8183 (s390_emit_sub): New function.
8184 (s390_emit_mul): New function.
8185 (s390_emit_lsh): New function.
8186 (s390_emit_rsh_signed): New function.
8187 (s390_emit_rsh_unsigned): New function.
8188 (s390_emit_ext): New function.
8189 (s390_emit_log_not): New function.
8190 (s390_emit_bit_and): New function.
8191 (s390_emit_bit_or): New function.
8192 (s390_emit_bit_xor): New function.
8193 (s390_emit_bit_not): New function.
8194 (s390_emit_equal): New function.
8195 (s390_emit_less_signed): New function.
8196 (s390_emit_less_unsigned): New function.
8197 (s390_emit_ref): New function.
8198 (s390_emit_if_goto): New function.
8199 (s390_emit_goto): New function.
8200 (s390_write_goto_address): New function.
8201 (s390_emit_litpool): New function.
8202 (s390_emit_const): New function.
8203 (s390_emit_call): New function.
8204 (s390_emit_reg): New function.
8205 (s390_emit_pop): New function.
8206 (s390_emit_stack_flush): New function.
8207 (s390_emit_zero_ext): New function.
8208 (s390_emit_swap): New function.
8209 (s390_emit_stack_adjust): New function.
8210 (s390_emit_set_r2): New function.
8211 (s390_emit_int_call_1): New function.
8212 (s390_emit_void_call_2): New function.
8213 (s390_emit_eq_goto): New function.
8214 (s390_emit_ne_goto): New function.
8215 (s390_emit_lt_goto): New function.
8216 (s390_emit_le_goto): New function.
8217 (s390_emit_gt_goto): New function.
8218 (s390_emit_ge_goto): New function.
8219 (s390x_emit_prologue): New function.
8220 (s390x_emit_epilogue): New function.
8221 (s390x_emit_add): New function.
8222 (s390x_emit_sub): New function.
8223 (s390x_emit_mul): New function.
8224 (s390x_emit_lsh): New function.
8225 (s390x_emit_rsh_signed): New function.
8226 (s390x_emit_rsh_unsigned): New function.
8227 (s390x_emit_ext): New function.
8228 (s390x_emit_log_not): New function.
8229 (s390x_emit_bit_and): New function.
8230 (s390x_emit_bit_or): New function.
8231 (s390x_emit_bit_xor): New function.
8232 (s390x_emit_bit_not): New function.
8233 (s390x_emit_equal): New function.
8234 (s390x_emit_less_signed): New function.
8235 (s390x_emit_less_unsigned): New function.
8236 (s390x_emit_ref): New function.
8237 (s390x_emit_if_goto): New function.
8238 (s390x_emit_const): New function.
8239 (s390x_emit_call): New function.
8240 (s390x_emit_reg): New function.
8241 (s390x_emit_pop): New function.
8242 (s390x_emit_stack_flush): New function.
8243 (s390x_emit_zero_ext): New function.
8244 (s390x_emit_swap): New function.
8245 (s390x_emit_stack_adjust): New function.
8246 (s390x_emit_int_call_1): New function.
8247 (s390x_emit_void_call_2): New function.
8248 (s390x_emit_eq_goto): New function.
8249 (s390x_emit_ne_goto): New function.
8250 (s390x_emit_lt_goto): New function.
8251 (s390x_emit_le_goto): New function.
8252 (s390x_emit_gt_goto): New function.
8253 (s390x_emit_ge_goto): New function.
8254 (s390_emit_ops): New function.
8255 (struct linux_target_ops): Fill in emit_ops hook.
8257 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8260 * Makefile.in: Add s390 IPA files.
8261 * configure.srv: Build IPA for s390.
8262 * linux-s390-ipa.c: New file.
8263 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8264 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8265 (tdesc_s390_linux32): Likewise.
8266 (init_registers_s390_linux32v1): Likewise.
8267 (tdesc_s390_linux32v1): Likewise.
8268 (init_registers_s390_linux32v2): Likewise.
8269 (tdesc_s390_linux32v2): Likewise.
8270 (init_registers_s390_linux64): Likewise.
8271 (tdesc_s390_linux64): Likewise.
8272 (init_registers_s390_linux64v1): Likewise.
8273 (tdesc_s390_linux64v1): Likewise.
8274 (init_registers_s390_linux64v2): Likewise.
8275 (tdesc_s390_linux64v2): Likewise.
8276 (init_registers_s390_te_linux64): Likewise.
8277 (tdesc_s390_te_linux64): Likewise.
8278 (init_registers_s390_vx_linux64): Likewise.
8279 (tdesc_s390_vx_linux64): Likewise.
8280 (init_registers_s390_tevx_linux64): Likewise.
8281 (tdesc_s390_tevx_linux64): Likewise.
8282 (init_registers_s390x_linux64): Likewise.
8283 (tdesc_s390x_linux64): Likewise.
8284 (init_registers_s390x_linux64v1): Likewise.
8285 (tdesc_s390x_linux64v1): Likewise.
8286 (init_registers_s390x_linux64v2): Likewise.
8287 (tdesc_s390x_linux64v2): Likewise.
8288 (init_registers_s390x_te_linux64): Likewise.
8289 (tdesc_s390x_te_linux64): Likewise.
8290 (init_registers_s390x_vx_linux64): Likewise.
8291 (tdesc_s390x_vx_linux64): Likewise.
8292 (init_registers_s390x_tevx_linux64): Likewise.
8293 (tdesc_s390x_tevx_linux64): Likewise.
8294 (have_hwcap_s390_vx): New static variable.
8295 (s390_arch_setup): Fill have_hwcap_s390_vx.
8296 (s390_get_thread_area): New function.
8297 (s390_ft_entry_gpr_esa): New const.
8298 (s390_ft_entry_gpr_zarch): New const.
8299 (s390_ft_entry_misc): New const.
8300 (s390_ft_entry_fr): New const.
8301 (s390_ft_entry_vr): New const.
8302 (s390_ft_main_31): New const.
8303 (s390_ft_main_64): New const.
8304 (s390_ft_exit_fr): New const.
8305 (s390_ft_exit_vr): New const.
8306 (s390_ft_exit_misc): New const.
8307 (s390_ft_exit_gpr_esa): New const.
8308 (s390_ft_exit_gpr_zarch): New const.
8309 (append_insns): New function.
8310 (s390_relocate_instruction): New function.
8311 (s390_install_fast_tracepoint_jump_pad): New function.
8312 (s390_get_min_fast_tracepoint_insn_len): New function.
8313 (s390_get_ipa_tdesc_idx): New function.
8314 (struct linux_target_ops): Wire in the above functions.
8315 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8316 * linux-s390-tdesc.h: New file.
8318 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8320 * linux-s390-low.c (s390_supports_tracepoints): New function.
8321 (struct linux_target_ops): Fill supports_tracepoints hook.
8323 2016-03-18 Yao Qi <yao.qi@linaro.org>
8325 * linux-low.c (lwp_signal_can_be_delivered): New function.
8326 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8328 2016-03-18 Yao Qi <yao.qi@linaro.org>
8330 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8331 0 if signal is enqueued. Remove 'signal' from one debugging
8332 message. Move one debugging message to some lines below.
8333 Remove code setting 'signal' to 0.
8335 2016-03-18 Yao Qi <yao.qi@linaro.org>
8337 * linux-low.c (linux_low_filter_event): Remove redundant
8338 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8340 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8342 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8343 (struct linux_target_ops): Wire in the above.
8345 2016-03-03 Yao Qi <yao.qi@linaro.org>
8347 * linux-low.c: Update comments to start_step_over.
8349 2016-03-03 Yao Qi <yao.qi@linaro.org>
8352 * linux-low.c (handle_extended_wait): Set child suspended
8353 if event_lwp->bp_reinsert isn't zero.
8355 2016-03-02 Yao Qi <yao.qi@linaro.org>
8357 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8358 enqueue_pending_signal.
8360 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8362 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8365 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8367 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8368 (s390_regmap_3264) [!__s390x__]: New global.
8369 (s390_collect_ptrace_register): Skip map entries containing -1.
8370 (s390_supply_ptrace_register): Ditto.
8371 (s390_fill_gprs_high): New function.
8372 (s390_store_gprs_high): New function.
8373 (s390_regsets): Add NT_S390_HIGH_GPRS.
8374 (s390_get_hwcap): Enable on 31-bit.
8375 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8376 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8377 Detect NT_S390_HIGH_GPRS.
8378 (s390_usrregs_info_3264): Enable on 31-bit.
8379 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8380 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8382 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8385 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8386 * configure.srv: Ditto.
8387 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8388 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8389 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8390 (init_registers_amd64_linux): Remove prototype.
8391 (tdesc_amd64_linux): Remove declaration.
8392 (get_ipa_tdesc): New function.
8393 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8394 initialize remaining tdescs.
8395 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8396 (init_registers_i386_linux): Remove prototype.
8397 (tdesc_i386_linux): Remove declaration.
8398 (get_ipa_tdesc): New function.
8399 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8400 initialize remaining tdescs.
8401 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8402 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8403 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8404 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8405 (x86_get_ipa_tdesc_idx): New function.
8406 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8407 * linux-x86-tdesc.h: New file.
8408 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8409 (target_get_ipa_tdesc_idx): New macro.
8410 * tracepoint.c (ipa_tdesc_idx): New macro.
8411 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8412 (symbol_list): Add ipa_tdesc_idx.
8413 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8414 (ipa_tdesc): Remove.
8415 (ipa_tdesc_idx): New variable.
8416 (get_context_regcache): Use get_ipa_tdesc.
8417 (gdb_collect): Ditto.
8419 * tracepoint.h (get_ipa_tdesc): New prototype.
8420 (ipa_tdesc): Remove.
8422 2016-02-24 Pedro Alves <palves@redhat.com>
8424 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8425 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8426 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8427 Factor out common code between the USE_SIGTRAP_SIGINFO and
8428 !USE_SIGTRAP_SIGINFO blocks.
8429 (linux_low_filter_event): Call save_stop_reason instead of
8430 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8432 (linux_wait_1): Update comments.
8434 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8436 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8437 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8438 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8439 ppc_insert_point, ppc_remove_point.
8441 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8443 * linux-s390-low.c (s390_supports_z_point_type): New function.
8444 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8446 2016-02-16 Yao Qi <yao.qi@linaro.org>
8448 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8449 PC. Get pc from regcache_read_pc.
8451 2016-02-12 Yao Qi <yao.qi@linaro.org>
8453 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8454 or linux_get_pc_32bit.
8455 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8457 2016-02-12 Yao Qi <yao.qi@linaro.org>
8459 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8460 arm_linux_get_next_pcs_fixup.
8462 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8464 * tracepoint.c (x_tracepoint_action_download): Change
8465 write_inferior_data_ptr to write_inferior_data_pointer.
8466 (cmd_qtstart): Likewise.
8467 (write_inferior_data_ptr): Remove.
8468 (download_agent_expr): Change write_inferior_data_ptr to
8469 write_inferior_data_pointer.
8470 (download_tracepoint_1): Likewise.
8471 (download_tracepoint): Likewise.
8472 (download_trace_state_variables): Likewise.
8474 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8475 Marcin Kościelnicki <koriakin@0x04.net>
8477 * tracepoint.c (struct tracepoint_action_ops): Remove.
8478 (struct tracepoint_action): Remove ops.
8479 (m_tracepoint_action_download, r_tracepoint_action_download)
8480 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8481 size and offset accordingly.
8482 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8483 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8484 (tracepoint_action_send, tracepoint_action_download): New functions.
8485 Helpers for trace action handlers.
8486 (add_tracepoint_action): Remove setup actions ops.
8487 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8489 2016-02-10 Yao Qi <yao.qi@linaro.org>
8491 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8493 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8495 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8497 * configure: Regenerate.
8499 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8501 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8502 void * to gdb_byte *.
8503 * linux-low.c (siginfo_fixup): Likewise.
8504 (linux_xfer_siginfo): Likewise.
8505 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8507 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8509 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8511 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8513 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8515 * linux-x86-low.c [__x86_64__]: Include
8516 "nat/amd64-linux-siginfo.h".
8517 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8518 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8519 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8520 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8521 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8522 (cpt_si_fd, si_timerid, si_overrun): Move from
8523 nat/amd64-linux-siginfo.c.
8524 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8526 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8528 * server.c (skip_to_semicolon): Remove.
8529 (process_point_options): Use strchrnul instead of
8532 2016-01-26 Yao Qi <yao.qi@linaro.org>
8534 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8535 * linux-low.c (install_software_single_step_breakpoints): Don't
8536 call regcache_read_pc.
8537 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8540 2016-01-26 Yao Qi <yao.qi@linaro.org>
8542 * linux-low.c (install_software_single_step_breakpoints): Call
8543 regcache_read_pc instead of get_pc.
8545 2016-01-26 Yao Qi <yao.qi@linaro.org>
8547 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8548 (unblock_async_io): Rename to ...
8549 (block_unblock_async_io): ... it. New function.
8550 (enable_async_io): Don't install SIGIO handler. Unblock it
8552 (disable_async_io): Don't ignore SIGIO. Block it instead.
8553 (initialize_async_io): Install SIGIO handler. Don't call
8556 2016-01-26 Yao Qi <yao.qi@linaro.org>
8558 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8559 first character is '\003', call *the_target->request_interrupt.
8561 2016-01-25 Yao Qi <yao.qi@linaro.org>
8563 * remote-utils.c (new_thread_notify): Remove.
8564 (dead_thread_notify): Likewise.
8565 * remote-utils.h (new_thread_notify): Remove declaration.
8566 (dead_thread_notify): Likewise.
8568 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8570 * gdb.trace/pending.exp: Fix expected message on continue.
8572 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8574 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8575 it works properly on big-endian machines where sizeof (CORE_ADDR)
8578 2016-01-21 Pedro Alves <palves@redhat.com>
8580 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8581 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8582 * configure: Regenerate.
8584 2016-01-21 Yao Qi <yao.qi@linaro.org>
8586 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8587 is_thumb and set it according to CPSR saved on the stack.
8588 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8589 arm_sigreturn_next_pc.
8591 2016-01-18 Yao Qi <yao.qi@linaro.org>
8593 * linux-low.c (linux_set_pc_64bit): New function.
8594 (linux_get_pc_64bit): New function.
8595 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8597 * linux-sparc-low.c (debug_threads): Remove declaration.
8598 (sparc_get_pc): Remove.
8599 (the_low_target): Use linux_get_pc_64bit instead of
8601 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8602 (the_low_target): Use linux_get_pc_64bit and
8605 2016-01-18 Yao Qi <yao.qi@linaro.org>
8607 * linux-arm-low.c (debug_threads): Remove declaration.
8608 (arm_get_pc, arm_set_pc): Remove.
8609 (the_low_target): Use linux_get_pc_32bit and
8611 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8612 (the_low_target): Use linux_get_pc_32bit and
8614 * linux-cris-low.c (debug_threads): Remove declaration.
8615 (cris_get_pc, cris_set_pc,): Remove.
8616 (the_low_target): Use linux_get_pc_32bit and
8618 * linux-crisv32-low.c (debug_threads): Remove declaration.
8619 (cris_get_pc, cris_set_pc): Remove.
8620 (the_low_target): Use linux_get_pc_32bit and
8622 * linux-low.c: Include inttypes.h.
8623 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8624 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8625 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8626 (the_low_target): Use linux_get_pc_32bit and
8628 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8629 (the_low_target): Use linux_get_pc_32bit and
8631 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8632 (the_low_target): Use linux_get_pc_32bit and
8634 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8635 (the_low_target): Use linux_get_pc_32bit and
8637 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8638 (the_low_target): Use linux_get_pc_32bit and
8641 2016-01-18 Gary Benson <gbenson@redhat.com>
8643 * configure.ac (AC_FUNC_FORK): New check.
8644 * config.in: Regenerate.
8645 * configure: Likewise.
8647 2016-01-14 Yao Qi <yao.qi@linaro.org>
8649 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8650 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8651 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8652 arm_get_next_pcs_ctor.
8654 2016-01-12 Josh Stone <jistone@redhat.com>
8655 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8657 * inferiors.h: Include "gdb_vecs.h".
8658 (struct process_info): Add syscalls_to_catch.
8659 * inferiors.c (remove_process): Free syscalls_to_catch.
8660 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8661 syscall_return stops.
8662 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8663 * server.c (handle_general_set): Handle QCatchSyscalls.
8664 (handle_query): Report support for QCatchSyscalls.
8665 * target.h (struct target_ops): Add supports_catch_syscall.
8666 (target_supports_catch_syscall): New macro.
8667 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8668 (struct lwp_info): Add syscall_state.
8669 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8670 Maintain syscall_state and syscalls_to_catch across exec.
8671 (get_syscall_trapinfo): New function, proxy to the_low_target.
8672 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8673 (linux_low_filter_event): Toggle syscall_state entry/return for
8674 syscall traps, and set it ignored for all others.
8675 (gdb_catching_syscalls_p): New function.
8676 (gdb_catch_this_syscall_p): New function.
8677 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8678 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8679 (linux_supports_catch_syscall): New function.
8680 (linux_target_ops): Install it.
8681 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8682 (the_low_target): Install it.
8684 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8686 * acinclude.m4: Include new ../warning.m4 file.
8687 * configure: Regenerated.
8688 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8690 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8692 * ax.c (is_goto_target): Mark static.
8693 * linux-low.c (register_addr): Likewise.
8694 (linux_fetch_registers, linux_store_registers): Likewise.
8695 * mem-break.c (any_persistent_commands): Fix old prototype.
8696 (add_commands_to_breakpoint): Mark static.
8697 * regcache.c (find_register_by_name): Delete unused func.
8698 * remote-utils.c (hex_or_minus_one): Mark static.
8699 * server.c (monitor_show_help): Mark static.
8700 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8701 handle_v_requests): Likewise.
8703 2016-01-12 Pedro Alves <palves@redhat.com>
8705 Remove use of the registered trademark symbol throughout.
8707 2016-01-08 Yao Qi <yao.qi@linaro.org>
8709 * remote-utils.c (getpkt): If c is '\003', call target hook
8712 2016-01-06 Yao Qi <yao.qi@linaro.org>
8714 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8715 linux-aarch32-low.c.
8716 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8717 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8718 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8719 (thumb2_breakpoint): Declare.
8720 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8721 linux-aarch32-low.h.
8722 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8723 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8724 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8726 2016-01-01 Joel Brobecker <brobecker@adacore.com>
8728 * gdbreplay.c (gdbreplay_version): Change copyright year in
8730 * server.c (gdbserver_version): Likewise.
8732 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8734 * server.c (crc32_table): Delete.
8735 (crc32): Use libiberty's xcrc32 function.
8737 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8739 * lynx-low.c (lynx_delete_thread_callback): New function.
8740 (lynx_mourn): Properly delete our process and all of its
8741 threads. Remove call to clear_inferiors.
8743 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8745 * target.c (thread_search_callback): Add check that
8746 the thread_stopped target callback is not NULL before
8749 2015-12-21 Yao Qi <yao.qi@linaro.org>
8751 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8754 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8756 * server.c (handle_query): Call target_supports_software_single_step.
8758 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8760 * linux-low.c (single_step): New function.
8761 (linux_resume_one_lwp_throw): Call single_step.
8762 (start_step_over): Likewise.
8764 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8766 * Makefile.in (SFILES): Append arch/arm-linux.c,
8767 arch/arm-get-next-pcs.c.
8768 (arm-linux.o): New rule.
8769 (arm-get-next-pcs.o): New rule.
8770 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8772 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8773 to linux-aarch32-low.c.
8774 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8775 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8776 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8777 (thumb2_breakpoint_len): Likewise.
8778 (arm_is_thumb_mode): Make non-static.
8779 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8780 from linux-aarch32-low.c.
8781 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8782 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8783 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8784 (thumb2_breakpoint_len): Likewise.
8785 (arm_is_thumb_mode): New declaration.
8786 * linux-arm-low.c: Include arch/arm-linux.h
8787 aarch/arm-get-next-pcs.h, sys/syscall.h.
8788 (get_next_pcs_ops): New struct.
8789 (get_next_pcs_addr_bits_remove): New function.
8790 (get_next_pcs_is_thumb): New function.
8791 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8792 (arm_sigreturn_next_pc): Likewise.
8793 (get_next_pcs_syscall_next_pc): Likewise.
8794 (arm_gdbserver_get_next_pcs): Likewise.
8795 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8797 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8798 * server.h: Include gdb_vecs.h.
8800 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8802 * Makefile.in (SFILES): Append common/common-regcache.c.
8803 (OBS): Append common-regcache.o.
8804 (common-regcache.o): New rule.
8805 * regcache.c (init_register_cache): Initialize cache to
8807 (regcache_raw_read_unsigned): New function.
8808 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8809 register_status enum.
8811 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8813 * linux-aarch64-low.c (the_low_targets): Rename
8814 breakpoint_reinsert_addr to get_next_pcs.
8815 * linux-arm-low.c (the_low_targets): Likewise.
8816 * linux-bfin-low.c (the_low_targets): Likewise.
8817 * linux-cris-low.c (the_low_targets): Likewise.
8818 * linux-crisv32-low.c (the_low_targets): Likewise.
8819 * linux-low.c (can_software_single_step): Likewise.
8820 (install_software_single_step_breakpoints): New function.
8821 (start_step_over): Use install_software_single_step_breakpoints.
8822 * linux-low.h: New CORE_ADDR vector.
8823 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8825 * linux-mips-low.c (the_low_targets): Likewise.
8826 * linux-nios2-low.c (the_low_targets): Likewise.
8827 * linux-sparc-low.c (the_low_targets): Likewise.
8829 2015-12-17 Pedro Alves <palves@redhat.com>
8831 * linux-low.c (linux_kill_one_lwp): Remove references to
8833 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8835 (linux_init_signals): Delete.
8836 (initialize_low): Adjust.
8837 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8839 2015-12-16 Pedro Alves <palves@redhat.com>
8841 * configure.ac (compiler warning flags): When testing a
8842 -Wno-foo option, check whether -Wfoo works instead.
8843 * configure: Regenerate.
8845 2015-12-11 Don Breazeal <donb@codesourcery.com>
8847 * server.c (process_serial_event): Don't exit from gdbserver
8848 in remote mode if there are still active inferiors.
8850 2015-12-11 Yao Qi <yao.qi@linaro.org>
8852 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8853 arm_breakpoint_at if the process is 32-bit.
8855 2015-12-11 Yao Qi <yao.qi@linaro.org>
8857 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8860 2015-12-07 Yao Qi <yao.qi@linaro.org>
8862 * configure.srv: Append arm.o to srv_tgtobj for
8863 aarch64*-*-linux* target.
8864 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8865 from linux-arm-low.c.
8866 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8867 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8868 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8869 (thumb2_breakpoint_len): Likewise.
8870 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8871 (arm_breakpoint_kinds): Likewise.
8872 (arm_breakpoint_kind_from_pc): Likewise.
8873 (arm_sw_breakpoint_from_kind): Likewise.
8874 (arm_breakpoint_kind_from_current_state): Likewise.
8875 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8876 (arm_sw_breakpoint_from_kind): Declare.
8877 (arm_breakpoint_kind_from_current_state): Declare.
8878 (arm_breakpoint_at): Declare.
8879 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8880 arm_sw_breakpoint_from_kind if process is 32-bit.
8881 (aarch64_breakpoint_kind_from_pc): New function.
8882 (aarch64_breakpoint_kind_from_current_state): New function.
8883 (the_low_target): Initialize fields breakpoint_kind_from_pc
8884 and breakpoint_kind_from_current_state.
8885 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8886 linux-aarch32-low.c.
8887 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8888 (arm_breakpoint, arm_breakpoint_len): Likewise.
8889 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8890 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8891 (arm_is_thumb_mode): Likewise.
8892 (arm_breakpoint_at): Likewise.
8893 (arm_breakpoint_kind_from_pc): Likewise.
8894 (arm_sw_breakpoint_from_kind): Likewise.
8895 (arm_breakpoint_kind_from_current_state): Likewise.
8898 2015-08-04 Yao Qi <yao.qi@linaro.org>
8900 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8901 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8902 * server.c (extended_protocol): Remove "static".
8903 * server.h (extended_protocol): Declare it.
8905 2015-12-04 Josh Stone <jistone@redhat.com>
8907 * target.h (struct target_ops) <arch_setup>: Rename to ...
8908 (struct target_ops) <post_create_inferior>: ... this.
8909 (target_arch_setup): Rename to ...
8910 (target_post_create_inferior): ... this, calling post_create_inferior.
8911 * server.c (start_inferior): Update target_arch_setup calls to
8912 target_post_create_inferior.
8913 * linux-low.c (linux_low_ptrace_options): Forward declare.
8914 (linux_arch_setup): Update its comment for general use.
8915 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8916 (struct linux_target_ops): Use linux_post_create_inferior.
8917 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8918 to post_create_inferior.
8919 * nto-low.c (struct nto_target_ops): Likewise.
8920 * spu-low.c (struct spu_target_ops): Likewise.
8921 * win32-low.c (struct win32_target_ops): Likewise.
8923 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
8925 * linux-arm-low.c: Remove duplicate arch/arm.h include.
8927 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8929 * linux-arm-low.c (arm_reinsert_addr): Remove function.
8930 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
8931 * linux-cris-low.c (cris_reinsert_addr> Remove function.
8932 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8933 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
8934 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8935 * linux-mips-low.c (mips_reinsert_addr): Remove function.
8936 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8937 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
8938 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8939 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
8940 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8942 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8944 * linux-low.c (linux_look_up_symbols): Don't call
8945 linux_supports_traceclone.
8946 * linux-low.h (thread_db_init): Remove use_events argument.
8947 * thread-db.c (thread_db_use_event): Remove global variable.
8948 (struct thread_db) <td_thr_event_enable_p>: Remove field.
8949 (struct thread_db) <td_create_bp>: Remove field.
8950 (thread_db_create_event): Remove function.
8951 (thread_db_enable_reporting): Likewise.
8952 (find_one_thread): Don't check for thread_db_use_events.
8953 (attach_thread): Likewise.
8954 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
8955 (try_thread_db_load_1): Don't check for thread_db_use_events.
8956 (thread_db_init): Remove use_events argument and thread events
8958 (remove_thread_event_breakpoints): Remove function.
8959 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
8961 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8963 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
8965 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8966 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
8967 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8968 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
8969 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
8971 * linux-crisv32-low.c (cris_supports_hardware_single_step):
8973 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8974 * linux-low.c (can_hardware_single_step): Use
8975 supports_hardware_single_step.
8976 (can_software_single_step): New function.
8977 (start_step_over): Call can_software_single_step.
8978 (linux_supports_hardware_single_step): New function.
8979 (struct target_ops) <supports_software_single_step>: Initialize.
8980 * linux-low.h (struct linux_target_ops)
8981 <supports_hardware_single_step>: Initialize.
8982 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
8983 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8984 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
8985 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
8986 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
8987 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8988 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
8989 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8990 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
8991 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
8993 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
8994 (struct linux_target_ops) <tile_supports_hardware_single_step>:
8996 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
8997 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8998 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9000 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9001 * target.h (struct target_ops): <supports_software_single_step>:
9003 (target_supports_software_single_step): New macro.
9005 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9007 * linux-low.c (linux_wait_1): Fix pc advance condition.
9008 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9009 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9011 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9013 * linux-arm-low.c (arm_is_thumb_mode): New function.
9014 (arm_breakpoint_at): Use arm_is_thumb_mode.
9015 (arm_breakpoint_kind_from_current_state): New function.
9016 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9018 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9019 (linux_breakpoint_kind_from_current_state): New function.
9020 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9021 * linux-low.h (struct linux_target_ops)
9022 <breakpoint_kind_from_current_state>: New field.
9023 * target.h (struct target_ops): Likewise.
9024 (target_breakpoint_kind_from_current_state): New macro.
9026 2015-11-30 Pedro Alves <palves@redhat.com>
9028 * linux-low.c (linux_resume): Wake up the event loop before
9031 2015-11-30 Pedro Alves <palves@redhat.com>
9033 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9035 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9037 * target.c (struct thread_search): New structure.
9038 (thread_search_callback): New function.
9039 (prev_general_thread): New global.
9040 (prepare_to_access_memory, done_accessing_memory): New functions.
9041 * target.h (prepare_to_access_memory, done_accessing_memory):
9042 Replace macros with function declarations.
9044 2015-11-30 Pedro Alves <palves@redhat.com>
9047 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9048 report TARGET_WAITKIND_NO_RESUMED.
9049 * remote-utils.c (prepare_resume_reply): Handle
9050 TARGET_WAITKIND_NO_RESUMED.
9051 * server.c (report_no_resumed): New global.
9052 (handle_query) <qSupported>: Handle "no-resumed+". Report
9053 "no-resumed+" support.
9054 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9055 return error if the client doesn't support no-resumed events.
9056 (push_stop_notification): New function.
9057 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9058 events if the client supports them.
9060 2015-11-30 Pedro Alves <palves@redhat.com>
9062 * linux-low.c (thread_still_has_status_pending_p): Don't check
9064 (lwp_resumed): New function.
9065 (status_pending_p_callback): Return early if the LWP is not
9066 supposed to be resumed.
9068 2015-11-30 Pedro Alves <palves@redhat.com>
9070 * linux-low.c (handle_extended_wait): Assert that the LWP's
9071 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9072 thread create events, leave the new child's status pending.
9073 (linux_low_filter_event): If GDB wants to hear about thread exit
9074 events, leave the LWP marked dead and don't delete it.
9075 (linux_wait_for_event_filtered): Don't check for thread exit.
9076 (filter_exit_event): New function.
9077 (linux_wait_1): Use it, when returning an exit event.
9078 (linux_resume_one_lwp_throw): Assert that the LWP's
9079 waitstatus is TARGET_WAITKIND_IGNORE.
9080 * remote-utils.c (prepare_resume_reply): Handle
9081 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9082 * server.c (report_thread_events): New global.
9083 (handle_general_set): Handle QThreadEvents.
9084 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9085 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9086 TARGET_WAITKIND_THREAD_EXITED.
9087 * server.h (report_thread_events): Declare.
9089 2015-11-30 Pedro Alves <palves@redhat.com>
9091 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9092 the thread's last_resume_kind was resume_stop.
9094 2015-11-30 Pedro Alves <palves@redhat.com>
9096 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9099 2015-11-30 Pedro Alves <palves@redhat.com>
9101 * server.c (handle_v_requests): Handle vCtrlC.
9103 2015-11-30 Pedro Alves <palves@redhat.com>
9105 * gdbthread.h (find_any_thread_of_pid): Declare.
9106 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9108 * server.c (handle_query): If current_thread is NULL, look for
9109 another thread of the selected process.
9111 2015-11-26 Daniel Colascione <dancol@dancol.org>
9112 Simon Marchi <simon.marchi@ericsson.com>
9114 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9115 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9117 * target.h (struct target_ops) <thread_name>: New field.
9118 (target_thread_name): New macro.
9120 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9122 * regcache.h (regcache_invalidate_pid): Add declaration.
9123 * regcache.c (regcache_invalidate_pid): New function, extracted
9124 from regcache_invalidate.
9125 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9126 Add trivial documentation comment.
9127 * lynx-low.c: Use regcache_invalidate_pid instead of
9128 regcache_invalidate.
9130 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9132 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9133 and Elf64_auxv_t if the target is Android.
9135 2015-11-22 Doug Evans <xdje42@gmail.com>
9137 * target.h: #include <sys/types.h>.
9139 2015-11-19 Pedro Alves <palves@redhat.com>
9141 * linux-low.c (linux_process_qsupported): Change prototype.
9143 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9145 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9146 and adjust to loop over all features.
9147 * server.c (handle_query) <qSupported>: Adjust to call
9148 target_process_qsupported once, passing it a vector of unprocessed
9150 * target.h (struct target_ops) <process_qsupported>: Change
9152 (target_process_qsupported): Adjust.
9154 2015-11-19 Pedro Alves <palves@redhat.com>
9156 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9158 * configure: Regenerate.
9160 2015-11-19 Pedro Alves <palves@redhat.com>
9162 * configure: Regenerate.
9164 2015-11-19 Yao Qi <yao.qi@linaro.org>
9166 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9169 2015-11-19 Yao Qi <yao.qi@linaro.org>
9171 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9172 (struct aarch64_operand): Move enum out.
9174 2015-11-19 Yao Qi <yao.qi@linaro.org>
9176 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9177 struct user_fpsimd_state *.
9178 (aarch64_store_fpregset): Likewise.
9180 2015-11-19 Yao Qi <yao.qi@linaro.org>
9182 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9183 struct user_pt_regs *.
9184 (aarch64_store_gregset): Likewise.
9186 2015-11-18 Pedro Alves <palves@redhat.com>
9188 * Makefile.in (all_object_files): Add $IPA_OBJS.
9190 2015-11-17 Pedro Alves <palves@redhat.com>
9192 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9193 GDB_SIGNAL_0 and gdb_signal_to_string.
9195 2015-11-17 Pedro Alves <palves@redhat.com>
9197 * win32-low.c (handle_output_debug_string): Remove parameter.
9198 (win32_kill): Remove our_status local and adjust call to
9199 handle_output_debug_string.
9200 (get_child_debug_event): Adjust call to
9201 handle_output_debug_string.
9203 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9205 * linux-mips-low.c (mips_fill_gregset): Add cast.
9206 (mips_store_gregset): Likewise.
9207 (mips_fill_fpregset): Likewise.
9208 (mips_store_fpregset): Likewise.
9210 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9212 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9215 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9217 * linux-mips-low.c (mips_linux_new_thread): Change type of
9218 watch_type to enum target_hw_bp_type.
9220 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9222 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9223 Change return type to arm_hwbp_type.
9225 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9227 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9228 (arm_store_gregset): Likewise.
9229 * linux-arm-low.c (arm_get_hwcap): Likewise.
9230 (arm_read_description): Likewise.
9232 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9234 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9236 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9238 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9239 (ppc_fill_vsxregset): Likewise.
9240 (ppc_store_vsxregset): Likewise.
9241 (ppc_fill_vrregset): Likewise.
9242 (ppc_store_vrregset): Likewise.
9243 (ppc_fill_evrregset): Likewise.
9244 (ppc_store_evrregset): Likewise.
9246 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9248 * linux-ppc-low.c (ppc_usrregs_info): Remove
9249 forward-declaration.
9250 (ppc_arch_setup): Move lower in file.
9252 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9254 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9255 (ps_pdwrite): Likewise.
9257 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9259 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9260 to after assert checks.
9262 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9264 * proc-service.c (ps_pdread): Add/adjust casts.
9265 (ps_pdwrite): Add/adjust casts.
9267 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9269 * server.c (handle_search_memory_1): Cast return value of
9272 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9274 * server.c (write_qxfer_response): Change type of data to
9277 2015-10-29 Pedro Alves <palves@redhat.com>
9279 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9281 2015-10-29 Pedro Alves <palves@redhat.com>
9283 * tracepoint.c (clear_installed_tracepoints): Add casts.
9285 2015-10-29 Pedro Alves <palves@redhat.com>
9287 * server.c (handle_v_cont, process_serial_event): Add enum
9288 gdb_signal casts to signal parsing code.
9290 2015-10-29 Pedro Alves <palves@redhat.com>
9292 * linux-low.h (NULL_REGSET): Define.
9293 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9294 * linux-arm-low.c (arm_regsets): Likewise.
9295 * linux-crisv32-low.c (cris_regsets): Likewise.
9296 * linux-m68k-low.c (m68k_regsets): Likewise.
9297 * linux-mips-low.c (mips_regsets): Likewise.
9298 * linux-nios2-low.c (nios2_regsets): Likewise.
9299 * linux-ppc-low.c (ppc_regsets): Likewise.
9300 * linux-s390-low.c (s390_regsets): Likewise.
9301 * linux-sh-low.c (sh_regsets): Likewise.
9302 * linux-sparc-low.c (sparc_regsets): Likewise.
9303 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9304 * linux-tile-low.c (tile_regsets): Likewise.
9305 * linux-x86-low.c (x86_regsets): Likewise.
9306 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9308 2015-10-29 Pedro Alves <palves@redhat.com>
9310 * linux-low.h (NULL_REGSET): Define.
9311 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9312 * linux-arm-low.c (arm_regsets): Likewise.
9313 * linux-crisv32-low.c (cris_regsets): Likewise.
9314 * linux-m68k-low.c (m68k_regsets): Likewise.
9315 * linux-mips-low.c (mips_regsets): Likewise.
9316 * linux-nios2-low.c (nios2_regsets): Likewise.
9317 * linux-ppc-low.c (ppc_regsets): Likewise.
9318 * linux-s390-low.c (s390_regsets): Likewise.
9319 * linux-sh-low.c (sh_regsets): Likewise.
9320 * linux-sparc-low.c (sparc_regsets): Likewise.
9321 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9322 * linux-tile-low.c (tile_regsets): Likewise.
9323 * linux-x86-low.c (x86_regsets): Likewise.
9324 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9326 2015-10-26 Doug Evans <dje@google.com>
9328 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9330 2015-10-26 Doug Evans <dje@google.com>
9332 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9334 2015-10-26 Doug Evans <dje@google.com>
9336 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9338 (attach_thread, find_new_threads_callback): Ditto.
9340 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9342 * mem-break.h (set_breakpoint_data): Remove.
9344 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9346 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9347 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9348 (initialize_low): Remove set_breakpoint_data call.
9349 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9350 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9351 (initialize_low): Remove set_breakpoint_data call.
9352 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9353 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9354 (initialize_low): Remove set_breakpoint_data call.
9356 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9358 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9359 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9360 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9361 * target.h (target_breakpoint_kind_from_pc): New macro.
9363 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9365 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9366 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9367 the default breakpoint kind.
9369 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9371 * linux-arm-low.c (arm_supports_z_point_type): Add software
9374 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9376 * linux-arm-low.c: Refactor breakpoint definitions.
9377 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9378 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9380 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9382 * Makefile.in: Add arm.c/o.
9383 * configure.srv: Likewise.
9384 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9385 (arm_breakpoint_kind_from_pc): New function.
9386 (arm_sw_breakpoint_from_kind): Return proper kind.
9387 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9389 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9391 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9393 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9394 (struct raw_breakpoint) <size>: Remove.
9395 (struct raw_breakpoint) <kind>: Add.
9396 (bp_size): New function.
9397 (bp_opcode): Likewise.
9398 (find_raw_breakpoint_at): Adjust for kind.
9399 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9400 (remove_memory_breakpoint): Adjust for kind call bp_size.
9401 (set_raw_breakpoint_at): Adjust for kind.
9402 (set_breakpoint): Likewise.
9403 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9404 (delete_raw_breakpoint): Adjust for kind.
9405 (delete_breakpoint): Likewise.
9406 (find_gdb_breakpoint): Likewise.
9407 (set_gdb_breakpoint_1): Likewise.
9408 (set_gdb_breakpoint): Likewise.
9409 (delete_gdb_breakpoint_1): Likewise.
9410 (delete_gdb_breakpoint): Likewise.
9411 (uninsert_raw_breakpoint): Likewise.
9412 (reinsert_raw_breakpoint): Likewise.
9413 (set_breakpoint_data): Remove.
9414 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9415 (check_mem_read): Adjust for kind call bp_size.
9416 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9417 (clone_one_breakpoint): Adjust for kind.
9418 * mem-break.h (set_gdb_breakpoint): Likewise.
9419 (delete_gdb_breakpoint): Likewise.
9420 * server.c (process_serial_event): Likewise.
9422 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9424 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9425 (struct linux_target_ops) <breakpoint>: Remove.
9426 (struct linux_target_ops) <breakpoint_len>: Remove.
9427 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9428 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9429 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9430 (arm_sw_breakpoint_from_kind): New function.
9431 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9432 (struct linux_target_ops) <breakpoint>: Remove.
9433 (struct linux_target_ops) <breakpoint_len>: Remove.
9434 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9435 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9436 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9437 (struct linux_target_ops) <breakpoint>: Remove.
9438 (struct linux_target_ops) <breakpoint_len>: Remove.
9439 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9440 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9441 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9442 (struct linux_target_ops) <breakpoint>: Remove.
9443 (struct linux_target_ops) <breakpoint_len>: Remove.
9444 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9445 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9446 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9447 and sw_breakpoint_from_kind to increment the pc.
9448 (linux_breakpoint_kind_from_pc): New function.
9449 (linux_sw_breakpoint_from_kind): New function.
9450 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9451 (initialize_low): Call breakpoint_kind_from_pc and
9452 sw_breakpoint_from_kind to replace breakpoint_data/len.
9453 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9455 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9456 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9457 (struct linux_target_ops) <breakpoint>: Remove.
9458 (struct linux_target_ops) <breakpoint_len>: Remove.
9459 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9460 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9461 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9462 (struct linux_target_ops) <breakpoint>: Remove.
9463 (struct linux_target_ops) <breakpoint_len>: Remove.
9464 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9465 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9466 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9467 (struct linux_target_ops) <breakpoint>: Remove.
9468 (struct linux_target_ops) <breakpoint_len>: Remove.
9469 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9470 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9471 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9472 (struct linux_target_ops) <breakpoint>: Remove.
9473 (struct linux_target_ops) <breakpoint_len>: Remove.
9474 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9475 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9476 * linux-ppc-low.c (ppc_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-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9482 (struct linux_target_ops) <breakpoint>: Remove.
9483 (struct linux_target_ops) <breakpoint_len>: Remove.
9484 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9485 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9486 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9487 (struct linux_target_ops) <breakpoint>: Remove.
9488 (struct linux_target_ops) <breakpoint_len>: Remove.
9489 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9490 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9491 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9492 (struct linux_target_ops) <breakpoint>: Remove.
9493 (struct linux_target_ops) <breakpoint_len>: Remove.
9494 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9495 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9496 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9497 (struct linux_target_ops) <breakpoint>: Remove.
9498 (struct linux_target_ops) <breakpoint_len>: Remove.
9499 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9500 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9501 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9502 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9503 (struct linux_target_ops) <breakpoint>: Remove.
9504 (struct linux_target_ops) <breakpoint_len>: Remove.
9505 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9506 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9507 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9508 (struct linux_target_ops) <breakpoint>: Remove.
9509 (struct linux_target_ops) <breakpoint_len>: Remove.
9510 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9511 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9513 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9515 * linux-cris-low.c (cris_get_pc): Remove void arg.
9517 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9519 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9522 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9524 * inferiors.c (thread_pid_matches_callback): New function.
9525 (find_thread_process): New function.
9526 (remove_thread): Reset current_thread.
9527 (remove_process): Assert threads have been removed first.
9529 2015-10-15 Yao Qi <yao.qi@linaro.org>
9531 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9533 (aarch64_remove_point): Likewise.
9534 * regcache.c (regcache_register_size): New function.
9536 2015-10-12 Yao Qi <yao.qi@linaro.org>
9538 * linux-aarch64-low.c: Update all callers as emit_load_store
9539 is renamed to aarch64_emit_load_store.
9541 2015-10-12 Yao Qi <yao.qi@linaro.org>
9543 * linux-aarch64-low.c: Update all callers of function renaming
9544 from emit_insn to aarch64_emit_insn.
9546 2015-10-12 Yao Qi <yao.qi@linaro.org>
9548 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9549 arch/aarch64-insn.h.
9550 (struct aarch64_memory_operand): Likewise.
9552 (emit_insn): Move to arch/aarch64-insn.c.
9553 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9554 (emit_load_store): Move to arch/aarch64-insn.c.
9555 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9556 (can_encode_int32): Remove.
9558 2015-10-12 Yao Qi <yao.qi@linaro.org>
9560 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9561 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9562 (aarch64_relocate_instruction): Likewise.
9563 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9564 (struct aarch64_insn_visitor): Likewise.
9566 2015-10-12 Yao Qi <yao.qi@linaro.org>
9568 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9569 (struct aarch64_insn_visitor): New.
9570 (struct aarch64_insn_relocation_data): New.
9571 (aarch64_ftrace_insn_reloc_b): New function.
9572 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9573 (aarch64_ftrace_insn_reloc_cb): Likewise.
9574 (aarch64_ftrace_insn_reloc_tb): Likewise.
9575 (aarch64_ftrace_insn_reloc_adr): Likewise.
9576 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9577 (aarch64_ftrace_insn_reloc_others): Likewise.
9579 (aarch64_relocate_instruction): Use visitor.
9581 2015-10-12 Yao Qi <yao.qi@linaro.org>
9583 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9584 int. Add argument buf.
9585 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9586 aarch64_relocate_instruction.
9588 2015-10-12 Yao Qi <yao.qi@linaro.org>
9590 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9591 argument insn. Remove local variable insn. Don't call
9593 (aarch64_install_fast_tracepoint_jump_pad): Call
9596 2015-09-30 Yao Qi <yao.qi@linaro.org>
9598 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9599 (emit_load_store_pair): Likewise.
9601 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9603 * dll.c (match_dll): Add cast(s).
9604 (unloaded_dll): Likewise.
9605 * linux-low.c (second_thread_of_pid_p): Likewise.
9606 (delete_lwp_callback): Likewise.
9607 (count_events_callback): Likewise.
9608 (select_event_lwp_callback): Likewise.
9609 (linux_set_resume_request): Likewise.
9610 * server.c (accumulate_file_name_length): Likewise.
9611 (emit_dll_description): Likewise.
9612 (handle_qxfer_threads_worker): Likewise.
9613 (visit_actioned_threads): Likewise.
9614 * thread-db.c (any_thread_of): Likewise.
9615 * tracepoint.c (same_process_p): Likewise.
9616 (match_blocktype): Likewise.
9617 (build_traceframe_info_xml): Likewise.
9619 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9621 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9623 (gdb_unparse_agent_expr): Likewise.
9624 * hostio.c (require_data): Likewise.
9625 (handle_pread): Likewise.
9626 * linux-low.c (disable_regset): Likewise.
9627 (fetch_register): Likewise.
9628 (store_register): Likewise.
9629 (get_dynamic): Likewise.
9630 (linux_qxfer_libraries_svr4): Likewise.
9631 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9632 (set_fast_tracepoint_jump): Likewise.
9633 (uninsert_fast_tracepoint_jumps_at): Likewise.
9634 (reinsert_fast_tracepoint_jumps_at): Likewise.
9635 (validate_inserted_breakpoint): Likewise.
9636 (clone_agent_expr): Likewise.
9637 * regcache.c (init_register_cache): Likewise.
9638 * remote-utils.c (putpkt_binary_1): Likewise.
9639 (decode_M_packet): Likewise.
9640 (decode_X_packet): Likewise.
9641 (look_up_one_symbol): Likewise.
9642 (relocate_instruction): Likewise.
9643 (monitor_output): Likewise.
9644 * server.c (handle_search_memory): Likewise.
9645 (handle_qxfer_exec_file): Likewise.
9646 (handle_qxfer_libraries): Likewise.
9647 (handle_qxfer): Likewise.
9648 (handle_query): Likewise.
9649 (handle_v_cont): Likewise.
9650 (handle_v_run): Likewise.
9651 (captured_main): Likewise.
9652 * target.c (write_inferior_memory): Likewise.
9653 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9654 * tracepoint.c (init_trace_buffer): Likewise.
9655 (add_tracepoint_action): Likewise.
9656 (add_traceframe): Likewise.
9657 (add_traceframe_block): Likewise.
9658 (cmd_qtdpsrc): Likewise.
9659 (cmd_qtdv): Likewise.
9660 (cmd_qtstatus): Likewise.
9661 (response_source): Likewise.
9662 (response_tsv): Likewise.
9663 (cmd_qtnotes): Likewise.
9664 (gdb_collect): Likewise.
9665 (initialize_tracepoint): Likewise.
9667 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9669 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9670 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9671 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9673 (enum aarch64_condition_codes): New enum.
9674 (w0): New static global.
9677 (struct aarch64_memory_operand) <type>: New
9678 MEMORY_OPERAND_POSTINDEX type.
9679 (postindex_memory_operand): New helper function.
9680 (emit_ret): New function.
9681 (emit_load_store_pair): New function, factored out of emit_stp
9682 with support for MEMORY_OPERAND_POSTINDEX.
9683 (emit_stp): Rewrite using emit_load_store_pair.
9684 (emit_ldp): New function.
9685 (emit_load_store): Likewise.
9686 (emit_ldr): Mention post-index instruction in comment.
9687 (emit_ldrh): New function.
9688 (emit_ldrb): New function.
9689 (emit_ldrsw): Mention post-index instruction in comment.
9690 (emit_str): Likewise.
9691 (emit_subs): New function.
9692 (emit_cmp): Likewise.
9693 (emit_and): Likewise.
9694 (emit_orr): Likewise.
9695 (emit_orn): Likewise.
9696 (emit_eor): Likewise.
9697 (emit_mvn): Likewise.
9698 (emit_lslv): Likewise.
9699 (emit_lsrv): Likewise.
9700 (emit_asrv): Likewise.
9701 (emit_mul): Likewise.
9702 (emit_sbfm): Likewise.
9703 (emit_sbfx): Likewise.
9704 (emit_ubfm): Likewise.
9705 (emit_ubfx): Likewise.
9706 (emit_csinc): Likewise.
9707 (emit_cset): Likewise.
9708 (emit_nop): Likewise.
9709 (emit_ops_insns): New helper function.
9710 (emit_pop): Likewise.
9711 (emit_push): Likewise.
9712 (aarch64_emit_prologue): New function.
9713 (aarch64_emit_epilogue): Likewise.
9714 (aarch64_emit_add): Likewise.
9715 (aarch64_emit_sub): Likewise.
9716 (aarch64_emit_mul): Likewise.
9717 (aarch64_emit_lsh): Likewise.
9718 (aarch64_emit_rsh_signed): Likewise.
9719 (aarch64_emit_rsh_unsigned): Likewise.
9720 (aarch64_emit_ext): Likewise.
9721 (aarch64_emit_log_not): Likewise.
9722 (aarch64_emit_bit_and): Likewise.
9723 (aarch64_emit_bit_or): Likewise.
9724 (aarch64_emit_bit_xor): Likewise.
9725 (aarch64_emit_bit_not): Likewise.
9726 (aarch64_emit_equal): Likewise.
9727 (aarch64_emit_less_signed): Likewise.
9728 (aarch64_emit_less_unsigned): Likewise.
9729 (aarch64_emit_ref): Likewise.
9730 (aarch64_emit_if_goto): Likewise.
9731 (aarch64_emit_goto): Likewise.
9732 (aarch64_write_goto_address): Likewise.
9733 (aarch64_emit_const): Likewise.
9734 (aarch64_emit_call): Likewise.
9735 (aarch64_emit_reg): Likewise.
9736 (aarch64_emit_pop): Likewise.
9737 (aarch64_emit_stack_flush): Likewise.
9738 (aarch64_emit_zero_ext): Likewise.
9739 (aarch64_emit_swap): Likewise.
9740 (aarch64_emit_stack_adjust): Likewise.
9741 (aarch64_emit_int_call_1): Likewise.
9742 (aarch64_emit_void_call_2): Likewise.
9743 (aarch64_emit_eq_goto): Likewise.
9744 (aarch64_emit_ne_goto): Likewise.
9745 (aarch64_emit_lt_goto): Likewise.
9746 (aarch64_emit_le_goto): Likewise.
9747 (aarch64_emit_gt_goto): Likewise.
9748 (aarch64_emit_ge_got): Likewise.
9749 (aarch64_emit_ops_impl): New static global variable.
9750 (aarch64_emit_ops): New target function, return
9751 &aarch64_emit_ops_impl.
9752 (struct linux_target_ops): Install it.
9754 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9756 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9757 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9759 * linux-aarch64-ipa.c: New file.
9760 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9762 (aarch64_get_thread_area): New target method.
9763 (extract_signed_bitfield): New helper function.
9764 (aarch64_decode_ldr_literal): New function.
9765 (enum aarch64_opcodes): New enum.
9766 (struct aarch64_register): New struct.
9767 (struct aarch64_operand): New struct.
9768 (x0): New static global.
9777 (aarch64_register): New helper function.
9778 (register_operand): Likewise.
9779 (immediate_operand): Likewise.
9780 (struct aarch64_memory_operand): New struct.
9781 (offset_memory_operand): New helper function.
9782 (preindex_memory_operand): Likewise.
9783 (enum aarch64_system_control_registers): New enum.
9784 (ENCODE): New macro.
9785 (emit_insn): New helper function.
9786 (emit_b): New function.
9787 (emit_bcond): Likewise.
9788 (emit_cb): Likewise.
9789 (emit_tb): Likewise.
9790 (emit_blr): Likewise.
9791 (emit_stp): Likewise.
9792 (emit_ldp_q_offset): Likewise.
9793 (emit_stp_q_offset): Likewise.
9794 (emit_load_store): Likewise.
9795 (emit_ldr): Likewise.
9796 (emit_ldrsw): Likewise.
9797 (emit_str): Likewise.
9798 (emit_ldaxr): Likewise.
9799 (emit_stxr): Likewise.
9800 (emit_stlr): Likewise.
9801 (emit_data_processing_reg): Likewise.
9802 (emit_data_processing): Likewise.
9803 (emit_add): Likewise.
9804 (emit_sub): Likewise.
9805 (emit_mov): Likewise.
9806 (emit_movk): Likewise.
9807 (emit_mov_addr): Likewise.
9808 (emit_mrs): Likewise.
9809 (emit_msr): Likewise.
9810 (emit_sevl): Likewise.
9811 (emit_wfe): Likewise.
9812 (append_insns): Likewise.
9813 (can_encode_int32_in): New helper function.
9814 (aarch64_relocate_instruction): New function.
9815 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9816 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9817 (struct linux_target_ops): Install aarch64_get_thread_area,
9818 aarch64_install_fast_tracepoint_jump_pad and
9819 aarch64_get_min_fast_tracepoint_insn_len.
9821 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9823 * Makefile.in (aarch64-insn.o): New rule.
9824 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9826 2015-09-21 Yao Qi <yao.qi@linaro.org>
9828 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9830 2015-09-21 Yao Qi <yao.qi@linaro.org>
9832 * tracepoint.c (max_jump_pad_size): Remove.
9834 2015-09-18 Yao Qi <yao.qi@linaro.org>
9836 * linux-aarch64-low.c: Don't include sys/uio.h.
9837 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9839 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
9841 * tracepoint.c (eval_result_type): Change prototype.
9842 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9844 2015-09-15 Pedro Alves <palves@redhat.com>
9846 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9847 Check whether to report exec events instead of checking whether
9848 multiprocess is enabled.
9850 2015-09-15 Pedro Alves <palves@redhat.com>
9853 * remote-utils.c (prepare_resume_reply): Merge
9854 TARGET_WAITKIND_VFORK_DONE switch case with the
9855 TARGET_WAITKIND_FORKED case.
9857 2015-09-15 Yao Qi <yao.qi@linaro.org>
9859 * server.c (handle_query): Check string comparison using
9860 "else if" instead of "if".
9862 2015-09-15 Yao Qi <yao.qi@linaro.org>
9864 * server.c (vCont_supported): New global variable.
9865 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9866 matches. Append ";vContSupported+" to own_buf.
9867 (handle_v_requests): Append ";s;S" to own_buf if target supports
9868 hardware single step or vCont_supported is false.
9869 (capture_main): Set vCont_supported to zero.
9871 2015-09-15 Yao Qi <yao.qi@linaro.org>
9873 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9875 (linux_supports_hardware_single_step): ... New function.
9876 (linux_target_ops): Update.
9877 * lynx-low.c (lynx_target_ops): Set field
9878 supports_hardware_single_step to target_can_do_hardware_single_step.
9879 * nto-low.c (nto_target_ops): Likewise.
9880 * spu-low.c (spu_target_ops): Likewise.
9881 * win32-low.c (win32_target_ops): Likewise.
9882 * target.c (target_can_do_hardware_single_step): New function.
9883 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9884 Remove. <supports_hardware_single_step>: New field.
9885 (target_supports_conditional_breakpoints): Remove.
9886 (target_supports_hardware_single_step): New macro.
9887 (target_can_do_hardware_single_step): Declare.
9888 * server.c (handle_query): Use target_supports_hardware_single_step
9889 instead of target_supports_conditional_breakpoints.
9891 2015-09-15 Yao Qi <yao.qi@linaro.org>
9893 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9895 (struct linux_target_ops the_low_target): Install
9896 aarch64_linux_siginfo_fixup.
9898 2015-09-11 Don Breazeal <donb@codesourcery.com>
9899 Luis Machado <lgustavo@codesourcery.com>
9901 * linux-low.c (linux_mourn): Static declaration.
9902 (linux_arch_setup): Move in front of
9903 handle_extended_wait.
9904 (linux_arch_setup_thread): New function.
9905 (handle_extended_wait): Handle exec events. Call
9906 linux_arch_setup_thread. Make event_lwp argument a
9907 pointer-to-a-pointer.
9908 (check_zombie_leaders): Do not check stopped threads.
9909 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9910 (linux_low_filter_event): Add lwp and thread for exec'ing
9911 non-leader thread if leader thread has been deleted.
9912 Refactor code into linux_arch_setup_thread and call it.
9913 Pass child lwp pointer by reference to handle_extended_wait.
9914 (linux_wait_for_event_filtered): Update comment.
9915 (linux_wait_1): Prevent clobbering exec event status.
9916 (linux_supports_exec_events): New function.
9917 (linux_target_ops) <supports_exec_events>: Initialize new member.
9918 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9920 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9921 * server.c (report_exec_events): New global variable.
9922 (handle_query): Handle qSupported query for exec-events feature.
9923 (captured_main): Initialize report_exec_events.
9924 * server.h (report_exec_events): Declare new global variable.
9925 * target.h (struct target_ops) <supports_exec_events>: New
9927 (target_supports_exec_events): New macro.
9928 * win32-low.c (win32_target_ops) <supports_exec_events>:
9929 Initialize new member.
9931 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
9933 * linux-low.c (linux_low_enable_btrace): Remove.
9934 (linux_target_ops): Replace linux_low_enable_btrace with
9935 linux_enable_btrace.
9937 2015-09-03 Yao Qi <yao.qi@linaro.org>
9939 * linux-aarch64-low.c (aarch64_insert_point): Call
9940 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
9943 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
9945 * linux-low.c (check_stopped_by_breakpoint): Use
9946 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
9948 2015-08-27 Pedro Alves <palves@redhat.com>
9950 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
9952 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
9954 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
9955 the XNEW-family equivalent.
9956 (compile_bytecodes): Likewise.
9957 * dll.c (loaded_dll): Likewise.
9958 * event-loop.c (append_callback_event): Likewise.
9959 (create_file_handler): Likewise.
9960 (create_file_event): Likewise.
9961 * hostio.c (handle_open): Likewise.
9962 * inferiors.c (add_thread): Likewise.
9963 (add_process): Likewise.
9964 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
9965 * linux-arm-low.c (arm_new_process): Likewise.
9966 (arm_new_thread): Likewise.
9967 * linux-low.c (add_to_pid_list): Likewise.
9968 (linux_add_process): Likewise.
9969 (handle_extended_wait): Likewise.
9970 (add_lwp): Likewise.
9971 (enqueue_one_deferred_signal): Likewise.
9972 (enqueue_pending_signal): Likewise.
9973 (linux_resume_one_lwp_throw): Likewise.
9974 (linux_resume_one_thread): Likewise.
9975 (linux_read_memory): Likewise.
9976 (linux_write_memory): Likewise.
9977 * linux-mips-low.c (mips_linux_new_process): Likewise.
9978 (mips_linux_new_thread): Likewise.
9979 (mips_add_watchpoint): Likewise.
9980 * linux-x86-low.c (initialize_low_arch): Likewise.
9981 * lynx-low.c (lynx_add_process): Likewise.
9982 * mem-break.c (set_raw_breakpoint_at): Likewise.
9983 (set_breakpoint): Likewise.
9984 (add_condition_to_breakpoint): Likewise.
9985 (add_commands_to_breakpoint): Likewise.
9986 (clone_agent_expr): Likewise.
9987 (clone_one_breakpoint): Likewise.
9988 * regcache.c (new_register_cache): Likewise.
9989 * remote-utils.c (look_up_one_symbol): Likewise.
9990 * server.c (queue_stop_reply): Likewise.
9991 (start_inferior): Likewise.
9992 (queue_stop_reply_callback): Likewise.
9993 (handle_target_event): Likewise.
9994 * spu-low.c (fetch_ppc_memory): Likewise.
9995 (store_ppc_memory): Likewise.
9996 * target.c (set_target_ops): Likewise.
9997 * thread-db.c (thread_db_load_search): Likewise.
9998 (try_thread_db_load_1): Likewise.
9999 * tracepoint.c (add_tracepoint): Likewise.
10000 (add_tracepoint_action): Likewise.
10001 (create_trace_state_variable): Likewise.
10002 (cmd_qtdpsrc): Likewise.
10003 (cmd_qtro): Likewise.
10004 (add_while_stepping_state): Likewise.
10005 * win32-low.c (child_add_thread): Likewise.
10006 (get_image_name): Likewise.
10008 2015-08-25 Yao Qi <yao.qi@linaro.org>
10010 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10012 2015-08-25 Yao Qi <yao.qi@linaro.org>
10014 * Makefile.in (aarch64-linux.o): New rule.
10015 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10017 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10018 (aarch64_init_debug_reg_state): Make it extern.
10019 (aarch64_linux_prepare_to_resume): Remove.
10021 2015-08-25 Yao Qi <yao.qi@linaro.org>
10023 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10024 lwp_arch_private_info and ptid_of_lwp.
10026 2015-08-25 Yao Qi <yao.qi@linaro.org>
10028 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10029 Find proc_info by find_process_pid. All callers updated.
10031 2015-08-25 Yao Qi <yao.qi@linaro.org>
10033 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10035 (debug_reg_change_callback): Remove.
10036 (aarch64_notify_debug_reg_change): Remove.
10038 2015-08-25 Yao Qi <yao.qi@linaro.org>
10040 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10041 Call current_lwp_ptid.
10043 2015-08-25 Yao Qi <yao.qi@linaro.org>
10045 * linux-aarch64-low.c (debug_reg_change_callback): Use
10048 2015-08-25 Yao Qi <yao.qi@linaro.org>
10050 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10052 2015-08-25 Yao Qi <yao.qi@linaro.org>
10054 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10056 2015-08-25 Yao Qi <yao.qi@linaro.org>
10058 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10061 2015-08-25 Yao Qi <yao.qi@linaro.org>
10063 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10065 (debug_reg_change_callback): Remove argument entry and add argument
10066 lwp. Remove local variable thread. Don't print thread id in the
10067 debugging output. Don't check whether pid of thread equals to pid.
10068 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10069 iterate_over_lwps instead find_inferior.
10071 2015-08-24 Pedro Alves <palves@redhat.com>
10073 * inferiors.c (get_first_process): New function.
10074 * inferiors.h (get_first_process): New declaration.
10075 * remote-utils.c (read_ptid): Default to the first process in the
10076 list, instead of to the current thread's process.
10078 2015-08-24 Pedro Alves <palves@redhat.com>
10080 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10081 * event-loop.c: Likewise.
10082 * remote-utils.c: Likewise.
10083 * tracepoint.c: Likewise.
10085 2015-08-24 Pedro Alves <palves@redhat.com>
10087 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10090 2015-08-21 Pedro Alves <palves@redhat.com>
10092 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10093 instead of literal 1.
10095 2015-08-21 Pedro Alves <palves@redhat.com>
10097 * tdesc.c (default_description): Explicitly zero-initialize.
10099 2015-08-21 Pedro Alves <palves@redhat.com>
10102 * inferiors.c (remove_thread): Discard any pending stop reply for
10104 * server.c (remove_all_on_match_pid): Rename to ...
10105 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10107 (discard_queued_stop_replies): Change parameter to a ptid. Now
10109 (handle_v_kill, kill_inferior_callback, captured_main)
10110 (process_serial_event): Adjust.
10111 * server.h (discard_queued_stop_replies): Declare.
10113 2015-08-21 Pedro Alves <palves@redhat.com>
10115 * linux-low.c (wait_for_sigstop): Always switch to no thread
10116 selected if the previously current thread dies.
10117 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10118 process instead of the current thread's.
10119 * remote-utils.c (input_interrupt): Don't check if there's no
10121 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10122 current thread to the general thread fails, error out.
10123 (handle_qxfer_auxv, handle_qxfer_libraries)
10124 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10125 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10126 (handle_query): Check if there's a thread selected instead of
10127 checking whether there's any thread in the thread list.
10128 (handle_qxfer_threads, handle_qxfer_btrace)
10129 (handle_qxfer_btrace_conf): Don't error out early if there's no
10130 thread in the thread list.
10131 (handle_v_cont, myresume): Don't set the current thread to the
10133 (process_serial_event) <Hg handling>: Also set thread_id if the
10134 previous general thread is still alive.
10135 (process_serial_event) <g/G handling>: If setting the current
10136 thread to the general thread fails, error out.
10137 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10138 thread's lwp instead of the current thread's.
10139 * target.c (set_desired_thread): If the desired thread was not
10140 found, leave the current thread pointing to NULL. Return an int
10141 (boolean) indicating success.
10142 * target.h (set_desired_thread): Change return type to int.
10144 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10146 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10147 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10149 (ps_get_thread_area): New function.
10151 2015-08-19 Gary Benson <gbenson@redhat.com>
10153 * hostio.c (handle_pread): Do not attempt to read more data
10154 than hostio_reply_with_data can fit in a packet.
10156 2015-08-18 Joel Brobecker <brobecker@adacore.com>
10158 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10160 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10162 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10164 2015-08-06 Pedro Alves <palves@redhat.com>
10166 * tracepoint.c (expr_eval_result): Now an int.
10168 2015-08-06 Pedro Alves <palves@redhat.com>
10170 * gdbthread.h (struct regcache): Forward declare.
10171 (struct thread_info) <regcache_data>: Now a struct regcache
10173 * inferiors.c (inferior_regcache_data)
10174 (set_inferior_regcache_data): Now work with struct regcache
10176 * inferiors.h (struct regcache): Forward declare.
10177 (inferior_regcache_data, set_inferior_regcache_data): Now work
10178 with struct regcache pointers.
10179 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10180 (free_register_cache_thread): Remove struct regcache pointer
10183 2015-08-06 Pedro Alves <palves@redhat.com>
10185 * server.c (captured_main): On error, print the exception message
10186 to stderr, and if run_once is set, throw a quit.
10188 2015-08-06 Pedro Alves <palves@redhat.com>
10190 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10191 the current thread.
10193 2015-08-06 Pedro Alves <palves@redhat.com>
10195 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10196 reading beyond the passed in buffer length.
10198 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10200 * tracepoint.c (symbol_list) <required>: Remove.
10202 2015-08-06 Pedro Alves <palves@redhat.com>
10204 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10205 count if stopping and suspending threads.
10206 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10207 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10208 (linux_detach): Complete an ongoing step-over.
10209 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10211 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10212 (linux_wait_1): If passing a signal to the inferior after
10213 finishing a step-over, unsuspend and re-resume all lwps. If we
10214 see a single-step event but the thread should be continuing, don't
10215 pass the trap to gdb.
10216 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10217 internal_error instead of gdb_assert.
10218 (enqueue_pending_signal): New function.
10219 (check_ptrace_stopped_lwp_gone): Add debug output.
10220 (start_step_over): Use internal_error instead of gdb_assert.
10221 (complete_ongoing_step_over): New function.
10222 (linux_resume_one_thread): Don't resume a suspended thread.
10223 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10226 2015-08-06 Pedro Alves <palves@redhat.com>
10228 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10229 (linux_thread_alive): Use lwp_is_marked_dead.
10230 (extended_event_reported): Delete.
10231 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10232 instead of extended_event_reported.
10233 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10235 (lwp_is_marked_dead): New function.
10236 (lwp_running): Use lwp_is_marked_dead.
10237 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10240 2015-08-06 Pedro Alves <palves@redhat.com>
10242 * linux-low.c (linux_wait_1): Move fork event output out of the
10243 !report_to_gdb check. Pass event_child->waitstatus to
10244 target_waitstatus_to_string instead of ourstatus.
10246 2015-08-04 Yao Qi <yao.qi@linaro.org>
10248 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10249 if current_thread is 32 bit.
10251 2015-08-04 Yao Qi <yao.qi@linaro.org>
10253 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10254 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10255 * server.c (extended_protocol): Remove "static".
10256 * server.h (extended_protocol): Declare it.
10258 2015-08-04 Yao Qi <yao.qi@linaro.org>
10260 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10261 both aarch64 and aarch32.
10262 (aarch64_set_pc): Likewise.
10264 2015-08-04 Yao Qi <yao.qi@linaro.org>
10266 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10267 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10268 arm-with-neon.xml to srv_xmlfiles.
10269 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10270 (is_64bit_tdesc): New function.
10271 (aarch64_linux_read_description): New function.
10272 (aarch64_arch_setup): Call aarch64_linux_read_description.
10273 (regs_info): Rename to regs_info_aarch64.
10274 (aarch64_regs_info): Return right regs_info.
10275 (initialize_low_arch): Call initialize_low_arch_aarch32.
10277 2015-08-04 Yao Qi <yao.qi@linaro.org>
10279 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10280 * linux-aarch32-low.c: New file.
10281 * linux-aarch32-low.h: New file.
10282 * linux-arm-low.c (arm_fill_gregset): Move it to
10283 linux-aarch32-low.c.
10284 (arm_store_gregset): Likewise.
10285 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10286 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10287 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10288 (regs_info): Rename to regs_info_arm.
10289 (arm_regs_info): Return regs_info_aarch32 if
10290 have_ptrace_getregset is 1 and target description is
10291 arm_with_neon or arm_with_vfpv3.
10292 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10293 Call initialize_low_arch_aarch32 instead.
10295 2015-08-04 Yao Qi <yao.qi@linaro.org>
10297 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10298 * linux-low.c: ... here.
10299 * linux-low.h (have_ptrace_getregset): Declare it.
10301 2015-08-04 Pedro Alves <palves@redhat.com>
10303 * thread-db.c (struct thread_db): Use new typedefs.
10304 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10306 (disable_thread_event_reporting): Cast result of dlsym to
10307 destination function pointer type.
10308 (thread_db_mourn): Use td_ta_delete_ftype.
10310 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10312 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10314 (CDX_BREAKPOINT): Define for R2.
10315 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10316 (the_low_target): Add comments.
10318 2015-07-30 Yao Qi <yao.qi@linaro.org>
10320 * linux-arm-low.c (arm_hwcap): Remove it.
10321 (arm_read_description): New local variable arm_hwcap. Don't
10322 set arm_hwcap to zero.
10324 2015-07-30 Yao Qi <yao.qi@linaro.org>
10326 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10327 Use regcache->tdesc instead.
10328 (arm_store_wmmxregset): Likewise.
10329 (arm_fill_vfpregset): Likewise.
10330 (arm_store_vfpregset): Likewise.
10332 2015-07-30 Yao Qi <yao.qi@linaro.org>
10334 * linux-arm-low.c: Include arch/arm.h.
10335 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10336 (arm_store_gregset): Likewise.
10338 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10340 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10341 ptrace's 4th parameter.
10343 2015-07-27 Yao Qi <yao.qi@linaro.org>
10345 * configure.srv (case aarch64*-*-linux*): Don't set
10348 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10350 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10352 * linux-arm-low.c: Likewise.
10353 * linux-cris-low.c: Likewise.
10354 * linux-crisv32-low.c: Likewise.
10355 * linux-low.c: Likewise.
10356 * linux-m68k-low.c: Likewise.
10357 * linux-mips-low.c: Likewise.
10358 * linux-nios2-low.c: Likewise.
10359 * linux-s390-low.c: Likewise.
10360 * linux-sparc-low.c: Likewise.
10361 * linux-tic6x-low.c: Likewise.
10362 * linux-tile-low.c: Likewise.
10363 * linux-x86-low.c: Likewise.
10365 2015-07-24 Pedro Alves <palves@redhat.com>
10367 * config.in: Regenerate.
10368 * configure: Regenerate.
10370 2015-07-24 Pedro Alves <palves@redhat.com>
10372 * acinclude.m4: Include ../ptrace.m4.
10373 * configure.ac: Call GDB_AC_PTRACE.
10374 * config.in, configure: Regenerate.
10376 2015-07-24 Yao Qi <yao.qi@linaro.org>
10378 * linux-low.c (linux_create_inferior): Remove setting to
10379 proc->priv->new_inferior.
10380 (linux_attach): Likewise.
10381 (linux_low_filter_event): Likewise.
10382 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10384 2015-07-24 Yao Qi <yao.qi@linaro.org>
10386 * linux-low.c (linux_arch_setup): New function.
10387 (linux_low_filter_event): If proc->tdesc is NULL and
10388 proc->attached is true, call the_low_target.arch_setup.
10389 Otherwise, keep status pending, and return.
10390 (linux_resume_one_lwp_throw): Don't call get_pc if
10391 thread->while_stepping isn't NULL. Don't call
10392 get_thread_regcache if proc->tdesc is NULL.
10393 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10394 (linux_target_ops): Install arch_setup.
10395 * server.c (start_inferior): Call the_target->arch_setup.
10396 * target.h (struct target_ops) <arch_setup>: New field.
10397 (target_arch_setup): New marco.
10398 * lynx-low.c (lynx_target_ops): Update.
10399 * nto-low.c (nto_target_ops): Update.
10400 * spu-low.c (spu_target_ops): Update.
10401 * win32-low.c (win32_target_ops): Update.
10403 2015-07-24 Yao Qi <yao.qi@linaro.org>
10405 * linux-low.c (linux_add_process): Don't set
10406 proc->priv->new_inferior.
10407 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10408 (linux_attach): Likewise.
10410 2015-07-24 Yao Qi <yao.qi@linaro.org>
10412 * server.c (start_inferior): Code refactor.
10414 2015-07-24 Yao Qi <yao.qi@linaro.org>
10416 * server.c (process_serial_event): Set general_thread.
10418 2015-07-21 Yao Qi <yao.qi@linaro.org>
10420 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10421 aarch64_linux_get_debug_reg_capacity.
10423 2015-07-17 Yao Qi <yao.qi@linaro.org>
10425 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10426 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10427 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10428 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10429 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10430 (AARCH64_HWP_ALIGNMENT): Likewise.
10431 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10432 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10433 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10434 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10435 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10436 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10437 (struct aarch64_debug_reg_state): Likewise.
10438 (struct arch_lwp_info): Likewise.
10439 (aarch64_align_watchpoint): Likewise.
10440 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10441 (aarch64_watchpoint_length): Likewise.
10442 (aarch64_point_encode_ctrl_reg): Likewise
10443 (aarch64_point_is_aligned): Likewise.
10444 (aarch64_align_watchpoint): Likewise.
10445 (aarch64_linux_set_debug_regs):
10446 (aarch64_dr_state_insert_one_point): Likewise.
10447 (aarch64_dr_state_remove_one_point): Likewise.
10448 (aarch64_handle_breakpoint): Likewise.
10449 (aarch64_handle_aligned_watchpoint): Likewise.
10450 (aarch64_handle_unaligned_watchpoint): Likewise.
10451 (aarch64_handle_watchpoint): Likewise.
10453 2015-07-17 Yao Qi <yao.qi@linaro.org>
10455 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10456 and don't aarch64_get_debug_reg_state. All callers update.
10457 (aarch64_handle_aligned_watchpoint): Likewise.
10458 (aarch64_handle_unaligned_watchpoint): Likewise.
10459 (aarch64_handle_watchpoint): Likewise.
10460 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10461 (aarch64_remove_point): Likewise.
10463 2015-07-17 Yao Qi <yao.qi@linaro.org>
10465 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10467 (aarch64_handle_unaligned_watchpoint): Likewise.
10469 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10471 Revert the previous 3 commits:
10472 Move gdb_regex* to common/
10473 Move linux_find_memory_regions_full & co.
10474 gdbserver build-id attribute generator
10476 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10477 Jan Kratochvil <jan.kratochvil@redhat.com>
10479 gdbserver build-id attribute generator.
10480 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10481 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10482 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10484 (get_dynamic): Use find_pdhr to traverse program headers.
10485 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10486 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10487 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10488 (get_hex_build_id): New.
10489 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10490 to reply XML document.
10492 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10493 Jan Kratochvil <jan.kratochvil@redhat.com>
10495 * target.c: Include target/target-utils.h and fcntl.h.
10496 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10497 (target_fileio_read_stralloc): New functions.
10499 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10501 * Makefile.in (OBS): Add gdb_regex.o.
10502 (gdb_regex.o): New.
10503 * config.in: Rebuilt.
10504 * configure: Rebuilt.
10506 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10507 Jan Kratochvil <jan.kratochvil@redhat.com>
10509 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10510 * Makefile.in (OBS): Add target-utils.o.
10511 (linux-maps.o, target-utils.o): New.
10512 * configure.srv (srv_linux_obj): Add linux-maps.o.
10514 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10516 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10517 function, return 1.
10518 (the_low_target): Install it.
10520 2015-07-14 Pedro Alves <palves@redhat.com>
10522 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10523 Instead, ignore ECHILD, and throw an error for other errnos.
10525 2015-07-10 Pedro Alves <palves@redhat.com>
10527 * event-loop.c (struct callback_event) <data>: Change type to
10528 gdb_client_data instance instead of gdb_client_data pointer.
10529 (append_callback_event): Adjust.
10531 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10533 * linux-aarch64-low.c: Add comments for each linux_target_ops
10534 method. Remove comments already covered in target_ops and
10535 linux_target_ops definitions.
10536 (the_low_target): Add comments for each unimplemented method.
10538 2015-07-09 Yao Qi <yao.qi@linaro.org>
10540 * linux-aarch64-low.c (aarch64_regmap): Remove.
10541 (aarch64_usrregs_info): Remove.
10542 (regs_info): Set field usrregs to NULL.
10544 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10546 * linux-low.c: Include "rsp-low.h"
10547 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10548 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10549 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10550 (handle_btrace_enable_pt): New.
10551 (handle_btrace_general_set): Support "pt".
10552 (handle_btrace_conf_general_set): Support "pt:size".
10554 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10556 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10559 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10561 * linux-aarch64-low.c: Remove comment about endianness.
10562 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10563 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10566 2015-06-24 Gary Benson <gbenson@redhat.com>
10568 * linux-i386-ipa.c (stdint.h): Do not include.
10569 * lynx-i386-low.c (stdint.h): Likewise.
10570 * lynx-ppc-low.c (stdint.h): Likewise.
10571 * mem-break.c (stdint.h): Likewise.
10572 * thread-db.c (stdint.h): Likewise.
10573 * tracepoint.c (stdint.h): Likewise.
10574 * win32-low.c (stdint.h): Likewise.
10576 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10578 * server.c (write_qxfer_response): Update call to
10579 remote_escape_output.
10581 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10582 Jan Kratochvil <jan.kratochvil@redhat.com>
10584 Merge multiple hex conversions.
10585 * gdbreplay.c (tohex): Rename to 'fromhex'.
10586 (logchar): Use fromhex.
10588 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10590 * server.c (handle_qxfer_libraries): Set `version' attribute for
10593 2015-06-10 Gary Benson <gbenson@redhat.com>
10595 * target.h (struct target_ops) <multifs_open>: New field.
10596 <multifs_unlink>: Likewise.
10597 <multifs_readlink>: Likewise.
10598 * linux-low.c (nat/linux-namespaces.h): New include.
10599 (linux_target_ops): Initialize the_target->multifs_open,
10600 the_target->multifs_unlink and the_target->multifs_readlink.
10601 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10602 * hostio.c (hostio_fs_pid): New static variable.
10603 (hostio_handle_new_gdb_connection): New function.
10604 (handle_setfs): Likewise.
10605 (handle_open): Use the_target->multifs_open as appropriate.
10606 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10607 (handle_readlink): Use the_target->multifs_readlink as
10609 (handle_vFile): Handle vFile:setfs packets.
10610 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10611 after target_handle_new_gdb_connection.
10613 2015-06-10 Gary Benson <gbenson@redhat.com>
10615 * configure.ac (AC_CHECK_FUNCS): Add setns.
10616 * config.in: Regenerate.
10617 * configure: Likewise.
10618 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10619 (linux-namespaces.o): New rule.
10620 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10622 2015-06-09 Gary Benson <gbenson@redhat.com>
10624 * hostio.c (handle_open): Process mode argument with
10625 fileio_to_host_mode.
10627 2015-06-01 Yao Qi <yao.qi@linaro.org>
10629 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10630 * linux-x86-low.c: Likewise.
10632 2015-05-28 Don Breazeal <donb@codesourcery.com>
10634 * linux-low.c (handle_extended_wait): Initialize
10635 thread_info.last_resume_kind for new fork children.
10637 2015-05-15 Pedro Alves <palves@redhat.com>
10639 * target.h (target_handle_new_gdb_connection): Rewrite using if
10640 wrapped in do/while.
10642 2015-05-14 Joel Brobecker <brobecker@adacore.com>
10644 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10645 * configure, config.in: Regenerate.
10646 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10649 2015-05-12 Don Breazeal <donb@codesourcery.com>
10651 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10652 PTRACE_EVENT_VFORK_DONE.
10653 (linux_low_ptrace_options, extended_event_reported): Add vfork
10655 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10656 and "vforkdone" for RSP 'T' Stop Reply Packet.
10657 * server.h (report_vfork_events): Declare
10660 2015-05-12 Don Breazeal <donb@codesourcery.com>
10662 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10663 (the_low_target) <new_fork>: Initialize new member.
10664 * linux-arm-low.c (arm_new_fork): New function.
10665 (the_low_target) <new_fork>: Initialize new member.
10666 * linux-low.c (handle_extended_wait): Call new target function
10668 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10669 * linux-mips-low.c (mips_add_watchpoint): New function
10670 extracted from mips_insert_point.
10671 (the_low_target) <new_fork>: Initialize new member.
10672 (mips_linux_new_fork): New function.
10673 (mips_insert_point): Call mips_add_watchpoint.
10674 * linux-x86-low.c (x86_linux_new_fork): New function.
10675 (the_low_target) <new_fork>: Initialize new member.
10677 2015-05-12 Don Breazeal <donb@codesourcery.com>
10679 * linux-low.c (handle_extended_wait): Implement return value,
10680 rename argument 'event_child' to 'event_lwp', handle
10681 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10682 (linux_low_ptrace_options): New function.
10683 (linux_low_filter_event): Call linux_low_ptrace_options,
10684 use different argument fo linux_enable_event_reporting,
10685 use return value from handle_extended_wait.
10686 (extended_event_reported): New function.
10687 (linux_wait_1): Call extended_event_reported and set
10688 status to report fork events.
10689 (linux_write_memory): Add pid to debug message.
10690 (reset_lwp_ptrace_options_callback): New function.
10691 (linux_handle_new_gdb_connection): New function.
10692 (linux_target_ops): Initialize new structure member.
10693 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10694 * lynx-low.c: Initialize new structure member.
10695 * remote-utils.c (prepare_resume_reply): Implement stop reason
10696 "fork" for "T" stop message.
10697 * server.c (handle_query): Call handle_new_gdb_connection.
10698 * server.h (report_fork_events): Declare global flag.
10699 * target.h (struct target_ops) <handle_new_gdb_connection>:
10701 (target_handle_new_gdb_connection): New macro.
10702 * win32-low.c: Initialize new structure member.
10704 2015-05-12 Don Breazeal <donb@codesourcery.com>
10706 * mem-break.c (APPEND_TO_LIST): Define macro.
10707 (clone_agent_expr): New function.
10708 (clone_one_breakpoint): New function.
10709 (clone_all_breakpoints): New function.
10710 * mem-break.h: Declare new functions.
10712 2015-05-12 Don Breazeal <donb@codesourcery.com>
10714 * linux-low.c (linux_supports_fork_events): New function.
10715 (linux_supports_vfork_events): New function.
10716 (linux_target_ops): Initialize new structure members.
10717 (initialize_low): Call linux_check_ptrace_features.
10718 * lynx-low.c (lynx_target_ops): Initialize new structure
10720 * server.c (report_fork_events, report_vfork_events):
10722 (handle_query): Add new features to qSupported packet and
10724 (captured_main): Initialize new global variables.
10725 * target.h (struct target_ops) <supports_fork_events>:
10727 <supports_vfork_events>: New member.
10728 (target_supports_fork_events): New macro.
10729 (target_supports_vfork_events): New macro.
10730 * win32-low.c (win32_target_ops): Initialize new structure
10733 2015-05-12 Gary Benson <gbenson@redhat.com>
10735 * server.c (handle_qxfer_exec_file): Use current process
10738 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10740 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10741 Remove HAVE_PTRACE_GETREGS conditionals.
10742 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10743 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10745 2015-05-08 Yao Qi <yao.qi@linaro.org>
10747 * linux-low.c (linux_supports_conditional_breakpoints): New
10749 (linux_target_ops): Install new target method.
10750 * lynx-low.c (lynx_target_ops): Install NULL hook for
10751 supports_conditional_breakpoints.
10752 * nto-low.c (nto_target_ops): Likewise.
10753 * spu-low.c (spu_target_ops): Likewise.
10754 * win32-low.c (win32_target_ops): Likewise.
10755 * server.c (handle_query): Check
10756 target_supports_conditional_breakpoints.
10757 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10759 (target_supports_conditional_breakpoints): New macro.
10761 2015-05-06 Pedro Alves <palves@redhat.com>
10764 * server.c (start_inferior): If the process exits, mourn it.
10766 2015-04-21 Gary Benson <gbenson@redhat.com>
10768 * hostio.c (fileio_open_flags_to_host): Factored out to
10769 fileio_to_host_openflags in common/fileio.c. Single use
10772 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10774 * linux-xtensa-low.c (xtensa_fill_gregset)
10775 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10778 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10780 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10781 (regs_info): Replace usrregs pointer with NULL.
10783 2015-04-17 Gary Benson <gbenson@redhat.com>
10785 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10786 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10787 * server.c (handle_qxfer_exec_file): New function.
10788 (qxfer_packets): Add exec-file entry.
10789 (handle_query): Report qXfer:exec-file:read as supported packet.
10791 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10793 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10795 2015-04-09 Gary Benson <gbenson@redhat.com>
10797 * hostio-errno.c (errno_to_fileio_error): Remove function.
10798 Update caller to use remote_fileio_to_fio_error.
10800 2015-04-09 Yao Qi <yao.qi@linaro.org>
10802 * linux-low.c (linux_insert_point): Call
10803 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10804 (linux_remove_point): Call remove_memory_breakpoint if type is
10806 * linux-x86-low.c (x86_insert_point): Don't call
10807 insert_memory_breakpoint.
10808 (x86_remove_point): Don't call remove_memory_breakpoint.
10810 2015-04-01 Pedro Alves <palves@redhat.com>
10811 Cleber Rosa <crosa@redhat.com>
10813 * server.c (gdbserver_usage): Reorganize and extend the usage
10816 2015-03-24 Pedro Alves <palves@redhat.com>
10818 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10819 output. Also dump TRAP_TRACE.
10820 (linux_low_filter_event): In debug output, distinguish a
10821 resume_stop SIGSTOP from a delayed SIGSTOP.
10823 2015-03-24 Gary Benson <gbenson@redhat.com>
10825 * linux-x86-low.c (x86_linux_new_thread): Moved to
10827 (x86_linux_prepare_to_resume): Likewise.
10829 2015-03-24 Gary Benson <gbenson@redhat.com>
10831 * Makefile.in (x86-linux-dregs.o): New rule.
10832 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10833 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10834 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10835 (x86_linux_dr_get): Likewise.
10836 (x86_linux_dr_set): Likewise.
10837 (update_debug_registers_callback): Likewise.
10838 (x86_linux_dr_set_addr): Likewise.
10839 (x86_linux_dr_get_addr): Likewise.
10840 (x86_linux_dr_set_control): Likewise.
10841 (x86_linux_dr_get_control): Likewise.
10842 (x86_linux_dr_get_status): Likewise.
10843 (x86_linux_update_debug_registers): Likewise.
10845 2015-03-24 Gary Benson <gbenson@redhat.com>
10847 * linux-x86-low.c (x86_linux_update_debug_registers):
10848 New function, factored out from...
10849 (x86_linux_prepare_to_resume): ...this.
10851 2015-03-24 Gary Benson <gbenson@redhat.com>
10853 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10854 (x86_linux_dr_set): Likewise.
10855 (update_debug_registers_callback): Likewise.
10856 (x86_linux_dr_set_addr): Likewise.
10857 (x86_linux_dr_get_addr): Likewise.
10858 (x86_linux_dr_set_control): Likewise.
10859 (x86_linux_dr_get_control): Likewise.
10860 (x86_linux_dr_get_status): Likewise.
10861 (x86_linux_prepare_to_resume): Likewise.
10863 2015-03-24 Gary Benson <gbenson@redhat.com>
10865 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10866 Use perror_with_name. Pass string through gettext.
10867 (x86_linux_dr_set): Likewise.
10869 2015-03-24 Gary Benson <gbenson@redhat.com>
10871 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10872 (x86_linux_dr_set_addr): ...this.
10873 (x86_dr_low_get_addr): Rename to...
10874 (x86_linux_dr_get_addr): ...this.
10875 (x86_dr_low_set_control): Rename to...
10876 (x86_linux_dr_set_control): ...this.
10877 (x86_dr_low_get_control): Rename to...
10878 (x86_linux_dr_get_control): ...this.
10879 (x86_dr_low_get_status): Rename to...
10880 (x86_linux_dr_get_status): ...this.
10881 (x86_dr_low): Update with new function names.
10883 2015-03-24 Gary Benson <gbenson@redhat.com>
10885 * Makefile.in (x86-linux.o): New rule.
10886 * configure.srv: Add x86-linux.o to relevant targets.
10887 * linux-low.c (lwp_set_arch_private_info): New function.
10888 (lwp_arch_private_info): Likewise.
10889 * linux-x86-low.c: Include nat/x86-linux.h.
10890 (arch_lwp_info): Removed structure.
10891 (update_debug_registers_callback):
10892 Use lwp_set_debug_registers_changed.
10893 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10894 and lwp_set_debug_registers_changed.
10895 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10897 2015-03-24 Gary Benson <gbenson@redhat.com>
10899 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10900 * linux-arm-low.c (arm_new_thread): Likewise.
10901 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10902 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10903 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10904 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10906 2015-03-24 Gary Benson <gbenson@redhat.com>
10908 * linux-low.c (ptid_of_lwp): New function.
10909 (lwp_is_stopped): Likewise.
10910 (lwp_stop_reason): Likewise.
10911 * linux-x86-low.c (update_debug_registers_callback):
10912 Use lwp_is_stopped.
10913 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10916 2015-03-24 Gary Benson <gbenson@redhat.com>
10918 * linux-low.h (linux_stop_lwp): Remove declaration.
10920 2015-03-24 Gary Benson <gbenson@redhat.com>
10922 * linux-low.h: Include nat/linux-nat.h.
10923 * linux-low.c (iterate_over_lwps_args): New structure.
10924 (iterate_over_lwps_filter): New function.
10925 (iterate_over_lwps): Likewise.
10926 * linux-x86-low.c (update_debug_registers_callback):
10927 Update signature to what iterate_over_lwps expects.
10928 Remove PID check that iterate_over_lwps now performs.
10929 (x86_dr_low_set_addr): Use iterate_over_lwps.
10930 (x86_dr_low_set_control): Likewise.
10932 2015-03-24 Gary Benson <gbenson@redhat.com>
10934 * linux-x86-low.c (x86_debug_reg_state): New function.
10935 (x86_linux_prepare_to_resume): Use the above.
10937 2015-03-24 Gary Benson <gbenson@redhat.com>
10939 * linux-low.c (current_lwp_ptid): New function.
10940 * linux-x86-low.c: Include nat/linux-nat.h.
10941 (x86_dr_low_get_addr): Use current_lwp_ptid.
10942 (x86_dr_low_get_control): Likewise.
10943 (x86_dr_low_get_status): Likewise.
10945 2015-03-20 Pedro Alves <palves@redhat.com>
10947 * tracepoint.c (cmd_qtstatus): Make "str" const.
10949 2015-03-20 Pedro Alves <palves@redhat.com>
10951 * server.c (handle_general_set): Make "req_str" const.
10953 2015-03-19 Pedro Alves <palves@redhat.com>
10955 * linux-low.c (linux_resume_one_lwp): Rename to ...
10956 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
10957 instead call perror_with_name.
10958 (check_ptrace_stopped_lwp_gone): New function.
10959 (linux_resume_one_lwp): Reimplement as wrapper around
10960 linux_resume_one_lwp_throw that swallows errors if the LWP is
10963 2015-03-19 Pedro Alves <palves@redhat.com>
10965 * linux-low.c (count_events_callback, select_event_lwp_callback):
10966 No longer check whether the thread has resume_stop as last resume
10969 2015-03-19 Pedro Alves <palves@redhat.com>
10971 * linux-low.c (count_events_callback, select_event_lwp_callback):
10972 Use the lwp's status_pending_p field, not the thread's.
10974 2015-03-19 Pedro Alves <palves@redhat.com>
10976 * linux-low.c (select_event_lwp_callback): Update comments to
10977 no longer mention SIGTRAP.
10979 2015-03-18 Gary Benson <gbenson@redhat.com>
10981 * server.c (handle_query): Do not report vFile:fstat as supported.
10983 2015-03-11 Gary Benson <gbenson@redhat.com>
10985 * hostio.c (sys/types.h): New include.
10986 (sys/stat.h): Likewise.
10987 (common-remote-fileio.h): Likewise.
10988 (handle_fstat): New function.
10989 (handle_vFile): Handle vFile:fstat packets.
10991 2015-03-11 Gary Benson <gbenson@redhat.com>
10993 * configure.ac (AC_CHECK_MEMBERS): Add checks for
10994 struct stat.st_blocks and struct stat.st_blksize.
10995 * configure: Regenerate.
10996 * config.in: Likewise.
10997 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
10998 (OBS): Add common-remote-fileio.o.
10999 (common-remote-fileio.o): New rule.
11001 2015-03-09 Pedro Alves <palves@redhat.com>
11003 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11004 'struct sockaddr' pointer in 'accept' call.
11006 2015-03-09 Pedro Alves <palves@redhat.com>
11009 2015-03-07 Pedro Alves <palves@redhat.com>
11010 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11011 or <winsock2.h> here. Instead include "gdb_socket.h".
11012 (remote_open): Use union gdb_sockaddr_u.
11013 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11014 or <winsock2.h> here. Instead include "gdb_socket.h".
11015 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11016 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11018 (init_named_socket, gdb_agent_helper_thread): Use union
11021 2015-03-07 Pedro Alves <palves@redhat.com>
11023 * configure.ac (build_warnings): Move
11024 -Wdeclaration-after-statement to the C-specific set.
11025 * configure: Regenerate.
11027 2015-03-07 Pedro Alves <palves@redhat.com>
11029 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11030 or <winsock2.h> here. Instead include "gdb_socket.h".
11031 (remote_open): Use union gdb_sockaddr_u.
11032 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11033 or <winsock2.h> here. Instead include "gdb_socket.h".
11034 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11035 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11037 (init_named_socket, gdb_agent_helper_thread): Use union
11040 2015-03-07 Pedro Alves <palves@redhat.com>
11042 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11045 2015-03-06 Yao Qi <yao.qi@linaro.org>
11047 * linux-aarch64-low.c (aarch64_insert_point): Use
11048 show_debug_regs as a boolean.
11049 (aarch64_remove_point): Likewise.
11051 2015-03-05 Pedro Alves <palves@redhat.com>
11053 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11054 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11055 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11056 * nto-low.c (nto_target_ops): Likewise.
11057 * spu-low.c (spu_target_ops): Likewise.
11058 * win32-low.c (win32_target_ops): Likewise.
11060 2015-03-04 Pedro Alves <palves@redhat.com>
11062 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
11063 Decide whether a breakpoint triggered based on the SIGTRAP's
11065 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11066 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
11067 (linux_low_filter_event): Check for breakpoints before checking
11069 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11071 (linux_stopped_by_sw_breakpoint)
11072 (linux_supports_stopped_by_sw_breakpoint)
11073 (linux_stopped_by_hw_breakpoint)
11074 (linux_supports_stopped_by_hw_breakpoint): New functions.
11075 (linux_target_ops): Install new target methods.
11077 2015-03-04 Pedro Alves <palves@redhat.com>
11079 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11080 * server.c (swbreak_feature, hwbreak_feature): New globals.
11081 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11082 (captured_main): Clear swbreak_feature and hwbreak_feature.
11083 * server.h (swbreak_feature, hwbreak_feature): Declare.
11084 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11085 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11086 supports_stopped_by_hw_breakpoint>: New fields.
11087 (target_supports_stopped_by_sw_breakpoint)
11088 (target_stopped_by_sw_breakpoint)
11089 (target_supports_stopped_by_hw_breakpoint)
11090 (target_stopped_by_hw_breakpoint): Declare.
11092 2015-03-04 Pedro Alves <palves@redhat.com>
11094 enum lwp_stop_reason -> enum target_stop_reason
11095 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11096 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11097 (linux_wait_1, stuck_in_jump_pad_callback)
11098 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11099 (linux_stopped_by_watchpoint):
11100 * linux-low.h (enum lwp_stop_reason): Delete.
11101 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11102 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11104 2015-03-04 Yao Qi <yao.qi@linaro.org>
11106 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11108 2015-03-03 Gary Benson <gbenson@redhat.com>
11110 * hostio.c (handle_vFile): Fix prefix lengths.
11112 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11114 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11117 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11119 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11120 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11121 (clean): Add "rm -f" for above C files.
11122 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11123 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11124 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11125 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11126 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11127 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11128 (init_registers_s390x_vx_linux64)
11129 (init_registers_s390x_tevx_linux64)
11130 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11131 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11133 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11134 (s390_store_vxrs_high): New functions.
11135 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11137 (s390_arch_setup): Add logic for selecting one of the new target
11138 descriptions. Activate the new vector regsets if applicable.
11139 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11140 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11141 and init_registers_s390x_tevx_linux64.
11143 2015-03-01 Pedro Alves <palves@redhat.com>
11145 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11148 2015-02-27 Pedro Alves <palves@redhat.com>
11150 * linux-x86-low.c (u_debugreg_offset): New function.
11151 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11153 2015-02-27 Pedro Alves <palves@redhat.com>
11155 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11156 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11157 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11158 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11159 (ps_lsetfpregs, ps_getpid)
11160 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11161 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11162 (ps_lsetxregs, ps_plog): Declare.
11164 2015-02-27 Pedro Alves <palves@redhat.com>
11166 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11167 IP_AGENT_EXPORT_FUNC.
11168 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11169 IP_AGENT_EXPORT_FUNC.
11170 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11171 (IP_AGENT_EXPORT): Delete.
11172 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11173 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11174 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11175 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11176 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11177 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11178 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11179 (traceframe_read_count, traceframe_write_count)
11180 (traceframes_created, trace_state_variables, get_raw_reg)
11181 (get_trace_state_variable_value, set_trace_state_variable_value)
11182 (ust_loaded, helper_thread_id, cmd_buf): Use
11183 IPA_SYM_EXPORTED_NAME.
11184 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11185 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11186 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11187 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11188 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11189 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11190 EXTERN_C_PUSH/EXTERN_C_POP.
11191 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11192 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11193 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11194 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11195 (traceframe_write_count, traceframe_read_count)
11196 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11197 (about_to_request_buffer_space, get_trace_state_variable_value)
11198 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11199 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11200 EXTERN_C_PUSH/EXTERN_C_POP.
11201 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11202 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11203 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11204 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11205 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11206 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11207 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11208 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11210 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11211 (IP_AGENT_EXPORT_VAR_DECL): Define.
11212 (tracing): Declare.
11213 (gdb_agent_get_raw_reg): Declare.
11215 2015-02-27 Tom Tromey <tromey@redhat.com>
11216 Pedro Alves <palves@redhat.com>
11218 Rename symbols whose names are reserved C++ keywords throughout.
11220 2015-02-27 Pedro Alves <palves@redhat.com>
11222 * Makefile.in (COMPILER): New, get it from autoconf.
11223 (CXX): Get from autoconf instead.
11224 (COMPILE.pre): Use COMPILER.
11225 (CC-LD): Rename to ...
11226 (CC_LD): ... this. Use COMPILER.
11227 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11228 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11229 * acinclude.m4: Include build-with-cxx.m4.
11230 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11231 Disable -Werror by default if building in C++ mode.
11232 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11233 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11234 the C++ compiler. Save/restore CXXFLAGS too.
11235 * configure: Regenerate.
11237 2015-02-27 Pedro Alves <palves@redhat.com>
11239 * acinclude.m4: Include libiberty.m4.
11240 * configure.ac: Call libiberty_INIT.
11241 * config.in, configure: Regenerate.
11243 2015-02-26 Pedro Alves <palves@redhat.com>
11245 * linux-low.c (linux_wait_1): When incrementing the PC past a
11246 program breakpoint always use the_low_target.breakpoint_len as
11247 increment, rather than the maximum between that and
11248 the_low_target.decr_pc_after_break.
11250 2015-02-23 Pedro Alves <palves@redhat.com>
11252 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11253 thread was doing a step-over; always adjust the PC if
11254 we stepped over a permanent breakpoint.
11255 (linux_wait_1): If we stepped over breakpoint that was on top of a
11256 permanent breakpoint, manually advance the PC past it.
11258 2015-02-23 Pedro Alves <palves@redhat.com>
11260 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11262 (x86_fill_gregset, x86_store_gregset): Use it when handling
11265 2015-02-20 Pedro Alves <palves@redhat.com>
11267 * thread-db.c: Include "nat/linux-procfs.h".
11268 (thread_db_init): Skip listing new threads if the kernel supports
11269 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11271 2015-02-20 Pedro Alves <palves@redhat.com>
11273 * linux-low.c (status_pending_p_callback): Use ptid_match.
11275 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11277 PR breakpoints/16812
11278 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11279 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11280 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11282 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11284 PR breakpoints/15956
11285 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11287 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11289 * linux-low.c (linux_low_btrace_conf): Print size.
11290 * server.c (handle_btrace_conf_general_set): New.
11291 (hanle_general_set): Call handle_btrace_conf_general_set.
11292 (handle_query): Report Qbtrace-conf:bts:size as supported.
11294 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11296 * linux-low.c (linux_low_enable_btrace): Update parameters.
11297 (linux_low_btrace_conf): New.
11298 (linux_target_ops)<to_btrace_conf>: Initialize.
11299 * server.c (current_btrace_conf): New.
11300 (handle_btrace_enable): Rename to ...
11301 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
11302 to target_enable_btrace. Update comment. Update users.
11303 (handle_qxfer_btrace_conf): New.
11304 (qxfer_packets): Add btrace-conf entry.
11305 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11306 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11307 (target_ops)<read_btrace_conf>: New.
11308 (target_enable_btrace): Update parameters.
11309 (target_read_btrace_conf): New.
11311 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11313 * server.c (handle_btrace_general_set): Remove call to
11314 target_supports_btrace.
11315 (supported_btrace_packets): New.
11316 (handle_query): Call supported_btrace_packets.
11317 * target.h: include btrace-common.h.
11318 (btrace_target_info): Removed.
11319 (supports_btrace, target_supports_btrace): Update parameters.
11321 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11323 * Makefile.in (SFILES): Add common/btrace-common.c.
11324 (OBS): Add common/btrace-common.o.
11325 (btrace-common.o): Add build rules.
11326 * linux-low: Include btrace-common.h.
11327 (linux_low_read_btrace): Use struct btrace_data. Call
11328 btrace_data_init and btrace_data_fini.
11330 2015-02-06 Pedro Alves <palves@redhat.com>
11332 * thread-db.c (find_new_threads_callback): Add debug output.
11334 2015-02-04 Pedro Alves <palves@redhat.com>
11336 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11337 (resume_stopped_resumed_lwps): New function.
11338 (linux_wait_for_event_filtered): Use it.
11340 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11342 * Makefile.in (SFILES): Add linux-personality.c.
11343 (linux-personality.o): New rule.
11344 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11345 list of objects to be built.
11346 * linux-low.c: Include nat/linux-personality.h.
11347 (linux_create_inferior): Remove code to disable address space
11348 randomization (moved to ../nat/linux-personality.c). Create
11349 cleanup to disable address space randomization.
11351 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11353 * Makefile.in (posix-strerror.o): New rule.
11354 (mingw-strerror.o): Likewise.
11355 * configure: Regenerated.
11356 * configure.ac: Source file ../common/common.host. Initialize new
11357 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11359 2015-01-14 Yao Qi <yao@codesourcery.com>
11361 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11362 (ppc-linux.o): New rule.
11363 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11364 * configure.ac: AC_CHECK_FUNCS(getauxval).
11365 * config.in: Re-generated.
11366 * configure: Re-generated.
11367 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11368 ppc64_64bit_inferior_p
11370 2015-01-14 Yao Qi <yao@codesourcery.com>
11372 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11373 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11374 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11375 (PT_ORIG_R3, PT_TRAP): Likewise.
11376 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11377 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11378 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11380 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11382 * i387-fp.c (i387_cache_to_xsave): In look over
11383 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11384 zmmh_low_space field by use of zmmh_high_space.
11386 2015-01-09 Pedro Alves <palves@redhat.com>
11388 * linux-low.c (step_over_bkpt): Move higher up in the file.
11389 (handle_extended_wait): Don't store the stop_pc here.
11390 (get_stop_pc): Adjust comments and rename to ...
11391 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11392 stopped for a software breakpoint or hardware breakpoint.
11393 (thread_still_has_status_pending_p): New function.
11394 (status_pending_p_callback): Use
11395 thread_still_has_status_pending_p. If the event is no longer
11396 interesting, resume the LWP.
11397 (handle_tracepoints): Add assert.
11398 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11399 (wstatus_maybe_breakpoint): New function.
11400 (cancel_breakpoint): Delete function.
11401 (check_stopped_by_watchpoint): New function, factored out from
11402 linux_low_filter_event.
11403 (lp_status_maybe_breakpoint): Delete function.
11404 (linux_low_filter_event): Remove filter_ptid argument.
11405 Leave thread group exits pending here. Store the LWP's stop PC.
11406 Always leave events pending.
11407 (linux_wait_for_event_filtered): Pull all events out of the
11408 kernel, and leave them all pending.
11409 (count_events_callback, select_event_lwp_callback): Consider all
11411 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11412 (select_event_lwp): Only give preference to the stepping LWP in
11413 all-stop mode. Adjust comments.
11414 (ignore_event): New function.
11415 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11416 references to cancel_breakpoints. Adjust to renames. Also give
11417 equal priority to all LWPs that have had events in non-stop mode.
11418 If reporting a software breakpoint event, unadjust the LWP's PC.
11419 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11420 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11422 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11423 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11424 (linux_stopped_by_watchpoint): Adjust.
11425 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11426 * linux-low.h (enum lwp_stop_reason): New.
11427 (struct lwp_info) <stop_pc>: Adjust comment.
11428 <stopped_by_watchpoint>: Delete field.
11429 <stop_reason>: New field.
11430 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11431 * mem-break.c (software_breakpoint_inserted_here)
11432 (hardware_breakpoint_inserted_here): New function.
11433 * mem-break.h (software_breakpoint_inserted_here)
11434 (hardware_breakpoint_inserted_here): Declare.
11435 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11436 (cancel_breakpoints): Delete.
11437 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11438 (upload_fast_traceframes): Remove references to
11439 cancel_breakpoints.
11441 2015-01-09 Pedro Alves <palves@redhat.com>
11443 * thread-db.c (find_new_threads_callback): Ignore thread if the
11444 kernel thread ID is -1.
11446 2015-01-09 Pedro Alves <palves@redhat.com>
11448 * linux-low.c (linux_attach_fail_reason_string): Move to
11449 nat/linux-ptrace.c, and rename.
11450 (linux_attach_lwp): Update comment.
11451 (attach_proc_task_lwp_callback): New function.
11452 (linux_attach): Adjust to rename and use
11453 linux_proc_attach_tgid_threads.
11454 (linux_attach_fail_reason_string): Delete declaration.
11456 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11458 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11459 * server.c (gdbserver_version): Likewise.
11461 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11463 * remote-utils.c: Include ctype.h.
11464 (input_interrupt): Explicitly handle the case when the char
11465 received is the NUL byte. Improve the printing of non-ASCII
11468 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11470 * linux-low.c (linux_low_filter_event): Update call to
11471 linux_enable_event_reporting following the addition of
11472 a new parameter to that function.
11474 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11477 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11478 (AARCH64_FPCR_REGNO): Likewise.
11479 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11480 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11481 (aarch64_store_fpregset): Likewise.
11483 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11485 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11486 Remove FIXME comment about assumption about N.
11488 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11490 * configure.ac: If large-file support is disabled in GDBserver,
11491 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11492 * configure: Regenerate.
11494 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11496 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11497 warning upon ENODATA from ptrace.
11498 * linux-s390-low.c (s390_store_tdb): New.
11499 (s390_regsets): Add regset for NT_S390_TDB.
11501 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11503 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11504 without a fill_function.
11505 * linux-s390-low.c (s390_fill_last_break): Remove.
11506 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11507 (s390_arch_setup): Use regset's size instead of fill_function for
11508 loop end condition.
11510 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11512 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11513 the regset's store function when ptrace returned an error.
11514 * regcache.c (get_thread_regcache): Invalidate register cache
11515 before fetching inferior's registers.
11517 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11519 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11520 while-loop as for-loop.
11521 (regsets_store_inferior_registers): Likewise.
11523 2014-11-28 Yao Qi <yao@codesourcery.com>
11525 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11526 * config.in, configure: Re-generate.
11527 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11530 2014-11-21 Yao Qi <yao@codesourcery.com>
11532 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11533 (AC_CHECK_HEADERS): Remove malloc.h.
11534 * configure: Re-generated.
11535 * config.in: Re-generated.
11536 * server.h: Don't include alloca.h and malloc.h.
11537 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11538 Don't include malloc.h.
11540 2014-11-17 Joel Brobecker <brobecker@adacore.com>
11542 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11543 corresponding ERRNO check in same block.
11545 2014-11-12 Pedro Alves <palves@redhat.com>
11547 * server.c (cont_thread): Update comment.
11548 (start_inferior, attach_inferior): No longer clear cont_thread.
11549 (handle_v_cont): No longer set cont_thread.
11550 (captured_main): Clear cont_thread each time a GDB connects.
11552 2014-11-12 Pedro Alves <palves@redhat.com>
11554 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11555 thread, and don't resume all threads if the Hc thread has exited.
11557 2014-11-12 Pedro Alves <palves@redhat.com>
11559 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11560 the process group instead of to a specific LWP.
11562 2014-10-15 Pedro Alves <palves@redhat.com>
11565 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11567 (arm_set_thread_context): Delete.
11568 (the_low_target): Adjust.
11569 * win32-i386-low.c (debug_registers_changed)
11570 (debug_registers_used): Delete.
11571 (update_debug_registers_callback): New function.
11572 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11573 needing to update their debug registers.
11574 (win32_get_current_dr): New function.
11575 (x86_dr_low_get_addr, x86_dr_low_get_control)
11576 (x86_dr_low_get_status): Fetch the debug register from the thread
11578 (i386_initial_stuff): Adjust.
11579 (i386_get_thread_context): Remove current_event parameter. Don't
11580 clear debug_registers_changed nor copy DR values to
11582 (i386_set_thread_context): Delete.
11583 (i386_prepare_to_resume): New function.
11584 (i386_thread_added): Mark the thread as needing to update irs
11586 (the_low_target): Remove i386_set_thread_context and install
11587 i386_prepare_to_resume.
11588 * win32-low.c (win32_get_thread_context): Adjust.
11589 (win32_set_thread_context): Use SetThreadContext
11591 (win32_prepare_to_resume): New function.
11592 (win32_require_context): New function, factored out from ...
11593 (thread_rec): ... this.
11594 (continue_one_thread): Call win32_prepare_to_resume on each thread
11595 we're about to continue.
11596 (win32_resume): Call win32_prepare_to_resume on the event thread.
11597 * win32-low.h (struct win32_thread_info)
11598 <debug_registers_changed>: New field.
11599 (struct win32_target_ops): Change prototype of set_thread_context,
11600 delete set_thread_context and add prepare_to_resume.
11601 (win32_require_context): New declaration.
11603 2014-10-08 Gary Benson <gbenson@redhat.com>
11605 * server.h: Do not include common-exceptions.h.
11607 2014-10-08 Gary Benson <gbenson@redhat.com>
11609 * server.h: Do not include cleanups.h.
11611 2014-09-30 James Hogan <james.hogan@imgtec.com>
11613 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11614 mips64-dsp-linux.c.
11616 2014-09-23 Yao Qi <yao@codesourcery.com>
11618 * linux-low.c (lp_status_maybe_breakpoint): New function.
11619 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11620 (count_events_callback): Likewise.
11621 (select_event_lwp_callback): Likewise.
11622 (cancel_breakpoints_callback): Likewise.
11624 2014-09-19 Don Breazeal <donb@codesourcery.com>
11626 * linux-low.c (handle_extended_wait): Call
11627 linux_ptrace_get_extended_event.
11628 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11629 linux_is_extended_waitstatus.
11631 2014-09-16 Joel Brobecker <brobecker@adacore.com>
11633 * Makefile.in (CPPFLAGS): Define.
11634 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11635 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11637 2014-09-16 Gary Benson <gbenson@redhat.com>
11639 * inferiors.h (current_inferior): Renamed as...
11640 (current_thread): New variable. All uses updated.
11641 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11642 (maybe_move_out_of_jump_pad): Likewise.
11643 (cancel_breakpoint): Likewise.
11644 (linux_low_filter_event): Likewise.
11645 (wait_for_sigstop): Likewise.
11646 (linux_resume_one_lwp): Likewise.
11647 (need_step_over_p): Likewise.
11648 (start_step_over): Likewise.
11649 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11650 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11651 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11652 and save_inferior as saved_thread.
11653 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11655 (regcache_invalidate_thread): Likewise.
11656 * remote-utils.c (prepare_resume_reply): Likewise.
11657 * thread-db.c (thread_db_get_tls_address): Likewise.
11658 (disable_thread_event_reporting): Likewise.
11659 (remove_thread_event_breakpoints): Likewise.
11660 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11662 * target.h (set_desired_inferior): Renamed as...
11663 (set_desired_thread): New declaration. All uses updated.
11664 * server.c (myresume): Updated comment to reference thread instead
11666 (handle_serial_event): Likewise.
11667 (handle_target_event): Likewise.
11669 2014-09-12 Tom Tromey <tromey@redhat.com>
11670 Gary Benson <gbenson@redhat.com>
11672 * regcache.h: Include common-regcache.h.
11673 (regcache_read_pc): Don't declare.
11674 * regcache.c (get_thread_regcache_for_ptid): New function.
11676 2014-09-11 Tom Tromey <tromey@redhat.com>
11677 Gary Benson <gbenson@redhat.com>
11679 * symbol.c: New file.
11680 * Makefile.in (SFILES): Add symbol.c.
11681 (OBS): Add symbol.o.
11683 2014-09-11 Gary Benson <gbenson@redhat.com>
11685 * target.c (target_stop_ptid, target_continue_ptid): New
11688 2014-09-11 Tom Tromey <tromey@redhat.com>
11689 Gary Benson <gbenson@redhat.com>
11691 * target.h: Include target/target.h.
11692 * target.c (target_read_memory, target_read_uint32)
11693 (target_write_memory): New functions.
11695 2014-09-11 Gary Benson <gbenson@redhat.com>
11697 * server.h (debug_hw_points): Don't declare.
11698 * server.c (debug_hw_points): Don't define. Replace all uses
11699 with show_debug_regs.
11700 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11701 all uses with show_debug_regs.
11703 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11705 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11706 endianness into account.
11707 (ppc_supply_ptrace_register): Likewise.
11709 2014-09-03 James Hogan <james.hogan@imgtec.com>
11711 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11712 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11714 2014-09-03 Gary Benson <gbenson@redhat.com>
11716 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11717 ALL_DEBUG_ADDRESS_REGISTERS.
11719 2014-09-02 Gary Benson <gbenson@redhat.com>
11721 * i386-low.h: Renamed as...
11722 * x86-low.h: New file. All type, function and variable name
11723 prefixes changed from "i386_" to "x86_". All references updated.
11724 * i386-low.c: Renamed as...
11725 * x86-low.c: New file. All type, function and variable name
11726 prefixes changed from "i386_" to "x86_". All references updated.
11728 2014-09-02 Gary Benson <gbenson@redhat.com>
11730 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11731 (x86_linux_new_thread): Likewise.
11733 2014-08-29 Gary Benson <gbenson@redhat.com>
11735 * server.h (setjmp.h): Do not include.
11736 (toplevel): Do not declare.
11737 (common-exceptions.h): Include.
11738 (cleanups.h): Likewise.
11739 * server.c (toplevel): Do not define.
11740 (exit_code): New static global.
11741 (detach_or_kill_for_exit_cleanup): New function.
11742 (main): New function. Original main renamed to...
11743 (captured_main): New function.
11744 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11746 2014-08-29 Gary Benson <gbenson@redhat.com>
11748 * Makefile.in (SFILES): Add common/common-exceptions.c.
11749 (OBS): Add common-exceptions.o.
11750 (common-exceptions.o): New rule.
11751 * utils.c (prepare_to_throw_exception): New function.
11753 2014-08-29 Gary Benson <gbenson@redhat.com>
11755 * config.in: Regenerate.
11756 * configure: Likewise.
11758 2014-08-29 Gary Benson <gbenson@redhat.com>
11760 * Makefile.in (SFILES): Add common/cleanups.c.
11762 (cleanups.o): New rule.
11764 2014-08-29 Gary Benson <gbenson@redhat.com>
11766 * utils.c (internal_vwarning): New function.
11768 2014-08-28 Gary Benson <gbenson@redhat.com>
11770 * utils.h (fatal): Remove declaration.
11771 * utils.c (fatal): Remove function.
11773 2014-08-28 Gary Benson <gbenson@redhat.com>
11775 * tracepoint.c (gdb_agent_init): Replace fatal with
11777 (initialize_tracepoint): Likewise.
11779 2014-08-28 Gary Benson <gbenson@redhat.com>
11781 * remote-utils.c (remote_prepare): Replace fatal with error.
11783 2014-08-28 Gary Benson <gbenson@redhat.com>
11785 * linux-low.c (linux_async): Replace fatal with warning.
11786 Tidy up and return.
11787 (linux_start_non_stop): Return -1 if linux_async failed.
11789 2014-08-28 Gary Benson <gbenson@redhat.com>
11791 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11793 (i386_dr_low_get_addr): Remove vague comment.
11794 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11797 2014-08-28 Gary Benson <gbenson@redhat.com>
11799 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11800 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11802 (linux_resume_one_lwp): Likewise.
11803 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11805 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11806 with internal_error.
11807 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11808 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11809 (find_register_by_name): Replace fatal with internal_error.
11810 (find_regno): Likewise.
11811 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11812 * thread-db.c (thread_db_create_event): Likewise.
11813 (thread_db_load_search): Likewise.
11814 (try_thread_db_load_1): Likewise.
11815 * tracepoint.c (get_jump_space_head): Replace fatal with
11817 (claim_trampoline_space): Likewise.
11818 (have_fast_tracepoint_trampoline_buffer): Likewise.
11819 (cmd_qtstart): Likewise.
11820 (stop_tracing): Likewise.
11821 (fast_tracepoint_collecting): Likewise.
11822 (target_malloc): Likewise.
11823 (download_tracepoint): Likewise.
11824 (download_trace_state_variables): Replace check with gdb_assert.
11825 (upload_fast_traceframes): Replace fatal with internal_error.
11827 2014-08-19 Tom Tromey <tromey@redhat.com>
11828 Gary Benson <gbenson@redhat.com>
11830 * Makefile.in (SFILES): Add common/common-debug.c.
11831 (OBS): Add common-debug.o.
11832 (common-debug.o): New rule.
11833 * debug.h (debug_printf): Don't declare.
11834 * debug.c (debug_printf): Renamed and rewritten as...
11835 (debug_vprintf): New function.
11837 2014-08-19 Gary Benson <gbenson@redhat.com>
11839 * utils.h: Do not include print-utils.h.
11841 2014-08-19 Tom Tromey <tromey@redhat.com>
11842 Gary Benson <gbenson@redhat.com>
11844 * server.h: Add static assertion.
11845 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11847 2014-08-19 Tom Tromey <tromey@redhat.com>
11848 Gary Benson <gbenson@redhat.com>
11850 * Makefile.in (SFILES): Add common/errors.c.
11851 (OBS): Add errors.o.
11852 (IPA_OBS): Add errors-ipa.o.
11853 (errors.o): New rule.
11854 (errors-ipa.o): Likewise.
11855 * utils.h (perror_with_name, error, warning): Don't declare.
11856 * utils.c (warning): Renamed and rewritten as...
11857 (vwarning): New function.
11858 (error): Renamed and rewritten as...
11859 (verror): New function.
11860 (internal_error): Renamed and rewritten as...
11861 (internal_verror): New function.
11863 2014-08-07 Gary Benson <gbenson@redhat.com>
11865 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11866 * configure: Regenerate.
11867 * config.in: Likewise.
11868 * server.h: Do not include errno.h.
11869 * event-loop.c: Likewise.
11870 * hostio-errno.c: Likewise.
11871 * linux-low.c: Likewise.
11872 * remote-utils.c: Likewise.
11873 * spu-low.c: Likewise.
11874 * utils.c: Likewise.
11875 * gdbreplay.c: Unconditionally include errno.h.
11877 2014-08-07 Gary Benson <gbenson@redhat.com>
11879 * server.h: Do not include string.h.
11880 * event-loop.c: Likewise.
11881 * linux-low.c: Likewise.
11882 * regcache.c: Likewise.
11883 * remote-utils.c: Likewise.
11884 * spu-low.c: Likewise.
11885 * utils.c: Likewise.
11887 2014-08-07 Gary Benson <gbenson@redhat.com>
11889 * server.h: Do not include gdb_assert.h.
11891 2014-08-07 Gary Benson <gbenson@redhat.com>
11893 * server.h: Do not include common-utils.h.
11895 2014-08-07 Gary Benson <gbenson@redhat.com>
11897 * server.h: Do not include ptid.h.
11898 * notif.h: Likewise.
11900 2014-08-07 Gary Benson <gbenson@redhat.com>
11902 * server.h: Do not include gdb_locale.h.
11904 2014-08-07 Gary Benson <gbenson@redhat.com>
11906 * server.h: Do not include gdb/signals.h.
11907 * win32-low.c: Likewise.
11909 2014-08-07 Gary Benson <gbenson@redhat.com>
11911 * server.h: Do not include pathmax.h.
11913 2014-08-07 Gary Benson <gbenson@redhat.com>
11915 * server.h: Do not include libiberty.h.
11916 * linux-bfin-low.c: Likewise.
11918 2014-08-07 Gary Benson <gbenson@redhat.com>
11920 * server.h: Do not include ansidecl.h.
11922 2014-08-07 Gary Benson <gbenson@redhat.com>
11924 * linux-x86-low.c: Do not include stddef.h.
11925 * lynx-ppc-low.c: Likewise.
11926 * tracepoint.c: Likewise.
11928 2014-08-07 Gary Benson <gbenson@redhat.com>
11930 * server.h: Do not include stdarg.h.
11931 * nto-low.c: Likewise.
11933 2014-08-07 Gary Benson <gbenson@redhat.com>
11935 * server.h: Do not include stdlib.h.
11936 * inferiors.c: Likewise.
11937 * linux-low.c: Likewise.
11938 * regcache.c: Likewise.
11939 * spu-low.c: Likewise.
11940 * tracepoint.c: Likewise.
11941 * utils.c: Likewise.
11943 2014-08-07 Gary Benson <gbenson@redhat.com>
11945 * server.h: Do not include stdio.h.
11946 * linux-low.c: Likewise.
11947 * remote-utils.c: Likewise.
11948 * spu-low.c: Likewise.
11949 * utils.c: Likewise.
11950 * wincecompat.c: Likewise.
11952 2014-08-06 Gary Benson <gbenson@redhat.com>
11954 * regcache.c (init_register_cache): Move conditionals inside if.
11956 2014-08-06 Gary Benson <gbenson@redhat.com>
11958 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
11960 2014-07-31 Gary Benson <gbenson@redhat.com>
11962 * ax.h: Do not include server.h.
11963 * gdbthread.h: Likewise.
11964 * lynx-low.h: Likewise.
11965 * notif.h: Likewise.
11967 2014-07-30 Gary Benson <gbenson@redhat.com>
11969 * server.h: Include common-defs.h.
11970 Do not include config.h or build-gnulib-gdbserver/config.h.
11972 2014-07-30 Gary Benson <gbenson@redhat.com>
11974 * hostio-errno.c: Move server.h to top of includes list.
11975 * inferiors.c: Likewise.
11976 * linux-x86-low.c: Likewise.
11977 * notif.c: Include server.h.
11979 2014-07-24 Tom Tromey <tromey@redhat.com>
11980 Gary Benson <gbenson@redhat.com>
11982 * server.h (CORE_ADDR): Now unsigned.
11984 2014-07-16 Pedro Alves <palves@redhat.com>
11986 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
11988 2014-07-15 Pedro Alves <palves@redhat.com>
11990 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
11993 2014-07-11 Pedro Alves <palves@redhat.com>
11995 * linux-low.c (kill_wait_lwp): New function, based on
11996 kill_one_lwp_callback, but use my_waitpid directly.
11997 (kill_one_lwp_callback, linux_kill): Use it.
11999 2014-06-23 Pedro Alves <palves@redhat.com>
12001 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12002 before setting DR0..DR3.
12004 2014-06-20 Gary Benson <gbenson@redhat.com>
12006 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12007 * configure: Regenerated.
12008 * config.in: Likewise.
12010 2014-06-20 Gary Benson <gbenson@redhat.com>
12012 * Makefile.in (SFILES): Update locations for files moved
12013 from common to nat.
12014 (object file files): Reordered.
12016 2014-06-20 Gary Benson <gbenson@redhat.com>
12018 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12019 (i386_dr_low_set_addr): Likewise.
12020 (i386_dr_low_get_addr): Likewise.
12021 (i386_dr_low_can_set_control): Likewise.
12022 (i386_dr_low_set_control): Likewise.
12023 (i386_dr_low_get_control): Likewise.
12024 (i386_dr_low_get_status): Likewise.
12025 (i386_get_debug_register_length): Likewise.
12026 * linux-x86-low.c (i386_dr_low_set_addr):
12027 Changed signature. Made static.
12028 (i386_dr_low_get_addr): Likewise.
12029 (i386_dr_low_set_control): Likewise.
12030 (i386_dr_low_get_control): Likewise.
12031 (i386_dr_low_get_status): Likewise.
12032 (i386_dr_low): New global variable.
12033 * win32-i386-low.c (i386_dr_low_set_addr):
12034 Changed signature. Made static.
12035 (i386_dr_low_get_addr): Likewise.
12036 (i386_dr_low_set_control): Likewise.
12037 (i386_dr_low_get_control): Likewise.
12038 (i386_dr_low_get_status): Likewise.
12039 (i386_dr_low): New global variable.
12041 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12043 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12044 * Makefile.in (AR, AR_FLAGS): Define.
12045 * configure: Regenerate.
12047 2014-06-19 Gary Benson <gbenson@redhat.com>
12049 * Makefile.in (i386-dregs.o): New rule.
12050 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12051 * i386-low.c (target.h): Remove include.
12052 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12053 (DR_CONTROL_SHIFT): Likewise.
12054 (DR_CONTROL_SIZE): Likewise.
12055 (DR_RW_EXECUTE): Likewise.
12056 (DR_RW_WRITE): Likewise.
12057 (DR_RW_READ): Likewise.
12058 (DR_RW_IORW): Likewise.
12059 (DR_LEN_1): Likewise.
12060 (DR_LEN_2): Likewise.
12061 (DR_LEN_4): Likewise.
12062 (DR_LEN_8): Likewise.
12063 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12064 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12065 (DR_ENABLE_SIZE): Likewise.
12066 (DR_LOCAL_SLOWDOWN): Likewise.
12067 (DR_GLOBAL_SLOWDOWN): Likewise.
12068 (DR_CONTROL_RESERVED): Likewise.
12069 (I386_DR_CONTROL_MASK): Likewise.
12070 (I386_DR_VACANT): Likewise.
12071 (I386_DR_LOCAL_ENABLE): Likewise.
12072 (I386_DR_GLOBAL_ENABLE): Likewise.
12073 (I386_DR_DISABLE): Likewise.
12074 (I386_DR_SET_RW_LEN): Likewise.
12075 (I386_DR_GET_RW_LEN): Likewise.
12076 (I386_DR_WATCH_HIT): Likewise.
12077 (i386_wp_op_t): Likewise.
12078 (i386_show_dr): Likewise.
12079 (i386_length_and_rw_bits): Likewise.
12080 (i386_insert_aligned_watchpoint): Likewise.
12081 (i386_remove_aligned_watchpoint): Likewise.
12082 (i386_handle_nonaligned_watchpoint): Likewise.
12083 i386_update_inferior_debug_regs(): Likewise.
12084 (i386_dr_insert_watchpoint): Likewise.
12085 (i386_dr_remove_watchpoint): Likewise.
12086 (i386_dr_region_ok_for_watchpoint): Likewise.
12087 (i386_dr_stopped_data_address): Likewise.
12088 (i386_dr_stopped_by_watchpoint): Likewise.
12090 2014-06-19 Gary Benson <gbenson@redhat.com>
12092 * i386-low.c (i386_dr_show): Renamed to
12093 i386_show_dr and made static. All uses updated.
12094 (i386_dr_length_and_rw_bits): Renamed to
12095 i386_length_and_rw_bits and made static.
12097 (i386_dr_insert_aligned_watchpoint): Renamed to
12098 i386_insert_aligned_watchpoint and made static.
12100 (i386_dr_remove_aligned_watchpoint): Renamed to
12101 i386_remove_aligned_watchpoint and made static.
12103 (i386_dr_update_inferior_debug_regs): Renamed to
12104 i386_update_inferior_debug_regs and made static.
12107 2014-06-18 Gary Benson <gbenson@redhat.com>
12109 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12110 (i386_dr_low_can_set_control): Likewise.
12111 (i386_get_debug_register_length): Likewise.
12112 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12113 (i386_dr_low_can_set_control): Likewise.
12114 (i386_get_debug_register_length): Likewise.
12116 2014-06-17 Gary Benson <gbenson@redhat.com>
12118 * i386-low.h (i386-dregs.h): New include.
12119 (DR_FIRSTADDR): Now in i386-dregs.h.
12120 (DR_LASTADDR): Likewise.
12121 (DR_NADDR): Likewise.
12122 (DR_STATUS): Likewise.
12123 (DR_CONTROL): Likewise.
12124 (i386_debug_reg_state): Likewise.
12125 (i386_dr_insert_watchpoint): Likewise.
12126 (i386_dr_remove_watchpoint): Likewise.
12127 (i386_dr_region_ok_for_watchpoint): Likewise.
12128 (i386_dr_stopped_data_address): Likewise.
12129 (i386_dr_stopped_by_watchpoint): Likewise.
12130 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12132 2014-06-18 Gary Benson <gbenson@redhat.com>
12134 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12135 i386_dr_insert_watchpoint.
12136 (i386_low_remove_watchpoint): Renamed to
12137 i386_dr_remove_watchpoint.
12138 (i386_low_region_ok_for_watchpoint): Renamed to
12139 i386_dr_region_ok_for_watchpoint.
12140 (i386_low_stopped_data_address): Renamed to
12141 i386_dr_stopped_data_address.
12142 (i386_low_stopped_by_watchpoint): Renamed to
12143 i386_dr_stopped_by_watchpoint.
12144 * i386-low.c (i386_show_dr): Renamed to
12145 i386_dr_show and made nonstatic. All uses updated.
12146 (i386_length_and_rw_bits): Renamed to
12147 i386_dr_length_and_rw_bits and made nonstatic.
12149 (i386_insert_aligned_watchpoint): Renamed to
12150 i386_dr_insert_aligned_watchpoint and made nonstatic.
12152 (i386_remove_aligned_watchpoint): Renamed to
12153 i386_dr_remove_aligned_watchpoint and made nonstatic.
12155 (i386_update_inferior_debug_regs): Renamed to
12156 i386_dr_update_inferior_debug_regs and made nonstatic.
12158 (i386_low_insert_watchpoint): Renamed to
12159 i386_dr_insert_watchpoint. All uses updated.
12160 (i386_low_remove_watchpoint): Renamed to
12161 i386_dr_remove_watchpoint. All uses updated.
12162 (i386_low_region_ok_for_watchpoint): Renamed to
12163 i386_dr_region_ok_for_watchpoint. All uses updated.
12164 (i386_low_stopped_data_address): Renamed to
12165 i386_dr_stopped_data_address. All uses updated.
12166 (i386_low_stopped_by_watchpoint): Renamed to
12167 i386_dr_stopped_by_watchpoint. All uses updated.
12169 2014-06-18 Gary Benson <gbenson@redhat.com>
12171 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12172 (i386_dr_low_can_set_control): Likewise.
12173 (i386_insert_aligned_watchpoint): New check.
12175 2014-06-18 Gary Benson <gbenson@redhat.com>
12177 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12180 2014-06-18 Gary Benson <gbenson@redhat.com>
12182 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12183 instead of fatal and error.
12184 (i386_handle_nonaligned_watchpoint): Likewise.
12186 2014-06-18 Gary Benson <gbenson@redhat.com>
12188 * i386-low.c (i386_get_debug_register_length): New macro.
12189 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12190 (i386_show_dr): Use debug_printf instead of fprintf. Use
12191 phex to format values.
12193 2014-06-18 Gary Benson <gbenson@redhat.com>
12195 * i386-low.h: Comment changes.
12196 * i386-low.c: Likewise.
12198 2014-06-18 Gary Benson <gbenson@redhat.com>
12200 * i386-low.c: Whitespace changes.
12202 2014-06-12 Tom Tromey <tromey@redhat.com>
12204 * utils.c (freeargv): Remove.
12206 2014-06-12 Tom Tromey <tromey@redhat.com>
12208 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12209 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12210 (parse_debug_format_options): Likewise.
12211 (gdbserver_usage): Likewise.
12212 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12213 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12214 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12216 ($(LIBGNU)): Depend on libiberty.
12217 (all-lib): Recurse into all subdirs.
12218 (install-only): Invoke "install" target in subdirs.
12219 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12221 * configure: Rebuild.
12222 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12223 for vasprintf, vsnprintf, or gettimeofday.
12224 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12227 2014-06-05 Joel Brobecker <brobecker@adacore.com>
12229 * development.sh: Delete.
12230 * Makefile.in (config.status): Adjust dependency on development.sh.
12231 * configure.ac: Adjust development.sh source call.
12232 * configure: Regenerate.
12234 2014-06-02 Pedro Alves <palves@redhat.com>
12236 * ax.c (gdb_free_agent_expr): New function.
12237 * ax.h (gdb_free_agent_expr): New declaration.
12238 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12240 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12242 (clear_breakpoint_conditions_and_commands): New function.
12243 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12244 (clear_breakpoint_conditions_and_commands): New declaration.
12246 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12248 * linux-aarch64-low.c (asm/ptrace.h): Include.
12250 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12252 Fix TLS access for -static -pthread.
12253 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12254 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12255 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12257 2014-05-20 Pedro Alves <palves@redhat.com>
12259 * linux-aarch64-low.c (aarch64_insert_point)
12260 (aarch64_remove_point): No longer check whether the type is
12261 supported here. Adjust to new interface.
12262 (the_low_target): Install aarch64_supports_z_point_type as
12263 supports_z_point_type method.
12264 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12265 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12266 instead of a Z packet char. Adjust.
12267 (arm_supports_z_point_type): New function.
12268 (arm_insert_point, arm_remove_point): Adjust to new interface.
12269 (the_low_target): Install arm_supports_z_point_type.
12270 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12271 (cris_insert_point, cris_remove_point): Adjust to new interface.
12272 Don't check whether the type is supported here.
12273 (the_low_target): Install cris_supports_z_point_type.
12274 * linux-low.c (linux_supports_z_point_type): New function.
12275 (linux_insert_point, linux_remove_point): Adjust to new interface.
12276 * linux-low.h (struct linux_target_ops) <insert_point,
12277 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12278 raw_breakpoint pointer parameter.
12279 <supports_z_point_type>: New method.
12280 * linux-mips-low.c (mips_supports_z_point_type): New function.
12281 (mips_insert_point, mips_remove_point): Adjust to new interface.
12282 Use mips_supports_z_point_type.
12283 (the_low_target): Install mips_supports_z_point_type.
12284 * linux-ppc-low.c (the_low_target): Install NULL as
12285 supports_z_point_type method.
12286 * linux-s390-low.c (the_low_target): Install NULL as
12287 supports_z_point_type method.
12288 * linux-sparc-low.c (the_low_target): Install NULL as
12289 supports_z_point_type method.
12290 * linux-x86-low.c (x86_supports_z_point_type): New function.
12291 (x86_insert_point): Adjust to new insert_point interface. Use
12292 insert_memory_breakpoint. Adjust to new
12293 i386_low_insert_watchpoint interface.
12294 (x86_remove_point): Adjust to remove_point interface. Use
12295 remove_memory_breakpoint. Adjust to new
12296 i386_low_remove_watchpoint interface.
12297 (the_low_target): Install x86_supports_z_point_type.
12298 * lynx-low.c (lynx_target_ops): Install NULL as
12299 supports_z_point_type callback.
12300 * nto-low.c (nto_supports_z_point_type): New.
12301 (nto_insert_point, nto_remove_point): Adjust to new interface.
12302 (nto_target_ops): Install nto_supports_z_point_type.
12303 * mem-break.c: Adjust intro comment.
12304 (struct raw_breakpoint) <raw_type, size>: New fields.
12305 <inserted>: Update comment.
12306 <shlib_disabled>: Delete field.
12307 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12308 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12309 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12310 (raw_bkpt_type_to_target_hw_bp_type): New function.
12311 (find_enabled_raw_code_breakpoint_at): New function.
12312 (find_raw_breakpoint_at): New type and size parameters. Use them.
12313 (insert_memory_breakpoint): New function, based off
12314 set_raw_breakpoint_at.
12315 (remove_memory_breakpoint): New function.
12316 (set_raw_breakpoint_at): Reimplement.
12317 (set_breakpoint): New, based on set_breakpoint_at.
12318 (set_breakpoint_at): Reimplement.
12319 (delete_raw_breakpoint): Go through the_target->remove_point
12320 instead of assuming memory breakpoints.
12321 (find_gdb_breakpoint_at): Delete.
12322 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12323 (find_gdb_breakpoint): New function.
12324 (set_gdb_breakpoint_at): Delete.
12325 (z_type_supported): New function.
12326 (set_gdb_breakpoint_1): New function, loosely based off
12327 set_gdb_breakpoint_at.
12328 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12329 (delete_gdb_breakpoint_at): Delete.
12330 (delete_gdb_breakpoint_1): New function, loosely based off
12331 delete_gdb_breakpoint_at.
12332 (delete_gdb_breakpoint): New function.
12333 (clear_gdb_breakpoint_conditions): Rename to ...
12334 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12336 (add_condition_to_breakpoint): Make static.
12337 (add_breakpoint_condition): Take a struct breakpoint pointer
12338 instead of an address. Adjust.
12339 (gdb_condition_true_at_breakpoint): Rename to ...
12340 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12342 (gdb_condition_true_at_breakpoint): Reimplement.
12343 (add_breakpoint_commands): Take a struct breakpoint pointer
12344 instead of an address. Adjust.
12345 (gdb_no_commands_at_breakpoint): Rename to ...
12346 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12347 parameter. Return true if no breakpoint was found. Change debug
12349 (gdb_no_commands_at_breakpoint): Reimplement.
12350 (run_breakpoint_commands): Rename to ...
12351 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12352 and change return type to boolean.
12353 (run_breakpoint_commands): New function.
12354 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12355 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12356 breakpoint. Go through the_target->remove_point instead of
12357 assuming memory breakpoint.
12358 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12359 software and hardware breakpoints.
12360 (reinsert_raw_breakpoint): Go through the_target->insert_point
12361 instead of assuming memory breakpoint.
12362 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12363 software and hardware breakpoints.
12364 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12365 Check both software and hardware breakpoints.
12366 (validate_inserted_breakpoint): Assert the breakpoint is a
12367 software breakpoint. Set the inserted flag to -1 instead of
12368 setting shlib_disabled.
12369 (delete_disabled_breakpoints): Adjust.
12370 (validate_breakpoints): Only validate software breakpoints.
12371 Adjust to inserted flag change.
12372 (check_mem_read, check_mem_write): Skip breakpoint types other
12373 than software breakpoints. Adjust to inserted flag change.
12374 * mem-break.h (enum raw_bkpt_type): New enum.
12375 (raw_breakpoint, struct process_info): Forward declare.
12376 (Z_packet_to_target_hw_bp_type): Delete declaration.
12377 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12378 (set_gdb_breakpoint, delete_gdb_breakpoint)
12379 (clear_breakpoint_conditions): New declarations.
12380 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12381 (breakpoint_inserted_here): Update comment.
12382 (add_breakpoint_condition, add_breakpoint_commands): Replace
12383 address parameter with a breakpoint pointer parameter.
12384 (gdb_breakpoint_here): Update comment.
12385 (delete_gdb_breakpoint_at): Delete.
12386 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12387 * server.c (process_point_options): Take a struct breakpoint
12388 pointer instead of an address. Adjust.
12389 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12390 delete_gdb_breakpoint.
12391 * spu-low.c (spu_target_ops): Install NULL as
12392 supports_z_point_type method.
12393 * target.h: Include mem-break.h.
12394 (struct target_ops) <prepare_to_access_memory>: Update comment.
12395 <supports_z_point_type>: New field.
12396 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12397 instead of a char. Also take a raw breakpoint pointer.
12398 * win32-arm-low.c (the_low_target): Install NULL as
12399 supports_z_point_type.
12400 * win32-i386-low.c (i386_supports_z_point_type): New function.
12401 (i386_insert_point, i386_remove_point): Adjust to new interface.
12402 (the_low_target): Install i386_supports_z_point_type.
12403 * win32-low.c (win32_supports_z_point_type): New function.
12404 (win32_insert_point, win32_remove_point): Adjust to new interface.
12405 (win32_target_ops): Install win32_supports_z_point_type.
12406 * win32-low.h (struct win32_target_ops):
12407 <supports_z_point_type>: New method.
12408 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12409 instead of a char. Also take a raw breakpoint pointer.
12411 2014-05-20 Pedro Alves <palves@redhat.com>
12413 * mem-break.h: Include break-common.h.
12414 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12415 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12416 (Z_packet_to_target_hw_bp_type): New declaration.
12417 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12418 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12419 (Z_PACKET_ACCESS_WP): Delete macros.
12420 (Z_packet_to_hw_type): Delete function.
12421 * i386-low.h: Don't include break-common.h here.
12422 (Z_packet_to_hw_type): Delete declaration.
12423 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12424 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12425 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12426 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12427 * linux-aarch64-low.c: Don't include break-common.h here.
12428 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12429 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12430 (Z_packet_to_target_hw_bp_type): Delete function.
12431 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12433 (mips_insert_point, mips_remove_point): Use
12434 Z_packet_to_target_hw_bp_type.
12436 2014-05-20 Pedro Alves <palves@redhat.com>
12438 * linux-aarch64-low.c: Include break-common.h.
12439 (enum target_point_type): Delete.
12440 (Z_packet_to_point_type): Rename to ...
12441 (Z_packet_to_target_hw_bp_type): ... this, and return a
12442 target_hw_bp_type instead.
12443 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12444 instead of an enum target_point_type.
12445 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12447 (aarch64_dr_state_insert_one_point)
12448 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12449 (aarch64_handle_aligned_watchpoint)
12450 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12451 Take an enum target_hw_bp_type instead of an enum
12453 (aarch64_supports_z_point_type): New function.
12454 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12455 use Z_packet_to_target_hw_bp_type.
12457 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12459 * configure.ac: Only use -Werror by default when DEVELOPMENT
12461 * configure: Regenerate.
12463 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12465 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12466 * linux-x86-low.c (X86_64_USER_REGS): New.
12467 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12469 2014-04-28 Yao Qi <yao@codesourcery.com>
12471 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12474 2014-04-25 Pedro Alves <palves@redhat.com>
12477 * linux-low.c (linux_attach_fail_reason_string): New function.
12478 (linux_attach_lwp): Delete.
12479 (linux_attach_lwp_1): Rename to ...
12480 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12481 argument. Remove "initial" parameter. Return int instead of
12482 void. Don't error or warn here.
12483 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12484 failure to attach to the tgid. Call warning when failing to
12486 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12487 argument. Remove "initial" parameter. Return int instead of
12488 void. Don't error or warn here.
12489 (linux_attach_fail_reason_string): New declaration.
12490 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12491 interface change. Use linux_attach_fail_reason_string.
12493 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12494 Walfred Tedeschi <walfred.tedeschi@intel.com>
12496 * Makefile.in: Added rules to handle new files
12497 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12498 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12499 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12500 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12501 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12502 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12503 x32-avx512-linux.o.
12504 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12505 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12506 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12507 i386/x32-avx512.xml.
12508 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12509 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12510 i386/x32-avx512-linux.xml.
12511 * i387-fp.c (num_avx512_k_registers): New constant for number
12513 (num_avx512_zmmh_low_registers): New constant for number of
12514 lower ZMM registers (0-15).
12515 (num_avx512_zmmh_high_registers): New constant for number of
12516 higher ZMM registers (16-31).
12517 (num_avx512_ymmh_registers): New contant for number of higher
12518 YMM registers (ymm16-31 added by avx521 on x86_64).
12519 (num_avx512_xmm_registers): New constant for number of higher
12520 XMM registers (xmm16-31 added by AVX512 on x86_64).
12521 (struct i387_xsave): Add space for AVX512 registers.
12522 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12523 Add code to handle AVX512 registers.
12524 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12525 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12526 prototypei from generated file.
12527 (tdesc_amd64_avx512_linux): Likewise.
12528 (init_registers_x32_avx512_linux): Likewise.
12529 (tdesc_x32_avx512_linux): Likewise.
12530 (init_registers_i386_avx512_linux): Likewise.
12531 (tdesc_i386_avx512_linux): Likewise.
12532 (x86_64_regmap): Add AVX512 registers.
12533 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12535 (initialize_low_arch): Add code to initialize AVX512 registers.
12537 2014-04-23 Pedro Alves <palves@redhat.com>
12539 * mem-break.c (find_gdb_breakpoint_at): Make static.
12540 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12542 2014-04-23 Pedro Alves <palves@redhat.com>
12544 * i386-low.c: Don't include break-common.h here.
12545 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12546 prototype to take target_hw_bp_type as argument instead of a Z
12548 * i386-low.h: Include break-common.h here.
12549 (Z_packet_to_hw_type): Declare.
12550 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12552 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12553 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12554 (x86_remove_point): Convert the packet number to a
12555 target_hw_bp_type before calling i386_low_remove_watchpoint.
12556 * win32-i386-low.c (i386_insert_point): Convert the packet number
12557 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12558 (i386_remove_point): Convert the packet number to a
12559 target_hw_bp_type before calling i386_low_remove_watchpoint.
12561 2014-04-23 Pedro Alves <palves@redhat.com>
12563 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12565 2014-04-10 Pedro Alves <palves@redhat.com>
12567 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12568 Check if the condition or command is NULL before checking if the
12569 breakpoint is known. On success, return true.
12570 * mem-break.h (add_breakpoint_condition): Document return.
12571 (add_breakpoint_commands): Add describing comment.
12572 * server.c (skip_to_semicolon): New function.
12573 (process_point_options): Use it.
12575 2014-04-09 Pedro Alves <palves@redhat.com>
12577 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12580 2014-02-27 Pedro Alves <palves@redhat.com>
12583 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12585 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12587 (last_thread_of_process_p): Take a PID argument instead of a
12589 (linux_wait_for_lwp): Delete.
12590 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12592 (linux_low_filter_event): New function, party factored out from
12593 linux_wait_for_event.
12594 (linux_wait_for_event): Rename to ...
12595 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12596 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12597 sigsuspend. Check for zombie leaders.
12598 (linux_wait_for_event): Reimplement as wrapper around
12599 linux_wait_for_event_filtered.
12600 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12601 a normal or signal exit is seen, it's the whole process exiting.
12602 (wait_for_sigstop): No longer a for_each_inferior callback.
12603 Rewrite on top of linux_wait_for_event_filtered.
12604 (stop_all_lwps): Call wait_for_sigstop directly.
12605 * server.c (resume, handle_target_event): Handle
12606 TARGET_WAITKIND_NO_RESUMED.
12608 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12610 * win32-low.c (psapi_get_dll_name,
12611 * win32_CreateToolhelp32Snapshot): Delete.
12612 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12613 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12615 (handle_load_dll): Add function description.
12616 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12618 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12620 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12622 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12623 base address when calling win32_add_one_solib.
12624 (handle_load_dll): Delete local variable load_addr.
12625 Remove 0x1000 offset applied to DLL base address when calling
12626 win32_add_one_solib.
12627 (handle_unload_dll): Add comment.
12629 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12631 * win32-low.c (win32_add_all_dlls): Renames
12632 win32_ensure_ntdll_loaded. Rewrite function documentation.
12633 Adjust implementation to always load all DLLs.
12634 Add 0x1000 offset to DLL base address when calling
12635 win32_add_one_solib.
12636 (child_initialization_done): New static global.
12637 (do_initial_child_stuff): Set child_initialization_done to
12638 zero during child initialization, and 1 after. Replace call
12639 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12641 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12642 (handle_unload_dll): Add function documentation.
12643 (get_child_debug_event): Ignore load and unload DLL events
12644 during child initialization.
12646 2014-02-20 Doug Evans <dje@google.com>
12648 Remove global all_lwps.
12649 * inferiors.h (ptid_of): Move here from linux-low.h.
12650 (pid_of, lwpid_of): Ditto.
12651 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12652 parameter is a struct thread_info * now.
12653 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12654 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12655 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12657 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12658 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12659 * linux-arm-low.c (update_registers_callback): Update, "entry"
12660 parameter is a struct thread_info * now.
12661 Fetch lwpid from current_inferior directly.
12662 (arm_insert_point): Pass &all_threads to find_inferior instead of
12664 (arm_remove_point): Ditto.
12665 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12666 (arm_prepare_to_resume): Fetch pid from thread.
12667 (arm_read_description): Fetch lwpid from current_inferior directly.
12668 * linux-low.c (all_lwps): Delete.
12669 (delete_lwp): Delete call to remove_inferior.
12670 (handle_extended_wait): Fetch lwpid from thread.
12671 (add_lwp): Don't set lwp->entry.id. Remove call to
12672 add_inferior_to_list.
12673 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12674 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12675 (kill_one_lwp_callback): Ditto.
12676 (linux_kill): Don't dereference NULL pointer.
12677 Fetch ptid,lwpid from thread.
12678 (get_detach_signal): Fetch ptid from thread.
12679 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12680 Simplify call to regcache_invalidate_thread.
12681 (delete_lwp_callback): Update, "entry" parameter is a
12682 struct thread_info * now. Fetch pid from thread.
12683 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12684 (status_pending_p_callback): Update, "entry" parameter is a
12685 struct thread_info * now. Fetch ptid from thread.
12686 (find_lwp_pid): Update, "entry" parameter is a
12687 struct thread_info * now.
12688 (linux_wait_for_lwp): Fetch pid from thread.
12689 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12690 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12691 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12692 (dequeue_one_deferred_signal): Ditto.
12693 (cancel_breakpoint): Fetch ptid from current_inferior.
12694 (linux_wait_for_event): Pass &all_threads to find_inferior,
12695 not &all_lwps. Fetch ptid, lwpid from thread.
12696 (count_events_callback): Update, "entry" parameter is a
12697 struct thread_info * now.
12698 (select_singlestep_lwp_callback): Ditto.
12699 (select_event_lwp_callback): Ditto.
12700 (cancel_breakpoints_callback): Ditto.
12701 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12703 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12704 (unsuspend_one_lwp): Update, "entry" parameter is a
12705 struct thread_info * now.
12706 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12708 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12709 Fetch lwpid from thread, not lwp.
12710 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12711 Pass &all_threads to find_inferior, not &all_lwps.
12712 (send_sigstop): Fetch lwpid from thread, not lwp.
12713 (send_sigstop_callback): Update, "entry" parameter is a
12714 struct thread_info * now.
12715 (suspend_and_send_sigstop_callback): Ditto.
12716 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12717 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12718 struct thread_info * now.
12719 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12721 (lwp_running): Update, "entry" parameter is a
12722 struct thread_info * now.
12723 (stop_all_lwps): Fetch ptid from thread.
12724 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12725 (linux_resume_one_lwp): Fetch lwpid from thread.
12726 (linux_set_resume_request): Update, "entry" parameter is a
12727 struct thread_info * now. Fetch pid, lwpid from thread.
12728 (resume_status_pending_p): Update, "entry" parameter is a
12729 struct thread_info * now.
12730 (need_step_over_p): Ditto. Fetch lwpid from thread.
12731 (start_step_over): Fetch lwpid from thread.
12732 (linux_resume_one_thread): Update, "entry" parameter is a
12733 struct thread_info * now. Fetch lwpid from thread.
12734 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12735 (proceed_one_lwp): Update, "entry" parameter is a
12736 struct thread_info * now. Fetch lwpid from thread.
12737 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12738 struct thread_info * now.
12739 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12740 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12741 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12743 (regsets_store_inferior_registers): Ditto.
12744 (fetch_register, store_register): Ditto.
12745 (linux_read_memory, linux_write_memory): Ditto.
12746 (linux_request_interrupt): Ditto.
12747 (linux_read_auxv): Ditto.
12748 (linux_xfer_siginfo): Ditto.
12749 (linux_qxfer_spu): Ditto.
12750 (linux_qxfer_libraries_svr4): Ditto.
12751 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12752 moved to inferiors.h.
12754 (get_thread_lwp): Update.
12755 (struct lwp_info): Delete member "entry". Simplify comment for
12757 (all_lwps): Delete.
12758 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12759 current_inferior directly.
12760 (update_watch_registers_callback): Update, "entry" parameter is a
12761 struct thread_info * now. Fetch pid from thread.
12762 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12763 (mips_insert_point): Fetch lwpid from current_inferior.
12764 Pass &all_threads to find_inferior, not &all_lwps.
12765 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12766 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12768 (mips_stopped_data_address): Ditto.
12769 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12771 * linux-tile-low.c (tile_arch_setup): Ditto.
12772 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12773 (update_debug_registers_callback): Update, "entry" parameter is a
12774 struct thread_info * now. Fetch pid from thread.
12775 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12776 Pass &all_threads to find_inferior, not &all_lwps.
12777 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12778 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12779 Pass &all_threads to find_inferior, not &all_lwps.
12780 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12781 (i386_dr_low_get_status): Ditto.
12782 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12783 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12784 (x86_linux_read_description): Ditto.
12785 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12787 2014-02-20 Doug Evans <dje@google.com>
12789 * inferiors.c (get_first_inferior): Fix buglet.
12791 2014-02-19 Doug Evans <dje@google.com>
12793 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12794 * inferiors.c (add_thread): Change result type to struct thread_info *.
12795 All callers updated.
12796 (add_lwp): Call add_thread here instead of in callers.
12797 All callers updated.
12798 * linux-low.h (get_lwp_thread): Rewrite.
12799 (struct lwp_info): New member "thread".
12801 2014-02-19 Doug Evans <dje@google.com>
12803 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12804 All callers updated.
12806 2014-02-19 Doug Evans <dje@google.com>
12808 * inferiors.c (add_thread): Fix whitespace.
12810 2014-02-19 Doug Evans <dje@google.com>
12812 * dll.c (clear_dlls): Replace accessing list implemention details
12814 * gdbthread.h (get_first_thread): Declare.
12815 * inferiors.c (for_each_inferior_with_data): New function.
12816 (get_first_thread): New function.
12817 (find_thread_ptid): Simplify.
12818 (get_first_inferior): New function.
12819 (clear_list): Delete.
12820 (one_inferior_p): New function.
12821 (clear_inferior_list): New function.
12822 (clear_inferiors): Update.
12823 * inferiors.h (for_each_inferior_with_data): Declare.
12824 (clear_inferior_list): Declare.
12825 (one_inferior_p): Declare.
12826 (get_first_inferior): Declare.
12827 * linux-low.c (linux_wait_for_event): Replace accessing list
12828 implemention details with API function.
12829 * server.c (target_running): Ditto.
12830 (accumulate_file_name_length): New function.
12831 (emit_dll_description): New function.
12832 (handle_qxfer_libraries): Replace accessing list implemention
12833 details with API function.
12834 (handle_qxfer_threads_worker): New function.
12835 (handle_qxfer_threads_proper): Replace accessing list implemention
12836 details with API function.
12837 (handle_query): Ditto.
12838 (visit_actioned_threads_callback_ftype): New typedef.
12839 (visit_actioned_threads_data): New struct.
12840 (visit_actioned_threads): Rewrite to be find_inferior callback.
12841 (resume): Call find_inferior.
12842 (handle_status): Replace accessing list implemention
12843 details with API function.
12844 (process_serial_event): Replace accessing list implemention details
12846 * target.c (set_desired_inferior): Replace accessing list implemention
12847 details with API function.
12848 * tracepoint.c (same_process_p): New function.
12849 (gdb_agent_about_to_close): Replace accessing list implemention
12850 details with API function.
12851 * win32-low.c (child_delete_thread): Replace accessing list
12852 implemention details with API function.
12853 (match_dll_by_basename): New function.
12854 (dll_is_loaded_by_basename): New function.
12855 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12856 details call to dll_is_loaded_by_basename.
12858 2014-02-19 Doug Evans <dje@google.com>
12860 * dll.h (struct dll_info): Add comment.
12861 * gdbthread.h (struct thread_info): Add comment.
12862 (current_ptid): Simplify.
12863 * inferiors.c (add_process): Update.
12864 (remove_process): Update.
12865 * inferiors.h (struct process_info): Rename member "head" to "entry".
12866 * linux-low.c (delete_lwp): Update.
12868 (last_thread_of_process_p): Update.
12869 (kill_one_lwp_callback, linux_kill): Update.
12870 (status_pending_p_callback): Update.
12871 (wait_for_sigstop): Update. Simplify read of ptid.
12872 (start_step_over): Update.
12873 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12874 (get_lwp_thread): Update.
12875 (struct lwp_info): Rename member "head" to "entry".
12876 * regcache.h (inferior_list_entry): Delete.
12877 * server.c (kill_inferior_callback): Update.
12878 (detach_or_kill_inferior_callback): Update.
12879 (print_started_pid): Update.
12880 (print_attached_pid): Update.
12881 (process_serial_event): Simplify read of ptid.
12882 * thread-db.c (thread_db_create_event): Update.
12883 (thread_db_get_tls_address): Update.
12884 * win32-low.c (current_inferior_ptid): Simplify.
12886 2014-02-19 Tom Tromey <tromey@redhat.com>
12888 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12890 (target_supports_btrace): Update.
12892 2014-02-14 Yao Qi <yao@codesourcery.com>
12894 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12895 (rsp-low-ipa.o): New target.
12897 2014-02-12 Tom Tromey <tromey@redhat.com>
12899 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12900 convert_ascii_to_int.
12901 * regcache.c (registers_to_string): Likewise.
12902 * remote-utils.c (decode_M_packet): Likewise.
12903 * server.c (process_serial_event): Likewise.
12905 2014-02-12 Tom Tromey <tromey@redhat.com>
12907 * server.c (handle_query, handle_v_run): Use hex2bin, not
12909 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12911 2014-02-12 Tom Tromey <tromey@redhat.com>
12913 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12914 convert_int_to_ascii.
12915 * regcache.c (registers_to_string, collect_register_as_string):
12917 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12919 * server.c (process_serial_event): Likewise.
12920 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12921 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
12923 2014-02-12 Tom Tromey <tromey@redhat.com>
12925 * remote-utils.c (look_up_one_symbol, monitor_output): Use
12926 bin2hex, not hexify.
12927 * tracepoint.c (cmd_qtstatus): Likewise.
12929 2014-02-12 Tom Tromey <tromey@redhat.com>
12931 * remote-utils.c (monitor_output): Pass explicit length to
12934 2014-02-12 Tom Tromey <tromey@redhat.com>
12936 * tracepoint.c: Include rsp-low.h.
12937 * server.c: Include rsp-low.h.
12938 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
12939 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
12941 * remote-utils.c: Include rsp-low.h.
12942 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
12943 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
12944 (convert_int_to_ascii, convert_ascii_to_int): Move to
12946 * regcache.c: Include rsp-low.h.
12947 * ax.c: Include rsp-low.h.
12948 * Makefile.in (SFILES): Add common/rsp-low.c.
12949 (OBS): Add rsp-low.o.
12950 (rsp-low.o): New target.
12952 2014-02-12 Tom Tromey <tromey@redhat.com>
12954 * utils.h (pulongest, plongest, phex_nz): Don't declare.
12955 Include print-utils.h.
12956 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
12957 (plongest, thirty_two, phex_nz): Remove.
12958 * Makefile.in (SFILES): Add common/print-utils.c.
12959 (OBS): Add print-utils.o.
12960 (print-utils-ipa.o): New target.
12961 (print-utils.o): New target.
12962 (IPA_OBJS): Add print-utils-ipa.o.
12964 2014-02-06 Tom Tromey <tromey@redhat.com>
12966 * Makefile.in (SFILES): Fix indentation.
12968 2014-02-05 Doug Evans <dje@google.com>
12970 * linux-low.c (linux_wait_for_event): Improve comment.
12971 (linux_wait_1): Keep current_inferior in sync with event_child.
12973 2014-01-22 Doug Evans <dje@google.com>
12975 * gdbthread.h (gdb_id_to_thread): Delete, unused.
12977 2014-01-22 Doug Evans <dje@google.com>
12979 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
12980 * configure: Regenerate.
12981 * config.in: Regenerate.
12982 * Makefile.in (SFILES): Add debug.c.
12983 (OBS): Add debug.o.
12984 * debug.c: New file.
12985 * debug.h: New file.
12986 * linux-aarch64-low.c (*): Update all debugging printfs to use
12987 debug_printf instead of fprintf.
12988 * linux-arm-low.c (*): Ditto.
12989 * linux-cris-low.c (*): Ditto.
12990 * linux-crisv32-low.c (*): Ditto.
12991 * linux-m32r-low.c (*): Ditto.
12992 * linux-sparc-low.c (*): Ditto.
12993 * linux-x86.c (*): Ditto.
12994 * linux-low.c (*): Ditto.
12995 (linux_wait_1): Add calls to debug_enter, debug_exit.
12996 (linux_wait): Remove redundant debugging printf.
12997 (stop_all_lwps): Add calls to debug_enter, debug_exit.
12998 (linux_resume, unstop_all_lwps): Ditto.
12999 * mem-break.c (*): Update all debugging printfs to use
13000 debug_printf instead of fprintf.
13001 * remote-utils.c (*): Ditto.
13002 * thread-db.c (*): Ditto.
13003 * server.c #include <ctype.h>, "gdb_vecs.h".
13004 (debug_threads): Moved to debug.c.
13005 (*): Update all debugging printfs to use debug_printf instead of
13007 (start_inferior): Replace call to fflush with call to debug_flush.
13008 (monitor_show_help): Mention set debug-format.
13009 (parse_debug_format_options): New function.
13010 (handle_monitor_command): Handle "monitor set debug-format".
13011 (gdbserver_usage): Mention --debug-format.
13012 (main): Parse --debug-format.
13013 * server.h (debug_threads): Declaration moved to debug.h.
13014 #include "debug.h".
13015 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13016 trace_debug_1 that uses debug_printf.
13017 (tracepoint_look_up_symbols): Update all debugging printfs to use
13018 debug_printf instead of fprintf.
13020 2014-01-20 Baruch Siach <baruch@tkos.co.il>
13022 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13025 2014-01-17 Pedro Alves <palves@redhat.com>
13028 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13029 defined after including gdb_proc_service.h.
13031 2014-01-16 Doug Evans <dje@google.com>
13033 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13034 (match_dll): Use it.
13036 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13038 * target.h (target_ops) <read_btrace>: Change parameters and
13039 return type to allow error reporting.
13040 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13041 trace reading errors on.
13042 * linux-low.c (linux_low_read_btrace): Pass trace reading
13044 (linux_low_disable_btrace): New.
13046 2014-01-15 Doug Evans <dje@google.com>
13048 * inferiors.c (thread_id_to_gdb_id): Delete.
13049 * inferiors.h (thread_id_to_gdb_id): Delete.
13051 2014-01-13 Eli Zaretskii <eliz@gnu.org>
13053 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13054 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13057 2014-01-08 Pedro Alves <palves@redhat.com>
13059 * server.c (handle_status): Don't discard previous queued stop
13060 replies or thread's pending status here.
13061 (main) <disconnection>: Do it here instead.
13063 2014-01-08 Pedro Alves <palves@redhat.com>
13065 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13066 * server.c (visit_actioned_threads, handle_pending_status): New
13068 (handle_v_cont): Factor out parts to ...
13069 (resume): ... this new function. If in all-stop, and a thread
13070 being resumed has a pending status, report it without actually
13072 (myresume): Adjust to use the new 'resume' function.
13073 (clear_pending_status_callback, set_pending_status_callback)
13074 (find_status_pending_thread_callback): New functions.
13075 (handle_status): Handle the case of multiple threads having
13076 interesting statuses to report. Report threads' real last signal
13077 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13078 with an interesting thread to report the status for, instead of
13079 always reporting the status of the first thread.
13081 2014-01-01 Joel Brobecker <brobecker@adacore.com>
13083 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13084 * gdbreplay.c (gdbreplay_version): Likewise.
13086 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13088 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13089 iov.iov_len with the real length in use.
13091 2013-12-13 Joel Brobecker <brobecker@adacore.com>
13093 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13094 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13095 for all targets that use win32-low.c.
13096 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13097 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13099 2013-12-13 Pedro Alves <palves@redhat.com>
13101 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13102 if equal to TARGET_WAITKIND_LOADED.
13103 * win32-low.c (cached_status): New static global.
13104 (win32_wait): Add declaration.
13105 (do_initial_child_stuff): Flush all initial pending debug events
13106 up to the initial breakpoint.
13107 (win32_wait): If CACHED_STATUS was set, return that instead
13108 of doing a real wait. Remove the code resuming the execution
13109 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13110 during the initial phase. Also remove the code changing
13111 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13112 TARGET_WAITKIND_STOPPED.
13114 2013-12-11 Yao Qi <yao@codesourcery.com>
13116 * notif.c (handle_notif_ack): Return 0 if no notification
13119 2013-11-20 Doug Evans <dje@google.com>
13121 * linux-low.c (linux_set_resume_request): Fix comment.
13123 2013-11-20 Doug Evans <dje@google.com>
13125 * linux-low.c (resume_status_pending_p): Tweak comment.
13127 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13129 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13130 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13131 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13132 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13133 (srv_amd64_regobj): Add amd64-mpx.o.
13134 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13135 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13136 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13137 * i387-fp.c (num_pl_bnd_register) Added constant.
13138 (num_pl_bnd_cfg_registers) Added constant.
13139 (struct i387_xsave) Added reserved area and MPX fields.
13140 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13141 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13143 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13144 (init_registers_amd64_mpx_linux): Declare new function.
13145 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13146 (x86_64_regmap): Add MPX registers.
13147 (x86_linux_read_description): Add MPX case.
13148 (initialize_low_arch): Initialize MPX targets.
13150 2013-11-18 Tom Tromey <tromey@redhat.com>
13152 * configure: Rebuild.
13153 * configure.ac: Don't check for stdlib.h.
13154 * gdbreplay.c: Unconditionally include stdlib.h.
13156 2013-11-18 Tom Tromey <tromey@redhat.com>
13158 * config.in: Rebuild.
13159 * configure: Rebuild.
13160 * configure.ac: Don't use AC_HEADER_DIRENT.
13162 2013-11-18 Tom Tromey <tromey@redhat.com>
13164 * server.h: Don't check HAVE_STRING_H.
13165 * gdbreplay.c: Don't check HAVE_STRING_H.
13166 * configure: Rebuild.
13168 2013-11-18 Tom Tromey <tromey@redhat.com>
13170 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13173 2013-11-08 Tom Tromey <tromey@redhat.com>
13175 * configure, config.in: Rebuild.
13176 * configure.ac: Remove unused configury.
13178 2013-11-08 Tom Tromey <tromey@redhat.com>
13180 * acinclude.m4: Include common.m4, codeset.m4.
13181 * configure, config.in: Rebuild.
13182 * configure.ac: Use GDB_AC_COMMON.
13184 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13186 * linux-s390-low.c (HWCAP_S390_TE): New define.
13187 (s390_arch_setup): Consider the TE field in the HWCAP for
13188 determining 'have_regset_tdb'.
13190 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13193 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13196 2013-10-02 Pedro Alves <palves@redhat.com>
13198 * server.c (process_serial_event): Don't output "GDBserver
13199 exiting" if GDB is connected through stdio.
13200 * target.c (mywait): Likewise, be silent if GDB is connected
13203 2013-10-01 Joel Brobecker <brobecker@adacore.com>
13205 * lynx-low.c (lynx_add_threads_after_attach): New function.
13206 (lynx_attach): Remove call to add_thread. Add call to
13207 lynx_add_threads_after_attach instead.
13209 2013-09-28 Mike Frysinger <vapier@gentoo.org>
13211 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13212 * config.in, configure: Regenerated.
13214 2013-09-18 Yao Qi <yao@codesourcery.com>
13217 * server.c (start_inferior): Clear 'resume_info'.
13219 2013-09-16 Jiong Wang <jiwang@tilera.com>
13221 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13224 2013-09-16 Jiong Wang <jiwang@tilera.com>
13226 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13227 linux-tile-low.o to srv_tgtobj.
13229 2013-09-16 Will Newton <will.newton@linaro.org>
13231 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13234 2013-09-06 Pedro Alves <palves@redhat.com>
13236 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13237 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13238 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13239 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13240 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13241 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13243 2013-09-06 Pedro Alves <palves@redhat.com>
13245 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13246 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13248 2013-09-06 Pedro Alves <palves@redhat.com>
13250 * linux-amd64-ipa.c: Include tracepoint.h.
13251 * linux-i386-ipa.c: Include tracepoint.h.
13253 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13255 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13256 (ps_get_thread_area): New function.
13258 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13260 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13261 (initialize_low_arch): Call init_registers_crisv32 rather than
13262 init_register_crisv32.
13264 2013-09-05 Pedro Alves <palves@redhat.com>
13266 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13268 * hostio.h: ... this new file.
13269 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13270 win32-low.c: Include hostio.h.
13272 2013-09-05 Pedro Alves <palves@redhat.com>
13274 * server.h (gdb_client_data, handler_func, callback_handler_func)
13275 (delete_file_handler, add_file_handler, append_callback_event)
13276 (delete_callback_event, start_event_loop, initialize_event_loop):
13277 Move to event-loop.h and include it.
13278 * event-loop.h: New file.
13280 2013-09-05 Pedro Alves <palves@redhat.com>
13282 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13283 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13284 (loaded_dll, unloaded_dll): Move to ...
13285 * dll.h: ... this new file.
13286 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13288 2013-09-05 Pedro Alves <palves@redhat.com>
13290 * server.h (current_process, get_thread_process, all_processes)
13291 (add_inferior_to_list, for_each_inferior, current_inferior)
13292 (remove_inferior, add_process, remove_process, find_process_pid)
13293 (have_started_inferiors_p, have_attached_inferiors_p)
13294 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13295 (clear_inferiors, find_inferior, find_inferior_id)
13296 (inferior_target_data, set_inferior_target_data)
13297 (inferior_regcache_data, set_inferior_regcache_data): Move to
13298 inferiors.h, and include it.
13299 * inferiors.h: New file.
13301 2013-09-05 Pedro Alves <palves@redhat.com>
13303 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13307 2013-09-05 Pedro Alves <palves@redhat.com>
13309 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13311 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13312 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13313 (handle_tracepoint_general_set, handle_tracepoint_query)
13314 (tracepoint_finished_step, tracepoint_was_hit)
13315 (release_while_stepping_state_list, current_traceframe)
13316 (in_readonly_region, traceframe_read_mem)
13317 (fetch_traceframe_registers, traceframe_read_sdata)
13318 (traceframe_read_info, struct fast_tpoint_collect_status)
13319 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13320 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13321 (supply_fast_tracepoint_registers)
13322 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13323 (ipa_tdesc, claim_trampoline_space)
13324 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13325 (agent_mem_read, agent_get_trace_state_variable_value)
13326 (agent_set_trace_state_variable_value, agent_tsv_read)
13327 (agent_mem_read_string, get_raw_reg_func_addr)
13328 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13329 * tracepoint.h: ... this new file.
13331 2013-09-05 Pedro Alves <palves@redhat.com>
13333 * server.h (perror_with_name, error, fatal, warning, paddress)
13334 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13336 * utils.h: New file.
13338 2013-09-05 Pedro Alves <palves@redhat.com>
13340 * server.h (remote_debug, noack_mode, transport_is_reliable)
13341 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13342 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13343 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13344 (write_enn, initialize_async_io, enable_async_io)
13345 (disable_async_io, check_remote_input_interrupt_request)
13346 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13347 (dead_thread_notify, prepare_resume_reply)
13348 (decode_address_to_semicolon, decode_address, decode_m_packet)
13349 (decode_M_packet, decode_X_packet, decode_xfer_write)
13350 (decode_search_memory_packet, unhexify, hexify)
13351 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13352 (look_up_one_symbol, relocate_instruction)
13353 (monitor_output): Move to remote-utils.h, and include it.
13354 * remote-utils.h: New file.
13356 2013-09-05 Pedro Alves <palves@redhat.com>
13358 * server.h (_): Delete.
13360 2013-09-02 Pedro Alves <palves@redhat.com>
13362 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13363 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13365 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13367 2013-09-02 Pierre Muller <muller@sourceware.org>
13369 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13370 or WriteProcessMemory complete successfully and handle
13371 ERROR_PARTIAL_COPY error.
13373 2013-09-02 Pedro Alves <palves@redhat.com>
13375 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13376 error instead of EIO.
13378 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13381 * linux-low.c: Include filestuff.h.
13382 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13383 * lynx-low.c: Include filestuff.h.
13384 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13385 * server.c: Include filestuff.h.
13386 (main): Call notice_open_fds.
13387 * spu-low.c: Include filestuff.h.
13388 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13390 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13392 * Makefile.in: Explain why ../target and ../nat are not
13393 listed as include file search paths.
13394 (linux-waitpid.o): New object file rule.
13395 * configure.srv (srv_native_linux_obj): New variable.
13396 Replace all occurrences of linux native object files with
13397 $srv_native_linux_obj.
13398 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13399 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13400 (linux_enable_event_reporting): Remove declaration.
13401 (my_waitpid): Moved to common/linux-waitpid.c.
13402 (linux_wait_for_event): Pass ptid when calling
13403 linux_enable_event_reporting.
13404 (linux_supports_tracefork_flag): Remove.
13405 (linux_enable_event_reporting): Likewise.
13406 (linux_tracefork_grandchild): Remove.
13407 (STACK_SIZE): Moved to common/linux-ptrace.c.
13408 (linux_tracefork_child): Remove.
13409 (linux_test_for_tracefork): Remove.
13410 (linux_look_up_symbols): Call linux_supports_traceclone.
13411 (initialize_low): Remove call to linux_test_for_tracefork.
13412 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13413 common/linux-ptrace.h.
13414 (PTRACE_TYPE_ARG4): Likewise.
13415 Include linux-ptrace.h.
13417 2013-08-21 Pedro Alves <palves@redhat.com>
13419 * config.in: Renegerate.
13421 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13423 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13424 (SFILES): Remove $(srcdir)/common/target-common.c and
13425 add $(srcdir)/target/waitstatus.c.
13426 (OBS): Remove target-common.o and add waitstatus.o.
13427 (server_h): Remove $(srcdir)/../common/target-common.h and
13428 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13429 and $(srcdir)/../target/waitstatus.h.
13430 (target-common.o): Remove.
13431 (waitstatus.o): New target object file.
13432 * target.h: Do not include target-common.h and
13433 include target/resume.h, target/wait.h and
13434 target/waitstatus.h.
13436 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13438 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13439 to PTRACE_TYPE_ARG3.
13440 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13441 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13443 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13444 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13446 2013-07-27 Jie Zhang <jie@codesourcery.com>
13447 Daniel Jacobowitz <dan@codesourcery.com>
13448 Yao Qi <yao@codesourcery.com>
13450 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13451 (mips-linux-watch.o): New rule.
13452 (mips_linux_watch_h): New variable.
13453 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13455 * linux-mips-low.c: Include mips-linux-watch.h.
13456 (struct arch_process_info, struct arch_lwp_info): New.
13457 (update_watch_registers_callback): New function.
13458 (mips_linux_new_process, mips_linux_new_thread) New functions.
13459 (mips_linux_prepare_to_resume, mips_insert_point): New
13461 (mips_remove_point, mips_stopped_by_watchpoint): New
13463 (rsp_bp_type_to_target_hw_bp_type): New function.
13464 (mips_stopped_data_address): New function.
13465 (the_low_target): Add watchpoint support functions.
13467 2013-07-27 Yao Qi <yao@codesourcery.com>
13469 * i386-low.c: Include break-common.h.
13470 (enum target_hw_bp_type): Remove.
13472 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13474 * Makefile.in (SFILES): /common/target-common.c.
13475 (OBS): Add target-common.o.
13476 (server_h): Add $(srcdir)/../common/target-common.h.
13477 (target-common.o): New target.
13478 * server.c (queue_stop_reply_callback): Free
13479 status string after use.
13480 * target.c (target_waitstatus_to_string): Remove.
13481 * target.h: Include target-common.h.
13482 (resume_kind): Likewise.
13483 (target_waitkind): Likewise.
13484 (target_waitstatus): Likewise.
13485 (TARGET_WNOHANG): Likewise.
13487 2013-07-04 Yao Qi <yao@codesourcery.com>
13489 * Makefile.in (host_alias): Use @host_noncanonical@.
13490 (target_alias): Use @target_noncanonical@.
13491 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13492 ACX_NONCANONICAL_HOST.
13493 * configure: Regenerated.
13496 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13498 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13499 * configure: Rebuild.
13500 * Makefile.in (version_host, version_target): Get from configure.
13501 (version.c): Use $(version_host) and $(version_target).
13503 2013-07-03 Pedro Alves <palves@redhat.com>
13505 * Makefile.in (config.status): Depend on development.sh.
13506 * acinclude.m4: Include libmcheck.m4.
13507 * configure: Regenerate.
13509 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13511 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13512 attribute inside the parentheses.
13513 (winapi_DebugSetProcessKillOnExit): Ditto.
13514 (winapi_DebugBreakProcess): Ditto.
13515 (winapi_GenerateConsoleCtrlEvent): Ditto.
13517 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13519 * notif.h (notif_event): Add a dummy member to avoid compiler
13522 2013-07-01 Pedro Alves <palves@redhat.com>
13524 * hostio.c (HOSTIO_PATH_MAX): Define.
13525 (require_filename, handle_open, handle_unlink, handle_readlink):
13528 2013-07-01 Pedro Alves <palves@redhat.com>
13530 * server.h: Include "pathmax.h".
13531 * linux-low.c: Don't include sys/param.h.
13532 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13534 * win32-low.c: Don't include sys/param.h.
13535 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13537 2013-07-01 Pedro Alves <palves@redhat.com>
13539 * event-loop.c: Don't check HAVE_UNISTD_H before including
13541 * gdbreplay.c: Likewise.
13542 * remote-utils.c: Likewise.
13543 * server.c: Likewise.
13544 * configure.ac: Don't check for unistd.h.
13545 * configure: Regenerate.
13547 2013-06-28 Tom Tromey <tromey@redhat.com>
13549 * Makefile.in (version.c): Use version.in, not
13552 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13554 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13555 * configure: Rebuild.
13556 * Makefile.in (version_host, version_target): Get from configure.
13557 (version.c): Use $(version_host) and $(version_target).
13559 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13561 Fix trace-status to output user name without trailing colon.
13562 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13564 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13566 Fix trace-status to output proper start-time and stop-time.
13567 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13568 output start time and stop time in hex as gdb expects.
13570 2013-06-26 Pedro Alves <pedro@codesourcery.com>
13572 * tracepoint.c (build_traceframe_info_xml): Output trace state
13573 variables present in the trace buffer.
13575 2013-06-24 Tom Tromey <tromey@redhat.com>
13577 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13579 (version.o): Remove.
13580 * gdbreplay.c: Include version.h.
13581 (version, host_name): Don't declare.
13582 * server.h: Include version.h.
13583 (version, host_name): Don't declare.
13585 2013-06-12 Pedro Alves <palves@redhat.com>
13587 * linux-x86-low.c (linux_is_elf64): Delete global.
13588 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13589 with local linux_pid_exe_is_elf_64_file use.
13591 2013-06-11 Pedro Alves <palves@redhat.com>
13593 * linux-low.c (regset_disabled, disable_regset): New functions.
13594 (regsets_fetch_inferior_registers)
13595 (regsets_store_inferior_registers): Use them.
13596 (initialize_regsets_info); Don't allocate the disabled_regsets
13598 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13601 2013-06-11 Pedro Alves <palves@redhat.com>
13603 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13606 2013-06-11 Pedro Alves <palves@redhat.com>
13608 * linux-x86-low.c (initialize_low_arch): Call
13609 init_registers_x32_avx_linux.
13611 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13613 Fix compatibility with Android Bionic.
13614 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13617 2013-06-07 Pedro Alves <palves@redhat.com>
13620 * Makefile.in (OBS): Add tdesc.o.
13621 (IPA_OBJS): Add tdesc-ipa.o.
13622 (tdesc-ipa.o): New rule.
13623 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13625 * linux-low.c (new_inferior): Delete.
13626 (disabled_regsets, num_regsets): Delete.
13627 (linux_add_process): Adjust to set the new per-process
13629 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13630 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13631 was a stop. When calling arch_setup, switch the current inferior
13632 to the thread that got an event.
13633 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13634 (regsets_fetch_inferior_registers)
13635 (regsets_store_inferior_registers): New regsets_info parameter.
13637 (linux_register_in_regsets): New regs_info parameter. Adjust to
13639 (register_addr, fetch_register, store_register): New usrregs_info
13640 parameter. Adjust to use it.
13641 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13642 parameter regs_info. Adjust to use it.
13643 (linux_fetch_registers): Get the current inferior's regs_info, and
13645 (linux_store_registers): Ditto.
13646 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13647 (initialize_low): Don't initialize the target_regsets here. Call
13648 initialize_low_arch.
13649 * linux-low.h (target_regsets): Delete declaration.
13650 (struct regsets_info): New.
13651 (struct usrregs_info): New.
13652 (struct regs_info): New.
13653 (struct process_info_private) <new_inferior>: New field.
13654 (struct linux_target_ops): Delete the num_regs, regmap, and
13655 regset_bitmap fields. New field regs_info.
13656 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13657 * i387-fp.c (num_xmm_registers): Delete.
13658 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13659 calls to new interface.
13660 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13661 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13662 Infer the number of xmm registers from the regcache's target
13664 * i387-fp.h (num_xmm_registers): Delete.
13665 * inferiors.c (add_thread): Don't install the thread's regcache
13667 * proc-service.c (gregset_info): Fetch the current inferior's
13668 regs_info. Adjust to use it.
13669 * regcache.c: Include tdesc.h.
13670 (register_bytes, reg_defs, num_registers)
13671 (gdbserver_expedite_regs): Delete.
13672 (get_thread_regcache): If the thread doesn't have a regcache yet,
13673 create one, instead of aborting gdbserver.
13674 (regcache_invalidate_one): Rename to ...
13675 (regcache_invalidate_thread): ... this.
13676 (regcache_invalidate_one): New.
13677 (regcache_invalidate): Only invalidate registers of the current
13679 (init_register_cache): Add target_desc parameter, and use it.
13680 (new_register_cache): Ditto. Assert the target description has a
13681 non zero registers_size.
13682 (regcache_cpy): Add assertions. Adjust.
13683 (realloc_register_cache, set_register_cache): Delete.
13684 (registers_to_string, registers_from_string): Adjust.
13685 (find_register_by_name, find_regno, find_register_by_number)
13686 (register_cache_size): Add target_desc parameter, and use it.
13687 (free_register_cache_thread, free_register_cache_thread_one)
13688 (regcache_release, register_cache_size): New.
13689 (register_size): Add target_desc parameter, and use it.
13690 (register_data, supply_register, supply_register_zeroed)
13691 (supply_regblock, supply_register_by_name, collect_register)
13692 (collect_register_as_string, collect_register_by_name): Adjust.
13693 * regcache.h (struct target_desc): Forward declare.
13694 (struct regcache) <tdesc>: New field.
13695 (init_register_cache, new_register_cache): Add target_desc
13697 (regcache_invalidate_thread): Declare.
13698 (regcache_invalidate_one): Delete declaration.
13699 (regcache_release): Declare.
13700 (find_register_by_number, register_cache_size, register_size)
13701 (find_regno): Add target_desc parameter.
13702 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13704 * remote-utils.c: Include tdesc.h.
13705 (outreg, prepare_resume_reply): Adjust.
13706 * server.c: Include tdesc.h.
13707 (gdbserver_xmltarget): Delete declaration.
13708 (get_features_xml, process_serial_event): Adjust.
13709 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13711 (struct process_info) <tdesc>: New field.
13712 (ipa_tdesc): Declare.
13713 * tdesc.c: New file.
13714 * tdesc.h: New file.
13715 * tracepoint.c: Include tdesc.h.
13716 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13717 (get_context_regcache): Adjust to pass ipa_tdesc down.
13718 (do_action_at_tracepoint): Adjust to get the register cache size
13719 from the context regcache's description.
13720 (traceframe_walk_blocks): Adjust to get the register cache size
13721 from the current trace frame's description.
13722 (traceframe_get_pc): Adjust to get current trace frame's
13723 description and pass it down.
13724 (gdb_collect): Adjust to get the register cache size from the
13726 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13727 (gdbserver_xmltarget): Delete.
13728 (initialize_low_tracepoint): Set the ipa's target description.
13729 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13730 (initialize_low_tracepoint): Set the ipa's target description.
13731 * linux-x86-low.c: Include tdesc.h.
13732 [__x86_64__] (is_64bit_tdesc): New.
13733 (ps_get_thread_area, x86_get_thread_area): Use it.
13734 (i386_cannot_store_register): Rename to ...
13735 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13736 (i386_cannot_fetch_register): Rename to ...
13737 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13738 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13740 (target_regsets): Rename to ...
13741 (x86_regsets): ... this.
13742 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13744 (x86_siginfo_fixup): Use is_64bit_tdesc.
13745 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13746 (tdesc_x32_avx_linux, tdesc_x32_linux)
13747 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13749 (x86_linux_update_xmltarget): Delete.
13750 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13751 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13752 (AMD64_LINUX_USER64_CS): New.
13753 (x86_linux_read_description): New, based on
13754 x86_linux_update_xmltarget.
13755 (same_process_callback): New.
13756 (x86_arch_setup_process_callback): New.
13757 (x86_linux_update_xmltarget): New.
13758 (x86_regsets_info): New.
13759 (amd64_linux_regs_info): New.
13760 (i386_linux_usrregs_info): New.
13761 (i386_linux_regs_info): New.
13762 (x86_linux_regs_info): New.
13763 (x86_arch_setup): Reimplement.
13764 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13765 (x86_emit_ops): Ditto.
13766 (the_low_target): Adjust. Install x86_linux_regs_info,
13767 x86_cannot_fetch_register, and x86_cannot_store_register.
13768 (initialize_low_arch): New.
13769 * linux-ia64-low.c (tdesc_ia64): Declare.
13770 (ia64_fetch_register): Adjust.
13771 (ia64_usrregs_info, regs_info): New globals.
13772 (ia64_regs_info): New function.
13773 (the_low_target): Adjust.
13774 (initialize_low_arch): New function.
13775 * linux-sparc-low.c (tdesc_sparc64): Declare.
13776 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13778 (sparc_arch_setup): New function.
13779 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13780 (the_low_target): Adjust.
13781 (initialize_low_arch): New function.
13782 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13783 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13784 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13785 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13786 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13787 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13788 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13789 (tdesc_powerpc_isa205_vsx64l): Declare.
13790 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13791 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13792 (ppc_set_pc, ppc_get_hwcap): Adjust.
13793 (ppc_usrregs_info): Forward declare.
13794 (!__powerpc64__) ppc_regmap_adjusted: New global.
13795 (ppc_arch_setup): Adjust to the current process'es target
13797 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13798 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13799 (ppc_store_evrregset): Adjust.
13800 (target_regsets): Rename to ...
13801 (ppc_regsets): ... this, and make static.
13802 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13803 (ppc_regs_info): New function.
13804 (the_low_target): Adjust.
13805 (initialize_low_arch): New function.
13806 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13807 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13808 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13809 (tdesc_s390x_linux64v2): Declare.
13810 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13811 (s390_fill_gregset, s390_store_last_break): Adjust.
13812 (target_regsets): Rename to ...
13813 (s390_regsets): ... this, and make static.
13814 (s390_get_pc, s390_set_pc): Adjust.
13815 (s390_get_hwcap): New target_desc parameter, and use it.
13816 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13817 (s390_arch_setup): Adjust to set the current process'es target
13818 description. Don't adjust the regmap.
13819 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13820 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13821 (regs_info_3264): New globals.
13822 (s390_regs_info): New function.
13823 (the_low_target): Adjust.
13824 (initialize_low_arch): New function.
13825 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13826 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13827 [__mips64] (init_registers_mips_linux)
13828 (init_registers_mips_dsp_linux): Delete defines.
13829 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13830 (have_dsp): New global.
13831 (mips_read_description): New, based on mips_arch_setup.
13832 (mips_arch_setup): Reimplement.
13833 (get_usrregs_info): New function.
13834 (mips_cannot_fetch_register, mips_cannot_store_register)
13835 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13836 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13837 (target_regsets): Rename to ...
13838 (mips_regsets): ... this, and make static.
13839 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13840 (dsp_regs_info, regs_info): New globals.
13841 (mips_regs_info): New function.
13842 (the_low_target): Adjust.
13843 (initialize_low_arch): New function.
13844 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13845 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13847 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13848 (arm_read_description): New, with bits factored from
13850 (arm_arch_setup): Reimplement.
13851 (target_regsets): Rename to ...
13852 (arm_regsets): ... this, and make static.
13853 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13854 (arm_regs_info): New function.
13855 (the_low_target): Adjust.
13856 (initialize_low_arch): New function.
13857 * linux-m68k-low.c (tdesc_m68k): Declare.
13858 (target_regsets): Rename to ...
13859 (m68k_regsets): ... this, and make static.
13860 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13861 (m68k_regs_info): New function.
13862 (m68k_arch_setup): New function.
13863 (the_low_target): Adjust.
13864 (initialize_low_arch): New function.
13865 * linux-sh-low.c (tdesc_sharch): Declare.
13866 (target_regsets): Rename to ...
13867 (sh_regsets): ... this, and make static.
13868 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13869 (sh_regs_info, sh_arch_setup): New functions.
13870 (the_low_target): Adjust.
13871 (initialize_low_arch): New function.
13872 * linux-bfin-low.c (tdesc_bfin): Declare.
13873 (bfin_arch_setup): New function.
13874 (bfin_usrregs_info, regs_info): New globals.
13875 (bfin_regs_info): New function.
13876 (the_low_target): Adjust.
13877 (initialize_low_arch): New function.
13878 * linux-cris-low.c (tdesc_cris): Declare.
13879 (cris_arch_setup): New function.
13880 (cris_usrregs_info, regs_info): New globals.
13881 (cris_regs_info): New function.
13882 (the_low_target): Adjust.
13883 (initialize_low_arch): New function.
13884 * linux-cris-low.c (tdesc_crisv32): Declare.
13885 (cris_arch_setup): New function.
13886 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13887 (cris_regs_info): New function.
13888 (the_low_target): Adjust.
13889 (initialize_low_arch): New function.
13890 * linux-m32r-low.c (tdesc_m32r): Declare.
13891 (m32r_arch_setup): New function.
13892 (m32r_usrregs_info, regs_info): New globals.
13893 (m32r_regs_info): Adjust.
13894 (initialize_low_arch): New function.
13895 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13896 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13897 (tic6x_usrregs_info): Forward declare.
13898 (tic6x_read_description): New function, based on ...
13899 (tic6x_arch_setup): ... this. Reimplement.
13900 (target_regsets): Rename to ...
13901 (tic6x_regsets): ... this, and make static.
13902 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13903 (tic6x_regs_info): New function.
13904 (the_low_target): Adjust.
13905 (initialize_low_arch): New function.
13906 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13907 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13908 (target_regsets): Rename to ...
13909 (xtensa_regsets): ... this, and make static.
13910 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13912 (xtensa_arch_setup, xtensa_regs_info): New functions.
13913 (the_low_target): Adjust.
13914 (initialize_low_arch): New function.
13915 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13916 (nios2_arch_setup): Set the current process'es tdesc.
13917 (target_regsets): Rename to ...
13918 (nios2_regsets): ... this.
13919 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13920 (nios2_regs_info): New function.
13921 (the_low_target): Adjust.
13922 (initialize_low_arch): New function.
13923 * linux-aarch64-low.c (tdesc_aarch64): Declare.
13924 (aarch64_arch_setup): Set the current process'es tdesc.
13925 (target_regsets): Rename to ...
13926 (aarch64_regsets): ... this.
13927 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
13928 (aarch64_regs_info): New function.
13929 (the_low_target): Adjust.
13930 (initialize_low_arch): New function.
13931 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
13933 (target_regsets): Rename to ...
13934 (tile_regsets): ... this.
13935 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
13936 (tile_regs_info): New function.
13937 (tile_arch_setup): Set the current process'es tdesc.
13938 (the_low_target): Adjust.
13939 (initialize_low_arch): New function.
13940 * spu-low.c (tdesc_spu): Declare.
13941 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
13942 * win32-arm-low.c (tdesc_arm): Declare.
13943 (arm_arch_setup): New function.
13944 (the_low_target): Install arm_arch_setup instead of
13945 init_registers_arm.
13946 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
13947 (init_windows_x86): Rename to ...
13948 (i386_arch_setup): ... this. Set `win32_tdesc'.
13949 (the_low_target): Adjust.
13950 * win32-low.c (win32_tdesc): New global.
13951 (child_add_thread): Don't create the thread cache here.
13952 (do_initial_child_stuff): Set the new process'es tdesc.
13953 * win32-low.h (struct target_desc): Forward declare.
13954 (win32_tdesc): Declare.
13955 * lynx-i386-low.c (tdesc_i386): Declare global.
13956 (lynx_i386_arch_setup): Set `lynx_tdesc'.
13957 * lynx-low.c (lynx_tdesc): New global.
13958 (lynx_add_process): Set the new process'es tdesc.
13959 * lynx-low.h (struct target_desc): Forward declare.
13960 (lynx_tdesc): Declare global.
13961 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
13962 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
13963 * nto-low.c (nto_tdesc): New global.
13964 (do_attach): Set the new process'es tdesc.
13965 * nto-low.h (struct target_desc): Forward declare.
13966 (nto_tdesc): Declare.
13967 * nto-x86-low.c (tdesc_i386): Declare.
13968 (nto_x86_arch_setup): Set `nto_tdesc'.
13970 2013-06-04 Gary Benson <gbenson@redhat.com>
13972 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
13973 to qSupported response when appropriate.
13974 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
13975 with nonzero-length annex.
13976 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
13977 arguments supplied in annex.
13979 2013-05-31 Doug Evans <dje@google.com>
13982 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
13983 64 bits in 64-cross-32 environment.
13985 2013-05-28 Pedro Alves <palves@redhat.com>
13987 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
13988 (aarch64-without-fpu.c): Delete rule.
13989 * configure.srv (aarch64*-*-linux*): Remove references to
13990 aarch64-without-fpu.o and aarch64-without-fpu.xml.
13991 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
13994 2013-05-24 Pedro Alves <palves@redhat.com>
13996 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
13997 instead of strchr/decode_address. Error if the range isn't split
13998 with a ','. Don't assume there's be a ':' in the action.
14000 2013-05-23 Yao Qi <yao@codesourcery.com>
14001 Pedro Alves <palves@redhat.com>
14003 * linux-low.c (lwp_in_step_range): New function.
14004 (linux_wait_1): If the thread was range stepping and stopped
14005 outside the stepping range, report the stop to GDB. Otherwise,
14006 continue stepping. Add range stepping debug output.
14007 (linux_set_resume_request): Copy the step range from the resume
14008 request to the lwp.
14009 (linux_supports_range_stepping): New.
14010 (linux_target_ops) <supports_range_stepping>: Set to
14011 linux_supports_range_stepping.
14012 * linux-low.h (struct linux_target_ops)
14013 <supports_range_stepping>: New field.
14014 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14015 * linux-x86-low.c (x86_supports_range_stepping): New.
14016 (the_low_target) <supports_range_stepping>: Set to
14017 x86_supports_range_stepping.
14018 * server.c (handle_v_cont): Handle 'r' action.
14019 (handle_v_requests): Append ";r" if the target supports range
14021 * target.h (struct thread_resume) <step_range_start,
14022 step_range_end>: New fields.
14023 (struct target_ops) <supports_range_stepping>:
14025 (target_supports_range_stepping): New macro.
14027 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14029 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14030 confusion in comment.
14032 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14034 * lynx-low.c (struct process_info_private): New type.
14035 (lynx_add_process): New function.
14036 (lynx_create_inferior, lynx_attach): Replace calls to
14037 add_process by calls to lynx_add_process.
14038 (lynx_resume): If PTID is null, then try using
14039 current_process()->private->last_wait_event_ptid.
14041 (lynx_clear_inferiors): Delete. The contents of that function
14042 has been inlined in lynx_mourn;
14043 (lynx_wait_1): Save the ptid in the process's private data.
14044 (lynx_mourn): Free the process' private data. Replace call
14045 to lynx_clear_inferiors by call to clear_inferiors.
14047 2013-05-17 Yao Qi <yao@codesourcery.com>
14049 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14052 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
14054 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14055 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14056 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14057 PT_TEXT_END_ADDR guards. Update comments.
14058 (linux_target_op) <read_offsets>: Conditionally define to
14059 linux_read_offsets if the target is UCLIBC and if it defines
14060 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14062 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14063 Andrew Jenner <andrew@codesourcery.com>
14065 * Makefile.in (SFILES): Add linux-nios2-low.c.
14066 (clean): Add action to delete nios2-linux.c.
14067 (nios2-linux.c): New rule.
14068 * configure.srv: Add nios2*-*-linux*.
14069 * linux-nios2-low.c: New.
14071 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14073 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14075 2013-04-25 Hui Zhu <hui@codesourcery.com>
14078 * ax.c (ax_printf): Add fflush.
14080 2013-04-22 Tom Tromey <tromey@redhat.com>
14082 * Makefile.in (SFILES): Add filestuff.c.
14083 (OBS): Add filestuff.o.
14084 (filestuff.o): New target.
14085 * config.in, configure: Rebuild.
14086 * configure.ac: Check for fdwalk, pipe2.
14088 2013-04-17 Pedro Alves <palves@redhat.com>
14090 * configure.ac (USE_THREAD_DB): Delete variable.
14091 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14092 Don't AC_SUBST USE_THREAD_DB.
14093 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14094 * config.in, configure: Regenerate.
14096 2013-04-16 Pedro Alves <palves@redhat.com>
14098 * linux-low.h (struct lwp_info) <thread_known>: Move under
14099 the USE_THREAD_DB #ifdef.
14101 2013-04-16 Pedro Alves <palves@redhat.com>
14103 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14104 (linux-low.o): Delete rule.
14105 * linux-low.h: Always include "gdb_thread_db.h" instead of
14106 conditionally including thread_db.h.
14107 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14110 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14112 * Makefile.in (install-only): Fix make install regression.
14114 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14116 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14117 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14119 * gdbserver.1: Remove.
14121 2013-03-22 Pedro Alves <palves@redhat.com>
14123 * linux-low.c (handle_extended_wait): Don't call
14124 linux_enable_event_reporting.
14126 2013-03-15 Tony Theodore <tonyt@logyst.com>
14129 * Makefile.in (SHELL): Use @SHELL@.
14131 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14133 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14136 2013-03-13 Joel Brobecker <brobecker@adacore.com>
14138 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14139 Remove extraneous NULL element.
14141 2013-03-13 Yao Qi <yao@codesourcery.com>
14143 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14144 'V' block in trace frame.
14146 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14148 * target.h (struct target_ops): Add btrace ops.
14149 (target_supports_btrace): New macro.
14150 (target_enable_btrace): New macro.
14151 (target_disable_btrace): New macro.
14152 (target_read_btrace): New macro.
14153 * gdbthread.h (struct thread_info): Add btrace field.
14154 * server.c: Include btrace-common.h.
14155 (handle_btrace_general_set): New function.
14156 (handle_btrace_enable): New function.
14157 (handle_btrace_disable): New function.
14158 (handle_general_set): Call handle_btrace_general_set.
14159 (handle_qxfer_btrace): New function.
14160 (struct qxfer qxfer_packets[]): Add btrace entry.
14161 * inferiors.c (remove_thread): Disable btrace.
14162 * linux-low: Include linux-btrace.h.
14163 (linux_low_enable_btrace): New function.
14164 (linux_low_read_btrace): New function.
14165 (linux_target_ops): Add btrace ops.
14166 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14167 Add srv_linux_btrace=yes.
14168 (x86_64-*-linux*): Add linux-btrace.o.
14169 Add srv_linux_btrace=yes.
14170 * configure.ac: Define HAVE_LINUX_BTRACE.
14171 * config.in: Regenerated.
14172 * configure: Regenerated.
14174 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14176 * server.c (handle_qxfer): Preserve error message if -3 is
14178 (qxfer): Document the -3 return value.
14180 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14182 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14183 (linux_btrace_h): New variable.
14184 (linux-btrace.o): New rule.
14186 2013-03-08 Stan Shebs <stan@codesourcery.com>
14187 Hafiz Abid Qadeer <abidh@codesourcery.com>
14189 * tracepoint.c (trace_buffer_size): New global.
14190 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14191 (init_trace_buffer): Change to one-argument function. Allocate
14192 trace buffer memory.
14193 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14194 handle QTBuffer:size packet.
14195 (cmd_bigqtbuffer_size): New function.
14196 (initialize_tracepoint): Call init_trace_buffer with
14197 DEFAULT_TRACE_BUFFER_SIZE.
14198 * server.c (handle_query): Add QTBuffer:size in the
14201 2013-03-07 Yao Qi <yao@codesourcery.com>
14203 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14204 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14206 (cmd_qtsp): Adjust condition. Do post increment.
14207 Set cur_action and cur_step_action back to 0.
14209 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14212 * linux-low.c (linux_write_memory): Return early success if LEN is
14215 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
14217 * configure.srv: Add x86_64-*-cygwin* as target.
14219 2013-02-28 Tom Tromey <tromey@redhat.com>
14221 * configure.ac: Invoke AC_SYS_LARGEFILE.
14222 * configure, config.in: Rebuild.
14224 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
14226 * win32-low.c: Throughout, fix format strings and casts of
14227 printf-like functions to avoid type related warnings on all
14229 (get_child_debug_event): Print dwDebugEventCode as hex since
14230 that's how it's usually documented.
14232 2013-02-28 Yao Qi <yao@codesourcery.com>
14234 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14237 2013-02-27 Jiong Wang <jiwang@tilera.com>
14239 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14240 (reg-tilegx32.c): New rule.
14241 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14242 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14243 different register info initializer according to elf class.
14244 (init_registers_tilgx32): New function. The tilegx32 register info
14246 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14247 (tile_store_gregset): Likewise.
14249 2013-02-27 Yao Qi <yao@codesourcery.com>
14251 * server.c (process_point_options): Print debug message when
14252 debug_threads is true.
14254 2013-02-26 Yao Qi <yao@codesourcery.com>
14256 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14258 2013-02-19 Pedro Alves <palves@redhat.com>
14259 Kai Tietz <ktietz@redhat.com>
14263 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14264 instead of strtoul to extract address from packet.
14265 (process_serial_event) <'z'>: Likewise.
14267 2013-02-18 Yao Qi <yao@codesourcery.com>
14269 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14271 2013-02-14 Pedro Alves <palves@redhat.com>
14275 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14276 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14278 2013-02-14 Pedro Alves <palves@redhat.com>
14280 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14282 2013-02-14 Pedro Alves <palves@redhat.com>
14284 * tracepoint.c (save_string): Delete.
14285 (add_tracepoint_action): Use savestring instead of save_string.
14287 2013-02-12 Pedro Alves <palves@redhat.com>
14289 * linux-xtensa-low.c: Ditto.
14290 * xtensa-xtregs.c: Ditto.
14292 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14294 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14297 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14299 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14300 aarch64_num_wp_regs and aarch64_num_bp_regs to
14301 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14303 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14305 * linux-aarch64-low.c (ps_get_thread_area): Replace
14306 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14308 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14309 Marcus Shawcroft <marcus.shawcroft@arm.com>
14310 Nigel Stephens <nigel.stephens@arm.com>
14311 Yufeng Zhang <yufeng.zhang@arm.com>
14313 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14314 (aarch64.c, aarch64-without-fpu.c): New targets.
14315 * configure.srv (aarch64*-*-linux*): New.
14316 * linux-aarch64-low.c: New file.
14318 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14320 * linux-low.c (handle_extended_wait, linux_create_inferior)
14321 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14322 (dequeue_one_deferred_signal, linux_resume_one_thread)
14323 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14324 (linux_tracefork_grandchild, linux_test_for_tracefork)
14325 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14326 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14327 where the argument is 0.
14329 2013-01-25 Yao Qi <yao@codesourcery.com>
14331 * event-loop.c: Include "queue.h".
14332 (gdb_event_p): New typedef.
14333 (struct gdb_event) <next_event>: Remove.
14334 (event_queue): Change to QUEUE(gdb_event_p).
14335 (async_queue_event): Remove.
14336 (gdb_event_xfree): New.
14337 (initialize_event_loop): New.
14338 (process_event): Use API from QUEUE.
14339 (wait_for_event): Likewise.
14340 * server.c (main): Call initialize_event_loop.
14341 * server.h (initialize_event_loop): Declare.
14343 2013-01-18 Yao Qi <yao@codesourcery.com>
14345 * ax.h (struct eval_agent_expr_context): New.
14346 (gdb_eval_agent_expr): Update declaration.
14347 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14348 TFRAME. Add new argument CTX.
14349 * server.h (struct eval_agent_expr_context): Declare.
14350 (agent_mem_read, agent_tsv_read): Update declaration.
14351 (agent_mem_read_string): Likewise.
14352 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14353 (add_traceframe_block): Add new argument TPOINT.
14354 Increase TPOINT->traceframe_usage.
14355 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14356 eval_tracepoint_agent_expr.
14357 (condition_true_at_tracepoint): Likewise.
14358 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14359 (agent_mem_read_string, agent_tsv_read): Likewise.
14361 2013-01-16 Yao Qi <yao@codesourcery.com>
14363 * linux-low.c (linux_resume_one_lwp): Don't check
14364 'lwp->bp_reinsert != 0'.
14366 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14367 Pedro Alves <palves@redhat.com>
14369 * lynx-low.c (ptrace_request_to_str): Define a temporary
14370 macro and use it to simplify this function's implementation.
14372 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14374 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14377 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14379 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14381 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14383 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14385 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14387 * lynx-low.c (lynx_resume): Use the resume_info parameter
14388 to determine the ptid for the lynx_ptrace call, unless
14389 it is equal to minus_one_ptid, in which case we use the
14390 ptid of the current_inferior.
14391 (lynx_wait_1): After having received a thread create/exit
14392 event, resume the inferior's execution using the signaling
14393 thread's ptid, rather than the old ptid.
14395 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14397 * lynx-low.c (lynx_resume): Delete variable ret.
14399 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14401 * gdbreplay.c (gdbreplay_version): Update copyright year.
14402 * server.c (gdbserver_version): Likewise.
14404 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14406 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14409 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14411 * lynx-low.c (ptrace_request_to_str): Add handling for
14412 PTRACE_GETTRACESIG.
14414 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14416 * lynx-low.c (lynx_attach): Delete variable new_process.
14418 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14420 * lynx-low.c (lynx_create_inferior): Delete variable
14423 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14425 * lynx-low.c (ptrace_request_to_str): Do not handle
14426 PTRACE_GETTHREADLIST if this macro does not exist.
14428 2012-12-15 Yao Qi <yao@codesourcery.com>
14430 * Makefile.in (OBS): Add notif.o.
14431 * notif.c, notif.h: New.
14432 * server.c: Include "notif.h".
14433 (struct vstop_notif) <next>: Remove.
14435 (queue_stop_reply): Update.
14436 (push_event, send_next_stop_reply): Remove.
14437 (discard_queued_stop_replies): Update.
14438 (notif_stop): New variable.
14439 (handle_v_stopped): Remove.
14440 (handle_v_requests): Don't call handle_v_stopped. Call
14441 handle_ack_notif instead.
14442 (queue_stop_reply_callback): Call notif_event_enque instead
14443 of queue_stop_reply.
14444 (handle_status): Don't call send_next_stop_reply, call
14445 notif_write_event instead.
14446 (kill_inferior_callback): Likewise.
14447 (detach_or_kill_inferior_callback): Likewise.
14448 (main): Call initialize_notif.
14449 (process_serial_event): Call QUEUE_is_empty.
14450 (handle_target_event): Call notif_push instead of push event.
14451 * server.h (push_event): Remove declaration.
14453 2012-12-10 Tom Tromey <tromey@redhat.com>
14455 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14456 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14459 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14460 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14461 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14462 (amd64-linux-ipa.o, ax.o): Rewrite.
14463 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14464 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14465 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14466 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14467 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14468 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14469 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14470 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14471 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14472 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14473 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14474 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14475 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14476 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14477 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14478 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14479 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14480 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14481 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14482 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14483 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14484 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14485 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14486 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14487 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14488 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14489 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14490 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14491 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14492 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14493 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14494 (reg-tilegx.o): Remove.
14495 (all_object_files): New macro.
14496 Include .deps files.
14497 * aclocal.m4, configure: Rebuild.
14498 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14499 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14500 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14502 2012-12-05 Tom Tromey <tromey@redhat.com>
14505 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14507 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14509 * configure.ac: Check for linux/perf_event.h.
14510 * config.in: Regenerated.
14511 * configure: Regenerated.
14513 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14515 * hostio.c (handle_readlink): Decrease buffer size
14516 parameter passed to readlink by one byte.
14518 2012-11-26 Yao Qi <yao@codesourcery.com>
14520 * configure.ac (build_warnings): Append '-Wempty-body'.
14521 * configure: Regenerated.
14522 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14525 2012-11-15 Pierre Muller <muller@sourceware.org>
14527 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14528 * config.in: Regenerate.
14529 * configure: Regenerate.
14530 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14531 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14532 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14533 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14535 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14536 instead of <sys/wait.h> header.
14537 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14539 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
14541 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14542 (various make rules): Remove -DGDBSERVER
14544 2012-11-09 Yao Qi <yao@codesourcery.com>
14546 * spu-low.c (current_ptid): Move it to ..
14547 * gdbthread.h: ... here. New.
14548 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14549 * server.c (myresume, process_serial_event): Likewise.
14550 * thread-db.c (thread_db_find_new_threads): Likewise.
14551 * tracepoint.c (run_inferior_command): Likewise.
14553 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
14555 * server.c (handle_search_memory_1): Include access length in
14558 2012-09-05 Michael Brandt <michael.brandt@axis.com>
14560 * linux-crisv32-low.c: Fix compile errors.
14562 2012-09-04 Yao Qi <yao@codesourcery.com>
14564 * tracepoint.c (cmd_qtsv): Adjust debug message.
14565 Don't check CUR_TPOINT.
14567 2012-08-28 Yao Qi <yao@codesourcery.com>
14569 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14570 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14571 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14572 Remove declarations of xmalloc, xreallloc, xstrdup and
14574 * Makefile.in (libiberty_h): New.
14575 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14576 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14578 2012-08-23 Yao Qi <yao@codesourcery.com>
14580 * server.h: Remove declaration of 'xsnprintf'.
14582 2012-08-22 Keith Seitz <keiths@redhat.com>
14584 * server.h: Include build-gnulib-gbserver/config.h.
14585 * gdbreplay.c: Likewise.
14587 2012-08-08 Doug Evans <dje@google.com>
14589 * Makefile.in (SFILES): Add gdb_vecs.c.
14590 (OBS): Add gdb_vecs.o.
14591 (gdb_vecs_h, host_defs_h): New variables.
14592 (thread-db.o): Add $(gdb_vecs_h) dependency.
14593 (gdb_vecs.o): New rule.
14594 * thread-db.c: #include "gdb_vecs.h".
14595 (thread_db_load_search): Use a vector to iterate over path elements.
14596 Handle text appearing after "$pdir".
14598 * configure.ac: Add check for strstr.
14599 * config.in: Regenerate.
14600 * configure: Regenerate.
14602 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14604 * hostio.c (handle_pread): If pread fails, fall back to attempting
14606 (handle_pwrite): Likewise for pwrite.
14608 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14610 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14611 between unsupported TYPE and unimplementable ADDR/LEN combination.
14612 (arm_insert_point): Act on new return value.
14614 2012-07-31 Pedro Alves <palves@redhat.com>
14616 * server.c (process_point_options): Only skip tokens if we find
14617 one that is unrecognized. Don't treat 'X' specially while
14618 skipping unrecognized tokens.
14620 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14622 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14623 to 4-byte-align HW breakpoint addresses for Thumb.
14625 2012-07-27 Yao Qi <yao@codesourcery.com>
14629 * server.h: Declare gdb_agent_about_to_close.
14630 * target.c (kill_inferior): Include "agent.h".
14631 New. Send command 'kill'.
14632 * target.h (kill_inferior): Removed macro.
14633 * tracepoint.c (gdb_agent_about_to_close): New.
14634 (gdb_agent_helper_thread): Handle command 'close'.
14635 Wait endlessly until the inferior stops.
14636 Install gdb_agent_remove_socket to atexit hook.
14637 (agent_socket_name): New static variable.
14638 (gdb_agent_socket_init): Replace local variable 'name' with
14639 'agent_socket_name'.
14640 (gdb_agent_remove_socket): New.
14642 2012-07-27 Yao Qi <yao@codesourcery.com>
14644 * server.c (process_point_options): Stop at 'X' when parsing.
14646 2012-07-19 Michael Eager <eager@eagercon.com>
14648 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
14650 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14651 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14652 hardware breakpoint.
14654 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14656 * gdbserver/linux-low.c (initialize_low): Call
14657 linux_ptrace_init_warnings.
14659 2012-07-02 Doug Evans <dje@google.com>
14661 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14664 2012-07-02 Stan Shebs <stan@codesourcery.com>
14666 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14667 (ax.o): Add it to build rule.
14669 (OBS): Add format.o.
14670 (IPA_OBS): Add format.o.
14671 * server.c (handle_query): Claim support for breakpoint commands.
14672 (process_point_options): Add command case.
14673 (process_serial_event): Leave running if there are printfs in
14675 * mem-break.h (any_persistent_commands): Declare.
14676 (add_breakpoint_commands): Declare.
14677 (gdb_no_commands_at_breakpoint): Declare.
14678 (run_breakpoint_commands): Declare.
14679 * mem-break.c (struct point_command_list): New struct.
14680 (struct breakpoint): New field command_list.
14681 (any_persistent_commands): New function.
14682 (add_commands_to_breakpoint): New function.
14683 (add_breakpoint_commands): New function.
14684 (gdb_no_commands_at_breakpoint): New function.
14685 (run_breakpoint_commands): New function.
14686 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14688 * ax.c: Include format.h.
14689 (ax_printf): New function.
14690 (gdb_eval_agent_expr): Add printf opcode.
14692 2012-06-13 Yao Qi <yao@codesourcery.com>
14694 * server.c (start_inferior): Remove duplicated writes to fields
14695 'last_resume_kind' and 'last_status' of 'current_inferior'.
14697 2012-06-12 Yao Qi <yao@codesourcery.com>
14698 Pedro Alves <palves@redhat.com>
14700 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14702 * server.c (handle_v_cont): Extend comment.
14704 2012-06-11 Yao Qi <yao@codesourcery.com>
14706 * linux-low.c (linux_attach): Add 'static'.
14708 2012-06-06 Yao Qi <yao@codesourcery.com>
14710 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14712 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14714 Fix gcc -flto compilation warning.
14715 * server.c (main): Make variable multi_mode and attach volatile.
14717 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14719 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14720 if the platform doesn't know about it.
14722 2012-05-30 Jeff Kenton <jkenton@tilera.com>
14724 * Makefile.in (SFILES): Add linux-tile-low.c.
14725 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14726 * configure.srv: Handle tilegx-*-linux*.
14727 * linux-tile-low.c: New file.
14729 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14731 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14733 2012-05-24 Pedro Alves <palves@redhat.com>
14737 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
14739 2012-05-24 Pedro Alves <palves@redhat.com>
14743 Replace target_signal with gdb_signal throughout.
14745 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14747 * linux-low.c (linux_store_registers): Avoid the copying sequence
14748 when no data has been retrieved by ptrace.
14750 2012-05-22 Will Deacon <will.deacon@arm.com>
14752 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14753 Include asm/ptrace.h.
14754 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14757 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14759 * linux-low.c (linux_store_registers): Don't re-retrieve data
14760 with ptrace that has already been obtained from /proc. Always
14761 copy any data retrieved with ptrace to the buffer supplied.
14763 2012-05-11 Yao Qi <yao@codesourcery.com>
14764 Pedro Alves <palves@redhat.com>
14766 * linux-low.c (enum stopping_threads_kind): New.
14767 (stopping_threads): Change type to `enum stopping_threads_kind'.
14768 (handle_extended_wait): If stopping and suspending threads, leave
14769 the new_lwp suspended too.
14770 (linux_wait_for_event): Adjust.
14771 (stop_all_lwps): Set `stopping_threads' to
14772 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14773 whether we're suspending threads or just stopping them. Assert no
14776 2012-04-29 Yao Qi <yao@codesourcery.com>
14778 * server.h: Move some code to ...
14779 * gdbthread.h: ... here. New.
14780 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14781 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14782 (nto-low.o, win32-low.o): Likewise.
14783 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14784 * regcache.c, remote-utils.c, server.c: Likewise.
14785 * target.c, tracepoint.c, win32-low.c: Likewise.
14787 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14789 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14790 (PTRACE_ARG4_TYPE): Likewise.
14791 (PTRACE_XFER_TYPE): Likewise.
14792 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14793 ptrace to PTRACE_ARG3_TYPE.
14794 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14795 (PTRACE_ARG4_TYPE): Likewise.
14796 (PTRACE_XFER_TYPE): Likewise.
14797 (linux_detach_one_lwp): Cast fourth argument of
14798 ptrace to long then PTRACE_ARG4_TYPE.
14799 (regsets_fetch_inferior_registers): Cast third argument of
14800 ptrace to long then PTRACE_ARG3_TYPE.
14801 (regsets_store_inferior_registers): Likewise.
14803 2012-04-20 Pedro Alves <palves@redhat.com>
14805 * configure: Regenerate.
14807 2012-04-19 Pedro Alves <palves@redhat.com>
14809 * Makefile.in (GNULIB_BUILDDIR): New.
14810 (LIBGNU, INCGNU, GNULIB_H): Adjust.
14811 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14812 (all, install-only, uninstall, clean-info, all-lib, clean): No
14813 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14814 (maintainer-clean realclean distclean): Use subdir_do.
14816 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
14817 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
14818 * acinclude.m4: Include acx_configure_dir.m4.
14819 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14820 calls. Call AC_PROG_RANLIB. Configure gnulib using
14823 (GNULIB_STDINT_H): Adjust.
14824 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14825 * gdbreplay.c: Include build-gnulib/config.h.
14826 * server.h: Likewise.
14827 * aclocal.m4: Regenerate.
14828 * config.in: Regenerate.
14829 * configure: Regenerate.
14831 2012-04-19 Pedro Alves <palves@redhat.com>
14833 * Makefile.in (LIBGNU, INCGNU): Adjust.
14834 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14835 (all, install-only, uninstall, clean-info, all-lib, clean)
14836 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14837 * configure.ac: Adjust AC_OUTPUT output.
14838 * aclocal.m4: Regenerate.
14839 * configure: Regenerate.
14841 2012-04-19 Pedro Alves <palves@redhat.com>
14843 * Makefile.in (generated_files): New.
14844 (server_h): Remove the explicit dependency on config.h, and depend
14845 on $generated_files.
14847 2012-04-19 Pedro Alves <palves@redhat.com>
14849 * Makefile.in (INCGNU): Add -Ignulib.
14851 2012-04-19 Pedro Alves <palves@redhat.com>
14853 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14854 (INCGNU): ... this, and spell out -I here.
14855 (GNULIB_LIB): Rename to ...
14856 (LIBGNU): ... this.
14857 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14859 2012-04-19 Pedro Alves <palves@redhat.com>
14861 * config.in: Regenerate.
14863 2012-04-19 Pedro Alves <palves@redhat.com>
14865 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14866 * server.h (memmem): Remove declaration.
14867 * config.in: Regenerate.
14868 * configure: Regenerate.
14870 2012-04-19 Yao Qi <yao@codesourcery.com>
14872 * Makefile.in (SFILES): Add common/vec.c.
14876 2012-04-19 Yao Qi <yao@codesourcery.com>
14878 * remote-utils.c (prepare_resume_reply): Replace with macro
14879 target_core_of_thread.
14880 * server.c (handle_qxfer_threads_proper): Likewise.
14881 * target.h (traget_core_of_thread): New macro.
14883 2012-04-18 Pedro Alves <palves@redhat.com>
14885 * aclocal.m4: Regenerate.
14886 * configure: Regenerate.
14888 2012-04-16 Yao Qi <yao@codesourcery.com>
14890 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14891 duplicated on address.
14893 2012-04-16 Yao Qi <yao@codesourcery.com>
14895 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14896 (struct tracepoint_action_ops) <send>: New field.
14897 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14898 (agent_expr_send, x_tracepoint_action_send): New.
14899 (l_tracepoint_action_send): New.
14900 (cmd_qtdp): Download and install tracepoint
14901 according to `use_agent'.
14902 (run_inferior_command): Add one more parameter `len'.
14904 (tracepoint_send_agent): New.
14905 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14907 2012-04-16 Yao Qi <yao@codesourcery.com>
14909 * tracepoint.c (download_tracepoints): Moved to ...
14910 (cmd_qtstart): ... here.
14912 2012-04-14 Yao Qi <yao@codesourcery.com>
14914 * tracepoint.c: Include inttypes.h.
14915 (struct collect_memory_action): Use sized types.
14916 (struct tracepoint): Likewise.
14917 (cmd_qtdp, stop_tracing): Update print specifiers.
14918 (cmd_qtp, response_tracepoint): Likewise.
14919 (collect_data_at_tracepoint): Likewise.
14920 (collect_data_at_step): Likewise.
14922 2012-04-14 Yao Qi <yao@codesourcery.com>
14924 Import gnulib module inttypes.
14925 * aclocal.m4, config.in, configure: Regenerated.
14927 2012-04-14 Yao Qi <yao@codesourcery.com>
14929 * Makefile.in (maintainer-clean, realclean, distclean): Remove
14930 Makefile and config.status at last.
14932 2012-04-13 Yao Qi <yao@codesourcery.com>
14934 * tracepoint.c: Include stdint.h unconditionally.
14936 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14938 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
14939 on BFD_HAVE_SYS_PROCFS_TYPE.
14940 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
14941 * configure: Regenerate.
14942 * config.in: Likewise.
14944 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
14946 * Makefile.in (clean): Also remove x32.c x32-linux.c
14947 x32-avx.c x32-avx-linux.c.
14948 (x32.o): New target.
14950 (x32-linux.o): Likewise.
14951 (x32-linux.c): Likewise.
14952 (x32-avx.o): Likewise.
14953 (x32-avx.c): Likewise.
14954 (x32-avx-linux.o): Likewise.
14955 (x32-avx-linux.c): Likewise.
14957 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
14958 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
14959 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
14960 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
14961 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
14962 i386/x32-avx-linux.xml.
14964 * linux-x86-low.c (init_registers_x32_linux): New prototype.
14965 (init_registers_x32_avx_linux): Likwise.
14966 (x86_linux_update_xmltarget): Call init_registers_x32_linux
14967 or init_registers_x32_avx_linux if linux_is_elf64 is false.
14969 2012-04-13 Pedro Alves <palves@redhat.com>
14971 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
14972 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
14973 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
14974 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
14977 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14979 * linux-x86-low.c (compat_x32_clock_t): New.
14980 (compat_x32_siginfo_t): Likewise.
14981 (compat_x32_siginfo_from_siginfo): Likewise.
14982 (siginfo_from_compat_x32_siginfo): Likewise.
14983 (linux_is_elf64): Likewise.
14984 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
14985 and siginfo_from_compat_x32_siginfo for x32.
14986 (x86_arch_setup): Set linux_is_elf64.
14988 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14991 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
14993 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
14994 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
14995 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
14996 compatible with process.
14998 2012-04-12 Yao Qi <yao@codesourcery.com>
15000 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15001 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15002 (install-only, install-info, clean): Handle sub dir gnulib.
15003 (all-lib, am--refresh): New targets.
15004 (memmem.o): Remove target.
15005 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15006 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15007 (AC_REPLACE_FUNCS): Remove memmem.
15008 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15009 (AC_OUTPUT): Generate Makefile in gnulib/.
15010 * aclocal.m4, config.in, configure: Regenerated.
15012 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15014 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15016 2012-04-05 Pedro Alves <palves@redhat.com>
15018 -Werror=strict-aliasing
15020 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15023 2012-04-04 Pedro Alves <palves@redhat.com>
15025 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15026 (sparc_store_gregset_from_stack, sparc_store_gregset)
15027 (sparc_breakpoint_at): Fix formatting.
15029 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15031 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15033 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15034 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15035 * config.in: Regenerate.
15036 * configure: Likewise.
15038 2012-03-29 Pedro Alves <palves@redhat.com>
15040 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15041 Correct ptrace arguments.
15043 2012-03-28 Pedro Alves <palves@redhat.com>
15045 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15046 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15047 (IA64_FR1_REGNUM): New defines.
15048 (ia64_fetch_register): New.
15049 (the_low_target): Install it.
15050 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15052 * linux-low.c (linux_fetch_registers): Try the
15053 the_low_target.fetch_register hook first.
15055 * linux-arm-low.c (the_low_target): Adjust.
15056 * linux-bfin-low.c (the_low_target): Adjust.
15057 * linux-cris-low.c (the_low_target): Adjust.
15058 * linux-crisv32-low.c (the_low_target): Adjust.
15059 * linux-m32r-low.c (the_low_target): Adjust.
15060 * linux-m68k-low.c (the_low_target): Adjust.
15061 * linux-mips-low.c (the_low_target): Adjust.
15062 * linux-ppc-low.c (the_low_target): Adjust.
15063 * linux-s390-low.c (the_low_target): Adjust.
15064 * linux-sh-low.c (the_low_target): Adjust.
15065 * linux-sparc-low.c (the_low_target): Adjust.
15066 * linux-tic6x-low.c (the_low_target): Adjust.
15067 * linux-x86-low.c (the_low_target): Adjust.
15068 * linux-xtensa-low.c (the_low_target): Adjust.
15070 2012-03-26 Pedro Alves <palves@redhat.com>
15072 * server.c (handle_qxfer_libraries): Don't bail early if
15073 the_target->qxfer_libraries_svr4 is not NULL.
15075 2012-03-26 Pedro Alves <palves@redhat.com>
15077 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15079 2012-03-23 Pedro Alves <palves@redhat.com>
15081 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15082 "library-list-svr4" element's start tag when the the DSO list is
15085 2012-03-23 Pedro Alves <palves@redhat.com>
15087 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15088 a variable whose type size is the same as the inferior's pointer
15091 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15093 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15095 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15096 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15097 * linux-low.h: Include <signal.h>.
15098 (struct siginfo): Remove forward declaration.
15099 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15102 2012-03-21 Mike Frysinger <vapier@gentoo.org>
15104 * .gitignore: Ignore more files.
15106 2012-03-19 Pedro Alves <palves@redhat.com>
15107 Jan Kratochvil <jan.kratochvil@redhat.com>
15109 * server.c (cont_thread, general_thread): Add describing comments.
15110 (start_inferior): Clear `cont_thread'.
15111 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15114 2012-03-15 Yao Qi <yao@codesourcery.com>
15116 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15118 (cmd_qtdp): ... here.
15120 2012-03-15 Yao Qi <yao@codesourcery.com>
15122 * tracepoint.c (struct tracepoint_action_ops): New.
15123 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15124 (m_tracepoint_action_download): New.
15125 (r_tracepoint_action_download): New.
15126 (x_tracepoint_action_download): New.
15127 (l_tracepoint_action_download): New.
15128 (add_tracepoint_action): Install `action->ops' according type.
15129 (download_tracepoint_1): Move code `download' function pointer
15130 of various tracepoint_action_ops.
15132 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15134 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15135 linux_ptrace_attach_warnings.
15137 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15139 * Makefile.in (linux-ptrace.o): New.
15140 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15141 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15142 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15143 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15144 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15146 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15148 2012-03-08 Yao Qi <yao@codesourcery.com>
15149 Pedro Alves <palves@redhat.com>
15151 Fix PR server/13392.
15152 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15153 offset of JMP insn.
15154 * tracepoint.c (remove_tracepoint): New.
15155 (cmd_qtdp): Call remove_tracepoint when failed to install.
15157 2012-03-07 Pedro Alves <palves@redhat.com>
15159 * linux-low.c (get_detach_signal): New.
15160 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15161 Pass on pending signals to PTRACE_DETACH. Check the result of the
15163 * server.c (program_signals, program_signals_p): New.
15164 (handle_general_set): Handle QProgramSignals.
15165 * server.h (program_signals, program_signals_p): Declare.
15167 2012-03-05 Pedro Alves <palves@redhat.com>
15168 Jan Kratochvil <jan.kratochvil@redhat.com>
15170 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15173 2012-03-03 Yao Qi <yao@codesourcery.com>
15175 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15176 agent_look_up_symbols.
15178 2012-03-03 Yao Qi <yao@codesourcery.com>
15180 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15181 (linux-x86-low.o): Likewise.
15182 * server.h: Remove in_process_agent_loaded.
15183 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15187 2012-03-03 Yao Qi <yao@codesourcery.com>
15189 * tracepoint.c (gdb_agent_capability): New global.
15190 (in_process_agent_loaded_ust): Renamed to
15191 `in_process_agent_supports_ust'.
15193 (in_process_agent_supports_ust): Call agent_capability_check.
15194 (clear_installed_tracepoints): Assert that agent supports
15197 2012-03-03 Yao Qi <yao@codesourcery.com>
15199 * linux-low.c (linux_supports_agent): New.
15200 (linux_target_ops): Initialize field `supports_agent' with
15201 linux_supports_agent.
15202 * target.h (struct target_ops) <supports_agent>: New.
15203 (target_supports_agent): New macro.
15204 * server.c (handle_general_set): Handle packet 'QAgent'.
15205 (handle_query): Send `QAgent+'.
15206 * Makefile.in (server.o): Depends on agent.h.
15208 2012-03-03 Yao Qi <yao@codesourcery.com>
15210 * Makefile.in (OBS): Add agent.o.
15211 Add new rule for agent.o.
15212 Track dependence of tracepoint.c on agent.h.
15213 * tracepoint.c (run_inferior_command_1):
15214 (run_inferior_command): Call agent_run_command.
15215 (gdb_ust_connect_sync_socket): Deleted. Move it to
15217 (resume_thread, stop_thread): Likewise.
15218 (gdb_ust_socket_init): Renamed to ...
15219 (gdb_agent_socket_init): ... New.
15220 (gdb_ust_thread): Renamed to ...
15221 (gdb_agent_helper_thread): ... New.
15222 (gdb_ust_init): Move some code to ...
15223 (gdb_agent_init): ... here. New.
15224 [HAVE_UST]: Call gdb_ust_init.
15225 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15226 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15227 * config.in, configure: Regenerated.
15229 2012-03-02 Pedro Alves <palves@redhat.com>
15231 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15232 * linux-low.c (struct simple_pid_list): New.
15233 (stopped_pids): New a struct simple_pid_list pointer.
15234 (add_to_pid_list, pull_pid_from_list): New.
15235 (handle_extended_wait): Don't assume the first signal new children
15236 report is SIGSTOP. Adjust call to pull_pid_from_list.
15237 (linux_wait_for_lwp): Adjust.
15239 2012-03-02 Yao Qi <yao@codesourcery.com>
15241 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15244 2012-03-02 Yao Qi <yao@codesourcery.com>
15246 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15247 `stop_pc' and `tpoint'. Update caller.
15249 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15251 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15252 * linux-low.c (use_linux_regsets): New macro.
15253 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15254 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15255 (linux_register_in_regsets): New function.
15256 (usr_fetch_inferior_registers): Skip registers covered by
15258 (usr_store_inferior_registers): Likewise.
15259 (usr_fetch_inferior_registers): New macro.
15260 (usr_store_inferior_registers): Likewise.
15261 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15262 (linux_store_registers): Likewise.
15263 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15265 (init_registers_mips64_dsp_linux): Likewise.
15266 (init_registers_mips_linux): New macro.
15267 (init_registers_mips_dsp_linux): Likewise.
15268 (mips_dsp_num_regs): Likewise.
15269 (DSP_BASE, DSP_CONTROL): New fallback macros.
15270 (mips_base_regs): New macro.
15271 (mips_regmap): Use it. Fix the size.
15272 (mips_dsp_regmap): New variable.
15273 (mips_dsp_regset_bitmap): Likewise.
15274 (mips_arch_setup): New function.
15275 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15277 (mips_cannot_store_register): Likewise.
15278 (the_low_target): Update .arch_setup, .num_regs and .regmap
15279 initializers. Add .regset_bitmap initializer.
15280 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15282 * linux-bfin-low.c (the_low_target): Likewise.
15283 * linux-cris-low.c (the_low_target): Likewise.
15284 * linux-crisv32-low.c (the_low_target): Likewise.
15285 * linux-ia64-low.c (the_low_target): Likewise.
15286 * linux-m32r-low.c (the_low_target): Likewise.
15287 * linux-m68k-low.c (the_low_target): Likewise.
15288 * linux-ppc-low.c (the_low_target): Likewise.
15289 * linux-s390-low.c (the_low_target): Likewise.
15290 * linux-sh-low.c (the_low_target): Likewise.
15291 * linux-sparc-low.c (the_low_target): Likewise.
15292 * linux-tic6x-low.c (the_low_target): Likewise.
15293 * linux-x86-low.c (the_low_target): Likewise.
15294 * linux-xtensa-low.c (the_low_target): Likewise.
15295 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15296 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15297 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15299 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15300 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15302 2012-02-29 Yao Qi <yao@codesourcery.com>
15303 Pedro Alves <palves@redhat.com>
15305 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15306 `step_over_finished' is true.
15308 2012-02-27 Pedro Alves <palves@redhat.com>
15310 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15311 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15313 2012-02-27 Pedro Alves <palves@redhat.com>
15316 * linux-low.c (pid_is_stopped): New.
15317 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15319 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15321 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15324 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15326 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15328 2012-02-24 Luis Machado <lgustavo@codesourcery>
15330 * server.c (handle_query): Advertise support for target-side
15331 breakpoint condition evaluation.
15332 (process_point_options): New function.
15333 (process_serial_event): When inserting a breakpoint, check for
15334 a target-side condition that should be evaluated.
15336 * mem-break.c: Include regcache.h and ax.h.
15337 (point_cond_list_t): New data structure.
15338 (breakpoint) <cond_list>: New field.
15339 (find_gdb_breakpoint_at): Make non-static.
15340 (delete_gdb_breakpoint_at): Clear any target-side
15342 (clear_gdb_breakpoint_conditions): New function.
15343 (add_condition_to_breakpoint): Likewise.
15344 (add_breakpoint_condition): Likewise.
15345 (gdb_condition_true_at_breakpoint): Likewise.
15346 (gdb_breakpoint_here): Return result directly instead
15347 of going through a local variable.
15349 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15350 (clear_gdb_breakpoint_conditions): Likewise.
15351 (add_breakpoint_condition): Likewise.
15352 (gdb_condition_true_at_breakpoint): Likewise.
15354 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15355 (need_step_over_p): Take target-side breakpoint condition into
15358 2012-02-24 Luis Machado <lgustavo@codesourcery>
15360 * server.h: Include tracepoint.h.
15361 (agent_mem_read, agent_get_trace_state_variable_value,
15362 agent_set_trace_state_variable_value,
15363 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15364 get_set_tsv_func_addr): New prototypes.
15366 * ax.h: New include file.
15367 * ax.c: New source file.
15369 * tracepoint.c: Include ax.h.
15370 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15371 agent_expr, eval_result_type): Move to ax.h.
15372 (parse_agent_expr): Rename to ...
15373 (gdb_parse_agent_expr): ... this, make it non-static and move
15375 (unparse_agent_expr) Rename to ...
15376 (gdb_unparse_agent_expr): ... this, make it non-static and move
15378 (eval_agent_expr): Rename to ...
15379 (eval_tracepoint_agent_expr): ... this.
15380 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15381 forward declarations.
15382 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15383 (agent_get_trace_state_variable_value): New function.
15384 (agent_set_trace_state_variable_value): New function.
15385 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15386 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15387 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15388 (condition_true_at_tracepoint): Likewise.
15389 (parse_agent_expr): Rename to ...
15390 (gdb_parse_agent_expr): ... this and move to ax.c.
15391 (unparse_agent_expr): Rename to ...
15392 (gdb_unparse_agent_expr): ... this and move to ax.c.
15393 (gdb_agent_op_name): Move to ax.c.
15394 (eval_agent_expr): Rename to ...
15395 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15397 (eval_tracepoint_agent_expr): New function.
15398 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15400 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15402 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15403 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15404 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15405 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15406 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15407 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15408 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15409 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15410 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15411 (compile_bytecodes): Remove forward declaration.
15412 (is_goto_target): Move to ax.c.
15413 (compile_bytecodes): Move to ax.c and call
15414 agent_get_trace_state_variable_value (...) and
15415 agent_set_trace_state_variable_value (...).
15417 * Makefile.in: Update ax.c and IPA dependencies.
15419 2012-02-24 Pedro Alves <palves@redhat.com>
15421 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15422 (cmd_bigqtbuffer_circular): ... this. Only handle
15423 'QTBuffer:circular:'.
15424 (handle_tracepoint_general_set): Adjust.
15426 2012-02-16 Yao Qi <yao@codesourcery.com>
15428 * inferiors.c: Move code to ...
15429 * dll.c: .... here. New.
15430 * server.h: Declare clear_dlls.
15431 * Makefile.in (SFILES): Add dll.c.
15435 2012-02-11 Yao Qi <yao@codesourcery.com>
15437 * server.c: (handle_monitor_command): Add a new parameter
15439 (handle_query): Update caller.
15441 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15443 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15444 * configure, config.in: Regenerate.
15445 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15448 2012-02-02 Pedro Alves <palves@redhat.com>
15450 Try SIGKILL first, then PTRACE_KILL.
15451 * linux-low.c (linux_kill_one_lwp): New.
15452 (linux_kill_one_lwp): Rename to ...
15453 (kill_one_lwp_callback): ... this. Use the new
15454 linux_kill_one_lwp.
15456 2012-02-02 Pedro Alves <palves@redhat.com>
15458 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15461 2012-01-27 Pedro Alves <palves@redhat.com>
15463 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15464 (elf_64_file_p): Make static.
15465 (linux_pid_exe_is_elf_64_file): New.
15466 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15467 Delete declarations.
15468 (linux_pid_exe_is_elf_64_file): Declare.
15469 * linux-x86-low.c (x86_arch_setup): Use
15470 linux_pid_exe_is_elf_64_file.
15472 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15474 * linux-low.c (linux_wait_for_event_1): Rename to ...
15475 (linux_wait_for_event): ... here and merge it with former
15476 linux_wait_for_event - new variable wait_ptid, use it.
15477 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15479 2012-01-23 Pedro Alves <palves@redhat.com>
15481 * server.c (main): Avoid yet another case of infinite loop while
15482 detaching/killing after a longjmp.
15484 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15487 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15489 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15491 * hostio.c (handle_readlink): New function.
15492 (handle_vFile): Call it to handle "vFile:readlink" packets.
15494 2012-01-20 Pedro Alves <palves@redhat.com>
15495 Ulrich Weigand <ulrich.weigand@linaro.org>
15497 * server.c (handle_v_requests): Only support vAttach and vRun to
15498 start multiple processes when in extended protocol mode.
15500 2012-01-17 Pedro Alves <palves@redhat.com>
15502 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15503 memalign plus mprotect to allocate the scratch buffer.
15505 2012-01-13 Pedro Alves <palves@redhat.com>
15507 * server.c (attach_inferior): Clear `cont_thread'.
15509 2012-01-13 Pedro Alves <palves@redhat.com>
15511 * server.c (main): Avoid infinite loop while detaching/killing
15514 2012-01-09 Doug Evans <dje@google.com>
15516 * server.c (start_inferior): Set last_ptid in --wrapper case.
15518 2012-01-06 Yao Qi <yao@codesourcery.com>
15520 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15522 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15524 2012-01-04 Yao Qi <yao@codesourcery.com>
15526 * tracepoint.c (cmd_qtdp): Print debug message
15527 for static tracepoint.
15529 2012-01-04 Yao Qi <yao@codesourcery.com>
15531 * tracepoint.c (trace_vdebug): Differentiate debug message
15532 between gdbserver and IPA.
15534 2012-01-03 Yao Qi <yao@codesourcery.com>
15536 * tracepoint.c (tracepoint_was_hit): Don't collect for
15539 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15541 * terminal.h: Reformat copyright header.
15543 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15545 * server.c (gdbserver_version): Update copyright year.
15546 * gdbreplay.c (gdbreplay_version): Likewise.
15548 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15550 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15553 2011-12-18 Hui Zhu <teawater@gmail.com>
15554 * linux-low.c (linux_create_inferior): Save return value to ret.
15556 2011-12-18 Hui Zhu <teawater@gmail.com>
15558 * linux-low.c (linux_create_inferior): Save return value to ret.
15560 2011-12-16 Doug Evans <dje@google.com>
15562 * linux-low.c (linux_create_inferior): If stdio connection,
15563 redirect stdin from /dev/null, stdout to stderr.
15564 * remote-utils.c (remote_is_stdio): New static global.
15565 (remote_connection_is_stdio): New function.
15566 (remote_prepare): Handle stdio connection.
15567 (remote_open): Ditto.
15568 (remote_close): Don't close stdin for stdio connections.
15569 (read_prim,write_prim): New functions. Replace all calls to
15570 read/write to these.
15571 * server.c (main): Watch for "-" argument. Move call to
15572 remote_prepare before start_inferior.
15573 * server.h (STDIO_CONNECTION_NAME): New macro.
15574 (remote_connection_is_stdio): Declare.
15576 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15577 in debugging output.
15579 2011-12-15 Yao Qi <yao@codesourcery.com>
15581 * tracepoint.c: Include sys/syscall.h.
15582 (gdb_ust_thread): Remove preprocessor conditional.
15584 2011-12-14 Pedro Alves <pedro@codesourcery.com>
15586 * linux-low.c (linux_detach_one_lwp): Call
15587 the_low_target.prepare_to_resume before detaching.
15589 2011-12-14 Yao Qi <yao@codesourcery.com>
15591 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15594 2011-12-14 Yao Qi <yao@codesourcery.com>
15596 * i386-low.c (i386_low_stopped_data_address): Initialize local
15597 variable `control'.
15599 2011-12-13 Pedro Alves <pedro@codesourcery.com>
15603 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15604 DR_CONTROL unless necessary. Extend comments.
15605 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15606 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15608 2011-12-13 Yao Qi <yao@codesourcery.com>
15610 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15612 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15614 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15616 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15617 Print new debug message for such case.
15619 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15621 Fix overlapping memcpy.
15622 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15623 the read_inferior_memory transfer.
15624 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15625 write_inferior_memory transfer.
15626 (set_fast_tracepoint_jump): New variable buf. Use it for the
15627 read_inferior_memory and write_inferior_memory transfers.
15628 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15629 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15630 Use it for the write_inferior_memory transfer.
15631 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15634 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15636 * linux-low.c (fetch_register, store_register): Make code
15637 consistent, fix formatting.
15639 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15641 * linux-low.c (usr_store_inferior_registers): Factor out code
15642 to handle individual registers into...
15643 (store_register): ... this new function.
15645 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15647 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15648 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15649 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15650 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15651 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15652 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15653 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15654 (srv_xmlfiles): Add new XML files.
15656 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15658 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15659 (init_registers_s390_linux32v1): Add prototype.
15660 (init_registers_s390_linux32v2): Likewise.
15661 (init_registers_s390_linux64v1): Likewise.
15662 (init_registers_s390_linux64v2): Likewise.
15663 (init_registers_s390x_linux64v1): Likewise.
15664 (init_registers_s390x_linux64v2): Likewise.
15665 (s390_num_regs): Increment to 52.
15666 (s390_regmap): Add orig_r2 register.
15667 (s390_num_regs_3264): Increment to 68.
15668 (s390_regmap_3264): Add orig_r2 register.
15669 (s390_collect_ptrace_register): Handle orig_r2 register.
15670 (s390_supply_ptrace_register): Likewise.
15671 (s390_fill_last_break): New function.
15672 (s390_store_last_break): Likewise.
15673 (s390_fill_system_call): New function.
15674 (s390_store_system_call): Likewise.
15675 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15677 (s390_check_regset): New function.
15678 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15679 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15680 Update target_regsets for available register sets.
15682 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15683 Jan Kratochvil <jan.kratochvil@redhat.com>
15685 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15686 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15688 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15689 * linux-low.h (struct process_info_private): New member r_debug.
15690 * server.c (handle_qxfer_libraries): Call
15691 the_target->qxfer_libraries_svr4.
15692 (handle_qxfer_libraries_svr4): New function.
15693 (qxfer_packets): New entry "libraries-svr4".
15694 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15695 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15696 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15697 PACKET_qXfer_libraries_svr4.
15699 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15701 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15702 PSW address/mask between 8-byte and 16-byte formats.
15703 (s390_supply_ptrace_register): Likewise.
15704 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15705 basic addressing mode bit.
15707 2011-11-24 Stan Shebs <stan@codesourcery.com>
15709 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15711 2011-11-17 Stan Shebs <stan@codesourcery.com>
15713 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15714 (tracing_start_time): New global.
15715 (tracing_stop_time): New global.
15716 (tracing_user_name): New global.
15717 (tracing_notes): New global.
15718 (tracing_stop_note): New global.
15719 (cmd_qtstart): Set traceframe_usage, start_time.
15720 (stop_tracing): Set stop_time.
15721 (cmd_qtstatus): Report additional status.
15722 (cmd_qtp): New function.
15723 (handle_tracepoint_query): Call it.
15724 (cmd_qtnotes): New function.
15725 (handle_tracepoint_general_set): Call it.
15726 (get_timestamp): Rename from tsv_get_timestamp.
15728 2011-11-14 Stan Shebs <stan@codesourcery.com>
15729 Kwok Cheung Yeung <kcy@codesourcery.com>
15731 * linux-x86-low.c (small_jump_insn): New.
15732 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15733 trampoline and error message, build a trampoline and issue a small
15734 jump instruction to it.
15735 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15736 trampoline and error message.
15737 (x86_get_min_fast_tracepoint_insn_len): New.
15738 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15739 * linux-low.h (struct linux_target_ops): Add arguments to
15740 install_fast_tracepoint_jump_pad operation, add new operation.
15741 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15743 (linux_get_min_fast_tracepoint_insn_len): New function.
15744 (linux_target_op): Add new operation.
15745 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15746 (gdb_trampoline_buffer_end): Ditto.
15747 (gdb_trampoline_buffer_error): Ditto.
15748 (struct ipa_sym_addresses): Add fields for new IPA variables.
15749 (symbol_list): Add entries for new IPA variables.
15750 (struct tracepoint): Add fields to hold the address range of the
15751 trampoline used by the tracepoint.
15752 (trampoline_buffer_head): New static variable.
15753 (trampoline_buffer_tail): Ditto.
15754 (claim_trampoline_space): New function.
15755 (have_fast_tracepoint_trampoline_buffer): New function.
15756 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15758 (install_fast_tracepoint): Ditto, also add error buffer argument.
15759 (cmd_qtminftpilen): New function.
15760 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15761 (fast_tracepoint_from_trampoline_address): New function.
15762 (fast_tracepoint_collecting): Handle trampoline as part of jump
15764 (set_trampoline_buffer_space): New function.
15765 (initialize_tracepoint): Initialize new IPA variables.
15766 * target.h (struct target_ops): Add arguments to
15767 install_fast_tracepoint_jump_pad operation, add new
15768 get_min_fast_tracepoint_insn_len operation.
15769 (target_get_min_fast_tracepoint_insn_len): New.
15770 (install_fast_tracepoint_jump_pad): Add arguments.
15771 * server.h (IPA_BUFSIZ): Define.
15772 * linux-i386-ipa.c: Include extra header files.
15773 (initialize_fast_tracepoint_trampoline_buffer): New function.
15774 (initialize_low_tracepoint): Call it.
15775 * server.h (set_trampoline_buffer_space): Declare.
15776 (claim_trampoline_space): Ditto.
15777 (have_fast_tracepoint_trampoline_buffer): Ditto.
15779 2011-11-14 Yao Qi <yao@codesourcery.com>
15781 * server.c (handle_query): Handle InstallInTrace for qSupported.
15782 * tracepoint.c (add_tracepoint): Sort list.
15783 (install_tracepoint, download_tracepoint): New.
15784 (cmd_qtdp): Call them to install and download tracepoints.
15785 (sort_tracepoints): Removed.
15786 (cmd_qtstart): Update.
15788 2011-11-14 Yao Qi <yao@codesourcery.com>
15790 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15791 * mem-break.h: Declare.
15792 * tracepoint.c (cmd_qtstart): Move some code to ...
15793 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15795 (download_tracepoints): Move some code to ...
15796 (download_tracepoint_1): ... here. New.
15798 2011-11-08 Yao Qi <yao@codesourcery.com>
15800 * remote-utils.c (relocate_instruction): A comment fix.
15802 2011-11-07 Joel Brobecker <brobecker@adacore.com>
15804 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15805 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15806 dr_status_mirror and dr_control_mirror from debug_reg_state.
15807 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15808 (i386_initial_stuff): Remove use of deleted globals.
15809 (i386_get_thread_context, i386_set_thread_context,
15810 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15811 from debug_reg_state.
15813 2011-11-05 Yao Qi <yao@codesourcery.com>
15815 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15816 address as TPOINT's.
15818 2011-11-02 Stan Shebs <stan@codesourcery.com>
15820 * tracepoint.c (agent_mem_read_string): New function.
15821 (eval_agent_expr): Call it for tracenz.
15822 * server.c (handle_query): Report support for tracenz.
15824 2011-11-02 Yao Qi <yao@codesourcery.com>
15826 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15828 2011-11-02 Yao Qi <yao@codesourcery.com>
15830 * target.h: Fix a typo in comment.
15832 2011-10-31 Pedro Alves <pedro@codesourcery.com>
15834 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15835 clobber the breakpoints' shadows with fast tracepoint jumps.
15836 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15837 * target.c (write_inferior_memory): Also pass MYADDR down to
15840 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15842 * configure.ac: Check support for personality routine.
15843 * configure: Regenerate.
15844 * config.in: Likewise.
15845 * linux-low.c: Include <sys/personality.h>.
15846 Define ADDR_NO_RANDOMIZE if necessary.
15847 (linux_create_inferior): Disable address space randomization when
15848 forking inferior, if requested.
15849 (linux_supports_disable_randomization): New function.
15850 (linux_target_ops): Install it.
15851 * server.h (disable_randomization): Declare.
15852 * server.c (disable_randomization): New global variable.
15853 (handle_general_set): Handle QDisableRandomization.
15854 (handle_query): Likewise for qSupported.
15855 (main): Support --disable-randomization and --no-disable-randomization
15856 command line arguments.
15857 * target.h (struct target_ops): Add supports_disable_randomization.
15858 (target_supports_disable_randomization): New macro.
15860 2011-09-29 Mike Frysinger <vapier@gentoo.org>
15862 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15864 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15865 [!PT_GETDSBT] (target_loadmap): New definition.
15866 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15867 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15868 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15869 and PT_GETDSBT to LINUX_LOADMAP.
15870 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15871 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15873 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15875 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15876 (arm_linux_hwbp_cap): New static variable.
15877 (arm_linux_get_hwbp_cap): Replace by ...
15878 (arm_linux_init_hwbp_cap): ... this new function.
15879 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15880 (arm_linux_get_hw_watchpoint_count): Likewise.
15881 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15882 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15883 (arm_prepare_to_resume): Use perror_with_name instead of error.
15885 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15887 * linux-arm-low.c: Include <signal.h>.
15888 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15889 (struct arm_linux_hwbp_cap): New data type.
15890 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15891 (struct arm_linux_hw_breakpoint): New data type.
15892 (MAX_BPTS, MAX_WPTS): Define.
15893 (struct arch_process_info, struct arch_lwp_info): New data types.
15894 (arm_linux_get_hwbp_cap): New function.
15895 (arm_linux_get_hw_breakpoint_count): Likewise.
15896 (arm_linux_get_hw_watchpoint_count): Likewise.
15897 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15898 (arm_hwbp_control_initialize): Likewise.
15899 (arm_hwbp_control_is_enabled): Likewise.
15900 (arm_hwbp_control_is_initialized): Likewise.
15901 (arm_hwbp_control_disable): Likewise.
15902 (arm_linux_hw_breakpoint_equal): Likewise.
15903 (arm_linux_hw_point_initialize): Likewise.
15904 (struct update_registers_data): New data structure.
15905 (update_registers_callback: New function.
15906 (arm_insert_point): Likewise.
15907 (arm_remove_point): Likewise.
15908 (arm_stopped_by_watchpoint): Likewise.
15909 (arm_stopped_data_address): Likewise.
15910 (arm_new_process): Likewise.
15911 (arm_new_thread): Likewise.
15912 (arm_prepare_to_resume): Likewise.
15913 (the_low_target): Register arm_insert_point, arm_remove_point,
15914 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15915 arm_new_thread, and arm_prepare_to_resume.
15917 2011-09-15 Stan Shebs <stan@codesourcery.com>
15919 * server.h (struct emit_ops): Add compare-goto fields.
15920 * tracepoint.c (gdb_agent_op_sizes): New table.
15921 (emit_eq_goto): New function.
15922 (emit_ne_goto): New function.
15923 (emit_lt_goto): New function.
15924 (emit_le_goto): New function.
15925 (emit_gt_goto): New function.
15926 (emit_ge_goto): New function.
15927 (is_goto_target): New function.
15928 (compile_bytecodes): Recognize special cases of compare-goto
15929 combinations and call specialized emitters for them.
15930 * linux-x86-low.c (amd64_emit_eq_goto): New function.
15931 (amd64_emit_ne_goto): New function.
15932 (amd64_emit_lt_goto): New function.
15933 (amd64_emit_le_goto): New function.
15934 (amd64_emit_gt_goto): New function.
15935 (amd64_emit_ge_goto): New function.
15936 (amd64_emit_ops): Add the new functions.
15937 (i386_emit_eq_goto): New function.
15938 (i386_emit_ne_goto): New function.
15939 (i386_emit_lt_goto): New function.
15940 (i386_emit_le_goto): New function.
15941 (i386_emit_gt_goto): New function.
15942 (i386_emit_ge_goto): New function.
15943 (i386_emit_ops): Add the new functions.
15945 2011-09-08 Stan Shebs <stan@codesourcery.com>
15947 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
15948 (i386_emit_epilogue): Restore %ebx.
15950 2011-08-31 Jie Zhang <jzhang918@gmail.com>
15952 * server.c (step_thread): Remove definition.
15953 (process_serial_event): Don't handle Hs.
15954 * server.h (step_thread): Remove declaration.
15955 * target.c (set_desired_inferior): Remove use of step_thread.
15957 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
15959 * linux-low.c: Include linux-procfs.h.
15960 (linux_attach_lwp_1): Update comments.
15961 (linux_attach): Scan for existing threads when attaching to a
15962 process that is the tgid.
15963 * Makefile.in: Update dependencies.
15965 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
15967 * configure.srv: Add linux-procfs.o dependencies.
15969 2011-08-14 Yao Qi <yao@codesourcery.com>
15971 * target.h (struct target_ops): Fix indent.
15972 * win32-low.c (win32_target_ops): Fix comment.
15974 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
15975 Yao Qi <yao@codesourcery.com>
15977 * Makefile.in (clean): Remove tic6x-*.c files.
15978 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
15979 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
15980 (tic6x-c64xp-linux.c): Likewise.
15981 * configure.srv: Add support for tic6x-*-uclinux.
15982 * linux-tic6x-low.c: New.
15983 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
15985 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
15986 Yao Qi <yao@codesourcery.com>
15988 * target.h (struct target_ops): Add read_loadmap.
15989 * linux-low.c (struct target_loadseg): New type.
15990 (struct target_loadmap): New type.
15991 (linux_read_loadmap): New function.
15992 (linux_target_ops): Add linux_read_loadmap.
15993 * server.c (handle_query): Support qXfer:fdpic:read packet.
15994 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
15997 2011-08-05 Eli Zaretskii <eliz@gnu.org>
15999 * win32-low.c: Include <stdint.h>.
16001 2011-07-22 Pedro Alves <pedro@codesourcery.com>
16003 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16004 to the inferior here.
16005 (i386_remove_aligned_watchpoint): Ditto.
16006 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16007 fit part of the watchpoint in the debug registers.
16008 (i386_update_inferior_debug_regs): New.
16009 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16010 registers, and only update the inferior on success.
16011 (i386_low_remove_watchpoint): Ditto.
16013 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16015 * linux-low.c (compare_ints, unique, list_threads, show_process,
16016 linux_core_of_thread): Delete.
16017 (linux_target_ops): Change linux_core_of_thread to
16018 linux_common_core_of_thread.
16019 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16020 * utils.c (malloc_failure): Change type of argument.
16021 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16022 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16023 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16024 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16025 (IPA_OBJS): Add common-utils-ipa.o.
16026 (ptid_h, linux_osdata_h): New macros.
16027 (server_h): Add common/common-utils.h, common/xml-utils.h,
16028 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16030 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16031 ptid.o, buffer.o): New rules.
16032 (linux-low.o): Add common/linux-osdata.h as a dependency.
16033 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16034 * configure.ac: Add AC_HEADER_DIRENT check.
16035 * config.in: Regenerate.
16036 * configure: Regenerate.
16037 * remote-utils.c (xml_escape_text): Delete.
16038 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16039 buffer_xml_printf): Move to common/buffer.c.
16040 * server.c (main): Remove call to initialize_inferiors.
16041 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16042 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16043 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16044 internal_error, gdb_assert, gdb_assert_fail): Delete.
16045 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16046 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16048 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16049 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16050 initialize_inferiors): Delete.
16052 2011-07-20 Pedro Alves <pedro@codesourcery.com>
16054 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16057 2011-05-31 Pedro Alves <pedro@codesourcery.com>
16059 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16061 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16063 2011-05-26 Yao Qi <yao@codesourcery.com>
16065 * Makefile.in (thread-db.o): Track dependence to
16066 common/gdb_thread_db.h.
16067 * thread-db.c: include gdb_thread_db.h from right place.
16069 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16071 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16072 __FILE__ and __LINE__ to internal_error.
16074 2011-05-13 Doug Evans <dje@google.com>
16076 * thread-db.c (try_thread_db_load_from_sdir): New function.
16077 (try_thread_db_load_from_dir): New function.
16078 (thread_db_load_search): Handle $sdir, ignore $pdir.
16079 Remove trying of system directories if search of
16080 libthread-db-search-path fails, that is now done via $sdir.
16082 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16084 * server.c (handle_query): Add EnableDisableTracepoints to the list
16085 of supported features.
16086 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
16088 (cmd_qtenable_disable): New.
16089 (cmd_qtstart): Install tracepoints even if disabled.
16090 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16091 receiving a QTEnable or QTDisable packet.
16092 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16093 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16095 (gdb_probe): Skip data collection if static tracepoint is disabled.
16097 2011-05-10 Doug Evans <dje@google.com>
16099 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16101 2011-05-04 Doug Evans <dje@google.com>
16103 * linux-low.c (linux_join): Skip process lookup.
16104 * spu-low.c (spu_join): Ditto.
16105 * server.c (join_inferiors_callback): Delete.
16106 (process_serial_event): For 'D' packet (detach) call join_inferior
16109 2011-05-04 Joseph Myers <joseph@codesourcery.com>
16111 * README: Don't mention xscale*-*-linux*.
16112 * configure.srv (xscale*-*-linux*): Don't handle target.
16114 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16116 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16118 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16119 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16120 (i386_emit_void_call_2): Likewise.
16122 2011-04-26 Yao Qi <yao@codesourcery.com>
16124 * linux-low.c: Move common macros to linux-ptrace.h.
16125 Include linux-ptrace.h.
16126 * Makefile.in (linux_ptrace_h): New.
16127 (linux-low.o): Depends on linux-ptrace.h.
16129 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16131 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16132 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16133 (remote_prepare): New function with most of the TCP code from ...
16134 (remote_open): ... here. Detect PORT here unconditionally. Move also
16135 setting transport_is_reliable.
16136 * server.c (run_once): New variable.
16137 (gdbserver_usage): Document it.
16138 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16139 the first run if RUN_ONCE.
16140 * server.h (run_once, remote_prepare): New declarations.
16142 2011-04-19 Tom Tromey <tromey@redhat.com>
16144 * win32-low.c (handle_load_dll): Remove duplicate "the".
16146 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16148 Remove support for old Cygwin 1.5 versions.
16149 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16150 function to avoid warning.
16151 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16154 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16156 * gdbserver/server.h (Macro _): Define it if not available.
16158 2011-03-14 Michael Snyder <msnyder@vmware.com>
16160 * hostio.c (handle_close): Remove unnecessary null test.
16162 2011-03-10 Joel Brobecker <brobecker@adacore.com>
16164 * Makefile.in (maintainer-clean realclean distclean): Remove
16165 "make ... subdir_do" command.
16167 2011-03-10 Michael Snyder <msnyder@vmware.com>
16169 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16171 * server.c (handle_v_run): Free alloced buffer on early return.
16173 2011-03-09 Yao Qi <yao@codesourcery.com>
16176 2011-03-04 Yao Qi <yao@codesourcery.com>
16178 * Makefile.in: Remove GNU make feature --directory.
16180 2011-03-05 Yao Qi <yao@codesourcery.com>
16182 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16183 (subdir_do): New make target. Copied from gdb/Makefile.
16184 (maintainer-clean, realclean, distclean, clean): Call corresponding
16185 make targets in common/Makefile.
16187 2011-02-11 Yao Qi <yao@codesourcery.com>
16189 * configure.ac: Call AC_PROG_RANLIB.
16190 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16191 * configure: Regenerate.
16193 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16195 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16197 2011-03-06 Yao Qi <yao@codesourcery.com>
16199 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16201 2011-03-05 Yao Qi <yao@codesourcery.com>
16203 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16204 (subdir_do): New make target. Copied from gdb/Makefile.
16205 (maintainer-clean, realclean, distclean, clean): Call corresponding
16206 make targets in common/Makefile.
16208 2011-03-04 Yao Qi <yao@codesourcery.com>
16210 * Makefile.in: Remove GNU make feature --directory.
16212 2011-03-04 Michael Snyder <msnyder@vmware.com>
16214 * server.c (queue_stop_reply): Call xmalloc not malloc.
16216 2011-03-02 Michael Snyder <msnyder@vmware.com>
16218 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16220 2011-02-28 Michael Snyder <msnyder@vmware.com>
16222 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16223 (cmd_qtframe): Ditto.
16224 (cmd_qtbuffer): Ditto.
16225 (cmd_bigqtbuffer): Ditto.
16227 * utils.c (decimal2str): Initialize 'width' to nine, then
16228 don't mess with it.
16230 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16232 * hostio.c (require_data): Free *data, not data.
16234 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16236 * hostio.c (require_data): Use free, not xfree.
16238 2011-02-27 Michael Snyder <msnyder@vmware.com>
16240 * server.c (handle_query): Discard unused value.
16242 * hostio.c (require_data): Free malloc memory before returning
16245 2011-02-26 Michael Snyder <msnyder@vmware.com>
16247 * linux-low.c (list_threads): Call closedir for dirent.
16249 2011-02-27 Michael Snyder <msnyder@vmware.com>
16251 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16252 a case statement falls through.
16254 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16256 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16259 2011-02-26 Michael Snyder <msnyder@vmware.com>
16261 * utils.c (decimal2str): Eliminate dead code and dead param.
16262 (pulongest): Drop dead param from call to decimal2str.
16265 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16267 Revert the following patch (not approved yet):
16268 2011-02-21 Hui Zhu <teawater@gmail.com>
16269 * tracepoint.c (tp_printf): New function.
16270 (eval_agent_expr): Handle gdb_agent_op_printf.
16272 2011-02-21 Hui Zhu <teawater@gmail.com>
16274 * tracepoint.c (tp_printf): New function.
16275 (eval_agent_expr): Handle gdb_agent_op_printf.
16277 2011-02-18 Tom Tromey <tromey@redhat.com>
16279 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16280 (tracepoint.o): Likewise.
16281 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16282 (gdb_agent_op_names): Likewise.
16284 2011-02-18 Tom Tromey <tromey@redhat.com>
16286 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16287 gdb_agent_op_rot>: New constants.
16288 (gdb_agent_op_names): Add pick and roll.
16289 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16292 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16294 * aclocal.m4: Regenerated with aclocal-1.11.1.
16296 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16298 * server.c (handle_qxfer_traceframe_info): New.
16299 (qxfer_packets): Register "traceframe-info".
16300 (handle_query): Report support for qXfer:traceframe-info:read+.
16301 * tracepoint.c (match_blocktype): New.
16302 (traceframe_find_block_type): Rename to ...
16303 (traceframe_walk_blocks): ... this. Add callback filter argument,
16305 (traceframe_find_block_type): New, reimplemented on top of
16306 traceframe_walk_blocks.
16307 (build_traceframe_info_xml): New.
16308 (traceframe_read_info): New.
16309 * server.h (traceframe_read_info): Declare.
16311 2011-02-11 Yao Qi <yao@codesourcery.com>
16313 * configure.ac: Call AC_PROG_RANLIB.
16314 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16315 * configure: Regenerate.
16317 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16319 * server.c (gdb_read_memory): Change return semantics to allow
16321 (handle_search_memory_1): Adjust.
16322 (process_serial_event) <'m' packet>: Handle partial transfers.
16323 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16325 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16327 * regcache.c (init_register_cache): Initialize
16328 regcache->register_status.
16329 (free_register_cache): Release regcache->register_status.
16330 (regcache_cpy): Copy register_status.
16331 (registers_to_string): Print 'x's for unavailable registers.
16332 (supply_register): Mark the register's status valid or
16333 unavailable, depending on whether a buffer was passed in or not.
16334 (supply_register_zeroed): New.
16335 (supply_regblock): Mark the registers' status valid or
16336 unavailable, depending on whether a buffer was passed in or not.
16337 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16338 (struct regcache): New `register_status' field.
16339 (supply_register_zeroed): Declare.
16340 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16341 supply_register_zeroed, rather than passing a NULL buffer to
16343 * tracepoint.c (fetch_traceframe_registers): Update comment.
16345 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16347 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16350 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16352 * server.h (decode_xfer_write): Change prototype.
16353 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16354 and don't extract the annex here.
16355 * server.c (decode_xfer_read): Remove `annex' parameter,
16356 and don't extract the annex here.
16357 (decode_xfer): New.
16358 (struct qxfer): New.
16359 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16360 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16361 (handle_qxfer_statictrace): New functions, abstracted out from
16362 handle_query, and made to use the struct qxfer interface.
16363 (handle_threads_qxfer_proper): Rename to ...
16364 (handle_qxfer_threads_proper): ... this.
16365 (handle_threads_qxfer): Rename to ...
16366 (handle_qxfer_threads): ... this. Adjust.
16367 (qxfer_packets): New array.
16368 (handle_qxfer): New function.
16369 (handle_query): Use handle_qxfer.
16371 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16373 * gdbreplay.c: Shorten lines of >= 80 columns.
16374 * linux-low.c: Ditto.
16375 * linux-ppc-low.c: Ditto.
16376 * linux-s390-low.c: Ditto.
16377 * linux-sparc-low.c: Ditto.
16378 * linux-x86-low.c: Ditto.
16379 * linux-xtensa-low.c: Ditto.
16380 * mem-break.c: Ditto.
16381 * nto-low.c: Ditto.
16382 * regcache.h: Ditto.
16383 * remote-utils.c: Ditto.
16386 * thread-db.c: Ditto.
16387 * tracepoint.c: Ditto.
16389 * win32-low.h: Ditto.
16391 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16393 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16396 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16398 * server.c (gdbserver_version): Update copyright year in version
16400 * gdbreplay.c (gdbreplay_version): Ditto.
16402 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16404 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16405 * linux-bfin-low.c: New file.
16406 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16407 PT_DATA_ADDR for BFIN targets.
16408 * Makefile.in (SFILES): Add linux-bfin-low.c.
16409 (clean): Remove reg-bfin.c.
16410 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16411 * README: Mention supported Blackfin targets.
16413 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16415 * .gitignore: New file.
16417 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16419 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16421 2010-10-22 Jie Zhang <jie@codesourcery.com>
16423 * Makefile.in: Add FLAGS_TO_PASS variable.
16424 (install): Remove dependency of install-only and recursively
16425 invoke make for install-only.
16427 2010-10-04 Doug Evans <dje@google.com>
16429 * Makefile.in (uninstall): Use $(DESTDIR).
16431 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16435 * linux-x86-low.c (compat_siginfo_from_siginfo)
16436 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16437 si_code is < 0. Check for si_code == SI_TIMER before checking for
16440 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16442 * lynx-i386-low.c: New file.
16443 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16445 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16447 * lynx-low.c (ptrace_request_to_str): Remove handling for
16448 request values that have been removed in LynxOS 5.x.
16450 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16452 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16455 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16457 * configure.ac: Add --enable-inprocess-agent option.
16458 * configure: Rebuilt.
16460 2010-09-06 Yao Qi <yao@codesourcery.com>
16462 * linux-low.c (linux_kill): Remove unused variable.
16463 (linux_stabilize_threads): Likewise.
16464 * server.c (start_inferior): Likewise.
16465 (queue_stop_reply_callback): Likewise.
16466 * tracepoint.c (do_action_at_tracepoint): Likewise.
16468 2010-09-06 Yao Qi <yao@codesourcery.com>
16470 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16473 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16475 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16477 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16479 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16482 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16484 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16485 gdbserver/lynx-ppc-low.c: New files.
16486 * Makefile.in (lynx_low_h): New variable.
16487 (lynx-low.o, lynx-ppc-low.o): New rules.
16488 * configure.ac: On LynxOS, link with -lnetinet.
16489 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16490 * configure: regenerate.
16492 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16494 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16495 * configure.ac: Add check for vasprintf and vsnprintf.
16496 * configure, config.in: Regenerate.
16497 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16499 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16501 * gdbreplay.c: Move include of alloca.h up, next to include of
16503 * server.h: Add include of malloc.h.
16504 * mem-break.c: Remove include of malloc.h.
16505 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16507 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16509 * Makefile.in (memmem.o): Build with -Wno-error.
16511 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16513 * utils.c (xsnprintf): Make non-static.
16514 * server.h: Add xsnprintf declaration.
16515 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16516 replace calls to snprintf by calls to xsnprintf throughout.
16518 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16520 * configure.ac: Add configure check for alloca.
16521 * configure, config.in: Regenerate.
16522 * server.h: Include alloca.h if it exists.
16523 * gdbreplay.c: Include alloca.h if it exists.
16525 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16527 * linux-low.c (__SIGRTMIN): Define if not already defined.
16528 (linux_create_inferior): Check for __ANDROID__ rather than
16530 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16531 are already deferred.
16532 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16533 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16534 stopped and already has a pending signal to report.
16535 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16536 a pending signal to report or is moving out of a jump pad.
16537 (linux_init_signals): Check for __ANDROID__ rather than
16540 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16542 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16543 debug_threads check. Avoid a linear search when not doing debug
16546 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16548 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16549 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16550 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16551 (process_event): Change local fd's type to gdb_fildes_t.
16552 (create_file_handler): Adjust prototype.
16553 (delete_file_handler): Adjust prototype.
16554 (handle_file_event): Adjust prototype. Use pfildes.
16555 (create_file_event): Adjsut prototype.
16556 * remote-utils.c (remote_desc, listen_desc): Change type to
16558 * server.h: New gdb_fildes_t typedef.
16559 [USE_WIN32API]: Include winsock2.h.
16560 (delete_file_handler, add_file_handler): Adjust prototypes.
16561 (pfildes): Declare.
16562 * utils.c (pfildes): New.
16564 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16566 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16567 * configure: Regenerate.
16569 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16571 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16572 (linux_done_accessing_memory): ... this.
16573 (linux_target_ops): Adjust.
16574 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16575 * nto-low.c (nto_target_ops): Adjust comment.
16576 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16577 * spu-low.c (spu_target_ops): Adjust comment.
16578 * target.h (target_ops): Rename unprepare_to_access_memory field
16579 to done_accessing_memory.
16580 (unprepare_to_access_memory): Rename to ...
16581 (done_accessing_memory): ... this.
16583 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16585 * linux-low.c (linux_prepare_to_access_memory): New.
16586 (linux_unprepare_to_access_memory): New.
16587 (linux_target_ops): Install them.
16588 * server.c (read_memory): Rename to ...
16589 (gdb_read_memory): ... this. Use
16590 prepare_to_access_memory/prepare_to_access_memory.
16591 (write_memory): Rename to ...
16592 (gdb_write_memory): ... this. Use
16593 prepare_to_access_memory/prepare_to_access_memory.
16594 (handle_search_memory_1): Adjust.
16595 (process_serial_event): Adjust.
16596 * target.h (struct target_ops): New fields
16597 prepare_to_access_memory and unprepare_to_access_memory.
16598 (prepare_to_access_memory, unprepare_to_access_memory): New.
16599 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16600 prepare_to_access_memory/prepare_to_access_memory.
16601 * nto-low.c (nto_target_ops): Adjust.
16602 * spu-low.c (spu_target_ops): Adjust.
16603 * win32-low.c (win32_target_ops): Adjust.
16605 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16607 * Makefile.in (WARN_CFLAGS): Get it from configure.
16608 (WERROR_CFLAGS): New.
16609 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16610 * configure.ac: Introduce --enable-werror, which adds -Werror to
16611 the compiler command line. Enabled by default. Disable with
16612 --disable-werror. Add -Wdeclaration-after-statement
16613 Wpointer-arith and -Wformat-nonliteral to warning flags.
16614 * configure: Regenerate.
16616 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16618 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16620 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16622 * gdbreplay.c (remote_error): New.
16624 (expect): Use gdbchar. Check for error reading from GDB.
16625 Clarify sync error output.
16626 (play): Check for errors writing to GDB.
16627 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16628 * remote-utils.c (getpkt): Check for errors writing to the remote
16631 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16633 * linux-low.c (linux_wait_1): Move non-debugging code out of
16634 `debug_threads' control.
16636 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16638 * linux-low.c (linux_wait_1): Don't set last_status here.
16639 * server.c (push_event, queue_stop_reply_callback): Assert we're
16640 not pushing a TARGET_WAITKIND_IGNORE event.
16641 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16642 (myresume, handle_target_event): Set the thread's last_resume_kind
16643 and last_status from the target returned status.
16645 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16649 * linux-x86-low.c (update_debug_registers_callback): New.
16650 (i386_dr_low_set_addr): Use it.
16651 (i386_dr_low_get_addr): New.
16652 (i386_dr_low_set_control): Use update_debug_registers_callback.
16653 (i386_dr_low_get_control): New.
16654 (i386_dr_low_get_status): Adjust.
16655 * linux-low.c (linux_stop_lwp): New.
16656 * linux-low.h (linux_stop_lwp): Declare.
16658 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16659 argument instead of a i386_debug_reg_state.
16660 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16661 a i386_debug_reg_state.
16662 (i386_insert_aligned_watchpoint): Adjust.
16663 (i386_remove_aligned_watchpoint): Adjust.
16664 (i386_low_stopped_data_address): Read the debug registers from the
16665 inferior instead of from the mirrors.
16666 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16667 (i386_dr_low_get_addr): Declare.
16668 (i386_dr_low_get_control): Declare.
16669 (i386_dr_low_get_status): Change prototype.
16671 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16672 (i386_dr_low_get_addr): New.
16673 (i386_dr_low_get_control): New.
16674 (i386_dr_low_get_status): Adjust prototype. Return
16676 (i386_initial_stuff): Clear dr_status_mirror and
16678 (i386_get_thread_context): Adjust.
16679 (i386_set_thread_context): Adjust.
16680 (i386_thread_added): Adjust.
16682 2010-08-24 Pedro Alves <pedro@codesourcery.com>
16684 * linux-low.h (linux_thread_area): Delete declaration.
16686 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16688 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16689 after its termination.
16691 2010-08-09 Pedro Alves <pedro@codesourcery.com>
16693 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16694 (gdb_wants_all_stopped): Delete.
16695 (linux_wait_1): Don't call them.
16696 * server.c (handle_v_cont): Tag all threads as want-stopped.
16697 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16698 stopped as "client-wants-stopped".
16700 2010-07-31 Pedro Alves <pedro@codesourcery.com>
16702 * Makefile.in (signals_h): New.
16703 (server_h): Depend on it.
16704 (server.o): Don't depend on $(signals_def).
16705 (signals.o): Depend on $(signals_def).
16707 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16709 * Makefile.in (signals_def): New.
16710 (server_h): Append include/gdb/signals.h and signals_def.
16711 (server.o): Append signals_def.
16713 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16715 * server.c (handle_target_event): Use target_signal_to_host for
16716 resume_info.sig initialization.
16717 * target.h (struct thread_resume) <sig>: New comment.
16719 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16721 * server.c (handle_query): strcpy() the returned string from paddress()
16722 instead of sprintf().
16723 * utils.c (paddress): Return phex_nz().
16725 2010-07-07 Joel Brobecker <brobecker@adacore.com>
16727 * server.c (handle_v_cont): Call mourn_inferior if process
16729 (myresume): Likewise.
16731 2010-07-01 Pedro Alves <pedro@codesourcery.com>
16733 Static tracepoints, and integration with UST.
16735 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16736 * mem-break.c (uninsert_all_breakpoints)
16737 (reinsert_all_breakpoints): New.
16738 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16739 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16740 (gdb_agent_ust_loaded, helper_thread_id)
16741 (gdb_agent_helper_thread_id): New macros.
16742 (struct ipa_sym_addresses): Add addr_ust_loaded,
16743 addr_helper_thread_id, addr_cmd_buf.
16744 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16745 (in_process_agent_loaded_ust): New.
16746 (write_e_ust_not_loaded): New.
16747 (maybe_write_ipa_ust_not_loaded): New.
16748 (struct collect_static_trace_data_action): New.
16749 (enum tracepoint_type) <static_tracepoint>: New.
16750 (struct tracepoint) <handle>: Mention static tracepoints.
16751 (struct static_tracepoint_ctx): New.
16752 (CMD_BUF_SIZE): New.
16753 (add_tracepoint_action): Handle static tracepoint actions.
16754 (unprobe_marker_at): New.
16755 (clear_installed_tracepoints): Handle static tracepoints.
16756 (cmd_qtdp): Handle static tracepoints.
16757 (probe_marker_at): New.
16758 (cmd_qtstart): Handle static tracepoints.
16759 (response_tracepoint): Handle static tracepoints.
16760 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16761 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16762 (get_context_regcache): Handle static tracepoints.
16763 (do_action_at_tracepoint): Handle static tracepoint actions.
16764 (traceframe_find_block_type): Handle static trace data blocks.
16765 (traceframe_read_sdata): New.
16766 (download_tracepoints): Download static tracepoint actions.
16767 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16768 (GDB_PROBE_NAME): New.
16770 (GET_UST_SYM): New.
16773 (ust_marker_to_static_tracepoint): New.
16775 (collect_ust_data_at_tracepoint): New.
16776 (gdb_ust_probe): New.
16777 (UNIX_PATH_MAX, SOCK_DIR): New.
16778 (gdb_ust_connect_sync_socket): New.
16779 (resume_thread, stop_thread): New.
16780 (run_inferior_command): New.
16781 (init_named_socket): New.
16782 (gdb_ust_socket_init): New.
16783 (cstr_to_hexstr): New.
16785 (first_marker, next_marker): New.
16786 (response_ust_marker): New.
16787 (cmd_qtfstm, cmd_qtsstm): New.
16788 (unprobe_marker_at, probe_marker_at): New.
16789 (cmd_qtstmat, gdb_ust_thread): New.
16790 (gdb_ust_init): New.
16791 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16792 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16793 (ST_REGENTRY): New.
16794 (x86_64_st_collect_regmap): New.
16795 (X86_64_NUM_ST_COLLECT_GREGS): New.
16796 (AMD64_RIP_REGNUM): New.
16797 (supply_static_tracepoint_registers): New.
16798 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16799 (ST_REGENTRY): New.
16800 (i386_st_collect_regmap): New.
16801 (i386_NUM_ST_COLLECT_GREGS): New.
16802 (supply_static_tracepoint_registers): New.
16803 * server.c (handle_query): Handle qXfer:statictrace:read.
16804 <qSupported>: Report support for StaticTracepoints, and
16805 qXfer:statictrace:read features.
16806 * server.h (traceframe_read_sdata)
16807 (supply_static_tracepoint_registers): Declare.
16808 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16809 (unpack_varlen_hex): Include in IPA build.
16810 * Makefile.in (ustlibs, ustinc): New.
16811 (IPA_OBJS): Add remote-utils-ipa.o.
16812 ($(IPA_LIB)): Link -ldl and -lpthread.
16814 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16815 * config.in, configure: Regenerate.
16817 2010-06-20 Ian Lance Taylor <iant@google.com>
16818 Pedro Alves <pedro@codesourcery.com>
16820 * linux-x86-low.c (always_true): Delete.
16821 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16822 trying to fool the compiler with always_true.
16824 2010-06-20 Pedro Alves <pedro@codesourcery.com>
16826 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16827 conditions in gdbserver.
16829 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16831 * spu-low.c (spu_read_memory): Wrap around local store limit.
16832 (spu_write_memory): Likewise.
16834 2010-06-15 Pedro Alves <pedro@codesourcery.com>
16836 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16837 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16839 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16841 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16842 uses with LONGEST uses.
16844 2010-06-14 Stan Shebs <stan@codesourcery.com>
16845 Pedro Alves <pedro@codesourcery.com>
16849 * linux-x86-low.c: Include limits.h.
16851 (always_true): New.
16854 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16855 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16856 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16857 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16858 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16859 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16860 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16861 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16862 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16863 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16864 (amd64_emit_void_call_2): New.
16865 (amd64_emit_ops): New.
16866 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16867 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16868 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16869 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16870 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16871 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16872 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16873 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16874 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16875 (i386_emit_stack_adjust, i386_emit_int_call_1)
16876 (i386_emit_void_call_2): New.
16877 (i386_emit_ops): New.
16878 (x86_emit_ops): New.
16879 (the_low_target): Install x86_emit_ops.
16880 * server.h (struct emit_ops): New.
16881 (get_raw_reg_func_addr): Declare.
16882 (current_insn_ptr, emit_error): Declare.
16883 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16884 (set_trace_state_variable_value): New defines.
16885 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16886 addr_get_trace_state_variable_value and
16887 addr_set_trace_state_variable_value.
16888 (symbol_list): New fields for get_raw_reg,
16889 get_trace_state_variable_value and set_trace_state_variable_value.
16890 (condfn): New typedef.
16891 (struct tracepoint): New field `compiled_cond'.
16892 (do_action_at_tracepoint): Clear compiled_cond.
16893 (get_trace_state_variable_value, set_trace_state_variable_value):
16895 (condition_true_at_tracepoint): If there's a compiled condition,
16897 (current_insn_ptr, emit_error): New globals.
16898 (struct bytecode_address): New.
16899 (get_raw_reg_func_addr): New.
16900 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16901 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16902 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16903 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16904 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16905 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16906 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16907 (compile_tracepoint_condition, compile_bytecodes): New.
16908 * target.h (emit_ops): Forward declare.
16909 (struct target_ops): New field emit_ops.
16910 (target_emit_ops): New.
16911 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16912 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16913 * linux-low.c (linux_emit_ops): New.
16914 (linux_target_ops): Install it.
16915 * linux-low.h (struct linux_target_ops): New field emit_ops.
16917 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16919 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16920 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16922 2010-06-01 Pedro Alves <pedro@codesourcery.com>
16923 Stan Shebs <stan@codesourcery.com>
16925 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
16926 (all): Depend on $(extra_libraries).
16927 (install-only): Install the IPA.
16928 (IPA_OBJS, IPA_LIB): New.
16929 (clean): Remove the IPA lib.
16930 (IPAGENT_CFLAGS): New.
16931 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
16932 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
16933 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
16934 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
16935 * configure.ac: Check for atomic builtins support in the compiler.
16936 (IPA_DEPFILES, extra_libraries): Define.
16937 * configure.srv (ipa_obj): Add description.
16938 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
16939 (i[34567]86-*-linux*): Set ipa_obj.
16940 (x86_64-*-linux*): Set ipa_obj.
16941 * linux-low.c (stabilizing_threads): New.
16942 (supports_fast_tracepoints): New.
16943 (linux_detach): Stabilize threads before detaching.
16944 (handle_tracepoints): Handle internal tracing breakpoints. Assert
16945 the lwp is either not stabilizing, or is moving out of a jump pad.
16946 (linux_fast_tracepoint_collecting): New.
16947 (maybe_move_out_of_jump_pad): New.
16948 (enqueue_one_deferred_signal): New.
16949 (dequeue_one_deferred_signal): New.
16950 (linux_wait_for_event_1): If moving out of a jump pad, defer
16951 pending signals to later.
16952 (linux_stabilize_threads): New.
16953 (linux_wait_1): Check if threads need moving out of jump pads, and
16955 (stuck_in_jump_pad_callback): New.
16956 (move_out_of_jump_pad_callback): New.
16957 (lwp_running): New.
16958 (linux_resume_one_lwp): Handle moving out of jump pads.
16959 (linux_set_resume_request): Dequeue deferred signals.
16960 (need_step_over_p): Also step over fast tracepoint jumps.
16961 (start_step_over): Also uninsert fast tracepoint jumps.
16962 (finish_step_over): Also reinsert fast tracepoint jumps.
16963 (linux_install_fast_tracepoint_jump): New.
16964 (linux_target_ops): Install linux_stabilize_threads and
16965 linux_install_fast_tracepoint_jump_pad.
16966 * linux-low.h (linux_target_ops) <get_thread_area,
16967 install_fast_tracepoint_jump_pad>: New fields.
16968 (struct lwp_info) <collecting_fast_tracepoint,
16969 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
16970 (linux_get_thread_area): Declare.
16971 * linux-x86-low.c (jump_insn): New.
16972 (x86_get_thread_area): New.
16973 (append_insns): New.
16974 (push_opcode): New.
16975 (amd64_install_fast_tracepoint_jump_pad): New.
16976 (i386_install_fast_tracepoint_jump_pad): New.
16977 (x86_install_fast_tracepoint_jump_pad): New.
16978 (the_low_target): Install x86_get_thread_area and
16979 x86_install_fast_tracepoint_jump_pad.
16980 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
16981 (struct fast_tracepoint_jump): New.
16982 (fast_tracepoint_jump_insn): New.
16983 (fast_tracepoint_jump_shadow): New.
16984 (find_fast_tracepoint_jump_at): New.
16985 (fast_tracepoint_jump_here): New.
16986 (delete_fast_tracepoint_jump): New.
16987 (set_fast_tracepoint_jump): New.
16988 (uninsert_fast_tracepoint_jumps_at): New.
16989 (reinsert_fast_tracepoint_jumps_at): New.
16990 (set_breakpoint_at): Use write_inferior_memory.
16991 (uninsert_raw_breakpoint): Use write_inferior_memory.
16992 (check_mem_read): Mask out fast tracepoint jumps.
16993 (check_mem_write): Mask out fast tracepoint jumps.
16994 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
16995 (set_fast_tracepoint_jump): Declare.
16996 (delete_fast_tracepoint_jump)
16997 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
16998 (reinsert_fast_tracepoint_jumps_at): Declare.
16999 * regcache.c: Don't compile many functions when building the
17000 in-process agent library.
17001 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17002 the register buffer in the heap.
17003 (free_register_cache): If the register buffer isn't owned by the
17004 regcache, don't free it.
17005 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17006 pre-existing register caches.
17007 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17009 (convert_ascii_to_int): : Constify `from' parameter type.
17010 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17011 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17012 the needed buffer in-place.
17013 (relocate_instruction): New.
17014 * server.c (handle_query) <qSymbols>: If the target supports
17015 tracepoints, give it a chance of looking up symbols. Report
17016 support for fast tracepoints.
17017 (handle_status): Stabilize threads.
17018 (process_serial_event): Adjust.
17019 * server.h (struct fast_tracepoint_jump): Forward declare.
17020 (struct process_info) <fast_tracepoint_jumps>: New field.
17021 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17022 (decode_X_packet, decode_M_packet): Adjust.
17023 (relocate_instruction): Declare.
17024 (in_process_agent_loaded): Declare.
17025 (tracepoint_look_up_symbols): Declare.
17026 (struct fast_tpoint_collect_status): Declare.
17027 (fast_tracepoint_collecting): Declare.
17028 (force_unlock_trace_buffer): Declare.
17029 (handle_tracepoint_bkpts): Declare.
17030 (initialize_low_tracepoint)
17031 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17032 * target.h (struct target_ops) <stabilize_threads,
17033 install_fast_tracepoint_jump_pad>: New fields.
17034 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17035 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17036 [HAVE_STDINT_H]: Include stdint.h.
17037 (trace_debug_1): Rename to ...
17038 (trace_vdebug): ... this.
17039 (trace_debug): Rename to ...
17040 (trace_debug_1): ... this. Add `level' parameter.
17041 (trace_debug): New.
17042 (ATTR_USED, ATTR_NOINLINE): New.
17043 (IP_AGENT_EXPORT): New.
17044 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17045 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17046 (about_to_request_buffer_space, trace_buffer_is_full)
17047 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17048 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17049 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17050 (traceframe_write_count, traceframes_created)
17051 (trace_state_variables)
17052 New renaming defines.
17053 (struct ipa_sym_addresses): New.
17054 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17055 (symbol_list): New.
17056 (ipa_sym_addrs): New.
17057 (all_tracepoint_symbols_looked_up): New.
17058 (in_process_agent_loaded): New.
17059 (write_e_ipa_not_loaded): New.
17060 (maybe_write_ipa_not_loaded): New.
17061 (tracepoint_look_up_symbols): New.
17062 (debug_threads) [IN_PROCESS_AGENT]: New.
17063 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17064 (UNKNOWN_SIDE_EFFECTS): New.
17065 (stop_tracing): New.
17066 (flush_trace_buffer): New.
17067 (stop_tracing_bkpt): New.
17068 (flush_trace_buffer_bkpt): New.
17069 (read_inferior_integer): New.
17070 (read_inferior_uinteger): New.
17071 (read_inferior_data_pointer): New.
17072 (write_inferior_data_pointer): New.
17073 (write_inferior_integer): New.
17074 (write_inferior_uinteger): New.
17075 (struct collect_static_trace_data_action): Delete.
17076 (enum tracepoint_type): New.
17077 (struct tracepoint) <type>: New field `type'.
17078 <actions_str, step_actions, step_actions_str>: Only include in
17080 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17081 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17082 (tracepoints): Use IP_AGENT_EXPORT.
17083 (last_tracepoint): Don't include in the IPA.
17084 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17085 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17086 (alloced_trace_state_variables): New.
17087 (trace_state_variables): Use IP_AGENT_EXPORT.
17088 (traceframe_t): Delete unused variable.
17089 (circular_trace_buffer): Don't include in the IPA.
17090 (trace_buffer_start): Delete.
17091 (struct trace_buffer_control): New.
17092 (trace_buffer_free): Delete.
17093 (struct ipa_trace_buffer_control): New.
17094 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17095 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17097 (trace_buffer_ctrl): New.
17098 (TRACE_BUFFER_CTRL_CURR): New.
17099 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17100 Reimplement as macros.
17101 (trace_buffer_wrap): Delete.
17102 (traceframe_write_count, traceframe_read_count)
17103 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17104 (struct tracepoint_hit_ctx) <type>: New field.
17105 (struct fast_tracepoint_ctx): New.
17106 (memory_barrier): New.
17108 (record_tracepoint_error): Update atomically in the IPA.
17109 (clear_inferior_trace_buffer): New.
17110 (about_to_request_buffer_space): New.
17111 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17112 updating the same buffer.
17113 (add_tracepoint): Default the tracepoint's type to trap
17114 tracepoint, and orig_size to -1.
17115 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17116 internal variables.
17117 (create_trace_state_variable): New parameter `gdb'. Handle it.
17118 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17119 (cmd_qtdp): Handle fast tracepoints.
17120 (cmd_qtdv): Adjust.
17121 (max_jump_pad_size): New.
17122 (gdb_jump_pad_head): New.
17123 (get_jump_space_head): New.
17124 (claim_jump_space): New.
17125 (sort_tracepoints): New.
17126 (MAX_JUMP_SIZE): New.
17127 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17129 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17130 support. Upload fast traceframes, and delete internal IPA
17132 (stop_tracing_handler): New.
17133 (flush_trace_buffer_handler): New.
17134 (cmd_qtstop): Upload fast tracepoints.
17135 (response_tracepoint): Handle fast tracepoints.
17136 (tracepoint_finished_step): Upload fast traceframes. Set the
17137 tracepoint hit context's tracepoint type.
17138 (handle_tracepoint_bkpts): New.
17139 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17140 type. Add comment about fast tracepoints.
17141 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17142 non-existing action_str field.
17143 (get_context_regcache): Handle fast tracepoints.
17144 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17146 (fast_tracepoint_from_jump_pad_address): New.
17147 (fast_tracepoint_from_ipa_tpoint_address): New.
17148 (collecting_t): New.
17149 (force_unlock_trace_buffer): New.
17150 (fast_tracepoint_collecting): New.
17152 (gdb_collect): New.
17153 (write_inferior_data_ptr): New.
17154 (target_tp_heap): New.
17155 (target_malloc): New.
17156 (download_agent_expr): New.
17158 (download_tracepoints): New.
17159 (download_trace_state_variables): New.
17160 (upload_fast_traceframes): New.
17161 (IPA_FIRST_TRACEFRAME): New.
17162 (IPA_NEXT_TRACEFRAME_1): New.
17163 (IPA_NEXT_TRACEFRAME): New.
17164 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17165 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17166 (gdb_jump_pad_buffer_end): New.
17167 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17168 (initialize_tracepoint): Adjust.
17169 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17170 buffer. Initialize the low module.
17171 * utils.c (PREFIX, TOOLNAME): New.
17172 (malloc_failure): Use PREFIX.
17173 (error): In the IPA, an error causes an exit.
17174 (fatal, warning): Use PREFIX.
17175 (internal_error): Use TOOLNAME.
17176 (NUMCELLS): Increase to 10.
17177 * configure, config.in: Regenerate.
17179 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17181 * server.c (handle_query) <qSupported>: Do two passes over the
17182 qSupported string to avoid nesting strtok.
17184 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17186 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17188 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17189 -Wl,--dynamic-list.
17190 * configure: Regenerate.
17191 * proc-service.list: New.
17193 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17195 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17198 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17200 * gdbreplay.c (remote_open): Check error return from socket() call by
17201 its equality to -1 not by it being negative.
17202 * remote-utils.c (remote_open): Likewise.
17204 2010-05-23 Pedro Alves <pedro@codesourcery.com>
17206 * config.h: Regenerate.
17208 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17210 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17211 doesn't provide PTRACE_GET_THREAD_AREA.
17213 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17215 * linux-m68k-low.c: Include <asm/ptrace.h>
17216 (ps_get_thread_area): Implement.
17218 2010-05-03 Doug Evans <dje@google.com>
17220 * event-loop.c (struct callback_event): New struct.
17221 (callback_list): New global.
17222 (append_callback_event, delete_callback_event): New functions.
17223 (process_callback): New function.
17224 (start_event_loop): Call it.
17225 * remote-utils.c (NOT_SCHEDULED): Define.
17226 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17227 moved out of readchar.
17228 (readchar): Rewrite. Call reschedule before returning.
17229 (reset_readchar): New function.
17230 (remote_close): Call it.
17231 (process_remaining, reschedule): New functions.
17232 * server.h (callback_handler_func): New typedef.
17233 (append_callback_event, delete_callback_event): Declare.
17235 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17237 * proc-service.c (ps_pglobal_lookup): Use
17238 thread_db_look_up_one_symbol.
17239 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17240 parameter. Use it instead of all_symbols_looked_up.
17241 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17243 (all_symbols_looked_up): Don't declare.
17244 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17245 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17247 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17248 Set all_symbols_looked_up here.
17249 (thread_db_look_up_one_symbol): New.
17250 (thread_db_get_tls_address): Adjust.
17251 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17252 thread_db object on the heap, and tentatively set it in the
17254 (thread_db_init): Don't set all_symbols_looked_up here.
17255 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17257 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17259 * linux-low.c (linux_kill, linux_detach): Adjust.
17260 (status_pending_p_callback): Remove redundant statement. Check
17261 for !TARGET_WAITIKIND_IGNORE, instead of
17262 TARGET_WAITKIND_STOPPED.
17263 (handle_tracepoints): Make sure LWP is locked. Adjust.
17264 (linux_wait_for_event_1): Adjust.
17265 (linux_cancel_breakpoints): New.
17266 (unsuspend_one_lwp): New.
17267 (unsuspend_all_lwps): New.
17268 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17269 (send_sigstop_callback): Change return type to int, add new
17270 `except' parameter and handle it.
17271 (suspend_and_send_sigstop_callback): New.
17272 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17273 pass them down. If SUSPEND, also increment the lwp's suspend
17275 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17276 (need_step_over_p): Don't consider suspended LWPs.
17277 (start_step_over): Adjust.
17278 (proceed_one_lwp): Change return type to int, add new `except'
17279 parameter and handle it.
17280 (unsuspend_and_proceed_one_lwp): New.
17281 (proceed_all_lwps): Use find_inferior instead of
17283 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17284 also decrement the suspend count of LWPs. Pass `except' down,
17285 instead of hacking its suspend count.
17286 (linux_pause_all): Add `freeze' parameter. Adjust.
17287 (linux_unpause_all): New.
17288 (linux_target_ops): Install linux_unpause_all.
17289 * server.c (handle_status): Adjust.
17290 * target.h (struct target_ops): New fields `unpause_all' and
17291 `cancel_breakpoints'. Add new parameter to `pause_all'.
17292 (pause_all): Add new `freeze' parameter.
17293 (unpause_all): New.
17294 (cancel_breakpoints): New.
17295 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17296 cancel breakpoints.
17297 (cmd_qtstart): Pause threads.
17298 (stop_tracing): Pause threads, and cancel breakpoints.
17299 * win32-low.c (win32_target_ops): Adjust.
17301 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17303 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17304 the inferior right away from here...
17305 (linux_wait_1): ... to here, and adjust to check the thread's
17306 last_resume_kind instead of the lwp's step or stop_expected flags.
17308 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17310 * README: Use consistent `GDB' and `GDBserver' spellings.
17312 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17314 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17315 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17316 (linux_detach_one_lwp): Assume the lwp is stopped.
17317 (any_thread_of): Delete.
17318 (linux_detach): Stop all lwps here. Don't blindly delete all
17320 (delete_lwp_callback): New.
17321 (linux_mourn): Delete all lwps of the process that is gone.
17322 (linux_wait_1): Don't delete the last lwp of the process here.
17323 * mem-break.h (mark_breakpoints_out): Declare.
17324 * mem-break.c (mark_breakpoints_out): New.
17325 (free_all_breakpoints): Use it.
17326 * server.c (handle_target_event): If the process is gone, mark
17328 * thread-db.c (struct thread_db) <create_bp>: New field.
17329 (thread_db_enable_reporting): Fix prototype. Store a thread event
17330 breakpoint reference in the thread_db struct.
17331 (thread_db_load_search): Clear the thread_db object.
17332 (try_thread_db_load_1): Ditto.
17333 (switch_to_process): New.
17334 (disable_thread_event_reporting): Use it.
17335 (remove_thread_event_breakpoints): New.
17336 (thread_db_detach, thread_db_mourn): Use it.
17338 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17340 * linux-low.c (linux_enable_event_reporting): New.
17341 (linux_wait_for_event_1, handle_extended_wait): Use it.
17343 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17345 * linux-low.c (linux_kill_one_lwp, linux_kill)
17346 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17347 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17348 SIGSTOP even if the LWP is stopped.
17349 (send_sigstop_callback): New.
17350 (stop_all_lwps): Use send_sigstop_callback instead.
17351 (linux_resume_one_thread): Adjust.
17352 (proceed_one_lwp): Still proceed an LWP that the client has
17353 requested to stop, if we haven't reported it as stopped yet. Make
17354 sure that LWPs the client want stopped, have a pending SIGSTOP.
17356 2010-04-26 Doug Evans <dje@google.com>
17358 * server.c (handle_general_set): Make static.
17360 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17361 Print received char after testing for error/eof instead of before.
17362 (input_interrupt): Tweak comment.
17364 2010-04-23 Doug Evans <dje@google.com>
17366 * server.c (start_inferior): Print inferior argv if --debug.
17368 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17370 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17371 * nto-x86-low.c: Include server.h
17373 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17375 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17376 be consistent with other sources of this directory.
17377 (init_registers_amd64): Correct name of source file of this function
17380 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17382 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17383 64-bit executables.
17385 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17387 * win32-i386-low.c: Add 64-bit support.
17388 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17389 (init_registers_amd64): Declare.
17390 (mappings): Add 64-bit version of array.
17391 (init_windows_x86): New function.
17392 (the_low_target): Change init_arch field to init_windows_x86.
17394 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17396 * win32-low.c: Adapt to support also 64-bit architecture.
17397 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17398 (get_image_name): Use SIZE_T type for local variable `done'.
17399 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17400 (toolhelp_get_dll_name): Idem.
17401 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17402 Use uintptr_t typecast to avoid warning.
17403 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17404 (handle_exception): Use phex_nz to avoid warning.
17405 (win32_wait): Remove unused local variable `process'.
17407 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17409 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17412 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17414 * configure.ac: Use `ws2_32' library for srv_mingw.
17415 * configure: Regenerate.
17416 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17417 * remote-utils.c: Likewise.
17419 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17421 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17422 if __x86_64__ is defined.
17424 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17426 * configure: Regenerate.
17428 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17430 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17431 * target.h (target_ops): New get_tib_address field.
17432 * win32-low.h (win32_thread_info): Add thread_local_base field.
17433 * win32-low.c (child_add_thread): Add tlb argument.
17434 Set thread_local_base field to TLB.
17435 (get_child_debug_event): Adapt to child_add_thread change.
17436 (win32_get_tib_address): New function.
17437 (win32_target_ops): Set get_tib_address field to
17438 win32_get_tib_address.
17439 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17441 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17443 * linux-low.c (linux_mourn): Also remove the process.
17444 * server.c (handle_target_event): Don't remove the process here.
17445 * nto-low.c (nto_mourn): New.
17446 (nto_target_ops): Install it.
17447 * spu-low.c (spu_mourn): New.
17448 (spu_target_ops): Install it.
17449 * win32-low.c (win32_mourn): New.
17450 (win32_target_ops): Install it.
17452 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17454 * server.h (buffer_xml_printf): Remove redundant `;'.
17456 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17458 * regcache.c (set_register_cache): Invalidate regcaches before
17459 changing the register cache layout.
17460 (regcache_invalidate_one): Allow a NULL regcache.
17461 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17462 regcaches before changing the register cache layout or the target
17465 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17467 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17468 variable warning on Linux/x86-64.
17470 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17472 GDBserver disconnected tracing support.
17474 * linux-low.c (linux_remove_process): Delete.
17475 (add_lwp): Don't set last_resume_kind here.
17476 (linux_kill): Use `mourn'.
17477 (linux_detach): Use `thread_db_detach', and `mourn'.
17478 (linux_mourn): New.
17479 (linux_attach_lwp_1): Adjust comment.
17480 (linux_attach): last_resume_kind moved the thread_info; adjust.
17481 (status_pending_p_callback): Adjust.
17482 (linux_wait_for_event_1): Adjust.
17483 (count_events_callback, select_singlestep_lwp_callback)
17484 (select_event_lwp_callback, cancel_breakpoints_callback)
17485 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17486 (proceed_one_lwp): Adjust.
17487 (linux_async): Add debug output.
17488 (linux_thread_stopped): New.
17489 (linux_pause_all): New.
17490 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17492 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17493 (thread_db_free): Delete declaration.
17494 (thread_db_detach, thread_db_mourn): Declare.
17495 * thread-db.c (thread_db_init): Use thread_db_mourn.
17496 (thread_db_free): Delete, split in two.
17497 (disable_thread_event_reporting): New.
17498 (thread_db_detach): New.
17499 (thread_db_mourn): New.
17501 * server.h (struct thread_info) <last_resume_kind>: New field.
17502 <attached>: Add comment.
17503 <gdb_detached>: New field.
17504 (handler_func): Change return type to int.
17505 (handle_serial_event, handle_target_event): Ditto.
17506 (gdb_connected): Declare.
17508 (disconnected_tracing): Declare.
17509 (stop_tracing): Declare.
17511 * server.c (handle_query) <qSupported>: Report support for
17512 disconnected tracing.
17513 (queue_stop_reply_callback): Account for running threads.
17514 (gdb_wants_thread_stopped): New.
17515 (gdb_wants_all_threads_stopped): New.
17516 (gdb_reattached_process): New.
17517 (handle_status): Clear the `gdb_detached' flag of all processes.
17518 In all-stop, stop all threads.
17519 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17520 (process_serial_event): If the remote connection breaks, or if an
17521 exit was forced with "monitor exit", force an event loop exit.
17522 Handle disconnected tracing on detach.
17523 (handle_serial_event): Adjust.
17524 (handle_target_event): If GDB isn't connected, forward events back
17525 to the inferior, unless the last process exited, in which case,
17526 exit gdbserver. Adjust interface.
17528 * remote-utils.c (remote_open): Don't block in accept. Instead
17529 register an event loop source on the listen socket file
17530 descriptor. Refactor bits into ...
17531 (listen_desc): ... this new global.
17532 (gdb_connected): ... this new function.
17533 (enable_async_notification): ... this new function.
17534 (handle_accept_event): ... this new function.
17535 (remote_close): Clear remote_desc.
17537 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17539 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17541 (mourn_inferior): Define.
17542 (target_process_qsupported): Avoid the dangling else problem.
17543 (thread_stopped): Define.
17544 (pause_all): Define.
17545 (target_waitstatus_to_string): Declare.
17546 * target.c (target_waitstatus_to_string): New.
17548 * tracepoint.c (tracing): Make extern.
17549 (disconnected_tracing): New.
17550 (stop_tracing): Make extern. Handle tracing stops due to GDB
17552 (cmd_qtdisconnected): New.
17553 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17554 (handle_tracepoint_general_set): Handle QTDisconnected.
17556 * event-loop.c (event_handler_func): Change return type to int.
17557 (process_event): Bail out if the event handler wants the event
17559 (handle_file_event): Ditto.
17560 (start_event_loop): Bail out if the event handler wants the event
17563 * nto-low.c (nto_target_ops): Adjust.
17564 * spu-low.c (spu_wait): Don't remove the process here.
17565 (spu_target_ops): Adjust.
17566 * win32-low.c (win32_wait): Don't remove the process here.
17567 (win32_target_ops): Adjust.
17569 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17571 * regcache.c (realloc_register_cache): Invalidate inferior's
17572 regcache before recreating it.
17574 2010-04-09 Pedro Alves <pedro@codesourcery.com>
17576 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17578 2010-04-09 Stan Shebs <stan@codesourcery.com>
17579 Pedro Alves <pedro@codesourcery.com>
17581 * server.h (LONGEST): New.
17582 (struct thread_info) <while_stepping>: New field.
17583 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17585 (initialize_tracepoint, handle_tracepoint_general_set)
17586 (handle_tracepoint_query, tracepoint_finished_step)
17587 (tracepoint_was_hit, release_while_stepping_state_list):
17588 (current_traceframe): Declare.
17589 * server.c (handle_general_set): Handle tracepoint packets.
17590 (read_memory): New.
17591 (write_memory): New.
17592 (handle_search_memory_1): Use read_memory.
17593 (handle_query): Report support for conditional tracepoints, trace
17594 state variables, and tracepoint sources. Handle tracepoint
17596 (main): Initialize the tracepoints module.
17597 (process_serial_event): Handle traceframe reads/writes.
17599 * linux-low.c (handle_tracepoints): New.
17600 (linux_wait_1): Call it.
17601 (linux_resume_one_lwp): Handle while-stepping.
17602 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17603 (linux_target_ops): Install them.
17604 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17606 * linux-x86-low.c (x86_supports_tracepoints): New.
17607 (the_low_target). Install it.
17609 * mem-break.h (delete_breakpoint): Declare.
17610 * mem-break.c (delete_breakpoint): Make external.
17612 * target.h (struct target_ops): Add `supports_tracepoints',
17613 `read_pc', and `write_pc' fields.
17614 (target_supports_tracepoints): Define.
17615 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17618 * regcache.h (struct regcache) <registers_owned>: New field.
17619 (init_register_cache, regcache_cpy): Declare.
17620 (regcache_read_pc, regcache_write_pc): Declare.
17621 (register_cache_size): Declare.
17622 (supply_regblock): Declare.
17623 * regcache.c (init_register_cache): New.
17624 (new_register_cache): Use it.
17625 (regcache_cpy): New.
17626 (register_cache_size): New.
17627 (supply_regblock): New.
17628 (regcache_read_pc, regcache_write_pc): New.
17630 * tracepoint.c: New.
17632 * Makefile.in (OBS): Add tracepoint.o.
17633 (tracepoint.o): New rule.
17635 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17637 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17639 (i386-mmx.c): Likewise.
17640 (i386-mmx-linux.o): Likewise.
17641 (i386-mmx-linux.c): Likewise.
17643 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17644 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17645 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17646 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17648 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17649 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17650 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17652 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17654 * Makefile.in (clean): Updated.
17656 (i386-avx.c): Likewise.
17657 (i386-avx-linux.o): Likewise.
17658 (i386-avx-linux.c): Likewise.
17659 (amd64-avx.o): Likewise.
17660 (amd64-avx.c): Likewise.
17661 (amd64-avx-linux.o): Likewise.
17662 (amd64-avx-linux.c): Likewise.
17664 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17665 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17666 (srv_amd64_regobj): Add amd64-avx.o.
17667 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17668 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17669 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17670 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17671 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17672 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17673 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17675 * i387-fp.c: Include "i386-xstate.h".
17677 (i387_cache_to_xsave): Likewise.
17678 (i387_xsave_to_cache): Likewise.
17679 (x86_xcr0): Likewise.
17681 * i387-fp.h (i387_cache_to_xsave): Likewise.
17682 (i387_xsave_to_cache): Likewise.
17683 (x86_xcr0): Likewise.
17685 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17686 * linux-crisv32-low.c (target_regsets): Likewise.
17687 * linux-m68k-low.c (target_regsets): Likewise.
17688 * linux-mips-low.c (target_regsets): Likewise.
17689 * linux-ppc-low.c (target_regsets): Likewise.
17690 * linux-s390-low.c (target_regsets): Likewise.
17691 * linux-sh-low.c (target_regsets): Likewise.
17692 * linux-sparc-low.c (target_regsets): Likewise.
17693 * linux-xtensa-low.c (target_regsets): Likewise.
17695 * linux-low.c: Include <sys/uio.h>.
17696 (regsets_fetch_inferior_registers): Support nt_type.
17697 (regsets_store_inferior_registers): Likewise.
17698 (linux_process_qsupported): New.
17699 (linux_target_ops): Add linux_process_qsupported.
17701 * linux-low.h (regset_info): Add nt_type.
17702 (linux_target_ops): Add process_qsupported.
17704 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17706 (init_registers_i386_avx_linux): New.
17707 (init_registers_amd64_avx_linux): Likewise.
17708 (xmltarget_i386_linux_no_xml): Likewise.
17709 (xmltarget_amd64_linux_no_xml): Likewise.
17710 (PTRACE_GETREGSET): Likewise.
17711 (PTRACE_SETREGSET): Likewise.
17712 (x86_fill_xstateregset): Likewise.
17713 (x86_store_xstateregset): Likewise.
17714 (use_xml): Likewise.
17715 (x86_linux_update_xmltarget): Likewise.
17716 (x86_linux_process_qsupported): Likewise.
17717 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17718 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17719 init_registers_i386_linux here. Call
17720 x86_linux_update_xmltarget.
17721 (the_low_target): Add x86_linux_process_qsupported.
17723 * server.c (handle_query): Call target_process_qsupported.
17725 * target.h (target_ops): Add process_qsupported.
17726 (target_process_qsupported): New.
17728 2010-04-03 Pedro Alves <pedro@codesourcery.com>
17730 * inferiors.c (add_thread): Set last_status kind to
17731 TARGET_WAITKIND_IGNORE.
17732 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17733 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17734 (linux_wait_1): Move `thread' local definition to block that uses
17735 it. Don't NULL initialize `event_child'.
17736 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17737 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17738 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17740 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17742 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17743 an extended waitstatus, or by a watchpoint.
17744 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17745 thread was stepping or has been stopped by a watchpoint.
17747 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17749 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17750 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17751 of another, then delete the previous, and validate all
17753 (validate_inserted_breakpoint): New.
17754 (delete_disabled_breakpoints): New.
17755 (validate_breakpoints): New.
17756 (check_mem_read): Validate breakpoints before trusting their
17757 shadow. Delete disabled breakpoints.
17758 (check_mem_write): Validate breakpoints before trusting they
17759 should be inserted. Delete disabled breakpoints.
17760 * mem-break.h (validate_breakpoints):
17761 * server.c (handle_query): Validate breakpoints when we see a
17764 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17766 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17767 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17768 if we could tell there's a GDB breakpoint at stop_pc.
17769 (need_step_over_p): Don't do a step over if we find a GDB
17770 breakpoint at the resume PC.
17772 * mem-break.c (struct raw_breakpoint): New.
17773 (enum bkpt_type): New type `gdb_breakpoint'.
17774 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17775 fields. New field `raw'.
17776 (find_raw_breakpoint_at): New.
17777 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17778 breakpoint instead.
17779 (set_breakpoint_at): Adjust.
17780 (delete_raw_breakpoint): New.
17781 (release_breakpoint): New.
17782 (delete_breakpoint): Rename to...
17783 (delete_breakpoint_1): ... this. Add proc parameter. Use
17784 release_breakpoint. Return ENOENT.
17785 (delete_breakpoint): Reimplement.
17786 (find_breakpoint_at): Delete.
17787 (find_gdb_breakpoint_at): New.
17788 (delete_breakpoint_at): Delete.
17789 (set_gdb_breakpoint_at): New.
17790 (delete_gdb_breakpoint_at): New.
17791 (gdb_breakpoint_here): New.
17792 (set_reinsert_breakpoint): Use release_breakpoint.
17793 (uninsert_breakpoint): Rename to ...
17794 (uninsert_raw_breakpoint): ... this.
17795 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17796 (reinsert_raw_breakpoint): Change parameter type to
17798 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17800 (check_breakpoints): Adjust. Use release_breakpoint.
17801 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17802 (breakpoint_inserted_here): Ditto.
17803 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17804 Don't trust the breakpoint's shadow if it is not inserted.
17805 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17806 (delete_all_breakpoints): Adjust.
17807 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17808 use delete_breakpoint_1.
17810 * mem-break.h (breakpoints_supported): Delete declaration.
17811 (set_gdb_breakpoint_at): Declare.
17812 (gdb_breakpoint_here): Declare.
17813 (delete_breakpoint_at): Delete.
17814 (delete_gdb_breakpoint_at): Declare.
17816 * server.h (struct raw_breakpoint): Forward declare.
17817 (struct process_info): New field `raw_breakpoints'.
17819 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17822 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17824 * linux-low.c (status_pending_p_callback): Fix comment.
17825 (linux_wait_for_event_1): Move most of the internal breakpoint
17826 handling from here...
17827 (linux_wait_1): ... to here.
17828 (count_events_callback): New.
17829 (select_singlestep_lwp_callback): New.
17830 (select_event_lwp_callback): New.
17831 (cancel_breakpoints_callback): New.
17832 (select_event_lwp): New.
17833 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17834 priority to all LWPs that have had events that should be reported
17835 to the client. Cancel breakpoints when about to reporting the
17836 event to the client, not while stopping lwps. No longer cancel
17837 finished single-steps here.
17838 (cancel_finished_single_step): Delete.
17839 (cancel_finished_single_steps): Delete.
17841 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17843 * mem-break.c (enum bkpt_type): New.
17844 (struct breakpoint): New field `type'.
17845 (set_breakpoint_at): Change return type to struct breakpoint
17846 pointer. Set type to `other_breakpoint' by default.
17847 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17848 in the breakpoint list.
17849 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17850 (reinsert_breakpoint): Rename to ...
17851 (reinsert_raw_breakpoint): ... this.
17852 (reinsert_breakpoints_at): Adjust.
17853 * mem-break.h (struct breakpoint): Declare.
17854 (set_breakpoint_at): Change return type to struct breakpoint
17857 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17859 * server.c (handle_query): Assign, not compare.
17861 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17863 Teach linux gdbserver to step-over-breakpoints.
17865 * linux-low.c (can_hardware_single_step): New.
17866 (supports_breakpoints): New.
17867 (handle_extended_wait): If stopping threads, read the stop pc of
17868 the new cloned LWP.
17870 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17871 low target doesn't support retrieving the PC.
17872 (add_lwp): Set last_resume_kind to resume_continue.
17873 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17874 (linux_attach): Don't clear stop_expected. Set the lwp's
17875 last_resume_kind to resume_stop.
17876 (linux_detach_one_lwp): Don't check for removed breakpoints.
17877 (check_removed_breakpoint): Delete.
17878 (status_pending_p): Rename to ...
17879 (status_pending_p_callback): ... this. Don't check for removed
17880 breakpoints. Don't consider threads that are stopped from GDB's
17882 (linux_wait_for_lwp): Always read the stop_pc here.
17883 (cancel_breakpoint): New.
17884 (step_over_bkpt): New global.
17885 (linux_wait_for_event_1): Implement stepping over breakpoints.
17886 (gdb_wants_lwp_stopped): New.
17887 (gdb_wants_all_stopped): New.
17888 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17889 single-step traps here. Store the thread's last reported target
17891 (send_sigstop): Don't clear stop_expected. Always set it,
17893 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17894 (cancel_finished_single_step): New.
17895 (cancel_finished_single_steps): New.
17896 (wait_for_sigstop): Don't cancel finished single-step traps here.
17897 (linux_resume_one_lwp): Don't check for removed breakpoints.
17898 Don't set `step' on non-hardware step archs.
17899 (linux_set_resume_request): Ignore resume_stop requests if already
17900 stopping or stopped. Set the lwp's last_resume_kind.
17901 (resume_status_pending_p): Don't check for removed breakpoints.
17902 (need_step_over_p): New.
17903 (start_step_over): New.
17904 (finish_step_over): New.
17905 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17906 requests. Clear the thread's last reported target waitstatus.
17907 Don't use the `suspended' flag. Don't consider pending breakpoints.
17908 (linux_resume): Start a step-over if necessary.
17909 (proceed_one_lwp): New.
17910 (proceed_all_lwps): New.
17911 (unstop_all_lwps): New.
17912 * linux-low.h (struct lwp_info): Rewrite comment for the
17913 `suspended' flag. Add the `stop_pc' field. Delete the
17914 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17915 Add `'last_resume_kind' and `need_step_over' fields.
17916 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17917 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17918 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17919 (set_raw_breakpoint_at): New.
17920 (set_breakpoint_at): Rewrite to use it.
17921 (reinsert_breakpoint_handler): Delete.
17922 (set_reinsert_breakpoint): New.
17923 (reinsert_breakpoint_by_bp): Delete.
17924 (delete_reinsert_breakpoints): New.
17925 (uninsert_breakpoint): Rewrite.
17926 (uninsert_breakpoints_at): New.
17927 (reinsert_breakpoint): Rewrite.
17928 (reinsert_breakpoints_at): New.
17929 (check_breakpoints): Rewrite.
17930 (breakpoint_here): New.
17931 (breakpoint_inserted_here): New.
17932 (check_mem_read): Adjust.
17933 * mem-break.h (breakpoints_supported, breakpoint_here)
17934 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
17935 (reinsert_breakpoint_by_bp): Delete declaration.
17936 (delete_reinsert_breakpoints): Declare.
17937 (reinsert_breakpoint): Delete declaration.
17938 (reinsert_breakpoints_at): Declare.
17939 (uninsert_breakpoint): Delete declaration.
17940 (uninsert_breakpoints_at): Declare.
17941 (check_breakpoints): Adjust prototype.
17942 * server.h: Adjust include order.
17943 (struct thread_info): Declare here. Add a `last_status' field.
17945 2010-03-23 Michael Snyder <msnyder@vmware.com>
17947 * server.c (crc32): New function.
17948 (handle_query): Add handling for 'qCRC:' request.
17950 2010-03-23 Pedro Alves <pedro@codesourcery.com>
17952 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
17953 lwp had been stopped by a watchpoint.
17955 2010-03-16 Pedro Alves <pedro@codesourcery.com>
17957 * server.h (internal_error): Declare.
17958 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
17959 * utils.c (internal_error): New function.
17961 2010-03-15 Andreas Schwab <schwab@redhat.com>
17963 * configure.srv: Fix typo setting srv_regobj.
17965 2010-03-15 Pedro Alves <pedro@codesourcery.com>
17967 * linux-low.c (fetch_register): Avoid passing a non string literal
17969 (usr_store_inferior_registers): Ditto.
17971 2010-03-14 Pedro Alves <pedro@codesourcery.com>
17973 * linux-low.c (linux_write_memory): Bail out early if peeking
17976 2010-03-14 Pedro Alves <pedro@codesourcery.com>
17978 * linux-low.h (struct lwp_info): New fields
17979 `stopped_by_watchpoint' and `stopped_data_address'.
17980 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
17981 here, and cache them in the lwp object.
17982 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
17984 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
17986 (linux_stopped_by_watchpoint): Rewrite.
17987 (linux_stopped_data_address): Rewrite.
17989 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
17991 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
17992 switching the current inferior, not before.
17994 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
17996 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
17997 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
17998 i386-linux.c and amd64-linux.c.
17999 (reg-i386.o): Removed.
18000 (reg-i386.c): Likewise.
18001 (reg-i386-linux.o): Likewise.
18002 (reg-i386-linux.c): Likewise.
18003 (reg-x86-64.o): Likewise.
18004 (reg-x86-64.c): Likewise.
18005 (reg-x86-64-linux.o): Likewise.
18006 (reg-x86-64-linux.c): Likewise.
18008 (i386.c): Likewise.
18009 (i386-linux.o): Likewise.
18010 (i386-linux.c): Likewise.
18011 (amd64.o): Likewise.
18012 (amd64.c): Likewise.
18013 (amd64-linux.o): Likewise.
18014 (amd64-linux.c): Likewise.
18016 * configure.srv (srv_i386_regobj): New.
18017 (srv_i386_linux_regobj): Likewise.
18018 (srv_amd64_regobj): Likewise.
18019 (srv_amd64_linux_regobj): Likewise.
18020 (srv_i386_32bit_xmlfiles): Likewise.
18021 (srv_i386_64bit_xmlfiles): Likewise.
18022 (srv_i386_xmlfiles): Likewise.
18023 (srv_amd64_xmlfiles): Likewise.
18024 (srv_i386_linux_xmlfiles): Likewise.
18025 (srv_amd64_linux_xmlfiles): Likewise.
18026 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18027 srv_xmlfiles to $srv_i386_xmlfiles.
18028 (i[34567]86-*-mingw32ce*): Likewise.
18029 (i[34567]86-*-mingw*): Likewise.
18030 (i[34567]86-*-nto*): Likewise.
18031 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18032 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18033 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18034 (x86_64-*-linux*): Likewise.
18036 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18037 (init_registers_amd64_linux): New.
18038 (x86_arch_setup): Replace init_registers_x86_64_linux with
18039 init_registers_amd64_linux.
18041 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18043 * configure.ac: Check for libdl. If it is not available link against
18044 static libthread_db.
18045 * configure: Regenerate.
18047 2010-02-22 Pedro Alves <pedro@codesourcery.com>
18051 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18052 handing a read watchpoint.
18053 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18055 2010-02-12 Doug Evans <dje@google.com>
18057 * linux-low.c (linux_supports_tracefork_flag): Document.
18058 (linux_look_up_symbols): Add comment.
18060 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18062 * regcache.c (supply_register): Clear regcache if buf is NULL.
18064 2010-02-02 Nicolas Roche <roche@sourceware.org>
18065 Joel Brobecker <brobecker@adacore.com>
18067 * inferiors.c (find_inferior): Add function documentation.
18068 (unloaded_dll): Handle the case where the unloaded dll has not
18069 been previously registered in the dll list.
18071 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18073 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18074 (thumb2_breakpoint): New.
18075 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18077 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18079 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18080 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18083 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18085 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18087 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18089 * linux-s390-low.c (s390_collect_ptrace_register)
18090 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18092 2010-01-21 Doug Evans <dje@google.com>
18094 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18095 (PTRACE_ARG4_TYPE): New macro.
18096 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18097 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18098 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18099 (usr_store_inferior_registers): Ditto.
18100 (linux_read_memory, linux_write_memory): Ditto.
18101 (linux_test_for_tracefork): Ditto.
18103 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18104 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18106 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18108 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18111 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18113 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18114 prototype to take a regcache. Adjust.
18116 2010-01-20 Pedro Alves <pedro@codesourcery.com>
18118 * regcache.h (struct thread_info): Forward declare.
18119 (struct regcache): New.
18120 (new_register_cache): Adjust prototype.
18121 (get_thread_regcache): Declare.
18122 (free_register_cache): Adjust prototype.
18123 (registers_to_string, registers_from_string): Ditto.
18124 (supply_register, supply_register_by_name, collect_register)
18125 (collect_register_as_string, collect_register_by_name): Ditto.
18126 * regcache.c (struct inferior_regcache_data): Delete.
18127 (get_regcache): Rename to ...
18128 (get_thread_regcache): ... this. Adjust. Switch inferior before
18129 fetching registers.
18130 (regcache_invalidate_one): Adjust.
18131 (regcache_invalidate): Fix prototype.
18132 (new_register_cache): Return the new register cache.
18133 (free_register_cache): Change prototype.
18134 (realloc_register_cache): Adjust.
18135 (registers_to_string): Change prototype to take a regcache. Adjust.
18136 (registers_from_string): Ditto.
18137 (register_data): Ditto.
18138 (supply_register): Ditto.
18139 (supply_register_by_name): Ditto.
18140 (collect_register): Ditto.
18141 (collect_register_as_string): Ditto.
18142 (collect_register_by_name): Ditto.
18143 * server.c (process_serial_event): Adjust.
18144 * linux-low.h (regset_fill_func, regset_store_func): Change
18146 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18148 * linux-low.c (get_stop_pc): Adjust.
18149 (check_removed_breakpoint): Adjust.
18150 (linux_wait_for_event): Adjust.
18151 (linux_resume_one_lwp): Adjust.
18152 (fetch_register): Add regcache parameter. Adjust.
18153 (usr_store_inferior_registers): Ditto.
18154 (regsets_fetch_inferior_registers): Ditto.
18155 (regsets_store_inferior_registers): Ditto.
18156 (linux_fetch_registers, linux_store_registers): Ditto.
18157 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18159 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18161 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18162 prototype to take a regcache.
18163 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18164 * remote-utils.c (convert_ascii_to_int, outreg)
18165 (prepare_resume_reply): Change prototype to take a regcache.
18167 * target.h (struct target_ops) <fetch_registers, store_registers>:
18168 Change prototype to take a regcache.
18169 (fetch_inferior_registers, store_inferior_registers): Change
18170 prototype to take a regcache. Adjust.
18171 * proc-service.c (ps_lgetregs): Adjust.
18172 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18173 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18174 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18175 take a regcache. Adjust.
18176 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18177 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18178 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18179 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18180 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18181 (cris_cannot_fetch_register):
18182 (cris_breakpoint_at): Change prototype to take a regcache.
18184 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18185 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18186 to take a regcache. Adjust.
18187 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18189 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18190 take a regcache. Adjust.
18191 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18192 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18193 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18194 * linux-mips-low.c (mips_get_pc):
18195 (mips_set_pc): Change prototype to take a regcache. Adjust.
18196 (mips_reinsert_addr): Adjust.
18197 (mips_collect_register): Change prototype to take a regcache.
18199 (mips_supply_register):
18200 (mips_collect_register_32bit, mips_supply_register_32bit)
18201 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18202 (mips_store_fpregset): Ditto.
18203 * linux-ppc-low.c (ppc_supply_ptrace_register)
18204 (ppc_supply_ptrace_register): Ditto.
18205 (parse_spufs_run): Adjust.
18206 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18207 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18208 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18209 take a regcache. Adjust.
18210 * linux-s390-low.c (s390_collect_ptrace_register)
18211 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18212 (s390_set_pc): Change prototype to take a regcache. Adjust.
18213 (s390_arch_setup): Adjust.
18214 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18215 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18216 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18217 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18218 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18220 (sparc_breakpoint_at): Adjust.
18221 * linux-xtensa-low.c (xtensa_fill_gregset):
18222 (xtensa_store_gregset):
18223 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18224 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18225 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18226 prototype to take a regcache. Adjust.
18227 * win32-arm-low.c (arm_fetch_inferior_register)
18228 (arm_store_inferior_register): Change prototype to take a
18230 * win32-i386-low.c (i386_fetch_inferior_register)
18231 (i386_store_inferior_register): Change prototype to take a
18233 * win32-low.c (child_fetch_inferior_registers)
18234 (child_store_inferior_registers): Change prototype to take a
18236 (win32_wait): Adjust.
18237 (win32_fetch_inferior_registers): Change prototype to take a
18239 (win32_store_inferior_registers): Adjust.
18240 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18241 store_inferior_register>: Change prototype to take a regcache.
18243 2010-01-20 Doug Evans <dje@google.com>
18245 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18247 (linux_wait_for_event1, linux_init_signals): Ditto.
18248 (W_STOPCODE): Provide definition if missing.
18250 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18252 * linux-low.c (linux_core_of_thread): New.
18253 (compare_ints, show_process, list_threads): New.
18254 (linux_qxfer_osdata): Report threads and cores.
18255 (linux_target_op): Register linux_core_of_thread.
18256 * remote-utils.c (prepare_resume_reply): Report the core.
18257 (buffer_xml_printf): Support %d specifier.
18258 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18260 (handle_query): Handle qXfer:threads. Announce availability
18262 * target.h (struct target_ops): New field core_of_thread.
18264 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18266 * Makefile.in (clean): Remove new generated files.
18267 (reg-s390.o, reg-s390.c): Remove rules.
18268 (reg-s390x.o, reg-s390x.c): Likewise.
18269 (s390-linux32.o, s390-linux32.c): Add rules.
18270 (s390-linux64.o, s390-linux64.c): Likewise.
18271 (s390x-linux64.o, s390x-linux64.c): Likewise.
18272 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18273 * linux-s390-low.c: Include <elf.h>.
18274 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18275 (init_registers_s390): Remove prototype.
18276 (init_registers_s390x): Likewise.
18277 (init_registers_s390_linux32): Add prototype.
18278 (init_registers_s390_linux64): Likewise.
18279 (init_registers_s390x_linux64): Likewise.
18280 (s390_num_regs_3264): New define.
18281 (s390_regmap_3264): New global variable.
18282 (s390_cannot_fetch_register): Remove obsolete check.
18283 (s390_cannot_store_register): Likewise.
18284 (s390_collect_ptrace_register): Handle upper/lower register halves.
18285 (s390_supply_ptrace_register): Likewise.
18286 (s390_fill_gregset): Update to register number changes.
18287 (s390_get_hwcap): New routine.
18288 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18289 Install appropriate regmap and register set.
18291 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18293 * server.c (gdbserver_version): Update copyright year to 2010.
18294 * gdbreplay.c (gdbreplay_version): Likewise.
18296 2009-12-28 Doug Evans <dje@google.com>
18298 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18299 elf/external.h. Include <elf.h> instead but only if necessary.
18301 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18303 * linux-low.c (linux_remove_process): Remove `detaching'
18304 parameter. Don't release/detach from thread_db here.
18305 (linux_kill): Release/detach from thread_db here, ...
18306 (linux_detach): ... and here, before actually detaching.
18307 (linux_wait_1): ... and here, when a process exits.
18308 * thread-db.c (any_thread_of): New.
18309 (thread_db_free): Switch the current inferior to a thread of the
18312 2009-12-21 Doug Evans <dje@google.com>
18314 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18316 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18317 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18318 warning ifndef __NR_tkill. Move setting of errno there too.
18319 Delete unnecessary resetting of errno after syscall.
18320 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18322 * configure.ac: Check for dladdr.
18323 * config.in: Regenerate.
18324 * configure: Regenerate.
18325 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18326 (try_thread_db_load): Update.
18328 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18330 2009-12-18 Doug Evans <dje@google.com>
18332 * event-loop.c: Include unistd.h if it exists.
18334 * linux-low.c (my_waitpid): Move definition away from being in
18335 between linux_tracefork_child/linux_test_for_tracefork.
18337 * gdb_proc_service.h (psaddr_t): Fix type.
18338 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18339 signature to match glibc.
18341 2009-12-16 Doug Evans <dje@google.com>
18343 * linux-low.c (linux_read_memory): Fix argument to read.
18345 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18347 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18348 events, don't leave current_inferior pointing at null.
18350 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18352 * win32-low.c (LOG): Delete.
18353 (OUTMSG): Output to stderr.
18354 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18355 on compile time LOG macro.
18356 (win32_wait): Fix debug output.
18358 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18360 * win32-low.c (win32_add_one_solib): If the dll name is
18361 "ntdll.dll", prepend the system directory to the dll path.
18363 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18365 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18367 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18368 Vladimir Prus <vladimir@codesourcery.com>
18370 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18371 * configure.ac: Check for __mcoldfire__ and set
18372 gdb_cv_m68k_is_coldfire.
18373 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18374 reg-cf.o and reg-m68k.o.
18375 * configure: Regenerated.
18377 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18379 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18380 Pass it to thread_db_free.
18381 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18382 proper `detaching' argument to linux_remove_process.
18383 * linux-low.h (thread_db_free): Add `detaching' parameter.
18384 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18386 (thread_db_free): Add `detaching' parameter. Only
18387 call td_ta_clear_event if detaching from process.
18389 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18391 * thread-db.c (thread_db_free): Fix typo.
18393 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18396 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18398 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18400 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18401 with an i686 compiler.
18402 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18404 * configure: Rebuilt.
18406 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18410 * server.c (handle_search_memory_1): Correct read_addr initialization
18411 in loop for searching subsequent chunks.
18413 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18415 * configure.ac: New --with-libthread-db option.
18416 * thread-db.c: Allow direct dependence on libthread_db.
18417 (thread_db_free): Adjust.
18418 * config.in: Regenerate.
18419 * configure: Likewise.
18421 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18424 * thread-db.c (attach_thread): New function.
18425 (maybe_attach_thread): Return success/failure.
18426 (find_new_threads_callback): Adjust.
18427 (thread_db_find_new_threads): Loop until no new threads.
18429 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18431 * proc-service.c (ps_lgetregs): Formatting.
18433 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18435 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18436 * configure.ac: Adjust.
18437 * linux-low.h (struct process_info_private): Move members to struct
18439 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18440 * linux-low.c (linux_remove_process): Adjust.
18441 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18442 * server.c (handle_query): Move code ...
18443 (handle_monitor_command): ... here. New function.
18444 * target.h (struct target_ops): New member.
18445 * thread-db.c (struct thread_db): New.
18446 (libthread_db_search_path): New variable.
18447 (thread_db_create_event, thread_db_enable_reporting)
18448 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18449 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18450 (try_thread_db_load_1, dladdr_to_soname): New functions.
18451 (try_thread_db_load, thread_db_load_search): New functions.
18452 (thread_db_init): Search for libthread_db.
18453 (thread_db_free): New function.
18454 (thread_db_handle_monitor_command): Likewise.
18455 * config.in: Regenerate.
18456 * configure: Regenerate.
18458 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18460 * spu-low.c (spu_kill): Wait for inferior to terminate.
18461 Call clear_inferiors.
18462 (spu_detach): Call clear_inferiors.
18464 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18466 * aclocal.m4: Regenerate.
18467 * config.in: Likewise.
18468 * configure: Likewise.
18470 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18472 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18473 (parse_spufs_run): New function.
18474 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18475 (ppc_breakpoint_at): Handle SPU breakpoints.
18477 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18479 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18480 (SPUFS_MAGIC): Define.
18481 (spu_enumerate_spu_ids): New function.
18482 (linux_qxfer_spu): New function.
18483 (linux_target_ops): Install linux_qxfer_spu.
18485 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18487 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18488 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18489 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18490 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18491 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18492 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18493 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18494 (init_registers_powerpc_cell32l): Add prototype.
18495 (init_registers_powerpc_cell64l): Likewise.
18496 (ppc_arch_setup): Detect Cell/B.E. architecture.
18498 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18500 * Makefile.in (datarootdir): New variable.
18502 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18504 * linux-low.c (linux_write_memory): Update debugging output.
18505 * Makefile.in (clean): Add new descriptions.
18506 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18507 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18508 * configure.srv: Add new files for arm*-*-linux*.
18509 * linux-arm-low.c: Add new declarations.
18510 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18511 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18512 (HWCAP_VFPv3D16): New.
18513 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18514 instead of __IWMMXT__.
18515 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18516 (arm_arch_setup): New.
18517 (target_regsets): Remove #ifdef. Add VFP regset.
18518 (the_low_target): Use arm_arch_setup.
18520 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18522 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18523 the main thread again.
18525 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18527 Adding Neutrino gdbserver.
18528 * configure: Regenerated.
18529 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18530 * configure.srv (i[34567]86-*-nto*): New target.
18531 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18532 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18533 (nto_comctrl) [__QNX__]: New function.
18534 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18536 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
18538 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18541 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18542 Pedro Alves <pedro@codesourcery.com>
18544 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18545 don't support CONTEXT_EXTENDED_REGISTERS.
18546 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18547 (the_low_target): Install them.
18548 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18549 failing with ERROR_PIPE_NOT_CONNECTED.
18551 2009-06-30 Doug Evans <dje@google.com>
18552 Pierre Muller <muller@ics.u-strasbg.fr>
18554 Add h/w watchpoint support to x86-linux, win32-i386.
18555 * Makefile.in (SFILES): Add i386-low.c
18556 (i386_low_h): Define.
18557 (i386-low.o): Add dependencies.
18558 (linux-x86-low.o): Add i386-low.h dependency.
18559 (win32-i386-low.o): Ditto.
18560 * i386-low.c: New file.
18561 * i386-low.h: New file.
18562 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18563 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18564 * linux-low.c (linux_add_process): Initialize arch_private.
18565 (linux_remove_process): Free arch_private.
18566 (add_lwp): Initialize arch_private.
18567 (delete_lwp): Free arch_private.
18568 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18570 * linux-low.h (process_info_private): New member arch_private.
18571 (lwp_info): New member arch_private.
18572 (linux_target_ops): New members new_process, new_thread,
18574 (ptid_of): New macro.
18575 * linux-x86-low.c: Include stddef.h, i386-low.h.
18576 (arch_process_info): New struct.
18577 (arch_lwp_info): New struct.
18578 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18579 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18580 (i386_dr_low_get_status): New function.
18581 (x86_insert_point, x86_remove_point): New functions.
18582 (x86_stopped_by_watchpoint): New function.
18583 (x86_stopped_data_address): New function.
18584 (x86_linux_new_process, x86_linux_new_thread): New functions.
18585 (x86_linux_prepare_to_resume): New function.
18586 (the_low_target): Add entries for insert_point, remove_point,
18587 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18589 * server.c (debug_hw_points): New global.
18590 (monitor_show_help): Document set debug-hw-points.
18591 (handle_query): Process "set debug-hw-points".
18592 * server.h (debug_hw_points): Declare.
18593 (paddress): Declare.
18594 * utils.c (NUMCELLS, CELLSIZE): New macros.
18595 (get_sell, xsnprintf, paddress): New functions.
18596 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18597 remove_point, stopped_by_watchpoint, stopped_data_address.
18598 * win32-i386-low.c: Include i386-low.h.
18599 (debug_reg_state): Replaces dr.
18600 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18601 (i386_dr_low_get_status): New function.
18602 (i386_insert_point, i386_remove_point): New functions.
18603 (i386_stopped_by_watchpoint): New function.
18604 (i386_stopped_data_address): New function.
18605 (i386_initial_stuff): Update.
18606 (get_thread_context,set_thread_context,i386_thread_added): Update.
18607 (the_low_target): Add entries for insert_point,
18608 remove_point, stopped_by_watchpoint, stopped_data_address.
18609 * win32-low.c (win32_insert_watchpoint): New function.
18610 (win32_remove_watchpoint): New function.
18611 (win32_stopped_by_watchpoint): New function.
18612 (win32_stopped_data_address): New function.
18613 (win32_target_ops): Add entries for insert_watchpoint,
18614 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18615 * win32-low.h (win32_target_ops): New members insert_point,
18616 remove_point, stopped_by_watchpoint, stopped_data_address.
18618 2009-06-25 Pedro Alves <pedro@codesourcery.com>
18620 * server.c (process_serial_event): Re-return unsupported, not
18621 error, if the type isn't recognized. Re-allow supporting only
18622 insert or remove packets. Also call require_running for
18623 breakpoints. Add missing break statement to default case. Tidy.
18624 * target.h (struct target_ops): Rename insert_watchpoint to
18625 insert_point, and remove_watchpoint to remove_point.
18627 * linux-low.h (struct linux_target_ops): Likewise.
18628 * linux-low.c (linux_insert_watchpoint): Rename to ...
18629 (linux_insert_point): ... this. Adjust.
18630 (linux_remove_watchpoint): Rename to ...
18631 (linux_remove_point): ... this. Adjust.
18632 (linux_target_ops): Adjust.
18633 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18634 (cris_insert_point): ... this.
18635 (cris_remove_watchpoint): Rename to ...
18636 (cris_remove_point): ... this.
18637 (the_low_target): Adjust.
18639 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18641 * server.c (handle_v_kill): Pass signal_pid to
18642 kill_inferior if multi_process is zero.
18644 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18646 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18647 * target.h (target_ops): Comment for *_watchpoint to make it clear
18648 the functions can get types '0' and '1'.
18650 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18652 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18653 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18654 * regcache.c (get_regcache): Likewise.
18655 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18656 * win32-low.c (child_fetch_inferior_registers): Remove check for
18659 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18660 Pedro Alves <pedro@codesourcery.com>
18662 * target.h (struct target_ops) <supports_multi_process>: New
18664 (target_supports_multi_process): New.
18665 * server.c (handle_query): Even if GDB reports support, only
18666 enable multi-process if the target also supports it. Report
18667 multi-process support only if the target backend supports it.
18668 * linux-low.c (linux_supports_multi_process): New function.
18669 (linux_target_ops): Install it as target_supports_multi_process
18672 2009-05-24 Doug Evans <dje@google.com>
18674 Global renaming of find_thread_pid to find_thread_ptid.
18675 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18676 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18677 All callers updated.
18679 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18680 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18683 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18684 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18685 (linux_resume_one_lwp): Ditto.
18687 2009-05-23 Doug Evans <dje@google.com>
18689 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18690 from struct inferior_list_entry * to struct lwp_info *.
18691 All callers updated.
18693 2009-05-13 Doug Evans <dje@google.com>
18695 * linux-x86-low.c: Don't include assert.h.
18696 (x86_siginfo_fixup): Use fatal, not assert.
18697 (x86_arch_setup): Fix comment.
18699 2009-05-12 Doug Evans <dje@google.com>
18701 Biarch support for i386/amd64 gdbserver.
18702 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18703 Add linux-x86-low.c.
18704 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18705 (linux-x86-low.o): Add.
18706 * linux-x86-64-low.c: Delete.
18707 * linux-i386-low.c: Delete.
18708 * linux-x86-low.c: New file.
18709 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18711 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18713 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18714 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18715 (linux_child_pid_to_exec_file): New function.
18716 (elf_64_header_p, elf_64_file_p): New functions.
18717 (siginfo_fixup): New function.
18718 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18719 give target a chance to convert layout.
18720 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18721 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18723 2009-05-07 Doug Evans <dje@google.com>
18725 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18726 (regsets_store_inferior_registers): Ditto.
18728 2009-05-06 Pedro Alves <pedro@codesourcery.com>
18732 * linux-low.c (must_set_ptrace_flags): Delete.
18733 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18735 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18736 `lwp->must_set_ptrace_flags' instead.
18737 (linux_wait_for_event_1): Set ptrace options here.
18738 (linux_wait_1): ... not here.
18740 2009-04-30 Doug Evans <dje@google.com>
18742 * inferiors.c (started_inferior_callback): New function.
18743 (attached_inferior_callback): New function.
18744 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18745 * server.c (print_started_pid, print_attached_pid): New functions.
18746 (detach_or_kill_for_exit): New function.
18747 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18748 * server.h (have_started_inferiors_p): Declare.
18749 (have_attached_inferiors_p): Declare.
18751 * inferiors.c (remove_process): Fix memory leak, free process.
18752 * linux-low.c (linux_remove_process): New function.
18753 (linux_kill): Call it instead of remove_process.
18754 (linux_detach, linux_wait_1): Ditto.
18756 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18758 * configure.srv: Add x86 Windows CE target.
18760 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18762 * inferiors.c (get_thread_process): Make global.
18763 * server.h (get_thread_process): Add prototype.
18764 * thread-db.c (find_one_thread): Use get_thread_process
18765 instead of current_process.
18766 (thread_db_get_tls_address): Do not crash if called when
18767 thread layer is not yet initialized.
18769 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18771 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18772 * spu-low.c (current_tid): Rename to ...
18773 (current_ptid): ... this.
18774 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18775 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18776 ptid_get_lwp (current_ptid) instead of current_tid.
18777 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18778 instead of current_tid. Use find_process_pid to verify pid
18779 argument is valid. Pass proper argument to remove_process.
18780 (spu_thread_alive): Compare current_ptid instead of current_tid.
18781 (spu_resume): Likewise.
18783 2009-04-02 Pedro Alves <pedro@codesourcery.com>
18785 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18788 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18790 Implement the multiprocess extensions, and add linux multiprocess
18793 * server.h (ULONGEST): Declare.
18794 (struct ptid, ptid_t): New.
18795 (minus_one_ptid, null_ptid): Declare.
18796 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18797 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18798 (struct inferior_list_entry): Change `id' type from unsigned from
18800 (struct sym_cache, struct breakpoint, struct
18801 process_info_private): Forward declare.
18802 (struct process_info): Declare.
18803 (current_process): Declare.
18804 (all_processes): Declare.
18805 (initialize_inferiors): Declare.
18806 (add_thread): Adjust to use ptid_t.
18807 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18808 (add_process, remove_process, find_thread_pid): Declare.
18809 (find_inferior_id): Adjust to use ptid_t.
18810 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18811 (multi_process): Declare.
18812 (push_event): Adjust to use ptid_t.
18813 (read_ptid, write_ptid): Declare.
18814 (prepare_resume_reply): Adjust to use ptid_t.
18815 (clear_symbol_cache): Declare.
18816 * inferiors.c (all_processes): New.
18817 (null_ptid, minus_one_ptid): New.
18818 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18819 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18820 (add_thread): Change unsigned long to ptid. Remove gdb_id
18822 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18823 (gdb_id_to_thread): Rename to ...
18824 (find_thread_pid): ... this. Change unsigned long to ptid.
18825 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18826 (loaded_dll, pull_pid_from_list): Adjust.
18827 (add_process, remove_process, find_process_pid)
18828 (get_thread_process, current_process, initialize_inferiors): New.
18829 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18830 (struct target_waitstatus) <related_pid>: Ditto.
18831 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18832 return type to int.
18833 (struct target_ops) <join>: Add `pid' argument.
18834 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18835 (struct target_ops) <wait>: Add `ptid' field. Change return type
18837 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18838 (mywait): Add `ptid' argument. Change return type to ptid_t.
18839 (target_pid_to_str): Declare.
18840 * target.c (set_desired_inferior): Adjust to use ptids.
18841 (mywait): Add new `ptid' argument. Adjust.
18842 (target_pid_to_str): New.
18843 * mem-break.h (free_all_breakpoints): Declare.
18844 * mem-break.c (breakpoints): Delelete.
18845 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18846 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18847 to use per-process breakpoint list.
18848 (free_all_breakpoints): New.
18849 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18850 (symbol_cache, all_symbols_looked_up): Delete.
18852 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18854 (prepare_resume_reply): Change ptid argument's type from unsigned
18855 long to ptid_t. Adjust. Implement W;process and X;process.
18856 (free_sym_cache, clear_symbol_cache): New.
18857 (look_up_one_symbol): Adjust to per-process symbol cache. *
18858 * server.c (cont_thread, general_thread, step_thread): Change type
18860 (attached): Delete.
18861 (multi_process): New.
18862 (last_ptid): Change type to ptid_t.
18863 (struct vstop_notif) <ptid>: Change type to ptid_t.
18864 (queue_stop_reply, push_event): Change `ptid' argument's type to
18866 (discard_queued_stop_replies): Add `pid' argument.
18867 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18868 changes. Don't reference the `attached' global.
18869 (attach_inferior): Adjust to mywait interface changes.
18870 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18871 features. Handle and report "multiprocess+". Handle
18873 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18875 (handle_v_kill): New.
18876 (handle_v_stopped): Adjust to use target_pid_to_str.
18877 (handle_v_requests): Allow multiple attaches and runs when
18878 multiprocess extensions are in effect. Handle "vKill".
18879 (myresume): Adjust to use ptids.
18880 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18881 (handle_status): Adjust to discard_queued_stop_replies interface
18883 (first_thread_of, kill_inferior_callback)
18884 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18885 (main): Call initialize_inferiors. Adjust to use ptids, killing
18886 and detaching from all inferiors. Handle multiprocess packet
18888 * linux-low.h: Include gdb_proc_service.h.
18889 (struct process_info_private): New.
18890 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18891 <lwpid_of>: Use ptid_get_lwp.
18892 (get_lwp_thread): Adjust.
18893 (struct lwp_info): Add `dead' member.
18894 (find_lwp_pid): Declare.
18895 * linux-low.c (thread_db_active): Delete.
18896 (new_inferior): Adjust comment.
18897 (inferior_pid): Delete.
18898 (linux_add_process): New.
18899 (handle_extended_wait): Adjust.
18900 (add_lwp): Change unsigned long to ptid.
18901 (linux_create_inferior): Add process to processes table. Adjust
18902 to use ptids. Don't set new_inferior here.
18903 (linux_attach_lwp): Rename to ...
18904 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18905 it. Adjust to use ptids.
18906 (linux_attach_lwp): New.
18907 (linux_attach): Add process to processes table. Don't set
18909 (struct counter): New.
18910 (second_thread_of_pid_p, last_thread_of_process_p): New.
18911 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18912 multiple processes.
18913 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18914 processes. Remove process from process table.
18915 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18916 to multiple processes.
18917 (any_thread_of): New.
18918 (linux_detach): Add `pid' argument, and handle it. Remove process
18919 from processes table.
18920 (linux_join): Add `pid' argument. Handle it.
18921 (linux_thread_alive): Change unsighed long argument to ptid_t.
18922 Consider dead lwps as not being alive.
18923 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
18924 threads we're not interested in.
18925 (same_lwp, find_lwp_pid): New.
18926 (linux_wait_for_lwp): Change `pid' argument's type from int to
18928 (linux_wait_for_event): Rename to ...
18929 (linux_wait_for_event_1): ... this. Change `pid' argument's type
18930 from int to ptid_t. Adjust.
18931 (linux_wait_for_event): New.
18932 (linux_wait_1): Add `ptid' argument. Change return type to
18933 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
18934 that exit from the process table.
18935 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
18937 (mark_lwp_dead): New.
18938 (wait_for_sigstop): Adjust to use ptids. If a process exits while
18939 stopping all threads, mark its main lwp as dead.
18940 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
18942 (fetch_register, usr_store_inferior_registers)
18943 (regsets_fetch_inferior_registers)
18944 (regsets_store_inferior_registers, linux_read_memory)
18945 (linux_write_memory): Inline `inferior_pid'.
18946 (linux_look_up_symbols): Adjust to use per-process
18947 `thread_db_active'.
18948 (linux_request_interrupt): Adjust to use ptids.
18949 (linux_read_auxv): Inline `inferior_pid'.
18950 (initialize_low): Don't reference thread_db_active.
18951 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
18952 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
18953 (ps_getpid): Return the pid of the current inferior.
18954 * thread-db.c (proc_handle, thread_agent): Delete.
18955 (thread_db_create_event, thread_db_enable_reporting): Adjust to
18957 (find_one_thread): Change argument type to ptid_t. Adjust to
18959 (maybe_attach_thread): Adjust to per-process data and ptids.
18960 (thread_db_find_new_threads): Ditto.
18961 (thread_db_init): Ditto.
18962 * spu-low.c (spu_create_inferior, spu_attach): Add process to
18963 processes table. Adjust to use ptids.
18964 (spu_kill, spu_detach): Adjust interface. Remove process from
18966 (spu_join, spu_thread_alive): Adjust interface.
18967 (spu_wait): Adjust interface. Remove process from processes
18968 table. Adjust to use ptids.
18969 * win32-low.c (current_inferior_tid): Delete.
18970 (current_inferior_ptid): New.
18971 (debug_event_ptid): New.
18972 (thread_rec): Take a ptid. Adjust.
18973 (child_add_thread): Add `pid' argument. Adjust to use ptids.
18974 (child_delete_thread): Ditto.
18975 (do_initial_child_stuff): Add `attached' argument. Add process to
18977 (child_fetch_inferior_registers, child_store_inferior_registers):
18979 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
18980 (win32_attach): Pass 1 to do_initial_child_stuff.
18981 (win32_kill): Adjust interface. Remove process from processes
18983 (win32_detach): Ditto.
18984 (win32_join): Adjust interface.
18985 (win32_thread_alive): Take a ptid.
18986 (win32_resume): Adjust to use ptids.
18987 (get_child_debug_event): Ditto.
18988 (win32_wait): Adjust interface. Remove exiting process from
18991 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18993 Non-stop mode support.
18995 * server.h (non_stop): Declare.
18996 (gdb_client_data, handler_func): Declare.
18997 (delete_file_handler, add_file_handler, start_event_loop):
18999 (handle_serial_event, handle_target_event, push_event)
19000 (putpkt_notif): Declare.
19001 * target.h (enum resume_kind): New.
19002 (struct thread_resume): Replace `step' field by `kind' field.
19003 (TARGET_WNOHANG): Define.
19004 (struct target_ops) <wait>: Add `options' argument.
19005 <supports_non_stop, async, start_non_stop>: New fields.
19006 (target_supports_non_stop, target_async): New.
19007 (start_non_stop): Declare.
19008 (mywait): Add `options' argument.
19009 * target.c (mywait): Add `options' argument. Print child exit
19010 notifications here.
19011 (start_non_stop): New.
19012 * server.c (non_stop, own_buf, mem_buf): New globals.
19013 (struct vstop_notif): New.
19014 (notif_queue): New global.
19015 (queue_stop_reply, push_event, discard_queued_stop_replies)
19016 (send_next_stop_reply): New.
19017 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19019 (attach_inferior): In non-stop mode, don't wait for the target
19021 (handle_general_set): Handle QNonStop.
19022 (handle_query): When handling qC, return the current general
19023 thread, instead of the first thread of the list.
19024 (handle_query): If the backend supports non-stop mode, include
19025 QNonStop+ in the qSupported query response.
19026 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19028 (handle_v_attach, handle_v_run): Handle non-stop mode.
19029 (handle_v_stopped): New.
19030 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19031 (myresume): Adjust to use resume_kind. Handle non-stop.
19032 (queue_stop_reply_callback): New.
19033 (handle_status): Handle non-stop mode.
19034 (main): Clear non_stop flag on reconnection. Use the event-loop.
19035 Refactor serial protocol handling from here ...
19036 (process_serial_event): ... to this new function. When GDB
19037 selects any thread, select one here. In non-stop mode, wait until
19038 GDB acks all pending events before exiting.
19039 (handle_serial_event, handle_target_event): New.
19040 * remote-utils.c (remote_open): Install remote_desc in the event
19042 (remote_close): Remove remote_desc from the event loop.
19043 (putpkt_binary): Rename to...
19044 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19045 (putpkt_binary): New as wrapper around putpkt_binary_1.
19046 (putpkt_notif): New.
19047 (prepare_resume_reply): In non-stop mode, don't change the
19049 * event-loop.c: New.
19050 * Makefile.in (OBJ): Add event-loop.o.
19051 (event-loop.o): New rule.
19053 * linux-low.h (pid_of): Moved here.
19055 (get_lwp_thread): Use lwpid_of.
19056 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19057 * linux-low.c (pid_of): Delete.
19058 (inferior_pid): Use lwpid_of.
19059 (linux_event_pipe): New.
19060 (target_is_async_p): New.
19062 (handle_extended_wait): Use lwpid_of.
19063 (add_lwp): Don't set lwpid field.
19064 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19065 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19066 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19067 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19068 first. Adjust to linux_wait_for_event interface changes. Use
19070 (linux_detach): Don't delete the main lwp here.
19071 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19072 (status_pending_p): Don't consider explicitly suspended lwps.
19073 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19074 pointer. Add OPTIONS argument. Change return type to int. Use
19075 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19076 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19077 pointer. Add status pointer argument. Return a pid instead of a
19078 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19079 changes. In non-stop mode, don't switch to a random thread.
19080 (linux_wait): Rename to...
19081 (linux_wait_1): ... this. Add target_options argument, and handle
19082 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19083 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19084 clean exit and signal exit code. Don't stop all threads in
19085 non-stop mode. In all-stop mode, only stop all threads when
19086 reporting a stop to GDB. Handle explicit thread stop requests.
19087 (async_file_flush, async_file_mark): New.
19089 (send_sigstop): Use lwpid_of.
19090 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19091 interface changes. In non-stop mode, don't switch to a random
19093 (linux_resume_one_lwp): Use lwpid_of.
19094 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19095 (linux_resume_one_thread): ... this. Handle resume_stop. In
19096 non-stop mode, don't look for pending flag in all threads.
19097 (resume_status_pending_p): Don't consider explicitly suspended
19099 (my_waitpid): Reimplement. Emulate __WALL.
19100 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19102 (sigchld_handler, linux_supports_non_stop, linux_async)
19103 (linux_start_non_stop): New.
19104 (linux_target_ops): Register linux_supports_non_stop, linux_async
19105 and linux_start_non_stop.
19106 (initialize_low): Install SIGCHLD handler.
19107 * thread-db.c (thread_db_create_event, find_one_thread)
19108 (thread_db_get_tls_address): Use lwpid_of.
19109 * win32-low.c (win32_detach): Adjust to use resume_kind.
19110 (win32_wait): Add `options' argument.
19111 * spu-low.c (spu_resume): Adjust to use resume_kind.
19112 (spu_wait): Add `options' argument.
19114 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19116 Decouple target code from remote protocol.
19118 * target.h (enum target_waitkind): New.
19119 (struct target_waitstatus): New.
19120 (struct target_ops) <wait>: Return an unsigned long. Take a
19121 target_waitstatus pointer instead of a char pointer.
19122 (mywait): Likewise.
19123 * target.c (mywait): Change prototype to return an unsigned long.
19124 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19125 * server.h (thread_from_wait, old_thread_from_wait): Delete
19127 (prepare_resume_reply): Change prototype to take a
19129 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19130 (last_status, last_ptid): New.
19131 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19132 pid instead of a signal.
19133 (attach_inferior): Remove "status" and "signal" parameters.
19135 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19137 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19138 (handle_v_requests, myresume): Remove "status" and "signal"
19139 parameters. Adjust.
19140 (handle_status): New.
19141 (main): Delete local `status'. Adjust.
19142 * remote-utils.c: Include target.h.
19143 (prepare_resume_reply): Change prototype to take a
19144 target_waitstatus. Adjust.
19146 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19148 * spu-low.c (spu_wait): Adjust.
19149 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19151 (win32_wait): Adjust.
19153 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19155 * target.h (struct thread_resume): Delete leave_stopped member.
19156 (struct target_ops): Add a `n' argument to the `resume' callback.
19157 * server.c (start_inferior): Adjust.
19158 (handle_v_cont, myresume): Adjust.
19159 * linux-low.c (check_removed_breakpoint): Adjust to resume
19160 interface change, and to removed leave_stopped field.
19161 (resume_ptr): Delete.
19162 (struct thread_resume_array): New.
19163 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19164 resume interface change.
19165 (linux_continue_one_thread, linux_queue_one_thread)
19166 (resume_status_pending_p): Check if the resume field is NULL
19167 instead of checking the leave_stopped member.
19168 (linux_resume): Adjust to the target resume interface change.
19169 * spu-low.c (spu_resume): Adjust to the target resume interface
19171 * win32-low.c (win32_detach, win32_resume): Ditto.
19173 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19175 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19177 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19179 (linux_continue_one_thread): Only preserve the stepping flag if
19180 there's a pending breakpoint.
19182 2009-03-31 Pedro Alves <pedro@codesourcery.com>
19184 * server.c (main): After the inferior having exited, call
19185 remote_close before exiting gdbserver.
19187 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19189 Fix size of FPSCR in Power 7 processors.
19190 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19191 (PPC_FEATURE_HAS_DFP): New #define.
19192 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19195 2009-03-23 Pedro Alves <pedro@codesourcery.com>
19197 * server.c (handle_query) Whitespace and formatting.
19199 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19201 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19202 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19203 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19204 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19205 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19206 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19207 Makefile.in, configure.ac: Fix whitespace throughout.
19208 * configure: Regenerate.
19210 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19212 * inferiors.c (find_inferior): Make it safe for the callback
19213 function to delete the currently iterated inferior.
19215 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19217 * Makefile.in (linuw_low_h): Move higher.
19218 (thread-db.o): Depend on $(linux_low_h).
19220 2009-03-17 Pedro Alves <pedro@codesourcery.com>
19222 Rename "process" to "lwp" throughout.
19224 * linux-low.c (all_processes): Rename to...
19225 (all_lwps): ... this.
19226 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19227 (add_process): Rename to ...
19228 (add_lwp): ... this. Adjust.
19229 (linux_create_inferior): Adjust.
19230 (linux_attach_lwp): Adjust.
19231 (linux_attach): Adjust.
19232 (linux_kill_one_process): Rename to ...
19233 (linux_kill_one_lwp): ... this. Adjust.
19234 (linux_kill): Adjust.
19235 (linux_detach_one_process): Rename to ...
19236 (linux_detach_one_lwp): ... this. Adjust.
19237 (linux_detach): Adjust.
19238 (check_removed_breakpoint): Adjust.
19239 (status_pending_p): Adjust.
19240 (linux_wait_for_process): Rename to ...
19241 (linux_wait_for_lwp): ... this. Adjust.
19242 (linux_wait_for_event): Adjust.
19243 (send_sigstop): Adjust.
19244 (wait_for_sigstop): Adjust.
19245 (stop_all_processes): Rename to ...
19246 (stop_all_lwps): ... this.
19247 (linux_resume_one_process): Rename to ...
19248 (linux_resume_one_lwp): ... this. Adjust.
19249 (linux_set_resume_request, linux_continue_one_thread)
19250 (linux_queue_one_thread, resume_status_pending_p)
19251 (usr_store_inferior_registers, regsets_store_inferior_registers)
19252 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19254 * linux-low.h (get_process): Rename to ...
19255 (get_lwp): ... this. Adjust.
19256 (get_thread_process): Rename to ...
19257 (get_thread_lwp): ... this. Adjust.
19258 (get_process_thread): Rename to ...
19259 (get_lwp_thread): ... this. Adjust.
19260 (struct process_info): Rename to ...
19261 (struct lwp_info): ... this.
19262 (all_processes): Rename to ...
19263 (all_lwps): ... this.
19264 * proc-service.c (ps_lgetregs): Adjust.
19265 * thread-db.c (thread_db_create_event, find_one_thread)
19266 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19268 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19270 * server.c (handle_query): Handle "qAttached".
19272 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19274 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19275 GPLv3, update license URL.
19277 2009-03-01 Doug Evans <dje@google.com>
19279 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19280 (server_h): Add gdb_signals.h.
19281 (signals.o): Update.
19282 * server.h (target_signal_from_host,target_signal_to_host_p)
19283 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19285 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19287 * remote-utils.c (getpkt): Also generate remote-debug
19288 information if noack_mode is set.
19290 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19292 * server.c (handle_query): Report qXfer:siginfo:read and
19293 qXfer:siginfo:write as supported and handle them.
19294 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19295 * linux-low.c (linux_xfer_siginfo): New.
19296 (linux_target_ops): Set it.
19298 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19300 * server.c (gdbserver_usage): Mention --remote-debug.
19301 (main): Accept '--remote-debug' switch.
19303 2009-01-18 Doug Evans <dje@google.com>
19305 * regcache.c (new_register_cache): No need to check result of xcalloc.
19306 * server.c (handle_search_memory): Back out calls to xmalloc,
19307 result is checked and error is returned to user upon failure.
19308 (handle_query): Ditto. Add more checks for result of malloc.
19309 (handle_v_cont): Check result of malloc, report error back to
19311 (handle_v_run): Ditto. Call freeargv.
19312 * server.h (freeargv): Declare.
19313 * utils.c (freeargv): New fn.
19315 2009-01-15 Doug Evans <dje@google.com>
19317 * gdbreplay.c (perror_with_name): Make arg const char *.
19318 * server.h (target_signal_to_name): Make return type const char *.
19319 * thread-db.c (thread_db_err_str): Make return type const char *.
19320 * utils.c (perror_with_name): Make arg const char *.
19322 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19324 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19325 when handling a EXIT_PROCESS_DEBUG_EVENT.
19327 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19329 * gdbreplay.c (gdbreplay_version): Update copyright year.
19330 * server.c (gdbserver_version): Likewise.
19332 2009-01-05 Doug Evans <dje@google.com>
19334 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19335 (handle_extended_wait): Improve comment.
19337 2008-12-13 Doug Evans <dje@google.com>
19339 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19340 * server.h (ATTR_MALLOC): New macro.
19341 (xmalloc,xcalloc,xstrdup): Declare.
19342 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19343 * inferiors.c: Ditto.
19344 * linux-low.c: Ditto.
19345 * mem-break.c: Ditto.
19346 * regcache.c: Ditto.
19347 * remote-utils.c: Ditto.
19350 * win32-low.c: Ditto.
19352 2008-12-12 Doug Evans <dje@google.com>
19354 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19355 in debugging printf.
19357 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19359 2008-12-09 Doug Evans <dje@google.com>
19361 * linux-low.h (struct process_info): Delete member tid, unused.
19362 * thread-db.c (find_one_thread): Update.
19363 (maybe_attach_thread): Update.
19365 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19367 * target.h (struct target_ops): Add qxfer_osdata member.
19368 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19370 (linux_qxfer_osdata): New functions.
19371 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19373 * server.c (handle_query): Handle "qXfer:osdata:read:".
19374 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19375 (buffer_xml_printf): New functions.
19376 * server.h (struct buffer): New.
19377 (buffer_grow_str, buffer_grow_str0): New macros.
19378 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19379 (buffer_xml_printf): Declare.
19381 2008-11-24 Doug Evans <dje@google.com>
19383 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19385 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19387 * server.c (handle_v_run): Always use the supplied argument list.
19389 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19391 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19392 (xtensa_regmap_table): Add entry for scompare1.
19394 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19396 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19397 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19398 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19399 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19400 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19401 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19402 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19403 XML target descriptions.
19404 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19405 when inferior is running on an ISA 2.05 or later processor. Add
19406 special case to return offset for full 64-bit slot of FPSCR when
19409 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19411 * Makefile.in (SFILES, clean): Added sparc64 files.
19412 (reg-sparc64.o, reg-sparc64.c): New.
19413 * configure.srv (sparc*-*-linux*): New configuration.
19414 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19415 syscall arguments for SPARC.
19416 (regsets_store_inferior_registers): Likewise.
19417 * linux-sparc-low.c: New file.
19419 2008-10-21 Doug Evans <dje@google.com>
19421 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19422 (READLINE_DIR,READLINE_DEP): Delete.
19423 (INTERNAL_CFLAGS): Update.
19424 (LINTFLAGS): Update.
19426 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19428 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19429 whole argv from the last run, not just argv[0].
19431 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19433 * regcache.c (new_register_cache): Return NULL if the register
19434 cache size isn't known yet.
19435 (free_register_cache): Avoid dereferencing a NULL regcache.
19437 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19439 * configure.srv: Merge MIPS and MIPS64.
19441 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19443 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19445 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19447 * Makefile.in: Add required vsx dependencies.
19449 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19450 Declare init_registers_powerpc_vsx32l.
19451 Declare init_registers_powerpc_vsx64l.
19452 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19453 (ppc_arch_setup): Check for VSX in hwcap.
19454 (ppc_fill_vsxregset): New function.
19455 (ppc_store_vsxregset): New function.
19456 Add new VSX entry in regset_info target_regsets.
19458 * configure.srv: Add new VSX dependencies.
19460 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19462 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19463 (remote_open): Set or clear transport_is_reliable.
19464 (putpkt_binary): Don't expect acks in noack mode.
19465 (getpkt): Don't send ack/nac in noack mode.
19466 * server.c (handle_general_set): Handle QStartNoAckMode.
19467 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19469 (main): Reset noack_mode on every connection.
19470 * server.h (noack_mode): Declare.
19472 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19474 * Makefile.in (GDBREPLAY_OBS): New variable.
19475 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19477 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19478 Daniel Jacobowitz <dan@codesourcery.com>
19480 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19481 (usr_store_inferior_registers): Likewise.
19482 (regsets_store_inferior_registers): Likewise.
19484 2008-07-31 Rolf Jansen <rj@surtec.com>
19485 Pedro Alves <pedro@codesourcery.com>
19487 * configure.ac: Check for memmem declaration.
19488 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19489 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19490 (disable_packet_qfThreadInfo): Unconditionally compile.
19491 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19492 * configure, config.in: Regenerate.
19494 2008-07-28 Doug Kwan <dougkwan@google.com>
19496 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19497 (linux_write_memory): Remove declaration of errno.
19499 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19501 * linux-low.c (handle_extended_wait): Do not use "status"
19502 variable uninitialized.
19504 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19506 * server.c (handle_v_attach): Inhibit reporting dll changes.
19508 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19510 * remote-utils.c (prepare_resume_reply): If requested, don't
19511 output "thread:TID" in the T stop reply.
19513 * server.c (disable_packet_vCont, disable_packet_Tthread)
19514 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19515 (handle_query): If requested, disable support for qC, qfThreadInfo
19517 (handle_v_requests): If requested, disable support for vCont.
19518 (gdbserver_show_disableable): New.
19519 (main): Handle --disable-packet and --disable-packet=LIST.
19521 * server.h (disable_packet_vCont, disable_packet_Tthread)
19522 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19524 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19526 * server.c (gdbserver_usage): Mention --version.
19528 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19530 * Makefile.in (gdbreplay.o): New rule.
19532 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19534 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19535 message, not gdbserver.
19537 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
19538 Nathan Sidwell <nathan@codesourcery.com>
19539 Joseph Myers <joseph@codesourcery.com>
19541 * acinclude.m4: Include ../../config/acx.m4.
19542 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19543 * configure, config.in: Regenerate.
19544 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19545 * server.c (gdbserver_version): Print PKGVERSION.
19546 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19547 (main): Adjust gdbserver_usage calls.
19548 * gdbreplay.c (version, host_name): Add declarations.
19549 (gdbreplay_version, gdbreplay_usage): New.
19550 (main): Accept --version and --help options.
19552 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19554 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19555 (arm_breakpoint_at): Handle Thumb.
19556 (the_low_target): Add comment.
19558 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19560 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19562 2008-05-09 Doug Evans <dje@google.com>
19564 * server.h (decode_search_memory_packet): Declare.
19565 * remote-utils.c (decode_search_memory_packet): New fn.
19566 * server.c (handle_search_memory_1): New fn.
19567 (handle_search_memory): New fn.
19568 (handle_query): Process qSearch:memory packets.
19570 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19572 * regcache.c (registers_length): Remove.
19573 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19574 full register packet.
19575 * regcache.h (registers_length): Remove prototype.
19576 * server.h (PBUFSIZ): Define to 16384.
19578 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19580 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19581 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19582 powerpc-64l.o, and powerpc-altivec64l.o.
19583 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19584 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19585 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19586 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19587 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19590 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19591 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19592 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19593 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19594 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19595 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19596 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19597 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19598 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19599 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19602 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19603 (init_registers_powerpc_32l): ... this new prototype.
19604 (init_registers_powerpc_32): Remove, replace by ...
19605 (init_registers_powerpc_altivec32l): ... this new prototype.
19606 (init_registers_powerpc_e500): Remove, replace by ...
19607 (init_registers_powerpc_e500l): ... this new prototype.
19608 (init_registers_ppc64): Remove, replace by ...
19609 (init_registers_powerpc_64l): ... this new prototype.
19610 (init_registers_powerpc_64): Remove, replace by ...
19611 (init_registers_powerpc_altivec64l): ... this new prototype.
19612 (ppc_num_regs): Set to 73.
19613 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19614 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19615 (ppc_cannot_store_register): Handle orig_r3 and trap.
19616 (ppc_arch_setup): Update init_registers_... calls.
19617 (ppc_fill_gregset): Handle orig_r3 and trap.
19619 * inferiors.c (clear_inferiors): Reset current_inferior.
19621 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
19623 * acinclude.m4: Add override.m4.
19624 * configure: Regenerate.
19626 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19628 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19629 initial call to init_register_ppc64.
19631 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19633 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19634 single powerpc*-*-linux* case.
19635 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19637 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19639 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
19640 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
19642 * linux-ppc-low.c: Include <elf.h>.
19643 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19644 (ppc_hwcap): New global variable.
19645 (ppc_regmap): Remove __SPE__ #ifdef sections.
19646 (ppc_regmap_e500): New global variable.
19647 (ppc_cannot_store_register): Update __SPE__ special case.
19648 (ppc_get_hwcap): New function.
19649 (ppc_arch_setup): Use it to determine whether inferior supports
19650 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19651 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19652 Do not access registers if target does not support AltiVec.
19653 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19654 Do not access registers if target does not support SPE.
19655 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19657 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19659 * linux-low.c (disabled_regsets, num_regsets): New.
19660 (use_regsets_p): Delete.
19661 (linux_wait_for_process): Clear disabled_regsets.
19662 (regsets_fetch_inferior_registers): Check and set it.
19663 (regsets_store_inferior_registers): Likewise.
19664 (linux_fetch_registers, linux_store_registers): Do not use
19666 (initialize_low): Allocate disabled_regsets.
19668 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19670 * Makefile.in (LIBOBJS): New.
19671 (OBS): Use LIBOBJS.
19672 (memmem.o): New rule.
19673 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19674 * configure: Regenerated.
19676 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19678 * server.c (handle_query): Never return "unsupported" for
19679 qXfer:features:read queries.
19681 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19683 * server.c (get_features_xml): Fix inverted condition.
19684 (handle_query): Always support qXfer:feature:read.
19686 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19688 * server.c (wrapper_argv): New.
19689 (start_inferior): Handle wrapper_argv. If set, expect an extra
19691 (gdbserver_usage): Document --wrapper.
19692 (main): Parse --wrapper.
19694 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19696 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19697 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19698 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19699 (ppc_set_pc): Likewise.
19700 (ppc_arch_setup): New function.
19701 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19702 of collect_register.
19703 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
19705 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19707 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19708 instead of linux-ppc64-low.o.
19709 * linux-ppc64-low.c: Remove file.
19710 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19711 (linux-ppc64-low.o): Remove rule.
19713 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19714 (init_registers_powerpc_64): Likewise.
19715 (ppc_regmap): Conditionally define depending on __powerpc64__.
19716 (ppc_cannot_store_register): Do not special-case "fpscr" when
19717 compiled on __powerpc64__.
19718 (ppc_collect_ptrace_register): New function.
19719 (ppc_supply_ptrace_register): New function.
19720 (ppc_breakpoint): Change type to "unsigned int".
19721 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19722 (the_low_target): Conditionally provide initializers for the
19723 arch_setup member depending on __powerpc64__. Install
19724 collect_ptrace_register and supply_ptrace_register members.
19726 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19728 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19729 * server.c (gdbserver_xmltarget): Define.
19730 (get_features_xml): Use it to replace "target.xml" and arch_string.
19732 * configure.srv: Remove srv_xmltarget. Add XML files that were
19733 mentioned there to srv_xmlfiles instead. Remove conditional tests
19734 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19735 srv_xmlfiles and srv_regobj to include all possible choices.
19736 * configure.ac (srv_xmltarget): Remove.
19737 (srv_xmlfiles): Do not add "target.xml".
19738 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19739 checks for supplementary target information.
19740 * configure: Regenerate.
19741 * Makefile.in (XML_TARGET): Remove.
19742 (target.xml): Remove rule.
19743 (clean): Do not clean up target.xml.
19744 (.PRECIOUS): Do not mention target.xml.
19746 * target.h (struct target_ops): Remove arch_string member.
19747 * linux-low.c (linux_arch_string): Remove.
19748 (linux_target_ops): Remove arch_string initializer.
19749 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19750 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19751 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19752 * spu-low.c (spu_arch_string): Remove.
19753 (spu_target_ops): Remove arch_string initializer.
19754 * win32-low.c (win32_arch_string): Remove.
19755 (win32_target_ops): Remove arch_string initializer.
19756 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19757 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19758 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19760 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19762 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19763 by collect_ptrace_register and supply_ptrace_register hooks.
19764 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19765 instead of checking for the_low_target.left_pad_xfer.
19766 (usr_store_inferior_registers): Use collect_ptrace_register callback
19767 instead of checking for the_low_target.left_pad_xfer.
19769 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19770 (s390_supply_ptrace_register): Likewise.
19771 (s390_fill_gregset): Call s390_collect_ptrace_register.
19772 (the_low_target): Update.
19774 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19775 (ppc_supply_ptrace_register): Likewise.
19776 (the_low_target): Update.
19778 * linux-i386-low.c (the_low_target): Update.
19779 * linux-x86-64-low.c (the_low_target): Update.
19781 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19783 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19784 reg-s390.o and reg-s390x.o.
19786 * linux-low.c (new_inferior): New global variable.
19787 (linux_create_inferior, linux_attach): Set it.
19788 (linux_wait_for_process): Call the_low_target.arch_setup after the
19789 target has stopped for the first time.
19790 (initialize_low): Do not call the_low_target.arch_setup.
19792 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19793 (s390_set_pc): Likewise.
19794 (s390_arch_setup): New function.
19795 (the_low_target): Use s390_arch_setup as arch_setup routine.
19797 * regcache.c (realloc_register_cache): New function.
19798 (set_register_cache): Call it for each existing regcache.
19800 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19802 * server.h (init_registers): Remove prototype.
19804 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19805 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19806 instead of init_registers ().
19807 * linux-arm-low.c (init_registers_arm): Add prototype.
19808 (init_registers_arm_with_iwmmxt): Likewise.
19809 (the_low_target): Add initializer for arch_setup field.
19810 * linux-cris-low.c (init_registers_cris): Add prototype.
19811 (the_low_target): Add initializer for arch_setup field.
19812 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19813 (the_low_target): Add initializer for arch_setup field.
19814 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19815 (the_low_target): Add initializer for arch_setup field.
19816 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19817 (the_low_target): Add initializer for arch_setup field.
19818 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19819 (the_low_target): Add initializer for arch_setup field.
19820 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19821 (the_low_target): Add initializer for arch_setup field.
19822 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19823 (init_registers_mips64_linux): Likewise.
19824 (the_low_target): Add initializer for arch_setup field.
19825 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19826 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19827 (the_low_target): Add initializer for arch_setup field.
19828 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19829 (init_registers_powerpc_64): Likewise.
19830 (the_low_target): Add initializer for arch_setup field.
19831 * linux-s390-low.c (init_registers_s390): Add prototype.
19832 (init_registers_s390x): Likewise.
19833 (the_low_target): Add initializer for arch_setup field.
19834 * linux-sh-low.c (init_registers_sh): Add prototype.
19835 (the_low_target): Add initializer for arch_setup field.
19836 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19837 (the_low_target): Add initializer for arch_setup field.
19838 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19839 (the_low_target): Add initializer for arch_setup field.
19841 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19842 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19843 instead of init_registers ().
19844 * win32-arm-low.c (init_registers_arm): Add prototype.
19845 (the_low_target): Add initializer for arch_setup field.
19846 * win32-i386-low.c (init_registers_i386): Add prototype.
19847 (the_low_target): Add initializer for arch_setup field.
19849 * spu-low.c (init_registers_spu): Add prototype.
19850 (initialize_low): Call initialie_registers_spu () instead of
19851 initialize_registers ().
19853 2008-02-19 Pedro Alves <pedro@codesourcery.com>
19855 * server.c (handle_v_requests): When handling the vRun and vAttach
19856 packets, if already debugging a process, don't kill it. Return an
19859 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19861 * server.c (handle_query): Correct length check.
19863 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19865 * win32-low.c (do_initial_child_stuff): Add process handle
19866 parameter. Set current_process_handle and current_process_id from the
19867 parameters. Clear globals.
19868 (win32_create_inferior): Don't set current_process_handle and
19869 current_process_id here. Instead pass them on the call to
19870 do_initial_child_stuff.
19871 (win32_attach): Likewise.
19872 (win32_clear_inferiors): New.
19873 (win32_kill): Don't close the current process handle or the
19874 current thread handle here. Instead call win32_clear_inferiors.
19875 (win32_detach): Don't open a new handle to the process. Call
19876 win32_clear_inferiors.
19877 (win32_join): Don't rely on current_process_handle; open a new
19878 handle using the process id.
19879 (win32_wait): Call win32_clear_inferiors when the inferior process
19882 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19884 * server.c (monitor_show_help): Add "exit".
19886 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19888 * Makefile.in (SFILES): Add linux-xtensa-low.c.
19889 (clean): Add reg-xtensa.c.
19890 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
19891 * configure.srv (xtensa*-*-linux*) New target.
19892 * linux-xtensa-low.c: New.
19893 * xtensa-xtregs.c: New.
19895 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19897 * hostio.c: Don't include errno.h.
19898 (errno_to_fileio_errno): Move to hostio-errno.
19899 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19900 error number outputting to the target->hostio_last_error callback.
19901 (hostio_packet_error): Use FILEIO_EINVAL directly.
19902 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19903 calls to hostio_error.
19904 * hostio-errno.c: New.
19905 * server.h (hostio_last_error_from_errno): Declare.
19906 * target.h (target_ops): Add hostio_last_error member.
19907 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19908 as hostio_last_error handler.
19909 * spu-low.c (spu_target_ops): Likewise.
19910 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19911 (wince_hostio_last_error): New functions.
19912 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19913 as hostio_last_error handler.
19914 (win32_target_ops) [!_WIN32_WCE]: Register
19915 hostio_last_error_from_errno as hostio_last_error handler.
19916 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19917 (hostio-errno.o): New rule.
19918 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19919 * configure.srv (srv_hostio_err_objs): New variable. Default to
19921 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19922 * configure: Regenerate.
19924 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19926 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
19927 (linux_kill, linux_detach): Clean up the process list.
19928 * remote-utils.c (remote_open): Improve port number parsing.
19929 (putpkt_binary, input_interrupt): Only send interrupts if the target
19931 * server.c (extended_protocol): Make static.
19932 (attached): Define earlier.
19933 (exit_requested, response_needed, program_argv): New variables.
19934 (target_running): New.
19935 (start_inferior): Clear attached here.
19936 (attach_inferior): Set attached here.
19937 (require_running): Define.
19938 (handle_query): Use require_running and target_running. Implement
19940 (handle_v_attach, handle_v_run): New.
19941 (handle_v_requests): Use require_running. Handle vAttach and vRun.
19942 (gdbserver_usage): Update.
19943 (main): Redo argument parsing. Handle --debug and --multi. Handle
19944 --attach along with other options or after the port. Save
19945 program_argv. Support no initial program. Resynchronize
19946 communication with GDB after an error. Handle "monitor exit".
19947 Use require_running and target_running. Always allow the extended
19948 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
19949 restart in extended mode.
19950 * README: Refer to the GDB manual. Update --attach usage.
19952 2007-12-20 Andreas Schwab <schwab@suse.de>
19954 * linux-low.c (STACK_SIZE): Define.
19955 (linux_tracefork_child): Use it. Use __clone2 on ia64.
19956 (linux_test_for_tracefork): Likewise.
19958 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
19960 * linux-low.c (linux_wait_for_event): Update messages. Do not
19961 reinsert auto-delete breakpoints.
19962 * mem-break.c (struct breakpoint): Change return type of handler to
19964 (set_breakpoint_at): Update handler type.
19965 (reinsert_breakpoint_handler): Return 1 instead of calling
19967 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
19969 (check_breakpoints): Delete auto-delete breakpoints and return 2.
19970 * mem-break.h (set_breakpoint_at): Update handler type.
19971 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
19972 * win32-low.c (auto_delete_breakpoint): New.
19973 (get_child_debug_event): Use it.
19975 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
19977 * configure.ac: Check for pread and pwrite.
19978 * hostio.c (handle_pread): Fall back to lseek and read.
19979 (handle_pwrite): Fall back to lseek and write.
19980 * config.in, configure: Regenerated.
19982 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
19984 * server.c (myresume): Add own_buf argument.
19985 (main): Update calls.
19987 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
19989 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
19990 * remote-utils.c (remote_open): Do not call disable_async_io.
19991 (block_async_io): Delete.
19992 (unblock_async_io): Make static.
19993 (initialize_async_io): New.
19994 * server.c (handle_v_cont): Handle async I/O here.
19995 (myresume): Likewise. Move other common resume tasks here...
19996 (main): ... from here. Call initialize_async_io. Disable async
19997 I/O before the main loop.
19998 * server.h (initialize_async_io): Declare.
19999 (block_async_io, unblock_async_io): Delete prototypes.
20000 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20002 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20004 * remote-utils.c (readchar): Allow binary data in received messages.
20006 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20008 * win32-low.c (attaching): New global.
20009 (win32_create_inferior): Clear the `attaching' global.
20010 (win32_attach): Set the `attaching' global.
20011 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20012 attaching. Only set a breakpoint at the entry point if not
20015 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20017 * server.c (main): Don't report dll events on the initial
20018 connection on attaches.
20020 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20022 * server.c (main): Relax numerical bases supported for the pid of
20023 the --attach command line argument.
20025 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20027 * win32-low.c (win32_attach): Call OpenProcess before
20028 DebugActiveProcess, not after. Add last error output to error
20031 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20033 * win32-low.c (win32_get_thread_context)
20034 (win32_set_thread_context): New functions.
20035 (thread_rec): Use win32_get_thread_context.
20036 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20037 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20040 2007-12-03 Leo Zayas
20041 Pedro Alves <pedro_alves@portugalmail.pt>
20043 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20045 (child_add_thread): Minor cleanup.
20046 (child_continue): Resume artificially suspended threads before
20047 calling ContinueDebugEvent.
20048 (suspend_one_thread): New.
20049 (fake_breakpoint_event): New.
20050 (get_child_debug_event): Change return type to int. Check here if
20051 gdb sent an interrupt request. If a soft interrupt was requested,
20052 fake a breakpoint event. Return 0 if there is no event to handle,
20054 (win32_wait): Don't check here if gdb sent an interrupt request.
20055 Ensure there is a valid event to handle.
20056 (win32_request_interrupt): Add soft interruption method as last
20059 2007-12-03 Leo Zayas
20060 Pedro Alves <pedro_alves@portugalmail.pt>
20062 * win32-low.h (win32_thread_info): Add descriptions to the
20063 structure members. Replace `suspend_count' counter by a
20065 * win32-low.c (thread_rec): Update condition of when to get the
20066 context from the inferior. Rely on ContextFlags being set if it
20067 has already been retrieved. Only suspend the inferior thread if
20068 we haven't already. Warn if that fails.
20069 (continue_one_thread): s/suspend_count/suspended/. Only call
20070 ResumeThread once. Warn if that fails.
20072 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20074 * win32-low.c (win32_wait): Don't read from the inferior when it
20075 has already exited.
20077 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20079 * Makefile.in (win32_low_h): New variable.
20080 (win32-low.o): Add dependency on $(win32_low_h).
20081 (win32-arm-low.o, win32-i386-low.o): New rules.
20083 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20085 * hostio.c: Correct copyright year.
20087 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20089 * Makefile.in (OBS): Add hostio.o.
20090 (hostio.o): New rule.
20091 * server.h (handle_vFile): Declare.
20092 * hostio.c: New file.
20093 * server.c (handle_v_requests): Take packet_len and new_packet_len
20094 for binary packets. Call handle_vFile.
20095 (main): Update call to handle_v_requests.
20097 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20099 * linux-low.c: Include <sched.h>.
20101 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20103 * linux-low.c (linux_tracefork_grandchild): New.
20104 (linux_tracefork_child): Use clone.
20105 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20107 2007-10-31 Joel Brobecker <brobecker@adacore.com>
20109 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20111 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20113 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20115 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20117 * inferiors.c (change_inferior_id): Delete.
20118 (add_pid_to_list, pull_pid_from_list): New.
20119 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20120 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20121 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20122 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20123 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20124 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20125 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20126 (using_threads): Always set to 1.
20127 (handle_extended_wait): New.
20128 (add_process): Do not set TID.
20129 (linux_create_inferior): Set must_set_ptrace_flags.
20130 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20131 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20132 (linux_thread_alive): Rename TID argument to LWPID.
20133 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20134 (linux_wait_for_event): Do not use TID or check using_threads. Update
20135 call to dead_thread_notify. Call handle_extended_wait.
20136 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20137 (send_sigstop): Delete sigstop_sent.
20138 (wait_for_sigstop): Avoid TID.
20139 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20140 (linux_test_for_tracefork): New.
20141 (linux_lookup_signals): Use thread_db_active and
20142 linux_supports_tracefork_flag.
20143 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20144 * linux-low.h (get_process_thread): Avoid TID.
20145 (struct process_ifo): Move thread_known and tid to the end. Remove
20147 (linux_attach_lwp, thread_db_init): Update prototypes.
20148 * server.h (change_inferior_id): Delete prototype.
20149 (add_pid_to_list, pull_pid_from_list): New prototypes.
20150 * thread-db.c (thread_db_use_events): New.
20151 (find_first_thread): Rename to...
20152 (find_one_thread): ...this. Update callers and messages. Do not
20153 call fatal. Check thread_db_use_events. Do not call
20154 change_inferior_id or new_thread_notify.
20155 (maybe_attach_thread): Update. Do not call new_thread_notify.
20156 (thread_db_init): Set thread_db_use_events. Check use_events.
20157 * utils.c (fatal, warning): Correct message prefix.
20159 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20161 * Makefile.in (clean): Remove new files.
20162 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20163 (powerpc-64.o, powerpc-64.c): New rules.
20164 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20165 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20167 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20169 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20170 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20171 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20172 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20173 (target_regsets): Add AltiVec and SPE register sets.
20174 * configure.ac: Check for AltiVec and SPE.
20175 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20176 (ppc_fill_vrregset, ppc_store_vrregset): New.
20177 (target_regsets): Add AltiVec register set.
20178 * configure: Regenerated.
20180 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20182 * linux-low.c (O_LARGEFILE): Define.
20183 (linux_read_memory): Use /proc/PID/mem.
20184 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20185 * configure, config.in: Regenerated.
20187 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20189 * linux-low.c (linux_wait_for_event): Do not pass signals while
20192 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20194 * win32-low.c (create_process): New.
20195 (win32_create_inferior): Use create_process instead of
20196 CreateProcess. If create_process failed retry appending an ".exe"
20197 suffix. Store the GetLastError result immediatelly after
20198 create_process calls and use it on the call to error.
20200 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20202 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20204 2007-08-23 Joel Brobecker <brobecker@adacore.com>
20206 * configure.ac: Switch license to GPLv3.
20208 2007-08-01 Michael Snyder <msnyder@access-company.com>
20210 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20212 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20214 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20216 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20217 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20218 CloseToolhelp32Snapshot.
20219 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20220 CloseToolhelp32Snapshot.
20222 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
20224 * server.c (main): Check for inferior exit before main loop.
20226 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20228 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20229 instead of on tmp_desc.
20231 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20232 Daniel Jacobowitz <dan@codesourcery.com>
20234 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20235 (add_thread): Minor cleanups.
20236 (clear_inferiors): Move lower in the file. Clear the DLL
20238 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20239 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20240 (xml_escape_text): New.
20241 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20243 (handle_v_cont): Report errors.
20244 (gdbserver_version): Update.
20245 (main): Correct size of own_buf. Do not report initial DLL events.
20246 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20247 (unloaded_dll, xml_escape_text): New.
20248 * win32-low.c (enum target_waitkind): Update comments.
20249 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20250 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20251 (win32_EnumProcessModules, win32_GetModuleInformation)
20252 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20253 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20254 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20255 (win32_Module32First, win32_Module32Next, load_toolhelp)
20256 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20257 (get_child_debug_event): Handle DLL events.
20258 (win32_wait): Likewise.
20260 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20262 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20263 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20265 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20267 * win32-low.c (handle_output_debug_string): Ignore event if not
20270 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20272 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20274 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20276 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20278 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20280 * inferiors.c (change_inferior_id): Add comment.
20281 * linux-low.c (check_removed_breakpoint): Add an early
20282 prototype. Improve debug output.
20283 (linux_attach): Doc update.
20284 (linux_detach_one_process, linux_detach): Clean up before releasing
20286 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20287 * linux-low.h (struct process_info): Doc improvement.
20288 * mem-break.c (delete_all_breakpoints): New.
20289 * mem-break.h (delete_all_breakpoints): New prototype.
20290 * thread-db.c (find_first_thread): New.
20291 (thread_db_create_event): Call it instead of
20292 thread_db_find_new_threads. Clean up unused variables.
20293 (maybe_attach_thread): Remove first thread handling.
20294 (thread_db_find_new_threads): Use find_first_thread.
20295 (thread_db_get_tls_address): Likewise.
20297 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20299 * thread-db.c (thread_db_find_new_threads): Add prototype.
20300 (thread_db_create_event): Check for the main thread before adding
20302 (maybe_attach_thread): Only enable event reporting if TID == 0.
20303 (thread_db_get_tls_address): Check for new threads.
20305 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20307 * linux-low.c (linux_create_inferior): Try execv before execvp.
20308 * spu-low.c (spu_create_inferior): Likewise.
20310 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20312 * linux-low.c (linux_create_inferior): Change execv to execvp.
20313 * spu-low.c (spu_create_inferior): Likewies.
20315 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20317 * Makefile.in (clean): Clean new files instead of deleted ones.
20318 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20319 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20321 * configure.srv: Specify XML files and new regformats for MIPS and
20323 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20324 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20325 an entry for the restart register.
20326 (mips_cannot_fetch_register, mips_cannot_store_register)
20327 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20328 register names to match the XML descriptions.
20329 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20330 restart register instead of $0.
20332 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20333 Markus Deuling <deuling@de.ibm.com>
20335 * remote-utils.c (decode_xfer_write): New function.
20336 * server.h (decode_xfer_write): Add prototype.
20337 * server.c (handle_query): Add PACKET_LEN argument. Support
20338 qXfer:spu:read and qXfer:spu:write packets.
20339 (main): Pass packet_len to handle_query.
20340 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20341 * target.h (target_ops): Add qxfer_spu.
20343 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20345 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20346 accessing non-seekable spufs files.
20348 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20350 * server.c (handle_query): Add reply for qC packet.
20352 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20353 Leo Zayas <lerele@champenstudios@com>
20355 * server.h (check_remote_input_interrupt_request): New function.
20356 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20357 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20358 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20359 (check_remote_input_interrupt_request): New function.
20360 * server.h (check_remote_input_interrupt_request): Declare.
20361 * win32-low.c (winapi_DebugBreakProcess,
20362 winapi_GenerateConsoleCtrlEvent): New typedefs.
20363 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20365 (win32_wait): Check for remote interrupt request
20366 with check_remote_input_interrupt_request.
20367 (win32_request_interrupt): New function.
20368 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20370 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20372 * win32-low.c (debug_registers_changed,
20373 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20374 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20375 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20376 (thread_rec): Get context using the low target.
20377 (child_add_thread): Call thread_added on the low target,
20378 which does the same thing.
20380 (do_initial_child_stuff): Remove debug registers references.
20381 Set context using the low target. Resume threads after
20382 setting the contexts.
20383 (child_continue): Remove dead variable. Remove debug
20384 registers references.
20385 (child_fetch_inferior_registers): Go through the low target.
20386 (do_child_store_inferior_registers): Remove.
20387 (child_store_inferior_registers): Go through the low target.
20388 (win32_resume): Remove debug registers references.
20389 Set context using the low target.
20390 (handle_exception): Change return type to void. Don't record
20391 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20392 first chance exception.
20393 (get_child_debug_event): Change return type to void. Remove
20394 goto loop. Always return after waiting for debug event.
20395 (win32_wait): Convert to switch statement. Handle spurious
20398 * win32-i386-low.c (debug_registers_changed,
20399 debug_registers_used): New.
20400 (initial_stuff): Rename to ...
20401 (i386_initial_stuff): ... this. Clear debug registers
20403 (store_debug_registers): Delete.
20404 (i386_get_thread_context): New.
20405 (load_debug_registers): Delete.
20406 (i386_set_thread_context): New.
20407 (i386_thread_added): New.
20408 (single_step): Rename to ...
20409 (i386_single_step): ... this.
20410 (do_fetch_inferior_registers): Rename to ...
20411 (i386_fetch_inferior_register): ... this.
20412 (i386_store_inferior_register): New.
20413 (the_low_target): Adapt to new interface.
20415 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20416 (arm_get_thread_context): New.
20417 (arm_set_thread_context): New.
20419 (do_fetch_inferior_registers): Rename to ...
20420 (arm_fetch_inferior_register): ... this.
20421 (arm_store_inferior_register): New.
20422 (arm_wince_breakpoint): Reimplement as unsigned long.
20423 (arm_wince_breakpoint_len): Define.
20424 (the_low_target): Adapt to new interface.
20426 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20427 load_debug_registers. Add get_thread_context, set_thread_context,
20428 thread_added and store_inferior_register. Rename
20429 fetch_inferior_registers to fetch_inferior_register.
20430 (regptr): Remove declaration.
20432 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20434 * linux-low.c (linux_detach): Change return type to int. Return 0.
20435 * spu-low.c (spu_detach): Likewise.
20437 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20439 * target.h (target_ops): Change return type of detach to int.
20441 (join_inferior): New.
20442 * server.c (main): Don't skip detach support on mingw32.
20443 If the inferior doesn't support detaching return error.
20444 Call join_inferior instead of using waitpid.
20445 * linux-low.c (linux_join): New.
20446 (linux_target_op): Add linux_join.
20447 * spu-low.c (spu_join): New.
20448 (spu_target_ops): Add spu_join.
20449 * win32-low.c (win32_detach): Adapt to new interface.
20450 Reopen current_process_handle before detaching. Issue a child
20451 resume before detaching.
20453 (win32_target_op): Add win32_join.
20455 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20457 * win32-low.c (win32-attach): Fix return value.
20458 * target.h (target_ops): Describe ATTACH return values.
20460 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20462 * win32-low.c (GETPROCADDRESS): Define.
20463 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20464 (winapi_DebugSetProcessKillOnExit): Likewise.
20465 (win32_create_inferior): Force usage of ansi CreateProcessA.
20466 (win32_attach): Use GETPROCADDRESS.
20467 (win32_detach): Likewise.
20469 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20471 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20473 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20475 * win32-low.c: Commit leftover changes from 2007-03-29.
20477 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20479 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20480 fields short instead of int. Add explicit padding.
20481 (i387_cache_to_fsave): Remove unnecessary casts.
20482 (i387_fsave_to_cache): Doc fix.
20483 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20485 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20487 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20488 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20490 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20492 * configure.srv (arm*-*-mingw32ce*): Move near the other
20495 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20497 * configure.ac: Add errno checking.
20498 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20499 sys/file.h and malloc.h.
20500 (AC_CHECK_DECLS): Add perror.
20501 (srv_mingwce): Handle.
20502 * configure.srv (i[34567]86-*-cygwin*): Add
20503 win32-i386-low.o to srv_tgtobj.
20504 (i[34567]86-*-mingw*): Likewise.
20505 (arm*-*-mingw32ce*): Add case.
20506 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20507 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20508 [__MINGW32CE__] (strerror): New function.
20509 [__MINGW32CE__] (errno): Define to GetLastError.
20510 [__MINGW32CE__] (COUNTOF): New macro.
20511 (remote_open): Remove extra close call.
20512 * mem-break.c (delete_breakpoint_at): New function.
20513 * mem-break.h (delete_breakpoint_at): Declare.
20514 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20515 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20516 [USE_WIN32API] (read, write): Add char* casts.
20517 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20518 * server.h: Include wincecompat.h on Windows CE.
20519 [HAVE_ERRNO_H]: Check.
20520 (perror): Declare if not declared.
20521 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20522 (perror_with_name): Remove errno declaration.
20523 * wincecompat.h: New.
20524 * wincecompat.c: New.
20525 * win32-low.h: New.
20526 * win32-arm-low.c: New.
20527 * win32-i386-low.c: New.
20528 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20529 (OUTMSG2): Make it safe.
20531 (COUNTOF): New macro.
20532 (NUM_REGS): Get it from the low target.
20533 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20534 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20535 (thread_rec): Let low target handle debug registers.
20536 (child_add_thread): Likewise.
20537 (child_init_thread_list): Likewise.
20538 (continue_one_thread): Likewise.
20540 (do_child_fetch_inferior_registers): Move to ...
20541 * win32-i386-low.c: ... here, and rename to ...
20542 (do_fetch_inferior_registers): ... this.
20543 * win32-low.c (child_fetch_inferior_registers):
20544 Go through the low target.
20545 (do_child_store_inferior_registers): Use regptr.
20546 (strwinerror): New function.
20547 (win32_create_inferior): Handle Windows CE.
20548 Use strwinerror instead of strerror on Windows error
20549 codes. Add program to the error output.
20550 Don't close the main thread handle on Windows CE.
20551 (win32_attach): Use coredll.dll on Windows CE.
20552 (win32_kill): Close current process and current
20554 (win32_detach): Use coredll.dll on Windows CE.
20555 (win32_resume): Let low target handle debug registers, and
20557 (handle_exception): Add/Remove initial breakpoint. Avoid
20558 non-existant WSTOPSIG on Windows CE.
20559 (win32_read_inferior_memory): Cast to remove warning.
20560 (win32_arch_string): Go through the low target.
20561 (initialize_low): Call set_breakpoint_data with the low
20562 target's breakpoint.
20563 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20564 FOP_REGNUM, mappings): Move to ...
20565 * win32-i386-low.c: ... here.
20566 * win32-low.c (win32_thread_info): Move to ...
20567 * win32-low.h: ... here.
20568 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20569 win32-arm-low.c and wincecompat.c.
20570 (all:): Add $EXEEXT.
20571 (install-only:): Likewise.
20572 (gdbserver:): Likewise.
20573 (gdbreplay:): Likewise.
20574 * config.in: Regenerate.
20575 * configure: Regenerate.
20577 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20579 * win32-low.c: Rename typedef thread_info to
20580 win32_thread_info throughout.
20582 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20584 * win32-i386-low.c: Rename to ...
20585 * win32-low.c: ... this.
20586 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20587 * Makefile.in: Likewise.
20589 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20591 * remote-utils.c (monitor_output): Constify msg parameter.
20592 * server.h (monitor_output): Likewise.
20593 * win32-i386-low.c (handle_output_debug_string): New.
20594 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20595 handle_output_debug_string.
20596 (get_child_debug_event): Likewise.
20598 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20600 * server.c (main): Correct strtoul check.
20602 2007-03-27 Jon Ringle <jon@ringle.org>
20604 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20606 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20608 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20610 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20612 * terminal.h: Check HAVE_SGTTY_H.
20614 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
20616 * remote-utils.c (remote_open): Print out the assigned port number.
20618 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20620 * remote-utils.c (monitor_output): New function.
20621 * server.c (debug_threads): Define here.
20622 (monitor_show_help): New function.
20623 (handle_query): Handle qRcmd.
20624 (main): Do not handle 'd' packet.
20625 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20626 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20629 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20631 * Makefile.in (EXEEXT): New.
20632 (clean): Use $(EXEEXT).
20634 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20636 * target.h (target_ops): Rename send_signal to request_interrupt,
20637 and remove enum target_signal parameter.
20638 * linux-low.c (linux_request_interrupt): Rename from
20639 linux_send_signal, and always send SIGINT.
20640 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20641 and always send SIGINT.
20642 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20644 (input_interrupt): Likewise.
20646 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20648 * server.c (get_features_xml): Check if target implemented
20650 * win32-i386-low.c (win32_arch_string): New.
20651 (win32_target_ops): Add win32_arch_string as arch_string member.
20653 2007-02-22 Markus Deuling <deuling@de.ibm.com>
20655 * spu-low.c (spu_arch_string): New.
20656 (spu_target_ops): Add spu_arch_string.
20658 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20660 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20661 * configure.ac: Do not check for terminal.h.
20662 * configure, config.in: Regenerated.
20664 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20666 * Makefile.in (OBS): Add $(XML_BUILTIN).
20667 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20669 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20670 (arm-with-iwmmxt.c): New.
20671 * config.in, configure: Regenerate.
20672 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20673 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20674 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20675 (arm*-*-linux*): Add iWMMXt and regset support.
20676 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20677 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20678 (arm_store_wmmxregset, target_regsets): New.
20679 * server.c (get_features_xml): Take annex argument. Check builtin
20681 (handle_query): Handle multiple annexes.
20683 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20685 * remote-utils.c [USE_WIN32API] (read, write): Define.
20686 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20689 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20691 * linux-i386-low.c (the_low_target): Set arch_string.
20692 * linux-x86-64-low.c (the_low_target): Likewise.
20693 * linux-low.c (linux_arch_string): New.
20694 (linux_target_ops): Add it.
20695 * linux-low.h (struct linux_target_ops): Add arch_string.
20696 * server.c (write_qxfer_response): Use const void * for DATA.
20697 (get_features_xml): New.
20698 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20699 * target.h (struct target_ops): Add arch_string method.
20701 2007-01-03 Denis Pilat <denis.pilat@st.com>
20702 Daniel Jacobowitz <dan@codesourcery.com>
20704 * linux-low.c (linux_kill): Handle being called with no threads.
20705 * win32-i386-low.c (win32_kill): Likewise.
20706 (get_child_debug_event): Clear current_process_handle.
20708 2006-12-30 Denis PILAT <denis.pilat@st.com>
20709 Daniel Jacobowitz <dan@codesourcery.com>
20711 * remote-utils.c (remote_open): Check the type of specified
20712 serial port devices before opening them.
20713 * server.c (main): Kill the inferior if an error occurs during
20714 the first remote_open.
20716 2006-12-05 Markus Deuling <deuling@de.ibm.com>
20718 * README: Update supported targets.
20720 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20722 * Makefile.in (clean): Remove reg-mips64.c.
20723 (reg-mips64.c, reg-mips64.o): New rules.
20724 * configure.srv: Handle mips64. Include regset support for mips.
20725 * linux-mips-low.c (union mips_register): New.
20726 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20727 (mips_breakpoint, mips_breakpoint_at): Use int.
20728 (mips_collect_register, mips_supply_register)
20729 (mips_collect_register_32bit, mips_supply_register_32bit)
20730 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20731 (mips_store_fpregset, target_regsets): New.
20732 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20734 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20736 * configure.srv: Add target "spu*-*-*".
20737 * Makefile.in (clean): Remove reg-spu.c.
20738 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20739 * spu-low.c: New file.
20741 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20743 * configure.ac: Correct td_thr_tls_get_addr test.
20744 * configure: Regenerated.
20746 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20748 * linux-low.c (linux_wait_for_event): Reformat. Use the
20749 pass_signals array.
20750 * remote-utils.c (decode_address_to_semicolon): New.
20751 * server.c (pass_signals, handle_general_set): New.
20752 (handle_query): Mention QPassSignals for qSupported.
20753 (main): Call handle_general_set.
20754 * server.h (pass_signals, decode_address_to_semicolon): New.
20756 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20758 * server.c (handle_query): Correct error handling for read_auxv.
20760 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20762 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20763 and srv_linux_thread_db to yes.
20764 * linux-s390-low.c (s390_fill_gregset): New function.
20765 (target_regsets): Define data structure.
20767 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20769 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20770 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20771 * config.in, configure: Regenerated.
20772 * inferiors.c (gdb_id_to_thread): New function.
20773 (gdb_id_to_thread_id): Use it.
20774 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20775 * linux-low.h (struct process_info): Add th member.
20776 (thread_db_get_tls_address): New prototype.
20777 * remote-utils.c (decode_address): Make non-static.
20778 * server.c (handle_query): Handle qGetTLSAddr.
20779 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20780 * target.h (struct target_ops): Add get_tls_address.
20781 * thread-db.c (maybe_attach_thread): Save the thread handle.
20782 (thread_db_get_tls_address): New.
20784 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20786 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20787 (linux_resume_one_process): Take a siginfo_t *. Update all
20788 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20789 (struct pending_signals): Add a siginfo_t.
20790 (linux_wait_for_process): Always set last_status.
20791 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20792 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20793 * linux-low.h (struct process_info): Add last_status.
20795 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20797 * remote-utils.c (try_rle): New function.
20798 (putpkt_binary): Use it.
20800 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20802 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20803 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20804 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20805 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20806 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20809 2006-08-08 Richard Sandiford <richard@codesourcery.com>
20811 * server.c (terminal_fd): New variable.
20812 (old_foreground_pgrp): Likewise.
20813 (restore_old_foreground_pgrp): New function.
20814 (start_inferior): Record the terminal file descriptor in terminal_fd
20815 and its original foreground group in old_foreground_pgrp. Register
20816 restore_old_foreground_pgrp with atexit().
20818 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20820 * server.c (handle_query): Correct qPart to qXfer.
20822 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20824 * configure.ac: Check for more headers which are missing on
20825 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20826 * configure.srv: Add Cygwin and mingw32.
20827 * remote-utils.c: Don't include headers unconditionally which
20828 are missing on mingw32. Include <winsock.h> for mingw32.
20829 (remote_open): Adjust for mingw32 support. Flush
20830 standard error after writing to it.
20831 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20832 (unblock_async_io, enable_async_io, disable_async_io)
20833 (readchar, getpkt): Update for Winsock support.
20834 (prepare_resume_reply): Expect a protocol signal number.
20835 * server.c: Disable <sys/wait.h> on mingw32.
20836 (start_inferior): Adjust for mingw32 support. Flush
20837 standard error after writing to it.
20838 (attach_inferior): Likewise. Use protocol signal
20840 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20842 * win32-i386-low.c: New file.
20843 * Makefile.in (XM_CLIBS): Set.
20844 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20845 (win32-i386-low.o): New dependency rule.
20846 * linux-low.c (linux_wait): Use target signal numbers.
20847 * target.h (struct target_ops): Doc fix.
20848 * server.h (target_signal_to_name): New prototype.
20849 * gdbreplay.c: Don't include headers unconditionally which
20850 are missing on mingw32. Include <winsock.h> for mingw32.
20851 (remote_close, remote_open): Adjust for Winsock support.
20852 * configure, config.in: Regenerated.
20854 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20856 * server.c (decode_xfer_read, write_qxfer_response): New.
20857 (handle_query): Take a packet length argument. Handle
20858 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20859 the qSupported response.
20860 (main): Update call to handle_query.
20862 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20864 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20865 (putpkt_binary): Renamed from putpkt and adjusted for binary
20867 (putpkt): New wrapper for putpkt_binary.
20868 (readchar): Don't mask off the high bit.
20869 (decode_X_packet): New function.
20870 * server.c (main): Call putpkt_binary if a handler sets the packet
20871 length. Save the length of the incoming packet. Handle 'X'.
20872 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20874 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20876 * server.c (handle_query): Handle qSupported.
20878 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20880 * remote-utils.c (all_symbols_looked_up): New variable.
20881 (look_up_one_symbol): Check it.
20882 * server.h (look_up_one_symbol): New declaration.
20883 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20885 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20887 * Makefile.in (linux-arm-low.o): Update dependencies.
20888 * linux-arm-low.c: Include "gdb_proc_service.h".
20889 (PTRACE_GET_THREAD_AREA): Define.
20890 (ps_get_thread_area): New function.
20892 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20894 * configure.srv (m68k*-*-uclinux*): New target.
20895 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20896 (linux_resume_one_process): Remove extraneous cast.
20897 (linux_read_offsets): New.
20898 (linux_target_op): Add linux_read_offsets on mmuless systems.
20899 * server.c (handle_query): Add qOffsets logic.
20900 * target.h (struct target_ops): Add read_offsets.
20902 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20904 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20905 (PTRACE_GET_THREAD_AREA): Define.
20906 (ps_get_thread_area): New function.
20907 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20908 (linux-x86-64-low.o): Update.
20910 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20912 * configure.ac: Remove checks for prfpregset_t.
20913 * gdb_proc_service.h: New file.
20914 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20915 new "gdb_proc_service.h".
20916 * proc-service.c: Likewise.
20917 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20918 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20919 * Makefile.in (gdb_proc_service_h): Updated.
20920 * configure, config.in: Regenerated.
20922 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20924 * remote-utils.c (prepare_resume_reply): Move declaration
20925 of gdb_id_from_wait to the top of the block.
20927 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
20929 * linux-low.c (regsets_store_inferior_registers): Read the regset
20930 from the target before filling it.
20932 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20934 * server.c (attach_inferior): Return SIGTRAP for a successful
20937 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
20939 * Makefile.in (OBS): Add version.o.
20940 (STAGESTUFF): Delete.
20941 (version.o): Add dependencies.
20942 (version.c): Replace rule.
20943 (clean): Remove version.c.
20944 * server.c (gdbserver_version): New.
20945 (gdbserver_usage): Use printf.
20946 (main): Handle --version and --help.
20947 * server.h (version, host_name): Add declarations.
20949 2005-12-23 Eli Zaretskii <eliz@gnu.org>
20961 * linux-x86-64-low.c:
20963 * linux-s390-low.c:
20964 * linux-ppc64-low.c:
20966 * linux-mips-low.c:
20967 * linux-m68k-low.c:
20968 * linux-m32r-low.c:
20971 * linux-ia64-low.c:
20972 * linux-i386-low.c:
20973 * linux-crisv32-low.c:
20985 * gdbserver.1: Add (C) after Copyright. Update the FSF
20988 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
20990 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
20991 (arm_breakpoint_at): Recognize both breakpoints.
20992 (the_low_target): Use the correct breakpoint instruction.
20994 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
20996 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
20997 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
20998 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
20999 (the_low_target): Update.
21001 2005-10-25 Andreas Schwab <schwab@suse.de>
21003 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21005 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21006 (ia64_num_regs): Reduce to 462.
21008 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21010 * acinclude.m4: Correct quoting.
21011 * aclocal.m4: Regenerated.
21013 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21014 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21015 (thread_db_init): Call thread_db_err_str.
21016 * configure.ac: Check for TD_VERSION.
21017 * config.in, configure: Regenerated.
21019 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21021 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21023 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21025 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21026 is not available. Define HAVE_PTRACE_GETREGS if it is.
21027 * config.in, configure: Regenerated.
21028 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21029 * linux-i386-low.c, linux-m68k-low.c: Update to use
21030 HAVE_PTRACE_GETREGS.
21031 * linux-low.c (regsets_fetch_inferior_registers)
21032 (regsets_store_inferior_registers): Only return 0 if we processed
21034 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21035 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21037 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21039 * inferiors.c (struct thread_info): Add gdb_id.
21040 (add_thread): Add gdb_id argument.
21041 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21042 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21043 calls to add_thread.
21044 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21045 * server.c (handle_query): Use thread_to_gdb_id.
21046 (handle_v_cont, main): Use gdb_id_to_thread_id.
21047 * server.h (add_thread): Update prototype.
21048 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21051 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21053 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21054 left-padded registers.
21055 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21056 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21058 2005-07-01 Steve Ellcey <sje@cup.hp.com>
21060 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21061 * configure: Regenerate.
21062 * config.in: Regenerate.
21063 * server.h (NEED_DECLARATION_STRERROR):
21064 Replace with !HAVE_DECL_STRERROR.
21066 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21068 * linux-low.c (linux_wait, linux_send_signal): Don't test
21069 an unsigned long variable for > 0 if it could be MAX_ULONG.
21070 * server.c (myresume): Likewise.
21071 * target.c (set_desired_inferior): Likewise.
21073 2005-06-13 Mark Kettenis <kettenis@gnu.org>
21075 * configure.ac: Simplify and improve check for socklen_t.
21076 * configure, config.in: Regenerate.
21078 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21080 * acconfig.h: Remove.
21081 * configure.ac: Add a test for socklen_t. Use three-argument
21082 AC_DEFINE throughout.
21083 * config.in: Regenerated using autoheader 2.59.
21084 * configure: Regenerated.
21086 * gdbreplay.c (socklen_t): Provide a default.
21087 (remote_open): Use socklen_t.
21088 * remote-utils.c (socklen_t): Provide a default.
21089 (remote_open): Use socklen_t.
21090 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21093 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21095 * linux-low.c (linux_read_memory, linux_write_memory)
21096 (linux_read_auxv): Likewise.
21097 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21098 (check_mem_write): Likewise.
21099 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21101 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21102 (registers_from_string, register_data): Likewise.
21103 * server.c (handle_query, main): Likewise.
21104 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21105 (decode_M_packet): Likewise.
21106 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21107 * target.h (struct target_ops): Update read_memory, write_memory,
21109 (read_inferior_memory, write_inferior_memory): Update.
21110 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21111 to unsigned char *.
21112 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21113 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21114 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21115 linux-s390-low.c, linux-sh-low.c: Update for changes in
21116 read_inferior_memory and the_low_target->breakpoint.
21118 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21120 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21121 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21122 * configure.srv: Add powerpc64-*-linux*.
21123 * linux-ppc64-low.c: New file.
21125 2005-05-23 Orjan Friberg <orjanf@axis.com>
21127 * linux-cris-low.c: New file with support for CRIS.
21128 * linux-crisv32-low.c: Ditto for CRISv32.
21129 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21130 (clean): Add reg-cris.c and reg-crisv32.c.
21131 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
21132 reg-crisv32.o, and reg-crisv32.c to make rules.
21133 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21134 recognized targets.
21136 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21138 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21139 of sizeof (PTRACE_XFER_TYPE).
21140 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21142 2005-05-12 Orjan Friberg <orjanf@axis.com>
21144 * target.h (struct target_ops): Add insert_watchpoint,
21145 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21146 pointers for hardware watchpoint support.
21147 * linux-low.h (struct linux_target_ops): Ditto.
21148 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21149 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21150 to linux_target_ops.
21151 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21153 * server.c (main): Recognize 'Z' and 'z' packets.
21155 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21157 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21158 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21159 (the_low_target): Add new members.
21161 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21163 * proc-service.c (ps_lgetregs): Search all_processes instead of
21166 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21168 * server.c (start_inferior): Change return type to int.
21169 (attach_inferior): Change sigptr to int *.
21170 (handle_v_cont, handle_v_requests): Change signal to int *.
21171 (main): Change signal to int.
21173 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
21175 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21176 * configure.srv: Add m32r*-*-linux*.
21177 * linux-m32r-low.c: New file.
21179 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21181 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21183 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21185 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21186 Take unsigned long arguments for PIDs.
21187 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21188 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21189 (wait_for_sigstop, linux_resume_one_process)
21190 (regsets_fetch_inferior_registers, linux_send_signal)
21191 (linux_read_auxv): Likewise. Update the types of variables holding
21192 PIDs. Update format string specifiers.
21193 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21194 * remote-utils.c (prepare_resume_reply): Likewise.
21195 * server.c (cont_thread, general_thread, step_thread)
21196 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21198 (handle_query): Update format specifiers.
21199 (handle_v_cont, main): Use strtoul for thread IDs.
21200 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21201 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21202 (general_thread, step_thread, thread_from_wait)
21203 (old_thread_from_wait): Update.
21204 * target.h (struct thread_resume): Use unsigned long for THREAD.
21205 (struct target_ops): Use unsigned long for arguments to attach and
21208 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21210 * acinclude.m4: Include bfd/bfd.m4 directly.
21211 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21212 <agriffis@toolchain.org>.
21213 * aclocal.m4, configure: Regenerated.
21215 2005-01-07 Andrew Cagney <cagney@gnu.org>
21217 * configure.ac: Rename configure.in, require autoconf 2.59.
21218 * configure: Re-generate.
21220 2004-12-08 Daniel Jacobowitz <dan@debian.org>
21222 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21223 LIBS when finished.
21224 * aclocal.m4: Regenerated.
21225 * configure: Regenerated.
21227 2004-11-21 Andreas Schwab <schwab@suse.de>
21229 * linux-m68k-low.c (m68k_num_gregs): Define.
21230 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21231 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21232 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21233 (m68k_breakpoint_at): New. Add to the_low_target.
21235 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21236 srv_linux_thread_db to yes.
21238 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21240 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21241 (ARCH_SET_FS): Likewise.
21242 (ARCH_GET_FS): Likewise.
21243 (ARCH_GET_GS): Likewise.
21245 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21247 * linux-i386-low.c (ps_get_thread_area): New.
21248 * linux-x86-64-low.c (ps_get_thread_area): New.
21249 * linux-low.c: Include <sys/syscall.h>.
21250 (linux_kill_one_process): Don't kill the first thread here.
21251 (linux_kill): Kill the first thread here.
21252 (kill_lwp): New function.
21253 (send_sigstop, linux_send_signal): Use it.
21254 * proc-service.c: Clean up #ifdefs.
21255 (fpregset_info): Delete.
21256 (ps_lgetregs): Update and enable implementation.
21257 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21259 * remote-utils.c (struct sym_cache, symbol_cache): New.
21260 (input_interrupt): Print a clearer message.
21261 (async_io_enabled): New variable.
21262 (enable_async_io, disable_async_io): Use it. Update comments.
21263 (look_up_one_symbol): Use the symbol cache.
21264 * thread-db.c (thread_db_look_up_symbols): New function.
21265 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21267 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21269 * configure.in: Test for -rdynamic.
21270 * configure: Regenerated.
21271 * Makefile (INTERNAL_LDFLAGS): New.
21272 (gdbserver, gdbreplay): Use it.
21274 2004-09-02 Andrew Cagney <cagney@gnu.org>
21276 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21278 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21280 * linux-low.c (linux_wait): Clear all_processes list also.
21282 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21284 * linux-low.c: Include <errno.h>. Remove extern declaration of
21287 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21289 * gdbreplay.c, server.h, utils.c: Update copyright years.
21291 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21293 * server.c (main): Print child status or termination signal from
21294 variable 'signal', not 'sig'.
21296 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21298 * linux-low.c (linux_read_memory): Change return type to
21299 int. Check for and return error from ptrace().
21300 * target.c (read_inferior_memory): Change return type to int. Pass
21301 back return status from the_target->read_memory().
21302 * target.h (struct target_ops): Adapt *read_memory() prototype.
21304 (read_inferior_memory): Adapt prototype.
21305 * server.c (main): Return an error packet if
21306 read_inferior_memory() returns an error.
21308 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21310 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21311 Unify with other clean targets.
21313 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21315 * server.c (handle_v_cont): Call set_desired_inferior.
21317 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21319 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21321 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21323 * linux-low.c (linux_wait): Unblock async I/O.
21324 (linux_resume): Block and enable async I/O.
21325 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21326 * server.h (block_async_io, unblock_async_io): Add prototypes.
21328 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21330 * remote-utils.c (remote_open): Print a status notice after
21331 opening a TCP port.
21332 * server.c (attach_inferior): Print a status notice after
21335 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21337 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21339 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21341 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21343 * server.c, target.h: Update copyright years.
21345 2004-02-25 Roland McGrath <roland@redhat.com>
21347 * target.h (struct target_ops): New member `read_auxv'.
21348 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21349 * linux-low.c (linux_read_auxv): New function.
21350 (linux_target_ops): Initialize `read_auxv' member to that.
21352 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21354 Committed by Jim Blandy <jimb@redhat.com>.
21356 * linux-s390-low.c (s390_num_regs): Update.
21357 (s390_regmap): Remove control registers. Use __s390x__ predefine
21358 instead of GPR_SIZE to distiguish s390 and s390x targets.
21360 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21362 * linux-low.c: Update copyright year.
21363 (check_removed_breakpoint): Clear pending_is_breakpoint.
21364 (linux_set_resume_request, linux_queue_one_thread)
21365 (resume_status_pending_p): New functions.
21366 (linux_continue_one_thread): Use process->resume.
21367 (linux_resume): Only resume threads if there are no pending events.
21368 * linux-low.h (struct process_info): Add resume request
21371 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21373 * regcache.c (new_register_cache): Clear the allocated register
21374 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21376 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21378 * linux-low.c (linux_resume): Take a struct thread_resume *
21380 (linux_wait): Update call.
21381 (resume_ptr): New static variable.
21382 (linux_continue_one_thread): Renamed from
21383 linux_continue_one_process. Use resume_ptr.
21384 (linux_resume): Use linux_continue_one_thread.
21385 * server.c (handle_v_cont, handle_v_requests): New functions.
21386 (myresume): New function.
21387 (main): Handle 'v' case.
21388 * target.h (struct thread_resume): New type.
21389 (struct target_ops): Change argument of "resume" to struct
21391 (myresume): Delete macro.
21393 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21395 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21396 (uninstall): Support DESTDIR.
21398 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21400 * configure.srv: Add xscale*linux copy of arm*linux entry.
21402 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21404 * linux-arm-low.c (arm_reinsert_addr): New function.
21405 (the_low_target): Add arm_reinsert_addr.
21407 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21409 * mem-break.c: Remove whitespace at end of file.
21411 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21413 * configure.in: Check whether we need to prototype strerror.
21414 * server.h: Optionally prototype strerror.
21415 * gdbreplay.c (perror_with_name): Use strerror.
21416 * linux-low.c (linux_attach_lwp): Use strerror.
21417 * utils.c (perror_with_name): Use strerror.
21418 * config.in, configure: Regenerated.
21420 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21422 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21423 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21425 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21427 * Makefile.in (SFILES): Update.
21428 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21429 low-sun3.c: Remove files.
21431 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21433 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21434 (linux_detach_one_process, linux_detach): New functions.
21435 (linux_target_ops): Add linux_detach.
21436 * server.c (main): Handle 'D' packet.
21437 * target.h (struct target_ops): Add "detach" member.
21438 (detach_inferior): Define.
21440 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21442 From Kelley Cook <kelleycook@wideopenwest.com>:
21443 * configure.srv: Accept i[34567]86 variants.
21445 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21447 * linux-low.c (linux_wait_for_event): Correct comment typos.
21448 (linux_resume_one_process): Call check_removed_breakpoint.
21449 (linux_send_signal): New function.
21450 (linux_target_ops): Add linux_send_signal.
21451 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21453 * target.h (struct target_ops): Add send_signal.
21455 2003-05-29 Jim Blandy <jimb@redhat.com>
21457 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21458 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21459 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21460 away part of the register's value.
21462 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21464 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21465 (linux_wait_for_event, linux_init_signals): Likewise.
21467 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21469 * configure.in: Check for stdlib.h.
21470 * configure: Regenerated.
21471 * config.in: Regenerated.
21473 2003-01-04 Andreas Schwab <schwab@suse.de>
21475 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21477 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21479 * Makefile.in: Remove obsolete code.
21481 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21483 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21484 defined(PT_FPR0_HI).
21486 2002-11-17 Stuart Hughes <seh@zee2.com>
21488 * linux-arm-low.c (arm_num_regs): Increase.
21489 (arm_regmap): Include status register.
21491 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21493 * linux-low.c (register_addr): Remove incorrect -1 check.
21495 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21497 * linux-low.c (linux_create_inferior): Call setpgid. Return
21499 (unstopped_p, linux_signal_pid): Remove.
21500 (linux_target_ops): Remove linux_signal_pid.
21501 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21502 global instead of target method.
21503 * target.h (struct target_ops): Remove signal_pid. Update comment
21504 for create_inferior.
21505 * server.c (signal_pid): New variable.
21506 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21507 gdbserver. Set the child to be the foreground process group.
21508 (attach_inferior): Set signal_pid.
21510 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21512 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21514 2002-08-20 Jim Blandy <jimb@redhat.com>
21516 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21519 2002-08-01 Andrew Cagney <cagney@redhat.com>
21521 * Makefile.in: Make chill references obsolete.
21523 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21525 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21526 * configure: Regenerate.
21527 * config.in: Regenerate.
21529 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21531 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21532 (perror_with_name, remote_close, remote_open, expect, play): Static.
21534 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21536 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
21537 byte offsets instead of an array of indexes.
21538 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21540 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
21542 * regcache.c: Add comment.
21544 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
21546 * thread-db.c: New file.
21547 * proc-service.c: New file.
21548 * acinclude.m4: New file.
21549 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21550 proc-service.o, and thread-db.o.
21551 (linux-low.o): Add USE_THREAD_DB.
21552 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21553 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21554 * aclocal.m4: Regenerated.
21555 * config.in: Regenerated.
21556 * configure: Regenerated.
21557 * configure.in: Check for proc_service.h, sys/procfs.h,
21558 thread_db.h, and linux/elf.h headrs.
21559 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21560 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21561 Check for -lthread_db and thread support.
21562 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21563 PowerPC, and SuperH.
21564 * i387-fp.c: Constify arguments.
21565 * i387-fp.h: Likewise.
21566 * inferiors.c: (struct thread_info): Renamed from
21567 `struct inferior_info'. Remove PID member. Use generic inferior
21568 list header. All uses updated.
21569 (inferiors, signal_pid): Removed.
21570 (all_threads): New variable.
21571 (get_thread): Define.
21572 (add_inferior_to_list): New function.
21573 (for_each_inferior): New function.
21574 (change_inferior_id): New function.
21575 (add_inferior): Removed.
21576 (remove_inferior): New function.
21577 (add_thread): New function.
21578 (free_one_thread): New function.
21579 (remove_thread): New function.
21580 (clear_inferiors): Use for_each_inferior and free_one_thread.
21581 (find_inferior): New function.
21582 (find_inferior_id): New function.
21583 (inferior_target_data): Update argument type.
21584 (set_inferior_target_data): Likewise.
21585 (inferior_regcache_data): Likewise.
21586 (set_inferior_regcache_data): Likewise.
21587 * linux-low.c (linux_bp_reinsert): Remove.
21588 (all_processes, stopping_threads, using_thrads)
21589 (struct pending_signals, debug_threads, pid_of): New.
21590 (inferior_pid): Replace with macro.
21591 (struct inferior_linux_data): Remove.
21592 (get_stop_pc, add_process): New functions.
21593 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21594 Use add_process and add_thread.
21595 (linux_attach_lwp): New function, based on old linux_attach. Use
21596 add_process and add_thread. Set stop_expected for new threads.
21597 (linux_attach): New function.
21598 (linux_kill_one_process): New function.
21599 (linux_kill): Kill all LWPs.
21600 (linux_thread_alive): Use find_inferior_id.
21601 (check_removed_breakpoints, status_pending_p): New functions.
21602 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21603 Update. Use WNOHANG. Wait for cloned processes also. Update process
21604 struct for the found process.
21605 (linux_wait_for_event): New function.
21606 (linux_wait): Use it. Support LWPs.
21607 (send_sigstop, wait_for_sigstop, stop_all_processes)
21608 (linux_resume_one_process, linux_continue_one_process): New functions.
21609 (linux_resume): Support LWPs.
21610 (REGISTER_RAW_SIZE): Remove.
21611 (fetch_register): Use register_size instead. Call supply_register.
21612 (usr_store_inferior_registers): Likewise. Call collect_register.
21613 Fix recursive case.
21614 (regsets_fetch_inferior_registers): Improve error message.
21615 (regsets_store_inferior_registers): Add debugging.
21616 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21617 (unstopped_p, linux_signal_pid): New functions.
21618 (linux_target_ops): Add linux_signal_pid.
21619 (linux_init_signals): New function.
21620 (initialize_low): Call it. Initialize using_threads.
21621 * regcache.c (inferior_regcache_data): Add valid
21623 (get_regcache): Fetch registers lazily. Add fetch argument
21624 and update all callers.
21625 (regcache_invalidate_one, regcache_invalidate): New
21627 (new_register_cache): Renamed from create_register_cache.
21628 Return the new regcache.
21629 (free_register_cache): Change argument to a void *.
21630 (registers_to_string, registers_from_string): Call get_regcache
21631 with fetch flag set.
21632 (register_data): Make static. Pass fetch flag to get_regcache.
21633 (supply_register): Call get_regcache with fetch flag clear.
21634 (collect_register): Call get_regcache with fetch flag set.
21635 (collect_register_as_string): New function.
21636 * regcache.h: Update.
21637 * remote-utils.c (putpkt): Flush after debug output and use
21639 Handle input interrupts while waiting for an ACK.
21640 (input_interrupt): Use signal_pid method.
21641 (getpkt): Flush after debug output and use stderr.
21642 (outreg): Use collect_register_as_string.
21643 (new_thread_notify, dead_thread_notify): New functions.
21644 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21645 and general_thread.
21646 (look_up_one_symbol): Flush after debug output.
21647 * server.c (step_thread, server_waiting): New variables.
21648 (start_inferior): Don't use signal_pid. Update call to mywait.
21649 (attach_inferior): Update call to mywait.
21650 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21651 (main): Don't fetch/store registers explicitly. Use
21652 set_desired_inferior. Support proposed ``Hs'' packet. Update
21654 * server.h: Update.
21655 (struct inferior_list, struct_inferior_list_entry): New.
21656 * target.c (set_desired_inferior): New.
21657 (write_inferior_memory): Constify.
21658 (mywait): New function.
21659 * target.h: Update.
21660 (struct target_ops): New signal_pid method.
21661 (mywait): Removed macro, added prototype.
21663 * linux-low.h (regset_func): Removed.
21664 (regset_fill_func, regset_store_func): New.
21665 (enum regset_type): New.
21666 (struct regset_info): Add type field. Use new operation types.
21667 (struct linux_target_ops): stop_pc renamed to get_pc.
21668 Add decr_pc_after_break and breakpoint_at.
21669 (get_process, get_thread_proess, get_process_thread)
21670 (strut process_info, all_processes, linux_attach_lwp)
21671 (thread_db_init): New.
21673 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21674 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21675 (the_low_target): Add new members.
21676 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21677 (i386_store_fpxregset): Constify.
21678 (target_regsets): Add new kind identifier.
21679 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21680 (i386_set_pc): Add debugging.
21681 (i386_breakpoint_at): New function.
21682 (the_low_target): Add new members.
21683 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21684 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21685 (mips_breakpoint_at): New.
21686 (the_low_target): Add new members.
21687 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21688 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21689 (the_low_target): Add new members.
21690 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21691 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21692 (the_low_target): Add new members.
21693 * linux-x86-64-low.c (target_regsets): Add new kind
21696 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
21698 From Martin Pool <mbp@samba.org>:
21699 * server.c (gdbserver_usage): New function.
21702 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
21704 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21705 stop_at -> stop_pc.
21707 2002-05-04 Andrew Cagney <ac131313@redhat.com>
21709 * Makefile.in: Remove obsolete code.
21711 2002-04-24 Michal Ludvig <mludvig@suse.cz>
21713 * linux-low.c (regsets_fetch_inferior_registers),
21714 (regsets_store_inferior_registers): Removed cast to int from
21716 * regcache.h: Added declaration of struct inferior_info.
21718 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21720 * inferiors.c (struct inferior_info): Add regcache_data.
21721 (add_inferior): Call create_register_cache.
21722 (clear_inferiors): Call free_register_cache.
21723 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21724 * regcache.c (struct inferior_regcache_data): New.
21725 (registers): Remove.
21726 (get_regcache): New function.
21727 (create_register_cache, free_register_cache): New functions.
21728 (set_register_cache): Don't initialize the register cache here.
21729 (registers_to_string, registers_from_string, register_data): Call
21731 * regcache.h: Add prototypes.
21732 * server.h: Likewise.
21734 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21736 * mem-break.c: New file.
21737 * mem-break.h: New file.
21738 * Makefile.in: Add mem-break.o rule; update server.h
21740 * inferiors.c (struct inferior_info): Add target_data
21742 (clear_inferiors): Free target_data member if set.
21743 (inferior_target_data, set_inferior_target_data): New functions.
21744 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21745 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21746 * linux-low.c (linux_bp_reinsert): New variable.
21747 (struct inferior_linux_data): New.
21748 (linux_create_inferior): Use set_inferior_target_data.
21749 (linux_attach): Likewise. Call add_inferior.
21750 (linux_wait_for_one_inferior): New function.
21751 (linux_wait): Call it.
21752 (linux_write_memory): Add const.
21753 (initialize_low): Call set_breakpoint_data.
21754 * linux-low.h (struct linux_target_ops): Add breakpoint
21756 * server.c (attach_inferior): Remove extra add_inferior
21758 * server.h: Include mem-break.h. Update inferior.c
21760 * target.c (read_inferior_memory)
21761 (write_inferior_memory): New functions.
21762 * target.h (read_inferior_memory)
21763 (write_inferior_memory): Change macros to prototypes.
21764 (struct target_ops): Update comments. Add const to write_memory
21767 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
21769 * linux-low.c (usr_store_inferior_registers): Support
21770 registers which are allowed to fail to store.
21771 * linux-low.h (linux_target_ops): Likewise.
21772 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21773 (ppc_cannot_store_register): FPSCR may not be storable.
21775 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21777 * server.h: Include <string.h> if HAVE_STRING_H.
21778 * ChangeLog: Correct paths in last ChangeLog entry.
21780 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21782 * linux-low.h: Remove obsolete prototypes.
21783 (struct linux_target_ops): New.
21784 (extern the_low_target): New.
21785 * linux-low.c (num_regs, regmap): Remove declarations.
21786 (register_addr): Use the_low_target explicitly.
21787 (fetch_register): Likewise.
21788 (usr_fetch_inferior_registers): Likewise.
21789 (usr_store_inferior_registers): Likewise.
21790 * linux-arm-low.c (num_regs): Remove.
21791 (arm_num_regs): Define.
21792 (arm_regmap): Renamed from regmap, made static.
21793 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21795 (arm_cannot_store_register): Renamed from cannot_store_register,
21797 (the_low_target): New.
21798 * linux-i386-low.c (num_regs): Remove.
21799 (i386_num_regs): Define.
21800 (i386_regmap): Renamed from regmap, made static.
21801 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21803 (i386_cannot_store_register): Renamed from cannot_store_register,
21805 (the_low_target): New.
21806 * linux-ia64-low.c (num_regs): Remove.
21807 (ia64_num_regs): Define.
21808 (ia64_regmap): Renamed from regmap, made static.
21809 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21811 (ia64_cannot_store_register): Renamed from cannot_store_register,
21813 (the_low_target): New.
21814 * linux-m68k-low.c (num_regs): Remove.
21815 (m68k_num_regs): Define.
21816 (m68k_regmap): Renamed from regmap, made static.
21817 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21819 (m68k_cannot_store_register): Renamed from cannot_store_register,
21821 (the_low_target): New.
21822 * linux-mips-low.c (num_regs): Remove.
21823 (mips_num_regs): Define.
21824 (mips_regmap): Renamed from regmap, made static.
21825 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21827 (mips_cannot_store_register): Renamed from cannot_store_register,
21829 (the_low_target): New.
21830 * linux-ppc-low.c (num_regs): Remove.
21831 (ppc_num_regs): Define.
21832 (ppc_regmap): Renamed from regmap, made static.
21833 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21835 (ppc_cannot_store_register): Renamed from cannot_store_register,
21837 (the_low_target): New.
21838 * linux-s390-low.c (num_regs): Remove.
21839 (s390_num_regs): Define.
21840 (s390_regmap): Renamed from regmap, made static.
21841 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21843 (s390_cannot_store_register): Renamed from cannot_store_register,
21845 (the_low_target): New.
21846 * linux-sh-low.c (num_regs): Remove.
21847 (sh_num_regs): Define.
21848 (sh_regmap): Renamed from regmap, made static.
21849 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21851 (sh_cannot_store_register): Renamed from cannot_store_register,
21853 (the_low_target): New.
21854 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21855 (the_low_target): New.
21857 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21859 * Makefile.in: Add stamp-h target.
21860 * configure.in: Create stamp-h.
21861 * configure: Regenerated.
21863 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21865 * inferiors.c: New file.
21866 * target.c: New file.
21867 * target.h: New file.
21868 * Makefile.in: Add target.o and inferiors.o. Update
21870 * linux-low.c (inferior_pid): New static variable,
21871 moved from server.c.
21872 (linux_create_inferior): Renamed from create_inferior.
21873 Call add_inferior. Return 0 on success instead of a PID.
21874 (linux_attach): Renamed from myattach.
21875 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21876 (linux_thread_alive): Renamed from mythread_alive.
21877 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21879 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21880 (regsets_store_inferior_registers): Correct error message.
21881 Add missing ``return 0''.
21882 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21883 (linux_store_registers): Renamed from store_inferior_registers.
21884 (linux_read_memory): Renamed from read_inferior_memory.
21885 (linux_write_memory): Renamed from write_inferior_memory.
21886 (linux_target_ops): New structure.
21887 (initialize_low): Call set_target_ops ().
21888 * remote-utils.c (unhexify): New function.
21889 (hexify): New function.
21890 (input_interrupt): Send signals to ``signal_pid''.
21891 * server.c (inferior_pid): Remove.
21892 (start_inferior): Update create_inferior call.
21893 (attach_inferior): Call add_inferior.
21894 (handle_query): New function.
21895 (main): Call handle_query for `q' packets.
21896 * server.h: Include "target.h". Remove obsolete prototypes.
21897 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21899 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21901 * Makefile.in: Add WARN_CFLAGS. Update configury
21903 * configure.in: Check for <string.h>
21904 * configure: Regenerate.
21905 * config.in: Regenerate.
21906 * gdbreplay.c: Include needed system headers.
21907 (remote_open): Remove strchr prototype.
21908 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21909 * regcache.c (supply_register): Change buf argument to const void *.
21910 (supply_register_by_name): Likewise.
21911 (collect_register): Change buf argument to void *.
21912 (collect_register_by_name): Likewise.
21913 * regcache.h: Add missing prototypes.
21914 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21915 * server.c (handle_query): New function.
21916 (attached): New static variable, moved out of main.
21917 (main): Quiet longjmp clobber warnings.
21918 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21919 * utils.c (error): Remove NORETURN.