1 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn the 'get_syscall_trapinfo' linux target op into a method
4 of process_stratum_target.
6 * linux-low.h (struct linux_target_ops): Remove the op.
7 (class linux_process_target) <get_syscall_trapinfo>
8 <gdb_catch_this_syscall>
9 <low_supports_catch_syscall>
10 <low_get_syscall_trapinfo>: Declare.
11 * linux-low.cc (get_syscall_trapinfo): Turn into...
12 (linux_process_target::get_syscall_trapinfo): ...this.
13 (linux_process_target::low_get_syscall_trapinfo): Define.
14 (gdb_catch_this_syscall_p): Turn into...
15 (linux_process_target::gdb_catch_this_syscall): ...this.
16 (linux_process_target::low_supports_catch_syscall): Define.
18 Update the callers below.
20 (linux_process_target::wait_1)
21 (linux_process_target::supports_catch_syscall)
23 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
24 <low_get_syscall_trapinfo>: Declare.
25 (x86_target::low_supports_catch_syscall): Define.
26 (x86_get_syscall_trapinfo): Turn into...
27 (x86_target::low_get_syscall_trapinfo): ...this.
28 (the_low_target): Remove the op field.
29 * linux-aarch64-low.cc (class aarch64_target)
30 <low_supports_catch_syscall>
31 <low_get_syscall_trapinfo>: Declare.
32 (aarch64_target::low_supports_catch_syscall): Define.
33 (aarch64_get_syscall_trapinfo): Turn into...
34 (aarch64_target::low_get_syscall_trapinfo): ...this.
35 (the_low_target): Remove the op field.
36 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
37 <low_get_syscall_trapinfo>: Declare.
38 (arm_target::low_supports_catch_syscall): Define.
39 (arm_get_syscall_trapinfo): Turn into...
40 (arm_target::low_get_syscall_trapinfo): ...this.
41 (the_low_target): Remove the op field.
42 * linux-ppc-low.cc (the_low_target): Remove the op field.
43 * linux-s390-low.cc (the_low_target): Remove the op field.
45 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
47 Remove the 'supports_hardware_single_step' linux target op and
48 override the process_stratum_target's op definition in
49 linux_process_target to return true.
51 * linux-low.h (struct linux_target_ops): Remove the op.
52 (class linux_process_target) <finish_step_over>
53 <maybe_hw_step>: Declare.
54 * linux-low.cc (can_hardware_single_step): Remove.
55 (maybe_hw_step): Turn into...
56 (linux_process_target::maybe_hw_step): ...this.
57 (finish_step_over): Turn into...
58 (linux_process_target::finish_step_over): ...this.
59 (linux_process_target::supports_hardware_single_step): Update
62 Update the callers below.
64 (linux_process_target::single_step)
65 (linux_process_target::resume_one_lwp_throw)
67 * linux-arm-low.cc (class arm_target)
68 <supports_hardware_single_step>: Declare.
69 (arm_supports_hardware_single_step): Turn into...
70 (arm_target::supports_hardware_single_step): ...this.
71 (the_low_target): Remove the op field.
72 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
73 (the_low_target): Remove the op field.
74 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
76 (the_low_target): Remove the op field.
77 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
78 (the_low_target): Remove the op field.
79 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
80 (the_low_target): Remove the op field.
81 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
82 (the_low_target): Remove the op field.
83 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
84 (the_low_target): Remove the op field.
85 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
86 (the_low_target): Remove the op field.
87 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
88 (the_low_target): Remove the op field.
89 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
90 (the_low_target): Remove the op field.
91 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
92 (the_low_target): Remove the op field.
93 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
94 (the_low_target): Remove the op field.
95 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
97 (the_low_target): Remove the op field.
99 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
101 Turn the 'supports_range_stepping' linux target op into a method
102 of linux_process_target.
104 * linux-low.h (struct linux_target_ops): Remove the op.
105 (class linux_process_target) <low_supports_range_stepping>: Declare.
106 * linux-low.cc (linux_process_target::low_supports_range_stepping):
108 (linux_process_target::supports_range_stepping): Update the call
110 * linux-x86-low.cc (class x86_target)
111 <low_supports_range_stepping>: Declare.
112 (x86_supports_range_stepping): Turn into...
113 (x86_target::low_supports_range_stepping): ...this.
114 (the_low_target): Remove the op field.
115 * linux-aarch64-low.cc (class aarch64_target)
116 <low_supports_range_stepping>: Declare.
117 (aarch64_supports_range_stepping): Turn into...
118 (aarch64_target::low_supports_range_stepping): ...this.
119 (the_low_target): Remove the op field.
120 * linux-arm-low.cc (the_low_target): Remove the op field.
121 * linux-bfin-low.cc (the_low_target): Ditto.
122 * linux-crisv32-low.cc (the_low_target): Ditto.
123 * linux-m32r-low.cc (the_low_target): Ditto.
124 * linux-m68k-low.cc (the_low_target): Ditto.
125 * linux-ppc-low.cc (the_low_target): Ditto.
126 * linux-s390-low.cc (the_low_target): Ditto.
127 * linux-sh-low.cc (the_low_target): Ditto.
128 * linux-tic6x-low.cc (the_low_target): Ditto.
129 * linux-tile-low.cc (the_low_target): Ditto.
130 * linux-xtensa-low.cc (the_low_target): Ditto.
132 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
134 Remove the 'emit_ops' linux target ops and let the concrete
135 linux target define the op by overriding the declaration of
136 process_stratum_target.
138 * linux-low.h (struct linux_target_ops): Remove the op.
139 (class linux_process_target) <emit_ops>: Remove.
140 * linux-low.cc (linux_process_target::emit_ops): Remove.
141 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
142 (x86_emit_ops): Turn into...
143 (x86_target::emit_ops): ...this.
144 (the_low_target): Remove the op field.
145 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
146 (aarch64_emit_ops): Turn into...
147 (aarch64_target::emit_ops): ...this.
148 (the_low_target): Remove the op field.
149 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
150 (ppc_emit_ops): Turn into...
151 (ppc_target::emit_ops): ...this.
152 (the_low_target): Remove the op field.
153 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
154 (s390_emit_ops): Turn into...
155 (s390_target::emit_ops): ...this.
156 (the_low_target): Remove the op field.
157 * linux-arm-low.cc (the_low_target): Remove the op field.
158 * linux-bfin-low.cc (the_low_target): Ditto.
159 * linux-crisv32-low.cc (the_low_target): Ditto.
160 * linux-m32r-low.cc (the_low_target): Ditto.
161 * linux-m68k-low.cc (the_low_target): Ditto.
162 * linux-sh-low.cc (the_low_target): Ditto.
163 * linux-tic6x-low.cc (the_low_target): Ditto.
164 * linux-tile-low.cc (the_low_target): Ditto.
165 * linux-xtensa-low.cc (the_low_target): Ditto.
167 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
169 Remove the 'install_fast_tracepoint_jump_pad' and
170 'get_min_fast_tracepoint_insn_len' linux target ops to let the
171 concrete linux target define the ops by overriding the declarations
172 of process_stratum_target.
174 * linux-low.h (struct linux_target_ops): Remove the ops.
175 (class linux_process_target) <supports_fast_tracepoints>
176 <install_fast_tracepoint_jump_pad>
177 <get_min_fast_tracepoint_insn_len>: Remove.
178 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
179 (linux_process_target::install_fast_tracepoint_jump_pad)
180 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
181 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
182 <install_fast_tracepoint_jump_pad>
183 <get_min_fast_tracepoint_insn_len>: Declare.
184 (x86_target::supports_fast_tracepoints): Define.
185 (x86_install_fast_tracepoint_jump_pad): Turn into...
186 (x86_target::install_fast_tracepoint_jump_pad): ...this.
187 (x86_get_min_fast_tracepoint_insn_len): Turn into...
188 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
189 (the_low_target): Remove the op fields.
190 * linux-aarch64-low.cc (class aarch64_target)
191 <supports_fast_tracepoints>
192 <install_fast_tracepoint_jump_pad>
193 <get_min_fast_tracepoint_insn_len>: Declare.
194 (aarch64_target::supports_fast_tracepoints): Define.
195 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
196 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
197 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
198 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
199 (the_low_target): Remove the op fields.
200 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
201 <install_fast_tracepoint_jump_pad>
202 <get_min_fast_tracepoint_insn_len>: Declare.
203 (ppc_target::supports_fast_tracepoints): Define.
204 (ppc_install_fast_tracepoint_jump_pad): Turn into...
205 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
206 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
207 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
208 (the_low_target): Remove the op fields.
209 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
210 <install_fast_tracepoint_jump_pad>
211 <get_min_fast_tracepoint_insn_len>: Declare.
212 (s390_target::supports_fast_tracepoints): Define.
213 (s390_install_fast_tracepoint_jump_pad): Turn into...
214 (s390_target::install_fast_tracepoint_jump_pad): ...this.
215 (s390_get_min_fast_tracepoint_insn_len): Turn into...
216 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
217 (the_low_target): Remove the op fields.
218 * linux-arm-low.cc (the_low_target): Remove the op fields.
219 * linux-bfin-low.cc (the_low_target): Ditto.
220 * linux-crisv32-low.cc (the_low_target): Ditto.
221 * linux-m32r-low.cc (the_low_target): Ditto.
222 * linux-m68k-low.cc (the_low_target): Ditto.
223 * linux-sh-low.cc (the_low_target): Ditto.
224 * linux-tic6x-low.cc (the_low_target): Ditto.
225 * linux-tile-low.cc (the_low_target): Ditto.
226 * linux-xtensa-low.cc (the_low_target): Ditto.
228 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
230 Turn the 'get_thread_area' linux target op into a method of
231 process_stratum_target.
233 * linux-low.h (struct linux_target_ops): Remove the op.
234 (class linux_process_target) <stuck_in_jump_pad>
235 <linux_fast_tracepoint_collecting>
236 <low_get_thread_area>: Declare.
237 * linux-low.cc (supports_fast_tracepoints): Remove.
238 (linux_fast_tracepoint_collecting): Turn into...
239 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
240 (linux_process_target::low_get_thread_area): Define.
241 (stuck_in_jump_pad_callback): Turn into...
242 (linux_process_target::stuck_in_jump_pad): ...this.
244 Update the caller below.
246 (linux_process_target::stabilize_threads)
248 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
250 (x86_get_thread_area): Turn into...
251 (x86_target::low_get_thread_area): ...this.
252 (the_low_target): Remove the op field.
253 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
255 (aarch64_get_thread_area): Turn into...
256 (aarch64_target::low_get_thread_area): ...this.
257 (the_low_target): Remove the op field.
258 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
260 (ppc_get_thread_area): Turn into...
261 (ppc_target::low_get_thread_area): ...this.
262 (the_low_target): Remove the op field.
263 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
265 (s390_get_thread_area): Turn into...
266 (s390_target::low_get_thread_area): ...this.
267 (the_low_target): Remove the op field.
268 * linux-arm-low.cc (the_low_target): Remove the op field.
269 * linux-bfin-low.cc (the_low_target): Ditto.
270 * linux-crisv32-low.cc (the_low_target): Ditto.
271 * linux-m32r-low.cc (the_low_target): Ditto.
272 * linux-m68k-low.cc (the_low_target): Ditto.
273 * linux-sh-low.cc (the_low_target): Ditto.
274 * linux-tic6x-low.cc (the_low_target): Ditto.
275 * linux-tile-low.cc (the_low_target): Ditto.
276 * linux-xtensa-low.cc (the_low_target): Ditto.
278 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
280 Remote the 'supports_tracepoints' linux target op and let the
281 concrete linux target define it by overriding the op declared in
282 process_stratum_target.
284 * linux-low.h (struct linux_target_ops): Remove the op.
285 (class linux_process_target) <supports_tracepoints>: Remove.
286 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
287 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
289 (x86_supports_tracepoints): Turn into...
290 (x86_target::supports_tracepoints): ...this.
291 (the_low_target): Remove the op field.
292 * linux-aarch64-low.cc (class aarch64_target)
293 <supports_tracepoints>: Declare.
294 (aarch64_supports_tracepoints): Turn into...
295 (aarch64_target::supports_tracepoints): ...this.
296 (the_low_target): Remove the op field.
297 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
299 (ppc_supports_tracepoints): Turn into...
300 (ppc_target::supports_tracepoints): ...this.
301 (the_low_target): Remove the op field.
302 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
304 (s390_supports_tracepoints): Turn into...
305 (s390_target::supports_tracepoints): ...this.
306 (the_low_target): Remove the op field.
307 * linux-arm-low.cc (the_low_target): Remove the op field.
308 * linux-bfin-low.cc (the_low_target): Ditto.
309 * linux-crisv32-low.cc (the_low_target): Ditto.
310 * linux-m32r-low.cc (the_low_target): Ditto.
311 * linux-m68k-low.cc (the_low_target): Ditto.
312 * linux-sh-low.cc (the_low_target): Ditto.
313 * linux-tic6x-low.cc (the_low_target): Ditto.
314 * linux-tile-low.cc (the_low_target): Ditto.
315 * linux-xtensa-low.cc (the_low_target): Ditto.
317 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
319 Remove the 'process_qsupported' linux target op and let a concrete
320 linux target define the op by overriding the op declaration in
321 process_stratum_target.
323 * linux-low.h (struct linux_target_ops): Remove the op.
324 (class linux_process_target) <process_qsupported>: Remove.
325 * linux-low.cc (linux_process_target::process_qsupported): Remove.
326 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
327 (x86_linux_process_qsupported): Turn into...
328 (x86_target::process_qsupported): ...this.
329 (the_low_target): Remove the op field.
330 * linux-aarch64-low.cc (the_low_target): Remove the op
332 * linux-arm-low.cc (the_low_target): Ditto.
333 * linux-bfin-low.cc (the_low_target): Ditto.
334 * linux-crisv32-low.cc (the_low_target): Ditto.
335 * linux-m32r-low.cc (the_low_target): Ditto.
336 * linux-m68k-low.cc (the_low_target): Ditto.
337 * linux-ppc-low.cc (the_low_target): Ditto.
338 * linux-s390-low.cc (the_low_target): Ditto.
339 * linux-sh-low.cc (the_low_target): Ditto.
340 * linux-tic6x-low.cc (the_low_target): Ditto.
341 * linux-tile-low.cc (the_low_target): Ditto.
342 * linux-xtensa-low.cc (the_low_target): Ditto.
344 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
346 Turn the 'prepare_to_resume' linux target op into a method of
347 linux_process_target.
349 * linux-low.h (struct linux_target_ops): Remove the op.
350 (class linux_process_target) <low_prepare_to_resume>: Declare.
351 * linux-low.cc (linux_process_target::low_prepare_to_resume):
354 Update the callers below:
356 (linux_process_target::resume_one_lwp_throw)
357 (linux_process_target::low_prepare_to_resume)
359 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
361 (x86_target::low_prepare_to_resume): Define.
362 (the_low_target): Remove the op field.
363 * linux-aarch64-low.cc (class aarch64_target)
364 <low_prepare_to_resume>: Declare.
365 (aarch64_target::low_prepare_to_resume): Define.
366 (the_low_target): Remove the op field.
367 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
369 (arm_prepare_to_resume): Turn into...
370 (arm_target::low_prepare_to_resume): ...this.
371 (the_low_target): Remove the op field.
372 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
374 (mips_linux_prepare_to_resume): Turn into...
375 (mips_target::low_prepare_to_resume): ...this.
376 (the_low_target): Remove the op field.
377 * linux-bfin-low.cc (the_low_target): Remove the op field.
378 * linux-crisv32-low.cc (the_low_target): Ditto.
379 * linux-m32r-low.cc (the_low_target): Ditto.
380 * linux-m68k-low.cc (the_low_target): Ditto.
381 * linux-ppc-low.cc (the_low_target): Ditto.
382 * linux-s390-low.cc (the_low_target): Ditto.
383 * linux-sh-low.cc (the_low_target): Ditto.
384 * linux-tic6x-low.cc (the_low_target): Ditto.
385 * linux-tile-low.cc (the_low_target): Ditto.
386 * linux-xtensa-low.cc (the_low_target): Ditto.
388 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
390 Turn the 'new_process', 'delete_process', 'new_thread',
391 'delete_thread', and 'new_fork' linux target ops into methods
392 of linux_process_target.
394 * linux-low.h (struct linux_target_ops): Remove the ops.
395 (class linux_process_target) <add_linux_process>
400 <check_zombie_leaders>
406 <low_new_fork>: Declare.
407 * linux-low.cc (delete_lwp): Turn into...
408 (linux_process_target::delete_lwp): ...this.
409 (linux_process_target::low_delete_thread): Define.
410 (linux_add_process): Turn into...
411 (linux_process_target::add_linux_process): ...this.
412 (linux_process_target::low_new_process): Define.
413 (linux_process_target::low_delete_process): Define.
414 (linux_process_target::low_new_fork): Define.
415 (add_lwp): Turn into...
416 (linux_process_target::add_lwp): ...this.
417 (linux_process_target::low_new_thread): Define.
418 (linux_attach_lwp): Turn into...
419 (linux_process_target::attach_lwp): ...this.
420 (linux_detach_one_lwp): Turn into...
421 (linux_process_target::detach_one_lwp): ...this.
422 (linux_detach_lwp_callback): Remove and inline...
423 (linux_process_target::detach): ...here.
424 (check_zombie_leaders): Turn into...
425 (linux_process_target::check_zombie_leaders): ...this.
426 (filter_exit_event): Turn into...
427 (linux_process_target::filter_exit_event): ...this.
429 Update the callers below.
431 (linux_process_target::handle_extended_wait)
432 (linux_process_target::create_inferior)
433 (attach_proc_task_lwp_callback)
434 (linux_process_target::attach)
435 (linux_process_target::detach)
436 (linux_process_target::mourn)
437 * thread-db.cc (attach_thread)
439 * linux-x86-low.cc (class x86_target) <low_new_process>
443 <low_new_fork>: Declare.
444 (x86_linux_new_process): Turn into...
445 (x86_target::low_new_process): ...this.
446 (x86_linux_delete_process): Turn into...
447 (x86_target::low_delete_process): ...this.
448 (x86_target::low_new_thread): Define.
449 (x86_target::low_delete_thread): Define.
450 (x86_linux_new_fork): Turn into...
451 (x86_target::low_new_fork): ...this.
452 (the_low_target): Remove the op fields.
453 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
457 <low_new_fork>: Declare.
458 (aarch64_linux_new_process): Turn into...
459 (aarch64_target::low_new_process): ...this.
460 (aarch64_linux_delete_process): Turn into...
461 (aarch64_target::low_delete_process): ...this.
462 (aarch64_target::low_new_thread): Define.
463 (aarch64_target::low_delete_thread): Define.
464 (aarch64_linux_new_fork): Turn into...
465 (aarch64_target::low_new_fork): ...this.
466 (the_low_target): Remove the op fields.
467 * linux-arm-low.cc (class arm_target) <low_new_process>
471 <low_new_fork>: Declare.
472 (arm_new_process): Turn into...
473 (arm_target::low_new_process): ...this.
474 (arm_delete_process): Turn into...
475 (arm_target::low_delete_process): ...this.
476 (arm_new_thread): Turn into...
477 (arm_target::low_new_thread): ...this.
478 (arm_delete_thread): Turn into...
479 (arm_target::low_delete_thread): ...this.
480 (arm_new_fork): Turn into...
481 (arm_target::low_new_fork): ...this.
482 (the_low_target): Remove the op fields.
483 * linux-mips-low.cc (class mips_target) <low_new_process>
487 <low_new_fork>: Declare.
488 (mips_linux_new_process): Turn into...
489 (mips_target::low_new_process): ...this.
490 (mips_linux_delete_process): Turn into...
491 (mips_target::low_delete_process): ...this.
492 (mips_linux_new_thread): Turn into...
493 (mips_target::low_new_thread): ...this.
494 (mips_linux_delete_thread): Turn into...
495 (mips_target::low_delete_thread): ...this.
496 (mips_linux_new_fork): Turn into...
497 (mips_target::low_new_fork): ...this.
498 (the_low_target): Remove the op fields.
499 * linux-bfin-low.cc (the_low_target): Remove the op fields.
500 * linux-crisv32-low.cc (the_low_target): Ditto.
501 * linux-m32r-low.cc (the_low_target): Ditto.
502 * linux-m68k-low.cc (the_low_target): Ditto.
503 * linux-ppc-low.cc (the_low_target): Ditto.
504 * linux-s390-low.cc (the_low_target): Ditto.
505 * linux-sh-low.cc (the_low_target): Ditto.
506 * linux-tic6x-low.cc (the_low_target): Ditto.
507 * linux-tile-low.cc (the_low_target): Ditto.
508 * linux-xtensa-low.cc (the_low_target): Ditto.
510 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
512 Turn the 'siginfo_fixup' linux target op into a method of
513 linux_process_target.
515 * linux-low.h (struct linux_target_ops): Remove the op.
516 (class linux_process_target) <siginfo_fixup>
517 <low_siginfo_fixup>: Declare.
518 * linux-low.cc (siginfo_fixup): Turn into...
519 (linux_process_target::siginfo_fixup): ...this.
520 (linux_process_target::low_siginfo_fixup): Define.
521 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
522 (x86_siginfo_fixup): Turn into...
523 (x86_target::low_siginfo_fixup): ...this.
524 (the_low_target): Remove the op field.
525 * linux-aarch64-low.cc (class aarch64_target):
526 <low_siginfo_fixup>: Declare.
527 (aarch64_linux_siginfo_fixup): Turn into...
528 (aarch64_target::low_siginfo_fixup): ...this.
529 (the_low_target): Remove the op field.
530 * linux-arm-low.cc (the_low_target): Remove the op field.
531 * linux-bfin-low.cc (the_low_target): Ditto.
532 * linux-crisv32-low.cc (the_low_target): Ditto.
533 * linux-m32r-low.cc (the_low_target): Ditto.
534 * linux-m68k-low.cc (the_low_target): Ditto.
535 * linux-mips-low.cc (the_low_target): Ditto.
536 * linux-ppc-low.cc (the_low_target): Ditto.
537 * linux-s390-low.cc (the_low_target): Ditto.
538 * linux-sh-low.cc (the_low_target): Ditto.
539 * linux-tic6x-low.cc (the_low_target): Ditto.
540 * linux-tile-low.cc (the_low_target): Ditto.
541 * linux-xtensa-low.cc (the_low_target): Ditto.
543 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
545 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
546 linux target ops into methods of linux_process_target.
548 * linux-low.h (struct linux_target_ops): Remove the ops.
549 (class linux_process_target) <low_collect_ptrace_register>
550 <low_store_ptrace_register>: Declare.
551 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
552 (linux_process_target::low_supply_ptrace_register): Define.
554 Update the callers below.
556 (linux_process_target::fetch_register)
557 (linux_process_target::store_register)
559 * linux-x86-low.cc (the_low_target): Remove the op fields.
560 * linux-aarch64-low.cc (the_low_target): Ditto.
561 * linux-arm-low.cc (the_low_target): Ditto.
562 * linux-bfin-low.cc (the_low_target): Ditto.
563 * linux-crisv32-low.cc (the_low_target): Ditto.
564 * linux-m32r-low.cc (the_low_target): Ditto.
565 * linux-m68k-low.cc (the_low_target): Ditto.
566 * linux-sh-low.cc (the_low_target): Ditto.
567 * linux-sparc-low.cc (the_low_target): Ditto.
568 * linux-tic6x-low.cc (the_low_target): Ditto.
569 * linux-tile-low.cc (the_low_target): Ditto.
570 * linux-xtensa-low.cc (the_low_target): Ditto.
571 * linux-mips-low.cc (class mips_target)
572 <low_collect_ptrace_register>
573 <low_supply_ptrace_register>: Declare.
574 (mips_collect_ptrace_register): Turn into ...
575 (mips_target::low_collect_ptrace_register): ...this.
576 (mips_supply_ptrace_register): Turn into...
577 (mips_target::low_supply_ptrace_register): ...this.
578 (the_low_target): Remove the op fields.
579 * linux-ppc-low.cc (class ppc_target)
580 <low_collect_ptrace_register>
581 <low_supply_ptrace_register>: Declare.
582 (ppc_collect_ptrace_register): Turn into ...
583 (ppc_target::low_collect_ptrace_register): ...this.
584 (ppc_supply_ptrace_register): Turn into ...
585 (ppc_target::low_supply_ptrace_register): ...this.
586 (ppc_fill_gregset): Update for the calls to
587 low_collect_ptrace_register.
588 (the_low_target): Remove the op fields.
589 * linux-s390-low.cc (class s390_target)
590 <low_collect_ptrace_register>
591 <low_supply_ptrace_register>: Declare.
592 (s390_collect_ptrace_register): Turn into ...
593 (s390_target::low_collect_ptrace_register): ...this.
594 (s390_supply_ptrace_register): Turn into ...
595 (s390_target::low_supply_ptrace_register): ...this.
596 (s390_fill_gregset): Update for the calls to
597 low_collect_ptrace_register.
598 (the_low_target): Remove the op fields.
600 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
602 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
603 target ops into methods of linux_process_target.
605 * linux-low.h (struct linux_target_ops): Remove the ops.
606 (class linux_process_target) <check_stopped_by_watchpoint>
607 <low_stopped_by_watchpoint>
608 <low_stopped_data_address>: Declare.
609 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
610 (linux_process_target::check_stopped_by_watchpoint): ...this.
611 (linux_process_target::low_stopped_by_watchpoint): Define.
612 (linux_process_target::low_stopped_data_address): Define.
613 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
614 <low_stopped_data_address>: Declare.
615 (x86_stopped_by_watchpoint): Turn into...
616 (x86_target::low_stopped_by_watchpoint): ...this.
617 (x86_stopped_data_address): Turn into...
618 (x86_target::low_stopped_data_address): ...this.
619 (the_low_target): Remove the op fields.
620 * linux-aarch64-low.cc (class aarch64_target)
621 <low_stopped_by_watchpoint>
622 <low_stopped_data_address>: Declare.
623 (aarch64_stopped_by_watchpoint): Turn into...
624 (aarch64_target::low_stopped_by_watchpoint): ...this.
625 (aarch64_stopped_data_address): Turn into...
626 (aarch64_target::low_stopped_data_address): ...this.
627 (the_low_target): Remove the op fields.
628 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
629 <low_stopped_data_address>: Declare.
630 (arm_stopped_by_watchpoint): Turn into...
631 (arm_target::low_stopped_by_watchpoint): ...this.
632 (arm_stopped_data_address): Turn into...
633 (arm_target::low_stopped_data_address): ...this.
634 (the_low_target): Remove the op fields.
635 * linux-crisv32-low.cc (class crisv32_target)
636 <low_stopped_by_watchpoint>
637 <low_stopped_data_address>: Declare.
638 (cris_stopped_by_watchpoint): Turn into...
639 (crisv32_target::low_stopped_by_watchpoint): ...this.
640 (cris_stopped_data_address): Turn into...
641 (crisv32_target::low_stopped_data_address): ...this.
642 (the_low_target): Remove the op fields.
643 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
644 <low_stopped_data_address>: Declare.
645 (mips_stopped_by_watchpoint): Turn into...
646 (mips_target::low_stopped_by_watchpoint): ...this.
647 (mips_stopped_data_address): Turn into...
648 (mips_target::low_stopped_data_address): ...this.
649 (the_low_target): Remove the op fields.
650 * linux-bfin-low.cc (the_low_target): Remove the op fields.
651 * linux-m32r-low.cc (the_low_target): Ditto.
652 * linux-m68k-low.cc (the_low_target): Ditto.
653 * linux-ppc-low.cc (the_low_target): Ditto.
654 * linux-s390-low.cc (the_low_target): Ditto.
655 * linux-sh-low.cc (the_low_target): Ditto.
656 * linux-sparc-low.cc (the_low_target): Ditto.
657 * linux-tic6x-low.cc (the_low_target): Ditto.
658 * linux-tile-low.cc (the_low_target): Ditto.
659 * linux-xtensa-low.cc (the_low_target): Ditto.
661 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
663 Turn the 'insert_point' and 'remove_point' linux target ops into
664 methods of linux_process_target.
666 * linux-low.h (struct linux_target_ops): Remove the ops.
667 (class linux_process_target) <low_insert_point>
668 <low_remove_point>: Declare.
669 * linux-low.cc (linux_process_target::low_insert_point)
670 (linux_process_target::low_remove_point): Define.
671 (linux_process_target::insert_point)
672 (linux_process_target::remove_point): Update for calls to
673 low_insert_point and low_remove_point.
674 * linux-x86-low.cc (class x86_target) <low_insert_point>
675 <low_remove_point>: Declare.
676 (x86_insert_point): Turn into...
677 (x86_target::low_insert_point): ...this.
678 (x86_remove_point): Turn into...
679 (x86_target::low_remove_point): ...this.
680 (the_low_target): Remove the op fields.
681 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
682 <low_remove_point>: Declare.
683 (aarch64_insert_point): Turn into...
684 (aarch64_target::low_insert_point): ...this.
685 (aarch64_remove_point): Turn into...
686 (aarch64_target::low_remove_point): ...this.
687 (the_low_target): Remove the op fields.
688 * linux-arm-low.cc (class arm_target) <low_insert_point>
689 <low_remove_point>: Declare.
690 (arm_insert_point): Turn into...
691 (arm_target::low_insert_point): ...this.
692 (arm_remove_point): Turn into...
693 (arm_target::low_remove_point): ...this.
694 (the_low_target): Remove the op fields.
695 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
696 <low_remove_point>: Declare.
697 (crisv32_insert_point): Turn into...
698 (crisv32_target::low_insert_point): ...this.
699 (crisv32_remove_point): Turn into...
700 (crisv32_target::low_remove_point): ...this.
701 (the_low_target): Remove the op fields.
702 * linux-mips-low.cc (class mips_target) <low_insert_point>
703 <low_remove_point>: Declare.
704 (mips_insert_point): Turn into...
705 (mips_target::low_insert_point): ...this.
706 (mips_remove_point): Turn into...
707 (mips_target::low_remove_point): ...this.
708 (the_low_target): Remove the op fields.
709 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
710 <low_remove_point>: Declare.
711 (ppc_insert_point): Turn into...
712 (ppc_target::low_insert_point): ...this.
713 (ppc_remove_point): Turn into...
714 (ppc_target::low_remove_point): ...this.
715 (the_low_target): Remove the op fields.
716 * linux-bfin-low.cc (the_low_target): Remove the op fields.
717 * linux-m32r-low.cc (the_low_target): Ditto.
718 * linux-m68k-low.cc (the_low_target): Ditto.
719 * linux-s390-low.cc (the_low_target): Ditto.
720 * linux-sh-low.cc (the_low_target): Ditto.
721 * linux-sparc-low.cc (the_low_target): Ditto.
722 * linux-tic6x-low.cc (the_low_target): Ditto.
723 * linux-tile-low.cc (the_low_target): Ditto.
724 * linux-xtensa-low.cc (the_low_target): Ditto.
726 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
728 Remove the 'supports_z_point_type' linux target op and let the
729 concrete linux target define it by overriding the op declared in
730 process_stratum_target.
732 * linux-low.cc (linux_process_target::supports_z_point_type):
734 * linux-low.h (struct linux_target_ops): Remove the op.
735 (class linux_process_target) <supports_z_point_type>: Remove.
736 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
738 (x86_supports_z_point_type): Turn into...
739 (x86_target::supports_z_point_type): ...this.
740 (the_low_target): Remove the op field.
741 * linux-aarch64-low.cc (class aarch64_target)
742 <supports_z_point_type>: Declare.
743 (aarch64_supports_z_point_type): Turn into...
744 (aarch64_target::supports_z_point_type): ...this.
745 (the_low_target): Remove the op field.
746 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
748 (arm_supports_z_point_type): Turn into...
749 (arm_target::supports_z_point_type): ...this.
750 (the_low_target): Remove the op field.
751 * linux-crisv32-low.cc (class crisv32_target)
752 <supports_z_point_type>: Declare.
753 (cris_supports_z_point_type): Turn into...
754 (crisv32_target::supports_z_point_type): ...this.
755 (the_low_target): Remove the op field.
756 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
758 (mips_supports_z_point_type): Turn into...
759 (mips_target::supports_z_point_type): ...this.
760 (the_low_target): Remove the op field.
761 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
763 (ppc_supports_z_point_type): Turn into...
764 (ppc_target::supports_z_point_type): ...this.
765 (the_low_target): Remove the op field.
766 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
768 (s390_supports_z_point_type): Turn into...
769 (s390_target::supports_z_point_type): ...this.
770 (the_low_target): Remove the op field.
771 * linux-bfin-low.cc (the_low_target): Remove the op field.
772 * linux-m32r-low.cc (the_low_target): Ditto.
773 * linux-m68k-low.cc (the_low_target): Ditto.
774 * linux-sh-low.cc (the_low_target): Ditto.
775 * linux-sparc-low.cc (the_low_target): Ditto.
776 * linux-tic6x-low.cc (the_low_target): Ditto.
777 * linux-tile-low.cc (the_low_target): Ditto.
778 * linux-xtensa-low.cc (the_low_target): Ditto.
780 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
782 Turn the 'breakpoint_at' linux target op into a method of
783 linux_process_target.
785 * linux-low.h (struct linux_target_ops): Remove the op.
786 (class linux_process_target) <low_breakpoint_at>: Declare.
788 Update the callers below:
790 * linux-low.cc (linux_process_target::save_stop_reason)
791 (linux_process_target::thread_still_has_status_pending)
792 (linux_process_target::wait_1)
794 * linux-x86-low.cc (class x86_target)
795 <low_breakpoint_at>: Declare.
796 (x86_breakpoint_at): Turn into...
797 (x86_target::low_breakpoint_at): ...this.
798 (the_low_target): Remove the op field.
799 * linux-aarch64-low.cc (class aarch64_target)
800 <low_breakpoint_at>: Declare.
801 (aarch64_breakpoint_at): Turn into...
802 (aarch64_target::low_breakpoint_at): ...this.
803 (the_low_target): Remove the op field.
804 * linux-arm-low.cc (class arm_target)
805 <low_breakpoint_at>: Declare.
806 (arm_target::low_breakpoint_at): Define.
807 (the_low_target): Remove the op field.
808 * linux-bfin-low.cc (class bfin_target)
809 <low_breakpoint_at>: Declare.
810 (bfin_breakpoint_at): Turn into...
811 (bfin_target::low_breakpoint_at): ...this.
812 (the_low_target): Remove the op field.
813 * linux-cris-low.cc (class cris_target)
814 <low_breakpoint_at>: Declare.
815 (cris_breakpoint_at): Turn into...
816 (cris_target::low_breakpoint_at): ...this.
817 (the_low_target): Remove the op field.
818 * linux-crisv32-low.cc (class crisv32_target)
819 <low_breakpoint_at>: Declare.
820 (crisv32_breakpoint_at): Turn into...
821 (crisv32_target::low_breakpoint_at): ...this.
822 (the_low_target): Remove the op field.
823 * linux-ia64-low.cc (class ia64_target)
824 <low_breakpoint_at>: Declare.
825 (ia64_target::low_breakpoint_at): Define.
826 * linux-m32r-low.cc (class m32r_target)
827 <low_breakpoint_at>: Declare.
828 (m32r_breakpoint_at): Turn into...
829 (m32r_target::low_breakpoint_at): ...this.
830 (the_low_target): Remove the op field.
831 * linux-m68k-low.cc (class m68k_target)
832 <low_breakpoint_at>: Declare.
833 (m68k_breakpoint_at): Turn into...
834 (m68k_target::low_breakpoint_at): ...this.
835 (the_low_target): Remove the op field.
836 * linux-mips-low.cc (class mips_target)
837 <low_breakpoint_at>: Declare.
838 (mips_breakpoint_at): Turn into...
839 (mips_target::low_breakpoint_at): ...this.
840 (the_low_target): Remove the op field.
841 * linux-nios2-low.cc (class nios2_target)
842 <low_breakpoint_at>: Declare.
843 (nios2_breakpoint_at): Turn into...
844 (nios2_target::low_breakpoint_at): ...this.
845 (the_low_target): Remove the op field.
846 * linux-ppc-low.cc (class ppc_target)
847 <low_breakpoint_at>: Declare.
848 (ppc_breakpoint_at): Turn into...
849 (ppc_target::low_breakpoint_at): ...this.
850 (the_low_target): Remove the op field.
851 * linux-riscv-low.cc (class riscv_target)
852 <low_breakpoint_at>: Declare.
853 (riscv_breakpoint_at): Turn into...
854 (riscv_target::low_breakpoint_at): ...this.
855 (the_low_target): Remove the op field.
856 * linux-s390-low.cc (class s390_target)
857 <low_breakpoint_at>: Declare.
858 (s390_breakpoint_at): Turn into...
859 (s390_target::low_breakpoint_at): ...this.
860 (the_low_target): Remove the op field.
861 * linux-sh-low.cc (class sh_target)
862 <low_breakpoint_at>: Declare.
863 (sh_breakpoint_at): Turn into...
864 (sh_target::low_breakpoint_at): ...this.
865 (the_low_target): Remove the op field.
866 * linux-sparc-low.cc (class sparc_target)
867 <low_breakpoint_at>: Declare.
868 (sparc_breakpoint_at): Turn into...
869 (sparc_target::low_breakpoint_at): ...this.
870 (the_low_target): Remove the op field.
871 * linux-tic6x-low.cc (class tic6x_target)
872 <low_breakpoint_at>: Declare.
873 (tic6x_breakpoint_at): Turn into...
874 (tic6x_target::low_breakpoint_at): ...this.
875 (the_low_target): Remove the op field.
876 * linux-tile-low.cc (class tile_target)
877 <low_breakpoint_at>: Declare.
878 (tile_breakpoint_at): Turn into...
879 (tile_target::low_breakpoint_at): ...this.
880 (the_low_target): Remove the op field.
881 * linux-xtensa-low.cc (class xtensa_target)
882 <low_breakpoint_at>: Declare.
883 (xtensa_breakpoint_at): Turn into...
884 (xtensa_target::low_breakpoint_at): ...this.
885 (the_low_target): Remove the op field.
887 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
889 Turn the 'decr_pc_after_break' linux_target_ops field into
890 a method of linux_process_target.
892 * linux-low.h (struct linux_target_ops)
893 <decr_pc_after_break>: Remove.
894 (class linux_process_target) <low_decr_pc_after_break>: New method
896 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
897 New method implementation.
899 Update the users below.
901 (linux_process_target::save_stop_reason)
902 (linux_process_target::wait_1)
903 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
905 (x86_target::low_decr_pc_after_break): New method implementation.
906 (the_low_target): Remove the field.
907 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
909 (bfin_target::low_decr_pc_after_break): New method implementation.
910 (the_low_target): Remove the field.
911 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
913 (m68k_target::low_decr_pc_after_break): New method implementation.
914 (the_low_target): Remove the field.
915 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
917 (s390_target::low_decr_pc_after_break): New method implementation.
918 (the_low_target): Remove the field.
919 * linux-aarch64-low.cc (the_low_target): Remove the field.
920 * linux-arm-low.cc (the_low_target): Remove the field.
921 * linux-cris-low.cc (the_low_target): Remove the field.
922 * linux-crisv32-low.cc (the_low_target): Remove the field.
923 * linux-m32r-low.cc (the_low_target): Remove the field.
924 * linux-mips-low.cc (the_low_target): Remove the field.
925 * linux-nios2-low.cc (the_low_target): Remove the field.
926 * linux-ppc-low.cc (the_low_target): Remove the field.
927 * linux-riscv-low.cc (the_low_target): Remove the field.
928 * linux-sh-low.cc (the_low_target): Remove the field.
929 * linux-sparc-low.cc (the_low_target): Remove the field.
930 * linux-tic6x-low.cc (the_low_target): Remove the field.
931 * linux-tile-low.cc (the_low_target): Remove the field.
932 * linux-xtensa-low.cc (the_low_target): Remove the field.
934 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
936 Remove the 'supports_software_single_step' linux target op and let
937 the concrete linux target define it by overriding the op in
938 process_stratum_target.
939 Turn the 'get_next_pcs' linux target op into a method of
940 linux_process_target.
942 * linux-low.h (struct linux_target_ops): Remove the ops.
943 (class linux_process_target) <supports_software_single_step>:
945 <low_get_next_pcs>: Declare.
946 * linux-low.cc (can_software_single_step): Remove.
947 (linux_process_target::low_get_next_pcs): Define.
948 (linux_process_target::supports_software_single_step): Remove.
950 Update the callers below.
952 (linux_process_target::handle_extended_wait)
953 (linux_process_target::wait_1)
954 (linux_process_target::install_software_single_step_breakpoints)
955 (linux_process_target::single_step)
956 (linux_process_target::thread_needs_step_over)
957 (linux_process_target::proceed_one_lwp)
958 (linux_process_target::supports_range_stepping)
960 * linux-x86-low.cc (the_low_target): Remove the op field.
961 * linux-aarch64-low.cc (the_low_target): Ditto.
962 * linux-bfin-low.cc (the_low_target): Ditto.
963 * linux-cris-low.cc (the_low_target): Ditto.
964 * linux-crisv32-low.cc (the_low_target): Ditto.
965 * linux-m32r-low.cc (the_low_target): Ditto.
966 * linux-m68k-low.cc (the_low_target): Ditto.
967 * linux-mips-low.cc (the_low_target): Ditto.
968 * linux-nios2-low.cc (the_low_target): Ditto.
969 * linux-ppc-low.cc (the_low_target): Ditto.
970 * linux-riscv-low.cc (the_low_target): Ditto.
971 * linux-s390-low.cc (the_low_target): Ditto.
972 * linux-sh-low.cc (the_low_target): Ditto.
973 * linux-sparc-low.cc (the_low_target): Ditto.
974 * linux-tic6x-low.cc (the_low_target): Ditto.
975 * linux-tile-low.cc (the_low_target): Ditto.
976 * linux-xtensa-low.cc (the_low_target): Ditto.
977 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
978 <supports_software_single_step>: Declare.
979 (arm_target::supports_software_single_step): Define.
980 (arm_gdbserver_get_next_pcs): Turn into...
981 (arm_target::low_get_next_pcs): ...this.
982 (the_low_target): Remove the op field.
984 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
986 Remove the 'sw_breakpoint_from_kind' linux target op, and let
987 the concrete linux target define it by overriding the op
988 in process_stratum_target.
990 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
992 * linux-low.h (struct linux_target_ops): Remove the op.
993 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
994 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
996 (x86_sw_breakpoint_from_kind): Turn into...
997 (x86_target::sw_breakpoint_from_kind): ...this.
998 (the_low_target): Remove the op field.
999 * linux-aarch64-low.cc (class aarch64_target)
1000 <sw_breakpoint_from_kind>: Declare.
1001 (aarch64_sw_breakpoint_from_kind): Turn into...
1002 (aarch64_target::sw_breakpoint_from_kind): ...this.
1003 (the_low_target): Remove the op field.
1004 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1006 (arm_target::sw_breakpoint_from_kind): Define.
1007 (the_low_target): Remove the op field.
1008 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1010 (bfin_sw_breakpoint_from_kind): Turn into...
1011 (bfin_target::sw_breakpoint_from_kind): ...this.
1012 (the_low_target): Remove the op field.
1013 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1015 (cris_sw_breakpoint_from_kind): Turn into...
1016 (cris_target::sw_breakpoint_from_kind): ...this.
1017 (the_low_target): Remove the op field.
1018 * linux-crisv32-low.cc (class crisv32_target)
1019 <sw_breakpoint_from_kind>: Declare.
1020 (cris_sw_breakpoint_from_kind): Turn into...
1021 (crisv32_target::sw_breakpoint_from_kind): ...this.
1022 (the_low_target): Remove the op field.
1023 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1025 (ia64_target::sw_breakpoint_from_kind): Define.
1026 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1028 (m32r_sw_breakpoint_from_kind): Turn into...
1029 (m32r_target::sw_breakpoint_from_kind): ...this.
1030 (the_low_target): Remove the op field.
1031 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1033 (m68k_sw_breakpoint_from_kind): Turn into...
1034 (m68k_target::sw_breakpoint_from_kind): ...this.
1035 (the_low_target): Remove the op field.
1036 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1038 (mips_sw_breakpoint_from_kind): Turn into...
1039 (mips_target::sw_breakpoint_from_kind): ...this.
1040 (the_low_target): Remove the op field.
1041 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1043 (nios2_sw_breakpoint_from_kind): Turn into...
1044 (nios2_target::sw_breakpoint_from_kind): ...this.
1045 (the_low_target): Remove the op field.
1046 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1048 (ppc_sw_breakpoint_from_kind): Turn into...
1049 (ppc_target::sw_breakpoint_from_kind): ...this.
1050 (the_low_target): Remove the op field.
1051 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1053 (riscv_sw_breakpoint_from_kind): Turn into...
1054 (riscv_target::sw_breakpoint_from_kind): ...this.
1055 (the_low_target): Remove the op field.
1056 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1058 (s390_sw_breakpoint_from_kind): Turn into...
1059 (s390_target::sw_breakpoint_from_kind): ...this.
1060 (the_low_target): Remove the op field.
1061 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1063 (sh_sw_breakpoint_from_kind): Turn into...
1064 (sh_target::sw_breakpoint_from_kind): ...this.
1065 (the_low_target): Remove the op field.
1066 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1068 (sparc_sw_breakpoint_from_kind): Turn into...
1069 (sparc_target::sw_breakpoint_from_kind): ...this.
1070 (the_low_target): Remove the op field.
1071 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1073 (tic6x_sw_breakpoint_from_kind): Turn into...
1074 (tic6x_target::sw_breakpoint_from_kind): ...this.
1075 (the_low_target): Remove the op field.
1076 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1078 (tile_sw_breakpoint_from_kind): Turn into...
1079 (tile_target::sw_breakpoint_from_kind): ...this.
1080 (the_low_target): Remove the op field.
1081 * linux-xtensa-low.cc (class xtensa_target)
1082 <sw_breakpoint_from_kind>: Declare.
1083 (xtensa_sw_breakpoint_from_kind): Turn into...
1084 (xtensa_target::sw_breakpoint_from_kind): ...this.
1085 (the_low_target): Remove the op field.
1087 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1089 Remove the 'breakpoint_kind_from_pc' and
1090 'breakpoint_kind_from_current_state' linux target ops, and let the
1091 concrete linux target define them by overriding the ops of
1092 process_stratum_target.
1094 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1096 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1097 * linux-low.h (struct linux_target_ops): Remove ops.
1098 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1099 <breakpoint_kind_from_current_state>: Remove.
1100 * linux-x86-low.cc (the_low_target): Remove the op fields.
1101 * linux-bfin-low.cc (the_low_target): Ditto.
1102 * linux-cris-low.cc (the_low_target): Ditto.
1103 * linux-crisv32-low.cc (the_low_target): Ditto.
1104 * linux-m32r-low.cc (the_low_target): Ditto.
1105 * linux-m68k-low.cc (the_low_target): Ditto.
1106 * linux-mips-low.cc (the_low_target): Ditto.
1107 * linux-nios2-low.cc (the_low_target): Ditto.
1108 * linux-ppc-low.cc (the_low_target): Ditto.
1109 * linux-s390-low.cc (the_low_target): Ditto.
1110 * linux-sh-low.cc (the_low_target): Ditto.
1111 * linux-sparc-low.cc (the_low_target): Ditto.
1112 * linux-tic6x-low.cc (the_low_target): Ditto.
1113 * linux-tile-low.cc (the_low_target): Ditto.
1114 * linux-xtensa-low.cc (the_low_target): Ditto.
1115 * linux-aarch64-low.cc (class aarch64_target)
1116 <breakpoint_kind_from_pc>
1117 <breakpoint_kind_from_current_state>: Declare.
1118 (aarch64_breakpoint_kind_from_pc): Turn into...
1119 (aarch64_target::breakpoint_kind_from_pc): ...this.
1120 (aarch64_breakpoint_kind_from_current_state): Turn into...
1121 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1122 (the_low_target): Remove the op fields.
1123 * linux-arm-low.cc (class arm_target):
1124 <breakpoint_kind_from_pc>
1125 <breakpoint_kind_from_current_state>: Declare.
1126 (arm_target::breakpoint_kind_from_pc): Define.
1127 (arm_target::breakpoint_kind_from_current_state): Define.
1128 (the_low_target): Remove the op fields.
1129 * linux-riscv-low.cc (class riscv_target):
1130 <breakpoint_kind_from_pc>: Declare.
1131 (riscv_breakpoint_kind_from_pc): Turn into...
1132 (riscv_target::breakpoint_kind_from_pc): ...this.
1133 (the_low_target): Remove the op fields.
1135 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1137 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1138 of linux_process_target.
1140 * linux-low.h (struct linux_target_ops): Remove the ops.
1141 (class linux_process_target) <low_supports_breakpoints>
1143 <low_set_pc>: Declare.
1144 * linux-low.cc (supports_breakpoints): Turn into...
1145 (linux_process_target::low_supports_breakpoints): ...this.
1146 (linux_process_target::low_get_pc): Define.
1147 (linux_process_target::low_set_pc): Define.
1149 Update the callers below.
1151 (linux_process_target::get_pc)
1152 (linux_process_target::save_stop_reason)
1153 (linux_process_target::maybe_move_out_of_jump_pad)
1154 (linux_process_target::wait_1)
1155 (linux_process_target::resume_one_lwp_throw)
1156 (linux_process_target::resume)
1157 (linux_process_target::proceed_all_lwps)
1158 (linux_process_target::read_pc)
1159 (linux_process_target::write_pc)
1161 * linux-x86-low.cc (class linux_process_target)
1162 <low_supports_breakpoints>
1164 <low_set_pc>: Declare.
1165 (x86_target::low_supports_breakpoints): Define.
1166 (x86_get_pc): Turn into...
1167 (x86_target::low_get_pc): ...this.
1168 (x86_set_pc): Turn into...
1169 (x86_target::low_set_pc): ...this.
1170 (the_low_target): Remove the op fields.
1171 * linux-arm-low.cc (class arm_target)
1172 <low_supports_breakpoints>
1174 <low_set_pc>: Declare.
1175 (arm_target::low_supports_breakpoints)
1176 (arm_target::low_get_pc)
1177 (arm_target::low_set_pc): Define.
1178 (the_low_target): Remove the op fields.
1179 * linux-bfin-low.cc (class bfin_target)
1180 <low_supports_breakpoints>
1182 <low_set_pc>: Declare.
1183 (bfin_target::low_supports_breakpoints)
1184 (bfin_target::low_get_pc)
1185 (bfin_target::low_set_pc): Define.
1186 (the_low_target): Remove the op fields.
1187 * linux-cris-low.cc (class cris_target)
1188 <low_supports_breakpoints>
1190 <low_set_pc>: Declare.
1191 (cris_target::low_supports_breakpoints)
1192 (cris_target::low_get_pc)
1193 (cris_target::low_set_pc): Define.
1194 (the_low_target): Remove the op fields.
1195 * linux-crisv32-low.cc (class crisv32_target)
1196 <low_supports_breakpoints>
1198 <low_set_pc>: Declare.
1199 (crisv32_target::low_supports_breakpoints)
1200 (crisv32_target::low_get_pc)
1201 (crisv32_target::low_set_pc): Define.
1202 (the_low_target): Remove the op fields.
1203 * linux-m32r-low.cc (class m32r_target)
1204 <low_supports_breakpoints>
1206 <low_set_pc>: Declare.
1207 (m32r_target::low_supports_breakpoints)
1208 (m32r_target::low_get_pc)
1209 (m32r_target::low_set_pc): Define.
1210 (the_low_target): Remove the op fields.
1211 * linux-m68k-low.cc (class m68k_target)
1212 <low_supports_breakpoints>
1214 <low_set_pc>: Declare.
1215 (m68k_target::low_supports_breakpoints)
1216 (m68k_target::low_get_pc)
1217 (m68k_target::low_set_pc): Define.
1218 (the_low_target): Remove the op fields.
1219 * linux-nios2-low.cc (class nios2_target)
1220 <low_supports_breakpoints>
1222 <low_set_pc>: Declare.
1223 (nios2_target::low_supports_breakpoints)
1224 (nios2_target::low_get_pc)
1225 (nios2_target::low_set_pc): Define.
1226 (the_low_target): Remove the op fields.
1227 * linux-sh-low.cc (class sh_target)
1228 <low_supports_breakpoints>
1230 <low_set_pc>: Declare.
1231 (sh_target::low_supports_breakpoints)
1232 (sh_target::low_get_pc)
1233 (sh_target::low_set_pc): Define.
1234 (the_low_target): Remove the op fields.
1235 * linux-xtensa-low.cc (class xtensa_target)
1236 <low_supports_breakpoints>
1238 <low_set_pc>: Declare.
1239 (xtensa_target::low_supports_breakpoints)
1240 (xtensa_target::low_get_pc)
1241 (xtensa_target::low_set_pc): Define.
1242 (the_low_target): Remove the op fields.
1243 * linux-sparc-low.cc (class sparc_target)
1244 <low_supports_breakpoints>
1245 <low_get_pc>: Declare.
1246 (sparc_target::low_supports_breakpoints)
1247 (sparc_target::low_get_pc): Define.
1248 (the_low_target): Remove the op fields.
1249 * linux-tile-low.cc (class tile_target)
1250 <low_supports_breakpoints>
1252 <low_set_pc>: Declare.
1253 (tile_target::low_supports_breakpoints)
1254 (tile_target::low_get_pc)
1255 (tile_target::low_set_pc): Define.
1256 (the_low_target): Remove the op fields.
1257 * linux-aarch64-low.cc (class aarch64_target)
1258 <low_supports_breakpoints>
1260 <low_set_pc>: Declare.
1261 (aarch64_target::low_supports_breakpoints): Define.
1262 (aarch64_get_pc): Turn into...
1263 (aarch64_target::low_get_pc): ...this.
1264 (aarch64_set_pc): Turn into...
1265 (aarch64_target::low_set_pc): ...this.
1266 (the_low_target): Remove the op fields.
1267 * linux-mips-low.cc (class mips_target)
1268 <low_supports_breakpoints>
1270 <low_set_pc>: Declare.
1271 (mips_target::low_supports_breakpoints): Define.
1272 (mips_get_pc): Turn into...
1273 (mips_target::low_get_pc): ...this.
1274 (mips_set_pc): Turn into...
1275 (mips_target::low_set_pc): ...this.
1276 (the_low_target): Remove the op fields.
1277 * linux-ppc-low.cc (class ppc_target)
1278 <low_supports_breakpoints>
1280 <low_set_pc>: Declare.
1281 (ppc_target::low_supports_breakpoints): Define.
1282 (ppc_get_pc): Turn into...
1283 (ppc_target::low_get_pc): ...this.
1284 (ppc_set_pc): Turn into...
1285 (ppc_target::low_set_pc): ...this.
1286 (the_low_target): Remove the op fields.
1287 * linux-riscv-low.cc (class riscv_target)
1288 <low_supports_breakpoints>
1290 <low_set_pc>: Declare.
1291 (riscv_target::low_supports_breakpoints): Define.
1292 (riscv_get_pc): Turn into...
1293 (riscv_target::low_get_pc): ...this.
1294 (riscv_set_pc): Turn into...
1295 (riscv_target::low_set_pc): ...this.
1296 (the_low_target): Remove the op fields.
1297 * linux-s390-low.cc (class s390_target)
1298 <low_supports_breakpoints>
1300 <low_set_pc>: Declare.
1301 (s390_target::low_supports_breakpoints): Define.
1302 (s390_get_pc): Turn into...
1303 (s390_target::low_get_pc): ...this.
1304 (s390_set_pc): Turn into...
1305 (s390_target::low_set_pc): ...this.
1306 (the_low_target): Remove the op fields.
1307 * linux-tic6x-low.cc (class tic6x_target)
1308 <low_supports_breakpoints>
1310 <low_set_pc>: Declare.
1311 (tic6x_target::low_supports_breakpoints): Define.
1312 (tic6x_get_pc): Turn into...
1313 (tic6x_target::low_get_pc): ...this.
1314 (tic6x_set_pc): Turn into...
1315 (tic6x_target::low_set_pc): ...this.
1316 (the_low_target): Remove the op fields.
1318 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1320 Turn some more static methods in linux-low into private methods
1321 of linux_process_target.
1323 * linux-low.cc (get_pc): Turn into...
1324 (linux_process_target::get_pc): ...this.
1325 (save_stop_reason): Turn into...
1326 (linux_process_target::save_stop_reason): ...this.
1327 (thread_still_has_status_pending_p): Turn into...
1328 (linux_process_target::thread_still_has_status_pending): ...this.
1329 (status_pending_p_callback): Turn into...
1330 (linux_process_target::status_pending_p_callback): ...this.
1331 (resume_stopped_resumed_lwps): Turn into...
1332 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1333 (install_software_single_step_breakpoints): Turn into...
1334 (linux_process_target::install_software_single_step_breakpoints):
1336 (single_step): Turn into...
1337 (linux_process_target::single_step): ...this.
1338 (linux_resume_one_lwp_throw): Turn into...
1339 (linux_process_target::resume_one_lwp_throw): ...this.
1340 (linux_resume_one_lwp): Turn into...
1341 (linux_process_target::resume_one_lwp): ...this.
1342 (resume_status_pending_p): Turn into...
1343 (linux_process_target::resume_status_pending): ...this.
1344 (need_step_over_p): Turn into...
1345 (linux_process_target::thread_needs_step_over): ...this.
1346 (linux_resume_one_thread): Turn into...
1347 (linux_process_target::resume_one_thread): ...this.
1348 (proceed_one_lwp): Turn into...
1349 (linux_process_target::proceed_one_lwp): ...this.
1350 (unsuspend_and_proceed_one_lwp): Turn into...
1351 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1353 Update the calls/references to the above functions below.
1355 (linux_process_target::handle_extended_wait)
1356 (linux_process_target::filter_event)
1357 (linux_process_target::wait_for_event_filtered)
1358 (linux_process_target::wait_1)
1359 (linux_process_target::move_out_of_jump_pad)
1360 (linux_process_target::start_step_over)
1361 (linux_process_target::resume)
1362 (linux_process_target::proceed_all_lwps)
1363 (regsets_store_inferior_registers)
1364 (linux_process_target::store_register)
1366 * linux-low.h (class linux_process_target)
1369 <thread_still_has_status_pending>
1370 <status_pending_p_callback>
1371 <resume_stopped_resumed_lwps>
1372 <install_software_single_step_breakpoints>
1374 <resume_one_lwp_throw>
1376 <resume_status_pending>
1377 <thread_needs_step_over>
1380 <unsuspend_and_proceed_one_lwp>: Declare.
1382 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1384 Turn the 'fetch_register' linux target op into a method of
1385 linux_process_target.
1387 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1388 (class linux_process_target) <low_fetch_register>: Declare.
1389 * linux-x86-low.cc (the_low_target)
1390 * linux-aarch64-low.cc (the_low_target)
1391 * linux-arm-low.cc (the_low_target)
1392 * linux-bfin-low.cc (the_low_target)
1393 * linux-cris-low.cc (the_low_target)
1394 * linux-crisv32-low.cc (the_low_target)
1395 * linux-m32r-low.cc (the_low_target)
1396 * linux-m68k-low.cc (the_low_target)
1397 * linux-nios2-low.cc (the_low_target)
1398 * linux-ppc-low.cc (the_low_target)
1399 * linux-s390-low.cc (the_low_target)
1400 * linux-sh-low.cc (the_low_target)
1401 * linux-sparc-low.cc (the_low_target)
1402 * linux-tic6x-low.cc (the_low_target)
1403 * linux-tile-low.cc (the_low_target)
1404 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1405 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1407 (ia64_fetch_register): Turn into...
1408 (ia64_target::low_fetch_register): ...this.
1409 (the_low_target): Remove the op field.
1410 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1412 (mips_fetch_register): Turn into...
1413 (mips_target::low_fetch_register): ...this.
1414 (the_low_target): Remove the op field.
1415 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1417 (riscv_fetch_register): Turn into...
1418 (riscv_target::low_fetch_register): ...this.
1419 (the_low_target): Remove the op field.
1421 Update the callers below.
1423 * linux-low.cc (linux_process_target::fetch_registers)
1424 (linux_process_target::low_fetch_register)
1426 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1428 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1429 linux target ops into methods of linux_process_target.
1431 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1432 (class linux_process_target) <fetch_register>
1434 <usr_fetch_inferior_registers>
1435 <usr_store_inferior_registers>
1436 <low_cannot_fetch_register>
1437 <low_cannot_fetch_register> Declare.
1438 * linux-low.cc (fetch_register): Turn into...
1439 (linux_process_target::fetch_register): ...this.
1440 (store_register): Turn into ...
1441 (linux_process_target::store_register): ...this.
1442 (usr_fetch_inferior_registers): Turn into...
1443 (linux_process_target::usr_fetch_inferior_registers): ...this.
1444 (usr_store_inferior_registers): Turn into...
1445 (linux_process_target::usr_store_inferior_registers): ...this.
1446 * linux-x86-low.cc (class x86_target)
1447 <low_cannot_fetch_register>
1448 <low_cannot_store_register>: Declare.
1449 (x86_cannot_store_register): Turn into...
1450 (x86_target::low_cannot_store_register): ...this.
1451 (x86_cannot_fetch_register): Turn into...
1452 (x86_target::low_cannot_fetch_register): ...this.
1453 (the_low_target): Remove the target op fields.
1454 * linux-aarch64-low.cc (class aarch64_target)
1455 <low_cannot_fetch_register>
1456 <low_cannot_store_register>: Declare.
1457 (aarch64_target::low_cannot_fetch_register)
1458 (aarch64_target::low_cannot_store_register): Define.
1459 (the_low_target): Remove the op fields.
1460 * linux-arm-low.cc (class arm_target)
1461 <low_cannot_fetch_register>
1462 <low_cannot_store_register>: Declare.
1463 (arm_cannot_fetch_register): Turn into...
1464 (arm_target::low_cannot_fetch_register): ...this.
1465 (arm_cannot_store_register): Turn into...
1466 (arm_target::low_cannot_store_register): ...this.
1467 (the_low_target): Remove the op fields.
1468 * linux-bfin-low.cc (class bfin_target)
1469 <low_cannot_fetch_register>
1470 <low_cannot_store_register>: Declare.
1471 (bfin_cannot_fetch_register): Turn into...
1472 (bfin_target::low_cannot_fetch_register): ...this.
1473 (bfin_cannot_store_register): Turn into...
1474 (bfin_target::low_cannot_store_register): ...this.
1475 (the_low_target): Remove the op fields.
1476 * linux-cris-low.cc (class cris_target)
1477 <low_cannot_fetch_register>
1478 <low_cannot_store_register>: Declare.
1479 (cris_cannot_fetch_register): Turn into...
1480 (cris_target::low_cannot_fetch_register): ...this.
1481 (cris_cannot_store_register): Turn into...
1482 (cris_target::low_cannot_store_register): ...this.
1483 (the_low_target): Remove the op fields.
1484 * linux-crisv32-low.cc (class crisv32_target)
1485 <low_cannot_fetch_register>
1486 <low_cannot_store_register>: Declare.
1487 (crisv32_target::low_cannot_fetch_register)
1488 (crisv32_target::low_cannot_store_register): Define.
1489 (the_low_target): Remove the op fields.
1490 * linux-ia64-low.cc (class ia64_target)
1491 <low_cannot_fetch_register>
1492 <low_cannot_store_register>: Declare.
1493 (ia64_cannot_fetch_register): Turn into...
1494 (ia64_target::low_cannot_fetch_register): ...this.
1495 (ia64_cannot_store_register): Turn into...
1496 (ia64_target::low_cannot_store_register): ...this.
1497 (the_low_target): Remove the op fields.
1498 * linux-m32r-low.cc (class m32r_target)
1499 <low_cannot_fetch_register>
1500 <low_cannot_store_register>: Declare.
1501 (m32r_cannot_fetch_register): Turn into...
1502 (m32r_target::low_cannot_fetch_register): ...this.
1503 (m32r_cannot_store_register): Turn into...
1504 (m32r_target::low_cannot_store_register): ...this.
1505 (the_low_target): Remove the op fields.
1506 * linux-m68k-low.cc (class m68k_target)
1507 <low_cannot_fetch_register>
1508 <low_cannot_store_register>: Declare.
1509 (m68k_cannot_fetch_register): Turn into...
1510 (m68k_target::low_cannot_fetch_register): ...this.
1511 (m68k_cannot_store_register): Turn into...
1512 (m68k_target::low_cannot_store_register): ...this.
1513 (the_low_target): Remove the op fields.
1514 * linux-mips-low.cc (class mips_target)
1515 <low_cannot_fetch_register>
1516 <low_cannot_store_register>: Declare.
1517 (mips_cannot_fetch_register): Turn into...
1518 (mips_target::low_cannot_fetch_register): ...this.
1519 (mips_cannot_store_register): Turn into...
1520 (mips_target::low_cannot_store_register): ...this.
1521 (get_usrregs_info): Inline at the call sites in
1522 low_cannot_fetch_register and low_cannot_store_register,
1524 (the_low_target): Remove the op fields.
1525 * linux-nios2-low.cc (class nios2_target)
1526 <low_cannot_fetch_register>
1527 <low_cannot_store_register>: Declare.
1528 (nios2_cannot_fetch_register): Turn into...
1529 (nios2_target::low_cannot_fetch_register): ...this.
1530 (nios2_cannot_store_register): Turn into...
1531 (nios2_target::low_cannot_store_register): ...this.
1532 (the_low_target): Remove the op fields.
1533 * linux-ppc-low.cc (class ppc_target)
1534 <low_cannot_fetch_register>
1535 <low_cannot_store_register>: Declare.
1536 (ppc_cannot_fetch_register): Turn into...
1537 (ppc_target::low_cannot_fetch_register): ...this.
1538 (ppc_cannot_store_register): Turn into...
1539 (ppc_target::low_cannot_store_register): ...this.
1540 (the_low_target): Remove the op fields.
1541 * linux-riscv-low.cc (class riscv_target)
1542 <low_cannot_fetch_register>
1543 <low_cannot_store_register>: Declare.
1544 (riscv_target::low_cannot_fetch_register)
1545 (riscv_target::low_cannot_store_register): Define.
1546 (the_low_target): Remove the op fields.
1547 * linux-s390-low.cc (class s390_target)
1548 <low_cannot_fetch_register>
1549 <low_cannot_store_register>: Declare.
1550 (s390_cannot_fetch_register): Turn into...
1551 (s390_target::low_cannot_fetch_register): ...this.
1552 (s390_cannot_store_register): Turn into...
1553 (s390_target::low_cannot_store_register): ...this.
1554 (the_low_target): Remove the op fields.
1555 * linux-sh-low.cc (class sh_target)
1556 <low_cannot_fetch_register>
1557 <low_cannot_store_register>: Declare.
1558 (sh_cannot_fetch_register): Turn into...
1559 (sh_target::low_cannot_fetch_register): ...this.
1560 (sh_cannot_store_register): Turn into...
1561 (sh_target::low_cannot_store_register): ...this.
1562 (the_low_target): Remove the op fields.
1563 * linux-sparc-low.cc (class sparc_target)
1564 <low_cannot_fetch_register>
1565 <low_cannot_store_register>: Declare.
1566 (sparc_cannot_fetch_register): Turn into...
1567 (sparc_target::low_cannot_fetch_register): ...this.
1568 (sparc_cannot_store_register): Turn into...
1569 (sparc_target::low_cannot_store_register): ...this.
1570 (the_low_target): Remove the op fields.
1571 * linux-tic6x-low.cc (class tic6x_target)
1572 <low_cannot_fetch_register>
1573 <low_cannot_store_register>: Declare.
1574 (tic6x_cannot_fetch_register): Turn into...
1575 (tic6x_target::low_cannot_fetch_register): ...this.
1576 (tic6x_cannot_store_register): Turn into...
1577 (tic6x_target::low_cannot_store_register): ...this.
1578 (the_low_target): Remove the op fields.
1579 * linux-tile-low.cc (class tile_target)
1580 <low_cannot_fetch_register>
1581 <low_cannot_store_register>: Declare.
1582 (tile_cannot_fetch_register): Turn into...
1583 (tile_target::low_cannot_fetch_register): ...this.
1584 (tile_cannot_store_register): Turn into...
1585 (tile_target::low_cannot_store_register): ...this.
1586 (the_low_target): Remove the op fields.
1587 * linux-xtensa-low.cc (class xtensa_target)
1588 <low_cannot_fetch_register>
1589 <low_cannot_store_register>: Declare.
1590 (xtensa_target::low_cannot_fetch_register)
1591 (xtensa_target::low_cannot_store_register): Define.
1592 (the_low_target): Remove the op fields.
1594 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1596 Turn the 'regs_info' linux target op into a method of
1597 linux_process_target.
1599 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1600 (class linux_process_target) <get_regs_info>: Define.
1602 Update the callers below.
1604 * linux-low.cc (linux_process_target::fetch_registers)
1605 (linux_process_target::store_registers)
1606 * proc-service.cc (gregset_info)
1608 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1609 (x86_linux_regs_info): Turn into ...
1610 (x86_target::get_regs_info): ...this.
1611 (the_low_target): Remove the op field.
1612 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1614 (aarch64_regs_info): Turn into ...
1615 (aarch64_target::get_regs_info): ...this.
1616 (the_low_target): Remove the op field.
1617 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1618 (arm_regs_info): Turn into ...
1619 (arm_target::get_regs_info): ...this.
1620 (the_low_target): Remove the op field.
1621 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1622 (bfin_regs_info): Turn into ...
1623 (bfin_target::get_regs_info): ...this.
1624 (the_low_target): Remove the op field.
1625 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1626 (cris_regs_info): Turn into ...
1627 (cris_target::get_regs_info): ...this.
1628 (the_low_target): Remove the op field.
1629 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1631 (crisv32_regs_info): Turn into ...
1632 (crisv32_target::get_regs_info): ...this.
1633 (the_low_target): Remove the op field.
1634 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1635 (ia64_regs_info): Turn into ...
1636 (ia64_target::get_regs_info): ...this.
1637 (the_low_target): Remove the op field.
1638 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1639 (m32r_regs_info): Turn into ...
1640 (m32r_target::get_regs_info): ...this.
1641 (the_low_target): Remove the op field.
1642 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1643 (m68k_regs_info): Turn into ...
1644 (m68k_target::get_regs_info): ...this.
1645 (the_low_target): Remove the op field.
1646 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1647 (mips_regs_info): Turn into ...
1648 (mips_target::get_regs_info): ...this.
1649 (the_low_target): Remove the op field.
1650 (get_usrregs_info): Update the call to the op.
1651 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1652 (nios2_regs_info): Turn into ...
1653 (nios2_target::get_regs_info): ...this.
1654 (the_low_target): Remove the op field.
1655 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1656 (ppc_regs_info): Turn into ...
1657 (ppc_target::get_regs_info): ...this.
1658 (the_low_target): Remove the op field.
1659 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1660 (riscv_regs_info): Turn into ...
1661 (riscv_target::get_regs_info): ...this.
1662 (the_low_target): Remove the op field.
1663 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1664 (s390_regs_info): Turn into ...
1665 (s390_target::get_regs_info): ...this.
1666 (the_low_target): Remove the op field.
1667 (s390_collect_ptrace_register)
1668 (s390_supply_ptrace_register)
1669 (s390_fill_gregset): Update the call to the op.
1670 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1671 (sh_regs_info): Turn into ...
1672 (sh_target::get_regs_info): ...this.
1673 (the_low_target): Remove the op field.
1674 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1675 (sparc_regs_info): Turn into ...
1676 (sparc_target::get_regs_info): ...this.
1677 (the_low_target): Remove the op field.
1678 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1679 (tic6x_regs_info): Turn into ...
1680 (tic6x_target::get_regs_info): ...this.
1681 (the_low_target): Remove the op field.
1682 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1683 (tile_regs_info): Turn into ...
1684 (tile_target::get_regs_info): ...this.
1685 (the_low_target): Remove the op field.
1686 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1688 (xtensa_regs_info): Turn into ...
1689 (xtensa_target::get_regs_info): ...this.
1690 (the_low_target): Remove the op field.
1692 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1694 Turn the 'arch_setup' linux target op into a method of
1695 linux_process_target.
1697 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1698 (class linux_process_target) <arch_setup_thread>
1699 <low_arch_setup>: New declarations.
1700 * linux-low.cc (linux_arch_setup): Delete.
1701 (linux_arch_setup_thread): Turn into...
1702 (linux_process_target::arch_setup_thread): ... this.
1704 Update the callers below.
1706 (linux_process_target::handle_extended_wait)
1707 (linux_process_target::post_create_inferior)
1708 (linux_process_target::filter_event)
1710 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1712 (x86_linux_update_xmltarget): Turn into...
1713 (x86_target::update_xmltarget): ...this.
1714 (x86_linux_process_qsupported): Update the call to
1715 x86_linux_update_xmltarget.
1716 (x86_arch_setup): Turn into ...
1717 (x86_target::low_arch_setup): ...this.
1718 (the_low_target): Remove the op field.
1719 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1721 (aarch64_arch_setup): Turn into ...
1722 (aarch64_target::low_arch_setup): ...this.
1723 (the_low_target): Remove the op field.
1724 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1726 (arm_arch_setup): Turn into ...
1727 (arm_target::low_arch_setup): ...this.
1728 (the_low_target): Remove the op field.
1729 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1731 (bfin_arch_setup): Turn into ...
1732 (bfin_target::low_arch_setup): ...this.
1733 (the_low_target): Remove the op field.
1734 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1736 (cris_arch_setup): Turn into ...
1737 (cris_target::low_arch_setup): ...this.
1738 (the_low_target): Remove the op field.
1739 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1741 (crisv32_arch_setup): Turn into ...
1742 (crisv32_target::low_arch_setup): ...this.
1743 (the_low_target): Remove the op field.
1744 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1746 (ia64_arch_setup): Turn into ...
1747 (ia64_target::low_arch_setup): ...this.
1748 (the_low_target): Remove the op field.
1749 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1751 (m32r_arch_setup): Turn into ...
1752 (m32r_target::low_arch_setup): ...this.
1753 (the_low_target): Remove the op field.
1754 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1756 (m68k_arch_setup): Turn into ...
1757 (m68k_target::low_arch_setup): ...this.
1758 (the_low_target): Remove the op field.
1759 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1761 (mips_arch_setup): Turn into ...
1762 (mips_target::low_arch_setup): ...this.
1763 (the_low_target): Remove the op field.
1764 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1766 (nios2_arch_setup): Turn into ...
1767 (nios2_target::low_arch_setup): ...this.
1768 (the_low_target): Remove the op field.
1769 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1771 (ppc_arch_setup): Turn into ...
1772 (ppc_target::low_arch_setup): ...this.
1773 (the_low_target): Remove the op field.
1774 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1776 (riscv_arch_setup): Turn into ...
1777 (riscv_target::low_arch_setup): ...this.
1778 (the_low_target): Remove the op field.
1779 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1781 (s390_arch_setup): Turn into ...
1782 (s390_target::low_arch_setup): ...this.
1783 (the_low_target): Remove the op field.
1784 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1786 (sh_arch_setup): Turn into ...
1787 (sh_target::low_arch_setup): ...this.
1788 (the_low_target): Remove the op field.
1789 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1791 (sparc_arch_setup): Turn into ...
1792 (sparc_target::low_arch_setup): ...this.
1793 (the_low_target): Remove the op field.
1794 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1796 (tic6x_arch_setup): Turn into ...
1797 (tic6x_target::low_arch_setup): ...this.
1798 (the_low_target): Remove the op field.
1799 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1801 (tile_arch_setup): Turn into ...
1802 (tile_target::low_arch_setup): ...this.
1803 (the_low_target): Remove the op field.
1804 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1806 (xtensa_arch_setup): Turn into ...
1807 (xtensa_target::low_arch_setup): ...this.
1808 (the_low_target): Remove the op field.
1810 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1812 * linux-low.h (the_linux_target): New extern declaration.
1813 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1815 (the_linux_target): Remove.
1816 * linux-x86-low.cc (class x86_target): New class.
1817 (the_x86_target): New static object.
1818 (the_linux_target): Define as pointer to the_x86_target.
1819 * linux-aarch64-low.cc (class aarch64_target): New class.
1820 (the_aarch64_target): New static object.
1821 (the_linux_target): Define as pointer to the_aarch64_target.
1822 * linux-arm-low.cc (class arm_target): New class.
1823 (the_arm_target): New static object.
1824 (the_linux_target): Define as pointer to the_arm_target.
1825 * linux-bfin-low.cc (class bfin_target): New class.
1826 (the_bfin_target): New static object.
1827 (the_linux_target): Define as pointer to the_bfin_target.
1828 * linux-cris-low.cc (class cris_target): New class.
1829 (the_cris_target): New static object.
1830 (the_linux_target): Define as pointer to the_cris_target.
1831 * linux-crisv32-low.cc (class crisv32_target): New class.
1832 (the_crisv32_target): New static object.
1833 (the_linux_target): Define as pointer to the_crisv32_target.
1834 * linux-ia64-low.cc (class ia64_target): New class.
1835 (the_ia64_target): New static object.
1836 (the_linux_target): Define as pointer to the_ia64_target.
1837 * linux-m32r-low.cc (class m32r_target): New class.
1838 (the_m32r_target): New static object.
1839 (the_linux_target): Define as pointer to the_m32r_target.
1840 * linux-m68k-low.cc (class m68k_target): New class.
1841 (the_m68k_target): New static object.
1842 (the_linux_target): Define as pointer to the_m68k_target.
1843 * linux-mips-low.cc (class mips_target): New class.
1844 (the_mips_target): New static object.
1845 (the_linux_target): Define as pointer to the_mips_target.
1846 * linux-nios2-low.cc (class nios2_target): New class.
1847 (the_nios2_target): New static object.
1848 (the_linux_target): Define as pointer to the_nios2_target.
1849 * linux-ppc-low.cc (class ppc_target): New class.
1850 (the_ppc_target): New static object.
1851 (the_linux_target): Define as pointer to the_ppc_target.
1852 * linux-riscv-low.cc (class riscv_target): New class.
1853 (the_riscv_target): New static object.
1854 (the_linux_target): Define as pointer to the_riscv_target.
1855 * linux-s390-low.cc (class s390_target): New class.
1856 (the_s390_target): New static object.
1857 (the_linux_target): Define as pointer to the_s390_target.
1858 * linux-sh-low.cc (class sh_target): New class.
1859 (the_sh_target): New static object.
1860 (the_linux_target): Define as pointer to the_sh_target.
1861 * linux-sparc-low.cc (class sparc_target): New class.
1862 (the_sparc_target): New static object.
1863 (the_linux_target): Define as pointer to the_sparc_target.
1864 * linux-tic6x-low.cc (class tic6x_target): New class.
1865 (the_tic6x_target): New static object.
1866 (the_linux_target): Define as pointer to the_tic6x_target.
1867 * linux-tile-low.cc (class tile_target): New class.
1868 (the_tile_target): New static object.
1869 (the_linux_target): Define as pointer to the_tile_target.
1870 * linux-xtensa-low.cc (class xtensa_target): New class.
1871 (the_xtensa_target): New static object.
1872 (the_linux_target): Define as pointer to the_xtensa_target.
1874 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1876 Turn some static functions in linux-low.cc into private methods of
1877 linux_process_target.
1879 * linux-low.cc (handle_extended_wait): Turn into ...
1880 (linux_process_target::handle_extended_wait): ...this. Call
1881 'mourn' on 'this' object instead of 'the_target'.
1882 (maybe_move_out_of_jump_pad): Turn into...
1883 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
1884 (linux_low_filter_event): Turn into...
1885 (linux_process_target::filter_event): ...this.
1886 (linux_wait_for_event_filtered): Turn into...
1887 (linux_process_target::wait_for_event_filtered): ...this.
1888 (linux_wait_for_event): Turn into...
1889 (linux_process_target::wait_for_event): ...this.
1890 (linux_wait_1): Turn into...
1891 (linux_process_target::wait_1): ...this.
1892 (wait_for_sigstop): Turn into...
1893 (linux_process_target::wait_for_sigstop): ...this.
1894 (move_out_of_jump_pad_callback): Turn into...
1895 (linux_process_target::move_out_of_jump_pad): ...this.
1896 (stop_all_lwps): Turn into...
1897 (linux_process_target::stop_all_lwps): ...this.
1898 (start_step_over): Turn into...
1899 (linux_process_target::start_step_over): ...this.
1900 (complete_ongoing_step_over): Turn into...
1901 (linux_process_target::complete_ongoing_step_over): ...this.
1902 (proceed_all_lwps): Turn into...
1903 (linux_process_target::proceed_all_lwps): ...this.
1904 (unstop_all_lwps): Turn into...
1905 (linux_process_target::unstop_all_lwps): ...this.
1907 * linux-low.h (class linux_process_target)
1908 <handle_extended_wait>
1909 <maybe_move_out_of_jump_pad>
1911 <wait_for_event_filtered>
1915 <move_out_of_jump_pad>
1918 <complete_ongoing_step_over>
1920 <unstop_all_lwps>: Declare.
1922 Update the callers below.
1924 * linux-low.cc (linux_process_target::attach): Update.
1925 (linux_process_target::stabilize_threads): Ditto.
1926 (linux_process_target::wait): Ditto.
1928 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1930 * linux-low.h (struct linux_target_ops): Update the comment for
1931 'cannot_store_register' to return 0 or 1.
1932 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
1935 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
1937 * config.in: Re-generate.
1938 * configure: Re-generate.
1940 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1942 * regcache.cc (find_register_by_number): Update.
1943 * tdesc.cc (init_target_desc): Likewise.
1944 * tdesc.h (target_desc::reg_defs): Likewise.
1946 2020-03-12 Tom Tromey <tom@tromey.com>
1948 * configure: Rebuild.
1949 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
1950 (WIN32APILIBS): New subst.
1951 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
1953 (gdbsupport/%.o): Remove target.
1954 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
1955 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
1956 (WIN32APILIBS): New variable.
1957 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
1958 (gdbreplay$(EXEEXT)): Likewise.
1960 2020-03-12 Tom Tromey <tom@tromey.com>
1962 * config.in, configure: Rebuild.
1963 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
1964 * acinclude.m4: Include gettext-sister.m4.
1965 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
1967 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
1968 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
1970 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
1972 * acinclude.m4: Update path to selftest.m4.
1974 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
1976 * configure.ac: Don't source bfd/development.sh, move
1977 GDB_AC_COMMON higher.
1978 * configure: Re-generate.
1980 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
1982 * configure: Re-generate.
1984 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
1986 * configure: Re-generate.
1988 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1990 * .dir-locals.el: New file.
1992 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1994 * .gitattributes: New file.
1996 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
1998 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
1999 reply into an S reply.
2000 * server.cc (disable_packet_T): New global.
2001 (captured_main): Set new global when appropriate.
2002 * server.h (disable_packet_T): Declare.
2004 2020-02-21 Tom Tromey <tom@tromey.com>
2006 * Makefile.in (mostlyclean): New target.
2008 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2010 * target.h (struct process_stratum_target): Remove.
2011 (class process_target): Rename to ...
2012 (class process_stratum_target): ... this.
2013 * linux-low.h (class linux_process_target): Derive from
2014 'process_stratum_target'.
2015 * linux-low.cc (linux_target_ops): Remove.
2016 (initialize_low): Set the_target to the singleton instance of
2017 linux_process_target.
2018 * lynx-low.h (class lynx_process_target): Derive from
2019 'process_stratum_target'.
2020 * lynx-low.cc (lynx_target_ops): Remove.
2021 (initialize_low): Set the_target to the singleton instance of
2022 lynx_process_target.
2023 * nto-low.h (class nto_process_target): Derive from
2024 'process_stratum_target'.
2025 * nto-low.cc (nto_target_ops): Remove.
2026 (initialize_low): Set the_target to the singleton instance of
2028 * win32-low.h (class win32_process_target): Derive from
2029 'process_stratum_target'.
2030 * win32-low.cc (win32_target_ops): Remove.
2031 (initialize_low): Set the_target to the singleton instance of
2032 win32_process_target.
2034 Replace 'the_target->pt' with 'the_target' in the uses below.
2036 * hostio.cc (hostio_error)
2041 * linux-aarch32-low.cc (arm_breakpoint_at)
2042 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2043 * linux-arm-low.cc (arm_sigreturn_next_pc)
2045 (arm_get_syscall_trapinfo)
2046 * linux-cris-low.cc (cris_breakpoint_at)
2047 * linux-crisv32-low.cc (cris_breakpoint_at)
2048 * linux-low.cc (handle_extended_wait)
2051 (linux_process_target::breakpoint_kind_from_pc)
2053 * linux-m32r-low.cc (m32r_breakpoint_at)
2054 * linux-mips-low.cc (mips_breakpoint_at)
2055 * linux-nios2-low.cc (nios2_breakpoint_at)
2056 * linux-ppc-low.cc (ppc_breakpoint_at)
2057 * linux-s390-low.cc (s390_get_hwcap)
2058 * linux-sh-low.cc (sh_breakpoint_at)
2059 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2060 (sparc_store_gregset_from_stack)
2061 (sparc_breakpoint_at)
2062 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2063 * linux-tile-low.cc (tile_breakpoint_at)
2064 * linux-x86-low.cc (x86_breakpoint_at)
2065 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2066 * mem-break.cc (bp_size)
2068 (insert_memory_breakpoint)
2069 (set_raw_breakpoint_at)
2070 (delete_raw_breakpoint)
2072 (uninsert_raw_breakpoint)
2073 (reinsert_raw_breakpoint)
2074 (validate_inserted_breakpoint)
2075 * regcache.cc (regcache_read_pc)
2077 * remote-utils.cc (putpkt_binary_1)
2080 (prepare_resume_reply)
2081 * server.cc (handle_general_set)
2084 (handle_qxfer_exec_file)
2085 (handle_qxfer_libraries_svr4)
2086 (handle_qxfer_osdata)
2087 (handle_qxfer_siginfo)
2088 (handle_qxfer_fdpic)
2092 (queue_stop_reply_callback)
2094 * target.cc (prepare_to_access_memory)
2095 (done_accessing_memory)
2096 (read_inferior_memory)
2097 (target_write_memory)
2098 (target_stop_and_wait)
2100 (target_mourn_inferior)
2101 (target_continue_no_signal)
2103 (target_supports_multi_process)
2106 (target_create_inferior)
2107 (target_post_create_inferior)
2109 (target_supports_fork_events)
2110 (target_supports_vfork_events)
2111 (target_supports_exec_events)
2112 (target_handle_new_gdb_connection)
2115 (fetch_inferior_registers)
2116 (store_inferior_registers)
2118 (target_supports_non_stop)
2120 (target_process_qsupported)
2121 (target_supports_catch_syscall)
2122 (target_get_ipa_tdesc_idx)
2123 (target_supports_tracepoints)
2124 (target_supports_fast_tracepoints)
2125 (target_get_min_fast_tracepoint_insn_len)
2126 (target_thread_stopped)
2128 (target_unpause_all)
2129 (target_stabilize_threads)
2130 (target_install_fast_tracepoint_jump_pad)
2132 (target_supports_disable_randomization)
2133 (target_supports_agent)
2134 (target_enable_btrace)
2135 (target_disable_btrace)
2136 (target_read_btrace)
2137 (target_read_btrace_conf)
2138 (target_supports_range_stepping)
2139 (target_supports_stopped_by_sw_breakpoint)
2140 (target_stopped_by_sw_breakpoint)
2141 (target_supports_stopped_by_hw_breakpoint)
2142 (target_supports_hardware_single_step)
2143 (target_stopped_by_hw_breakpoint)
2144 (target_breakpoint_kind_from_pc)
2145 (target_breakpoint_kind_from_current_state)
2146 (target_supports_software_single_step)
2147 (target_core_of_thread)
2148 (target_thread_name)
2149 (target_thread_handle)
2150 * win32-low.cc (do_initial_child_stuff)
2152 Rename target op default definitions listed below.
2154 * target.cc (process_target::post_create_inferior): Rename as ...
2155 (process_stratum_target::post_create_inferior): ... this.
2156 (process_target::prepare_to_access_memory): Rename as ...
2157 (process_stratum_target::prepare_to_access_memory): ... this.
2158 (process_target::done_accessing_memory): Rename as ...
2159 (process_stratum_target::done_accessing_memory): ... this.
2160 (process_target::look_up_symbols): Rename as ...
2161 (process_stratum_target::look_up_symbols): ... this.
2162 (process_target::supports_read_auxv): Rename as ...
2163 (process_stratum_target::supports_read_auxv): ... this.
2164 (process_target::read_auxv): Rename as ...
2165 (process_stratum_target::read_auxv): ... this.
2166 (process_target::supports_z_point_type): Rename as ...
2167 (process_stratum_target::supports_z_point_type): ... this.
2168 (process_target::insert_point): Rename as ...
2169 (process_stratum_target::insert_point): ... this.
2170 (process_target::remove_point): Rename as ...
2171 (process_stratum_target::remove_point): ... this.
2172 (process_target::stopped_by_sw_breakpoint): Rename as ...
2173 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2174 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2175 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2176 (process_target::stopped_by_hw_breakpoint): Rename as ...
2177 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2178 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2179 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2180 (process_target::supports_hardware_single_step): Rename as ...
2181 (process_stratum_target::supports_hardware_single_step): ... this.
2182 (process_target::stopped_by_watchpoint): Rename as ...
2183 (process_stratum_target::stopped_by_watchpoint): ... this.
2184 (process_target::stopped_data_address): Rename as ...
2185 (process_stratum_target::stopped_data_address): ... this.
2186 (process_target::supports_read_offsets): Rename as ...
2187 (process_stratum_target::supports_read_offsets): ... this.
2188 (process_target::read_offsets): Rename as ...
2189 (process_stratum_target::read_offsets): ... this.
2190 (process_target::supports_get_tls_address): Rename as ...
2191 (process_stratum_target::supports_get_tls_address): ... this.
2192 (process_target::get_tls_address): Rename as ...
2193 (process_stratum_target::get_tls_address): ... this.
2194 (process_target::hostio_last_error): Rename as ...
2195 (process_stratum_target::hostio_last_error): ... this.
2196 (process_target::supports_qxfer_osdata): Rename as ...
2197 (process_stratum_target::supports_qxfer_osdata): ... this.
2198 (process_target::qxfer_osdata): Rename as ...
2199 (process_stratum_target::qxfer_osdata): ... this.
2200 (process_target::supports_qxfer_siginfo): Rename as ...
2201 (process_stratum_target::supports_qxfer_siginfo): ... this.
2202 (process_target::qxfer_siginfo): Rename as ...
2203 (process_stratum_target::qxfer_siginfo): ... this.
2204 (process_target::supports_non_stop): Rename as ...
2205 (process_stratum_target::supports_non_stop): ... this.
2206 (process_target::async): Rename as ...
2207 (process_stratum_target::async): ... this.
2208 (process_target::start_non_stop): Rename as ...
2209 (process_stratum_target::start_non_stop): ... this.
2210 (process_target::supports_multi_process): Rename as ...
2211 (process_stratum_target::supports_multi_process): ... this.
2212 (process_target::supports_fork_events): Rename as ...
2213 (process_stratum_target::supports_fork_events): ... this.
2214 (process_target::supports_vfork_events): Rename as ...
2215 (process_stratum_target::supports_vfork_events): ... this.
2216 (process_target::supports_exec_events): Rename as ...
2217 (process_stratum_target::supports_exec_events): ... this.
2218 (process_target::handle_new_gdb_connection): Rename as ...
2219 (process_stratum_target::handle_new_gdb_connection): ... this.
2220 (process_target::handle_monitor_command): Rename as ...
2221 (process_stratum_target::handle_monitor_command): ... this.
2222 (process_target::core_of_thread): Rename as ...
2223 (process_stratum_target::core_of_thread): ... this.
2224 (process_target::supports_read_loadmap): Rename as ...
2225 (process_stratum_target::supports_read_loadmap): ... this.
2226 (process_target::read_loadmap): Rename as ...
2227 (process_stratum_target::read_loadmap): ... this.
2228 (process_target::process_qsupported): Rename as ...
2229 (process_stratum_target::process_qsupported): ... this.
2230 (process_target::supports_tracepoints): Rename as ...
2231 (process_stratum_target::supports_tracepoints): ... this.
2232 (process_target::read_pc): Rename as ...
2233 (process_stratum_target::read_pc): ... this.
2234 (process_target::write_pc): Rename as ...
2235 (process_stratum_target::write_pc): ... this.
2236 (process_target::supports_thread_stopped): Rename as ...
2237 (process_stratum_target::supports_thread_stopped): ... this.
2238 (process_target::thread_stopped): Rename as ...
2239 (process_stratum_target::thread_stopped): ... this.
2240 (process_target::supports_get_tib_address): Rename as ...
2241 (process_stratum_target::supports_get_tib_address): ... this.
2242 (process_target::get_tib_address): Rename as ...
2243 (process_stratum_target::get_tib_address): ... this.
2244 (process_target::pause_all): Rename as ...
2245 (process_stratum_target::pause_all): ... this.
2246 (process_target::unpause_all): Rename as ...
2247 (process_stratum_target::unpause_all): ... this.
2248 (process_target::stabilize_threads): Rename as ...
2249 (process_stratum_target::stabilize_threads): ... this.
2250 (process_target::supports_fast_tracepoints): Rename as ...
2251 (process_stratum_target::supports_fast_tracepoints): ... this.
2252 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2253 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2254 (process_target::emit_ops): Rename as ...
2255 (process_stratum_target::emit_ops): ... this.
2256 (process_target::supports_disable_randomization): Rename as ...
2257 (process_stratum_target::supports_disable_randomization): ... this.
2258 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2259 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2260 (process_target::qxfer_libraries_svr4): Rename as ...
2261 (process_stratum_target::qxfer_libraries_svr4): ... this.
2262 (process_target::supports_agent): Rename as ...
2263 (process_stratum_target::supports_agent): ... this.
2264 (process_target::enable_btrace): Rename as ...
2265 (process_stratum_target::enable_btrace): ... this.
2266 (process_target::disable_btrace): Rename as ...
2267 (process_stratum_target::disable_btrace): ... this.
2268 (process_target::read_btrace): Rename as ...
2269 (process_stratum_target::read_btrace): ... this.
2270 (process_target::read_btrace_conf): Rename as ...
2271 (process_stratum_target::read_btrace_conf): ... this.
2272 (process_target::supports_range_stepping): Rename as ...
2273 (process_stratum_target::supports_range_stepping): ... this.
2274 (process_target::supports_pid_to_exec_file): Rename as ...
2275 (process_stratum_target::supports_pid_to_exec_file): ... this.
2276 (process_target::pid_to_exec_file): Rename as ...
2277 (process_stratum_target::pid_to_exec_file): ... this.
2278 (process_target::supports_multifs): Rename as ...
2279 (process_stratum_target::supports_multifs): ... this.
2280 (process_target::multifs_open): Rename as ...
2281 (process_stratum_target::multifs_open): ... this.
2282 (process_target::multifs_unlink): Rename as ...
2283 (process_stratum_target::multifs_unlink): ... this.
2284 (process_target::multifs_readlink): Rename as ...
2285 (process_stratum_target::multifs_readlink): ... this.
2286 (process_target::breakpoint_kind_from_pc): Rename as ...
2287 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2288 (process_target::breakpoint_kind_from_current_state): Rename as ...
2289 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2290 (process_target::thread_name): Rename as ...
2291 (process_stratum_target::thread_name): ... this.
2292 (process_target::thread_handle): Rename as ...
2293 (process_stratum_target::thread_handle): ... this.
2294 (process_target::supports_software_single_step): Rename as ...
2295 (process_stratum_target::supports_software_single_step): ... this.
2296 (process_target::supports_catch_syscall): Rename as ...
2297 (process_stratum_target::supports_catch_syscall): ... this.
2298 (process_target::get_ipa_tdesc_idx): Rename as ...
2299 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2301 2020-02-20 Pedro Alves <palves@redhat.com>
2303 * target.cc (set_target_ops): Simply copy the given target pointer
2304 instead of creating a copy of the pointed object.
2306 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2308 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2311 * target.h (struct process_stratum_target): Remove the target op.
2312 (class process_target): Add the target op.
2313 (target_get_ipa_tdesc_idx): Update the macro.
2314 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2316 Update the derived classes and callers below.
2318 * linux-low.cc (linux_target_ops): Update.
2319 (linux_get_ipa_tdesc_idx): Turn into ...
2320 (linux_process_target::get_ipa_tdesc_idx): ... this.
2321 * linux-low.h (class linux_process_target): Update.
2322 * lynx-low.cc (lynx_target_ops): Update.
2323 * nto-low.cc (nto_target_ops): Update.
2324 * win32-low.cc (win32_target_ops): Update.
2326 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2328 Turn process_stratum_target's supports_catch_syscall op into a
2329 method of process_target.
2331 * target.h (struct process_stratum_target): Remove the target op.
2332 (class process_target): Add the target op.
2333 (target_supports_catch_syscall): Update the macro.
2334 * target.cc (process_target::supports_catch_syscall): Define.
2336 Update the derived classes and callers below.
2338 * linux-low.cc (linux_target_ops): Update.
2339 (linux_supports_catch_syscall): Turn into ...
2340 (linux_process_target::supports_catch_syscall): ... this.
2341 * linux-low.h (class linux_process_target): Update.
2342 * lynx-low.cc (lynx_target_ops): Update.
2343 * nto-low.cc (nto_target_ops): Update.
2344 * win32-low.cc (win32_target_ops): Update.
2346 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2348 Turn process_stratum_target's supports_software_single_step op
2349 into a method of process_target.
2351 * target.h (struct process_stratum_target): Remove the target op.
2352 (class process_target): Add the target op.
2353 (target_supports_software_single_step): Update the macro.
2354 * target.cc (process_target::supports_software_single_step): Define.
2356 Update the derived classes and callers below.
2358 * linux-low.cc (linux_target_ops): Update.
2359 (linux_supports_software_single_step): Turn into ...
2360 (linux_process_target::supports_software_single_step): ... this.
2361 * linux-low.h (class linux_process_target): Update.
2362 * lynx-low.cc (lynx_target_ops): Update.
2363 * nto-low.cc (nto_target_ops): Update.
2364 * win32-low.cc (win32_target_ops): Update.
2366 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2368 Turn process_stratum_target's thread_name and thread_handle ops
2369 into methods of process_target.
2371 * target.h (struct process_stratum_target): Remove the target ops.
2372 (class process_target): Add the target ops.
2373 (target_thread_name): Update the macro.
2374 (target_thread_handle): Update the macro.
2375 * target.cc (process_target::thread_name): Define.
2376 (process_target::thread_handle): Define.
2378 Update the derived classes and callers below.
2380 * linux-low.cc (linux_target_ops): Update.
2381 (linux_process_target::thread_name): Define.
2382 (linux_process_target::thread_handle): Define.
2383 * linux-low.h (class linux_process_target): Update.
2384 * lynx-low.cc (lynx_target_ops): Update.
2385 * nto-low.cc (nto_target_ops): Update.
2386 * win32-low.cc (win32_target_ops): Update.
2388 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2390 Turn process_stratum_target's breakpoint_kind_from_pc,
2391 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2392 ops into methods of process_target.
2394 * target.h (struct process_stratum_target): Remove the target op.
2395 (class process_target): Add the target op.
2396 (target_breakpoint_kind_from_pc): Update the macro.
2397 (target_breakpoint_kind_from_current_state): Update the macro.
2398 (default_breakpoint_kind_from_pc): Remove declaration.
2399 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2400 (process_target::breakpoint_kind_from_pc): ... this.
2401 (process_target::breakpoint_kind_from_current_state): Define.
2403 Update the derived classes and callers below.
2405 * mem-break.cc (bp_size): Update.
2406 (bp_opcode): Update.
2407 * linux-low.cc (linux_target_ops): Update.
2408 (linux_wait_1): Update.
2409 (linux_breakpoint_kind_from_pc): Turn into ...
2410 (linux_process_target::breakpoint_kind_from_pc): ... this.
2411 (linux_sw_breakpoint_from_kind): Turn into ...
2412 (linux_process_target::sw_breakpoint_from_kind): ... this.
2413 (linux_breakpoint_kind_from_current_state): Turn into ...
2414 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2415 * linux-low.h (class linux_process_target): Update.
2416 * lynx-low.cc (lynx_target_ops): Update.
2417 (lynx_process_target::sw_breakpoint_from_kind): Define.
2418 * lynx-low.h (class lynx_process_target): Update.
2419 * nto-low.cc (nto_target_ops): Update.
2420 (nto_sw_breakpoint_from_kind): Turn into ...
2421 (nto_process_target::sw_breakpoint_from_kind): ... this.
2422 * nto-low.h (class nto_process_target): Update.
2423 * win32-low.cc (win32_target_ops): Update.
2424 (win32_sw_breakpoint_from_kind): Turn into ...
2425 (win32_process_target::sw_breakpoint_from_kind): ... this.
2426 * win32-low.h (class win32_process_target): Update.
2428 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2430 Turn process_stratum_target's multifs_open, multifs_readlink,
2431 multifs_unlink ops into methods of process_target.
2433 * target.h (struct process_stratum_target): Remove the target ops.
2434 (class process_target): Add the target ops. Also add
2436 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2438 (process_target::supports_multifs): Define.
2439 (process_target::multifs_open): Define.
2440 (process_target::multifs_readlink): Define.
2441 (process_target::multifs_unlink): Define.
2443 Update the derived classes and callers below.
2445 * hostio.cc (handle_setfs): Update.
2446 (handle_open): Update.
2447 (handle_unlink): Update.
2448 (handle_readlink): Update.
2449 * linux-low.cc (linux_target_ops): Update.
2450 (linux_process_target::supports_multifs): Define.
2451 (linux_process_target::multifs_open): Define.
2452 (linux_process_target::multifs_readlink): Define.
2453 (linux_process_target::multifs_unlink): Define.
2454 * linux-low.h (class linux_process_target): Update.
2455 * lynx-low.cc (lynx_target_ops): Update.
2456 * nto-low.cc (nto_target_ops): Update.
2457 * win32-low.cc (win32_target_ops): Update.
2459 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2461 Turn process_stratum_target's pid_to_exec_file op into a method
2464 * target.h (struct process_stratum_target): Remove the target op.
2465 (class process_target): Add the target op. Also add
2466 'supports_pid_to_exec_file'.
2467 * target.cc (process_target::pid_to_exec_file): Define.
2468 (process_target::supports_pid_to_exec_file): Define.
2470 Update the derived classes and callers below.
2472 * server.cc (handle_qxfer_exec_file): Update.
2473 (handle_query): Update.
2474 * linux-low.cc (linux_target_ops): Update.
2475 (linux_process_target::supports_pid_to_exec_file): Define.
2476 (linux_process_target::pid_to_exec_file): Define.
2477 * linux-low.h (class linux_process_target): Update.
2478 * lynx-low.cc (lynx_target_ops): Update.
2479 * nto-low.cc (nto_target_ops): Update.
2480 * win32-low.cc (win32_target_ops): Update.
2482 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2484 Turn process_stratum_target's supports_range_stepping op into a
2485 method of process_target.
2487 * target.h (struct process_stratum_target): Remove the target op.
2488 (class process_target): Add the target op.
2489 (target_supports_range_stepping): Update the macro.
2490 * target.cc (process_target::supports_range_stepping): Define.
2492 Update the derived classes and callers below.
2494 * linux-low.cc (linux_target_ops): Update.
2495 (linux_supports_range_stepping): Turn into ...
2496 (linux_process_target::supports_range_stepping): ... this.
2497 * linux-low.h (class linux_process_target): Update.
2498 * lynx-low.cc (lynx_target_ops): Update.
2499 * nto-low.cc (nto_target_ops): Update.
2500 * win32-low.cc (win32_target_ops): Update.
2502 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2504 Turn process_stratum_target's btrace-related ops (enable_btrace,
2505 disable_btrace, read_btrace, read_btrace_conf) into methods of
2508 * target.h (struct process_stratum_target): Remove the target ops.
2509 (class process_target): Add the target ops.
2510 (target_enable_btrace): Update.
2511 (target_disable_btrace): Update.
2512 (target_read_btrace): Update.
2513 (target_read_btrace_conf): Update.
2514 * target.cc (process_target::enable_btrace): Define.
2515 (process_target::disable_btrace): Define.
2516 (process_target::read_btrace): Define.
2517 (process_target::read_btrace_conf): Define.
2519 Update the derived classes and callers below.
2521 * linux-low.cc (linux_target_ops): Update.
2522 (linux_process_target:enable_btrace): Define as a wrapper around
2523 linux_enable_btrace.
2524 (linux_low_disable_btrace): Turn into ...
2525 (linux_process_target::disable_btrace): ... this.
2526 (linux_low_read_btrace): Turn into ...
2527 (linux_process_target::read_btrace): ... this.
2528 (linux_low_btrace_conf): Turn into ...
2529 (linux_process_target::read_btrace_conf): ... this.
2530 * linux-low.h (class linux_process_target): Update.
2531 * lynx-low.cc (lynx_target_ops): Update.
2532 * nto-low.cc (nto_target_ops): Update.
2533 * win32-low.cc (win32_target_ops): Update.
2535 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2537 Turn process_stratum_target's supports_agent op into a method of
2540 * target.h (struct process_stratum_target): Remove the target op.
2541 (class process_target): Add the target op.
2542 (target_supports_agent): Update the macro.
2543 * target.cc (process_target::supports_agent): Define.
2545 Update the derived classes and callers below.
2547 * linux-low.cc (linux_target_ops): Update.
2548 (linux_supports_agent): Turn into ...
2549 (linux_process_target::supports_agent): ... this.
2550 * linux-low.h (class linux_process_target): Update.
2551 * lynx-low.cc (lynx_target_ops): Update.
2552 * nto-low.cc (nto_target_ops): Update.
2553 * win32-low.cc (win32_target_ops): Update.
2555 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2557 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2558 method of process_target.
2560 * target.h (struct process_stratum_target): Remove the target op.
2561 (class process_target): Add the target op. Also add
2562 'supports_qxfer_libraries_svr4'.
2563 * target.cc (process_target::qxfer_libraries_svr4): Define.
2564 (process_target::supports_qxfer_libraries_svr4): Define.
2566 Update the derived classes and callers below.
2568 * server.cc (handle_qxfer_libraries_svr4): Update.
2569 (handle_query): Update.
2570 * linux-low.cc (linux_target_ops): Update.
2571 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2572 (linux_qxfer_libraries_svr4): Turn into ...
2573 (linux_process_target::qxfer_libraries_svr4): ... this.
2574 * linux-low.h (class linux_process_target): Update.
2575 * lynx-low.cc (lynx_target_ops): Update.
2576 * nto-low.cc (nto_target_ops): Update.
2577 * win32-low.cc (win32_target_ops): Update.
2579 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2581 Turn process_stratum_target's supports_disable_randomization op
2582 into a method of process_target.
2584 * target.h (struct process_stratum_target): Remove the target op.
2585 (class process_target): Add the target op.
2586 (target_supports_disable_randomization): Update the macro.
2587 * target.cc (process_target::supports_disable_randomization): Define.
2589 Update the derived classes and callers below.
2591 * linux-low.cc (linux_target_ops): Update.
2592 (linux_supports_disable_randomization): Turn into ...
2593 (linux_process_target::supports_disable_randomization): ... this.
2594 * linux-low.h (class linux_process_target): Update.
2595 * lynx-low.cc (lynx_target_ops): Update.
2596 * nto-low.cc (nto_target_ops): Update.
2597 * win32-low.cc (win32_target_ops): Update.
2599 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2601 Turn process_stratum_target's emit_ops op into a method of
2604 * target.h (struct process_stratum_target): Remove the target op.
2605 (class process_target): Add the target op.
2606 (target_emit_ops): Update the macro.
2607 * target.cc (process_target::emit_ops): Define.
2609 Update the derived classes and callers below.
2611 * linux-low.cc (linux_target_ops): Update.
2612 (linux_emit_ops): Turn into ...
2613 (linux_process_target::emit_ops): ... this.
2614 * linux-low.h (class linux_process_target): Update.
2615 * lynx-low.cc (lynx_target_ops): Update.
2616 * nto-low.cc (nto_target_ops): Update.
2617 * win32-low.cc (win32_target_ops): Update.
2619 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2621 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2622 and get_min_fast_tracepoint_insn_len ops into methods of
2625 * target.h (struct process_stratum_target): Remove the target ops.
2626 (class process_target): Add the target ops. Also add
2627 'supports_fast_tracepoints'.
2628 (target_supports_fast_tracepoints): Update the macro.
2629 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2630 (install_fast_tracepoint_jump_pad): Update and rename the macro
2632 (target_install_fast_tracepoint_jump_pad): ... this.
2633 * target.cc (process_target::supports_fast_tracepoints): Define.
2634 (process_target::install_fast_tracepoint_jump_pad): Define.
2635 (process_target::get_min_fast_tracepoint_insn_len): Define.
2637 Update the derived classes and callers below.
2639 * tracepoint.cc (install_fast_tracepoint): Update.
2640 * linux-low.cc (linux_target_ops): Update.
2641 (linux_process_target::supports_fast_tracepoints): Define.
2642 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2643 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2644 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2645 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2646 * linux-low.h (class linux_process_target): Update.
2647 * lynx-low.cc (lynx_target_ops): Update.
2648 * nto-low.cc (nto_target_ops): Update.
2649 * win32-low.cc (win32_target_ops): Update.
2651 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2653 Turn process_stratum_target's stabilize_threads op into a
2654 method of process_target.
2656 * target.h (struct process_stratum_target): Remove the target op.
2657 (class process_target): Add the target op.
2658 (target_stabilize_threads): Update the macro.
2659 * target.cc (process_target::stabilize_threads): Define.
2661 Update the derived classes and callers below.
2663 * server.cc (handle_status): Update.
2664 * tracepoint.cc (cmd_qtdp): Update.
2665 (cmd_qtstart): Update.
2666 * linux-low.cc (linux_target_ops): Update.
2667 (linux_stabilize_threads): Turn into ...
2668 (linux_process_target::stabilize_threads): ... this.
2669 (linux_wait_1): Update.
2670 * linux-low.h (class linux_process_target): Update.
2671 * lynx-low.cc (lynx_target_ops): Update.
2672 * nto-low.cc (nto_target_ops): Update.
2673 * win32-low.cc (win32_target_ops): Update.
2675 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2677 Turn process_stratum_target's pause_all and unpause_all ops
2678 into methods of process_target.
2680 * target.h (struct process_stratum_target): Remove the target ops.
2681 (class process_target): Add the target ops.
2682 (pause_all): Update the macro and rename to...
2683 (target_pause_all): ... this.
2684 (unpause_all): Update the macro and rename to...
2685 (target_unpause_all): ... this.
2686 * target.cc (process_target::pause_all): Define.
2687 (process_target::unpause_all): Define.
2689 Update the derived classes and callers below.
2691 * server.cc (handle_status): Update.
2692 * tracepoint.cc (clear_installed_tracepoints): Update.
2694 (cmd_qtstart): Update.
2695 (stop_tracing): Update.
2696 (cmd_qtstatus): Update.
2697 (upload_fast_traceframes): Update.
2698 (run_inferior_command): Update.
2699 * linux-low.cc (linux_target_ops): Update.
2700 (linux_pause_all): Turn into ...
2701 (linux_process_target::pause_all): ... this.
2702 (linux_unpause_all): Turn into ...
2703 (linux_process_target::unpause_all): ... this.
2704 (linux_process_target::prepare_to_access_memory): Update.
2705 (linux_process_target::done_accessing_memory): Update.
2706 * linux-low.h (class linux_process_target): Update.
2707 * lynx-low.cc (lynx_target_ops): Update.
2708 * nto-low.cc (nto_target_ops): Update.
2709 * win32-low.cc (win32_target_ops): Update.
2711 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2713 Turn process_stratum_target's get_tib_address op into a method of
2716 * target.h (struct process_stratum_target): Remove the target op.
2717 (class process_target): Add the target op. Also add
2718 'supports_get_tib_address'.
2719 * target.cc (process_target::get_tib_address): Define.
2720 (process_target::supports_get_tib_address): Define.
2722 Update the derived classes and callers below.
2724 * server.cc (handle_query): Update.
2725 * linux-low.cc (win32_target_ops): Update.
2726 * lynx-low.cc (lynx_target_ops): Update.
2727 * nto-low.cc (nto_target_ops): Update.
2728 * win32-low.cc (win32_target_ops): Update.
2729 (win32_process_target::supports_get_tib_address): Define.
2730 (win32_get_tib_address): Turn into ...
2731 (win32_process_target::get_tib_address): ... this.
2732 * win32-low.h (class win32_process_target): Update.
2734 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2736 Turn process_stratum_target's thread_stopped op into a method of
2739 * target.h (struct process_stratum_target): Remove the target op.
2740 (class process_target): Add the target op. Also add
2741 'supports_thread_stopped'.
2742 (target_thread_stopped): Update the macro.
2743 * target.cc (process_target::thread_stopped): Define.
2744 (process_target::supports_thread_stopped): Define.
2745 (prepare_to_access_memory): Update.
2747 Update the derived classes and callers below.
2749 * server.cc (queue_stop_reply_callback): Update.
2750 * linux-low.cc (linux_target_ops): Update.
2751 (linux_process_target::supports_thread_stopped): Define.
2752 (linux_thread_stopped): Turn into ...
2753 (linux_process_target::thread_stopped): ... this.
2754 * linux-low.h (class linux_process_target): Update.
2755 * lynx-low.cc (lynx_target_ops): Update.
2756 * nto-low.cc (nto_target_ops): Update.
2757 * win32-low.cc (win32_target_ops): Update.
2759 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2761 Turn process_stratum_target's read_pc and write_pc ops into
2762 methods of process_target.
2764 * target.h (struct process_stratum_target): Remove the target ops.
2765 (class process_target): Add the target ops.
2766 * target.cc (process_target::read_pc): Define.
2767 (process_target::write_pc): Define.
2769 Update the derived classes and callers below.
2771 * regcache.cc (regcache_read_pc): Update.
2772 (regcache_write_pc): Update.
2773 * linux-low.cc (linux_target_ops): Update.
2774 (linux_read_pc): Turn into ...
2775 (linux_process_target::read_pc): ... this.
2776 (linux_write_pc): Turn into ...
2777 (linux_process_target::write_pc): ... this.
2778 * linux-low.h (class linux_process_target): Update.
2779 * lynx-low.cc (lynx_target_ops): Update.
2780 * nto-low.cc (nto_target_ops): Update.
2781 * win32-low.cc (win32_target_ops): Update.
2783 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2785 Turn process_stratum_target's supports_tracepoints op into a
2786 method of process_target.
2788 * target.h (struct process_stratum_target): Remove the target op.
2789 (class process_target): Add the target op.
2790 (target_supports_tracepoints): Update the macro.
2791 * target.cc (process_target::supports_tracepoints): Define.
2793 Update the derived classes and callers below.
2795 * linux-low.cc (linux_target_ops): Update.
2796 (linux_supports_tracepoints): Turn into ...
2797 (linux_process_target::supports_tracepoints): ... this.
2798 * linux-low.h (class linux_process_target): Update.
2799 * lynx-low.cc (lynx_target_ops): Update.
2800 * nto-low.cc (nto_target_ops): Update.
2801 * win32-low.cc (win32_target_ops): Update.
2803 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2805 Turn process_stratum_target's process_qsupported op into a method
2808 * target.h (struct process_stratum_target): Remove the target op.
2809 (class process_target): Add the target op.
2810 (target_process_qsupported): Update the macro.
2811 * target.cc (process_target::process_qsupported): Define.
2813 Update the derived classes and callers below.
2815 * linux-low.cc (linux_target_ops): Update.
2816 (linux_process_qsupported): Turn into ...
2817 (linux_process_target::process_qsupported): ... this.
2818 * linux-low.h (class linux_process_target): Update.
2819 * lynx-low.cc (lynx_target_ops): Update.
2820 * nto-low.cc (nto_target_ops): Update.
2821 * win32-low.cc (win32_target_ops): Update.
2823 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2825 Turn process_stratum_target's read_loadmap op into a method of
2828 * target.h (struct process_stratum_target): Remove the target op.
2829 (class process_target): Add the target op. Also add
2830 'supports_read_loadmap'.
2831 * target.cc (process_target::read_loadmap): Define.
2832 (process_target::supports_read_loadmap): Define.
2834 Update the derived classes and callers below.
2836 * server.cc (handle_qxfer_fdpic): Update.
2837 (handle_query): Update.
2838 * linux-low.cc (linux_target_ops): Update.
2839 (linux_process_target::supports_read_loadmap): Define.
2840 (linux_read_loadmap): Turn into ...
2841 (linux_process_target::read_loadmap): ... this.
2842 * linux-low.h (class linux_process_target): Update.
2843 * lynx-low.cc (lynx_target_ops): Update.
2844 * nto-low.cc (nto_target_ops): Update.
2845 * win32-low.cc (win32_target_ops): Update.
2847 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2849 Turn process_stratum_target's core_of_thread op into a method of
2852 * target.h (struct process_stratum_target): Remove the target op.
2853 (class process_target): Add the target op.
2854 (target_core_of_thread): Update the macro.
2855 * target.cc (process_target::core_of_thread): Define.
2857 Update the derived classes and callers below.
2859 * linux-low.cc (linux_target_ops): Update.
2860 (linux_process_target::core_of_thread): Define.
2861 * linux-low.h (class linux_process_target): Update.
2862 * lynx-low.cc (lynx_target_ops): Update.
2863 * nto-low.cc (nto_target_ops): Update.
2864 * win32-low.cc (win32_target_ops): Update.
2866 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2868 Turn process_stratum_target's handle_monitor_command op into a
2869 method of process_target.
2871 * target.h (struct process_stratum_target): Remove the target op.
2872 (class process_target): Add the target op.
2873 (target_handle_monitor_command): Update the macro.
2874 * target.cc (process_target::handle_monitor_command): Define.
2876 Update the derived classes and callers below.
2878 * server.cc (handle_query): Update.
2879 * linux-low.cc (linux_target_ops): Update.
2880 (linux_process_target::handle_monitor_command): Define.
2881 * linux-low.h (class linux_process_target): Update.
2882 * lynx-low.cc (lynx_target_ops): Update.
2883 * nto-low.cc (nto_target_ops): Update.
2884 * win32-low.cc (win32_target_ops): Update.
2886 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2888 Turn process_stratum_target's handle_new_gdb_connection op into a
2889 method of process_target.
2891 * target.h (struct process_stratum_target): Remove the target op.
2892 (class process_target): Add the target op.
2893 (target_handle_new_gdb_connection): Update the macro.
2894 * target.cc (process_target::handle_new_gdb_connection): Define.
2896 Update the derived classes and callers below.
2898 * linux-low.cc (linux_target_ops): Update.
2899 (linux_handle_new_gdb_connection): Turn into ...
2900 (linux_process_target::handle_new_gdb_connection): ... this.
2901 * linux-low.h (class linux_process_target): Update.
2902 * lynx-low.cc (lynx_target_ops): Update.
2903 * nto-low.cc (nto_target_ops): Update.
2904 * win32-low.cc (win32_target_ops): Update.
2906 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2908 Turn process_stratum_target's supports_fork_events,
2909 supports_vfork_events, and supports_exec_events ops into methods
2912 * target.h (struct process_stratum_target): Remove the target ops.
2913 (class process_target): Add the target ops.
2914 (target_supports_fork_events): Update the macro.
2915 (target_supports_vfork_events): Update the macro.
2916 (target_supports_exec_events): Update the macro.
2917 * target.cc (process_target::supports_fork_events): Define.
2918 (process_target::supports_vfork_events): Define.
2919 (process_target::supports_exec_events): Define.
2921 Update the derived classes and callers below.
2923 * linux-low.cc (linux_target_ops): Update.
2924 (linux_supports_fork_events): Turn into ...
2925 (linux_process_target::supports_fork_events): ... this.
2926 (linux_supports_vfork_events): Turn into ...
2927 (linux_process_target::supports_vfork_events): ... this.
2928 (linux_supports_exec_events): Turn into ...
2929 (linux_process_target::supports_exec_events): ... this.
2930 * linux-low.h (class linux_process_target): Update.
2931 * lynx-low.cc (lynx_target_ops): Update.
2932 * nto-low.cc (nto_target_ops): Update.
2933 * win32-low.cc (win32_target_ops): Update.
2935 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2937 Turn process_stratum_target's supports_multi_process op into a
2938 method of process_target.
2940 * target.h (struct process_stratum_target): Remove the target op.
2941 (class process_target): Add the target op.
2942 * target.cc (process_target::supports_multi_process): Define.
2943 (target_supports_multi_process): Update.
2945 Update the derived classes and callers below.
2947 * linux-low.cc (linux_target_ops): Update.
2948 (linux_supports_multi_process): Turn into ...
2949 (linux_process_target::supports_multi_process): ... this.
2950 * linux-low.h (class linux_process_target): Update.
2951 * lynx-low.cc (lynx_target_ops): Update.
2952 * nto-low.cc (nto_target_ops): Update.
2953 * win32-low.cc (win32_target_ops): Update.
2955 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2957 Turn process_stratum_target's supports_non_stop, async, and
2958 start_non_stop ops into methods of process_target.
2960 * target.h (struct process_stratum_target): Remove the target ops.
2961 (class process_target): Add the target ops.
2962 (target_supports_non_stop): Update the macro.
2963 (target_async): Update the macro.
2964 (start_non_stop): Remove declaration.
2965 * target.cc (process_target::supports_non_stop): Define.
2966 (process_target::async): Define.
2967 (process_target::start_non_stop): Define.
2968 (start_non_stop): Remove.
2970 Update the derived classes and callers below.
2972 * server.cc (handle_qxfer_siginfo): Update.
2973 (handle_query): Update.
2974 * linux-low.cc (linux_target_ops): Update.
2975 (linux_supports_non_stop): Turn into ...
2976 (linux_process_target::supports_non_stop): ... this.
2977 (linux_async): Turn into ...
2978 (linux_process_target::async): ... this.
2979 (linux_start_non_stop): Turn into ...
2980 (linux_process_target::start_non_stop): ... this.
2981 * linux-low.h (class linux_process_target): Update.
2982 * lynx-low.cc (lynx_target_ops): Update.
2983 * nto-low.cc (nto_target_ops): Update.
2984 (nto_supports_non_stop): Remove; rely on the default behavior
2986 * win32-low.cc (win32_target_ops): Update.
2988 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2990 Turn process_stratum_target's qxfer_siginfo op into a method of
2993 * target.h (struct process_stratum_target): Remove the target op.
2994 (class process_target): Add the target op. Also add
2995 'supports_qxfer_siginfo'.
2996 * target.cc (process_target::qxfer_siginfo): Define.
2997 (process_target::supports_qxfer_siginfo): Define.
2999 Update the derived classes and callers below.
3001 * server.cc (handle_qxfer_siginfo): Update.
3002 (handle_query): Update.
3003 * linux-low.cc (linux_target_ops): Update.
3004 (linux_process_target::supports_qxfer_siginfo): Define.
3005 (linux_xfer_siginfo): Turn into ...
3006 (linux_process_target::qxfer_siginfo): ... this.
3007 * linux-low.h (class linux_process_target): Update.
3008 * lynx-low.cc (lynx_target_ops): Update.
3009 * nto-low.cc (nto_target_ops): Update.
3010 * win32-low.cc (win32_target_ops): Update.
3012 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3014 Turn process_stratum_target's qxfer_osdata op into a method of
3017 * target.h (struct process_stratum_target): Remove the target op.
3018 (class process_target): Add the target op. Also add
3019 'supports_qxfer_osdata'.
3020 * target.cc (process_target::qxfer_osdata): Define.
3021 (process_target::supports_qxfer_osdata): Define.
3023 Update the derived classes and callers below.
3025 * server.cc (handle_qxfer_osdata): Update.
3026 (handle_query): Update.
3027 * linux-low.cc (linux_target_ops): Update.
3028 (linux_process_target::supports_qxfer_osdata): Define.
3029 (linux_qxfer_osdata): Turn into ...
3030 (linux_process_target::qxfer_osdata): ... this.
3031 * linux-low.h (class linux_process_target): Update.
3032 * lynx-low.cc (lynx_target_ops): Update.
3033 * nto-low.cc (nto_target_ops): Update.
3034 * win32-low.cc (win32_target_ops): Update.
3036 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3038 Turn process_stratum_target's hostio_last_error op into a
3039 method of process_target.
3041 * target.h (struct process_stratum_target): Remove the target op.
3042 (class process_target): Add the target op.
3043 * target.cc: Add "hostio.h" to includes.
3044 (process_target::hostio_last_error): Define.
3046 Update the derived classes and callers below.
3048 * hostio.cc (hostio_error): Update.
3049 * linux-low.cc: Remove "hostio.h" from includes.
3050 (linux_target_ops): Update.
3051 * lynx-low.cc (lynx_target_ops): Update.
3052 * nto-low.cc (nto_target_ops): Update.
3053 * win32-low.h (class win32_process_target): Update.
3054 * win32-low.cc (win32_target_ops): Update.
3055 (wince_hostio_last_error): Turn into ...
3056 (win32_process_target::hostio_last_error): ... this.
3058 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3060 Turn process_stratum_target's get_tls_address op into a method of
3063 * target.h (struct process_stratum_target): Remove the target op.
3064 (class process_target): Add the target op. Also add
3065 'supports_get_tls_address'.
3066 * target.cc (process_target::get_tls_address): Define.
3067 (process_target::supports_get_tls_address): Define.
3069 Update the derived classes and callers below.
3071 * server.cc (handle_query): Update.
3072 * linux-low.cc (linux_target_ops): Update.
3073 (linux_process_target::supports_get_tls_address): Define.
3074 (linux_process_target::get_tls_address): Define.
3075 * linux-low.h (class linux_process_target): Update.
3076 * lynx-low.cc (lynx_target_ops): Update.
3077 * nto-low.cc (nto_target_ops): Update.
3078 * win32-low.cc (win32_target_ops): Update.
3080 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3082 Turn process_stratum_target's read_offsets op into a method of
3085 * target.h (struct process_stratum_target): Remove the target op.
3086 (class process_target): Add the target op. Also add
3087 'supports_read_offsets'.
3088 * target.cc (process_target::read_offsets): Define.
3089 (process_target::supports_read_offsets): Define.
3091 Update the derived classes and callers below.
3093 * server.cc (handle_query): Update.
3094 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3095 (linux_target_ops): Update.
3096 (linux_process_target::supports_read_offsets): Define.
3097 (linux_read_offsets): Turn into ...
3098 (linux_process_target::read_offsets): ... this.
3099 * linux-low.h (class linux_process_target): Update.
3100 * lynx-low.cc (lynx_target_ops): Update.
3101 * nto-low.cc (nto_target_ops): Update.
3102 * win32-low.cc (win32_target_ops): Update.
3104 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3106 Turn process_stratum_target's stopped_by_watchpoint and
3107 stopped_data_address ops into methods of process_target.
3109 * target.h (struct process_stratum_target): Remove the target ops.
3110 (class process_target): Add the target ops.
3111 * target.cc (process_target::stopped_by_watchpoint): Define.
3112 (process_target::stopped_data_address): Define.
3114 Update the derived classes and callers below.
3116 * remote-utils.cc (prepare_resume_reply): Update.
3117 * linux-low.cc (linux_target_ops): Update.
3118 (linux_stopped_by_watchpoint): Turn into ...
3119 (linux_process_target::stopped_by_watchpoint): ... this.
3120 (linux_stopped_data_address): Turn into ...
3121 (linux_process_target::stopped_data_address): ... this.
3122 * linux-low.h (class linux_process_target): Update.
3123 * lynx-low.cc (lynx_target_ops): Update.
3124 * nto-low.cc (nto_target_ops): Update.
3125 (nto_stopped_by_watchpoint): Turn into ...
3126 (nto_process_target::stopped_by_watchpoint): ... this.
3127 (nto_stopped_data_address): Turn into ...
3128 (nto_process_target::stopped_data_address): ... this.
3129 * nto-low.h (class nto_process_target): Update.
3130 * win32-low.cc (win32_target_ops): Update.
3131 (win32_stopped_by_watchpoint): Turn into ...
3132 (win32_process_target::stopped_by_watchpoint): ... this.
3133 (win32_stopped_data_address): Turn into ...
3134 (win32_process_target::stopped_data_address): ... this.
3135 * win32-low.h (class win32_process_target): Update.
3137 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3139 Turn process_stratum_target's supports_hardware_single_step op into
3140 a method of process_target.
3142 * target.h (struct process_stratum_target): Remove the target op.
3143 (class process_target): Add the target op.
3144 (target_supports_hardware_single_step): Update the macro.
3145 (target_can_do_hardware_single_step): Remove declaration.
3146 * target.cc (process_target::supports_hardware_single_step): Define.
3147 (target_can_do_hardware_single_step): Remove.
3149 Update the derived classes and callers below.
3151 * linux-low.h (class linux_process_target): Update.
3152 * linux-low.cc (linux_target_ops): Update.
3153 (linux_supports_hardware_single_step): Turn into ...
3154 (linux_process_target::supports_hardware_single_step): ... this.
3155 * lynx-low.h (class lynx_process_target): Update.
3156 * lynx-low.cc (lynx_target_ops): Update.
3157 (lynx_process_target::supports_hardware_single_step): Define.
3158 * nto-low.h (class nto_process_target): Update.
3159 * nto-low.cc (nto_target_ops): Update.
3160 (nto_process_target::supports_hardware_single_step): Define.
3161 * win32-low.h (class win32_process_target): Update.
3162 * win32-low.cc (win32_target_ops): Update.
3163 (win32_process_target::supports_hardware_single_step): Define.
3165 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3167 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3168 ops into methods of process_target.
3170 * target.h (struct process_stratum_target): Remove the target ops.
3171 (class process_target): Add the target ops.
3172 (target_stopped_by_hw_breakpoint): Update the macro.
3173 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3174 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3175 (process_target::supports_stopped_by_hw_breakpoint): Define.
3177 Update the derived classes and callers below.
3179 * linux-low.cc (linux_target_ops): Update.
3180 (linux_stopped_by_hw_breakpoint): Turn into ...
3181 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3182 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3183 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3184 * linux-low.h (class linux_process_target): Update.
3185 * lynx-low.cc (lynx_target_ops): Update.
3186 * nto-low.cc (nto_target_ops): Update.
3187 * win32-low.cc (win32_target_ops): Update.
3189 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3191 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3192 ops into methods of process_target.
3194 * target.h (struct process_stratum_target): Remove the target ops.
3195 (class process_target): Add the target ops.
3196 (target_stopped_by_sw_breakpoint): Update the macro.
3197 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3198 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3199 (process_target::supports_stopped_by_sw_breakpoint): Define.
3201 Update the derived classes and callers below.
3203 * linux-low.cc (linux_target_ops): Update.
3204 (linux_stopped_by_sw_breakpoint): Turn into ...
3205 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3206 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3207 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3208 * linux-low.h (class linux_process_target): Update.
3209 * lynx-low.cc (lynx_target_ops): Update.
3210 * nto-low.cc (nto_target_ops): Update.
3211 * win32-low.cc (win32_target_ops): Update.
3213 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3215 Turn process_stratum_target's insert_point and remove_point ops
3216 into methods of process_target.
3218 * target.h (struct process_stratum_target): Remove the target ops.
3219 (class process_target): Add the target ops.
3220 * target.cc (process_target::insert_point): Define.
3221 (process_target::remove_point): Define.
3223 Update the derived classes and callers below.
3225 * mem-break.cc (set_raw_breakpoint_at): Update.
3226 (delete_raw_breakpoint): Update.
3227 (uninsert_raw_breakpoint): Update.
3228 (reinsert_raw_breakpoint): Update.
3229 * linux-low.cc (linux_target_ops): Update.
3230 (linux_insert_point): Turn into ...
3231 (linux_process_target::insert_point): ... this.
3232 (linux_remove_point): Turn into ...
3233 (linux_process_target::remove_point): ... this.
3234 * linux-low.h (class linux_process_target): Update.
3235 * lynx-low.cc (lynx_target_ops): Update.
3236 * nto-low.cc (nto_target_ops): Update.
3237 (nto_insert_point): Turn into ...
3238 (nto_process_target::insert_point): ... this.
3239 (nto_remove_point): Turn into ...
3240 (nto_process_target::remove_point): ... this.
3241 * nto-low.h (class nto_process_target): Update.
3242 * win32-low.cc (win32_target_ops): Update.
3243 (win32_insert_point): Turn into ...
3244 (win32_process_target::insert_point): ... this.
3245 (win32_remove_point): Turn into ...
3246 (win32_process_target::remove_point): ... this.
3247 * win32-low.h (class win32_process_target): Update.
3249 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3251 Turn process_stratum_target's supports_z_point_type op into a
3252 method of process_target.
3254 * target.h (struct process_stratum_target): Remove the target op.
3255 (class process_target): Add the target op.
3256 * target.cc (process_target::supports_z_point_type): Define.
3258 Update the derived classes and callers below.
3260 * mem-break.cc (z_type_supported): Update.
3261 * linux-low.cc (linux_target_ops): Update.
3262 (linux_supports_z_point_type): Turn into ...
3263 (linux_process_target::supports_z_point_type): ... this.
3264 * linux-low.h (class linux_process_target): Update.
3265 * lynx-low.cc (lynx_target_ops): Update.
3266 * nto-low.cc (nto_target_ops): Update.
3267 (nto_supports_z_point_type): Turn into ...
3268 (nto_process_target::supports_z_point_type): ... this.
3269 * nto-low.h (class nto_process_target): Update.
3270 * win32-low.cc (win32_target_ops): Update.
3271 (win32_supports_z_point_type): Turn into ...
3272 (win32_process_target::supports_z_point_type): ... this.
3273 * win32-low.h (class win32_process_target): Update.
3275 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3277 Turn process_stratum_target's read_auxv op into a method of
3280 * target.h (class process_stratum_target): Remove the target op.
3281 (struct process_target): Add the target op. Also add
3282 'supports_read_auxv'.
3283 * target.cc (process_target::read_auxv): Define.
3284 (process_target::supports_read_auxv): Define.
3286 Update the derived classes and callers below.
3288 * server.cc (handle_qxfer_auxv): Update.
3289 (handle_query): Update.
3290 * linux-low.cc (linux_target_ops): Update.
3291 (linux_process_target::supports_read_auxv): Define.
3292 (linux_read_auxv): Turn into ...
3293 (linux_process_target::read_auxv): ... this.
3294 * linux-low.h (class linux_process_target): Update.
3295 * lynx-low.cc (lynx_target_ops): Update.
3296 * nto-low.cc (nto_target_ops): Update.
3297 (nto_process_target::supports_read_auxv): Define.
3298 (nto_read_auxv): Turn into ...
3299 (nto_process_target::read_auxv): ... this.
3300 * nto-low.h (class nto_process_target): Update.
3301 * win32-low.cc (win32_target_ops): Update.
3303 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3305 Turn process_stratum_target's request_interrupt op into a method of
3308 * target.h (struct process_stratum_target): Remove the target op.
3309 (class process_target): Add the target op.
3311 Update the derived classes and callers below.
3313 * remote-utils.cc (putpkt_binary_1): Update.
3314 (input_interrupt): Update.
3316 * server.cc (handle_v_requests): Update.
3317 * linux-low.cc (linux_target_ops): Update.
3318 (linux_request_interrupt): Turn into ...
3319 (linux_process_target::request_interrupt): ... this.
3320 * linux-low.h (class linux_process_target): Update.
3321 * lynx-low.cc (lynx_target_ops): Update.
3322 (lynx_request_interrupt): Turn into ...
3323 (lynx_process_target::request_interrupt): ... this.
3324 * lynx-low.h (class lynx_process_target): Update.
3325 * nto-low.cc (nto_target_ops): Update.
3326 (nto_request_interrupt): Turn into ...
3327 (nto_process_target::request_interrupt): ... this.
3328 * nto-low.h (class nto_process_target): Update.
3329 * win32-low.cc (win32_target_ops): Update.
3330 (win32_request_interrupt): Turn into ...
3331 (win32_process_target::request_interrupt): ... this.
3332 * win32-low.h (class win32_process_target): Update.
3334 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3336 Turn process_stratum_target's look_up_symbols op into a method of
3339 * target.h (struct process_stratum_target): Remove the target op.
3340 (class process_target): Add the target op.
3341 * target.cc (process_target::look_up_symbols): Define.
3343 Update the derived classes and callers below.
3345 * server.cc (handle_query): Update.
3346 * linux-low.cc (linux_target_ops): Update.
3347 (linux_look_up_symbols): Turn into ...
3348 (linux_process_target::look_up_symbols): ... this.
3349 * linux-low.h (class linux_process_target): Update.
3350 * lynx-low.cc (lynx_target_ops): Update.
3351 * nto-low.cc (nto_target_ops): Update.
3352 * win32-low.cc (win32_target_ops): Update.
3354 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3356 Turn process_stratum_target's read_memory and write_memory
3357 ops into methods of process_target.
3359 * target.h (struct process_stratum_target): Remove the target ops.
3360 (class process_target): Add the target ops.
3362 Update the derived classes and callers below.
3364 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3365 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3366 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3367 (arm_get_syscall_trapinfo): Update.
3368 * linux-cris-low.cc (cris_breakpoint_at): Update.
3369 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3370 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3371 * linux-mips-low.cc (mips_breakpoint_at): Update.
3372 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3373 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3374 * linux-sh-low.cc (sh_breakpoint_at): Update.
3375 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3376 (sparc_store_gregset_from_stack): Update.
3377 (sparc_breakpoint_at): Update.
3378 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3379 * linux-tile-low.cc (tile_breakpoint_at): Update.
3380 * linux-x86-low.cc (x86_breakpoint_at): Update.
3381 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3382 * mem-brea.cc (insert_memory_breakpoint): Update.
3383 (validate_inserted_breakpoint): Update.
3384 * target.cc (read_inferior_memory): Update.
3385 (target_write_memory): Update.
3386 * linux-low.cc (linux_target_ops): Update.
3387 (linux_read_memory): Make a wrapper around the read_memory target
3389 (linux_process_target::read_memory): Rename from linux_read_memory.
3390 (linux_write_memory): Turn into ...
3391 (linux_process_target::write_memory): ... this.
3392 * linux-low.h (class linux_process_target): Update.
3393 * lynx-low.cc (lynx_target_ops): Update.
3394 (lynx_read_memory): Turn into ...
3395 (lynx_process_target::read_memory): ... this.
3396 (lynx_write_memory): Turn into ...
3397 (lynx_process_target::write_memory): ... this.
3398 * lynx-low.h (class lynx_process_target): Update.
3399 * nto-low.cc (nto_target_ops): Update.
3400 (nto_read_memory): Turn into ...
3401 (nto_process_target::read_memory): ... this.
3402 (nto_write_memory): Turn into ...
3403 (nto_process_target::write_memory): ... this.
3404 * nto-low.h (class nto_process_target): Update.
3405 * win32-low.cc (win32_target_ops): Update.
3406 (win32_read_inferior_memory): Turn into ...
3407 (win32_process_target::read_memory): ... this.
3408 (win32_write_inferior_memory): Turn into ...
3409 (win32_process_target::write_memory): ... this.
3410 * win32-low.h (class win32_process_target): Update.
3412 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3414 Turn process_stratum_target's prepare_to_access_memory and
3415 done_accessing_memory ops into methods of process_target.
3417 * target.h (struct process_stratum_target): Remove the target ops.
3418 (class process_target): Add the target ops.
3419 * target.cc (process_target::prepare_to_access_memory): Define.
3420 (process_target::done_accessing_memory): Define.
3421 (prepare_to_access_memory): Update.
3422 (done_accessing_memory): Update.
3424 Update the derived classes and callers below.
3426 * linux-low.cc (linux_target_ops): Update.
3427 (linux_prepare_to_access_memory): Turn into ...
3428 (linux_process_target::prepare_to_access_memory): ... this.
3429 (linux_done_accessing_memory): Turn into ...
3430 (linux_process_target::done_accessing_memory): ... this.
3431 * linux-low.h (class linux_process_target): Update.
3432 * lynx-low.cc (lynx_target_ops): Update.
3433 * nto-low.cc (nto_target_ops): Update.
3434 * win32-low.cc (win32_target_ops): Update.
3436 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3438 Turn process_stratum_target's fetch_registers and store_registers
3439 ops into methods of process_target.
3441 * target.h (struct process_stratum_target): Remove the target ops.
3442 (class process_target): Add the target ops.
3443 (fetch_inferior_registers): Update the macro.
3444 (store_inferior_registers): Update the macro.
3446 Update the derived classes and callers below.
3448 * linux-low.cc (linux_target_ops): Update.
3449 (linux_fetch_registers): Turn into ...
3450 (linux_process_target::fetch_registers): ... this.
3451 (linux_store_registers): Turn into ...
3452 (linux_process_target::store_registers): ... this.
3453 * linux-low.h (class linux_process_target): Update.
3454 * lynx-low.cc (lynx_target_ops): Update.
3455 (lynx_fetch_registers): Turn into ...
3456 (lynx_process_target::fetch_registers): ... this.
3457 (lynx_store_registers): Turn into ...
3458 (lynx_process_target::store_registers): ... this.
3459 * lynx-low.h (class lynx_process_target): Update.
3460 * nto-low.cc (nto_target_ops): Update.
3461 (nto_fetch_registers): Turn into ...
3462 (nto_process_target::fetch_registers): ... this.
3463 (nto_store_registers): Turn into ...
3464 (nto_process_target::store_registers): ... this.
3465 * nto-low.h (class nto_process_target): Update.
3466 * win32-low.cc (win32_target_ops): Update.
3467 (win32_fetch_inferior_registers): Turn into ...
3468 (win32_process_target::fetch_registers): ... this.
3469 (win32_store_inferior_registers): Turn into ...
3470 (win32_process_target::store_registers): ... this.
3471 * win32-low.h (class win32_process_target): Update.
3473 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3475 Turn process_stratum_target's wait op into a method of
3478 * target.h (struct process_stratum_target): Remove the target op.
3479 (class process_target): Add the target op.
3481 Update the derived classes and callers below.
3483 * target.cc (target_wait): Update.
3484 * linux-low.cc (linux_target_ops): Update.
3485 (linux_wait): Turn into ...
3486 (linux_process_target::wait): ... this.
3487 * linux-low.h (class linux_process_target): Update.
3488 * lynx-low.cc (lynx_target_ops): Update.
3489 (lynx_wait): Turn into ...
3490 (lynx_process_target::wait): ... this.
3491 * lynx-low.h (class lynx_process_target): Update.
3492 * nto-low.cc (nto_target_ops): Update.
3493 (nto_wait): Turn into ...
3494 (nto_process_target::wait): ... this.
3495 * nto-low.h (class nto_process_target): Update.
3496 * win32-low.cc (win32_target_ops): Update.
3497 (win32_wait): Turn into ...
3498 (win32_process_target::wait): ... this.
3499 (do_initial_child_stuff): Update.
3500 * win32-low.h (class win32_process_target): Update.
3502 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3504 Turn process_stratum_target's resume op into a method of
3507 * target.h (struct process_stratum_target): Remove the target op.
3508 (class process_target): Add the target op.
3510 Update the derived classes and callers below.
3512 * server.cc (resume): Update.
3513 * target.cc (target_stop_and_wait): Update.
3514 (target_continue_no_signal): Update.
3515 (target_continue): Update.
3516 * linux-low.cc (linux_target_ops): Update.
3517 (linux_resume): Turn into ...
3518 (linux_process_target::resume): ... this.
3519 * linux-low.h (class linux_process_target): Update.
3520 * lynx-low.cc (lynx_target_ops): Update.
3521 (lynx_resume): Turn into ...
3522 (lynx_process_target::resume): ... this.
3523 * lynx-low.h (class lynx_process_target): Update.
3524 * nto-low.cc (nto_target_ops): Update.
3525 (nto_resume): Turn into ...
3526 (nto_process_target::resume): ... this.
3527 * nto-low.h (class nto_process_target): Update.
3528 * win32-low.cc (win32_target_ops): Update.
3529 (win32_resume): Turn into ...
3530 (win32_process_target::resume): ... this.
3531 (win32_process_target::detach): Update.
3532 (do_initial_child_stuff): Update.
3533 * win32-low.h (class win32_process_target): Update.
3535 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3537 Turn process_stratum_target's thread_alive op into a method of
3540 * target.h (struct process_stratum_target): Remove the target op.
3541 (class process_target): Add the target op.
3542 (mythread_alive): Update the macro.
3544 Update the derived classes and callers below.
3546 * linux-low.cc (linux_target_ops): Update.
3547 (linux_thread_alive): Turn into ...
3548 (linux_process_target::thread_alive): ... this.
3549 (wait_for_sigstop): Update.
3550 * linux-low.h (class linux_process_target): Update.
3551 * lynx-low.cc (lynx_target_ops): Update.
3552 (lynx_thread_alive): Turn into ...
3553 (lynx_process_target::thread_alive): ... this.
3554 * lynx-low.h (class lynx_process_target): Update.
3555 * nto-low.cc (nto_target_ops): Update.
3556 (nto_thread_alive): Turn into ...
3557 (nto_process_target::thread_alive): ... this.
3558 * nto-low.h (class nto_process_target): Update.
3559 * win32-low.cc (win32_target_ops): Update.
3560 (win32_thread_alive): Turn into ...
3561 (win32_process_target::thread_alive): ... this.
3562 * win32-low.h (class win32_process_target): Update.
3564 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3566 Turn process_stratum_target's join op into a method of
3569 * target.h (struct process_stratum_target): Remove the target op.
3570 (class process_target): Add the target op.
3571 (join_inferior): Update the macro.
3573 Update the derived classes and callers below.
3575 * linux-low.cc (linux_target_ops): Update.
3576 (linux_join): Turn into ...
3577 (linux_process_target::join): ... this.
3578 * linux-low.h (class linux_process_target): Update.
3579 * lynx-low.cc (lynx_target_ops): Update.
3580 (lynx_join): Turn into ...
3581 (lynx_process_target::join): ... this.
3582 * lynx-low.h (class lynx_process_target): Update.
3583 * nto-low.cc (nto_target_ops): Update.
3584 (nto_process_target::join): Define.
3585 * nto-low.h (class nto_process_target): Update.
3586 * win32-low.cc (win32_target_ops): Update.
3587 (win32_join): Turn into ...
3588 (win32_process_target::join): ... this.
3589 * win32-low.h (class win32_process_target): Update.
3591 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3593 Turn process_stratum_target's mourn op into a method of
3596 * target.h (struct process_stratum_target): Remove the target op.
3597 (class process_target): Add the target op.
3599 Update the derived classes and callers below.
3601 * target.cc (target_mourn_inferior): Update.
3602 * linux-low.cc (linux_target_ops): Update.
3603 (linux_mourn): Turn into ...
3604 (linux_process_target::mourn): ... this.
3605 (handle_extended_wait): Update.
3606 (linux_process_target::kill): Update.
3607 (linux_process_target::detach): Update.
3608 * linux-low.h (class linux_process_target): Update.
3609 * lynx-low.cc (lynx_target_ops): Update.
3610 (lynx_mourn): Turn into ...
3611 (lynx_process_target::mourn): ... this.
3612 * lynx-low.h (class lynx_process_target): Update.
3613 * nto-low.cc (nto_target_ops): Update.
3614 (nto_mourn): Turn into ...
3615 (nto_process_target::mourn): ... this.
3616 * nto-low.h (class nto_process_target): Update.
3617 * win32-low.cc (win32_target_ops): Update.
3618 (win32_mourn): Turn into ...
3619 (win32_process_target::mourn): ... this.
3620 * win32-low.h (class win32_process_target): Update.
3622 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3624 Turn process_stratum_target's detach op into a method of
3627 * target.h (struct process_stratum_target): Remove the target op.
3628 (class process_target): Add the target op.
3629 (detach_inferior): Update the macro.
3631 Update the derived classes and callers below.
3633 * linux-low.cc (linux_target_ops): Update.
3634 (linux_detach): Turn into ...
3635 (linux_process_target::detach): ... this.
3636 * linux-low.h (class linux_process_target): Update.
3637 * lynx-low.cc (lynx_target_ops): Update.
3638 (lynx_detach): Turn into ...
3639 (lynx_process_target::detach): ... this.
3640 * lynx-low.h (class lynx_process_target): Update.
3641 * nto-low.cc (nto_target_ops): Update.
3642 (nto_detach): Turn into ...
3643 (nto_process_target::detach): ... this.
3644 * nto-low.h (class nto_process_target): Update.
3645 * win32-low.cc (win32_target_ops): Update.
3646 (win32_detach): Turn into ...
3647 (win32_process_target::detach): ... this.
3648 * win32-low.h (class win32_process_target): Update.
3650 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3652 Turn process_stratum_target's kill op into a method of
3655 * target.h (struct process_stratum_target): Remove the target op.
3656 (class process_target): Add the target op.
3658 Update the derived classes and callers below.
3660 * target.cc (kill_inferior): Update.
3661 * linux-low.cc (linux_target_ops): Update.
3662 (linux_kill): Turn into ...
3663 (linux_process_target::kill): ... this.
3664 * linux-low.h (class linux_process_target): Update.
3665 * lynx-low.cc (lynx_target_ops): Update.
3666 (lynx_kill): Turn into ...
3667 (lynx_process_target::kill): ... this.
3668 * lynx-low.h (class lynx_process_target): Update.
3669 * nto-low.cc (nto_target_ops): Update.
3670 (nto_kill): Turn into ...
3671 (nto_process_target::kill): ... this.
3672 * nto-low.h (class nto_process_target): Update.
3673 * win32-low.cc (win32_target_ops): Update.
3674 (win32_kill): Turn into ...
3675 (win32_process_target::kill): ... this.
3676 * win32-low.h (class win32_process_target): Update.
3678 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3680 Turn process_stratum_target's attach op into a method of
3683 * target.h (struct process_stratum_target): Remove the target op.
3684 (class process_target): Add the target op.
3685 (myattach): Update the macro.
3687 Update the derived classes and callers below.
3689 * linux-low.cc (linux_target_ops): Update.
3690 (linux_attach): Turn into ...
3691 (linux_process_target::attach): ... this.
3692 * linux-low.h (class linux_process_target): Update.
3693 * lynx-low.cc (lynx_target_ops): Update.
3694 (lynx_attach): Turn into ...
3695 (lynx_process_target::attach): ... this.
3696 * lynx-low.h (class lynx_process_target): Update.
3697 * nto-low.cc (nto_target_ops): Update.
3698 (nto_attach): Turn into ...
3699 (nto_process_target::attach): ... this.
3700 * nto-low.h (class nto_process_target): Update.
3701 * win32-low.cc (win32_target_ops): Update.
3702 (win32_attach): Turn into ...
3703 (win32_process_target::attach): ... this.
3704 * win32-low.h (class win32_process_target): Update.
3706 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3708 Turn process_stratum_target's post_create_inferior op into a method
3711 * target.h (struct process_stratum_target): Remove the target op.
3712 (class process_target): Add the target op.
3713 (target_post_create_inferior): Update the macro.
3714 * target.cc (process_target::post_create_inferior): Define.
3716 Update the derived classes and callers below.
3718 * linux-low.cc (linux_target_ops): Update.
3719 (linux_post_create_inferior): Turn into ...
3720 (linux_process_target::post_create_inferior): ... this.
3721 * linux-low.h (class linux_process_target): Update.
3722 * lynx-low.cc (lynx_target_ops): Update.
3723 * nto-low.cc (nto_target_ops): Update.
3724 * win32-low.cc (win32_target_ops): Update.
3726 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3728 Turn process_stratum_target's create_inferior op into a method of
3731 * target.h (struct process_stratum_target): Remove the target op.
3732 (class process_target): Add the target op.
3733 (create_inferior): Rename the macro to ...
3734 (target_create_inferior): ... this.
3736 Update the derived classes and callers below.
3738 * server.cc (handle_v_run): Update.
3739 (captured_main): Update.
3740 (process_serial_event): Update.
3741 * linux-low.cc (linux_target_ops): Update.
3742 (linux_create_inferior): Turn into ...
3743 (linux_process_target::create_inferior): ... this.
3744 * linux-low.h (class linux_process_target): Update.
3745 * lynx-low.cc (lynx_target_ops): Update.
3746 (lynx_create_inferior): Turn into ...
3747 (lynx_process_target::create_inferior): ... this.
3748 * lynx-low.h (class lynx_process_target): Update.
3749 * nto-low.cc (nto_target_ops): Update.
3750 (nto_create_inferior): Turn into ...
3751 (nto_process_target::create_inferior): ... this.
3752 * nto-low.h (class nto_process_target): Update.
3753 * win32-low.cc (win32_target_ops): Update.
3754 (win32_create_inferior): Turn into ...
3755 (win32_process_target::create_inferior): ... this.
3756 * win32-low.h (class win32_process_target): Update.
3758 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3760 * target.h (class process_target): New class definition.
3761 (struct process_stratum_target) <pt>: New field with type
3763 * linux-low.h (class linux_process_target): Define as a derived
3764 class of 'process_target'.
3765 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3767 * lynx-low.h (class lynx_process_target): Define as a derived
3768 class of 'process_target'.
3769 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3771 * nto-low.h (class nto_process_target): Define as a derived
3772 class of 'process_target'.
3773 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3775 * win32-low.h (class win32_process_target): Define as a derived
3776 class of 'process_target'.
3777 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3780 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3782 * configure: Regenerate.
3784 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
3785 Andrew Burgess <andrew.burgess@embecosm.com>
3787 * linux-riscv-low.cc: New file.
3788 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3789 and nat/riscv-linux-tdesc.c.
3790 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3791 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3794 2020-02-14 Tom Tromey <tom@tromey.com>
3796 * acinclude.m4: Don't include acx_configure_dir.m4.
3797 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3798 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3799 (all, install-only, uninstall, clean-info, clean)
3800 (maintainer-clean): Don't recurse.
3801 (subdir_do, all-lib): Remove.
3802 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3804 (generated_files): Update.
3805 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3806 * configure: Rebuild.
3807 * configure.ac: Don't configure gnulib or libiberty.
3810 2020-02-14 Eli Zaretskii <eliz@gnu.org>
3812 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3813 preparing the command line for CreateProcess.
3814 (win32_create_inferior): Reflect the program name in debugging
3815 output that shows the process and its command line.
3817 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3819 * Makefile.in: Rename source files from .c to .cc.
3820 * %.c: Rename to %.cc.
3821 * configure.ac: Rename server.c to server.cc.
3822 * configure: Re-generate.
3824 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3826 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3828 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
3830 * win32-low.c (win32_create_inferior): Set signal_pid.
3832 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
3833 Pedro Alves <palves@redhat.com>
3835 Skip building gdbserver in a cross-configuration.
3836 * configure.srv: Set $gdbserver_host depending on whether $target
3837 is $host. Use $gdbserver_host instead of $host.
3839 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3841 * configure: Re-generate.
3843 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3845 * configure: Re-generate.
3847 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3849 * acinclude.m4: Update warning.m4 path.
3851 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3853 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3854 (handle_exception): Set siginfo_er.
3855 (win32_xfer_siginfo): New function.
3857 2020-02-07 Tom Tromey <tom@tromey.com>
3858 Pedro Alves <palves@redhat.com>
3860 * README: Update build documentation.
3861 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
3863 * configure.ac: Update paths.
3864 * configure: Rebuild.
3865 * acinclude.m4: Update paths.
3866 * Makefile.in: Update include paths.
3867 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
3868 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
3869 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
3870 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
3871 (%-generated.c): Update paths.
3872 * Move entire directory from ../gdb/gdbserver.
3874 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
3876 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
3878 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3880 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
3881 assignment instead of srv_linux_obj.
3883 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
3885 * server.c (handle_qxfer_libraries): Write segment-address with
3888 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
3890 * Makefile.in (install-strip): New target.
3891 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
3892 * aclocal.m4: Regenerate.
3893 * configure: Regenerate.
3894 * configure.ac: Add AM_PROG_INSTALL_STRIP.
3896 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
3898 * Makefile.in (SFILES): Adjust paths to point to real files.
3899 (OBS): Move waitstatus.o to target/waitstatus.o.
3900 (TAGS): Transform paths appropriately.
3902 (nat/%.o): ... this pattern rule.
3904 (target/%.o): ... this pattern rule.
3905 * configure.srv: Adjust paths throughout to include nat/ prefix
3906 with the revant files.
3907 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
3908 * configure: Regenerate.
3910 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
3912 * Makefile.in (TAGS): Remove config files from the recipe.
3914 2020-01-14 Tom Tromey <tom@tromey.com>
3916 * configure: Rebuild.
3917 * configure.ac: Remove any checks that were added to common.m4.
3918 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
3921 2020-01-14 Tom Tromey <tom@tromey.com>
3923 * server.h: Include config.h.
3924 * gdbreplay.c: Include config.h.
3925 * configure: Rebuild.
3926 * configure.ac: Don't source common.host.
3927 * acinclude.m4: Update path.
3928 * Makefile.in (INCSUPPORT): New variable.
3929 (INCLUDE_CFLAGS): Add INCSUPPORT.
3930 (SFILES): Update paths.
3931 (version-generated.c): Update path to create-version.sh.
3932 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
3934 2020-01-14 Tom Tromey <tom@tromey.com>
3936 * configure.ac (LIBS): Use WIN32APILIBS.
3937 (USE_WIN32API): Don't define.
3938 * configure: Rebuild.
3940 2020-01-14 Tom Tromey <tom@tromey.com>
3942 * configure: Rebuild.
3944 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3946 * Makefile.in (%-generated.c): Remove rule for files from
3949 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3951 * configure: Re-generate.
3953 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3955 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
3957 * tracepoint.c (stop_tracing, flush_trace_buffer,
3958 about_to_request_buffer_space, get_trace_state_variable_value,
3959 set_trace_state_variable_value, gdb_collect): Add declaration.
3961 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3963 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
3964 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
3965 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
3966 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
3967 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
3970 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3972 * inferiors.c: Include gdbsupport/common-inferior.h.
3974 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3976 * hostio-errno.c: Include hostio.h.
3978 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3980 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
3983 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3985 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
3986 * linux-arm-tdesc.h: Include arch/arm.h.
3988 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3990 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
3992 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3994 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
3995 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
3997 2020-01-10 Pedro Alves <palves@redhat.com>
3999 * fork-child.c (post_fork_inferior): Pass target down to
4001 * inferiors.c (switch_to_thread): Add process_stratum_target
4003 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4004 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4005 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4006 * remote-utils.c (prepare_resume_reply): Pass the target to
4008 * target.c (the_target): Now a process_stratum_target.
4009 (done_accessing_memory): Pass the target to switch_to_thread.
4010 (set_target_ops): Ajust to use process_stratum_target.
4011 * target.h (struct target_ops): Rename to ...
4012 (struct process_stratum_target): ... this.
4013 (the_target, set_target_ops): Adjust.
4014 (prepare_to_access_memory): Adjust comment.
4015 * win32-low.c (child_xfer_memory): Adjust to use
4016 process_stratum_target.
4017 (win32_target_ops): Now a process_stratum_target.
4019 2020-01-06 Eli Zaretskii <eliz@gnu.org>
4020 Pedro Alves <palves@redhat.com>
4022 * win32-low.c (get_child_debug_event): Extract the fatal exception
4023 from the exit status and convert to the equivalent Posix signal
4025 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4026 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4028 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
4030 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4032 2020-01-01 Joel Brobecker <brobecker@adacore.com>
4034 * server.c (gdbserver_version): Change copyright year to 2020.
4035 * gdbreplay.c (gdbreplay_version): Likewise.
4037 2019-12-19 Christian Biesinger <cbiesinger@google.com>
4039 * configure: Regenerate.
4040 * configure.ac: Quote variable arguments of test.
4042 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4044 * Makefile.in: Fix build with GNU Make 3.81
4046 2019-12-16 Tom Tromey <tromey@adacore.com>
4048 * server.c (get_exec_file): Constify result.
4050 2019-12-10 Christian Biesinger <cbiesinger@google.com>
4052 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4053 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4054 * config.in: Regenerate.
4055 * configure: Regenerate.
4056 * configure.ac: Don't check for strerror.
4057 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4058 Call safe_strerror instead of strerror.
4059 * server.h (strerror): Remove this now-unnecessary declaration.
4060 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4062 (gdb_agent_helper_thread): Likewise.
4063 * utils.c (perror_with_name): Likewise.
4065 2019-11-26 Tom Tromey <tom@tromey.com>
4067 * configure, config.in: Rebuild.
4069 2019-11-26 Tom Tromey <tom@tromey.com>
4071 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4072 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4074 * configure, config.in: Rebuild.
4076 2019-11-26 Tom Tromey <tom@tromey.com>
4078 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4079 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4080 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4081 * acinclude.m4: Include ax_pthread.m4.
4082 * config.in, configure: Rebuild.
4084 2019-11-26 Christian Biesinger <cbiesinger@google.com>
4086 * debug.c (debug_set_output): Call safe_strerror instead of
4088 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4089 (linux_kill_one_lwp): Likewise.
4090 (linux_detach_one_lwp): Likewise.
4091 (linux_wait_for_event_filtered): Likewise.
4092 (store_register): Likewise.
4093 * lynx-low.c (lynx_attach): Likewise.
4094 * mem-break.c (insert_memory_breakpoint): Likewise.
4095 (remove_memory_breakpoint): Likewise.
4096 (delete_fast_tracepoint_jump): Likewise.
4097 (set_fast_tracepoint_jump): Likewise.
4098 (uninsert_fast_tracepoint_jumps_at): Likewise.
4099 (reinsert_fast_tracepoint_jumps_at): Likewise.
4100 * nto-low.c (nto_xfer_memory): Likewise.
4101 (nto_resume): Likewise.
4103 2019-11-20 Luis Machado <luis.machado@linaro.org>
4105 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4106 instead of register count.
4107 * tdesc.c (tdesc_contains_feature): New function.
4108 * tdesc.h (tdesc_contains_feature): New prototype.
4110 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4112 * Makefile.in: Add safe-strerror.c.
4113 * configure: Regenerate.
4114 * configure.ac: Don't source common.host.
4116 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4118 * config.in: Regenerate.
4119 * configure: Regenerate.
4121 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4123 * ax.c (ax_printf): Handle size_t_arg.
4125 2019-11-06 Christian Biesinger <cbiesinger@google.com>
4127 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4128 * mi/mi-main.c (output_cores): Likewise.
4129 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4130 (linux_xfer_osdata_modules): Likewise.
4131 * remote.c (register_remote_support_xml): Likewise.
4132 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4133 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4135 2019-11-01 Christian Biesinger <cbiesinger@google.com>
4137 * configure: Regenerate.
4138 * configure.ac: Remove check for strerror_r.
4140 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4142 * config.in: Regenerate.
4143 * configure: Regenerate.
4144 * configure.ac: Also check for strerror_r.
4146 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4148 * ax.h (debug_agent): Remove duplicate declaration.
4150 2019-10-26 Tom de Vries <tdevries@suse.de>
4152 * linux-aarch64-low.c: Fix typos in comments.
4153 * linux-arm-low.c: Same.
4154 * linux-low.c: Same.
4155 * linux-ppc-low.c: Same.
4156 * proc-service.c: Same.
4159 * tracepoint.c: Same.
4160 * win32-low.c: Same.
4162 2019-10-25 Tom Tromey <tromey@adacore.com>
4164 * utils.c (xstrdup): Remove.
4166 2019-10-23 Tom Tromey <tom@tromey.com>
4168 * configure, config.in: Rebuild.
4170 2019-10-23 Tom Tromey <tom@tromey.com>
4172 * configure: Rebuild.
4173 * acinclude.m4: Use m4_include, not sinclude.
4175 2019-10-17 Tom Tromey <tromey@adacore.com>
4177 * configure: Rebuild.
4178 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4179 in AC_CONFIG_FILES invocation.
4180 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4183 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4185 * server.c: Include xml-builtin.h.
4186 (get_xml_features): Don't declare xml_builtins here.
4188 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4190 * Makefile.in: Remove references to vec-ipa.o.
4192 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4194 * Makefile.in: Remove references to vec.c.
4196 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4198 * server.c (server_waiting): Change to bool.
4199 (extended_protocol): Likewise.
4200 (response_needed): Likewise.
4201 (exit_requested): Likewise.
4202 (run_once): Likewise.
4203 (report_no_resumed): Likewise.
4204 (non_stop): Likewise.
4205 (disable_packet_vCont): Likewise.
4206 (disable_packet_Tthread): Likewise.
4207 (disable_packet_qC): Likewise.
4208 (disable_packet_qfThreadInfo): Likewise.
4209 (handle_general_set): Update.
4210 (handle_detach): Update.
4211 (handle_monitor_command): Update.
4212 (handle_query): Update.
4213 (captured_main): Update.
4214 (process_serial_event): Update.
4215 * server.h (server_waiting): Change to bool.
4216 (disable_packet_vCont): Likewise.
4217 (disable_packet_Tthread): Likewise.
4218 (disable_packet_qC): Likewise.
4219 (disable_packet_qfThreadInfo): Likewise.
4220 (run_once): Likewise.
4221 (non_stop): Likewise.
4222 * target.c (target_stop_and_wait): Update.
4224 2019-10-02 Tom Tromey <tromey@adacore.com>
4226 * Makefile.in (SFILES): Add common-inferior.c.
4227 (OBS): Add common-inferior.o.
4228 * server.c (startup_with_shell): Don't define.
4230 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4232 * linux-low.c (linux_low_read_btrace): Update for change to
4235 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4237 * debug.c (debug_threads): Remove comment in favor of the header.
4238 * debug.h (using_threads): Add declaration.
4239 (debug_threads): Add comment.
4240 * linux-aarch64-low.c: Include debug.h and remove declaration of
4242 * nto-low.c: Likewise.
4243 * remote-utils.c: Likewise.
4244 * thread-db.c: Likewise.
4246 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4248 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4249 and powerpc-cell64l-ipa.o.
4250 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4251 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4252 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4255 * spu-low.c: Remove file.
4257 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4258 (parse_spufs_run): Remove.
4259 (ppc_get_pc): Remove Cell/B.E. support.
4260 (ppc_set_pc): Likewise.
4261 (ppc_breakpoint_at): Likewise.
4262 (ppc_arch_setup): Likewise.
4263 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4264 tdesc_powerpc_cell32l.
4265 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4266 or init_registers_powerpc_cell32l.
4267 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4268 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4269 or init_registers_powerpc_cell32l.
4270 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4271 (init_registers_powerpc_cell32l): Remove prototype.
4272 (init_registers_powerpc_cell64l): Likewise.
4274 * target.h (struct target_ops): Remove qxfer_spu member.
4275 * server.c (handle_qxfer_spu): Remove.
4276 (qxfer_packets): Remove entry for "spu".
4277 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4278 * linux-low.c (SPUFS_MAGIC): Remove.
4279 (spu_enumerate_spu_ids): Remove.
4280 (linux_qxfer_spu): Remove.
4281 (linux_target_ops): Remove qxfer_spu member.
4282 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4283 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4284 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4286 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4288 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4289 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4290 * config.in: Regenerate.
4291 * configure: Regenerate.
4293 2019-08-15 Tom Tromey <tromey@adacore.com>
4295 * target.c (target_write_memory): Use gdb::byte_vector.
4297 2019-08-15 Tom Tromey <tromey@adacore.com>
4299 * tracepoint.c (write_inferior_data_pointer)
4300 (write_inferior_integer, write_inferior_int8)
4301 (write_inferior_uinteger, m_tracepoint_action_download)
4302 (r_tracepoint_action_download, x_tracepoint_action_download)
4303 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4304 (download_agent_expr, download_tracepoint_1)
4305 (download_trace_state_variables, upload_fast_traceframes): Update.
4306 * server.c (gdb_write_memory): Update.
4307 * remote-utils.c (relocate_instruction): Update.
4308 * proc-service.c (ps_pdwrite): Update.
4309 * mem-break.c (remove_memory_breakpoint)
4310 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4311 (uninsert_fast_tracepoint_jumps_at)
4312 (reinsert_fast_tracepoint_jumps_at): Update.
4313 * linux-x86-low.c (append_insns)
4314 (i386_install_fast_tracepoint_jump_pad)
4315 (amd64_write_goto_address, i386_write_goto_address): Update.
4316 * linux-s390-low.c (append_insns, s390_write_goto_address):
4318 * linux-ppc-low.c (ppc_relocate_instruction)
4319 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4320 (ppc_write_goto_address): Update.
4321 * linux-aarch64-low.c (append_insns): Update.
4322 * target.h (struct target_ops): Update.
4323 (write_inferior_memory): Don't declare.
4324 * target.c (target_write_memory): Rename from
4325 write_inferior_memory. Remove old target_write_memory.
4327 2019-08-15 Tom Tromey <tromey@adacore.com>
4329 * target.c (write_inferior_memory): Use std::vector.
4331 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4334 * configure.ac: Drop enable-libmcheck support.
4335 * configure, config.in: Rebuild.
4336 * acinclude.m4: Don't include it.
4338 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4340 * configure.srv: Remove Arm xml files.
4342 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4344 * configure.srv: Add new files. Remove xml generated files.
4345 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4347 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4348 * linux-aarch32-tdesc.c: New file.
4349 * linux-aarch32-tdesc.h: New file.
4350 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4351 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4352 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4353 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4354 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4355 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4356 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4357 (arm_read_description): Call arm_linux_read_description.
4358 (initialize_low_arch): Don't init registers.
4359 * linux-arm-tdesc.c: New file.
4360 * linux-arm-tdesc.h: New file.
4362 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4364 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4365 Move counter inside for.
4366 (arm_read_description): Check ptrace earlier.
4367 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4369 2019-07-09 Tom Tromey <tom@tromey.com>
4371 * configure: Rebuild.
4372 * configure.ac: Change common to gdbsupport.
4373 * acinclude.m4: Change common to gdbsupport.
4374 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4375 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4376 common to gdbsupport.
4377 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4378 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4379 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4380 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4381 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4382 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4383 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4384 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4385 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4386 common to gdbsupport.
4388 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4390 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4392 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4394 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4396 * configure.srv: Remove legacy xml.
4397 * linux-aarch64-low.c (initialize_low_arch): Remove
4398 initialize_low_tdesc call.
4399 * linux-aarch64-tdesc-selftest.c: Remove file.
4400 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4401 * linux-x86-low.c (initialize_low_arch): Remove
4402 initialize_low_tdesc call.
4403 * linux-x86-tdesc-selftest.c: Remove file.
4404 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4406 2019-06-20 Tom de Vries <tdevries@suse.de>
4408 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4409 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4411 2019-06-19 Tom de Vries <tdevries@suse.de>
4413 * debug.h (debug_write): Change return type to ssize_t.
4414 * debug.c (debug_write): Same.
4416 2019-06-14 Tom Tromey <tom@tromey.com>
4418 * configure.ac: Use new path to gnulib.
4419 * configure: Rebuild.
4420 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4423 2019-06-11 Tom Tromey <tom@tromey.com>
4425 * Makefile.in (SFILES): Add alloc.c.
4427 (IPA_OBJS): Add alloc-ipa.o.
4428 (alloc-ipa.o): New target.
4429 (%.o: ../%.c): New pattern rule.
4431 2019-06-10 Tom Tromey <tromey@adacore.com>
4433 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4434 end warning with a newline.
4435 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4437 * thread-db.c (attach_thread): Don't end warning with a newline.
4438 (thread_db_notice_clone): Likewise.
4439 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4441 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4442 end warning with a newline.
4444 2019-06-04 Pedro Alves <palves@redhat.com>
4446 * server.c (captured_main): Use make_unique_xstrdup.
4448 2019-06-02 Tom Tromey <tom@tromey.com>
4450 * gdbreplay.c (fromhex): Remove.
4451 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4453 2019-05-29 Tom Tromey <tromey@adacore.com>
4455 * configure: Rebuild.
4457 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4459 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4460 sign extension code on 32-bit builds.
4462 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4465 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4467 2019-04-19 Tom Tromey <tom@tromey.com>
4469 * server.c (struct vstop_notif): Derive from notif_event.
4471 (queue_stop_reply): Update.
4472 (remove_all_on_match_ptid): Change type. Rewrite.
4473 (discard_queued_stop_replies): Rewrite.
4474 (in_queued_stop_replies_ptid): Change type.
4475 (in_queued_stop_replies): Rewrite.
4476 (notif_stop): Update.
4477 (queue_stop_reply_callback): Update.
4478 (captured_main): Don't call initialize_notif.
4479 (push_stop_notification): Update.
4480 * notif.c (notif_write_event, handle_notif_ack)
4481 (notif_event_enque, notif_push): Update.
4482 (notif_event_xfree, initialize_notif): Remove.
4483 * notif.h (struct notif_event): Include <list>, not
4485 (struct notif_server) <queue>: Now a std::list.
4486 (notif_event_p): Remove typedef.
4487 (initialize_notif): Don't declare.
4488 (struct notif_event): Add virtual destructor.
4490 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4492 * ax.c (ax_vdebug): Call debug_printf.
4493 * debug.c (debug_write): New function.
4494 * debug.h (debug_write): New declaration.
4495 * linux-low.c (sigchld_handler): Call debug_write.
4497 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4499 * debug.c (debug_set_output): New function.
4500 (debug_vprintf): Send output to debug_file.
4501 (debug_flush): Likewise.
4502 * debug.h (debug_set_output): New declaration.
4503 * server.c (handle_monitor_command): Add debug-file option.
4504 (captured_main): Likewise.
4506 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4508 * debug.c (remote_debug): Add definition.
4509 * debug.h (remote_debug): Add declaration.
4510 * hostio.c (remote_debug): Remove declaration.
4511 * remote-utils.c (struct ui_file): Likewise.
4512 (remote_debug): Likewise.
4513 * remote-utils.h (remote_debug): Likewise,
4514 * server.c (remote_debug): Remove definition.
4516 2019-04-10 Kevin Buettner <kevinb@redhat.com>
4518 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4519 when using a 64-bit gdbserver.
4521 2019-04-09 Tom Tromey <tromey@adacore.com>
4523 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4525 2019-04-08 Tom Tromey <tom@tromey.com>
4527 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4529 (linux_resume_one_lwp): Likewise.
4531 2019-04-08 Tom Tromey <tom@tromey.com>
4533 * gdbreplay.c: Update.
4534 * linux-low.c: Update.
4537 2019-04-08 Tom Tromey <tom@tromey.com>
4539 * server.c: Use C++ exception handling.
4540 * linux-low.c: Use C++ exception handling.
4541 * gdbreplay.c: Use C++ exception handling.
4543 2019-04-08 Tom Tromey <tom@tromey.com>
4545 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4546 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4547 (captured_main, main): Update.
4548 * gdbreplay.c (main): Update.
4550 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4552 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4553 value in argument pointer, return 1 if the entry is found and 0
4554 otherwise. Move comment.
4555 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4556 * linux-low.h (linux_get_auxv): Declare.
4557 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4559 2019-04-05 Tom Tromey <tromey@adacore.com>
4561 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4564 2019-03-28 Alan Hayward <alan.hayward@arm.com>
4566 * linux-low.c (AT_HWCAP2): Add define if not already included.
4568 2019-03-26 Alan Hayward <alan.hayward@arm.com>
4570 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4571 (aarch64_arch_setup): Call linux_get_hwcap.
4572 * linux-arm-low.c (arm_get_hwcap): Remove function.
4573 (arm_read_description): Call linux_get_hwcap.
4574 * linux-low.c (linux_get_auxv): New function.
4575 (linux_get_hwcap): Likewise.
4576 (linux_get_hwcap2): Likewise.
4577 * linux-low.h (linux_get_hwcap): New declaration.
4578 (linux_get_hwcap2): Likewise.
4579 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4580 (ppc_arch_setup): Call linux_get_hwcap.
4581 * linux-s390-low.c (s390_get_hwcap): Remove function.
4582 (s390_arch_setup): Call linux_get_hwcap.
4584 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4585 Jiong Wang <jiong.wang@arm.com>
4587 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4588 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4590 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4592 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4593 Jiong Wang <jiong.wang@arm.com>
4595 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4596 (aarch64_get_hwcap): New function.
4597 (aarch64_arch_setup): Read APIA hwcap.
4599 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4600 Jiong Wang <jiong.wang@arm.com>
4602 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4603 (initialize_low_tracepoint): Likewise.
4604 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4605 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4606 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4607 (aarch64_linux_read_description): Likewise.
4608 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4610 2019-03-12 John Baldwin <jhb@FreeBSD.org>
4612 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4613 i386_create_target_description for 'segments' parameter.
4614 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4615 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4616 * win32-i386-low.c (i386_arch_setup): Likewise.
4618 2019-03-12 Tom Tromey <tromey@adacore.com>
4620 * linux-low.c (iterate_over_lwps): Update.
4622 2019-03-06 Tom Tromey <tom@tromey.com>
4624 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4625 (captured_main): Use SCOPE_EXIT.
4627 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4629 * configure.srv: Use '$enable_unittest' instead of '$development'
4630 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4633 2019-02-27 Tom Tromey <tromey@adacore.com>
4635 * gdbreplay.c (logchar): Handle \r\n.
4637 2019-02-07 Alan Hayward <alan.hayward@arm.com>
4639 * linux-low.c (linux_attach): Add process before lwp.
4640 * server.c (attach_inferior): Check if already attached.
4642 2019-02-07 Tom Tromey <tom@tromey.com>
4644 * x86-tdesc.h: Rename include guard.
4645 * x86-low.h: Add include guard.
4646 * wincecompat.h: Rename include guard.
4647 * win32-low.h: Add include guard.
4648 * utils.h: Rename include guard.
4649 * tracepoint.h: Rename include guard.
4650 * tdesc.h: Rename include guard.
4651 * target.h: Rename include guard.
4652 * server.h: Rename include guard.
4653 * remote-utils.h: Rename include guard.
4654 * regcache.h: Rename include guard.
4655 * nto-low.h: Rename include guard.
4656 * notif.h: Add include guard.
4657 * mem-break.h: Rename include guard.
4658 * lynx-low.h: Add include guard.
4659 * linux-x86-tdesc.h: Add include guard.
4660 * linux-s390-tdesc.h: Add include guard.
4661 * linux-ppc-tdesc-init.h: Add include guard.
4662 * linux-low.h: Add include guard.
4663 * linux-aarch64-tdesc.h: Add include guard.
4664 * linux-aarch32-low.h: Add include guard.
4665 * inferiors.h: Rename include guard.
4666 * i387-fp.h: Rename include guard.
4667 * hostio.h: Rename include guard.
4668 * gdbthread.h: Rename include guard.
4669 * gdb_proc_service.h: Rename include guard.
4670 * event-loop.h: Rename include guard.
4671 * dll.h: Rename include guard.
4672 * debug.h: Rename include guard.
4673 * ax.h: Rename include guard.
4675 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4678 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4679 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4681 2019-01-25 Tom Tromey <tom@tromey.com>
4683 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4685 2019-01-25 Tom Tromey <tom@tromey.com>
4687 * win32-low.c: Fix common/ includes.
4688 * win32-i386-low.c: Fix common/ includes.
4689 * tracepoint.c: Fix common/ includes.
4690 * thread-db.c: Fix common/ includes.
4691 * target.h: Fix common/ includes.
4692 * symbol.c: Fix common/ includes.
4693 * spu-low.c: Fix common/ includes.
4694 * server.h: Fix common/ includes.
4695 * server.c: Fix common/ includes.
4696 * remote-utils.c: Fix common/ includes.
4697 * regcache.h: Fix common/ includes.
4698 * regcache.c: Fix common/ includes.
4699 * nto-x86-low.c: Fix common/ includes.
4700 * notif.h: Fix common/ includes.
4701 * mem-break.h: Fix common/ includes.
4702 * lynx-low.c: Fix common/ includes.
4703 * lynx-i386-low.c: Fix common/ includes.
4704 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4705 * linux-x86-low.c: Fix common/ includes.
4706 * linux-low.c: Fix common/ includes.
4707 * inferiors.h: Fix common/ includes.
4708 * i387-fp.c: Fix common/ includes.
4709 * hostio.c: Fix common/ includes.
4710 * hostio-errno.c: Fix common/ includes.
4711 * gdbthread.h: Fix common/ includes.
4712 * gdbreplay.c: Fix common/ includes.
4713 * fork-child.c: Fix common/ includes.
4714 * event-loop.c: Fix common/ includes.
4716 (enum gdb_agent_op): Fix common/ includes.
4718 2019-01-21 Tom Tromey <tom@tromey.com>
4720 * tracepoint.c: Fix includes.
4721 * remote-utils.c: Fix includes.
4722 * linux-x86-low.c: Fix includes.
4724 2019-01-01 Joel Brobecker <brobecker@adacore.com>
4726 * gdbreplay.c (gdbreplay_version): Update copyright year in
4728 * server.c (gdbserver_version): Likewise.
4730 2018-12-05 Alan Hayward <alan.hayward@arm.com>
4732 * linux-low.c (add_lwp): Switch ordering.
4734 2018-11-29 Tom Tromey <tom@tromey.com>
4736 * win32-low.c (win32_join): Take pid, not process.
4737 * target.h (struct target_ops) <join>: Change argument type.
4738 (join_inferior): Change argument name.
4739 * spu-low.c (spu_join): Take pid, not process.
4740 * server.c (handle_detach): Preserve pid before destroying
4742 * lynx-low.c (lynx_join): Take pid, not process.
4743 * linux-low.c (linux_join): Take pid, not process.
4745 2018-11-23 Alan Hayward <alan.hayward@arm.com>
4747 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4748 (aarch64_cannot_fetch_register): Likewise.
4749 (struct linux_target_ops): Update references.
4751 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4753 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4755 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4757 * configure.srv (ipa_ppc_linux_regobj): Add
4758 powerpc-isa207-htm-vsx32l-ipa.o and
4759 powerpc-isa207-htm-vsx64l-ipa.o.
4760 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4761 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4762 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4763 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4764 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4765 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4766 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4767 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4768 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4769 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4770 (init_registers_powerpc_isa207_htm_vsx32l)
4771 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4772 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4773 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4774 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4775 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4776 (ppc_store_tm_ctarregset): New functions.
4777 (ppc_regsets): Add entries for HTM regsets.
4778 (ppc_arch_setup): Set htm in features struct when needed. Set
4779 sizes for the HTM regsets.
4780 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4781 (initialize_low_arch): Call
4782 init_registers_powerpc_isa207_htm_vsx32l and
4783 init_registers_powerpc_isa207_htm_vsx64l.
4784 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4785 PPC_TDESC_ISA207_HTM_VSX.
4786 (initialize_low_tracepoint): Call
4787 init_registers_powerpc_isa207_htm_vsx32l and
4788 init_registers_powerpc_isa207_htm_vsx64l.
4790 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4792 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4793 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4794 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4795 (ppc_store_pmuregset): New functions.
4796 (ppc_regsets): Add entries for ebb and pmu regsets.
4797 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4798 pmu regsets are available. Set sizes for these regsets.
4800 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4802 * configure.srv (ipa_ppc_linux_regobj): Add
4803 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4804 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4805 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4806 rs6000/powerpc-isa207-vsx32l.xml, and
4807 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4808 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4809 <PPC_TDESC_ISA207_VSX>: New enum value.
4810 (init_registers_powerpc_isa207_vsx32l): Declare.
4811 (init_registers_powerpc_isa207_vsx64l): Declare.
4812 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4813 (ppc_store_tarregset): New function.
4814 (ppc_regsets): Add entry for the TAR regset.
4815 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4816 size for the TAR regsets.
4817 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4818 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4819 and init_registers_powerpc_isa207_vsx64l.
4820 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4821 (initialize_low_tracepoint): Call
4822 init_registers_powerpc_isa207_vsx32l and
4823 init_registers_powerpc_isa207_vsx64l.
4825 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4826 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4828 * configure.srv (ipa_ppc_linux_regobj): Add
4829 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4830 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4831 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4832 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4833 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4834 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4835 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4836 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4837 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4838 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4839 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4840 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4841 (ppc_hwcap): Add comment.
4842 (ppc_hwcap2): New global.
4843 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4844 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4845 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4846 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4847 when needed. Set sizes for the the DSCR and PPR regsets.
4848 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4849 (initialize_low_arch): Call
4850 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4851 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4852 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4853 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4854 (initialize_low_tracepoint): Call
4855 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4856 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4858 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4860 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
4862 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
4863 Simon Marchi <simark@simark.ca>
4865 * acinclude.m4: Include "../selftest.m4".
4866 * configure: Regenerate.
4867 * configure.ac: Use "GDB_AC_SELFTEST".
4868 * configure.srv: Use "$enable_unittests" instead of
4869 "$development" when checking whether unit tests have been
4871 * server.c (captured_main): Update message informing that
4872 selftests have been disabled.
4874 2018-10-04 Tom Tromey <tom@tromey.com>
4876 * configure: Rebuild.
4878 2018-10-04 Tom Tromey <tom@tromey.com>
4880 * server.c (handle_status): Rename inner "thread".
4881 (process_serial_event): Declare "res" in 'm' case.
4882 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
4883 (iterate_over_lwps): Rename inner "thread".
4884 (linux_qxfer_libraries_svr4): Rename inner "len".
4885 * gdbthread.h (find_thread_in_random): Rename inner "thread".
4887 2018-10-01 Gary Benson <gbenson@redhat.com>
4889 * gdb_proc_service.h: Moved common code to
4890 common/gdb_proc_service.h.
4892 2018-10-01 Gary Benson <gbenson@redhat.com>
4894 * gdb_proc_service.h: Synchronize comments and whitespace with
4895 GDB's version of this file.
4897 2018-09-25 Tom Tromey <tom@tromey.com>
4899 * configure: Rebuild.
4900 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
4902 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4904 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
4905 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
4906 ($(IPA_LIB)): Sort IPA_OBJS.
4908 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4910 * Makefile.in: Remove references to $(ADD_DEPS).
4912 2018-09-16 Tom Tromey <tom@tromey.com>
4914 * remote-utils.c (remote_open): Use GNU style for metasyntactic
4916 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
4919 2018-09-05 Tom Tromey <tom@tromey.com>
4921 * configure: Rebuild.
4923 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4926 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
4928 2018-08-27 Tom Tromey <tom@tromey.com>
4931 * configure: Rebuild.
4933 2018-08-27 Tom Tromey <tom@tromey.com>
4935 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
4936 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
4937 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
4938 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
4939 (s390x_emit_stack_adjust): Add casts to unsigned char.
4941 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
4945 * server.h (struct client_state) <disable_randomization>:
4948 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4950 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
4952 (mips_supply_ptrace_register): Likewise.
4954 2018-07-22 Tom Tromey <tom@tromey.com>
4956 * configure: Rebuild.
4958 2018-07-22 Tom Tromey <tom@tromey.com>
4960 * win32-low.c (win32_create_inferior): Remove unused variables.
4961 * gdbreplay.c (remote_open): Remove unused variable.
4962 * remote-utils.c (remote_prepare): Remove unused variable.
4963 * x86-tdesc.h (X86_TDESC_H): Define.
4964 (amd64_expedite_regs): Define conditionally.
4965 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
4966 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
4967 * remote-utils.c (readchar): Remove unused variable.
4969 2018-07-13 Pedro Alves <palves@redhat.com>
4971 * linux-low.c (linux_kill): Change parameter to process_info
4972 pointer instead of pid. Adjust.
4973 * lynx-low.c (lynx_kill): Likewise.
4974 * nto-low.c (nto_kill): Likewise.
4975 * spu-low.c (spu_kill): Likewise.
4976 * win32-low.c (win32_kill): Likewise.
4977 * server.c (handle_v_kill, kill_inferior_callback)
4978 (detach_or_kill_for_exit): Adjust.
4979 * target.c (kill_inferior): Change parameter to process_info
4980 pointer instead of pid. Adjust.
4981 * target.h (struct target_ops) <kill>: Change parameter to
4982 process_info pointer instead of pid. Adjust all implementations
4984 (kill_inferior): Likewise.
4986 2018-07-13 Pedro Alves <palves@redhat.com>
4988 * linux-low.c (linux_detach, linux_join): Change parameter to
4989 process_info pointer instead of pid. Adjust.
4990 * lynx-low.c (lynx_detach, lynx_join): Likewise.
4991 * nto-low.c (nto_detach): Likewise.
4992 * spu-low.c (spu_detach, spu_join): Likewise.
4993 * win32-low.c (win32_detach, win32_join): Likewise.
4994 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
4995 * target.h (struct target_ops) <detach, join>: Change parameter to
4996 process_info pointer instead of pid. Adjust all implementations
4998 (detach_inferior, join_inferior): Rename 'pid' parameter to
5001 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5002 Jan Kratochvil <jan.kratochvil@redhat.com>
5003 Paul Fertser <fercerpav@gmail.com>
5004 Tsutomu Seki <sekiriki@gmail.com>
5006 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5007 (OBS): Add 'common/netstuff.o'.
5008 (GDBREPLAY_OBS): Likewise.
5009 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5010 (remote_open): Implement support for IPv6
5012 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5014 (handle_accept_event): Accept connections from IPv6 sources.
5015 (remote_prepare): Handle IPv6-style hostnames; implement
5016 support for IPv6 connections.
5017 (remote_open): Implement support for printing connections from
5020 2018-07-11 Pedro Alves <palves@redhat.com>
5023 * mem-break.c (any_persistent_commands): Add process_info
5024 parameter and use it instead of relying on the current process.
5025 Change return type to bool.
5026 * mem-break.h (any_persistent_commands): Add process_info
5027 parameter and change return type to bool.
5028 * server.c (handle_detach): Remove require_running_or_return call.
5029 Look up the process_info for the process we're about to detach.
5030 If not found, return back error to GDB. Adjust
5031 any_persistent_commands call to pass down a process pointer.
5033 2018-07-11 Pedro Alves <palves@redhat.com>
5035 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5036 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5037 instead of collect_register_by_name.
5038 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5039 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5041 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5042 Pedro Alves <palves@redhat.com>
5044 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5046 2018-07-03 Tom Tromey <tom@tromey.com>
5048 * linux-low.c: Update.
5049 * lynx-low.c: Update.
5050 * mem-break.c: Update.
5051 * nto-low.c: Update.
5052 * remote-utils.c: Update.
5054 * spu-low.c: Update.
5056 * win32-low.c: Update.
5058 2018-07-03 Tom Tromey <tom@tromey.com>
5062 2018-07-03 Tom Tromey <tom@tromey.com>
5064 * linux-low.c: Update.
5066 2018-07-03 Tom Tromey <tom@tromey.com>
5070 2018-07-03 Tom Tromey <tom@tromey.com>
5072 * linux-low.c: Update.
5073 * linux-mips-low.c: Update.
5074 * lynx-low.c: Update.
5075 * nto-low.c: Update.
5076 * remote-utils.c: Update.
5078 * spu-low.c: Update.
5080 * thread-db.c: Update.
5082 2018-07-03 Tom Tromey <tom@tromey.com>
5084 * linux-low.c: Update.
5085 * linux-mips-low.c: Update.
5086 * lynx-low.c: Update.
5087 * mem-break.c: Update.
5088 * nto-low.c: Update.
5089 * remote-utils.c: Update.
5091 * spu-low.c: Update.
5093 * tracepoint.c: Update.
5095 2018-07-03 Tom Tromey <tom@tromey.com>
5097 * linux-low.c: Update.
5098 * linux-ppc-low.c: Update.
5099 * linux-x86-low.c: Update.
5100 * proc-service.c: Update.
5102 * spu-low.c: Update.
5103 * thread-db.c: Update.
5104 * win32-low.c: Update.
5106 2018-07-03 Tom Tromey <tom@tromey.com>
5108 * linux-low.c: Update.
5109 * lynx-low.c: Update.
5110 * nto-low.c: Update.
5111 * remote-utils.c: Update.
5112 * spu-low.c: Update.
5113 * thread-db.c: Update.
5114 * win32-low.c: Update.
5116 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5118 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5119 parameter in call to 'amd64_create_target_description'.
5121 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5123 * x86-tdesc.h: Remove executable permission flag.
5125 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5127 * configure.ac: Remove AC_PREREQ, add missing quoting.
5128 * configure: Re-generate.
5129 * config.in: Re-generate.
5130 * aclocal.m4: Re-generate.
5132 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5134 * tracepoint.h (current_traceframe): Remove declaration.
5136 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5138 * linux-aarch64-low.c (is_sve_tdesc): New function.
5139 (aarch64_sve_regs_copy_to_regcache): Likewise.
5140 (aarch64_sve_regs_copy_from_regcache): Likewise.
5141 (aarch64_regs_info): Add SVE checks.
5142 (initialize_low_arch): Initialize SVE.
5144 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5146 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5148 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5150 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5151 (initialize_low_tracepoint): Likewise
5152 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5153 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5155 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5157 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5159 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5161 * server.h (PBUFSIZ): Increase size
5163 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5165 * regcache.c (regcache::raw_compare): New function.
5166 * regcache.h (regcache::raw_compare): New declaration.
5168 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5170 * regcache.c (new_register_cache): Use new.
5171 (free_register_cache): Use delete.
5172 (register_data): Use const.
5173 (supply_register): Move body inside regcache.
5174 (regcache::raw_supply): New override function.
5175 (collect_register): Move body inside regcache.
5176 (regcache::raw_collect): New override function.
5177 (regcache::get_register_status): New override function.
5178 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5180 2018-06-09 Tom Tromey <tom@tromey.com>
5182 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5184 (event_queue): Use std::queue.
5185 (gdb_event_xfree): Remove.
5186 (initialize_event_loop, process_event, wait_for_event): Update.
5188 2018-06-08 Stan Cox <scox@redhat.com>
5190 * win32-low.c (win32_create_inferior): last_ptid and last_status
5191 moved to client_state.
5193 2018-06-08 Pedro Alves <palves@redhat.com>
5195 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5196 common/common-exceptions.o, common/common-utils.o,
5197 common/errors.o, common/print-utils.o and utils.o.
5198 * gdbreplay.c: Include "common-defs.h" instead of the two
5199 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5200 string.h or alloca.h.
5201 (perror_with_name): Delete.
5202 (remote_open): Use xstrdup instead of strdup.
5203 (main): Rename to ...
5204 (captured_main): ... this.
5207 2018-06-08 Tom Tromey <tom@tromey.com>
5209 * linux-low.c (linux_low_read_btrace): Update.
5211 2018-06-04 Stan Cox <scox@redhat.com>
5213 * server.h (struct client_state): New.
5214 * server.c (cont_thread, general_thread, multi_process)
5215 (report_fork_events, report_vfork_events, report_exec_events)
5216 (report_thread_events, swbreak_feature, hwbreak_feature)
5217 (vCont_supported, disable_randomization, pass_signals)
5218 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5219 Moved to client_state.
5220 * remote-utils.c (remote_debug, noack_mode)
5221 (transport_is_reliable): Moved to client_state.
5222 * tracepoint.c (current_traceframe): Moved to client_state.
5225 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5226 linux-low.c, remote-utils.h, target.c: Use client_state.
5228 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5230 * configure.srv: Add new c/h file.
5232 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5234 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5237 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5239 * gdb.arch/mips-fpregset-core.exp: New test.
5240 * gdb.arch/mips-fpregset-core.c: New test source.
5242 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5245 * hostio.c (require_int): Do not report overflow for integers
5246 between 0xfffffff and 0x7fffffff.
5248 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5250 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5251 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5252 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5254 (the_low_target): Wire them.
5256 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5258 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5259 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5260 mode. Call collect_register_by_name with vscr using
5261 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5262 (ppc_store_vrregset): Add and set vscr_offset variable as in
5263 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5266 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5268 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5269 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5270 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5272 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5274 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5275 (ppc_store_vsxregset): Likewise.
5276 (ppc_fill_vrregset): Likewise.
5277 (ppc_store_vrregset): Likewise.
5278 (ppc_fill_evrregset): Likewise.
5279 (ppc_store_evrregset): Likewise.
5280 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5281 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5284 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5286 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5287 wordsize of the inferior. Call ppc_linux_target_wordsize.
5289 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5291 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5292 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5293 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5294 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5295 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5296 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5297 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5298 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5299 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5300 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5301 (tdesc_powerpc_e500l): Remove.
5302 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5303 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5304 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5305 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5307 (ppc_arch_setup): Remove target description matching code. Fill a
5308 ppc_linux_features struct and call ppc_linux_match_description
5311 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5313 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5314 width of the requested register exceeds the width of the
5316 (mips_cannot_store_register): Likewise.
5318 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5320 * linux-mips-low.c (mips_fetch_register): New function. Update
5322 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5323 (the_low_target): Wire `mips_fetch_register'.
5325 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5327 * lynx-i386-low.c (LYNXOS_178): New macro.
5328 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5329 the layout on LynxOS-178.
5330 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5331 handle floating point registers that are not supported by
5334 2018-05-10 Tom Tromey <tom@tromey.com>
5336 * configure: Rebuild.
5338 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5341 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5342 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5343 Use it to set the expedite_regs field in the given tdesc.
5344 * x86-tdesc.h: New file.
5345 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5346 Adjust following the addition of the new expedite_regs parameter
5347 to init_target_desc.
5348 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5349 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5350 (i386_linux_read_description, amd64_linux_read_description):
5351 Adjust following the addition of the new expedite_regs parameter
5352 to init_target_desc.
5353 * lynx-i386-low.c: #include "x86-tdesc.h".
5354 (lynx_i386_arch_setup): Adjust following the addition of the new
5355 expedite_regs parameter to init_target_desc.
5356 * nto-x86-low.c: #include "x86-tdesc.h".
5357 (nto_x86_arch_setup): Adjust following the addition of the new
5358 expedite_regs parameter to init_target_desc.
5359 * win32-i386-low.c: #include "x86-tdesc.h".
5360 (i386_arch_setup): Adjust following the addition of the new
5361 expedite_regs parameter to init_target_desc.
5363 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5366 * win32-low.c (win32_create_inferior): Add call to my_wait
5367 setting last_status global.
5369 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5372 * win32-low.c (create_process): Only call gdb_tilde_expand if
5373 inferior_cwd is not NULL.
5375 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5377 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5378 registers to the cache if their values have changed.
5379 (i387_xsave_to_cache): Provide default values for x87 control
5380 registers when these features are available, but disabled.
5381 * regcache.c (supply_register_by_name_zeroed): New function.
5382 * regcache.h (supply_register_by_name_zeroed): Declare new
5385 2018-05-07 Tom Tromey <tom@tromey.com>
5387 * configure: Rebuild.
5389 2018-05-04 Tom Tromey <tom@tromey.com>
5391 * configure: Rebuild.
5393 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5394 Pedro Alves <palves@redhat.com>
5396 * linux-aarch64-low.c (aarch64_stopped_data_address):
5399 2018-04-27 Tom Tromey <tom@tromey.com>
5401 * configure: Rebuild.
5403 2018-04-23 Tom Tromey <tom@tromey.com>
5405 * configure: Rebuild.
5407 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5409 * Makefile.in (depcomp): Add "..".
5410 (all_deps_files): New and use it.
5412 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5414 * configure.srv (aarch64*-*-linux*): Don't include xml.
5415 (i[34567]86-*-cygwin*): Likewise.
5416 (i[34567]86-*-linux*): Likewise.
5417 (i[34567]86-*-lynxos*): Likewise.
5418 (i[34567]86-*-mingw32ce*): Likewise.
5419 (i[34567]86-*-mingw*): Likewise.
5420 (i[34567]86-*-nto*): Likewise.
5421 (tic6x-*-uclinux): Likewise.
5422 (x86_64-*-linux*): Likewise.
5423 (x86_64-*-mingw*): Likewise.
5424 (x86_64-*-cygwin*): Likewise.
5426 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5428 * tdesc.c: Remove xml parameter.
5430 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5432 * server.c (get_features_xml): Remove cast.
5433 * tdesc.c (void target_desc::accept): Fill in function.
5434 (tdesc_get_features_xml): Remove old xml creation.
5435 (print_xml_feature::visit_pre): Add xml vistor.
5436 * tdesc.h (struct target_desc): Make xmltarget mutable.
5437 (tdesc_get_features_xml): Remove declaration.
5439 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5441 * tdesc.c (tdesc_architecture_name): Add new function.
5442 (tdesc_osabi_name): Likewise.
5443 (tdesc_get_features_xml): Use new functions.
5445 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5447 * tdesc.c (tdesc_create_flags): Remove.
5448 (tdesc_add_flag): Likewise.
5449 (tdesc_named_type): Likewise.
5450 (tdesc_create_union): Likewise.
5451 (tdesc_create_struct): Likewise.
5452 (tdesc_create_vector): Likewise.
5453 (tdesc_add_bitfield): Likewise.
5454 (tdesc_add_field): Likewise.
5455 (tdesc_set_struct_size): Likewise.
5457 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5459 * tdesc.c (~target_desc): Remove implictly deleted items.
5460 (init_target_desc): Iterate all features.
5461 (tdesc_get_features_xml): Use vector.
5462 (tdesc_create_feature): Create feature.
5463 * tdesc.h (tdesc_feature) Remove
5464 (target_desc): Add features.
5466 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5468 * Makefile.in: Add common/tdesc.c
5469 * tdesc.c (init_target_desc): init all reg_defs from register
5471 (tdesc_create_reg): Create tdesc_reg.
5472 * tdesc.h (tdesc_feature): Add register vector.
5474 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5476 * tdesc.h (struct target_desc) <features>: Change type to
5477 std::vector<std::string>.
5478 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5480 (tdesc_get_features_xml): Likewise.
5481 (tdesc_create_feature): Likewise.
5483 2018-03-26 Alan Hayward <alan.hayward@arm.com>
5485 * regcache.c (find_register_by_number): Return a ref.
5486 (find_regno): Use references.
5487 (register_size): Likewise.
5488 (register_data): Likewise.
5489 * tdesc.c (target_desc::~target_desc): Remove free calls.
5490 (target_desc::operator==): Use std::vector compare.
5491 (init_target_desc): Use reference.
5492 (tdesc_create_reg): Use reg constructors.
5493 * tdesc.h (struct target_desc): Replace pointer with object.
5495 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5497 * regcache.c (find_register_by_number): Make static.
5498 (find_regno): Use find_register_by_number
5499 * regcache.h (struct reg): Remove declaration.
5501 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5503 * tdesc.c (target_desc::~target_desc): Move to here.
5504 (target_desc::operator==): Likewise.
5505 * tdesc.h (target_desc::~target_desc): Move from here.
5506 (target_desc::operator==): Likewise.
5508 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5510 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5512 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5514 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5516 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5517 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5518 and init_registers_s390_gs_linux64.
5520 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5522 * linux-s390-low.c (s390_fill_gs): Remove function.
5523 (s390_fill_gsbc): Remove function.
5524 (s390_regsets): Set fill functions for the guarded storage regsets
5527 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5529 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5530 the word size. Add comment.
5531 (s390_get_wordsize): New function.
5532 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5533 pswm with it. Instead, use s390_get_wordsize to determine the
5534 word size first and derive the correct tdesc from that directly.
5536 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5538 * Makefile.in: Include silent-rules.mk.
5539 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5540 (COMPILE): Add ECHO_CXX.
5541 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5542 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5543 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5544 (version-generated.c): Add ECHO_GEN.
5545 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5546 (IPAGENT_COMPILE): Add ECHO_CXX.
5547 (%-generated.c): Add ECHO_REGDAT.
5549 2018-03-14 Tom Tromey <tom@tromey.com>
5552 * ax.c (ax_printf): Special case for NULL.
5554 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5556 * linux-low.c (linux_qxfer_libraries_svr4): Use
5557 xml_escape_text_append.
5559 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5561 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5563 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5565 * server.c (handle_general_set): Remove unnecessary xstrdup.
5567 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5569 * server.c (parse_debug_format_options): Adjust to
5570 delim_string_to_char_ptr_vec changes.
5571 * thread-db.c (thread_db_load_search): Adjust to
5572 dirnames_to_char_ptr_vec changes.
5574 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5576 * target.h (target_enable_btrace, target_disable_btrace)
5577 (target_read_btrace, target_read_btrace_conf): Turn macro into
5578 inline function. Throw error if target method is not defined.
5579 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5580 check for btrace target method. Be prepared to handle exceptions
5581 from btrace target methods.
5583 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5585 * server.c (captured_main): Change order of error message printed
5586 when the current working directory cannot be found.
5588 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5590 * server.c: Include "filenames.h" and "pathstuff.h".
5591 (program_name): Delete variable.
5592 (program_path): New anonymous class.
5593 (get_exec_wrapper): Use "program_path" instead of
5595 (handle_v_run): Likewise.
5596 (captured_main): Likewise.
5597 (process_serial_event): Likewise.
5599 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5601 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5602 (OBJS): Add "pathstuff.o".
5603 * server.c (current_directory): New global variable.
5604 (captured_main): Initialize "current_directory".
5606 2018-02-26 Alan Hayward <alan.hayward@arm.com>
5608 * tdesc.c: Use common/tdesc.h.
5609 * tdesc.h: Likewise.
5611 2018-02-20 Alan Hayward <alan.hayward@arm.com>
5612 Simon Marchi <simon.marchi@ericsson.com>
5614 * Makefile.in: Switch order of make rules.
5616 2018-02-19 Alan Hayward <alan.hayward@arm.com>
5618 * Makefile.in: Add common directory in build.
5619 * configure.ac: Add common reference.
5620 * configure: Regenerate.
5622 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5624 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5625 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5626 * spu-low.c (spu_target_ops): Likewise.
5627 * win32-low.c (win32_target_ops): Likewise.
5628 * server.c (supported_btrace_packets): Report packets unconditionally.
5629 * target.h (target_ops) <supports_btrace>: Remove.
5630 (target_supports_btrace): Remove.
5632 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5634 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5635 (handle_btrace_disable): Change return type to void. Use exceptions
5637 (handle_btrace_general_set): Catch exception and copy message to
5640 2018-02-08 Tom Tromey <tom@tromey.com>
5642 * linux-low.c (install_software_single_step_breakpoints): Use
5643 make_scoped_restore.
5644 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5645 (do_restore_current_thread_cleanup): Remove.
5646 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5649 2018-02-08 Tom Tromey <tom@tromey.com>
5651 * mem-break.c (set_raw_breakpoint_at): Use
5652 gdb::unique_xmalloc_ptr.
5654 2018-01-30 Pedro Alves <palves@redhat.com>
5657 * target.c (target_terminal::terminal_state): Rename to ...
5658 (target_terminal::m_terminal_state): ... this.
5660 2018-01-19 James Clarke <jrtc27@jrtc27.com>
5662 * linux-low.c (handle_extended_wait): Surround call to
5663 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5665 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5667 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5668 linux_ptrace_attach_fail_reason_string now returning an
5670 (linux_attach): Likewise.
5671 * thread-db.c (attach_thread): Likewise.
5673 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5676 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5677 checking for fs_base/gs_base fields in struct user_regs_struct.
5678 * configure: Regenerate.
5680 2018-01-16 Yao Qi <yao.qi@linaro.org>
5683 * linux-low.c (fetch_register): Call supply_register instead of
5686 2018-01-08 Yao Qi <yao.qi@linaro.org>
5687 Simon Marchi <simon.marchi@ericsson.com>
5689 * Makefile.in (OBS): Remove selftest.o.
5690 * configure.ac: Set srv_selftest_objs if $development is true.
5691 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5692 * configure: Re-generated.
5693 * server.c (captured_main): Wrap variable selftest_filter with
5696 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5698 * server.c (parse_debug_format_options): Return std::string.
5699 (handle_monitor_command, captured_main): Adjust.
5701 2018-01-05 Pedro Alves <palves@redhat.com>
5704 * server.c (captured_main): Pass quiet=false to
5705 save_original_signals_state.
5707 2018-01-01 Joel Brobecker <brobecker@adacore.com>
5709 * gdbreplay.c (gdbreplay_version): Update copyright year in
5711 * server.c (gdbserver_version): Likewise.
5713 2017-12-08 Tom Tromey <tom@tromey.com>
5715 * ax.c (ax_printf): Update.
5717 2017-12-07 Yao Qi <yao.qi@linaro.org>
5719 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5720 aarch64_linux_read_description.
5721 * linux-amd64-ipa.c (idx2mask): New array.
5722 (get_ipa_tdesc): Move idx2mask out.
5723 (initialize_low_tracepoint): Initialize target descriptions.
5724 * linux-i386-ipa.c (idx2mask): New array.
5725 (get_ipa_tdesc): Move idx2mask out.
5726 (initialize_low_tracepoint): Initialize target descriptions.
5728 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5730 * tdesc.c (struct tdesc_type): Change return type.
5731 (tdesc_add_flag): Change parameter type.
5732 (tdesc_add_bitfield): Likewise.
5733 (tdesc_add_field): Likewise.
5734 (tdesc_set_struct_size): Likewise.
5736 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5738 * regcache.c (registers_to_string): Remove unused variable.
5740 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5742 * inferiors.c (for_each_inferior_with_data): Remove.
5743 * inferiors.h (for_each_inferior_with_data): Remove.
5744 * server.c (handle_qxfer_threads_worker): Change parameter type.
5745 (handle_qxfer_threads_proper): Use for_each_thread.
5747 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5749 * inferiors.c (for_each_inferior): Remove.
5750 (clear_inferiors): Use for_each_thread.
5751 * inferiors.h (for_each_inferior): Remove.
5752 * linux-low.c (linux_wait_for_event_filtered): Use
5754 (linux_stabilize_threads): Likewise.
5755 * regcache.c (regcache_release): Likewise.
5756 * server.c (gdb_wants_all_threads_stopped): Likewise.
5757 (clear_pending_status_callback): Remove.
5758 (handle_status): Use for_each_thread.
5759 (captured_main): Likewise.
5760 * win32-low.c (child_init_thread_list): Likewise.
5761 (win32_clear_inferiors): Likewise.
5762 (fake_breakpoint_event): Likewise.
5764 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5766 * inferiors.h (find_inferior): Remove.
5767 * inferiors.c (find_inferior): Remove.
5769 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5771 * linux-low.c (resume_status_pending_p): Update comment.
5772 (need_step_over_p): Update comment.
5774 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5776 * linux-low.c (proceed_one_lwp): Return void, change parameter
5778 (unsuspend_and_proceed_one_lwp): Likewise.
5779 (proceed_all_lwps): Use for_each_thread.
5780 (unstop_all_lwps): Likewise.
5782 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5784 * linux-low.c (linux_resume_one_thread): Return void, take
5786 (linux_resume): Use for_each_thread.
5788 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5790 * linux-low.c (send_sigstop_callback): Return void, change
5791 parameter type. Rename to...
5792 (send_sigstop): ... this.
5793 (suspend_and_send_sigstop_callback): Return void, change parameter
5795 (suspend_and_send_sigstop): ... this.
5796 (stop_all_lwps): Use for_each_thread.
5798 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5800 * linux-low.c (lwp_running): Return bool, remove unused
5802 (linux_stabilize_threads): Use find_thread.
5804 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5806 * linux-low.c (select_singlestep_lwp_callback): Remove.
5807 (count_events_callback): Remove.
5808 (select_event_lwp_callback): Remove.
5809 (select_event_lwp): Use find_thread/for_each_thread.
5811 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5813 * linux-low.c (not_stopped_callback): Return bool, take filter
5815 (linux_wait_for_event_filtered): Use find_thread.
5816 (linux_wait_1): Likewise.
5818 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5820 * linux-low.c (same_lwp): Remove.
5821 (find_lwp_pid): Use find_thread.
5823 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5825 * linux-low.c (delete_lwp_callback): Remove.
5826 (linux_mourn): Use for_each_thread.
5828 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5830 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5831 args parameter, don't check for pid.
5832 (linux_detach): Use for_each_thread.
5834 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5836 * linux-low.c (struct counter): Remove.
5837 (second_thread_of_pid_p): Remove.
5838 (last_thread_of_process_p): Use find_thread.
5840 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5842 * inferiors.c (find_inferior_in_random): Remove.
5843 * inferiors.h (find_inferior_in_random): Remove.
5844 * linux-low.c (status_pending_p_callback): Return bool, accept
5845 parameter ptid directly.
5846 (linux_wait_for_event_filtered): Use find_thread_in_random.
5847 (linux_wait_1): Likewise.
5849 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5851 * inferiors.c (find_inferior_id): Remove.
5852 (find_thread_ptid): Move implemention from find_inferior_id to
5854 * inferiors.h (find_inferior_id): Remove.
5855 * server.c (handle_status): Use find_thread_ptid.
5856 (process_serial_event): Likewise.
5857 * thread-db.c (find_one_thread): Likewise.
5858 (thread_db_thread_handle): Likewise.
5859 * win32-low.c (thread_rec): Likewise.
5860 (child_delete_thread): Likewise.
5861 (win32_thread_alive): Likewise.
5862 (get_child_debug_event): Likewise.
5864 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5866 * linux-mips-low.c (update_watch_registers_callback): Return
5867 void, remove pid_p parameter, don't check for pid.
5868 (mips_insert_point, mips_remove_point): Use for_each_thread.
5870 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5872 * lynx.low (lynx_delete_thread_callback): Remove.
5873 (lynx_mourn): Use for_each_thread.
5875 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5877 * regcache.c (regcache_invalidate_one): Remove.
5878 (regcache_invalidate_pid): use for_each_thread.
5880 2017-11-26 Tom Tromey <tom@tromey.com>
5882 * linux-low.c (linux_create_inferior): Update.
5884 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
5886 * spu-low.c (spu_create_inferior): Fix typo in argument name.
5888 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5890 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
5891 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5892 * linux-aarch64-tdesc-selftest.c: New file.
5893 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5895 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5897 * configure.srv: Add new file.
5898 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5899 * linux-aarch64-tdesc-selftest.c: New file.
5900 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5902 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5904 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
5905 * linux-aarch64-low.c (initialize_low_arch): Remove init.
5906 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
5908 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5910 * configure.srv: Add new files.
5911 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
5912 aarch64_linux_read_description.
5913 * linux-aarch64-low.c (aarch64_linux_read_description):
5914 Merge with aarch64_arch_setup.
5915 (aarch64_arch_setup): Call aarch64_linux_read_description.
5916 * linux-aarch64-tdesc.c: New file.
5917 * linux-aarch64-tdesc.h: New file.
5919 2017-11-24 Yao Qi <yao.qi@linaro.org>
5921 * configure.srv: Set $srv_regobj for tic6x-linux.
5922 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
5923 (tic6x_read_description): Move some code to tic6x_arch_setup.
5924 (tic6x_tdesc_test): New function.
5925 (initialize_low_arch): Call selftests::register_test.
5927 2017-11-22 Yao Qi <yao.qi@linaro.org>
5929 * remote-utils.c (prepare_resume_reply): Use memcpy.
5931 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5933 * linux-low.c (kill_one_lwp_callback): Return void, take
5934 argument directly, don't filter on pid.
5935 (linux_kill): Use for_each_thread.
5937 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5939 * linux-low.c (need_step_over_p): Return bool, remove dummy
5941 (linux_resume, proceed_all_lwps): Use find_thread.
5943 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5945 * linux-low.c (resume_status_pending_p): Return bool, remove
5947 (linux_resume): Use find_thread.
5949 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5951 * linux-low.c (struct thread_resume_array): Remove.
5952 (linux_set_resume_request): Return void, take arguments
5954 (linux_resume): Use for_each_thread.
5956 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5958 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
5959 return bool, remove data argument.
5960 (linux_stabilize_threads): Use find_thread.
5962 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5964 * linux-low.c (unsuspend_one_lwp): Remove.
5965 (unsuspend_all_lwps): Use for_each_thread, inline code from
5968 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5970 * gdbthread.h (find_thread): Add overload with ptid_t filter.
5971 * linux-low.c (struct iterate_over_lwps_args): Remove.
5972 (iterate_over_lwps_filter): Remove.
5973 (iterate_over_lwps): Use find_thread.
5975 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5977 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
5978 (linux_handle_new_gdb_connection): Use for_each_thread, inline
5979 code from reset_lwp_ptrace_options_callback.
5981 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5983 * linux-arm-low.c (struct update_registers_data): Remove.
5984 (update_registers_callback): Return void, take arguments
5985 directly, don't check thread's pid.
5986 (arm_insert_point, arm_remove_point): Use for_each_thread.
5988 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5990 * win32-low.c (continue_one_thread): Return void, take argument
5992 (child_continue): Use for_each_thread.
5994 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5996 * win32-i386-low.c (update_debug_registers_callback): Rename
5998 (update_debug_registers): ... this, return void, remove pid_p arg.
5999 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6001 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6003 * inferiors.h (struct process_info): Add constructor, initialize
6005 <syscalls_to_catch>: Change type to std::vector<int>.
6006 * inferiors.c (add_process): Allocate process_info with new.
6007 (remove_process): Free process_info with delete.
6008 * linux-low.c (handle_extended_wait): Adjust.
6009 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6010 * server.c (handle_general_set): Adjust.
6012 2017-11-16 Pedro Alves <palves@redhat.com>
6014 * remote-utils.c (remote_close): Block SIGIO signals instead of
6015 uninstalling the SIGIO handler.
6017 2017-11-16 Alan Hayward <alan.hayward@arm.com>
6019 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6021 2017-11-16 Yao Qi <yao.qi@linaro.org>
6023 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6024 (tic6x_store_gregset): Likewise.
6025 (tic6x_usrregs_info): Move it up.
6027 2017-11-15 Alan Hayward <alan.hayward@arm.com>
6029 * Makefile.in: Update arch rules.
6030 * configure.srv: Explicitly mark arch/ files.
6032 2017-11-13 Andreas Schwab <schwab@suse.de>
6034 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6036 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6038 2017-11-06 Pedro Alves <palves@redhat.com>
6040 * config.in, configure: Regenerate.
6042 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6044 * target.c (struct thread_search): Remove.
6045 (thread_search_callback): Remove.
6046 (prepare_to_access_memory): Use for_each_thread instead of
6047 find_inferior. Inline code from thread_search_callback.
6049 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6051 * server.c (struct visit_actioned_threads_data): Remove.
6052 (visit_actioned_threads): Change prototype to take arguments
6054 (resume): Use find_thread instead of find_inferior.
6056 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6058 * server.c (queue_stop_reply_callback): Change prototype, return
6060 (find_status_pending_thread_callback): Remove.
6061 (handle_status): Replace find_inferior with find_thread and
6064 2017-10-25 Alan Hayward <alan.hayward@arm.com>
6066 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6068 (aarch64_store_gregset): Likewise.
6069 (aarch64_fill_fpregset): Likewise.
6070 (aarch64_store_fpregset): Likewise.
6072 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6074 * gdbthread.h (find_thread, for_each_thread): New functions.
6075 * inferiors.c (thread_of_pid): Remove.
6076 (find_any_thread_of_pid): Use find_thread.
6077 * linux-low.c (num_lwps): Use for_each_thread.
6079 2017-10-17 Yao Qi <yao.qi@linaro.org>
6081 * Makefile.in: Remove one rule.
6082 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6084 2017-10-17 Yao Qi <yao.qi@linaro.org>
6086 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6087 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6089 2017-10-17 Yao Qi <yao.qi@linaro.org>
6091 * configure.srv: Rename arm.o with arch/arm.o.
6093 2017-10-17 Yao Qi <yao.qi@linaro.org>
6095 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6096 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6097 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6098 (arch-i386.o, arch-amd64.o): Remove rules.
6099 (arch/%.o): New rule.
6100 Update POSTCOMPILE and COMPILE.pre.
6101 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6102 * configure: Re-generated.
6103 * configure.srv: Replace arch-i386.o with arch/i386.o.
6104 Replace arch-amd64.o with arch/amd64.o.
6106 2017-10-16 Yao Qi <yao.qi@linaro.org>
6108 * configure: Regenerated.
6110 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6112 * inferiors.h: (struct inferior_list): Remove.
6113 (struct inferior_list_entry); Remove.
6114 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6115 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6116 get_first_inferior): Remove.
6117 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6118 find_inferior_id, find_inferior_in_random): Change signature.
6119 * inferiors.c (all_threads): Change type to
6120 std::list<thread_info *>.
6121 (get_thread): Remove macro.
6122 (find_inferior, find_inferior_id): Change signature, implement
6124 (find_inferior_in_random): Change signature, implement using
6125 find_thread_in_random.
6126 (for_each_inferior, for_each_inferior_with_data): Change
6127 signature, implement using for_each_thread.
6128 (add_inferior_to_list, remove_inferior): Remove.
6129 (add_thread, get_first_thread, thread_of_pid,
6130 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6131 (get_first_inferior, one_inferior_p, clear_inferior_list):
6133 (clear_inferiors, get_thread_process): Update.
6134 * gdbthread.h: Include <list>.
6135 (struct thread_info) <entry>: Remove field.
6137 (all_threads): Change type to std::list<thread_info *>.
6138 (get_first_inferior): Add doc.
6139 (find_thread, for_each_thread, find_thread_in_random): New
6141 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6142 * linux-arm-low.c (update_registers_callback): Update.
6143 * linux-low.c (second_thread_of_pid_p): Update.
6144 (kill_one_lwp_callback, linux_detach_lwp_callback,
6145 delete_lwp_callback, status_pending_p_callback, same_lwp,
6146 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6147 iterate_over_lwps, not_stopped_callback,
6148 resume_stopped_resumed_lwps, count_events_callback,
6149 select_singlestep_lwp_callback, select_event_lwp_callback,
6150 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6151 suspend_and_send_sigstop_callback, wait_for_sigstop,
6152 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6153 lwp_running, linux_set_resume_request, resume_status_pending_p,
6154 need_step_over_p, start_step_over, linux_resume_one_thread,
6155 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6156 reset_lwp_ptrace_options_callback): Update.
6157 * linux-mips-low.c (update_watch_registers_callback): Update.
6158 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6160 (free_register_cache_thread_one): Remove.
6161 (regcache_release): Update.
6162 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6163 handle_qxfer_threads_worker): Update.
6164 (handle_query): Update, use list iterator.
6165 (visit_actioned_threads, handle_pending_status,
6166 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6167 clear_pending_status_callback, set_pending_status_callback,
6168 find_status_pending_thread_callback, handle_status,
6169 process_serial_event): Update.
6170 * target.c (thread_search_callback): Update.
6171 * thread-db.c (thread_db_get_tls_address): Update.
6172 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6174 * win32-i386-low.c (update_debug_registers_callback): Update.
6175 * win32-low.c (delete_thread_info, child_delete_thread,
6176 continue_one_thread, suspend_one_thread,
6177 get_child_debug_event): Adjust.
6179 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6181 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6182 * inferiors.h: Include <list>.
6183 (struct process_info) <entry>: Remove field.
6185 (pid_of): Change macro to function.
6186 (ptid_of, lwpid_of): Remove macro.
6187 (all_processes): Change type to std::list<process_info *>.
6188 (ALL_PROCESSES): Remove macro.
6189 (for_each_process, find_process): New function.
6190 * inferiors.c (all_processes): Change type to
6191 std::list<process_info *>.
6192 (find_thread_process): Adjust.
6193 (add_process): Likewise.
6194 (remove_process): Likewise.
6195 (find_process_pid): Likewise.
6196 (get_first_process): Likewise.
6197 (started_inferior_callback): Remove.
6198 (have_started_inferiors_p): Adjust.
6199 (attached_inferior_callback): Remove.
6200 (have_attached_inferiors_p): Adjust.
6201 * linux-low.c (check_zombie_leaders): Likewise.
6202 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6203 (x86_linux_update_xmltarget): Adjust.
6204 * server.c (handle_query): Likewise.
6205 (gdb_reattached_process): Remove.
6206 (handle_status): Adjust.
6207 (kill_inferior_callback): Likewise.
6208 (detach_or_kill_inferior): Remove.
6209 (print_started_pid): Likewise.
6210 (print_attached_pid): Likewise.
6211 (detach_or_kill_for_exit): Update.
6212 (process_serial_event): Likewise.
6213 * linux-arm-low.c (arm_new_fork): Likewise.
6215 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6217 * dll.h: Include <list>.
6218 (struct dll_info): Add constructor.
6219 <entry>: Remove field.
6220 (all_dlls): Change type to std::list<dll_info>.
6221 * dll.c: Include <algorithm>.
6222 (get_dll): Remove macro.
6223 (all_dlls): Change type to std::list<dll_info *>.
6224 (free_one_dll): Remove.
6225 (match_dll): Likewise.
6226 (loaded_dll): Adjust.
6227 (unloaded_dll): Adjust to all_dlls type change, use
6228 std::find_if. Inline code from match_dll.
6229 (clear_dlls): Adjust to all_dlls type change.
6230 * server.c (emit_dll_description): Remove.
6231 (handle_qxfer_libraries): Adjust to all_dlls type change,
6232 integrate emit_dll_description's functionality.
6234 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6236 * linux-low.h (struct linux_target_ops) <delete_process>: New
6238 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6239 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6240 (struct linux_target_ops): Add delete_process callback.
6241 * linux-arm-low.c (arm_delete_process): New.
6242 (struct linux_target_ops): Add delete_process callback.
6243 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6244 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6245 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6246 * linux-mips-low.c (mips_linux_delete_process): New.
6247 (struct linux_target_ops): Add delete_process callback.
6248 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6249 * linux-s390-low.c (struct linux_target_ops): Likewise.
6250 * linux-sh-low.c (struct linux_target_ops): Likewise.
6251 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6252 * linux-tile-low.c (struct linux_target_ops): Likewise.
6253 * linux-x86-low.c (x86_linux_delete_process): New.
6254 (struct linux_target_ops): Add delete_process callback.
6255 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6257 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6259 * linux-aarch64-low.c (the_low_target): Add thread delete
6261 * linux-arm-low.c (arm_delete_thread): New function.
6262 (the_low_target): Add thread delete callback.
6263 * linux-bfin-low.c (the_low_target): Likewise.
6264 * linux-crisv32-low.c (the_low_target): Likewise.
6265 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6267 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6269 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6270 * linux-mips-low.c (mips_linux_delete_thread): New function.
6271 (the_low_target): Add thread delete callback.
6272 * linux-ppc-low.c (the_low_target): Likewise.
6273 * linux-s390-low.c (the_low_target): Likewise.
6274 * linux-sh-low.c (the_low_target): Likewise.
6275 * linux-tic6x-low.c (the_low_target): Likewise.
6276 * linux-tile-low.c (the_low_target): Likewise.
6277 * linux-x86-low.c (the_low_target): Likewise.
6278 * linux-xtensa-low.c (the_low_target): Likewise.
6280 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6282 * win32-low.c: Include "common-inferior.h".
6284 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6286 * inferiors.c (set_inferior_cwd): New function.
6287 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6288 (handle_query): Inform that QSetWorkingDir is supported.
6289 * win32-low.c (create_process): Pass the inferior's cwd to
6292 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6294 * inferiors.c (current_inferior_cwd): New global variable.
6295 (get_inferior_cwd): New function.
6296 * inferiors.h (struct process_info) <cwd>: New field.
6298 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6300 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6301 (OBS): Add gdb_tilde_expand.o.
6303 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6305 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6306 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6308 2017-09-29 Pedro Alves <palves@redhat.com>
6310 * ax.c (gdb_parse_agent_expr): Constify.
6311 * ax.h (gdb_parse_agent_expr): Constify.
6312 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6314 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6315 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6316 * remote-utils.h (read_ptid): Constify.
6317 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6318 (process_point_options, process_serial_event): Constify.
6319 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6320 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6321 (cmd_qtbuffer): Constify.
6323 2017-09-29 Pedro Alves <palves@redhat.com>
6325 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6328 2017-09-29 Pedro Alves <palves@redhat.com>
6330 * linux-low.c (handle_extended_wait): Pass parent thread instead
6331 of process to thread_db_notice_clone.
6332 * linux-low.h (thread_db_notice_clone): Replace parent process
6333 parameter with parent thread parameter.
6334 * thread-db.c (find_one_thread): Add comment.
6335 (thread_db_notice_clone): Replace parent process parameter with
6336 parent thread parameter. Temporarily switch to the parent thread.
6338 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6340 * gdbthread.h: Include "common-gdbthread.h".
6341 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6342 "if" when validating the ptid.
6343 * remote-utils.c: Include "gdbthread.h".
6344 (prepare_resume_reply): Use "switch_to_thread".
6345 * target.c (done_accessing_memory): Likewise.
6347 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6349 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6350 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6351 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6352 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6353 s390x-gs-linux64-ipa.o to ipa_obj.
6354 * linux-s390-low.c (HWCAP_S390_GS): New define.
6355 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6357 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6358 (s390_arch_setup): Check for guarded-storage support and choose
6360 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6361 init_registers_s390x_gs_linux64.
6362 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6364 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6365 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6367 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6369 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6371 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6373 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6374 (thread_db_thread_handle): Declare.
6375 * linux-low.c (linux_target_ops): Initialize thread_handle.
6376 * server.c (handle_qxfer_threads_worker): Add support for
6378 * target.h (struct target_ops): Add new function pointer,
6380 (target_thread_handle): Define.
6381 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6383 (thread_db_thread_handle): New function.
6385 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6387 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6388 * linux-low.h (thread_db_notice_clone): Declare.
6389 * thread-db.c (thread_db_notice_clone): New function.
6391 2017-09-21 Pedro Alves <palves@redhat.com>
6393 * server.c (gdb_read_memory, handle_status, process_serial_event)
6394 (handle_serial_event, handle_target_event): Adjust to
6395 set_desired_thread prototype change.
6396 * target.c (set_desired_thread): Remove 'use_general' parameter
6398 * target.h (set_desired_thread): Remove 'use_general' parameter.
6400 2017-09-20 Tom Tromey <tom@tromey.com>
6402 * target.c (target_terminal::terminal_state): Define.
6403 (target_terminal::init): Rename from target_terminal_init.
6404 (target_terminal::inferior): Rename from
6405 target_terminal_inferior.
6406 (target_terminal::ours): Rename from target_terminal_ours.
6407 (target_terminal::ours_for_output, target_terminal::info): New.
6409 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6411 * server.c (accumulate_file_name_length): Remove.
6412 (emit_dll_description): Adjust to std::string change.
6413 (handle_qxfer_libraries): Use std::string to hold document.
6415 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6417 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6418 return type of xml_escape_text.
6419 * server.c (emit_dll_description): Likewise.
6421 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6423 * server.c (captured_main): Accept argument for --selftest.
6424 Update run_tests call.
6425 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6426 when registering selftests.
6428 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6430 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6431 instead of "VEC" for "target_desc.reg_defs".
6432 (regcache_cpy): Likewise.
6433 (registers_to_string): Likewise.
6434 (registers_from_string): Likewise.
6435 (find_regno): Likewise.
6436 (supply_regblock): Likewise.
6437 (regcache_raw_read_unsigned): Likewise.
6438 * tdesc.c (init_target_desc): Likewise.
6439 (tdesc_create_reg): Likewise.
6440 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6441 (struct target_desc) <reg_defs>: Convert to "std::vector".
6442 (target_desc): Do not initialize "reg_defs".
6443 (~target_desc): Update code to use "std::vector" instead of "VEC"
6444 for "target_desc.reg_defs".
6445 (operator==): Likewise.
6447 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6449 * inferiors.h (thread_to_gdb_id): Remove.
6450 * inferiors.c (thread_to_gdb_id): Remove.
6451 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6452 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6453 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6455 * nto-low.c (nto_fetch_registers, nto_store_registers,
6456 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6458 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6460 * inferiors.h (gdb_id_to_thread_id): Remove.
6461 * inferiors.c (gdb_id_to_thread_id): Remove.
6462 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6463 removal. Move pid declaration closer to where it's used.
6465 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6467 * server.c (handle_detach): New function.
6468 (process_serial_event): Move code out, call handle_detach.
6470 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6472 * server.c (require_running): Rename to ...
6473 (require_running_or_return): ... this ...
6474 (require_running_or_break): ... and this.
6475 (handle_query, process_serial_event): Adjust.
6477 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6479 * linux-low.c (linux_set_resume_request): Remove unused
6482 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6484 * server.c (first_thread_of): Remove.
6485 (process_serial_event): Replace usage of first_thread_of with
6486 find_any_thread_of_pid.
6487 * tracepoint.c (same_process_p): Remove.
6488 (gdb_agent_about_to_close): Replace usage of same_process_p with
6489 find_any_thread_of_pid.
6490 * linux-x86-low.c (same_process_callback): Remove.
6491 (x86_arch_setup_process_callback): Replace usage of
6492 same_process_callback with find_any_thread_of_pid.
6493 * thread-db.c (any_thread_of): Remove.
6494 (switch_to_process): Replace usage of any_thread_of with
6495 find_any_thread_of_pid.
6496 * inferiors.c (thread_pid_matches_callback): Remove.
6497 (find_thread_process): Adjust to use find_any_thread_of_pid.
6499 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6501 * regcache.c (get_thread_regcache): Guard calls to "memset"
6504 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6506 * linux-low.c (handle_extended_wait): Use
6507 "allocate_target_description" instead of "XNEW".
6508 * linux-x86-low.c (initialize_low_arch): Likewise.
6510 2017-09-05 Yao Qi <yao.qi@linaro.org>
6512 * configure.srv (srv_i386_regobj): Remove.
6513 (srv_amd64_regobj): Remove.
6514 (srv_regobj): Set it to "" for x86 non-linux targets.
6515 * linux-x86-tdesc.c (i386_linux_read_description):
6516 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6517 (init_registers_i386): Remove the declaration.
6518 (tdesc_i386): Remove the declaration.
6519 (lynx_i386_arch_setup): Call i386_create_target_description.
6520 * nto-x86-low.c: Likewise.
6521 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6522 [!__x86_64__]: include arch/i386.h.
6523 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6525 2017-09-05 Yao Qi <yao.qi@linaro.org>
6527 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6528 i386/amd64-XXX-linux from it.
6530 2017-09-05 Yao Qi <yao.qi@linaro.org>
6532 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6534 (ipa_amd64_linux_regobj): Remove.
6535 (ipa_x32_linux_regobj): Remove.
6537 2017-09-05 Yao Qi <yao.qi@linaro.org>
6539 * Makefile.in (arch-amd64.o): New rule.
6540 * configure.srv: Append arch-amd64.o.
6541 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6542 (get_ipa_tdesc): Call amd64_linux_read_description.
6543 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6544 and init_registers_amd64_XXX.
6545 * linux-x86-low.c (x86_linux_read_description): Call
6546 amd64_linux_read_description.
6547 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6548 (initialize_low_arch): Don't call init_registers_x32_XXX and
6549 init_registers_amd64_XXX.
6550 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6551 and tdesc_amd64_XXX.
6552 [__x86_64__] (amd64_tdesc_test): New function.
6553 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6554 and init_registers_amd64_XXX.
6555 * linux-x86-tdesc.c: Include arch/amd64.h.
6556 (xcr0_to_tdesc_idx): New function.
6557 (i386_linux_read_description): New function.
6558 (amd64_get_ipa_tdesc_idx): New function.
6559 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6560 (amd64_get_ipa_tdesc): Declare.
6562 2017-09-05 Yao Qi <yao.qi@linaro.org>
6564 * configure.srv (srv_i386_linux_xmlfiles): Remove
6565 i386/i386-XXX-linux.xml from it.
6567 2017-09-05 Yao Qi <yao.qi@linaro.org>
6569 * configure.srv: Set srv_i386_linux_regobj empty if $development
6571 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6572 initialize_low_tdesc.
6573 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6574 with #if initialize_low_tdesc.
6575 * linux-x86-tdesc-selftest.c: New file.
6576 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6578 2017-09-05 Yao Qi <yao.qi@linaro.org>
6580 * Makefile.in (arch-i386.o): New rule.
6581 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6582 (x86_64-*-linux*): Likewise.
6583 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6584 include arch/i386.h.
6585 (i386_linux_read_description): Remove code and call
6586 i386_create_target_description.
6587 * tdesc.c (allocate_target_description): New function.
6588 * tdesc.h (set_tdesc_architecture): Remove declaration.
6589 (set_tdesc_osabi): Likewise.
6591 2017-09-05 Yao Qi <yao.qi@linaro.org>
6593 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6594 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6595 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6597 * server.c (get_features_xml): Call tdesc_get_features_xml.
6598 * tdesc.c (set_tdesc_architecture): New function.
6599 (set_tdesc_osabi): New function.
6600 (tdesc_get_features_xml): New function.
6601 (tdesc_create_feature): Add an argument.
6602 * tdesc.h (struct target_desc) <features>: New field.
6603 <arch, osabi>: New field.
6604 (~target_desc): xfree features, arch, and osabi.
6605 (target_desc::oerator==): Don't compare .xmltarget.
6606 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6607 (set_tdesc_osabi): Likewise.
6608 (tdesc_get_features_xml): Likewise.
6610 2017-09-05 Yao Qi <yao.qi@linaro.org>
6612 * linux-x86-tdesc.c: Include selftest.h.
6613 (i386_tdesc_test): New function.
6614 (initialize_low_tdesc): Call selftests::register_test.
6615 * tdesc.h: Include regdef.h.
6616 (target_desc): Override operator == and !=.
6618 2017-09-05 Yao Qi <yao.qi@linaro.org>
6620 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6621 (ipa_obj): Likewise.
6622 * linux-i386-ipa.c: Include common/x86-xstate.h
6623 (get_ipa_tdesc): Call i386_linux_read_description.
6624 (initialize_low_tracepoint): Don't call init_registers_XXX
6625 functions, call initialize_low_tdesc instead.
6626 * linux-x86-low.c (x86_linux_read_description): Call
6627 i386_linux_read_description.
6628 (initialize_low_arch): Don't call init_registers_i386_XXX
6629 functions, call initialize_low_tdesc.
6630 * linux-x86-tdesc.c: New file.
6631 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6632 (i386_get_ipa_tdesc_idx): Declare.
6633 (i386_get_ipa_tdesc): Declare.
6634 (initialize_low_tdesc): Declare.
6636 2017-09-05 Yao Qi <yao.qi@linaro.org>
6638 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6641 2017-09-05 Yao Qi <yao.qi@linaro.org>
6643 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6644 * regcache.c (get_thread_regcache): Use VEC_length.
6645 (init_register_cache): Likewise.
6646 (regcache_cpy): Likewise.
6647 (registers_to_string): Iterate reg_defs via VEC_iterate.
6648 (find_regno): Likewise.
6649 (find_register_by_number): Use VEC_index.
6650 (register_size): Call find_register_by_number.
6651 (register_data): Call find_register_by_number.
6652 (supply_regblock): Use VEC_length.
6653 (regcache_raw_read_unsigned): Likewise.
6654 * tdesc.c (init_target_desc): Iterate reg_defs via
6656 (default_description): Update initializer.
6657 (copy_target_description): Don't update field num_registers.
6658 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6659 <num_registers>: Remove.
6661 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6663 * Makefile.in (.SECONDARY): Define target.
6665 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6667 * linux-low.c (linux_wait_1): Adjust.
6668 * server.c (queue_stop_reply_callback): Adjust.
6670 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6672 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6673 QEnvironmentUnset and QEnvironmentReset packets.
6674 (handle_query): Inform remote that QEnvironmentHexEncoded,
6675 QEnvironmentUnset and QEnvironmentReset are supported.
6677 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6679 * inferiors.h (inferior_target_data): Rename to ...
6680 (thread_target_data): ... this.
6681 (inferior_regcache_data): Rename to ...
6682 (thread_regcache_data): ... this.
6683 (set_inferior_regcache_data): Rename to ...
6684 (set_thread_regcache_data): ... this.
6685 * inferiors.c (inferior_target_data): Rename to ...
6686 (thread_target_data): ... this.
6687 (inferior_regcache_data): Rename to ...
6688 (thread_regcache_data): ... this.
6689 (set_inferior_regcache_data): Rename to ...
6690 (set_thread_regcache_data): ... this.
6691 (free_one_thread): Update.
6692 * linux-low.h (get_thread_lwp): Update.
6693 * regcache.c (get_thread_regcache): Update.
6694 (regcache_invalidate_thread): Update.
6695 (free_register_cache_thread): Update.
6696 * win32-i386-low.c (update_debug_registers_callback): Update.
6697 (win32_get_current_dr): Update.
6698 * win32-low.c (thread_rec): Update.
6699 (delete_thread_info): Update.
6700 (continue_one_thread): Update.
6701 (suspend_one_thread): Update.
6703 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6705 * inferiors.c (set_inferior_target_data): Remove.
6706 * inferiors.h (set_inferior_target_data): Remove.
6708 2017-08-18 Yao Qi <yao.qi@linaro.org>
6710 * Makefile.in (OBS): Add selftest.o.
6711 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6712 * configure, config.in: Re-generated.
6713 * server.c: Include common/sefltest.h.
6714 (captured_main): Handle option --selftest.
6716 2017-08-09 Yao Qi <yao.qi@linaro.org>
6718 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6719 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6720 i386-avx-mpx.o and i386-mmx.o.
6721 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6722 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6723 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6724 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6725 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6726 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6727 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6728 i386/amd64-avx-mpx.xml.
6730 2017-08-09 Yao Qi <yao.qi@linaro.org>
6732 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6733 and x32-avx-avx512.o.
6734 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6735 i386/x32-avx-avx512.xml.
6737 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6739 * tracepoint.h (enum class fast_tpoint_collect_result): New
6741 (fast_tracepoint_collecting): Change return type to
6742 fast_tpoint_collect_result.
6743 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6744 * linux-low.h: Include tracepoint.h.
6745 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6746 fast_tpoint_collect_result.
6747 * linux-low.c (handle_tracepoints): Adjust.
6748 (linux_fast_tracepoint_collecting): Change return type to
6749 fast_tpoint_collect_result.
6750 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6751 linux_wait_1, stuck_in_jump_pad_callback,
6752 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6753 proceed_one_lwp): Adjust to type change.
6755 2017-07-10 Yao Qi <yao.qi@linaro.org>
6757 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6759 2017-06-29 Yao Qi <yao.qi@linaro.org>
6761 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6763 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6765 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6767 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6769 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6771 * linux-low.c (linux_create_inferior): Adjust code to access the
6772 environment information via 'gdb_environ' class.
6773 * lynx-low.c (lynx_create_inferior): Likewise.
6774 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6775 (get_environ): Return a pointer to 'our_environ'.
6776 (captured_main): Initialize 'our_environ'.
6777 * server.h (get_environ): Adjust prototype.
6778 * spu-low.c (spu_create_inferior): Adjust code to access the
6779 environment information via 'gdb_environ' class.
6781 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6783 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6784 usage of "register" keyword.
6786 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6788 * configure: Re-generate.
6790 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6792 * configure: Re-generate.
6794 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6796 * Makefile.in (COMPILE.pre): Add "-x c++".
6798 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6800 * fork-child.c: Conditionally include <signal.h>.
6802 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6804 * server.c (handle_general_set): Handle new packet
6805 "QStartupWithShell".
6806 (handle_query): Add "QStartupWithShell" to the list of supported
6808 (gdbserver_usage): Add help text explaining the
6809 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6811 (captured_main): Recognize and act upon the presence of the new
6814 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6815 Pedro Alves <palves@redhat.com>
6817 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6818 * configure: Regenerate.
6819 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6821 (i[34567]86-*-lynxos*): Likewise.
6822 (spu*-*-*): Likewise.
6823 * fork-child.c: New file.
6824 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6826 (linux_ptrace_fun): New function.
6827 (linux_create_inferior): Adjust function prototype to reflect
6828 change on "target.h". Adjust function code to use
6830 (linux_request_interrupt): Delete "signal_pid".
6831 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6832 (lynx_ptrace_fun): New function.
6833 (lynx_create_inferior): Adjust function prototype to reflect
6834 change on "target.h". Adjust function code to use
6836 * nto-low.c (nto_create_inferior): Adjust function prototype and
6837 code to reflect change on "target.h". Update comments.
6838 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6839 "common-terminal.h" and "environ.h".
6840 (terminal_fd): Moved to fork-child.c.
6841 (old_foreground_pgrp): Likewise.
6842 (restore_old_foreground_pgrp): Likewise.
6843 (last_status): Make it global.
6844 (last_ptid): Likewise.
6845 (our_environ): New variable.
6846 (startup_with_shell): Likewise.
6847 (program_name): Likewise.
6848 (program_argv): Rename to...
6849 (program_args): ...this.
6850 (wrapper_argv): New variable.
6851 (start_inferior): Delete function.
6852 (get_exec_wrapper): New function.
6853 (get_exec_file): Likewise.
6854 (get_environ): Likewise.
6855 (prefork_hook): Likewise.
6856 (post_fork_inferior): Likewise.
6857 (postfork_hook): Likewise.
6858 (postfork_child_hook): Likewise.
6859 (handle_v_run): Update code to deal with arguments coming from the
6860 remote host. Update calls from "start_inferior" to
6862 (captured_main): Likewise. Initialize environment variable. Call
6864 * server.h (post_fork_inferior): New prototype.
6865 (get_environ): Likewise.
6866 (last_status): Declare.
6867 (last_ptid): Likewise.
6868 (signal_pid): Likewise.
6869 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6870 (spu_ptrace_fun): New function.
6871 (spu_create_inferior): Adjust function prototype to reflect change
6872 on "target.h". Adjust function code to use "fork_inferior".
6873 * target.c (target_terminal_init): New function.
6874 (target_terminal_inferior): Likewise.
6875 (target_terminal_ours): Likewise.
6876 * target.h: Include <vector>.
6877 (struct target_ops) <create_inferior>: Update prototype.
6878 (create_inferior): Update macro.
6879 * utils.c (gdb_flush_out_err): New function.
6880 * win32-low.c (win32_create_inferior): Adjust function prototype
6881 and code to reflect change on "target.h".
6883 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6885 * inferiors.c (switch_to_thread): New function.
6887 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6889 * Makefile.in (SFILE): Add "common/job-control.c".
6890 (OBS): Add "job-control.o".
6892 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6894 * Makefile: Remove "@host_makefile_frag@".
6896 2017-05-05 Pedro Alves <palves@redhat.com>
6898 * configure: Regenerate.
6900 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6902 * configure: Regenerate.
6904 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6906 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
6907 software_single_step change of return type to
6908 std::vector<CORE_ADDR>.
6909 * linux-low.c (install_software_single_step_breakpoints):
6911 * linux-low.h (install_software_single_step_breakpoints):
6914 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6916 * remote-utils.c: Include "gdb_termios.h" instead of
6918 * terminal.h: Delete file.
6920 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6922 * server.c: Include <vector>.
6923 <program_argv, wrapper_argv>: Convert to std::vector.
6924 (start_inferior): Rewrite function to use C++.
6925 (handle_v_run): Likewise. Update code that calculates the argv
6926 based on the vRun packet; use C++.
6927 (captured_main): Likewise.
6929 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
6931 * server.c (handle_v_cont): Initialize thread_resume::thread
6934 2017-04-05 Pedro Alves <palves@redhat.com>
6936 * configure: Regenerate.
6938 2017-04-05 Pedro Alves <palves@redhat.com>
6940 * gdbreplay.c (sync_error): Constify.
6941 * linux-x86-low.c (push_opcode): Constify.
6943 2017-04-05 Pedro Alves <palves@redhat.com>
6945 * win32-low.c (get_child_debug_event)
6946 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
6947 Report TARGET_WAITKIND_SPURIOUS instead.
6949 2017-04-05 Pedro Alves <palves@redhat.com>
6951 * remote-utils.c (remote_prepare, remote_open): Constify.
6952 * remote-utils.h (remote_prepare, remote_open): Constify.
6953 * server.c (captured_main): Constify 'port' handling.
6955 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
6957 * Makefile.in (clean): Clear .deps.
6959 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
6961 * .gitignore: Remove generated files, replace with wildcard.
6962 * (clean): Replace removal of generated files with wildcard.
6963 (version.c): Replace with...
6964 (version-generated.c): ...this.
6965 (xml-builtin.c): Replace with...
6966 (xml-builtin-generated.c): ...this.
6967 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
6968 (%.c: *regformats*): Replace with...
6969 (%-generated.c: *regformats*): ...this.
6971 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
6973 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
6974 (xtensa_fill_gregset): Call collect_register_by_name for
6976 (xtensa_store_gregset): Call supply_register_by_name for
6979 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
6981 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
6982 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
6983 (xtensa_store_gregset): Call supply_register for all registers in
6984 a0_regnum..a0_regnum + C0_NREGS range.
6986 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6988 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
6989 (ax-ipa.o: ax.c): Remove.
6990 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
6991 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
6992 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
6993 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
6994 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
6996 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6998 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
6999 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7000 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7001 (errors-ipa.o: ../common/errors.c): Remove.
7002 (format-ipa.o: ../common/format.c): Remove.
7003 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7005 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7007 * Makefile.in (%-ipa.o: %.c): New rule.
7008 (tracepoint-ipa.o: tracepoint.c): Remove.
7009 (utils-ipa.o: utils.c): Remove.
7010 (remote-utils-ipa.o: remote-utils.c): Remove.
7011 (regcache-ipa.o: regcache.c): Remove.
7012 (i386-linux-ipa.o: i386-linux.c): Remove.
7013 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7014 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7015 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7016 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7017 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7018 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7019 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7020 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7021 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7022 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7023 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7024 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7025 (aarch64-ipa.o: aarch64.c): Remove.
7026 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7027 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7028 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7029 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7030 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7031 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7032 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7033 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7034 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7035 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7036 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7037 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7038 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7039 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7040 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7041 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7042 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7043 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7044 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7045 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7046 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7047 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7048 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7049 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7050 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7051 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7052 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7053 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7054 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7055 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7056 (tdesc-ipa.o: tdesc.c): Remove.
7057 (x32-linux-ipa.o: x32-linux.c): Remove.
7058 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7059 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7061 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7063 * Makefile.in (%.o: ../arch/%.c): New rule.
7064 (arm.o: ../arch/arm.c): Remove.
7065 (arm-linux.o: ../arch/arm-linux.c): Remove.
7066 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7067 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7069 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7071 * Makefile.in (%.o: ../nat/%.c): New rule.
7072 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7073 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7074 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7075 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7076 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7077 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7078 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7079 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7080 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7081 (linux-personality.o: ../nat/linux-personality.c): Remove.
7082 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7083 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7084 (x86-linux.o: ../nat/x86-linux.c): Remove.
7085 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7086 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7088 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7090 * Makefile.in (%.o: ../common/%.c): New rule.
7091 (signals.o: ../common/signals.c): Remove.
7092 (print-utils.o: ../common/print-utils.c): Remove.
7093 (rsp-low.o: ../common/rsp-low.c): Remove.
7094 (common-utils.o: ../common/common-utils.c): Remove.
7095 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7096 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7097 (vec.o: ../common/vec.c): Remove.
7098 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7099 (xml-utils.o: ../common/xml-utils.c): Remove.
7100 (ptid.o: ../common/ptid.c): Remove.
7101 (buffer.o: ../common/buffer.c): Remove.
7102 (format.o: ../common/format.c): Remove.
7103 (filestuff.o: ../common/filestuff.c): Remove.
7104 (agent.o: ../common/agent.c): Remove.
7105 (errors.o: ../common/errors.c): Remove.
7106 (environ.o: ../common/environ.c): Remove.
7107 (common-debug.o: ../common/common-debug.c): Remove.
7108 (cleanups.o: ../common/cleanups.c): Remove.
7109 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7110 (fileio.o: ../common/fileio.c): Remove.
7111 (common-regcache.o: ../common/common-regcache.c): Remove.
7112 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7113 (new-op.o: ../common/new-op.c): Remove.
7114 (btrace-common.o: ../common/btrace-common.c): Remove.
7116 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7118 * Makefile.in (%.o: ../target/%.c): New rule.
7119 (waitstatus.o: ../target/waitstatus.c): Remove.
7121 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7124 (%.c: ../regformats/%.dat,
7125 (%.c: ../regformats/arm/%.dat,
7126 (%.c: ../regformats/i386/%.dat,
7127 (%.c: ../regformats/rs6000/%.dat): New rules.
7128 (aarch64.c): Remove.
7129 (reg-arm.c): Remove.
7130 (arm-with-iwmmxt.c): Remove.
7131 (arm-with-vfpv2.c): Remove.
7132 (arm-with-vfpv3.c): Remove.
7133 (arm-with-neon.c): Remove.
7134 (reg-bfin.c): Remove.
7135 (reg-cris.c): Remove.
7136 (reg-crisv32.c): Remove.
7138 (i386-linux.c): Remove.
7139 (i386-avx.c): Remove.
7140 (i386-avx-linux.c): Remove.
7141 (i386-avx-avx512.c): Remove.
7142 (i386-avx-avx512-linux.c): Remove.
7143 (i386-mpx.c): Remove.
7144 (i386-mpx-linux.c): Remove.
7145 (i386-avx-mpx-avx512-pku.c): Remove.
7146 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7147 (i386-avx-mpx.c): Remove.
7148 (i386-avx-mpx-linux.c): Remove.
7149 (i386-mmx.c): Remove.
7150 (i386-mmx-linux.c): Remove.
7151 (reg-ia64.c): Remove.
7152 (reg-m32r.c): Remove.
7153 (reg-m68k.c): Remove.
7155 (mips-linux.c): Remove.
7156 (mips-dsp-linux.c): Remove.
7157 (mips64-linux.c): Remove.
7158 (mips64-dsp-linux.c): Remove.
7159 (nios2-linux.c): Remove.
7160 (powerpc-32.c): Remove.
7161 (powerpc-32l.c): Remove.
7162 (powerpc-altivec32l.c): Remove.
7163 (powerpc-cell32l.c): Remove.
7164 (powerpc-vsx32l.c): Remove.
7165 (powerpc-isa205-32l.c): Remove.
7166 (powerpc-isa205-altivec32l.c): Remove.
7167 (powerpc-isa205-vsx32l.c): Remove.
7168 (powerpc-e500l.c): Remove.
7169 (powerpc-64l.c): Remove.
7170 (powerpc-altivec64l.c): Remove.
7171 (powerpc-cell64l.c): Remove.
7172 (powerpc-vsx64l.c): Remove.
7173 (powerpc-isa205-64l.c): Remove.
7174 (powerpc-isa205-altivec64l.c): Remove.
7175 (powerpc-isa205-vsx64l.c): Remove.
7176 (s390-linux32.c): Remove.
7177 (s390-linux32v1.c): Remove.
7178 (s390-linux32v2.c): Remove.
7179 (s390-linux64.c): Remove.
7180 (s390-linux64v1.c): Remove.
7181 (s390-linux64v2.c): Remove.
7182 (s390-te-linux64.c): Remove.
7183 (s390-vx-linux64.c): Remove.
7184 (s390-tevx-linux64.c): Remove.
7185 (s390x-linux64.c): Remove.
7186 (s390x-linux64v1.c): Remove.
7187 (s390x-linux64v2.c): Remove.
7188 (s390x-te-linux64.c): Remove.
7189 (s390x-vx-linux64.c): Remove.
7190 (s390x-tevx-linux64.c): Remove.
7191 (tic6x-c64xp-linux.c): Remove.
7192 (tic6x-c64x-linux.c): Remove.
7193 (tic6x-c62x-linux.c): Remove.
7195 (reg-sparc64.c): Remove.
7196 (reg-spu.c): Remove.
7198 (amd64-linux.c): Remove.
7199 (amd64-avx.c): Remove.
7200 (amd64-avx-linux.c): Remove.
7201 (amd64-avx-avx512.c): Remove.
7202 (amd64-avx-avx512-linux.c): Remove.
7203 (amd64-mpx.c): Remove.
7204 (amd64-mpx-linux.c): Remove.
7205 (amd64-avx-mpx-avx512-pku.c): Remove.
7206 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7207 (amd64-avx-mpx.c): Remove.
7208 (amd64-avx-mpx-linux.c): Remove.
7210 (x32-linux.c): Remove.
7211 (x32-avx.c): Remove.
7212 (x32-avx-linux.c): Remove.
7213 (x32-avx-avx512.c): Remove.
7214 (x32-avx-avx512-linux.c): Remove.
7215 (reg-xtensa.c): Remove.
7216 (reg-tilegx.c): Remove.
7217 (reg-tilegx32.c): Remove.
7219 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7221 * Makefile.in (SFILES): Add "common/environ.c".
7222 (OBJS): Add "common/environ.h".
7224 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7226 * configure.ac: Check if the fs_base and gs_base members of
7227 `struct user_regs_struct' exist.
7228 * config.in: Regenerated.
7229 * configure: Likewise.
7231 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7233 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7235 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7236 (get_next_pcs_syscall_next_pc): Likewise.
7238 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7240 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7241 * nto-x86-low.c: Likewise.
7243 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7245 * Makefile.in: Include disable-implicit-rules.mk.
7247 2016-11-23 Pedro Alves <palves@redhat.com>
7249 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7250 (debug_vprintf): Use std::chrono::steady_clock instead of
7251 gettimeofday. Use '.' instead of ':'.
7252 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7253 (get_timestamp): Use std::chrono::steady_clock instead of
7256 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7258 * Makefile.in: Fix whitespace formatting.
7260 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7262 * Makefile.in (SFILES, OBS): Flatten list and order
7265 2016-11-23 Pedro Alves <palves@redhat.com>
7267 * event-loop.c (handle_file_event): Use warning.
7268 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7269 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7272 2016-11-23 Pedro Alves <palves@redhat.com>
7274 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7276 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7277 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7278 debug_printf and debug_flush for debug output.
7279 * server.c (handle_general_set): Likewise.
7280 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7283 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7285 * Makefile.in (.c.o): Replace rule with ...
7286 (%.o: %.c): ... this one.
7288 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7290 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7291 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7293 * configure.ac: Remove checks for the make program.
7294 * configure: Re-generate.
7296 2016-10-28 Pedro Alves <palves@redhat.com>
7298 * Makefile.in (CXX_DIALECT): Get from configure.
7299 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7300 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7301 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7302 * config.in: Regenerate.
7303 * configure: Regenerate.
7305 2016-10-27 Yao Qi <yao.qi@linaro.org>
7307 * linux-low.c (linux_supports_range_stepping): Return true if
7308 can_software_single_step return true.
7310 2016-10-27 Yao Qi <yao.qi@linaro.org>
7312 * inferiors.c (find_inferior_in_random): New function.
7313 * inferiors.h (find_inferior_in_random): Declare.
7314 * linux-low.c (linux_wait_for_event_filtered): Call
7315 find_inferior_in_random instead of find_inferior.
7317 2016-10-27 Yao Qi <yao.qi@linaro.org>
7319 * linux-low.c (linux_wait_1): If single-step breakpoints are
7320 inserted, remove them.
7322 2016-10-26 Pedro Alves <palves@redhat.com>
7324 * linux-low.c (handle_extended_wait): Link parent/child fork
7326 (linux_wait_1): Unlink them.
7327 (linux_set_resume_request): Ignore resume requests for
7328 already-resumed and unhandled fork child threads.
7329 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7330 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7332 (handle_v_requests) <vCont>: Don't call require_running.
7333 * server.h (in_queued_stop_replies): New declaration.
7335 2016-10-24 Yao Qi <yao.qi@linaro.org>
7338 * linux-aarch64-low.c (append_insns): Cast the return value to
7341 2016-10-10 Yao Qi <yao.qi@linaro.org>
7343 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7345 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7347 * target.c (target_supports_multi_process): New function, moved
7349 * target.h (target_supports_multi_process): ... here. Remove
7352 2016-10-05 Tom Tromey <tom@tromey.com>
7355 * tracepoint.c (handle_tracepoint_bkpts): Check
7356 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7358 2016-10-05 Yao Qi <yao.qi@linaro.org>
7360 * configure.srv: Update the path of arm-*.xml files.
7362 2016-10-05 Terry Guo <terry.guo@arm.com>
7363 Yao Qi <yao.qi@linaro.org>
7365 * Makefile.in: Adjust the path of rules.
7366 * configure.srv: Update the path of xml files.
7367 * regformats/arm-with-iwmmxt.dat: Regenerated.
7368 * regformats/arm-with-neon.dat: Likewise.
7369 * regformats/arm-with-vfpv2.dat: Likewise.
7370 * regformats/arm-with-vfpv3.dat Likewise.
7372 2016-09-30 Yao Qi <yao.qi@linaro.org>
7375 * target.c (target_stop_and_wait): Don't call
7376 target_continue_no_signal, use resume_stop instead.
7378 2016-09-26 Yao Qi <yao.qi@linaro.org>
7380 * linux-low.c (linux_wait_1): Call debug_exit.
7382 2016-09-23 Pedro Alves <palves@redhat.com>
7384 * Makefile.in (SFILES): Add common/new-op.c.
7385 (OBS): Add common/new-op.o.
7386 (new-op.o): New rule.
7388 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7390 * .gitinore: Ignore more files.
7392 2016-09-21 Yao Qi <yao.qi@linaro.org>
7394 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7397 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7399 * server.c (start_inferior): Call target_mourn_inferior instead of
7400 mourn_inferior; pass ptid_t argument to it.
7402 (handle_target_event): Likewise.
7403 * target.c (target_mourn_inferior): New function.
7404 * target.h (mourn_inferior): Delete macro.
7406 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7408 * linux-low.c (lwp_is_stepping): New function.
7410 2016-09-06 Carl Love <cel@us.ibm.com>
7412 * server.c (start_inferior): Fixed comment, requested comment change
7413 didn't get updated correctly. Removed reference to ptrace () call as
7414 it is only true on Linux systems.
7416 2016-09-06 Carl Love <cel@us.ibm.com>
7418 * server.c (start_inferior): Do not call
7419 function target_post_create_inferior () if the
7420 inferior process has already exited.
7422 2016-09-05 Pedro Alves <palves@redhat.com>
7424 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7425 (COMPILE.pre, CC_LD): Use CXX directly.
7426 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7427 * acinclude.m4: Don't include build-with-cxx.m4.
7428 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7429 * configure: Regenerate.
7431 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7434 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7435 call writing data to own_buf.
7437 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7439 * target.c (mywait): Call target_wait instead of
7441 (target_wait): New function.
7443 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7445 * server.c (start_inferior): New variable 'ptid'. Replace calls
7446 to the_target->resume by target_continue{,_no_signal}, depending
7448 * target.c (target_stop_and_wait): Call target_continue_no_signal
7449 instead of the_target->resume.
7450 (target_continue): New function.
7452 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7454 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7456 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7459 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7461 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7462 * linux-arm-low.c (ps_get_thread_area): Likewise.
7463 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7464 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7465 * linux-mips-low.c (ps_get_thread_area): Likewise.
7466 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7467 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7468 * linux-x86-low.c (ps_get_thread_area): Likewise.
7469 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7471 2016-08-19 Pedro Alves <palves@redhat.com>
7473 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7475 2016-08-19 Pedro Alves <palves@redhat.com>
7477 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7478 comment. Use memcpy instead of casting through unsigned long.
7480 2016-08-19 Pedro Alves <palves@redhat.com>
7482 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7483 allocating around 0x80000000.
7485 2016-08-19 Pedro Alves <palves@redhat.com>
7488 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7489 (x32-avx512-linux-ipa.o): New rules.
7490 * configure.ac (x86_64-*-linux*): New x32 check.
7491 * configure.srv (ipa_x32_linux_regobj): New.
7492 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7493 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7495 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7497 * configure: Regenerate.
7499 2016-08-09 Pedro Alves <palves@redhat.com>
7502 * Makefile.in (OBS): Add signals-state-save-restore.o.
7503 (signals-state-save-restore.o): New rule.
7504 * config.in: Regenerate.
7505 * configure: Regenerate.
7506 * linux-low.c: Include "signals-state-save-restore.h".
7507 (linux_create_inferior): Call
7508 restore_original_signals_state.
7509 * server.c: Include "dispositions-save-restore.h".
7510 (captured_main): Call save_original_signals_state.
7512 2016-08-05 Pedro Alves <palves@redhat.com>
7514 * configure: Regenerate.
7516 2016-08-04 Yao Qi <yao.qi@linaro.org>
7518 * linux-low.c (regsets_fetch_inferior_registers): Check
7519 errno is ESRCH or not.
7521 2016-08-02 Yao Qi <yao.qi@linaro.org>
7523 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7524 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7525 (thread_db_load_search): Update.
7526 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7527 td_ta_set_event and td_ta_event_getmsg.
7529 2016-07-26 Pedro Alves <palves@redhat.com>
7532 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7533 of unsigned long for 64-bit registers and use uint32_t instead of
7534 unsigned int for 32-bit registers.
7536 2016-07-26 Pedro Alves <palves@redhat.com>
7538 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7541 2016-07-21 Tom Tromey <tom@tromey.com>
7543 * configure: Rebuild.
7545 2016-07-21 Yao Qi <yao.qi@linaro.org>
7547 * mem-break.c (find_gdb_breakpoint): Cast bp to
7548 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7550 2016-07-21 Yao Qi <yao.qi@linaro.org>
7552 * server.c (handle_v_requests): Support s and S actions
7553 if target_supports_software_single_step return true.
7555 2016-07-21 Yao Qi <yao.qi@linaro.org>
7557 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7558 is resume_step, call maybe_hw_step.
7559 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7561 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7563 (proceed_one_lwp): If resume request is resume_step, install
7564 reinsert breakpoints and call maybe_hw_step.
7566 2016-07-21 Yao Qi <yao.qi@linaro.org>
7568 * linux-low.c (proceed_one_lwp): Declare.
7569 (linux_resume_one_thread): Remove local variable 'step'.
7570 Lift code enqueue signal. Call proceed_one_lwp instead of
7571 linux_resume_one_lwp.
7573 2016-07-21 Yao Qi <yao.qi@linaro.org>
7575 * linux-low.c (linux_resume_one_thread): Call
7576 enqueue_pending_signal.
7578 2016-07-21 Yao Qi <yao.qi@linaro.org>
7580 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7581 * inferiors.c (do_restore_current_thread_cleanup): New function.
7582 (make_cleanup_restore_current_thread): Likewise.
7583 * linux-low.c (install_software_single_step_breakpoints): Call
7584 make_cleanup_restore_current_thread. Switch current_thread to
7587 2016-07-21 Yao Qi <yao.qi@linaro.org>
7589 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7590 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7591 (clone_one_breakpoint): Likewise.
7592 (delete_reinsert_breakpoints): Change parameter to thread.
7594 (has_reinsert_breakpoints): Likewise.
7595 (uninsert_reinsert_breakpoints): Likewise.
7596 (reinsert_reinsert_breakpoints): Likewise.
7597 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7598 (delete_reinsert_breakpoints): Likewise.
7599 (reinsert_reinsert_breakpoints): Likewise.
7600 (uninsert_reinsert_breakpoints): Likewise.
7601 (has_reinsert_breakpoints): Likewise.
7603 2016-07-21 Yao Qi <yao.qi@linaro.org>
7605 * inferiors.c (get_thread_process): Make parameter const.
7606 * inferiors.h (get_thread_process): Update declaration.
7607 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7608 Add new parameters child_thread and parent_thread. Callers
7610 * mem-break.h (clone_all_breakpoints): Update declaration.
7612 2016-07-21 Yao Qi <yao.qi@linaro.org>
7614 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7615 <command_list, handler>: Remove.
7616 (struct gdb_breakpoint): New.
7617 (struct other_breakpoint): New.
7618 (struct reinsert_breakpoint): New.
7619 (is_gdb_breakpoint): New function.
7620 (any_persistent_commands): Update command_list if
7621 is_gdb_breakpoint returns true.
7622 (set_breakpoint): Create breakpoints according to their types.
7623 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7624 (set_gdb_breakpoint_1): Likewise.
7625 (set_gdb_breakpoint): Likewise.
7626 (clear_breakpoint_conditions): Change parameter type to
7627 'struct gdb_breakpoint *'.
7628 (clear_breakpoint_commands): Likewise.
7629 (clear_breakpoint_conditions_and_commands): Likewise.
7630 (add_condition_to_breakpoint): Likewise.
7631 (add_breakpoint_condition): Likewise.
7632 (add_commands_to_breakpoint): Likewise.
7633 (check_breakpoints): Check other_breakpoint.
7634 (clone_one_breakpoint): Clone breakpopint according to its type.
7635 * mem-break.h (struct gdb_breakpoint): Declare.
7636 (set_gdb_breakpoint): Update declaration.
7637 (clear_breakpoint_conditions_and_commands): Likewise.
7638 (add_breakpoint_condition): Likewise.
7639 (add_breakpoint_commands): Likewise.
7640 * server.c (process_point_options): Change parameter type to
7641 'struct gdb_breakpoint *'.
7643 2016-07-21 Yao Qi <yao.qi@linaro.org>
7645 * mem-break.c (set_breakpoint_at): Rename it to ...
7646 (set_breakpoint_type_at): ... it.
7647 (set_breakpoint_at): Call set_breakpoint_type_at.
7648 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7649 * mem-break.h (set_breakpoint_at): Update comments.
7651 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7653 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7655 (nios2_store_gregset): Likewise.
7657 2016-07-01 Pedro Alves <palves@redhat.com>
7658 Antoine Tremblay <antoine.tremblay@ericsson.com>
7660 * linux-low.c: Change interface to take the target lwp_info
7661 pointer directly and return void. Handle detaching from a zombie
7663 (linux_detach_lwp_callback): New function.
7664 (linux_detach): Detach from the leader thread after detaching from
7667 2016-06-28 Yao Qi <yao.qi@linaro.org>
7669 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7670 for variable new_offset.
7671 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7672 (aarch64_ftrace_insn_reloc_cb): Likewise.
7673 (aarch64_ftrace_insn_reloc_tb): Likewise.
7674 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7675 PRIx64 instead of PRIx32.
7677 2016-06-28 Yao Qi <yao.qi@linaro.org>
7679 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7680 (the_low_target): Install arm_get_syscall_trapinfo.
7682 2016-06-28 Yao Qi <yao.qi@linaro.org>
7684 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7686 (the_low_target): Install aarch64_get_syscall_trapinfo.
7688 2016-06-28 Yao Qi <yao.qi@linaro.org>
7690 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7692 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7693 Remove parameter sysno.
7694 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7697 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7699 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7700 (s390_emit_ne_goto): Likewise.
7701 (s390_emit_lt_goto): Likewise.
7702 (s390_emit_le_goto): Likewise.
7703 (s390_emit_gt_goto): Likewise.
7704 (s390_emit_ge_goto): Likewise.
7705 (s390x_emit_eq_goto): Likewise.
7706 (s390x_emit_ne_goto): Likewise.
7707 (s390x_emit_lt_goto): Likewise.
7708 (s390x_emit_le_goto): Likewise.
7709 (s390x_emit_gt_goto): Likewise.
7710 (s390x_emit_ge_goto): Likewise.
7711 (s390_emit_ops_impl): Mark variable static.
7712 (s390x_emit_ops): Likewise.
7714 2016-06-17 Yao Qi <yao.qi@linaro.org>
7716 * linux-low.c (handle_extended_wait): Call
7717 uninsert_reinsert_breakpoints for the parent process. Remove
7718 reinsert breakpoints from the child process. Reinsert them to
7719 the parent process when vfork is done.
7720 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7721 (reinsert_reinsert_breakpoints): New function.
7722 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7723 (reinsert_reinsert_breakpoints): Declare.
7725 2016-06-17 Yao Qi <yao.qi@linaro.org>
7727 * linux-low.c (handle_extended_wait): If the parent is doing
7728 step-over, remove the reinsert breakpoints from the forked child.
7730 2016-06-17 Yao Qi <yao.qi@linaro.org>
7732 * linux-low.c (unsuspend_all_lwps): Declare.
7733 (linux_low_filter_event): If thread exited, call finish_step_over.
7734 If step-over is finished, unsuspend other threads.
7736 2016-06-17 Yao Qi <yao.qi@linaro.org>
7738 * linux-low.c (linux_resume_one_lwp_throw): Assert
7739 has_reinsert_breakpoints returns false.
7740 * mem-break.c (delete_disabled_breakpoints): Assert
7741 bp type isn't reinsert_breakpoint.
7743 2016-06-17 Yao Qi <yao.qi@linaro.org>
7745 * linux-low.c (maybe_hw_step): New function.
7746 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7747 (finish_step_over): Switch current_thread to lwp temporarily,
7748 and assert has_reinsert_breakpoints returns true.
7749 (proceed_one_lwp): Call maybe_hw_step.
7750 * mem-break.c (has_reinsert_breakpoints): New function.
7751 * mem-break.h (has_reinsert_breakpoints): Declare.
7753 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7755 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7757 2016-05-17 Yao Qi <yao.qi@linaro.org>
7759 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7760 instead of find_inferior.
7762 2016-05-05 Yao Qi <yao.qi@linaro.org>
7764 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7765 Initialize res to zero.
7767 2016-05-05 Yao Qi <yao.qi@linaro.org>
7769 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7772 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7774 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7775 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7776 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7778 2016-04-28 Par Olsson <par.olsson@windriver.com>
7779 Simon Marchi <simon.marchi@ericsson.com>
7781 * tracepoint.c (write_inferior_int8): New function.
7782 (cmd_qtenable_disable): Write enable flag using
7783 write_inferior_int8.
7785 2016-04-25 Yao Qi <yao.qi@linaro.org>
7787 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7788 (need_step_over_p): Return zero if the LWP has pending signals
7789 can be delivered on software single step target.
7791 2016-04-25 Yao Qi <yao.qi@linaro.org>
7793 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7794 return instead of error.
7796 2016-04-22 Yao Qi <yao.qi@linaro.org>
7798 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7801 2016-04-22 Yao Qi <yao.qi@linaro.org>
7803 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7804 signal when stepping over breakpoint with software single
7807 2016-04-21 Pedro Alves <palves@redhat.com>
7809 * linux-s390-low.c (s390_collect_ptrace_register)
7810 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7812 (s390_check_regset): Use void * instead of gdb_byte *.
7814 2016-04-20 Pedro Alves <palves@redhat.com>
7816 * configure: Renegerate.
7818 2016-04-20 Yao Qi <yao.qi@linaro.org>
7820 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7821 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7823 (arm_store_gregset): Likewise.
7825 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7827 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7828 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7829 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7830 (amd64-avx-mpx-linux.c): New rules.
7831 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7832 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7833 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7834 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7835 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7836 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7837 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7838 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7839 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7840 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7841 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7842 * linux-x86-low.c (x86_linux_read_description): Add case for
7843 X86_XSTATE_AVX_MPX_MASK.
7844 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7845 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7846 init_registers_i386_avx_mpx_linux.
7847 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7848 (initialize_low_tracepoint): Call
7849 init_registers_i386_avx_mpx_linux.
7850 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7851 (initialize_low_tracepoint): Call
7852 init_registers_amd64_avx_mpx_linux.
7853 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7854 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7855 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
7858 2016-04-18 Pedro Alves <palves@redhat.com>
7860 * configure: Regenerate.
7862 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
7864 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
7865 (aarch64_emit_sub): Likewise.
7867 2016-04-12 Pedro Alves <palves@redhat.com>
7869 * utils.c (prepare_to_throw_exception): Delete.
7871 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
7873 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
7875 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
7877 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
7879 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
7881 * linux-aarch64-ipa.c: Add <elf.h> include.
7882 * linux-ppc-ipa.c: Add <elf.h> include.
7883 * linux-s390-ipa.c: Add <elf.h> include.
7885 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7887 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
7888 (get_raw_reg_ptr): Likewise.
7889 (get_trace_state_variable_value_ptr): Likewise.
7890 (set_trace_state_variable_value_ptr): Likewise.
7891 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
7894 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
7895 Marcin Kościelnicki <koriakin@0x04.net>
7898 * linux-ppc-low.c (emit_insns): New function.
7899 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
7900 (ppc_emit_prologue): New function.
7901 (ppc_emit_epilogue): New function.
7902 (ppc_emit_add): New function.
7903 (ppc_emit_sub): New function.
7904 (ppc_emit_mul): New function.
7905 (ppc_emit_lsh): New function.
7906 (ppc_emit_rsh_signed): New function.
7907 (ppc_emit_rsh_unsigned): New function.
7908 (ppc_emit_ext): New function.
7909 (ppc_emit_zero_ext): New function.
7910 (ppc_emit_log_not): New function.
7911 (ppc_emit_bit_and): New function.
7912 (ppc_emit_bit_or): New function.
7913 (ppc_emit_bit_xor): New function.
7914 (ppc_emit_bit_not): New function.
7915 (ppc_emit_equal): New function.
7916 (ppc_emit_less_signed): New function.
7917 (ppc_emit_less_unsigned): New function.
7918 (ppc_emit_ref): New function.
7919 (ppc_emit_const): New function.
7920 (ppc_emit_reg): New function.
7921 (ppc_emit_pop): New function.
7922 (ppc_emit_stack_flush): New function.
7923 (ppc_emit_swap): New function.
7924 (ppc_emit_stack_adjust): New function.
7925 (ppc_emit_call): New function.
7926 (ppc_emit_int_call_1): New function.
7927 (ppc_emit_void_call_2): New function.
7928 (ppc_emit_if_goto): New function.
7929 (ppc_emit_goto): New function.
7930 (ppc_emit_eq_goto): New function.
7931 (ppc_emit_ne_goto): New function.
7932 (ppc_emit_lt_goto): New function.
7933 (ppc_emit_le_goto): New function.
7934 (ppc_emit_gt_goto): New function.
7935 (ppc_emit_ge_goto): New function.
7936 (ppc_write_goto_address): New function.
7937 (ppc_emit_ops_impl): New static variable.
7938 (ppc64v1_emit_prologue): New function.
7939 (ppc64v2_emit_prologue): New function.
7940 (ppc64_emit_epilogue): New function.
7941 (ppc64_emit_add): New function.
7942 (ppc64_emit_sub): New function.
7943 (ppc64_emit_mul): New function.
7944 (ppc64_emit_lsh): New function.
7945 (ppc64_emit_rsh_signed): New function.
7946 (ppc64_emit_rsh_unsigned): New function.
7947 (ppc64_emit_ext): New function.
7948 (ppc64_emit_zero_ext): New function.
7949 (ppc64_emit_log_not): New function.
7950 (ppc64_emit_bit_and): New function.
7951 (ppc64_emit_bit_or): New function.
7952 (ppc64_emit_bit_xor): New function.
7953 (ppc64_emit_bit_not): New function.
7954 (ppc64_emit_equal): New function.
7955 (ppc64_emit_less_signed): New function.
7956 (ppc64_emit_less_unsigned): New function.
7957 (ppc64_emit_ref): New function.
7958 (ppc64_emit_const): New function.
7959 (ppc64v1_emit_reg): New function.
7960 (ppc64v2_emit_reg): New function.
7961 (ppc64_emit_pop): New function.
7962 (ppc64_emit_stack_flush): New function.
7963 (ppc64_emit_swap): New function.
7964 (ppc64v1_emit_call): New function.
7965 (ppc64v2_emit_call): New function.
7966 (ppc64v1_emit_int_call_1): New function.
7967 (ppc64v2_emit_int_call_1): New function.
7968 (ppc64v1_emit_void_call_2): New function.
7969 (ppc64v2_emit_void_call_2): New function.
7970 (ppc64_emit_if_goto): New function.
7971 (ppc64_emit_eq_goto): New function.
7972 (ppc64_emit_ne_goto): New function.
7973 (ppc64_emit_lt_goto): New function.
7974 (ppc64_emit_le_goto): New function.
7975 (ppc64_emit_gt_goto): New function.
7976 (ppc64_emit_ge_goto): New function.
7977 (ppc64v1_emit_ops_impl): New static variable.
7978 (ppc64v2_emit_ops_impl): New static variable.
7979 (ppc_emit_ops): New function.
7980 (linux_low_target): Wire in ppc_emit_ops.
7982 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
7983 Marcin Kościelnicki <koriakin@0x04.net>
7986 * Makefile.in: Add powerpc-*-ipa.o
7987 * configure.srv: Add ipa_obj for powerpc*-linux.
7988 * linux-ppc-ipa.c: New file.
7989 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
7991 (PPC_FIELD): New macro.
7992 (PPC_SEXT): New macro.
7993 (PPC_OP6): New macro.
7994 (PPC_BO): New macro.
7995 (PPC_LI): New macro.
7996 (PPC_BD): New macro.
7997 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
7998 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
7999 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8000 (ppc_get_thread_area): New function.
8001 (is_elfv2_inferior): New function.
8002 (gen_ds_form): New function.
8003 (GEN_STD): New macro.
8004 (GEN_STDU): New macro.
8005 (GEN_LD): New macro.
8006 (GEN_LDU): New macro.
8007 (gen_d_form): New function.
8008 (GEN_ADDI): New macro.
8009 (GEN_ADDIS): New macro.
8010 (GEN_LI): New macro.
8011 (GEN_LIS): New macro.
8012 (GEN_ORI): New macro.
8013 (GEN_ORIS): New macro.
8014 (GEN_LWZ): New macro.
8015 (GEN_STW): New macro.
8016 (GEN_STWU): New macro.
8017 (gen_xfx_form): New function.
8018 (GEN_MFSPR): New macro.
8019 (GEN_MTSPR): New macro.
8020 (GEN_MFCR): New macro.
8021 (GEN_MTCR): New macro.
8022 (GEN_SYNC): New macro.
8023 (GEN_LWSYNC): New macro.
8024 (gen_x_form): New function.
8025 (GEN_OR): New macro.
8026 (GEN_MR): New macro.
8027 (GEN_LWARX): New macro.
8028 (GEN_STWCX): New macro.
8029 (GEN_CMPW): New macro.
8030 (gen_md_form): New function.
8031 (GEN_RLDICL): New macro.
8032 (GEN_RLDICR): New macro.
8033 (gen_i_form): New function.
8035 (GEN_BL): New macro.
8036 (gen_b_form): New function.
8037 (GEN_BNE): New macro.
8038 (GEN_LOAD): New macro.
8039 (GEN_STORE): New macro.
8040 (gen_limm): New function.
8041 (gen_atomic_xchg): New function.
8042 (gen_call): New function.
8043 (ppc_relocate_instruction): New function.
8044 (ppc_install_fast_tracepoint_jump_pad): New function.
8045 (ppc_get_min_fast_tracepoint_insn_len): New function.
8046 (ppc_get_ipa_tdesc_idx): New function.
8047 (the_low_target): Wire in the new functions.
8048 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8050 * linux-ppc-tdesc.h: New file.
8052 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8054 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8055 (alloc_jump_pad_buffer): New function.
8056 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8057 (alloc_jump_pad_buffer): New function.
8058 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8059 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8060 (alloc_jump_pad_buffer): New function.
8061 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8062 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8063 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8064 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8066 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8068 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8069 * linux-amd64-ipa.c: Likewise.
8070 * linux-i386-ipa.c: Likewise.
8071 * linux-s390-ipa.c: Likewise.
8072 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8073 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8074 set_trace_state_variable_value_ptr.
8075 (struct ipa_sym_addresses): Likewise.
8076 (symbol_list): Likewise.
8077 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8078 accessing gdb_collect directly.
8079 (gdb_collect_ptr_type): New typedef.
8080 (get_raw_reg_ptr_type): New typedef.
8081 (get_trace_state_variable_value_ptr_type): New typedef.
8082 (set_trace_state_variable_value_ptr_type): New typedef.
8083 (gdb_collect_ptr): New global.
8084 (get_raw_reg_ptr): New global.
8085 (get_trace_state_variable_value_ptr): New global.
8086 (set_trace_state_variable_value_ptr): New global.
8087 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8088 accessing get_raw_reg directly.
8089 (get_get_tsv_func_addr): Likewise for
8090 get_trace_state_variable_value_ptr.
8091 (get_set_tsv_func_addr): Likewise for
8092 set_trace_state_variable_value_ptr.
8093 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8095 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8097 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8099 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8101 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8103 (relocate_instruction): Remove own_buf.
8104 * server.c (own_buf): Make global.
8105 (handle_v_requests): Make global.
8106 * server.h (own_buf): New declaration.
8107 (handle_v_requests): New prototype.
8109 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8112 * linux-s390-low.c (add_insns): New function.
8113 (s390_emit_prologue): New function.
8114 (s390_emit_epilogue): New function.
8115 (s390_emit_add): New function.
8116 (s390_emit_sub): New function.
8117 (s390_emit_mul): New function.
8118 (s390_emit_lsh): New function.
8119 (s390_emit_rsh_signed): New function.
8120 (s390_emit_rsh_unsigned): New function.
8121 (s390_emit_ext): New function.
8122 (s390_emit_log_not): New function.
8123 (s390_emit_bit_and): New function.
8124 (s390_emit_bit_or): New function.
8125 (s390_emit_bit_xor): New function.
8126 (s390_emit_bit_not): New function.
8127 (s390_emit_equal): New function.
8128 (s390_emit_less_signed): New function.
8129 (s390_emit_less_unsigned): New function.
8130 (s390_emit_ref): New function.
8131 (s390_emit_if_goto): New function.
8132 (s390_emit_goto): New function.
8133 (s390_write_goto_address): New function.
8134 (s390_emit_litpool): New function.
8135 (s390_emit_const): New function.
8136 (s390_emit_call): New function.
8137 (s390_emit_reg): New function.
8138 (s390_emit_pop): New function.
8139 (s390_emit_stack_flush): New function.
8140 (s390_emit_zero_ext): New function.
8141 (s390_emit_swap): New function.
8142 (s390_emit_stack_adjust): New function.
8143 (s390_emit_set_r2): New function.
8144 (s390_emit_int_call_1): New function.
8145 (s390_emit_void_call_2): New function.
8146 (s390_emit_eq_goto): New function.
8147 (s390_emit_ne_goto): New function.
8148 (s390_emit_lt_goto): New function.
8149 (s390_emit_le_goto): New function.
8150 (s390_emit_gt_goto): New function.
8151 (s390_emit_ge_goto): New function.
8152 (s390x_emit_prologue): New function.
8153 (s390x_emit_epilogue): New function.
8154 (s390x_emit_add): New function.
8155 (s390x_emit_sub): New function.
8156 (s390x_emit_mul): New function.
8157 (s390x_emit_lsh): New function.
8158 (s390x_emit_rsh_signed): New function.
8159 (s390x_emit_rsh_unsigned): New function.
8160 (s390x_emit_ext): New function.
8161 (s390x_emit_log_not): New function.
8162 (s390x_emit_bit_and): New function.
8163 (s390x_emit_bit_or): New function.
8164 (s390x_emit_bit_xor): New function.
8165 (s390x_emit_bit_not): New function.
8166 (s390x_emit_equal): New function.
8167 (s390x_emit_less_signed): New function.
8168 (s390x_emit_less_unsigned): New function.
8169 (s390x_emit_ref): New function.
8170 (s390x_emit_if_goto): New function.
8171 (s390x_emit_const): New function.
8172 (s390x_emit_call): New function.
8173 (s390x_emit_reg): New function.
8174 (s390x_emit_pop): New function.
8175 (s390x_emit_stack_flush): New function.
8176 (s390x_emit_zero_ext): New function.
8177 (s390x_emit_swap): New function.
8178 (s390x_emit_stack_adjust): New function.
8179 (s390x_emit_int_call_1): New function.
8180 (s390x_emit_void_call_2): New function.
8181 (s390x_emit_eq_goto): New function.
8182 (s390x_emit_ne_goto): New function.
8183 (s390x_emit_lt_goto): New function.
8184 (s390x_emit_le_goto): New function.
8185 (s390x_emit_gt_goto): New function.
8186 (s390x_emit_ge_goto): New function.
8187 (s390_emit_ops): New function.
8188 (struct linux_target_ops): Fill in emit_ops hook.
8190 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8193 * Makefile.in: Add s390 IPA files.
8194 * configure.srv: Build IPA for s390.
8195 * linux-s390-ipa.c: New file.
8196 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8197 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8198 (tdesc_s390_linux32): Likewise.
8199 (init_registers_s390_linux32v1): Likewise.
8200 (tdesc_s390_linux32v1): Likewise.
8201 (init_registers_s390_linux32v2): Likewise.
8202 (tdesc_s390_linux32v2): Likewise.
8203 (init_registers_s390_linux64): Likewise.
8204 (tdesc_s390_linux64): Likewise.
8205 (init_registers_s390_linux64v1): Likewise.
8206 (tdesc_s390_linux64v1): Likewise.
8207 (init_registers_s390_linux64v2): Likewise.
8208 (tdesc_s390_linux64v2): Likewise.
8209 (init_registers_s390_te_linux64): Likewise.
8210 (tdesc_s390_te_linux64): Likewise.
8211 (init_registers_s390_vx_linux64): Likewise.
8212 (tdesc_s390_vx_linux64): Likewise.
8213 (init_registers_s390_tevx_linux64): Likewise.
8214 (tdesc_s390_tevx_linux64): Likewise.
8215 (init_registers_s390x_linux64): Likewise.
8216 (tdesc_s390x_linux64): Likewise.
8217 (init_registers_s390x_linux64v1): Likewise.
8218 (tdesc_s390x_linux64v1): Likewise.
8219 (init_registers_s390x_linux64v2): Likewise.
8220 (tdesc_s390x_linux64v2): Likewise.
8221 (init_registers_s390x_te_linux64): Likewise.
8222 (tdesc_s390x_te_linux64): Likewise.
8223 (init_registers_s390x_vx_linux64): Likewise.
8224 (tdesc_s390x_vx_linux64): Likewise.
8225 (init_registers_s390x_tevx_linux64): Likewise.
8226 (tdesc_s390x_tevx_linux64): Likewise.
8227 (have_hwcap_s390_vx): New static variable.
8228 (s390_arch_setup): Fill have_hwcap_s390_vx.
8229 (s390_get_thread_area): New function.
8230 (s390_ft_entry_gpr_esa): New const.
8231 (s390_ft_entry_gpr_zarch): New const.
8232 (s390_ft_entry_misc): New const.
8233 (s390_ft_entry_fr): New const.
8234 (s390_ft_entry_vr): New const.
8235 (s390_ft_main_31): New const.
8236 (s390_ft_main_64): New const.
8237 (s390_ft_exit_fr): New const.
8238 (s390_ft_exit_vr): New const.
8239 (s390_ft_exit_misc): New const.
8240 (s390_ft_exit_gpr_esa): New const.
8241 (s390_ft_exit_gpr_zarch): New const.
8242 (append_insns): New function.
8243 (s390_relocate_instruction): New function.
8244 (s390_install_fast_tracepoint_jump_pad): New function.
8245 (s390_get_min_fast_tracepoint_insn_len): New function.
8246 (s390_get_ipa_tdesc_idx): New function.
8247 (struct linux_target_ops): Wire in the above functions.
8248 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8249 * linux-s390-tdesc.h: New file.
8251 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8253 * linux-s390-low.c (s390_supports_tracepoints): New function.
8254 (struct linux_target_ops): Fill supports_tracepoints hook.
8256 2016-03-18 Yao Qi <yao.qi@linaro.org>
8258 * linux-low.c (lwp_signal_can_be_delivered): New function.
8259 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8261 2016-03-18 Yao Qi <yao.qi@linaro.org>
8263 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8264 0 if signal is enqueued. Remove 'signal' from one debugging
8265 message. Move one debugging message to some lines below.
8266 Remove code setting 'signal' to 0.
8268 2016-03-18 Yao Qi <yao.qi@linaro.org>
8270 * linux-low.c (linux_low_filter_event): Remove redundant
8271 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8273 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8275 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8276 (struct linux_target_ops): Wire in the above.
8278 2016-03-03 Yao Qi <yao.qi@linaro.org>
8280 * linux-low.c: Update comments to start_step_over.
8282 2016-03-03 Yao Qi <yao.qi@linaro.org>
8285 * linux-low.c (handle_extended_wait): Set child suspended
8286 if event_lwp->bp_reinsert isn't zero.
8288 2016-03-02 Yao Qi <yao.qi@linaro.org>
8290 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8291 enqueue_pending_signal.
8293 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8295 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8298 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8300 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8301 (s390_regmap_3264) [!__s390x__]: New global.
8302 (s390_collect_ptrace_register): Skip map entries containing -1.
8303 (s390_supply_ptrace_register): Ditto.
8304 (s390_fill_gprs_high): New function.
8305 (s390_store_gprs_high): New function.
8306 (s390_regsets): Add NT_S390_HIGH_GPRS.
8307 (s390_get_hwcap): Enable on 31-bit.
8308 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8309 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8310 Detect NT_S390_HIGH_GPRS.
8311 (s390_usrregs_info_3264): Enable on 31-bit.
8312 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8313 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8315 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8318 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8319 * configure.srv: Ditto.
8320 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8321 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8322 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8323 (init_registers_amd64_linux): Remove prototype.
8324 (tdesc_amd64_linux): Remove declaration.
8325 (get_ipa_tdesc): New function.
8326 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8327 initialize remaining tdescs.
8328 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8329 (init_registers_i386_linux): Remove prototype.
8330 (tdesc_i386_linux): Remove declaration.
8331 (get_ipa_tdesc): New function.
8332 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8333 initialize remaining tdescs.
8334 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8335 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8336 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8337 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8338 (x86_get_ipa_tdesc_idx): New function.
8339 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8340 * linux-x86-tdesc.h: New file.
8341 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8342 (target_get_ipa_tdesc_idx): New macro.
8343 * tracepoint.c (ipa_tdesc_idx): New macro.
8344 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8345 (symbol_list): Add ipa_tdesc_idx.
8346 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8347 (ipa_tdesc): Remove.
8348 (ipa_tdesc_idx): New variable.
8349 (get_context_regcache): Use get_ipa_tdesc.
8350 (gdb_collect): Ditto.
8352 * tracepoint.h (get_ipa_tdesc): New prototype.
8353 (ipa_tdesc): Remove.
8355 2016-02-24 Pedro Alves <palves@redhat.com>
8357 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8358 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8359 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8360 Factor out common code between the USE_SIGTRAP_SIGINFO and
8361 !USE_SIGTRAP_SIGINFO blocks.
8362 (linux_low_filter_event): Call save_stop_reason instead of
8363 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8365 (linux_wait_1): Update comments.
8367 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8369 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8370 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8371 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8372 ppc_insert_point, ppc_remove_point.
8374 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8376 * linux-s390-low.c (s390_supports_z_point_type): New function.
8377 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8379 2016-02-16 Yao Qi <yao.qi@linaro.org>
8381 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8382 PC. Get pc from regcache_read_pc.
8384 2016-02-12 Yao Qi <yao.qi@linaro.org>
8386 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8387 or linux_get_pc_32bit.
8388 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8390 2016-02-12 Yao Qi <yao.qi@linaro.org>
8392 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8393 arm_linux_get_next_pcs_fixup.
8395 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8397 * tracepoint.c (x_tracepoint_action_download): Change
8398 write_inferior_data_ptr to write_inferior_data_pointer.
8399 (cmd_qtstart): Likewise.
8400 (write_inferior_data_ptr): Remove.
8401 (download_agent_expr): Change write_inferior_data_ptr to
8402 write_inferior_data_pointer.
8403 (download_tracepoint_1): Likewise.
8404 (download_tracepoint): Likewise.
8405 (download_trace_state_variables): Likewise.
8407 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8408 Marcin Kościelnicki <koriakin@0x04.net>
8410 * tracepoint.c (struct tracepoint_action_ops): Remove.
8411 (struct tracepoint_action): Remove ops.
8412 (m_tracepoint_action_download, r_tracepoint_action_download)
8413 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8414 size and offset accordingly.
8415 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8416 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8417 (tracepoint_action_send, tracepoint_action_download): New functions.
8418 Helpers for trace action handlers.
8419 (add_tracepoint_action): Remove setup actions ops.
8420 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8422 2016-02-10 Yao Qi <yao.qi@linaro.org>
8424 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8426 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8428 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8430 * configure: Regenerate.
8432 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8434 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8435 void * to gdb_byte *.
8436 * linux-low.c (siginfo_fixup): Likewise.
8437 (linux_xfer_siginfo): Likewise.
8438 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8440 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8442 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8444 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8446 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8448 * linux-x86-low.c [__x86_64__]: Include
8449 "nat/amd64-linux-siginfo.h".
8450 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8451 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8452 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8453 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8454 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8455 (cpt_si_fd, si_timerid, si_overrun): Move from
8456 nat/amd64-linux-siginfo.c.
8457 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8459 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8461 * server.c (skip_to_semicolon): Remove.
8462 (process_point_options): Use strchrnul instead of
8465 2016-01-26 Yao Qi <yao.qi@linaro.org>
8467 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8468 * linux-low.c (install_software_single_step_breakpoints): Don't
8469 call regcache_read_pc.
8470 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8473 2016-01-26 Yao Qi <yao.qi@linaro.org>
8475 * linux-low.c (install_software_single_step_breakpoints): Call
8476 regcache_read_pc instead of get_pc.
8478 2016-01-26 Yao Qi <yao.qi@linaro.org>
8480 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8481 (unblock_async_io): Rename to ...
8482 (block_unblock_async_io): ... it. New function.
8483 (enable_async_io): Don't install SIGIO handler. Unblock it
8485 (disable_async_io): Don't ignore SIGIO. Block it instead.
8486 (initialize_async_io): Install SIGIO handler. Don't call
8489 2016-01-26 Yao Qi <yao.qi@linaro.org>
8491 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8492 first character is '\003', call *the_target->request_interrupt.
8494 2016-01-25 Yao Qi <yao.qi@linaro.org>
8496 * remote-utils.c (new_thread_notify): Remove.
8497 (dead_thread_notify): Likewise.
8498 * remote-utils.h (new_thread_notify): Remove declaration.
8499 (dead_thread_notify): Likewise.
8501 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8503 * gdb.trace/pending.exp: Fix expected message on continue.
8505 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8507 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8508 it works properly on big-endian machines where sizeof (CORE_ADDR)
8511 2016-01-21 Pedro Alves <palves@redhat.com>
8513 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8514 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8515 * configure: Regenerate.
8517 2016-01-21 Yao Qi <yao.qi@linaro.org>
8519 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8520 is_thumb and set it according to CPSR saved on the stack.
8521 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8522 arm_sigreturn_next_pc.
8524 2016-01-18 Yao Qi <yao.qi@linaro.org>
8526 * linux-low.c (linux_set_pc_64bit): New function.
8527 (linux_get_pc_64bit): New function.
8528 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8530 * linux-sparc-low.c (debug_threads): Remove declaration.
8531 (sparc_get_pc): Remove.
8532 (the_low_target): Use linux_get_pc_64bit instead of
8534 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8535 (the_low_target): Use linux_get_pc_64bit and
8538 2016-01-18 Yao Qi <yao.qi@linaro.org>
8540 * linux-arm-low.c (debug_threads): Remove declaration.
8541 (arm_get_pc, arm_set_pc): Remove.
8542 (the_low_target): Use linux_get_pc_32bit and
8544 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8545 (the_low_target): Use linux_get_pc_32bit and
8547 * linux-cris-low.c (debug_threads): Remove declaration.
8548 (cris_get_pc, cris_set_pc,): Remove.
8549 (the_low_target): Use linux_get_pc_32bit and
8551 * linux-crisv32-low.c (debug_threads): Remove declaration.
8552 (cris_get_pc, cris_set_pc): Remove.
8553 (the_low_target): Use linux_get_pc_32bit and
8555 * linux-low.c: Include inttypes.h.
8556 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8557 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8558 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8559 (the_low_target): Use linux_get_pc_32bit and
8561 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8562 (the_low_target): Use linux_get_pc_32bit and
8564 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8565 (the_low_target): Use linux_get_pc_32bit and
8567 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8568 (the_low_target): Use linux_get_pc_32bit and
8570 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8571 (the_low_target): Use linux_get_pc_32bit and
8574 2016-01-18 Gary Benson <gbenson@redhat.com>
8576 * configure.ac (AC_FUNC_FORK): New check.
8577 * config.in: Regenerate.
8578 * configure: Likewise.
8580 2016-01-14 Yao Qi <yao.qi@linaro.org>
8582 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8583 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8584 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8585 arm_get_next_pcs_ctor.
8587 2016-01-12 Josh Stone <jistone@redhat.com>
8588 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8590 * inferiors.h: Include "gdb_vecs.h".
8591 (struct process_info): Add syscalls_to_catch.
8592 * inferiors.c (remove_process): Free syscalls_to_catch.
8593 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8594 syscall_return stops.
8595 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8596 * server.c (handle_general_set): Handle QCatchSyscalls.
8597 (handle_query): Report support for QCatchSyscalls.
8598 * target.h (struct target_ops): Add supports_catch_syscall.
8599 (target_supports_catch_syscall): New macro.
8600 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8601 (struct lwp_info): Add syscall_state.
8602 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8603 Maintain syscall_state and syscalls_to_catch across exec.
8604 (get_syscall_trapinfo): New function, proxy to the_low_target.
8605 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8606 (linux_low_filter_event): Toggle syscall_state entry/return for
8607 syscall traps, and set it ignored for all others.
8608 (gdb_catching_syscalls_p): New function.
8609 (gdb_catch_this_syscall_p): New function.
8610 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8611 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8612 (linux_supports_catch_syscall): New function.
8613 (linux_target_ops): Install it.
8614 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8615 (the_low_target): Install it.
8617 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8619 * acinclude.m4: Include new ../warning.m4 file.
8620 * configure: Regenerated.
8621 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8623 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8625 * ax.c (is_goto_target): Mark static.
8626 * linux-low.c (register_addr): Likewise.
8627 (linux_fetch_registers, linux_store_registers): Likewise.
8628 * mem-break.c (any_persistent_commands): Fix old prototype.
8629 (add_commands_to_breakpoint): Mark static.
8630 * regcache.c (find_register_by_name): Delete unused func.
8631 * remote-utils.c (hex_or_minus_one): Mark static.
8632 * server.c (monitor_show_help): Mark static.
8633 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8634 handle_v_requests): Likewise.
8636 2016-01-12 Pedro Alves <palves@redhat.com>
8638 Remove use of the registered trademark symbol throughout.
8640 2016-01-08 Yao Qi <yao.qi@linaro.org>
8642 * remote-utils.c (getpkt): If c is '\003', call target hook
8645 2016-01-06 Yao Qi <yao.qi@linaro.org>
8647 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8648 linux-aarch32-low.c.
8649 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8650 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8651 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8652 (thumb2_breakpoint): Declare.
8653 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8654 linux-aarch32-low.h.
8655 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8656 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8657 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8659 2016-01-01 Joel Brobecker <brobecker@adacore.com>
8661 * gdbreplay.c (gdbreplay_version): Change copyright year in
8663 * server.c (gdbserver_version): Likewise.
8665 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8667 * server.c (crc32_table): Delete.
8668 (crc32): Use libiberty's xcrc32 function.
8670 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8672 * lynx-low.c (lynx_delete_thread_callback): New function.
8673 (lynx_mourn): Properly delete our process and all of its
8674 threads. Remove call to clear_inferiors.
8676 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8678 * target.c (thread_search_callback): Add check that
8679 the thread_stopped target callback is not NULL before
8682 2015-12-21 Yao Qi <yao.qi@linaro.org>
8684 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8687 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8689 * server.c (handle_query): Call target_supports_software_single_step.
8691 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8693 * linux-low.c (single_step): New function.
8694 (linux_resume_one_lwp_throw): Call single_step.
8695 (start_step_over): Likewise.
8697 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8699 * Makefile.in (SFILES): Append arch/arm-linux.c,
8700 arch/arm-get-next-pcs.c.
8701 (arm-linux.o): New rule.
8702 (arm-get-next-pcs.o): New rule.
8703 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8705 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8706 to linux-aarch32-low.c.
8707 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8708 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8709 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8710 (thumb2_breakpoint_len): Likewise.
8711 (arm_is_thumb_mode): Make non-static.
8712 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8713 from linux-aarch32-low.c.
8714 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8715 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8716 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8717 (thumb2_breakpoint_len): Likewise.
8718 (arm_is_thumb_mode): New declaration.
8719 * linux-arm-low.c: Include arch/arm-linux.h
8720 aarch/arm-get-next-pcs.h, sys/syscall.h.
8721 (get_next_pcs_ops): New struct.
8722 (get_next_pcs_addr_bits_remove): New function.
8723 (get_next_pcs_is_thumb): New function.
8724 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8725 (arm_sigreturn_next_pc): Likewise.
8726 (get_next_pcs_syscall_next_pc): Likewise.
8727 (arm_gdbserver_get_next_pcs): Likewise.
8728 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8730 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8731 * server.h: Include gdb_vecs.h.
8733 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8735 * Makefile.in (SFILES): Append common/common-regcache.c.
8736 (OBS): Append common-regcache.o.
8737 (common-regcache.o): New rule.
8738 * regcache.c (init_register_cache): Initialize cache to
8740 (regcache_raw_read_unsigned): New function.
8741 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8742 register_status enum.
8744 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8746 * linux-aarch64-low.c (the_low_targets): Rename
8747 breakpoint_reinsert_addr to get_next_pcs.
8748 * linux-arm-low.c (the_low_targets): Likewise.
8749 * linux-bfin-low.c (the_low_targets): Likewise.
8750 * linux-cris-low.c (the_low_targets): Likewise.
8751 * linux-crisv32-low.c (the_low_targets): Likewise.
8752 * linux-low.c (can_software_single_step): Likewise.
8753 (install_software_single_step_breakpoints): New function.
8754 (start_step_over): Use install_software_single_step_breakpoints.
8755 * linux-low.h: New CORE_ADDR vector.
8756 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8758 * linux-mips-low.c (the_low_targets): Likewise.
8759 * linux-nios2-low.c (the_low_targets): Likewise.
8760 * linux-sparc-low.c (the_low_targets): Likewise.
8762 2015-12-17 Pedro Alves <palves@redhat.com>
8764 * linux-low.c (linux_kill_one_lwp): Remove references to
8766 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8768 (linux_init_signals): Delete.
8769 (initialize_low): Adjust.
8770 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8772 2015-12-16 Pedro Alves <palves@redhat.com>
8774 * configure.ac (compiler warning flags): When testing a
8775 -Wno-foo option, check whether -Wfoo works instead.
8776 * configure: Regenerate.
8778 2015-12-11 Don Breazeal <donb@codesourcery.com>
8780 * server.c (process_serial_event): Don't exit from gdbserver
8781 in remote mode if there are still active inferiors.
8783 2015-12-11 Yao Qi <yao.qi@linaro.org>
8785 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8786 arm_breakpoint_at if the process is 32-bit.
8788 2015-12-11 Yao Qi <yao.qi@linaro.org>
8790 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8793 2015-12-07 Yao Qi <yao.qi@linaro.org>
8795 * configure.srv: Append arm.o to srv_tgtobj for
8796 aarch64*-*-linux* target.
8797 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8798 from linux-arm-low.c.
8799 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8800 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8801 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8802 (thumb2_breakpoint_len): Likewise.
8803 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8804 (arm_breakpoint_kinds): Likewise.
8805 (arm_breakpoint_kind_from_pc): Likewise.
8806 (arm_sw_breakpoint_from_kind): Likewise.
8807 (arm_breakpoint_kind_from_current_state): Likewise.
8808 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8809 (arm_sw_breakpoint_from_kind): Declare.
8810 (arm_breakpoint_kind_from_current_state): Declare.
8811 (arm_breakpoint_at): Declare.
8812 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8813 arm_sw_breakpoint_from_kind if process is 32-bit.
8814 (aarch64_breakpoint_kind_from_pc): New function.
8815 (aarch64_breakpoint_kind_from_current_state): New function.
8816 (the_low_target): Initialize fields breakpoint_kind_from_pc
8817 and breakpoint_kind_from_current_state.
8818 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8819 linux-aarch32-low.c.
8820 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8821 (arm_breakpoint, arm_breakpoint_len): Likewise.
8822 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8823 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8824 (arm_is_thumb_mode): Likewise.
8825 (arm_breakpoint_at): Likewise.
8826 (arm_breakpoint_kind_from_pc): Likewise.
8827 (arm_sw_breakpoint_from_kind): Likewise.
8828 (arm_breakpoint_kind_from_current_state): Likewise.
8831 2015-08-04 Yao Qi <yao.qi@linaro.org>
8833 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8834 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8835 * server.c (extended_protocol): Remove "static".
8836 * server.h (extended_protocol): Declare it.
8838 2015-12-04 Josh Stone <jistone@redhat.com>
8840 * target.h (struct target_ops) <arch_setup>: Rename to ...
8841 (struct target_ops) <post_create_inferior>: ... this.
8842 (target_arch_setup): Rename to ...
8843 (target_post_create_inferior): ... this, calling post_create_inferior.
8844 * server.c (start_inferior): Update target_arch_setup calls to
8845 target_post_create_inferior.
8846 * linux-low.c (linux_low_ptrace_options): Forward declare.
8847 (linux_arch_setup): Update its comment for general use.
8848 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8849 (struct linux_target_ops): Use linux_post_create_inferior.
8850 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8851 to post_create_inferior.
8852 * nto-low.c (struct nto_target_ops): Likewise.
8853 * spu-low.c (struct spu_target_ops): Likewise.
8854 * win32-low.c (struct win32_target_ops): Likewise.
8856 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
8858 * linux-arm-low.c: Remove duplicate arch/arm.h include.
8860 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8862 * linux-arm-low.c (arm_reinsert_addr): Remove function.
8863 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
8864 * linux-cris-low.c (cris_reinsert_addr> Remove function.
8865 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8866 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
8867 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8868 * linux-mips-low.c (mips_reinsert_addr): Remove function.
8869 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8870 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
8871 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8872 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
8873 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8875 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8877 * linux-low.c (linux_look_up_symbols): Don't call
8878 linux_supports_traceclone.
8879 * linux-low.h (thread_db_init): Remove use_events argument.
8880 * thread-db.c (thread_db_use_event): Remove global variable.
8881 (struct thread_db) <td_thr_event_enable_p>: Remove field.
8882 (struct thread_db) <td_create_bp>: Remove field.
8883 (thread_db_create_event): Remove function.
8884 (thread_db_enable_reporting): Likewise.
8885 (find_one_thread): Don't check for thread_db_use_events.
8886 (attach_thread): Likewise.
8887 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
8888 (try_thread_db_load_1): Don't check for thread_db_use_events.
8889 (thread_db_init): Remove use_events argument and thread events
8891 (remove_thread_event_breakpoints): Remove function.
8892 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
8894 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8896 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
8898 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8899 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
8900 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8901 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
8902 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
8904 * linux-crisv32-low.c (cris_supports_hardware_single_step):
8906 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8907 * linux-low.c (can_hardware_single_step): Use
8908 supports_hardware_single_step.
8909 (can_software_single_step): New function.
8910 (start_step_over): Call can_software_single_step.
8911 (linux_supports_hardware_single_step): New function.
8912 (struct target_ops) <supports_software_single_step>: Initialize.
8913 * linux-low.h (struct linux_target_ops)
8914 <supports_hardware_single_step>: Initialize.
8915 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
8916 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8917 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
8918 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
8919 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
8920 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8921 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
8922 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8923 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
8924 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
8926 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
8927 (struct linux_target_ops) <tile_supports_hardware_single_step>:
8929 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
8930 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8931 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
8933 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8934 * target.h (struct target_ops): <supports_software_single_step>:
8936 (target_supports_software_single_step): New macro.
8938 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8940 * linux-low.c (linux_wait_1): Fix pc advance condition.
8941 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
8942 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
8944 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8946 * linux-arm-low.c (arm_is_thumb_mode): New function.
8947 (arm_breakpoint_at): Use arm_is_thumb_mode.
8948 (arm_breakpoint_kind_from_current_state): New function.
8949 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
8951 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
8952 (linux_breakpoint_kind_from_current_state): New function.
8953 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
8954 * linux-low.h (struct linux_target_ops)
8955 <breakpoint_kind_from_current_state>: New field.
8956 * target.h (struct target_ops): Likewise.
8957 (target_breakpoint_kind_from_current_state): New macro.
8959 2015-11-30 Pedro Alves <palves@redhat.com>
8961 * linux-low.c (linux_resume): Wake up the event loop before
8964 2015-11-30 Pedro Alves <palves@redhat.com>
8966 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
8968 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
8970 * target.c (struct thread_search): New structure.
8971 (thread_search_callback): New function.
8972 (prev_general_thread): New global.
8973 (prepare_to_access_memory, done_accessing_memory): New functions.
8974 * target.h (prepare_to_access_memory, done_accessing_memory):
8975 Replace macros with function declarations.
8977 2015-11-30 Pedro Alves <palves@redhat.com>
8980 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
8981 report TARGET_WAITKIND_NO_RESUMED.
8982 * remote-utils.c (prepare_resume_reply): Handle
8983 TARGET_WAITKIND_NO_RESUMED.
8984 * server.c (report_no_resumed): New global.
8985 (handle_query) <qSupported>: Handle "no-resumed+". Report
8986 "no-resumed+" support.
8987 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
8988 return error if the client doesn't support no-resumed events.
8989 (push_stop_notification): New function.
8990 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
8991 events if the client supports them.
8993 2015-11-30 Pedro Alves <palves@redhat.com>
8995 * linux-low.c (thread_still_has_status_pending_p): Don't check
8997 (lwp_resumed): New function.
8998 (status_pending_p_callback): Return early if the LWP is not
8999 supposed to be resumed.
9001 2015-11-30 Pedro Alves <palves@redhat.com>
9003 * linux-low.c (handle_extended_wait): Assert that the LWP's
9004 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9005 thread create events, leave the new child's status pending.
9006 (linux_low_filter_event): If GDB wants to hear about thread exit
9007 events, leave the LWP marked dead and don't delete it.
9008 (linux_wait_for_event_filtered): Don't check for thread exit.
9009 (filter_exit_event): New function.
9010 (linux_wait_1): Use it, when returning an exit event.
9011 (linux_resume_one_lwp_throw): Assert that the LWP's
9012 waitstatus is TARGET_WAITKIND_IGNORE.
9013 * remote-utils.c (prepare_resume_reply): Handle
9014 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9015 * server.c (report_thread_events): New global.
9016 (handle_general_set): Handle QThreadEvents.
9017 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9018 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9019 TARGET_WAITKIND_THREAD_EXITED.
9020 * server.h (report_thread_events): Declare.
9022 2015-11-30 Pedro Alves <palves@redhat.com>
9024 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9025 the thread's last_resume_kind was resume_stop.
9027 2015-11-30 Pedro Alves <palves@redhat.com>
9029 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9032 2015-11-30 Pedro Alves <palves@redhat.com>
9034 * server.c (handle_v_requests): Handle vCtrlC.
9036 2015-11-30 Pedro Alves <palves@redhat.com>
9038 * gdbthread.h (find_any_thread_of_pid): Declare.
9039 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9041 * server.c (handle_query): If current_thread is NULL, look for
9042 another thread of the selected process.
9044 2015-11-26 Daniel Colascione <dancol@dancol.org>
9045 Simon Marchi <simon.marchi@ericsson.com>
9047 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9048 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9050 * target.h (struct target_ops) <thread_name>: New field.
9051 (target_thread_name): New macro.
9053 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9055 * regcache.h (regcache_invalidate_pid): Add declaration.
9056 * regcache.c (regcache_invalidate_pid): New function, extracted
9057 from regcache_invalidate.
9058 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9059 Add trivial documentation comment.
9060 * lynx-low.c: Use regcache_invalidate_pid instead of
9061 regcache_invalidate.
9063 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9065 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9066 and Elf64_auxv_t if the target is Android.
9068 2015-11-22 Doug Evans <xdje42@gmail.com>
9070 * target.h: #include <sys/types.h>.
9072 2015-11-19 Pedro Alves <palves@redhat.com>
9074 * linux-low.c (linux_process_qsupported): Change prototype.
9076 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9078 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9079 and adjust to loop over all features.
9080 * server.c (handle_query) <qSupported>: Adjust to call
9081 target_process_qsupported once, passing it a vector of unprocessed
9083 * target.h (struct target_ops) <process_qsupported>: Change
9085 (target_process_qsupported): Adjust.
9087 2015-11-19 Pedro Alves <palves@redhat.com>
9089 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9091 * configure: Regenerate.
9093 2015-11-19 Pedro Alves <palves@redhat.com>
9095 * configure: Regenerate.
9097 2015-11-19 Yao Qi <yao.qi@linaro.org>
9099 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9102 2015-11-19 Yao Qi <yao.qi@linaro.org>
9104 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9105 (struct aarch64_operand): Move enum out.
9107 2015-11-19 Yao Qi <yao.qi@linaro.org>
9109 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9110 struct user_fpsimd_state *.
9111 (aarch64_store_fpregset): Likewise.
9113 2015-11-19 Yao Qi <yao.qi@linaro.org>
9115 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9116 struct user_pt_regs *.
9117 (aarch64_store_gregset): Likewise.
9119 2015-11-18 Pedro Alves <palves@redhat.com>
9121 * Makefile.in (all_object_files): Add $IPA_OBJS.
9123 2015-11-17 Pedro Alves <palves@redhat.com>
9125 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9126 GDB_SIGNAL_0 and gdb_signal_to_string.
9128 2015-11-17 Pedro Alves <palves@redhat.com>
9130 * win32-low.c (handle_output_debug_string): Remove parameter.
9131 (win32_kill): Remove our_status local and adjust call to
9132 handle_output_debug_string.
9133 (get_child_debug_event): Adjust call to
9134 handle_output_debug_string.
9136 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9138 * linux-mips-low.c (mips_fill_gregset): Add cast.
9139 (mips_store_gregset): Likewise.
9140 (mips_fill_fpregset): Likewise.
9141 (mips_store_fpregset): Likewise.
9143 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9145 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9148 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9150 * linux-mips-low.c (mips_linux_new_thread): Change type of
9151 watch_type to enum target_hw_bp_type.
9153 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9155 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9156 Change return type to arm_hwbp_type.
9158 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9160 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9161 (arm_store_gregset): Likewise.
9162 * linux-arm-low.c (arm_get_hwcap): Likewise.
9163 (arm_read_description): Likewise.
9165 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9167 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9169 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9171 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9172 (ppc_fill_vsxregset): Likewise.
9173 (ppc_store_vsxregset): Likewise.
9174 (ppc_fill_vrregset): Likewise.
9175 (ppc_store_vrregset): Likewise.
9176 (ppc_fill_evrregset): Likewise.
9177 (ppc_store_evrregset): Likewise.
9179 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9181 * linux-ppc-low.c (ppc_usrregs_info): Remove
9182 forward-declaration.
9183 (ppc_arch_setup): Move lower in file.
9185 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9187 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9188 (ps_pdwrite): Likewise.
9190 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9192 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9193 to after assert checks.
9195 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9197 * proc-service.c (ps_pdread): Add/adjust casts.
9198 (ps_pdwrite): Add/adjust casts.
9200 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9202 * server.c (handle_search_memory_1): Cast return value of
9205 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9207 * server.c (write_qxfer_response): Change type of data to
9210 2015-10-29 Pedro Alves <palves@redhat.com>
9212 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9214 2015-10-29 Pedro Alves <palves@redhat.com>
9216 * tracepoint.c (clear_installed_tracepoints): Add casts.
9218 2015-10-29 Pedro Alves <palves@redhat.com>
9220 * server.c (handle_v_cont, process_serial_event): Add enum
9221 gdb_signal casts to signal parsing code.
9223 2015-10-29 Pedro Alves <palves@redhat.com>
9225 * linux-low.h (NULL_REGSET): Define.
9226 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9227 * linux-arm-low.c (arm_regsets): Likewise.
9228 * linux-crisv32-low.c (cris_regsets): Likewise.
9229 * linux-m68k-low.c (m68k_regsets): Likewise.
9230 * linux-mips-low.c (mips_regsets): Likewise.
9231 * linux-nios2-low.c (nios2_regsets): Likewise.
9232 * linux-ppc-low.c (ppc_regsets): Likewise.
9233 * linux-s390-low.c (s390_regsets): Likewise.
9234 * linux-sh-low.c (sh_regsets): Likewise.
9235 * linux-sparc-low.c (sparc_regsets): Likewise.
9236 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9237 * linux-tile-low.c (tile_regsets): Likewise.
9238 * linux-x86-low.c (x86_regsets): Likewise.
9239 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9241 2015-10-29 Pedro Alves <palves@redhat.com>
9243 * linux-low.h (NULL_REGSET): Define.
9244 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9245 * linux-arm-low.c (arm_regsets): Likewise.
9246 * linux-crisv32-low.c (cris_regsets): Likewise.
9247 * linux-m68k-low.c (m68k_regsets): Likewise.
9248 * linux-mips-low.c (mips_regsets): Likewise.
9249 * linux-nios2-low.c (nios2_regsets): Likewise.
9250 * linux-ppc-low.c (ppc_regsets): Likewise.
9251 * linux-s390-low.c (s390_regsets): Likewise.
9252 * linux-sh-low.c (sh_regsets): Likewise.
9253 * linux-sparc-low.c (sparc_regsets): Likewise.
9254 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9255 * linux-tile-low.c (tile_regsets): Likewise.
9256 * linux-x86-low.c (x86_regsets): Likewise.
9257 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9259 2015-10-26 Doug Evans <dje@google.com>
9261 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9263 2015-10-26 Doug Evans <dje@google.com>
9265 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9267 2015-10-26 Doug Evans <dje@google.com>
9269 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9271 (attach_thread, find_new_threads_callback): Ditto.
9273 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9275 * mem-break.h (set_breakpoint_data): Remove.
9277 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9279 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9280 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9281 (initialize_low): Remove set_breakpoint_data call.
9282 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9283 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9284 (initialize_low): Remove set_breakpoint_data call.
9285 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9286 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9287 (initialize_low): Remove set_breakpoint_data call.
9289 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9291 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9292 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9293 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9294 * target.h (target_breakpoint_kind_from_pc): New macro.
9296 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9298 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9299 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9300 the default breakpoint kind.
9302 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9304 * linux-arm-low.c (arm_supports_z_point_type): Add software
9307 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9309 * linux-arm-low.c: Refactor breakpoint definitions.
9310 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9311 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9313 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9315 * Makefile.in: Add arm.c/o.
9316 * configure.srv: Likewise.
9317 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9318 (arm_breakpoint_kind_from_pc): New function.
9319 (arm_sw_breakpoint_from_kind): Return proper kind.
9320 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9322 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9324 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9326 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9327 (struct raw_breakpoint) <size>: Remove.
9328 (struct raw_breakpoint) <kind>: Add.
9329 (bp_size): New function.
9330 (bp_opcode): Likewise.
9331 (find_raw_breakpoint_at): Adjust for kind.
9332 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9333 (remove_memory_breakpoint): Adjust for kind call bp_size.
9334 (set_raw_breakpoint_at): Adjust for kind.
9335 (set_breakpoint): Likewise.
9336 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9337 (delete_raw_breakpoint): Adjust for kind.
9338 (delete_breakpoint): Likewise.
9339 (find_gdb_breakpoint): Likewise.
9340 (set_gdb_breakpoint_1): Likewise.
9341 (set_gdb_breakpoint): Likewise.
9342 (delete_gdb_breakpoint_1): Likewise.
9343 (delete_gdb_breakpoint): Likewise.
9344 (uninsert_raw_breakpoint): Likewise.
9345 (reinsert_raw_breakpoint): Likewise.
9346 (set_breakpoint_data): Remove.
9347 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9348 (check_mem_read): Adjust for kind call bp_size.
9349 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9350 (clone_one_breakpoint): Adjust for kind.
9351 * mem-break.h (set_gdb_breakpoint): Likewise.
9352 (delete_gdb_breakpoint): Likewise.
9353 * server.c (process_serial_event): Likewise.
9355 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9357 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9358 (struct linux_target_ops) <breakpoint>: Remove.
9359 (struct linux_target_ops) <breakpoint_len>: Remove.
9360 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9361 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9362 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9363 (arm_sw_breakpoint_from_kind): New function.
9364 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9365 (struct linux_target_ops) <breakpoint>: Remove.
9366 (struct linux_target_ops) <breakpoint_len>: Remove.
9367 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9368 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9369 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9370 (struct linux_target_ops) <breakpoint>: Remove.
9371 (struct linux_target_ops) <breakpoint_len>: Remove.
9372 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9373 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9374 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9375 (struct linux_target_ops) <breakpoint>: Remove.
9376 (struct linux_target_ops) <breakpoint_len>: Remove.
9377 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9378 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9379 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9380 and sw_breakpoint_from_kind to increment the pc.
9381 (linux_breakpoint_kind_from_pc): New function.
9382 (linux_sw_breakpoint_from_kind): New function.
9383 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9384 (initialize_low): Call breakpoint_kind_from_pc and
9385 sw_breakpoint_from_kind to replace breakpoint_data/len.
9386 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9388 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9389 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9390 (struct linux_target_ops) <breakpoint>: Remove.
9391 (struct linux_target_ops) <breakpoint_len>: Remove.
9392 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9393 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9394 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9395 (struct linux_target_ops) <breakpoint>: Remove.
9396 (struct linux_target_ops) <breakpoint_len>: Remove.
9397 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9398 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9399 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9400 (struct linux_target_ops) <breakpoint>: Remove.
9401 (struct linux_target_ops) <breakpoint_len>: Remove.
9402 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9403 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9404 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9405 (struct linux_target_ops) <breakpoint>: Remove.
9406 (struct linux_target_ops) <breakpoint_len>: Remove.
9407 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9408 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9409 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9410 (struct linux_target_ops) <breakpoint>: Remove.
9411 (struct linux_target_ops) <breakpoint_len>: Remove.
9412 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9413 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9414 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9415 (struct linux_target_ops) <breakpoint>: Remove.
9416 (struct linux_target_ops) <breakpoint_len>: Remove.
9417 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9418 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9419 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9420 (struct linux_target_ops) <breakpoint>: Remove.
9421 (struct linux_target_ops) <breakpoint_len>: Remove.
9422 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9423 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9424 * linux-sparc-low.c (sparc_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-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9430 (struct linux_target_ops) <breakpoint>: Remove.
9431 (struct linux_target_ops) <breakpoint_len>: Remove.
9432 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9433 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9434 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9435 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9436 (struct linux_target_ops) <breakpoint>: Remove.
9437 (struct linux_target_ops) <breakpoint_len>: Remove.
9438 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9439 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9440 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9441 (struct linux_target_ops) <breakpoint>: Remove.
9442 (struct linux_target_ops) <breakpoint_len>: Remove.
9443 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9444 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9446 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9448 * linux-cris-low.c (cris_get_pc): Remove void arg.
9450 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9452 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9455 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9457 * inferiors.c (thread_pid_matches_callback): New function.
9458 (find_thread_process): New function.
9459 (remove_thread): Reset current_thread.
9460 (remove_process): Assert threads have been removed first.
9462 2015-10-15 Yao Qi <yao.qi@linaro.org>
9464 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9466 (aarch64_remove_point): Likewise.
9467 * regcache.c (regcache_register_size): New function.
9469 2015-10-12 Yao Qi <yao.qi@linaro.org>
9471 * linux-aarch64-low.c: Update all callers as emit_load_store
9472 is renamed to aarch64_emit_load_store.
9474 2015-10-12 Yao Qi <yao.qi@linaro.org>
9476 * linux-aarch64-low.c: Update all callers of function renaming
9477 from emit_insn to aarch64_emit_insn.
9479 2015-10-12 Yao Qi <yao.qi@linaro.org>
9481 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9482 arch/aarch64-insn.h.
9483 (struct aarch64_memory_operand): Likewise.
9485 (emit_insn): Move to arch/aarch64-insn.c.
9486 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9487 (emit_load_store): Move to arch/aarch64-insn.c.
9488 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9489 (can_encode_int32): Remove.
9491 2015-10-12 Yao Qi <yao.qi@linaro.org>
9493 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9494 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9495 (aarch64_relocate_instruction): Likewise.
9496 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9497 (struct aarch64_insn_visitor): Likewise.
9499 2015-10-12 Yao Qi <yao.qi@linaro.org>
9501 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9502 (struct aarch64_insn_visitor): New.
9503 (struct aarch64_insn_relocation_data): New.
9504 (aarch64_ftrace_insn_reloc_b): New function.
9505 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9506 (aarch64_ftrace_insn_reloc_cb): Likewise.
9507 (aarch64_ftrace_insn_reloc_tb): Likewise.
9508 (aarch64_ftrace_insn_reloc_adr): Likewise.
9509 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9510 (aarch64_ftrace_insn_reloc_others): Likewise.
9512 (aarch64_relocate_instruction): Use visitor.
9514 2015-10-12 Yao Qi <yao.qi@linaro.org>
9516 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9517 int. Add argument buf.
9518 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9519 aarch64_relocate_instruction.
9521 2015-10-12 Yao Qi <yao.qi@linaro.org>
9523 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9524 argument insn. Remove local variable insn. Don't call
9526 (aarch64_install_fast_tracepoint_jump_pad): Call
9529 2015-09-30 Yao Qi <yao.qi@linaro.org>
9531 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9532 (emit_load_store_pair): Likewise.
9534 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9536 * dll.c (match_dll): Add cast(s).
9537 (unloaded_dll): Likewise.
9538 * linux-low.c (second_thread_of_pid_p): Likewise.
9539 (delete_lwp_callback): Likewise.
9540 (count_events_callback): Likewise.
9541 (select_event_lwp_callback): Likewise.
9542 (linux_set_resume_request): Likewise.
9543 * server.c (accumulate_file_name_length): Likewise.
9544 (emit_dll_description): Likewise.
9545 (handle_qxfer_threads_worker): Likewise.
9546 (visit_actioned_threads): Likewise.
9547 * thread-db.c (any_thread_of): Likewise.
9548 * tracepoint.c (same_process_p): Likewise.
9549 (match_blocktype): Likewise.
9550 (build_traceframe_info_xml): Likewise.
9552 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9554 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9556 (gdb_unparse_agent_expr): Likewise.
9557 * hostio.c (require_data): Likewise.
9558 (handle_pread): Likewise.
9559 * linux-low.c (disable_regset): Likewise.
9560 (fetch_register): Likewise.
9561 (store_register): Likewise.
9562 (get_dynamic): Likewise.
9563 (linux_qxfer_libraries_svr4): Likewise.
9564 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9565 (set_fast_tracepoint_jump): Likewise.
9566 (uninsert_fast_tracepoint_jumps_at): Likewise.
9567 (reinsert_fast_tracepoint_jumps_at): Likewise.
9568 (validate_inserted_breakpoint): Likewise.
9569 (clone_agent_expr): Likewise.
9570 * regcache.c (init_register_cache): Likewise.
9571 * remote-utils.c (putpkt_binary_1): Likewise.
9572 (decode_M_packet): Likewise.
9573 (decode_X_packet): Likewise.
9574 (look_up_one_symbol): Likewise.
9575 (relocate_instruction): Likewise.
9576 (monitor_output): Likewise.
9577 * server.c (handle_search_memory): Likewise.
9578 (handle_qxfer_exec_file): Likewise.
9579 (handle_qxfer_libraries): Likewise.
9580 (handle_qxfer): Likewise.
9581 (handle_query): Likewise.
9582 (handle_v_cont): Likewise.
9583 (handle_v_run): Likewise.
9584 (captured_main): Likewise.
9585 * target.c (write_inferior_memory): Likewise.
9586 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9587 * tracepoint.c (init_trace_buffer): Likewise.
9588 (add_tracepoint_action): Likewise.
9589 (add_traceframe): Likewise.
9590 (add_traceframe_block): Likewise.
9591 (cmd_qtdpsrc): Likewise.
9592 (cmd_qtdv): Likewise.
9593 (cmd_qtstatus): Likewise.
9594 (response_source): Likewise.
9595 (response_tsv): Likewise.
9596 (cmd_qtnotes): Likewise.
9597 (gdb_collect): Likewise.
9598 (initialize_tracepoint): Likewise.
9600 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9602 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9603 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9604 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9606 (enum aarch64_condition_codes): New enum.
9607 (w0): New static global.
9610 (struct aarch64_memory_operand) <type>: New
9611 MEMORY_OPERAND_POSTINDEX type.
9612 (postindex_memory_operand): New helper function.
9613 (emit_ret): New function.
9614 (emit_load_store_pair): New function, factored out of emit_stp
9615 with support for MEMORY_OPERAND_POSTINDEX.
9616 (emit_stp): Rewrite using emit_load_store_pair.
9617 (emit_ldp): New function.
9618 (emit_load_store): Likewise.
9619 (emit_ldr): Mention post-index instruction in comment.
9620 (emit_ldrh): New function.
9621 (emit_ldrb): New function.
9622 (emit_ldrsw): Mention post-index instruction in comment.
9623 (emit_str): Likewise.
9624 (emit_subs): New function.
9625 (emit_cmp): Likewise.
9626 (emit_and): Likewise.
9627 (emit_orr): Likewise.
9628 (emit_orn): Likewise.
9629 (emit_eor): Likewise.
9630 (emit_mvn): Likewise.
9631 (emit_lslv): Likewise.
9632 (emit_lsrv): Likewise.
9633 (emit_asrv): Likewise.
9634 (emit_mul): Likewise.
9635 (emit_sbfm): Likewise.
9636 (emit_sbfx): Likewise.
9637 (emit_ubfm): Likewise.
9638 (emit_ubfx): Likewise.
9639 (emit_csinc): Likewise.
9640 (emit_cset): Likewise.
9641 (emit_nop): Likewise.
9642 (emit_ops_insns): New helper function.
9643 (emit_pop): Likewise.
9644 (emit_push): Likewise.
9645 (aarch64_emit_prologue): New function.
9646 (aarch64_emit_epilogue): Likewise.
9647 (aarch64_emit_add): Likewise.
9648 (aarch64_emit_sub): Likewise.
9649 (aarch64_emit_mul): Likewise.
9650 (aarch64_emit_lsh): Likewise.
9651 (aarch64_emit_rsh_signed): Likewise.
9652 (aarch64_emit_rsh_unsigned): Likewise.
9653 (aarch64_emit_ext): Likewise.
9654 (aarch64_emit_log_not): Likewise.
9655 (aarch64_emit_bit_and): Likewise.
9656 (aarch64_emit_bit_or): Likewise.
9657 (aarch64_emit_bit_xor): Likewise.
9658 (aarch64_emit_bit_not): Likewise.
9659 (aarch64_emit_equal): Likewise.
9660 (aarch64_emit_less_signed): Likewise.
9661 (aarch64_emit_less_unsigned): Likewise.
9662 (aarch64_emit_ref): Likewise.
9663 (aarch64_emit_if_goto): Likewise.
9664 (aarch64_emit_goto): Likewise.
9665 (aarch64_write_goto_address): Likewise.
9666 (aarch64_emit_const): Likewise.
9667 (aarch64_emit_call): Likewise.
9668 (aarch64_emit_reg): Likewise.
9669 (aarch64_emit_pop): Likewise.
9670 (aarch64_emit_stack_flush): Likewise.
9671 (aarch64_emit_zero_ext): Likewise.
9672 (aarch64_emit_swap): Likewise.
9673 (aarch64_emit_stack_adjust): Likewise.
9674 (aarch64_emit_int_call_1): Likewise.
9675 (aarch64_emit_void_call_2): Likewise.
9676 (aarch64_emit_eq_goto): Likewise.
9677 (aarch64_emit_ne_goto): Likewise.
9678 (aarch64_emit_lt_goto): Likewise.
9679 (aarch64_emit_le_goto): Likewise.
9680 (aarch64_emit_gt_goto): Likewise.
9681 (aarch64_emit_ge_got): Likewise.
9682 (aarch64_emit_ops_impl): New static global variable.
9683 (aarch64_emit_ops): New target function, return
9684 &aarch64_emit_ops_impl.
9685 (struct linux_target_ops): Install it.
9687 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9689 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9690 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9692 * linux-aarch64-ipa.c: New file.
9693 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9695 (aarch64_get_thread_area): New target method.
9696 (extract_signed_bitfield): New helper function.
9697 (aarch64_decode_ldr_literal): New function.
9698 (enum aarch64_opcodes): New enum.
9699 (struct aarch64_register): New struct.
9700 (struct aarch64_operand): New struct.
9701 (x0): New static global.
9710 (aarch64_register): New helper function.
9711 (register_operand): Likewise.
9712 (immediate_operand): Likewise.
9713 (struct aarch64_memory_operand): New struct.
9714 (offset_memory_operand): New helper function.
9715 (preindex_memory_operand): Likewise.
9716 (enum aarch64_system_control_registers): New enum.
9717 (ENCODE): New macro.
9718 (emit_insn): New helper function.
9719 (emit_b): New function.
9720 (emit_bcond): Likewise.
9721 (emit_cb): Likewise.
9722 (emit_tb): Likewise.
9723 (emit_blr): Likewise.
9724 (emit_stp): Likewise.
9725 (emit_ldp_q_offset): Likewise.
9726 (emit_stp_q_offset): Likewise.
9727 (emit_load_store): Likewise.
9728 (emit_ldr): Likewise.
9729 (emit_ldrsw): Likewise.
9730 (emit_str): Likewise.
9731 (emit_ldaxr): Likewise.
9732 (emit_stxr): Likewise.
9733 (emit_stlr): Likewise.
9734 (emit_data_processing_reg): Likewise.
9735 (emit_data_processing): Likewise.
9736 (emit_add): Likewise.
9737 (emit_sub): Likewise.
9738 (emit_mov): Likewise.
9739 (emit_movk): Likewise.
9740 (emit_mov_addr): Likewise.
9741 (emit_mrs): Likewise.
9742 (emit_msr): Likewise.
9743 (emit_sevl): Likewise.
9744 (emit_wfe): Likewise.
9745 (append_insns): Likewise.
9746 (can_encode_int32_in): New helper function.
9747 (aarch64_relocate_instruction): New function.
9748 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9749 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9750 (struct linux_target_ops): Install aarch64_get_thread_area,
9751 aarch64_install_fast_tracepoint_jump_pad and
9752 aarch64_get_min_fast_tracepoint_insn_len.
9754 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9756 * Makefile.in (aarch64-insn.o): New rule.
9757 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9759 2015-09-21 Yao Qi <yao.qi@linaro.org>
9761 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9763 2015-09-21 Yao Qi <yao.qi@linaro.org>
9765 * tracepoint.c (max_jump_pad_size): Remove.
9767 2015-09-18 Yao Qi <yao.qi@linaro.org>
9769 * linux-aarch64-low.c: Don't include sys/uio.h.
9770 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9772 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
9774 * tracepoint.c (eval_result_type): Change prototype.
9775 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9777 2015-09-15 Pedro Alves <palves@redhat.com>
9779 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9780 Check whether to report exec events instead of checking whether
9781 multiprocess is enabled.
9783 2015-09-15 Pedro Alves <palves@redhat.com>
9786 * remote-utils.c (prepare_resume_reply): Merge
9787 TARGET_WAITKIND_VFORK_DONE switch case with the
9788 TARGET_WAITKIND_FORKED case.
9790 2015-09-15 Yao Qi <yao.qi@linaro.org>
9792 * server.c (handle_query): Check string comparison using
9793 "else if" instead of "if".
9795 2015-09-15 Yao Qi <yao.qi@linaro.org>
9797 * server.c (vCont_supported): New global variable.
9798 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9799 matches. Append ";vContSupported+" to own_buf.
9800 (handle_v_requests): Append ";s;S" to own_buf if target supports
9801 hardware single step or vCont_supported is false.
9802 (capture_main): Set vCont_supported to zero.
9804 2015-09-15 Yao Qi <yao.qi@linaro.org>
9806 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9808 (linux_supports_hardware_single_step): ... New function.
9809 (linux_target_ops): Update.
9810 * lynx-low.c (lynx_target_ops): Set field
9811 supports_hardware_single_step to target_can_do_hardware_single_step.
9812 * nto-low.c (nto_target_ops): Likewise.
9813 * spu-low.c (spu_target_ops): Likewise.
9814 * win32-low.c (win32_target_ops): Likewise.
9815 * target.c (target_can_do_hardware_single_step): New function.
9816 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9817 Remove. <supports_hardware_single_step>: New field.
9818 (target_supports_conditional_breakpoints): Remove.
9819 (target_supports_hardware_single_step): New macro.
9820 (target_can_do_hardware_single_step): Declare.
9821 * server.c (handle_query): Use target_supports_hardware_single_step
9822 instead of target_supports_conditional_breakpoints.
9824 2015-09-15 Yao Qi <yao.qi@linaro.org>
9826 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9828 (struct linux_target_ops the_low_target): Install
9829 aarch64_linux_siginfo_fixup.
9831 2015-09-11 Don Breazeal <donb@codesourcery.com>
9832 Luis Machado <lgustavo@codesourcery.com>
9834 * linux-low.c (linux_mourn): Static declaration.
9835 (linux_arch_setup): Move in front of
9836 handle_extended_wait.
9837 (linux_arch_setup_thread): New function.
9838 (handle_extended_wait): Handle exec events. Call
9839 linux_arch_setup_thread. Make event_lwp argument a
9840 pointer-to-a-pointer.
9841 (check_zombie_leaders): Do not check stopped threads.
9842 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9843 (linux_low_filter_event): Add lwp and thread for exec'ing
9844 non-leader thread if leader thread has been deleted.
9845 Refactor code into linux_arch_setup_thread and call it.
9846 Pass child lwp pointer by reference to handle_extended_wait.
9847 (linux_wait_for_event_filtered): Update comment.
9848 (linux_wait_1): Prevent clobbering exec event status.
9849 (linux_supports_exec_events): New function.
9850 (linux_target_ops) <supports_exec_events>: Initialize new member.
9851 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9853 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9854 * server.c (report_exec_events): New global variable.
9855 (handle_query): Handle qSupported query for exec-events feature.
9856 (captured_main): Initialize report_exec_events.
9857 * server.h (report_exec_events): Declare new global variable.
9858 * target.h (struct target_ops) <supports_exec_events>: New
9860 (target_supports_exec_events): New macro.
9861 * win32-low.c (win32_target_ops) <supports_exec_events>:
9862 Initialize new member.
9864 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
9866 * linux-low.c (linux_low_enable_btrace): Remove.
9867 (linux_target_ops): Replace linux_low_enable_btrace with
9868 linux_enable_btrace.
9870 2015-09-03 Yao Qi <yao.qi@linaro.org>
9872 * linux-aarch64-low.c (aarch64_insert_point): Call
9873 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
9876 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
9878 * linux-low.c (check_stopped_by_breakpoint): Use
9879 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
9881 2015-08-27 Pedro Alves <palves@redhat.com>
9883 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
9885 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
9887 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
9888 the XNEW-family equivalent.
9889 (compile_bytecodes): Likewise.
9890 * dll.c (loaded_dll): Likewise.
9891 * event-loop.c (append_callback_event): Likewise.
9892 (create_file_handler): Likewise.
9893 (create_file_event): Likewise.
9894 * hostio.c (handle_open): Likewise.
9895 * inferiors.c (add_thread): Likewise.
9896 (add_process): Likewise.
9897 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
9898 * linux-arm-low.c (arm_new_process): Likewise.
9899 (arm_new_thread): Likewise.
9900 * linux-low.c (add_to_pid_list): Likewise.
9901 (linux_add_process): Likewise.
9902 (handle_extended_wait): Likewise.
9903 (add_lwp): Likewise.
9904 (enqueue_one_deferred_signal): Likewise.
9905 (enqueue_pending_signal): Likewise.
9906 (linux_resume_one_lwp_throw): Likewise.
9907 (linux_resume_one_thread): Likewise.
9908 (linux_read_memory): Likewise.
9909 (linux_write_memory): Likewise.
9910 * linux-mips-low.c (mips_linux_new_process): Likewise.
9911 (mips_linux_new_thread): Likewise.
9912 (mips_add_watchpoint): Likewise.
9913 * linux-x86-low.c (initialize_low_arch): Likewise.
9914 * lynx-low.c (lynx_add_process): Likewise.
9915 * mem-break.c (set_raw_breakpoint_at): Likewise.
9916 (set_breakpoint): Likewise.
9917 (add_condition_to_breakpoint): Likewise.
9918 (add_commands_to_breakpoint): Likewise.
9919 (clone_agent_expr): Likewise.
9920 (clone_one_breakpoint): Likewise.
9921 * regcache.c (new_register_cache): Likewise.
9922 * remote-utils.c (look_up_one_symbol): Likewise.
9923 * server.c (queue_stop_reply): Likewise.
9924 (start_inferior): Likewise.
9925 (queue_stop_reply_callback): Likewise.
9926 (handle_target_event): Likewise.
9927 * spu-low.c (fetch_ppc_memory): Likewise.
9928 (store_ppc_memory): Likewise.
9929 * target.c (set_target_ops): Likewise.
9930 * thread-db.c (thread_db_load_search): Likewise.
9931 (try_thread_db_load_1): Likewise.
9932 * tracepoint.c (add_tracepoint): Likewise.
9933 (add_tracepoint_action): Likewise.
9934 (create_trace_state_variable): Likewise.
9935 (cmd_qtdpsrc): Likewise.
9936 (cmd_qtro): Likewise.
9937 (add_while_stepping_state): Likewise.
9938 * win32-low.c (child_add_thread): Likewise.
9939 (get_image_name): Likewise.
9941 2015-08-25 Yao Qi <yao.qi@linaro.org>
9943 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
9945 2015-08-25 Yao Qi <yao.qi@linaro.org>
9947 * Makefile.in (aarch64-linux.o): New rule.
9948 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
9950 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
9951 (aarch64_init_debug_reg_state): Make it extern.
9952 (aarch64_linux_prepare_to_resume): Remove.
9954 2015-08-25 Yao Qi <yao.qi@linaro.org>
9956 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
9957 lwp_arch_private_info and ptid_of_lwp.
9959 2015-08-25 Yao Qi <yao.qi@linaro.org>
9961 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
9962 Find proc_info by find_process_pid. All callers updated.
9964 2015-08-25 Yao Qi <yao.qi@linaro.org>
9966 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
9968 (debug_reg_change_callback): Remove.
9969 (aarch64_notify_debug_reg_change): Remove.
9971 2015-08-25 Yao Qi <yao.qi@linaro.org>
9973 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
9974 Call current_lwp_ptid.
9976 2015-08-25 Yao Qi <yao.qi@linaro.org>
9978 * linux-aarch64-low.c (debug_reg_change_callback): Use
9981 2015-08-25 Yao Qi <yao.qi@linaro.org>
9983 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
9985 2015-08-25 Yao Qi <yao.qi@linaro.org>
9987 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
9989 2015-08-25 Yao Qi <yao.qi@linaro.org>
9991 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
9994 2015-08-25 Yao Qi <yao.qi@linaro.org>
9996 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
9998 (debug_reg_change_callback): Remove argument entry and add argument
9999 lwp. Remove local variable thread. Don't print thread id in the
10000 debugging output. Don't check whether pid of thread equals to pid.
10001 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10002 iterate_over_lwps instead find_inferior.
10004 2015-08-24 Pedro Alves <palves@redhat.com>
10006 * inferiors.c (get_first_process): New function.
10007 * inferiors.h (get_first_process): New declaration.
10008 * remote-utils.c (read_ptid): Default to the first process in the
10009 list, instead of to the current thread's process.
10011 2015-08-24 Pedro Alves <palves@redhat.com>
10013 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10014 * event-loop.c: Likewise.
10015 * remote-utils.c: Likewise.
10016 * tracepoint.c: Likewise.
10018 2015-08-24 Pedro Alves <palves@redhat.com>
10020 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10023 2015-08-21 Pedro Alves <palves@redhat.com>
10025 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10026 instead of literal 1.
10028 2015-08-21 Pedro Alves <palves@redhat.com>
10030 * tdesc.c (default_description): Explicitly zero-initialize.
10032 2015-08-21 Pedro Alves <palves@redhat.com>
10035 * inferiors.c (remove_thread): Discard any pending stop reply for
10037 * server.c (remove_all_on_match_pid): Rename to ...
10038 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10040 (discard_queued_stop_replies): Change parameter to a ptid. Now
10042 (handle_v_kill, kill_inferior_callback, captured_main)
10043 (process_serial_event): Adjust.
10044 * server.h (discard_queued_stop_replies): Declare.
10046 2015-08-21 Pedro Alves <palves@redhat.com>
10048 * linux-low.c (wait_for_sigstop): Always switch to no thread
10049 selected if the previously current thread dies.
10050 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10051 process instead of the current thread's.
10052 * remote-utils.c (input_interrupt): Don't check if there's no
10054 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10055 current thread to the general thread fails, error out.
10056 (handle_qxfer_auxv, handle_qxfer_libraries)
10057 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10058 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10059 (handle_query): Check if there's a thread selected instead of
10060 checking whether there's any thread in the thread list.
10061 (handle_qxfer_threads, handle_qxfer_btrace)
10062 (handle_qxfer_btrace_conf): Don't error out early if there's no
10063 thread in the thread list.
10064 (handle_v_cont, myresume): Don't set the current thread to the
10066 (process_serial_event) <Hg handling>: Also set thread_id if the
10067 previous general thread is still alive.
10068 (process_serial_event) <g/G handling>: If setting the current
10069 thread to the general thread fails, error out.
10070 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10071 thread's lwp instead of the current thread's.
10072 * target.c (set_desired_thread): If the desired thread was not
10073 found, leave the current thread pointing to NULL. Return an int
10074 (boolean) indicating success.
10075 * target.h (set_desired_thread): Change return type to int.
10077 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10079 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10080 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10082 (ps_get_thread_area): New function.
10084 2015-08-19 Gary Benson <gbenson@redhat.com>
10086 * hostio.c (handle_pread): Do not attempt to read more data
10087 than hostio_reply_with_data can fit in a packet.
10089 2015-08-18 Joel Brobecker <brobecker@adacore.com>
10091 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10093 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10095 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10097 2015-08-06 Pedro Alves <palves@redhat.com>
10099 * tracepoint.c (expr_eval_result): Now an int.
10101 2015-08-06 Pedro Alves <palves@redhat.com>
10103 * gdbthread.h (struct regcache): Forward declare.
10104 (struct thread_info) <regcache_data>: Now a struct regcache
10106 * inferiors.c (inferior_regcache_data)
10107 (set_inferior_regcache_data): Now work with struct regcache
10109 * inferiors.h (struct regcache): Forward declare.
10110 (inferior_regcache_data, set_inferior_regcache_data): Now work
10111 with struct regcache pointers.
10112 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10113 (free_register_cache_thread): Remove struct regcache pointer
10116 2015-08-06 Pedro Alves <palves@redhat.com>
10118 * server.c (captured_main): On error, print the exception message
10119 to stderr, and if run_once is set, throw a quit.
10121 2015-08-06 Pedro Alves <palves@redhat.com>
10123 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10124 the current thread.
10126 2015-08-06 Pedro Alves <palves@redhat.com>
10128 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10129 reading beyond the passed in buffer length.
10131 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10133 * tracepoint.c (symbol_list) <required>: Remove.
10135 2015-08-06 Pedro Alves <palves@redhat.com>
10137 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10138 count if stopping and suspending threads.
10139 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10140 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10141 (linux_detach): Complete an ongoing step-over.
10142 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10144 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10145 (linux_wait_1): If passing a signal to the inferior after
10146 finishing a step-over, unsuspend and re-resume all lwps. If we
10147 see a single-step event but the thread should be continuing, don't
10148 pass the trap to gdb.
10149 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10150 internal_error instead of gdb_assert.
10151 (enqueue_pending_signal): New function.
10152 (check_ptrace_stopped_lwp_gone): Add debug output.
10153 (start_step_over): Use internal_error instead of gdb_assert.
10154 (complete_ongoing_step_over): New function.
10155 (linux_resume_one_thread): Don't resume a suspended thread.
10156 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10159 2015-08-06 Pedro Alves <palves@redhat.com>
10161 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10162 (linux_thread_alive): Use lwp_is_marked_dead.
10163 (extended_event_reported): Delete.
10164 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10165 instead of extended_event_reported.
10166 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10168 (lwp_is_marked_dead): New function.
10169 (lwp_running): Use lwp_is_marked_dead.
10170 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10173 2015-08-06 Pedro Alves <palves@redhat.com>
10175 * linux-low.c (linux_wait_1): Move fork event output out of the
10176 !report_to_gdb check. Pass event_child->waitstatus to
10177 target_waitstatus_to_string instead of ourstatus.
10179 2015-08-04 Yao Qi <yao.qi@linaro.org>
10181 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10182 if current_thread is 32 bit.
10184 2015-08-04 Yao Qi <yao.qi@linaro.org>
10186 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10187 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10188 * server.c (extended_protocol): Remove "static".
10189 * server.h (extended_protocol): Declare it.
10191 2015-08-04 Yao Qi <yao.qi@linaro.org>
10193 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10194 both aarch64 and aarch32.
10195 (aarch64_set_pc): Likewise.
10197 2015-08-04 Yao Qi <yao.qi@linaro.org>
10199 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10200 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10201 arm-with-neon.xml to srv_xmlfiles.
10202 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10203 (is_64bit_tdesc): New function.
10204 (aarch64_linux_read_description): New function.
10205 (aarch64_arch_setup): Call aarch64_linux_read_description.
10206 (regs_info): Rename to regs_info_aarch64.
10207 (aarch64_regs_info): Return right regs_info.
10208 (initialize_low_arch): Call initialize_low_arch_aarch32.
10210 2015-08-04 Yao Qi <yao.qi@linaro.org>
10212 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10213 * linux-aarch32-low.c: New file.
10214 * linux-aarch32-low.h: New file.
10215 * linux-arm-low.c (arm_fill_gregset): Move it to
10216 linux-aarch32-low.c.
10217 (arm_store_gregset): Likewise.
10218 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10219 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10220 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10221 (regs_info): Rename to regs_info_arm.
10222 (arm_regs_info): Return regs_info_aarch32 if
10223 have_ptrace_getregset is 1 and target description is
10224 arm_with_neon or arm_with_vfpv3.
10225 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10226 Call initialize_low_arch_aarch32 instead.
10228 2015-08-04 Yao Qi <yao.qi@linaro.org>
10230 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10231 * linux-low.c: ... here.
10232 * linux-low.h (have_ptrace_getregset): Declare it.
10234 2015-08-04 Pedro Alves <palves@redhat.com>
10236 * thread-db.c (struct thread_db): Use new typedefs.
10237 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10239 (disable_thread_event_reporting): Cast result of dlsym to
10240 destination function pointer type.
10241 (thread_db_mourn): Use td_ta_delete_ftype.
10243 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10245 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10247 (CDX_BREAKPOINT): Define for R2.
10248 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10249 (the_low_target): Add comments.
10251 2015-07-30 Yao Qi <yao.qi@linaro.org>
10253 * linux-arm-low.c (arm_hwcap): Remove it.
10254 (arm_read_description): New local variable arm_hwcap. Don't
10255 set arm_hwcap to zero.
10257 2015-07-30 Yao Qi <yao.qi@linaro.org>
10259 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10260 Use regcache->tdesc instead.
10261 (arm_store_wmmxregset): Likewise.
10262 (arm_fill_vfpregset): Likewise.
10263 (arm_store_vfpregset): Likewise.
10265 2015-07-30 Yao Qi <yao.qi@linaro.org>
10267 * linux-arm-low.c: Include arch/arm.h.
10268 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10269 (arm_store_gregset): Likewise.
10271 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10273 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10274 ptrace's 4th parameter.
10276 2015-07-27 Yao Qi <yao.qi@linaro.org>
10278 * configure.srv (case aarch64*-*-linux*): Don't set
10281 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10283 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10285 * linux-arm-low.c: Likewise.
10286 * linux-cris-low.c: Likewise.
10287 * linux-crisv32-low.c: Likewise.
10288 * linux-low.c: Likewise.
10289 * linux-m68k-low.c: Likewise.
10290 * linux-mips-low.c: Likewise.
10291 * linux-nios2-low.c: Likewise.
10292 * linux-s390-low.c: Likewise.
10293 * linux-sparc-low.c: Likewise.
10294 * linux-tic6x-low.c: Likewise.
10295 * linux-tile-low.c: Likewise.
10296 * linux-x86-low.c: Likewise.
10298 2015-07-24 Pedro Alves <palves@redhat.com>
10300 * config.in: Regenerate.
10301 * configure: Regenerate.
10303 2015-07-24 Pedro Alves <palves@redhat.com>
10305 * acinclude.m4: Include ../ptrace.m4.
10306 * configure.ac: Call GDB_AC_PTRACE.
10307 * config.in, configure: Regenerate.
10309 2015-07-24 Yao Qi <yao.qi@linaro.org>
10311 * linux-low.c (linux_create_inferior): Remove setting to
10312 proc->priv->new_inferior.
10313 (linux_attach): Likewise.
10314 (linux_low_filter_event): Likewise.
10315 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10317 2015-07-24 Yao Qi <yao.qi@linaro.org>
10319 * linux-low.c (linux_arch_setup): New function.
10320 (linux_low_filter_event): If proc->tdesc is NULL and
10321 proc->attached is true, call the_low_target.arch_setup.
10322 Otherwise, keep status pending, and return.
10323 (linux_resume_one_lwp_throw): Don't call get_pc if
10324 thread->while_stepping isn't NULL. Don't call
10325 get_thread_regcache if proc->tdesc is NULL.
10326 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10327 (linux_target_ops): Install arch_setup.
10328 * server.c (start_inferior): Call the_target->arch_setup.
10329 * target.h (struct target_ops) <arch_setup>: New field.
10330 (target_arch_setup): New marco.
10331 * lynx-low.c (lynx_target_ops): Update.
10332 * nto-low.c (nto_target_ops): Update.
10333 * spu-low.c (spu_target_ops): Update.
10334 * win32-low.c (win32_target_ops): Update.
10336 2015-07-24 Yao Qi <yao.qi@linaro.org>
10338 * linux-low.c (linux_add_process): Don't set
10339 proc->priv->new_inferior.
10340 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10341 (linux_attach): Likewise.
10343 2015-07-24 Yao Qi <yao.qi@linaro.org>
10345 * server.c (start_inferior): Code refactor.
10347 2015-07-24 Yao Qi <yao.qi@linaro.org>
10349 * server.c (process_serial_event): Set general_thread.
10351 2015-07-21 Yao Qi <yao.qi@linaro.org>
10353 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10354 aarch64_linux_get_debug_reg_capacity.
10356 2015-07-17 Yao Qi <yao.qi@linaro.org>
10358 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10359 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10360 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10361 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10362 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10363 (AARCH64_HWP_ALIGNMENT): Likewise.
10364 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10365 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10366 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10367 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10368 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10369 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10370 (struct aarch64_debug_reg_state): Likewise.
10371 (struct arch_lwp_info): Likewise.
10372 (aarch64_align_watchpoint): Likewise.
10373 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10374 (aarch64_watchpoint_length): Likewise.
10375 (aarch64_point_encode_ctrl_reg): Likewise
10376 (aarch64_point_is_aligned): Likewise.
10377 (aarch64_align_watchpoint): Likewise.
10378 (aarch64_linux_set_debug_regs):
10379 (aarch64_dr_state_insert_one_point): Likewise.
10380 (aarch64_dr_state_remove_one_point): Likewise.
10381 (aarch64_handle_breakpoint): Likewise.
10382 (aarch64_handle_aligned_watchpoint): Likewise.
10383 (aarch64_handle_unaligned_watchpoint): Likewise.
10384 (aarch64_handle_watchpoint): Likewise.
10386 2015-07-17 Yao Qi <yao.qi@linaro.org>
10388 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10389 and don't aarch64_get_debug_reg_state. All callers update.
10390 (aarch64_handle_aligned_watchpoint): Likewise.
10391 (aarch64_handle_unaligned_watchpoint): Likewise.
10392 (aarch64_handle_watchpoint): Likewise.
10393 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10394 (aarch64_remove_point): Likewise.
10396 2015-07-17 Yao Qi <yao.qi@linaro.org>
10398 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10400 (aarch64_handle_unaligned_watchpoint): Likewise.
10402 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10404 Revert the previous 3 commits:
10405 Move gdb_regex* to common/
10406 Move linux_find_memory_regions_full & co.
10407 gdbserver build-id attribute generator
10409 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10410 Jan Kratochvil <jan.kratochvil@redhat.com>
10412 gdbserver build-id attribute generator.
10413 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10414 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10415 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10417 (get_dynamic): Use find_pdhr to traverse program headers.
10418 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10419 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10420 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10421 (get_hex_build_id): New.
10422 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10423 to reply XML document.
10425 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10426 Jan Kratochvil <jan.kratochvil@redhat.com>
10428 * target.c: Include target/target-utils.h and fcntl.h.
10429 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10430 (target_fileio_read_stralloc): New functions.
10432 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10434 * Makefile.in (OBS): Add gdb_regex.o.
10435 (gdb_regex.o): New.
10436 * config.in: Rebuilt.
10437 * configure: Rebuilt.
10439 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10440 Jan Kratochvil <jan.kratochvil@redhat.com>
10442 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10443 * Makefile.in (OBS): Add target-utils.o.
10444 (linux-maps.o, target-utils.o): New.
10445 * configure.srv (srv_linux_obj): Add linux-maps.o.
10447 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10449 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10450 function, return 1.
10451 (the_low_target): Install it.
10453 2015-07-14 Pedro Alves <palves@redhat.com>
10455 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10456 Instead, ignore ECHILD, and throw an error for other errnos.
10458 2015-07-10 Pedro Alves <palves@redhat.com>
10460 * event-loop.c (struct callback_event) <data>: Change type to
10461 gdb_client_data instance instead of gdb_client_data pointer.
10462 (append_callback_event): Adjust.
10464 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10466 * linux-aarch64-low.c: Add comments for each linux_target_ops
10467 method. Remove comments already covered in target_ops and
10468 linux_target_ops definitions.
10469 (the_low_target): Add comments for each unimplemented method.
10471 2015-07-09 Yao Qi <yao.qi@linaro.org>
10473 * linux-aarch64-low.c (aarch64_regmap): Remove.
10474 (aarch64_usrregs_info): Remove.
10475 (regs_info): Set field usrregs to NULL.
10477 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10479 * linux-low.c: Include "rsp-low.h"
10480 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10481 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10482 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10483 (handle_btrace_enable_pt): New.
10484 (handle_btrace_general_set): Support "pt".
10485 (handle_btrace_conf_general_set): Support "pt:size".
10487 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10489 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10492 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10494 * linux-aarch64-low.c: Remove comment about endianness.
10495 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10496 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10499 2015-06-24 Gary Benson <gbenson@redhat.com>
10501 * linux-i386-ipa.c (stdint.h): Do not include.
10502 * lynx-i386-low.c (stdint.h): Likewise.
10503 * lynx-ppc-low.c (stdint.h): Likewise.
10504 * mem-break.c (stdint.h): Likewise.
10505 * thread-db.c (stdint.h): Likewise.
10506 * tracepoint.c (stdint.h): Likewise.
10507 * win32-low.c (stdint.h): Likewise.
10509 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10511 * server.c (write_qxfer_response): Update call to
10512 remote_escape_output.
10514 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10515 Jan Kratochvil <jan.kratochvil@redhat.com>
10517 Merge multiple hex conversions.
10518 * gdbreplay.c (tohex): Rename to 'fromhex'.
10519 (logchar): Use fromhex.
10521 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10523 * server.c (handle_qxfer_libraries): Set `version' attribute for
10526 2015-06-10 Gary Benson <gbenson@redhat.com>
10528 * target.h (struct target_ops) <multifs_open>: New field.
10529 <multifs_unlink>: Likewise.
10530 <multifs_readlink>: Likewise.
10531 * linux-low.c (nat/linux-namespaces.h): New include.
10532 (linux_target_ops): Initialize the_target->multifs_open,
10533 the_target->multifs_unlink and the_target->multifs_readlink.
10534 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10535 * hostio.c (hostio_fs_pid): New static variable.
10536 (hostio_handle_new_gdb_connection): New function.
10537 (handle_setfs): Likewise.
10538 (handle_open): Use the_target->multifs_open as appropriate.
10539 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10540 (handle_readlink): Use the_target->multifs_readlink as
10542 (handle_vFile): Handle vFile:setfs packets.
10543 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10544 after target_handle_new_gdb_connection.
10546 2015-06-10 Gary Benson <gbenson@redhat.com>
10548 * configure.ac (AC_CHECK_FUNCS): Add setns.
10549 * config.in: Regenerate.
10550 * configure: Likewise.
10551 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10552 (linux-namespaces.o): New rule.
10553 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10555 2015-06-09 Gary Benson <gbenson@redhat.com>
10557 * hostio.c (handle_open): Process mode argument with
10558 fileio_to_host_mode.
10560 2015-06-01 Yao Qi <yao.qi@linaro.org>
10562 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10563 * linux-x86-low.c: Likewise.
10565 2015-05-28 Don Breazeal <donb@codesourcery.com>
10567 * linux-low.c (handle_extended_wait): Initialize
10568 thread_info.last_resume_kind for new fork children.
10570 2015-05-15 Pedro Alves <palves@redhat.com>
10572 * target.h (target_handle_new_gdb_connection): Rewrite using if
10573 wrapped in do/while.
10575 2015-05-14 Joel Brobecker <brobecker@adacore.com>
10577 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10578 * configure, config.in: Regenerate.
10579 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10582 2015-05-12 Don Breazeal <donb@codesourcery.com>
10584 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10585 PTRACE_EVENT_VFORK_DONE.
10586 (linux_low_ptrace_options, extended_event_reported): Add vfork
10588 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10589 and "vforkdone" for RSP 'T' Stop Reply Packet.
10590 * server.h (report_vfork_events): Declare
10593 2015-05-12 Don Breazeal <donb@codesourcery.com>
10595 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10596 (the_low_target) <new_fork>: Initialize new member.
10597 * linux-arm-low.c (arm_new_fork): New function.
10598 (the_low_target) <new_fork>: Initialize new member.
10599 * linux-low.c (handle_extended_wait): Call new target function
10601 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10602 * linux-mips-low.c (mips_add_watchpoint): New function
10603 extracted from mips_insert_point.
10604 (the_low_target) <new_fork>: Initialize new member.
10605 (mips_linux_new_fork): New function.
10606 (mips_insert_point): Call mips_add_watchpoint.
10607 * linux-x86-low.c (x86_linux_new_fork): New function.
10608 (the_low_target) <new_fork>: Initialize new member.
10610 2015-05-12 Don Breazeal <donb@codesourcery.com>
10612 * linux-low.c (handle_extended_wait): Implement return value,
10613 rename argument 'event_child' to 'event_lwp', handle
10614 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10615 (linux_low_ptrace_options): New function.
10616 (linux_low_filter_event): Call linux_low_ptrace_options,
10617 use different argument fo linux_enable_event_reporting,
10618 use return value from handle_extended_wait.
10619 (extended_event_reported): New function.
10620 (linux_wait_1): Call extended_event_reported and set
10621 status to report fork events.
10622 (linux_write_memory): Add pid to debug message.
10623 (reset_lwp_ptrace_options_callback): New function.
10624 (linux_handle_new_gdb_connection): New function.
10625 (linux_target_ops): Initialize new structure member.
10626 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10627 * lynx-low.c: Initialize new structure member.
10628 * remote-utils.c (prepare_resume_reply): Implement stop reason
10629 "fork" for "T" stop message.
10630 * server.c (handle_query): Call handle_new_gdb_connection.
10631 * server.h (report_fork_events): Declare global flag.
10632 * target.h (struct target_ops) <handle_new_gdb_connection>:
10634 (target_handle_new_gdb_connection): New macro.
10635 * win32-low.c: Initialize new structure member.
10637 2015-05-12 Don Breazeal <donb@codesourcery.com>
10639 * mem-break.c (APPEND_TO_LIST): Define macro.
10640 (clone_agent_expr): New function.
10641 (clone_one_breakpoint): New function.
10642 (clone_all_breakpoints): New function.
10643 * mem-break.h: Declare new functions.
10645 2015-05-12 Don Breazeal <donb@codesourcery.com>
10647 * linux-low.c (linux_supports_fork_events): New function.
10648 (linux_supports_vfork_events): New function.
10649 (linux_target_ops): Initialize new structure members.
10650 (initialize_low): Call linux_check_ptrace_features.
10651 * lynx-low.c (lynx_target_ops): Initialize new structure
10653 * server.c (report_fork_events, report_vfork_events):
10655 (handle_query): Add new features to qSupported packet and
10657 (captured_main): Initialize new global variables.
10658 * target.h (struct target_ops) <supports_fork_events>:
10660 <supports_vfork_events>: New member.
10661 (target_supports_fork_events): New macro.
10662 (target_supports_vfork_events): New macro.
10663 * win32-low.c (win32_target_ops): Initialize new structure
10666 2015-05-12 Gary Benson <gbenson@redhat.com>
10668 * server.c (handle_qxfer_exec_file): Use current process
10671 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10673 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10674 Remove HAVE_PTRACE_GETREGS conditionals.
10675 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10676 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10678 2015-05-08 Yao Qi <yao.qi@linaro.org>
10680 * linux-low.c (linux_supports_conditional_breakpoints): New
10682 (linux_target_ops): Install new target method.
10683 * lynx-low.c (lynx_target_ops): Install NULL hook for
10684 supports_conditional_breakpoints.
10685 * nto-low.c (nto_target_ops): Likewise.
10686 * spu-low.c (spu_target_ops): Likewise.
10687 * win32-low.c (win32_target_ops): Likewise.
10688 * server.c (handle_query): Check
10689 target_supports_conditional_breakpoints.
10690 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10692 (target_supports_conditional_breakpoints): New macro.
10694 2015-05-06 Pedro Alves <palves@redhat.com>
10697 * server.c (start_inferior): If the process exits, mourn it.
10699 2015-04-21 Gary Benson <gbenson@redhat.com>
10701 * hostio.c (fileio_open_flags_to_host): Factored out to
10702 fileio_to_host_openflags in common/fileio.c. Single use
10705 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10707 * linux-xtensa-low.c (xtensa_fill_gregset)
10708 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10711 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10713 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10714 (regs_info): Replace usrregs pointer with NULL.
10716 2015-04-17 Gary Benson <gbenson@redhat.com>
10718 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10719 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10720 * server.c (handle_qxfer_exec_file): New function.
10721 (qxfer_packets): Add exec-file entry.
10722 (handle_query): Report qXfer:exec-file:read as supported packet.
10724 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10726 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10728 2015-04-09 Gary Benson <gbenson@redhat.com>
10730 * hostio-errno.c (errno_to_fileio_error): Remove function.
10731 Update caller to use remote_fileio_to_fio_error.
10733 2015-04-09 Yao Qi <yao.qi@linaro.org>
10735 * linux-low.c (linux_insert_point): Call
10736 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10737 (linux_remove_point): Call remove_memory_breakpoint if type is
10739 * linux-x86-low.c (x86_insert_point): Don't call
10740 insert_memory_breakpoint.
10741 (x86_remove_point): Don't call remove_memory_breakpoint.
10743 2015-04-01 Pedro Alves <palves@redhat.com>
10744 Cleber Rosa <crosa@redhat.com>
10746 * server.c (gdbserver_usage): Reorganize and extend the usage
10749 2015-03-24 Pedro Alves <palves@redhat.com>
10751 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10752 output. Also dump TRAP_TRACE.
10753 (linux_low_filter_event): In debug output, distinguish a
10754 resume_stop SIGSTOP from a delayed SIGSTOP.
10756 2015-03-24 Gary Benson <gbenson@redhat.com>
10758 * linux-x86-low.c (x86_linux_new_thread): Moved to
10760 (x86_linux_prepare_to_resume): Likewise.
10762 2015-03-24 Gary Benson <gbenson@redhat.com>
10764 * Makefile.in (x86-linux-dregs.o): New rule.
10765 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10766 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10767 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10768 (x86_linux_dr_get): Likewise.
10769 (x86_linux_dr_set): Likewise.
10770 (update_debug_registers_callback): Likewise.
10771 (x86_linux_dr_set_addr): Likewise.
10772 (x86_linux_dr_get_addr): Likewise.
10773 (x86_linux_dr_set_control): Likewise.
10774 (x86_linux_dr_get_control): Likewise.
10775 (x86_linux_dr_get_status): Likewise.
10776 (x86_linux_update_debug_registers): Likewise.
10778 2015-03-24 Gary Benson <gbenson@redhat.com>
10780 * linux-x86-low.c (x86_linux_update_debug_registers):
10781 New function, factored out from...
10782 (x86_linux_prepare_to_resume): ...this.
10784 2015-03-24 Gary Benson <gbenson@redhat.com>
10786 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10787 (x86_linux_dr_set): Likewise.
10788 (update_debug_registers_callback): Likewise.
10789 (x86_linux_dr_set_addr): Likewise.
10790 (x86_linux_dr_get_addr): Likewise.
10791 (x86_linux_dr_set_control): Likewise.
10792 (x86_linux_dr_get_control): Likewise.
10793 (x86_linux_dr_get_status): Likewise.
10794 (x86_linux_prepare_to_resume): Likewise.
10796 2015-03-24 Gary Benson <gbenson@redhat.com>
10798 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10799 Use perror_with_name. Pass string through gettext.
10800 (x86_linux_dr_set): Likewise.
10802 2015-03-24 Gary Benson <gbenson@redhat.com>
10804 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10805 (x86_linux_dr_set_addr): ...this.
10806 (x86_dr_low_get_addr): Rename to...
10807 (x86_linux_dr_get_addr): ...this.
10808 (x86_dr_low_set_control): Rename to...
10809 (x86_linux_dr_set_control): ...this.
10810 (x86_dr_low_get_control): Rename to...
10811 (x86_linux_dr_get_control): ...this.
10812 (x86_dr_low_get_status): Rename to...
10813 (x86_linux_dr_get_status): ...this.
10814 (x86_dr_low): Update with new function names.
10816 2015-03-24 Gary Benson <gbenson@redhat.com>
10818 * Makefile.in (x86-linux.o): New rule.
10819 * configure.srv: Add x86-linux.o to relevant targets.
10820 * linux-low.c (lwp_set_arch_private_info): New function.
10821 (lwp_arch_private_info): Likewise.
10822 * linux-x86-low.c: Include nat/x86-linux.h.
10823 (arch_lwp_info): Removed structure.
10824 (update_debug_registers_callback):
10825 Use lwp_set_debug_registers_changed.
10826 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10827 and lwp_set_debug_registers_changed.
10828 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10830 2015-03-24 Gary Benson <gbenson@redhat.com>
10832 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10833 * linux-arm-low.c (arm_new_thread): Likewise.
10834 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10835 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10836 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10837 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10839 2015-03-24 Gary Benson <gbenson@redhat.com>
10841 * linux-low.c (ptid_of_lwp): New function.
10842 (lwp_is_stopped): Likewise.
10843 (lwp_stop_reason): Likewise.
10844 * linux-x86-low.c (update_debug_registers_callback):
10845 Use lwp_is_stopped.
10846 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10849 2015-03-24 Gary Benson <gbenson@redhat.com>
10851 * linux-low.h (linux_stop_lwp): Remove declaration.
10853 2015-03-24 Gary Benson <gbenson@redhat.com>
10855 * linux-low.h: Include nat/linux-nat.h.
10856 * linux-low.c (iterate_over_lwps_args): New structure.
10857 (iterate_over_lwps_filter): New function.
10858 (iterate_over_lwps): Likewise.
10859 * linux-x86-low.c (update_debug_registers_callback):
10860 Update signature to what iterate_over_lwps expects.
10861 Remove PID check that iterate_over_lwps now performs.
10862 (x86_dr_low_set_addr): Use iterate_over_lwps.
10863 (x86_dr_low_set_control): Likewise.
10865 2015-03-24 Gary Benson <gbenson@redhat.com>
10867 * linux-x86-low.c (x86_debug_reg_state): New function.
10868 (x86_linux_prepare_to_resume): Use the above.
10870 2015-03-24 Gary Benson <gbenson@redhat.com>
10872 * linux-low.c (current_lwp_ptid): New function.
10873 * linux-x86-low.c: Include nat/linux-nat.h.
10874 (x86_dr_low_get_addr): Use current_lwp_ptid.
10875 (x86_dr_low_get_control): Likewise.
10876 (x86_dr_low_get_status): Likewise.
10878 2015-03-20 Pedro Alves <palves@redhat.com>
10880 * tracepoint.c (cmd_qtstatus): Make "str" const.
10882 2015-03-20 Pedro Alves <palves@redhat.com>
10884 * server.c (handle_general_set): Make "req_str" const.
10886 2015-03-19 Pedro Alves <palves@redhat.com>
10888 * linux-low.c (linux_resume_one_lwp): Rename to ...
10889 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
10890 instead call perror_with_name.
10891 (check_ptrace_stopped_lwp_gone): New function.
10892 (linux_resume_one_lwp): Reimplement as wrapper around
10893 linux_resume_one_lwp_throw that swallows errors if the LWP is
10896 2015-03-19 Pedro Alves <palves@redhat.com>
10898 * linux-low.c (count_events_callback, select_event_lwp_callback):
10899 No longer check whether the thread has resume_stop as last resume
10902 2015-03-19 Pedro Alves <palves@redhat.com>
10904 * linux-low.c (count_events_callback, select_event_lwp_callback):
10905 Use the lwp's status_pending_p field, not the thread's.
10907 2015-03-19 Pedro Alves <palves@redhat.com>
10909 * linux-low.c (select_event_lwp_callback): Update comments to
10910 no longer mention SIGTRAP.
10912 2015-03-18 Gary Benson <gbenson@redhat.com>
10914 * server.c (handle_query): Do not report vFile:fstat as supported.
10916 2015-03-11 Gary Benson <gbenson@redhat.com>
10918 * hostio.c (sys/types.h): New include.
10919 (sys/stat.h): Likewise.
10920 (common-remote-fileio.h): Likewise.
10921 (handle_fstat): New function.
10922 (handle_vFile): Handle vFile:fstat packets.
10924 2015-03-11 Gary Benson <gbenson@redhat.com>
10926 * configure.ac (AC_CHECK_MEMBERS): Add checks for
10927 struct stat.st_blocks and struct stat.st_blksize.
10928 * configure: Regenerate.
10929 * config.in: Likewise.
10930 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
10931 (OBS): Add common-remote-fileio.o.
10932 (common-remote-fileio.o): New rule.
10934 2015-03-09 Pedro Alves <palves@redhat.com>
10936 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
10937 'struct sockaddr' pointer in 'accept' call.
10939 2015-03-09 Pedro Alves <palves@redhat.com>
10942 2015-03-07 Pedro Alves <palves@redhat.com>
10943 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
10944 or <winsock2.h> here. Instead include "gdb_socket.h".
10945 (remote_open): Use union gdb_sockaddr_u.
10946 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
10947 or <winsock2.h> here. Instead include "gdb_socket.h".
10948 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
10949 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
10951 (init_named_socket, gdb_agent_helper_thread): Use union
10954 2015-03-07 Pedro Alves <palves@redhat.com>
10956 * configure.ac (build_warnings): Move
10957 -Wdeclaration-after-statement to the C-specific set.
10958 * configure: Regenerate.
10960 2015-03-07 Pedro Alves <palves@redhat.com>
10962 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
10963 or <winsock2.h> here. Instead include "gdb_socket.h".
10964 (remote_open): Use union gdb_sockaddr_u.
10965 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
10966 or <winsock2.h> here. Instead include "gdb_socket.h".
10967 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
10968 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
10970 (init_named_socket, gdb_agent_helper_thread): Use union
10973 2015-03-07 Pedro Alves <palves@redhat.com>
10975 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
10978 2015-03-06 Yao Qi <yao.qi@linaro.org>
10980 * linux-aarch64-low.c (aarch64_insert_point): Use
10981 show_debug_regs as a boolean.
10982 (aarch64_remove_point): Likewise.
10984 2015-03-05 Pedro Alves <palves@redhat.com>
10986 * lynx-low.c (lynx_target_ops): Install NULL hooks for
10987 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
10988 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
10989 * nto-low.c (nto_target_ops): Likewise.
10990 * spu-low.c (spu_target_ops): Likewise.
10991 * win32-low.c (win32_target_ops): Likewise.
10993 2015-03-04 Pedro Alves <palves@redhat.com>
10995 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
10996 Decide whether a breakpoint triggered based on the SIGTRAP's
10998 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
10999 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
11000 (linux_low_filter_event): Check for breakpoints before checking
11002 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11004 (linux_stopped_by_sw_breakpoint)
11005 (linux_supports_stopped_by_sw_breakpoint)
11006 (linux_stopped_by_hw_breakpoint)
11007 (linux_supports_stopped_by_hw_breakpoint): New functions.
11008 (linux_target_ops): Install new target methods.
11010 2015-03-04 Pedro Alves <palves@redhat.com>
11012 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11013 * server.c (swbreak_feature, hwbreak_feature): New globals.
11014 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11015 (captured_main): Clear swbreak_feature and hwbreak_feature.
11016 * server.h (swbreak_feature, hwbreak_feature): Declare.
11017 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11018 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11019 supports_stopped_by_hw_breakpoint>: New fields.
11020 (target_supports_stopped_by_sw_breakpoint)
11021 (target_stopped_by_sw_breakpoint)
11022 (target_supports_stopped_by_hw_breakpoint)
11023 (target_stopped_by_hw_breakpoint): Declare.
11025 2015-03-04 Pedro Alves <palves@redhat.com>
11027 enum lwp_stop_reason -> enum target_stop_reason
11028 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11029 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11030 (linux_wait_1, stuck_in_jump_pad_callback)
11031 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11032 (linux_stopped_by_watchpoint):
11033 * linux-low.h (enum lwp_stop_reason): Delete.
11034 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11035 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11037 2015-03-04 Yao Qi <yao.qi@linaro.org>
11039 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11041 2015-03-03 Gary Benson <gbenson@redhat.com>
11043 * hostio.c (handle_vFile): Fix prefix lengths.
11045 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11047 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11050 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11052 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11053 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11054 (clean): Add "rm -f" for above C files.
11055 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11056 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11057 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11058 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11059 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11060 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11061 (init_registers_s390x_vx_linux64)
11062 (init_registers_s390x_tevx_linux64)
11063 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11064 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11066 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11067 (s390_store_vxrs_high): New functions.
11068 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11070 (s390_arch_setup): Add logic for selecting one of the new target
11071 descriptions. Activate the new vector regsets if applicable.
11072 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11073 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11074 and init_registers_s390x_tevx_linux64.
11076 2015-03-01 Pedro Alves <palves@redhat.com>
11078 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11081 2015-02-27 Pedro Alves <palves@redhat.com>
11083 * linux-x86-low.c (u_debugreg_offset): New function.
11084 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11086 2015-02-27 Pedro Alves <palves@redhat.com>
11088 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11089 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11090 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11091 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11092 (ps_lsetfpregs, ps_getpid)
11093 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11094 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11095 (ps_lsetxregs, ps_plog): Declare.
11097 2015-02-27 Pedro Alves <palves@redhat.com>
11099 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11100 IP_AGENT_EXPORT_FUNC.
11101 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11102 IP_AGENT_EXPORT_FUNC.
11103 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11104 (IP_AGENT_EXPORT): Delete.
11105 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11106 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11107 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11108 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11109 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11110 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11111 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11112 (traceframe_read_count, traceframe_write_count)
11113 (traceframes_created, trace_state_variables, get_raw_reg)
11114 (get_trace_state_variable_value, set_trace_state_variable_value)
11115 (ust_loaded, helper_thread_id, cmd_buf): Use
11116 IPA_SYM_EXPORTED_NAME.
11117 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11118 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11119 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11120 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11121 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11122 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11123 EXTERN_C_PUSH/EXTERN_C_POP.
11124 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11125 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11126 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11127 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11128 (traceframe_write_count, traceframe_read_count)
11129 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11130 (about_to_request_buffer_space, get_trace_state_variable_value)
11131 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11132 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11133 EXTERN_C_PUSH/EXTERN_C_POP.
11134 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11135 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11136 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11137 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11138 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11139 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11140 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11141 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11143 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11144 (IP_AGENT_EXPORT_VAR_DECL): Define.
11145 (tracing): Declare.
11146 (gdb_agent_get_raw_reg): Declare.
11148 2015-02-27 Tom Tromey <tromey@redhat.com>
11149 Pedro Alves <palves@redhat.com>
11151 Rename symbols whose names are reserved C++ keywords throughout.
11153 2015-02-27 Pedro Alves <palves@redhat.com>
11155 * Makefile.in (COMPILER): New, get it from autoconf.
11156 (CXX): Get from autoconf instead.
11157 (COMPILE.pre): Use COMPILER.
11158 (CC-LD): Rename to ...
11159 (CC_LD): ... this. Use COMPILER.
11160 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11161 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11162 * acinclude.m4: Include build-with-cxx.m4.
11163 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11164 Disable -Werror by default if building in C++ mode.
11165 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11166 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11167 the C++ compiler. Save/restore CXXFLAGS too.
11168 * configure: Regenerate.
11170 2015-02-27 Pedro Alves <palves@redhat.com>
11172 * acinclude.m4: Include libiberty.m4.
11173 * configure.ac: Call libiberty_INIT.
11174 * config.in, configure: Regenerate.
11176 2015-02-26 Pedro Alves <palves@redhat.com>
11178 * linux-low.c (linux_wait_1): When incrementing the PC past a
11179 program breakpoint always use the_low_target.breakpoint_len as
11180 increment, rather than the maximum between that and
11181 the_low_target.decr_pc_after_break.
11183 2015-02-23 Pedro Alves <palves@redhat.com>
11185 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11186 thread was doing a step-over; always adjust the PC if
11187 we stepped over a permanent breakpoint.
11188 (linux_wait_1): If we stepped over breakpoint that was on top of a
11189 permanent breakpoint, manually advance the PC past it.
11191 2015-02-23 Pedro Alves <palves@redhat.com>
11193 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11195 (x86_fill_gregset, x86_store_gregset): Use it when handling
11198 2015-02-20 Pedro Alves <palves@redhat.com>
11200 * thread-db.c: Include "nat/linux-procfs.h".
11201 (thread_db_init): Skip listing new threads if the kernel supports
11202 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11204 2015-02-20 Pedro Alves <palves@redhat.com>
11206 * linux-low.c (status_pending_p_callback): Use ptid_match.
11208 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11210 PR breakpoints/16812
11211 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11212 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11213 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11215 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11217 PR breakpoints/15956
11218 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11220 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11222 * linux-low.c (linux_low_btrace_conf): Print size.
11223 * server.c (handle_btrace_conf_general_set): New.
11224 (hanle_general_set): Call handle_btrace_conf_general_set.
11225 (handle_query): Report Qbtrace-conf:bts:size as supported.
11227 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11229 * linux-low.c (linux_low_enable_btrace): Update parameters.
11230 (linux_low_btrace_conf): New.
11231 (linux_target_ops)<to_btrace_conf>: Initialize.
11232 * server.c (current_btrace_conf): New.
11233 (handle_btrace_enable): Rename to ...
11234 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
11235 to target_enable_btrace. Update comment. Update users.
11236 (handle_qxfer_btrace_conf): New.
11237 (qxfer_packets): Add btrace-conf entry.
11238 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11239 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11240 (target_ops)<read_btrace_conf>: New.
11241 (target_enable_btrace): Update parameters.
11242 (target_read_btrace_conf): New.
11244 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11246 * server.c (handle_btrace_general_set): Remove call to
11247 target_supports_btrace.
11248 (supported_btrace_packets): New.
11249 (handle_query): Call supported_btrace_packets.
11250 * target.h: include btrace-common.h.
11251 (btrace_target_info): Removed.
11252 (supports_btrace, target_supports_btrace): Update parameters.
11254 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11256 * Makefile.in (SFILES): Add common/btrace-common.c.
11257 (OBS): Add common/btrace-common.o.
11258 (btrace-common.o): Add build rules.
11259 * linux-low: Include btrace-common.h.
11260 (linux_low_read_btrace): Use struct btrace_data. Call
11261 btrace_data_init and btrace_data_fini.
11263 2015-02-06 Pedro Alves <palves@redhat.com>
11265 * thread-db.c (find_new_threads_callback): Add debug output.
11267 2015-02-04 Pedro Alves <palves@redhat.com>
11269 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11270 (resume_stopped_resumed_lwps): New function.
11271 (linux_wait_for_event_filtered): Use it.
11273 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11275 * Makefile.in (SFILES): Add linux-personality.c.
11276 (linux-personality.o): New rule.
11277 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11278 list of objects to be built.
11279 * linux-low.c: Include nat/linux-personality.h.
11280 (linux_create_inferior): Remove code to disable address space
11281 randomization (moved to ../nat/linux-personality.c). Create
11282 cleanup to disable address space randomization.
11284 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11286 * Makefile.in (posix-strerror.o): New rule.
11287 (mingw-strerror.o): Likewise.
11288 * configure: Regenerated.
11289 * configure.ac: Source file ../common/common.host. Initialize new
11290 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11292 2015-01-14 Yao Qi <yao@codesourcery.com>
11294 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11295 (ppc-linux.o): New rule.
11296 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11297 * configure.ac: AC_CHECK_FUNCS(getauxval).
11298 * config.in: Re-generated.
11299 * configure: Re-generated.
11300 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11301 ppc64_64bit_inferior_p
11303 2015-01-14 Yao Qi <yao@codesourcery.com>
11305 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11306 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11307 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11308 (PT_ORIG_R3, PT_TRAP): Likewise.
11309 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11310 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11311 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11313 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11315 * i387-fp.c (i387_cache_to_xsave): In look over
11316 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11317 zmmh_low_space field by use of zmmh_high_space.
11319 2015-01-09 Pedro Alves <palves@redhat.com>
11321 * linux-low.c (step_over_bkpt): Move higher up in the file.
11322 (handle_extended_wait): Don't store the stop_pc here.
11323 (get_stop_pc): Adjust comments and rename to ...
11324 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11325 stopped for a software breakpoint or hardware breakpoint.
11326 (thread_still_has_status_pending_p): New function.
11327 (status_pending_p_callback): Use
11328 thread_still_has_status_pending_p. If the event is no longer
11329 interesting, resume the LWP.
11330 (handle_tracepoints): Add assert.
11331 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11332 (wstatus_maybe_breakpoint): New function.
11333 (cancel_breakpoint): Delete function.
11334 (check_stopped_by_watchpoint): New function, factored out from
11335 linux_low_filter_event.
11336 (lp_status_maybe_breakpoint): Delete function.
11337 (linux_low_filter_event): Remove filter_ptid argument.
11338 Leave thread group exits pending here. Store the LWP's stop PC.
11339 Always leave events pending.
11340 (linux_wait_for_event_filtered): Pull all events out of the
11341 kernel, and leave them all pending.
11342 (count_events_callback, select_event_lwp_callback): Consider all
11344 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11345 (select_event_lwp): Only give preference to the stepping LWP in
11346 all-stop mode. Adjust comments.
11347 (ignore_event): New function.
11348 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11349 references to cancel_breakpoints. Adjust to renames. Also give
11350 equal priority to all LWPs that have had events in non-stop mode.
11351 If reporting a software breakpoint event, unadjust the LWP's PC.
11352 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11353 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11355 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11356 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11357 (linux_stopped_by_watchpoint): Adjust.
11358 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11359 * linux-low.h (enum lwp_stop_reason): New.
11360 (struct lwp_info) <stop_pc>: Adjust comment.
11361 <stopped_by_watchpoint>: Delete field.
11362 <stop_reason>: New field.
11363 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11364 * mem-break.c (software_breakpoint_inserted_here)
11365 (hardware_breakpoint_inserted_here): New function.
11366 * mem-break.h (software_breakpoint_inserted_here)
11367 (hardware_breakpoint_inserted_here): Declare.
11368 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11369 (cancel_breakpoints): Delete.
11370 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11371 (upload_fast_traceframes): Remove references to
11372 cancel_breakpoints.
11374 2015-01-09 Pedro Alves <palves@redhat.com>
11376 * thread-db.c (find_new_threads_callback): Ignore thread if the
11377 kernel thread ID is -1.
11379 2015-01-09 Pedro Alves <palves@redhat.com>
11381 * linux-low.c (linux_attach_fail_reason_string): Move to
11382 nat/linux-ptrace.c, and rename.
11383 (linux_attach_lwp): Update comment.
11384 (attach_proc_task_lwp_callback): New function.
11385 (linux_attach): Adjust to rename and use
11386 linux_proc_attach_tgid_threads.
11387 (linux_attach_fail_reason_string): Delete declaration.
11389 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11391 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11392 * server.c (gdbserver_version): Likewise.
11394 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11396 * remote-utils.c: Include ctype.h.
11397 (input_interrupt): Explicitly handle the case when the char
11398 received is the NUL byte. Improve the printing of non-ASCII
11401 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11403 * linux-low.c (linux_low_filter_event): Update call to
11404 linux_enable_event_reporting following the addition of
11405 a new parameter to that function.
11407 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11410 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11411 (AARCH64_FPCR_REGNO): Likewise.
11412 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11413 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11414 (aarch64_store_fpregset): Likewise.
11416 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11418 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11419 Remove FIXME comment about assumption about N.
11421 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11423 * configure.ac: If large-file support is disabled in GDBserver,
11424 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11425 * configure: Regenerate.
11427 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11429 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11430 warning upon ENODATA from ptrace.
11431 * linux-s390-low.c (s390_store_tdb): New.
11432 (s390_regsets): Add regset for NT_S390_TDB.
11434 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11436 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11437 without a fill_function.
11438 * linux-s390-low.c (s390_fill_last_break): Remove.
11439 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11440 (s390_arch_setup): Use regset's size instead of fill_function for
11441 loop end condition.
11443 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11445 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11446 the regset's store function when ptrace returned an error.
11447 * regcache.c (get_thread_regcache): Invalidate register cache
11448 before fetching inferior's registers.
11450 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11452 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11453 while-loop as for-loop.
11454 (regsets_store_inferior_registers): Likewise.
11456 2014-11-28 Yao Qi <yao@codesourcery.com>
11458 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11459 * config.in, configure: Re-generate.
11460 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11463 2014-11-21 Yao Qi <yao@codesourcery.com>
11465 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11466 (AC_CHECK_HEADERS): Remove malloc.h.
11467 * configure: Re-generated.
11468 * config.in: Re-generated.
11469 * server.h: Don't include alloca.h and malloc.h.
11470 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11471 Don't include malloc.h.
11473 2014-11-17 Joel Brobecker <brobecker@adacore.com>
11475 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11476 corresponding ERRNO check in same block.
11478 2014-11-12 Pedro Alves <palves@redhat.com>
11480 * server.c (cont_thread): Update comment.
11481 (start_inferior, attach_inferior): No longer clear cont_thread.
11482 (handle_v_cont): No longer set cont_thread.
11483 (captured_main): Clear cont_thread each time a GDB connects.
11485 2014-11-12 Pedro Alves <palves@redhat.com>
11487 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11488 thread, and don't resume all threads if the Hc thread has exited.
11490 2014-11-12 Pedro Alves <palves@redhat.com>
11492 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11493 the process group instead of to a specific LWP.
11495 2014-10-15 Pedro Alves <palves@redhat.com>
11498 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11500 (arm_set_thread_context): Delete.
11501 (the_low_target): Adjust.
11502 * win32-i386-low.c (debug_registers_changed)
11503 (debug_registers_used): Delete.
11504 (update_debug_registers_callback): New function.
11505 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11506 needing to update their debug registers.
11507 (win32_get_current_dr): New function.
11508 (x86_dr_low_get_addr, x86_dr_low_get_control)
11509 (x86_dr_low_get_status): Fetch the debug register from the thread
11511 (i386_initial_stuff): Adjust.
11512 (i386_get_thread_context): Remove current_event parameter. Don't
11513 clear debug_registers_changed nor copy DR values to
11515 (i386_set_thread_context): Delete.
11516 (i386_prepare_to_resume): New function.
11517 (i386_thread_added): Mark the thread as needing to update irs
11519 (the_low_target): Remove i386_set_thread_context and install
11520 i386_prepare_to_resume.
11521 * win32-low.c (win32_get_thread_context): Adjust.
11522 (win32_set_thread_context): Use SetThreadContext
11524 (win32_prepare_to_resume): New function.
11525 (win32_require_context): New function, factored out from ...
11526 (thread_rec): ... this.
11527 (continue_one_thread): Call win32_prepare_to_resume on each thread
11528 we're about to continue.
11529 (win32_resume): Call win32_prepare_to_resume on the event thread.
11530 * win32-low.h (struct win32_thread_info)
11531 <debug_registers_changed>: New field.
11532 (struct win32_target_ops): Change prototype of set_thread_context,
11533 delete set_thread_context and add prepare_to_resume.
11534 (win32_require_context): New declaration.
11536 2014-10-08 Gary Benson <gbenson@redhat.com>
11538 * server.h: Do not include common-exceptions.h.
11540 2014-10-08 Gary Benson <gbenson@redhat.com>
11542 * server.h: Do not include cleanups.h.
11544 2014-09-30 James Hogan <james.hogan@imgtec.com>
11546 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11547 mips64-dsp-linux.c.
11549 2014-09-23 Yao Qi <yao@codesourcery.com>
11551 * linux-low.c (lp_status_maybe_breakpoint): New function.
11552 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11553 (count_events_callback): Likewise.
11554 (select_event_lwp_callback): Likewise.
11555 (cancel_breakpoints_callback): Likewise.
11557 2014-09-19 Don Breazeal <donb@codesourcery.com>
11559 * linux-low.c (handle_extended_wait): Call
11560 linux_ptrace_get_extended_event.
11561 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11562 linux_is_extended_waitstatus.
11564 2014-09-16 Joel Brobecker <brobecker@adacore.com>
11566 * Makefile.in (CPPFLAGS): Define.
11567 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11568 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11570 2014-09-16 Gary Benson <gbenson@redhat.com>
11572 * inferiors.h (current_inferior): Renamed as...
11573 (current_thread): New variable. All uses updated.
11574 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11575 (maybe_move_out_of_jump_pad): Likewise.
11576 (cancel_breakpoint): Likewise.
11577 (linux_low_filter_event): Likewise.
11578 (wait_for_sigstop): Likewise.
11579 (linux_resume_one_lwp): Likewise.
11580 (need_step_over_p): Likewise.
11581 (start_step_over): Likewise.
11582 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11583 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11584 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11585 and save_inferior as saved_thread.
11586 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11588 (regcache_invalidate_thread): Likewise.
11589 * remote-utils.c (prepare_resume_reply): Likewise.
11590 * thread-db.c (thread_db_get_tls_address): Likewise.
11591 (disable_thread_event_reporting): Likewise.
11592 (remove_thread_event_breakpoints): Likewise.
11593 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11595 * target.h (set_desired_inferior): Renamed as...
11596 (set_desired_thread): New declaration. All uses updated.
11597 * server.c (myresume): Updated comment to reference thread instead
11599 (handle_serial_event): Likewise.
11600 (handle_target_event): Likewise.
11602 2014-09-12 Tom Tromey <tromey@redhat.com>
11603 Gary Benson <gbenson@redhat.com>
11605 * regcache.h: Include common-regcache.h.
11606 (regcache_read_pc): Don't declare.
11607 * regcache.c (get_thread_regcache_for_ptid): New function.
11609 2014-09-11 Tom Tromey <tromey@redhat.com>
11610 Gary Benson <gbenson@redhat.com>
11612 * symbol.c: New file.
11613 * Makefile.in (SFILES): Add symbol.c.
11614 (OBS): Add symbol.o.
11616 2014-09-11 Gary Benson <gbenson@redhat.com>
11618 * target.c (target_stop_ptid, target_continue_ptid): New
11621 2014-09-11 Tom Tromey <tromey@redhat.com>
11622 Gary Benson <gbenson@redhat.com>
11624 * target.h: Include target/target.h.
11625 * target.c (target_read_memory, target_read_uint32)
11626 (target_write_memory): New functions.
11628 2014-09-11 Gary Benson <gbenson@redhat.com>
11630 * server.h (debug_hw_points): Don't declare.
11631 * server.c (debug_hw_points): Don't define. Replace all uses
11632 with show_debug_regs.
11633 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11634 all uses with show_debug_regs.
11636 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11638 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11639 endianness into account.
11640 (ppc_supply_ptrace_register): Likewise.
11642 2014-09-03 James Hogan <james.hogan@imgtec.com>
11644 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11645 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11647 2014-09-03 Gary Benson <gbenson@redhat.com>
11649 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11650 ALL_DEBUG_ADDRESS_REGISTERS.
11652 2014-09-02 Gary Benson <gbenson@redhat.com>
11654 * i386-low.h: Renamed as...
11655 * x86-low.h: New file. All type, function and variable name
11656 prefixes changed from "i386_" to "x86_". All references updated.
11657 * i386-low.c: Renamed as...
11658 * x86-low.c: New file. All type, function and variable name
11659 prefixes changed from "i386_" to "x86_". All references updated.
11661 2014-09-02 Gary Benson <gbenson@redhat.com>
11663 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11664 (x86_linux_new_thread): Likewise.
11666 2014-08-29 Gary Benson <gbenson@redhat.com>
11668 * server.h (setjmp.h): Do not include.
11669 (toplevel): Do not declare.
11670 (common-exceptions.h): Include.
11671 (cleanups.h): Likewise.
11672 * server.c (toplevel): Do not define.
11673 (exit_code): New static global.
11674 (detach_or_kill_for_exit_cleanup): New function.
11675 (main): New function. Original main renamed to...
11676 (captured_main): New function.
11677 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11679 2014-08-29 Gary Benson <gbenson@redhat.com>
11681 * Makefile.in (SFILES): Add common/common-exceptions.c.
11682 (OBS): Add common-exceptions.o.
11683 (common-exceptions.o): New rule.
11684 * utils.c (prepare_to_throw_exception): New function.
11686 2014-08-29 Gary Benson <gbenson@redhat.com>
11688 * config.in: Regenerate.
11689 * configure: Likewise.
11691 2014-08-29 Gary Benson <gbenson@redhat.com>
11693 * Makefile.in (SFILES): Add common/cleanups.c.
11695 (cleanups.o): New rule.
11697 2014-08-29 Gary Benson <gbenson@redhat.com>
11699 * utils.c (internal_vwarning): New function.
11701 2014-08-28 Gary Benson <gbenson@redhat.com>
11703 * utils.h (fatal): Remove declaration.
11704 * utils.c (fatal): Remove function.
11706 2014-08-28 Gary Benson <gbenson@redhat.com>
11708 * tracepoint.c (gdb_agent_init): Replace fatal with
11710 (initialize_tracepoint): Likewise.
11712 2014-08-28 Gary Benson <gbenson@redhat.com>
11714 * remote-utils.c (remote_prepare): Replace fatal with error.
11716 2014-08-28 Gary Benson <gbenson@redhat.com>
11718 * linux-low.c (linux_async): Replace fatal with warning.
11719 Tidy up and return.
11720 (linux_start_non_stop): Return -1 if linux_async failed.
11722 2014-08-28 Gary Benson <gbenson@redhat.com>
11724 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11726 (i386_dr_low_get_addr): Remove vague comment.
11727 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11730 2014-08-28 Gary Benson <gbenson@redhat.com>
11732 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11733 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11735 (linux_resume_one_lwp): Likewise.
11736 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11738 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11739 with internal_error.
11740 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11741 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11742 (find_register_by_name): Replace fatal with internal_error.
11743 (find_regno): Likewise.
11744 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11745 * thread-db.c (thread_db_create_event): Likewise.
11746 (thread_db_load_search): Likewise.
11747 (try_thread_db_load_1): Likewise.
11748 * tracepoint.c (get_jump_space_head): Replace fatal with
11750 (claim_trampoline_space): Likewise.
11751 (have_fast_tracepoint_trampoline_buffer): Likewise.
11752 (cmd_qtstart): Likewise.
11753 (stop_tracing): Likewise.
11754 (fast_tracepoint_collecting): Likewise.
11755 (target_malloc): Likewise.
11756 (download_tracepoint): Likewise.
11757 (download_trace_state_variables): Replace check with gdb_assert.
11758 (upload_fast_traceframes): Replace fatal with internal_error.
11760 2014-08-19 Tom Tromey <tromey@redhat.com>
11761 Gary Benson <gbenson@redhat.com>
11763 * Makefile.in (SFILES): Add common/common-debug.c.
11764 (OBS): Add common-debug.o.
11765 (common-debug.o): New rule.
11766 * debug.h (debug_printf): Don't declare.
11767 * debug.c (debug_printf): Renamed and rewritten as...
11768 (debug_vprintf): New function.
11770 2014-08-19 Gary Benson <gbenson@redhat.com>
11772 * utils.h: Do not include print-utils.h.
11774 2014-08-19 Tom Tromey <tromey@redhat.com>
11775 Gary Benson <gbenson@redhat.com>
11777 * server.h: Add static assertion.
11778 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11780 2014-08-19 Tom Tromey <tromey@redhat.com>
11781 Gary Benson <gbenson@redhat.com>
11783 * Makefile.in (SFILES): Add common/errors.c.
11784 (OBS): Add errors.o.
11785 (IPA_OBS): Add errors-ipa.o.
11786 (errors.o): New rule.
11787 (errors-ipa.o): Likewise.
11788 * utils.h (perror_with_name, error, warning): Don't declare.
11789 * utils.c (warning): Renamed and rewritten as...
11790 (vwarning): New function.
11791 (error): Renamed and rewritten as...
11792 (verror): New function.
11793 (internal_error): Renamed and rewritten as...
11794 (internal_verror): New function.
11796 2014-08-07 Gary Benson <gbenson@redhat.com>
11798 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11799 * configure: Regenerate.
11800 * config.in: Likewise.
11801 * server.h: Do not include errno.h.
11802 * event-loop.c: Likewise.
11803 * hostio-errno.c: Likewise.
11804 * linux-low.c: Likewise.
11805 * remote-utils.c: Likewise.
11806 * spu-low.c: Likewise.
11807 * utils.c: Likewise.
11808 * gdbreplay.c: Unconditionally include errno.h.
11810 2014-08-07 Gary Benson <gbenson@redhat.com>
11812 * server.h: Do not include string.h.
11813 * event-loop.c: Likewise.
11814 * linux-low.c: Likewise.
11815 * regcache.c: Likewise.
11816 * remote-utils.c: Likewise.
11817 * spu-low.c: Likewise.
11818 * utils.c: Likewise.
11820 2014-08-07 Gary Benson <gbenson@redhat.com>
11822 * server.h: Do not include gdb_assert.h.
11824 2014-08-07 Gary Benson <gbenson@redhat.com>
11826 * server.h: Do not include common-utils.h.
11828 2014-08-07 Gary Benson <gbenson@redhat.com>
11830 * server.h: Do not include ptid.h.
11831 * notif.h: Likewise.
11833 2014-08-07 Gary Benson <gbenson@redhat.com>
11835 * server.h: Do not include gdb_locale.h.
11837 2014-08-07 Gary Benson <gbenson@redhat.com>
11839 * server.h: Do not include gdb/signals.h.
11840 * win32-low.c: Likewise.
11842 2014-08-07 Gary Benson <gbenson@redhat.com>
11844 * server.h: Do not include pathmax.h.
11846 2014-08-07 Gary Benson <gbenson@redhat.com>
11848 * server.h: Do not include libiberty.h.
11849 * linux-bfin-low.c: Likewise.
11851 2014-08-07 Gary Benson <gbenson@redhat.com>
11853 * server.h: Do not include ansidecl.h.
11855 2014-08-07 Gary Benson <gbenson@redhat.com>
11857 * linux-x86-low.c: Do not include stddef.h.
11858 * lynx-ppc-low.c: Likewise.
11859 * tracepoint.c: Likewise.
11861 2014-08-07 Gary Benson <gbenson@redhat.com>
11863 * server.h: Do not include stdarg.h.
11864 * nto-low.c: Likewise.
11866 2014-08-07 Gary Benson <gbenson@redhat.com>
11868 * server.h: Do not include stdlib.h.
11869 * inferiors.c: Likewise.
11870 * linux-low.c: Likewise.
11871 * regcache.c: Likewise.
11872 * spu-low.c: Likewise.
11873 * tracepoint.c: Likewise.
11874 * utils.c: Likewise.
11876 2014-08-07 Gary Benson <gbenson@redhat.com>
11878 * server.h: Do not include stdio.h.
11879 * linux-low.c: Likewise.
11880 * remote-utils.c: Likewise.
11881 * spu-low.c: Likewise.
11882 * utils.c: Likewise.
11883 * wincecompat.c: Likewise.
11885 2014-08-06 Gary Benson <gbenson@redhat.com>
11887 * regcache.c (init_register_cache): Move conditionals inside if.
11889 2014-08-06 Gary Benson <gbenson@redhat.com>
11891 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
11893 2014-07-31 Gary Benson <gbenson@redhat.com>
11895 * ax.h: Do not include server.h.
11896 * gdbthread.h: Likewise.
11897 * lynx-low.h: Likewise.
11898 * notif.h: Likewise.
11900 2014-07-30 Gary Benson <gbenson@redhat.com>
11902 * server.h: Include common-defs.h.
11903 Do not include config.h or build-gnulib-gdbserver/config.h.
11905 2014-07-30 Gary Benson <gbenson@redhat.com>
11907 * hostio-errno.c: Move server.h to top of includes list.
11908 * inferiors.c: Likewise.
11909 * linux-x86-low.c: Likewise.
11910 * notif.c: Include server.h.
11912 2014-07-24 Tom Tromey <tromey@redhat.com>
11913 Gary Benson <gbenson@redhat.com>
11915 * server.h (CORE_ADDR): Now unsigned.
11917 2014-07-16 Pedro Alves <palves@redhat.com>
11919 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
11921 2014-07-15 Pedro Alves <palves@redhat.com>
11923 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
11926 2014-07-11 Pedro Alves <palves@redhat.com>
11928 * linux-low.c (kill_wait_lwp): New function, based on
11929 kill_one_lwp_callback, but use my_waitpid directly.
11930 (kill_one_lwp_callback, linux_kill): Use it.
11932 2014-06-23 Pedro Alves <palves@redhat.com>
11934 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
11935 before setting DR0..DR3.
11937 2014-06-20 Gary Benson <gbenson@redhat.com>
11939 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
11940 * configure: Regenerated.
11941 * config.in: Likewise.
11943 2014-06-20 Gary Benson <gbenson@redhat.com>
11945 * Makefile.in (SFILES): Update locations for files moved
11946 from common to nat.
11947 (object file files): Reordered.
11949 2014-06-20 Gary Benson <gbenson@redhat.com>
11951 * i386-low.h (i386_dr_low_can_set_addr): Removed.
11952 (i386_dr_low_set_addr): Likewise.
11953 (i386_dr_low_get_addr): Likewise.
11954 (i386_dr_low_can_set_control): Likewise.
11955 (i386_dr_low_set_control): Likewise.
11956 (i386_dr_low_get_control): Likewise.
11957 (i386_dr_low_get_status): Likewise.
11958 (i386_get_debug_register_length): Likewise.
11959 * linux-x86-low.c (i386_dr_low_set_addr):
11960 Changed signature. Made static.
11961 (i386_dr_low_get_addr): Likewise.
11962 (i386_dr_low_set_control): Likewise.
11963 (i386_dr_low_get_control): Likewise.
11964 (i386_dr_low_get_status): Likewise.
11965 (i386_dr_low): New global variable.
11966 * win32-i386-low.c (i386_dr_low_set_addr):
11967 Changed signature. Made static.
11968 (i386_dr_low_get_addr): Likewise.
11969 (i386_dr_low_set_control): Likewise.
11970 (i386_dr_low_get_control): Likewise.
11971 (i386_dr_low_get_status): Likewise.
11972 (i386_dr_low): New global variable.
11974 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
11976 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
11977 * Makefile.in (AR, AR_FLAGS): Define.
11978 * configure: Regenerate.
11980 2014-06-19 Gary Benson <gbenson@redhat.com>
11982 * Makefile.in (i386-dregs.o): New rule.
11983 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
11984 * i386-low.c (target.h): Remove include.
11985 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
11986 (DR_CONTROL_SHIFT): Likewise.
11987 (DR_CONTROL_SIZE): Likewise.
11988 (DR_RW_EXECUTE): Likewise.
11989 (DR_RW_WRITE): Likewise.
11990 (DR_RW_READ): Likewise.
11991 (DR_RW_IORW): Likewise.
11992 (DR_LEN_1): Likewise.
11993 (DR_LEN_2): Likewise.
11994 (DR_LEN_4): Likewise.
11995 (DR_LEN_8): Likewise.
11996 (DR_LOCAL_ENABLE_SHIFT): Likewise.
11997 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
11998 (DR_ENABLE_SIZE): Likewise.
11999 (DR_LOCAL_SLOWDOWN): Likewise.
12000 (DR_GLOBAL_SLOWDOWN): Likewise.
12001 (DR_CONTROL_RESERVED): Likewise.
12002 (I386_DR_CONTROL_MASK): Likewise.
12003 (I386_DR_VACANT): Likewise.
12004 (I386_DR_LOCAL_ENABLE): Likewise.
12005 (I386_DR_GLOBAL_ENABLE): Likewise.
12006 (I386_DR_DISABLE): Likewise.
12007 (I386_DR_SET_RW_LEN): Likewise.
12008 (I386_DR_GET_RW_LEN): Likewise.
12009 (I386_DR_WATCH_HIT): Likewise.
12010 (i386_wp_op_t): Likewise.
12011 (i386_show_dr): Likewise.
12012 (i386_length_and_rw_bits): Likewise.
12013 (i386_insert_aligned_watchpoint): Likewise.
12014 (i386_remove_aligned_watchpoint): Likewise.
12015 (i386_handle_nonaligned_watchpoint): Likewise.
12016 i386_update_inferior_debug_regs(): Likewise.
12017 (i386_dr_insert_watchpoint): Likewise.
12018 (i386_dr_remove_watchpoint): Likewise.
12019 (i386_dr_region_ok_for_watchpoint): Likewise.
12020 (i386_dr_stopped_data_address): Likewise.
12021 (i386_dr_stopped_by_watchpoint): Likewise.
12023 2014-06-19 Gary Benson <gbenson@redhat.com>
12025 * i386-low.c (i386_dr_show): Renamed to
12026 i386_show_dr and made static. All uses updated.
12027 (i386_dr_length_and_rw_bits): Renamed to
12028 i386_length_and_rw_bits and made static.
12030 (i386_dr_insert_aligned_watchpoint): Renamed to
12031 i386_insert_aligned_watchpoint and made static.
12033 (i386_dr_remove_aligned_watchpoint): Renamed to
12034 i386_remove_aligned_watchpoint and made static.
12036 (i386_dr_update_inferior_debug_regs): Renamed to
12037 i386_update_inferior_debug_regs and made static.
12040 2014-06-18 Gary Benson <gbenson@redhat.com>
12042 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12043 (i386_dr_low_can_set_control): Likewise.
12044 (i386_get_debug_register_length): Likewise.
12045 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12046 (i386_dr_low_can_set_control): Likewise.
12047 (i386_get_debug_register_length): Likewise.
12049 2014-06-17 Gary Benson <gbenson@redhat.com>
12051 * i386-low.h (i386-dregs.h): New include.
12052 (DR_FIRSTADDR): Now in i386-dregs.h.
12053 (DR_LASTADDR): Likewise.
12054 (DR_NADDR): Likewise.
12055 (DR_STATUS): Likewise.
12056 (DR_CONTROL): Likewise.
12057 (i386_debug_reg_state): Likewise.
12058 (i386_dr_insert_watchpoint): Likewise.
12059 (i386_dr_remove_watchpoint): Likewise.
12060 (i386_dr_region_ok_for_watchpoint): Likewise.
12061 (i386_dr_stopped_data_address): Likewise.
12062 (i386_dr_stopped_by_watchpoint): Likewise.
12063 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12065 2014-06-18 Gary Benson <gbenson@redhat.com>
12067 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12068 i386_dr_insert_watchpoint.
12069 (i386_low_remove_watchpoint): Renamed to
12070 i386_dr_remove_watchpoint.
12071 (i386_low_region_ok_for_watchpoint): Renamed to
12072 i386_dr_region_ok_for_watchpoint.
12073 (i386_low_stopped_data_address): Renamed to
12074 i386_dr_stopped_data_address.
12075 (i386_low_stopped_by_watchpoint): Renamed to
12076 i386_dr_stopped_by_watchpoint.
12077 * i386-low.c (i386_show_dr): Renamed to
12078 i386_dr_show and made nonstatic. All uses updated.
12079 (i386_length_and_rw_bits): Renamed to
12080 i386_dr_length_and_rw_bits and made nonstatic.
12082 (i386_insert_aligned_watchpoint): Renamed to
12083 i386_dr_insert_aligned_watchpoint and made nonstatic.
12085 (i386_remove_aligned_watchpoint): Renamed to
12086 i386_dr_remove_aligned_watchpoint and made nonstatic.
12088 (i386_update_inferior_debug_regs): Renamed to
12089 i386_dr_update_inferior_debug_regs and made nonstatic.
12091 (i386_low_insert_watchpoint): Renamed to
12092 i386_dr_insert_watchpoint. All uses updated.
12093 (i386_low_remove_watchpoint): Renamed to
12094 i386_dr_remove_watchpoint. All uses updated.
12095 (i386_low_region_ok_for_watchpoint): Renamed to
12096 i386_dr_region_ok_for_watchpoint. All uses updated.
12097 (i386_low_stopped_data_address): Renamed to
12098 i386_dr_stopped_data_address. All uses updated.
12099 (i386_low_stopped_by_watchpoint): Renamed to
12100 i386_dr_stopped_by_watchpoint. All uses updated.
12102 2014-06-18 Gary Benson <gbenson@redhat.com>
12104 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12105 (i386_dr_low_can_set_control): Likewise.
12106 (i386_insert_aligned_watchpoint): New check.
12108 2014-06-18 Gary Benson <gbenson@redhat.com>
12110 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12113 2014-06-18 Gary Benson <gbenson@redhat.com>
12115 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12116 instead of fatal and error.
12117 (i386_handle_nonaligned_watchpoint): Likewise.
12119 2014-06-18 Gary Benson <gbenson@redhat.com>
12121 * i386-low.c (i386_get_debug_register_length): New macro.
12122 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12123 (i386_show_dr): Use debug_printf instead of fprintf. Use
12124 phex to format values.
12126 2014-06-18 Gary Benson <gbenson@redhat.com>
12128 * i386-low.h: Comment changes.
12129 * i386-low.c: Likewise.
12131 2014-06-18 Gary Benson <gbenson@redhat.com>
12133 * i386-low.c: Whitespace changes.
12135 2014-06-12 Tom Tromey <tromey@redhat.com>
12137 * utils.c (freeargv): Remove.
12139 2014-06-12 Tom Tromey <tromey@redhat.com>
12141 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12142 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12143 (parse_debug_format_options): Likewise.
12144 (gdbserver_usage): Likewise.
12145 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12146 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12147 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12149 ($(LIBGNU)): Depend on libiberty.
12150 (all-lib): Recurse into all subdirs.
12151 (install-only): Invoke "install" target in subdirs.
12152 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12154 * configure: Rebuild.
12155 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12156 for vasprintf, vsnprintf, or gettimeofday.
12157 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12160 2014-06-05 Joel Brobecker <brobecker@adacore.com>
12162 * development.sh: Delete.
12163 * Makefile.in (config.status): Adjust dependency on development.sh.
12164 * configure.ac: Adjust development.sh source call.
12165 * configure: Regenerate.
12167 2014-06-02 Pedro Alves <palves@redhat.com>
12169 * ax.c (gdb_free_agent_expr): New function.
12170 * ax.h (gdb_free_agent_expr): New declaration.
12171 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12173 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12175 (clear_breakpoint_conditions_and_commands): New function.
12176 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12177 (clear_breakpoint_conditions_and_commands): New declaration.
12179 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12181 * linux-aarch64-low.c (asm/ptrace.h): Include.
12183 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12185 Fix TLS access for -static -pthread.
12186 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12187 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12188 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12190 2014-05-20 Pedro Alves <palves@redhat.com>
12192 * linux-aarch64-low.c (aarch64_insert_point)
12193 (aarch64_remove_point): No longer check whether the type is
12194 supported here. Adjust to new interface.
12195 (the_low_target): Install aarch64_supports_z_point_type as
12196 supports_z_point_type method.
12197 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12198 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12199 instead of a Z packet char. Adjust.
12200 (arm_supports_z_point_type): New function.
12201 (arm_insert_point, arm_remove_point): Adjust to new interface.
12202 (the_low_target): Install arm_supports_z_point_type.
12203 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12204 (cris_insert_point, cris_remove_point): Adjust to new interface.
12205 Don't check whether the type is supported here.
12206 (the_low_target): Install cris_supports_z_point_type.
12207 * linux-low.c (linux_supports_z_point_type): New function.
12208 (linux_insert_point, linux_remove_point): Adjust to new interface.
12209 * linux-low.h (struct linux_target_ops) <insert_point,
12210 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12211 raw_breakpoint pointer parameter.
12212 <supports_z_point_type>: New method.
12213 * linux-mips-low.c (mips_supports_z_point_type): New function.
12214 (mips_insert_point, mips_remove_point): Adjust to new interface.
12215 Use mips_supports_z_point_type.
12216 (the_low_target): Install mips_supports_z_point_type.
12217 * linux-ppc-low.c (the_low_target): Install NULL as
12218 supports_z_point_type method.
12219 * linux-s390-low.c (the_low_target): Install NULL as
12220 supports_z_point_type method.
12221 * linux-sparc-low.c (the_low_target): Install NULL as
12222 supports_z_point_type method.
12223 * linux-x86-low.c (x86_supports_z_point_type): New function.
12224 (x86_insert_point): Adjust to new insert_point interface. Use
12225 insert_memory_breakpoint. Adjust to new
12226 i386_low_insert_watchpoint interface.
12227 (x86_remove_point): Adjust to remove_point interface. Use
12228 remove_memory_breakpoint. Adjust to new
12229 i386_low_remove_watchpoint interface.
12230 (the_low_target): Install x86_supports_z_point_type.
12231 * lynx-low.c (lynx_target_ops): Install NULL as
12232 supports_z_point_type callback.
12233 * nto-low.c (nto_supports_z_point_type): New.
12234 (nto_insert_point, nto_remove_point): Adjust to new interface.
12235 (nto_target_ops): Install nto_supports_z_point_type.
12236 * mem-break.c: Adjust intro comment.
12237 (struct raw_breakpoint) <raw_type, size>: New fields.
12238 <inserted>: Update comment.
12239 <shlib_disabled>: Delete field.
12240 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12241 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12242 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12243 (raw_bkpt_type_to_target_hw_bp_type): New function.
12244 (find_enabled_raw_code_breakpoint_at): New function.
12245 (find_raw_breakpoint_at): New type and size parameters. Use them.
12246 (insert_memory_breakpoint): New function, based off
12247 set_raw_breakpoint_at.
12248 (remove_memory_breakpoint): New function.
12249 (set_raw_breakpoint_at): Reimplement.
12250 (set_breakpoint): New, based on set_breakpoint_at.
12251 (set_breakpoint_at): Reimplement.
12252 (delete_raw_breakpoint): Go through the_target->remove_point
12253 instead of assuming memory breakpoints.
12254 (find_gdb_breakpoint_at): Delete.
12255 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12256 (find_gdb_breakpoint): New function.
12257 (set_gdb_breakpoint_at): Delete.
12258 (z_type_supported): New function.
12259 (set_gdb_breakpoint_1): New function, loosely based off
12260 set_gdb_breakpoint_at.
12261 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12262 (delete_gdb_breakpoint_at): Delete.
12263 (delete_gdb_breakpoint_1): New function, loosely based off
12264 delete_gdb_breakpoint_at.
12265 (delete_gdb_breakpoint): New function.
12266 (clear_gdb_breakpoint_conditions): Rename to ...
12267 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12269 (add_condition_to_breakpoint): Make static.
12270 (add_breakpoint_condition): Take a struct breakpoint pointer
12271 instead of an address. Adjust.
12272 (gdb_condition_true_at_breakpoint): Rename to ...
12273 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12275 (gdb_condition_true_at_breakpoint): Reimplement.
12276 (add_breakpoint_commands): Take a struct breakpoint pointer
12277 instead of an address. Adjust.
12278 (gdb_no_commands_at_breakpoint): Rename to ...
12279 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12280 parameter. Return true if no breakpoint was found. Change debug
12282 (gdb_no_commands_at_breakpoint): Reimplement.
12283 (run_breakpoint_commands): Rename to ...
12284 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12285 and change return type to boolean.
12286 (run_breakpoint_commands): New function.
12287 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12288 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12289 breakpoint. Go through the_target->remove_point instead of
12290 assuming memory breakpoint.
12291 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12292 software and hardware breakpoints.
12293 (reinsert_raw_breakpoint): Go through the_target->insert_point
12294 instead of assuming memory breakpoint.
12295 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12296 software and hardware breakpoints.
12297 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12298 Check both software and hardware breakpoints.
12299 (validate_inserted_breakpoint): Assert the breakpoint is a
12300 software breakpoint. Set the inserted flag to -1 instead of
12301 setting shlib_disabled.
12302 (delete_disabled_breakpoints): Adjust.
12303 (validate_breakpoints): Only validate software breakpoints.
12304 Adjust to inserted flag change.
12305 (check_mem_read, check_mem_write): Skip breakpoint types other
12306 than software breakpoints. Adjust to inserted flag change.
12307 * mem-break.h (enum raw_bkpt_type): New enum.
12308 (raw_breakpoint, struct process_info): Forward declare.
12309 (Z_packet_to_target_hw_bp_type): Delete declaration.
12310 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12311 (set_gdb_breakpoint, delete_gdb_breakpoint)
12312 (clear_breakpoint_conditions): New declarations.
12313 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12314 (breakpoint_inserted_here): Update comment.
12315 (add_breakpoint_condition, add_breakpoint_commands): Replace
12316 address parameter with a breakpoint pointer parameter.
12317 (gdb_breakpoint_here): Update comment.
12318 (delete_gdb_breakpoint_at): Delete.
12319 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12320 * server.c (process_point_options): Take a struct breakpoint
12321 pointer instead of an address. Adjust.
12322 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12323 delete_gdb_breakpoint.
12324 * spu-low.c (spu_target_ops): Install NULL as
12325 supports_z_point_type method.
12326 * target.h: Include mem-break.h.
12327 (struct target_ops) <prepare_to_access_memory>: Update comment.
12328 <supports_z_point_type>: New field.
12329 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12330 instead of a char. Also take a raw breakpoint pointer.
12331 * win32-arm-low.c (the_low_target): Install NULL as
12332 supports_z_point_type.
12333 * win32-i386-low.c (i386_supports_z_point_type): New function.
12334 (i386_insert_point, i386_remove_point): Adjust to new interface.
12335 (the_low_target): Install i386_supports_z_point_type.
12336 * win32-low.c (win32_supports_z_point_type): New function.
12337 (win32_insert_point, win32_remove_point): Adjust to new interface.
12338 (win32_target_ops): Install win32_supports_z_point_type.
12339 * win32-low.h (struct win32_target_ops):
12340 <supports_z_point_type>: New method.
12341 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12342 instead of a char. Also take a raw breakpoint pointer.
12344 2014-05-20 Pedro Alves <palves@redhat.com>
12346 * mem-break.h: Include break-common.h.
12347 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12348 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12349 (Z_packet_to_target_hw_bp_type): New declaration.
12350 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12351 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12352 (Z_PACKET_ACCESS_WP): Delete macros.
12353 (Z_packet_to_hw_type): Delete function.
12354 * i386-low.h: Don't include break-common.h here.
12355 (Z_packet_to_hw_type): Delete declaration.
12356 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12357 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12358 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12359 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12360 * linux-aarch64-low.c: Don't include break-common.h here.
12361 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12362 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12363 (Z_packet_to_target_hw_bp_type): Delete function.
12364 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12366 (mips_insert_point, mips_remove_point): Use
12367 Z_packet_to_target_hw_bp_type.
12369 2014-05-20 Pedro Alves <palves@redhat.com>
12371 * linux-aarch64-low.c: Include break-common.h.
12372 (enum target_point_type): Delete.
12373 (Z_packet_to_point_type): Rename to ...
12374 (Z_packet_to_target_hw_bp_type): ... this, and return a
12375 target_hw_bp_type instead.
12376 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12377 instead of an enum target_point_type.
12378 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12380 (aarch64_dr_state_insert_one_point)
12381 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12382 (aarch64_handle_aligned_watchpoint)
12383 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12384 Take an enum target_hw_bp_type instead of an enum
12386 (aarch64_supports_z_point_type): New function.
12387 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12388 use Z_packet_to_target_hw_bp_type.
12390 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12392 * configure.ac: Only use -Werror by default when DEVELOPMENT
12394 * configure: Regenerate.
12396 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12398 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12399 * linux-x86-low.c (X86_64_USER_REGS): New.
12400 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12402 2014-04-28 Yao Qi <yao@codesourcery.com>
12404 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12407 2014-04-25 Pedro Alves <palves@redhat.com>
12410 * linux-low.c (linux_attach_fail_reason_string): New function.
12411 (linux_attach_lwp): Delete.
12412 (linux_attach_lwp_1): Rename to ...
12413 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12414 argument. Remove "initial" parameter. Return int instead of
12415 void. Don't error or warn here.
12416 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12417 failure to attach to the tgid. Call warning when failing to
12419 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12420 argument. Remove "initial" parameter. Return int instead of
12421 void. Don't error or warn here.
12422 (linux_attach_fail_reason_string): New declaration.
12423 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12424 interface change. Use linux_attach_fail_reason_string.
12426 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12427 Walfred Tedeschi <walfred.tedeschi@intel.com>
12429 * Makefile.in: Added rules to handle new files
12430 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12431 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12432 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12433 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12434 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12435 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12436 x32-avx512-linux.o.
12437 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12438 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12439 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12440 i386/x32-avx512.xml.
12441 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12442 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12443 i386/x32-avx512-linux.xml.
12444 * i387-fp.c (num_avx512_k_registers): New constant for number
12446 (num_avx512_zmmh_low_registers): New constant for number of
12447 lower ZMM registers (0-15).
12448 (num_avx512_zmmh_high_registers): New constant for number of
12449 higher ZMM registers (16-31).
12450 (num_avx512_ymmh_registers): New contant for number of higher
12451 YMM registers (ymm16-31 added by avx521 on x86_64).
12452 (num_avx512_xmm_registers): New constant for number of higher
12453 XMM registers (xmm16-31 added by AVX512 on x86_64).
12454 (struct i387_xsave): Add space for AVX512 registers.
12455 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12456 Add code to handle AVX512 registers.
12457 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12458 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12459 prototypei from generated file.
12460 (tdesc_amd64_avx512_linux): Likewise.
12461 (init_registers_x32_avx512_linux): Likewise.
12462 (tdesc_x32_avx512_linux): Likewise.
12463 (init_registers_i386_avx512_linux): Likewise.
12464 (tdesc_i386_avx512_linux): Likewise.
12465 (x86_64_regmap): Add AVX512 registers.
12466 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12468 (initialize_low_arch): Add code to initialize AVX512 registers.
12470 2014-04-23 Pedro Alves <palves@redhat.com>
12472 * mem-break.c (find_gdb_breakpoint_at): Make static.
12473 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12475 2014-04-23 Pedro Alves <palves@redhat.com>
12477 * i386-low.c: Don't include break-common.h here.
12478 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12479 prototype to take target_hw_bp_type as argument instead of a Z
12481 * i386-low.h: Include break-common.h here.
12482 (Z_packet_to_hw_type): Declare.
12483 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12485 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12486 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12487 (x86_remove_point): Convert the packet number to a
12488 target_hw_bp_type before calling i386_low_remove_watchpoint.
12489 * win32-i386-low.c (i386_insert_point): Convert the packet number
12490 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12491 (i386_remove_point): Convert the packet number to a
12492 target_hw_bp_type before calling i386_low_remove_watchpoint.
12494 2014-04-23 Pedro Alves <palves@redhat.com>
12496 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12498 2014-04-10 Pedro Alves <palves@redhat.com>
12500 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12501 Check if the condition or command is NULL before checking if the
12502 breakpoint is known. On success, return true.
12503 * mem-break.h (add_breakpoint_condition): Document return.
12504 (add_breakpoint_commands): Add describing comment.
12505 * server.c (skip_to_semicolon): New function.
12506 (process_point_options): Use it.
12508 2014-04-09 Pedro Alves <palves@redhat.com>
12510 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12513 2014-02-27 Pedro Alves <palves@redhat.com>
12516 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12518 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12520 (last_thread_of_process_p): Take a PID argument instead of a
12522 (linux_wait_for_lwp): Delete.
12523 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12525 (linux_low_filter_event): New function, party factored out from
12526 linux_wait_for_event.
12527 (linux_wait_for_event): Rename to ...
12528 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12529 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12530 sigsuspend. Check for zombie leaders.
12531 (linux_wait_for_event): Reimplement as wrapper around
12532 linux_wait_for_event_filtered.
12533 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12534 a normal or signal exit is seen, it's the whole process exiting.
12535 (wait_for_sigstop): No longer a for_each_inferior callback.
12536 Rewrite on top of linux_wait_for_event_filtered.
12537 (stop_all_lwps): Call wait_for_sigstop directly.
12538 * server.c (resume, handle_target_event): Handle
12539 TARGET_WAITKIND_NO_RESUMED.
12541 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12543 * win32-low.c (psapi_get_dll_name,
12544 * win32_CreateToolhelp32Snapshot): Delete.
12545 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12546 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12548 (handle_load_dll): Add function description.
12549 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12551 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12553 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12555 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12556 base address when calling win32_add_one_solib.
12557 (handle_load_dll): Delete local variable load_addr.
12558 Remove 0x1000 offset applied to DLL base address when calling
12559 win32_add_one_solib.
12560 (handle_unload_dll): Add comment.
12562 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12564 * win32-low.c (win32_add_all_dlls): Renames
12565 win32_ensure_ntdll_loaded. Rewrite function documentation.
12566 Adjust implementation to always load all DLLs.
12567 Add 0x1000 offset to DLL base address when calling
12568 win32_add_one_solib.
12569 (child_initialization_done): New static global.
12570 (do_initial_child_stuff): Set child_initialization_done to
12571 zero during child initialization, and 1 after. Replace call
12572 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12574 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12575 (handle_unload_dll): Add function documentation.
12576 (get_child_debug_event): Ignore load and unload DLL events
12577 during child initialization.
12579 2014-02-20 Doug Evans <dje@google.com>
12581 Remove global all_lwps.
12582 * inferiors.h (ptid_of): Move here from linux-low.h.
12583 (pid_of, lwpid_of): Ditto.
12584 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12585 parameter is a struct thread_info * now.
12586 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12587 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12588 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12590 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12591 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12592 * linux-arm-low.c (update_registers_callback): Update, "entry"
12593 parameter is a struct thread_info * now.
12594 Fetch lwpid from current_inferior directly.
12595 (arm_insert_point): Pass &all_threads to find_inferior instead of
12597 (arm_remove_point): Ditto.
12598 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12599 (arm_prepare_to_resume): Fetch pid from thread.
12600 (arm_read_description): Fetch lwpid from current_inferior directly.
12601 * linux-low.c (all_lwps): Delete.
12602 (delete_lwp): Delete call to remove_inferior.
12603 (handle_extended_wait): Fetch lwpid from thread.
12604 (add_lwp): Don't set lwp->entry.id. Remove call to
12605 add_inferior_to_list.
12606 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12607 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12608 (kill_one_lwp_callback): Ditto.
12609 (linux_kill): Don't dereference NULL pointer.
12610 Fetch ptid,lwpid from thread.
12611 (get_detach_signal): Fetch ptid from thread.
12612 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12613 Simplify call to regcache_invalidate_thread.
12614 (delete_lwp_callback): Update, "entry" parameter is a
12615 struct thread_info * now. Fetch pid from thread.
12616 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12617 (status_pending_p_callback): Update, "entry" parameter is a
12618 struct thread_info * now. Fetch ptid from thread.
12619 (find_lwp_pid): Update, "entry" parameter is a
12620 struct thread_info * now.
12621 (linux_wait_for_lwp): Fetch pid from thread.
12622 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12623 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12624 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12625 (dequeue_one_deferred_signal): Ditto.
12626 (cancel_breakpoint): Fetch ptid from current_inferior.
12627 (linux_wait_for_event): Pass &all_threads to find_inferior,
12628 not &all_lwps. Fetch ptid, lwpid from thread.
12629 (count_events_callback): Update, "entry" parameter is a
12630 struct thread_info * now.
12631 (select_singlestep_lwp_callback): Ditto.
12632 (select_event_lwp_callback): Ditto.
12633 (cancel_breakpoints_callback): Ditto.
12634 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12636 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12637 (unsuspend_one_lwp): Update, "entry" parameter is a
12638 struct thread_info * now.
12639 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12641 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12642 Fetch lwpid from thread, not lwp.
12643 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12644 Pass &all_threads to find_inferior, not &all_lwps.
12645 (send_sigstop): Fetch lwpid from thread, not lwp.
12646 (send_sigstop_callback): Update, "entry" parameter is a
12647 struct thread_info * now.
12648 (suspend_and_send_sigstop_callback): Ditto.
12649 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12650 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12651 struct thread_info * now.
12652 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12654 (lwp_running): Update, "entry" parameter is a
12655 struct thread_info * now.
12656 (stop_all_lwps): Fetch ptid from thread.
12657 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12658 (linux_resume_one_lwp): Fetch lwpid from thread.
12659 (linux_set_resume_request): Update, "entry" parameter is a
12660 struct thread_info * now. Fetch pid, lwpid from thread.
12661 (resume_status_pending_p): Update, "entry" parameter is a
12662 struct thread_info * now.
12663 (need_step_over_p): Ditto. Fetch lwpid from thread.
12664 (start_step_over): Fetch lwpid from thread.
12665 (linux_resume_one_thread): Update, "entry" parameter is a
12666 struct thread_info * now. Fetch lwpid from thread.
12667 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12668 (proceed_one_lwp): Update, "entry" parameter is a
12669 struct thread_info * now. Fetch lwpid from thread.
12670 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12671 struct thread_info * now.
12672 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12673 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12674 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12676 (regsets_store_inferior_registers): Ditto.
12677 (fetch_register, store_register): Ditto.
12678 (linux_read_memory, linux_write_memory): Ditto.
12679 (linux_request_interrupt): Ditto.
12680 (linux_read_auxv): Ditto.
12681 (linux_xfer_siginfo): Ditto.
12682 (linux_qxfer_spu): Ditto.
12683 (linux_qxfer_libraries_svr4): Ditto.
12684 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12685 moved to inferiors.h.
12687 (get_thread_lwp): Update.
12688 (struct lwp_info): Delete member "entry". Simplify comment for
12690 (all_lwps): Delete.
12691 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12692 current_inferior directly.
12693 (update_watch_registers_callback): Update, "entry" parameter is a
12694 struct thread_info * now. Fetch pid from thread.
12695 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12696 (mips_insert_point): Fetch lwpid from current_inferior.
12697 Pass &all_threads to find_inferior, not &all_lwps.
12698 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12699 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12701 (mips_stopped_data_address): Ditto.
12702 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12704 * linux-tile-low.c (tile_arch_setup): Ditto.
12705 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12706 (update_debug_registers_callback): Update, "entry" parameter is a
12707 struct thread_info * now. Fetch pid from thread.
12708 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12709 Pass &all_threads to find_inferior, not &all_lwps.
12710 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12711 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12712 Pass &all_threads to find_inferior, not &all_lwps.
12713 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12714 (i386_dr_low_get_status): Ditto.
12715 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12716 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12717 (x86_linux_read_description): Ditto.
12718 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12720 2014-02-20 Doug Evans <dje@google.com>
12722 * inferiors.c (get_first_inferior): Fix buglet.
12724 2014-02-19 Doug Evans <dje@google.com>
12726 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12727 * inferiors.c (add_thread): Change result type to struct thread_info *.
12728 All callers updated.
12729 (add_lwp): Call add_thread here instead of in callers.
12730 All callers updated.
12731 * linux-low.h (get_lwp_thread): Rewrite.
12732 (struct lwp_info): New member "thread".
12734 2014-02-19 Doug Evans <dje@google.com>
12736 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12737 All callers updated.
12739 2014-02-19 Doug Evans <dje@google.com>
12741 * inferiors.c (add_thread): Fix whitespace.
12743 2014-02-19 Doug Evans <dje@google.com>
12745 * dll.c (clear_dlls): Replace accessing list implemention details
12747 * gdbthread.h (get_first_thread): Declare.
12748 * inferiors.c (for_each_inferior_with_data): New function.
12749 (get_first_thread): New function.
12750 (find_thread_ptid): Simplify.
12751 (get_first_inferior): New function.
12752 (clear_list): Delete.
12753 (one_inferior_p): New function.
12754 (clear_inferior_list): New function.
12755 (clear_inferiors): Update.
12756 * inferiors.h (for_each_inferior_with_data): Declare.
12757 (clear_inferior_list): Declare.
12758 (one_inferior_p): Declare.
12759 (get_first_inferior): Declare.
12760 * linux-low.c (linux_wait_for_event): Replace accessing list
12761 implemention details with API function.
12762 * server.c (target_running): Ditto.
12763 (accumulate_file_name_length): New function.
12764 (emit_dll_description): New function.
12765 (handle_qxfer_libraries): Replace accessing list implemention
12766 details with API function.
12767 (handle_qxfer_threads_worker): New function.
12768 (handle_qxfer_threads_proper): Replace accessing list implemention
12769 details with API function.
12770 (handle_query): Ditto.
12771 (visit_actioned_threads_callback_ftype): New typedef.
12772 (visit_actioned_threads_data): New struct.
12773 (visit_actioned_threads): Rewrite to be find_inferior callback.
12774 (resume): Call find_inferior.
12775 (handle_status): Replace accessing list implemention
12776 details with API function.
12777 (process_serial_event): Replace accessing list implemention details
12779 * target.c (set_desired_inferior): Replace accessing list implemention
12780 details with API function.
12781 * tracepoint.c (same_process_p): New function.
12782 (gdb_agent_about_to_close): Replace accessing list implemention
12783 details with API function.
12784 * win32-low.c (child_delete_thread): Replace accessing list
12785 implemention details with API function.
12786 (match_dll_by_basename): New function.
12787 (dll_is_loaded_by_basename): New function.
12788 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12789 details call to dll_is_loaded_by_basename.
12791 2014-02-19 Doug Evans <dje@google.com>
12793 * dll.h (struct dll_info): Add comment.
12794 * gdbthread.h (struct thread_info): Add comment.
12795 (current_ptid): Simplify.
12796 * inferiors.c (add_process): Update.
12797 (remove_process): Update.
12798 * inferiors.h (struct process_info): Rename member "head" to "entry".
12799 * linux-low.c (delete_lwp): Update.
12801 (last_thread_of_process_p): Update.
12802 (kill_one_lwp_callback, linux_kill): Update.
12803 (status_pending_p_callback): Update.
12804 (wait_for_sigstop): Update. Simplify read of ptid.
12805 (start_step_over): Update.
12806 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12807 (get_lwp_thread): Update.
12808 (struct lwp_info): Rename member "head" to "entry".
12809 * regcache.h (inferior_list_entry): Delete.
12810 * server.c (kill_inferior_callback): Update.
12811 (detach_or_kill_inferior_callback): Update.
12812 (print_started_pid): Update.
12813 (print_attached_pid): Update.
12814 (process_serial_event): Simplify read of ptid.
12815 * thread-db.c (thread_db_create_event): Update.
12816 (thread_db_get_tls_address): Update.
12817 * win32-low.c (current_inferior_ptid): Simplify.
12819 2014-02-19 Tom Tromey <tromey@redhat.com>
12821 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12823 (target_supports_btrace): Update.
12825 2014-02-14 Yao Qi <yao@codesourcery.com>
12827 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12828 (rsp-low-ipa.o): New target.
12830 2014-02-12 Tom Tromey <tromey@redhat.com>
12832 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12833 convert_ascii_to_int.
12834 * regcache.c (registers_to_string): Likewise.
12835 * remote-utils.c (decode_M_packet): Likewise.
12836 * server.c (process_serial_event): Likewise.
12838 2014-02-12 Tom Tromey <tromey@redhat.com>
12840 * server.c (handle_query, handle_v_run): Use hex2bin, not
12842 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12844 2014-02-12 Tom Tromey <tromey@redhat.com>
12846 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12847 convert_int_to_ascii.
12848 * regcache.c (registers_to_string, collect_register_as_string):
12850 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12852 * server.c (process_serial_event): Likewise.
12853 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12854 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
12856 2014-02-12 Tom Tromey <tromey@redhat.com>
12858 * remote-utils.c (look_up_one_symbol, monitor_output): Use
12859 bin2hex, not hexify.
12860 * tracepoint.c (cmd_qtstatus): Likewise.
12862 2014-02-12 Tom Tromey <tromey@redhat.com>
12864 * remote-utils.c (monitor_output): Pass explicit length to
12867 2014-02-12 Tom Tromey <tromey@redhat.com>
12869 * tracepoint.c: Include rsp-low.h.
12870 * server.c: Include rsp-low.h.
12871 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
12872 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
12874 * remote-utils.c: Include rsp-low.h.
12875 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
12876 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
12877 (convert_int_to_ascii, convert_ascii_to_int): Move to
12879 * regcache.c: Include rsp-low.h.
12880 * ax.c: Include rsp-low.h.
12881 * Makefile.in (SFILES): Add common/rsp-low.c.
12882 (OBS): Add rsp-low.o.
12883 (rsp-low.o): New target.
12885 2014-02-12 Tom Tromey <tromey@redhat.com>
12887 * utils.h (pulongest, plongest, phex_nz): Don't declare.
12888 Include print-utils.h.
12889 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
12890 (plongest, thirty_two, phex_nz): Remove.
12891 * Makefile.in (SFILES): Add common/print-utils.c.
12892 (OBS): Add print-utils.o.
12893 (print-utils-ipa.o): New target.
12894 (print-utils.o): New target.
12895 (IPA_OBJS): Add print-utils-ipa.o.
12897 2014-02-06 Tom Tromey <tromey@redhat.com>
12899 * Makefile.in (SFILES): Fix indentation.
12901 2014-02-05 Doug Evans <dje@google.com>
12903 * linux-low.c (linux_wait_for_event): Improve comment.
12904 (linux_wait_1): Keep current_inferior in sync with event_child.
12906 2014-01-22 Doug Evans <dje@google.com>
12908 * gdbthread.h (gdb_id_to_thread): Delete, unused.
12910 2014-01-22 Doug Evans <dje@google.com>
12912 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
12913 * configure: Regenerate.
12914 * config.in: Regenerate.
12915 * Makefile.in (SFILES): Add debug.c.
12916 (OBS): Add debug.o.
12917 * debug.c: New file.
12918 * debug.h: New file.
12919 * linux-aarch64-low.c (*): Update all debugging printfs to use
12920 debug_printf instead of fprintf.
12921 * linux-arm-low.c (*): Ditto.
12922 * linux-cris-low.c (*): Ditto.
12923 * linux-crisv32-low.c (*): Ditto.
12924 * linux-m32r-low.c (*): Ditto.
12925 * linux-sparc-low.c (*): Ditto.
12926 * linux-x86.c (*): Ditto.
12927 * linux-low.c (*): Ditto.
12928 (linux_wait_1): Add calls to debug_enter, debug_exit.
12929 (linux_wait): Remove redundant debugging printf.
12930 (stop_all_lwps): Add calls to debug_enter, debug_exit.
12931 (linux_resume, unstop_all_lwps): Ditto.
12932 * mem-break.c (*): Update all debugging printfs to use
12933 debug_printf instead of fprintf.
12934 * remote-utils.c (*): Ditto.
12935 * thread-db.c (*): Ditto.
12936 * server.c #include <ctype.h>, "gdb_vecs.h".
12937 (debug_threads): Moved to debug.c.
12938 (*): Update all debugging printfs to use debug_printf instead of
12940 (start_inferior): Replace call to fflush with call to debug_flush.
12941 (monitor_show_help): Mention set debug-format.
12942 (parse_debug_format_options): New function.
12943 (handle_monitor_command): Handle "monitor set debug-format".
12944 (gdbserver_usage): Mention --debug-format.
12945 (main): Parse --debug-format.
12946 * server.h (debug_threads): Declaration moved to debug.h.
12947 #include "debug.h".
12948 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
12949 trace_debug_1 that uses debug_printf.
12950 (tracepoint_look_up_symbols): Update all debugging printfs to use
12951 debug_printf instead of fprintf.
12953 2014-01-20 Baruch Siach <baruch@tkos.co.il>
12955 * linux-xtensa-low.c: Include asm/ptrace.h instead of
12958 2014-01-17 Pedro Alves <palves@redhat.com>
12961 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
12962 defined after including gdb_proc_service.h.
12964 2014-01-16 Doug Evans <dje@google.com>
12966 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
12967 (match_dll): Use it.
12969 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
12971 * target.h (target_ops) <read_btrace>: Change parameters and
12972 return type to allow error reporting.
12973 * server.c (handle_qxfer_btrace): Support delta reads. Pass
12974 trace reading errors on.
12975 * linux-low.c (linux_low_read_btrace): Pass trace reading
12977 (linux_low_disable_btrace): New.
12979 2014-01-15 Doug Evans <dje@google.com>
12981 * inferiors.c (thread_id_to_gdb_id): Delete.
12982 * inferiors.h (thread_id_to_gdb_id): Delete.
12984 2014-01-13 Eli Zaretskii <eliz@gnu.org>
12986 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
12987 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
12990 2014-01-08 Pedro Alves <palves@redhat.com>
12992 * server.c (handle_status): Don't discard previous queued stop
12993 replies or thread's pending status here.
12994 (main) <disconnection>: Do it here instead.
12996 2014-01-08 Pedro Alves <palves@redhat.com>
12998 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
12999 * server.c (visit_actioned_threads, handle_pending_status): New
13001 (handle_v_cont): Factor out parts to ...
13002 (resume): ... this new function. If in all-stop, and a thread
13003 being resumed has a pending status, report it without actually
13005 (myresume): Adjust to use the new 'resume' function.
13006 (clear_pending_status_callback, set_pending_status_callback)
13007 (find_status_pending_thread_callback): New functions.
13008 (handle_status): Handle the case of multiple threads having
13009 interesting statuses to report. Report threads' real last signal
13010 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13011 with an interesting thread to report the status for, instead of
13012 always reporting the status of the first thread.
13014 2014-01-01 Joel Brobecker <brobecker@adacore.com>
13016 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13017 * gdbreplay.c (gdbreplay_version): Likewise.
13019 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13021 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13022 iov.iov_len with the real length in use.
13024 2013-12-13 Joel Brobecker <brobecker@adacore.com>
13026 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13027 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13028 for all targets that use win32-low.c.
13029 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13030 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13032 2013-12-13 Pedro Alves <palves@redhat.com>
13034 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13035 if equal to TARGET_WAITKIND_LOADED.
13036 * win32-low.c (cached_status): New static global.
13037 (win32_wait): Add declaration.
13038 (do_initial_child_stuff): Flush all initial pending debug events
13039 up to the initial breakpoint.
13040 (win32_wait): If CACHED_STATUS was set, return that instead
13041 of doing a real wait. Remove the code resuming the execution
13042 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13043 during the initial phase. Also remove the code changing
13044 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13045 TARGET_WAITKIND_STOPPED.
13047 2013-12-11 Yao Qi <yao@codesourcery.com>
13049 * notif.c (handle_notif_ack): Return 0 if no notification
13052 2013-11-20 Doug Evans <dje@google.com>
13054 * linux-low.c (linux_set_resume_request): Fix comment.
13056 2013-11-20 Doug Evans <dje@google.com>
13058 * linux-low.c (resume_status_pending_p): Tweak comment.
13060 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13062 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13063 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13064 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13065 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13066 (srv_amd64_regobj): Add amd64-mpx.o.
13067 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13068 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13069 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13070 * i387-fp.c (num_pl_bnd_register) Added constant.
13071 (num_pl_bnd_cfg_registers) Added constant.
13072 (struct i387_xsave) Added reserved area and MPX fields.
13073 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13074 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13076 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13077 (init_registers_amd64_mpx_linux): Declare new function.
13078 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13079 (x86_64_regmap): Add MPX registers.
13080 (x86_linux_read_description): Add MPX case.
13081 (initialize_low_arch): Initialize MPX targets.
13083 2013-11-18 Tom Tromey <tromey@redhat.com>
13085 * configure: Rebuild.
13086 * configure.ac: Don't check for stdlib.h.
13087 * gdbreplay.c: Unconditionally include stdlib.h.
13089 2013-11-18 Tom Tromey <tromey@redhat.com>
13091 * config.in: Rebuild.
13092 * configure: Rebuild.
13093 * configure.ac: Don't use AC_HEADER_DIRENT.
13095 2013-11-18 Tom Tromey <tromey@redhat.com>
13097 * server.h: Don't check HAVE_STRING_H.
13098 * gdbreplay.c: Don't check HAVE_STRING_H.
13099 * configure: Rebuild.
13101 2013-11-18 Tom Tromey <tromey@redhat.com>
13103 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13106 2013-11-08 Tom Tromey <tromey@redhat.com>
13108 * configure, config.in: Rebuild.
13109 * configure.ac: Remove unused configury.
13111 2013-11-08 Tom Tromey <tromey@redhat.com>
13113 * acinclude.m4: Include common.m4, codeset.m4.
13114 * configure, config.in: Rebuild.
13115 * configure.ac: Use GDB_AC_COMMON.
13117 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13119 * linux-s390-low.c (HWCAP_S390_TE): New define.
13120 (s390_arch_setup): Consider the TE field in the HWCAP for
13121 determining 'have_regset_tdb'.
13123 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13126 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13129 2013-10-02 Pedro Alves <palves@redhat.com>
13131 * server.c (process_serial_event): Don't output "GDBserver
13132 exiting" if GDB is connected through stdio.
13133 * target.c (mywait): Likewise, be silent if GDB is connected
13136 2013-10-01 Joel Brobecker <brobecker@adacore.com>
13138 * lynx-low.c (lynx_add_threads_after_attach): New function.
13139 (lynx_attach): Remove call to add_thread. Add call to
13140 lynx_add_threads_after_attach instead.
13142 2013-09-28 Mike Frysinger <vapier@gentoo.org>
13144 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13145 * config.in, configure: Regenerated.
13147 2013-09-18 Yao Qi <yao@codesourcery.com>
13150 * server.c (start_inferior): Clear 'resume_info'.
13152 2013-09-16 Jiong Wang <jiwang@tilera.com>
13154 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13157 2013-09-16 Jiong Wang <jiwang@tilera.com>
13159 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13160 linux-tile-low.o to srv_tgtobj.
13162 2013-09-16 Will Newton <will.newton@linaro.org>
13164 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13167 2013-09-06 Pedro Alves <palves@redhat.com>
13169 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13170 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13171 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13172 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13173 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13174 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13176 2013-09-06 Pedro Alves <palves@redhat.com>
13178 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13179 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13181 2013-09-06 Pedro Alves <palves@redhat.com>
13183 * linux-amd64-ipa.c: Include tracepoint.h.
13184 * linux-i386-ipa.c: Include tracepoint.h.
13186 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13188 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13189 (ps_get_thread_area): New function.
13191 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13193 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13194 (initialize_low_arch): Call init_registers_crisv32 rather than
13195 init_register_crisv32.
13197 2013-09-05 Pedro Alves <palves@redhat.com>
13199 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13201 * hostio.h: ... this new file.
13202 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13203 win32-low.c: Include hostio.h.
13205 2013-09-05 Pedro Alves <palves@redhat.com>
13207 * server.h (gdb_client_data, handler_func, callback_handler_func)
13208 (delete_file_handler, add_file_handler, append_callback_event)
13209 (delete_callback_event, start_event_loop, initialize_event_loop):
13210 Move to event-loop.h and include it.
13211 * event-loop.h: New file.
13213 2013-09-05 Pedro Alves <palves@redhat.com>
13215 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13216 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13217 (loaded_dll, unloaded_dll): Move to ...
13218 * dll.h: ... this new file.
13219 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13221 2013-09-05 Pedro Alves <palves@redhat.com>
13223 * server.h (current_process, get_thread_process, all_processes)
13224 (add_inferior_to_list, for_each_inferior, current_inferior)
13225 (remove_inferior, add_process, remove_process, find_process_pid)
13226 (have_started_inferiors_p, have_attached_inferiors_p)
13227 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13228 (clear_inferiors, find_inferior, find_inferior_id)
13229 (inferior_target_data, set_inferior_target_data)
13230 (inferior_regcache_data, set_inferior_regcache_data): Move to
13231 inferiors.h, and include it.
13232 * inferiors.h: New file.
13234 2013-09-05 Pedro Alves <palves@redhat.com>
13236 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13240 2013-09-05 Pedro Alves <palves@redhat.com>
13242 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13244 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13245 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13246 (handle_tracepoint_general_set, handle_tracepoint_query)
13247 (tracepoint_finished_step, tracepoint_was_hit)
13248 (release_while_stepping_state_list, current_traceframe)
13249 (in_readonly_region, traceframe_read_mem)
13250 (fetch_traceframe_registers, traceframe_read_sdata)
13251 (traceframe_read_info, struct fast_tpoint_collect_status)
13252 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13253 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13254 (supply_fast_tracepoint_registers)
13255 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13256 (ipa_tdesc, claim_trampoline_space)
13257 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13258 (agent_mem_read, agent_get_trace_state_variable_value)
13259 (agent_set_trace_state_variable_value, agent_tsv_read)
13260 (agent_mem_read_string, get_raw_reg_func_addr)
13261 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13262 * tracepoint.h: ... this new file.
13264 2013-09-05 Pedro Alves <palves@redhat.com>
13266 * server.h (perror_with_name, error, fatal, warning, paddress)
13267 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13269 * utils.h: New file.
13271 2013-09-05 Pedro Alves <palves@redhat.com>
13273 * server.h (remote_debug, noack_mode, transport_is_reliable)
13274 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13275 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13276 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13277 (write_enn, initialize_async_io, enable_async_io)
13278 (disable_async_io, check_remote_input_interrupt_request)
13279 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13280 (dead_thread_notify, prepare_resume_reply)
13281 (decode_address_to_semicolon, decode_address, decode_m_packet)
13282 (decode_M_packet, decode_X_packet, decode_xfer_write)
13283 (decode_search_memory_packet, unhexify, hexify)
13284 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13285 (look_up_one_symbol, relocate_instruction)
13286 (monitor_output): Move to remote-utils.h, and include it.
13287 * remote-utils.h: New file.
13289 2013-09-05 Pedro Alves <palves@redhat.com>
13291 * server.h (_): Delete.
13293 2013-09-02 Pedro Alves <palves@redhat.com>
13295 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13296 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13298 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13300 2013-09-02 Pierre Muller <muller@sourceware.org>
13302 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13303 or WriteProcessMemory complete successfully and handle
13304 ERROR_PARTIAL_COPY error.
13306 2013-09-02 Pedro Alves <palves@redhat.com>
13308 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13309 error instead of EIO.
13311 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13314 * linux-low.c: Include filestuff.h.
13315 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13316 * lynx-low.c: Include filestuff.h.
13317 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13318 * server.c: Include filestuff.h.
13319 (main): Call notice_open_fds.
13320 * spu-low.c: Include filestuff.h.
13321 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13323 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13325 * Makefile.in: Explain why ../target and ../nat are not
13326 listed as include file search paths.
13327 (linux-waitpid.o): New object file rule.
13328 * configure.srv (srv_native_linux_obj): New variable.
13329 Replace all occurrences of linux native object files with
13330 $srv_native_linux_obj.
13331 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13332 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13333 (linux_enable_event_reporting): Remove declaration.
13334 (my_waitpid): Moved to common/linux-waitpid.c.
13335 (linux_wait_for_event): Pass ptid when calling
13336 linux_enable_event_reporting.
13337 (linux_supports_tracefork_flag): Remove.
13338 (linux_enable_event_reporting): Likewise.
13339 (linux_tracefork_grandchild): Remove.
13340 (STACK_SIZE): Moved to common/linux-ptrace.c.
13341 (linux_tracefork_child): Remove.
13342 (linux_test_for_tracefork): Remove.
13343 (linux_look_up_symbols): Call linux_supports_traceclone.
13344 (initialize_low): Remove call to linux_test_for_tracefork.
13345 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13346 common/linux-ptrace.h.
13347 (PTRACE_TYPE_ARG4): Likewise.
13348 Include linux-ptrace.h.
13350 2013-08-21 Pedro Alves <palves@redhat.com>
13352 * config.in: Renegerate.
13354 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13356 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13357 (SFILES): Remove $(srcdir)/common/target-common.c and
13358 add $(srcdir)/target/waitstatus.c.
13359 (OBS): Remove target-common.o and add waitstatus.o.
13360 (server_h): Remove $(srcdir)/../common/target-common.h and
13361 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13362 and $(srcdir)/../target/waitstatus.h.
13363 (target-common.o): Remove.
13364 (waitstatus.o): New target object file.
13365 * target.h: Do not include target-common.h and
13366 include target/resume.h, target/wait.h and
13367 target/waitstatus.h.
13369 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13371 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13372 to PTRACE_TYPE_ARG3.
13373 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13374 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13376 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13377 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13379 2013-07-27 Jie Zhang <jie@codesourcery.com>
13380 Daniel Jacobowitz <dan@codesourcery.com>
13381 Yao Qi <yao@codesourcery.com>
13383 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13384 (mips-linux-watch.o): New rule.
13385 (mips_linux_watch_h): New variable.
13386 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13388 * linux-mips-low.c: Include mips-linux-watch.h.
13389 (struct arch_process_info, struct arch_lwp_info): New.
13390 (update_watch_registers_callback): New function.
13391 (mips_linux_new_process, mips_linux_new_thread) New functions.
13392 (mips_linux_prepare_to_resume, mips_insert_point): New
13394 (mips_remove_point, mips_stopped_by_watchpoint): New
13396 (rsp_bp_type_to_target_hw_bp_type): New function.
13397 (mips_stopped_data_address): New function.
13398 (the_low_target): Add watchpoint support functions.
13400 2013-07-27 Yao Qi <yao@codesourcery.com>
13402 * i386-low.c: Include break-common.h.
13403 (enum target_hw_bp_type): Remove.
13405 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13407 * Makefile.in (SFILES): /common/target-common.c.
13408 (OBS): Add target-common.o.
13409 (server_h): Add $(srcdir)/../common/target-common.h.
13410 (target-common.o): New target.
13411 * server.c (queue_stop_reply_callback): Free
13412 status string after use.
13413 * target.c (target_waitstatus_to_string): Remove.
13414 * target.h: Include target-common.h.
13415 (resume_kind): Likewise.
13416 (target_waitkind): Likewise.
13417 (target_waitstatus): Likewise.
13418 (TARGET_WNOHANG): Likewise.
13420 2013-07-04 Yao Qi <yao@codesourcery.com>
13422 * Makefile.in (host_alias): Use @host_noncanonical@.
13423 (target_alias): Use @target_noncanonical@.
13424 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13425 ACX_NONCANONICAL_HOST.
13426 * configure: Regenerated.
13429 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13431 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13432 * configure: Rebuild.
13433 * Makefile.in (version_host, version_target): Get from configure.
13434 (version.c): Use $(version_host) and $(version_target).
13436 2013-07-03 Pedro Alves <palves@redhat.com>
13438 * Makefile.in (config.status): Depend on development.sh.
13439 * acinclude.m4: Include libmcheck.m4.
13440 * configure: Regenerate.
13442 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13444 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13445 attribute inside the parentheses.
13446 (winapi_DebugSetProcessKillOnExit): Ditto.
13447 (winapi_DebugBreakProcess): Ditto.
13448 (winapi_GenerateConsoleCtrlEvent): Ditto.
13450 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13452 * notif.h (notif_event): Add a dummy member to avoid compiler
13455 2013-07-01 Pedro Alves <palves@redhat.com>
13457 * hostio.c (HOSTIO_PATH_MAX): Define.
13458 (require_filename, handle_open, handle_unlink, handle_readlink):
13461 2013-07-01 Pedro Alves <palves@redhat.com>
13463 * server.h: Include "pathmax.h".
13464 * linux-low.c: Don't include sys/param.h.
13465 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13467 * win32-low.c: Don't include sys/param.h.
13468 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13470 2013-07-01 Pedro Alves <palves@redhat.com>
13472 * event-loop.c: Don't check HAVE_UNISTD_H before including
13474 * gdbreplay.c: Likewise.
13475 * remote-utils.c: Likewise.
13476 * server.c: Likewise.
13477 * configure.ac: Don't check for unistd.h.
13478 * configure: Regenerate.
13480 2013-06-28 Tom Tromey <tromey@redhat.com>
13482 * Makefile.in (version.c): Use version.in, not
13485 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13487 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13488 * configure: Rebuild.
13489 * Makefile.in (version_host, version_target): Get from configure.
13490 (version.c): Use $(version_host) and $(version_target).
13492 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13494 Fix trace-status to output user name without trailing colon.
13495 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13497 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13499 Fix trace-status to output proper start-time and stop-time.
13500 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13501 output start time and stop time in hex as gdb expects.
13503 2013-06-26 Pedro Alves <pedro@codesourcery.com>
13505 * tracepoint.c (build_traceframe_info_xml): Output trace state
13506 variables present in the trace buffer.
13508 2013-06-24 Tom Tromey <tromey@redhat.com>
13510 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13512 (version.o): Remove.
13513 * gdbreplay.c: Include version.h.
13514 (version, host_name): Don't declare.
13515 * server.h: Include version.h.
13516 (version, host_name): Don't declare.
13518 2013-06-12 Pedro Alves <palves@redhat.com>
13520 * linux-x86-low.c (linux_is_elf64): Delete global.
13521 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13522 with local linux_pid_exe_is_elf_64_file use.
13524 2013-06-11 Pedro Alves <palves@redhat.com>
13526 * linux-low.c (regset_disabled, disable_regset): New functions.
13527 (regsets_fetch_inferior_registers)
13528 (regsets_store_inferior_registers): Use them.
13529 (initialize_regsets_info); Don't allocate the disabled_regsets
13531 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13534 2013-06-11 Pedro Alves <palves@redhat.com>
13536 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13539 2013-06-11 Pedro Alves <palves@redhat.com>
13541 * linux-x86-low.c (initialize_low_arch): Call
13542 init_registers_x32_avx_linux.
13544 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13546 Fix compatibility with Android Bionic.
13547 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13550 2013-06-07 Pedro Alves <palves@redhat.com>
13553 * Makefile.in (OBS): Add tdesc.o.
13554 (IPA_OBJS): Add tdesc-ipa.o.
13555 (tdesc-ipa.o): New rule.
13556 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13558 * linux-low.c (new_inferior): Delete.
13559 (disabled_regsets, num_regsets): Delete.
13560 (linux_add_process): Adjust to set the new per-process
13562 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13563 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13564 was a stop. When calling arch_setup, switch the current inferior
13565 to the thread that got an event.
13566 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13567 (regsets_fetch_inferior_registers)
13568 (regsets_store_inferior_registers): New regsets_info parameter.
13570 (linux_register_in_regsets): New regs_info parameter. Adjust to
13572 (register_addr, fetch_register, store_register): New usrregs_info
13573 parameter. Adjust to use it.
13574 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13575 parameter regs_info. Adjust to use it.
13576 (linux_fetch_registers): Get the current inferior's regs_info, and
13578 (linux_store_registers): Ditto.
13579 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13580 (initialize_low): Don't initialize the target_regsets here. Call
13581 initialize_low_arch.
13582 * linux-low.h (target_regsets): Delete declaration.
13583 (struct regsets_info): New.
13584 (struct usrregs_info): New.
13585 (struct regs_info): New.
13586 (struct process_info_private) <new_inferior>: New field.
13587 (struct linux_target_ops): Delete the num_regs, regmap, and
13588 regset_bitmap fields. New field regs_info.
13589 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13590 * i387-fp.c (num_xmm_registers): Delete.
13591 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13592 calls to new interface.
13593 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13594 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13595 Infer the number of xmm registers from the regcache's target
13597 * i387-fp.h (num_xmm_registers): Delete.
13598 * inferiors.c (add_thread): Don't install the thread's regcache
13600 * proc-service.c (gregset_info): Fetch the current inferior's
13601 regs_info. Adjust to use it.
13602 * regcache.c: Include tdesc.h.
13603 (register_bytes, reg_defs, num_registers)
13604 (gdbserver_expedite_regs): Delete.
13605 (get_thread_regcache): If the thread doesn't have a regcache yet,
13606 create one, instead of aborting gdbserver.
13607 (regcache_invalidate_one): Rename to ...
13608 (regcache_invalidate_thread): ... this.
13609 (regcache_invalidate_one): New.
13610 (regcache_invalidate): Only invalidate registers of the current
13612 (init_register_cache): Add target_desc parameter, and use it.
13613 (new_register_cache): Ditto. Assert the target description has a
13614 non zero registers_size.
13615 (regcache_cpy): Add assertions. Adjust.
13616 (realloc_register_cache, set_register_cache): Delete.
13617 (registers_to_string, registers_from_string): Adjust.
13618 (find_register_by_name, find_regno, find_register_by_number)
13619 (register_cache_size): Add target_desc parameter, and use it.
13620 (free_register_cache_thread, free_register_cache_thread_one)
13621 (regcache_release, register_cache_size): New.
13622 (register_size): Add target_desc parameter, and use it.
13623 (register_data, supply_register, supply_register_zeroed)
13624 (supply_regblock, supply_register_by_name, collect_register)
13625 (collect_register_as_string, collect_register_by_name): Adjust.
13626 * regcache.h (struct target_desc): Forward declare.
13627 (struct regcache) <tdesc>: New field.
13628 (init_register_cache, new_register_cache): Add target_desc
13630 (regcache_invalidate_thread): Declare.
13631 (regcache_invalidate_one): Delete declaration.
13632 (regcache_release): Declare.
13633 (find_register_by_number, register_cache_size, register_size)
13634 (find_regno): Add target_desc parameter.
13635 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13637 * remote-utils.c: Include tdesc.h.
13638 (outreg, prepare_resume_reply): Adjust.
13639 * server.c: Include tdesc.h.
13640 (gdbserver_xmltarget): Delete declaration.
13641 (get_features_xml, process_serial_event): Adjust.
13642 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13644 (struct process_info) <tdesc>: New field.
13645 (ipa_tdesc): Declare.
13646 * tdesc.c: New file.
13647 * tdesc.h: New file.
13648 * tracepoint.c: Include tdesc.h.
13649 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13650 (get_context_regcache): Adjust to pass ipa_tdesc down.
13651 (do_action_at_tracepoint): Adjust to get the register cache size
13652 from the context regcache's description.
13653 (traceframe_walk_blocks): Adjust to get the register cache size
13654 from the current trace frame's description.
13655 (traceframe_get_pc): Adjust to get current trace frame's
13656 description and pass it down.
13657 (gdb_collect): Adjust to get the register cache size from the
13659 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13660 (gdbserver_xmltarget): Delete.
13661 (initialize_low_tracepoint): Set the ipa's target description.
13662 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13663 (initialize_low_tracepoint): Set the ipa's target description.
13664 * linux-x86-low.c: Include tdesc.h.
13665 [__x86_64__] (is_64bit_tdesc): New.
13666 (ps_get_thread_area, x86_get_thread_area): Use it.
13667 (i386_cannot_store_register): Rename to ...
13668 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13669 (i386_cannot_fetch_register): Rename to ...
13670 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13671 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13673 (target_regsets): Rename to ...
13674 (x86_regsets): ... this.
13675 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13677 (x86_siginfo_fixup): Use is_64bit_tdesc.
13678 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13679 (tdesc_x32_avx_linux, tdesc_x32_linux)
13680 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13682 (x86_linux_update_xmltarget): Delete.
13683 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13684 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13685 (AMD64_LINUX_USER64_CS): New.
13686 (x86_linux_read_description): New, based on
13687 x86_linux_update_xmltarget.
13688 (same_process_callback): New.
13689 (x86_arch_setup_process_callback): New.
13690 (x86_linux_update_xmltarget): New.
13691 (x86_regsets_info): New.
13692 (amd64_linux_regs_info): New.
13693 (i386_linux_usrregs_info): New.
13694 (i386_linux_regs_info): New.
13695 (x86_linux_regs_info): New.
13696 (x86_arch_setup): Reimplement.
13697 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13698 (x86_emit_ops): Ditto.
13699 (the_low_target): Adjust. Install x86_linux_regs_info,
13700 x86_cannot_fetch_register, and x86_cannot_store_register.
13701 (initialize_low_arch): New.
13702 * linux-ia64-low.c (tdesc_ia64): Declare.
13703 (ia64_fetch_register): Adjust.
13704 (ia64_usrregs_info, regs_info): New globals.
13705 (ia64_regs_info): New function.
13706 (the_low_target): Adjust.
13707 (initialize_low_arch): New function.
13708 * linux-sparc-low.c (tdesc_sparc64): Declare.
13709 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13711 (sparc_arch_setup): New function.
13712 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13713 (the_low_target): Adjust.
13714 (initialize_low_arch): New function.
13715 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13716 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13717 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13718 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13719 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13720 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13721 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13722 (tdesc_powerpc_isa205_vsx64l): Declare.
13723 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13724 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13725 (ppc_set_pc, ppc_get_hwcap): Adjust.
13726 (ppc_usrregs_info): Forward declare.
13727 (!__powerpc64__) ppc_regmap_adjusted: New global.
13728 (ppc_arch_setup): Adjust to the current process'es target
13730 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13731 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13732 (ppc_store_evrregset): Adjust.
13733 (target_regsets): Rename to ...
13734 (ppc_regsets): ... this, and make static.
13735 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13736 (ppc_regs_info): New function.
13737 (the_low_target): Adjust.
13738 (initialize_low_arch): New function.
13739 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13740 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13741 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13742 (tdesc_s390x_linux64v2): Declare.
13743 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13744 (s390_fill_gregset, s390_store_last_break): Adjust.
13745 (target_regsets): Rename to ...
13746 (s390_regsets): ... this, and make static.
13747 (s390_get_pc, s390_set_pc): Adjust.
13748 (s390_get_hwcap): New target_desc parameter, and use it.
13749 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13750 (s390_arch_setup): Adjust to set the current process'es target
13751 description. Don't adjust the regmap.
13752 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13753 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13754 (regs_info_3264): New globals.
13755 (s390_regs_info): New function.
13756 (the_low_target): Adjust.
13757 (initialize_low_arch): New function.
13758 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13759 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13760 [__mips64] (init_registers_mips_linux)
13761 (init_registers_mips_dsp_linux): Delete defines.
13762 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13763 (have_dsp): New global.
13764 (mips_read_description): New, based on mips_arch_setup.
13765 (mips_arch_setup): Reimplement.
13766 (get_usrregs_info): New function.
13767 (mips_cannot_fetch_register, mips_cannot_store_register)
13768 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13769 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13770 (target_regsets): Rename to ...
13771 (mips_regsets): ... this, and make static.
13772 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13773 (dsp_regs_info, regs_info): New globals.
13774 (mips_regs_info): New function.
13775 (the_low_target): Adjust.
13776 (initialize_low_arch): New function.
13777 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13778 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13780 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13781 (arm_read_description): New, with bits factored from
13783 (arm_arch_setup): Reimplement.
13784 (target_regsets): Rename to ...
13785 (arm_regsets): ... this, and make static.
13786 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13787 (arm_regs_info): New function.
13788 (the_low_target): Adjust.
13789 (initialize_low_arch): New function.
13790 * linux-m68k-low.c (tdesc_m68k): Declare.
13791 (target_regsets): Rename to ...
13792 (m68k_regsets): ... this, and make static.
13793 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13794 (m68k_regs_info): New function.
13795 (m68k_arch_setup): New function.
13796 (the_low_target): Adjust.
13797 (initialize_low_arch): New function.
13798 * linux-sh-low.c (tdesc_sharch): Declare.
13799 (target_regsets): Rename to ...
13800 (sh_regsets): ... this, and make static.
13801 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13802 (sh_regs_info, sh_arch_setup): New functions.
13803 (the_low_target): Adjust.
13804 (initialize_low_arch): New function.
13805 * linux-bfin-low.c (tdesc_bfin): Declare.
13806 (bfin_arch_setup): New function.
13807 (bfin_usrregs_info, regs_info): New globals.
13808 (bfin_regs_info): New function.
13809 (the_low_target): Adjust.
13810 (initialize_low_arch): New function.
13811 * linux-cris-low.c (tdesc_cris): Declare.
13812 (cris_arch_setup): New function.
13813 (cris_usrregs_info, regs_info): New globals.
13814 (cris_regs_info): New function.
13815 (the_low_target): Adjust.
13816 (initialize_low_arch): New function.
13817 * linux-cris-low.c (tdesc_crisv32): Declare.
13818 (cris_arch_setup): New function.
13819 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13820 (cris_regs_info): New function.
13821 (the_low_target): Adjust.
13822 (initialize_low_arch): New function.
13823 * linux-m32r-low.c (tdesc_m32r): Declare.
13824 (m32r_arch_setup): New function.
13825 (m32r_usrregs_info, regs_info): New globals.
13826 (m32r_regs_info): Adjust.
13827 (initialize_low_arch): New function.
13828 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13829 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13830 (tic6x_usrregs_info): Forward declare.
13831 (tic6x_read_description): New function, based on ...
13832 (tic6x_arch_setup): ... this. Reimplement.
13833 (target_regsets): Rename to ...
13834 (tic6x_regsets): ... this, and make static.
13835 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13836 (tic6x_regs_info): New function.
13837 (the_low_target): Adjust.
13838 (initialize_low_arch): New function.
13839 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13840 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13841 (target_regsets): Rename to ...
13842 (xtensa_regsets): ... this, and make static.
13843 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13845 (xtensa_arch_setup, xtensa_regs_info): New functions.
13846 (the_low_target): Adjust.
13847 (initialize_low_arch): New function.
13848 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13849 (nios2_arch_setup): Set the current process'es tdesc.
13850 (target_regsets): Rename to ...
13851 (nios2_regsets): ... this.
13852 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13853 (nios2_regs_info): New function.
13854 (the_low_target): Adjust.
13855 (initialize_low_arch): New function.
13856 * linux-aarch64-low.c (tdesc_aarch64): Declare.
13857 (aarch64_arch_setup): Set the current process'es tdesc.
13858 (target_regsets): Rename to ...
13859 (aarch64_regsets): ... this.
13860 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
13861 (aarch64_regs_info): New function.
13862 (the_low_target): Adjust.
13863 (initialize_low_arch): New function.
13864 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
13866 (target_regsets): Rename to ...
13867 (tile_regsets): ... this.
13868 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
13869 (tile_regs_info): New function.
13870 (tile_arch_setup): Set the current process'es tdesc.
13871 (the_low_target): Adjust.
13872 (initialize_low_arch): New function.
13873 * spu-low.c (tdesc_spu): Declare.
13874 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
13875 * win32-arm-low.c (tdesc_arm): Declare.
13876 (arm_arch_setup): New function.
13877 (the_low_target): Install arm_arch_setup instead of
13878 init_registers_arm.
13879 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
13880 (init_windows_x86): Rename to ...
13881 (i386_arch_setup): ... this. Set `win32_tdesc'.
13882 (the_low_target): Adjust.
13883 * win32-low.c (win32_tdesc): New global.
13884 (child_add_thread): Don't create the thread cache here.
13885 (do_initial_child_stuff): Set the new process'es tdesc.
13886 * win32-low.h (struct target_desc): Forward declare.
13887 (win32_tdesc): Declare.
13888 * lynx-i386-low.c (tdesc_i386): Declare global.
13889 (lynx_i386_arch_setup): Set `lynx_tdesc'.
13890 * lynx-low.c (lynx_tdesc): New global.
13891 (lynx_add_process): Set the new process'es tdesc.
13892 * lynx-low.h (struct target_desc): Forward declare.
13893 (lynx_tdesc): Declare global.
13894 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
13895 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
13896 * nto-low.c (nto_tdesc): New global.
13897 (do_attach): Set the new process'es tdesc.
13898 * nto-low.h (struct target_desc): Forward declare.
13899 (nto_tdesc): Declare.
13900 * nto-x86-low.c (tdesc_i386): Declare.
13901 (nto_x86_arch_setup): Set `nto_tdesc'.
13903 2013-06-04 Gary Benson <gbenson@redhat.com>
13905 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
13906 to qSupported response when appropriate.
13907 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
13908 with nonzero-length annex.
13909 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
13910 arguments supplied in annex.
13912 2013-05-31 Doug Evans <dje@google.com>
13915 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
13916 64 bits in 64-cross-32 environment.
13918 2013-05-28 Pedro Alves <palves@redhat.com>
13920 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
13921 (aarch64-without-fpu.c): Delete rule.
13922 * configure.srv (aarch64*-*-linux*): Remove references to
13923 aarch64-without-fpu.o and aarch64-without-fpu.xml.
13924 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
13927 2013-05-24 Pedro Alves <palves@redhat.com>
13929 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
13930 instead of strchr/decode_address. Error if the range isn't split
13931 with a ','. Don't assume there's be a ':' in the action.
13933 2013-05-23 Yao Qi <yao@codesourcery.com>
13934 Pedro Alves <palves@redhat.com>
13936 * linux-low.c (lwp_in_step_range): New function.
13937 (linux_wait_1): If the thread was range stepping and stopped
13938 outside the stepping range, report the stop to GDB. Otherwise,
13939 continue stepping. Add range stepping debug output.
13940 (linux_set_resume_request): Copy the step range from the resume
13941 request to the lwp.
13942 (linux_supports_range_stepping): New.
13943 (linux_target_ops) <supports_range_stepping>: Set to
13944 linux_supports_range_stepping.
13945 * linux-low.h (struct linux_target_ops)
13946 <supports_range_stepping>: New field.
13947 (struct lwp_info) <step_range_start, step_range_end>: New fields.
13948 * linux-x86-low.c (x86_supports_range_stepping): New.
13949 (the_low_target) <supports_range_stepping>: Set to
13950 x86_supports_range_stepping.
13951 * server.c (handle_v_cont): Handle 'r' action.
13952 (handle_v_requests): Append ";r" if the target supports range
13954 * target.h (struct thread_resume) <step_range_start,
13955 step_range_end>: New fields.
13956 (struct target_ops) <supports_range_stepping>:
13958 (target_supports_range_stepping): New macro.
13960 2013-05-17 Joel Brobecker <brobecker@adacore.com>
13962 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
13963 confusion in comment.
13965 2013-05-17 Joel Brobecker <brobecker@adacore.com>
13967 * lynx-low.c (struct process_info_private): New type.
13968 (lynx_add_process): New function.
13969 (lynx_create_inferior, lynx_attach): Replace calls to
13970 add_process by calls to lynx_add_process.
13971 (lynx_resume): If PTID is null, then try using
13972 current_process()->private->last_wait_event_ptid.
13974 (lynx_clear_inferiors): Delete. The contents of that function
13975 has been inlined in lynx_mourn;
13976 (lynx_wait_1): Save the ptid in the process's private data.
13977 (lynx_mourn): Free the process' private data. Replace call
13978 to lynx_clear_inferiors by call to clear_inferiors.
13980 2013-05-17 Yao Qi <yao@codesourcery.com>
13982 * i386-low.c (i386_length_and_rw_bits): Move the comment to
13985 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
13987 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
13988 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
13989 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
13990 PT_TEXT_END_ADDR guards. Update comments.
13991 (linux_target_op) <read_offsets>: Conditionally define to
13992 linux_read_offsets if the target is UCLIBC and if it defines
13993 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
13995 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
13996 Andrew Jenner <andrew@codesourcery.com>
13998 * Makefile.in (SFILES): Add linux-nios2-low.c.
13999 (clean): Add action to delete nios2-linux.c.
14000 (nios2-linux.c): New rule.
14001 * configure.srv: Add nios2*-*-linux*.
14002 * linux-nios2-low.c: New.
14004 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14006 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14008 2013-04-25 Hui Zhu <hui@codesourcery.com>
14011 * ax.c (ax_printf): Add fflush.
14013 2013-04-22 Tom Tromey <tromey@redhat.com>
14015 * Makefile.in (SFILES): Add filestuff.c.
14016 (OBS): Add filestuff.o.
14017 (filestuff.o): New target.
14018 * config.in, configure: Rebuild.
14019 * configure.ac: Check for fdwalk, pipe2.
14021 2013-04-17 Pedro Alves <palves@redhat.com>
14023 * configure.ac (USE_THREAD_DB): Delete variable.
14024 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14025 Don't AC_SUBST USE_THREAD_DB.
14026 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14027 * config.in, configure: Regenerate.
14029 2013-04-16 Pedro Alves <palves@redhat.com>
14031 * linux-low.h (struct lwp_info) <thread_known>: Move under
14032 the USE_THREAD_DB #ifdef.
14034 2013-04-16 Pedro Alves <palves@redhat.com>
14036 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14037 (linux-low.o): Delete rule.
14038 * linux-low.h: Always include "gdb_thread_db.h" instead of
14039 conditionally including thread_db.h.
14040 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14043 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14045 * Makefile.in (install-only): Fix make install regression.
14047 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14049 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14050 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14052 * gdbserver.1: Remove.
14054 2013-03-22 Pedro Alves <palves@redhat.com>
14056 * linux-low.c (handle_extended_wait): Don't call
14057 linux_enable_event_reporting.
14059 2013-03-15 Tony Theodore <tonyt@logyst.com>
14062 * Makefile.in (SHELL): Use @SHELL@.
14064 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14066 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14069 2013-03-13 Joel Brobecker <brobecker@adacore.com>
14071 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14072 Remove extraneous NULL element.
14074 2013-03-13 Yao Qi <yao@codesourcery.com>
14076 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14077 'V' block in trace frame.
14079 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14081 * target.h (struct target_ops): Add btrace ops.
14082 (target_supports_btrace): New macro.
14083 (target_enable_btrace): New macro.
14084 (target_disable_btrace): New macro.
14085 (target_read_btrace): New macro.
14086 * gdbthread.h (struct thread_info): Add btrace field.
14087 * server.c: Include btrace-common.h.
14088 (handle_btrace_general_set): New function.
14089 (handle_btrace_enable): New function.
14090 (handle_btrace_disable): New function.
14091 (handle_general_set): Call handle_btrace_general_set.
14092 (handle_qxfer_btrace): New function.
14093 (struct qxfer qxfer_packets[]): Add btrace entry.
14094 * inferiors.c (remove_thread): Disable btrace.
14095 * linux-low: Include linux-btrace.h.
14096 (linux_low_enable_btrace): New function.
14097 (linux_low_read_btrace): New function.
14098 (linux_target_ops): Add btrace ops.
14099 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14100 Add srv_linux_btrace=yes.
14101 (x86_64-*-linux*): Add linux-btrace.o.
14102 Add srv_linux_btrace=yes.
14103 * configure.ac: Define HAVE_LINUX_BTRACE.
14104 * config.in: Regenerated.
14105 * configure: Regenerated.
14107 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14109 * server.c (handle_qxfer): Preserve error message if -3 is
14111 (qxfer): Document the -3 return value.
14113 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14115 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14116 (linux_btrace_h): New variable.
14117 (linux-btrace.o): New rule.
14119 2013-03-08 Stan Shebs <stan@codesourcery.com>
14120 Hafiz Abid Qadeer <abidh@codesourcery.com>
14122 * tracepoint.c (trace_buffer_size): New global.
14123 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14124 (init_trace_buffer): Change to one-argument function. Allocate
14125 trace buffer memory.
14126 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14127 handle QTBuffer:size packet.
14128 (cmd_bigqtbuffer_size): New function.
14129 (initialize_tracepoint): Call init_trace_buffer with
14130 DEFAULT_TRACE_BUFFER_SIZE.
14131 * server.c (handle_query): Add QTBuffer:size in the
14134 2013-03-07 Yao Qi <yao@codesourcery.com>
14136 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14137 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14139 (cmd_qtsp): Adjust condition. Do post increment.
14140 Set cur_action and cur_step_action back to 0.
14142 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14145 * linux-low.c (linux_write_memory): Return early success if LEN is
14148 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
14150 * configure.srv: Add x86_64-*-cygwin* as target.
14152 2013-02-28 Tom Tromey <tromey@redhat.com>
14154 * configure.ac: Invoke AC_SYS_LARGEFILE.
14155 * configure, config.in: Rebuild.
14157 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
14159 * win32-low.c: Throughout, fix format strings and casts of
14160 printf-like functions to avoid type related warnings on all
14162 (get_child_debug_event): Print dwDebugEventCode as hex since
14163 that's how it's usually documented.
14165 2013-02-28 Yao Qi <yao@codesourcery.com>
14167 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14170 2013-02-27 Jiong Wang <jiwang@tilera.com>
14172 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14173 (reg-tilegx32.c): New rule.
14174 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14175 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14176 different register info initializer according to elf class.
14177 (init_registers_tilgx32): New function. The tilegx32 register info
14179 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14180 (tile_store_gregset): Likewise.
14182 2013-02-27 Yao Qi <yao@codesourcery.com>
14184 * server.c (process_point_options): Print debug message when
14185 debug_threads is true.
14187 2013-02-26 Yao Qi <yao@codesourcery.com>
14189 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14191 2013-02-19 Pedro Alves <palves@redhat.com>
14192 Kai Tietz <ktietz@redhat.com>
14196 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14197 instead of strtoul to extract address from packet.
14198 (process_serial_event) <'z'>: Likewise.
14200 2013-02-18 Yao Qi <yao@codesourcery.com>
14202 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14204 2013-02-14 Pedro Alves <palves@redhat.com>
14208 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14209 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14211 2013-02-14 Pedro Alves <palves@redhat.com>
14213 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14215 2013-02-14 Pedro Alves <palves@redhat.com>
14217 * tracepoint.c (save_string): Delete.
14218 (add_tracepoint_action): Use savestring instead of save_string.
14220 2013-02-12 Pedro Alves <palves@redhat.com>
14222 * linux-xtensa-low.c: Ditto.
14223 * xtensa-xtregs.c: Ditto.
14225 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14227 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14230 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14232 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14233 aarch64_num_wp_regs and aarch64_num_bp_regs to
14234 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14236 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14238 * linux-aarch64-low.c (ps_get_thread_area): Replace
14239 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14241 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14242 Marcus Shawcroft <marcus.shawcroft@arm.com>
14243 Nigel Stephens <nigel.stephens@arm.com>
14244 Yufeng Zhang <yufeng.zhang@arm.com>
14246 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14247 (aarch64.c, aarch64-without-fpu.c): New targets.
14248 * configure.srv (aarch64*-*-linux*): New.
14249 * linux-aarch64-low.c: New file.
14251 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14253 * linux-low.c (handle_extended_wait, linux_create_inferior)
14254 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14255 (dequeue_one_deferred_signal, linux_resume_one_thread)
14256 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14257 (linux_tracefork_grandchild, linux_test_for_tracefork)
14258 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14259 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14260 where the argument is 0.
14262 2013-01-25 Yao Qi <yao@codesourcery.com>
14264 * event-loop.c: Include "queue.h".
14265 (gdb_event_p): New typedef.
14266 (struct gdb_event) <next_event>: Remove.
14267 (event_queue): Change to QUEUE(gdb_event_p).
14268 (async_queue_event): Remove.
14269 (gdb_event_xfree): New.
14270 (initialize_event_loop): New.
14271 (process_event): Use API from QUEUE.
14272 (wait_for_event): Likewise.
14273 * server.c (main): Call initialize_event_loop.
14274 * server.h (initialize_event_loop): Declare.
14276 2013-01-18 Yao Qi <yao@codesourcery.com>
14278 * ax.h (struct eval_agent_expr_context): New.
14279 (gdb_eval_agent_expr): Update declaration.
14280 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14281 TFRAME. Add new argument CTX.
14282 * server.h (struct eval_agent_expr_context): Declare.
14283 (agent_mem_read, agent_tsv_read): Update declaration.
14284 (agent_mem_read_string): Likewise.
14285 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14286 (add_traceframe_block): Add new argument TPOINT.
14287 Increase TPOINT->traceframe_usage.
14288 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14289 eval_tracepoint_agent_expr.
14290 (condition_true_at_tracepoint): Likewise.
14291 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14292 (agent_mem_read_string, agent_tsv_read): Likewise.
14294 2013-01-16 Yao Qi <yao@codesourcery.com>
14296 * linux-low.c (linux_resume_one_lwp): Don't check
14297 'lwp->bp_reinsert != 0'.
14299 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14300 Pedro Alves <palves@redhat.com>
14302 * lynx-low.c (ptrace_request_to_str): Define a temporary
14303 macro and use it to simplify this function's implementation.
14305 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14307 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14310 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14312 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14314 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14316 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14318 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14320 * lynx-low.c (lynx_resume): Use the resume_info parameter
14321 to determine the ptid for the lynx_ptrace call, unless
14322 it is equal to minus_one_ptid, in which case we use the
14323 ptid of the current_inferior.
14324 (lynx_wait_1): After having received a thread create/exit
14325 event, resume the inferior's execution using the signaling
14326 thread's ptid, rather than the old ptid.
14328 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14330 * lynx-low.c (lynx_resume): Delete variable ret.
14332 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14334 * gdbreplay.c (gdbreplay_version): Update copyright year.
14335 * server.c (gdbserver_version): Likewise.
14337 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14339 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14342 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14344 * lynx-low.c (ptrace_request_to_str): Add handling for
14345 PTRACE_GETTRACESIG.
14347 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14349 * lynx-low.c (lynx_attach): Delete variable new_process.
14351 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14353 * lynx-low.c (lynx_create_inferior): Delete variable
14356 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14358 * lynx-low.c (ptrace_request_to_str): Do not handle
14359 PTRACE_GETTHREADLIST if this macro does not exist.
14361 2012-12-15 Yao Qi <yao@codesourcery.com>
14363 * Makefile.in (OBS): Add notif.o.
14364 * notif.c, notif.h: New.
14365 * server.c: Include "notif.h".
14366 (struct vstop_notif) <next>: Remove.
14368 (queue_stop_reply): Update.
14369 (push_event, send_next_stop_reply): Remove.
14370 (discard_queued_stop_replies): Update.
14371 (notif_stop): New variable.
14372 (handle_v_stopped): Remove.
14373 (handle_v_requests): Don't call handle_v_stopped. Call
14374 handle_ack_notif instead.
14375 (queue_stop_reply_callback): Call notif_event_enque instead
14376 of queue_stop_reply.
14377 (handle_status): Don't call send_next_stop_reply, call
14378 notif_write_event instead.
14379 (kill_inferior_callback): Likewise.
14380 (detach_or_kill_inferior_callback): Likewise.
14381 (main): Call initialize_notif.
14382 (process_serial_event): Call QUEUE_is_empty.
14383 (handle_target_event): Call notif_push instead of push event.
14384 * server.h (push_event): Remove declaration.
14386 2012-12-10 Tom Tromey <tromey@redhat.com>
14388 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14389 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14392 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14393 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14394 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14395 (amd64-linux-ipa.o, ax.o): Rewrite.
14396 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14397 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14398 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14399 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14400 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14401 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14402 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14403 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14404 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14405 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14406 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14407 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14408 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14409 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14410 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14411 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14412 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14413 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14414 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14415 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14416 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14417 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14418 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14419 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14420 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14421 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14422 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14423 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14424 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14425 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14426 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14427 (reg-tilegx.o): Remove.
14428 (all_object_files): New macro.
14429 Include .deps files.
14430 * aclocal.m4, configure: Rebuild.
14431 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14432 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14433 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14435 2012-12-05 Tom Tromey <tromey@redhat.com>
14438 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14440 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14442 * configure.ac: Check for linux/perf_event.h.
14443 * config.in: Regenerated.
14444 * configure: Regenerated.
14446 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14448 * hostio.c (handle_readlink): Decrease buffer size
14449 parameter passed to readlink by one byte.
14451 2012-11-26 Yao Qi <yao@codesourcery.com>
14453 * configure.ac (build_warnings): Append '-Wempty-body'.
14454 * configure: Regenerated.
14455 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14458 2012-11-15 Pierre Muller <muller@sourceware.org>
14460 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14461 * config.in: Regenerate.
14462 * configure: Regenerate.
14463 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14464 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14465 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14466 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14468 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14469 instead of <sys/wait.h> header.
14470 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14472 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
14474 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14475 (various make rules): Remove -DGDBSERVER
14477 2012-11-09 Yao Qi <yao@codesourcery.com>
14479 * spu-low.c (current_ptid): Move it to ..
14480 * gdbthread.h: ... here. New.
14481 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14482 * server.c (myresume, process_serial_event): Likewise.
14483 * thread-db.c (thread_db_find_new_threads): Likewise.
14484 * tracepoint.c (run_inferior_command): Likewise.
14486 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
14488 * server.c (handle_search_memory_1): Include access length in
14491 2012-09-05 Michael Brandt <michael.brandt@axis.com>
14493 * linux-crisv32-low.c: Fix compile errors.
14495 2012-09-04 Yao Qi <yao@codesourcery.com>
14497 * tracepoint.c (cmd_qtsv): Adjust debug message.
14498 Don't check CUR_TPOINT.
14500 2012-08-28 Yao Qi <yao@codesourcery.com>
14502 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14503 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14504 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14505 Remove declarations of xmalloc, xreallloc, xstrdup and
14507 * Makefile.in (libiberty_h): New.
14508 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14509 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14511 2012-08-23 Yao Qi <yao@codesourcery.com>
14513 * server.h: Remove declaration of 'xsnprintf'.
14515 2012-08-22 Keith Seitz <keiths@redhat.com>
14517 * server.h: Include build-gnulib-gbserver/config.h.
14518 * gdbreplay.c: Likewise.
14520 2012-08-08 Doug Evans <dje@google.com>
14522 * Makefile.in (SFILES): Add gdb_vecs.c.
14523 (OBS): Add gdb_vecs.o.
14524 (gdb_vecs_h, host_defs_h): New variables.
14525 (thread-db.o): Add $(gdb_vecs_h) dependency.
14526 (gdb_vecs.o): New rule.
14527 * thread-db.c: #include "gdb_vecs.h".
14528 (thread_db_load_search): Use a vector to iterate over path elements.
14529 Handle text appearing after "$pdir".
14531 * configure.ac: Add check for strstr.
14532 * config.in: Regenerate.
14533 * configure: Regenerate.
14535 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14537 * hostio.c (handle_pread): If pread fails, fall back to attempting
14539 (handle_pwrite): Likewise for pwrite.
14541 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14543 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14544 between unsupported TYPE and unimplementable ADDR/LEN combination.
14545 (arm_insert_point): Act on new return value.
14547 2012-07-31 Pedro Alves <palves@redhat.com>
14549 * server.c (process_point_options): Only skip tokens if we find
14550 one that is unrecognized. Don't treat 'X' specially while
14551 skipping unrecognized tokens.
14553 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14555 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14556 to 4-byte-align HW breakpoint addresses for Thumb.
14558 2012-07-27 Yao Qi <yao@codesourcery.com>
14562 * server.h: Declare gdb_agent_about_to_close.
14563 * target.c (kill_inferior): Include "agent.h".
14564 New. Send command 'kill'.
14565 * target.h (kill_inferior): Removed macro.
14566 * tracepoint.c (gdb_agent_about_to_close): New.
14567 (gdb_agent_helper_thread): Handle command 'close'.
14568 Wait endlessly until the inferior stops.
14569 Install gdb_agent_remove_socket to atexit hook.
14570 (agent_socket_name): New static variable.
14571 (gdb_agent_socket_init): Replace local variable 'name' with
14572 'agent_socket_name'.
14573 (gdb_agent_remove_socket): New.
14575 2012-07-27 Yao Qi <yao@codesourcery.com>
14577 * server.c (process_point_options): Stop at 'X' when parsing.
14579 2012-07-19 Michael Eager <eager@eagercon.com>
14581 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
14583 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14584 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14585 hardware breakpoint.
14587 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14589 * gdbserver/linux-low.c (initialize_low): Call
14590 linux_ptrace_init_warnings.
14592 2012-07-02 Doug Evans <dje@google.com>
14594 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14597 2012-07-02 Stan Shebs <stan@codesourcery.com>
14599 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14600 (ax.o): Add it to build rule.
14602 (OBS): Add format.o.
14603 (IPA_OBS): Add format.o.
14604 * server.c (handle_query): Claim support for breakpoint commands.
14605 (process_point_options): Add command case.
14606 (process_serial_event): Leave running if there are printfs in
14608 * mem-break.h (any_persistent_commands): Declare.
14609 (add_breakpoint_commands): Declare.
14610 (gdb_no_commands_at_breakpoint): Declare.
14611 (run_breakpoint_commands): Declare.
14612 * mem-break.c (struct point_command_list): New struct.
14613 (struct breakpoint): New field command_list.
14614 (any_persistent_commands): New function.
14615 (add_commands_to_breakpoint): New function.
14616 (add_breakpoint_commands): New function.
14617 (gdb_no_commands_at_breakpoint): New function.
14618 (run_breakpoint_commands): New function.
14619 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14621 * ax.c: Include format.h.
14622 (ax_printf): New function.
14623 (gdb_eval_agent_expr): Add printf opcode.
14625 2012-06-13 Yao Qi <yao@codesourcery.com>
14627 * server.c (start_inferior): Remove duplicated writes to fields
14628 'last_resume_kind' and 'last_status' of 'current_inferior'.
14630 2012-06-12 Yao Qi <yao@codesourcery.com>
14631 Pedro Alves <palves@redhat.com>
14633 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14635 * server.c (handle_v_cont): Extend comment.
14637 2012-06-11 Yao Qi <yao@codesourcery.com>
14639 * linux-low.c (linux_attach): Add 'static'.
14641 2012-06-06 Yao Qi <yao@codesourcery.com>
14643 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14645 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14647 Fix gcc -flto compilation warning.
14648 * server.c (main): Make variable multi_mode and attach volatile.
14650 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14652 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14653 if the platform doesn't know about it.
14655 2012-05-30 Jeff Kenton <jkenton@tilera.com>
14657 * Makefile.in (SFILES): Add linux-tile-low.c.
14658 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14659 * configure.srv: Handle tilegx-*-linux*.
14660 * linux-tile-low.c: New file.
14662 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14664 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14666 2012-05-24 Pedro Alves <palves@redhat.com>
14670 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
14672 2012-05-24 Pedro Alves <palves@redhat.com>
14676 Replace target_signal with gdb_signal throughout.
14678 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14680 * linux-low.c (linux_store_registers): Avoid the copying sequence
14681 when no data has been retrieved by ptrace.
14683 2012-05-22 Will Deacon <will.deacon@arm.com>
14685 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14686 Include asm/ptrace.h.
14687 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14690 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14692 * linux-low.c (linux_store_registers): Don't re-retrieve data
14693 with ptrace that has already been obtained from /proc. Always
14694 copy any data retrieved with ptrace to the buffer supplied.
14696 2012-05-11 Yao Qi <yao@codesourcery.com>
14697 Pedro Alves <palves@redhat.com>
14699 * linux-low.c (enum stopping_threads_kind): New.
14700 (stopping_threads): Change type to `enum stopping_threads_kind'.
14701 (handle_extended_wait): If stopping and suspending threads, leave
14702 the new_lwp suspended too.
14703 (linux_wait_for_event): Adjust.
14704 (stop_all_lwps): Set `stopping_threads' to
14705 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14706 whether we're suspending threads or just stopping them. Assert no
14709 2012-04-29 Yao Qi <yao@codesourcery.com>
14711 * server.h: Move some code to ...
14712 * gdbthread.h: ... here. New.
14713 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14714 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14715 (nto-low.o, win32-low.o): Likewise.
14716 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14717 * regcache.c, remote-utils.c, server.c: Likewise.
14718 * target.c, tracepoint.c, win32-low.c: Likewise.
14720 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14722 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14723 (PTRACE_ARG4_TYPE): Likewise.
14724 (PTRACE_XFER_TYPE): Likewise.
14725 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14726 ptrace to PTRACE_ARG3_TYPE.
14727 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14728 (PTRACE_ARG4_TYPE): Likewise.
14729 (PTRACE_XFER_TYPE): Likewise.
14730 (linux_detach_one_lwp): Cast fourth argument of
14731 ptrace to long then PTRACE_ARG4_TYPE.
14732 (regsets_fetch_inferior_registers): Cast third argument of
14733 ptrace to long then PTRACE_ARG3_TYPE.
14734 (regsets_store_inferior_registers): Likewise.
14736 2012-04-20 Pedro Alves <palves@redhat.com>
14738 * configure: Regenerate.
14740 2012-04-19 Pedro Alves <palves@redhat.com>
14742 * Makefile.in (GNULIB_BUILDDIR): New.
14743 (LIBGNU, INCGNU, GNULIB_H): Adjust.
14744 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14745 (all, install-only, uninstall, clean-info, all-lib, clean): No
14746 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14747 (maintainer-clean realclean distclean): Use subdir_do.
14749 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
14750 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
14751 * acinclude.m4: Include acx_configure_dir.m4.
14752 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14753 calls. Call AC_PROG_RANLIB. Configure gnulib using
14756 (GNULIB_STDINT_H): Adjust.
14757 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14758 * gdbreplay.c: Include build-gnulib/config.h.
14759 * server.h: Likewise.
14760 * aclocal.m4: Regenerate.
14761 * config.in: Regenerate.
14762 * configure: Regenerate.
14764 2012-04-19 Pedro Alves <palves@redhat.com>
14766 * Makefile.in (LIBGNU, INCGNU): Adjust.
14767 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14768 (all, install-only, uninstall, clean-info, all-lib, clean)
14769 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14770 * configure.ac: Adjust AC_OUTPUT output.
14771 * aclocal.m4: Regenerate.
14772 * configure: Regenerate.
14774 2012-04-19 Pedro Alves <palves@redhat.com>
14776 * Makefile.in (generated_files): New.
14777 (server_h): Remove the explicit dependency on config.h, and depend
14778 on $generated_files.
14780 2012-04-19 Pedro Alves <palves@redhat.com>
14782 * Makefile.in (INCGNU): Add -Ignulib.
14784 2012-04-19 Pedro Alves <palves@redhat.com>
14786 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14787 (INCGNU): ... this, and spell out -I here.
14788 (GNULIB_LIB): Rename to ...
14789 (LIBGNU): ... this.
14790 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14792 2012-04-19 Pedro Alves <palves@redhat.com>
14794 * config.in: Regenerate.
14796 2012-04-19 Pedro Alves <palves@redhat.com>
14798 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14799 * server.h (memmem): Remove declaration.
14800 * config.in: Regenerate.
14801 * configure: Regenerate.
14803 2012-04-19 Yao Qi <yao@codesourcery.com>
14805 * Makefile.in (SFILES): Add common/vec.c.
14809 2012-04-19 Yao Qi <yao@codesourcery.com>
14811 * remote-utils.c (prepare_resume_reply): Replace with macro
14812 target_core_of_thread.
14813 * server.c (handle_qxfer_threads_proper): Likewise.
14814 * target.h (traget_core_of_thread): New macro.
14816 2012-04-18 Pedro Alves <palves@redhat.com>
14818 * aclocal.m4: Regenerate.
14819 * configure: Regenerate.
14821 2012-04-16 Yao Qi <yao@codesourcery.com>
14823 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14824 duplicated on address.
14826 2012-04-16 Yao Qi <yao@codesourcery.com>
14828 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14829 (struct tracepoint_action_ops) <send>: New field.
14830 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14831 (agent_expr_send, x_tracepoint_action_send): New.
14832 (l_tracepoint_action_send): New.
14833 (cmd_qtdp): Download and install tracepoint
14834 according to `use_agent'.
14835 (run_inferior_command): Add one more parameter `len'.
14837 (tracepoint_send_agent): New.
14838 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14840 2012-04-16 Yao Qi <yao@codesourcery.com>
14842 * tracepoint.c (download_tracepoints): Moved to ...
14843 (cmd_qtstart): ... here.
14845 2012-04-14 Yao Qi <yao@codesourcery.com>
14847 * tracepoint.c: Include inttypes.h.
14848 (struct collect_memory_action): Use sized types.
14849 (struct tracepoint): Likewise.
14850 (cmd_qtdp, stop_tracing): Update print specifiers.
14851 (cmd_qtp, response_tracepoint): Likewise.
14852 (collect_data_at_tracepoint): Likewise.
14853 (collect_data_at_step): Likewise.
14855 2012-04-14 Yao Qi <yao@codesourcery.com>
14857 Import gnulib module inttypes.
14858 * aclocal.m4, config.in, configure: Regenerated.
14860 2012-04-14 Yao Qi <yao@codesourcery.com>
14862 * Makefile.in (maintainer-clean, realclean, distclean): Remove
14863 Makefile and config.status at last.
14865 2012-04-13 Yao Qi <yao@codesourcery.com>
14867 * tracepoint.c: Include stdint.h unconditionally.
14869 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14871 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
14872 on BFD_HAVE_SYS_PROCFS_TYPE.
14873 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
14874 * configure: Regenerate.
14875 * config.in: Likewise.
14877 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
14879 * Makefile.in (clean): Also remove x32.c x32-linux.c
14880 x32-avx.c x32-avx-linux.c.
14881 (x32.o): New target.
14883 (x32-linux.o): Likewise.
14884 (x32-linux.c): Likewise.
14885 (x32-avx.o): Likewise.
14886 (x32-avx.c): Likewise.
14887 (x32-avx-linux.o): Likewise.
14888 (x32-avx-linux.c): Likewise.
14890 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
14891 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
14892 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
14893 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
14894 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
14895 i386/x32-avx-linux.xml.
14897 * linux-x86-low.c (init_registers_x32_linux): New prototype.
14898 (init_registers_x32_avx_linux): Likwise.
14899 (x86_linux_update_xmltarget): Call init_registers_x32_linux
14900 or init_registers_x32_avx_linux if linux_is_elf64 is false.
14902 2012-04-13 Pedro Alves <palves@redhat.com>
14904 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
14905 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
14906 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
14907 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
14910 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14912 * linux-x86-low.c (compat_x32_clock_t): New.
14913 (compat_x32_siginfo_t): Likewise.
14914 (compat_x32_siginfo_from_siginfo): Likewise.
14915 (siginfo_from_compat_x32_siginfo): Likewise.
14916 (linux_is_elf64): Likewise.
14917 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
14918 and siginfo_from_compat_x32_siginfo for x32.
14919 (x86_arch_setup): Set linux_is_elf64.
14921 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14924 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
14926 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
14927 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
14928 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
14929 compatible with process.
14931 2012-04-12 Yao Qi <yao@codesourcery.com>
14933 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
14934 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
14935 (install-only, install-info, clean): Handle sub dir gnulib.
14936 (all-lib, am--refresh): New targets.
14937 (memmem.o): Remove target.
14938 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
14939 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
14940 (AC_REPLACE_FUNCS): Remove memmem.
14941 Invoke gl_INIT and AM_INIT_AUTOMAKE.
14942 (AC_OUTPUT): Generate Makefile in gnulib/.
14943 * aclocal.m4, config.in, configure: Regenerated.
14945 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
14947 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
14949 2012-04-05 Pedro Alves <palves@redhat.com>
14951 -Werror=strict-aliasing
14953 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
14956 2012-04-04 Pedro Alves <palves@redhat.com>
14958 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14959 (sparc_store_gregset_from_stack, sparc_store_gregset)
14960 (sparc_breakpoint_at): Fix formatting.
14962 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14964 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
14966 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
14967 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
14968 * config.in: Regenerate.
14969 * configure: Likewise.
14971 2012-03-29 Pedro Alves <palves@redhat.com>
14973 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
14974 Correct ptrace arguments.
14976 2012-03-28 Pedro Alves <palves@redhat.com>
14978 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
14979 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
14980 (IA64_FR1_REGNUM): New defines.
14981 (ia64_fetch_register): New.
14982 (the_low_target): Install it.
14983 * linux-low.h (struct linux_target_ops) <fetch_register>: New
14985 * linux-low.c (linux_fetch_registers): Try the
14986 the_low_target.fetch_register hook first.
14988 * linux-arm-low.c (the_low_target): Adjust.
14989 * linux-bfin-low.c (the_low_target): Adjust.
14990 * linux-cris-low.c (the_low_target): Adjust.
14991 * linux-crisv32-low.c (the_low_target): Adjust.
14992 * linux-m32r-low.c (the_low_target): Adjust.
14993 * linux-m68k-low.c (the_low_target): Adjust.
14994 * linux-mips-low.c (the_low_target): Adjust.
14995 * linux-ppc-low.c (the_low_target): Adjust.
14996 * linux-s390-low.c (the_low_target): Adjust.
14997 * linux-sh-low.c (the_low_target): Adjust.
14998 * linux-sparc-low.c (the_low_target): Adjust.
14999 * linux-tic6x-low.c (the_low_target): Adjust.
15000 * linux-x86-low.c (the_low_target): Adjust.
15001 * linux-xtensa-low.c (the_low_target): Adjust.
15003 2012-03-26 Pedro Alves <palves@redhat.com>
15005 * server.c (handle_qxfer_libraries): Don't bail early if
15006 the_target->qxfer_libraries_svr4 is not NULL.
15008 2012-03-26 Pedro Alves <palves@redhat.com>
15010 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15012 2012-03-23 Pedro Alves <palves@redhat.com>
15014 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15015 "library-list-svr4" element's start tag when the the DSO list is
15018 2012-03-23 Pedro Alves <palves@redhat.com>
15020 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15021 a variable whose type size is the same as the inferior's pointer
15024 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15026 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15028 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15029 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15030 * linux-low.h: Include <signal.h>.
15031 (struct siginfo): Remove forward declaration.
15032 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15035 2012-03-21 Mike Frysinger <vapier@gentoo.org>
15037 * .gitignore: Ignore more files.
15039 2012-03-19 Pedro Alves <palves@redhat.com>
15040 Jan Kratochvil <jan.kratochvil@redhat.com>
15042 * server.c (cont_thread, general_thread): Add describing comments.
15043 (start_inferior): Clear `cont_thread'.
15044 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15047 2012-03-15 Yao Qi <yao@codesourcery.com>
15049 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15051 (cmd_qtdp): ... here.
15053 2012-03-15 Yao Qi <yao@codesourcery.com>
15055 * tracepoint.c (struct tracepoint_action_ops): New.
15056 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15057 (m_tracepoint_action_download): New.
15058 (r_tracepoint_action_download): New.
15059 (x_tracepoint_action_download): New.
15060 (l_tracepoint_action_download): New.
15061 (add_tracepoint_action): Install `action->ops' according type.
15062 (download_tracepoint_1): Move code `download' function pointer
15063 of various tracepoint_action_ops.
15065 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15067 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15068 linux_ptrace_attach_warnings.
15070 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15072 * Makefile.in (linux-ptrace.o): New.
15073 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15074 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15075 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15076 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15077 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15079 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15081 2012-03-08 Yao Qi <yao@codesourcery.com>
15082 Pedro Alves <palves@redhat.com>
15084 Fix PR server/13392.
15085 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15086 offset of JMP insn.
15087 * tracepoint.c (remove_tracepoint): New.
15088 (cmd_qtdp): Call remove_tracepoint when failed to install.
15090 2012-03-07 Pedro Alves <palves@redhat.com>
15092 * linux-low.c (get_detach_signal): New.
15093 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15094 Pass on pending signals to PTRACE_DETACH. Check the result of the
15096 * server.c (program_signals, program_signals_p): New.
15097 (handle_general_set): Handle QProgramSignals.
15098 * server.h (program_signals, program_signals_p): Declare.
15100 2012-03-05 Pedro Alves <palves@redhat.com>
15101 Jan Kratochvil <jan.kratochvil@redhat.com>
15103 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15106 2012-03-03 Yao Qi <yao@codesourcery.com>
15108 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15109 agent_look_up_symbols.
15111 2012-03-03 Yao Qi <yao@codesourcery.com>
15113 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15114 (linux-x86-low.o): Likewise.
15115 * server.h: Remove in_process_agent_loaded.
15116 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15120 2012-03-03 Yao Qi <yao@codesourcery.com>
15122 * tracepoint.c (gdb_agent_capability): New global.
15123 (in_process_agent_loaded_ust): Renamed to
15124 `in_process_agent_supports_ust'.
15126 (in_process_agent_supports_ust): Call agent_capability_check.
15127 (clear_installed_tracepoints): Assert that agent supports
15130 2012-03-03 Yao Qi <yao@codesourcery.com>
15132 * linux-low.c (linux_supports_agent): New.
15133 (linux_target_ops): Initialize field `supports_agent' with
15134 linux_supports_agent.
15135 * target.h (struct target_ops) <supports_agent>: New.
15136 (target_supports_agent): New macro.
15137 * server.c (handle_general_set): Handle packet 'QAgent'.
15138 (handle_query): Send `QAgent+'.
15139 * Makefile.in (server.o): Depends on agent.h.
15141 2012-03-03 Yao Qi <yao@codesourcery.com>
15143 * Makefile.in (OBS): Add agent.o.
15144 Add new rule for agent.o.
15145 Track dependence of tracepoint.c on agent.h.
15146 * tracepoint.c (run_inferior_command_1):
15147 (run_inferior_command): Call agent_run_command.
15148 (gdb_ust_connect_sync_socket): Deleted. Move it to
15150 (resume_thread, stop_thread): Likewise.
15151 (gdb_ust_socket_init): Renamed to ...
15152 (gdb_agent_socket_init): ... New.
15153 (gdb_ust_thread): Renamed to ...
15154 (gdb_agent_helper_thread): ... New.
15155 (gdb_ust_init): Move some code to ...
15156 (gdb_agent_init): ... here. New.
15157 [HAVE_UST]: Call gdb_ust_init.
15158 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15159 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15160 * config.in, configure: Regenerated.
15162 2012-03-02 Pedro Alves <palves@redhat.com>
15164 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15165 * linux-low.c (struct simple_pid_list): New.
15166 (stopped_pids): New a struct simple_pid_list pointer.
15167 (add_to_pid_list, pull_pid_from_list): New.
15168 (handle_extended_wait): Don't assume the first signal new children
15169 report is SIGSTOP. Adjust call to pull_pid_from_list.
15170 (linux_wait_for_lwp): Adjust.
15172 2012-03-02 Yao Qi <yao@codesourcery.com>
15174 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15177 2012-03-02 Yao Qi <yao@codesourcery.com>
15179 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15180 `stop_pc' and `tpoint'. Update caller.
15182 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15184 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15185 * linux-low.c (use_linux_regsets): New macro.
15186 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15187 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15188 (linux_register_in_regsets): New function.
15189 (usr_fetch_inferior_registers): Skip registers covered by
15191 (usr_store_inferior_registers): Likewise.
15192 (usr_fetch_inferior_registers): New macro.
15193 (usr_store_inferior_registers): Likewise.
15194 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15195 (linux_store_registers): Likewise.
15196 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15198 (init_registers_mips64_dsp_linux): Likewise.
15199 (init_registers_mips_linux): New macro.
15200 (init_registers_mips_dsp_linux): Likewise.
15201 (mips_dsp_num_regs): Likewise.
15202 (DSP_BASE, DSP_CONTROL): New fallback macros.
15203 (mips_base_regs): New macro.
15204 (mips_regmap): Use it. Fix the size.
15205 (mips_dsp_regmap): New variable.
15206 (mips_dsp_regset_bitmap): Likewise.
15207 (mips_arch_setup): New function.
15208 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15210 (mips_cannot_store_register): Likewise.
15211 (the_low_target): Update .arch_setup, .num_regs and .regmap
15212 initializers. Add .regset_bitmap initializer.
15213 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15215 * linux-bfin-low.c (the_low_target): Likewise.
15216 * linux-cris-low.c (the_low_target): Likewise.
15217 * linux-crisv32-low.c (the_low_target): Likewise.
15218 * linux-ia64-low.c (the_low_target): Likewise.
15219 * linux-m32r-low.c (the_low_target): Likewise.
15220 * linux-m68k-low.c (the_low_target): Likewise.
15221 * linux-ppc-low.c (the_low_target): Likewise.
15222 * linux-s390-low.c (the_low_target): Likewise.
15223 * linux-sh-low.c (the_low_target): Likewise.
15224 * linux-sparc-low.c (the_low_target): Likewise.
15225 * linux-tic6x-low.c (the_low_target): Likewise.
15226 * linux-x86-low.c (the_low_target): Likewise.
15227 * linux-xtensa-low.c (the_low_target): Likewise.
15228 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15229 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15230 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15232 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15233 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15235 2012-02-29 Yao Qi <yao@codesourcery.com>
15236 Pedro Alves <palves@redhat.com>
15238 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15239 `step_over_finished' is true.
15241 2012-02-27 Pedro Alves <palves@redhat.com>
15243 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15244 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15246 2012-02-27 Pedro Alves <palves@redhat.com>
15249 * linux-low.c (pid_is_stopped): New.
15250 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15252 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15254 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15257 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15259 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15261 2012-02-24 Luis Machado <lgustavo@codesourcery>
15263 * server.c (handle_query): Advertise support for target-side
15264 breakpoint condition evaluation.
15265 (process_point_options): New function.
15266 (process_serial_event): When inserting a breakpoint, check for
15267 a target-side condition that should be evaluated.
15269 * mem-break.c: Include regcache.h and ax.h.
15270 (point_cond_list_t): New data structure.
15271 (breakpoint) <cond_list>: New field.
15272 (find_gdb_breakpoint_at): Make non-static.
15273 (delete_gdb_breakpoint_at): Clear any target-side
15275 (clear_gdb_breakpoint_conditions): New function.
15276 (add_condition_to_breakpoint): Likewise.
15277 (add_breakpoint_condition): Likewise.
15278 (gdb_condition_true_at_breakpoint): Likewise.
15279 (gdb_breakpoint_here): Return result directly instead
15280 of going through a local variable.
15282 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15283 (clear_gdb_breakpoint_conditions): Likewise.
15284 (add_breakpoint_condition): Likewise.
15285 (gdb_condition_true_at_breakpoint): Likewise.
15287 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15288 (need_step_over_p): Take target-side breakpoint condition into
15291 2012-02-24 Luis Machado <lgustavo@codesourcery>
15293 * server.h: Include tracepoint.h.
15294 (agent_mem_read, agent_get_trace_state_variable_value,
15295 agent_set_trace_state_variable_value,
15296 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15297 get_set_tsv_func_addr): New prototypes.
15299 * ax.h: New include file.
15300 * ax.c: New source file.
15302 * tracepoint.c: Include ax.h.
15303 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15304 agent_expr, eval_result_type): Move to ax.h.
15305 (parse_agent_expr): Rename to ...
15306 (gdb_parse_agent_expr): ... this, make it non-static and move
15308 (unparse_agent_expr) Rename to ...
15309 (gdb_unparse_agent_expr): ... this, make it non-static and move
15311 (eval_agent_expr): Rename to ...
15312 (eval_tracepoint_agent_expr): ... this.
15313 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15314 forward declarations.
15315 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15316 (agent_get_trace_state_variable_value): New function.
15317 (agent_set_trace_state_variable_value): New function.
15318 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15319 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15320 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15321 (condition_true_at_tracepoint): Likewise.
15322 (parse_agent_expr): Rename to ...
15323 (gdb_parse_agent_expr): ... this and move to ax.c.
15324 (unparse_agent_expr): Rename to ...
15325 (gdb_unparse_agent_expr): ... this and move to ax.c.
15326 (gdb_agent_op_name): Move to ax.c.
15327 (eval_agent_expr): Rename to ...
15328 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15330 (eval_tracepoint_agent_expr): New function.
15331 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15333 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15335 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15336 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15337 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15338 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15339 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15340 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15341 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15342 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15343 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15344 (compile_bytecodes): Remove forward declaration.
15345 (is_goto_target): Move to ax.c.
15346 (compile_bytecodes): Move to ax.c and call
15347 agent_get_trace_state_variable_value (...) and
15348 agent_set_trace_state_variable_value (...).
15350 * Makefile.in: Update ax.c and IPA dependencies.
15352 2012-02-24 Pedro Alves <palves@redhat.com>
15354 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15355 (cmd_bigqtbuffer_circular): ... this. Only handle
15356 'QTBuffer:circular:'.
15357 (handle_tracepoint_general_set): Adjust.
15359 2012-02-16 Yao Qi <yao@codesourcery.com>
15361 * inferiors.c: Move code to ...
15362 * dll.c: .... here. New.
15363 * server.h: Declare clear_dlls.
15364 * Makefile.in (SFILES): Add dll.c.
15368 2012-02-11 Yao Qi <yao@codesourcery.com>
15370 * server.c: (handle_monitor_command): Add a new parameter
15372 (handle_query): Update caller.
15374 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15376 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15377 * configure, config.in: Regenerate.
15378 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15381 2012-02-02 Pedro Alves <palves@redhat.com>
15383 Try SIGKILL first, then PTRACE_KILL.
15384 * linux-low.c (linux_kill_one_lwp): New.
15385 (linux_kill_one_lwp): Rename to ...
15386 (kill_one_lwp_callback): ... this. Use the new
15387 linux_kill_one_lwp.
15389 2012-02-02 Pedro Alves <palves@redhat.com>
15391 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15394 2012-01-27 Pedro Alves <palves@redhat.com>
15396 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15397 (elf_64_file_p): Make static.
15398 (linux_pid_exe_is_elf_64_file): New.
15399 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15400 Delete declarations.
15401 (linux_pid_exe_is_elf_64_file): Declare.
15402 * linux-x86-low.c (x86_arch_setup): Use
15403 linux_pid_exe_is_elf_64_file.
15405 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15407 * linux-low.c (linux_wait_for_event_1): Rename to ...
15408 (linux_wait_for_event): ... here and merge it with former
15409 linux_wait_for_event - new variable wait_ptid, use it.
15410 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15412 2012-01-23 Pedro Alves <palves@redhat.com>
15414 * server.c (main): Avoid yet another case of infinite loop while
15415 detaching/killing after a longjmp.
15417 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15420 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15422 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15424 * hostio.c (handle_readlink): New function.
15425 (handle_vFile): Call it to handle "vFile:readlink" packets.
15427 2012-01-20 Pedro Alves <palves@redhat.com>
15428 Ulrich Weigand <ulrich.weigand@linaro.org>
15430 * server.c (handle_v_requests): Only support vAttach and vRun to
15431 start multiple processes when in extended protocol mode.
15433 2012-01-17 Pedro Alves <palves@redhat.com>
15435 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15436 memalign plus mprotect to allocate the scratch buffer.
15438 2012-01-13 Pedro Alves <palves@redhat.com>
15440 * server.c (attach_inferior): Clear `cont_thread'.
15442 2012-01-13 Pedro Alves <palves@redhat.com>
15444 * server.c (main): Avoid infinite loop while detaching/killing
15447 2012-01-09 Doug Evans <dje@google.com>
15449 * server.c (start_inferior): Set last_ptid in --wrapper case.
15451 2012-01-06 Yao Qi <yao@codesourcery.com>
15453 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15455 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15457 2012-01-04 Yao Qi <yao@codesourcery.com>
15459 * tracepoint.c (cmd_qtdp): Print debug message
15460 for static tracepoint.
15462 2012-01-04 Yao Qi <yao@codesourcery.com>
15464 * tracepoint.c (trace_vdebug): Differentiate debug message
15465 between gdbserver and IPA.
15467 2012-01-03 Yao Qi <yao@codesourcery.com>
15469 * tracepoint.c (tracepoint_was_hit): Don't collect for
15472 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15474 * terminal.h: Reformat copyright header.
15476 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15478 * server.c (gdbserver_version): Update copyright year.
15479 * gdbreplay.c (gdbreplay_version): Likewise.
15481 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15483 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15486 2011-12-18 Hui Zhu <teawater@gmail.com>
15487 * linux-low.c (linux_create_inferior): Save return value to ret.
15489 2011-12-18 Hui Zhu <teawater@gmail.com>
15491 * linux-low.c (linux_create_inferior): Save return value to ret.
15493 2011-12-16 Doug Evans <dje@google.com>
15495 * linux-low.c (linux_create_inferior): If stdio connection,
15496 redirect stdin from /dev/null, stdout to stderr.
15497 * remote-utils.c (remote_is_stdio): New static global.
15498 (remote_connection_is_stdio): New function.
15499 (remote_prepare): Handle stdio connection.
15500 (remote_open): Ditto.
15501 (remote_close): Don't close stdin for stdio connections.
15502 (read_prim,write_prim): New functions. Replace all calls to
15503 read/write to these.
15504 * server.c (main): Watch for "-" argument. Move call to
15505 remote_prepare before start_inferior.
15506 * server.h (STDIO_CONNECTION_NAME): New macro.
15507 (remote_connection_is_stdio): Declare.
15509 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15510 in debugging output.
15512 2011-12-15 Yao Qi <yao@codesourcery.com>
15514 * tracepoint.c: Include sys/syscall.h.
15515 (gdb_ust_thread): Remove preprocessor conditional.
15517 2011-12-14 Pedro Alves <pedro@codesourcery.com>
15519 * linux-low.c (linux_detach_one_lwp): Call
15520 the_low_target.prepare_to_resume before detaching.
15522 2011-12-14 Yao Qi <yao@codesourcery.com>
15524 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15527 2011-12-14 Yao Qi <yao@codesourcery.com>
15529 * i386-low.c (i386_low_stopped_data_address): Initialize local
15530 variable `control'.
15532 2011-12-13 Pedro Alves <pedro@codesourcery.com>
15536 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15537 DR_CONTROL unless necessary. Extend comments.
15538 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15539 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15541 2011-12-13 Yao Qi <yao@codesourcery.com>
15543 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15545 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15547 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15549 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15550 Print new debug message for such case.
15552 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15554 Fix overlapping memcpy.
15555 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15556 the read_inferior_memory transfer.
15557 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15558 write_inferior_memory transfer.
15559 (set_fast_tracepoint_jump): New variable buf. Use it for the
15560 read_inferior_memory and write_inferior_memory transfers.
15561 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15562 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15563 Use it for the write_inferior_memory transfer.
15564 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15567 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15569 * linux-low.c (fetch_register, store_register): Make code
15570 consistent, fix formatting.
15572 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15574 * linux-low.c (usr_store_inferior_registers): Factor out code
15575 to handle individual registers into...
15576 (store_register): ... this new function.
15578 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15580 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15581 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15582 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15583 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15584 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15585 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15586 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15587 (srv_xmlfiles): Add new XML files.
15589 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15591 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15592 (init_registers_s390_linux32v1): Add prototype.
15593 (init_registers_s390_linux32v2): Likewise.
15594 (init_registers_s390_linux64v1): Likewise.
15595 (init_registers_s390_linux64v2): Likewise.
15596 (init_registers_s390x_linux64v1): Likewise.
15597 (init_registers_s390x_linux64v2): Likewise.
15598 (s390_num_regs): Increment to 52.
15599 (s390_regmap): Add orig_r2 register.
15600 (s390_num_regs_3264): Increment to 68.
15601 (s390_regmap_3264): Add orig_r2 register.
15602 (s390_collect_ptrace_register): Handle orig_r2 register.
15603 (s390_supply_ptrace_register): Likewise.
15604 (s390_fill_last_break): New function.
15605 (s390_store_last_break): Likewise.
15606 (s390_fill_system_call): New function.
15607 (s390_store_system_call): Likewise.
15608 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15610 (s390_check_regset): New function.
15611 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15612 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15613 Update target_regsets for available register sets.
15615 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15616 Jan Kratochvil <jan.kratochvil@redhat.com>
15618 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15619 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15621 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15622 * linux-low.h (struct process_info_private): New member r_debug.
15623 * server.c (handle_qxfer_libraries): Call
15624 the_target->qxfer_libraries_svr4.
15625 (handle_qxfer_libraries_svr4): New function.
15626 (qxfer_packets): New entry "libraries-svr4".
15627 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15628 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15629 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15630 PACKET_qXfer_libraries_svr4.
15632 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15634 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15635 PSW address/mask between 8-byte and 16-byte formats.
15636 (s390_supply_ptrace_register): Likewise.
15637 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15638 basic addressing mode bit.
15640 2011-11-24 Stan Shebs <stan@codesourcery.com>
15642 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15644 2011-11-17 Stan Shebs <stan@codesourcery.com>
15646 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15647 (tracing_start_time): New global.
15648 (tracing_stop_time): New global.
15649 (tracing_user_name): New global.
15650 (tracing_notes): New global.
15651 (tracing_stop_note): New global.
15652 (cmd_qtstart): Set traceframe_usage, start_time.
15653 (stop_tracing): Set stop_time.
15654 (cmd_qtstatus): Report additional status.
15655 (cmd_qtp): New function.
15656 (handle_tracepoint_query): Call it.
15657 (cmd_qtnotes): New function.
15658 (handle_tracepoint_general_set): Call it.
15659 (get_timestamp): Rename from tsv_get_timestamp.
15661 2011-11-14 Stan Shebs <stan@codesourcery.com>
15662 Kwok Cheung Yeung <kcy@codesourcery.com>
15664 * linux-x86-low.c (small_jump_insn): New.
15665 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15666 trampoline and error message, build a trampoline and issue a small
15667 jump instruction to it.
15668 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15669 trampoline and error message.
15670 (x86_get_min_fast_tracepoint_insn_len): New.
15671 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15672 * linux-low.h (struct linux_target_ops): Add arguments to
15673 install_fast_tracepoint_jump_pad operation, add new operation.
15674 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15676 (linux_get_min_fast_tracepoint_insn_len): New function.
15677 (linux_target_op): Add new operation.
15678 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15679 (gdb_trampoline_buffer_end): Ditto.
15680 (gdb_trampoline_buffer_error): Ditto.
15681 (struct ipa_sym_addresses): Add fields for new IPA variables.
15682 (symbol_list): Add entries for new IPA variables.
15683 (struct tracepoint): Add fields to hold the address range of the
15684 trampoline used by the tracepoint.
15685 (trampoline_buffer_head): New static variable.
15686 (trampoline_buffer_tail): Ditto.
15687 (claim_trampoline_space): New function.
15688 (have_fast_tracepoint_trampoline_buffer): New function.
15689 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15691 (install_fast_tracepoint): Ditto, also add error buffer argument.
15692 (cmd_qtminftpilen): New function.
15693 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15694 (fast_tracepoint_from_trampoline_address): New function.
15695 (fast_tracepoint_collecting): Handle trampoline as part of jump
15697 (set_trampoline_buffer_space): New function.
15698 (initialize_tracepoint): Initialize new IPA variables.
15699 * target.h (struct target_ops): Add arguments to
15700 install_fast_tracepoint_jump_pad operation, add new
15701 get_min_fast_tracepoint_insn_len operation.
15702 (target_get_min_fast_tracepoint_insn_len): New.
15703 (install_fast_tracepoint_jump_pad): Add arguments.
15704 * server.h (IPA_BUFSIZ): Define.
15705 * linux-i386-ipa.c: Include extra header files.
15706 (initialize_fast_tracepoint_trampoline_buffer): New function.
15707 (initialize_low_tracepoint): Call it.
15708 * server.h (set_trampoline_buffer_space): Declare.
15709 (claim_trampoline_space): Ditto.
15710 (have_fast_tracepoint_trampoline_buffer): Ditto.
15712 2011-11-14 Yao Qi <yao@codesourcery.com>
15714 * server.c (handle_query): Handle InstallInTrace for qSupported.
15715 * tracepoint.c (add_tracepoint): Sort list.
15716 (install_tracepoint, download_tracepoint): New.
15717 (cmd_qtdp): Call them to install and download tracepoints.
15718 (sort_tracepoints): Removed.
15719 (cmd_qtstart): Update.
15721 2011-11-14 Yao Qi <yao@codesourcery.com>
15723 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15724 * mem-break.h: Declare.
15725 * tracepoint.c (cmd_qtstart): Move some code to ...
15726 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15728 (download_tracepoints): Move some code to ...
15729 (download_tracepoint_1): ... here. New.
15731 2011-11-08 Yao Qi <yao@codesourcery.com>
15733 * remote-utils.c (relocate_instruction): A comment fix.
15735 2011-11-07 Joel Brobecker <brobecker@adacore.com>
15737 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15738 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15739 dr_status_mirror and dr_control_mirror from debug_reg_state.
15740 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15741 (i386_initial_stuff): Remove use of deleted globals.
15742 (i386_get_thread_context, i386_set_thread_context,
15743 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15744 from debug_reg_state.
15746 2011-11-05 Yao Qi <yao@codesourcery.com>
15748 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15749 address as TPOINT's.
15751 2011-11-02 Stan Shebs <stan@codesourcery.com>
15753 * tracepoint.c (agent_mem_read_string): New function.
15754 (eval_agent_expr): Call it for tracenz.
15755 * server.c (handle_query): Report support for tracenz.
15757 2011-11-02 Yao Qi <yao@codesourcery.com>
15759 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15761 2011-11-02 Yao Qi <yao@codesourcery.com>
15763 * target.h: Fix a typo in comment.
15765 2011-10-31 Pedro Alves <pedro@codesourcery.com>
15767 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15768 clobber the breakpoints' shadows with fast tracepoint jumps.
15769 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15770 * target.c (write_inferior_memory): Also pass MYADDR down to
15773 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15775 * configure.ac: Check support for personality routine.
15776 * configure: Regenerate.
15777 * config.in: Likewise.
15778 * linux-low.c: Include <sys/personality.h>.
15779 Define ADDR_NO_RANDOMIZE if necessary.
15780 (linux_create_inferior): Disable address space randomization when
15781 forking inferior, if requested.
15782 (linux_supports_disable_randomization): New function.
15783 (linux_target_ops): Install it.
15784 * server.h (disable_randomization): Declare.
15785 * server.c (disable_randomization): New global variable.
15786 (handle_general_set): Handle QDisableRandomization.
15787 (handle_query): Likewise for qSupported.
15788 (main): Support --disable-randomization and --no-disable-randomization
15789 command line arguments.
15790 * target.h (struct target_ops): Add supports_disable_randomization.
15791 (target_supports_disable_randomization): New macro.
15793 2011-09-29 Mike Frysinger <vapier@gentoo.org>
15795 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15797 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15798 [!PT_GETDSBT] (target_loadmap): New definition.
15799 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15800 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15801 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15802 and PT_GETDSBT to LINUX_LOADMAP.
15803 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15804 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15806 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15808 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15809 (arm_linux_hwbp_cap): New static variable.
15810 (arm_linux_get_hwbp_cap): Replace by ...
15811 (arm_linux_init_hwbp_cap): ... this new function.
15812 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15813 (arm_linux_get_hw_watchpoint_count): Likewise.
15814 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15815 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15816 (arm_prepare_to_resume): Use perror_with_name instead of error.
15818 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15820 * linux-arm-low.c: Include <signal.h>.
15821 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15822 (struct arm_linux_hwbp_cap): New data type.
15823 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15824 (struct arm_linux_hw_breakpoint): New data type.
15825 (MAX_BPTS, MAX_WPTS): Define.
15826 (struct arch_process_info, struct arch_lwp_info): New data types.
15827 (arm_linux_get_hwbp_cap): New function.
15828 (arm_linux_get_hw_breakpoint_count): Likewise.
15829 (arm_linux_get_hw_watchpoint_count): Likewise.
15830 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15831 (arm_hwbp_control_initialize): Likewise.
15832 (arm_hwbp_control_is_enabled): Likewise.
15833 (arm_hwbp_control_is_initialized): Likewise.
15834 (arm_hwbp_control_disable): Likewise.
15835 (arm_linux_hw_breakpoint_equal): Likewise.
15836 (arm_linux_hw_point_initialize): Likewise.
15837 (struct update_registers_data): New data structure.
15838 (update_registers_callback: New function.
15839 (arm_insert_point): Likewise.
15840 (arm_remove_point): Likewise.
15841 (arm_stopped_by_watchpoint): Likewise.
15842 (arm_stopped_data_address): Likewise.
15843 (arm_new_process): Likewise.
15844 (arm_new_thread): Likewise.
15845 (arm_prepare_to_resume): Likewise.
15846 (the_low_target): Register arm_insert_point, arm_remove_point,
15847 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15848 arm_new_thread, and arm_prepare_to_resume.
15850 2011-09-15 Stan Shebs <stan@codesourcery.com>
15852 * server.h (struct emit_ops): Add compare-goto fields.
15853 * tracepoint.c (gdb_agent_op_sizes): New table.
15854 (emit_eq_goto): New function.
15855 (emit_ne_goto): New function.
15856 (emit_lt_goto): New function.
15857 (emit_le_goto): New function.
15858 (emit_gt_goto): New function.
15859 (emit_ge_goto): New function.
15860 (is_goto_target): New function.
15861 (compile_bytecodes): Recognize special cases of compare-goto
15862 combinations and call specialized emitters for them.
15863 * linux-x86-low.c (amd64_emit_eq_goto): New function.
15864 (amd64_emit_ne_goto): New function.
15865 (amd64_emit_lt_goto): New function.
15866 (amd64_emit_le_goto): New function.
15867 (amd64_emit_gt_goto): New function.
15868 (amd64_emit_ge_goto): New function.
15869 (amd64_emit_ops): Add the new functions.
15870 (i386_emit_eq_goto): New function.
15871 (i386_emit_ne_goto): New function.
15872 (i386_emit_lt_goto): New function.
15873 (i386_emit_le_goto): New function.
15874 (i386_emit_gt_goto): New function.
15875 (i386_emit_ge_goto): New function.
15876 (i386_emit_ops): Add the new functions.
15878 2011-09-08 Stan Shebs <stan@codesourcery.com>
15880 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
15881 (i386_emit_epilogue): Restore %ebx.
15883 2011-08-31 Jie Zhang <jzhang918@gmail.com>
15885 * server.c (step_thread): Remove definition.
15886 (process_serial_event): Don't handle Hs.
15887 * server.h (step_thread): Remove declaration.
15888 * target.c (set_desired_inferior): Remove use of step_thread.
15890 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
15892 * linux-low.c: Include linux-procfs.h.
15893 (linux_attach_lwp_1): Update comments.
15894 (linux_attach): Scan for existing threads when attaching to a
15895 process that is the tgid.
15896 * Makefile.in: Update dependencies.
15898 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
15900 * configure.srv: Add linux-procfs.o dependencies.
15902 2011-08-14 Yao Qi <yao@codesourcery.com>
15904 * target.h (struct target_ops): Fix indent.
15905 * win32-low.c (win32_target_ops): Fix comment.
15907 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
15908 Yao Qi <yao@codesourcery.com>
15910 * Makefile.in (clean): Remove tic6x-*.c files.
15911 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
15912 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
15913 (tic6x-c64xp-linux.c): Likewise.
15914 * configure.srv: Add support for tic6x-*-uclinux.
15915 * linux-tic6x-low.c: New.
15916 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
15918 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
15919 Yao Qi <yao@codesourcery.com>
15921 * target.h (struct target_ops): Add read_loadmap.
15922 * linux-low.c (struct target_loadseg): New type.
15923 (struct target_loadmap): New type.
15924 (linux_read_loadmap): New function.
15925 (linux_target_ops): Add linux_read_loadmap.
15926 * server.c (handle_query): Support qXfer:fdpic:read packet.
15927 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
15930 2011-08-05 Eli Zaretskii <eliz@gnu.org>
15932 * win32-low.c: Include <stdint.h>.
15934 2011-07-22 Pedro Alves <pedro@codesourcery.com>
15936 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
15937 to the inferior here.
15938 (i386_remove_aligned_watchpoint): Ditto.
15939 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
15940 fit part of the watchpoint in the debug registers.
15941 (i386_update_inferior_debug_regs): New.
15942 (i386_low_insert_watchpoint): Work on a local mirror of the debug
15943 registers, and only update the inferior on success.
15944 (i386_low_remove_watchpoint): Ditto.
15946 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
15948 * linux-low.c (compare_ints, unique, list_threads, show_process,
15949 linux_core_of_thread): Delete.
15950 (linux_target_ops): Change linux_core_of_thread to
15951 linux_common_core_of_thread.
15952 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
15953 * utils.c (malloc_failure): Change type of argument.
15954 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
15955 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
15956 common/linux-osdata.c, common/ptid.c and common/buffer.c.
15957 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
15958 (IPA_OBJS): Add common-utils-ipa.o.
15959 (ptid_h, linux_osdata_h): New macros.
15960 (server_h): Add common/common-utils.h, common/xml-utils.h,
15961 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
15963 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
15964 ptid.o, buffer.o): New rules.
15965 (linux-low.o): Add common/linux-osdata.h as a dependency.
15966 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
15967 * configure.ac: Add AC_HEADER_DIRENT check.
15968 * config.in: Regenerate.
15969 * configure: Regenerate.
15970 * remote-utils.c (xml_escape_text): Delete.
15971 (buffer_grow, buffer_free, buffer_init, buffer_finish,
15972 buffer_xml_printf): Move to common/buffer.c.
15973 * server.c (main): Remove call to initialize_inferiors.
15974 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
15975 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
15976 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
15977 internal_error, gdb_assert, gdb_assert_fail): Delete.
15978 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
15979 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
15981 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
15982 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
15983 initialize_inferiors): Delete.
15985 2011-07-20 Pedro Alves <pedro@codesourcery.com>
15987 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
15990 2011-05-31 Pedro Alves <pedro@codesourcery.com>
15992 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
15994 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
15996 2011-05-26 Yao Qi <yao@codesourcery.com>
15998 * Makefile.in (thread-db.o): Track dependence to
15999 common/gdb_thread_db.h.
16000 * thread-db.c: include gdb_thread_db.h from right place.
16002 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16004 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16005 __FILE__ and __LINE__ to internal_error.
16007 2011-05-13 Doug Evans <dje@google.com>
16009 * thread-db.c (try_thread_db_load_from_sdir): New function.
16010 (try_thread_db_load_from_dir): New function.
16011 (thread_db_load_search): Handle $sdir, ignore $pdir.
16012 Remove trying of system directories if search of
16013 libthread-db-search-path fails, that is now done via $sdir.
16015 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16017 * server.c (handle_query): Add EnableDisableTracepoints to the list
16018 of supported features.
16019 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
16021 (cmd_qtenable_disable): New.
16022 (cmd_qtstart): Install tracepoints even if disabled.
16023 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16024 receiving a QTEnable or QTDisable packet.
16025 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16026 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16028 (gdb_probe): Skip data collection if static tracepoint is disabled.
16030 2011-05-10 Doug Evans <dje@google.com>
16032 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16034 2011-05-04 Doug Evans <dje@google.com>
16036 * linux-low.c (linux_join): Skip process lookup.
16037 * spu-low.c (spu_join): Ditto.
16038 * server.c (join_inferiors_callback): Delete.
16039 (process_serial_event): For 'D' packet (detach) call join_inferior
16042 2011-05-04 Joseph Myers <joseph@codesourcery.com>
16044 * README: Don't mention xscale*-*-linux*.
16045 * configure.srv (xscale*-*-linux*): Don't handle target.
16047 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16049 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16051 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16052 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16053 (i386_emit_void_call_2): Likewise.
16055 2011-04-26 Yao Qi <yao@codesourcery.com>
16057 * linux-low.c: Move common macros to linux-ptrace.h.
16058 Include linux-ptrace.h.
16059 * Makefile.in (linux_ptrace_h): New.
16060 (linux-low.o): Depends on linux-ptrace.h.
16062 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16064 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16065 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16066 (remote_prepare): New function with most of the TCP code from ...
16067 (remote_open): ... here. Detect PORT here unconditionally. Move also
16068 setting transport_is_reliable.
16069 * server.c (run_once): New variable.
16070 (gdbserver_usage): Document it.
16071 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16072 the first run if RUN_ONCE.
16073 * server.h (run_once, remote_prepare): New declarations.
16075 2011-04-19 Tom Tromey <tromey@redhat.com>
16077 * win32-low.c (handle_load_dll): Remove duplicate "the".
16079 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16081 Remove support for old Cygwin 1.5 versions.
16082 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16083 function to avoid warning.
16084 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16087 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16089 * gdbserver/server.h (Macro _): Define it if not available.
16091 2011-03-14 Michael Snyder <msnyder@vmware.com>
16093 * hostio.c (handle_close): Remove unnecessary null test.
16095 2011-03-10 Joel Brobecker <brobecker@adacore.com>
16097 * Makefile.in (maintainer-clean realclean distclean): Remove
16098 "make ... subdir_do" command.
16100 2011-03-10 Michael Snyder <msnyder@vmware.com>
16102 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16104 * server.c (handle_v_run): Free alloced buffer on early return.
16106 2011-03-09 Yao Qi <yao@codesourcery.com>
16109 2011-03-04 Yao Qi <yao@codesourcery.com>
16111 * Makefile.in: Remove GNU make feature --directory.
16113 2011-03-05 Yao Qi <yao@codesourcery.com>
16115 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16116 (subdir_do): New make target. Copied from gdb/Makefile.
16117 (maintainer-clean, realclean, distclean, clean): Call corresponding
16118 make targets in common/Makefile.
16120 2011-02-11 Yao Qi <yao@codesourcery.com>
16122 * configure.ac: Call AC_PROG_RANLIB.
16123 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16124 * configure: Regenerate.
16126 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16128 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16130 2011-03-06 Yao Qi <yao@codesourcery.com>
16132 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16134 2011-03-05 Yao Qi <yao@codesourcery.com>
16136 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16137 (subdir_do): New make target. Copied from gdb/Makefile.
16138 (maintainer-clean, realclean, distclean, clean): Call corresponding
16139 make targets in common/Makefile.
16141 2011-03-04 Yao Qi <yao@codesourcery.com>
16143 * Makefile.in: Remove GNU make feature --directory.
16145 2011-03-04 Michael Snyder <msnyder@vmware.com>
16147 * server.c (queue_stop_reply): Call xmalloc not malloc.
16149 2011-03-02 Michael Snyder <msnyder@vmware.com>
16151 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16153 2011-02-28 Michael Snyder <msnyder@vmware.com>
16155 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16156 (cmd_qtframe): Ditto.
16157 (cmd_qtbuffer): Ditto.
16158 (cmd_bigqtbuffer): Ditto.
16160 * utils.c (decimal2str): Initialize 'width' to nine, then
16161 don't mess with it.
16163 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16165 * hostio.c (require_data): Free *data, not data.
16167 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16169 * hostio.c (require_data): Use free, not xfree.
16171 2011-02-27 Michael Snyder <msnyder@vmware.com>
16173 * server.c (handle_query): Discard unused value.
16175 * hostio.c (require_data): Free malloc memory before returning
16178 2011-02-26 Michael Snyder <msnyder@vmware.com>
16180 * linux-low.c (list_threads): Call closedir for dirent.
16182 2011-02-27 Michael Snyder <msnyder@vmware.com>
16184 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16185 a case statement falls through.
16187 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16189 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16192 2011-02-26 Michael Snyder <msnyder@vmware.com>
16194 * utils.c (decimal2str): Eliminate dead code and dead param.
16195 (pulongest): Drop dead param from call to decimal2str.
16198 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16200 Revert the following patch (not approved yet):
16201 2011-02-21 Hui Zhu <teawater@gmail.com>
16202 * tracepoint.c (tp_printf): New function.
16203 (eval_agent_expr): Handle gdb_agent_op_printf.
16205 2011-02-21 Hui Zhu <teawater@gmail.com>
16207 * tracepoint.c (tp_printf): New function.
16208 (eval_agent_expr): Handle gdb_agent_op_printf.
16210 2011-02-18 Tom Tromey <tromey@redhat.com>
16212 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16213 (tracepoint.o): Likewise.
16214 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16215 (gdb_agent_op_names): Likewise.
16217 2011-02-18 Tom Tromey <tromey@redhat.com>
16219 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16220 gdb_agent_op_rot>: New constants.
16221 (gdb_agent_op_names): Add pick and roll.
16222 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16225 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16227 * aclocal.m4: Regenerated with aclocal-1.11.1.
16229 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16231 * server.c (handle_qxfer_traceframe_info): New.
16232 (qxfer_packets): Register "traceframe-info".
16233 (handle_query): Report support for qXfer:traceframe-info:read+.
16234 * tracepoint.c (match_blocktype): New.
16235 (traceframe_find_block_type): Rename to ...
16236 (traceframe_walk_blocks): ... this. Add callback filter argument,
16238 (traceframe_find_block_type): New, reimplemented on top of
16239 traceframe_walk_blocks.
16240 (build_traceframe_info_xml): New.
16241 (traceframe_read_info): New.
16242 * server.h (traceframe_read_info): Declare.
16244 2011-02-11 Yao Qi <yao@codesourcery.com>
16246 * configure.ac: Call AC_PROG_RANLIB.
16247 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16248 * configure: Regenerate.
16250 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16252 * server.c (gdb_read_memory): Change return semantics to allow
16254 (handle_search_memory_1): Adjust.
16255 (process_serial_event) <'m' packet>: Handle partial transfers.
16256 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16258 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16260 * regcache.c (init_register_cache): Initialize
16261 regcache->register_status.
16262 (free_register_cache): Release regcache->register_status.
16263 (regcache_cpy): Copy register_status.
16264 (registers_to_string): Print 'x's for unavailable registers.
16265 (supply_register): Mark the register's status valid or
16266 unavailable, depending on whether a buffer was passed in or not.
16267 (supply_register_zeroed): New.
16268 (supply_regblock): Mark the registers' status valid or
16269 unavailable, depending on whether a buffer was passed in or not.
16270 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16271 (struct regcache): New `register_status' field.
16272 (supply_register_zeroed): Declare.
16273 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16274 supply_register_zeroed, rather than passing a NULL buffer to
16276 * tracepoint.c (fetch_traceframe_registers): Update comment.
16278 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16280 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16283 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16285 * server.h (decode_xfer_write): Change prototype.
16286 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16287 and don't extract the annex here.
16288 * server.c (decode_xfer_read): Remove `annex' parameter,
16289 and don't extract the annex here.
16290 (decode_xfer): New.
16291 (struct qxfer): New.
16292 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16293 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16294 (handle_qxfer_statictrace): New functions, abstracted out from
16295 handle_query, and made to use the struct qxfer interface.
16296 (handle_threads_qxfer_proper): Rename to ...
16297 (handle_qxfer_threads_proper): ... this.
16298 (handle_threads_qxfer): Rename to ...
16299 (handle_qxfer_threads): ... this. Adjust.
16300 (qxfer_packets): New array.
16301 (handle_qxfer): New function.
16302 (handle_query): Use handle_qxfer.
16304 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16306 * gdbreplay.c: Shorten lines of >= 80 columns.
16307 * linux-low.c: Ditto.
16308 * linux-ppc-low.c: Ditto.
16309 * linux-s390-low.c: Ditto.
16310 * linux-sparc-low.c: Ditto.
16311 * linux-x86-low.c: Ditto.
16312 * linux-xtensa-low.c: Ditto.
16313 * mem-break.c: Ditto.
16314 * nto-low.c: Ditto.
16315 * regcache.h: Ditto.
16316 * remote-utils.c: Ditto.
16319 * thread-db.c: Ditto.
16320 * tracepoint.c: Ditto.
16322 * win32-low.h: Ditto.
16324 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16326 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16329 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16331 * server.c (gdbserver_version): Update copyright year in version
16333 * gdbreplay.c (gdbreplay_version): Ditto.
16335 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16337 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16338 * linux-bfin-low.c: New file.
16339 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16340 PT_DATA_ADDR for BFIN targets.
16341 * Makefile.in (SFILES): Add linux-bfin-low.c.
16342 (clean): Remove reg-bfin.c.
16343 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16344 * README: Mention supported Blackfin targets.
16346 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16348 * .gitignore: New file.
16350 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16352 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16354 2010-10-22 Jie Zhang <jie@codesourcery.com>
16356 * Makefile.in: Add FLAGS_TO_PASS variable.
16357 (install): Remove dependency of install-only and recursively
16358 invoke make for install-only.
16360 2010-10-04 Doug Evans <dje@google.com>
16362 * Makefile.in (uninstall): Use $(DESTDIR).
16364 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16368 * linux-x86-low.c (compat_siginfo_from_siginfo)
16369 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16370 si_code is < 0. Check for si_code == SI_TIMER before checking for
16373 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16375 * lynx-i386-low.c: New file.
16376 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16378 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16380 * lynx-low.c (ptrace_request_to_str): Remove handling for
16381 request values that have been removed in LynxOS 5.x.
16383 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16385 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16388 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16390 * configure.ac: Add --enable-inprocess-agent option.
16391 * configure: Rebuilt.
16393 2010-09-06 Yao Qi <yao@codesourcery.com>
16395 * linux-low.c (linux_kill): Remove unused variable.
16396 (linux_stabilize_threads): Likewise.
16397 * server.c (start_inferior): Likewise.
16398 (queue_stop_reply_callback): Likewise.
16399 * tracepoint.c (do_action_at_tracepoint): Likewise.
16401 2010-09-06 Yao Qi <yao@codesourcery.com>
16403 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16406 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16408 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16410 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16412 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16415 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16417 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16418 gdbserver/lynx-ppc-low.c: New files.
16419 * Makefile.in (lynx_low_h): New variable.
16420 (lynx-low.o, lynx-ppc-low.o): New rules.
16421 * configure.ac: On LynxOS, link with -lnetinet.
16422 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16423 * configure: regenerate.
16425 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16427 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16428 * configure.ac: Add check for vasprintf and vsnprintf.
16429 * configure, config.in: Regenerate.
16430 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16432 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16434 * gdbreplay.c: Move include of alloca.h up, next to include of
16436 * server.h: Add include of malloc.h.
16437 * mem-break.c: Remove include of malloc.h.
16438 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16440 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16442 * Makefile.in (memmem.o): Build with -Wno-error.
16444 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16446 * utils.c (xsnprintf): Make non-static.
16447 * server.h: Add xsnprintf declaration.
16448 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16449 replace calls to snprintf by calls to xsnprintf throughout.
16451 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16453 * configure.ac: Add configure check for alloca.
16454 * configure, config.in: Regenerate.
16455 * server.h: Include alloca.h if it exists.
16456 * gdbreplay.c: Include alloca.h if it exists.
16458 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16460 * linux-low.c (__SIGRTMIN): Define if not already defined.
16461 (linux_create_inferior): Check for __ANDROID__ rather than
16463 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16464 are already deferred.
16465 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16466 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16467 stopped and already has a pending signal to report.
16468 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16469 a pending signal to report or is moving out of a jump pad.
16470 (linux_init_signals): Check for __ANDROID__ rather than
16473 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16475 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16476 debug_threads check. Avoid a linear search when not doing debug
16479 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16481 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16482 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16483 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16484 (process_event): Change local fd's type to gdb_fildes_t.
16485 (create_file_handler): Adjust prototype.
16486 (delete_file_handler): Adjust prototype.
16487 (handle_file_event): Adjust prototype. Use pfildes.
16488 (create_file_event): Adjsut prototype.
16489 * remote-utils.c (remote_desc, listen_desc): Change type to
16491 * server.h: New gdb_fildes_t typedef.
16492 [USE_WIN32API]: Include winsock2.h.
16493 (delete_file_handler, add_file_handler): Adjust prototypes.
16494 (pfildes): Declare.
16495 * utils.c (pfildes): New.
16497 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16499 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16500 * configure: Regenerate.
16502 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16504 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16505 (linux_done_accessing_memory): ... this.
16506 (linux_target_ops): Adjust.
16507 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16508 * nto-low.c (nto_target_ops): Adjust comment.
16509 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16510 * spu-low.c (spu_target_ops): Adjust comment.
16511 * target.h (target_ops): Rename unprepare_to_access_memory field
16512 to done_accessing_memory.
16513 (unprepare_to_access_memory): Rename to ...
16514 (done_accessing_memory): ... this.
16516 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16518 * linux-low.c (linux_prepare_to_access_memory): New.
16519 (linux_unprepare_to_access_memory): New.
16520 (linux_target_ops): Install them.
16521 * server.c (read_memory): Rename to ...
16522 (gdb_read_memory): ... this. Use
16523 prepare_to_access_memory/prepare_to_access_memory.
16524 (write_memory): Rename to ...
16525 (gdb_write_memory): ... this. Use
16526 prepare_to_access_memory/prepare_to_access_memory.
16527 (handle_search_memory_1): Adjust.
16528 (process_serial_event): Adjust.
16529 * target.h (struct target_ops): New fields
16530 prepare_to_access_memory and unprepare_to_access_memory.
16531 (prepare_to_access_memory, unprepare_to_access_memory): New.
16532 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16533 prepare_to_access_memory/prepare_to_access_memory.
16534 * nto-low.c (nto_target_ops): Adjust.
16535 * spu-low.c (spu_target_ops): Adjust.
16536 * win32-low.c (win32_target_ops): Adjust.
16538 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16540 * Makefile.in (WARN_CFLAGS): Get it from configure.
16541 (WERROR_CFLAGS): New.
16542 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16543 * configure.ac: Introduce --enable-werror, which adds -Werror to
16544 the compiler command line. Enabled by default. Disable with
16545 --disable-werror. Add -Wdeclaration-after-statement
16546 Wpointer-arith and -Wformat-nonliteral to warning flags.
16547 * configure: Regenerate.
16549 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16551 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16553 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16555 * gdbreplay.c (remote_error): New.
16557 (expect): Use gdbchar. Check for error reading from GDB.
16558 Clarify sync error output.
16559 (play): Check for errors writing to GDB.
16560 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16561 * remote-utils.c (getpkt): Check for errors writing to the remote
16564 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16566 * linux-low.c (linux_wait_1): Move non-debugging code out of
16567 `debug_threads' control.
16569 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16571 * linux-low.c (linux_wait_1): Don't set last_status here.
16572 * server.c (push_event, queue_stop_reply_callback): Assert we're
16573 not pushing a TARGET_WAITKIND_IGNORE event.
16574 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16575 (myresume, handle_target_event): Set the thread's last_resume_kind
16576 and last_status from the target returned status.
16578 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16582 * linux-x86-low.c (update_debug_registers_callback): New.
16583 (i386_dr_low_set_addr): Use it.
16584 (i386_dr_low_get_addr): New.
16585 (i386_dr_low_set_control): Use update_debug_registers_callback.
16586 (i386_dr_low_get_control): New.
16587 (i386_dr_low_get_status): Adjust.
16588 * linux-low.c (linux_stop_lwp): New.
16589 * linux-low.h (linux_stop_lwp): Declare.
16591 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16592 argument instead of a i386_debug_reg_state.
16593 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16594 a i386_debug_reg_state.
16595 (i386_insert_aligned_watchpoint): Adjust.
16596 (i386_remove_aligned_watchpoint): Adjust.
16597 (i386_low_stopped_data_address): Read the debug registers from the
16598 inferior instead of from the mirrors.
16599 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16600 (i386_dr_low_get_addr): Declare.
16601 (i386_dr_low_get_control): Declare.
16602 (i386_dr_low_get_status): Change prototype.
16604 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16605 (i386_dr_low_get_addr): New.
16606 (i386_dr_low_get_control): New.
16607 (i386_dr_low_get_status): Adjust prototype. Return
16609 (i386_initial_stuff): Clear dr_status_mirror and
16611 (i386_get_thread_context): Adjust.
16612 (i386_set_thread_context): Adjust.
16613 (i386_thread_added): Adjust.
16615 2010-08-24 Pedro Alves <pedro@codesourcery.com>
16617 * linux-low.h (linux_thread_area): Delete declaration.
16619 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16621 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16622 after its termination.
16624 2010-08-09 Pedro Alves <pedro@codesourcery.com>
16626 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16627 (gdb_wants_all_stopped): Delete.
16628 (linux_wait_1): Don't call them.
16629 * server.c (handle_v_cont): Tag all threads as want-stopped.
16630 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16631 stopped as "client-wants-stopped".
16633 2010-07-31 Pedro Alves <pedro@codesourcery.com>
16635 * Makefile.in (signals_h): New.
16636 (server_h): Depend on it.
16637 (server.o): Don't depend on $(signals_def).
16638 (signals.o): Depend on $(signals_def).
16640 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16642 * Makefile.in (signals_def): New.
16643 (server_h): Append include/gdb/signals.h and signals_def.
16644 (server.o): Append signals_def.
16646 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16648 * server.c (handle_target_event): Use target_signal_to_host for
16649 resume_info.sig initialization.
16650 * target.h (struct thread_resume) <sig>: New comment.
16652 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16654 * server.c (handle_query): strcpy() the returned string from paddress()
16655 instead of sprintf().
16656 * utils.c (paddress): Return phex_nz().
16658 2010-07-07 Joel Brobecker <brobecker@adacore.com>
16660 * server.c (handle_v_cont): Call mourn_inferior if process
16662 (myresume): Likewise.
16664 2010-07-01 Pedro Alves <pedro@codesourcery.com>
16666 Static tracepoints, and integration with UST.
16668 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16669 * mem-break.c (uninsert_all_breakpoints)
16670 (reinsert_all_breakpoints): New.
16671 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16672 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16673 (gdb_agent_ust_loaded, helper_thread_id)
16674 (gdb_agent_helper_thread_id): New macros.
16675 (struct ipa_sym_addresses): Add addr_ust_loaded,
16676 addr_helper_thread_id, addr_cmd_buf.
16677 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16678 (in_process_agent_loaded_ust): New.
16679 (write_e_ust_not_loaded): New.
16680 (maybe_write_ipa_ust_not_loaded): New.
16681 (struct collect_static_trace_data_action): New.
16682 (enum tracepoint_type) <static_tracepoint>: New.
16683 (struct tracepoint) <handle>: Mention static tracepoints.
16684 (struct static_tracepoint_ctx): New.
16685 (CMD_BUF_SIZE): New.
16686 (add_tracepoint_action): Handle static tracepoint actions.
16687 (unprobe_marker_at): New.
16688 (clear_installed_tracepoints): Handle static tracepoints.
16689 (cmd_qtdp): Handle static tracepoints.
16690 (probe_marker_at): New.
16691 (cmd_qtstart): Handle static tracepoints.
16692 (response_tracepoint): Handle static tracepoints.
16693 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16694 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16695 (get_context_regcache): Handle static tracepoints.
16696 (do_action_at_tracepoint): Handle static tracepoint actions.
16697 (traceframe_find_block_type): Handle static trace data blocks.
16698 (traceframe_read_sdata): New.
16699 (download_tracepoints): Download static tracepoint actions.
16700 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16701 (GDB_PROBE_NAME): New.
16703 (GET_UST_SYM): New.
16706 (ust_marker_to_static_tracepoint): New.
16708 (collect_ust_data_at_tracepoint): New.
16709 (gdb_ust_probe): New.
16710 (UNIX_PATH_MAX, SOCK_DIR): New.
16711 (gdb_ust_connect_sync_socket): New.
16712 (resume_thread, stop_thread): New.
16713 (run_inferior_command): New.
16714 (init_named_socket): New.
16715 (gdb_ust_socket_init): New.
16716 (cstr_to_hexstr): New.
16718 (first_marker, next_marker): New.
16719 (response_ust_marker): New.
16720 (cmd_qtfstm, cmd_qtsstm): New.
16721 (unprobe_marker_at, probe_marker_at): New.
16722 (cmd_qtstmat, gdb_ust_thread): New.
16723 (gdb_ust_init): New.
16724 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16725 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16726 (ST_REGENTRY): New.
16727 (x86_64_st_collect_regmap): New.
16728 (X86_64_NUM_ST_COLLECT_GREGS): New.
16729 (AMD64_RIP_REGNUM): New.
16730 (supply_static_tracepoint_registers): New.
16731 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16732 (ST_REGENTRY): New.
16733 (i386_st_collect_regmap): New.
16734 (i386_NUM_ST_COLLECT_GREGS): New.
16735 (supply_static_tracepoint_registers): New.
16736 * server.c (handle_query): Handle qXfer:statictrace:read.
16737 <qSupported>: Report support for StaticTracepoints, and
16738 qXfer:statictrace:read features.
16739 * server.h (traceframe_read_sdata)
16740 (supply_static_tracepoint_registers): Declare.
16741 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16742 (unpack_varlen_hex): Include in IPA build.
16743 * Makefile.in (ustlibs, ustinc): New.
16744 (IPA_OBJS): Add remote-utils-ipa.o.
16745 ($(IPA_LIB)): Link -ldl and -lpthread.
16747 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16748 * config.in, configure: Regenerate.
16750 2010-06-20 Ian Lance Taylor <iant@google.com>
16751 Pedro Alves <pedro@codesourcery.com>
16753 * linux-x86-low.c (always_true): Delete.
16754 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16755 trying to fool the compiler with always_true.
16757 2010-06-20 Pedro Alves <pedro@codesourcery.com>
16759 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16760 conditions in gdbserver.
16762 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16764 * spu-low.c (spu_read_memory): Wrap around local store limit.
16765 (spu_write_memory): Likewise.
16767 2010-06-15 Pedro Alves <pedro@codesourcery.com>
16769 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16770 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16772 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16774 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16775 uses with LONGEST uses.
16777 2010-06-14 Stan Shebs <stan@codesourcery.com>
16778 Pedro Alves <pedro@codesourcery.com>
16782 * linux-x86-low.c: Include limits.h.
16784 (always_true): New.
16787 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16788 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16789 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16790 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16791 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16792 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16793 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16794 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16795 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16796 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16797 (amd64_emit_void_call_2): New.
16798 (amd64_emit_ops): New.
16799 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16800 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16801 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16802 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16803 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16804 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16805 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16806 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16807 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16808 (i386_emit_stack_adjust, i386_emit_int_call_1)
16809 (i386_emit_void_call_2): New.
16810 (i386_emit_ops): New.
16811 (x86_emit_ops): New.
16812 (the_low_target): Install x86_emit_ops.
16813 * server.h (struct emit_ops): New.
16814 (get_raw_reg_func_addr): Declare.
16815 (current_insn_ptr, emit_error): Declare.
16816 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16817 (set_trace_state_variable_value): New defines.
16818 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16819 addr_get_trace_state_variable_value and
16820 addr_set_trace_state_variable_value.
16821 (symbol_list): New fields for get_raw_reg,
16822 get_trace_state_variable_value and set_trace_state_variable_value.
16823 (condfn): New typedef.
16824 (struct tracepoint): New field `compiled_cond'.
16825 (do_action_at_tracepoint): Clear compiled_cond.
16826 (get_trace_state_variable_value, set_trace_state_variable_value):
16828 (condition_true_at_tracepoint): If there's a compiled condition,
16830 (current_insn_ptr, emit_error): New globals.
16831 (struct bytecode_address): New.
16832 (get_raw_reg_func_addr): New.
16833 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16834 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16835 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16836 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16837 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16838 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16839 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16840 (compile_tracepoint_condition, compile_bytecodes): New.
16841 * target.h (emit_ops): Forward declare.
16842 (struct target_ops): New field emit_ops.
16843 (target_emit_ops): New.
16844 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16845 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16846 * linux-low.c (linux_emit_ops): New.
16847 (linux_target_ops): Install it.
16848 * linux-low.h (struct linux_target_ops): New field emit_ops.
16850 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16852 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16853 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16855 2010-06-01 Pedro Alves <pedro@codesourcery.com>
16856 Stan Shebs <stan@codesourcery.com>
16858 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
16859 (all): Depend on $(extra_libraries).
16860 (install-only): Install the IPA.
16861 (IPA_OBJS, IPA_LIB): New.
16862 (clean): Remove the IPA lib.
16863 (IPAGENT_CFLAGS): New.
16864 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
16865 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
16866 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
16867 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
16868 * configure.ac: Check for atomic builtins support in the compiler.
16869 (IPA_DEPFILES, extra_libraries): Define.
16870 * configure.srv (ipa_obj): Add description.
16871 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
16872 (i[34567]86-*-linux*): Set ipa_obj.
16873 (x86_64-*-linux*): Set ipa_obj.
16874 * linux-low.c (stabilizing_threads): New.
16875 (supports_fast_tracepoints): New.
16876 (linux_detach): Stabilize threads before detaching.
16877 (handle_tracepoints): Handle internal tracing breakpoints. Assert
16878 the lwp is either not stabilizing, or is moving out of a jump pad.
16879 (linux_fast_tracepoint_collecting): New.
16880 (maybe_move_out_of_jump_pad): New.
16881 (enqueue_one_deferred_signal): New.
16882 (dequeue_one_deferred_signal): New.
16883 (linux_wait_for_event_1): If moving out of a jump pad, defer
16884 pending signals to later.
16885 (linux_stabilize_threads): New.
16886 (linux_wait_1): Check if threads need moving out of jump pads, and
16888 (stuck_in_jump_pad_callback): New.
16889 (move_out_of_jump_pad_callback): New.
16890 (lwp_running): New.
16891 (linux_resume_one_lwp): Handle moving out of jump pads.
16892 (linux_set_resume_request): Dequeue deferred signals.
16893 (need_step_over_p): Also step over fast tracepoint jumps.
16894 (start_step_over): Also uninsert fast tracepoint jumps.
16895 (finish_step_over): Also reinsert fast tracepoint jumps.
16896 (linux_install_fast_tracepoint_jump): New.
16897 (linux_target_ops): Install linux_stabilize_threads and
16898 linux_install_fast_tracepoint_jump_pad.
16899 * linux-low.h (linux_target_ops) <get_thread_area,
16900 install_fast_tracepoint_jump_pad>: New fields.
16901 (struct lwp_info) <collecting_fast_tracepoint,
16902 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
16903 (linux_get_thread_area): Declare.
16904 * linux-x86-low.c (jump_insn): New.
16905 (x86_get_thread_area): New.
16906 (append_insns): New.
16907 (push_opcode): New.
16908 (amd64_install_fast_tracepoint_jump_pad): New.
16909 (i386_install_fast_tracepoint_jump_pad): New.
16910 (x86_install_fast_tracepoint_jump_pad): New.
16911 (the_low_target): Install x86_get_thread_area and
16912 x86_install_fast_tracepoint_jump_pad.
16913 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
16914 (struct fast_tracepoint_jump): New.
16915 (fast_tracepoint_jump_insn): New.
16916 (fast_tracepoint_jump_shadow): New.
16917 (find_fast_tracepoint_jump_at): New.
16918 (fast_tracepoint_jump_here): New.
16919 (delete_fast_tracepoint_jump): New.
16920 (set_fast_tracepoint_jump): New.
16921 (uninsert_fast_tracepoint_jumps_at): New.
16922 (reinsert_fast_tracepoint_jumps_at): New.
16923 (set_breakpoint_at): Use write_inferior_memory.
16924 (uninsert_raw_breakpoint): Use write_inferior_memory.
16925 (check_mem_read): Mask out fast tracepoint jumps.
16926 (check_mem_write): Mask out fast tracepoint jumps.
16927 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
16928 (set_fast_tracepoint_jump): Declare.
16929 (delete_fast_tracepoint_jump)
16930 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
16931 (reinsert_fast_tracepoint_jumps_at): Declare.
16932 * regcache.c: Don't compile many functions when building the
16933 in-process agent library.
16934 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
16935 the register buffer in the heap.
16936 (free_register_cache): If the register buffer isn't owned by the
16937 regcache, don't free it.
16938 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
16939 pre-existing register caches.
16940 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
16942 (convert_ascii_to_int): : Constify `from' parameter type.
16943 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
16944 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
16945 the needed buffer in-place.
16946 (relocate_instruction): New.
16947 * server.c (handle_query) <qSymbols>: If the target supports
16948 tracepoints, give it a chance of looking up symbols. Report
16949 support for fast tracepoints.
16950 (handle_status): Stabilize threads.
16951 (process_serial_event): Adjust.
16952 * server.h (struct fast_tracepoint_jump): Forward declare.
16953 (struct process_info) <fast_tracepoint_jumps>: New field.
16954 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
16955 (decode_X_packet, decode_M_packet): Adjust.
16956 (relocate_instruction): Declare.
16957 (in_process_agent_loaded): Declare.
16958 (tracepoint_look_up_symbols): Declare.
16959 (struct fast_tpoint_collect_status): Declare.
16960 (fast_tracepoint_collecting): Declare.
16961 (force_unlock_trace_buffer): Declare.
16962 (handle_tracepoint_bkpts): Declare.
16963 (initialize_low_tracepoint)
16964 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
16965 * target.h (struct target_ops) <stabilize_threads,
16966 install_fast_tracepoint_jump_pad>: New fields.
16967 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
16968 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
16969 [HAVE_STDINT_H]: Include stdint.h.
16970 (trace_debug_1): Rename to ...
16971 (trace_vdebug): ... this.
16972 (trace_debug): Rename to ...
16973 (trace_debug_1): ... this. Add `level' parameter.
16974 (trace_debug): New.
16975 (ATTR_USED, ATTR_NOINLINE): New.
16976 (IP_AGENT_EXPORT): New.
16977 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
16978 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
16979 (about_to_request_buffer_space, trace_buffer_is_full)
16980 (stopping_tracepoint, expr_eval_result, error_tracepoint)
16981 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
16982 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
16983 (traceframe_write_count, traceframes_created)
16984 (trace_state_variables)
16985 New renaming defines.
16986 (struct ipa_sym_addresses): New.
16987 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
16988 (symbol_list): New.
16989 (ipa_sym_addrs): New.
16990 (all_tracepoint_symbols_looked_up): New.
16991 (in_process_agent_loaded): New.
16992 (write_e_ipa_not_loaded): New.
16993 (maybe_write_ipa_not_loaded): New.
16994 (tracepoint_look_up_symbols): New.
16995 (debug_threads) [IN_PROCESS_AGENT]: New.
16996 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
16997 (UNKNOWN_SIDE_EFFECTS): New.
16998 (stop_tracing): New.
16999 (flush_trace_buffer): New.
17000 (stop_tracing_bkpt): New.
17001 (flush_trace_buffer_bkpt): New.
17002 (read_inferior_integer): New.
17003 (read_inferior_uinteger): New.
17004 (read_inferior_data_pointer): New.
17005 (write_inferior_data_pointer): New.
17006 (write_inferior_integer): New.
17007 (write_inferior_uinteger): New.
17008 (struct collect_static_trace_data_action): Delete.
17009 (enum tracepoint_type): New.
17010 (struct tracepoint) <type>: New field `type'.
17011 <actions_str, step_actions, step_actions_str>: Only include in
17013 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17014 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17015 (tracepoints): Use IP_AGENT_EXPORT.
17016 (last_tracepoint): Don't include in the IPA.
17017 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17018 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17019 (alloced_trace_state_variables): New.
17020 (trace_state_variables): Use IP_AGENT_EXPORT.
17021 (traceframe_t): Delete unused variable.
17022 (circular_trace_buffer): Don't include in the IPA.
17023 (trace_buffer_start): Delete.
17024 (struct trace_buffer_control): New.
17025 (trace_buffer_free): Delete.
17026 (struct ipa_trace_buffer_control): New.
17027 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17028 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17030 (trace_buffer_ctrl): New.
17031 (TRACE_BUFFER_CTRL_CURR): New.
17032 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17033 Reimplement as macros.
17034 (trace_buffer_wrap): Delete.
17035 (traceframe_write_count, traceframe_read_count)
17036 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17037 (struct tracepoint_hit_ctx) <type>: New field.
17038 (struct fast_tracepoint_ctx): New.
17039 (memory_barrier): New.
17041 (record_tracepoint_error): Update atomically in the IPA.
17042 (clear_inferior_trace_buffer): New.
17043 (about_to_request_buffer_space): New.
17044 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17045 updating the same buffer.
17046 (add_tracepoint): Default the tracepoint's type to trap
17047 tracepoint, and orig_size to -1.
17048 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17049 internal variables.
17050 (create_trace_state_variable): New parameter `gdb'. Handle it.
17051 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17052 (cmd_qtdp): Handle fast tracepoints.
17053 (cmd_qtdv): Adjust.
17054 (max_jump_pad_size): New.
17055 (gdb_jump_pad_head): New.
17056 (get_jump_space_head): New.
17057 (claim_jump_space): New.
17058 (sort_tracepoints): New.
17059 (MAX_JUMP_SIZE): New.
17060 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17062 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17063 support. Upload fast traceframes, and delete internal IPA
17065 (stop_tracing_handler): New.
17066 (flush_trace_buffer_handler): New.
17067 (cmd_qtstop): Upload fast tracepoints.
17068 (response_tracepoint): Handle fast tracepoints.
17069 (tracepoint_finished_step): Upload fast traceframes. Set the
17070 tracepoint hit context's tracepoint type.
17071 (handle_tracepoint_bkpts): New.
17072 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17073 type. Add comment about fast tracepoints.
17074 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17075 non-existing action_str field.
17076 (get_context_regcache): Handle fast tracepoints.
17077 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17079 (fast_tracepoint_from_jump_pad_address): New.
17080 (fast_tracepoint_from_ipa_tpoint_address): New.
17081 (collecting_t): New.
17082 (force_unlock_trace_buffer): New.
17083 (fast_tracepoint_collecting): New.
17085 (gdb_collect): New.
17086 (write_inferior_data_ptr): New.
17087 (target_tp_heap): New.
17088 (target_malloc): New.
17089 (download_agent_expr): New.
17091 (download_tracepoints): New.
17092 (download_trace_state_variables): New.
17093 (upload_fast_traceframes): New.
17094 (IPA_FIRST_TRACEFRAME): New.
17095 (IPA_NEXT_TRACEFRAME_1): New.
17096 (IPA_NEXT_TRACEFRAME): New.
17097 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17098 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17099 (gdb_jump_pad_buffer_end): New.
17100 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17101 (initialize_tracepoint): Adjust.
17102 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17103 buffer. Initialize the low module.
17104 * utils.c (PREFIX, TOOLNAME): New.
17105 (malloc_failure): Use PREFIX.
17106 (error): In the IPA, an error causes an exit.
17107 (fatal, warning): Use PREFIX.
17108 (internal_error): Use TOOLNAME.
17109 (NUMCELLS): Increase to 10.
17110 * configure, config.in: Regenerate.
17112 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17114 * server.c (handle_query) <qSupported>: Do two passes over the
17115 qSupported string to avoid nesting strtok.
17117 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17119 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17121 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17122 -Wl,--dynamic-list.
17123 * configure: Regenerate.
17124 * proc-service.list: New.
17126 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17128 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17131 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17133 * gdbreplay.c (remote_open): Check error return from socket() call by
17134 its equality to -1 not by it being negative.
17135 * remote-utils.c (remote_open): Likewise.
17137 2010-05-23 Pedro Alves <pedro@codesourcery.com>
17139 * config.h: Regenerate.
17141 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17143 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17144 doesn't provide PTRACE_GET_THREAD_AREA.
17146 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17148 * linux-m68k-low.c: Include <asm/ptrace.h>
17149 (ps_get_thread_area): Implement.
17151 2010-05-03 Doug Evans <dje@google.com>
17153 * event-loop.c (struct callback_event): New struct.
17154 (callback_list): New global.
17155 (append_callback_event, delete_callback_event): New functions.
17156 (process_callback): New function.
17157 (start_event_loop): Call it.
17158 * remote-utils.c (NOT_SCHEDULED): Define.
17159 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17160 moved out of readchar.
17161 (readchar): Rewrite. Call reschedule before returning.
17162 (reset_readchar): New function.
17163 (remote_close): Call it.
17164 (process_remaining, reschedule): New functions.
17165 * server.h (callback_handler_func): New typedef.
17166 (append_callback_event, delete_callback_event): Declare.
17168 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17170 * proc-service.c (ps_pglobal_lookup): Use
17171 thread_db_look_up_one_symbol.
17172 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17173 parameter. Use it instead of all_symbols_looked_up.
17174 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17176 (all_symbols_looked_up): Don't declare.
17177 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17178 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17180 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17181 Set all_symbols_looked_up here.
17182 (thread_db_look_up_one_symbol): New.
17183 (thread_db_get_tls_address): Adjust.
17184 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17185 thread_db object on the heap, and tentatively set it in the
17187 (thread_db_init): Don't set all_symbols_looked_up here.
17188 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17190 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17192 * linux-low.c (linux_kill, linux_detach): Adjust.
17193 (status_pending_p_callback): Remove redundant statement. Check
17194 for !TARGET_WAITIKIND_IGNORE, instead of
17195 TARGET_WAITKIND_STOPPED.
17196 (handle_tracepoints): Make sure LWP is locked. Adjust.
17197 (linux_wait_for_event_1): Adjust.
17198 (linux_cancel_breakpoints): New.
17199 (unsuspend_one_lwp): New.
17200 (unsuspend_all_lwps): New.
17201 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17202 (send_sigstop_callback): Change return type to int, add new
17203 `except' parameter and handle it.
17204 (suspend_and_send_sigstop_callback): New.
17205 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17206 pass them down. If SUSPEND, also increment the lwp's suspend
17208 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17209 (need_step_over_p): Don't consider suspended LWPs.
17210 (start_step_over): Adjust.
17211 (proceed_one_lwp): Change return type to int, add new `except'
17212 parameter and handle it.
17213 (unsuspend_and_proceed_one_lwp): New.
17214 (proceed_all_lwps): Use find_inferior instead of
17216 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17217 also decrement the suspend count of LWPs. Pass `except' down,
17218 instead of hacking its suspend count.
17219 (linux_pause_all): Add `freeze' parameter. Adjust.
17220 (linux_unpause_all): New.
17221 (linux_target_ops): Install linux_unpause_all.
17222 * server.c (handle_status): Adjust.
17223 * target.h (struct target_ops): New fields `unpause_all' and
17224 `cancel_breakpoints'. Add new parameter to `pause_all'.
17225 (pause_all): Add new `freeze' parameter.
17226 (unpause_all): New.
17227 (cancel_breakpoints): New.
17228 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17229 cancel breakpoints.
17230 (cmd_qtstart): Pause threads.
17231 (stop_tracing): Pause threads, and cancel breakpoints.
17232 * win32-low.c (win32_target_ops): Adjust.
17234 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17236 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17237 the inferior right away from here...
17238 (linux_wait_1): ... to here, and adjust to check the thread's
17239 last_resume_kind instead of the lwp's step or stop_expected flags.
17241 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17243 * README: Use consistent `GDB' and `GDBserver' spellings.
17245 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17247 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17248 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17249 (linux_detach_one_lwp): Assume the lwp is stopped.
17250 (any_thread_of): Delete.
17251 (linux_detach): Stop all lwps here. Don't blindly delete all
17253 (delete_lwp_callback): New.
17254 (linux_mourn): Delete all lwps of the process that is gone.
17255 (linux_wait_1): Don't delete the last lwp of the process here.
17256 * mem-break.h (mark_breakpoints_out): Declare.
17257 * mem-break.c (mark_breakpoints_out): New.
17258 (free_all_breakpoints): Use it.
17259 * server.c (handle_target_event): If the process is gone, mark
17261 * thread-db.c (struct thread_db) <create_bp>: New field.
17262 (thread_db_enable_reporting): Fix prototype. Store a thread event
17263 breakpoint reference in the thread_db struct.
17264 (thread_db_load_search): Clear the thread_db object.
17265 (try_thread_db_load_1): Ditto.
17266 (switch_to_process): New.
17267 (disable_thread_event_reporting): Use it.
17268 (remove_thread_event_breakpoints): New.
17269 (thread_db_detach, thread_db_mourn): Use it.
17271 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17273 * linux-low.c (linux_enable_event_reporting): New.
17274 (linux_wait_for_event_1, handle_extended_wait): Use it.
17276 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17278 * linux-low.c (linux_kill_one_lwp, linux_kill)
17279 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17280 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17281 SIGSTOP even if the LWP is stopped.
17282 (send_sigstop_callback): New.
17283 (stop_all_lwps): Use send_sigstop_callback instead.
17284 (linux_resume_one_thread): Adjust.
17285 (proceed_one_lwp): Still proceed an LWP that the client has
17286 requested to stop, if we haven't reported it as stopped yet. Make
17287 sure that LWPs the client want stopped, have a pending SIGSTOP.
17289 2010-04-26 Doug Evans <dje@google.com>
17291 * server.c (handle_general_set): Make static.
17293 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17294 Print received char after testing for error/eof instead of before.
17295 (input_interrupt): Tweak comment.
17297 2010-04-23 Doug Evans <dje@google.com>
17299 * server.c (start_inferior): Print inferior argv if --debug.
17301 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17303 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17304 * nto-x86-low.c: Include server.h
17306 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17308 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17309 be consistent with other sources of this directory.
17310 (init_registers_amd64): Correct name of source file of this function
17313 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17315 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17316 64-bit executables.
17318 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17320 * win32-i386-low.c: Add 64-bit support.
17321 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17322 (init_registers_amd64): Declare.
17323 (mappings): Add 64-bit version of array.
17324 (init_windows_x86): New function.
17325 (the_low_target): Change init_arch field to init_windows_x86.
17327 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17329 * win32-low.c: Adapt to support also 64-bit architecture.
17330 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17331 (get_image_name): Use SIZE_T type for local variable `done'.
17332 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17333 (toolhelp_get_dll_name): Idem.
17334 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17335 Use uintptr_t typecast to avoid warning.
17336 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17337 (handle_exception): Use phex_nz to avoid warning.
17338 (win32_wait): Remove unused local variable `process'.
17340 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17342 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17345 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17347 * configure.ac: Use `ws2_32' library for srv_mingw.
17348 * configure: Regenerate.
17349 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17350 * remote-utils.c: Likewise.
17352 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17354 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17355 if __x86_64__ is defined.
17357 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17359 * configure: Regenerate.
17361 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17363 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17364 * target.h (target_ops): New get_tib_address field.
17365 * win32-low.h (win32_thread_info): Add thread_local_base field.
17366 * win32-low.c (child_add_thread): Add tlb argument.
17367 Set thread_local_base field to TLB.
17368 (get_child_debug_event): Adapt to child_add_thread change.
17369 (win32_get_tib_address): New function.
17370 (win32_target_ops): Set get_tib_address field to
17371 win32_get_tib_address.
17372 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17374 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17376 * linux-low.c (linux_mourn): Also remove the process.
17377 * server.c (handle_target_event): Don't remove the process here.
17378 * nto-low.c (nto_mourn): New.
17379 (nto_target_ops): Install it.
17380 * spu-low.c (spu_mourn): New.
17381 (spu_target_ops): Install it.
17382 * win32-low.c (win32_mourn): New.
17383 (win32_target_ops): Install it.
17385 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17387 * server.h (buffer_xml_printf): Remove redundant `;'.
17389 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17391 * regcache.c (set_register_cache): Invalidate regcaches before
17392 changing the register cache layout.
17393 (regcache_invalidate_one): Allow a NULL regcache.
17394 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17395 regcaches before changing the register cache layout or the target
17398 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17400 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17401 variable warning on Linux/x86-64.
17403 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17405 GDBserver disconnected tracing support.
17407 * linux-low.c (linux_remove_process): Delete.
17408 (add_lwp): Don't set last_resume_kind here.
17409 (linux_kill): Use `mourn'.
17410 (linux_detach): Use `thread_db_detach', and `mourn'.
17411 (linux_mourn): New.
17412 (linux_attach_lwp_1): Adjust comment.
17413 (linux_attach): last_resume_kind moved the thread_info; adjust.
17414 (status_pending_p_callback): Adjust.
17415 (linux_wait_for_event_1): Adjust.
17416 (count_events_callback, select_singlestep_lwp_callback)
17417 (select_event_lwp_callback, cancel_breakpoints_callback)
17418 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17419 (proceed_one_lwp): Adjust.
17420 (linux_async): Add debug output.
17421 (linux_thread_stopped): New.
17422 (linux_pause_all): New.
17423 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17425 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17426 (thread_db_free): Delete declaration.
17427 (thread_db_detach, thread_db_mourn): Declare.
17428 * thread-db.c (thread_db_init): Use thread_db_mourn.
17429 (thread_db_free): Delete, split in two.
17430 (disable_thread_event_reporting): New.
17431 (thread_db_detach): New.
17432 (thread_db_mourn): New.
17434 * server.h (struct thread_info) <last_resume_kind>: New field.
17435 <attached>: Add comment.
17436 <gdb_detached>: New field.
17437 (handler_func): Change return type to int.
17438 (handle_serial_event, handle_target_event): Ditto.
17439 (gdb_connected): Declare.
17441 (disconnected_tracing): Declare.
17442 (stop_tracing): Declare.
17444 * server.c (handle_query) <qSupported>: Report support for
17445 disconnected tracing.
17446 (queue_stop_reply_callback): Account for running threads.
17447 (gdb_wants_thread_stopped): New.
17448 (gdb_wants_all_threads_stopped): New.
17449 (gdb_reattached_process): New.
17450 (handle_status): Clear the `gdb_detached' flag of all processes.
17451 In all-stop, stop all threads.
17452 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17453 (process_serial_event): If the remote connection breaks, or if an
17454 exit was forced with "monitor exit", force an event loop exit.
17455 Handle disconnected tracing on detach.
17456 (handle_serial_event): Adjust.
17457 (handle_target_event): If GDB isn't connected, forward events back
17458 to the inferior, unless the last process exited, in which case,
17459 exit gdbserver. Adjust interface.
17461 * remote-utils.c (remote_open): Don't block in accept. Instead
17462 register an event loop source on the listen socket file
17463 descriptor. Refactor bits into ...
17464 (listen_desc): ... this new global.
17465 (gdb_connected): ... this new function.
17466 (enable_async_notification): ... this new function.
17467 (handle_accept_event): ... this new function.
17468 (remote_close): Clear remote_desc.
17470 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17472 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17474 (mourn_inferior): Define.
17475 (target_process_qsupported): Avoid the dangling else problem.
17476 (thread_stopped): Define.
17477 (pause_all): Define.
17478 (target_waitstatus_to_string): Declare.
17479 * target.c (target_waitstatus_to_string): New.
17481 * tracepoint.c (tracing): Make extern.
17482 (disconnected_tracing): New.
17483 (stop_tracing): Make extern. Handle tracing stops due to GDB
17485 (cmd_qtdisconnected): New.
17486 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17487 (handle_tracepoint_general_set): Handle QTDisconnected.
17489 * event-loop.c (event_handler_func): Change return type to int.
17490 (process_event): Bail out if the event handler wants the event
17492 (handle_file_event): Ditto.
17493 (start_event_loop): Bail out if the event handler wants the event
17496 * nto-low.c (nto_target_ops): Adjust.
17497 * spu-low.c (spu_wait): Don't remove the process here.
17498 (spu_target_ops): Adjust.
17499 * win32-low.c (win32_wait): Don't remove the process here.
17500 (win32_target_ops): Adjust.
17502 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17504 * regcache.c (realloc_register_cache): Invalidate inferior's
17505 regcache before recreating it.
17507 2010-04-09 Pedro Alves <pedro@codesourcery.com>
17509 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17511 2010-04-09 Stan Shebs <stan@codesourcery.com>
17512 Pedro Alves <pedro@codesourcery.com>
17514 * server.h (LONGEST): New.
17515 (struct thread_info) <while_stepping>: New field.
17516 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17518 (initialize_tracepoint, handle_tracepoint_general_set)
17519 (handle_tracepoint_query, tracepoint_finished_step)
17520 (tracepoint_was_hit, release_while_stepping_state_list):
17521 (current_traceframe): Declare.
17522 * server.c (handle_general_set): Handle tracepoint packets.
17523 (read_memory): New.
17524 (write_memory): New.
17525 (handle_search_memory_1): Use read_memory.
17526 (handle_query): Report support for conditional tracepoints, trace
17527 state variables, and tracepoint sources. Handle tracepoint
17529 (main): Initialize the tracepoints module.
17530 (process_serial_event): Handle traceframe reads/writes.
17532 * linux-low.c (handle_tracepoints): New.
17533 (linux_wait_1): Call it.
17534 (linux_resume_one_lwp): Handle while-stepping.
17535 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17536 (linux_target_ops): Install them.
17537 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17539 * linux-x86-low.c (x86_supports_tracepoints): New.
17540 (the_low_target). Install it.
17542 * mem-break.h (delete_breakpoint): Declare.
17543 * mem-break.c (delete_breakpoint): Make external.
17545 * target.h (struct target_ops): Add `supports_tracepoints',
17546 `read_pc', and `write_pc' fields.
17547 (target_supports_tracepoints): Define.
17548 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17551 * regcache.h (struct regcache) <registers_owned>: New field.
17552 (init_register_cache, regcache_cpy): Declare.
17553 (regcache_read_pc, regcache_write_pc): Declare.
17554 (register_cache_size): Declare.
17555 (supply_regblock): Declare.
17556 * regcache.c (init_register_cache): New.
17557 (new_register_cache): Use it.
17558 (regcache_cpy): New.
17559 (register_cache_size): New.
17560 (supply_regblock): New.
17561 (regcache_read_pc, regcache_write_pc): New.
17563 * tracepoint.c: New.
17565 * Makefile.in (OBS): Add tracepoint.o.
17566 (tracepoint.o): New rule.
17568 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17570 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17572 (i386-mmx.c): Likewise.
17573 (i386-mmx-linux.o): Likewise.
17574 (i386-mmx-linux.c): Likewise.
17576 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17577 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17578 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17579 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17581 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17582 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17583 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17585 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17587 * Makefile.in (clean): Updated.
17589 (i386-avx.c): Likewise.
17590 (i386-avx-linux.o): Likewise.
17591 (i386-avx-linux.c): Likewise.
17592 (amd64-avx.o): Likewise.
17593 (amd64-avx.c): Likewise.
17594 (amd64-avx-linux.o): Likewise.
17595 (amd64-avx-linux.c): Likewise.
17597 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17598 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17599 (srv_amd64_regobj): Add amd64-avx.o.
17600 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17601 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17602 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17603 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17604 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17605 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17606 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17608 * i387-fp.c: Include "i386-xstate.h".
17610 (i387_cache_to_xsave): Likewise.
17611 (i387_xsave_to_cache): Likewise.
17612 (x86_xcr0): Likewise.
17614 * i387-fp.h (i387_cache_to_xsave): Likewise.
17615 (i387_xsave_to_cache): Likewise.
17616 (x86_xcr0): Likewise.
17618 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17619 * linux-crisv32-low.c (target_regsets): Likewise.
17620 * linux-m68k-low.c (target_regsets): Likewise.
17621 * linux-mips-low.c (target_regsets): Likewise.
17622 * linux-ppc-low.c (target_regsets): Likewise.
17623 * linux-s390-low.c (target_regsets): Likewise.
17624 * linux-sh-low.c (target_regsets): Likewise.
17625 * linux-sparc-low.c (target_regsets): Likewise.
17626 * linux-xtensa-low.c (target_regsets): Likewise.
17628 * linux-low.c: Include <sys/uio.h>.
17629 (regsets_fetch_inferior_registers): Support nt_type.
17630 (regsets_store_inferior_registers): Likewise.
17631 (linux_process_qsupported): New.
17632 (linux_target_ops): Add linux_process_qsupported.
17634 * linux-low.h (regset_info): Add nt_type.
17635 (linux_target_ops): Add process_qsupported.
17637 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17639 (init_registers_i386_avx_linux): New.
17640 (init_registers_amd64_avx_linux): Likewise.
17641 (xmltarget_i386_linux_no_xml): Likewise.
17642 (xmltarget_amd64_linux_no_xml): Likewise.
17643 (PTRACE_GETREGSET): Likewise.
17644 (PTRACE_SETREGSET): Likewise.
17645 (x86_fill_xstateregset): Likewise.
17646 (x86_store_xstateregset): Likewise.
17647 (use_xml): Likewise.
17648 (x86_linux_update_xmltarget): Likewise.
17649 (x86_linux_process_qsupported): Likewise.
17650 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17651 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17652 init_registers_i386_linux here. Call
17653 x86_linux_update_xmltarget.
17654 (the_low_target): Add x86_linux_process_qsupported.
17656 * server.c (handle_query): Call target_process_qsupported.
17658 * target.h (target_ops): Add process_qsupported.
17659 (target_process_qsupported): New.
17661 2010-04-03 Pedro Alves <pedro@codesourcery.com>
17663 * inferiors.c (add_thread): Set last_status kind to
17664 TARGET_WAITKIND_IGNORE.
17665 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17666 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17667 (linux_wait_1): Move `thread' local definition to block that uses
17668 it. Don't NULL initialize `event_child'.
17669 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17670 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17671 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17673 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17675 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17676 an extended waitstatus, or by a watchpoint.
17677 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17678 thread was stepping or has been stopped by a watchpoint.
17680 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17682 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17683 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17684 of another, then delete the previous, and validate all
17686 (validate_inserted_breakpoint): New.
17687 (delete_disabled_breakpoints): New.
17688 (validate_breakpoints): New.
17689 (check_mem_read): Validate breakpoints before trusting their
17690 shadow. Delete disabled breakpoints.
17691 (check_mem_write): Validate breakpoints before trusting they
17692 should be inserted. Delete disabled breakpoints.
17693 * mem-break.h (validate_breakpoints):
17694 * server.c (handle_query): Validate breakpoints when we see a
17697 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17699 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17700 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17701 if we could tell there's a GDB breakpoint at stop_pc.
17702 (need_step_over_p): Don't do a step over if we find a GDB
17703 breakpoint at the resume PC.
17705 * mem-break.c (struct raw_breakpoint): New.
17706 (enum bkpt_type): New type `gdb_breakpoint'.
17707 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17708 fields. New field `raw'.
17709 (find_raw_breakpoint_at): New.
17710 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17711 breakpoint instead.
17712 (set_breakpoint_at): Adjust.
17713 (delete_raw_breakpoint): New.
17714 (release_breakpoint): New.
17715 (delete_breakpoint): Rename to...
17716 (delete_breakpoint_1): ... this. Add proc parameter. Use
17717 release_breakpoint. Return ENOENT.
17718 (delete_breakpoint): Reimplement.
17719 (find_breakpoint_at): Delete.
17720 (find_gdb_breakpoint_at): New.
17721 (delete_breakpoint_at): Delete.
17722 (set_gdb_breakpoint_at): New.
17723 (delete_gdb_breakpoint_at): New.
17724 (gdb_breakpoint_here): New.
17725 (set_reinsert_breakpoint): Use release_breakpoint.
17726 (uninsert_breakpoint): Rename to ...
17727 (uninsert_raw_breakpoint): ... this.
17728 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17729 (reinsert_raw_breakpoint): Change parameter type to
17731 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17733 (check_breakpoints): Adjust. Use release_breakpoint.
17734 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17735 (breakpoint_inserted_here): Ditto.
17736 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17737 Don't trust the breakpoint's shadow if it is not inserted.
17738 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17739 (delete_all_breakpoints): Adjust.
17740 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17741 use delete_breakpoint_1.
17743 * mem-break.h (breakpoints_supported): Delete declaration.
17744 (set_gdb_breakpoint_at): Declare.
17745 (gdb_breakpoint_here): Declare.
17746 (delete_breakpoint_at): Delete.
17747 (delete_gdb_breakpoint_at): Declare.
17749 * server.h (struct raw_breakpoint): Forward declare.
17750 (struct process_info): New field `raw_breakpoints'.
17752 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17755 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17757 * linux-low.c (status_pending_p_callback): Fix comment.
17758 (linux_wait_for_event_1): Move most of the internal breakpoint
17759 handling from here...
17760 (linux_wait_1): ... to here.
17761 (count_events_callback): New.
17762 (select_singlestep_lwp_callback): New.
17763 (select_event_lwp_callback): New.
17764 (cancel_breakpoints_callback): New.
17765 (select_event_lwp): New.
17766 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17767 priority to all LWPs that have had events that should be reported
17768 to the client. Cancel breakpoints when about to reporting the
17769 event to the client, not while stopping lwps. No longer cancel
17770 finished single-steps here.
17771 (cancel_finished_single_step): Delete.
17772 (cancel_finished_single_steps): Delete.
17774 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17776 * mem-break.c (enum bkpt_type): New.
17777 (struct breakpoint): New field `type'.
17778 (set_breakpoint_at): Change return type to struct breakpoint
17779 pointer. Set type to `other_breakpoint' by default.
17780 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17781 in the breakpoint list.
17782 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17783 (reinsert_breakpoint): Rename to ...
17784 (reinsert_raw_breakpoint): ... this.
17785 (reinsert_breakpoints_at): Adjust.
17786 * mem-break.h (struct breakpoint): Declare.
17787 (set_breakpoint_at): Change return type to struct breakpoint
17790 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17792 * server.c (handle_query): Assign, not compare.
17794 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17796 Teach linux gdbserver to step-over-breakpoints.
17798 * linux-low.c (can_hardware_single_step): New.
17799 (supports_breakpoints): New.
17800 (handle_extended_wait): If stopping threads, read the stop pc of
17801 the new cloned LWP.
17803 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17804 low target doesn't support retrieving the PC.
17805 (add_lwp): Set last_resume_kind to resume_continue.
17806 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17807 (linux_attach): Don't clear stop_expected. Set the lwp's
17808 last_resume_kind to resume_stop.
17809 (linux_detach_one_lwp): Don't check for removed breakpoints.
17810 (check_removed_breakpoint): Delete.
17811 (status_pending_p): Rename to ...
17812 (status_pending_p_callback): ... this. Don't check for removed
17813 breakpoints. Don't consider threads that are stopped from GDB's
17815 (linux_wait_for_lwp): Always read the stop_pc here.
17816 (cancel_breakpoint): New.
17817 (step_over_bkpt): New global.
17818 (linux_wait_for_event_1): Implement stepping over breakpoints.
17819 (gdb_wants_lwp_stopped): New.
17820 (gdb_wants_all_stopped): New.
17821 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17822 single-step traps here. Store the thread's last reported target
17824 (send_sigstop): Don't clear stop_expected. Always set it,
17826 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17827 (cancel_finished_single_step): New.
17828 (cancel_finished_single_steps): New.
17829 (wait_for_sigstop): Don't cancel finished single-step traps here.
17830 (linux_resume_one_lwp): Don't check for removed breakpoints.
17831 Don't set `step' on non-hardware step archs.
17832 (linux_set_resume_request): Ignore resume_stop requests if already
17833 stopping or stopped. Set the lwp's last_resume_kind.
17834 (resume_status_pending_p): Don't check for removed breakpoints.
17835 (need_step_over_p): New.
17836 (start_step_over): New.
17837 (finish_step_over): New.
17838 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17839 requests. Clear the thread's last reported target waitstatus.
17840 Don't use the `suspended' flag. Don't consider pending breakpoints.
17841 (linux_resume): Start a step-over if necessary.
17842 (proceed_one_lwp): New.
17843 (proceed_all_lwps): New.
17844 (unstop_all_lwps): New.
17845 * linux-low.h (struct lwp_info): Rewrite comment for the
17846 `suspended' flag. Add the `stop_pc' field. Delete the
17847 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17848 Add `'last_resume_kind' and `need_step_over' fields.
17849 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17850 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17851 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17852 (set_raw_breakpoint_at): New.
17853 (set_breakpoint_at): Rewrite to use it.
17854 (reinsert_breakpoint_handler): Delete.
17855 (set_reinsert_breakpoint): New.
17856 (reinsert_breakpoint_by_bp): Delete.
17857 (delete_reinsert_breakpoints): New.
17858 (uninsert_breakpoint): Rewrite.
17859 (uninsert_breakpoints_at): New.
17860 (reinsert_breakpoint): Rewrite.
17861 (reinsert_breakpoints_at): New.
17862 (check_breakpoints): Rewrite.
17863 (breakpoint_here): New.
17864 (breakpoint_inserted_here): New.
17865 (check_mem_read): Adjust.
17866 * mem-break.h (breakpoints_supported, breakpoint_here)
17867 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
17868 (reinsert_breakpoint_by_bp): Delete declaration.
17869 (delete_reinsert_breakpoints): Declare.
17870 (reinsert_breakpoint): Delete declaration.
17871 (reinsert_breakpoints_at): Declare.
17872 (uninsert_breakpoint): Delete declaration.
17873 (uninsert_breakpoints_at): Declare.
17874 (check_breakpoints): Adjust prototype.
17875 * server.h: Adjust include order.
17876 (struct thread_info): Declare here. Add a `last_status' field.
17878 2010-03-23 Michael Snyder <msnyder@vmware.com>
17880 * server.c (crc32): New function.
17881 (handle_query): Add handling for 'qCRC:' request.
17883 2010-03-23 Pedro Alves <pedro@codesourcery.com>
17885 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
17886 lwp had been stopped by a watchpoint.
17888 2010-03-16 Pedro Alves <pedro@codesourcery.com>
17890 * server.h (internal_error): Declare.
17891 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
17892 * utils.c (internal_error): New function.
17894 2010-03-15 Andreas Schwab <schwab@redhat.com>
17896 * configure.srv: Fix typo setting srv_regobj.
17898 2010-03-15 Pedro Alves <pedro@codesourcery.com>
17900 * linux-low.c (fetch_register): Avoid passing a non string literal
17902 (usr_store_inferior_registers): Ditto.
17904 2010-03-14 Pedro Alves <pedro@codesourcery.com>
17906 * linux-low.c (linux_write_memory): Bail out early if peeking
17909 2010-03-14 Pedro Alves <pedro@codesourcery.com>
17911 * linux-low.h (struct lwp_info): New fields
17912 `stopped_by_watchpoint' and `stopped_data_address'.
17913 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
17914 here, and cache them in the lwp object.
17915 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
17917 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
17919 (linux_stopped_by_watchpoint): Rewrite.
17920 (linux_stopped_data_address): Rewrite.
17922 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
17924 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
17925 switching the current inferior, not before.
17927 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
17929 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
17930 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
17931 i386-linux.c and amd64-linux.c.
17932 (reg-i386.o): Removed.
17933 (reg-i386.c): Likewise.
17934 (reg-i386-linux.o): Likewise.
17935 (reg-i386-linux.c): Likewise.
17936 (reg-x86-64.o): Likewise.
17937 (reg-x86-64.c): Likewise.
17938 (reg-x86-64-linux.o): Likewise.
17939 (reg-x86-64-linux.c): Likewise.
17941 (i386.c): Likewise.
17942 (i386-linux.o): Likewise.
17943 (i386-linux.c): Likewise.
17944 (amd64.o): Likewise.
17945 (amd64.c): Likewise.
17946 (amd64-linux.o): Likewise.
17947 (amd64-linux.c): Likewise.
17949 * configure.srv (srv_i386_regobj): New.
17950 (srv_i386_linux_regobj): Likewise.
17951 (srv_amd64_regobj): Likewise.
17952 (srv_amd64_linux_regobj): Likewise.
17953 (srv_i386_32bit_xmlfiles): Likewise.
17954 (srv_i386_64bit_xmlfiles): Likewise.
17955 (srv_i386_xmlfiles): Likewise.
17956 (srv_amd64_xmlfiles): Likewise.
17957 (srv_i386_linux_xmlfiles): Likewise.
17958 (srv_amd64_linux_xmlfiles): Likewise.
17959 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
17960 srv_xmlfiles to $srv_i386_xmlfiles.
17961 (i[34567]86-*-mingw32ce*): Likewise.
17962 (i[34567]86-*-mingw*): Likewise.
17963 (i[34567]86-*-nto*): Likewise.
17964 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
17965 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
17966 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
17967 (x86_64-*-linux*): Likewise.
17969 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
17970 (init_registers_amd64_linux): New.
17971 (x86_arch_setup): Replace init_registers_x86_64_linux with
17972 init_registers_amd64_linux.
17974 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
17976 * configure.ac: Check for libdl. If it is not available link against
17977 static libthread_db.
17978 * configure: Regenerate.
17980 2010-02-22 Pedro Alves <pedro@codesourcery.com>
17984 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
17985 handing a read watchpoint.
17986 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
17988 2010-02-12 Doug Evans <dje@google.com>
17990 * linux-low.c (linux_supports_tracefork_flag): Document.
17991 (linux_look_up_symbols): Add comment.
17993 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
17995 * regcache.c (supply_register): Clear regcache if buf is NULL.
17997 2010-02-02 Nicolas Roche <roche@sourceware.org>
17998 Joel Brobecker <brobecker@adacore.com>
18000 * inferiors.c (find_inferior): Add function documentation.
18001 (unloaded_dll): Handle the case where the unloaded dll has not
18002 been previously registered in the dll list.
18004 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18006 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18007 (thumb2_breakpoint): New.
18008 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18010 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18012 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18013 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18016 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18018 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18020 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18022 * linux-s390-low.c (s390_collect_ptrace_register)
18023 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18025 2010-01-21 Doug Evans <dje@google.com>
18027 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18028 (PTRACE_ARG4_TYPE): New macro.
18029 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18030 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18031 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18032 (usr_store_inferior_registers): Ditto.
18033 (linux_read_memory, linux_write_memory): Ditto.
18034 (linux_test_for_tracefork): Ditto.
18036 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18037 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18039 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18041 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18044 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18046 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18047 prototype to take a regcache. Adjust.
18049 2010-01-20 Pedro Alves <pedro@codesourcery.com>
18051 * regcache.h (struct thread_info): Forward declare.
18052 (struct regcache): New.
18053 (new_register_cache): Adjust prototype.
18054 (get_thread_regcache): Declare.
18055 (free_register_cache): Adjust prototype.
18056 (registers_to_string, registers_from_string): Ditto.
18057 (supply_register, supply_register_by_name, collect_register)
18058 (collect_register_as_string, collect_register_by_name): Ditto.
18059 * regcache.c (struct inferior_regcache_data): Delete.
18060 (get_regcache): Rename to ...
18061 (get_thread_regcache): ... this. Adjust. Switch inferior before
18062 fetching registers.
18063 (regcache_invalidate_one): Adjust.
18064 (regcache_invalidate): Fix prototype.
18065 (new_register_cache): Return the new register cache.
18066 (free_register_cache): Change prototype.
18067 (realloc_register_cache): Adjust.
18068 (registers_to_string): Change prototype to take a regcache. Adjust.
18069 (registers_from_string): Ditto.
18070 (register_data): Ditto.
18071 (supply_register): Ditto.
18072 (supply_register_by_name): Ditto.
18073 (collect_register): Ditto.
18074 (collect_register_as_string): Ditto.
18075 (collect_register_by_name): Ditto.
18076 * server.c (process_serial_event): Adjust.
18077 * linux-low.h (regset_fill_func, regset_store_func): Change
18079 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18081 * linux-low.c (get_stop_pc): Adjust.
18082 (check_removed_breakpoint): Adjust.
18083 (linux_wait_for_event): Adjust.
18084 (linux_resume_one_lwp): Adjust.
18085 (fetch_register): Add regcache parameter. Adjust.
18086 (usr_store_inferior_registers): Ditto.
18087 (regsets_fetch_inferior_registers): Ditto.
18088 (regsets_store_inferior_registers): Ditto.
18089 (linux_fetch_registers, linux_store_registers): Ditto.
18090 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18092 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18094 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18095 prototype to take a regcache.
18096 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18097 * remote-utils.c (convert_ascii_to_int, outreg)
18098 (prepare_resume_reply): Change prototype to take a regcache.
18100 * target.h (struct target_ops) <fetch_registers, store_registers>:
18101 Change prototype to take a regcache.
18102 (fetch_inferior_registers, store_inferior_registers): Change
18103 prototype to take a regcache. Adjust.
18104 * proc-service.c (ps_lgetregs): Adjust.
18105 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18106 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18107 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18108 take a regcache. Adjust.
18109 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18110 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18111 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18112 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18113 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18114 (cris_cannot_fetch_register):
18115 (cris_breakpoint_at): Change prototype to take a regcache.
18117 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18118 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18119 to take a regcache. Adjust.
18120 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18122 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18123 take a regcache. Adjust.
18124 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18125 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18126 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18127 * linux-mips-low.c (mips_get_pc):
18128 (mips_set_pc): Change prototype to take a regcache. Adjust.
18129 (mips_reinsert_addr): Adjust.
18130 (mips_collect_register): Change prototype to take a regcache.
18132 (mips_supply_register):
18133 (mips_collect_register_32bit, mips_supply_register_32bit)
18134 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18135 (mips_store_fpregset): Ditto.
18136 * linux-ppc-low.c (ppc_supply_ptrace_register)
18137 (ppc_supply_ptrace_register): Ditto.
18138 (parse_spufs_run): Adjust.
18139 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18140 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18141 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18142 take a regcache. Adjust.
18143 * linux-s390-low.c (s390_collect_ptrace_register)
18144 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18145 (s390_set_pc): Change prototype to take a regcache. Adjust.
18146 (s390_arch_setup): Adjust.
18147 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18148 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18149 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18150 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18151 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18153 (sparc_breakpoint_at): Adjust.
18154 * linux-xtensa-low.c (xtensa_fill_gregset):
18155 (xtensa_store_gregset):
18156 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18157 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18158 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18159 prototype to take a regcache. Adjust.
18160 * win32-arm-low.c (arm_fetch_inferior_register)
18161 (arm_store_inferior_register): Change prototype to take a
18163 * win32-i386-low.c (i386_fetch_inferior_register)
18164 (i386_store_inferior_register): Change prototype to take a
18166 * win32-low.c (child_fetch_inferior_registers)
18167 (child_store_inferior_registers): Change prototype to take a
18169 (win32_wait): Adjust.
18170 (win32_fetch_inferior_registers): Change prototype to take a
18172 (win32_store_inferior_registers): Adjust.
18173 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18174 store_inferior_register>: Change prototype to take a regcache.
18176 2010-01-20 Doug Evans <dje@google.com>
18178 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18180 (linux_wait_for_event1, linux_init_signals): Ditto.
18181 (W_STOPCODE): Provide definition if missing.
18183 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18185 * linux-low.c (linux_core_of_thread): New.
18186 (compare_ints, show_process, list_threads): New.
18187 (linux_qxfer_osdata): Report threads and cores.
18188 (linux_target_op): Register linux_core_of_thread.
18189 * remote-utils.c (prepare_resume_reply): Report the core.
18190 (buffer_xml_printf): Support %d specifier.
18191 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18193 (handle_query): Handle qXfer:threads. Announce availability
18195 * target.h (struct target_ops): New field core_of_thread.
18197 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18199 * Makefile.in (clean): Remove new generated files.
18200 (reg-s390.o, reg-s390.c): Remove rules.
18201 (reg-s390x.o, reg-s390x.c): Likewise.
18202 (s390-linux32.o, s390-linux32.c): Add rules.
18203 (s390-linux64.o, s390-linux64.c): Likewise.
18204 (s390x-linux64.o, s390x-linux64.c): Likewise.
18205 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18206 * linux-s390-low.c: Include <elf.h>.
18207 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18208 (init_registers_s390): Remove prototype.
18209 (init_registers_s390x): Likewise.
18210 (init_registers_s390_linux32): Add prototype.
18211 (init_registers_s390_linux64): Likewise.
18212 (init_registers_s390x_linux64): Likewise.
18213 (s390_num_regs_3264): New define.
18214 (s390_regmap_3264): New global variable.
18215 (s390_cannot_fetch_register): Remove obsolete check.
18216 (s390_cannot_store_register): Likewise.
18217 (s390_collect_ptrace_register): Handle upper/lower register halves.
18218 (s390_supply_ptrace_register): Likewise.
18219 (s390_fill_gregset): Update to register number changes.
18220 (s390_get_hwcap): New routine.
18221 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18222 Install appropriate regmap and register set.
18224 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18226 * server.c (gdbserver_version): Update copyright year to 2010.
18227 * gdbreplay.c (gdbreplay_version): Likewise.
18229 2009-12-28 Doug Evans <dje@google.com>
18231 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18232 elf/external.h. Include <elf.h> instead but only if necessary.
18234 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18236 * linux-low.c (linux_remove_process): Remove `detaching'
18237 parameter. Don't release/detach from thread_db here.
18238 (linux_kill): Release/detach from thread_db here, ...
18239 (linux_detach): ... and here, before actually detaching.
18240 (linux_wait_1): ... and here, when a process exits.
18241 * thread-db.c (any_thread_of): New.
18242 (thread_db_free): Switch the current inferior to a thread of the
18245 2009-12-21 Doug Evans <dje@google.com>
18247 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18249 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18250 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18251 warning ifndef __NR_tkill. Move setting of errno there too.
18252 Delete unnecessary resetting of errno after syscall.
18253 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18255 * configure.ac: Check for dladdr.
18256 * config.in: Regenerate.
18257 * configure: Regenerate.
18258 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18259 (try_thread_db_load): Update.
18261 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18263 2009-12-18 Doug Evans <dje@google.com>
18265 * event-loop.c: Include unistd.h if it exists.
18267 * linux-low.c (my_waitpid): Move definition away from being in
18268 between linux_tracefork_child/linux_test_for_tracefork.
18270 * gdb_proc_service.h (psaddr_t): Fix type.
18271 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18272 signature to match glibc.
18274 2009-12-16 Doug Evans <dje@google.com>
18276 * linux-low.c (linux_read_memory): Fix argument to read.
18278 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18280 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18281 events, don't leave current_inferior pointing at null.
18283 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18285 * win32-low.c (LOG): Delete.
18286 (OUTMSG): Output to stderr.
18287 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18288 on compile time LOG macro.
18289 (win32_wait): Fix debug output.
18291 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18293 * win32-low.c (win32_add_one_solib): If the dll name is
18294 "ntdll.dll", prepend the system directory to the dll path.
18296 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18298 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18300 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18301 Vladimir Prus <vladimir@codesourcery.com>
18303 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18304 * configure.ac: Check for __mcoldfire__ and set
18305 gdb_cv_m68k_is_coldfire.
18306 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18307 reg-cf.o and reg-m68k.o.
18308 * configure: Regenerated.
18310 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18312 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18313 Pass it to thread_db_free.
18314 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18315 proper `detaching' argument to linux_remove_process.
18316 * linux-low.h (thread_db_free): Add `detaching' parameter.
18317 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18319 (thread_db_free): Add `detaching' parameter. Only
18320 call td_ta_clear_event if detaching from process.
18322 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18324 * thread-db.c (thread_db_free): Fix typo.
18326 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18329 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18331 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18333 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18334 with an i686 compiler.
18335 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18337 * configure: Rebuilt.
18339 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18343 * server.c (handle_search_memory_1): Correct read_addr initialization
18344 in loop for searching subsequent chunks.
18346 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18348 * configure.ac: New --with-libthread-db option.
18349 * thread-db.c: Allow direct dependence on libthread_db.
18350 (thread_db_free): Adjust.
18351 * config.in: Regenerate.
18352 * configure: Likewise.
18354 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18357 * thread-db.c (attach_thread): New function.
18358 (maybe_attach_thread): Return success/failure.
18359 (find_new_threads_callback): Adjust.
18360 (thread_db_find_new_threads): Loop until no new threads.
18362 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18364 * proc-service.c (ps_lgetregs): Formatting.
18366 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18368 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18369 * configure.ac: Adjust.
18370 * linux-low.h (struct process_info_private): Move members to struct
18372 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18373 * linux-low.c (linux_remove_process): Adjust.
18374 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18375 * server.c (handle_query): Move code ...
18376 (handle_monitor_command): ... here. New function.
18377 * target.h (struct target_ops): New member.
18378 * thread-db.c (struct thread_db): New.
18379 (libthread_db_search_path): New variable.
18380 (thread_db_create_event, thread_db_enable_reporting)
18381 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18382 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18383 (try_thread_db_load_1, dladdr_to_soname): New functions.
18384 (try_thread_db_load, thread_db_load_search): New functions.
18385 (thread_db_init): Search for libthread_db.
18386 (thread_db_free): New function.
18387 (thread_db_handle_monitor_command): Likewise.
18388 * config.in: Regenerate.
18389 * configure: Regenerate.
18391 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18393 * spu-low.c (spu_kill): Wait for inferior to terminate.
18394 Call clear_inferiors.
18395 (spu_detach): Call clear_inferiors.
18397 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18399 * aclocal.m4: Regenerate.
18400 * config.in: Likewise.
18401 * configure: Likewise.
18403 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18405 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18406 (parse_spufs_run): New function.
18407 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18408 (ppc_breakpoint_at): Handle SPU breakpoints.
18410 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18412 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18413 (SPUFS_MAGIC): Define.
18414 (spu_enumerate_spu_ids): New function.
18415 (linux_qxfer_spu): New function.
18416 (linux_target_ops): Install linux_qxfer_spu.
18418 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18420 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18421 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18422 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18423 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18424 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18425 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18426 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18427 (init_registers_powerpc_cell32l): Add prototype.
18428 (init_registers_powerpc_cell64l): Likewise.
18429 (ppc_arch_setup): Detect Cell/B.E. architecture.
18431 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18433 * Makefile.in (datarootdir): New variable.
18435 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18437 * linux-low.c (linux_write_memory): Update debugging output.
18438 * Makefile.in (clean): Add new descriptions.
18439 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18440 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18441 * configure.srv: Add new files for arm*-*-linux*.
18442 * linux-arm-low.c: Add new declarations.
18443 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18444 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18445 (HWCAP_VFPv3D16): New.
18446 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18447 instead of __IWMMXT__.
18448 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18449 (arm_arch_setup): New.
18450 (target_regsets): Remove #ifdef. Add VFP regset.
18451 (the_low_target): Use arm_arch_setup.
18453 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18455 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18456 the main thread again.
18458 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18460 Adding Neutrino gdbserver.
18461 * configure: Regenerated.
18462 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18463 * configure.srv (i[34567]86-*-nto*): New target.
18464 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18465 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18466 (nto_comctrl) [__QNX__]: New function.
18467 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18469 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
18471 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18474 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18475 Pedro Alves <pedro@codesourcery.com>
18477 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18478 don't support CONTEXT_EXTENDED_REGISTERS.
18479 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18480 (the_low_target): Install them.
18481 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18482 failing with ERROR_PIPE_NOT_CONNECTED.
18484 2009-06-30 Doug Evans <dje@google.com>
18485 Pierre Muller <muller@ics.u-strasbg.fr>
18487 Add h/w watchpoint support to x86-linux, win32-i386.
18488 * Makefile.in (SFILES): Add i386-low.c
18489 (i386_low_h): Define.
18490 (i386-low.o): Add dependencies.
18491 (linux-x86-low.o): Add i386-low.h dependency.
18492 (win32-i386-low.o): Ditto.
18493 * i386-low.c: New file.
18494 * i386-low.h: New file.
18495 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18496 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18497 * linux-low.c (linux_add_process): Initialize arch_private.
18498 (linux_remove_process): Free arch_private.
18499 (add_lwp): Initialize arch_private.
18500 (delete_lwp): Free arch_private.
18501 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18503 * linux-low.h (process_info_private): New member arch_private.
18504 (lwp_info): New member arch_private.
18505 (linux_target_ops): New members new_process, new_thread,
18507 (ptid_of): New macro.
18508 * linux-x86-low.c: Include stddef.h, i386-low.h.
18509 (arch_process_info): New struct.
18510 (arch_lwp_info): New struct.
18511 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18512 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18513 (i386_dr_low_get_status): New function.
18514 (x86_insert_point, x86_remove_point): New functions.
18515 (x86_stopped_by_watchpoint): New function.
18516 (x86_stopped_data_address): New function.
18517 (x86_linux_new_process, x86_linux_new_thread): New functions.
18518 (x86_linux_prepare_to_resume): New function.
18519 (the_low_target): Add entries for insert_point, remove_point,
18520 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18522 * server.c (debug_hw_points): New global.
18523 (monitor_show_help): Document set debug-hw-points.
18524 (handle_query): Process "set debug-hw-points".
18525 * server.h (debug_hw_points): Declare.
18526 (paddress): Declare.
18527 * utils.c (NUMCELLS, CELLSIZE): New macros.
18528 (get_sell, xsnprintf, paddress): New functions.
18529 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18530 remove_point, stopped_by_watchpoint, stopped_data_address.
18531 * win32-i386-low.c: Include i386-low.h.
18532 (debug_reg_state): Replaces dr.
18533 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18534 (i386_dr_low_get_status): New function.
18535 (i386_insert_point, i386_remove_point): New functions.
18536 (i386_stopped_by_watchpoint): New function.
18537 (i386_stopped_data_address): New function.
18538 (i386_initial_stuff): Update.
18539 (get_thread_context,set_thread_context,i386_thread_added): Update.
18540 (the_low_target): Add entries for insert_point,
18541 remove_point, stopped_by_watchpoint, stopped_data_address.
18542 * win32-low.c (win32_insert_watchpoint): New function.
18543 (win32_remove_watchpoint): New function.
18544 (win32_stopped_by_watchpoint): New function.
18545 (win32_stopped_data_address): New function.
18546 (win32_target_ops): Add entries for insert_watchpoint,
18547 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18548 * win32-low.h (win32_target_ops): New members insert_point,
18549 remove_point, stopped_by_watchpoint, stopped_data_address.
18551 2009-06-25 Pedro Alves <pedro@codesourcery.com>
18553 * server.c (process_serial_event): Re-return unsupported, not
18554 error, if the type isn't recognized. Re-allow supporting only
18555 insert or remove packets. Also call require_running for
18556 breakpoints. Add missing break statement to default case. Tidy.
18557 * target.h (struct target_ops): Rename insert_watchpoint to
18558 insert_point, and remove_watchpoint to remove_point.
18560 * linux-low.h (struct linux_target_ops): Likewise.
18561 * linux-low.c (linux_insert_watchpoint): Rename to ...
18562 (linux_insert_point): ... this. Adjust.
18563 (linux_remove_watchpoint): Rename to ...
18564 (linux_remove_point): ... this. Adjust.
18565 (linux_target_ops): Adjust.
18566 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18567 (cris_insert_point): ... this.
18568 (cris_remove_watchpoint): Rename to ...
18569 (cris_remove_point): ... this.
18570 (the_low_target): Adjust.
18572 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18574 * server.c (handle_v_kill): Pass signal_pid to
18575 kill_inferior if multi_process is zero.
18577 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18579 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18580 * target.h (target_ops): Comment for *_watchpoint to make it clear
18581 the functions can get types '0' and '1'.
18583 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18585 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18586 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18587 * regcache.c (get_regcache): Likewise.
18588 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18589 * win32-low.c (child_fetch_inferior_registers): Remove check for
18592 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18593 Pedro Alves <pedro@codesourcery.com>
18595 * target.h (struct target_ops) <supports_multi_process>: New
18597 (target_supports_multi_process): New.
18598 * server.c (handle_query): Even if GDB reports support, only
18599 enable multi-process if the target also supports it. Report
18600 multi-process support only if the target backend supports it.
18601 * linux-low.c (linux_supports_multi_process): New function.
18602 (linux_target_ops): Install it as target_supports_multi_process
18605 2009-05-24 Doug Evans <dje@google.com>
18607 Global renaming of find_thread_pid to find_thread_ptid.
18608 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18609 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18610 All callers updated.
18612 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18613 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18616 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18617 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18618 (linux_resume_one_lwp): Ditto.
18620 2009-05-23 Doug Evans <dje@google.com>
18622 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18623 from struct inferior_list_entry * to struct lwp_info *.
18624 All callers updated.
18626 2009-05-13 Doug Evans <dje@google.com>
18628 * linux-x86-low.c: Don't include assert.h.
18629 (x86_siginfo_fixup): Use fatal, not assert.
18630 (x86_arch_setup): Fix comment.
18632 2009-05-12 Doug Evans <dje@google.com>
18634 Biarch support for i386/amd64 gdbserver.
18635 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18636 Add linux-x86-low.c.
18637 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18638 (linux-x86-low.o): Add.
18639 * linux-x86-64-low.c: Delete.
18640 * linux-i386-low.c: Delete.
18641 * linux-x86-low.c: New file.
18642 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18644 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18646 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18647 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18648 (linux_child_pid_to_exec_file): New function.
18649 (elf_64_header_p, elf_64_file_p): New functions.
18650 (siginfo_fixup): New function.
18651 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18652 give target a chance to convert layout.
18653 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18654 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18656 2009-05-07 Doug Evans <dje@google.com>
18658 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18659 (regsets_store_inferior_registers): Ditto.
18661 2009-05-06 Pedro Alves <pedro@codesourcery.com>
18665 * linux-low.c (must_set_ptrace_flags): Delete.
18666 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18668 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18669 `lwp->must_set_ptrace_flags' instead.
18670 (linux_wait_for_event_1): Set ptrace options here.
18671 (linux_wait_1): ... not here.
18673 2009-04-30 Doug Evans <dje@google.com>
18675 * inferiors.c (started_inferior_callback): New function.
18676 (attached_inferior_callback): New function.
18677 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18678 * server.c (print_started_pid, print_attached_pid): New functions.
18679 (detach_or_kill_for_exit): New function.
18680 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18681 * server.h (have_started_inferiors_p): Declare.
18682 (have_attached_inferiors_p): Declare.
18684 * inferiors.c (remove_process): Fix memory leak, free process.
18685 * linux-low.c (linux_remove_process): New function.
18686 (linux_kill): Call it instead of remove_process.
18687 (linux_detach, linux_wait_1): Ditto.
18689 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18691 * configure.srv: Add x86 Windows CE target.
18693 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18695 * inferiors.c (get_thread_process): Make global.
18696 * server.h (get_thread_process): Add prototype.
18697 * thread-db.c (find_one_thread): Use get_thread_process
18698 instead of current_process.
18699 (thread_db_get_tls_address): Do not crash if called when
18700 thread layer is not yet initialized.
18702 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18704 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18705 * spu-low.c (current_tid): Rename to ...
18706 (current_ptid): ... this.
18707 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18708 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18709 ptid_get_lwp (current_ptid) instead of current_tid.
18710 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18711 instead of current_tid. Use find_process_pid to verify pid
18712 argument is valid. Pass proper argument to remove_process.
18713 (spu_thread_alive): Compare current_ptid instead of current_tid.
18714 (spu_resume): Likewise.
18716 2009-04-02 Pedro Alves <pedro@codesourcery.com>
18718 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18721 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18723 Implement the multiprocess extensions, and add linux multiprocess
18726 * server.h (ULONGEST): Declare.
18727 (struct ptid, ptid_t): New.
18728 (minus_one_ptid, null_ptid): Declare.
18729 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18730 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18731 (struct inferior_list_entry): Change `id' type from unsigned from
18733 (struct sym_cache, struct breakpoint, struct
18734 process_info_private): Forward declare.
18735 (struct process_info): Declare.
18736 (current_process): Declare.
18737 (all_processes): Declare.
18738 (initialize_inferiors): Declare.
18739 (add_thread): Adjust to use ptid_t.
18740 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18741 (add_process, remove_process, find_thread_pid): Declare.
18742 (find_inferior_id): Adjust to use ptid_t.
18743 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18744 (multi_process): Declare.
18745 (push_event): Adjust to use ptid_t.
18746 (read_ptid, write_ptid): Declare.
18747 (prepare_resume_reply): Adjust to use ptid_t.
18748 (clear_symbol_cache): Declare.
18749 * inferiors.c (all_processes): New.
18750 (null_ptid, minus_one_ptid): New.
18751 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18752 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18753 (add_thread): Change unsigned long to ptid. Remove gdb_id
18755 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18756 (gdb_id_to_thread): Rename to ...
18757 (find_thread_pid): ... this. Change unsigned long to ptid.
18758 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18759 (loaded_dll, pull_pid_from_list): Adjust.
18760 (add_process, remove_process, find_process_pid)
18761 (get_thread_process, current_process, initialize_inferiors): New.
18762 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18763 (struct target_waitstatus) <related_pid>: Ditto.
18764 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18765 return type to int.
18766 (struct target_ops) <join>: Add `pid' argument.
18767 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18768 (struct target_ops) <wait>: Add `ptid' field. Change return type
18770 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18771 (mywait): Add `ptid' argument. Change return type to ptid_t.
18772 (target_pid_to_str): Declare.
18773 * target.c (set_desired_inferior): Adjust to use ptids.
18774 (mywait): Add new `ptid' argument. Adjust.
18775 (target_pid_to_str): New.
18776 * mem-break.h (free_all_breakpoints): Declare.
18777 * mem-break.c (breakpoints): Delelete.
18778 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18779 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18780 to use per-process breakpoint list.
18781 (free_all_breakpoints): New.
18782 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18783 (symbol_cache, all_symbols_looked_up): Delete.
18785 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18787 (prepare_resume_reply): Change ptid argument's type from unsigned
18788 long to ptid_t. Adjust. Implement W;process and X;process.
18789 (free_sym_cache, clear_symbol_cache): New.
18790 (look_up_one_symbol): Adjust to per-process symbol cache. *
18791 * server.c (cont_thread, general_thread, step_thread): Change type
18793 (attached): Delete.
18794 (multi_process): New.
18795 (last_ptid): Change type to ptid_t.
18796 (struct vstop_notif) <ptid>: Change type to ptid_t.
18797 (queue_stop_reply, push_event): Change `ptid' argument's type to
18799 (discard_queued_stop_replies): Add `pid' argument.
18800 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18801 changes. Don't reference the `attached' global.
18802 (attach_inferior): Adjust to mywait interface changes.
18803 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18804 features. Handle and report "multiprocess+". Handle
18806 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18808 (handle_v_kill): New.
18809 (handle_v_stopped): Adjust to use target_pid_to_str.
18810 (handle_v_requests): Allow multiple attaches and runs when
18811 multiprocess extensions are in effect. Handle "vKill".
18812 (myresume): Adjust to use ptids.
18813 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18814 (handle_status): Adjust to discard_queued_stop_replies interface
18816 (first_thread_of, kill_inferior_callback)
18817 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18818 (main): Call initialize_inferiors. Adjust to use ptids, killing
18819 and detaching from all inferiors. Handle multiprocess packet
18821 * linux-low.h: Include gdb_proc_service.h.
18822 (struct process_info_private): New.
18823 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18824 <lwpid_of>: Use ptid_get_lwp.
18825 (get_lwp_thread): Adjust.
18826 (struct lwp_info): Add `dead' member.
18827 (find_lwp_pid): Declare.
18828 * linux-low.c (thread_db_active): Delete.
18829 (new_inferior): Adjust comment.
18830 (inferior_pid): Delete.
18831 (linux_add_process): New.
18832 (handle_extended_wait): Adjust.
18833 (add_lwp): Change unsigned long to ptid.
18834 (linux_create_inferior): Add process to processes table. Adjust
18835 to use ptids. Don't set new_inferior here.
18836 (linux_attach_lwp): Rename to ...
18837 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18838 it. Adjust to use ptids.
18839 (linux_attach_lwp): New.
18840 (linux_attach): Add process to processes table. Don't set
18842 (struct counter): New.
18843 (second_thread_of_pid_p, last_thread_of_process_p): New.
18844 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18845 multiple processes.
18846 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18847 processes. Remove process from process table.
18848 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18849 to multiple processes.
18850 (any_thread_of): New.
18851 (linux_detach): Add `pid' argument, and handle it. Remove process
18852 from processes table.
18853 (linux_join): Add `pid' argument. Handle it.
18854 (linux_thread_alive): Change unsighed long argument to ptid_t.
18855 Consider dead lwps as not being alive.
18856 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
18857 threads we're not interested in.
18858 (same_lwp, find_lwp_pid): New.
18859 (linux_wait_for_lwp): Change `pid' argument's type from int to
18861 (linux_wait_for_event): Rename to ...
18862 (linux_wait_for_event_1): ... this. Change `pid' argument's type
18863 from int to ptid_t. Adjust.
18864 (linux_wait_for_event): New.
18865 (linux_wait_1): Add `ptid' argument. Change return type to
18866 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
18867 that exit from the process table.
18868 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
18870 (mark_lwp_dead): New.
18871 (wait_for_sigstop): Adjust to use ptids. If a process exits while
18872 stopping all threads, mark its main lwp as dead.
18873 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
18875 (fetch_register, usr_store_inferior_registers)
18876 (regsets_fetch_inferior_registers)
18877 (regsets_store_inferior_registers, linux_read_memory)
18878 (linux_write_memory): Inline `inferior_pid'.
18879 (linux_look_up_symbols): Adjust to use per-process
18880 `thread_db_active'.
18881 (linux_request_interrupt): Adjust to use ptids.
18882 (linux_read_auxv): Inline `inferior_pid'.
18883 (initialize_low): Don't reference thread_db_active.
18884 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
18885 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
18886 (ps_getpid): Return the pid of the current inferior.
18887 * thread-db.c (proc_handle, thread_agent): Delete.
18888 (thread_db_create_event, thread_db_enable_reporting): Adjust to
18890 (find_one_thread): Change argument type to ptid_t. Adjust to
18892 (maybe_attach_thread): Adjust to per-process data and ptids.
18893 (thread_db_find_new_threads): Ditto.
18894 (thread_db_init): Ditto.
18895 * spu-low.c (spu_create_inferior, spu_attach): Add process to
18896 processes table. Adjust to use ptids.
18897 (spu_kill, spu_detach): Adjust interface. Remove process from
18899 (spu_join, spu_thread_alive): Adjust interface.
18900 (spu_wait): Adjust interface. Remove process from processes
18901 table. Adjust to use ptids.
18902 * win32-low.c (current_inferior_tid): Delete.
18903 (current_inferior_ptid): New.
18904 (debug_event_ptid): New.
18905 (thread_rec): Take a ptid. Adjust.
18906 (child_add_thread): Add `pid' argument. Adjust to use ptids.
18907 (child_delete_thread): Ditto.
18908 (do_initial_child_stuff): Add `attached' argument. Add process to
18910 (child_fetch_inferior_registers, child_store_inferior_registers):
18912 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
18913 (win32_attach): Pass 1 to do_initial_child_stuff.
18914 (win32_kill): Adjust interface. Remove process from processes
18916 (win32_detach): Ditto.
18917 (win32_join): Adjust interface.
18918 (win32_thread_alive): Take a ptid.
18919 (win32_resume): Adjust to use ptids.
18920 (get_child_debug_event): Ditto.
18921 (win32_wait): Adjust interface. Remove exiting process from
18924 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18926 Non-stop mode support.
18928 * server.h (non_stop): Declare.
18929 (gdb_client_data, handler_func): Declare.
18930 (delete_file_handler, add_file_handler, start_event_loop):
18932 (handle_serial_event, handle_target_event, push_event)
18933 (putpkt_notif): Declare.
18934 * target.h (enum resume_kind): New.
18935 (struct thread_resume): Replace `step' field by `kind' field.
18936 (TARGET_WNOHANG): Define.
18937 (struct target_ops) <wait>: Add `options' argument.
18938 <supports_non_stop, async, start_non_stop>: New fields.
18939 (target_supports_non_stop, target_async): New.
18940 (start_non_stop): Declare.
18941 (mywait): Add `options' argument.
18942 * target.c (mywait): Add `options' argument. Print child exit
18943 notifications here.
18944 (start_non_stop): New.
18945 * server.c (non_stop, own_buf, mem_buf): New globals.
18946 (struct vstop_notif): New.
18947 (notif_queue): New global.
18948 (queue_stop_reply, push_event, discard_queued_stop_replies)
18949 (send_next_stop_reply): New.
18950 (start_inferior): Adjust to use resume_kind. Adjust to mywait
18952 (attach_inferior): In non-stop mode, don't wait for the target
18954 (handle_general_set): Handle QNonStop.
18955 (handle_query): When handling qC, return the current general
18956 thread, instead of the first thread of the list.
18957 (handle_query): If the backend supports non-stop mode, include
18958 QNonStop+ in the qSupported query response.
18959 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
18961 (handle_v_attach, handle_v_run): Handle non-stop mode.
18962 (handle_v_stopped): New.
18963 (handle_v_requests): Report support for vCont;t. Handle vStopped.
18964 (myresume): Adjust to use resume_kind. Handle non-stop.
18965 (queue_stop_reply_callback): New.
18966 (handle_status): Handle non-stop mode.
18967 (main): Clear non_stop flag on reconnection. Use the event-loop.
18968 Refactor serial protocol handling from here ...
18969 (process_serial_event): ... to this new function. When GDB
18970 selects any thread, select one here. In non-stop mode, wait until
18971 GDB acks all pending events before exiting.
18972 (handle_serial_event, handle_target_event): New.
18973 * remote-utils.c (remote_open): Install remote_desc in the event
18975 (remote_close): Remove remote_desc from the event loop.
18976 (putpkt_binary): Rename to...
18977 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
18978 (putpkt_binary): New as wrapper around putpkt_binary_1.
18979 (putpkt_notif): New.
18980 (prepare_resume_reply): In non-stop mode, don't change the
18982 * event-loop.c: New.
18983 * Makefile.in (OBJ): Add event-loop.o.
18984 (event-loop.o): New rule.
18986 * linux-low.h (pid_of): Moved here.
18988 (get_lwp_thread): Use lwpid_of.
18989 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
18990 * linux-low.c (pid_of): Delete.
18991 (inferior_pid): Use lwpid_of.
18992 (linux_event_pipe): New.
18993 (target_is_async_p): New.
18995 (handle_extended_wait): Use lwpid_of.
18996 (add_lwp): Don't set lwpid field.
18997 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
18998 (linux_kill_one_lwp): If killing a running lwp, stop it first.
18999 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19000 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19001 first. Adjust to linux_wait_for_event interface changes. Use
19003 (linux_detach): Don't delete the main lwp here.
19004 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19005 (status_pending_p): Don't consider explicitly suspended lwps.
19006 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19007 pointer. Add OPTIONS argument. Change return type to int. Use
19008 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19009 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19010 pointer. Add status pointer argument. Return a pid instead of a
19011 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19012 changes. In non-stop mode, don't switch to a random thread.
19013 (linux_wait): Rename to...
19014 (linux_wait_1): ... this. Add target_options argument, and handle
19015 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19016 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19017 clean exit and signal exit code. Don't stop all threads in
19018 non-stop mode. In all-stop mode, only stop all threads when
19019 reporting a stop to GDB. Handle explicit thread stop requests.
19020 (async_file_flush, async_file_mark): New.
19022 (send_sigstop): Use lwpid_of.
19023 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19024 interface changes. In non-stop mode, don't switch to a random
19026 (linux_resume_one_lwp): Use lwpid_of.
19027 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19028 (linux_resume_one_thread): ... this. Handle resume_stop. In
19029 non-stop mode, don't look for pending flag in all threads.
19030 (resume_status_pending_p): Don't consider explicitly suspended
19032 (my_waitpid): Reimplement. Emulate __WALL.
19033 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19035 (sigchld_handler, linux_supports_non_stop, linux_async)
19036 (linux_start_non_stop): New.
19037 (linux_target_ops): Register linux_supports_non_stop, linux_async
19038 and linux_start_non_stop.
19039 (initialize_low): Install SIGCHLD handler.
19040 * thread-db.c (thread_db_create_event, find_one_thread)
19041 (thread_db_get_tls_address): Use lwpid_of.
19042 * win32-low.c (win32_detach): Adjust to use resume_kind.
19043 (win32_wait): Add `options' argument.
19044 * spu-low.c (spu_resume): Adjust to use resume_kind.
19045 (spu_wait): Add `options' argument.
19047 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19049 Decouple target code from remote protocol.
19051 * target.h (enum target_waitkind): New.
19052 (struct target_waitstatus): New.
19053 (struct target_ops) <wait>: Return an unsigned long. Take a
19054 target_waitstatus pointer instead of a char pointer.
19055 (mywait): Likewise.
19056 * target.c (mywait): Change prototype to return an unsigned long.
19057 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19058 * server.h (thread_from_wait, old_thread_from_wait): Delete
19060 (prepare_resume_reply): Change prototype to take a
19062 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19063 (last_status, last_ptid): New.
19064 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19065 pid instead of a signal.
19066 (attach_inferior): Remove "status" and "signal" parameters.
19068 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19070 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19071 (handle_v_requests, myresume): Remove "status" and "signal"
19072 parameters. Adjust.
19073 (handle_status): New.
19074 (main): Delete local `status'. Adjust.
19075 * remote-utils.c: Include target.h.
19076 (prepare_resume_reply): Change prototype to take a
19077 target_waitstatus. Adjust.
19079 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19081 * spu-low.c (spu_wait): Adjust.
19082 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19084 (win32_wait): Adjust.
19086 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19088 * target.h (struct thread_resume): Delete leave_stopped member.
19089 (struct target_ops): Add a `n' argument to the `resume' callback.
19090 * server.c (start_inferior): Adjust.
19091 (handle_v_cont, myresume): Adjust.
19092 * linux-low.c (check_removed_breakpoint): Adjust to resume
19093 interface change, and to removed leave_stopped field.
19094 (resume_ptr): Delete.
19095 (struct thread_resume_array): New.
19096 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19097 resume interface change.
19098 (linux_continue_one_thread, linux_queue_one_thread)
19099 (resume_status_pending_p): Check if the resume field is NULL
19100 instead of checking the leave_stopped member.
19101 (linux_resume): Adjust to the target resume interface change.
19102 * spu-low.c (spu_resume): Adjust to the target resume interface
19104 * win32-low.c (win32_detach, win32_resume): Ditto.
19106 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19108 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19110 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19112 (linux_continue_one_thread): Only preserve the stepping flag if
19113 there's a pending breakpoint.
19115 2009-03-31 Pedro Alves <pedro@codesourcery.com>
19117 * server.c (main): After the inferior having exited, call
19118 remote_close before exiting gdbserver.
19120 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19122 Fix size of FPSCR in Power 7 processors.
19123 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19124 (PPC_FEATURE_HAS_DFP): New #define.
19125 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19128 2009-03-23 Pedro Alves <pedro@codesourcery.com>
19130 * server.c (handle_query) Whitespace and formatting.
19132 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19134 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19135 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19136 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19137 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19138 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19139 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19140 Makefile.in, configure.ac: Fix whitespace throughout.
19141 * configure: Regenerate.
19143 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19145 * inferiors.c (find_inferior): Make it safe for the callback
19146 function to delete the currently iterated inferior.
19148 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19150 * Makefile.in (linuw_low_h): Move higher.
19151 (thread-db.o): Depend on $(linux_low_h).
19153 2009-03-17 Pedro Alves <pedro@codesourcery.com>
19155 Rename "process" to "lwp" throughout.
19157 * linux-low.c (all_processes): Rename to...
19158 (all_lwps): ... this.
19159 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19160 (add_process): Rename to ...
19161 (add_lwp): ... this. Adjust.
19162 (linux_create_inferior): Adjust.
19163 (linux_attach_lwp): Adjust.
19164 (linux_attach): Adjust.
19165 (linux_kill_one_process): Rename to ...
19166 (linux_kill_one_lwp): ... this. Adjust.
19167 (linux_kill): Adjust.
19168 (linux_detach_one_process): Rename to ...
19169 (linux_detach_one_lwp): ... this. Adjust.
19170 (linux_detach): Adjust.
19171 (check_removed_breakpoint): Adjust.
19172 (status_pending_p): Adjust.
19173 (linux_wait_for_process): Rename to ...
19174 (linux_wait_for_lwp): ... this. Adjust.
19175 (linux_wait_for_event): Adjust.
19176 (send_sigstop): Adjust.
19177 (wait_for_sigstop): Adjust.
19178 (stop_all_processes): Rename to ...
19179 (stop_all_lwps): ... this.
19180 (linux_resume_one_process): Rename to ...
19181 (linux_resume_one_lwp): ... this. Adjust.
19182 (linux_set_resume_request, linux_continue_one_thread)
19183 (linux_queue_one_thread, resume_status_pending_p)
19184 (usr_store_inferior_registers, regsets_store_inferior_registers)
19185 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19187 * linux-low.h (get_process): Rename to ...
19188 (get_lwp): ... this. Adjust.
19189 (get_thread_process): Rename to ...
19190 (get_thread_lwp): ... this. Adjust.
19191 (get_process_thread): Rename to ...
19192 (get_lwp_thread): ... this. Adjust.
19193 (struct process_info): Rename to ...
19194 (struct lwp_info): ... this.
19195 (all_processes): Rename to ...
19196 (all_lwps): ... this.
19197 * proc-service.c (ps_lgetregs): Adjust.
19198 * thread-db.c (thread_db_create_event, find_one_thread)
19199 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19201 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19203 * server.c (handle_query): Handle "qAttached".
19205 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19207 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19208 GPLv3, update license URL.
19210 2009-03-01 Doug Evans <dje@google.com>
19212 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19213 (server_h): Add gdb_signals.h.
19214 (signals.o): Update.
19215 * server.h (target_signal_from_host,target_signal_to_host_p)
19216 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19218 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19220 * remote-utils.c (getpkt): Also generate remote-debug
19221 information if noack_mode is set.
19223 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19225 * server.c (handle_query): Report qXfer:siginfo:read and
19226 qXfer:siginfo:write as supported and handle them.
19227 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19228 * linux-low.c (linux_xfer_siginfo): New.
19229 (linux_target_ops): Set it.
19231 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19233 * server.c (gdbserver_usage): Mention --remote-debug.
19234 (main): Accept '--remote-debug' switch.
19236 2009-01-18 Doug Evans <dje@google.com>
19238 * regcache.c (new_register_cache): No need to check result of xcalloc.
19239 * server.c (handle_search_memory): Back out calls to xmalloc,
19240 result is checked and error is returned to user upon failure.
19241 (handle_query): Ditto. Add more checks for result of malloc.
19242 (handle_v_cont): Check result of malloc, report error back to
19244 (handle_v_run): Ditto. Call freeargv.
19245 * server.h (freeargv): Declare.
19246 * utils.c (freeargv): New fn.
19248 2009-01-15 Doug Evans <dje@google.com>
19250 * gdbreplay.c (perror_with_name): Make arg const char *.
19251 * server.h (target_signal_to_name): Make return type const char *.
19252 * thread-db.c (thread_db_err_str): Make return type const char *.
19253 * utils.c (perror_with_name): Make arg const char *.
19255 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19257 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19258 when handling a EXIT_PROCESS_DEBUG_EVENT.
19260 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19262 * gdbreplay.c (gdbreplay_version): Update copyright year.
19263 * server.c (gdbserver_version): Likewise.
19265 2009-01-05 Doug Evans <dje@google.com>
19267 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19268 (handle_extended_wait): Improve comment.
19270 2008-12-13 Doug Evans <dje@google.com>
19272 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19273 * server.h (ATTR_MALLOC): New macro.
19274 (xmalloc,xcalloc,xstrdup): Declare.
19275 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19276 * inferiors.c: Ditto.
19277 * linux-low.c: Ditto.
19278 * mem-break.c: Ditto.
19279 * regcache.c: Ditto.
19280 * remote-utils.c: Ditto.
19283 * win32-low.c: Ditto.
19285 2008-12-12 Doug Evans <dje@google.com>
19287 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19288 in debugging printf.
19290 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19292 2008-12-09 Doug Evans <dje@google.com>
19294 * linux-low.h (struct process_info): Delete member tid, unused.
19295 * thread-db.c (find_one_thread): Update.
19296 (maybe_attach_thread): Update.
19298 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19300 * target.h (struct target_ops): Add qxfer_osdata member.
19301 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19303 (linux_qxfer_osdata): New functions.
19304 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19306 * server.c (handle_query): Handle "qXfer:osdata:read:".
19307 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19308 (buffer_xml_printf): New functions.
19309 * server.h (struct buffer): New.
19310 (buffer_grow_str, buffer_grow_str0): New macros.
19311 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19312 (buffer_xml_printf): Declare.
19314 2008-11-24 Doug Evans <dje@google.com>
19316 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19318 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19320 * server.c (handle_v_run): Always use the supplied argument list.
19322 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19324 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19325 (xtensa_regmap_table): Add entry for scompare1.
19327 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19329 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19330 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19331 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19332 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19333 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19334 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19335 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19336 XML target descriptions.
19337 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19338 when inferior is running on an ISA 2.05 or later processor. Add
19339 special case to return offset for full 64-bit slot of FPSCR when
19342 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19344 * Makefile.in (SFILES, clean): Added sparc64 files.
19345 (reg-sparc64.o, reg-sparc64.c): New.
19346 * configure.srv (sparc*-*-linux*): New configuration.
19347 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19348 syscall arguments for SPARC.
19349 (regsets_store_inferior_registers): Likewise.
19350 * linux-sparc-low.c: New file.
19352 2008-10-21 Doug Evans <dje@google.com>
19354 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19355 (READLINE_DIR,READLINE_DEP): Delete.
19356 (INTERNAL_CFLAGS): Update.
19357 (LINTFLAGS): Update.
19359 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19361 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19362 whole argv from the last run, not just argv[0].
19364 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19366 * regcache.c (new_register_cache): Return NULL if the register
19367 cache size isn't known yet.
19368 (free_register_cache): Avoid dereferencing a NULL regcache.
19370 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19372 * configure.srv: Merge MIPS and MIPS64.
19374 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19376 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19378 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19380 * Makefile.in: Add required vsx dependencies.
19382 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19383 Declare init_registers_powerpc_vsx32l.
19384 Declare init_registers_powerpc_vsx64l.
19385 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19386 (ppc_arch_setup): Check for VSX in hwcap.
19387 (ppc_fill_vsxregset): New function.
19388 (ppc_store_vsxregset): New function.
19389 Add new VSX entry in regset_info target_regsets.
19391 * configure.srv: Add new VSX dependencies.
19393 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19395 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19396 (remote_open): Set or clear transport_is_reliable.
19397 (putpkt_binary): Don't expect acks in noack mode.
19398 (getpkt): Don't send ack/nac in noack mode.
19399 * server.c (handle_general_set): Handle QStartNoAckMode.
19400 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19402 (main): Reset noack_mode on every connection.
19403 * server.h (noack_mode): Declare.
19405 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19407 * Makefile.in (GDBREPLAY_OBS): New variable.
19408 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19410 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19411 Daniel Jacobowitz <dan@codesourcery.com>
19413 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19414 (usr_store_inferior_registers): Likewise.
19415 (regsets_store_inferior_registers): Likewise.
19417 2008-07-31 Rolf Jansen <rj@surtec.com>
19418 Pedro Alves <pedro@codesourcery.com>
19420 * configure.ac: Check for memmem declaration.
19421 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19422 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19423 (disable_packet_qfThreadInfo): Unconditionally compile.
19424 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19425 * configure, config.in: Regenerate.
19427 2008-07-28 Doug Kwan <dougkwan@google.com>
19429 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19430 (linux_write_memory): Remove declaration of errno.
19432 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19434 * linux-low.c (handle_extended_wait): Do not use "status"
19435 variable uninitialized.
19437 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19439 * server.c (handle_v_attach): Inhibit reporting dll changes.
19441 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19443 * remote-utils.c (prepare_resume_reply): If requested, don't
19444 output "thread:TID" in the T stop reply.
19446 * server.c (disable_packet_vCont, disable_packet_Tthread)
19447 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19448 (handle_query): If requested, disable support for qC, qfThreadInfo
19450 (handle_v_requests): If requested, disable support for vCont.
19451 (gdbserver_show_disableable): New.
19452 (main): Handle --disable-packet and --disable-packet=LIST.
19454 * server.h (disable_packet_vCont, disable_packet_Tthread)
19455 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19457 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19459 * server.c (gdbserver_usage): Mention --version.
19461 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19463 * Makefile.in (gdbreplay.o): New rule.
19465 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19467 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19468 message, not gdbserver.
19470 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
19471 Nathan Sidwell <nathan@codesourcery.com>
19472 Joseph Myers <joseph@codesourcery.com>
19474 * acinclude.m4: Include ../../config/acx.m4.
19475 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19476 * configure, config.in: Regenerate.
19477 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19478 * server.c (gdbserver_version): Print PKGVERSION.
19479 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19480 (main): Adjust gdbserver_usage calls.
19481 * gdbreplay.c (version, host_name): Add declarations.
19482 (gdbreplay_version, gdbreplay_usage): New.
19483 (main): Accept --version and --help options.
19485 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19487 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19488 (arm_breakpoint_at): Handle Thumb.
19489 (the_low_target): Add comment.
19491 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19493 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19495 2008-05-09 Doug Evans <dje@google.com>
19497 * server.h (decode_search_memory_packet): Declare.
19498 * remote-utils.c (decode_search_memory_packet): New fn.
19499 * server.c (handle_search_memory_1): New fn.
19500 (handle_search_memory): New fn.
19501 (handle_query): Process qSearch:memory packets.
19503 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19505 * regcache.c (registers_length): Remove.
19506 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19507 full register packet.
19508 * regcache.h (registers_length): Remove prototype.
19509 * server.h (PBUFSIZ): Define to 16384.
19511 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19513 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19514 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19515 powerpc-64l.o, and powerpc-altivec64l.o.
19516 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19517 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19518 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19519 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19520 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19523 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19524 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19525 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19526 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19527 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19528 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19529 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19530 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19531 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19532 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19535 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19536 (init_registers_powerpc_32l): ... this new prototype.
19537 (init_registers_powerpc_32): Remove, replace by ...
19538 (init_registers_powerpc_altivec32l): ... this new prototype.
19539 (init_registers_powerpc_e500): Remove, replace by ...
19540 (init_registers_powerpc_e500l): ... this new prototype.
19541 (init_registers_ppc64): Remove, replace by ...
19542 (init_registers_powerpc_64l): ... this new prototype.
19543 (init_registers_powerpc_64): Remove, replace by ...
19544 (init_registers_powerpc_altivec64l): ... this new prototype.
19545 (ppc_num_regs): Set to 73.
19546 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19547 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19548 (ppc_cannot_store_register): Handle orig_r3 and trap.
19549 (ppc_arch_setup): Update init_registers_... calls.
19550 (ppc_fill_gregset): Handle orig_r3 and trap.
19552 * inferiors.c (clear_inferiors): Reset current_inferior.
19554 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
19556 * acinclude.m4: Add override.m4.
19557 * configure: Regenerate.
19559 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19561 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19562 initial call to init_register_ppc64.
19564 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19566 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19567 single powerpc*-*-linux* case.
19568 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19570 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19572 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
19573 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
19575 * linux-ppc-low.c: Include <elf.h>.
19576 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19577 (ppc_hwcap): New global variable.
19578 (ppc_regmap): Remove __SPE__ #ifdef sections.
19579 (ppc_regmap_e500): New global variable.
19580 (ppc_cannot_store_register): Update __SPE__ special case.
19581 (ppc_get_hwcap): New function.
19582 (ppc_arch_setup): Use it to determine whether inferior supports
19583 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19584 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19585 Do not access registers if target does not support AltiVec.
19586 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19587 Do not access registers if target does not support SPE.
19588 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19590 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19592 * linux-low.c (disabled_regsets, num_regsets): New.
19593 (use_regsets_p): Delete.
19594 (linux_wait_for_process): Clear disabled_regsets.
19595 (regsets_fetch_inferior_registers): Check and set it.
19596 (regsets_store_inferior_registers): Likewise.
19597 (linux_fetch_registers, linux_store_registers): Do not use
19599 (initialize_low): Allocate disabled_regsets.
19601 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19603 * Makefile.in (LIBOBJS): New.
19604 (OBS): Use LIBOBJS.
19605 (memmem.o): New rule.
19606 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19607 * configure: Regenerated.
19609 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19611 * server.c (handle_query): Never return "unsupported" for
19612 qXfer:features:read queries.
19614 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19616 * server.c (get_features_xml): Fix inverted condition.
19617 (handle_query): Always support qXfer:feature:read.
19619 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19621 * server.c (wrapper_argv): New.
19622 (start_inferior): Handle wrapper_argv. If set, expect an extra
19624 (gdbserver_usage): Document --wrapper.
19625 (main): Parse --wrapper.
19627 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19629 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19630 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19631 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19632 (ppc_set_pc): Likewise.
19633 (ppc_arch_setup): New function.
19634 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19635 of collect_register.
19636 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
19638 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19640 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19641 instead of linux-ppc64-low.o.
19642 * linux-ppc64-low.c: Remove file.
19643 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19644 (linux-ppc64-low.o): Remove rule.
19646 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19647 (init_registers_powerpc_64): Likewise.
19648 (ppc_regmap): Conditionally define depending on __powerpc64__.
19649 (ppc_cannot_store_register): Do not special-case "fpscr" when
19650 compiled on __powerpc64__.
19651 (ppc_collect_ptrace_register): New function.
19652 (ppc_supply_ptrace_register): New function.
19653 (ppc_breakpoint): Change type to "unsigned int".
19654 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19655 (the_low_target): Conditionally provide initializers for the
19656 arch_setup member depending on __powerpc64__. Install
19657 collect_ptrace_register and supply_ptrace_register members.
19659 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19661 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19662 * server.c (gdbserver_xmltarget): Define.
19663 (get_features_xml): Use it to replace "target.xml" and arch_string.
19665 * configure.srv: Remove srv_xmltarget. Add XML files that were
19666 mentioned there to srv_xmlfiles instead. Remove conditional tests
19667 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19668 srv_xmlfiles and srv_regobj to include all possible choices.
19669 * configure.ac (srv_xmltarget): Remove.
19670 (srv_xmlfiles): Do not add "target.xml".
19671 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19672 checks for supplementary target information.
19673 * configure: Regenerate.
19674 * Makefile.in (XML_TARGET): Remove.
19675 (target.xml): Remove rule.
19676 (clean): Do not clean up target.xml.
19677 (.PRECIOUS): Do not mention target.xml.
19679 * target.h (struct target_ops): Remove arch_string member.
19680 * linux-low.c (linux_arch_string): Remove.
19681 (linux_target_ops): Remove arch_string initializer.
19682 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19683 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19684 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19685 * spu-low.c (spu_arch_string): Remove.
19686 (spu_target_ops): Remove arch_string initializer.
19687 * win32-low.c (win32_arch_string): Remove.
19688 (win32_target_ops): Remove arch_string initializer.
19689 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19690 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19691 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19693 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19695 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19696 by collect_ptrace_register and supply_ptrace_register hooks.
19697 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19698 instead of checking for the_low_target.left_pad_xfer.
19699 (usr_store_inferior_registers): Use collect_ptrace_register callback
19700 instead of checking for the_low_target.left_pad_xfer.
19702 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19703 (s390_supply_ptrace_register): Likewise.
19704 (s390_fill_gregset): Call s390_collect_ptrace_register.
19705 (the_low_target): Update.
19707 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19708 (ppc_supply_ptrace_register): Likewise.
19709 (the_low_target): Update.
19711 * linux-i386-low.c (the_low_target): Update.
19712 * linux-x86-64-low.c (the_low_target): Update.
19714 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19716 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19717 reg-s390.o and reg-s390x.o.
19719 * linux-low.c (new_inferior): New global variable.
19720 (linux_create_inferior, linux_attach): Set it.
19721 (linux_wait_for_process): Call the_low_target.arch_setup after the
19722 target has stopped for the first time.
19723 (initialize_low): Do not call the_low_target.arch_setup.
19725 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19726 (s390_set_pc): Likewise.
19727 (s390_arch_setup): New function.
19728 (the_low_target): Use s390_arch_setup as arch_setup routine.
19730 * regcache.c (realloc_register_cache): New function.
19731 (set_register_cache): Call it for each existing regcache.
19733 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19735 * server.h (init_registers): Remove prototype.
19737 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19738 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19739 instead of init_registers ().
19740 * linux-arm-low.c (init_registers_arm): Add prototype.
19741 (init_registers_arm_with_iwmmxt): Likewise.
19742 (the_low_target): Add initializer for arch_setup field.
19743 * linux-cris-low.c (init_registers_cris): Add prototype.
19744 (the_low_target): Add initializer for arch_setup field.
19745 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19746 (the_low_target): Add initializer for arch_setup field.
19747 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19748 (the_low_target): Add initializer for arch_setup field.
19749 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19750 (the_low_target): Add initializer for arch_setup field.
19751 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19752 (the_low_target): Add initializer for arch_setup field.
19753 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19754 (the_low_target): Add initializer for arch_setup field.
19755 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19756 (init_registers_mips64_linux): Likewise.
19757 (the_low_target): Add initializer for arch_setup field.
19758 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19759 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19760 (the_low_target): Add initializer for arch_setup field.
19761 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19762 (init_registers_powerpc_64): Likewise.
19763 (the_low_target): Add initializer for arch_setup field.
19764 * linux-s390-low.c (init_registers_s390): Add prototype.
19765 (init_registers_s390x): Likewise.
19766 (the_low_target): Add initializer for arch_setup field.
19767 * linux-sh-low.c (init_registers_sh): Add prototype.
19768 (the_low_target): Add initializer for arch_setup field.
19769 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19770 (the_low_target): Add initializer for arch_setup field.
19771 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19772 (the_low_target): Add initializer for arch_setup field.
19774 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19775 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19776 instead of init_registers ().
19777 * win32-arm-low.c (init_registers_arm): Add prototype.
19778 (the_low_target): Add initializer for arch_setup field.
19779 * win32-i386-low.c (init_registers_i386): Add prototype.
19780 (the_low_target): Add initializer for arch_setup field.
19782 * spu-low.c (init_registers_spu): Add prototype.
19783 (initialize_low): Call initialie_registers_spu () instead of
19784 initialize_registers ().
19786 2008-02-19 Pedro Alves <pedro@codesourcery.com>
19788 * server.c (handle_v_requests): When handling the vRun and vAttach
19789 packets, if already debugging a process, don't kill it. Return an
19792 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19794 * server.c (handle_query): Correct length check.
19796 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19798 * win32-low.c (do_initial_child_stuff): Add process handle
19799 parameter. Set current_process_handle and current_process_id from the
19800 parameters. Clear globals.
19801 (win32_create_inferior): Don't set current_process_handle and
19802 current_process_id here. Instead pass them on the call to
19803 do_initial_child_stuff.
19804 (win32_attach): Likewise.
19805 (win32_clear_inferiors): New.
19806 (win32_kill): Don't close the current process handle or the
19807 current thread handle here. Instead call win32_clear_inferiors.
19808 (win32_detach): Don't open a new handle to the process. Call
19809 win32_clear_inferiors.
19810 (win32_join): Don't rely on current_process_handle; open a new
19811 handle using the process id.
19812 (win32_wait): Call win32_clear_inferiors when the inferior process
19815 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19817 * server.c (monitor_show_help): Add "exit".
19819 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19821 * Makefile.in (SFILES): Add linux-xtensa-low.c.
19822 (clean): Add reg-xtensa.c.
19823 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
19824 * configure.srv (xtensa*-*-linux*) New target.
19825 * linux-xtensa-low.c: New.
19826 * xtensa-xtregs.c: New.
19828 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19830 * hostio.c: Don't include errno.h.
19831 (errno_to_fileio_errno): Move to hostio-errno.
19832 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19833 error number outputting to the target->hostio_last_error callback.
19834 (hostio_packet_error): Use FILEIO_EINVAL directly.
19835 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19836 calls to hostio_error.
19837 * hostio-errno.c: New.
19838 * server.h (hostio_last_error_from_errno): Declare.
19839 * target.h (target_ops): Add hostio_last_error member.
19840 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19841 as hostio_last_error handler.
19842 * spu-low.c (spu_target_ops): Likewise.
19843 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19844 (wince_hostio_last_error): New functions.
19845 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19846 as hostio_last_error handler.
19847 (win32_target_ops) [!_WIN32_WCE]: Register
19848 hostio_last_error_from_errno as hostio_last_error handler.
19849 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19850 (hostio-errno.o): New rule.
19851 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19852 * configure.srv (srv_hostio_err_objs): New variable. Default to
19854 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19855 * configure: Regenerate.
19857 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19859 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
19860 (linux_kill, linux_detach): Clean up the process list.
19861 * remote-utils.c (remote_open): Improve port number parsing.
19862 (putpkt_binary, input_interrupt): Only send interrupts if the target
19864 * server.c (extended_protocol): Make static.
19865 (attached): Define earlier.
19866 (exit_requested, response_needed, program_argv): New variables.
19867 (target_running): New.
19868 (start_inferior): Clear attached here.
19869 (attach_inferior): Set attached here.
19870 (require_running): Define.
19871 (handle_query): Use require_running and target_running. Implement
19873 (handle_v_attach, handle_v_run): New.
19874 (handle_v_requests): Use require_running. Handle vAttach and vRun.
19875 (gdbserver_usage): Update.
19876 (main): Redo argument parsing. Handle --debug and --multi. Handle
19877 --attach along with other options or after the port. Save
19878 program_argv. Support no initial program. Resynchronize
19879 communication with GDB after an error. Handle "monitor exit".
19880 Use require_running and target_running. Always allow the extended
19881 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
19882 restart in extended mode.
19883 * README: Refer to the GDB manual. Update --attach usage.
19885 2007-12-20 Andreas Schwab <schwab@suse.de>
19887 * linux-low.c (STACK_SIZE): Define.
19888 (linux_tracefork_child): Use it. Use __clone2 on ia64.
19889 (linux_test_for_tracefork): Likewise.
19891 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
19893 * linux-low.c (linux_wait_for_event): Update messages. Do not
19894 reinsert auto-delete breakpoints.
19895 * mem-break.c (struct breakpoint): Change return type of handler to
19897 (set_breakpoint_at): Update handler type.
19898 (reinsert_breakpoint_handler): Return 1 instead of calling
19900 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
19902 (check_breakpoints): Delete auto-delete breakpoints and return 2.
19903 * mem-break.h (set_breakpoint_at): Update handler type.
19904 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
19905 * win32-low.c (auto_delete_breakpoint): New.
19906 (get_child_debug_event): Use it.
19908 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
19910 * configure.ac: Check for pread and pwrite.
19911 * hostio.c (handle_pread): Fall back to lseek and read.
19912 (handle_pwrite): Fall back to lseek and write.
19913 * config.in, configure: Regenerated.
19915 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
19917 * server.c (myresume): Add own_buf argument.
19918 (main): Update calls.
19920 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
19922 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
19923 * remote-utils.c (remote_open): Do not call disable_async_io.
19924 (block_async_io): Delete.
19925 (unblock_async_io): Make static.
19926 (initialize_async_io): New.
19927 * server.c (handle_v_cont): Handle async I/O here.
19928 (myresume): Likewise. Move other common resume tasks here...
19929 (main): ... from here. Call initialize_async_io. Disable async
19930 I/O before the main loop.
19931 * server.h (initialize_async_io): Declare.
19932 (block_async_io, unblock_async_io): Delete prototypes.
19933 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
19935 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
19937 * remote-utils.c (readchar): Allow binary data in received messages.
19939 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19941 * win32-low.c (attaching): New global.
19942 (win32_create_inferior): Clear the `attaching' global.
19943 (win32_attach): Set the `attaching' global.
19944 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
19945 attaching. Only set a breakpoint at the entry point if not
19948 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19950 * server.c (main): Don't report dll events on the initial
19951 connection on attaches.
19953 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19955 * server.c (main): Relax numerical bases supported for the pid of
19956 the --attach command line argument.
19958 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19960 * win32-low.c (win32_attach): Call OpenProcess before
19961 DebugActiveProcess, not after. Add last error output to error
19964 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19966 * win32-low.c (win32_get_thread_context)
19967 (win32_set_thread_context): New functions.
19968 (thread_rec): Use win32_get_thread_context.
19969 (continue_one_thread, win32_resume): Use win32_set_thread_context.
19970 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
19973 2007-12-03 Leo Zayas
19974 Pedro Alves <pedro_alves@portugalmail.pt>
19976 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
19978 (child_add_thread): Minor cleanup.
19979 (child_continue): Resume artificially suspended threads before
19980 calling ContinueDebugEvent.
19981 (suspend_one_thread): New.
19982 (fake_breakpoint_event): New.
19983 (get_child_debug_event): Change return type to int. Check here if
19984 gdb sent an interrupt request. If a soft interrupt was requested,
19985 fake a breakpoint event. Return 0 if there is no event to handle,
19987 (win32_wait): Don't check here if gdb sent an interrupt request.
19988 Ensure there is a valid event to handle.
19989 (win32_request_interrupt): Add soft interruption method as last
19992 2007-12-03 Leo Zayas
19993 Pedro Alves <pedro_alves@portugalmail.pt>
19995 * win32-low.h (win32_thread_info): Add descriptions to the
19996 structure members. Replace `suspend_count' counter by a
19998 * win32-low.c (thread_rec): Update condition of when to get the
19999 context from the inferior. Rely on ContextFlags being set if it
20000 has already been retrieved. Only suspend the inferior thread if
20001 we haven't already. Warn if that fails.
20002 (continue_one_thread): s/suspend_count/suspended/. Only call
20003 ResumeThread once. Warn if that fails.
20005 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20007 * win32-low.c (win32_wait): Don't read from the inferior when it
20008 has already exited.
20010 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20012 * Makefile.in (win32_low_h): New variable.
20013 (win32-low.o): Add dependency on $(win32_low_h).
20014 (win32-arm-low.o, win32-i386-low.o): New rules.
20016 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20018 * hostio.c: Correct copyright year.
20020 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20022 * Makefile.in (OBS): Add hostio.o.
20023 (hostio.o): New rule.
20024 * server.h (handle_vFile): Declare.
20025 * hostio.c: New file.
20026 * server.c (handle_v_requests): Take packet_len and new_packet_len
20027 for binary packets. Call handle_vFile.
20028 (main): Update call to handle_v_requests.
20030 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20032 * linux-low.c: Include <sched.h>.
20034 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20036 * linux-low.c (linux_tracefork_grandchild): New.
20037 (linux_tracefork_child): Use clone.
20038 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20040 2007-10-31 Joel Brobecker <brobecker@adacore.com>
20042 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20044 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20046 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20048 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20050 * inferiors.c (change_inferior_id): Delete.
20051 (add_pid_to_list, pull_pid_from_list): New.
20052 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20053 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20054 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20055 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20056 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20057 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20058 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20059 (using_threads): Always set to 1.
20060 (handle_extended_wait): New.
20061 (add_process): Do not set TID.
20062 (linux_create_inferior): Set must_set_ptrace_flags.
20063 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20064 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20065 (linux_thread_alive): Rename TID argument to LWPID.
20066 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20067 (linux_wait_for_event): Do not use TID or check using_threads. Update
20068 call to dead_thread_notify. Call handle_extended_wait.
20069 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20070 (send_sigstop): Delete sigstop_sent.
20071 (wait_for_sigstop): Avoid TID.
20072 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20073 (linux_test_for_tracefork): New.
20074 (linux_lookup_signals): Use thread_db_active and
20075 linux_supports_tracefork_flag.
20076 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20077 * linux-low.h (get_process_thread): Avoid TID.
20078 (struct process_ifo): Move thread_known and tid to the end. Remove
20080 (linux_attach_lwp, thread_db_init): Update prototypes.
20081 * server.h (change_inferior_id): Delete prototype.
20082 (add_pid_to_list, pull_pid_from_list): New prototypes.
20083 * thread-db.c (thread_db_use_events): New.
20084 (find_first_thread): Rename to...
20085 (find_one_thread): ...this. Update callers and messages. Do not
20086 call fatal. Check thread_db_use_events. Do not call
20087 change_inferior_id or new_thread_notify.
20088 (maybe_attach_thread): Update. Do not call new_thread_notify.
20089 (thread_db_init): Set thread_db_use_events. Check use_events.
20090 * utils.c (fatal, warning): Correct message prefix.
20092 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20094 * Makefile.in (clean): Remove new files.
20095 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20096 (powerpc-64.o, powerpc-64.c): New rules.
20097 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20098 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20100 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20102 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20103 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20104 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20105 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20106 (target_regsets): Add AltiVec and SPE register sets.
20107 * configure.ac: Check for AltiVec and SPE.
20108 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20109 (ppc_fill_vrregset, ppc_store_vrregset): New.
20110 (target_regsets): Add AltiVec register set.
20111 * configure: Regenerated.
20113 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20115 * linux-low.c (O_LARGEFILE): Define.
20116 (linux_read_memory): Use /proc/PID/mem.
20117 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20118 * configure, config.in: Regenerated.
20120 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20122 * linux-low.c (linux_wait_for_event): Do not pass signals while
20125 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20127 * win32-low.c (create_process): New.
20128 (win32_create_inferior): Use create_process instead of
20129 CreateProcess. If create_process failed retry appending an ".exe"
20130 suffix. Store the GetLastError result immediatelly after
20131 create_process calls and use it on the call to error.
20133 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20135 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20137 2007-08-23 Joel Brobecker <brobecker@adacore.com>
20139 * configure.ac: Switch license to GPLv3.
20141 2007-08-01 Michael Snyder <msnyder@access-company.com>
20143 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20145 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20147 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20149 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20150 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20151 CloseToolhelp32Snapshot.
20152 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20153 CloseToolhelp32Snapshot.
20155 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
20157 * server.c (main): Check for inferior exit before main loop.
20159 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20161 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20162 instead of on tmp_desc.
20164 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20165 Daniel Jacobowitz <dan@codesourcery.com>
20167 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20168 (add_thread): Minor cleanups.
20169 (clear_inferiors): Move lower in the file. Clear the DLL
20171 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20172 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20173 (xml_escape_text): New.
20174 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20176 (handle_v_cont): Report errors.
20177 (gdbserver_version): Update.
20178 (main): Correct size of own_buf. Do not report initial DLL events.
20179 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20180 (unloaded_dll, xml_escape_text): New.
20181 * win32-low.c (enum target_waitkind): Update comments.
20182 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20183 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20184 (win32_EnumProcessModules, win32_GetModuleInformation)
20185 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20186 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20187 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20188 (win32_Module32First, win32_Module32Next, load_toolhelp)
20189 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20190 (get_child_debug_event): Handle DLL events.
20191 (win32_wait): Likewise.
20193 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20195 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20196 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20198 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20200 * win32-low.c (handle_output_debug_string): Ignore event if not
20203 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20205 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20207 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20209 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20211 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20213 * inferiors.c (change_inferior_id): Add comment.
20214 * linux-low.c (check_removed_breakpoint): Add an early
20215 prototype. Improve debug output.
20216 (linux_attach): Doc update.
20217 (linux_detach_one_process, linux_detach): Clean up before releasing
20219 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20220 * linux-low.h (struct process_info): Doc improvement.
20221 * mem-break.c (delete_all_breakpoints): New.
20222 * mem-break.h (delete_all_breakpoints): New prototype.
20223 * thread-db.c (find_first_thread): New.
20224 (thread_db_create_event): Call it instead of
20225 thread_db_find_new_threads. Clean up unused variables.
20226 (maybe_attach_thread): Remove first thread handling.
20227 (thread_db_find_new_threads): Use find_first_thread.
20228 (thread_db_get_tls_address): Likewise.
20230 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20232 * thread-db.c (thread_db_find_new_threads): Add prototype.
20233 (thread_db_create_event): Check for the main thread before adding
20235 (maybe_attach_thread): Only enable event reporting if TID == 0.
20236 (thread_db_get_tls_address): Check for new threads.
20238 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20240 * linux-low.c (linux_create_inferior): Try execv before execvp.
20241 * spu-low.c (spu_create_inferior): Likewise.
20243 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20245 * linux-low.c (linux_create_inferior): Change execv to execvp.
20246 * spu-low.c (spu_create_inferior): Likewies.
20248 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20250 * Makefile.in (clean): Clean new files instead of deleted ones.
20251 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20252 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20254 * configure.srv: Specify XML files and new regformats for MIPS and
20256 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20257 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20258 an entry for the restart register.
20259 (mips_cannot_fetch_register, mips_cannot_store_register)
20260 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20261 register names to match the XML descriptions.
20262 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20263 restart register instead of $0.
20265 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20266 Markus Deuling <deuling@de.ibm.com>
20268 * remote-utils.c (decode_xfer_write): New function.
20269 * server.h (decode_xfer_write): Add prototype.
20270 * server.c (handle_query): Add PACKET_LEN argument. Support
20271 qXfer:spu:read and qXfer:spu:write packets.
20272 (main): Pass packet_len to handle_query.
20273 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20274 * target.h (target_ops): Add qxfer_spu.
20276 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20278 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20279 accessing non-seekable spufs files.
20281 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20283 * server.c (handle_query): Add reply for qC packet.
20285 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20286 Leo Zayas <lerele@champenstudios@com>
20288 * server.h (check_remote_input_interrupt_request): New function.
20289 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20290 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20291 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20292 (check_remote_input_interrupt_request): New function.
20293 * server.h (check_remote_input_interrupt_request): Declare.
20294 * win32-low.c (winapi_DebugBreakProcess,
20295 winapi_GenerateConsoleCtrlEvent): New typedefs.
20296 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20298 (win32_wait): Check for remote interrupt request
20299 with check_remote_input_interrupt_request.
20300 (win32_request_interrupt): New function.
20301 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20303 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20305 * win32-low.c (debug_registers_changed,
20306 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20307 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20308 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20309 (thread_rec): Get context using the low target.
20310 (child_add_thread): Call thread_added on the low target,
20311 which does the same thing.
20313 (do_initial_child_stuff): Remove debug registers references.
20314 Set context using the low target. Resume threads after
20315 setting the contexts.
20316 (child_continue): Remove dead variable. Remove debug
20317 registers references.
20318 (child_fetch_inferior_registers): Go through the low target.
20319 (do_child_store_inferior_registers): Remove.
20320 (child_store_inferior_registers): Go through the low target.
20321 (win32_resume): Remove debug registers references.
20322 Set context using the low target.
20323 (handle_exception): Change return type to void. Don't record
20324 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20325 first chance exception.
20326 (get_child_debug_event): Change return type to void. Remove
20327 goto loop. Always return after waiting for debug event.
20328 (win32_wait): Convert to switch statement. Handle spurious
20331 * win32-i386-low.c (debug_registers_changed,
20332 debug_registers_used): New.
20333 (initial_stuff): Rename to ...
20334 (i386_initial_stuff): ... this. Clear debug registers
20336 (store_debug_registers): Delete.
20337 (i386_get_thread_context): New.
20338 (load_debug_registers): Delete.
20339 (i386_set_thread_context): New.
20340 (i386_thread_added): New.
20341 (single_step): Rename to ...
20342 (i386_single_step): ... this.
20343 (do_fetch_inferior_registers): Rename to ...
20344 (i386_fetch_inferior_register): ... this.
20345 (i386_store_inferior_register): New.
20346 (the_low_target): Adapt to new interface.
20348 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20349 (arm_get_thread_context): New.
20350 (arm_set_thread_context): New.
20352 (do_fetch_inferior_registers): Rename to ...
20353 (arm_fetch_inferior_register): ... this.
20354 (arm_store_inferior_register): New.
20355 (arm_wince_breakpoint): Reimplement as unsigned long.
20356 (arm_wince_breakpoint_len): Define.
20357 (the_low_target): Adapt to new interface.
20359 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20360 load_debug_registers. Add get_thread_context, set_thread_context,
20361 thread_added and store_inferior_register. Rename
20362 fetch_inferior_registers to fetch_inferior_register.
20363 (regptr): Remove declaration.
20365 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20367 * linux-low.c (linux_detach): Change return type to int. Return 0.
20368 * spu-low.c (spu_detach): Likewise.
20370 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20372 * target.h (target_ops): Change return type of detach to int.
20374 (join_inferior): New.
20375 * server.c (main): Don't skip detach support on mingw32.
20376 If the inferior doesn't support detaching return error.
20377 Call join_inferior instead of using waitpid.
20378 * linux-low.c (linux_join): New.
20379 (linux_target_op): Add linux_join.
20380 * spu-low.c (spu_join): New.
20381 (spu_target_ops): Add spu_join.
20382 * win32-low.c (win32_detach): Adapt to new interface.
20383 Reopen current_process_handle before detaching. Issue a child
20384 resume before detaching.
20386 (win32_target_op): Add win32_join.
20388 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20390 * win32-low.c (win32-attach): Fix return value.
20391 * target.h (target_ops): Describe ATTACH return values.
20393 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20395 * win32-low.c (GETPROCADDRESS): Define.
20396 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20397 (winapi_DebugSetProcessKillOnExit): Likewise.
20398 (win32_create_inferior): Force usage of ansi CreateProcessA.
20399 (win32_attach): Use GETPROCADDRESS.
20400 (win32_detach): Likewise.
20402 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20404 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20406 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20408 * win32-low.c: Commit leftover changes from 2007-03-29.
20410 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20412 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20413 fields short instead of int. Add explicit padding.
20414 (i387_cache_to_fsave): Remove unnecessary casts.
20415 (i387_fsave_to_cache): Doc fix.
20416 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20418 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20420 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20421 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20423 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20425 * configure.srv (arm*-*-mingw32ce*): Move near the other
20428 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20430 * configure.ac: Add errno checking.
20431 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20432 sys/file.h and malloc.h.
20433 (AC_CHECK_DECLS): Add perror.
20434 (srv_mingwce): Handle.
20435 * configure.srv (i[34567]86-*-cygwin*): Add
20436 win32-i386-low.o to srv_tgtobj.
20437 (i[34567]86-*-mingw*): Likewise.
20438 (arm*-*-mingw32ce*): Add case.
20439 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20440 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20441 [__MINGW32CE__] (strerror): New function.
20442 [__MINGW32CE__] (errno): Define to GetLastError.
20443 [__MINGW32CE__] (COUNTOF): New macro.
20444 (remote_open): Remove extra close call.
20445 * mem-break.c (delete_breakpoint_at): New function.
20446 * mem-break.h (delete_breakpoint_at): Declare.
20447 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20448 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20449 [USE_WIN32API] (read, write): Add char* casts.
20450 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20451 * server.h: Include wincecompat.h on Windows CE.
20452 [HAVE_ERRNO_H]: Check.
20453 (perror): Declare if not declared.
20454 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20455 (perror_with_name): Remove errno declaration.
20456 * wincecompat.h: New.
20457 * wincecompat.c: New.
20458 * win32-low.h: New.
20459 * win32-arm-low.c: New.
20460 * win32-i386-low.c: New.
20461 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20462 (OUTMSG2): Make it safe.
20464 (COUNTOF): New macro.
20465 (NUM_REGS): Get it from the low target.
20466 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20467 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20468 (thread_rec): Let low target handle debug registers.
20469 (child_add_thread): Likewise.
20470 (child_init_thread_list): Likewise.
20471 (continue_one_thread): Likewise.
20473 (do_child_fetch_inferior_registers): Move to ...
20474 * win32-i386-low.c: ... here, and rename to ...
20475 (do_fetch_inferior_registers): ... this.
20476 * win32-low.c (child_fetch_inferior_registers):
20477 Go through the low target.
20478 (do_child_store_inferior_registers): Use regptr.
20479 (strwinerror): New function.
20480 (win32_create_inferior): Handle Windows CE.
20481 Use strwinerror instead of strerror on Windows error
20482 codes. Add program to the error output.
20483 Don't close the main thread handle on Windows CE.
20484 (win32_attach): Use coredll.dll on Windows CE.
20485 (win32_kill): Close current process and current
20487 (win32_detach): Use coredll.dll on Windows CE.
20488 (win32_resume): Let low target handle debug registers, and
20490 (handle_exception): Add/Remove initial breakpoint. Avoid
20491 non-existant WSTOPSIG on Windows CE.
20492 (win32_read_inferior_memory): Cast to remove warning.
20493 (win32_arch_string): Go through the low target.
20494 (initialize_low): Call set_breakpoint_data with the low
20495 target's breakpoint.
20496 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20497 FOP_REGNUM, mappings): Move to ...
20498 * win32-i386-low.c: ... here.
20499 * win32-low.c (win32_thread_info): Move to ...
20500 * win32-low.h: ... here.
20501 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20502 win32-arm-low.c and wincecompat.c.
20503 (all:): Add $EXEEXT.
20504 (install-only:): Likewise.
20505 (gdbserver:): Likewise.
20506 (gdbreplay:): Likewise.
20507 * config.in: Regenerate.
20508 * configure: Regenerate.
20510 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20512 * win32-low.c: Rename typedef thread_info to
20513 win32_thread_info throughout.
20515 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20517 * win32-i386-low.c: Rename to ...
20518 * win32-low.c: ... this.
20519 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20520 * Makefile.in: Likewise.
20522 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20524 * remote-utils.c (monitor_output): Constify msg parameter.
20525 * server.h (monitor_output): Likewise.
20526 * win32-i386-low.c (handle_output_debug_string): New.
20527 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20528 handle_output_debug_string.
20529 (get_child_debug_event): Likewise.
20531 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20533 * server.c (main): Correct strtoul check.
20535 2007-03-27 Jon Ringle <jon@ringle.org>
20537 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20539 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20541 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20543 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20545 * terminal.h: Check HAVE_SGTTY_H.
20547 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
20549 * remote-utils.c (remote_open): Print out the assigned port number.
20551 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20553 * remote-utils.c (monitor_output): New function.
20554 * server.c (debug_threads): Define here.
20555 (monitor_show_help): New function.
20556 (handle_query): Handle qRcmd.
20557 (main): Do not handle 'd' packet.
20558 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20559 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20562 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20564 * Makefile.in (EXEEXT): New.
20565 (clean): Use $(EXEEXT).
20567 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20569 * target.h (target_ops): Rename send_signal to request_interrupt,
20570 and remove enum target_signal parameter.
20571 * linux-low.c (linux_request_interrupt): Rename from
20572 linux_send_signal, and always send SIGINT.
20573 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20574 and always send SIGINT.
20575 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20577 (input_interrupt): Likewise.
20579 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20581 * server.c (get_features_xml): Check if target implemented
20583 * win32-i386-low.c (win32_arch_string): New.
20584 (win32_target_ops): Add win32_arch_string as arch_string member.
20586 2007-02-22 Markus Deuling <deuling@de.ibm.com>
20588 * spu-low.c (spu_arch_string): New.
20589 (spu_target_ops): Add spu_arch_string.
20591 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20593 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20594 * configure.ac: Do not check for terminal.h.
20595 * configure, config.in: Regenerated.
20597 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20599 * Makefile.in (OBS): Add $(XML_BUILTIN).
20600 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20602 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20603 (arm-with-iwmmxt.c): New.
20604 * config.in, configure: Regenerate.
20605 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20606 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20607 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20608 (arm*-*-linux*): Add iWMMXt and regset support.
20609 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20610 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20611 (arm_store_wmmxregset, target_regsets): New.
20612 * server.c (get_features_xml): Take annex argument. Check builtin
20614 (handle_query): Handle multiple annexes.
20616 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20618 * remote-utils.c [USE_WIN32API] (read, write): Define.
20619 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20622 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20624 * linux-i386-low.c (the_low_target): Set arch_string.
20625 * linux-x86-64-low.c (the_low_target): Likewise.
20626 * linux-low.c (linux_arch_string): New.
20627 (linux_target_ops): Add it.
20628 * linux-low.h (struct linux_target_ops): Add arch_string.
20629 * server.c (write_qxfer_response): Use const void * for DATA.
20630 (get_features_xml): New.
20631 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20632 * target.h (struct target_ops): Add arch_string method.
20634 2007-01-03 Denis Pilat <denis.pilat@st.com>
20635 Daniel Jacobowitz <dan@codesourcery.com>
20637 * linux-low.c (linux_kill): Handle being called with no threads.
20638 * win32-i386-low.c (win32_kill): Likewise.
20639 (get_child_debug_event): Clear current_process_handle.
20641 2006-12-30 Denis PILAT <denis.pilat@st.com>
20642 Daniel Jacobowitz <dan@codesourcery.com>
20644 * remote-utils.c (remote_open): Check the type of specified
20645 serial port devices before opening them.
20646 * server.c (main): Kill the inferior if an error occurs during
20647 the first remote_open.
20649 2006-12-05 Markus Deuling <deuling@de.ibm.com>
20651 * README: Update supported targets.
20653 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20655 * Makefile.in (clean): Remove reg-mips64.c.
20656 (reg-mips64.c, reg-mips64.o): New rules.
20657 * configure.srv: Handle mips64. Include regset support for mips.
20658 * linux-mips-low.c (union mips_register): New.
20659 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20660 (mips_breakpoint, mips_breakpoint_at): Use int.
20661 (mips_collect_register, mips_supply_register)
20662 (mips_collect_register_32bit, mips_supply_register_32bit)
20663 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20664 (mips_store_fpregset, target_regsets): New.
20665 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20667 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20669 * configure.srv: Add target "spu*-*-*".
20670 * Makefile.in (clean): Remove reg-spu.c.
20671 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20672 * spu-low.c: New file.
20674 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20676 * configure.ac: Correct td_thr_tls_get_addr test.
20677 * configure: Regenerated.
20679 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20681 * linux-low.c (linux_wait_for_event): Reformat. Use the
20682 pass_signals array.
20683 * remote-utils.c (decode_address_to_semicolon): New.
20684 * server.c (pass_signals, handle_general_set): New.
20685 (handle_query): Mention QPassSignals for qSupported.
20686 (main): Call handle_general_set.
20687 * server.h (pass_signals, decode_address_to_semicolon): New.
20689 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20691 * server.c (handle_query): Correct error handling for read_auxv.
20693 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20695 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20696 and srv_linux_thread_db to yes.
20697 * linux-s390-low.c (s390_fill_gregset): New function.
20698 (target_regsets): Define data structure.
20700 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20702 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20703 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20704 * config.in, configure: Regenerated.
20705 * inferiors.c (gdb_id_to_thread): New function.
20706 (gdb_id_to_thread_id): Use it.
20707 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20708 * linux-low.h (struct process_info): Add th member.
20709 (thread_db_get_tls_address): New prototype.
20710 * remote-utils.c (decode_address): Make non-static.
20711 * server.c (handle_query): Handle qGetTLSAddr.
20712 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20713 * target.h (struct target_ops): Add get_tls_address.
20714 * thread-db.c (maybe_attach_thread): Save the thread handle.
20715 (thread_db_get_tls_address): New.
20717 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20719 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20720 (linux_resume_one_process): Take a siginfo_t *. Update all
20721 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20722 (struct pending_signals): Add a siginfo_t.
20723 (linux_wait_for_process): Always set last_status.
20724 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20725 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20726 * linux-low.h (struct process_info): Add last_status.
20728 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20730 * remote-utils.c (try_rle): New function.
20731 (putpkt_binary): Use it.
20733 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20735 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20736 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20737 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20738 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20739 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20742 2006-08-08 Richard Sandiford <richard@codesourcery.com>
20744 * server.c (terminal_fd): New variable.
20745 (old_foreground_pgrp): Likewise.
20746 (restore_old_foreground_pgrp): New function.
20747 (start_inferior): Record the terminal file descriptor in terminal_fd
20748 and its original foreground group in old_foreground_pgrp. Register
20749 restore_old_foreground_pgrp with atexit().
20751 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20753 * server.c (handle_query): Correct qPart to qXfer.
20755 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20757 * configure.ac: Check for more headers which are missing on
20758 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20759 * configure.srv: Add Cygwin and mingw32.
20760 * remote-utils.c: Don't include headers unconditionally which
20761 are missing on mingw32. Include <winsock.h> for mingw32.
20762 (remote_open): Adjust for mingw32 support. Flush
20763 standard error after writing to it.
20764 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20765 (unblock_async_io, enable_async_io, disable_async_io)
20766 (readchar, getpkt): Update for Winsock support.
20767 (prepare_resume_reply): Expect a protocol signal number.
20768 * server.c: Disable <sys/wait.h> on mingw32.
20769 (start_inferior): Adjust for mingw32 support. Flush
20770 standard error after writing to it.
20771 (attach_inferior): Likewise. Use protocol signal
20773 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20775 * win32-i386-low.c: New file.
20776 * Makefile.in (XM_CLIBS): Set.
20777 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20778 (win32-i386-low.o): New dependency rule.
20779 * linux-low.c (linux_wait): Use target signal numbers.
20780 * target.h (struct target_ops): Doc fix.
20781 * server.h (target_signal_to_name): New prototype.
20782 * gdbreplay.c: Don't include headers unconditionally which
20783 are missing on mingw32. Include <winsock.h> for mingw32.
20784 (remote_close, remote_open): Adjust for Winsock support.
20785 * configure, config.in: Regenerated.
20787 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20789 * server.c (decode_xfer_read, write_qxfer_response): New.
20790 (handle_query): Take a packet length argument. Handle
20791 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20792 the qSupported response.
20793 (main): Update call to handle_query.
20795 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20797 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20798 (putpkt_binary): Renamed from putpkt and adjusted for binary
20800 (putpkt): New wrapper for putpkt_binary.
20801 (readchar): Don't mask off the high bit.
20802 (decode_X_packet): New function.
20803 * server.c (main): Call putpkt_binary if a handler sets the packet
20804 length. Save the length of the incoming packet. Handle 'X'.
20805 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20807 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20809 * server.c (handle_query): Handle qSupported.
20811 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20813 * remote-utils.c (all_symbols_looked_up): New variable.
20814 (look_up_one_symbol): Check it.
20815 * server.h (look_up_one_symbol): New declaration.
20816 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20818 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20820 * Makefile.in (linux-arm-low.o): Update dependencies.
20821 * linux-arm-low.c: Include "gdb_proc_service.h".
20822 (PTRACE_GET_THREAD_AREA): Define.
20823 (ps_get_thread_area): New function.
20825 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20827 * configure.srv (m68k*-*-uclinux*): New target.
20828 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20829 (linux_resume_one_process): Remove extraneous cast.
20830 (linux_read_offsets): New.
20831 (linux_target_op): Add linux_read_offsets on mmuless systems.
20832 * server.c (handle_query): Add qOffsets logic.
20833 * target.h (struct target_ops): Add read_offsets.
20835 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20837 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20838 (PTRACE_GET_THREAD_AREA): Define.
20839 (ps_get_thread_area): New function.
20840 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20841 (linux-x86-64-low.o): Update.
20843 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20845 * configure.ac: Remove checks for prfpregset_t.
20846 * gdb_proc_service.h: New file.
20847 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20848 new "gdb_proc_service.h".
20849 * proc-service.c: Likewise.
20850 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20851 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20852 * Makefile.in (gdb_proc_service_h): Updated.
20853 * configure, config.in: Regenerated.
20855 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20857 * remote-utils.c (prepare_resume_reply): Move declaration
20858 of gdb_id_from_wait to the top of the block.
20860 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
20862 * linux-low.c (regsets_store_inferior_registers): Read the regset
20863 from the target before filling it.
20865 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20867 * server.c (attach_inferior): Return SIGTRAP for a successful
20870 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
20872 * Makefile.in (OBS): Add version.o.
20873 (STAGESTUFF): Delete.
20874 (version.o): Add dependencies.
20875 (version.c): Replace rule.
20876 (clean): Remove version.c.
20877 * server.c (gdbserver_version): New.
20878 (gdbserver_usage): Use printf.
20879 (main): Handle --version and --help.
20880 * server.h (version, host_name): Add declarations.
20882 2005-12-23 Eli Zaretskii <eliz@gnu.org>
20894 * linux-x86-64-low.c:
20896 * linux-s390-low.c:
20897 * linux-ppc64-low.c:
20899 * linux-mips-low.c:
20900 * linux-m68k-low.c:
20901 * linux-m32r-low.c:
20904 * linux-ia64-low.c:
20905 * linux-i386-low.c:
20906 * linux-crisv32-low.c:
20918 * gdbserver.1: Add (C) after Copyright. Update the FSF
20921 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
20923 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
20924 (arm_breakpoint_at): Recognize both breakpoints.
20925 (the_low_target): Use the correct breakpoint instruction.
20927 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
20929 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
20930 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
20931 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
20932 (the_low_target): Update.
20934 2005-10-25 Andreas Schwab <schwab@suse.de>
20936 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
20938 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
20939 (ia64_num_regs): Reduce to 462.
20941 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
20943 * acinclude.m4: Correct quoting.
20944 * aclocal.m4: Regenerated.
20946 Suggested by SZOKOVACS Robert <szo@ies.hu>:
20947 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
20948 (thread_db_init): Call thread_db_err_str.
20949 * configure.ac: Check for TD_VERSION.
20950 * config.in, configure: Regenerated.
20952 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
20954 * server.h (error, fatal, warning): Add ATTR_FORMAT.
20956 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20958 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
20959 is not available. Define HAVE_PTRACE_GETREGS if it is.
20960 * config.in, configure: Regenerated.
20961 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
20962 * linux-i386-low.c, linux-m68k-low.c: Update to use
20963 HAVE_PTRACE_GETREGS.
20964 * linux-low.c (regsets_fetch_inferior_registers)
20965 (regsets_store_inferior_registers): Only return 0 if we processed
20967 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
20968 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
20970 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20972 * inferiors.c (struct thread_info): Add gdb_id.
20973 (add_thread): Add gdb_id argument.
20974 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
20975 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
20976 calls to add_thread.
20977 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
20978 * server.c (handle_query): Use thread_to_gdb_id.
20979 (handle_v_cont, main): Use gdb_id_to_thread_id.
20980 * server.h (add_thread): Update prototype.
20981 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
20984 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20986 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
20987 left-padded registers.
20988 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
20989 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
20991 2005-07-01 Steve Ellcey <sje@cup.hp.com>
20993 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
20994 * configure: Regenerate.
20995 * config.in: Regenerate.
20996 * server.h (NEED_DECLARATION_STRERROR):
20997 Replace with !HAVE_DECL_STRERROR.
20999 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21001 * linux-low.c (linux_wait, linux_send_signal): Don't test
21002 an unsigned long variable for > 0 if it could be MAX_ULONG.
21003 * server.c (myresume): Likewise.
21004 * target.c (set_desired_inferior): Likewise.
21006 2005-06-13 Mark Kettenis <kettenis@gnu.org>
21008 * configure.ac: Simplify and improve check for socklen_t.
21009 * configure, config.in: Regenerate.
21011 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21013 * acconfig.h: Remove.
21014 * configure.ac: Add a test for socklen_t. Use three-argument
21015 AC_DEFINE throughout.
21016 * config.in: Regenerated using autoheader 2.59.
21017 * configure: Regenerated.
21019 * gdbreplay.c (socklen_t): Provide a default.
21020 (remote_open): Use socklen_t.
21021 * remote-utils.c (socklen_t): Provide a default.
21022 (remote_open): Use socklen_t.
21023 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21026 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21028 * linux-low.c (linux_read_memory, linux_write_memory)
21029 (linux_read_auxv): Likewise.
21030 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21031 (check_mem_write): Likewise.
21032 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21034 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21035 (registers_from_string, register_data): Likewise.
21036 * server.c (handle_query, main): Likewise.
21037 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21038 (decode_M_packet): Likewise.
21039 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21040 * target.h (struct target_ops): Update read_memory, write_memory,
21042 (read_inferior_memory, write_inferior_memory): Update.
21043 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21044 to unsigned char *.
21045 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21046 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21047 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21048 linux-s390-low.c, linux-sh-low.c: Update for changes in
21049 read_inferior_memory and the_low_target->breakpoint.
21051 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21053 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21054 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21055 * configure.srv: Add powerpc64-*-linux*.
21056 * linux-ppc64-low.c: New file.
21058 2005-05-23 Orjan Friberg <orjanf@axis.com>
21060 * linux-cris-low.c: New file with support for CRIS.
21061 * linux-crisv32-low.c: Ditto for CRISv32.
21062 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21063 (clean): Add reg-cris.c and reg-crisv32.c.
21064 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
21065 reg-crisv32.o, and reg-crisv32.c to make rules.
21066 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21067 recognized targets.
21069 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21071 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21072 of sizeof (PTRACE_XFER_TYPE).
21073 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21075 2005-05-12 Orjan Friberg <orjanf@axis.com>
21077 * target.h (struct target_ops): Add insert_watchpoint,
21078 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21079 pointers for hardware watchpoint support.
21080 * linux-low.h (struct linux_target_ops): Ditto.
21081 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21082 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21083 to linux_target_ops.
21084 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21086 * server.c (main): Recognize 'Z' and 'z' packets.
21088 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21090 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21091 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21092 (the_low_target): Add new members.
21094 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21096 * proc-service.c (ps_lgetregs): Search all_processes instead of
21099 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21101 * server.c (start_inferior): Change return type to int.
21102 (attach_inferior): Change sigptr to int *.
21103 (handle_v_cont, handle_v_requests): Change signal to int *.
21104 (main): Change signal to int.
21106 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
21108 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21109 * configure.srv: Add m32r*-*-linux*.
21110 * linux-m32r-low.c: New file.
21112 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21114 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21116 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21118 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21119 Take unsigned long arguments for PIDs.
21120 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21121 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21122 (wait_for_sigstop, linux_resume_one_process)
21123 (regsets_fetch_inferior_registers, linux_send_signal)
21124 (linux_read_auxv): Likewise. Update the types of variables holding
21125 PIDs. Update format string specifiers.
21126 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21127 * remote-utils.c (prepare_resume_reply): Likewise.
21128 * server.c (cont_thread, general_thread, step_thread)
21129 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21131 (handle_query): Update format specifiers.
21132 (handle_v_cont, main): Use strtoul for thread IDs.
21133 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21134 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21135 (general_thread, step_thread, thread_from_wait)
21136 (old_thread_from_wait): Update.
21137 * target.h (struct thread_resume): Use unsigned long for THREAD.
21138 (struct target_ops): Use unsigned long for arguments to attach and
21141 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21143 * acinclude.m4: Include bfd/bfd.m4 directly.
21144 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21145 <agriffis@toolchain.org>.
21146 * aclocal.m4, configure: Regenerated.
21148 2005-01-07 Andrew Cagney <cagney@gnu.org>
21150 * configure.ac: Rename configure.in, require autoconf 2.59.
21151 * configure: Re-generate.
21153 2004-12-08 Daniel Jacobowitz <dan@debian.org>
21155 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21156 LIBS when finished.
21157 * aclocal.m4: Regenerated.
21158 * configure: Regenerated.
21160 2004-11-21 Andreas Schwab <schwab@suse.de>
21162 * linux-m68k-low.c (m68k_num_gregs): Define.
21163 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21164 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21165 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21166 (m68k_breakpoint_at): New. Add to the_low_target.
21168 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21169 srv_linux_thread_db to yes.
21171 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21173 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21174 (ARCH_SET_FS): Likewise.
21175 (ARCH_GET_FS): Likewise.
21176 (ARCH_GET_GS): Likewise.
21178 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21180 * linux-i386-low.c (ps_get_thread_area): New.
21181 * linux-x86-64-low.c (ps_get_thread_area): New.
21182 * linux-low.c: Include <sys/syscall.h>.
21183 (linux_kill_one_process): Don't kill the first thread here.
21184 (linux_kill): Kill the first thread here.
21185 (kill_lwp): New function.
21186 (send_sigstop, linux_send_signal): Use it.
21187 * proc-service.c: Clean up #ifdefs.
21188 (fpregset_info): Delete.
21189 (ps_lgetregs): Update and enable implementation.
21190 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21192 * remote-utils.c (struct sym_cache, symbol_cache): New.
21193 (input_interrupt): Print a clearer message.
21194 (async_io_enabled): New variable.
21195 (enable_async_io, disable_async_io): Use it. Update comments.
21196 (look_up_one_symbol): Use the symbol cache.
21197 * thread-db.c (thread_db_look_up_symbols): New function.
21198 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21200 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21202 * configure.in: Test for -rdynamic.
21203 * configure: Regenerated.
21204 * Makefile (INTERNAL_LDFLAGS): New.
21205 (gdbserver, gdbreplay): Use it.
21207 2004-09-02 Andrew Cagney <cagney@gnu.org>
21209 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21211 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21213 * linux-low.c (linux_wait): Clear all_processes list also.
21215 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21217 * linux-low.c: Include <errno.h>. Remove extern declaration of
21220 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21222 * gdbreplay.c, server.h, utils.c: Update copyright years.
21224 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21226 * server.c (main): Print child status or termination signal from
21227 variable 'signal', not 'sig'.
21229 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21231 * linux-low.c (linux_read_memory): Change return type to
21232 int. Check for and return error from ptrace().
21233 * target.c (read_inferior_memory): Change return type to int. Pass
21234 back return status from the_target->read_memory().
21235 * target.h (struct target_ops): Adapt *read_memory() prototype.
21237 (read_inferior_memory): Adapt prototype.
21238 * server.c (main): Return an error packet if
21239 read_inferior_memory() returns an error.
21241 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21243 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21244 Unify with other clean targets.
21246 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21248 * server.c (handle_v_cont): Call set_desired_inferior.
21250 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21252 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21254 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21256 * linux-low.c (linux_wait): Unblock async I/O.
21257 (linux_resume): Block and enable async I/O.
21258 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21259 * server.h (block_async_io, unblock_async_io): Add prototypes.
21261 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21263 * remote-utils.c (remote_open): Print a status notice after
21264 opening a TCP port.
21265 * server.c (attach_inferior): Print a status notice after
21268 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21270 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21272 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21274 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21276 * server.c, target.h: Update copyright years.
21278 2004-02-25 Roland McGrath <roland@redhat.com>
21280 * target.h (struct target_ops): New member `read_auxv'.
21281 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21282 * linux-low.c (linux_read_auxv): New function.
21283 (linux_target_ops): Initialize `read_auxv' member to that.
21285 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21287 Committed by Jim Blandy <jimb@redhat.com>.
21289 * linux-s390-low.c (s390_num_regs): Update.
21290 (s390_regmap): Remove control registers. Use __s390x__ predefine
21291 instead of GPR_SIZE to distiguish s390 and s390x targets.
21293 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21295 * linux-low.c: Update copyright year.
21296 (check_removed_breakpoint): Clear pending_is_breakpoint.
21297 (linux_set_resume_request, linux_queue_one_thread)
21298 (resume_status_pending_p): New functions.
21299 (linux_continue_one_thread): Use process->resume.
21300 (linux_resume): Only resume threads if there are no pending events.
21301 * linux-low.h (struct process_info): Add resume request
21304 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21306 * regcache.c (new_register_cache): Clear the allocated register
21307 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21309 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21311 * linux-low.c (linux_resume): Take a struct thread_resume *
21313 (linux_wait): Update call.
21314 (resume_ptr): New static variable.
21315 (linux_continue_one_thread): Renamed from
21316 linux_continue_one_process. Use resume_ptr.
21317 (linux_resume): Use linux_continue_one_thread.
21318 * server.c (handle_v_cont, handle_v_requests): New functions.
21319 (myresume): New function.
21320 (main): Handle 'v' case.
21321 * target.h (struct thread_resume): New type.
21322 (struct target_ops): Change argument of "resume" to struct
21324 (myresume): Delete macro.
21326 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21328 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21329 (uninstall): Support DESTDIR.
21331 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21333 * configure.srv: Add xscale*linux copy of arm*linux entry.
21335 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21337 * linux-arm-low.c (arm_reinsert_addr): New function.
21338 (the_low_target): Add arm_reinsert_addr.
21340 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21342 * mem-break.c: Remove whitespace at end of file.
21344 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21346 * configure.in: Check whether we need to prototype strerror.
21347 * server.h: Optionally prototype strerror.
21348 * gdbreplay.c (perror_with_name): Use strerror.
21349 * linux-low.c (linux_attach_lwp): Use strerror.
21350 * utils.c (perror_with_name): Use strerror.
21351 * config.in, configure: Regenerated.
21353 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21355 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21356 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21358 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21360 * Makefile.in (SFILES): Update.
21361 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21362 low-sun3.c: Remove files.
21364 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21366 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21367 (linux_detach_one_process, linux_detach): New functions.
21368 (linux_target_ops): Add linux_detach.
21369 * server.c (main): Handle 'D' packet.
21370 * target.h (struct target_ops): Add "detach" member.
21371 (detach_inferior): Define.
21373 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21375 From Kelley Cook <kelleycook@wideopenwest.com>:
21376 * configure.srv: Accept i[34567]86 variants.
21378 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21380 * linux-low.c (linux_wait_for_event): Correct comment typos.
21381 (linux_resume_one_process): Call check_removed_breakpoint.
21382 (linux_send_signal): New function.
21383 (linux_target_ops): Add linux_send_signal.
21384 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21386 * target.h (struct target_ops): Add send_signal.
21388 2003-05-29 Jim Blandy <jimb@redhat.com>
21390 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21391 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21392 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21393 away part of the register's value.
21395 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21397 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21398 (linux_wait_for_event, linux_init_signals): Likewise.
21400 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21402 * configure.in: Check for stdlib.h.
21403 * configure: Regenerated.
21404 * config.in: Regenerated.
21406 2003-01-04 Andreas Schwab <schwab@suse.de>
21408 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21410 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21412 * Makefile.in: Remove obsolete code.
21414 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21416 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21417 defined(PT_FPR0_HI).
21419 2002-11-17 Stuart Hughes <seh@zee2.com>
21421 * linux-arm-low.c (arm_num_regs): Increase.
21422 (arm_regmap): Include status register.
21424 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21426 * linux-low.c (register_addr): Remove incorrect -1 check.
21428 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21430 * linux-low.c (linux_create_inferior): Call setpgid. Return
21432 (unstopped_p, linux_signal_pid): Remove.
21433 (linux_target_ops): Remove linux_signal_pid.
21434 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21435 global instead of target method.
21436 * target.h (struct target_ops): Remove signal_pid. Update comment
21437 for create_inferior.
21438 * server.c (signal_pid): New variable.
21439 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21440 gdbserver. Set the child to be the foreground process group.
21441 (attach_inferior): Set signal_pid.
21443 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21445 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21447 2002-08-20 Jim Blandy <jimb@redhat.com>
21449 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21452 2002-08-01 Andrew Cagney <cagney@redhat.com>
21454 * Makefile.in: Make chill references obsolete.
21456 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21458 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21459 * configure: Regenerate.
21460 * config.in: Regenerate.
21462 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21464 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21465 (perror_with_name, remote_close, remote_open, expect, play): Static.
21467 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21469 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
21470 byte offsets instead of an array of indexes.
21471 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21473 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
21475 * regcache.c: Add comment.
21477 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
21479 * thread-db.c: New file.
21480 * proc-service.c: New file.
21481 * acinclude.m4: New file.
21482 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21483 proc-service.o, and thread-db.o.
21484 (linux-low.o): Add USE_THREAD_DB.
21485 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21486 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21487 * aclocal.m4: Regenerated.
21488 * config.in: Regenerated.
21489 * configure: Regenerated.
21490 * configure.in: Check for proc_service.h, sys/procfs.h,
21491 thread_db.h, and linux/elf.h headrs.
21492 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21493 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21494 Check for -lthread_db and thread support.
21495 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21496 PowerPC, and SuperH.
21497 * i387-fp.c: Constify arguments.
21498 * i387-fp.h: Likewise.
21499 * inferiors.c: (struct thread_info): Renamed from
21500 `struct inferior_info'. Remove PID member. Use generic inferior
21501 list header. All uses updated.
21502 (inferiors, signal_pid): Removed.
21503 (all_threads): New variable.
21504 (get_thread): Define.
21505 (add_inferior_to_list): New function.
21506 (for_each_inferior): New function.
21507 (change_inferior_id): New function.
21508 (add_inferior): Removed.
21509 (remove_inferior): New function.
21510 (add_thread): New function.
21511 (free_one_thread): New function.
21512 (remove_thread): New function.
21513 (clear_inferiors): Use for_each_inferior and free_one_thread.
21514 (find_inferior): New function.
21515 (find_inferior_id): New function.
21516 (inferior_target_data): Update argument type.
21517 (set_inferior_target_data): Likewise.
21518 (inferior_regcache_data): Likewise.
21519 (set_inferior_regcache_data): Likewise.
21520 * linux-low.c (linux_bp_reinsert): Remove.
21521 (all_processes, stopping_threads, using_thrads)
21522 (struct pending_signals, debug_threads, pid_of): New.
21523 (inferior_pid): Replace with macro.
21524 (struct inferior_linux_data): Remove.
21525 (get_stop_pc, add_process): New functions.
21526 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21527 Use add_process and add_thread.
21528 (linux_attach_lwp): New function, based on old linux_attach. Use
21529 add_process and add_thread. Set stop_expected for new threads.
21530 (linux_attach): New function.
21531 (linux_kill_one_process): New function.
21532 (linux_kill): Kill all LWPs.
21533 (linux_thread_alive): Use find_inferior_id.
21534 (check_removed_breakpoints, status_pending_p): New functions.
21535 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21536 Update. Use WNOHANG. Wait for cloned processes also. Update process
21537 struct for the found process.
21538 (linux_wait_for_event): New function.
21539 (linux_wait): Use it. Support LWPs.
21540 (send_sigstop, wait_for_sigstop, stop_all_processes)
21541 (linux_resume_one_process, linux_continue_one_process): New functions.
21542 (linux_resume): Support LWPs.
21543 (REGISTER_RAW_SIZE): Remove.
21544 (fetch_register): Use register_size instead. Call supply_register.
21545 (usr_store_inferior_registers): Likewise. Call collect_register.
21546 Fix recursive case.
21547 (regsets_fetch_inferior_registers): Improve error message.
21548 (regsets_store_inferior_registers): Add debugging.
21549 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21550 (unstopped_p, linux_signal_pid): New functions.
21551 (linux_target_ops): Add linux_signal_pid.
21552 (linux_init_signals): New function.
21553 (initialize_low): Call it. Initialize using_threads.
21554 * regcache.c (inferior_regcache_data): Add valid
21556 (get_regcache): Fetch registers lazily. Add fetch argument
21557 and update all callers.
21558 (regcache_invalidate_one, regcache_invalidate): New
21560 (new_register_cache): Renamed from create_register_cache.
21561 Return the new regcache.
21562 (free_register_cache): Change argument to a void *.
21563 (registers_to_string, registers_from_string): Call get_regcache
21564 with fetch flag set.
21565 (register_data): Make static. Pass fetch flag to get_regcache.
21566 (supply_register): Call get_regcache with fetch flag clear.
21567 (collect_register): Call get_regcache with fetch flag set.
21568 (collect_register_as_string): New function.
21569 * regcache.h: Update.
21570 * remote-utils.c (putpkt): Flush after debug output and use
21572 Handle input interrupts while waiting for an ACK.
21573 (input_interrupt): Use signal_pid method.
21574 (getpkt): Flush after debug output and use stderr.
21575 (outreg): Use collect_register_as_string.
21576 (new_thread_notify, dead_thread_notify): New functions.
21577 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21578 and general_thread.
21579 (look_up_one_symbol): Flush after debug output.
21580 * server.c (step_thread, server_waiting): New variables.
21581 (start_inferior): Don't use signal_pid. Update call to mywait.
21582 (attach_inferior): Update call to mywait.
21583 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21584 (main): Don't fetch/store registers explicitly. Use
21585 set_desired_inferior. Support proposed ``Hs'' packet. Update
21587 * server.h: Update.
21588 (struct inferior_list, struct_inferior_list_entry): New.
21589 * target.c (set_desired_inferior): New.
21590 (write_inferior_memory): Constify.
21591 (mywait): New function.
21592 * target.h: Update.
21593 (struct target_ops): New signal_pid method.
21594 (mywait): Removed macro, added prototype.
21596 * linux-low.h (regset_func): Removed.
21597 (regset_fill_func, regset_store_func): New.
21598 (enum regset_type): New.
21599 (struct regset_info): Add type field. Use new operation types.
21600 (struct linux_target_ops): stop_pc renamed to get_pc.
21601 Add decr_pc_after_break and breakpoint_at.
21602 (get_process, get_thread_proess, get_process_thread)
21603 (strut process_info, all_processes, linux_attach_lwp)
21604 (thread_db_init): New.
21606 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21607 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21608 (the_low_target): Add new members.
21609 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21610 (i386_store_fpxregset): Constify.
21611 (target_regsets): Add new kind identifier.
21612 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21613 (i386_set_pc): Add debugging.
21614 (i386_breakpoint_at): New function.
21615 (the_low_target): Add new members.
21616 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21617 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21618 (mips_breakpoint_at): New.
21619 (the_low_target): Add new members.
21620 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21621 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21622 (the_low_target): Add new members.
21623 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21624 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21625 (the_low_target): Add new members.
21626 * linux-x86-64-low.c (target_regsets): Add new kind
21629 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
21631 From Martin Pool <mbp@samba.org>:
21632 * server.c (gdbserver_usage): New function.
21635 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
21637 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21638 stop_at -> stop_pc.
21640 2002-05-04 Andrew Cagney <ac131313@redhat.com>
21642 * Makefile.in: Remove obsolete code.
21644 2002-04-24 Michal Ludvig <mludvig@suse.cz>
21646 * linux-low.c (regsets_fetch_inferior_registers),
21647 (regsets_store_inferior_registers): Removed cast to int from
21649 * regcache.h: Added declaration of struct inferior_info.
21651 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21653 * inferiors.c (struct inferior_info): Add regcache_data.
21654 (add_inferior): Call create_register_cache.
21655 (clear_inferiors): Call free_register_cache.
21656 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21657 * regcache.c (struct inferior_regcache_data): New.
21658 (registers): Remove.
21659 (get_regcache): New function.
21660 (create_register_cache, free_register_cache): New functions.
21661 (set_register_cache): Don't initialize the register cache here.
21662 (registers_to_string, registers_from_string, register_data): Call
21664 * regcache.h: Add prototypes.
21665 * server.h: Likewise.
21667 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21669 * mem-break.c: New file.
21670 * mem-break.h: New file.
21671 * Makefile.in: Add mem-break.o rule; update server.h
21673 * inferiors.c (struct inferior_info): Add target_data
21675 (clear_inferiors): Free target_data member if set.
21676 (inferior_target_data, set_inferior_target_data): New functions.
21677 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21678 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21679 * linux-low.c (linux_bp_reinsert): New variable.
21680 (struct inferior_linux_data): New.
21681 (linux_create_inferior): Use set_inferior_target_data.
21682 (linux_attach): Likewise. Call add_inferior.
21683 (linux_wait_for_one_inferior): New function.
21684 (linux_wait): Call it.
21685 (linux_write_memory): Add const.
21686 (initialize_low): Call set_breakpoint_data.
21687 * linux-low.h (struct linux_target_ops): Add breakpoint
21689 * server.c (attach_inferior): Remove extra add_inferior
21691 * server.h: Include mem-break.h. Update inferior.c
21693 * target.c (read_inferior_memory)
21694 (write_inferior_memory): New functions.
21695 * target.h (read_inferior_memory)
21696 (write_inferior_memory): Change macros to prototypes.
21697 (struct target_ops): Update comments. Add const to write_memory
21700 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
21702 * linux-low.c (usr_store_inferior_registers): Support
21703 registers which are allowed to fail to store.
21704 * linux-low.h (linux_target_ops): Likewise.
21705 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21706 (ppc_cannot_store_register): FPSCR may not be storable.
21708 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21710 * server.h: Include <string.h> if HAVE_STRING_H.
21711 * ChangeLog: Correct paths in last ChangeLog entry.
21713 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21715 * linux-low.h: Remove obsolete prototypes.
21716 (struct linux_target_ops): New.
21717 (extern the_low_target): New.
21718 * linux-low.c (num_regs, regmap): Remove declarations.
21719 (register_addr): Use the_low_target explicitly.
21720 (fetch_register): Likewise.
21721 (usr_fetch_inferior_registers): Likewise.
21722 (usr_store_inferior_registers): Likewise.
21723 * linux-arm-low.c (num_regs): Remove.
21724 (arm_num_regs): Define.
21725 (arm_regmap): Renamed from regmap, made static.
21726 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21728 (arm_cannot_store_register): Renamed from cannot_store_register,
21730 (the_low_target): New.
21731 * linux-i386-low.c (num_regs): Remove.
21732 (i386_num_regs): Define.
21733 (i386_regmap): Renamed from regmap, made static.
21734 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21736 (i386_cannot_store_register): Renamed from cannot_store_register,
21738 (the_low_target): New.
21739 * linux-ia64-low.c (num_regs): Remove.
21740 (ia64_num_regs): Define.
21741 (ia64_regmap): Renamed from regmap, made static.
21742 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21744 (ia64_cannot_store_register): Renamed from cannot_store_register,
21746 (the_low_target): New.
21747 * linux-m68k-low.c (num_regs): Remove.
21748 (m68k_num_regs): Define.
21749 (m68k_regmap): Renamed from regmap, made static.
21750 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21752 (m68k_cannot_store_register): Renamed from cannot_store_register,
21754 (the_low_target): New.
21755 * linux-mips-low.c (num_regs): Remove.
21756 (mips_num_regs): Define.
21757 (mips_regmap): Renamed from regmap, made static.
21758 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21760 (mips_cannot_store_register): Renamed from cannot_store_register,
21762 (the_low_target): New.
21763 * linux-ppc-low.c (num_regs): Remove.
21764 (ppc_num_regs): Define.
21765 (ppc_regmap): Renamed from regmap, made static.
21766 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21768 (ppc_cannot_store_register): Renamed from cannot_store_register,
21770 (the_low_target): New.
21771 * linux-s390-low.c (num_regs): Remove.
21772 (s390_num_regs): Define.
21773 (s390_regmap): Renamed from regmap, made static.
21774 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21776 (s390_cannot_store_register): Renamed from cannot_store_register,
21778 (the_low_target): New.
21779 * linux-sh-low.c (num_regs): Remove.
21780 (sh_num_regs): Define.
21781 (sh_regmap): Renamed from regmap, made static.
21782 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21784 (sh_cannot_store_register): Renamed from cannot_store_register,
21786 (the_low_target): New.
21787 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21788 (the_low_target): New.
21790 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21792 * Makefile.in: Add stamp-h target.
21793 * configure.in: Create stamp-h.
21794 * configure: Regenerated.
21796 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21798 * inferiors.c: New file.
21799 * target.c: New file.
21800 * target.h: New file.
21801 * Makefile.in: Add target.o and inferiors.o. Update
21803 * linux-low.c (inferior_pid): New static variable,
21804 moved from server.c.
21805 (linux_create_inferior): Renamed from create_inferior.
21806 Call add_inferior. Return 0 on success instead of a PID.
21807 (linux_attach): Renamed from myattach.
21808 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21809 (linux_thread_alive): Renamed from mythread_alive.
21810 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21812 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21813 (regsets_store_inferior_registers): Correct error message.
21814 Add missing ``return 0''.
21815 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21816 (linux_store_registers): Renamed from store_inferior_registers.
21817 (linux_read_memory): Renamed from read_inferior_memory.
21818 (linux_write_memory): Renamed from write_inferior_memory.
21819 (linux_target_ops): New structure.
21820 (initialize_low): Call set_target_ops ().
21821 * remote-utils.c (unhexify): New function.
21822 (hexify): New function.
21823 (input_interrupt): Send signals to ``signal_pid''.
21824 * server.c (inferior_pid): Remove.
21825 (start_inferior): Update create_inferior call.
21826 (attach_inferior): Call add_inferior.
21827 (handle_query): New function.
21828 (main): Call handle_query for `q' packets.
21829 * server.h: Include "target.h". Remove obsolete prototypes.
21830 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21832 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21834 * Makefile.in: Add WARN_CFLAGS. Update configury
21836 * configure.in: Check for <string.h>
21837 * configure: Regenerate.
21838 * config.in: Regenerate.
21839 * gdbreplay.c: Include needed system headers.
21840 (remote_open): Remove strchr prototype.
21841 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21842 * regcache.c (supply_register): Change buf argument to const void *.
21843 (supply_register_by_name): Likewise.
21844 (collect_register): Change buf argument to void *.
21845 (collect_register_by_name): Likewise.
21846 * regcache.h: Add missing prototypes.
21847 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21848 * server.c (handle_query): New function.
21849 (attached): New static variable, moved out of main.
21850 (main): Quiet longjmp clobber warnings.
21851 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21852 * utils.c (error): Remove NORETURN.