]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdbserver/ChangeLog
gdbserver/linux-low: turn 'get_pc' and 'set_pc' into methods
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
bf9ae9d8
TBA
12020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2
3 Turn the 'get_pc' and 'set_pc' linux target ops into methods
4 of linux_process_target.
5
6 * linux-low.h (struct linux_target_ops): Remove the ops.
7 (class linux_process_target) <low_supports_breakpoints>
8 <low_get_pc>
9 <low_set_pc>: Declare.
10 * linux-low.cc (supports_breakpoints): Turn into...
11 (linux_process_target::low_supports_breakpoints): ...this.
12 (linux_process_target::low_get_pc): Define.
13 (linux_process_target::low_set_pc): Define.
14
15 Update the callers below.
16
17 (linux_process_target::get_pc)
18 (linux_process_target::save_stop_reason)
19 (linux_process_target::maybe_move_out_of_jump_pad)
20 (linux_process_target::wait_1)
21 (linux_process_target::resume_one_lwp_throw)
22 (linux_process_target::resume)
23 (linux_process_target::proceed_all_lwps)
24 (linux_process_target::read_pc)
25 (linux_process_target::write_pc)
26
27 * linux-x86-low.cc (class linux_process_target)
28 <low_supports_breakpoints>
29 <low_get_pc>
30 <low_set_pc>: Declare.
31 (x86_target::low_supports_breakpoints): Define.
32 (x86_get_pc): Turn into...
33 (x86_target::low_get_pc): ...this.
34 (x86_set_pc): Turn into...
35 (x86_target::low_set_pc): ...this.
36 (the_low_target): Remove the op fields.
37 * linux-arm-low.cc (class arm_target)
38 <low_supports_breakpoints>
39 <low_get_pc>
40 <low_set_pc>: Declare.
41 (arm_target::low_supports_breakpoints)
42 (arm_target::low_get_pc)
43 (arm_target::low_set_pc): Define.
44 (the_low_target): Remove the op fields.
45 * linux-bfin-low.cc (class bfin_target)
46 <low_supports_breakpoints>
47 <low_get_pc>
48 <low_set_pc>: Declare.
49 (bfin_target::low_supports_breakpoints)
50 (bfin_target::low_get_pc)
51 (bfin_target::low_set_pc): Define.
52 (the_low_target): Remove the op fields.
53 * linux-cris-low.cc (class cris_target)
54 <low_supports_breakpoints>
55 <low_get_pc>
56 <low_set_pc>: Declare.
57 (cris_target::low_supports_breakpoints)
58 (cris_target::low_get_pc)
59 (cris_target::low_set_pc): Define.
60 (the_low_target): Remove the op fields.
61 * linux-crisv32-low.cc (class crisv32_target)
62 <low_supports_breakpoints>
63 <low_get_pc>
64 <low_set_pc>: Declare.
65 (crisv32_target::low_supports_breakpoints)
66 (crisv32_target::low_get_pc)
67 (crisv32_target::low_set_pc): Define.
68 (the_low_target): Remove the op fields.
69 * linux-m32r-low.cc (class m32r_target)
70 <low_supports_breakpoints>
71 <low_get_pc>
72 <low_set_pc>: Declare.
73 (m32r_target::low_supports_breakpoints)
74 (m32r_target::low_get_pc)
75 (m32r_target::low_set_pc): Define.
76 (the_low_target): Remove the op fields.
77 * linux-m68k-low.cc (class m68k_target)
78 <low_supports_breakpoints>
79 <low_get_pc>
80 <low_set_pc>: Declare.
81 (m68k_target::low_supports_breakpoints)
82 (m68k_target::low_get_pc)
83 (m68k_target::low_set_pc): Define.
84 (the_low_target): Remove the op fields.
85 * linux-nios2-low.cc (class nios2_target)
86 <low_supports_breakpoints>
87 <low_get_pc>
88 <low_set_pc>: Declare.
89 (nios2_target::low_supports_breakpoints)
90 (nios2_target::low_get_pc)
91 (nios2_target::low_set_pc): Define.
92 (the_low_target): Remove the op fields.
93 * linux-sh-low.cc (class sh_target)
94 <low_supports_breakpoints>
95 <low_get_pc>
96 <low_set_pc>: Declare.
97 (sh_target::low_supports_breakpoints)
98 (sh_target::low_get_pc)
99 (sh_target::low_set_pc): Define.
100 (the_low_target): Remove the op fields.
101 * linux-xtensa-low.cc (class xtensa_target)
102 <low_supports_breakpoints>
103 <low_get_pc>
104 <low_set_pc>: Declare.
105 (xtensa_target::low_supports_breakpoints)
106 (xtensa_target::low_get_pc)
107 (xtensa_target::low_set_pc): Define.
108 (the_low_target): Remove the op fields.
109 * linux-sparc-low.cc (class sparc_target)
110 <low_supports_breakpoints>
111 <low_get_pc>: Declare.
112 (sparc_target::low_supports_breakpoints)
113 (sparc_target::low_get_pc): Define.
114 (the_low_target): Remove the op fields.
115 * linux-tile-low.cc (class tile_target)
116 <low_supports_breakpoints>
117 <low_get_pc>
118 <low_set_pc>: Declare.
119 (tile_target::low_supports_breakpoints)
120 (tile_target::low_get_pc)
121 (tile_target::low_set_pc): Define.
122 (the_low_target): Remove the op fields.
123 * linux-aarch64-low.cc (class aarch64_target)
124 <low_supports_breakpoints>
125 <low_get_pc>
126 <low_set_pc>: Declare.
127 (aarch64_target::low_supports_breakpoints): Define.
128 (aarch64_get_pc): Turn into...
129 (aarch64_target::low_get_pc): ...this.
130 (aarch64_set_pc): Turn into...
131 (aarch64_target::low_set_pc): ...this.
132 (the_low_target): Remove the op fields.
133 * linux-mips-low.cc (class mips_target)
134 <low_supports_breakpoints>
135 <low_get_pc>
136 <low_set_pc>: Declare.
137 (mips_target::low_supports_breakpoints): Define.
138 (mips_get_pc): Turn into...
139 (mips_target::low_get_pc): ...this.
140 (mips_set_pc): Turn into...
141 (mips_target::low_set_pc): ...this.
142 (the_low_target): Remove the op fields.
143 * linux-ppc-low.cc (class ppc_target)
144 <low_supports_breakpoints>
145 <low_get_pc>
146 <low_set_pc>: Declare.
147 (ppc_target::low_supports_breakpoints): Define.
148 (ppc_get_pc): Turn into...
149 (ppc_target::low_get_pc): ...this.
150 (ppc_set_pc): Turn into...
151 (ppc_target::low_set_pc): ...this.
152 (the_low_target): Remove the op fields.
153 * linux-riscv-low.cc (class riscv_target)
154 <low_supports_breakpoints>
155 <low_get_pc>
156 <low_set_pc>: Declare.
157 (riscv_target::low_supports_breakpoints): Define.
158 (riscv_get_pc): Turn into...
159 (riscv_target::low_get_pc): ...this.
160 (riscv_set_pc): Turn into...
161 (riscv_target::low_set_pc): ...this.
162 (the_low_target): Remove the op fields.
163 * linux-s390-low.cc (class s390_target)
164 <low_supports_breakpoints>
165 <low_get_pc>
166 <low_set_pc>: Declare.
167 (s390_target::low_supports_breakpoints): Define.
168 (s390_get_pc): Turn into...
169 (s390_target::low_get_pc): ...this.
170 (s390_set_pc): Turn into...
171 (s390_target::low_set_pc): ...this.
172 (the_low_target): Remove the op fields.
173 * linux-tic6x-low.cc (class tic6x_target)
174 <low_supports_breakpoints>
175 <low_get_pc>
176 <low_set_pc>: Declare.
177 (tic6x_target::low_supports_breakpoints): Define.
178 (tic6x_get_pc): Turn into...
179 (tic6x_target::low_get_pc): ...this.
180 (tic6x_set_pc): Turn into...
181 (tic6x_target::low_set_pc): ...this.
182 (the_low_target): Remove the op fields.
183
df95181f
TBA
1842020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
185
186 Turn some more static methods in linux-low into private methods
187 of linux_process_target.
188
189 * linux-low.cc (get_pc): Turn into...
190 (linux_process_target::get_pc): ...this.
191 (save_stop_reason): Turn into...
192 (linux_process_target::save_stop_reason): ...this.
193 (thread_still_has_status_pending_p): Turn into...
194 (linux_process_target::thread_still_has_status_pending): ...this.
195 (status_pending_p_callback): Turn into...
196 (linux_process_target::status_pending_p_callback): ...this.
197 (resume_stopped_resumed_lwps): Turn into...
198 (linux_process_target::resume_stopped_resumed_lwps): ...this.
199 (install_software_single_step_breakpoints): Turn into...
200 (linux_process_target::install_software_single_step_breakpoints):
201 ...this.
202 (single_step): Turn into...
203 (linux_process_target::single_step): ...this.
204 (linux_resume_one_lwp_throw): Turn into...
205 (linux_process_target::resume_one_lwp_throw): ...this.
206 (linux_resume_one_lwp): Turn into...
207 (linux_process_target::resume_one_lwp): ...this.
208 (resume_status_pending_p): Turn into...
209 (linux_process_target::resume_status_pending): ...this.
210 (need_step_over_p): Turn into...
211 (linux_process_target::thread_needs_step_over): ...this.
212 (linux_resume_one_thread): Turn into...
213 (linux_process_target::resume_one_thread): ...this.
214 (proceed_one_lwp): Turn into...
215 (linux_process_target::proceed_one_lwp): ...this.
216 (unsuspend_and_proceed_one_lwp): Turn into...
217 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
218
219 Update the calls/references to the above functions below.
220
221 (linux_process_target::handle_extended_wait)
222 (linux_process_target::filter_event)
223 (linux_process_target::wait_for_event_filtered)
224 (linux_process_target::wait_1)
225 (linux_process_target::move_out_of_jump_pad)
226 (linux_process_target::start_step_over)
227 (linux_process_target::resume)
228 (linux_process_target::proceed_all_lwps)
229 (regsets_store_inferior_registers)
230 (linux_process_target::store_register)
231
232 * linux-low.h (class linux_process_target)
233 <get_pc>
234 <save_stop_reason>
235 <thread_still_has_status_pending>
236 <status_pending_p_callback>
237 <resume_stopped_resumed_lwps>
238 <install_software_single_step_breakpoints>
239 <single_step>
240 <resume_one_lwp_throw>
241 <resume_one_lwp>
242 <resume_status_pending>
243 <thread_needs_step_over>
244 <resume_one_thread>
245 <proceed_one_lwp>
246 <unsuspend_and_proceed_one_lwp>: Declare.
247
bd70b1f2
TBA
2482020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
249
250 Turn the 'fetch_register' linux target op into a method of
251 linux_process_target.
252
253 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
254 (class linux_process_target) <low_fetch_register>: Declare.
255 * linux-x86-low.cc (the_low_target)
256 * linux-aarch64-low.cc (the_low_target)
257 * linux-arm-low.cc (the_low_target)
258 * linux-bfin-low.cc (the_low_target)
259 * linux-cris-low.cc (the_low_target)
260 * linux-crisv32-low.cc (the_low_target)
261 * linux-m32r-low.cc (the_low_target)
262 * linux-m68k-low.cc (the_low_target)
263 * linux-nios2-low.cc (the_low_target)
264 * linux-ppc-low.cc (the_low_target)
265 * linux-s390-low.cc (the_low_target)
266 * linux-sh-low.cc (the_low_target)
267 * linux-sparc-low.cc (the_low_target)
268 * linux-tic6x-low.cc (the_low_target)
269 * linux-tile-low.cc (the_low_target)
270 * linux-xtensa-low.cc (the_low_target): Remove the op field.
271 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
272 Declare.
273 (ia64_fetch_register): Turn into...
274 (ia64_target::low_fetch_register): ...this.
275 (the_low_target): Remove the op field.
276 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
277 Declare.
278 (mips_fetch_register): Turn into...
279 (mips_target::low_fetch_register): ...this.
280 (the_low_target): Remove the op field.
281 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
282 Declare.
283 (riscv_fetch_register): Turn into...
284 (riscv_target::low_fetch_register): ...this.
285 (the_low_target): Remove the op field.
286
287 Update the callers below.
288
289 * linux-low.cc (linux_process_target::fetch_registers)
290 (linux_process_target::low_fetch_register)
291
daca57a7
TBA
2922020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
293
294 Turn the 'cannot_fetch_register' and 'cannot_store_register'
295 linux target ops into methods of linux_process_target.
296
297 * linux-low.h (struct linux_target_ops): Remove the low target ops.
298 (class linux_process_target) <fetch_register>
299 <store_register>
300 <usr_fetch_inferior_registers>
301 <usr_store_inferior_registers>
302 <low_cannot_fetch_register>
303 <low_cannot_fetch_register> Declare.
304 * linux-low.cc (fetch_register): Turn into...
305 (linux_process_target::fetch_register): ...this.
306 (store_register): Turn into ...
307 (linux_process_target::store_register): ...this.
308 (usr_fetch_inferior_registers): Turn into...
309 (linux_process_target::usr_fetch_inferior_registers): ...this.
310 (usr_store_inferior_registers): Turn into...
311 (linux_process_target::usr_store_inferior_registers): ...this.
312 * linux-x86-low.cc (class x86_target)
313 <low_cannot_fetch_register>
314 <low_cannot_store_register>: Declare.
315 (x86_cannot_store_register): Turn into...
316 (x86_target::low_cannot_store_register): ...this.
317 (x86_cannot_fetch_register): Turn into...
318 (x86_target::low_cannot_fetch_register): ...this.
319 (the_low_target): Remove the target op fields.
320 * linux-aarch64-low.cc (class aarch64_target)
321 <low_cannot_fetch_register>
322 <low_cannot_store_register>: Declare.
323 (aarch64_target::low_cannot_fetch_register)
324 (aarch64_target::low_cannot_store_register): Define.
325 (the_low_target): Remove the op fields.
326 * linux-arm-low.cc (class arm_target)
327 <low_cannot_fetch_register>
328 <low_cannot_store_register>: Declare.
329 (arm_cannot_fetch_register): Turn into...
330 (arm_target::low_cannot_fetch_register): ...this.
331 (arm_cannot_store_register): Turn into...
332 (arm_target::low_cannot_store_register): ...this.
333 (the_low_target): Remove the op fields.
334 * linux-bfin-low.cc (class bfin_target)
335 <low_cannot_fetch_register>
336 <low_cannot_store_register>: Declare.
337 (bfin_cannot_fetch_register): Turn into...
338 (bfin_target::low_cannot_fetch_register): ...this.
339 (bfin_cannot_store_register): Turn into...
340 (bfin_target::low_cannot_store_register): ...this.
341 (the_low_target): Remove the op fields.
342 * linux-cris-low.cc (class cris_target)
343 <low_cannot_fetch_register>
344 <low_cannot_store_register>: Declare.
345 (cris_cannot_fetch_register): Turn into...
346 (cris_target::low_cannot_fetch_register): ...this.
347 (cris_cannot_store_register): Turn into...
348 (cris_target::low_cannot_store_register): ...this.
349 (the_low_target): Remove the op fields.
350 * linux-crisv32-low.cc (class crisv32_target)
351 <low_cannot_fetch_register>
352 <low_cannot_store_register>: Declare.
353 (crisv32_target::low_cannot_fetch_register)
354 (crisv32_target::low_cannot_store_register): Define.
355 (the_low_target): Remove the op fields.
356 * linux-ia64-low.cc (class ia64_target)
357 <low_cannot_fetch_register>
358 <low_cannot_store_register>: Declare.
359 (ia64_cannot_fetch_register): Turn into...
360 (ia64_target::low_cannot_fetch_register): ...this.
361 (ia64_cannot_store_register): Turn into...
362 (ia64_target::low_cannot_store_register): ...this.
363 (the_low_target): Remove the op fields.
364 * linux-m32r-low.cc (class m32r_target)
365 <low_cannot_fetch_register>
366 <low_cannot_store_register>: Declare.
367 (m32r_cannot_fetch_register): Turn into...
368 (m32r_target::low_cannot_fetch_register): ...this.
369 (m32r_cannot_store_register): Turn into...
370 (m32r_target::low_cannot_store_register): ...this.
371 (the_low_target): Remove the op fields.
372 * linux-m68k-low.cc (class m68k_target)
373 <low_cannot_fetch_register>
374 <low_cannot_store_register>: Declare.
375 (m68k_cannot_fetch_register): Turn into...
376 (m68k_target::low_cannot_fetch_register): ...this.
377 (m68k_cannot_store_register): Turn into...
378 (m68k_target::low_cannot_store_register): ...this.
379 (the_low_target): Remove the op fields.
380 * linux-mips-low.cc (class mips_target)
381 <low_cannot_fetch_register>
382 <low_cannot_store_register>: Declare.
383 (mips_cannot_fetch_register): Turn into...
384 (mips_target::low_cannot_fetch_register): ...this.
385 (mips_cannot_store_register): Turn into...
386 (mips_target::low_cannot_store_register): ...this.
387 (get_usrregs_info): Inline at the call sites in
388 low_cannot_fetch_register and low_cannot_store_register,
389 and remove.
390 (the_low_target): Remove the op fields.
391 * linux-nios2-low.cc (class nios2_target)
392 <low_cannot_fetch_register>
393 <low_cannot_store_register>: Declare.
394 (nios2_cannot_fetch_register): Turn into...
395 (nios2_target::low_cannot_fetch_register): ...this.
396 (nios2_cannot_store_register): Turn into...
397 (nios2_target::low_cannot_store_register): ...this.
398 (the_low_target): Remove the op fields.
399 * linux-ppc-low.cc (class ppc_target)
400 <low_cannot_fetch_register>
401 <low_cannot_store_register>: Declare.
402 (ppc_cannot_fetch_register): Turn into...
403 (ppc_target::low_cannot_fetch_register): ...this.
404 (ppc_cannot_store_register): Turn into...
405 (ppc_target::low_cannot_store_register): ...this.
406 (the_low_target): Remove the op fields.
407 * linux-riscv-low.cc (class riscv_target)
408 <low_cannot_fetch_register>
409 <low_cannot_store_register>: Declare.
410 (riscv_target::low_cannot_fetch_register)
411 (riscv_target::low_cannot_store_register): Define.
412 (the_low_target): Remove the op fields.
413 * linux-s390-low.cc (class s390_target)
414 <low_cannot_fetch_register>
415 <low_cannot_store_register>: Declare.
416 (s390_cannot_fetch_register): Turn into...
417 (s390_target::low_cannot_fetch_register): ...this.
418 (s390_cannot_store_register): Turn into...
419 (s390_target::low_cannot_store_register): ...this.
420 (the_low_target): Remove the op fields.
421 * linux-sh-low.cc (class sh_target)
422 <low_cannot_fetch_register>
423 <low_cannot_store_register>: Declare.
424 (sh_cannot_fetch_register): Turn into...
425 (sh_target::low_cannot_fetch_register): ...this.
426 (sh_cannot_store_register): Turn into...
427 (sh_target::low_cannot_store_register): ...this.
428 (the_low_target): Remove the op fields.
429 * linux-sparc-low.cc (class sparc_target)
430 <low_cannot_fetch_register>
431 <low_cannot_store_register>: Declare.
432 (sparc_cannot_fetch_register): Turn into...
433 (sparc_target::low_cannot_fetch_register): ...this.
434 (sparc_cannot_store_register): Turn into...
435 (sparc_target::low_cannot_store_register): ...this.
436 (the_low_target): Remove the op fields.
437 * linux-tic6x-low.cc (class tic6x_target)
438 <low_cannot_fetch_register>
439 <low_cannot_store_register>: Declare.
440 (tic6x_cannot_fetch_register): Turn into...
441 (tic6x_target::low_cannot_fetch_register): ...this.
442 (tic6x_cannot_store_register): Turn into...
443 (tic6x_target::low_cannot_store_register): ...this.
444 (the_low_target): Remove the op fields.
445 * linux-tile-low.cc (class tile_target)
446 <low_cannot_fetch_register>
447 <low_cannot_store_register>: Declare.
448 (tile_cannot_fetch_register): Turn into...
449 (tile_target::low_cannot_fetch_register): ...this.
450 (tile_cannot_store_register): Turn into...
451 (tile_target::low_cannot_store_register): ...this.
452 (the_low_target): Remove the op fields.
453 * linux-xtensa-low.cc (class xtensa_target)
454 <low_cannot_fetch_register>
455 <low_cannot_store_register>: Declare.
456 (xtensa_target::low_cannot_fetch_register)
457 (xtensa_target::low_cannot_store_register): Define.
458 (the_low_target): Remove the op fields.
459
aa8d21c9
TBA
4602020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
461
462 Turn the 'regs_info' linux target op into a method of
463 linux_process_target.
464
465 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
466 (class linux_process_target) <get_regs_info>: Define.
467
468 Update the callers below.
469
470 * linux-low.cc (linux_process_target::fetch_registers)
471 (linux_process_target::store_registers)
472 * proc-service.cc (gregset_info)
473
474 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
475 (x86_linux_regs_info): Turn into ...
476 (x86_target::get_regs_info): ...this.
477 (the_low_target): Remove the op field.
478 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
479 Declare.
480 (aarch64_regs_info): Turn into ...
481 (aarch64_target::get_regs_info): ...this.
482 (the_low_target): Remove the op field.
483 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
484 (arm_regs_info): Turn into ...
485 (arm_target::get_regs_info): ...this.
486 (the_low_target): Remove the op field.
487 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
488 (bfin_regs_info): Turn into ...
489 (bfin_target::get_regs_info): ...this.
490 (the_low_target): Remove the op field.
491 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
492 (cris_regs_info): Turn into ...
493 (cris_target::get_regs_info): ...this.
494 (the_low_target): Remove the op field.
495 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
496 Declare.
497 (crisv32_regs_info): Turn into ...
498 (crisv32_target::get_regs_info): ...this.
499 (the_low_target): Remove the op field.
500 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
501 (ia64_regs_info): Turn into ...
502 (ia64_target::get_regs_info): ...this.
503 (the_low_target): Remove the op field.
504 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
505 (m32r_regs_info): Turn into ...
506 (m32r_target::get_regs_info): ...this.
507 (the_low_target): Remove the op field.
508 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
509 (m68k_regs_info): Turn into ...
510 (m68k_target::get_regs_info): ...this.
511 (the_low_target): Remove the op field.
512 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
513 (mips_regs_info): Turn into ...
514 (mips_target::get_regs_info): ...this.
515 (the_low_target): Remove the op field.
516 (get_usrregs_info): Update the call to the op.
517 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
518 (nios2_regs_info): Turn into ...
519 (nios2_target::get_regs_info): ...this.
520 (the_low_target): Remove the op field.
521 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
522 (ppc_regs_info): Turn into ...
523 (ppc_target::get_regs_info): ...this.
524 (the_low_target): Remove the op field.
525 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
526 (riscv_regs_info): Turn into ...
527 (riscv_target::get_regs_info): ...this.
528 (the_low_target): Remove the op field.
529 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
530 (s390_regs_info): Turn into ...
531 (s390_target::get_regs_info): ...this.
532 (the_low_target): Remove the op field.
533 (s390_collect_ptrace_register)
534 (s390_supply_ptrace_register)
535 (s390_fill_gregset): Update the call to the op.
536 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
537 (sh_regs_info): Turn into ...
538 (sh_target::get_regs_info): ...this.
539 (the_low_target): Remove the op field.
540 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
541 (sparc_regs_info): Turn into ...
542 (sparc_target::get_regs_info): ...this.
543 (the_low_target): Remove the op field.
544 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
545 (tic6x_regs_info): Turn into ...
546 (tic6x_target::get_regs_info): ...this.
547 (the_low_target): Remove the op field.
548 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
549 (tile_regs_info): Turn into ...
550 (tile_target::get_regs_info): ...this.
551 (the_low_target): Remove the op field.
552 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
553 Declare.
554 (xtensa_regs_info): Turn into ...
555 (xtensa_target::get_regs_info): ...this.
556 (the_low_target): Remove the op field.
557
797bcff5
TBA
5582020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
559
560 Turn the 'arch_setup' linux target op into a method of
561 linux_process_target.
562
563 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
564 (class linux_process_target) <arch_setup_thread>
565 <low_arch_setup>: New declarations.
566 * linux-low.cc (linux_arch_setup): Delete.
567 (linux_arch_setup_thread): Turn into...
568 (linux_process_target::arch_setup_thread): ... this.
569
570 Update the callers below.
571
572 (linux_process_target::handle_extended_wait)
573 (linux_process_target::post_create_inferior)
574 (linux_process_target::filter_event)
575
576 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
577 declaration.
578 (x86_linux_update_xmltarget): Turn into...
579 (x86_target::update_xmltarget): ...this.
580 (x86_linux_process_qsupported): Update the call to
581 x86_linux_update_xmltarget.
582 (x86_arch_setup): Turn into ...
583 (x86_target::low_arch_setup): ...this.
584 (the_low_target): Remove the op field.
585 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
586 declaration.
587 (aarch64_arch_setup): Turn into ...
588 (aarch64_target::low_arch_setup): ...this.
589 (the_low_target): Remove the op field.
590 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
591 declaration.
592 (arm_arch_setup): Turn into ...
593 (arm_target::low_arch_setup): ...this.
594 (the_low_target): Remove the op field.
595 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
596 declaration.
597 (bfin_arch_setup): Turn into ...
598 (bfin_target::low_arch_setup): ...this.
599 (the_low_target): Remove the op field.
600 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
601 declaration.
602 (cris_arch_setup): Turn into ...
603 (cris_target::low_arch_setup): ...this.
604 (the_low_target): Remove the op field.
605 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
606 declaration.
607 (crisv32_arch_setup): Turn into ...
608 (crisv32_target::low_arch_setup): ...this.
609 (the_low_target): Remove the op field.
610 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
611 declaration.
612 (ia64_arch_setup): Turn into ...
613 (ia64_target::low_arch_setup): ...this.
614 (the_low_target): Remove the op field.
615 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
616 declaration.
617 (m32r_arch_setup): Turn into ...
618 (m32r_target::low_arch_setup): ...this.
619 (the_low_target): Remove the op field.
620 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
621 declaration.
622 (m68k_arch_setup): Turn into ...
623 (m68k_target::low_arch_setup): ...this.
624 (the_low_target): Remove the op field.
625 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
626 declaration.
627 (mips_arch_setup): Turn into ...
628 (mips_target::low_arch_setup): ...this.
629 (the_low_target): Remove the op field.
630 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
631 declaration.
632 (nios2_arch_setup): Turn into ...
633 (nios2_target::low_arch_setup): ...this.
634 (the_low_target): Remove the op field.
635 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
636 declaration.
637 (ppc_arch_setup): Turn into ...
638 (ppc_target::low_arch_setup): ...this.
639 (the_low_target): Remove the op field.
640 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
641 declaration.
642 (riscv_arch_setup): Turn into ...
643 (riscv_target::low_arch_setup): ...this.
644 (the_low_target): Remove the op field.
645 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
646 declaration.
647 (s390_arch_setup): Turn into ...
648 (s390_target::low_arch_setup): ...this.
649 (the_low_target): Remove the op field.
650 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
651 declaration.
652 (sh_arch_setup): Turn into ...
653 (sh_target::low_arch_setup): ...this.
654 (the_low_target): Remove the op field.
655 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
656 declaration.
657 (sparc_arch_setup): Turn into ...
658 (sparc_target::low_arch_setup): ...this.
659 (the_low_target): Remove the op field.
660 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
661 declaration.
662 (tic6x_arch_setup): Turn into ...
663 (tic6x_target::low_arch_setup): ...this.
664 (the_low_target): Remove the op field.
665 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
666 declaration.
667 (tile_arch_setup): Turn into ...
668 (tile_target::low_arch_setup): ...this.
669 (the_low_target): Remove the op field.
670 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
671 declaration.
672 (xtensa_arch_setup): Turn into ...
673 (xtensa_target::low_arch_setup): ...this.
674 (the_low_target): Remove the op field.
675
ef0478f6
TBA
6762020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
677
678 * linux-low.h (the_linux_target): New extern declaration.
679 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
680 'the_target'.
681 (the_linux_target): Remove.
682 * linux-x86-low.cc (class x86_target): New class.
683 (the_x86_target): New static object.
684 (the_linux_target): Define as pointer to the_x86_target.
685 * linux-aarch64-low.cc (class aarch64_target): New class.
686 (the_aarch64_target): New static object.
687 (the_linux_target): Define as pointer to the_aarch64_target.
688 * linux-arm-low.cc (class arm_target): New class.
689 (the_arm_target): New static object.
690 (the_linux_target): Define as pointer to the_arm_target.
691 * linux-bfin-low.cc (class bfin_target): New class.
692 (the_bfin_target): New static object.
693 (the_linux_target): Define as pointer to the_bfin_target.
694 * linux-cris-low.cc (class cris_target): New class.
695 (the_cris_target): New static object.
696 (the_linux_target): Define as pointer to the_cris_target.
697 * linux-crisv32-low.cc (class crisv32_target): New class.
698 (the_crisv32_target): New static object.
699 (the_linux_target): Define as pointer to the_crisv32_target.
700 * linux-ia64-low.cc (class ia64_target): New class.
701 (the_ia64_target): New static object.
702 (the_linux_target): Define as pointer to the_ia64_target.
703 * linux-m32r-low.cc (class m32r_target): New class.
704 (the_m32r_target): New static object.
705 (the_linux_target): Define as pointer to the_m32r_target.
706 * linux-m68k-low.cc (class m68k_target): New class.
707 (the_m68k_target): New static object.
708 (the_linux_target): Define as pointer to the_m68k_target.
709 * linux-mips-low.cc (class mips_target): New class.
710 (the_mips_target): New static object.
711 (the_linux_target): Define as pointer to the_mips_target.
712 * linux-nios2-low.cc (class nios2_target): New class.
713 (the_nios2_target): New static object.
714 (the_linux_target): Define as pointer to the_nios2_target.
715 * linux-ppc-low.cc (class ppc_target): New class.
716 (the_ppc_target): New static object.
717 (the_linux_target): Define as pointer to the_ppc_target.
718 * linux-riscv-low.cc (class riscv_target): New class.
719 (the_riscv_target): New static object.
720 (the_linux_target): Define as pointer to the_riscv_target.
721 * linux-s390-low.cc (class s390_target): New class.
722 (the_s390_target): New static object.
723 (the_linux_target): Define as pointer to the_s390_target.
724 * linux-sh-low.cc (class sh_target): New class.
725 (the_sh_target): New static object.
726 (the_linux_target): Define as pointer to the_sh_target.
727 * linux-sparc-low.cc (class sparc_target): New class.
728 (the_sparc_target): New static object.
729 (the_linux_target): Define as pointer to the_sparc_target.
730 * linux-tic6x-low.cc (class tic6x_target): New class.
731 (the_tic6x_target): New static object.
732 (the_linux_target): Define as pointer to the_tic6x_target.
733 * linux-tile-low.cc (class tile_target): New class.
734 (the_tile_target): New static object.
735 (the_linux_target): Define as pointer to the_tile_target.
736 * linux-xtensa-low.cc (class xtensa_target): New class.
737 (the_xtensa_target): New static object.
738 (the_linux_target): Define as pointer to the_xtensa_target.
739
d16f3f6c
TBA
7402020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
741
742 Turn some static functions in linux-low.cc into private methods of
743 linux_process_target.
744
745 * linux-low.cc (handle_extended_wait): Turn into ...
746 (linux_process_target::handle_extended_wait): ...this. Call
747 'mourn' on 'this' object instead of 'the_target'.
748 (maybe_move_out_of_jump_pad): Turn into...
749 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
750 (linux_low_filter_event): Turn into...
751 (linux_process_target::filter_event): ...this.
752 (linux_wait_for_event_filtered): Turn into...
753 (linux_process_target::wait_for_event_filtered): ...this.
754 (linux_wait_for_event): Turn into...
755 (linux_process_target::wait_for_event): ...this.
756 (linux_wait_1): Turn into...
757 (linux_process_target::wait_1): ...this.
758 (wait_for_sigstop): Turn into...
759 (linux_process_target::wait_for_sigstop): ...this.
760 (move_out_of_jump_pad_callback): Turn into...
761 (linux_process_target::move_out_of_jump_pad): ...this.
762 (stop_all_lwps): Turn into...
763 (linux_process_target::stop_all_lwps): ...this.
764 (start_step_over): Turn into...
765 (linux_process_target::start_step_over): ...this.
766 (complete_ongoing_step_over): Turn into...
767 (linux_process_target::complete_ongoing_step_over): ...this.
768 (proceed_all_lwps): Turn into...
769 (linux_process_target::proceed_all_lwps): ...this.
770 (unstop_all_lwps): Turn into...
771 (linux_process_target::unstop_all_lwps): ...this.
772
773 * linux-low.h (class linux_process_target)
774 <handle_extended_wait>
775 <maybe_move_out_of_jump_pad>
776 filter_event>
777 <wait_for_event_filtered>
778 <wait_for_event>
779 <wait_1>
780 <wait_for_sigstop>
781 <move_out_of_jump_pad>
782 <stop_all_lwps>
783 <start_step_over>
784 <complete_ongoing_step_over>
785 <proceed_all_lwps>
786 <unstop_all_lwps>: Declare.
787
788 Update the callers below.
789
790 * linux-low.cc (linux_process_target::attach): Update.
791 (linux_process_target::stabilize_threads): Ditto.
792 (linux_process_target::wait): Ditto.
793
a5863204
TBA
7942020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
795
796 * linux-low.h (struct linux_target_ops): Update the comment for
797 'cannot_store_register' to return 0 or 1.
798 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
799 of 2.
800
c884cc46
SM
8012020-03-20 Simon Marchi <simon.marchi@efficios.com>
802
803 * config.in: Re-generate.
804 * configure: Re-generate.
805
5a82b8a1
KR
8062020-03-17 Kamil Rytarowski <n54@gmx.com>
807
808 * regcache.cc (find_register_by_number): Update.
809 * tdesc.cc (init_target_desc): Likewise.
810 * tdesc.h (target_desc::reg_defs): Likewise.
811
4635ff97
TT
8122020-03-12 Tom Tromey <tom@tromey.com>
813
814 * configure: Rebuild.
815 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
816 (WIN32APILIBS): New subst.
817 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
818 gdbsupport files.
819 (gdbsupport/%.o): Remove target.
820 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
821 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
822 (WIN32APILIBS): New variable.
823 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
824 (gdbreplay$(EXEEXT)): Likewise.
825
9a665d62
TT
8262020-03-12 Tom Tromey <tom@tromey.com>
827
828 * config.in, configure: Rebuild.
829 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
830 * acinclude.m4: Include gettext-sister.m4.
831 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
832 variables.
833 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
834 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
835
272cd5a3
SM
8362020-03-12 Simon Marchi <simon.marchi@efficios.com>
837
838 * acinclude.m4: Update path to selftest.m4.
839
db6878ac
SM
8402020-03-12 Simon Marchi <simon.marchi@efficios.com>
841
842 * configure.ac: Don't source bfd/development.sh, move
843 GDB_AC_COMMON higher.
844 * configure: Re-generate.
845
4d696a5c
SM
8462020-03-12 Simon Marchi <simon.marchi@efficios.com>
847
848 * configure: Re-generate.
849
a0761e34
SM
8502020-03-11 Simon Marchi <simon.marchi@efficios.com>
851
852 * configure: Re-generate.
853
20ea4a60
AB
8542020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
855
856 * .dir-locals.el: New file.
857
842806cb
TBA
8582020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
859
860 * .gitattributes: New file.
861
442131c1
AB
8622020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
863
864 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
865 reply into an S reply.
866 * server.cc (disable_packet_T): New global.
867 (captured_main): Set new global when appropriate.
868 * server.h (disable_packet_T): Declare.
869
dda42c0b
TT
8702020-02-21 Tom Tromey <tom@tromey.com>
871
872 * Makefile.in (mostlyclean): New target.
873
52405d85
TBA
8742020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
875
876 * target.h (struct process_stratum_target): Remove.
877 (class process_target): Rename to ...
878 (class process_stratum_target): ... this.
879 * linux-low.h (class linux_process_target): Derive from
880 'process_stratum_target'.
881 * linux-low.cc (linux_target_ops): Remove.
882 (initialize_low): Set the_target to the singleton instance of
883 linux_process_target.
884 * lynx-low.h (class lynx_process_target): Derive from
885 'process_stratum_target'.
886 * lynx-low.cc (lynx_target_ops): Remove.
887 (initialize_low): Set the_target to the singleton instance of
888 lynx_process_target.
889 * nto-low.h (class nto_process_target): Derive from
890 'process_stratum_target'.
891 * nto-low.cc (nto_target_ops): Remove.
892 (initialize_low): Set the_target to the singleton instance of
893 nto_process_target.
894 * win32-low.h (class win32_process_target): Derive from
895 'process_stratum_target'.
896 * win32-low.cc (win32_target_ops): Remove.
897 (initialize_low): Set the_target to the singleton instance of
898 win32_process_target.
899
900 Replace 'the_target->pt' with 'the_target' in the uses below.
901
902 * hostio.cc (hostio_error)
903 (handle_setfs)
904 (handle_open)
905 (handle_unlink)
906 (handle_readlink)
907 * linux-aarch32-low.cc (arm_breakpoint_at)
908 * linux-aarch64-low.cc (aarch64_breakpoint_at)
909 * linux-arm-low.cc (arm_sigreturn_next_pc)
910 (arm_get_hwcap)
911 (arm_get_syscall_trapinfo)
912 * linux-cris-low.cc (cris_breakpoint_at)
913 * linux-crisv32-low.cc (cris_breakpoint_at)
914 * linux-low.cc (handle_extended_wait)
915 (linux_wait_1)
916 (linux_read_memory)
917 (linux_process_target::breakpoint_kind_from_pc)
918 (linux_get_auxv)
919 * linux-m32r-low.cc (m32r_breakpoint_at)
920 * linux-mips-low.cc (mips_breakpoint_at)
921 * linux-nios2-low.cc (nios2_breakpoint_at)
922 * linux-ppc-low.cc (ppc_breakpoint_at)
923 * linux-s390-low.cc (s390_get_hwcap)
924 * linux-sh-low.cc (sh_breakpoint_at)
925 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
926 (sparc_store_gregset_from_stack)
927 (sparc_breakpoint_at)
928 * linux-tic6x-low.cc (tic6x_breakpoint_at)
929 * linux-tile-low.cc (tile_breakpoint_at)
930 * linux-x86-low.cc (x86_breakpoint_at)
931 * linux-xtensa-low.cc (xtensa_breakpoint_at)
932 * mem-break.cc (bp_size)
933 (bp_opcode)
934 (insert_memory_breakpoint)
935 (set_raw_breakpoint_at)
936 (delete_raw_breakpoint)
937 (z_type_supported)
938 (uninsert_raw_breakpoint)
939 (reinsert_raw_breakpoint)
940 (validate_inserted_breakpoint)
941 * regcache.cc (regcache_read_pc)
942 (regcache_write_pc)
943 * remote-utils.cc (putpkt_binary_1)
944 (input_interrupt)
945 (getpkt)
946 (prepare_resume_reply)
947 * server.cc (handle_general_set)
948 (handle_detach)
949 (handle_qxfer_auxv)
950 (handle_qxfer_exec_file)
951 (handle_qxfer_libraries_svr4)
952 (handle_qxfer_osdata)
953 (handle_qxfer_siginfo)
954 (handle_qxfer_fdpic)
955 (handle_query)
956 (resume)
957 (handle_v_requests)
958 (queue_stop_reply_callback)
959 (captured_main)
960 * target.cc (prepare_to_access_memory)
961 (done_accessing_memory)
962 (read_inferior_memory)
963 (target_write_memory)
964 (target_stop_and_wait)
965 (target_wait)
966 (target_mourn_inferior)
967 (target_continue_no_signal)
968 (target_continue)
969 (target_supports_multi_process)
970 (kill_inferior)
971 * target.h
972 (target_create_inferior)
973 (target_post_create_inferior)
974 (myattach)
975 (target_supports_fork_events)
976 (target_supports_vfork_events)
977 (target_supports_exec_events)
978 (target_handle_new_gdb_connection)
979 (detach_inferior)
980 (mythread_alive)
981 (fetch_inferior_registers)
982 (store_inferior_registers)
983 (join_inferior)
984 (target_supports_non_stop)
985 (target_async)
986 (target_process_qsupported)
987 (target_supports_catch_syscall)
988 (target_get_ipa_tdesc_idx)
989 (target_supports_tracepoints)
990 (target_supports_fast_tracepoints)
991 (target_get_min_fast_tracepoint_insn_len)
992 (target_thread_stopped)
993 (target_pause_all)
994 (target_unpause_all)
995 (target_stabilize_threads)
996 (target_install_fast_tracepoint_jump_pad)
997 (target_emit_ops)
998 (target_supports_disable_randomization)
999 (target_supports_agent)
1000 (target_enable_btrace)
1001 (target_disable_btrace)
1002 (target_read_btrace)
1003 (target_read_btrace_conf)
1004 (target_supports_range_stepping)
1005 (target_supports_stopped_by_sw_breakpoint)
1006 (target_stopped_by_sw_breakpoint)
1007 (target_supports_stopped_by_hw_breakpoint)
1008 (target_supports_hardware_single_step)
1009 (target_stopped_by_hw_breakpoint)
1010 (target_breakpoint_kind_from_pc)
1011 (target_breakpoint_kind_from_current_state)
1012 (target_supports_software_single_step)
1013 (target_core_of_thread)
1014 (target_thread_name)
1015 (target_thread_handle)
1016 * win32-low.cc (do_initial_child_stuff)
1017
1018 Rename target op default definitions listed below.
1019
1020 * target.cc (process_target::post_create_inferior): Rename as ...
1021 (process_stratum_target::post_create_inferior): ... this.
1022 (process_target::prepare_to_access_memory): Rename as ...
1023 (process_stratum_target::prepare_to_access_memory): ... this.
1024 (process_target::done_accessing_memory): Rename as ...
1025 (process_stratum_target::done_accessing_memory): ... this.
1026 (process_target::look_up_symbols): Rename as ...
1027 (process_stratum_target::look_up_symbols): ... this.
1028 (process_target::supports_read_auxv): Rename as ...
1029 (process_stratum_target::supports_read_auxv): ... this.
1030 (process_target::read_auxv): Rename as ...
1031 (process_stratum_target::read_auxv): ... this.
1032 (process_target::supports_z_point_type): Rename as ...
1033 (process_stratum_target::supports_z_point_type): ... this.
1034 (process_target::insert_point): Rename as ...
1035 (process_stratum_target::insert_point): ... this.
1036 (process_target::remove_point): Rename as ...
1037 (process_stratum_target::remove_point): ... this.
1038 (process_target::stopped_by_sw_breakpoint): Rename as ...
1039 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
1040 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
1041 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
1042 (process_target::stopped_by_hw_breakpoint): Rename as ...
1043 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
1044 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
1045 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
1046 (process_target::supports_hardware_single_step): Rename as ...
1047 (process_stratum_target::supports_hardware_single_step): ... this.
1048 (process_target::stopped_by_watchpoint): Rename as ...
1049 (process_stratum_target::stopped_by_watchpoint): ... this.
1050 (process_target::stopped_data_address): Rename as ...
1051 (process_stratum_target::stopped_data_address): ... this.
1052 (process_target::supports_read_offsets): Rename as ...
1053 (process_stratum_target::supports_read_offsets): ... this.
1054 (process_target::read_offsets): Rename as ...
1055 (process_stratum_target::read_offsets): ... this.
1056 (process_target::supports_get_tls_address): Rename as ...
1057 (process_stratum_target::supports_get_tls_address): ... this.
1058 (process_target::get_tls_address): Rename as ...
1059 (process_stratum_target::get_tls_address): ... this.
1060 (process_target::hostio_last_error): Rename as ...
1061 (process_stratum_target::hostio_last_error): ... this.
1062 (process_target::supports_qxfer_osdata): Rename as ...
1063 (process_stratum_target::supports_qxfer_osdata): ... this.
1064 (process_target::qxfer_osdata): Rename as ...
1065 (process_stratum_target::qxfer_osdata): ... this.
1066 (process_target::supports_qxfer_siginfo): Rename as ...
1067 (process_stratum_target::supports_qxfer_siginfo): ... this.
1068 (process_target::qxfer_siginfo): Rename as ...
1069 (process_stratum_target::qxfer_siginfo): ... this.
1070 (process_target::supports_non_stop): Rename as ...
1071 (process_stratum_target::supports_non_stop): ... this.
1072 (process_target::async): Rename as ...
1073 (process_stratum_target::async): ... this.
1074 (process_target::start_non_stop): Rename as ...
1075 (process_stratum_target::start_non_stop): ... this.
1076 (process_target::supports_multi_process): Rename as ...
1077 (process_stratum_target::supports_multi_process): ... this.
1078 (process_target::supports_fork_events): Rename as ...
1079 (process_stratum_target::supports_fork_events): ... this.
1080 (process_target::supports_vfork_events): Rename as ...
1081 (process_stratum_target::supports_vfork_events): ... this.
1082 (process_target::supports_exec_events): Rename as ...
1083 (process_stratum_target::supports_exec_events): ... this.
1084 (process_target::handle_new_gdb_connection): Rename as ...
1085 (process_stratum_target::handle_new_gdb_connection): ... this.
1086 (process_target::handle_monitor_command): Rename as ...
1087 (process_stratum_target::handle_monitor_command): ... this.
1088 (process_target::core_of_thread): Rename as ...
1089 (process_stratum_target::core_of_thread): ... this.
1090 (process_target::supports_read_loadmap): Rename as ...
1091 (process_stratum_target::supports_read_loadmap): ... this.
1092 (process_target::read_loadmap): Rename as ...
1093 (process_stratum_target::read_loadmap): ... this.
1094 (process_target::process_qsupported): Rename as ...
1095 (process_stratum_target::process_qsupported): ... this.
1096 (process_target::supports_tracepoints): Rename as ...
1097 (process_stratum_target::supports_tracepoints): ... this.
1098 (process_target::read_pc): Rename as ...
1099 (process_stratum_target::read_pc): ... this.
1100 (process_target::write_pc): Rename as ...
1101 (process_stratum_target::write_pc): ... this.
1102 (process_target::supports_thread_stopped): Rename as ...
1103 (process_stratum_target::supports_thread_stopped): ... this.
1104 (process_target::thread_stopped): Rename as ...
1105 (process_stratum_target::thread_stopped): ... this.
1106 (process_target::supports_get_tib_address): Rename as ...
1107 (process_stratum_target::supports_get_tib_address): ... this.
1108 (process_target::get_tib_address): Rename as ...
1109 (process_stratum_target::get_tib_address): ... this.
1110 (process_target::pause_all): Rename as ...
1111 (process_stratum_target::pause_all): ... this.
1112 (process_target::unpause_all): Rename as ...
1113 (process_stratum_target::unpause_all): ... this.
1114 (process_target::stabilize_threads): Rename as ...
1115 (process_stratum_target::stabilize_threads): ... this.
1116 (process_target::supports_fast_tracepoints): Rename as ...
1117 (process_stratum_target::supports_fast_tracepoints): ... this.
1118 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
1119 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
1120 (process_target::emit_ops): Rename as ...
1121 (process_stratum_target::emit_ops): ... this.
1122 (process_target::supports_disable_randomization): Rename as ...
1123 (process_stratum_target::supports_disable_randomization): ... this.
1124 (process_target::supports_qxfer_libraries_svr4): Rename as ...
1125 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
1126 (process_target::qxfer_libraries_svr4): Rename as ...
1127 (process_stratum_target::qxfer_libraries_svr4): ... this.
1128 (process_target::supports_agent): Rename as ...
1129 (process_stratum_target::supports_agent): ... this.
1130 (process_target::enable_btrace): Rename as ...
1131 (process_stratum_target::enable_btrace): ... this.
1132 (process_target::disable_btrace): Rename as ...
1133 (process_stratum_target::disable_btrace): ... this.
1134 (process_target::read_btrace): Rename as ...
1135 (process_stratum_target::read_btrace): ... this.
1136 (process_target::read_btrace_conf): Rename as ...
1137 (process_stratum_target::read_btrace_conf): ... this.
1138 (process_target::supports_range_stepping): Rename as ...
1139 (process_stratum_target::supports_range_stepping): ... this.
1140 (process_target::supports_pid_to_exec_file): Rename as ...
1141 (process_stratum_target::supports_pid_to_exec_file): ... this.
1142 (process_target::pid_to_exec_file): Rename as ...
1143 (process_stratum_target::pid_to_exec_file): ... this.
1144 (process_target::supports_multifs): Rename as ...
1145 (process_stratum_target::supports_multifs): ... this.
1146 (process_target::multifs_open): Rename as ...
1147 (process_stratum_target::multifs_open): ... this.
1148 (process_target::multifs_unlink): Rename as ...
1149 (process_stratum_target::multifs_unlink): ... this.
1150 (process_target::multifs_readlink): Rename as ...
1151 (process_stratum_target::multifs_readlink): ... this.
1152 (process_target::breakpoint_kind_from_pc): Rename as ...
1153 (process_stratum_target::breakpoint_kind_from_pc): ... this.
1154 (process_target::breakpoint_kind_from_current_state): Rename as ...
1155 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
1156 (process_target::thread_name): Rename as ...
1157 (process_stratum_target::thread_name): ... this.
1158 (process_target::thread_handle): Rename as ...
1159 (process_stratum_target::thread_handle): ... this.
1160 (process_target::supports_software_single_step): Rename as ...
1161 (process_stratum_target::supports_software_single_step): ... this.
1162 (process_target::supports_catch_syscall): Rename as ...
1163 (process_stratum_target::supports_catch_syscall): ... this.
1164 (process_target::get_ipa_tdesc_idx): Rename as ...
1165 (process_stratum_target::get_ipa_tdesc_idx): ... this.
1166
478f9adf
PA
11672020-02-20 Pedro Alves <palves@redhat.com>
1168
1169 * target.cc (set_target_ops): Simply copy the given target pointer
1170 instead of creating a copy of the pointed object.
1171
d633e831
TBA
11722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1173
1174 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
1175 of process_target.
1176
1177 * target.h (struct process_stratum_target): Remove the target op.
1178 (class process_target): Add the target op.
1179 (target_get_ipa_tdesc_idx): Update the macro.
1180 * target.cc (process_target::get_ipa_tdesc_idx): Define.
1181
1182 Update the derived classes and callers below.
1183
1184 * linux-low.cc (linux_target_ops): Update.
1185 (linux_get_ipa_tdesc_idx): Turn into ...
1186 (linux_process_target::get_ipa_tdesc_idx): ... this.
1187 * linux-low.h (class linux_process_target): Update.
1188 * lynx-low.cc (lynx_target_ops): Update.
1189 * nto-low.cc (nto_target_ops): Update.
1190 * win32-low.cc (win32_target_ops): Update.
1191
bc8d3ae4
TBA
11922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1193
1194 Turn process_stratum_target's supports_catch_syscall op into a
1195 method of process_target.
1196
1197 * target.h (struct process_stratum_target): Remove the target op.
1198 (class process_target): Add the target op.
1199 (target_supports_catch_syscall): Update the macro.
1200 * target.cc (process_target::supports_catch_syscall): Define.
1201
1202 Update the derived classes and callers below.
1203
1204 * linux-low.cc (linux_target_ops): Update.
1205 (linux_supports_catch_syscall): Turn into ...
1206 (linux_process_target::supports_catch_syscall): ... this.
1207 * linux-low.h (class linux_process_target): Update.
1208 * lynx-low.cc (lynx_target_ops): Update.
1209 * nto-low.cc (nto_target_ops): Update.
1210 * win32-low.cc (win32_target_ops): Update.
1211
5303a34f
TBA
12122020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1213
1214 Turn process_stratum_target's supports_software_single_step op
1215 into a method of process_target.
1216
1217 * target.h (struct process_stratum_target): Remove the target op.
1218 (class process_target): Add the target op.
1219 (target_supports_software_single_step): Update the macro.
1220 * target.cc (process_target::supports_software_single_step): Define.
1221
1222 Update the derived classes and callers below.
1223
1224 * linux-low.cc (linux_target_ops): Update.
1225 (linux_supports_software_single_step): Turn into ...
1226 (linux_process_target::supports_software_single_step): ... this.
1227 * linux-low.h (class linux_process_target): Update.
1228 * lynx-low.cc (lynx_target_ops): Update.
1229 * nto-low.cc (nto_target_ops): Update.
1230 * win32-low.cc (win32_target_ops): Update.
1231
7f63b89b
TBA
12322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1233
1234 Turn process_stratum_target's thread_name and thread_handle ops
1235 into methods of process_target.
1236
1237 * target.h (struct process_stratum_target): Remove the target ops.
1238 (class process_target): Add the target ops.
1239 (target_thread_name): Update the macro.
1240 (target_thread_handle): Update the macro.
1241 * target.cc (process_target::thread_name): Define.
1242 (process_target::thread_handle): Define.
1243
1244 Update the derived classes and callers below.
1245
1246 * linux-low.cc (linux_target_ops): Update.
1247 (linux_process_target::thread_name): Define.
1248 (linux_process_target::thread_handle): Define.
1249 * linux-low.h (class linux_process_target): Update.
1250 * lynx-low.cc (lynx_target_ops): Update.
1251 * nto-low.cc (nto_target_ops): Update.
1252 * win32-low.cc (win32_target_ops): Update.
1253
d367006f
TBA
12542020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1255
1256 Turn process_stratum_target's breakpoint_kind_from_pc,
1257 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
1258 ops into methods of process_target.
1259
1260 * target.h (struct process_stratum_target): Remove the target op.
1261 (class process_target): Add the target op.
1262 (target_breakpoint_kind_from_pc): Update the macro.
1263 (target_breakpoint_kind_from_current_state): Update the macro.
1264 (default_breakpoint_kind_from_pc): Remove declaration.
1265 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
1266 (process_target::breakpoint_kind_from_pc): ... this.
1267 (process_target::breakpoint_kind_from_current_state): Define.
1268
1269 Update the derived classes and callers below.
1270
1271 * mem-break.cc (bp_size): Update.
1272 (bp_opcode): Update.
1273 * linux-low.cc (linux_target_ops): Update.
1274 (linux_wait_1): Update.
1275 (linux_breakpoint_kind_from_pc): Turn into ...
1276 (linux_process_target::breakpoint_kind_from_pc): ... this.
1277 (linux_sw_breakpoint_from_kind): Turn into ...
1278 (linux_process_target::sw_breakpoint_from_kind): ... this.
1279 (linux_breakpoint_kind_from_current_state): Turn into ...
1280 (linux_process_target::breakpoint_kind_from_current_state): ... this.
1281 * linux-low.h (class linux_process_target): Update.
1282 * lynx-low.cc (lynx_target_ops): Update.
1283 (lynx_process_target::sw_breakpoint_from_kind): Define.
1284 * lynx-low.h (class lynx_process_target): Update.
1285 * nto-low.cc (nto_target_ops): Update.
1286 (nto_sw_breakpoint_from_kind): Turn into ...
1287 (nto_process_target::sw_breakpoint_from_kind): ... this.
1288 * nto-low.h (class nto_process_target): Update.
1289 * win32-low.cc (win32_target_ops): Update.
1290 (win32_sw_breakpoint_from_kind): Turn into ...
1291 (win32_process_target::sw_breakpoint_from_kind): ... this.
1292 * win32-low.h (class win32_process_target): Update.
1293
c9b7b804
TBA
12942020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1295
1296 Turn process_stratum_target's multifs_open, multifs_readlink,
1297 multifs_unlink ops into methods of process_target.
1298
1299 * target.h (struct process_stratum_target): Remove the target ops.
1300 (class process_target): Add the target ops. Also add
1301 'supports_multifs'.
1302 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
1303 "sys/stat.h".
1304 (process_target::supports_multifs): Define.
1305 (process_target::multifs_open): Define.
1306 (process_target::multifs_readlink): Define.
1307 (process_target::multifs_unlink): Define.
1308
1309 Update the derived classes and callers below.
1310
1311 * hostio.cc (handle_setfs): Update.
1312 (handle_open): Update.
1313 (handle_unlink): Update.
1314 (handle_readlink): Update.
1315 * linux-low.cc (linux_target_ops): Update.
1316 (linux_process_target::supports_multifs): Define.
1317 (linux_process_target::multifs_open): Define.
1318 (linux_process_target::multifs_readlink): Define.
1319 (linux_process_target::multifs_unlink): Define.
1320 * linux-low.h (class linux_process_target): Update.
1321 * lynx-low.cc (lynx_target_ops): Update.
1322 * nto-low.cc (nto_target_ops): Update.
1323 * win32-low.cc (win32_target_ops): Update.
1324
8247b823
TBA
13252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1326
1327 Turn process_stratum_target's pid_to_exec_file op into a method
1328 of process_target.
1329
1330 * target.h (struct process_stratum_target): Remove the target op.
1331 (class process_target): Add the target op. Also add
1332 'supports_pid_to_exec_file'.
1333 * target.cc (process_target::pid_to_exec_file): Define.
1334 (process_target::supports_pid_to_exec_file): Define.
1335
1336 Update the derived classes and callers below.
1337
1338 * server.cc (handle_qxfer_exec_file): Update.
1339 (handle_query): Update.
1340 * linux-low.cc (linux_target_ops): Update.
1341 (linux_process_target::supports_pid_to_exec_file): Define.
1342 (linux_process_target::pid_to_exec_file): Define.
1343 * linux-low.h (class linux_process_target): Update.
1344 * lynx-low.cc (lynx_target_ops): Update.
1345 * nto-low.cc (nto_target_ops): Update.
1346 * win32-low.cc (win32_target_ops): Update.
1347
2526e0cd
TBA
13482020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1349
1350 Turn process_stratum_target's supports_range_stepping op into a
1351 method of process_target.
1352
1353 * target.h (struct process_stratum_target): Remove the target op.
1354 (class process_target): Add the target op.
1355 (target_supports_range_stepping): Update the macro.
1356 * target.cc (process_target::supports_range_stepping): Define.
1357
1358 Update the derived classes and callers below.
1359
1360 * linux-low.cc (linux_target_ops): Update.
1361 (linux_supports_range_stepping): Turn into ...
1362 (linux_process_target::supports_range_stepping): ... this.
1363 * linux-low.h (class linux_process_target): Update.
1364 * lynx-low.cc (lynx_target_ops): Update.
1365 * nto-low.cc (nto_target_ops): Update.
1366 * win32-low.cc (win32_target_ops): Update.
1367
79597bdd
TBA
13682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1369
1370 Turn process_stratum_target's btrace-related ops (enable_btrace,
1371 disable_btrace, read_btrace, read_btrace_conf) into methods of
1372 process_target.
1373
1374 * target.h (struct process_stratum_target): Remove the target ops.
1375 (class process_target): Add the target ops.
1376 (target_enable_btrace): Update.
1377 (target_disable_btrace): Update.
1378 (target_read_btrace): Update.
1379 (target_read_btrace_conf): Update.
1380 * target.cc (process_target::enable_btrace): Define.
1381 (process_target::disable_btrace): Define.
1382 (process_target::read_btrace): Define.
1383 (process_target::read_btrace_conf): Define.
1384
1385 Update the derived classes and callers below.
1386
1387 * linux-low.cc (linux_target_ops): Update.
1388 (linux_process_target:enable_btrace): Define as a wrapper around
1389 linux_enable_btrace.
1390 (linux_low_disable_btrace): Turn into ...
1391 (linux_process_target::disable_btrace): ... this.
1392 (linux_low_read_btrace): Turn into ...
1393 (linux_process_target::read_btrace): ... this.
1394 (linux_low_btrace_conf): Turn into ...
1395 (linux_process_target::read_btrace_conf): ... this.
1396 * linux-low.h (class linux_process_target): Update.
1397 * lynx-low.cc (lynx_target_ops): Update.
1398 * nto-low.cc (nto_target_ops): Update.
1399 * win32-low.cc (win32_target_ops): Update.
1400
c0245cb9
TBA
14012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1402
1403 Turn process_stratum_target's supports_agent op into a method of
1404 process_target.
1405
1406 * target.h (struct process_stratum_target): Remove the target op.
1407 (class process_target): Add the target op.
1408 (target_supports_agent): Update the macro.
1409 * target.cc (process_target::supports_agent): Define.
1410
1411 Update the derived classes and callers below.
1412
1413 * linux-low.cc (linux_target_ops): Update.
1414 (linux_supports_agent): Turn into ...
1415 (linux_process_target::supports_agent): ... this.
1416 * linux-low.h (class linux_process_target): Update.
1417 * lynx-low.cc (lynx_target_ops): Update.
1418 * nto-low.cc (nto_target_ops): Update.
1419 * win32-low.cc (win32_target_ops): Update.
1420
974387bb
TBA
14212020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1422
1423 Turn process_stratum_target's qxfer_libraries_svr4 op into a
1424 method of process_target.
1425
1426 * target.h (struct process_stratum_target): Remove the target op.
1427 (class process_target): Add the target op. Also add
1428 'supports_qxfer_libraries_svr4'.
1429 * target.cc (process_target::qxfer_libraries_svr4): Define.
1430 (process_target::supports_qxfer_libraries_svr4): Define.
1431
1432 Update the derived classes and callers below.
1433
1434 * server.cc (handle_qxfer_libraries_svr4): Update.
1435 (handle_query): Update.
1436 * linux-low.cc (linux_target_ops): Update.
1437 (linux_process_target::supports_qxfer_libraries_svr4): Define.
1438 (linux_qxfer_libraries_svr4): Turn into ...
1439 (linux_process_target::qxfer_libraries_svr4): ... this.
1440 * linux-low.h (class linux_process_target): Update.
1441 * lynx-low.cc (lynx_target_ops): Update.
1442 * nto-low.cc (nto_target_ops): Update.
1443 * win32-low.cc (win32_target_ops): Update.
1444
c756403b
TBA
14452020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1446
1447 Turn process_stratum_target's supports_disable_randomization op
1448 into a method of process_target.
1449
1450 * target.h (struct process_stratum_target): Remove the target op.
1451 (class process_target): Add the target op.
1452 (target_supports_disable_randomization): Update the macro.
1453 * target.cc (process_target::supports_disable_randomization): Define.
1454
1455 Update the derived classes and callers below.
1456
1457 * linux-low.cc (linux_target_ops): Update.
1458 (linux_supports_disable_randomization): Turn into ...
1459 (linux_process_target::supports_disable_randomization): ... this.
1460 * linux-low.h (class linux_process_target): Update.
1461 * lynx-low.cc (lynx_target_ops): Update.
1462 * nto-low.cc (nto_target_ops): Update.
1463 * win32-low.cc (win32_target_ops): Update.
1464
345dafad
TBA
14652020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1466
1467 Turn process_stratum_target's emit_ops op into a method of
1468 process_target.
1469
1470 * target.h (struct process_stratum_target): Remove the target op.
1471 (class process_target): Add the target op.
1472 (target_emit_ops): Update the macro.
1473 * target.cc (process_target::emit_ops): Define.
1474
1475 Update the derived classes and callers below.
1476
1477 * linux-low.cc (linux_target_ops): Update.
1478 (linux_emit_ops): Turn into ...
1479 (linux_process_target::emit_ops): ... this.
1480 * linux-low.h (class linux_process_target): Update.
1481 * lynx-low.cc (lynx_target_ops): Update.
1482 * nto-low.cc (nto_target_ops): Update.
1483 * win32-low.cc (win32_target_ops): Update.
1484
c23c9391
TBA
14852020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1486
1487 Turn process_stratum_target's install_fast_tracepoint_jump_pad
1488 and get_min_fast_tracepoint_insn_len ops into methods of
1489 process_target.
1490
1491 * target.h (struct process_stratum_target): Remove the target ops.
1492 (class process_target): Add the target ops. Also add
1493 'supports_fast_tracepoints'.
1494 (target_supports_fast_tracepoints): Update the macro.
1495 (target_get_min_fast_tracepoint_insn_len): Update the macro.
1496 (install_fast_tracepoint_jump_pad): Update and rename the macro
1497 to ...
1498 (target_install_fast_tracepoint_jump_pad): ... this.
1499 * target.cc (process_target::supports_fast_tracepoints): Define.
1500 (process_target::install_fast_tracepoint_jump_pad): Define.
1501 (process_target::get_min_fast_tracepoint_insn_len): Define.
1502
1503 Update the derived classes and callers below.
1504
1505 * tracepoint.cc (install_fast_tracepoint): Update.
1506 * linux-low.cc (linux_target_ops): Update.
1507 (linux_process_target::supports_fast_tracepoints): Define.
1508 (linux_install_fast_tracepoint_jump_pad): Turn into ...
1509 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
1510 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
1511 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
1512 * linux-low.h (class linux_process_target): Update.
1513 * lynx-low.cc (lynx_target_ops): Update.
1514 * nto-low.cc (nto_target_ops): Update.
1515 * win32-low.cc (win32_target_ops): Update.
1516
5c9eb2f2
TBA
15172020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1518
1519 Turn process_stratum_target's stabilize_threads op into a
1520 method of process_target.
1521
1522 * target.h (struct process_stratum_target): Remove the target op.
1523 (class process_target): Add the target op.
1524 (target_stabilize_threads): Update the macro.
1525 * target.cc (process_target::stabilize_threads): Define.
1526
1527 Update the derived classes and callers below.
1528
1529 * server.cc (handle_status): Update.
1530 * tracepoint.cc (cmd_qtdp): Update.
1531 (cmd_qtstart): Update.
1532 * linux-low.cc (linux_target_ops): Update.
1533 (linux_stabilize_threads): Turn into ...
1534 (linux_process_target::stabilize_threads): ... this.
1535 (linux_wait_1): Update.
1536 * linux-low.h (class linux_process_target): Update.
1537 * lynx-low.cc (lynx_target_ops): Update.
1538 * nto-low.cc (nto_target_ops): Update.
1539 * win32-low.cc (win32_target_ops): Update.
1540
29e8dc09
TBA
15412020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1542
1543 Turn process_stratum_target's pause_all and unpause_all ops
1544 into methods of process_target.
1545
1546 * target.h (struct process_stratum_target): Remove the target ops.
1547 (class process_target): Add the target ops.
1548 (pause_all): Update the macro and rename to...
1549 (target_pause_all): ... this.
1550 (unpause_all): Update the macro and rename to...
1551 (target_unpause_all): ... this.
1552 * target.cc (process_target::pause_all): Define.
1553 (process_target::unpause_all): Define.
1554
1555 Update the derived classes and callers below.
1556
1557 * server.cc (handle_status): Update.
1558 * tracepoint.cc (clear_installed_tracepoints): Update.
1559 (cmd_qtdp): Update.
1560 (cmd_qtstart): Update.
1561 (stop_tracing): Update.
1562 (cmd_qtstatus): Update.
1563 (upload_fast_traceframes): Update.
1564 (run_inferior_command): Update.
1565 * linux-low.cc (linux_target_ops): Update.
1566 (linux_pause_all): Turn into ...
1567 (linux_process_target::pause_all): ... this.
1568 (linux_unpause_all): Turn into ...
1569 (linux_process_target::unpause_all): ... this.
1570 (linux_process_target::prepare_to_access_memory): Update.
1571 (linux_process_target::done_accessing_memory): Update.
1572 * linux-low.h (class linux_process_target): Update.
1573 * lynx-low.cc (lynx_target_ops): Update.
1574 * nto-low.cc (nto_target_ops): Update.
1575 * win32-low.cc (win32_target_ops): Update.
1576
4e2e869c
TBA
15772020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1578
1579 Turn process_stratum_target's get_tib_address op into a method of
1580 process_target.
1581
1582 * target.h (struct process_stratum_target): Remove the target op.
1583 (class process_target): Add the target op. Also add
1584 'supports_get_tib_address'.
1585 * target.cc (process_target::get_tib_address): Define.
1586 (process_target::supports_get_tib_address): Define.
1587
1588 Update the derived classes and callers below.
1589
1590 * server.cc (handle_query): Update.
1591 * linux-low.cc (win32_target_ops): Update.
1592 * lynx-low.cc (lynx_target_ops): Update.
1593 * nto-low.cc (nto_target_ops): Update.
1594 * win32-low.cc (win32_target_ops): Update.
1595 (win32_process_target::supports_get_tib_address): Define.
1596 (win32_get_tib_address): Turn into ...
1597 (win32_process_target::get_tib_address): ... this.
1598 * win32-low.h (class win32_process_target): Update.
1599
68119632
TBA
16002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1601
1602 Turn process_stratum_target's thread_stopped op into a method of
1603 process_target.
1604
1605 * target.h (struct process_stratum_target): Remove the target op.
1606 (class process_target): Add the target op. Also add
1607 'supports_thread_stopped'.
1608 (target_thread_stopped): Update the macro.
1609 * target.cc (process_target::thread_stopped): Define.
1610 (process_target::supports_thread_stopped): Define.
1611 (prepare_to_access_memory): Update.
1612
1613 Update the derived classes and callers below.
1614
1615 * server.cc (queue_stop_reply_callback): Update.
1616 * linux-low.cc (linux_target_ops): Update.
1617 (linux_process_target::supports_thread_stopped): Define.
1618 (linux_thread_stopped): Turn into ...
1619 (linux_process_target::thread_stopped): ... this.
1620 * linux-low.h (class linux_process_target): Update.
1621 * lynx-low.cc (lynx_target_ops): Update.
1622 * nto-low.cc (nto_target_ops): Update.
1623 * win32-low.cc (win32_target_ops): Update.
1624
770d8f6a
TBA
16252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1626
1627 Turn process_stratum_target's read_pc and write_pc ops into
1628 methods of process_target.
1629
1630 * target.h (struct process_stratum_target): Remove the target ops.
1631 (class process_target): Add the target ops.
1632 * target.cc (process_target::read_pc): Define.
1633 (process_target::write_pc): Define.
1634
1635 Update the derived classes and callers below.
1636
1637 * regcache.cc (regcache_read_pc): Update.
1638 (regcache_write_pc): Update.
1639 * linux-low.cc (linux_target_ops): Update.
1640 (linux_read_pc): Turn into ...
1641 (linux_process_target::read_pc): ... this.
1642 (linux_write_pc): Turn into ...
1643 (linux_process_target::write_pc): ... this.
1644 * linux-low.h (class linux_process_target): Update.
1645 * lynx-low.cc (lynx_target_ops): Update.
1646 * nto-low.cc (nto_target_ops): Update.
1647 * win32-low.cc (win32_target_ops): Update.
1648
290732bf
TBA
16492020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1650
1651 Turn process_stratum_target's supports_tracepoints op into a
1652 method of process_target.
1653
1654 * target.h (struct process_stratum_target): Remove the target op.
1655 (class process_target): Add the target op.
1656 (target_supports_tracepoints): Update the macro.
1657 * target.cc (process_target::supports_tracepoints): Define.
1658
1659 Update the derived classes and callers below.
1660
1661 * linux-low.cc (linux_target_ops): Update.
1662 (linux_supports_tracepoints): Turn into ...
1663 (linux_process_target::supports_tracepoints): ... this.
1664 * linux-low.h (class linux_process_target): Update.
1665 * lynx-low.cc (lynx_target_ops): Update.
1666 * nto-low.cc (nto_target_ops): Update.
1667 * win32-low.cc (win32_target_ops): Update.
1668
0df28b1b
TBA
16692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1670
1671 Turn process_stratum_target's process_qsupported op into a method
1672 of process_target.
1673
1674 * target.h (struct process_stratum_target): Remove the target op.
1675 (class process_target): Add the target op.
1676 (target_process_qsupported): Update the macro.
1677 * target.cc (process_target::process_qsupported): Define.
1678
1679 Update the derived classes and callers below.
1680
1681 * linux-low.cc (linux_target_ops): Update.
1682 (linux_process_qsupported): Turn into ...
1683 (linux_process_target::process_qsupported): ... this.
1684 * linux-low.h (class linux_process_target): Update.
1685 * lynx-low.cc (lynx_target_ops): Update.
1686 * nto-low.cc (nto_target_ops): Update.
1687 * win32-low.cc (win32_target_ops): Update.
1688
9da41fda
TBA
16892020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1690
1691 Turn process_stratum_target's read_loadmap op into a method of
1692 process_target.
1693
1694 * target.h (struct process_stratum_target): Remove the target op.
1695 (class process_target): Add the target op. Also add
1696 'supports_read_loadmap'.
1697 * target.cc (process_target::read_loadmap): Define.
1698 (process_target::supports_read_loadmap): Define.
1699
1700 Update the derived classes and callers below.
1701
1702 * server.cc (handle_qxfer_fdpic): Update.
1703 (handle_query): Update.
1704 * linux-low.cc (linux_target_ops): Update.
1705 (linux_process_target::supports_read_loadmap): Define.
1706 (linux_read_loadmap): Turn into ...
1707 (linux_process_target::read_loadmap): ... this.
1708 * linux-low.h (class linux_process_target): Update.
1709 * lynx-low.cc (lynx_target_ops): Update.
1710 * nto-low.cc (nto_target_ops): Update.
1711 * win32-low.cc (win32_target_ops): Update.
1712
95a45fc1
TBA
17132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1714
1715 Turn process_stratum_target's core_of_thread op into a method of
1716 process_target.
1717
1718 * target.h (struct process_stratum_target): Remove the target op.
1719 (class process_target): Add the target op.
1720 (target_core_of_thread): Update the macro.
1721 * target.cc (process_target::core_of_thread): Define.
1722
1723 Update the derived classes and callers below.
1724
1725 * linux-low.cc (linux_target_ops): Update.
1726 (linux_process_target::core_of_thread): Define.
1727 * linux-low.h (class linux_process_target): Update.
1728 * lynx-low.cc (lynx_target_ops): Update.
1729 * nto-low.cc (nto_target_ops): Update.
1730 * win32-low.cc (win32_target_ops): Update.
1731
55cf3021
TBA
17322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1733
1734 Turn process_stratum_target's handle_monitor_command op into a
1735 method of process_target.
1736
1737 * target.h (struct process_stratum_target): Remove the target op.
1738 (class process_target): Add the target op.
1739 (target_handle_monitor_command): Update the macro.
1740 * target.cc (process_target::handle_monitor_command): Define.
1741
1742 Update the derived classes and callers below.
1743
1744 * server.cc (handle_query): Update.
1745 * linux-low.cc (linux_target_ops): Update.
1746 (linux_process_target::handle_monitor_command): Define.
1747 * linux-low.h (class linux_process_target): Update.
1748 * lynx-low.cc (lynx_target_ops): Update.
1749 * nto-low.cc (nto_target_ops): Update.
1750 * win32-low.cc (win32_target_ops): Update.
1751
fb00dfce
TBA
17522020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1753
1754 Turn process_stratum_target's handle_new_gdb_connection op into a
1755 method of process_target.
1756
1757 * target.h (struct process_stratum_target): Remove the target op.
1758 (class process_target): Add the target op.
1759 (target_handle_new_gdb_connection): Update the macro.
1760 * target.cc (process_target::handle_new_gdb_connection): Define.
1761
1762 Update the derived classes and callers below.
1763
1764 * linux-low.cc (linux_target_ops): Update.
1765 (linux_handle_new_gdb_connection): Turn into ...
1766 (linux_process_target::handle_new_gdb_connection): ... this.
1767 * linux-low.h (class linux_process_target): Update.
1768 * lynx-low.cc (lynx_target_ops): Update.
1769 * nto-low.cc (nto_target_ops): Update.
1770 * win32-low.cc (win32_target_ops): Update.
1771
9690a72a
TBA
17722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1773
1774 Turn process_stratum_target's supports_fork_events,
1775 supports_vfork_events, and supports_exec_events ops into methods
1776 of process_target.
1777
1778 * target.h (struct process_stratum_target): Remove the target ops.
1779 (class process_target): Add the target ops.
1780 (target_supports_fork_events): Update the macro.
1781 (target_supports_vfork_events): Update the macro.
1782 (target_supports_exec_events): Update the macro.
1783 * target.cc (process_target::supports_fork_events): Define.
1784 (process_target::supports_vfork_events): Define.
1785 (process_target::supports_exec_events): Define.
1786
1787 Update the derived classes and callers below.
1788
1789 * linux-low.cc (linux_target_ops): Update.
1790 (linux_supports_fork_events): Turn into ...
1791 (linux_process_target::supports_fork_events): ... this.
1792 (linux_supports_vfork_events): Turn into ...
1793 (linux_process_target::supports_vfork_events): ... this.
1794 (linux_supports_exec_events): Turn into ...
1795 (linux_process_target::supports_exec_events): ... this.
1796 * linux-low.h (class linux_process_target): Update.
1797 * lynx-low.cc (lynx_target_ops): Update.
1798 * nto-low.cc (nto_target_ops): Update.
1799 * win32-low.cc (win32_target_ops): Update.
1800
652aef77
TBA
18012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1802
1803 Turn process_stratum_target's supports_multi_process op into a
1804 method of process_target.
1805
1806 * target.h (struct process_stratum_target): Remove the target op.
1807 (class process_target): Add the target op.
1808 * target.cc (process_target::supports_multi_process): Define.
1809 (target_supports_multi_process): Update.
1810
1811 Update the derived classes and callers below.
1812
1813 * linux-low.cc (linux_target_ops): Update.
1814 (linux_supports_multi_process): Turn into ...
1815 (linux_process_target::supports_multi_process): ... this.
1816 * linux-low.h (class linux_process_target): Update.
1817 * lynx-low.cc (lynx_target_ops): Update.
1818 * nto-low.cc (nto_target_ops): Update.
1819 * win32-low.cc (win32_target_ops): Update.
1820
0dc587d4
TBA
18212020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1822
1823 Turn process_stratum_target's supports_non_stop, async, and
1824 start_non_stop ops into methods of process_target.
1825
1826 * target.h (struct process_stratum_target): Remove the target ops.
1827 (class process_target): Add the target ops.
1828 (target_supports_non_stop): Update the macro.
1829 (target_async): Update the macro.
1830 (start_non_stop): Remove declaration.
1831 * target.cc (process_target::supports_non_stop): Define.
1832 (process_target::async): Define.
1833 (process_target::start_non_stop): Define.
1834 (start_non_stop): Remove.
1835
1836 Update the derived classes and callers below.
1837
1838 * server.cc (handle_qxfer_siginfo): Update.
1839 (handle_query): Update.
1840 * linux-low.cc (linux_target_ops): Update.
1841 (linux_supports_non_stop): Turn into ...
1842 (linux_process_target::supports_non_stop): ... this.
1843 (linux_async): Turn into ...
1844 (linux_process_target::async): ... this.
1845 (linux_start_non_stop): Turn into ...
1846 (linux_process_target::start_non_stop): ... this.
1847 * linux-low.h (class linux_process_target): Update.
1848 * lynx-low.cc (lynx_target_ops): Update.
1849 * nto-low.cc (nto_target_ops): Update.
1850 (nto_supports_non_stop): Remove; rely on the default behavior
1851 instead.
1852 * win32-low.cc (win32_target_ops): Update.
1853
d7abedf7
TBA
18542020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1855
1856 Turn process_stratum_target's qxfer_siginfo op into a method of
1857 process_target.
1858
1859 * target.h (struct process_stratum_target): Remove the target op.
1860 (class process_target): Add the target op. Also add
1861 'supports_qxfer_siginfo'.
1862 * target.cc (process_target::qxfer_siginfo): Define.
1863 (process_target::supports_qxfer_siginfo): Define.
1864
1865 Update the derived classes and callers below.
1866
1867 * server.cc (handle_qxfer_siginfo): Update.
1868 (handle_query): Update.
1869 * linux-low.cc (linux_target_ops): Update.
1870 (linux_process_target::supports_qxfer_siginfo): Define.
1871 (linux_xfer_siginfo): Turn into ...
1872 (linux_process_target::qxfer_siginfo): ... this.
1873 * linux-low.h (class linux_process_target): Update.
1874 * lynx-low.cc (lynx_target_ops): Update.
1875 * nto-low.cc (nto_target_ops): Update.
1876 * win32-low.cc (win32_target_ops): Update.
1877
2d0795ee
TBA
18782020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1879
1880 Turn process_stratum_target's qxfer_osdata op into a method of
1881 process_target.
1882
1883 * target.h (struct process_stratum_target): Remove the target op.
1884 (class process_target): Add the target op. Also add
1885 'supports_qxfer_osdata'.
1886 * target.cc (process_target::qxfer_osdata): Define.
1887 (process_target::supports_qxfer_osdata): Define.
1888
1889 Update the derived classes and callers below.
1890
1891 * server.cc (handle_qxfer_osdata): Update.
1892 (handle_query): Update.
1893 * linux-low.cc (linux_target_ops): Update.
1894 (linux_process_target::supports_qxfer_osdata): Define.
1895 (linux_qxfer_osdata): Turn into ...
1896 (linux_process_target::qxfer_osdata): ... this.
1897 * linux-low.h (class linux_process_target): Update.
1898 * lynx-low.cc (lynx_target_ops): Update.
1899 * nto-low.cc (nto_target_ops): Update.
1900 * win32-low.cc (win32_target_ops): Update.
1901
ea06bbaa
TBA
19022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1903
1904 Turn process_stratum_target's hostio_last_error op into a
1905 method of process_target.
1906
1907 * target.h (struct process_stratum_target): Remove the target op.
1908 (class process_target): Add the target op.
1909 * target.cc: Add "hostio.h" to includes.
1910 (process_target::hostio_last_error): Define.
1911
1912 Update the derived classes and callers below.
1913
1914 * hostio.cc (hostio_error): Update.
1915 * linux-low.cc: Remove "hostio.h" from includes.
1916 (linux_target_ops): Update.
1917 * lynx-low.cc (lynx_target_ops): Update.
1918 * nto-low.cc (nto_target_ops): Update.
1919 * win32-low.h (class win32_process_target): Update.
1920 * win32-low.cc (win32_target_ops): Update.
1921 (wince_hostio_last_error): Turn into ...
1922 (win32_process_target::hostio_last_error): ... this.
1923
6e3fd7e9
TBA
19242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1925
1926 Turn process_stratum_target's get_tls_address op into a method of
1927 process_target.
1928
1929 * target.h (struct process_stratum_target): Remove the target op.
1930 (class process_target): Add the target op. Also add
1931 'supports_get_tls_address'.
1932 * target.cc (process_target::get_tls_address): Define.
1933 (process_target::supports_get_tls_address): Define.
1934
1935 Update the derived classes and callers below.
1936
1937 * server.cc (handle_query): Update.
1938 * linux-low.cc (linux_target_ops): Update.
1939 (linux_process_target::supports_get_tls_address): Define.
1940 (linux_process_target::get_tls_address): Define.
1941 * linux-low.h (class linux_process_target): Update.
1942 * lynx-low.cc (lynx_target_ops): Update.
1943 * nto-low.cc (nto_target_ops): Update.
1944 * win32-low.cc (win32_target_ops): Update.
1945
5203ae1e
TBA
19462020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1947
1948 Turn process_stratum_target's read_offsets op into a method of
1949 process_target.
1950
1951 * target.h (struct process_stratum_target): Remove the target op.
1952 (class process_target): Add the target op. Also add
1953 'supports_read_offsets'.
1954 * target.cc (process_target::read_offsets): Define.
1955 (process_target::supports_read_offsets): Define.
1956
1957 Update the derived classes and callers below.
1958
1959 * server.cc (handle_query): Update.
1960 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
1961 (linux_target_ops): Update.
1962 (linux_process_target::supports_read_offsets): Define.
1963 (linux_read_offsets): Turn into ...
1964 (linux_process_target::read_offsets): ... this.
1965 * linux-low.h (class linux_process_target): Update.
1966 * lynx-low.cc (lynx_target_ops): Update.
1967 * nto-low.cc (nto_target_ops): Update.
1968 * win32-low.cc (win32_target_ops): Update.
1969
6eeb5c55
TBA
19702020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1971
1972 Turn process_stratum_target's stopped_by_watchpoint and
1973 stopped_data_address ops into methods of process_target.
1974
1975 * target.h (struct process_stratum_target): Remove the target ops.
1976 (class process_target): Add the target ops.
1977 * target.cc (process_target::stopped_by_watchpoint): Define.
1978 (process_target::stopped_data_address): Define.
1979
1980 Update the derived classes and callers below.
1981
1982 * remote-utils.cc (prepare_resume_reply): Update.
1983 * linux-low.cc (linux_target_ops): Update.
1984 (linux_stopped_by_watchpoint): Turn into ...
1985 (linux_process_target::stopped_by_watchpoint): ... this.
1986 (linux_stopped_data_address): Turn into ...
1987 (linux_process_target::stopped_data_address): ... this.
1988 * linux-low.h (class linux_process_target): Update.
1989 * lynx-low.cc (lynx_target_ops): Update.
1990 * nto-low.cc (nto_target_ops): Update.
1991 (nto_stopped_by_watchpoint): Turn into ...
1992 (nto_process_target::stopped_by_watchpoint): ... this.
1993 (nto_stopped_data_address): Turn into ...
1994 (nto_process_target::stopped_data_address): ... this.
1995 * nto-low.h (class nto_process_target): Update.
1996 * win32-low.cc (win32_target_ops): Update.
1997 (win32_stopped_by_watchpoint): Turn into ...
1998 (win32_process_target::stopped_by_watchpoint): ... this.
1999 (win32_stopped_data_address): Turn into ...
2000 (win32_process_target::stopped_data_address): ... this.
2001 * win32-low.h (class win32_process_target): Update.
2002
22aa6223
TBA
20032020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2004
2005 Turn process_stratum_target's supports_hardware_single_step op into
2006 a method of process_target.
2007
2008 * target.h (struct process_stratum_target): Remove the target op.
2009 (class process_target): Add the target op.
2010 (target_supports_hardware_single_step): Update the macro.
2011 (target_can_do_hardware_single_step): Remove declaration.
2012 * target.cc (process_target::supports_hardware_single_step): Define.
2013 (target_can_do_hardware_single_step): Remove.
2014
2015 Update the derived classes and callers below.
2016
2017 * linux-low.h (class linux_process_target): Update.
2018 * linux-low.cc (linux_target_ops): Update.
2019 (linux_supports_hardware_single_step): Turn into ...
2020 (linux_process_target::supports_hardware_single_step): ... this.
2021 * lynx-low.h (class lynx_process_target): Update.
2022 * lynx-low.cc (lynx_target_ops): Update.
2023 (lynx_process_target::supports_hardware_single_step): Define.
2024 * nto-low.h (class nto_process_target): Update.
2025 * nto-low.cc (nto_target_ops): Update.
2026 (nto_process_target::supports_hardware_single_step): Define.
2027 * win32-low.h (class win32_process_target): Update.
2028 * win32-low.cc (win32_target_ops): Update.
2029 (win32_process_target::supports_hardware_single_step): Define.
2030
93fe88b2
TBA
20312020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2032
2033 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
2034 ops into methods of process_target.
2035
2036 * target.h (struct process_stratum_target): Remove the target ops.
2037 (class process_target): Add the target ops.
2038 (target_stopped_by_hw_breakpoint): Update the macro.
2039 (target_supports_stopped_by_hw_breakpoint): Update the macro.
2040 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
2041 (process_target::supports_stopped_by_hw_breakpoint): Define.
2042
2043 Update the derived classes and callers below.
2044
2045 * linux-low.cc (linux_target_ops): Update.
2046 (linux_stopped_by_hw_breakpoint): Turn into ...
2047 (linux_process_target::stopped_by_hw_breakpoint): ... this.
2048 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
2049 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
2050 * linux-low.h (class linux_process_target): Update.
2051 * lynx-low.cc (lynx_target_ops): Update.
2052 * nto-low.cc (nto_target_ops): Update.
2053 * win32-low.cc (win32_target_ops): Update.
2054
84320c4e
TBA
20552020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2056
2057 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
2058 ops into methods of process_target.
2059
2060 * target.h (struct process_stratum_target): Remove the target ops.
2061 (class process_target): Add the target ops.
2062 (target_stopped_by_sw_breakpoint): Update the macro.
2063 (target_supports_stopped_by_sw_breakpoint): Update the macro.
2064 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
2065 (process_target::supports_stopped_by_sw_breakpoint): Define.
2066
2067 Update the derived classes and callers below.
2068
2069 * linux-low.cc (linux_target_ops): Update.
2070 (linux_stopped_by_sw_breakpoint): Turn into ...
2071 (linux_process_target::stopped_by_sw_breakpoint): ... this.
2072 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
2073 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
2074 * linux-low.h (class linux_process_target): Update.
2075 * lynx-low.cc (lynx_target_ops): Update.
2076 * nto-low.cc (nto_target_ops): Update.
2077 * win32-low.cc (win32_target_ops): Update.
2078
7e0bde70
TBA
20792020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2080
2081 Turn process_stratum_target's insert_point and remove_point ops
2082 into methods of process_target.
2083
2084 * target.h (struct process_stratum_target): Remove the target ops.
2085 (class process_target): Add the target ops.
2086 * target.cc (process_target::insert_point): Define.
2087 (process_target::remove_point): Define.
2088
2089 Update the derived classes and callers below.
2090
2091 * mem-break.cc (set_raw_breakpoint_at): Update.
2092 (delete_raw_breakpoint): Update.
2093 (uninsert_raw_breakpoint): Update.
2094 (reinsert_raw_breakpoint): Update.
2095 * linux-low.cc (linux_target_ops): Update.
2096 (linux_insert_point): Turn into ...
2097 (linux_process_target::insert_point): ... this.
2098 (linux_remove_point): Turn into ...
2099 (linux_process_target::remove_point): ... this.
2100 * linux-low.h (class linux_process_target): Update.
2101 * lynx-low.cc (lynx_target_ops): Update.
2102 * nto-low.cc (nto_target_ops): Update.
2103 (nto_insert_point): Turn into ...
2104 (nto_process_target::insert_point): ... this.
2105 (nto_remove_point): Turn into ...
2106 (nto_process_target::remove_point): ... this.
2107 * nto-low.h (class nto_process_target): Update.
2108 * win32-low.cc (win32_target_ops): Update.
2109 (win32_insert_point): Turn into ...
2110 (win32_process_target::insert_point): ... this.
2111 (win32_remove_point): Turn into ...
2112 (win32_process_target::remove_point): ... this.
2113 * win32-low.h (class win32_process_target): Update.
2114
a2b2297a
TBA
21152020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2116
2117 Turn process_stratum_target's supports_z_point_type op into a
2118 method of process_target.
2119
2120 * target.h (struct process_stratum_target): Remove the target op.
2121 (class process_target): Add the target op.
2122 * target.cc (process_target::supports_z_point_type): Define.
2123
2124 Update the derived classes and callers below.
2125
2126 * mem-break.cc (z_type_supported): Update.
2127 * linux-low.cc (linux_target_ops): Update.
2128 (linux_supports_z_point_type): Turn into ...
2129 (linux_process_target::supports_z_point_type): ... this.
2130 * linux-low.h (class linux_process_target): Update.
2131 * lynx-low.cc (lynx_target_ops): Update.
2132 * nto-low.cc (nto_target_ops): Update.
2133 (nto_supports_z_point_type): Turn into ...
2134 (nto_process_target::supports_z_point_type): ... this.
2135 * nto-low.h (class nto_process_target): Update.
2136 * win32-low.cc (win32_target_ops): Update.
2137 (win32_supports_z_point_type): Turn into ...
2138 (win32_process_target::supports_z_point_type): ... this.
2139 * win32-low.h (class win32_process_target): Update.
2140
eac215cc
TBA
21412020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2142
2143 Turn process_stratum_target's read_auxv op into a method of
2144 process_target.
2145
2146 * target.h (class process_stratum_target): Remove the target op.
2147 (struct process_target): Add the target op. Also add
2148 'supports_read_auxv'.
2149 * target.cc (process_target::read_auxv): Define.
2150 (process_target::supports_read_auxv): Define.
2151
2152 Update the derived classes and callers below.
2153
2154 * server.cc (handle_qxfer_auxv): Update.
2155 (handle_query): Update.
2156 * linux-low.cc (linux_target_ops): Update.
2157 (linux_process_target::supports_read_auxv): Define.
2158 (linux_read_auxv): Turn into ...
2159 (linux_process_target::read_auxv): ... this.
2160 * linux-low.h (class linux_process_target): Update.
2161 * lynx-low.cc (lynx_target_ops): Update.
2162 * nto-low.cc (nto_target_ops): Update.
2163 (nto_process_target::supports_read_auxv): Define.
2164 (nto_read_auxv): Turn into ...
2165 (nto_process_target::read_auxv): ... this.
2166 * nto-low.h (class nto_process_target): Update.
2167 * win32-low.cc (win32_target_ops): Update.
2168
eb497a2a
TBA
21692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2170
2171 Turn process_stratum_target's request_interrupt op into a method of
2172 process_target.
2173
2174 * target.h (struct process_stratum_target): Remove the target op.
2175 (class process_target): Add the target op.
2176
2177 Update the derived classes and callers below.
2178
2179 * remote-utils.cc (putpkt_binary_1): Update.
2180 (input_interrupt): Update.
2181 (getpkt): Update.
2182 * server.cc (handle_v_requests): Update.
2183 * linux-low.cc (linux_target_ops): Update.
2184 (linux_request_interrupt): Turn into ...
2185 (linux_process_target::request_interrupt): ... this.
2186 * linux-low.h (class linux_process_target): Update.
2187 * lynx-low.cc (lynx_target_ops): Update.
2188 (lynx_request_interrupt): Turn into ...
2189 (lynx_process_target::request_interrupt): ... this.
2190 * lynx-low.h (class lynx_process_target): Update.
2191 * nto-low.cc (nto_target_ops): Update.
2192 (nto_request_interrupt): Turn into ...
2193 (nto_process_target::request_interrupt): ... this.
2194 * nto-low.h (class nto_process_target): Update.
2195 * win32-low.cc (win32_target_ops): Update.
2196 (win32_request_interrupt): Turn into ...
2197 (win32_process_target::request_interrupt): ... this.
2198 * win32-low.h (class win32_process_target): Update.
2199
2a31c7aa
TBA
22002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2201
2202 Turn process_stratum_target's look_up_symbols op into a method of
2203 process_target.
2204
2205 * target.h (struct process_stratum_target): Remove the target op.
2206 (class process_target): Add the target op.
2207 * target.cc (process_target::look_up_symbols): Define.
2208
2209 Update the derived classes and callers below.
2210
2211 * server.cc (handle_query): Update.
2212 * linux-low.cc (linux_target_ops): Update.
2213 (linux_look_up_symbols): Turn into ...
2214 (linux_process_target::look_up_symbols): ... this.
2215 * linux-low.h (class linux_process_target): Update.
2216 * lynx-low.cc (lynx_target_ops): Update.
2217 * nto-low.cc (nto_target_ops): Update.
2218 * win32-low.cc (win32_target_ops): Update.
2219
e2558df3
TBA
22202020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2221
2222 Turn process_stratum_target's read_memory and write_memory
2223 ops into methods of process_target.
2224
2225 * target.h (struct process_stratum_target): Remove the target ops.
2226 (class process_target): Add the target ops.
2227
2228 Update the derived classes and callers below.
2229
2230 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
2231 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
2232 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
2233 (arm_get_syscall_trapinfo): Update.
2234 * linux-cris-low.cc (cris_breakpoint_at): Update.
2235 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
2236 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
2237 * linux-mips-low.cc (mips_breakpoint_at): Update.
2238 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
2239 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
2240 * linux-sh-low.cc (sh_breakpoint_at): Update.
2241 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
2242 (sparc_store_gregset_from_stack): Update.
2243 (sparc_breakpoint_at): Update.
2244 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
2245 * linux-tile-low.cc (tile_breakpoint_at): Update.
2246 * linux-x86-low.cc (x86_breakpoint_at): Update.
2247 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
2248 * mem-brea.cc (insert_memory_breakpoint): Update.
2249 (validate_inserted_breakpoint): Update.
2250 * target.cc (read_inferior_memory): Update.
2251 (target_write_memory): Update.
2252 * linux-low.cc (linux_target_ops): Update.
2253 (linux_read_memory): Make a wrapper around the read_memory target
2254 op call.
2255 (linux_process_target::read_memory): Rename from linux_read_memory.
2256 (linux_write_memory): Turn into ...
2257 (linux_process_target::write_memory): ... this.
2258 * linux-low.h (class linux_process_target): Update.
2259 * lynx-low.cc (lynx_target_ops): Update.
2260 (lynx_read_memory): Turn into ...
2261 (lynx_process_target::read_memory): ... this.
2262 (lynx_write_memory): Turn into ...
2263 (lynx_process_target::write_memory): ... this.
2264 * lynx-low.h (class lynx_process_target): Update.
2265 * nto-low.cc (nto_target_ops): Update.
2266 (nto_read_memory): Turn into ...
2267 (nto_process_target::read_memory): ... this.
2268 (nto_write_memory): Turn into ...
2269 (nto_process_target::write_memory): ... this.
2270 * nto-low.h (class nto_process_target): Update.
2271 * win32-low.cc (win32_target_ops): Update.
2272 (win32_read_inferior_memory): Turn into ...
2273 (win32_process_target::read_memory): ... this.
2274 (win32_write_inferior_memory): Turn into ...
2275 (win32_process_target::write_memory): ... this.
2276 * win32-low.h (class win32_process_target): Update.
2277
79b44087
TBA
22782020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2279
2280 Turn process_stratum_target's prepare_to_access_memory and
2281 done_accessing_memory ops into methods of process_target.
2282
2283 * target.h (struct process_stratum_target): Remove the target ops.
2284 (class process_target): Add the target ops.
2285 * target.cc (process_target::prepare_to_access_memory): Define.
2286 (process_target::done_accessing_memory): Define.
2287 (prepare_to_access_memory): Update.
2288 (done_accessing_memory): Update.
2289
2290 Update the derived classes and callers below.
2291
2292 * linux-low.cc (linux_target_ops): Update.
2293 (linux_prepare_to_access_memory): Turn into ...
2294 (linux_process_target::prepare_to_access_memory): ... this.
2295 (linux_done_accessing_memory): Turn into ...
2296 (linux_process_target::done_accessing_memory): ... this.
2297 * linux-low.h (class linux_process_target): Update.
2298 * lynx-low.cc (lynx_target_ops): Update.
2299 * nto-low.cc (nto_target_ops): Update.
2300 * win32-low.cc (win32_target_ops): Update.
2301
a5a4d4cd
TBA
23022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2303
2304 Turn process_stratum_target's fetch_registers and store_registers
2305 ops into methods of process_target.
2306
2307 * target.h (struct process_stratum_target): Remove the target ops.
2308 (class process_target): Add the target ops.
2309 (fetch_inferior_registers): Update the macro.
2310 (store_inferior_registers): Update the macro.
2311
2312 Update the derived classes and callers below.
2313
2314 * linux-low.cc (linux_target_ops): Update.
2315 (linux_fetch_registers): Turn into ...
2316 (linux_process_target::fetch_registers): ... this.
2317 (linux_store_registers): Turn into ...
2318 (linux_process_target::store_registers): ... this.
2319 * linux-low.h (class linux_process_target): Update.
2320 * lynx-low.cc (lynx_target_ops): Update.
2321 (lynx_fetch_registers): Turn into ...
2322 (lynx_process_target::fetch_registers): ... this.
2323 (lynx_store_registers): Turn into ...
2324 (lynx_process_target::store_registers): ... this.
2325 * lynx-low.h (class lynx_process_target): Update.
2326 * nto-low.cc (nto_target_ops): Update.
2327 (nto_fetch_registers): Turn into ...
2328 (nto_process_target::fetch_registers): ... this.
2329 (nto_store_registers): Turn into ...
2330 (nto_process_target::store_registers): ... this.
2331 * nto-low.h (class nto_process_target): Update.
2332 * win32-low.cc (win32_target_ops): Update.
2333 (win32_fetch_inferior_registers): Turn into ...
2334 (win32_process_target::fetch_registers): ... this.
2335 (win32_store_inferior_registers): Turn into ...
2336 (win32_process_target::store_registers): ... this.
2337 * win32-low.h (class win32_process_target): Update.
2338
6532e7e3
TBA
23392020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2340
2341 Turn process_stratum_target's wait op into a method of
2342 process_target.
2343
2344 * target.h (struct process_stratum_target): Remove the target op.
2345 (class process_target): Add the target op.
2346
2347 Update the derived classes and callers below.
2348
2349 * target.cc (target_wait): Update.
2350 * linux-low.cc (linux_target_ops): Update.
2351 (linux_wait): Turn into ...
2352 (linux_process_target::wait): ... this.
2353 * linux-low.h (class linux_process_target): Update.
2354 * lynx-low.cc (lynx_target_ops): Update.
2355 (lynx_wait): Turn into ...
2356 (lynx_process_target::wait): ... this.
2357 * lynx-low.h (class lynx_process_target): Update.
2358 * nto-low.cc (nto_target_ops): Update.
2359 (nto_wait): Turn into ...
2360 (nto_process_target::wait): ... this.
2361 * nto-low.h (class nto_process_target): Update.
2362 * win32-low.cc (win32_target_ops): Update.
2363 (win32_wait): Turn into ...
2364 (win32_process_target::wait): ... this.
2365 (do_initial_child_stuff): Update.
2366 * win32-low.h (class win32_process_target): Update.
2367
0e4d7e35
TBA
23682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2369
2370 Turn process_stratum_target's resume op into a method of
2371 process_target.
2372
2373 * target.h (struct process_stratum_target): Remove the target op.
2374 (class process_target): Add the target op.
2375
2376 Update the derived classes and callers below.
2377
2378 * server.cc (resume): Update.
2379 * target.cc (target_stop_and_wait): Update.
2380 (target_continue_no_signal): Update.
2381 (target_continue): Update.
2382 * linux-low.cc (linux_target_ops): Update.
2383 (linux_resume): Turn into ...
2384 (linux_process_target::resume): ... this.
2385 * linux-low.h (class linux_process_target): Update.
2386 * lynx-low.cc (lynx_target_ops): Update.
2387 (lynx_resume): Turn into ...
2388 (lynx_process_target::resume): ... this.
2389 * lynx-low.h (class lynx_process_target): Update.
2390 * nto-low.cc (nto_target_ops): Update.
2391 (nto_resume): Turn into ...
2392 (nto_process_target::resume): ... this.
2393 * nto-low.h (class nto_process_target): Update.
2394 * win32-low.cc (win32_target_ops): Update.
2395 (win32_resume): Turn into ...
2396 (win32_process_target::resume): ... this.
2397 (win32_process_target::detach): Update.
2398 (do_initial_child_stuff): Update.
2399 * win32-low.h (class win32_process_target): Update.
2400
13d3d99b
TBA
24012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2402
2403 Turn process_stratum_target's thread_alive op into a method of
2404 process_target.
2405
2406 * target.h (struct process_stratum_target): Remove the target op.
2407 (class process_target): Add the target op.
2408 (mythread_alive): Update the macro.
2409
2410 Update the derived classes and callers below.
2411
2412 * linux-low.cc (linux_target_ops): Update.
2413 (linux_thread_alive): Turn into ...
2414 (linux_process_target::thread_alive): ... this.
2415 (wait_for_sigstop): Update.
2416 * linux-low.h (class linux_process_target): Update.
2417 * lynx-low.cc (lynx_target_ops): Update.
2418 (lynx_thread_alive): Turn into ...
2419 (lynx_process_target::thread_alive): ... this.
2420 * lynx-low.h (class lynx_process_target): Update.
2421 * nto-low.cc (nto_target_ops): Update.
2422 (nto_thread_alive): Turn into ...
2423 (nto_process_target::thread_alive): ... this.
2424 * nto-low.h (class nto_process_target): Update.
2425 * win32-low.cc (win32_target_ops): Update.
2426 (win32_thread_alive): Turn into ...
2427 (win32_process_target::thread_alive): ... this.
2428 * win32-low.h (class win32_process_target): Update.
2429
95a49a39
TBA
24302020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2431
2432 Turn process_stratum_target's join op into a method of
2433 process_target.
2434
2435 * target.h (struct process_stratum_target): Remove the target op.
2436 (class process_target): Add the target op.
2437 (join_inferior): Update the macro.
2438
2439 Update the derived classes and callers below.
2440
2441 * linux-low.cc (linux_target_ops): Update.
2442 (linux_join): Turn into ...
2443 (linux_process_target::join): ... this.
2444 * linux-low.h (class linux_process_target): Update.
2445 * lynx-low.cc (lynx_target_ops): Update.
2446 (lynx_join): Turn into ...
2447 (lynx_process_target::join): ... this.
2448 * lynx-low.h (class lynx_process_target): Update.
2449 * nto-low.cc (nto_target_ops): Update.
2450 (nto_process_target::join): Define.
2451 * nto-low.h (class nto_process_target): Update.
2452 * win32-low.cc (win32_target_ops): Update.
2453 (win32_join): Turn into ...
2454 (win32_process_target::join): ... this.
2455 * win32-low.h (class win32_process_target): Update.
2456
8adb37b9
TBA
24572020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2458
2459 Turn process_stratum_target's mourn op into a method of
2460 process_target.
2461
2462 * target.h (struct process_stratum_target): Remove the target op.
2463 (class process_target): Add the target op.
2464
2465 Update the derived classes and callers below.
2466
2467 * target.cc (target_mourn_inferior): Update.
2468 * linux-low.cc (linux_target_ops): Update.
2469 (linux_mourn): Turn into ...
2470 (linux_process_target::mourn): ... this.
2471 (handle_extended_wait): Update.
2472 (linux_process_target::kill): Update.
2473 (linux_process_target::detach): Update.
2474 * linux-low.h (class linux_process_target): Update.
2475 * lynx-low.cc (lynx_target_ops): Update.
2476 (lynx_mourn): Turn into ...
2477 (lynx_process_target::mourn): ... this.
2478 * lynx-low.h (class lynx_process_target): Update.
2479 * nto-low.cc (nto_target_ops): Update.
2480 (nto_mourn): Turn into ...
2481 (nto_process_target::mourn): ... this.
2482 * nto-low.h (class nto_process_target): Update.
2483 * win32-low.cc (win32_target_ops): Update.
2484 (win32_mourn): Turn into ...
2485 (win32_process_target::mourn): ... this.
2486 * win32-low.h (class win32_process_target): Update.
2487
9061c9cf
TBA
24882020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2489
2490 Turn process_stratum_target's detach op into a method of
2491 process_target.
2492
2493 * target.h (struct process_stratum_target): Remove the target op.
2494 (class process_target): Add the target op.
2495 (detach_inferior): Update the macro.
2496
2497 Update the derived classes and callers below.
2498
2499 * linux-low.cc (linux_target_ops): Update.
2500 (linux_detach): Turn into ...
2501 (linux_process_target::detach): ... this.
2502 * linux-low.h (class linux_process_target): Update.
2503 * lynx-low.cc (lynx_target_ops): Update.
2504 (lynx_detach): Turn into ...
2505 (lynx_process_target::detach): ... this.
2506 * lynx-low.h (class lynx_process_target): Update.
2507 * nto-low.cc (nto_target_ops): Update.
2508 (nto_detach): Turn into ...
2509 (nto_process_target::detach): ... this.
2510 * nto-low.h (class nto_process_target): Update.
2511 * win32-low.cc (win32_target_ops): Update.
2512 (win32_detach): Turn into ...
2513 (win32_process_target::detach): ... this.
2514 * win32-low.h (class win32_process_target): Update.
2515
c6885a57
TBA
25162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2517
2518 Turn process_stratum_target's kill op into a method of
2519 process_target.
2520
2521 * target.h (struct process_stratum_target): Remove the target op.
2522 (class process_target): Add the target op.
2523
2524 Update the derived classes and callers below.
2525
2526 * target.cc (kill_inferior): Update.
2527 * linux-low.cc (linux_target_ops): Update.
2528 (linux_kill): Turn into ...
2529 (linux_process_target::kill): ... this.
2530 * linux-low.h (class linux_process_target): Update.
2531 * lynx-low.cc (lynx_target_ops): Update.
2532 (lynx_kill): Turn into ...
2533 (lynx_process_target::kill): ... this.
2534 * lynx-low.h (class lynx_process_target): Update.
2535 * nto-low.cc (nto_target_ops): Update.
2536 (nto_kill): Turn into ...
2537 (nto_process_target::kill): ... this.
2538 * nto-low.h (class nto_process_target): Update.
2539 * win32-low.cc (win32_target_ops): Update.
2540 (win32_kill): Turn into ...
2541 (win32_process_target::kill): ... this.
2542 * win32-low.h (class win32_process_target): Update.
2543
ef03dad8
TBA
25442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2545
2546 Turn process_stratum_target's attach op into a method of
2547 process_target.
2548
2549 * target.h (struct process_stratum_target): Remove the target op.
2550 (class process_target): Add the target op.
2551 (myattach): Update the macro.
2552
2553 Update the derived classes and callers below.
2554
2555 * linux-low.cc (linux_target_ops): Update.
2556 (linux_attach): Turn into ...
2557 (linux_process_target::attach): ... this.
2558 * linux-low.h (class linux_process_target): Update.
2559 * lynx-low.cc (lynx_target_ops): Update.
2560 (lynx_attach): Turn into ...
2561 (lynx_process_target::attach): ... this.
2562 * lynx-low.h (class lynx_process_target): Update.
2563 * nto-low.cc (nto_target_ops): Update.
2564 (nto_attach): Turn into ...
2565 (nto_process_target::attach): ... this.
2566 * nto-low.h (class nto_process_target): Update.
2567 * win32-low.cc (win32_target_ops): Update.
2568 (win32_attach): Turn into ...
2569 (win32_process_target::attach): ... this.
2570 * win32-low.h (class win32_process_target): Update.
2571
6dee9afb
TBA
25722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2573
2574 Turn process_stratum_target's post_create_inferior op into a method
2575 of process_target.
2576
2577 * target.h (struct process_stratum_target): Remove the target op.
2578 (class process_target): Add the target op.
2579 (target_post_create_inferior): Update the macro.
2580 * target.cc (process_target::post_create_inferior): Define.
2581
2582 Update the derived classes and callers below.
2583
2584 * linux-low.cc (linux_target_ops): Update.
2585 (linux_post_create_inferior): Turn into ...
2586 (linux_process_target::post_create_inferior): ... this.
2587 * linux-low.h (class linux_process_target): Update.
2588 * lynx-low.cc (lynx_target_ops): Update.
2589 * nto-low.cc (nto_target_ops): Update.
2590 * win32-low.cc (win32_target_ops): Update.
2591
15295543
TBA
25922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2593
2594 Turn process_stratum_target's create_inferior op into a method of
2595 process_target.
2596
2597 * target.h (struct process_stratum_target): Remove the target op.
2598 (class process_target): Add the target op.
2599 (create_inferior): Rename the macro to ...
2600 (target_create_inferior): ... this.
2601
2602 Update the derived classes and callers below.
2603
2604 * server.cc (handle_v_run): Update.
2605 (captured_main): Update.
2606 (process_serial_event): Update.
2607 * linux-low.cc (linux_target_ops): Update.
2608 (linux_create_inferior): Turn into ...
2609 (linux_process_target::create_inferior): ... this.
2610 * linux-low.h (class linux_process_target): Update.
2611 * lynx-low.cc (lynx_target_ops): Update.
2612 (lynx_create_inferior): Turn into ...
2613 (lynx_process_target::create_inferior): ... this.
2614 * lynx-low.h (class lynx_process_target): Update.
2615 * nto-low.cc (nto_target_ops): Update.
2616 (nto_create_inferior): Turn into ...
2617 (nto_process_target::create_inferior): ... this.
2618 * nto-low.h (class nto_process_target): Update.
2619 * win32-low.cc (win32_target_ops): Update.
2620 (win32_create_inferior): Turn into ...
2621 (win32_process_target::create_inferior): ... this.
2622 * win32-low.h (class win32_process_target): Update.
2623
5ef9273d
TBA
26242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2625
2626 * target.h (class process_target): New class definition.
2627 (struct process_stratum_target) <pt>: New field with type
2628 'process_target*'.
2629 * linux-low.h (class linux_process_target): Define as a derived
2630 class of 'process_target'.
2631 * linux-low.cc (linux_target_ops): Add a linux_process_target*
2632 as the 'pt' field.
2633 * lynx-low.h (class lynx_process_target): Define as a derived
2634 class of 'process_target'.
2635 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
2636 as the 'pt' field.
2637 * nto-low.h (class nto_process_target): Define as a derived
2638 class of 'process_target'.
2639 * nto-low.cc (nto_target_ops): Add an nto_process_target*
2640 as the 'pt' field.
2641 * win32-low.h (class win32_process_target): Define as a derived
2642 class of 'process_target'.
2643 * win32-low.cc (win32_target_ops): Add a win32_process_target*
2644 as the 'pt' field.
2645
9f1528a1
AB
26462020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
2647
2648 * configure: Regenerate.
2649
bf84f706
MR
26502020-02-19 Maciej W. Rozycki <macro@wdc.com>
2651 Andrew Burgess <andrew.burgess@embecosm.com>
2652
2653 * linux-riscv-low.cc: New file.
2654 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
2655 and nat/riscv-linux-tdesc.c.
2656 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
2657 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
2658 Define.
2659
1a627e7e
TT
26602020-02-14 Tom Tromey <tom@tromey.com>
2661
2662 * acinclude.m4: Don't include acx_configure_dir.m4.
2663 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
2664 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
2665 (all, install-only, uninstall, clean-info, clean)
2666 (maintainer-clean): Don't recurse.
2667 (subdir_do, all-lib): Remove.
2668 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
2669 (GNULIB_H): Remove.
2670 (generated_files): Update.
2671 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
2672 * configure: Rebuild.
2673 * configure.ac: Don't configure gnulib or libiberty.
2674 (GNULIB): Update.
2675
a9b34532
EZ
26762020-02-14 Eli Zaretskii <eliz@gnu.org>
2677
2678 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
2679 preparing the command line for CreateProcess.
2680 (win32_create_inferior): Reflect the program name in debugging
2681 output that shows the process and its command line.
2682
feacfcac
SM
26832020-02-13 Simon Marchi <simon.marchi@efficios.com>
2684
2685 * Makefile.in: Rename source files from .c to .cc.
2686 * %.c: Rename to %.cc.
2687 * configure.ac: Rename server.c to server.cc.
2688 * configure: Re-generate.
2689
06b3c5bd
SM
26902020-02-13 Simon Marchi <simon.marchi@efficios.com>
2691
2692 * Makefile.in: Rename gdbsupport source files from .c to .cc.
2693
052793ad
HD
26942020-02-12 Hannes Domani <ssbssa@yahoo.de>
2695
2696 * win32-low.c (win32_create_inferior): Set signal_pid.
2697
f20e3e82
MR
26982020-02-12 Maciej W. Rozycki <macro@wdc.com>
2699 Pedro Alves <palves@redhat.com>
2700
2701 Skip building gdbserver in a cross-configuration.
2702 * configure.srv: Set $gdbserver_host depending on whether $target
2703 is $host. Use $gdbserver_host instead of $host.
2704
8ddd8e0e
SM
27052020-02-11 Simon Marchi <simon.marchi@efficios.com>
2706
2707 * configure: Re-generate.
2708
898e7f60
SM
27092020-02-11 Simon Marchi <simon.marchi@efficios.com>
2710
2711 * configure: Re-generate.
2712
58df732b
SM
27132020-02-11 Simon Marchi <simon.marchi@efficios.com>
2714
2715 * acinclude.m4: Update warning.m4 path.
2716
7928d571
HD
27172020-02-09 Hannes Domani <ssbssa@yahoo.de>
2718
2719 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
2720 (handle_exception): Set siginfo_er.
2721 (win32_xfer_siginfo): New function.
2722
919adfe8
TT
27232020-02-07 Tom Tromey <tom@tromey.com>
2724 Pedro Alves <palves@redhat.com>
2725
2726 * README: Update build documentation.
2727 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
2728 host, not target.
2729 * configure.ac: Update paths.
2730 * configure: Rebuild.
2731 * acinclude.m4: Update paths.
2732 * Makefile.in: Update include paths.
2733 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
2734 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
2735 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
2736 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
2737 (%-generated.c): Update paths.
2738 * Move entire directory from ../gdb/gdbserver.
2739
287c844a
MR
27402020-01-29 Maciej W. Rozycki <macro@wdc.com>
2741
2742 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
2743
548a204f
PFC
27442020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2745
2746 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
2747 assignment instead of srv_linux_obj.
2748
a2236a08
HD
27492020-01-28 Hannes Domani <ssbssa@yahoo.de>
2750
2751 * server.c (handle_qxfer_libraries): Write segment-address with
2752 paddress.
2753
bdaed379
HD
27542020-01-24 Hannes Domani <ssbssa@yahoo.de>
2755
2756 * Makefile.in (install-strip): New target.
2757 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
2758 * aclocal.m4: Regenerate.
2759 * configure: Regenerate.
2760 * configure.ac: Add AM_PROG_INSTALL_STRIP.
2761
42cd72aa
MR
27622020-01-24 Maciej W. Rozycki <macro@wdc.com>
2763
2764 * Makefile.in (SFILES): Adjust paths to point to real files.
2765 (OBS): Move waitstatus.o to target/waitstatus.o.
2766 (TAGS): Transform paths appropriately.
2767 (%.o): Rename to...
2768 (nat/%.o): ... this pattern rule.
2769 (%.o): Rename to...
2770 (target/%.o): ... this pattern rule.
2771 * configure.srv: Adjust paths throughout to include nat/ prefix
2772 with the revant files.
2773 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
2774 * configure: Regenerate.
2775
42ba50ec
MR
27762020-01-24 Maciej W. Rozycki <macro@wdc.com>
2777
2778 * Makefile.in (TAGS): Remove config files from the recipe.
2779
05ea2a05
TT
27802020-01-14 Tom Tromey <tom@tromey.com>
2781
2782 * configure: Rebuild.
2783 * configure.ac: Remove any checks that were added to common.m4.
2784 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
2785 lib-link.m4.
2786
01027315
TT
27872020-01-14 Tom Tromey <tom@tromey.com>
2788
2789 * server.h: Include config.h.
2790 * gdbreplay.c: Include config.h.
2791 * configure: Rebuild.
2792 * configure.ac: Don't source common.host.
2793 * acinclude.m4: Update path.
2794 * Makefile.in (INCSUPPORT): New variable.
2795 (INCLUDE_CFLAGS): Add INCSUPPORT.
2796 (SFILES): Update paths.
2797 (version-generated.c): Update path to create-version.sh.
2798 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
2799
b2ceabe8
TT
28002020-01-14 Tom Tromey <tom@tromey.com>
2801
2802 * configure.ac (LIBS): Use WIN32APILIBS.
2803 (USE_WIN32API): Don't define.
2804 * configure: Rebuild.
2805
25c51f71
TT
28062020-01-14 Tom Tromey <tom@tromey.com>
2807
2808 * configure: Rebuild.
2809
c0bd321d
SM
28102020-01-13 Simon Marchi <simon.marchi@efficios.com>
2811
2812 * Makefile.in (%-generated.c): Remove rule for files from
2813 regformats/i386.
2814
bb564c58
SM
28152020-01-13 Simon Marchi <simon.marchi@efficios.com>
2816
2817 * configure: Re-generate.
2818
6e37c371
SM
28192020-01-13 Simon Marchi <simon.marchi@efficios.com>
2820
2821 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
2822 Define to static.
2823 * tracepoint.c (stop_tracing, flush_trace_buffer,
2824 about_to_request_buffer_space, get_trace_state_variable_value,
2825 set_trace_state_variable_value, gdb_collect): Add declaration.
2826
df4a0200
SM
28272020-01-13 Simon Marchi <simon.marchi@efficios.com>
2828
2829 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
2830 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
2831 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
2832 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
2833 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
2834 static.
2835
89e94ec9
SM
28362020-01-13 Simon Marchi <simon.marchi@efficios.com>
2837
2838 * inferiors.c: Include gdbsupport/common-inferior.h.
2839
2552728a
SM
28402020-01-13 Simon Marchi <simon.marchi@efficios.com>
2841
2842 * hostio-errno.c: Include hostio.h.
2843
4025fa09
SM
28442020-01-13 Simon Marchi <simon.marchi@efficios.com>
2845
2846 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
2847 prerequisite.
2848
c0b0a142
SM
28492020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2850
2851 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
2852 * linux-arm-tdesc.h: Include arch/arm.h.
2853
bb1183e2
SM
28542020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2855
2856 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
2857
f5df0b5f
SM
28582020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2859
2860 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
2861 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
2862
5b6d1e4f
PA
28632020-01-10 Pedro Alves <palves@redhat.com>
2864
2865 * fork-child.c (post_fork_inferior): Pass target down to
2866 startup_inferior.
2867 * inferiors.c (switch_to_thread): Add process_stratum_target
2868 parameter.
2869 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
2870 * nto-low.c (nto_target_ops): Now a process_stratum_target.
2871 * linux-low.c (linux_target_ops): Now a process_stratum_target.
2872 * remote-utils.c (prepare_resume_reply): Pass the target to
2873 switch_to_thread.
2874 * target.c (the_target): Now a process_stratum_target.
2875 (done_accessing_memory): Pass the target to switch_to_thread.
2876 (set_target_ops): Ajust to use process_stratum_target.
2877 * target.h (struct target_ops): Rename to ...
2878 (struct process_stratum_target): ... this.
2879 (the_target, set_target_ops): Adjust.
2880 (prepare_to_access_memory): Adjust comment.
2881 * win32-low.c (child_xfer_memory): Adjust to use
2882 process_stratum_target.
2883 (win32_target_ops): Now a process_stratum_target.
2884
559e7e50
EZ
28852020-01-06 Eli Zaretskii <eliz@gnu.org>
2886 Pedro Alves <palves@redhat.com>
2887
2888 * win32-low.c (get_child_debug_event): Extract the fatal exception
2889 from the exit status and convert to the equivalent Posix signal
2890 number.
2891 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
2892 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
2893
48189bec
HD
28942020-01-01 Hannes Domani <ssbssa@yahoo.de>
2895
2896 * Makefile.in: Use INSTALL_PROGRAM_ENV.
2897
5dd8bf88
JB
28982020-01-01 Joel Brobecker <brobecker@adacore.com>
2899
2900 * server.c (gdbserver_version): Change copyright year to 2020.
2901 * gdbreplay.c (gdbreplay_version): Likewise.
2902
0ad6b8ee
CB
29032019-12-19 Christian Biesinger <cbiesinger@google.com>
2904
2905 * configure: Regenerate.
2906 * configure.ac: Quote variable arguments of test.
2907
1ee7b812
BE
29082019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2909
2910 * Makefile.in: Fix build with GNU Make 3.81
2911
d9fa87f4
TT
29122019-12-16 Tom Tromey <tromey@adacore.com>
2913
2914 * server.c (get_exec_file): Constify result.
2915
ab7d13f0
CB
29162019-12-10 Christian Biesinger <cbiesinger@google.com>
2917
2918 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
2919 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
2920 * config.in: Regenerate.
2921 * configure: Regenerate.
2922 * configure.ac: Don't check for strerror.
2923 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
2924 Call safe_strerror instead of strerror.
2925 * server.h (strerror): Remove this now-unnecessary declaration.
2926 * tracepoint.c (init_named_socket): Call safe_strerror instead of
2927 strerror.
2928 (gdb_agent_helper_thread): Likewise.
2929 * utils.c (perror_with_name): Likewise.
2930
4da8c3a8
TT
29312019-11-26 Tom Tromey <tom@tromey.com>
2932
2933 * configure, config.in: Rebuild.
2934
21987b9c
TT
29352019-11-26 Tom Tromey <tom@tromey.com>
2936
2937 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
2938 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
2939 gdb_sigmask.
2940 * configure, config.in: Rebuild.
2941
5e030278
TT
29422019-11-26 Tom Tromey <tom@tromey.com>
2943
2944 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
2945 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
2946 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
2947 * acinclude.m4: Include ax_pthread.m4.
2948 * config.in, configure: Rebuild.
2949
6d91ce9a
CB
29502019-11-26 Christian Biesinger <cbiesinger@google.com>
2951
2952 * debug.c (debug_set_output): Call safe_strerror instead of
2953 strerror.
2954 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
2955 (linux_kill_one_lwp): Likewise.
2956 (linux_detach_one_lwp): Likewise.
2957 (linux_wait_for_event_filtered): Likewise.
2958 (store_register): Likewise.
2959 * lynx-low.c (lynx_attach): Likewise.
2960 * mem-break.c (insert_memory_breakpoint): Likewise.
2961 (remove_memory_breakpoint): Likewise.
2962 (delete_fast_tracepoint_jump): Likewise.
2963 (set_fast_tracepoint_jump): Likewise.
2964 (uninsert_fast_tracepoint_jumps_at): Likewise.
2965 (reinsert_fast_tracepoint_jumps_at): Likewise.
2966 * nto-low.c (nto_xfer_memory): Likewise.
2967 (nto_resume): Likewise.
2968
6cdd651f
LM
29692019-11-20 Luis Machado <luis.machado@linaro.org>
2970
2971 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
2972 instead of register count.
2973 * tdesc.c (tdesc_contains_feature): New function.
2974 * tdesc.h (tdesc_contains_feature): New prototype.
2975
cd850b40
CB
29762019-11-15 Christian Biesinger <cbiesinger@google.com>
2977
2978 * Makefile.in: Add safe-strerror.c.
2979 * configure: Regenerate.
2980 * configure.ac: Don't source common.host.
2981
5abebf3c
CB
29822019-11-15 Christian Biesinger <cbiesinger@google.com>
2983
2984 * config.in: Regenerate.
2985 * configure: Regenerate.
2986
e06f3d6e
AB
29872019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
2988
2989 * ax.c (ax_printf): Handle size_t_arg.
2990
ca3a04f6
CB
29912019-11-06 Christian Biesinger <cbiesinger@google.com>
2992
2993 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
2994 * mi/mi-main.c (output_cores): Likewise.
2995 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
2996 (linux_xfer_osdata_modules): Likewise.
2997 * remote.c (register_remote_support_xml): Likewise.
2998 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
2999 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
3000
e48f6033
CB
30012019-11-01 Christian Biesinger <cbiesinger@google.com>
3002
3003 * configure: Regenerate.
3004 * configure.ac: Remove check for strerror_r.
3005
e7e97a2e
CB
30062019-10-31 Christian Biesinger <cbiesinger@google.com>
3007
3008 * config.in: Regenerate.
3009 * configure: Regenerate.
3010 * configure.ac: Also check for strerror_r.
3011
75cafaa6
CB
30122019-10-31 Christian Biesinger <cbiesinger@google.com>
3013
3014 * ax.h (debug_agent): Remove duplicate declaration.
3015
30baf67b
TV
30162019-10-26 Tom de Vries <tdevries@suse.de>
3017
3018 * linux-aarch64-low.c: Fix typos in comments.
3019 * linux-arm-low.c: Same.
3020 * linux-low.c: Same.
3021 * linux-ppc-low.c: Same.
3022 * proc-service.c: Same.
3023 * regcache.h: Same.
3024 * server.c: Same.
3025 * tracepoint.c: Same.
3026 * win32-low.c: Same.
3027
52c64cf7
TT
30282019-10-25 Tom Tromey <tromey@adacore.com>
3029
3030 * utils.c (xstrdup): Remove.
3031
c12d372d
TT
30322019-10-23 Tom Tromey <tom@tromey.com>
3033
3034 * configure, config.in: Rebuild.
3035
4d0b984b
TT
30362019-10-23 Tom Tromey <tom@tromey.com>
3037
3038 * configure: Rebuild.
3039 * acinclude.m4: Use m4_include, not sinclude.
3040
c5adaa19
TT
30412019-10-17 Tom Tromey <tromey@adacore.com>
3042
3043 * configure: Rebuild.
3044 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
3045 in AC_CONFIG_FILES invocation.
3046 * Makefile.in (stamp-h, Makefile): Use new-style config.status
3047 invocation.
3048
fec4e896
CB
30492019-10-16 Christian Biesinger <cbiesinger@google.com>
3050
3051 * server.c: Include xml-builtin.h.
3052 (get_xml_features): Don't declare xml_builtins here.
3053
00975ff6
AB
30542019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
3055
3056 * Makefile.in: Remove references to vec-ipa.o.
3057
0dc32745
AB
30582019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
3059
3060 * Makefile.in: Remove references to vec.c.
3061
3e6ec53a
CB
30622019-10-02 Christian Biesinger <cbiesinger@google.com>
3063
3064 * server.c (server_waiting): Change to bool.
3065 (extended_protocol): Likewise.
3066 (response_needed): Likewise.
3067 (exit_requested): Likewise.
3068 (run_once): Likewise.
3069 (report_no_resumed): Likewise.
3070 (non_stop): Likewise.
3071 (disable_packet_vCont): Likewise.
3072 (disable_packet_Tthread): Likewise.
3073 (disable_packet_qC): Likewise.
3074 (disable_packet_qfThreadInfo): Likewise.
3075 (handle_general_set): Update.
3076 (handle_detach): Update.
3077 (handle_monitor_command): Update.
3078 (handle_query): Update.
3079 (captured_main): Update.
3080 (process_serial_event): Update.
3081 * server.h (server_waiting): Change to bool.
3082 (disable_packet_vCont): Likewise.
3083 (disable_packet_Tthread): Likewise.
3084 (disable_packet_qC): Likewise.
3085 (disable_packet_qfThreadInfo): Likewise.
3086 (run_once): Likewise.
3087 (non_stop): Likewise.
3088 * target.c (target_stop_and_wait): Update.
3089
80fd2826
TT
30902019-10-02 Tom Tromey <tromey@adacore.com>
3091
3092 * Makefile.in (SFILES): Add common-inferior.c.
3093 (OBS): Add common-inferior.o.
3094 * server.c (startup_with_shell): Don't define.
3095
46f29a9a
AB
30962019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
3097
3098 * linux-low.c (linux_low_read_btrace): Update for change to
3099 std::vector.
3100
f9d949fb
CB
31012019-09-20 Christian Biesinger <cbiesinger@google.com>
3102
3103 * debug.c (debug_threads): Remove comment in favor of the header.
3104 * debug.h (using_threads): Add declaration.
3105 (debug_threads): Add comment.
3106 * linux-aarch64-low.c: Include debug.h and remove declaration of
3107 debug_threads.
3108 * nto-low.c: Likewise.
3109 * remote-utils.c: Likewise.
3110 * thread-db.c: Likewise.
3111
abf516c6
UW
31122019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
3113
3114 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
3115 and powerpc-cell64l-ipa.o.
3116 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
3117 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
3118 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
3119 (spu*-*-*): Remove.
3120
3121 * spu-low.c: Remove file.
3122
3123 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
3124 (parse_spufs_run): Remove.
3125 (ppc_get_pc): Remove Cell/B.E. support.
3126 (ppc_set_pc): Likewise.
3127 (ppc_breakpoint_at): Likewise.
3128 (ppc_arch_setup): Likewise.
3129 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
3130 tdesc_powerpc_cell32l.
3131 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
3132 or init_registers_powerpc_cell32l.
3133 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
3134 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
3135 or init_registers_powerpc_cell32l.
3136 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
3137 (init_registers_powerpc_cell32l): Remove prototype.
3138 (init_registers_powerpc_cell64l): Likewise.
3139
3140 * target.h (struct target_ops): Remove qxfer_spu member.
3141 * server.c (handle_qxfer_spu): Remove.
3142 (qxfer_packets): Remove entry for "spu".
3143 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
3144 * linux-low.c (SPUFS_MAGIC): Remove.
3145 (spu_enumerate_spu_ids): Remove.
3146 (linux_qxfer_spu): Remove.
3147 (linux_target_ops): Remove qxfer_spu member.
3148 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
3149 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
3150 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
3151
2d41fa11
SDJ
31522019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
3153
3154 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
3155 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
3156 * config.in: Regenerate.
3157 * configure: Regenerate.
3158
d59b55f0
TT
31592019-08-15 Tom Tromey <tromey@adacore.com>
3160
3161 * target.c (target_write_memory): Use gdb::byte_vector.
3162
4196ab2a
TT
31632019-08-15 Tom Tromey <tromey@adacore.com>
3164
3165 * tracepoint.c (write_inferior_data_pointer)
3166 (write_inferior_integer, write_inferior_int8)
3167 (write_inferior_uinteger, m_tracepoint_action_download)
3168 (r_tracepoint_action_download, x_tracepoint_action_download)
3169 (l_tracepoint_action_download, clear_inferior_trace_buffer)
3170 (download_agent_expr, download_tracepoint_1)
3171 (download_trace_state_variables, upload_fast_traceframes): Update.
3172 * server.c (gdb_write_memory): Update.
3173 * remote-utils.c (relocate_instruction): Update.
3174 * proc-service.c (ps_pdwrite): Update.
3175 * mem-break.c (remove_memory_breakpoint)
3176 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
3177 (uninsert_fast_tracepoint_jumps_at)
3178 (reinsert_fast_tracepoint_jumps_at): Update.
3179 * linux-x86-low.c (append_insns)
3180 (i386_install_fast_tracepoint_jump_pad)
3181 (amd64_write_goto_address, i386_write_goto_address): Update.
3182 * linux-s390-low.c (append_insns, s390_write_goto_address):
3183 Update.
3184 * linux-ppc-low.c (ppc_relocate_instruction)
3185 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
3186 (ppc_write_goto_address): Update.
3187 * linux-aarch64-low.c (append_insns): Update.
3188 * target.h (struct target_ops): Update.
3189 (write_inferior_memory): Don't declare.
3190 * target.c (target_write_memory): Rename from
3191 write_inferior_memory. Remove old target_write_memory.
3192
c6778d00
TT
31932019-08-15 Tom Tromey <tromey@adacore.com>
3194
3195 * target.c (write_inferior_memory): Use std::vector.
3196
404f2902
FCE
31972019-08-06 Frank Ch. Eigler <fche@redhat.com>
3198
3199 PR build/24886
3200 * configure.ac: Drop enable-libmcheck support.
3201 * configure, config.in: Rebuild.
3202 * acinclude.m4: Don't include it.
3203
4c5aa8e0
AH
32042019-07-19 Alan Hayward <alan.hayward@arm.com>
3205
3206 * configure.srv: Remove Arm xml files.
3207
7cc17433
AH
32082019-07-19 Alan Hayward <alan.hayward@arm.com>
3209
3210 * configure.srv: Add new files. Remove xml generated files.
3211 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
3212 registers.
3213 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
3214 * linux-aarch32-tdesc.c: New file.
3215 * linux-aarch32-tdesc.h: New file.
3216 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
3217 * linux-arm-low.c (init_registers_arm, tdesc_arm)
3218 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
3219 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
3220 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
3221 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
3222 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
3223 (arm_read_description): Call arm_linux_read_description.
3224 (initialize_low_arch): Don't init registers.
3225 * linux-arm-tdesc.c: New file.
3226 * linux-arm-tdesc.h: New file.
3227
166a82be
AH
32282019-07-10 Alan Hayward <alan.hayward@arm.com>
3229
3230 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
3231 Move counter inside for.
3232 (arm_read_description): Check ptrace earlier.
3233 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
3234
268a13a5
TT
32352019-07-09 Tom Tromey <tom@tromey.com>
3236
3237 * configure: Rebuild.
3238 * configure.ac: Change common to gdbsupport.
3239 * acinclude.m4: Change common to gdbsupport.
3240 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
3241 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
3242 common to gdbsupport.
3243 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
3244 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
3245 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
3246 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
3247 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
3248 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
3249 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
3250 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
3251 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
3252 common to gdbsupport.
3253
350fab54
AH
32542019-07-04 Alan Hayward <alan.hayward@arm.com>
3255
3256 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
3257 defines.
3258 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
3259
2b40fda7
AH
32602019-07-04 Alan Hayward <alan.hayward@arm.com>
3261
3262 * configure.srv: Remove legacy xml.
3263 * linux-aarch64-low.c (initialize_low_arch): Remove
3264 initialize_low_tdesc call.
3265 * linux-aarch64-tdesc-selftest.c: Remove file.
3266 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
3267 * linux-x86-low.c (initialize_low_arch): Remove
3268 initialize_low_tdesc call.
3269 * linux-x86-tdesc-selftest.c: Remove file.
3270 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
3271
7d10623d
TV
32722019-06-20 Tom de Vries <tdevries@suse.de>
3273
3274 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
3275 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
3276
8d6a48df
TV
32772019-06-19 Tom de Vries <tdevries@suse.de>
3278
3279 * debug.h (debug_write): Change return type to ssize_t.
3280 * debug.c (debug_write): Same.
3281
73cc7272
TT
32822019-06-14 Tom Tromey <tom@tromey.com>
3283
3284 * configure.ac: Use new path to gnulib.
3285 * configure: Rebuild.
3286 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
3287 to gnulib.
3288
08f10e02
TT
32892019-06-11 Tom Tromey <tom@tromey.com>
3290
3291 * Makefile.in (SFILES): Add alloc.c.
3292 (OBS): Add alloc.o.
3293 (IPA_OBJS): Add alloc-ipa.o.
3294 (alloc-ipa.o): New target.
3295 (%.o: ../%.c): New pattern rule.
3296
422186a9
TT
32972019-06-10 Tom Tromey <tromey@adacore.com>
3298
3299 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
3300 end warning with a newline.
3301 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
3302 newline.
3303 * thread-db.c (attach_thread): Don't end warning with a newline.
3304 (thread_db_notice_clone): Likewise.
3305 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
3306 newline.
3307 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
3308 end warning with a newline.
3309
b02f78f9
PA
33102019-06-04 Pedro Alves <palves@redhat.com>
3311
3312 * server.c (captured_main): Use make_unique_xstrdup.
3313
88ed7edb
TT
33142019-06-02 Tom Tromey <tom@tromey.com>
3315
3316 * gdbreplay.c (fromhex): Remove.
3317 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
3318
33a6bc35
TT
33192019-05-29 Tom Tromey <tromey@adacore.com>
3320
3321 * configure: Rebuild.
3322
e90a813d
KB
33232019-05-06 Kevin Buettner <kevinb@redhat.com>
3324
3325 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
3326 sign extension code on 32-bit builds.
3327
353ea2d1
EZ
33282019-05-03 Eli Zaretskii <eliz@gnu.org>
3329
3330 * remote-utils.c:
3331 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
3332
b494cdff
TT
33332019-04-19 Tom Tromey <tom@tromey.com>
3334
3335 * server.c (struct vstop_notif): Derive from notif_event.
3336 <base>: Remove.
3337 (queue_stop_reply): Update.
3338 (remove_all_on_match_ptid): Change type. Rewrite.
3339 (discard_queued_stop_replies): Rewrite.
3340 (in_queued_stop_replies_ptid): Change type.
3341 (in_queued_stop_replies): Rewrite.
3342 (notif_stop): Update.
3343 (queue_stop_reply_callback): Update.
3344 (captured_main): Don't call initialize_notif.
3345 (push_stop_notification): Update.
3346 * notif.c (notif_write_event, handle_notif_ack)
3347 (notif_event_enque, notif_push): Update.
3348 (notif_event_xfree, initialize_notif): Remove.
3349 * notif.h (struct notif_event): Include <list>, not
3350 "common/queue.h".
3351 (struct notif_server) <queue>: Now a std::list.
3352 (notif_event_p): Remove typedef.
3353 (initialize_notif): Don't declare.
3354 (struct notif_event): Add virtual destructor.
3355
a7e559cc
AH
33562019-04-17 Alan Hayward <alan.hayward@arm.com>
3357
3358 * ax.c (ax_vdebug): Call debug_printf.
3359 * debug.c (debug_write): New function.
3360 * debug.h (debug_write): New declaration.
3361 * linux-low.c (sigchld_handler): Call debug_write.
3362
aeb2e706
AH
33632019-04-17 Alan Hayward <alan.hayward@arm.com>
3364
3365 * debug.c (debug_set_output): New function.
3366 (debug_vprintf): Send output to debug_file.
3367 (debug_flush): Likewise.
3368 * debug.h (debug_set_output): New declaration.
3369 * server.c (handle_monitor_command): Add debug-file option.
3370 (captured_main): Likewise.
3371
c1bc0935
AH
33722019-04-17 Alan Hayward <alan.hayward@arm.com>
3373
3374 * debug.c (remote_debug): Add definition.
3375 * debug.h (remote_debug): Add declaration.
3376 * hostio.c (remote_debug): Remove declaration.
3377 * remote-utils.c (struct ui_file): Likewise.
3378 (remote_debug): Likewise.
3379 * remote-utils.h (remote_debug): Likewise,
3380 * server.c (remote_debug): Remove definition.
3381
3f52fdbc
KB
33822019-04-10 Kevin Buettner <kevinb@redhat.com>
3383
3384 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
3385 when using a 64-bit gdbserver.
3386
b0319eaa
TT
33872019-04-09 Tom Tromey <tromey@adacore.com>
3388
3389 * linux-low.c (select_event_lwp): Use find_thread_in_random.
3390
eedc3f4f
TT
33912019-04-08 Tom Tromey <tom@tromey.com>
3392
3393 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
3394 throw.
3395 (linux_resume_one_lwp): Likewise.
3396
230d2906
TT
33972019-04-08 Tom Tromey <tom@tromey.com>
3398
3399 * gdbreplay.c: Update.
3400 * linux-low.c: Update.
3401 * server.c: Update.
3402
a70b8144
TT
34032019-04-08 Tom Tromey <tom@tromey.com>
3404
3405 * server.c: Use C++ exception handling.
3406 * linux-low.c: Use C++ exception handling.
3407 * gdbreplay.c: Use C++ exception handling.
3408
3d6e9d23
TT
34092019-04-08 Tom Tromey <tom@tromey.com>
3410
3411 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
3412 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
3413 (captured_main, main): Update.
3414 * gdbreplay.c (main): Update.
3415
0570503d
PFC
34162019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3417
3418 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
3419 value in argument pointer, return 1 if the entry is found and 0
3420 otherwise. Move comment.
3421 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
3422 * linux-low.h (linux_get_auxv): Declare.
3423 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
3424
227a9e65
TT
34252019-04-05 Tom Tromey <tromey@adacore.com>
3426
3427 * server.c (gdbserver_usage): Use upper-case for metasyntactic
3428 variables.
3429
69f4c9cc
AH
34302019-03-28 Alan Hayward <alan.hayward@arm.com>
3431
3432 * linux-low.c (AT_HWCAP2): Add define if not already included.
3433
974c89e0
AH
34342019-03-26 Alan Hayward <alan.hayward@arm.com>
3435
3436 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
3437 (aarch64_arch_setup): Call linux_get_hwcap.
3438 * linux-arm-low.c (arm_get_hwcap): Remove function.
3439 (arm_read_description): Call linux_get_hwcap.
3440 * linux-low.c (linux_get_auxv): New function.
3441 (linux_get_hwcap): Likewise.
3442 (linux_get_hwcap2): Likewise.
3443 * linux-low.h (linux_get_hwcap): New declaration.
3444 (linux_get_hwcap2): Likewise.
3445 * linux-ppc-low.c (ppc_get_auxv): Remove function.
3446 (ppc_arch_setup): Call linux_get_hwcap.
3447 * linux-s390-low.c (s390_get_hwcap): Remove function.
3448 (s390_arch_setup): Call linux_get_hwcap.
3449
1ef53e6b
AH
34502019-03-22 Alan Hayward <alan.hayward@arm.com>
3451 Jiong Wang <jiong.wang@arm.com>
3452
3453 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
3454 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
3455 to fail.
3456 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
3457
ee4fbcfa
AH
34582019-03-22 Alan Hayward <alan.hayward@arm.com>
3459 Jiong Wang <jiong.wang@arm.com>
3460
3461 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
3462 (aarch64_get_hwcap): New function.
3463 (aarch64_arch_setup): Read APIA hwcap.
3464
6dc0ebde
AH
34652019-03-22 Alan Hayward <alan.hayward@arm.com>
3466 Jiong Wang <jiong.wang@arm.com>
3467
3468 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
3469 (initialize_low_tracepoint): Likewise.
3470 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
3471 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
3472 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
3473 (aarch64_linux_read_description): Likewise.
3474 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
3475
1163a4b7
JB
34762019-03-12 John Baldwin <jhb@FreeBSD.org>
3477
3478 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
3479 i386_create_target_description for 'segments' parameter.
3480 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
3481 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3482 * win32-i386-low.c (i386_arch_setup): Likewise.
3483
d3a70e03
TT
34842019-03-12 Tom Tromey <tromey@adacore.com>
3485
3486 * linux-low.c (iterate_over_lwps): Update.
3487
37991b4f
TT
34882019-03-06 Tom Tromey <tom@tromey.com>
3489
3490 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
3491 (captured_main): Use SCOPE_EXIT.
3492
45950eb6
SDJ
34932019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
3494
3495 * configure.srv: Use '$enable_unittest' instead of '$development'
3496 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
3497 case.
3498
43ac54fc
TT
34992019-02-27 Tom Tromey <tromey@adacore.com>
3500
3501 * gdbreplay.c (logchar): Handle \r\n.
3502
df0da8a2
AH
35032019-02-07 Alan Hayward <alan.hayward@arm.com>
3504
3505 * linux-low.c (linux_attach): Add process before lwp.
3506 * server.c (attach_inferior): Check if already attached.
3507
1a5c2598
TT
35082019-02-07 Tom Tromey <tom@tromey.com>
3509
3510 * x86-tdesc.h: Rename include guard.
3511 * x86-low.h: Add include guard.
3512 * wincecompat.h: Rename include guard.
3513 * win32-low.h: Add include guard.
3514 * utils.h: Rename include guard.
3515 * tracepoint.h: Rename include guard.
3516 * tdesc.h: Rename include guard.
3517 * target.h: Rename include guard.
3518 * server.h: Rename include guard.
3519 * remote-utils.h: Rename include guard.
3520 * regcache.h: Rename include guard.
3521 * nto-low.h: Rename include guard.
3522 * notif.h: Add include guard.
3523 * mem-break.h: Rename include guard.
3524 * lynx-low.h: Add include guard.
3525 * linux-x86-tdesc.h: Add include guard.
3526 * linux-s390-tdesc.h: Add include guard.
3527 * linux-ppc-tdesc-init.h: Add include guard.
3528 * linux-low.h: Add include guard.
3529 * linux-aarch64-tdesc.h: Add include guard.
3530 * linux-aarch32-low.h: Add include guard.
3531 * inferiors.h: Rename include guard.
3532 * i387-fp.h: Rename include guard.
3533 * hostio.h: Rename include guard.
3534 * gdbthread.h: Rename include guard.
3535 * gdb_proc_service.h: Rename include guard.
3536 * event-loop.h: Rename include guard.
3537 * dll.h: Rename include guard.
3538 * debug.h: Rename include guard.
3539 * ax.h: Rename include guard.
3540
956cc47c
SN
35412018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
3542
3543 PR gdb/23985
3544 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
3545 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
3546
a0707f3c
TT
35472019-01-25 Tom Tromey <tom@tromey.com>
3548
3549 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
3550
0747795c
TT
35512019-01-25 Tom Tromey <tom@tromey.com>
3552
3553 * win32-low.c: Fix common/ includes.
3554 * win32-i386-low.c: Fix common/ includes.
3555 * tracepoint.c: Fix common/ includes.
3556 * thread-db.c: Fix common/ includes.
3557 * target.h: Fix common/ includes.
3558 * symbol.c: Fix common/ includes.
3559 * spu-low.c: Fix common/ includes.
3560 * server.h: Fix common/ includes.
3561 * server.c: Fix common/ includes.
3562 * remote-utils.c: Fix common/ includes.
3563 * regcache.h: Fix common/ includes.
3564 * regcache.c: Fix common/ includes.
3565 * nto-x86-low.c: Fix common/ includes.
3566 * notif.h: Fix common/ includes.
3567 * mem-break.h: Fix common/ includes.
3568 * lynx-low.c: Fix common/ includes.
3569 * lynx-i386-low.c: Fix common/ includes.
3570 * linux-x86-tdesc-selftest.c: Fix common/ includes.
3571 * linux-x86-low.c: Fix common/ includes.
3572 * linux-low.c: Fix common/ includes.
3573 * inferiors.h: Fix common/ includes.
3574 * i387-fp.c: Fix common/ includes.
3575 * hostio.c: Fix common/ includes.
3576 * hostio-errno.c: Fix common/ includes.
3577 * gdbthread.h: Fix common/ includes.
3578 * gdbreplay.c: Fix common/ includes.
3579 * fork-child.c: Fix common/ includes.
3580 * event-loop.c: Fix common/ includes.
3581 * ax.c:
3582 (enum gdb_agent_op): Fix common/ includes.
3583
be6d4f74
TT
35842019-01-21 Tom Tromey <tom@tromey.com>
3585
3586 * tracepoint.c: Fix includes.
3587 * remote-utils.c: Fix includes.
3588 * linux-x86-low.c: Fix includes.
3589
66d91b39
JB
35902019-01-01 Joel Brobecker <brobecker@adacore.com>
3591
3592 * gdbreplay.c (gdbreplay_version): Update copyright year in
3593 version message.
3594 * server.c (gdbserver_version): Likewise.
3595
754e3168
AH
35962018-12-05 Alan Hayward <alan.hayward@arm.com>
3597
3598 * linux-low.c (add_lwp): Switch ordering.
3599
d105de22
TT
36002018-11-29 Tom Tromey <tom@tromey.com>
3601
3602 * win32-low.c (win32_join): Take pid, not process.
3603 * target.h (struct target_ops) <join>: Change argument type.
3604 (join_inferior): Change argument name.
3605 * spu-low.c (spu_join): Take pid, not process.
3606 * server.c (handle_detach): Preserve pid before destroying
3607 process.
3608 * lynx-low.c (lynx_join): Take pid, not process.
3609 * linux-low.c (linux_join): Take pid, not process.
3610
50138245
AH
36112018-11-23 Alan Hayward <alan.hayward@arm.com>
3612
3613 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
3614 (aarch64_cannot_fetch_register): Likewise.
3615 (struct linux_target_ops): Update references.
3616
64f57f3d
PFC
36172018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3618
3619 * linux-ppc-low.c: Include nat/linux-ptrace.h.
3620
8d619c01
EBM
36212018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3622
3623 * configure.srv (ipa_ppc_linux_regobj): Add
3624 powerpc-isa207-htm-vsx32l-ipa.o and
3625 powerpc-isa207-htm-vsx64l-ipa.o.
3626 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
3627 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
3628 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
3629 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
3630 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
3631 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
3632 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
3633 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
3634 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3635 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
3636 (init_registers_powerpc_isa207_htm_vsx32l)
3637 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
3638 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
3639 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
3640 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
3641 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
3642 (ppc_store_tm_ctarregset): New functions.
3643 (ppc_regsets): Add entries for HTM regsets.
3644 (ppc_arch_setup): Set htm in features struct when needed. Set
3645 sizes for the HTM regsets.
3646 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
3647 (initialize_low_arch): Call
3648 init_registers_powerpc_isa207_htm_vsx32l and
3649 init_registers_powerpc_isa207_htm_vsx64l.
3650 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
3651 PPC_TDESC_ISA207_HTM_VSX.
3652 (initialize_low_tracepoint): Call
3653 init_registers_powerpc_isa207_htm_vsx32l and
3654 init_registers_powerpc_isa207_htm_vsx64l.
3655
232bfb86
EBM
36562018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3657
3658 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
3659 rs6000/power-linux-pmu.xml to srv_xmlfiles.
3660 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
3661 (ppc_store_pmuregset): New functions.
3662 (ppc_regsets): Add entries for ebb and pmu regsets.
3663 (ppc_arch_setup): Set isa207 in features struct if the ebb and
3664 pmu regsets are available. Set sizes for these regsets.
3665
f2cf6173
EBM
36662018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3667
3668 * configure.srv (ipa_ppc_linux_regobj): Add
3669 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
3670 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
3671 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
3672 rs6000/powerpc-isa207-vsx32l.xml, and
3673 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
3674 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3675 <PPC_TDESC_ISA207_VSX>: New enum value.
3676 (init_registers_powerpc_isa207_vsx32l): Declare.
3677 (init_registers_powerpc_isa207_vsx64l): Declare.
3678 * linux-ppc-low.c (ppc_fill_tarregset): New function.
3679 (ppc_store_tarregset): New function.
3680 (ppc_regsets): Add entry for the TAR regset.
3681 (ppc_arch_setup): Set isa207 in features struct when needed. Set
3682 size for the TAR regsets.
3683 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
3684 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
3685 and init_registers_powerpc_isa207_vsx64l.
3686 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
3687 (initialize_low_tracepoint): Call
3688 init_registers_powerpc_isa207_vsx32l and
3689 init_registers_powerpc_isa207_vsx64l.
3690
7ca18ed6
EBM
36912018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
3692 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3693
3694 * configure.srv (ipa_ppc_linux_regobj): Add
3695 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
3696 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
3697 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
3698 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
3699 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
3700 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
3701 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
3702 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3703 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
3704 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
3705 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
3706 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
3707 (ppc_hwcap): Add comment.
3708 (ppc_hwcap2): New global.
3709 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
3710 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
3711 (ppc_regsets): Add entries for the DSCR and PPR regsets.
3712 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
3713 when needed. Set sizes for the the DSCR and PPR regsets.
3714 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
3715 (initialize_low_arch): Call
3716 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
3717 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
3718 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
3719 PPC_TDESC_ISA205_PPR_DSCR_VSX.
3720 (initialize_low_tracepoint): Call
3721 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
3722 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
3723
5c849b22
PFC
37242018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3725
3726 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
3727
8ecfd7bd
SDJ
37282018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
3729 Simon Marchi <simark@simark.ca>
3730
3731 * acinclude.m4: Include "../selftest.m4".
3732 * configure: Regenerate.
3733 * configure.ac: Use "GDB_AC_SELFTEST".
3734 * configure.srv: Use "$enable_unittests" instead of
3735 "$development" when checking whether unit tests have been
3736 enabled.
3737 * server.c (captured_main): Update message informing that
3738 selftests have been disabled.
3739
96643e35
TT
37402018-10-04 Tom Tromey <tom@tromey.com>
3741
3742 * configure: Rebuild.
3743
da4ae14a
TT
37442018-10-04 Tom Tromey <tom@tromey.com>
3745
3746 * server.c (handle_status): Rename inner "thread".
3747 (process_serial_event): Declare "res" in 'm' case.
3748 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
3749 (iterate_over_lwps): Rename inner "thread".
3750 (linux_qxfer_libraries_svr4): Rename inner "len".
3751 * gdbthread.h (find_thread_in_random): Rename inner "thread".
3752
7c619dbd
GB
37532018-10-01 Gary Benson <gbenson@redhat.com>
3754
3755 * gdb_proc_service.h: Moved common code to
3756 common/gdb_proc_service.h.
3757
3795e814
GB
37582018-10-01 Gary Benson <gbenson@redhat.com>
3759
3760 * gdb_proc_service.h: Synchronize comments and whitespace with
3761 GDB's version of this file.
3762
49b036f1
TT
37632018-09-25 Tom Tromey <tom@tromey.com>
3764
3765 * configure: Rebuild.
3766 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
3767
8ff03f0b
SM
37682018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3769
3770 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
3771 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
3772 ($(IPA_LIB)): Sort IPA_OBJS.
3773
a1cd91dc
SM
37742018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3775
3776 * Makefile.in: Remove references to $(ADD_DEPS).
3777
752312ba
TT
37782018-09-16 Tom Tromey <tom@tromey.com>
3779
3780 * remote-utils.c (remote_open): Use GNU style for metasyntactic
3781 variables.
3782 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
3783 variables.
3784
f1628857
TT
37852018-09-05 Tom Tromey <tom@tromey.com>
3786
3787 * configure: Rebuild.
3788
ad202fcc
SM
37892018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
3790
3791 PR build/23399
3792 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
3793
d3d8724a
TT
37942018-08-27 Tom Tromey <tom@tromey.com>
3795
3796 PR build/23087:
3797 * configure: Rebuild.
3798
b4f183d2
TT
37992018-08-27 Tom Tromey <tom@tromey.com>
3800
3801 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
3802 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
3803 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
3804 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
3805 (s390x_emit_stack_adjust): Add casts to unsigned char.
3806
4e2aa472
SM
38072018-08-22 Simon Marchi <simon.marchi@ericsson.com>
3808
3809 PR gdb/23374
3810 PR gdb/23375
3811 * server.h (struct client_state) <disable_randomization>:
3812 Initialize to 1.
3813
cf4088a9
SM
38142018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3815
3816 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
3817 variable.
3818 (mips_supply_ptrace_register): Likewise.
3819
a0de763e
TT
38202018-07-22 Tom Tromey <tom@tromey.com>
3821
3822 * configure: Rebuild.
3823
b0a7723d
TT
38242018-07-22 Tom Tromey <tom@tromey.com>
3825
3826 * win32-low.c (win32_create_inferior): Remove unused variables.
3827 * gdbreplay.c (remote_open): Remove unused variable.
3828 * remote-utils.c (remote_prepare): Remove unused variable.
3829 * x86-tdesc.h (X86_TDESC_H): Define.
3830 (amd64_expedite_regs): Define conditionally.
3831 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
3832 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
3833 * remote-utils.c (readchar): Remove unused variable.
3834
a780ef4f
PA
38352018-07-13 Pedro Alves <palves@redhat.com>
3836
3837 * linux-low.c (linux_kill): Change parameter to process_info
3838 pointer instead of pid. Adjust.
3839 * lynx-low.c (lynx_kill): Likewise.
3840 * nto-low.c (nto_kill): Likewise.
3841 * spu-low.c (spu_kill): Likewise.
3842 * win32-low.c (win32_kill): Likewise.
3843 * server.c (handle_v_kill, kill_inferior_callback)
3844 (detach_or_kill_for_exit): Adjust.
3845 * target.c (kill_inferior): Change parameter to process_info
3846 pointer instead of pid. Adjust.
3847 * target.h (struct target_ops) <kill>: Change parameter to
3848 process_info pointer instead of pid. Adjust all implementations
3849 and callers.
3850 (kill_inferior): Likewise.
3851
ef2ddb33
PA
38522018-07-13 Pedro Alves <palves@redhat.com>
3853
3854 * linux-low.c (linux_detach, linux_join): Change parameter to
3855 process_info pointer instead of pid. Adjust.
3856 * lynx-low.c (lynx_detach, lynx_join): Likewise.
3857 * nto-low.c (nto_detach): Likewise.
3858 * spu-low.c (spu_detach, spu_join): Likewise.
3859 * win32-low.c (win32_detach, win32_join): Likewise.
3860 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
3861 * target.h (struct target_ops) <detach, join>: Change parameter to
3862 process_info pointer instead of pid. Adjust all implementations
3863 and callers.
3864 (detach_inferior, join_inferior): Rename 'pid' parameter to
3865 'proc'.
3866
c7ab0aef
SDJ
38672018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3868 Jan Kratochvil <jan.kratochvil@redhat.com>
3869 Paul Fertser <fercerpav@gmail.com>
3870 Tsutomu Seki <sekiriki@gmail.com>
3871
3872 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
3873 (OBS): Add 'common/netstuff.o'.
3874 (GDBREPLAY_OBS): Likewise.
3875 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
3876 (remote_open): Implement support for IPv6
3877 connections.
3878 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
3879 and 'wspiapi.h'.
3880 (handle_accept_event): Accept connections from IPv6 sources.
3881 (remote_prepare): Handle IPv6-style hostnames; implement
3882 support for IPv6 connections.
3883 (remote_open): Implement support for printing connections from
3884 IPv6 sources.
3885
31445d10
PA
38862018-07-11 Pedro Alves <palves@redhat.com>
3887
3888 PR gdb/23377
3889 * mem-break.c (any_persistent_commands): Add process_info
3890 parameter and use it instead of relying on the current process.
3891 Change return type to bool.
3892 * mem-break.h (any_persistent_commands): Add process_info
3893 parameter and change return type to bool.
3894 * server.c (handle_detach): Remove require_running_or_return call.
3895 Look up the process_info for the process we're about to detach.
3896 If not found, return back error to GDB. Adjust
3897 any_persistent_commands call to pass down a process pointer.
3898
cb197132
PA
38992018-07-11 Pedro Alves <palves@redhat.com>
3900
3901 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
3902 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
3903 instead of collect_register_by_name.
3904 * regcache.c (regcache_raw_get_unsigned_by_name): New.
3905 * regcache.h (regcache_raw_get_unsigned_by_name): New.
3906
1b919490
VB
39072018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3908 Pedro Alves <palves@redhat.com>
3909
3910 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
3911
d7e15655
TT
39122018-07-03 Tom Tromey <tom@tromey.com>
3913
3914 * linux-low.c: Update.
3915 * lynx-low.c: Update.
3916 * mem-break.c: Update.
3917 * nto-low.c: Update.
3918 * remote-utils.c: Update.
3919 * server.c: Update.
3920 * spu-low.c: Update.
3921 * target.c: Update.
3922 * win32-low.c: Update.
3923
26a57c92
TT
39242018-07-03 Tom Tromey <tom@tromey.com>
3925
3926 * server.c: Update.
3927
0e998d96
TT
39282018-07-03 Tom Tromey <tom@tromey.com>
3929
3930 * linux-low.c: Update.
3931
cc6bcb54
TT
39322018-07-03 Tom Tromey <tom@tromey.com>
3933
3934 * target.c: Update.
3935
e38504b3
TT
39362018-07-03 Tom Tromey <tom@tromey.com>
3937
3938 * linux-low.c: Update.
3939 * linux-mips-low.c: Update.
3940 * lynx-low.c: Update.
3941 * nto-low.c: Update.
3942 * remote-utils.c: Update.
3943 * server.c: Update.
3944 * spu-low.c: Update.
3945 * target.c: Update.
3946 * thread-db.c: Update.
3947
e99b03dc
TT
39482018-07-03 Tom Tromey <tom@tromey.com>
3949
3950 * linux-low.c: Update.
3951 * linux-mips-low.c: Update.
3952 * lynx-low.c: Update.
3953 * mem-break.c: Update.
3954 * nto-low.c: Update.
3955 * remote-utils.c: Update.
3956 * server.c: Update.
3957 * spu-low.c: Update.
3958 * target.c: Update.
3959 * tracepoint.c: Update.
3960
f2907e49
TT
39612018-07-03 Tom Tromey <tom@tromey.com>
3962
3963 * linux-low.c: Update.
3964 * linux-ppc-low.c: Update.
3965 * linux-x86-low.c: Update.
3966 * proc-service.c: Update.
3967 * server.c: Update.
3968 * spu-low.c: Update.
3969 * thread-db.c: Update.
3970 * win32-low.c: Update.
3971
fd79271b
TT
39722018-07-03 Tom Tromey <tom@tromey.com>
3973
3974 * linux-low.c: Update.
3975 * lynx-low.c: Update.
3976 * nto-low.c: Update.
3977 * remote-utils.c: Update.
3978 * spu-low.c: Update.
3979 * thread-db.c: Update.
3980 * win32-low.c: Update.
3981
c0867626
SDJ
39822018-06-29 Joel Brobecker <brobecker@adacore.com>
3983
3984 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
3985 parameter in call to 'amd64_create_target_description'.
3986
2512d7ef
JK
39872018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
3988
3989 * x86-tdesc.h: Remove executable permission flag.
3990
d0ac1c44
SM
39912018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3992
3993 * configure.ac: Remove AC_PREREQ, add missing quoting.
3994 * configure: Re-generate.
3995 * config.in: Re-generate.
3996 * aclocal.m4: Re-generate.
3997
c4eb05ff
SM
39982018-06-18 Simon Marchi <simon.marchi@ericsson.com>
3999
4000 * tracepoint.h (current_traceframe): Remove declaration.
4001
02895270
AH
40022018-06-18 Alan Hayward <alan.hayward@arm.com>
4003
4004 * linux-aarch64-low.c (is_sve_tdesc): New function.
4005 (aarch64_sve_regs_copy_to_regcache): Likewise.
4006 (aarch64_sve_regs_copy_from_regcache): Likewise.
4007 (aarch64_regs_info): Add SVE checks.
4008 (initialize_low_arch): Initialize SVE.
4009
e9902bfc
AH
40102018-06-18 Alan Hayward <alan.hayward@arm.com>
4011
4012 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
4013
fefa175e
AH
40142018-06-11 Alan Hayward <alan.hayward@arm.com>
4015
4016 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
4017 (initialize_low_tracepoint): Likewise
4018 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
4019 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
4020 param.
4021 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
4022 checks.
4023 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
4024
b91ad3ff
AH
40252018-06-11 Alan Hayward <alan.hayward@arm.com>
4026
4027 * server.h (PBUFSIZ): Increase size
4028
f868386e
AH
40292018-06-11 Alan Hayward <alan.hayward@arm.com>
4030
4031 * regcache.c (regcache::raw_compare): New function.
4032 * regcache.h (regcache::raw_compare): New declaration.
4033
9c861883
AH
40342018-06-11 Alan Hayward <alan.hayward@arm.com>
4035
4036 * regcache.c (new_register_cache): Use new.
4037 (free_register_cache): Use delete.
4038 (register_data): Use const.
4039 (supply_register): Move body inside regcache.
4040 (regcache::raw_supply): New override function.
4041 (collect_register): Move body inside regcache.
4042 (regcache::raw_collect): New override function.
4043 (regcache::get_register_status): New override function.
4044 * regcache.h (struct regcache): Inherit from reg_buffer_common.
4045
40591844
TT
40462018-06-09 Tom Tromey <tom@tromey.com>
4047
4048 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
4049 declare queue.
4050 (event_queue): Use std::queue.
4051 (gdb_event_xfree): Remove.
4052 (initialize_event_loop, process_event, wait_for_event): Update.
4053
6341380d
SC
40542018-06-08 Stan Cox <scox@redhat.com>
4055
4056 * win32-low.c (win32_create_inferior): last_ptid and last_status
4057 moved to client_state.
4058
03349c93
PA
40592018-06-08 Pedro Alves <palves@redhat.com>
4060
4061 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
4062 common/common-exceptions.o, common/common-utils.o,
4063 common/errors.o, common/print-utils.o and utils.o.
4064 * gdbreplay.c: Include "common-defs.h" instead of the two
4065 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
4066 string.h or alloca.h.
4067 (perror_with_name): Delete.
4068 (remote_open): Use xstrdup instead of strdup.
4069 (main): Rename to ...
4070 (captured_main): ... this.
4071 (main): New.
4072
8dcc53b3
TT
40732018-06-08 Tom Tromey <tom@tromey.com>
4074
4075 * linux-low.c (linux_low_read_btrace): Update.
4076
c12a5089
SC
40772018-06-04 Stan Cox <scox@redhat.com>
4078
4079 * server.h (struct client_state): New.
4080 * server.c (cont_thread, general_thread, multi_process)
4081 (report_fork_events, report_vfork_events, report_exec_events)
4082 (report_thread_events, swbreak_feature, hwbreak_feature)
4083 (vCont_supported, disable_randomization, pass_signals)
4084 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
4085 Moved to client_state.
4086 * remote-utils.c (remote_debug, noack_mode)
4087 (transport_is_reliable): Moved to client_state.
4088 * tracepoint.c (current_traceframe): Moved to client_state.
4089
4090 Update all callers.
4091 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
4092 linux-low.c, remote-utils.h, target.c: Use client_state.
4093
122394f1
AH
40942018-05-31 Alan Hayward <alan.hayward@arm.com>
4095
4096 * configure.srv: Add new c/h file.
4097
95228a0d
AH
40982018-05-31 Alan Hayward <alan.hayward@arm.com>
4099
4100 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
4101 null VQ.
4102
d8dab6c3
MR
41032018-05-25 Maciej W. Rozycki <macro@mips.com>
4104
4105 * gdb.arch/mips-fpregset-core.exp: New test.
4106 * gdb.arch/mips-fpregset-core.c: New test source.
4107
81e25b7c
EK
41082018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
4109
4110 PR server/23198
4111 * hostio.c (require_int): Do not report overflow for integers
4112 between 0xfffffff and 0x7fffffff.
4113
7e947ad3
MR
41142018-05-22 Maciej W. Rozycki <macro@mips.com>
4115
4116 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
4117 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
4118 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
4119 functions.
4120 (the_low_target): Wire them.
4121
1d75a658
PFC
41222018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4123
4124 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
4125 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
4126 mode. Call collect_register_by_name with vscr using
4127 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
4128 (ppc_store_vrregset): Add and set vscr_offset variable as in
4129 ppc_fill_vrregset. Call supply_register_by_name with vscr using
4130 vscr_offset.
4131
d078308a
PFC
41322018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4133
4134 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4135 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
4136 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
4137
7273b5fc
PFC
41382018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4139
4140 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
4141 (ppc_store_vsxregset): Likewise.
4142 (ppc_fill_vrregset): Likewise.
4143 (ppc_store_vrregset): Likewise.
4144 (ppc_fill_evrregset): Likewise.
4145 (ppc_store_evrregset): Likewise.
4146 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
4147 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
4148 needed.
4149
2e077f5e
PFC
41502018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4151
4152 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
4153 wordsize of the inferior. Call ppc_linux_target_wordsize.
4154
bd64614e
PFC
41552018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4156
4157 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
4158 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
4159 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
4160 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4161 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4162 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4163 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4164 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4165 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4166 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4167 (tdesc_powerpc_e500l): Remove.
4168 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
4169 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
4170 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
4171 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
4172 linux-ppc-tdesc.h.
4173 (ppc_arch_setup): Remove target description matching code. Fill a
4174 ppc_linux_features struct and call ppc_linux_match_description
4175 with it.
4176
75d74cca
MR
41772018-05-22 Maciej W. Rozycki <macro@mips.com>
4178
4179 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
4180 width of the requested register exceeds the width of the
4181 `ptrace' data type.
4182 (mips_cannot_store_register): Likewise.
4183
e4439e43
MR
41842018-05-21 Maciej W. Rozycki <macro@mips.com>
4185
4186 * linux-mips-low.c (mips_fetch_register): New function. Update
4187 preceding comment.
4188 (mips_store_gregset): Supply 0 rather than $restart for $zero.
4189 (the_low_target): Wire `mips_fetch_register'.
4190
55271bf9
JB
41912018-05-10 Joel Brobecker <brobecker@adacore.com>
4192
4193 * lynx-i386-low.c (LYNXOS_178): New macro.
4194 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
4195 the layout on LynxOS-178.
4196 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
4197 handle floating point registers that are not supported by
4198 LynxOS-178.
4199
1a34f210
TT
42002018-05-10 Tom Tromey <tom@tromey.com>
4201
4202 * configure: Rebuild.
4203
190852c8
JB
42042018-05-10 Joel Brobecker <brobecker@adacore.com>
4205
4206 PR server/23158:
4207 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
4208 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
4209 Use it to set the expedite_regs field in the given tdesc.
4210 * x86-tdesc.h: New file.
4211 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
4212 Adjust following the addition of the new expedite_regs parameter
4213 to init_target_desc.
4214 * linux-tic6x-low.c (tic6x_read_description): Likewise.
4215 * linux-x86-tdesc.c: #include "x86-tdesc.h".
4216 (i386_linux_read_description, amd64_linux_read_description):
4217 Adjust following the addition of the new expedite_regs parameter
4218 to init_target_desc.
4219 * lynx-i386-low.c: #include "x86-tdesc.h".
4220 (lynx_i386_arch_setup): Adjust following the addition of the new
4221 expedite_regs parameter to init_target_desc.
4222 * nto-x86-low.c: #include "x86-tdesc.h".
4223 (nto_x86_arch_setup): Adjust following the addition of the new
4224 expedite_regs parameter to init_target_desc.
4225 * win32-i386-low.c: #include "x86-tdesc.h".
4226 (i386_arch_setup): Adjust following the addition of the new
4227 expedite_regs parameter to init_target_desc.
4228
7dbac825
JB
42292018-05-10 Joel Brobecker <brobecker@adacore.com>
4230
4231 PR server/23158:
4232 * win32-low.c (win32_create_inferior): Add call to my_wait
4233 setting last_status global.
4234
906994d9
JB
42352018-05-10 Joel Brobecker <brobecker@adacore.com>
4236
4237 PR server/23158:
4238 * win32-low.c (create_process): Only call gdb_tilde_expand if
4239 inferior_cwd is not NULL.
4240
8ee22052
AB
42412018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
4242
4243 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
4244 registers to the cache if their values have changed.
4245 (i387_xsave_to_cache): Provide default values for x87 control
4246 registers when these features are available, but disabled.
4247 * regcache.c (supply_register_by_name_zeroed): New function.
4248 * regcache.h (supply_register_by_name_zeroed): Declare new
4249 function.
4250
aff689d3
TT
42512018-05-07 Tom Tromey <tom@tromey.com>
4252
4253 * configure: Rebuild.
4254
85e26832
TT
42552018-05-04 Tom Tromey <tom@tromey.com>
4256
4257 * configure: Rebuild.
4258
a3b60e45
JK
42592018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
4260 Pedro Alves <palves@redhat.com>
4261
4262 * linux-aarch64-low.c (aarch64_stopped_data_address):
4263 Likewise.
4264
632e107b
TT
42652018-04-27 Tom Tromey <tom@tromey.com>
4266
4267 * configure: Rebuild.
4268
458412c3
TT
42692018-04-23 Tom Tromey <tom@tromey.com>
4270
4271 * configure: Rebuild.
4272
f31c089e
SM
42732018-04-19 Simon Marchi <simon.marchi@ericsson.com>
4274
4275 * Makefile.in (depcomp): Add "..".
4276 (all_deps_files): New and use it.
4277
b319b098
AH
42782018-04-18 Alan Hayward <alan.hayward@arm.com>
4279
4280 * configure.srv (aarch64*-*-linux*): Don't include xml.
4281 (i[34567]86-*-cygwin*): Likewise.
4282 (i[34567]86-*-linux*): Likewise.
4283 (i[34567]86-*-lynxos*): Likewise.
4284 (i[34567]86-*-mingw32ce*): Likewise.
4285 (i[34567]86-*-mingw*): Likewise.
4286 (i[34567]86-*-nto*): Likewise.
4287 (tic6x-*-uclinux): Likewise.
4288 (x86_64-*-linux*): Likewise.
4289 (x86_64-*-mingw*): Likewise.
4290 (x86_64-*-cygwin*): Likewise.
4291
3b74854b
AH
42922018-04-18 Alan Hayward <alan.hayward@arm.com>
4293
4294 * tdesc.c: Remove xml parameter.
4295
e98577a9
AH
42962018-04-18 Alan Hayward <alan.hayward@arm.com>
4297
4298 * server.c (get_features_xml): Remove cast.
4299 * tdesc.c (void target_desc::accept): Fill in function.
4300 (tdesc_get_features_xml): Remove old xml creation.
4301 (print_xml_feature::visit_pre): Add xml vistor.
4302 * tdesc.h (struct target_desc): Make xmltarget mutable.
4303 (tdesc_get_features_xml): Remove declaration.
4304
d278f585
AH
43052018-04-18 Alan Hayward <alan.hayward@arm.com>
4306
4307 * tdesc.c (tdesc_architecture_name): Add new function.
4308 (tdesc_osabi_name): Likewise.
4309 (tdesc_get_features_xml): Use new functions.
4310
eee8a18d
AH
43112018-04-18 Alan Hayward <alan.hayward@arm.com>
4312
4313 * tdesc.c (tdesc_create_flags): Remove.
4314 (tdesc_add_flag): Likewise.
4315 (tdesc_named_type): Likewise.
4316 (tdesc_create_union): Likewise.
4317 (tdesc_create_struct): Likewise.
4318 (tdesc_create_vector): Likewise.
4319 (tdesc_add_bitfield): Likewise.
4320 (tdesc_add_field): Likewise.
4321 (tdesc_set_struct_size): Likewise.
4322
82ec9bc7
AH
43232018-04-18 Alan Hayward <alan.hayward@arm.com>
4324
4325 * tdesc.c (~target_desc): Remove implictly deleted items.
4326 (init_target_desc): Iterate all features.
4327 (tdesc_get_features_xml): Use vector.
4328 (tdesc_create_feature): Create feature.
4329 * tdesc.h (tdesc_feature) Remove
4330 (target_desc): Add features.
4331
ea3e7d71
AH
43322018-04-18 Alan Hayward <alan.hayward@arm.com>
4333
4334 * Makefile.in: Add common/tdesc.c
4335 * tdesc.c (init_target_desc): init all reg_defs from register
4336 vector.
4337 (tdesc_create_reg): Create tdesc_reg.
4338 * tdesc.h (tdesc_feature): Add register vector.
4339
17d08cd4
SM
43402018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
4341
4342 * tdesc.h (struct target_desc) <features>: Change type to
4343 std::vector<std::string>.
4344 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
4345 changes.
4346 (tdesc_get_features_xml): Likewise.
4347 (tdesc_create_feature): Likewise.
4348
5cd3e386
AH
43492018-03-26 Alan Hayward <alan.hayward@arm.com>
4350
4351 * regcache.c (find_register_by_number): Return a ref.
4352 (find_regno): Use references.
4353 (register_size): Likewise.
4354 (register_data): Likewise.
4355 * tdesc.c (target_desc::~target_desc): Remove free calls.
4356 (target_desc::operator==): Use std::vector compare.
4357 (init_target_desc): Use reference.
4358 (tdesc_create_reg): Use reg constructors.
4359 * tdesc.h (struct target_desc): Replace pointer with object.
4360
dff7492c
AH
43612018-03-23 Alan Hayward <alan.hayward@arm.com>
4362
4363 * regcache.c (find_register_by_number): Make static.
4364 (find_regno): Use find_register_by_number
4365 * regcache.h (struct reg): Remove declaration.
4366
d80e5242
AH
43672018-03-23 Alan Hayward <alan.hayward@arm.com>
4368
4369 * tdesc.c (target_desc::~target_desc): Move to here.
4370 (target_desc::operator==): Likewise.
4371 * tdesc.h (target_desc::~target_desc): Move from here.
4372 (target_desc::operator==): Likewise.
4373
f69c5afb
AA
43742018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
4375
4376 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
4377
ce29f843
AA
43782018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4379
4380 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
4381 S390_TDESC_GS.
4382 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
4383 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
4384 and init_registers_s390_gs_linux64.
4385
c49bd90b
AA
43862018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4387
4388 * linux-s390-low.c (s390_fill_gs): Remove function.
4389 (s390_fill_gsbc): Remove function.
4390 (s390_regsets): Set fill functions for the guarded storage regsets
4391 to NULL.
4392
7edb9bd3
AA
43932018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4394
4395 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
4396 the word size. Add comment.
4397 (s390_get_wordsize): New function.
4398 (s390_arch_setup): No longer select a temporary tdesc to fetch the
4399 pswm with it. Instead, use s390_get_wordsize to determine the
4400 word size first and derive the correct tdesc from that directly.
4401
39be3c7e
SM
44022018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
4403
4404 * Makefile.in: Include silent-rules.mk.
4405 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
4406 (COMPILE): Add ECHO_CXX.
4407 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
4408 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
4409 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
4410 (version-generated.c): Add ECHO_GEN.
4411 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
4412 (IPAGENT_COMPILE): Add ECHO_CXX.
4413 (%-generated.c): Add ECHO_REGDAT.
4414
3ae9ce5d
TT
44152018-03-14 Tom Tromey <tom@tromey.com>
4416
4417 PR cli/14977:
4418 * ax.c (ax_printf): Special case for NULL.
4419
e6a58aa8
SM
44202018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4421
4422 * linux-low.c (linux_qxfer_libraries_svr4): Use
4423 xml_escape_text_append.
4424
f6e8a41e
SM
44252018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4426
4427 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
4428
b9671caf
SM
44292018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4430
4431 * server.c (handle_general_set): Remove unnecessary xstrdup.
4432
e80aaf61
SM
44332018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4434
4435 * server.c (parse_debug_format_options): Adjust to
4436 delim_string_to_char_ptr_vec changes.
4437 * thread-db.c (thread_db_load_search): Adjust to
4438 dirnames_to_char_ptr_vec changes.
4439
b1223e78
MM
44402018-03-01 Markus Metzger <markus.t.metzger@intel.com>
4441
4442 * target.h (target_enable_btrace, target_disable_btrace)
4443 (target_read_btrace, target_read_btrace_conf): Turn macro into
4444 inline function. Throw error if target method is not defined.
4445 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
4446 check for btrace target method. Be prepared to handle exceptions
4447 from btrace target methods.
4448
81561546
SDJ
44492018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4450
4451 * server.c (captured_main): Change order of error message printed
4452 when the current working directory cannot be found.
4453
25e3c82c
SDJ
44542018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4455
4456 * server.c: Include "filenames.h" and "pathstuff.h".
4457 (program_name): Delete variable.
4458 (program_path): New anonymous class.
4459 (get_exec_wrapper): Use "program_path" instead of
4460 "program_name".
4461 (handle_v_run): Likewise.
4462 (captured_main): Likewise.
4463 (process_serial_event): Likewise.
4464
b4987c95
SDJ
44652018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4466
4467 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
4468 (OBJS): Add "pathstuff.o".
4469 * server.c (current_directory): New global variable.
4470 (captured_main): Initialize "current_directory".
4471
f46cd62a
AH
44722018-02-26 Alan Hayward <alan.hayward@arm.com>
4473
4474 * tdesc.c: Use common/tdesc.h.
4475 * tdesc.h: Likewise.
4476
a543c5ca
AH
44772018-02-20 Alan Hayward <alan.hayward@arm.com>
4478 Simon Marchi <simon.marchi@ericsson.com>
4479
4480 * Makefile.in: Switch order of make rules.
4481
b5884fa7
AH
44822018-02-19 Alan Hayward <alan.hayward@arm.com>
4483
4484 * Makefile.in: Add common directory in build.
4485 * configure.ac: Add common reference.
4486 * configure: Regenerate.
4487
de6242d3
MM
44882018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4489
4490 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
4491 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
4492 * spu-low.c (spu_target_ops): Likewise.
4493 * win32-low.c (win32_target_ops): Likewise.
4494 * server.c (supported_btrace_packets): Report packets unconditionally.
4495 * target.h (target_ops) <supports_btrace>: Remove.
4496 (target_supports_btrace): Remove.
4497
9ee23a85
MM
44982018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4499
4500 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
4501 (handle_btrace_disable): Change return type to void. Use exceptions
4502 to report errors.
4503 (handle_btrace_general_set): Catch exception and copy message to
4504 return message.
4505
8ce47547
TT
45062018-02-08 Tom Tromey <tom@tromey.com>
4507
4508 * linux-low.c (install_software_single_step_breakpoints): Use
4509 make_scoped_restore.
4510 * inferiors.c (make_cleanup_restore_current_thread): Remove.
4511 (do_restore_current_thread_cleanup): Remove.
4512 * gdbthread.h (make_cleanup_restore_current_thread): Don't
4513 declare.
4514
45dd3607
TT
45152018-02-08 Tom Tromey <tom@tromey.com>
4516
4517 * mem-break.c (set_raw_breakpoint_at): Use
4518 gdb::unique_xmalloc_ptr.
4519
e671cd59
PA
45202018-01-30 Pedro Alves <palves@redhat.com>
4521
4522 PR gdb/13211
4523 * target.c (target_terminal::terminal_state): Rename to ...
4524 (target_terminal::m_terminal_state): ... this.
4525
a0aad537
JC
45262018-01-19 James Clarke <jrtc27@jrtc27.com>
4527
4528 * linux-low.c (handle_extended_wait): Surround call to
4529 thread_db_notice_clone with #ifdef USE_THREAD_DB.
4530
4d9b86e1
SM
45312018-01-17 Simon Marchi <simon.marchi@ericsson.com>
4532
4533 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
4534 linux_ptrace_attach_fail_reason_string now returning an
4535 std::string.
4536 (linux_attach): Likewise.
4537 * thread-db.c (attach_thread): Likewise.
4538
f517c180
EA
45392018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
4540
4541 PR gdb/21559
4542 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
4543 checking for fs_base/gs_base fields in struct user_regs_struct.
4544 * configure: Regenerate.
4545
9a70f35c
YQ
45462018-01-16 Yao Qi <yao.qi@linaro.org>
4547
4548 PR gdb/18749
4549 * linux-low.c (fetch_register): Call supply_register instead of
4550 error.
4551
605fd3c6
YQ
45522018-01-08 Yao Qi <yao.qi@linaro.org>
4553 Simon Marchi <simon.marchi@ericsson.com>
4554
4555 * Makefile.in (OBS): Remove selftest.o.
4556 * configure.ac: Set srv_selftest_objs if $development is true.
4557 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
4558 * configure: Re-generated.
4559 * server.c (captured_main): Wrap variable selftest_filter with
4560 GDB_SELF_TEST.
4561
2cc05030
SM
45622018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4563
4564 * server.c (parse_debug_format_options): Return std::string.
4565 (handle_monitor_command, captured_main): Adjust.
4566
e379cee6
PA
45672018-01-05 Pedro Alves <palves@redhat.com>
4568
4569 PR gdb/18653
4570 * server.c (captured_main): Pass quiet=false to
4571 save_original_signals_state.
4572
82e1e79a
JB
45732018-01-01 Joel Brobecker <brobecker@adacore.com>
4574
4575 * gdbreplay.c (gdbreplay_version): Update copyright year in
4576 version message.
4577 * server.c (gdbserver_version): Likewise.
4578
8e481c3b
TT
45792017-12-08 Tom Tromey <tom@tromey.com>
4580
4581 * ax.c (ax_printf): Update.
4582
a8806230
YQ
45832017-12-07 Yao Qi <yao.qi@linaro.org>
4584
4585 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
4586 aarch64_linux_read_description.
4587 * linux-amd64-ipa.c (idx2mask): New array.
4588 (get_ipa_tdesc): Move idx2mask out.
4589 (initialize_low_tracepoint): Initialize target descriptions.
4590 * linux-i386-ipa.c (idx2mask): New array.
4591 (get_ipa_tdesc): Move idx2mask out.
4592 (initialize_low_tracepoint): Initialize target descriptions.
4593
d4a0e8b5
SM
45942017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
4595
4596 * tdesc.c (struct tdesc_type): Change return type.
4597 (tdesc_add_flag): Change parameter type.
4598 (tdesc_add_bitfield): Likewise.
4599 (tdesc_add_field): Likewise.
4600 (tdesc_set_struct_size): Likewise.
4601
798a7429
SM
46022017-12-05 Simon Marchi <simon.marchi@ericsson.com>
4603
4604 * regcache.c (registers_to_string): Remove unused variable.
4605
c0e15c9b
SM
46062017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4607
4608 * inferiors.c (for_each_inferior_with_data): Remove.
4609 * inferiors.h (for_each_inferior_with_data): Remove.
4610 * server.c (handle_qxfer_threads_worker): Change parameter type.
4611 (handle_qxfer_threads_proper): Use for_each_thread.
4612
f0045347
SM
46132017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4614
4615 * inferiors.c (for_each_inferior): Remove.
4616 (clear_inferiors): Use for_each_thread.
4617 * inferiors.h (for_each_inferior): Remove.
4618 * linux-low.c (linux_wait_for_event_filtered): Use
4619 for_each_thread.
4620 (linux_stabilize_threads): Likewise.
4621 * regcache.c (regcache_release): Likewise.
4622 * server.c (gdb_wants_all_threads_stopped): Likewise.
4623 (clear_pending_status_callback): Remove.
4624 (handle_status): Use for_each_thread.
4625 (captured_main): Likewise.
4626 * win32-low.c (child_init_thread_list): Likewise.
4627 (win32_clear_inferiors): Likewise.
4628 (fake_breakpoint_event): Likewise.
4629
9521758b
SM
46302017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4631
4632 * inferiors.h (find_inferior): Remove.
4633 * inferiors.c (find_inferior): Remove.
4634
8f86d7aa
SM
46352017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4636
4637 * linux-low.c (resume_status_pending_p): Update comment.
4638 (need_step_over_p): Update comment.
4639
e2b44075
SM
46402017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4641
4642 * linux-low.c (proceed_one_lwp): Return void, change parameter
4643 type.
4644 (unsuspend_and_proceed_one_lwp): Likewise.
4645 (proceed_all_lwps): Use for_each_thread.
4646 (unstop_all_lwps): Likewise.
4647
c80825ff
SM
46482017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4649
4650 * linux-low.c (linux_resume_one_thread): Return void, take
4651 parameter directly.
4652 (linux_resume): Use for_each_thread.
4653
df3e4dbe
SM
46542017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4655
4656 * linux-low.c (send_sigstop_callback): Return void, change
4657 parameter type. Rename to...
4658 (send_sigstop): ... this.
4659 (suspend_and_send_sigstop_callback): Return void, change parameter
4660 type. Rename to...
4661 (suspend_and_send_sigstop): ... this.
4662 (stop_all_lwps): Use for_each_thread.
4663
5a6b0a41
SM
46642017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4665
4666 * linux-low.c (lwp_running): Return bool, remove unused
4667 argument.
4668 (linux_stabilize_threads): Use find_thread.
4669
39a64da5
SM
46702017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4671
4672 * linux-low.c (select_singlestep_lwp_callback): Remove.
4673 (count_events_callback): Remove.
4674 (select_event_lwp_callback): Remove.
4675 (select_event_lwp): Use find_thread/for_each_thread.
4676
a1385b7b
SM
46772017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4678
4679 * linux-low.c (not_stopped_callback): Return bool, take filter
4680 argument directly.
4681 (linux_wait_for_event_filtered): Use find_thread.
4682 (linux_wait_1): Likewise.
4683
454296a2
SM
46842017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4685
4686 * linux-low.c (same_lwp): Remove.
4687 (find_lwp_pid): Use find_thread.
4688
6b2a85da
SM
46892017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4690
4691 * linux-low.c (delete_lwp_callback): Remove.
4692 (linux_mourn): Use for_each_thread.
4693
798a38e8
SM
46942017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4695
4696 * linux-low.c (linux_detach_lwp_callback): Return void, remove
4697 args parameter, don't check for pid.
4698 (linux_detach): Use for_each_thread.
4699
e4eb0dec
SM
47002017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4701
4702 * linux-low.c (struct counter): Remove.
4703 (second_thread_of_pid_p): Remove.
4704 (last_thread_of_process_p): Use find_thread.
4705
83e1b6c1
SM
47062017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4707
4708 * inferiors.c (find_inferior_in_random): Remove.
4709 * inferiors.h (find_inferior_in_random): Remove.
4710 * linux-low.c (status_pending_p_callback): Return bool, accept
4711 parameter ptid directly.
4712 (linux_wait_for_event_filtered): Use find_thread_in_random.
4713 (linux_wait_1): Likewise.
4714
8dc7b443
SM
47152017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4716
4717 * inferiors.c (find_inferior_id): Remove.
4718 (find_thread_ptid): Move implemention from find_inferior_id to
4719 here.
4720 * inferiors.h (find_inferior_id): Remove.
4721 * server.c (handle_status): Use find_thread_ptid.
4722 (process_serial_event): Likewise.
4723 * thread-db.c (find_one_thread): Likewise.
4724 (thread_db_thread_handle): Likewise.
4725 * win32-low.c (thread_rec): Likewise.
4726 (child_delete_thread): Likewise.
4727 (win32_thread_alive): Likewise.
4728 (get_child_debug_event): Likewise.
4729
da25033c
SM
47302017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4731
4732 * linux-mips-low.c (update_watch_registers_callback): Return
4733 void, remove pid_p parameter, don't check for pid.
4734 (mips_insert_point, mips_remove_point): Use for_each_thread.
4735
c91bb56b
SM
47362017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4737
4738 * lynx.low (lynx_delete_thread_callback): Remove.
4739 (lynx_mourn): Use for_each_thread.
4740
634a3254
SM
47412017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4742
4743 * regcache.c (regcache_invalidate_one): Remove.
4744 (regcache_invalidate_pid): use for_each_thread.
4745
41272101
TT
47462017-11-26 Tom Tromey <tom@tromey.com>
4747
4748 * linux-low.c (linux_create_inferior): Update.
4749
f5291a6f
UW
47502017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
4751
4752 * spu-low.c (spu_create_inferior): Fix typo in argument name.
4753
6654d750
AH
47542017-11-24 Alan Hayward <alan.hayward@arm.com>
4755
4756 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
4757 * linux-aarch64-low.c (initialize_low_arch): Call init func.
4758 * linux-aarch64-tdesc-selftest.c: New file.
4759 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
4760
47612017-11-24 Alan Hayward <alan.hayward@arm.com>
4762
4763 * configure.srv: Add new file.
4764 * linux-aarch64-low.c (initialize_low_arch): Call init func.
4765 * linux-aarch64-tdesc-selftest.c: New file.
4766 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
4767
49bdb7ee
AH
47682017-11-24 Alan Hayward <alan.hayward@arm.com>
4769
4770 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
4771 * linux-aarch64-low.c (initialize_low_arch): Remove init.
4772 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
4773
d6d7ce56
AH
47742017-11-24 Alan Hayward <alan.hayward@arm.com>
4775
4776 * configure.srv: Add new files.
4777 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
4778 aarch64_linux_read_description.
4779 * linux-aarch64-low.c (aarch64_linux_read_description):
4780 Merge with aarch64_arch_setup.
4781 (aarch64_arch_setup): Call aarch64_linux_read_description.
4782 * linux-aarch64-tdesc.c: New file.
4783 * linux-aarch64-tdesc.h: New file.
4784
506fe5f4
YQ
47852017-11-24 Yao Qi <yao.qi@linaro.org>
4786
4787 * configure.srv: Set $srv_regobj for tic6x-linux.
4788 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
4789 (tic6x_read_description): Move some code to tic6x_arch_setup.
4790 (tic6x_tdesc_test): New function.
4791 (initialize_low_arch): Call selftests::register_test.
4792
29f9a567
YQ
47932017-11-22 Yao Qi <yao.qi@linaro.org>
4794
4795 * remote-utils.c (prepare_resume_reply): Use memcpy.
4796
578290ec
SM
47972017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4798
4799 * linux-low.c (kill_one_lwp_callback): Return void, take
4800 argument directly, don't filter on pid.
4801 (linux_kill): Use for_each_thread.
4802
eca55aec
SM
48032017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4804
4805 * linux-low.c (need_step_over_p): Return bool, remove dummy
4806 argument.
4807 (linux_resume, proceed_all_lwps): Use find_thread.
4808
25c28b4d
SM
48092017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4810
4811 * linux-low.c (resume_status_pending_p): Return bool, remove
4812 flag_p argument.
4813 (linux_resume): Use find_thread.
4814
5fdda392
SM
48152017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4816
4817 * linux-low.c (struct thread_resume_array): Remove.
4818 (linux_set_resume_request): Return void, take arguments
4819 directly.
4820 (linux_resume): Use for_each_thread.
4821
fcb056a5
SM
48222017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4823
4824 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
4825 return bool, remove data argument.
4826 (linux_stabilize_threads): Use find_thread.
4827
139720c5
SM
48282017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4829
4830 * linux-low.c (unsuspend_one_lwp): Remove.
4831 (unsuspend_all_lwps): Use for_each_thread, inline code from
4832 unsuspend_one_lwp.
4833
6d1e5673
SM
48342017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4835
4836 * gdbthread.h (find_thread): Add overload with ptid_t filter.
4837 * linux-low.c (struct iterate_over_lwps_args): Remove.
4838 (iterate_over_lwps_filter): Remove.
4839 (iterate_over_lwps): Use find_thread.
4840
bbf550d5
SM
48412017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4842
4843 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
4844 (linux_handle_new_gdb_connection): Use for_each_thread, inline
4845 code from reset_lwp_ptrace_options_callback.
4846
00192f77
SM
48472017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4848
4849 * linux-arm-low.c (struct update_registers_data): Remove.
4850 (update_registers_callback): Return void, take arguments
4851 directly, don't check thread's pid.
4852 (arm_insert_point, arm_remove_point): Use for_each_thread.
4853
2bee2b6c
SM
48542017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4855
4856 * win32-low.c (continue_one_thread): Return void, take argument
4857 directly.
4858 (child_continue): Use for_each_thread.
4859
0b360f19
SM
48602017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4861
4862 * win32-i386-low.c (update_debug_registers_callback): Rename
4863 to ...
4864 (update_debug_registers): ... this, return void, remove pid_p arg.
4865 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
4866
f27866ba
SM
48672017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4868
4869 * inferiors.h (struct process_info): Add constructor, initialize
4870 fields..
4871 <syscalls_to_catch>: Change type to std::vector<int>.
4872 * inferiors.c (add_process): Allocate process_info with new.
4873 (remove_process): Free process_info with delete.
4874 * linux-low.c (handle_extended_wait): Adjust.
4875 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
4876 * server.c (handle_general_set): Adjust.
4877
e849ea89
PA
48782017-11-16 Pedro Alves <palves@redhat.com>
4879
4880 * remote-utils.c (remote_close): Block SIGIO signals instead of
4881 uninstalling the SIGIO handler.
4882
1d0aa65c
AH
48832017-11-16 Alan Hayward <alan.hayward@arm.com>
4884
4885 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
4886
3491a34c
YQ
48872017-11-16 Yao Qi <yao.qi@linaro.org>
4888
4889 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
4890 (tic6x_store_gregset): Likewise.
4891 (tic6x_usrregs_info): Move it up.
4892
a602f924
AH
48932017-11-15 Alan Hayward <alan.hayward@arm.com>
4894
4895 * Makefile.in: Update arch rules.
4896 * configure.srv: Explicitly mark arch/ files.
4897
5616b6c3
AS
48982017-11-13 Andreas Schwab <schwab@suse.de>
4899
4900 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
4901 function.
4902 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4903
d1928160
PA
49042017-11-06 Pedro Alves <palves@redhat.com>
4905
4906 * config.in, configure: Regenerate.
4907
bac608e7
SM
49082017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4909
4910 * target.c (struct thread_search): Remove.
4911 (thread_search_callback): Remove.
4912 (prepare_to_access_memory): Use for_each_thread instead of
4913 find_inferior. Inline code from thread_search_callback.
4914
eaddb425
SM
49152017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4916
4917 * server.c (struct visit_actioned_threads_data): Remove.
4918 (visit_actioned_threads): Change prototype to take arguments
4919 directly.
4920 (resume): Use find_thread instead of find_inferior.
4921
99078d34
SM
49222017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4923
4924 * server.c (queue_stop_reply_callback): Change prototype, return
4925 void.
4926 (find_status_pending_thread_callback): Remove.
4927 (handle_status): Replace find_inferior with find_thread and
4928 for_each_thread.
4929
cc628f3d
AH
49302017-10-25 Alan Hayward <alan.hayward@arm.com>
4931
4932 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
4933 with REGNO.
4934 (aarch64_store_gregset): Likewise.
4935 (aarch64_fill_fpregset): Likewise.
4936 (aarch64_store_fpregset): Likewise.
4937
4d3bb80e
SM
49382017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4939
4940 * gdbthread.h (find_thread, for_each_thread): New functions.
4941 * inferiors.c (thread_of_pid): Remove.
4942 (find_any_thread_of_pid): Use find_thread.
4943 * linux-low.c (num_lwps): Use for_each_thread.
4944
7a7cdfa0
YQ
49452017-10-17 Yao Qi <yao.qi@linaro.org>
4946
4947 * Makefile.in: Remove one rule.
4948 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
4949
e675d170
YQ
49502017-10-17 Yao Qi <yao.qi@linaro.org>
4951
4952 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
4953 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
4954
7eb4e0f9
YQ
49552017-10-17 Yao Qi <yao.qi@linaro.org>
4956
4957 * configure.srv: Rename arm.o with arch/arm.o.
4958
60d6cfc9
YQ
49592017-10-17 Yao Qi <yao.qi@linaro.org>
4960
4961 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
4962 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
4963 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
4964 (arch-i386.o, arch-amd64.o): Remove rules.
4965 (arch/%.o): New rule.
4966 Update POSTCOMPILE and COMPILE.pre.
4967 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4968 * configure: Re-generated.
4969 * configure.srv: Replace arch-i386.o with arch/i386.o.
4970 Replace arch-amd64.o with arch/amd64.o.
4971
5bfda255
YQ
49722017-10-16 Yao Qi <yao.qi@linaro.org>
4973
4974 * configure: Regenerated.
4975
9c80ecd6
SM
49762017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4977
4978 * inferiors.h: (struct inferior_list): Remove.
4979 (struct inferior_list_entry); Remove.
4980 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
4981 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
4982 get_first_inferior): Remove.
4983 (for_each_inferior, for_each_inferior_with_data, find_inferior,
4984 find_inferior_id, find_inferior_in_random): Change signature.
4985 * inferiors.c (all_threads): Change type to
4986 std::list<thread_info *>.
4987 (get_thread): Remove macro.
4988 (find_inferior, find_inferior_id): Change signature, implement
4989 using find_thread.
4990 (find_inferior_in_random): Change signature, implement using
4991 find_thread_in_random.
4992 (for_each_inferior, for_each_inferior_with_data): Change
4993 signature, implement using for_each_thread.
4994 (add_inferior_to_list, remove_inferior): Remove.
4995 (add_thread, get_first_thread, thread_of_pid,
4996 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
4997 (get_first_inferior, one_inferior_p, clear_inferior_list):
4998 Remove.
4999 (clear_inferiors, get_thread_process): Update.
5000 * gdbthread.h: Include <list>.
5001 (struct thread_info) <entry>: Remove field.
5002 <id>: New field.
5003 (all_threads): Change type to std::list<thread_info *>.
5004 (get_first_inferior): Add doc.
5005 (find_thread, for_each_thread, find_thread_in_random): New
5006 functions.
5007 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
5008 * linux-arm-low.c (update_registers_callback): Update.
5009 * linux-low.c (second_thread_of_pid_p): Update.
5010 (kill_one_lwp_callback, linux_detach_lwp_callback,
5011 delete_lwp_callback, status_pending_p_callback, same_lwp,
5012 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
5013 iterate_over_lwps, not_stopped_callback,
5014 resume_stopped_resumed_lwps, count_events_callback,
5015 select_singlestep_lwp_callback, select_event_lwp_callback,
5016 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
5017 suspend_and_send_sigstop_callback, wait_for_sigstop,
5018 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
5019 lwp_running, linux_set_resume_request, resume_status_pending_p,
5020 need_step_over_p, start_step_over, linux_resume_one_thread,
5021 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
5022 reset_lwp_ptrace_options_callback): Update.
5023 * linux-mips-low.c (update_watch_registers_callback): Update.
5024 * regcache.c (regcache_invalidate_one, regcache_invalidate):
5025 Update.
5026 (free_register_cache_thread_one): Remove.
5027 (regcache_release): Update.
5028 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
5029 handle_qxfer_threads_worker): Update.
5030 (handle_query): Update, use list iterator.
5031 (visit_actioned_threads, handle_pending_status,
5032 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
5033 clear_pending_status_callback, set_pending_status_callback,
5034 find_status_pending_thread_callback, handle_status,
5035 process_serial_event): Update.
5036 * target.c (thread_search_callback): Update.
5037 * thread-db.c (thread_db_get_tls_address): Update.
5038 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
5039 Update.
5040 * win32-i386-low.c (update_debug_registers_callback): Update.
5041 * win32-low.c (delete_thread_info, child_delete_thread,
5042 continue_one_thread, suspend_one_thread,
5043 get_child_debug_event): Adjust.
5044
9179355e
SM
50452017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5046
5047 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
5048 * inferiors.h: Include <list>.
5049 (struct process_info) <entry>: Remove field.
5050 <pid>: New field.
5051 (pid_of): Change macro to function.
5052 (ptid_of, lwpid_of): Remove macro.
5053 (all_processes): Change type to std::list<process_info *>.
5054 (ALL_PROCESSES): Remove macro.
5055 (for_each_process, find_process): New function.
5056 * inferiors.c (all_processes): Change type to
5057 std::list<process_info *>.
5058 (find_thread_process): Adjust.
5059 (add_process): Likewise.
5060 (remove_process): Likewise.
5061 (find_process_pid): Likewise.
5062 (get_first_process): Likewise.
5063 (started_inferior_callback): Remove.
5064 (have_started_inferiors_p): Adjust.
5065 (attached_inferior_callback): Remove.
5066 (have_attached_inferiors_p): Adjust.
5067 * linux-low.c (check_zombie_leaders): Likewise.
5068 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
5069 (x86_linux_update_xmltarget): Adjust.
5070 * server.c (handle_query): Likewise.
5071 (gdb_reattached_process): Remove.
5072 (handle_status): Adjust.
5073 (kill_inferior_callback): Likewise.
5074 (detach_or_kill_inferior): Remove.
5075 (print_started_pid): Likewise.
5076 (print_attached_pid): Likewise.
5077 (detach_or_kill_for_exit): Update.
5078 (process_serial_event): Likewise.
5079 * linux-arm-low.c (arm_new_fork): Likewise.
5080
c9cb8905
SM
50812017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5082
5083 * dll.h: Include <list>.
5084 (struct dll_info): Add constructor.
5085 <entry>: Remove field.
5086 (all_dlls): Change type to std::list<dll_info>.
5087 * dll.c: Include <algorithm>.
5088 (get_dll): Remove macro.
5089 (all_dlls): Change type to std::list<dll_info *>.
5090 (free_one_dll): Remove.
5091 (match_dll): Likewise.
5092 (loaded_dll): Adjust.
5093 (unloaded_dll): Adjust to all_dlls type change, use
5094 std::find_if. Inline code from match_dll.
5095 (clear_dlls): Adjust to all_dlls type change.
5096 * server.c (emit_dll_description): Remove.
5097 (handle_qxfer_libraries): Adjust to all_dlls type change,
5098 integrate emit_dll_description's functionality.
5099
04ec7890
SM
51002017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5101
5102 * linux-low.h (struct linux_target_ops) <delete_process>: New
5103 field.
5104 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
5105 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
5106 (struct linux_target_ops): Add delete_process callback.
5107 * linux-arm-low.c (arm_delete_process): New.
5108 (struct linux_target_ops): Add delete_process callback.
5109 * linux-bfin-low.c (struct linux_target_ops): Likewise.
5110 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
5111 * linux-m32r-low.c (struct linux_target_ops): Likewise.
5112 * linux-mips-low.c (mips_linux_delete_process): New.
5113 (struct linux_target_ops): Add delete_process callback.
5114 * linux-ppc-low.c (struct linux_target_ops): Likewise.
5115 * linux-s390-low.c (struct linux_target_ops): Likewise.
5116 * linux-sh-low.c (struct linux_target_ops): Likewise.
5117 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
5118 * linux-tile-low.c (struct linux_target_ops): Likewise.
5119 * linux-x86-low.c (x86_linux_delete_process): New.
5120 (struct linux_target_ops): Add delete_process callback.
5121 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
5122
466eecee
SM
51232017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5124
5125 * linux-aarch64-low.c (the_low_target): Add thread delete
5126 callback.
5127 * linux-arm-low.c (arm_delete_thread): New function.
5128 (the_low_target): Add thread delete callback.
5129 * linux-bfin-low.c (the_low_target): Likewise.
5130 * linux-crisv32-low.c (the_low_target): Likewise.
5131 * linux-low.c (delete_lwp): Invoke delete_thread callback if
5132 set.
5133 * linux-low.h (struct linux_target_ops) <delete_thread>: New
5134 field.
5135 * linux-m32r-low.c (the_low_target): Add thread delete callback.
5136 * linux-mips-low.c (mips_linux_delete_thread): New function.
5137 (the_low_target): Add thread delete callback.
5138 * linux-ppc-low.c (the_low_target): Likewise.
5139 * linux-s390-low.c (the_low_target): Likewise.
5140 * linux-sh-low.c (the_low_target): Likewise.
5141 * linux-tic6x-low.c (the_low_target): Likewise.
5142 * linux-tile-low.c (the_low_target): Likewise.
5143 * linux-x86-low.c (the_low_target): Likewise.
5144 * linux-xtensa-low.c (the_low_target): Likewise.
5145
b79f7801
YZ
51462017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
5147
5148 * win32-low.c: Include "common-inferior.h".
5149
bc3b087d
SDJ
51502017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5151
5152 * inferiors.c (set_inferior_cwd): New function.
5153 * server.c (handle_general_set): Handle QSetWorkingDir packet.
5154 (handle_query): Inform that QSetWorkingDir is supported.
5155 * win32-low.c (create_process): Pass the inferior's cwd to
5156 CreateProcess.
5157
d092c5a2
SDJ
51582017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5159
5160 * inferiors.c (current_inferior_cwd): New global variable.
5161 (get_inferior_cwd): New function.
5162 * inferiors.h (struct process_info) <cwd>: New field.
5163
7da0a886
SDJ
51642017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5165
5166 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
5167 (OBS): Add gdb_tilde_expand.o.
5168
289a6840
SM
51692017-10-02 Simon Marchi <simon.marchi@ericsson.com>
5170
5171 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
5172 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
5173
256642e8
PA
51742017-09-29 Pedro Alves <palves@redhat.com>
5175
5176 * ax.c (gdb_parse_agent_expr): Constify.
5177 * ax.h (gdb_parse_agent_expr): Constify.
5178 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5179 Constify.
5180 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
5181 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
5182 * remote-utils.h (read_ptid): Constify.
5183 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
5184 (process_point_options, process_serial_event): Constify.
5185 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
5186 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
5187 (cmd_qtbuffer): Constify.
5188
5b9ca4d4
PA
51892017-09-29 Pedro Alves <palves@redhat.com>
5190
5191 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
5192 fails.
5193
94c207e0
PA
51942017-09-29 Pedro Alves <palves@redhat.com>
5195
5196 * linux-low.c (handle_extended_wait): Pass parent thread instead
5197 of process to thread_db_notice_clone.
5198 * linux-low.h (thread_db_notice_clone): Replace parent process
5199 parameter with parent thread parameter.
5200 * thread-db.c (find_one_thread): Add comment.
5201 (thread_db_notice_clone): Replace parent process parameter with
5202 parent thread parameter. Temporarily switch to the parent thread.
5203
75352e28
SDJ
52042017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
5205
5206 * gdbthread.h: Include "common-gdbthread.h".
5207 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
5208 "if" when validating the ptid.
5209 * remote-utils.c: Include "gdbthread.h".
5210 (prepare_resume_reply): Use "switch_to_thread".
5211 * target.c (done_accessing_memory): Likewise.
5212
ad339634
AA
52132017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5214
5215 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
5216 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
5217 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
5218 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
5219 s390x-gs-linux64-ipa.o to ipa_obj.
5220 * linux-s390-low.c (HWCAP_S390_GS): New define.
5221 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
5222 New functions.
5223 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
5224 (s390_arch_setup): Check for guarded-storage support and choose
5225 appropriate tdesc.
5226 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
5227 init_registers_s390x_gs_linux64.
5228 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
5229 enum value.
5230 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
5231 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
5232
cc4d742f
SM
52332017-09-22 Simon Marchi <simon.marchi@ericsson.com>
5234
5235 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
5236
f6327dcb
KB
52372017-09-21 Kevin Buettner <kevinb@redhat.com>
5238
5239 * linux-low.h (struct lwp_info): Add new field, thread_handle.
5240 (thread_db_thread_handle): Declare.
5241 * linux-low.c (linux_target_ops): Initialize thread_handle.
5242 * server.c (handle_qxfer_threads_worker): Add support for
5243 "handle" attribute.
5244 * target.h (struct target_ops): Add new function pointer,
5245 thread_handle.
5246 (target_thread_handle): Define.
5247 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
5248 field in lwp.
5249 (thread_db_thread_handle): New function.
5250
86299109
KB
52512017-09-21 Kevin Buettner <kevinb@redhat.com>
5252
5253 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
5254 * linux-low.h (thread_db_notice_clone): Declare.
5255 * thread-db.c (thread_db_notice_clone): New function.
5256
f557a88a
PA
52572017-09-21 Pedro Alves <palves@redhat.com>
5258
5259 * server.c (gdb_read_memory, handle_status, process_serial_event)
5260 (handle_serial_event, handle_target_event): Adjust to
5261 set_desired_thread prototype change.
5262 * target.c (set_desired_thread): Remove 'use_general' parameter
5263 and adjust.
5264 * target.h (set_desired_thread): Remove 'use_general' parameter.
5265
223ffa71
TT
52662017-09-20 Tom Tromey <tom@tromey.com>
5267
5268 * target.c (target_terminal::terminal_state): Define.
5269 (target_terminal::init): Rename from target_terminal_init.
5270 (target_terminal::inferior): Rename from
5271 target_terminal_inferior.
5272 (target_terminal::ours): Rename from target_terminal_ours.
5273 (target_terminal::ours_for_output, target_terminal::info): New.
5274
04fd3ba9
SM
52752017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5276
5277 * server.c (accumulate_file_name_length): Remove.
5278 (emit_dll_description): Adjust to std::string change.
5279 (handle_qxfer_libraries): Use std::string to hold document.
5280
5e187554
SM
52812017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5282
5283 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
5284 return type of xml_escape_text.
5285 * server.c (emit_dll_description): Likewise.
5286
1526853e
SM
52872017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5288
5289 * server.c (captured_main): Accept argument for --selftest.
5290 Update run_tests call.
5291 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
5292 when registering selftests.
5293
c4dfafab
SDJ
52942017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
5295
5296 * regcache.c (get_thread_regcache): Update code to use "std::vector"
5297 instead of "VEC" for "target_desc.reg_defs".
5298 (regcache_cpy): Likewise.
5299 (registers_to_string): Likewise.
5300 (registers_from_string): Likewise.
5301 (find_regno): Likewise.
5302 (supply_regblock): Likewise.
5303 (regcache_raw_read_unsigned): Likewise.
5304 * tdesc.c (init_target_desc): Likewise.
5305 (tdesc_create_reg): Likewise.
5306 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
5307 (struct target_desc) <reg_defs>: Convert to "std::vector".
5308 (target_desc): Do not initialize "reg_defs".
5309 (~target_desc): Update code to use "std::vector" instead of "VEC"
5310 for "target_desc.reg_defs".
5311 (operator==): Likewise.
5312
124aceb4
SM
53132017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5314
5315 * inferiors.h (thread_to_gdb_id): Remove.
5316 * inferiors.c (thread_to_gdb_id): Remove.
5317 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
5318 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
5319 lynx_store_registers, lynx_read_memory, lynx_write_memory):
5320 Likewise.
5321 * nto-low.c (nto_fetch_registers, nto_store_registers,
5322 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
5323
96cde54f
SM
53242017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5325
5326 * inferiors.h (gdb_id_to_thread_id): Remove.
5327 * inferiors.c (gdb_id_to_thread_id): Remove.
5328 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
5329 removal. Move pid declaration closer to where it's used.
5330
e8ca139e
SM
53312017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5332
5333 * server.c (handle_detach): New function.
5334 (process_serial_event): Move code out, call handle_detach.
5335
f8a4e119
SM
53362017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5337
5338 * server.c (require_running): Rename to ...
5339 (require_running_or_return): ... this ...
5340 (require_running_or_break): ... and this.
5341 (handle_query, process_serial_event): Adjust.
5342
0eb0a407
SM
53432017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5344
5345 * linux-low.c (linux_set_resume_request): Remove unused
5346 variables.
5347
785922a5
SM
53482017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5349
5350 * server.c (first_thread_of): Remove.
5351 (process_serial_event): Replace usage of first_thread_of with
5352 find_any_thread_of_pid.
5353 * tracepoint.c (same_process_p): Remove.
5354 (gdb_agent_about_to_close): Replace usage of same_process_p with
5355 find_any_thread_of_pid.
5356 * linux-x86-low.c (same_process_callback): Remove.
5357 (x86_arch_setup_process_callback): Replace usage of
5358 same_process_callback with find_any_thread_of_pid.
5359 * thread-db.c (any_thread_of): Remove.
5360 (switch_to_process): Replace usage of any_thread_of with
5361 find_any_thread_of_pid.
5362 * inferiors.c (thread_pid_matches_callback): Remove.
5363 (find_thread_process): Adjust to use find_any_thread_of_pid.
5364
a059f00c
SDJ
53652017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
5366
5367 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 5368 with "!VEC_empty".
a059f00c 5369
cc397f3a
SDJ
53702017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
5371
5372 * linux-low.c (handle_extended_wait): Use
5373 "allocate_target_description" instead of "XNEW".
5374 * linux-x86-low.c (initialize_low_arch): Likewise.
5375
22916b07
YQ
53762017-09-05 Yao Qi <yao.qi@linaro.org>
5377
5378 * configure.srv (srv_i386_regobj): Remove.
5379 (srv_amd64_regobj): Remove.
5380 (srv_regobj): Set it to "" for x86 non-linux targets.
5381 * linux-x86-tdesc.c (i386_linux_read_description):
5382 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
5383 (init_registers_i386): Remove the declaration.
5384 (tdesc_i386): Remove the declaration.
5385 (lynx_i386_arch_setup): Call i386_create_target_description.
5386 * nto-x86-low.c: Likewise.
5387 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
5388 [!__x86_64__]: include arch/i386.h.
5389 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
5390
38602d55
YQ
53912017-09-05 Yao Qi <yao.qi@linaro.org>
5392
5393 * configure.srv (srv_amd64_linux_xmlfiles): Remove
5394 i386/amd64-XXX-linux from it.
5395
44b886ff
YQ
53962017-09-05 Yao Qi <yao.qi@linaro.org>
5397
5398 * configure.srv: Empty srv_amd64_linux_regobj if $development is
5399 false.
5400 (ipa_amd64_linux_regobj): Remove.
5401 (ipa_x32_linux_regobj): Remove.
5402
b4570e4b
YQ
54032017-09-05 Yao Qi <yao.qi@linaro.org>
5404
5405 * Makefile.in (arch-amd64.o): New rule.
5406 * configure.srv: Append arch-amd64.o.
5407 * linux-amd64-ipa.c: Include common/x86-xstate.h.
5408 (get_ipa_tdesc): Call amd64_linux_read_description.
5409 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
5410 and init_registers_amd64_XXX.
5411 * linux-x86-low.c (x86_linux_read_description): Call
5412 amd64_linux_read_description.
5413 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
5414 (initialize_low_arch): Don't call init_registers_x32_XXX and
5415 init_registers_amd64_XXX.
5416 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
5417 and tdesc_amd64_XXX.
5418 [__x86_64__] (amd64_tdesc_test): New function.
5419 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
5420 and init_registers_amd64_XXX.
5421 * linux-x86-tdesc.c: Include arch/amd64.h.
5422 (xcr0_to_tdesc_idx): New function.
5423 (i386_linux_read_description): New function.
5424 (amd64_get_ipa_tdesc_idx): New function.
5425 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
5426 (amd64_get_ipa_tdesc): Declare.
5427
d1f28ea2
YQ
54282017-09-05 Yao Qi <yao.qi@linaro.org>
5429
5430 * configure.srv (srv_i386_linux_xmlfiles): Remove
5431 i386/i386-XXX-linux.xml from it.
5432
25a93583
YQ
54332017-09-05 Yao Qi <yao.qi@linaro.org>
5434
5435 * configure.srv: Set srv_i386_linux_regobj empty if $development
5436 is false.
5437 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
5438 initialize_low_tdesc.
5439 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
5440 with #if initialize_low_tdesc.
5441 * linux-x86-tdesc-selftest.c: New file.
5442 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
5443
5f035c07
YQ
54442017-09-05 Yao Qi <yao.qi@linaro.org>
5445
5446 * Makefile.in (arch-i386.o): New rule.
5447 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
5448 (x86_64-*-linux*): Likewise.
5449 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
5450 include arch/i386.h.
5451 (i386_linux_read_description): Remove code and call
5452 i386_create_target_description.
5453 * tdesc.c (allocate_target_description): New function.
5454 * tdesc.h (set_tdesc_architecture): Remove declaration.
5455 (set_tdesc_osabi): Likewise.
5456
0abe8a89
YQ
54572017-09-05 Yao Qi <yao.qi@linaro.org>
5458
5459 * linux-x86-tdesc.c: Don't include <inttypes.h>.
5460 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
5461 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
5462 .xmltarget.
5463 * server.c (get_features_xml): Call tdesc_get_features_xml.
5464 * tdesc.c (set_tdesc_architecture): New function.
5465 (set_tdesc_osabi): New function.
5466 (tdesc_get_features_xml): New function.
5467 (tdesc_create_feature): Add an argument.
5468 * tdesc.h (struct target_desc) <features>: New field.
5469 <arch, osabi>: New field.
5470 (~target_desc): xfree features, arch, and osabi.
5471 (target_desc::oerator==): Don't compare .xmltarget.
5472 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
5473 (set_tdesc_osabi): Likewise.
5474 (tdesc_get_features_xml): Likewise.
5475
0a188386
YQ
54762017-09-05 Yao Qi <yao.qi@linaro.org>
5477
5478 * linux-x86-tdesc.c: Include selftest.h.
5479 (i386_tdesc_test): New function.
5480 (initialize_low_tdesc): Call selftests::register_test.
5481 * tdesc.h: Include regdef.h.
5482 (target_desc): Override operator == and !=.
5483
f49ff000
YQ
54842017-09-05 Yao Qi <yao.qi@linaro.org>
5485
5486 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
5487 (ipa_obj): Likewise.
5488 * linux-i386-ipa.c: Include common/x86-xstate.h
5489 (get_ipa_tdesc): Call i386_linux_read_description.
5490 (initialize_low_tracepoint): Don't call init_registers_XXX
5491 functions, call initialize_low_tdesc instead.
5492 * linux-x86-low.c (x86_linux_read_description): Call
5493 i386_linux_read_description.
5494 (initialize_low_arch): Don't call init_registers_i386_XXX
5495 functions, call initialize_low_tdesc.
5496 * linux-x86-tdesc.c: New file.
5497 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
5498 (i386_get_ipa_tdesc_idx): Declare.
5499 (i386_get_ipa_tdesc): Declare.
5500 (initialize_low_tdesc): Declare.
5501
2b68ef2f
YQ
55022017-09-05 Yao Qi <yao.qi@linaro.org>
5503
5504 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
5505 instead of 0.
5506
f7000548
YQ
55072017-09-05 Yao Qi <yao.qi@linaro.org>
5508
5509 * Makefile.in (IPA_OBJS): Add vec-ipa.o
5510 * regcache.c (get_thread_regcache): Use VEC_length.
5511 (init_register_cache): Likewise.
5512 (regcache_cpy): Likewise.
5513 (registers_to_string): Iterate reg_defs via VEC_iterate.
5514 (find_regno): Likewise.
5515 (find_register_by_number): Use VEC_index.
5516 (register_size): Call find_register_by_number.
5517 (register_data): Call find_register_by_number.
5518 (supply_regblock): Use VEC_length.
5519 (regcache_raw_read_unsigned): Likewise.
5520 * tdesc.c (init_target_desc): Iterate reg_defs via
5521 VEC_iterate.
5522 (default_description): Update initializer.
5523 (copy_target_description): Don't update field num_registers.
5524 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
5525 <num_registers>: Remove.
5526
50a421ac
SM
55272017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5528
5529 * Makefile.in (.SECONDARY): Define target.
5530
23fdd69e
SM
55312017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5532
5533 * linux-low.c (linux_wait_1): Adjust.
5534 * server.c (queue_stop_reply_callback): Adjust.
5535
0a2dde4a
SDJ
55362017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5537
5538 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
5539 QEnvironmentUnset and QEnvironmentReset packets.
5540 (handle_query): Inform remote that QEnvironmentHexEncoded,
5541 QEnvironmentUnset and QEnvironmentReset are supported.
5542
6afd337d
SM
55432017-08-25 Simon Marchi <simon.marchi@ericsson.com>
5544
5545 * inferiors.h (inferior_target_data): Rename to ...
5546 (thread_target_data): ... this.
5547 (inferior_regcache_data): Rename to ...
5548 (thread_regcache_data): ... this.
5549 (set_inferior_regcache_data): Rename to ...
5550 (set_thread_regcache_data): ... this.
5551 * inferiors.c (inferior_target_data): Rename to ...
5552 (thread_target_data): ... this.
5553 (inferior_regcache_data): Rename to ...
5554 (thread_regcache_data): ... this.
5555 (set_inferior_regcache_data): Rename to ...
5556 (set_thread_regcache_data): ... this.
5557 (free_one_thread): Update.
5558 * linux-low.h (get_thread_lwp): Update.
5559 * regcache.c (get_thread_regcache): Update.
5560 (regcache_invalidate_thread): Update.
5561 (free_register_cache_thread): Update.
5562 * win32-i386-low.c (update_debug_registers_callback): Update.
5563 (win32_get_current_dr): Update.
5564 * win32-low.c (thread_rec): Update.
5565 (delete_thread_info): Update.
5566 (continue_one_thread): Update.
5567 (suspend_one_thread): Update.
5568
a160cc46
SM
55692017-08-24 Simon Marchi <simon.marchi@ericsson.com>
5570
5571 * inferiors.c (set_inferior_target_data): Remove.
5572 * inferiors.h (set_inferior_target_data): Remove.
5573
6d580b63
YQ
55742017-08-18 Yao Qi <yao.qi@linaro.org>
5575
5576 * Makefile.in (OBS): Add selftest.o.
5577 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
5578 * configure, config.in: Re-generated.
5579 * server.c: Include common/sefltest.h.
5580 (captured_main): Handle option --selftest.
5581
f5a29eb0
YQ
55822017-08-09 Yao Qi <yao.qi@linaro.org>
5583
5584 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
5585 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
5586 i386-avx-mpx.o and i386-mmx.o.
5587 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
5588 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
5589 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
5590 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
5591 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
5592 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
5593 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
5594 i386/amd64-avx-mpx.xml.
5595
57757c2f
YQ
55962017-08-09 Yao Qi <yao.qi@linaro.org>
5597
5598 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
5599 and x32-avx-avx512.o.
5600 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
5601 i386/x32-avx-avx512.xml.
5602
229d26fc
SM
56032017-07-26 Simon Marchi <simon.marchi@ericsson.com>
5604
5605 * tracepoint.h (enum class fast_tpoint_collect_result): New
5606 enumeration.
5607 (fast_tracepoint_collecting): Change return type to
5608 fast_tpoint_collect_result.
5609 * tracepoint.c (fast_tracepoint_collecting): Likewise.
5610 * linux-low.h: Include tracepoint.h.
5611 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
5612 fast_tpoint_collect_result.
5613 * linux-low.c (handle_tracepoints): Adjust.
5614 (linux_fast_tracepoint_collecting): Change return type to
5615 fast_tpoint_collect_result.
5616 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
5617 linux_wait_1, stuck_in_jump_pad_callback,
5618 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
5619 proceed_one_lwp): Adjust to type change.
5620
2e1e43e1
YQ
56212017-07-10 Yao Qi <yao.qi@linaro.org>
5622
5623 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
5624
adc764e7
YQ
56252017-06-29 Yao Qi <yao.qi@linaro.org>
5626
5627 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
5628 Remove.
5629 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
5630
a206891a
SM
56312017-06-20 Simon Marchi <simon.marchi@ericsson.com>
5632
5633 * Makefile.in (IPA_OBJS): Sort and format one item per line.
5634
9a6c7d9c
SDJ
56352017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5636
5637 * linux-low.c (linux_create_inferior): Adjust code to access the
5638 environment information via 'gdb_environ' class.
5639 * lynx-low.c (lynx_create_inferior): Likewise.
5640 * server.c (our_environ): Make it an instance of 'gdb_environ'.
5641 (get_environ): Return a pointer to 'our_environ'.
5642 (captured_main): Initialize 'our_environ'.
5643 * server.h (get_environ): Adjust prototype.
5644 * spu-low.c (spu_create_inferior): Adjust code to access the
5645 environment information via 'gdb_environ' class.
5646
ae3e2ccf
SM
56472017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5648
5649 * linux-low.c (linux_read_memory, linux_write_memory): Remove
5650 usage of "register" keyword.
5651
3e019bdc
SM
56522017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5653
5654 * configure: Re-generate.
5655
8465943a
SM
56562017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5657
5658 * configure: Re-generate.
5659
cf0dd6f0
SM
56602017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5661
5662 * Makefile.in (COMPILE.pre): Add "-x c++".
5663
9845682b
SDJ
56642017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
5665
5666 * fork-child.c: Conditionally include <signal.h>.
5667
aefd8b33
SDJ
56682017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5669
5670 * server.c (handle_general_set): Handle new packet
5671 "QStartupWithShell".
5672 (handle_query): Add "QStartupWithShell" to the list of supported
5673 packets.
5674 (gdbserver_usage): Add help text explaining the
5675 new "--startup-with-shell" and "--no-startup-with-shell" CLI
5676 options.
5677 (captured_main): Recognize and act upon the presence of the new
5678 CLI options.
5679
2090129c
SDJ
56802017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5681 Pedro Alves <palves@redhat.com>
5682
5683 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
5684 * configure: Regenerate.
5685 * configure.srv (srv_linux_obj): Add "fork-child.o" and
5686 "fork-inferior.o".
5687 (i[34567]86-*-lynxos*): Likewise.
5688 (spu*-*-*): Likewise.
5689 * fork-child.c: New file.
5690 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
5691 and "environ.h".
5692 (linux_ptrace_fun): New function.
5693 (linux_create_inferior): Adjust function prototype to reflect
5694 change on "target.h". Adjust function code to use
5695 "fork_inferior".
5696 (linux_request_interrupt): Delete "signal_pid".
5697 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
5698 (lynx_ptrace_fun): New function.
5699 (lynx_create_inferior): Adjust function prototype to reflect
5700 change on "target.h". Adjust function code to use
5701 "fork_inferior".
5702 * nto-low.c (nto_create_inferior): Adjust function prototype and
5703 code to reflect change on "target.h". Update comments.
5704 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
5705 "common-terminal.h" and "environ.h".
5706 (terminal_fd): Moved to fork-child.c.
5707 (old_foreground_pgrp): Likewise.
5708 (restore_old_foreground_pgrp): Likewise.
5709 (last_status): Make it global.
5710 (last_ptid): Likewise.
5711 (our_environ): New variable.
5712 (startup_with_shell): Likewise.
5713 (program_name): Likewise.
5714 (program_argv): Rename to...
5715 (program_args): ...this.
5716 (wrapper_argv): New variable.
5717 (start_inferior): Delete function.
5718 (get_exec_wrapper): New function.
5719 (get_exec_file): Likewise.
5720 (get_environ): Likewise.
5721 (prefork_hook): Likewise.
5722 (post_fork_inferior): Likewise.
5723 (postfork_hook): Likewise.
5724 (postfork_child_hook): Likewise.
5725 (handle_v_run): Update code to deal with arguments coming from the
5726 remote host. Update calls from "start_inferior" to
5727 "create_inferior".
5728 (captured_main): Likewise. Initialize environment variable. Call
5729 "have_job_control".
5730 * server.h (post_fork_inferior): New prototype.
5731 (get_environ): Likewise.
5732 (last_status): Declare.
5733 (last_ptid): Likewise.
5734 (signal_pid): Likewise.
5735 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
5736 (spu_ptrace_fun): New function.
5737 (spu_create_inferior): Adjust function prototype to reflect change
5738 on "target.h". Adjust function code to use "fork_inferior".
5739 * target.c (target_terminal_init): New function.
5740 (target_terminal_inferior): Likewise.
5741 (target_terminal_ours): Likewise.
5742 * target.h: Include <vector>.
5743 (struct target_ops) <create_inferior>: Update prototype.
5744 (create_inferior): Update macro.
5745 * utils.c (gdb_flush_out_err): New function.
5746 * win32-low.c (win32_create_inferior): Adjust function prototype
5747 and code to reflect change on "target.h".
5748
043a4934
SDJ
57492017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5750
5751 * inferiors.c (switch_to_thread): New function.
5752
15652511
SDJ
57532017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5754
5755 * Makefile.in (SFILE): Add "common/job-control.c".
5756 (OBS): Add "job-control.o".
5757
21ea5acd
SDJ
57582017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5759
5760 * Makefile: Remove "@host_makefile_frag@".
5761
e13cb306
PA
57622017-05-05 Pedro Alves <palves@redhat.com>
5763
5764 * configure: Regenerate.
5765
c94fee56
SDJ
57662017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
5767
5768 * configure: Regenerate.
5769
a0ff9e1a
SM
57702017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5771
5772 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
5773 software_single_step change of return type to
5774 std::vector<CORE_ADDR>.
5775 * linux-low.c (install_software_single_step_breakpoints):
5776 Likewise.
5777 * linux-low.h (install_software_single_step_breakpoints):
5778 Likewise.
5779
be628ab8
SDJ
57802017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
5781
5782 * remote-utils.c: Include "gdb_termios.h" instead of
5783 "terminal.h".
5784 * terminal.h: Delete file.
5785
7c5ded6a
SDJ
57862017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
5787
5788 * server.c: Include <vector>.
5789 <program_argv, wrapper_argv>: Convert to std::vector.
5790 (start_inferior): Rewrite function to use C++.
5791 (handle_v_run): Likewise. Update code that calculates the argv
5792 based on the vRun packet; use C++.
5793 (captured_main): Likewise.
5794
436252de
SM
57952017-04-06 Simon Marchi <simon.marchi@ericsson.com>
5796
5797 * server.c (handle_v_cont): Initialize thread_resume::thread
5798 with null_ptid.
5799
9bf2a700
PA
58002017-04-05 Pedro Alves <palves@redhat.com>
5801
5802 * configure: Regenerate.
5803
a121b7c1
PA
58042017-04-05 Pedro Alves <palves@redhat.com>
5805
5806 * gdbreplay.c (sync_error): Constify.
5807 * linux-x86-low.c (push_opcode): Constify.
5808
21c8a587
PA
58092017-04-05 Pedro Alves <palves@redhat.com>
5810
5811 * win32-low.c (get_child_debug_event)
5812 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
5813 Report TARGET_WAITKIND_SPURIOUS instead.
5814
fb32b4f7
PA
58152017-04-05 Pedro Alves <palves@redhat.com>
5816
e79be6e5
SM
5817 * remote-utils.c (remote_prepare, remote_open): Constify.
5818 * remote-utils.h (remote_prepare, remote_open): Constify.
5819 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 5820
65dd1e59
SM
58212017-04-04 Simon Marchi <simon.marchi@ericsson.com>
5822
5823 * Makefile.in (clean): Clear .deps.
5824
8fa5b777
SM
58252017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
5826
5827 * .gitignore: Remove generated files, replace with wildcard.
5828 * (clean): Replace removal of generated files with wildcard.
5829 (version.c): Replace with...
5830 (version-generated.c): ...this.
5831 (xml-builtin.c): Replace with...
5832 (xml-builtin-generated.c): ...this.
5833 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
5834 (%.c: *regformats*): Replace with...
5835 (%-generated.c: *regformats*): ...this.
5836
a12e714b
MF
58372017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5838
5839 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
5840 (xtensa_fill_gregset): Call collect_register_by_name for
5841 threadptr register.
5842 (xtensa_store_gregset): Call supply_register_by_name for
5843 threadptr register.
5844
1a09b50a
MF
58452017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5846
5847 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
5848 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
5849 (xtensa_store_gregset): Call supply_register for all registers in
5850 a0_regnum..a0_regnum + C0_NREGS range.
5851
1a01e7c6
SM
58522017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5853
5854 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
5855 (ax-ipa.o: ax.c): Remove.
5856 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
5857 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
5858 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
5859 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
5860 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
5861
36bc18a8
SM
58622017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5863
5864 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
5865 (print-utils-ipa.o: ../common/print-utils.c): Remove.
5866 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
5867 (errors-ipa.o: ../common/errors.c): Remove.
5868 (format-ipa.o: ../common/format.c): Remove.
5869 (common-utils-ipa.o: ../common/common-utils.c): Remove.
5870
a8ebe3d5
SM
58712017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5872
5873 * Makefile.in (%-ipa.o: %.c): New rule.
5874 (tracepoint-ipa.o: tracepoint.c): Remove.
5875 (utils-ipa.o: utils.c): Remove.
5876 (remote-utils-ipa.o: remote-utils.c): Remove.
5877 (regcache-ipa.o: regcache.c): Remove.
5878 (i386-linux-ipa.o: i386-linux.c): Remove.
5879 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
5880 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
5881 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
5882 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
5883 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
5884 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
5885 (amd64-linux-ipa.o: amd64-linux.c): Remove.
5886 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
5887 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
5888 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
5889 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
5890 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
5891 (aarch64-ipa.o: aarch64.c): Remove.
5892 (s390-linux32-ipa.o: s390-linux32.c): Remove.
5893 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
5894 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
5895 (s390-linux64-ipa.o: s390-linux64.c): Remove.
5896 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
5897 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
5898 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
5899 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
5900 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
5901 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
5902 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
5903 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
5904 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
5905 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
5906 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
5907 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
5908 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
5909 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
5910 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
5911 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
5912 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
5913 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
5914 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
5915 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
5916 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
5917 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
5918 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
5919 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
5920 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
5921 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
5922 (tdesc-ipa.o: tdesc.c): Remove.
5923 (x32-linux-ipa.o: x32-linux.c): Remove.
5924 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
5925 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
5926
50cfacb7
SM
59272017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5928
5929 * Makefile.in (%.o: ../arch/%.c): New rule.
5930 (arm.o: ../arch/arm.c): Remove.
5931 (arm-linux.o: ../arch/arm-linux.c): Remove.
5932 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
5933 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
5934
c5a22423
SM
59352017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5936
5937 * Makefile.in (%.o: ../nat/%.c): New rule.
5938 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
5939 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
5940 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
5941 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
5942 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
5943 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
5944 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
5945 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
5946 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
5947 (linux-personality.o: ../nat/linux-personality.c): Remove.
5948 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
5949 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
5950 (x86-linux.o: ../nat/x86-linux.c): Remove.
5951 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
5952 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
5953
6bda016b
SM
59542017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5955
5956 * Makefile.in (%.o: ../common/%.c): New rule.
5957 (signals.o: ../common/signals.c): Remove.
5958 (print-utils.o: ../common/print-utils.c): Remove.
5959 (rsp-low.o: ../common/rsp-low.c): Remove.
5960 (common-utils.o: ../common/common-utils.c): Remove.
5961 (posix-strerror.o: ../common/posix-strerror.c): Remove.
5962 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
5963 (vec.o: ../common/vec.c): Remove.
5964 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
5965 (xml-utils.o: ../common/xml-utils.c): Remove.
5966 (ptid.o: ../common/ptid.c): Remove.
5967 (buffer.o: ../common/buffer.c): Remove.
5968 (format.o: ../common/format.c): Remove.
5969 (filestuff.o: ../common/filestuff.c): Remove.
5970 (agent.o: ../common/agent.c): Remove.
5971 (errors.o: ../common/errors.c): Remove.
5972 (environ.o: ../common/environ.c): Remove.
5973 (common-debug.o: ../common/common-debug.c): Remove.
5974 (cleanups.o: ../common/cleanups.c): Remove.
5975 (common-exceptions.o: ../common/common-exceptions.c): Remove.
5976 (fileio.o: ../common/fileio.c): Remove.
5977 (common-regcache.o: ../common/common-regcache.c): Remove.
5978 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
5979 (new-op.o: ../common/new-op.c): Remove.
5980 (btrace-common.o: ../common/btrace-common.c): Remove.
5981
21122961
SM
59822017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5983
5984 * Makefile.in (%.o: ../target/%.c): New rule.
5985 (waitstatus.o: ../target/waitstatus.c): Remove.
5986
c362e621
SM
59872017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5988
5989 * Makefile.in
5990 (%.c: ../regformats/%.dat,
5991 (%.c: ../regformats/arm/%.dat,
5992 (%.c: ../regformats/i386/%.dat,
5993 (%.c: ../regformats/rs6000/%.dat): New rules.
5994 (aarch64.c): Remove.
5995 (reg-arm.c): Remove.
5996 (arm-with-iwmmxt.c): Remove.
5997 (arm-with-vfpv2.c): Remove.
5998 (arm-with-vfpv3.c): Remove.
5999 (arm-with-neon.c): Remove.
6000 (reg-bfin.c): Remove.
6001 (reg-cris.c): Remove.
6002 (reg-crisv32.c): Remove.
6003 (i386.c): Remove.
6004 (i386-linux.c): Remove.
6005 (i386-avx.c): Remove.
6006 (i386-avx-linux.c): Remove.
6007 (i386-avx-avx512.c): Remove.
6008 (i386-avx-avx512-linux.c): Remove.
6009 (i386-mpx.c): Remove.
6010 (i386-mpx-linux.c): Remove.
6011 (i386-avx-mpx-avx512-pku.c): Remove.
6012 (i386-avx-mpx-avx512-pku-linux.c): Remove.
6013 (i386-avx-mpx.c): Remove.
6014 (i386-avx-mpx-linux.c): Remove.
6015 (i386-mmx.c): Remove.
6016 (i386-mmx-linux.c): Remove.
6017 (reg-ia64.c): Remove.
6018 (reg-m32r.c): Remove.
6019 (reg-m68k.c): Remove.
6020 (reg-cf.c): Remove.
6021 (mips-linux.c): Remove.
6022 (mips-dsp-linux.c): Remove.
6023 (mips64-linux.c): Remove.
6024 (mips64-dsp-linux.c): Remove.
6025 (nios2-linux.c): Remove.
6026 (powerpc-32.c): Remove.
6027 (powerpc-32l.c): Remove.
6028 (powerpc-altivec32l.c): Remove.
6029 (powerpc-cell32l.c): Remove.
6030 (powerpc-vsx32l.c): Remove.
6031 (powerpc-isa205-32l.c): Remove.
6032 (powerpc-isa205-altivec32l.c): Remove.
6033 (powerpc-isa205-vsx32l.c): Remove.
6034 (powerpc-e500l.c): Remove.
6035 (powerpc-64l.c): Remove.
6036 (powerpc-altivec64l.c): Remove.
6037 (powerpc-cell64l.c): Remove.
6038 (powerpc-vsx64l.c): Remove.
6039 (powerpc-isa205-64l.c): Remove.
6040 (powerpc-isa205-altivec64l.c): Remove.
6041 (powerpc-isa205-vsx64l.c): Remove.
6042 (s390-linux32.c): Remove.
6043 (s390-linux32v1.c): Remove.
6044 (s390-linux32v2.c): Remove.
6045 (s390-linux64.c): Remove.
6046 (s390-linux64v1.c): Remove.
6047 (s390-linux64v2.c): Remove.
6048 (s390-te-linux64.c): Remove.
6049 (s390-vx-linux64.c): Remove.
6050 (s390-tevx-linux64.c): Remove.
6051 (s390x-linux64.c): Remove.
6052 (s390x-linux64v1.c): Remove.
6053 (s390x-linux64v2.c): Remove.
6054 (s390x-te-linux64.c): Remove.
6055 (s390x-vx-linux64.c): Remove.
6056 (s390x-tevx-linux64.c): Remove.
6057 (tic6x-c64xp-linux.c): Remove.
6058 (tic6x-c64x-linux.c): Remove.
6059 (tic6x-c62x-linux.c): Remove.
6060 (reg-sh.c): Remove.
6061 (reg-sparc64.c): Remove.
6062 (reg-spu.c): Remove.
6063 (amd64.c): Remove.
6064 (amd64-linux.c): Remove.
6065 (amd64-avx.c): Remove.
6066 (amd64-avx-linux.c): Remove.
6067 (amd64-avx-avx512.c): Remove.
6068 (amd64-avx-avx512-linux.c): Remove.
6069 (amd64-mpx.c): Remove.
6070 (amd64-mpx-linux.c): Remove.
6071 (amd64-avx-mpx-avx512-pku.c): Remove.
6072 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
6073 (amd64-avx-mpx.c): Remove.
6074 (amd64-avx-mpx-linux.c): Remove.
6075 (x32.c): Remove.
6076 (x32-linux.c): Remove.
6077 (x32-avx.c): Remove.
6078 (x32-avx-linux.c): Remove.
6079 (x32-avx-avx512.c): Remove.
6080 (x32-avx-avx512-linux.c): Remove.
6081 (reg-xtensa.c): Remove.
6082 (reg-tilegx.c): Remove.
6083 (reg-tilegx32.c): Remove.
6084
1672e0d9
SDJ
60852017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
6086
6087 * Makefile.in (SFILES): Add "common/environ.c".
6088 (OBJS): Add "common/environ.h".
6089
239b6d10
WT
60902017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
6091
6092 * configure.ac: Check if the fs_base and gs_base members of
6093 `struct user_regs_struct' exist.
6094 * config.in: Regenerated.
6095 * configure: Likewise.
6096
694b382c
AT
60972017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
6098
6099 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
6100 target_read_memory.
6101 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
6102 (get_next_pcs_syscall_next_pc): Likewise.
6103
7dc53023
LM
61042016-12-23 Luis Machado <lgustavo@codesourcery.com>
6105
6106 * win32-i386-low.c: Fix incorrect reference to a couple source files.
6107 * nto-x86-low.c: Likewise.
6108
ad02e4fe
SM
61092016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
6110
6111 * Makefile.in: Include disable-implicit-rules.mk.
6112
dcb07cfa
PA
61132016-11-23 Pedro Alves <palves@redhat.com>
6114
6115 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
6116 (debug_vprintf): Use std::chrono::steady_clock instead of
6117 gettimeofday. Use '.' instead of ':'.
6118 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
6119 (get_timestamp): Use std::chrono::steady_clock instead of
6120 gettimeofday.
6121
8629c02c
SM
61222016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
6123
6124 * Makefile.in: Fix whitespace formatting.
6125
b593ecca
SM
61262016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
6127
6128 * Makefile.in (SFILES, OBS): Flatten list and order
6129 alphabetically.
6130
9986ba08
PA
61312016-11-23 Pedro Alves <palves@redhat.com>
6132
6133 * event-loop.c (handle_file_event): Use warning.
6134 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
6135 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6136 Use warning.
6137
4eefa7bc
PA
61382016-11-23 Pedro Alves <palves@redhat.com>
6139
6140 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
6141 output.
6142 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
6143 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
6144 debug_printf and debug_flush for debug output.
6145 * server.c (handle_general_set): Likewise.
6146 * thread-db.c (try_thread_db_load): Use debug_printf for debug
6147 output.
6148
5443506e
SM
61492016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6150
6151 * Makefile.in (.c.o): Replace rule with ...
6152 (%.o: %.c): ... this one.
6153
3b165252
SM
61542016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6155
6156 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
6157 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
6158 make.
6159 * configure.ac: Remove checks for the make program.
6160 * configure: Re-generate.
6161
0bcda685
PA
61622016-10-28 Pedro Alves <palves@redhat.com>
6163
6164 * Makefile.in (CXX_DIALECT): Get from configure.
6165 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
6166 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
6167 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
6168 * config.in: Regenerate.
6169 * configure: Regenerate.
6170
c3805894
YQ
61712016-10-27 Yao Qi <yao.qi@linaro.org>
6172
6173 * linux-low.c (linux_supports_range_stepping): Return true if
6174 can_software_single_step return true.
6175
89342618
YQ
61762016-10-27 Yao Qi <yao.qi@linaro.org>
6177
6178 * inferiors.c (find_inferior_in_random): New function.
6179 * inferiors.h (find_inferior_in_random): Declare.
6180 * linux-low.c (linux_wait_for_event_filtered): Call
6181 find_inferior_in_random instead of find_inferior.
6182
e3652c84
YQ
61832016-10-27 Yao Qi <yao.qi@linaro.org>
6184
6185 * linux-low.c (linux_wait_1): If single-step breakpoints are
6186 inserted, remove them.
6187
5a04c4cf
PA
61882016-10-26 Pedro Alves <palves@redhat.com>
6189
6190 * linux-low.c (handle_extended_wait): Link parent/child fork
6191 threads.
6192 (linux_wait_1): Unlink them.
6193 (linux_set_resume_request): Ignore resume requests for
6194 already-resumed and unhandled fork child threads.
6195 * linux-low.h (struct lwp_info) <fork_relative>: New field.
6196 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
6197 New functions.
6198 (handle_v_requests) <vCont>: Don't call require_running.
6199 * server.h (in_queued_stop_replies): New declaration.
6200
cb93dc7f
YQ
62012016-10-24 Yao Qi <yao.qi@linaro.org>
6202
6203 PR server/20733
6204 * linux-aarch64-low.c (append_insns): Cast the return value to
6205 'uint32_t *'.
6206
a1078bea
YQ
62072016-10-10 Yao Qi <yao.qi@linaro.org>
6208
6209 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
6210
1fb77080
SDJ
62112016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
6212
6213 * target.c (target_supports_multi_process): New function, moved
6214 from...
6215 * target.h (target_supports_multi_process): ... here. Remove
6216 macro.
6217
39b5a3b9
TT
62182016-10-05 Tom Tromey <tom@tromey.com>
6219
6220 PR remote/20655:
6221 * tracepoint.c (handle_tracepoint_bkpts): Check
6222 ipa_error_tracepoint, not ipa_stopping_tracepoint.
6223
c1d0b70a
YQ
62242016-10-05 Yao Qi <yao.qi@linaro.org>
6225
6226 * configure.srv: Update the path of arm-*.xml files.
6227
0a69eedb
YQ
62282016-10-05 Terry Guo <terry.guo@arm.com>
6229 Yao Qi <yao.qi@linaro.org>
6230
6231 * Makefile.in: Adjust the path of rules.
6232 * configure.srv: Update the path of xml files.
6233 * regformats/arm-with-iwmmxt.dat: Regenerated.
6234 * regformats/arm-with-neon.dat: Likewise.
6235 * regformats/arm-with-vfpv2.dat: Likewise.
6236 * regformats/arm-with-vfpv3.dat Likewise.
6237
17e16485
YQ
62382016-09-30 Yao Qi <yao.qi@linaro.org>
6239
6240 PR gdbserver/20627
6241 * target.c (target_stop_and_wait): Don't call
6242 target_continue_no_signal, use resume_stop instead.
6243
edeeb602
YQ
62442016-09-26 Yao Qi <yao.qi@linaro.org>
6245
6246 * linux-low.c (linux_wait_1): Call debug_exit.
6247
503b1c39
PA
62482016-09-23 Pedro Alves <palves@redhat.com>
6249
6250 * Makefile.in (SFILES): Add common/new-op.c.
6251 (OBS): Add common/new-op.o.
6252 (new-op.o): New rule.
6253
74172ecf
SM
62542016-09-21 Simon Marchi <simon.marchi@ericsson.com>
6255
6256 * .gitinore: Ignore more files.
6257
fc6cda2e
YQ
62582016-09-21 Yao Qi <yao.qi@linaro.org>
6259
6260 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
6261 23.
6262
bc1e6c81
SDJ
62632016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
6264
6265 * server.c (start_inferior): Call target_mourn_inferior instead of
6266 mourn_inferior; pass ptid_t argument to it.
6267 (resume): Likewise.
6268 (handle_target_event): Likewise.
6269 * target.c (target_mourn_inferior): New function.
6270 * target.h (mourn_inferior): Delete macro.
6271
0e00e962
AA
62722016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
6273
6274 * linux-low.c (lwp_is_stepping): New function.
6275
1d8cb77d
CL
62762016-09-06 Carl Love <cel@us.ibm.com>
6277
6278 * server.c (start_inferior): Fixed comment, requested comment change
6279 didn't get updated correctly. Removed reference to ptrace () call as
6280 it is only true on Linux systems.
6281
7313bced
CL
62822016-09-06 Carl Love <cel@us.ibm.com>
6283
6284 * server.c (start_inferior): Do not call
6285 function target_post_create_inferior () if the
6286 inferior process has already exited.
6287
cf6de44d
PA
62882016-09-05 Pedro Alves <palves@redhat.com>
6289
6290 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
6291 (COMPILE.pre, CC_LD): Use CXX directly.
6292 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
6293 * acinclude.m4: Don't include build-with-cxx.m4.
6294 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
6295 * configure: Regenerate.
6296
c1da6748
AT
62972016-09-02 Akash Trehan <akash.trehan123@gmail.com>
6298
6299 PR gdb/19495
6300 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
6301 call writing data to own_buf.
6302
f2b9e3df
SDJ
63032016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
6304
6305 * target.c (mywait): Call target_wait instead of
6306 the_target->wait.
6307 (target_wait): New function.
6308
049a8570
SDJ
63092016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
6310
6311 * server.c (start_inferior): New variable 'ptid'. Replace calls
6312 to the_target->resume by target_continue{,_no_signal}, depending
6313 on the case.
6314 * target.c (target_stop_and_wait): Call target_continue_no_signal
6315 instead of the_target->resume.
6316 (target_continue): New function.
6317
3aa5cfa0
AT
63182016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
6319
6320 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
6321
754653a7
AZ
63222016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
6323
6324 PR server/20491
6325 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
6326 ps_prochandle.
6327 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
6328 * linux-arm-low.c (ps_get_thread_area): Likewise.
6329 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
6330 * linux-m68k-low.c (ps_get_thread_area): Likewise.
6331 * linux-mips-low.c (ps_get_thread_area): Likewise.
6332 * linux-nios2-low.c (ps_get_thread_area): Likewise.
6333 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
6334 * linux-x86-low.c (ps_get_thread_area): Likewise.
6335 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
6336
ed036b40
PA
63372016-08-19 Pedro Alves <palves@redhat.com>
6338
6339 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
6340
c8ef42ee
PA
63412016-08-19 Pedro Alves <palves@redhat.com>
6342
6343 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
6344 comment. Use memcpy instead of casting through unsigned long.
6345
9c235a72
PA
63462016-08-19 Pedro Alves <palves@redhat.com>
6347
6348 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
6349 allocating around 0x80000000.
6350
201506da
PA
63512016-08-19 Pedro Alves <palves@redhat.com>
6352
6353 PR gdb/20415
6354 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
6355 (x32-avx512-linux-ipa.o): New rules.
6356 * configure.ac (x86_64-*-linux*): New x32 check.
6357 * configure.srv (ipa_x32_linux_regobj): New.
6358 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
6359 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
6360 descriptions.
6361 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
6362 descriptions.
6363 * configure: Regenerate.
6364
f348d89a
PA
63652016-08-09 Pedro Alves <palves@redhat.com>
6366
6367 PR gdb/18653
6368 * Makefile.in (OBS): Add signals-state-save-restore.o.
6369 (signals-state-save-restore.o): New rule.
6370 * config.in: Regenerate.
6371 * configure: Regenerate.
6372 * linux-low.c: Include "signals-state-save-restore.h".
6373 (linux_create_inferior): Call
6374 restore_original_signals_state.
6375 * server.c: Include "dispositions-save-restore.h".
6376 (captured_main): Call save_original_signals_state.
6377
1baf5149
PA
63782016-08-05 Pedro Alves <palves@redhat.com>
6379
6380 * configure: Regenerate.
6381
fcd4a73d
YQ
63822016-08-04 Yao Qi <yao.qi@linaro.org>
6383
6384 * linux-low.c (regsets_fetch_inferior_registers): Check
6385 errno is ESRCH or not.
6386
979659d0
YQ
63872016-08-02 Yao Qi <yao.qi@linaro.org>
6388
6389 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
6390 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
6391 (thread_db_load_search): Update.
6392 (try_thread_db_load_1): Don't look for td_ta_event_addr,
6393 td_ta_set_event and td_ta_event_getmsg.
6394
6598661d
PA
63952016-07-26 Pedro Alves <palves@redhat.com>
6396
6397 PR server/20414
6398 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
6399 of unsigned long for 64-bit registers and use uint32_t instead of
6400 unsigned int for 32-bit registers.
6401
9cf12d57
PA
64022016-07-26 Pedro Alves <palves@redhat.com>
6403
6404 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
6405 to 'ptrace'.
6406
305450ed
TT
64072016-07-21 Tom Tromey <tom@tromey.com>
6408
6409 * configure: Rebuild.
6410
2583da7c
YQ
64112016-07-21 Yao Qi <yao.qi@linaro.org>
6412
6413 * mem-break.c (find_gdb_breakpoint): Cast bp to
6414 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
6415
21536b36
YQ
64162016-07-21 Yao Qi <yao.qi@linaro.org>
6417
6418 * server.c (handle_v_requests): Support s and S actions
6419 if target_supports_software_single_step return true.
6420
8901d193
YQ
64212016-07-21 Yao Qi <yao.qi@linaro.org>
6422
6423 * linux-low.c (resume_stopped_resumed_lwps): If resume request
6424 is resume_step, call maybe_hw_step.
6425 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
6426 and unstop them.
6427 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
6428 breakpoints or not.
6429 (proceed_one_lwp): If resume request is resume_step, install
6430 reinsert breakpoints and call maybe_hw_step.
6431
0e9a339e
YQ
64322016-07-21 Yao Qi <yao.qi@linaro.org>
6433
6434 * linux-low.c (proceed_one_lwp): Declare.
6435 (linux_resume_one_thread): Remove local variable 'step'.
6436 Lift code enqueue signal. Call proceed_one_lwp instead of
6437 linux_resume_one_lwp.
6438
4281b351
YQ
64392016-07-21 Yao Qi <yao.qi@linaro.org>
6440
6441 * linux-low.c (linux_resume_one_thread): Call
6442 enqueue_pending_signal.
6443
984a2c04
YQ
64442016-07-21 Yao Qi <yao.qi@linaro.org>
6445
6446 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
6447 * inferiors.c (do_restore_current_thread_cleanup): New function.
6448 (make_cleanup_restore_current_thread): Likewise.
6449 * linux-low.c (install_software_single_step_breakpoints): Call
6450 make_cleanup_restore_current_thread. Switch current_thread to
6451 thread.
6452
bec903c9
YQ
64532016-07-21 Yao Qi <yao.qi@linaro.org>
6454
6455 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
6456 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
6457 (clone_one_breakpoint): Likewise.
6458 (delete_reinsert_breakpoints): Change parameter to thread.
6459 Callers updated.
6460 (has_reinsert_breakpoints): Likewise.
6461 (uninsert_reinsert_breakpoints): Likewise.
6462 (reinsert_reinsert_breakpoints): Likewise.
6463 * mem-break.h (set_reinsert_breakpoint): Update declaration.
6464 (delete_reinsert_breakpoints): Likewise.
6465 (reinsert_reinsert_breakpoints): Likewise.
6466 (uninsert_reinsert_breakpoints): Likewise.
6467 (has_reinsert_breakpoints): Likewise.
6468
63c40ec7
YQ
64692016-07-21 Yao Qi <yao.qi@linaro.org>
6470
6471 * inferiors.c (get_thread_process): Make parameter const.
6472 * inferiors.h (get_thread_process): Update declaration.
6473 * mem-break.c (clone_all_breakpoints): Remove all parameters.
6474 Add new parameters child_thread and parent_thread. Callers
6475 updated.
6476 * mem-break.h (clone_all_breakpoints): Update declaration.
6477
9aa76cd0
YQ
64782016-07-21 Yao Qi <yao.qi@linaro.org>
6479
6480 * mem-break.c (struct breakpoint) <cond_list>: Remove.
6481 <command_list, handler>: Remove.
6482 (struct gdb_breakpoint): New.
6483 (struct other_breakpoint): New.
6484 (struct reinsert_breakpoint): New.
6485 (is_gdb_breakpoint): New function.
6486 (any_persistent_commands): Update command_list if
6487 is_gdb_breakpoint returns true.
6488 (set_breakpoint): Create breakpoints according to their types.
6489 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
6490 (set_gdb_breakpoint_1): Likewise.
6491 (set_gdb_breakpoint): Likewise.
6492 (clear_breakpoint_conditions): Change parameter type to
6493 'struct gdb_breakpoint *'.
6494 (clear_breakpoint_commands): Likewise.
6495 (clear_breakpoint_conditions_and_commands): Likewise.
6496 (add_condition_to_breakpoint): Likewise.
6497 (add_breakpoint_condition): Likewise.
6498 (add_commands_to_breakpoint): Likewise.
6499 (check_breakpoints): Check other_breakpoint.
6500 (clone_one_breakpoint): Clone breakpopint according to its type.
6501 * mem-break.h (struct gdb_breakpoint): Declare.
6502 (set_gdb_breakpoint): Update declaration.
6503 (clear_breakpoint_conditions_and_commands): Likewise.
6504 (add_breakpoint_condition): Likewise.
6505 (add_breakpoint_commands): Likewise.
6506 * server.c (process_point_options): Change parameter type to
6507 'struct gdb_breakpoint *'.
6508
811f8301
YQ
65092016-07-21 Yao Qi <yao.qi@linaro.org>
6510
6511 * mem-break.c (set_breakpoint_at): Rename it to ...
6512 (set_breakpoint_type_at): ... it.
6513 (set_breakpoint_at): Call set_breakpoint_type_at.
6514 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
6515 * mem-break.h (set_breakpoint_at): Update comments.
6516
b1c51e36
CLT
65172016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
6518
6519 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
6520 to buf parameter.
6521 (nios2_store_gregset): Likewise.
6522
ced2dffb
PA
65232016-07-01 Pedro Alves <palves@redhat.com>
6524 Antoine Tremblay <antoine.tremblay@ericsson.com>
6525
6526 * linux-low.c: Change interface to take the target lwp_info
6527 pointer directly and return void. Handle detaching from a zombie
6528 thread.
6529 (linux_detach_lwp_callback): New function.
6530 (linux_detach): Detach from the leader thread after detaching from
6531 the clone threads.
6532
2ac09a5b
YQ
65332016-06-28 Yao Qi <yao.qi@linaro.org>
6534
6535 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
6536 for variable new_offset.
6537 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6538 (aarch64_ftrace_insn_reloc_cb): Likewise.
6539 (aarch64_ftrace_insn_reloc_tb): Likewise.
6540 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
6541 PRIx64 instead of PRIx32.
6542
79e7fd4f
YQ
65432016-06-28 Yao Qi <yao.qi@linaro.org>
6544
6545 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
6546 (the_low_target): Install arm_get_syscall_trapinfo.
6547
061fc021
YQ
65482016-06-28 Yao Qi <yao.qi@linaro.org>
6549
6550 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
6551 function.
6552 (the_low_target): Install aarch64_get_syscall_trapinfo.
6553
4cc32bec
YQ
65542016-06-28 Yao Qi <yao.qi@linaro.org>
6555
6556 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
6557 Callers updated.
6558 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
6559 Remove parameter sysno.
6560 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
6561 sysret.
6562
782c1122
AA
65632016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6564
6565 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
6566 (s390_emit_ne_goto): Likewise.
6567 (s390_emit_lt_goto): Likewise.
6568 (s390_emit_le_goto): Likewise.
6569 (s390_emit_gt_goto): Likewise.
6570 (s390_emit_ge_goto): Likewise.
6571 (s390x_emit_eq_goto): Likewise.
6572 (s390x_emit_ne_goto): Likewise.
6573 (s390x_emit_lt_goto): Likewise.
6574 (s390x_emit_le_goto): Likewise.
6575 (s390x_emit_gt_goto): Likewise.
6576 (s390x_emit_ge_goto): Likewise.
6577 (s390_emit_ops_impl): Mark variable static.
6578 (s390x_emit_ops): Likewise.
6579
2e7b624b
YQ
65802016-06-17 Yao Qi <yao.qi@linaro.org>
6581
6582 * linux-low.c (handle_extended_wait): Call
6583 uninsert_reinsert_breakpoints for the parent process. Remove
6584 reinsert breakpoints from the child process. Reinsert them to
6585 the parent process when vfork is done.
6586 * mem-break.c (uninsert_reinsert_breakpoints): New function.
6587 (reinsert_reinsert_breakpoints): New function.
6588 * mem-break.h (uninsert_reinsert_breakpoints): Declare
6589 (reinsert_reinsert_breakpoints): Declare.
6590
8a81c5d7
YQ
65912016-06-17 Yao Qi <yao.qi@linaro.org>
6592
6593 * linux-low.c (handle_extended_wait): If the parent is doing
6594 step-over, remove the reinsert breakpoints from the forked child.
6595
f50bf8e5
YQ
65962016-06-17 Yao Qi <yao.qi@linaro.org>
6597
6598 * linux-low.c (unsuspend_all_lwps): Declare.
6599 (linux_low_filter_event): If thread exited, call finish_step_over.
6600 If step-over is finished, unsuspend other threads.
6601
8376a3cb
YQ
66022016-06-17 Yao Qi <yao.qi@linaro.org>
6603
6604 * linux-low.c (linux_resume_one_lwp_throw): Assert
6605 has_reinsert_breakpoints returns false.
6606 * mem-break.c (delete_disabled_breakpoints): Assert
6607 bp type isn't reinsert_breakpoint.
6608
f79b145d
YQ
66092016-06-17 Yao Qi <yao.qi@linaro.org>
6610
6611 * linux-low.c (maybe_hw_step): New function.
6612 (linux_resume_one_lwp_throw): Call maybe_hw_step.
6613 (finish_step_over): Switch current_thread to lwp temporarily,
6614 and assert has_reinsert_breakpoints returns true.
6615 (proceed_one_lwp): Call maybe_hw_step.
6616 * mem-break.c (has_reinsert_breakpoints): New function.
6617 * mem-break.h (has_reinsert_breakpoints): Declare.
6618
0ae534d2
JT
66192016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
6620
6621 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
6622
fcdad592
YQ
66232016-05-17 Yao Qi <yao.qi@linaro.org>
6624
6625 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
6626 instead of find_inferior.
6627
9e784964
YQ
66282016-05-05 Yao Qi <yao.qi@linaro.org>
6629
6630 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
6631 Initialize res to zero.
6632
cf2ebb6e
YQ
66332016-05-05 Yao Qi <yao.qi@linaro.org>
6634
6635 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
6636 to uint32_t.
6637
c1aebf87
UW
66382016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
6639
6640 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
6641 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
6642 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
6643
35fd2deb 66442016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 6645 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
6646
6647 * tracepoint.c (write_inferior_int8): New function.
6648 (cmd_qtenable_disable): Write enable flag using
6649 write_inferior_int8.
6650
484b3c32
YQ
66512016-04-25 Yao Qi <yao.qi@linaro.org>
6652
6653 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
6654 (need_step_over_p): Return zero if the LWP has pending signals
6655 can be delivered on software single step target.
6656
85ba7d86
YQ
66572016-04-25 Yao Qi <yao.qi@linaro.org>
6658
6659 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
6660 return instead of error.
6661
3539aa13
YQ
66622016-04-22 Yao Qi <yao.qi@linaro.org>
6663
6664 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
6665 to 23.
6666
5b061e98
YQ
66672016-04-22 Yao Qi <yao.qi@linaro.org>
6668
6669 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
6670 signal when stepping over breakpoint with software single
6671 step.
6672
3451269c
PA
66732016-04-21 Pedro Alves <palves@redhat.com>
6674
6675 * linux-s390-low.c (s390_collect_ptrace_register)
6676 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
6677 add casts.
6678 (s390_check_regset): Use void * instead of gdb_byte *.
6679
a2358508
PA
66802016-04-20 Pedro Alves <palves@redhat.com>
6681
6682 * configure: Renegerate.
6683
6885166d
YQ
66842016-04-20 Yao Qi <yao.qi@linaro.org>
6685
6686 * linux-aarch32-low.c: Include "arch/arm-linux.h".
6687 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
6688 number 16.
6689 (arm_store_gregset): Likewise.
6690
2b863f51
WT
66912016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
6692
6693 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
6694 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
6695 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
6696 (amd64-avx-mpx-linux.c): New rules.
6697 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
6698 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
6699 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
6700 (srv_amd64_regobj): Add amd64-avx-mpx.o.
6701 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
6702 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
6703 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
6704 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
6705 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
6706 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
6707 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
6708 * linux-x86-low.c (x86_linux_read_description): Add case for
6709 X86_XSTATE_AVX_MPX_MASK.
6710 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
6711 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
6712 init_registers_i386_avx_mpx_linux.
6713 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
6714 (initialize_low_tracepoint): Call
6715 init_registers_i386_avx_mpx_linux.
6716 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
6717 (initialize_low_tracepoint): Call
6718 init_registers_amd64_avx_mpx_linux.
6719 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
6720 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
6721 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
6722 declarations.
6723
9b30624b
PA
67242016-04-18 Pedro Alves <palves@redhat.com>
6725
6726 * configure: Regenerate.
6727
45e3745e
AT
67282016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
6729
6730 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
6731 (aarch64_emit_sub): Likewise.
6732
2afc13ff
PA
67332016-04-12 Pedro Alves <palves@redhat.com>
6734
6735 * utils.c (prepare_to_throw_exception): Delete.
6736
6e774b13
SM
67372016-04-05 Simon Marchi <simon.marchi@ericsson.com>
6738
6739 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
6740
4dca19f8
MK
67412016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
6742
6743 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
6744
d0a9981f
MK
67452016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
6746
6747 * linux-aarch64-ipa.c: Add <elf.h> include.
6748 * linux-ppc-ipa.c: Add <elf.h> include.
6749 * linux-s390-ipa.c: Add <elf.h> include.
6750
252db07e
MK
67512016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6752
6753 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
6754 (get_raw_reg_ptr): Likewise.
6755 (get_trace_state_variable_value_ptr): Likewise.
6756 (set_trace_state_variable_value_ptr): Likewise.
6757 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
6758 char *.
6759
14e2b6d9
MK
67602016-03-31 Wei-cheng Wang <cole945@gmail.com>
6761 Marcin Kościelnicki <koriakin@0x04.net>
6762
6763 PR/17221
6764 * linux-ppc-low.c (emit_insns): New function.
6765 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
6766 (ppc_emit_prologue): New function.
6767 (ppc_emit_epilogue): New function.
6768 (ppc_emit_add): New function.
6769 (ppc_emit_sub): New function.
6770 (ppc_emit_mul): New function.
6771 (ppc_emit_lsh): New function.
6772 (ppc_emit_rsh_signed): New function.
6773 (ppc_emit_rsh_unsigned): New function.
6774 (ppc_emit_ext): New function.
6775 (ppc_emit_zero_ext): New function.
6776 (ppc_emit_log_not): New function.
6777 (ppc_emit_bit_and): New function.
6778 (ppc_emit_bit_or): New function.
6779 (ppc_emit_bit_xor): New function.
6780 (ppc_emit_bit_not): New function.
6781 (ppc_emit_equal): New function.
6782 (ppc_emit_less_signed): New function.
6783 (ppc_emit_less_unsigned): New function.
6784 (ppc_emit_ref): New function.
6785 (ppc_emit_const): New function.
6786 (ppc_emit_reg): New function.
6787 (ppc_emit_pop): New function.
6788 (ppc_emit_stack_flush): New function.
6789 (ppc_emit_swap): New function.
6790 (ppc_emit_stack_adjust): New function.
6791 (ppc_emit_call): New function.
6792 (ppc_emit_int_call_1): New function.
6793 (ppc_emit_void_call_2): New function.
6794 (ppc_emit_if_goto): New function.
6795 (ppc_emit_goto): New function.
6796 (ppc_emit_eq_goto): New function.
6797 (ppc_emit_ne_goto): New function.
6798 (ppc_emit_lt_goto): New function.
6799 (ppc_emit_le_goto): New function.
6800 (ppc_emit_gt_goto): New function.
6801 (ppc_emit_ge_goto): New function.
6802 (ppc_write_goto_address): New function.
6803 (ppc_emit_ops_impl): New static variable.
6804 (ppc64v1_emit_prologue): New function.
6805 (ppc64v2_emit_prologue): New function.
6806 (ppc64_emit_epilogue): New function.
6807 (ppc64_emit_add): New function.
6808 (ppc64_emit_sub): New function.
6809 (ppc64_emit_mul): New function.
6810 (ppc64_emit_lsh): New function.
6811 (ppc64_emit_rsh_signed): New function.
6812 (ppc64_emit_rsh_unsigned): New function.
6813 (ppc64_emit_ext): New function.
6814 (ppc64_emit_zero_ext): New function.
6815 (ppc64_emit_log_not): New function.
6816 (ppc64_emit_bit_and): New function.
6817 (ppc64_emit_bit_or): New function.
6818 (ppc64_emit_bit_xor): New function.
6819 (ppc64_emit_bit_not): New function.
6820 (ppc64_emit_equal): New function.
6821 (ppc64_emit_less_signed): New function.
6822 (ppc64_emit_less_unsigned): New function.
6823 (ppc64_emit_ref): New function.
6824 (ppc64_emit_const): New function.
6825 (ppc64v1_emit_reg): New function.
6826 (ppc64v2_emit_reg): New function.
6827 (ppc64_emit_pop): New function.
6828 (ppc64_emit_stack_flush): New function.
6829 (ppc64_emit_swap): New function.
6830 (ppc64v1_emit_call): New function.
6831 (ppc64v2_emit_call): New function.
6832 (ppc64v1_emit_int_call_1): New function.
6833 (ppc64v2_emit_int_call_1): New function.
6834 (ppc64v1_emit_void_call_2): New function.
6835 (ppc64v2_emit_void_call_2): New function.
6836 (ppc64_emit_if_goto): New function.
6837 (ppc64_emit_eq_goto): New function.
6838 (ppc64_emit_ne_goto): New function.
6839 (ppc64_emit_lt_goto): New function.
6840 (ppc64_emit_le_goto): New function.
6841 (ppc64_emit_gt_goto): New function.
6842 (ppc64_emit_ge_goto): New function.
6843 (ppc64v1_emit_ops_impl): New static variable.
6844 (ppc64v2_emit_ops_impl): New static variable.
6845 (ppc_emit_ops): New function.
6846 (linux_low_target): Wire in ppc_emit_ops.
6847
a2174ba4
MK
68482016-03-31 Wei-cheng Wang <cole945@gmail.com>
6849 Marcin Kościelnicki <koriakin@0x04.net>
6850
6851 PR/17221
6852 * Makefile.in: Add powerpc-*-ipa.o
6853 * configure.srv: Add ipa_obj for powerpc*-linux.
6854 * linux-ppc-ipa.c: New file.
6855 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
6856 includes.
6857 (PPC_FIELD): New macro.
6858 (PPC_SEXT): New macro.
6859 (PPC_OP6): New macro.
6860 (PPC_BO): New macro.
6861 (PPC_LI): New macro.
6862 (PPC_BD): New macro.
6863 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
6864 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
6865 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
6866 (ppc_get_thread_area): New function.
6867 (is_elfv2_inferior): New function.
6868 (gen_ds_form): New function.
6869 (GEN_STD): New macro.
6870 (GEN_STDU): New macro.
6871 (GEN_LD): New macro.
6872 (GEN_LDU): New macro.
6873 (gen_d_form): New function.
6874 (GEN_ADDI): New macro.
6875 (GEN_ADDIS): New macro.
6876 (GEN_LI): New macro.
6877 (GEN_LIS): New macro.
6878 (GEN_ORI): New macro.
6879 (GEN_ORIS): New macro.
6880 (GEN_LWZ): New macro.
6881 (GEN_STW): New macro.
6882 (GEN_STWU): New macro.
6883 (gen_xfx_form): New function.
6884 (GEN_MFSPR): New macro.
6885 (GEN_MTSPR): New macro.
6886 (GEN_MFCR): New macro.
6887 (GEN_MTCR): New macro.
6888 (GEN_SYNC): New macro.
6889 (GEN_LWSYNC): New macro.
6890 (gen_x_form): New function.
6891 (GEN_OR): New macro.
6892 (GEN_MR): New macro.
6893 (GEN_LWARX): New macro.
6894 (GEN_STWCX): New macro.
6895 (GEN_CMPW): New macro.
6896 (gen_md_form): New function.
6897 (GEN_RLDICL): New macro.
6898 (GEN_RLDICR): New macro.
6899 (gen_i_form): New function.
6900 (GEN_B): New macro.
6901 (GEN_BL): New macro.
6902 (gen_b_form): New function.
6903 (GEN_BNE): New macro.
6904 (GEN_LOAD): New macro.
6905 (GEN_STORE): New macro.
6906 (gen_limm): New function.
6907 (gen_atomic_xchg): New function.
6908 (gen_call): New function.
6909 (ppc_relocate_instruction): New function.
6910 (ppc_install_fast_tracepoint_jump_pad): New function.
6911 (ppc_get_min_fast_tracepoint_insn_len): New function.
6912 (ppc_get_ipa_tdesc_idx): New function.
6913 (the_low_target): Wire in the new functions.
6914 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
6915 tdescs.
6916 * linux-ppc-tdesc.h: New file.
6917
a13c4696
MK
69182016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6919
6920 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6921 (alloc_jump_pad_buffer): New function.
6922 * linux-amd64-ipa.c: Add <sys/mman.h> include.
6923 (alloc_jump_pad_buffer): New function.
6924 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
6925 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6926 (alloc_jump_pad_buffer): New function.
6927 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
6928 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
6929 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
6930 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
6931
1cda1512
MK
69322016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6933
6934 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
6935 * linux-amd64-ipa.c: Likewise.
6936 * linux-i386-ipa.c: Likewise.
6937 * linux-s390-ipa.c: Likewise.
6938 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
6939 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
6940 set_trace_state_variable_value_ptr.
6941 (struct ipa_sym_addresses): Likewise.
6942 (symbol_list): Likewise.
6943 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
6944 accessing gdb_collect directly.
6945 (gdb_collect_ptr_type): New typedef.
6946 (get_raw_reg_ptr_type): New typedef.
6947 (get_trace_state_variable_value_ptr_type): New typedef.
6948 (set_trace_state_variable_value_ptr_type): New typedef.
6949 (gdb_collect_ptr): New global.
6950 (get_raw_reg_ptr): New global.
6951 (get_trace_state_variable_value_ptr): New global.
6952 (set_trace_state_variable_value_ptr): New global.
6953 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
6954 accessing get_raw_reg directly.
6955 (get_get_tsv_func_addr): Likewise for
6956 get_trace_state_variable_value_ptr.
6957 (get_set_tsv_func_addr): Likewise for
6958 set_trace_state_variable_value_ptr.
6959 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
6960
72fb5488
SM
69612016-03-30 Simon Marchi <simon.marchi@ericsson.com>
6962
6963 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
6964
28170b88
MK
69652016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6966
6967 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
6968 packets.
6969 (relocate_instruction): Remove own_buf.
6970 * server.c (own_buf): Make global.
6971 (handle_v_requests): Make global.
6972 * server.h (own_buf): New declaration.
6973 (handle_v_requests): New prototype.
6974
f39e8743
MK
69752016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6976
6977 PR 18377
6978 * linux-s390-low.c (add_insns): New function.
6979 (s390_emit_prologue): New function.
6980 (s390_emit_epilogue): New function.
6981 (s390_emit_add): New function.
6982 (s390_emit_sub): New function.
6983 (s390_emit_mul): New function.
6984 (s390_emit_lsh): New function.
6985 (s390_emit_rsh_signed): New function.
6986 (s390_emit_rsh_unsigned): New function.
6987 (s390_emit_ext): New function.
6988 (s390_emit_log_not): New function.
6989 (s390_emit_bit_and): New function.
6990 (s390_emit_bit_or): New function.
6991 (s390_emit_bit_xor): New function.
6992 (s390_emit_bit_not): New function.
6993 (s390_emit_equal): New function.
6994 (s390_emit_less_signed): New function.
6995 (s390_emit_less_unsigned): New function.
6996 (s390_emit_ref): New function.
6997 (s390_emit_if_goto): New function.
6998 (s390_emit_goto): New function.
6999 (s390_write_goto_address): New function.
7000 (s390_emit_litpool): New function.
7001 (s390_emit_const): New function.
7002 (s390_emit_call): New function.
7003 (s390_emit_reg): New function.
7004 (s390_emit_pop): New function.
7005 (s390_emit_stack_flush): New function.
7006 (s390_emit_zero_ext): New function.
7007 (s390_emit_swap): New function.
7008 (s390_emit_stack_adjust): New function.
7009 (s390_emit_set_r2): New function.
7010 (s390_emit_int_call_1): New function.
7011 (s390_emit_void_call_2): New function.
7012 (s390_emit_eq_goto): New function.
7013 (s390_emit_ne_goto): New function.
7014 (s390_emit_lt_goto): New function.
7015 (s390_emit_le_goto): New function.
7016 (s390_emit_gt_goto): New function.
7017 (s390_emit_ge_goto): New function.
7018 (s390x_emit_prologue): New function.
7019 (s390x_emit_epilogue): New function.
7020 (s390x_emit_add): New function.
7021 (s390x_emit_sub): New function.
7022 (s390x_emit_mul): New function.
7023 (s390x_emit_lsh): New function.
7024 (s390x_emit_rsh_signed): New function.
7025 (s390x_emit_rsh_unsigned): New function.
7026 (s390x_emit_ext): New function.
7027 (s390x_emit_log_not): New function.
7028 (s390x_emit_bit_and): New function.
7029 (s390x_emit_bit_or): New function.
7030 (s390x_emit_bit_xor): New function.
7031 (s390x_emit_bit_not): New function.
7032 (s390x_emit_equal): New function.
7033 (s390x_emit_less_signed): New function.
7034 (s390x_emit_less_unsigned): New function.
7035 (s390x_emit_ref): New function.
7036 (s390x_emit_if_goto): New function.
7037 (s390x_emit_const): New function.
7038 (s390x_emit_call): New function.
7039 (s390x_emit_reg): New function.
7040 (s390x_emit_pop): New function.
7041 (s390x_emit_stack_flush): New function.
7042 (s390x_emit_zero_ext): New function.
7043 (s390x_emit_swap): New function.
7044 (s390x_emit_stack_adjust): New function.
7045 (s390x_emit_int_call_1): New function.
7046 (s390x_emit_void_call_2): New function.
7047 (s390x_emit_eq_goto): New function.
7048 (s390x_emit_ne_goto): New function.
7049 (s390x_emit_lt_goto): New function.
7050 (s390x_emit_le_goto): New function.
7051 (s390x_emit_gt_goto): New function.
7052 (s390x_emit_ge_goto): New function.
7053 (s390_emit_ops): New function.
7054 (struct linux_target_ops): Fill in emit_ops hook.
7055
abd9baf9
MK
70562016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
7057
7058 PR 18377
7059 * Makefile.in: Add s390 IPA files.
7060 * configure.srv: Build IPA for s390.
7061 * linux-s390-ipa.c: New file.
7062 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
7063 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
7064 (tdesc_s390_linux32): Likewise.
7065 (init_registers_s390_linux32v1): Likewise.
7066 (tdesc_s390_linux32v1): Likewise.
7067 (init_registers_s390_linux32v2): Likewise.
7068 (tdesc_s390_linux32v2): Likewise.
7069 (init_registers_s390_linux64): Likewise.
7070 (tdesc_s390_linux64): Likewise.
7071 (init_registers_s390_linux64v1): Likewise.
7072 (tdesc_s390_linux64v1): Likewise.
7073 (init_registers_s390_linux64v2): Likewise.
7074 (tdesc_s390_linux64v2): Likewise.
7075 (init_registers_s390_te_linux64): Likewise.
7076 (tdesc_s390_te_linux64): Likewise.
7077 (init_registers_s390_vx_linux64): Likewise.
7078 (tdesc_s390_vx_linux64): Likewise.
7079 (init_registers_s390_tevx_linux64): Likewise.
7080 (tdesc_s390_tevx_linux64): Likewise.
7081 (init_registers_s390x_linux64): Likewise.
7082 (tdesc_s390x_linux64): Likewise.
7083 (init_registers_s390x_linux64v1): Likewise.
7084 (tdesc_s390x_linux64v1): Likewise.
7085 (init_registers_s390x_linux64v2): Likewise.
7086 (tdesc_s390x_linux64v2): Likewise.
7087 (init_registers_s390x_te_linux64): Likewise.
7088 (tdesc_s390x_te_linux64): Likewise.
7089 (init_registers_s390x_vx_linux64): Likewise.
7090 (tdesc_s390x_vx_linux64): Likewise.
7091 (init_registers_s390x_tevx_linux64): Likewise.
7092 (tdesc_s390x_tevx_linux64): Likewise.
7093 (have_hwcap_s390_vx): New static variable.
7094 (s390_arch_setup): Fill have_hwcap_s390_vx.
7095 (s390_get_thread_area): New function.
7096 (s390_ft_entry_gpr_esa): New const.
7097 (s390_ft_entry_gpr_zarch): New const.
7098 (s390_ft_entry_misc): New const.
7099 (s390_ft_entry_fr): New const.
7100 (s390_ft_entry_vr): New const.
7101 (s390_ft_main_31): New const.
7102 (s390_ft_main_64): New const.
7103 (s390_ft_exit_fr): New const.
7104 (s390_ft_exit_vr): New const.
7105 (s390_ft_exit_misc): New const.
7106 (s390_ft_exit_gpr_esa): New const.
7107 (s390_ft_exit_gpr_zarch): New const.
7108 (append_insns): New function.
7109 (s390_relocate_instruction): New function.
7110 (s390_install_fast_tracepoint_jump_pad): New function.
7111 (s390_get_min_fast_tracepoint_insn_len): New function.
7112 (s390_get_ipa_tdesc_idx): New function.
7113 (struct linux_target_ops): Wire in the above functions.
7114 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
7115 * linux-s390-tdesc.h: New file.
7116
a4105d04
MK
71172016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
7118
7119 * linux-s390-low.c (s390_supports_tracepoints): New function.
7120 (struct linux_target_ops): Fill supports_tracepoints hook.
7121
35ac8b3e
YQ
71222016-03-18 Yao Qi <yao.qi@linaro.org>
7123
7124 * linux-low.c (lwp_signal_can_be_delivered): New function.
7125 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
7126
94610ec4
YQ
71272016-03-18 Yao Qi <yao.qi@linaro.org>
7128
7129 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
7130 0 if signal is enqueued. Remove 'signal' from one debugging
7131 message. Move one debugging message to some lines below.
7132 Remove code setting 'signal' to 0.
7133
80aea927
YQ
71342016-03-18 Yao Qi <yao.qi@linaro.org>
7135
7136 * linux-low.c (linux_low_filter_event): Remove redundant
7137 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
7138
b04fd3be
MK
71392016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
7140
7141 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
7142 (struct linux_target_ops): Wire in the above.
7143
c40c8d4b
YQ
71442016-03-03 Yao Qi <yao.qi@linaro.org>
7145
7146 * linux-low.c: Update comments to start_step_over.
7147
0f8288ae
YQ
71482016-03-03 Yao Qi <yao.qi@linaro.org>
7149
7150 PR server/19736
7151 * linux-low.c (handle_extended_wait): Set child suspended
7152 if event_lwp->bp_reinsert isn't zero.
7153
fdbd04a8
YQ
71542016-03-02 Yao Qi <yao.qi@linaro.org>
7155
7156 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
7157 enqueue_pending_signal.
7158
6896a8fa
MK
71592016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
7160
7161 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
7162 is actually loaded.
7163
ab503087
MK
71642016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
7165
7166 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
7167 (s390_regmap_3264) [!__s390x__]: New global.
7168 (s390_collect_ptrace_register): Skip map entries containing -1.
7169 (s390_supply_ptrace_register): Ditto.
7170 (s390_fill_gprs_high): New function.
7171 (s390_store_gprs_high): New function.
7172 (s390_regsets): Add NT_S390_HIGH_GPRS.
7173 (s390_get_hwcap): Enable on 31-bit.
7174 (have_hwcap_s390_high_gprs): Enable on 31-bit.
7175 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
7176 Detect NT_S390_HIGH_GPRS.
7177 (s390_usrregs_info_3264): Enable on 31-bit.
7178 (s390_regs_info): Enable regs_info_3264 on 31-bit.
7179 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
7180
ae91f625
MK
71812016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
7182
7183 PR gdb/13808
7184 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
7185 * configure.srv: Ditto.
7186 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
7187 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
7188 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
7189 (init_registers_amd64_linux): Remove prototype.
7190 (tdesc_amd64_linux): Remove declaration.
7191 (get_ipa_tdesc): New function.
7192 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
7193 initialize remaining tdescs.
7194 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
7195 (init_registers_i386_linux): Remove prototype.
7196 (tdesc_i386_linux): Remove declaration.
7197 (get_ipa_tdesc): New function.
7198 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
7199 initialize remaining tdescs.
7200 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
7201 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
7202 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
7203 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
7204 (x86_get_ipa_tdesc_idx): New function.
7205 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
7206 * linux-x86-tdesc.h: New file.
7207 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
7208 (target_get_ipa_tdesc_idx): New macro.
7209 * tracepoint.c (ipa_tdesc_idx): New macro.
7210 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
7211 (symbol_list): Add ipa_tdesc_idx.
7212 (cmd_qtstart): Write ipa_tdesc_idx in the target.
7213 (ipa_tdesc): Remove.
7214 (ipa_tdesc_idx): New variable.
7215 (get_context_regcache): Use get_ipa_tdesc.
7216 (gdb_collect): Ditto.
7217 (gdb_probe): Ditto.
7218 * tracepoint.h (get_ipa_tdesc): New prototype.
7219 (ipa_tdesc): Remove.
7220
e7ad2f14
PA
72212016-02-24 Pedro Alves <palves@redhat.com>
7222
7223 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
7224 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
7225 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
7226 Factor out common code between the USE_SIGTRAP_SIGINFO and
7227 !USE_SIGTRAP_SIGINFO blocks.
7228 (linux_low_filter_event): Call save_stop_reason instead of
7229 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
7230 Update comments.
7231 (linux_wait_1): Update comments.
7232
657f9cde
WW
72332016-02-24 Wei-cheng Wang <cole945@gmail.com>
7234
7235 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
7236 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
7237 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
7238 ppc_insert_point, ppc_remove_point.
7239
b00b61e1
MK
72402016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
7241
7242 * linux-s390-low.c (s390_supports_z_point_type): New function.
7243 (struct linux_target_ops): Wire s390_supports_z_point_type in.
7244
553cb527
YQ
72452016-02-16 Yao Qi <yao.qi@linaro.org>
7246
7247 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
7248 PC. Get pc from regcache_read_pc.
7249
a5652c21
YQ
72502016-02-12 Yao Qi <yao.qi@linaro.org>
7251
7252 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
7253 or linux_get_pc_32bit.
7254 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
7255
ed443b61
YQ
72562016-02-12 Yao Qi <yao.qi@linaro.org>
7257
7258 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
7259 arm_linux_get_next_pcs_fixup.
7260
020ecd38
MK
72612016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
7262
7263 * tracepoint.c (x_tracepoint_action_download): Change
7264 write_inferior_data_ptr to write_inferior_data_pointer.
7265 (cmd_qtstart): Likewise.
7266 (write_inferior_data_ptr): Remove.
7267 (download_agent_expr): Change write_inferior_data_ptr to
7268 write_inferior_data_pointer.
7269 (download_tracepoint_1): Likewise.
7270 (download_tracepoint): Likewise.
7271 (download_trace_state_variables): Likewise.
7272
7cae9051
WW
72732016-02-11 Wei-cheng Wang <cole945@gmail.com>
7274 Marcin Kościelnicki <koriakin@0x04.net>
7275
7276 * tracepoint.c (struct tracepoint_action_ops): Remove.
7277 (struct tracepoint_action): Remove ops.
7278 (m_tracepoint_action_download, r_tracepoint_action_download)
7279 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
7280 size and offset accordingly.
7281 (m_tracepoint_action_ops, r_tracepoint_action_ops)
7282 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
7283 (tracepoint_action_send, tracepoint_action_download): New functions.
7284 Helpers for trace action handlers.
7285 (add_tracepoint_action): Remove setup actions ops.
7286 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
7287
9f6a71b4
YQ
72882016-02-10 Yao Qi <yao.qi@linaro.org>
7289
7290 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
7291
1e94266c
SM
72922016-02-09 Simon Marchi <simon.marchi@ericsson.com>
7293
7294 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
7295 to AC_OUTPUT.
7296 * configure: Regenerate.
7297
8adce034
SM
72982016-02-09 Simon Marchi <simon.marchi@ericsson.com>
7299
7300 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
7301 void * to gdb_byte *.
7302 * linux-low.c (siginfo_fixup): Likewise.
7303 (linux_xfer_siginfo): Likewise.
7304 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
7305 Likewise.
7306 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
7307
93813b37
WT
73082016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
7309
7310 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
7311 to srv_tgtobj.
7312 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
7313 to srv_tgtobj.
7314 * linux-x86-low.c [__x86_64__]: Include
7315 "nat/amd64-linux-siginfo.h".
7316 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
7317 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
7318 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
7319 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
7320 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
7321 (cpt_si_fd, si_timerid, si_overrun): Move from
7322 nat/amd64-linux-siginfo.c.
7323 * Makefile.in (amd64-linux-siginfo.o:): New rule.
7324
8424cc97
SM
73252016-01-28 Simon Marchi <simon.marchi@ericsson.com>
7326
7327 * server.c (skip_to_semicolon): Remove.
7328 (process_point_options): Use strchrnul instead of
7329 skip_to_semicolon.
7330
4d18591b
YQ
73312016-01-26 Yao Qi <yao.qi@linaro.org>
7332
7333 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
7334 * linux-low.c (install_software_single_step_breakpoints): Don't
7335 call regcache_read_pc.
7336 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
7337 argument pc.
7338
d8020970
YQ
73392016-01-26 Yao Qi <yao.qi@linaro.org>
7340
7341 * linux-low.c (install_software_single_step_breakpoints): Call
7342 regcache_read_pc instead of get_pc.
7343
8b207339
YQ
73442016-01-26 Yao Qi <yao.qi@linaro.org>
7345
7346 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
7347 (unblock_async_io): Rename to ...
7348 (block_unblock_async_io): ... it. New function.
7349 (enable_async_io): Don't install SIGIO handler. Unblock it
7350 instead.
7351 (disable_async_io): Don't ignore SIGIO. Block it instead.
7352 (initialize_async_io): Install SIGIO handler. Don't call
7353 unblock_async_io.
7354
18879fef
YQ
73552016-01-26 Yao Qi <yao.qi@linaro.org>
7356
7357 * remote-utils.c (getpkt): If the buffer isn't empty, and the
7358 first character is '\003', call *the_target->request_interrupt.
7359
a0f8e08a
YQ
73602016-01-25 Yao Qi <yao.qi@linaro.org>
7361
7362 * remote-utils.c (new_thread_notify): Remove.
7363 (dead_thread_notify): Likewise.
7364 * remote-utils.h (new_thread_notify): Remove declaration.
7365 (dead_thread_notify): Likewise.
7366
cc5fd9ab
MK
73672016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
7368
7369 * gdb.trace/pending.exp: Fix expected message on continue.
7370
99e8eb11
MK
73712016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
7372
7373 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
7374 it works properly on big-endian machines where sizeof (CORE_ADDR)
7375 != sizeof (void *).
7376
a994041d
PA
73772016-01-21 Pedro Alves <palves@redhat.com>
7378
7379 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
7380 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
7381 * configure: Regenerate.
7382
f7a6a40d
YQ
73832016-01-21 Yao Qi <yao.qi@linaro.org>
7384
7385 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
7386 is_thumb and set it according to CPSR saved on the stack.
7387 (get_next_pcs_syscall_next_pc): Pass is_thumb to
7388 arm_sigreturn_next_pc.
7389
6f69e520
YQ
73902016-01-18 Yao Qi <yao.qi@linaro.org>
7391
7392 * linux-low.c (linux_set_pc_64bit): New function.
7393 (linux_get_pc_64bit): New function.
7394 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
7395 Declare.
7396 * linux-sparc-low.c (debug_threads): Remove declaration.
7397 (sparc_get_pc): Remove.
7398 (the_low_target): Use linux_get_pc_64bit instead of
7399 sparc_get_pc.
7400 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
7401 (the_low_target): Use linux_get_pc_64bit and
7402 linux_set_pc_64bit.
7403
276d4552
YQ
74042016-01-18 Yao Qi <yao.qi@linaro.org>
7405
7406 * linux-arm-low.c (debug_threads): Remove declaration.
7407 (arm_get_pc, arm_set_pc): Remove.
7408 (the_low_target): Use linux_get_pc_32bit and
7409 linux_set_pc_32bit.
7410 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
7411 (the_low_target): Use linux_get_pc_32bit and
7412 linux_set_pc_32bit.
7413 * linux-cris-low.c (debug_threads): Remove declaration.
7414 (cris_get_pc, cris_set_pc,): Remove.
7415 (the_low_target): Use linux_get_pc_32bit and
7416 linux_set_pc_32bit.
7417 * linux-crisv32-low.c (debug_threads): Remove declaration.
7418 (cris_get_pc, cris_set_pc): Remove.
7419 (the_low_target): Use linux_get_pc_32bit and
7420 linux_set_pc_32bit.
7421 * linux-low.c: Include inttypes.h.
7422 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
7423 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
7424 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
7425 (the_low_target): Use linux_get_pc_32bit and
7426 linux_set_pc_32bit.
7427 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
7428 (the_low_target): Use linux_get_pc_32bit and
7429 linux_set_pc_32bit.
7430 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
7431 (the_low_target): Use linux_get_pc_32bit and
7432 linux_set_pc_32bit.
7433 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
7434 (the_low_target): Use linux_get_pc_32bit and
7435 linux_set_pc_32bit.
7436 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
7437 (the_low_target): Use linux_get_pc_32bit and
7438 linux_set_pc_32bit.
7439
eb0edac8
GB
74402016-01-18 Gary Benson <gbenson@redhat.com>
7441
7442 * configure.ac (AC_FUNC_FORK): New check.
7443 * config.in: Regenerate.
7444 * configure: Likewise.
7445
1b451dda
YQ
74462016-01-14 Yao Qi <yao.qi@linaro.org>
7447
7448 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
7449 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
7450 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
7451 arm_get_next_pcs_ctor.
7452
82075af2
JS
74532016-01-12 Josh Stone <jistone@redhat.com>
7454 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7455
7456 * inferiors.h: Include "gdb_vecs.h".
7457 (struct process_info): Add syscalls_to_catch.
7458 * inferiors.c (remove_process): Free syscalls_to_catch.
7459 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
7460 syscall_return stops.
7461 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
7462 * server.c (handle_general_set): Handle QCatchSyscalls.
7463 (handle_query): Report support for QCatchSyscalls.
7464 * target.h (struct target_ops): Add supports_catch_syscall.
7465 (target_supports_catch_syscall): New macro.
7466 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
7467 (struct lwp_info): Add syscall_state.
7468 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
7469 Maintain syscall_state and syscalls_to_catch across exec.
7470 (get_syscall_trapinfo): New function, proxy to the_low_target.
7471 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
7472 (linux_low_filter_event): Toggle syscall_state entry/return for
7473 syscall traps, and set it ignored for all others.
7474 (gdb_catching_syscalls_p): New function.
7475 (gdb_catch_this_syscall_p): New function.
7476 (linux_wait_1): Handle SYSCALL_SIGTRAP.
7477 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
7478 (linux_supports_catch_syscall): New function.
7479 (linux_target_ops): Install it.
7480 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
7481 (the_low_target): Install it.
7482
8f13a3ce
MF
74832016-01-12 Mike Frysinger <vapier@gentoo.org>
7484
7485 * acinclude.m4: Include new ../warning.m4 file.
7486 * configure: Regenerated.
7487 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
7488
5b3da067
MF
74892016-01-12 Mike Frysinger <vapier@gentoo.org>
7490
7491 * ax.c (is_goto_target): Mark static.
7492 * linux-low.c (register_addr): Likewise.
7493 (linux_fetch_registers, linux_store_registers): Likewise.
7494 * mem-break.c (any_persistent_commands): Fix old prototype.
7495 (add_commands_to_breakpoint): Mark static.
7496 * regcache.c (find_register_by_name): Delete unused func.
7497 * remote-utils.c (hex_or_minus_one): Mark static.
7498 * server.c (monitor_show_help): Mark static.
7499 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
7500 handle_v_requests): Likewise.
7501
bc504a31
PA
75022016-01-12 Pedro Alves <palves@redhat.com>
7503
7504 Remove use of the registered trademark symbol throughout.
7505
5a0dd67a
YQ
75062016-01-08 Yao Qi <yao.qi@linaro.org>
7507
7508 * remote-utils.c (getpkt): If c is '\003', call target hook
7509 request_interrupt.
7510
b2ca446f
YQ
75112016-01-06 Yao Qi <yao.qi@linaro.org>
7512
7513 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
7514 linux-aarch32-low.c.
7515 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7516 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
7517 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7518 (thumb2_breakpoint): Declare.
7519 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
7520 linux-aarch32-low.h.
7521 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7522 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
7523 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7524
edd88788
JB
75252016-01-01 Joel Brobecker <brobecker@adacore.com>
7526
7527 * gdbreplay.c (gdbreplay_version): Change copyright year in
7528 version message.
7529 * server.c (gdbserver_version): Likewise.
7530
65da7f14
PP
75312015-12-28 Patrick Palka <patrick@parcs.ath.cx>
7532
7533 * server.c (crc32_table): Delete.
7534 (crc32): Use libiberty's xcrc32 function.
7535
4abd5ed2
JB
75362015-12-22 Joel Brobecker <brobecker@adacore.com>
7537
7538 * lynx-low.c (lynx_delete_thread_callback): New function.
7539 (lynx_mourn): Properly delete our process and all of its
7540 threads. Remove call to clear_inferiors.
7541
0e50fe5c
JB
75422015-12-22 Joel Brobecker <brobecker@adacore.com>
7543
7544 * target.c (thread_search_callback): Add check that
7545 the thread_stopped target callback is not NULL before
7546 calling it.
7547
35adc03f
YQ
75482015-12-21 Yao Qi <yao.qi@linaro.org>
7549
7550 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
7551 arm breakpoint.
7552
bd2b2909
AT
75532015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7554
7555 * server.c (handle_query): Call target_supports_software_single_step.
7556
7fe5e27e
AT
75572015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7558
7559 * linux-low.c (single_step): New function.
7560 (linux_resume_one_lwp_throw): Call single_step.
7561 (start_step_over): Likewise.
7562
d9311bfa
AT
75632015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7564
7565 * Makefile.in (SFILES): Append arch/arm-linux.c,
7566 arch/arm-get-next-pcs.c.
7567 (arm-linux.o): New rule.
7568 (arm-get-next-pcs.o): New rule.
7569 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
7570 arm-linux.o.
7571 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
7572 to linux-aarch32-low.c.
7573 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7574 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7575 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7576 (thumb2_breakpoint_len): Likewise.
7577 (arm_is_thumb_mode): Make non-static.
7578 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
7579 from linux-aarch32-low.c.
7580 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7581 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7582 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7583 (thumb2_breakpoint_len): Likewise.
7584 (arm_is_thumb_mode): New declaration.
7585 * linux-arm-low.c: Include arch/arm-linux.h
7586 aarch/arm-get-next-pcs.h, sys/syscall.h.
7587 (get_next_pcs_ops): New struct.
7588 (get_next_pcs_addr_bits_remove): New function.
7589 (get_next_pcs_is_thumb): New function.
7590 (get_next_pcs_read_memory_unsigned_integer): Likewise.
7591 (arm_sigreturn_next_pc): Likewise.
7592 (get_next_pcs_syscall_next_pc): Likewise.
7593 (arm_gdbserver_get_next_pcs): Likewise.
7594 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
7595 Initialize.
7596 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
7597 * server.h: Include gdb_vecs.h.
7598
68ce2059
AT
75992015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7600
7601 * Makefile.in (SFILES): Append common/common-regcache.c.
7602 (OBS): Append common-regcache.o.
7603 (common-regcache.o): New rule.
7604 * regcache.c (init_register_cache): Initialize cache to
7605 REG_UNAVAILABLE.
7606 (regcache_raw_read_unsigned): New function.
7607 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
7608 register_status enum.
7609
fa5308bd
AT
76102015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7611
7612 * linux-aarch64-low.c (the_low_targets): Rename
7613 breakpoint_reinsert_addr to get_next_pcs.
7614 * linux-arm-low.c (the_low_targets): Likewise.
7615 * linux-bfin-low.c (the_low_targets): Likewise.
7616 * linux-cris-low.c (the_low_targets): Likewise.
7617 * linux-crisv32-low.c (the_low_targets): Likewise.
7618 * linux-low.c (can_software_single_step): Likewise.
7619 (install_software_single_step_breakpoints): New function.
7620 (start_step_over): Use install_software_single_step_breakpoints.
7621 * linux-low.h: New CORE_ADDR vector.
7622 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
7623 get_next_pcs.
7624 * linux-mips-low.c (the_low_targets): Likewise.
7625 * linux-nios2-low.c (the_low_targets): Likewise.
7626 * linux-sparc-low.c (the_low_targets): Likewise.
7627
4a6ed09b
PA
76282015-12-17 Pedro Alves <palves@redhat.com>
7629
7630 * linux-low.c (linux_kill_one_lwp): Remove references to
7631 LinuxThreads.
7632 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
7633 to 'kill'.
7634 (linux_init_signals): Delete.
7635 (initialize_low): Adjust.
7636 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
7637
7544db95
PA
76382015-12-16 Pedro Alves <palves@redhat.com>
7639
7640 * configure.ac (compiler warning flags): When testing a
7641 -Wno-foo option, check whether -Wfoo works instead.
7642 * configure: Regenerate.
7643
8020350c
DB
76442015-12-11 Don Breazeal <donb@codesourcery.com>
7645
7646 * server.c (process_serial_event): Don't exit from gdbserver
7647 in remote mode if there are still active inferiors.
7648
db91f502
YQ
76492015-12-11 Yao Qi <yao.qi@linaro.org>
7650
7651 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
7652 arm_breakpoint_at if the process is 32-bit.
7653
b37a6290
YQ
76542015-12-11 Yao Qi <yao.qi@linaro.org>
7655
7656 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
7657 arm breakpoint.
7658
17b1509a
YQ
76592015-12-07 Yao Qi <yao.qi@linaro.org>
7660
7661 * configure.srv: Append arm.o to srv_tgtobj for
7662 aarch64*-*-linux* target.
7663 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
7664 from linux-arm-low.c.
7665 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7666 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7667 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7668 (thumb2_breakpoint_len): Likewise.
7669 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
7670 (arm_breakpoint_kinds): Likewise.
7671 (arm_breakpoint_kind_from_pc): Likewise.
7672 (arm_sw_breakpoint_from_kind): Likewise.
7673 (arm_breakpoint_kind_from_current_state): Likewise.
7674 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
7675 (arm_sw_breakpoint_from_kind): Declare.
7676 (arm_breakpoint_kind_from_current_state): Declare.
7677 (arm_breakpoint_at): Declare.
7678 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
7679 arm_sw_breakpoint_from_kind if process is 32-bit.
7680 (aarch64_breakpoint_kind_from_pc): New function.
7681 (aarch64_breakpoint_kind_from_current_state): New function.
7682 (the_low_target): Initialize fields breakpoint_kind_from_pc
7683 and breakpoint_kind_from_current_state.
7684 * linux-arm-low.c (arm_breakpoint_kinds): Move to
7685 linux-aarch32-low.c.
7686 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
7687 (arm_breakpoint, arm_breakpoint_len): Likewise.
7688 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
7689 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7690 (arm_is_thumb_mode): Likewise.
7691 (arm_breakpoint_at): Likewise.
7692 (arm_breakpoint_kind_from_pc): Likewise.
7693 (arm_sw_breakpoint_from_kind): Likewise.
7694 (arm_breakpoint_kind_from_current_state): Likewise.
7695
7696 Revert:
7697 2015-08-04 Yao Qi <yao.qi@linaro.org>
7698
7699 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7700 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7701 * server.c (extended_protocol): Remove "static".
7702 * server.h (extended_protocol): Declare it.
7703
ece66d65
JS
77042015-12-04 Josh Stone <jistone@redhat.com>
7705
7706 * target.h (struct target_ops) <arch_setup>: Rename to ...
7707 (struct target_ops) <post_create_inferior>: ... this.
7708 (target_arch_setup): Rename to ...
7709 (target_post_create_inferior): ... this, calling post_create_inferior.
7710 * server.c (start_inferior): Update target_arch_setup calls to
7711 target_post_create_inferior.
7712 * linux-low.c (linux_low_ptrace_options): Forward declare.
7713 (linux_arch_setup): Update its comment for general use.
7714 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
7715 (struct linux_target_ops): Use linux_post_create_inferior.
7716 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
7717 to post_create_inferior.
7718 * nto-low.c (struct nto_target_ops): Likewise.
7719 * spu-low.c (struct spu_target_ops): Likewise.
7720 * win32-low.c (struct win32_target_ops): Likewise.
7721
e58c48b4
AT
77222015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
7723
7724 * linux-arm-low.c: Remove duplicate arch/arm.h include.
7725
fbec8956
AT
77262015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7727
7728 * linux-arm-low.c (arm_reinsert_addr): Remove function.
7729 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
7730 * linux-cris-low.c (cris_reinsert_addr> Remove function.
7731 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7732 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
7733 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7734 * linux-mips-low.c (mips_reinsert_addr): Remove function.
7735 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7736 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
7737 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7738 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
7739 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7740
9b4c5f87
AT
77412015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7742
7743 * linux-low.c (linux_look_up_symbols): Don't call
7744 linux_supports_traceclone.
7745 * linux-low.h (thread_db_init): Remove use_events argument.
7746 * thread-db.c (thread_db_use_event): Remove global variable.
7747 (struct thread_db) <td_thr_event_enable_p>: Remove field.
7748 (struct thread_db) <td_create_bp>: Remove field.
7749 (thread_db_create_event): Remove function.
7750 (thread_db_enable_reporting): Likewise.
7751 (find_one_thread): Don't check for thread_db_use_events.
7752 (attach_thread): Likewise.
7753 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
7754 (try_thread_db_load_1): Don't check for thread_db_use_events.
7755 (thread_db_init): Remove use_events argument and thread events
7756 handling.
7757 (remove_thread_event_breakpoints): Remove function.
7758 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
7759
7d00775e
AT
77602015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7761
7762 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
7763 New function.
7764 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7765 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
7766 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7767 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
7768 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
7769 Initialize.
7770 * linux-crisv32-low.c (cris_supports_hardware_single_step):
7771 New function.
7772 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7773 * linux-low.c (can_hardware_single_step): Use
7774 supports_hardware_single_step.
7775 (can_software_single_step): New function.
7776 (start_step_over): Call can_software_single_step.
7777 (linux_supports_hardware_single_step): New function.
7778 (struct target_ops) <supports_software_single_step>: Initialize.
7779 * linux-low.h (struct linux_target_ops)
7780 <supports_hardware_single_step>: Initialize.
7781 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
7782 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7783 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
7784 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
7785 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
7786 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7787 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
7788 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7789 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
7790 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
7791 Initialize.
7792 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
7793 (struct linux_target_ops) <tile_supports_hardware_single_step>:
7794 Initialize.
7795 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
7796 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7797 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
7798 New function.
7799 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7800 * target.h (struct target_ops): <supports_software_single_step>:
7801 New field.
7802 (target_supports_software_single_step): New macro.
7803
2d97cd35
AT
78042015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7805
7806 * linux-low.c (linux_wait_1): Fix pc advance condition.
7807 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
7808 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
7809
769ef81f
AT
78102015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7811
7812 * linux-arm-low.c (arm_is_thumb_mode): New function.
7813 (arm_breakpoint_at): Use arm_is_thumb_mode.
7814 (arm_breakpoint_kind_from_current_state): New function.
7815 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
7816 Initialize.
7817 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
7818 (linux_breakpoint_kind_from_current_state): New function.
7819 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
7820 * linux-low.h (struct linux_target_ops)
7821 <breakpoint_kind_from_current_state>: New field.
7822 * target.h (struct target_ops): Likewise.
7823 (target_breakpoint_kind_from_current_state): New macro.
7824
1bebeeca
PA
78252015-11-30 Pedro Alves <palves@redhat.com>
7826
7827 * linux-low.c (linux_resume): Wake up the event loop before
7828 returning.
7829
a67a9fae
PA
78302015-11-30 Pedro Alves <palves@redhat.com>
7831
7832 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
7833 check.
7834 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
7835 to -1.
7836 * target.c (struct thread_search): New structure.
7837 (thread_search_callback): New function.
7838 (prev_general_thread): New global.
7839 (prepare_to_access_memory, done_accessing_memory): New functions.
7840 * target.h (prepare_to_access_memory, done_accessing_memory):
7841 Replace macros with function declarations.
7842
f2faf941
PA
78432015-11-30 Pedro Alves <palves@redhat.com>
7844
7845 PR 14618
7846 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
7847 report TARGET_WAITKIND_NO_RESUMED.
7848 * remote-utils.c (prepare_resume_reply): Handle
7849 TARGET_WAITKIND_NO_RESUMED.
7850 * server.c (report_no_resumed): New global.
7851 (handle_query) <qSupported>: Handle "no-resumed+". Report
7852 "no-resumed+" support.
7853 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
7854 return error if the client doesn't support no-resumed events.
7855 (push_stop_notification): New function.
7856 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
7857 events if the client supports them.
7858
a681f9c9
PA
78592015-11-30 Pedro Alves <palves@redhat.com>
7860
7861 * linux-low.c (thread_still_has_status_pending_p): Don't check
7862 vCont;t here.
7863 (lwp_resumed): New function.
7864 (status_pending_p_callback): Return early if the LWP is not
7865 supposed to be resumed.
7866
65706a29
PA
78672015-11-30 Pedro Alves <palves@redhat.com>
7868
7869 * linux-low.c (handle_extended_wait): Assert that the LWP's
7870 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
7871 thread create events, leave the new child's status pending.
7872 (linux_low_filter_event): If GDB wants to hear about thread exit
7873 events, leave the LWP marked dead and don't delete it.
7874 (linux_wait_for_event_filtered): Don't check for thread exit.
7875 (filter_exit_event): New function.
7876 (linux_wait_1): Use it, when returning an exit event.
7877 (linux_resume_one_lwp_throw): Assert that the LWP's
7878 waitstatus is TARGET_WAITKIND_IGNORE.
7879 * remote-utils.c (prepare_resume_reply): Handle
7880 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
7881 * server.c (report_thread_events): New global.
7882 (handle_general_set): Handle QThreadEvents.
7883 (handle_query) <qSupported>: Handle and report QThreadEvents+;
7884 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
7885 TARGET_WAITKIND_THREAD_EXITED.
7886 * server.h (report_thread_events): Declare.
7887
56cf4bed
PA
78882015-11-30 Pedro Alves <palves@redhat.com>
7889
7890 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
7891 the thread's last_resume_kind was resume_stop.
7892
500c1d85
PA
78932015-11-30 Pedro Alves <palves@redhat.com>
7894
7895 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
7896 before returning.
7897
de979965
PA
78982015-11-30 Pedro Alves <palves@redhat.com>
7899
7900 * server.c (handle_v_requests): Handle vCtrlC.
7901
34c65914
PA
79022015-11-30 Pedro Alves <palves@redhat.com>
7903
7904 * gdbthread.h (find_any_thread_of_pid): Declare.
7905 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
7906 functions.
7907 * server.c (handle_query): If current_thread is NULL, look for
7908 another thread of the selected process.
7909
79efa585 79102015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 7911 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
7912
7913 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
7914 * server.c (handle_qxfer_threads_worker): Refactor to include thread
7915 name in reply.
7916 * target.h (struct target_ops) <thread_name>: New field.
7917 (target_thread_name): New macro.
7918
80d82c19
JB
79192015-11-23 Joel Brobecker <brobecker@adacore.com>
7920
7921 * regcache.h (regcache_invalidate_pid): Add declaration.
7922 * regcache.c (regcache_invalidate_pid): New function, extracted
7923 from regcache_invalidate.
7924 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
7925 Add trivial documentation comment.
7926 * lynx-low.c: Use regcache_invalidate_pid instead of
7927 regcache_invalidate.
7928
64da5dd5
JB
79292015-11-23 Joel Brobecker <brobecker@adacore.com>
7930
7931 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
7932 and Elf64_auxv_t if the target is Android.
7933
37ce4055
DE
79342015-11-22 Doug Evans <xdje42@gmail.com>
7935
7936 * target.h: #include <sys/types.h>.
7937
06e03fff
PA
79382015-11-19 Pedro Alves <palves@redhat.com>
7939
7940 * linux-low.c (linux_process_qsupported): Change prototype.
7941 Adjust.
7942 * linux-low.h (struct linux_target_ops) <process_qsupported>:
7943 Change prototype.
7944 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
7945 and adjust to loop over all features.
7946 * server.c (handle_query) <qSupported>: Adjust to call
7947 target_process_qsupported once, passing it a vector of unprocessed
7948 features.
7949 * target.h (struct target_ops) <process_qsupported>: Change
7950 prototype.
7951 (target_process_qsupported): Adjust.
7952
9a084706
PA
79532015-11-19 Pedro Alves <palves@redhat.com>
7954
7955 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
7956 mode.
7957 * configure: Regenerate.
7958
dad44a1f
PA
79592015-11-19 Pedro Alves <palves@redhat.com>
7960
7961 * configure: Regenerate.
7962
231c0592
YQ
79632015-11-19 Yao Qi <yao.qi@linaro.org>
7964
7965 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
7966 type to uint32_t.
7967
6c1c9a8b
YQ
79682015-11-19 Yao Qi <yao.qi@linaro.org>
7969
7970 * linux-aarch64-low.c (enum aarch64_operand_type): New.
7971 (struct aarch64_operand): Move enum out.
7972
9caa3311
YQ
79732015-11-19 Yao Qi <yao.qi@linaro.org>
7974
7975 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
7976 struct user_fpsimd_state *.
7977 (aarch64_store_fpregset): Likewise.
7978
6a69a054
YQ
79792015-11-19 Yao Qi <yao.qi@linaro.org>
7980
7981 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
7982 struct user_pt_regs *.
7983 (aarch64_store_gregset): Likewise.
7984
1798301e
PA
79852015-11-18 Pedro Alves <palves@redhat.com>
7986
7987 * Makefile.in (all_object_files): Add $IPA_OBJS.
7988
ce7715e2
PA
79892015-11-17 Pedro Alves <palves@redhat.com>
7990
7991 * win32-low.c (win32_resume): Use gdb_signal_from_host,
7992 GDB_SIGNAL_0 and gdb_signal_to_string.
7993
c0879059
PA
79942015-11-17 Pedro Alves <palves@redhat.com>
7995
7996 * win32-low.c (handle_output_debug_string): Remove parameter.
7997 (win32_kill): Remove our_status local and adjust call to
7998 handle_output_debug_string.
7999 (get_child_debug_event): Adjust call to
8000 handle_output_debug_string.
8001
1996e237
SM
80022015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8003
8004 * linux-mips-low.c (mips_fill_gregset): Add cast.
8005 (mips_store_gregset): Likewise.
8006 (mips_fill_fpregset): Likewise.
8007 (mips_store_fpregset): Likewise.
8008
cbec665b
SM
80092015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8010
8011 * linux-mips-low.c (mips_add_watchpoint): Rename private to
8012 priv.
8013
eb3e3c67
SM
80142015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8015
8016 * linux-mips-low.c (mips_linux_new_thread): Change type of
8017 watch_type to enum target_hw_bp_type.
8018
171de4b8
SM
80192015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8020
8021 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
8022 Change return type to arm_hwbp_type.
8023
04248ead
SM
80242015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8025
8026 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
8027 (arm_store_gregset): Likewise.
8028 * linux-arm-low.c (arm_get_hwcap): Likewise.
8029 (arm_read_description): Likewise.
8030
04b3479c
SM
80312015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8032
8033 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
8034
2bc84e8a
SM
80352015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8036
8037 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
8038 (ppc_fill_vsxregset): Likewise.
8039 (ppc_store_vsxregset): Likewise.
8040 (ppc_fill_vrregset): Likewise.
8041 (ppc_store_vrregset): Likewise.
8042 (ppc_fill_evrregset): Likewise.
8043 (ppc_store_evrregset): Likewise.
8044
e6c5bb05
SM
80452015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8046
8047 * linux-ppc-low.c (ppc_usrregs_info): Remove
8048 forward-declaration.
8049 (ppc_arch_setup): Move lower in file.
8050
7ea45d72
SM
80512015-10-30 Simon Marchi <simon.marchi@ericsson.com>
8052
8053 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
8054 (ps_pdwrite): Likewise.
8055
69291610
HW
80562015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
8057
8058 * linux-arm-low.c (arm_new_thread): Move pointer dereference
8059 to after assert checks.
8060
b42945fd
SM
80612015-10-29 Simon Marchi <simon.marchi@ericsson.com>
8062
8063 * proc-service.c (ps_pdread): Add/adjust casts.
8064 (ps_pdwrite): Add/adjust casts.
8065
d6f85c84
SM
80662015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
8067
8068 * server.c (handle_search_memory_1): Cast return value of
8069 memmem.
8070
f98cd059
SM
80712015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
8072
8073 * server.c (write_qxfer_response): Change type of data to
8074 gdb_byte *.
8075
d2412fa5
PA
80762015-10-29 Pedro Alves <palves@redhat.com>
8077
8078 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
8079
c17414a2
PA
80802015-10-29 Pedro Alves <palves@redhat.com>
8081
8082 * tracepoint.c (clear_installed_tracepoints): Add casts.
8083
e053fbc4
PA
80842015-10-29 Pedro Alves <palves@redhat.com>
8085
8086 * server.c (handle_v_cont, process_serial_event): Add enum
8087 gdb_signal casts to signal parsing code.
8088
add67df8
PA
80892015-10-29 Pedro Alves <palves@redhat.com>
8090
8091 * linux-low.h (NULL_REGSET): Define.
8092 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
8093 * linux-arm-low.c (arm_regsets): Likewise.
8094 * linux-crisv32-low.c (cris_regsets): Likewise.
8095 * linux-m68k-low.c (m68k_regsets): Likewise.
8096 * linux-mips-low.c (mips_regsets): Likewise.
8097 * linux-nios2-low.c (nios2_regsets): Likewise.
8098 * linux-ppc-low.c (ppc_regsets): Likewise.
8099 * linux-s390-low.c (s390_regsets): Likewise.
8100 * linux-sh-low.c (sh_regsets): Likewise.
8101 * linux-sparc-low.c (sparc_regsets): Likewise.
8102 * linux-tic6x-low.c (tic6x_regsets): Likewise.
8103 * linux-tile-low.c (tile_regsets): Likewise.
8104 * linux-x86-low.c (x86_regsets): Likewise.
8105 * linux-xtensa-low.c (xtensa_regsets): Likewise.
8106
50bc912a
PA
81072015-10-29 Pedro Alves <palves@redhat.com>
8108
8109 * linux-low.h (NULL_REGSET): Define.
8110 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
8111 * linux-arm-low.c (arm_regsets): Likewise.
8112 * linux-crisv32-low.c (cris_regsets): Likewise.
8113 * linux-m68k-low.c (m68k_regsets): Likewise.
8114 * linux-mips-low.c (mips_regsets): Likewise.
8115 * linux-nios2-low.c (nios2_regsets): Likewise.
8116 * linux-ppc-low.c (ppc_regsets): Likewise.
8117 * linux-s390-low.c (s390_regsets): Likewise.
8118 * linux-sh-low.c (sh_regsets): Likewise.
8119 * linux-sparc-low.c (sparc_regsets): Likewise.
8120 * linux-tic6x-low.c (tic6x_regsets): Likewise.
8121 * linux-tile-low.c (tile_regsets): Likewise.
8122 * linux-x86-low.c (x86_regsets): Likewise.
8123 * linux-xtensa-low.c (xtensa_regsets): Likewise.
8124
682b2546
DE
81252015-10-26 Doug Evans <dje@google.com>
8126
8127 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
8128
963843d4
DE
81292015-10-26 Doug Evans <dje@google.com>
8130
8131 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
8132
d41401ac
DE
81332015-10-26 Doug Evans <dje@google.com>
8134
8135 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
8136 for debug_printf.
8137 (attach_thread, find_new_threads_callback): Ditto.
8138
3db28855
AT
81392015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
8140
8141 * mem-break.h (set_breakpoint_data): Remove.
8142
fb78e89c
AT
81432015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
8144
8145 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
8146 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
8147 (initialize_low): Remove set_breakpoint_data call.
8148 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
8149 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
8150 (initialize_low): Remove set_breakpoint_data call.
8151 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
8152 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
8153 (initialize_low): Remove set_breakpoint_data call.
8154
2e6ee069
AT
81552015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
8156
8157 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
8158 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
8159 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
8160 * target.h (target_breakpoint_kind_from_pc): New macro.
8161
1652a986
AT
81622015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
8163
8164 * linux-low.c (default_breakpoint_kind_from_pc): New function.
8165 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
8166 the default breakpoint kind.
8167
abeead09
AT
81682015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8169
8170 * linux-arm-low.c (arm_supports_z_point_type): Add software
8171 breakpoint support.
8172
b0b4b501
AT
81732015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8174
8175 * linux-arm-low.c: Refactor breakpoint definitions.
8176 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
8177 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
8178
8689682c
AT
81792015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8180
8181 * Makefile.in: Add arm.c/o.
8182 * configure.srv: Likewise.
8183 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
8184 (arm_breakpoint_kind_from_pc): New function.
8185 (arm_sw_breakpoint_from_kind): Return proper kind.
8186 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
8187
27165294
AT
81882015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8189
8190 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
8191 removal.
8192 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
8193 (struct raw_breakpoint) <size>: Remove.
8194 (struct raw_breakpoint) <kind>: Add.
8195 (bp_size): New function.
8196 (bp_opcode): Likewise.
8197 (find_raw_breakpoint_at): Adjust for kind.
8198 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
8199 (remove_memory_breakpoint): Adjust for kind call bp_size.
8200 (set_raw_breakpoint_at): Adjust for kind.
8201 (set_breakpoint): Likewise.
8202 (set_breakpoint_at): Call breakpoint_kind_from_pc.
8203 (delete_raw_breakpoint): Adjust for kind.
8204 (delete_breakpoint): Likewise.
8205 (find_gdb_breakpoint): Likewise.
8206 (set_gdb_breakpoint_1): Likewise.
8207 (set_gdb_breakpoint): Likewise.
8208 (delete_gdb_breakpoint_1): Likewise.
8209 (delete_gdb_breakpoint): Likewise.
8210 (uninsert_raw_breakpoint): Likewise.
8211 (reinsert_raw_breakpoint): Likewise.
8212 (set_breakpoint_data): Remove.
8213 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
8214 (check_mem_read): Adjust for kind call bp_size.
8215 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
8216 (clone_one_breakpoint): Adjust for kind.
8217 * mem-break.h (set_gdb_breakpoint): Likewise.
8218 (delete_gdb_breakpoint): Likewise.
8219 * server.c (process_serial_event): Likewise.
8220
dd373349
AT
82212015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8222
8223 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
8224 (struct linux_target_ops) <breakpoint>: Remove.
8225 (struct linux_target_ops) <breakpoint_len>: Remove.
8226 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8227 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8228 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
8229 (arm_sw_breakpoint_from_kind): New function.
8230 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
8231 (struct linux_target_ops) <breakpoint>: Remove.
8232 (struct linux_target_ops) <breakpoint_len>: Remove.
8233 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8234 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8235 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
8236 (struct linux_target_ops) <breakpoint>: Remove.
8237 (struct linux_target_ops) <breakpoint_len>: Remove.
8238 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8239 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8240 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
8241 (struct linux_target_ops) <breakpoint>: Remove.
8242 (struct linux_target_ops) <breakpoint_len>: Remove.
8243 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8244 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8245 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
8246 and sw_breakpoint_from_kind to increment the pc.
8247 (linux_breakpoint_kind_from_pc): New function.
8248 (linux_sw_breakpoint_from_kind): New function.
8249 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
8250 (initialize_low): Call breakpoint_kind_from_pc and
8251 sw_breakpoint_from_kind to replace breakpoint_data/len.
8252 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
8253 New field.
8254 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
8255 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
8256 (struct linux_target_ops) <breakpoint>: Remove.
8257 (struct linux_target_ops) <breakpoint_len>: Remove.
8258 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8259 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8260 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
8261 (struct linux_target_ops) <breakpoint>: Remove.
8262 (struct linux_target_ops) <breakpoint_len>: Remove.
8263 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8264 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8265 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
8266 (struct linux_target_ops) <breakpoint>: Remove.
8267 (struct linux_target_ops) <breakpoint_len>: Remove.
8268 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8269 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8270 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
8271 (struct linux_target_ops) <breakpoint>: Remove.
8272 (struct linux_target_ops) <breakpoint_len>: Remove.
8273 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8274 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8275 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
8276 (struct linux_target_ops) <breakpoint>: Remove.
8277 (struct linux_target_ops) <breakpoint_len>: Remove.
8278 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8279 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8280 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
8281 (struct linux_target_ops) <breakpoint>: Remove.
8282 (struct linux_target_ops) <breakpoint_len>: Remove.
8283 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8284 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8285 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
8286 (struct linux_target_ops) <breakpoint>: Remove.
8287 (struct linux_target_ops) <breakpoint_len>: Remove.
8288 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8289 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8290 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
8291 (struct linux_target_ops) <breakpoint>: Remove.
8292 (struct linux_target_ops) <breakpoint_len>: Remove.
8293 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8294 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8295 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
8296 (struct linux_target_ops) <breakpoint>: Remove.
8297 (struct linux_target_ops) <breakpoint_len>: Remove.
8298 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8299 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8300 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
8301 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
8302 (struct linux_target_ops) <breakpoint>: Remove.
8303 (struct linux_target_ops) <breakpoint_len>: Remove.
8304 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8305 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8306 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
8307 (struct linux_target_ops) <breakpoint>: Remove.
8308 (struct linux_target_ops) <breakpoint_len>: Remove.
8309 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8310 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8311
4cd98a19
AT
83122015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8313
8314 * linux-cris-low.c (cris_get_pc): Remove void arg.
8315
774ee6d2
AR
83162015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
8317
8318 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
8319 variable name.
8320
833dcd29
AR
83212015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
8322
8323 * inferiors.c (thread_pid_matches_callback): New function.
8324 (find_thread_process): New function.
8325 (remove_thread): Reset current_thread.
8326 (remove_process): Assert threads have been removed first.
8327
8d689ee5
YQ
83282015-10-15 Yao Qi <yao.qi@linaro.org>
8329
8330 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
8331 if it is 3.
8332 (aarch64_remove_point): Likewise.
8333 * regcache.c (regcache_register_size): New function.
8334
1c2e1515
YQ
83352015-10-12 Yao Qi <yao.qi@linaro.org>
8336
8337 * linux-aarch64-low.c: Update all callers as emit_load_store
8338 is renamed to aarch64_emit_load_store.
8339
e1c587c3
YQ
83402015-10-12 Yao Qi <yao.qi@linaro.org>
8341
8342 * linux-aarch64-low.c: Update all callers of function renaming
8343 from emit_insn to aarch64_emit_insn.
8344
b6542f81
YQ
83452015-10-12 Yao Qi <yao.qi@linaro.org>
8346
8347 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
8348 arch/aarch64-insn.h.
8349 (struct aarch64_memory_operand): Likewise.
8350 (ENCODE): Likewise.
8351 (emit_insn): Move to arch/aarch64-insn.c.
8352 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
8353 (emit_load_store): Move to arch/aarch64-insn.c.
8354 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
8355 (can_encode_int32): Remove.
8356
246994ce
YQ
83572015-10-12 Yao Qi <yao.qi@linaro.org>
8358
8359 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
8360 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
8361 (aarch64_relocate_instruction): Likewise.
8362 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
8363 (struct aarch64_insn_visitor): Likewise.
8364
0badd99f
YQ
83652015-10-12 Yao Qi <yao.qi@linaro.org>
8366
8367 * linux-aarch64-low.c (struct aarch64_insn_data): New.
8368 (struct aarch64_insn_visitor): New.
8369 (struct aarch64_insn_relocation_data): New.
8370 (aarch64_ftrace_insn_reloc_b): New function.
8371 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
8372 (aarch64_ftrace_insn_reloc_cb): Likewise.
8373 (aarch64_ftrace_insn_reloc_tb): Likewise.
8374 (aarch64_ftrace_insn_reloc_adr): Likewise.
8375 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
8376 (aarch64_ftrace_insn_reloc_others): Likewise.
8377 (visitor): New.
8378 (aarch64_relocate_instruction): Use visitor.
8379
dfaffe9d
YQ
83802015-10-12 Yao Qi <yao.qi@linaro.org>
8381
8382 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
8383 int. Add argument buf.
8384 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
8385 aarch64_relocate_instruction.
8386
70b439f0
YQ
83872015-10-12 Yao Qi <yao.qi@linaro.org>
8388
8389 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
8390 argument insn. Remove local variable insn. Don't call
8391 target_read_uint32.
8392 (aarch64_install_fast_tracepoint_jump_pad): Call
8393 target_read_uint32.
8394
7781c06f
YQ
83952015-09-30 Yao Qi <yao.qi@linaro.org>
8396
8397 * linux-aarch64-low.c (emit_movk): Shorten a long line.
8398 (emit_load_store_pair): Likewise.
8399
9a3c8263
SM
84002015-09-25 Simon Marchi <simon.marchi@ericsson.com>
8401
8402 * dll.c (match_dll): Add cast(s).
8403 (unloaded_dll): Likewise.
8404 * linux-low.c (second_thread_of_pid_p): Likewise.
8405 (delete_lwp_callback): Likewise.
8406 (count_events_callback): Likewise.
8407 (select_event_lwp_callback): Likewise.
8408 (linux_set_resume_request): Likewise.
8409 * server.c (accumulate_file_name_length): Likewise.
8410 (emit_dll_description): Likewise.
8411 (handle_qxfer_threads_worker): Likewise.
8412 (visit_actioned_threads): Likewise.
8413 * thread-db.c (any_thread_of): Likewise.
8414 * tracepoint.c (same_process_p): Likewise.
8415 (match_blocktype): Likewise.
8416 (build_traceframe_info_xml): Likewise.
8417
224c3ddb
SM
84182015-09-25 Simon Marchi <simon.marchi@ericsson.com>
8419
8420 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
8421 assignment.
8422 (gdb_unparse_agent_expr): Likewise.
8423 * hostio.c (require_data): Likewise.
8424 (handle_pread): Likewise.
8425 * linux-low.c (disable_regset): Likewise.
8426 (fetch_register): Likewise.
8427 (store_register): Likewise.
8428 (get_dynamic): Likewise.
8429 (linux_qxfer_libraries_svr4): Likewise.
8430 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
8431 (set_fast_tracepoint_jump): Likewise.
8432 (uninsert_fast_tracepoint_jumps_at): Likewise.
8433 (reinsert_fast_tracepoint_jumps_at): Likewise.
8434 (validate_inserted_breakpoint): Likewise.
8435 (clone_agent_expr): Likewise.
8436 * regcache.c (init_register_cache): Likewise.
8437 * remote-utils.c (putpkt_binary_1): Likewise.
8438 (decode_M_packet): Likewise.
8439 (decode_X_packet): Likewise.
8440 (look_up_one_symbol): Likewise.
8441 (relocate_instruction): Likewise.
8442 (monitor_output): Likewise.
8443 * server.c (handle_search_memory): Likewise.
8444 (handle_qxfer_exec_file): Likewise.
8445 (handle_qxfer_libraries): Likewise.
8446 (handle_qxfer): Likewise.
8447 (handle_query): Likewise.
8448 (handle_v_cont): Likewise.
8449 (handle_v_run): Likewise.
8450 (captured_main): Likewise.
8451 * target.c (write_inferior_memory): Likewise.
8452 * thread-db.c (try_thread_db_load_from_dir): Likewise.
8453 * tracepoint.c (init_trace_buffer): Likewise.
8454 (add_tracepoint_action): Likewise.
8455 (add_traceframe): Likewise.
8456 (add_traceframe_block): Likewise.
8457 (cmd_qtdpsrc): Likewise.
8458 (cmd_qtdv): Likewise.
8459 (cmd_qtstatus): Likewise.
8460 (response_source): Likewise.
8461 (response_tsv): Likewise.
8462 (cmd_qtnotes): Likewise.
8463 (gdb_collect): Likewise.
8464 (initialize_tracepoint): Likewise.
8465
afbe19f8
PL
84662015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8467
8468 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
8469 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
8470 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
8471 <NOP>: New.
8472 (enum aarch64_condition_codes): New enum.
8473 (w0): New static global.
8474 (fp): Likewise.
8475 (lr): Likewise.
8476 (struct aarch64_memory_operand) <type>: New
8477 MEMORY_OPERAND_POSTINDEX type.
8478 (postindex_memory_operand): New helper function.
8479 (emit_ret): New function.
8480 (emit_load_store_pair): New function, factored out of emit_stp
8481 with support for MEMORY_OPERAND_POSTINDEX.
8482 (emit_stp): Rewrite using emit_load_store_pair.
8483 (emit_ldp): New function.
8484 (emit_load_store): Likewise.
8485 (emit_ldr): Mention post-index instruction in comment.
8486 (emit_ldrh): New function.
8487 (emit_ldrb): New function.
8488 (emit_ldrsw): Mention post-index instruction in comment.
8489 (emit_str): Likewise.
8490 (emit_subs): New function.
8491 (emit_cmp): Likewise.
8492 (emit_and): Likewise.
8493 (emit_orr): Likewise.
8494 (emit_orn): Likewise.
8495 (emit_eor): Likewise.
8496 (emit_mvn): Likewise.
8497 (emit_lslv): Likewise.
8498 (emit_lsrv): Likewise.
8499 (emit_asrv): Likewise.
8500 (emit_mul): Likewise.
8501 (emit_sbfm): Likewise.
8502 (emit_sbfx): Likewise.
8503 (emit_ubfm): Likewise.
8504 (emit_ubfx): Likewise.
8505 (emit_csinc): Likewise.
8506 (emit_cset): Likewise.
8507 (emit_nop): Likewise.
8508 (emit_ops_insns): New helper function.
8509 (emit_pop): Likewise.
8510 (emit_push): Likewise.
8511 (aarch64_emit_prologue): New function.
8512 (aarch64_emit_epilogue): Likewise.
8513 (aarch64_emit_add): Likewise.
8514 (aarch64_emit_sub): Likewise.
8515 (aarch64_emit_mul): Likewise.
8516 (aarch64_emit_lsh): Likewise.
8517 (aarch64_emit_rsh_signed): Likewise.
8518 (aarch64_emit_rsh_unsigned): Likewise.
8519 (aarch64_emit_ext): Likewise.
8520 (aarch64_emit_log_not): Likewise.
8521 (aarch64_emit_bit_and): Likewise.
8522 (aarch64_emit_bit_or): Likewise.
8523 (aarch64_emit_bit_xor): Likewise.
8524 (aarch64_emit_bit_not): Likewise.
8525 (aarch64_emit_equal): Likewise.
8526 (aarch64_emit_less_signed): Likewise.
8527 (aarch64_emit_less_unsigned): Likewise.
8528 (aarch64_emit_ref): Likewise.
8529 (aarch64_emit_if_goto): Likewise.
8530 (aarch64_emit_goto): Likewise.
8531 (aarch64_write_goto_address): Likewise.
8532 (aarch64_emit_const): Likewise.
8533 (aarch64_emit_call): Likewise.
8534 (aarch64_emit_reg): Likewise.
8535 (aarch64_emit_pop): Likewise.
8536 (aarch64_emit_stack_flush): Likewise.
8537 (aarch64_emit_zero_ext): Likewise.
8538 (aarch64_emit_swap): Likewise.
8539 (aarch64_emit_stack_adjust): Likewise.
8540 (aarch64_emit_int_call_1): Likewise.
8541 (aarch64_emit_void_call_2): Likewise.
8542 (aarch64_emit_eq_goto): Likewise.
8543 (aarch64_emit_ne_goto): Likewise.
8544 (aarch64_emit_lt_goto): Likewise.
8545 (aarch64_emit_le_goto): Likewise.
8546 (aarch64_emit_gt_goto): Likewise.
8547 (aarch64_emit_ge_got): Likewise.
8548 (aarch64_emit_ops_impl): New static global variable.
8549 (aarch64_emit_ops): New target function, return
8550 &aarch64_emit_ops_impl.
8551 (struct linux_target_ops): Install it.
8552
bb903df0
PL
85532015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8554
8555 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
8556 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
8557 aarch64-ipa.o.
8558 * linux-aarch64-ipa.c: New file.
8559 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
8560 and endian.h.
8561 (aarch64_get_thread_area): New target method.
8562 (extract_signed_bitfield): New helper function.
8563 (aarch64_decode_ldr_literal): New function.
8564 (enum aarch64_opcodes): New enum.
8565 (struct aarch64_register): New struct.
8566 (struct aarch64_operand): New struct.
8567 (x0): New static global.
8568 (x1): Likewise.
8569 (x2): Likewise.
8570 (x3): Likewise.
8571 (x4): Likewise.
8572 (w2): Likewise.
8573 (ip0): Likewise.
8574 (sp): Likewise.
8575 (xzr): Likewise.
8576 (aarch64_register): New helper function.
8577 (register_operand): Likewise.
8578 (immediate_operand): Likewise.
8579 (struct aarch64_memory_operand): New struct.
8580 (offset_memory_operand): New helper function.
8581 (preindex_memory_operand): Likewise.
8582 (enum aarch64_system_control_registers): New enum.
8583 (ENCODE): New macro.
8584 (emit_insn): New helper function.
8585 (emit_b): New function.
8586 (emit_bcond): Likewise.
8587 (emit_cb): Likewise.
8588 (emit_tb): Likewise.
8589 (emit_blr): Likewise.
8590 (emit_stp): Likewise.
8591 (emit_ldp_q_offset): Likewise.
8592 (emit_stp_q_offset): Likewise.
8593 (emit_load_store): Likewise.
8594 (emit_ldr): Likewise.
8595 (emit_ldrsw): Likewise.
8596 (emit_str): Likewise.
8597 (emit_ldaxr): Likewise.
8598 (emit_stxr): Likewise.
8599 (emit_stlr): Likewise.
8600 (emit_data_processing_reg): Likewise.
8601 (emit_data_processing): Likewise.
8602 (emit_add): Likewise.
8603 (emit_sub): Likewise.
8604 (emit_mov): Likewise.
8605 (emit_movk): Likewise.
8606 (emit_mov_addr): Likewise.
8607 (emit_mrs): Likewise.
8608 (emit_msr): Likewise.
8609 (emit_sevl): Likewise.
8610 (emit_wfe): Likewise.
8611 (append_insns): Likewise.
8612 (can_encode_int32_in): New helper function.
8613 (aarch64_relocate_instruction): New function.
8614 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
8615 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
8616 (struct linux_target_ops): Install aarch64_get_thread_area,
8617 aarch64_install_fast_tracepoint_jump_pad and
8618 aarch64_get_min_fast_tracepoint_insn_len.
8619
787749ea
PL
86202015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8621
8622 * Makefile.in (aarch64-insn.o): New rule.
8623 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
8624
9812b2e6
YQ
86252015-09-21 Yao Qi <yao.qi@linaro.org>
8626
8627 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
8628
18fe412b
YQ
86292015-09-21 Yao Qi <yao.qi@linaro.org>
8630
8631 * tracepoint.c (max_jump_pad_size): Remove.
8632
a0cc84cd
YQ
86332015-09-18 Yao Qi <yao.qi@linaro.org>
8634
8635 * linux-aarch64-low.c: Don't include sys/uio.h.
8636 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
8637
d78908cf
WW
86382015-09-16 Wei-cheng Wang <cole945@gmail.com>
8639
8640 * tracepoint.c (eval_result_type): Change prototype.
8641 (condition_true_at_tracepoint): Fix argument to compiled_cond.
8642
d57e0d50
PA
86432015-09-15 Pedro Alves <palves@redhat.com>
8644
8645 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
8646 Check whether to report exec events instead of checking whether
8647 multiprocess is enabled.
8648
5a676acc
PA
86492015-09-15 Pedro Alves <palves@redhat.com>
8650
8651 PR remote/18965
8652 * remote-utils.c (prepare_resume_reply): Merge
8653 TARGET_WAITKIND_VFORK_DONE switch case with the
8654 TARGET_WAITKIND_FORKED case.
8655
7c5d0fad
YQ
86562015-09-15 Yao Qi <yao.qi@linaro.org>
8657
8658 * server.c (handle_query): Check string comparison using
8659 "else if" instead of "if".
8660
750ce8d1
YQ
86612015-09-15 Yao Qi <yao.qi@linaro.org>
8662
8663 * server.c (vCont_supported): New global variable.
8664 (handle_query): Set vCont_supported to 1 if "vContSupported+"
8665 matches. Append ";vContSupported+" to own_buf.
8666 (handle_v_requests): Append ";s;S" to own_buf if target supports
8667 hardware single step or vCont_supported is false.
8668 (capture_main): Set vCont_supported to zero.
8669
70b90b91
YQ
86702015-09-15 Yao Qi <yao.qi@linaro.org>
8671
8672 * linux-low.c (linux_supports_conditional_breakpoints): Rename
8673 it to ...
8674 (linux_supports_hardware_single_step): ... New function.
8675 (linux_target_ops): Update.
8676 * lynx-low.c (lynx_target_ops): Set field
8677 supports_hardware_single_step to target_can_do_hardware_single_step.
8678 * nto-low.c (nto_target_ops): Likewise.
8679 * spu-low.c (spu_target_ops): Likewise.
8680 * win32-low.c (win32_target_ops): Likewise.
8681 * target.c (target_can_do_hardware_single_step): New function.
8682 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8683 Remove. <supports_hardware_single_step>: New field.
8684 (target_supports_conditional_breakpoints): Remove.
8685 (target_supports_hardware_single_step): New macro.
8686 (target_can_do_hardware_single_step): Declare.
8687 * server.c (handle_query): Use target_supports_hardware_single_step
8688 instead of target_supports_conditional_breakpoints.
8689
ade90bde
YQ
86902015-09-15 Yao Qi <yao.qi@linaro.org>
8691
8692 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
8693 function.
8694 (struct linux_target_ops the_low_target): Install
8695 aarch64_linux_siginfo_fixup.
8696
94585166
DB
86972015-09-11 Don Breazeal <donb@codesourcery.com>
8698 Luis Machado <lgustavo@codesourcery.com>
8699
8700 * linux-low.c (linux_mourn): Static declaration.
8701 (linux_arch_setup): Move in front of
8702 handle_extended_wait.
8703 (linux_arch_setup_thread): New function.
8704 (handle_extended_wait): Handle exec events. Call
8705 linux_arch_setup_thread. Make event_lwp argument a
8706 pointer-to-a-pointer.
8707 (check_zombie_leaders): Do not check stopped threads.
8708 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
8709 (linux_low_filter_event): Add lwp and thread for exec'ing
8710 non-leader thread if leader thread has been deleted.
8711 Refactor code into linux_arch_setup_thread and call it.
8712 Pass child lwp pointer by reference to handle_extended_wait.
8713 (linux_wait_for_event_filtered): Update comment.
8714 (linux_wait_1): Prevent clobbering exec event status.
8715 (linux_supports_exec_events): New function.
8716 (linux_target_ops) <supports_exec_events>: Initialize new member.
8717 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
8718 new member.
8719 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
8720 * server.c (report_exec_events): New global variable.
8721 (handle_query): Handle qSupported query for exec-events feature.
8722 (captured_main): Initialize report_exec_events.
8723 * server.h (report_exec_events): Declare new global variable.
8724 * target.h (struct target_ops) <supports_exec_events>: New
8725 member.
8726 (target_supports_exec_events): New macro.
8727 * win32-low.c (win32_target_ops) <supports_exec_events>:
8728 Initialize new member.
8729
0568462b
MM
87302015-09-09 Markus Metzger <markus.t.metzger@intel.com>
8731
8732 * linux-low.c (linux_low_enable_btrace): Remove.
8733 (linux_target_ops): Replace linux_low_enable_btrace with
8734 linux_enable_btrace.
8735
39edd165
YQ
87362015-09-03 Yao Qi <yao.qi@linaro.org>
8737
8738 * linux-aarch64-low.c (aarch64_insert_point): Call
8739 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
8740 returns true.
8741
1db33b5a
UW
87422015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8743
8744 * linux-low.c (check_stopped_by_breakpoint): Use
8745 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
8746
ab290430
PA
87472015-08-27 Pedro Alves <palves@redhat.com>
8748
8749 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
8750
8d749320
SM
87512015-08-26 Simon Marchi <simon.marchi@ericsson.com>
8752
6711b7f8
SM
8753 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
8754 the XNEW-family equivalent.
8d749320
SM
8755 (compile_bytecodes): Likewise.
8756 * dll.c (loaded_dll): Likewise.
8757 * event-loop.c (append_callback_event): Likewise.
8758 (create_file_handler): Likewise.
8759 (create_file_event): Likewise.
8760 * hostio.c (handle_open): Likewise.
8761 * inferiors.c (add_thread): Likewise.
8762 (add_process): Likewise.
8763 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
8764 * linux-arm-low.c (arm_new_process): Likewise.
8765 (arm_new_thread): Likewise.
8766 * linux-low.c (add_to_pid_list): Likewise.
8767 (linux_add_process): Likewise.
8768 (handle_extended_wait): Likewise.
8769 (add_lwp): Likewise.
8770 (enqueue_one_deferred_signal): Likewise.
8771 (enqueue_pending_signal): Likewise.
8772 (linux_resume_one_lwp_throw): Likewise.
8773 (linux_resume_one_thread): Likewise.
8774 (linux_read_memory): Likewise.
8775 (linux_write_memory): Likewise.
8776 * linux-mips-low.c (mips_linux_new_process): Likewise.
8777 (mips_linux_new_thread): Likewise.
8778 (mips_add_watchpoint): Likewise.
8779 * linux-x86-low.c (initialize_low_arch): Likewise.
8780 * lynx-low.c (lynx_add_process): Likewise.
8781 * mem-break.c (set_raw_breakpoint_at): Likewise.
8782 (set_breakpoint): Likewise.
8783 (add_condition_to_breakpoint): Likewise.
8784 (add_commands_to_breakpoint): Likewise.
8785 (clone_agent_expr): Likewise.
8786 (clone_one_breakpoint): Likewise.
8787 * regcache.c (new_register_cache): Likewise.
8788 * remote-utils.c (look_up_one_symbol): Likewise.
8789 * server.c (queue_stop_reply): Likewise.
8790 (start_inferior): Likewise.
8791 (queue_stop_reply_callback): Likewise.
8792 (handle_target_event): Likewise.
8793 * spu-low.c (fetch_ppc_memory): Likewise.
8794 (store_ppc_memory): Likewise.
8795 * target.c (set_target_ops): Likewise.
8796 * thread-db.c (thread_db_load_search): Likewise.
8797 (try_thread_db_load_1): Likewise.
8798 * tracepoint.c (add_tracepoint): Likewise.
8799 (add_tracepoint_action): Likewise.
8800 (create_trace_state_variable): Likewise.
8801 (cmd_qtdpsrc): Likewise.
8802 (cmd_qtro): Likewise.
8803 (add_while_stepping_state): Likewise.
8804 * win32-low.c (child_add_thread): Likewise.
8805 (get_image_name): Likewise.
8806
ed8b7b42
YQ
88072015-08-25 Yao Qi <yao.qi@linaro.org>
8808
8809 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
8810
db3cb7cb
YQ
88112015-08-25 Yao Qi <yao.qi@linaro.org>
8812
8813 * Makefile.in (aarch64-linux.o): New rule.
8814 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
8815 srv_tgtobj.
8816 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
8817 (aarch64_init_debug_reg_state): Make it extern.
8818 (aarch64_linux_prepare_to_resume): Remove.
8819
f6011a1c
YQ
88202015-08-25 Yao Qi <yao.qi@linaro.org>
8821
8822 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
8823 lwp_arch_private_info and ptid_of_lwp.
8824
88e2cf7e
YQ
88252015-08-25 Yao Qi <yao.qi@linaro.org>
8826
8827 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
8828 Find proc_info by find_process_pid. All callers updated.
8829
5e35436e
YQ
88302015-08-25 Yao Qi <yao.qi@linaro.org>
8831
8832 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
8833 Remove.
8834 (debug_reg_change_callback): Remove.
8835 (aarch64_notify_debug_reg_change): Remove.
8836
4a8a7965
YQ
88372015-08-25 Yao Qi <yao.qi@linaro.org>
8838
8839 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
8840 Call current_lwp_ptid.
8841
32a271ee
YQ
88422015-08-25 Yao Qi <yao.qi@linaro.org>
8843
8844 * linux-aarch64-low.c (debug_reg_change_callback): Use
8845 debug_printf.
8846
0d51c8d7
YQ
88472015-08-25 Yao Qi <yao.qi@linaro.org>
8848
8849 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
8850
31a43dd5
YQ
88512015-08-25 Yao Qi <yao.qi@linaro.org>
8852
8853 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
8854
8ee52567
YQ
88552015-08-25 Yao Qi <yao.qi@linaro.org>
8856
8857 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
8858 the code.
8859
ff3f0f45
YQ
88602015-08-25 Yao Qi <yao.qi@linaro.org>
8861
8862 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
8863 Remove.
8864 (debug_reg_change_callback): Remove argument entry and add argument
8865 lwp. Remove local variable thread. Don't print thread id in the
8866 debugging output. Don't check whether pid of thread equals to pid.
8867 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
8868 iterate_over_lwps instead find_inferior.
8869
3d40fbb5
PA
88702015-08-24 Pedro Alves <palves@redhat.com>
8871
8872 * inferiors.c (get_first_process): New function.
8873 * inferiors.h (get_first_process): New declaration.
8874 * remote-utils.c (read_ptid): Default to the first process in the
8875 list, instead of to the current thread's process.
8876
438e1e42
PA
88772015-08-24 Pedro Alves <palves@redhat.com>
8878
8879 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
8880 * event-loop.c: Likewise.
8881 * remote-utils.c: Likewise.
8882 * tracepoint.c: Likewise.
8883
a8c6d4fc
PA
88842015-08-24 Pedro Alves <palves@redhat.com>
8885
8886 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
8887 ptid_get_lwp.
8888
99b0bb12
PA
88892015-08-21 Pedro Alves <palves@redhat.com>
8890
8891 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
8892 instead of literal 1.
8893
f8904751
PA
88942015-08-21 Pedro Alves <palves@redhat.com>
8895
8896 * tdesc.c (default_description): Explicitly zero-initialize.
8897
465a859e
PA
88982015-08-21 Pedro Alves <palves@redhat.com>
8899
8900 PR gdb/18749
8901 * inferiors.c (remove_thread): Discard any pending stop reply for
8902 this thread.
8903 * server.c (remove_all_on_match_pid): Rename to ...
8904 (remove_all_on_match_ptid): ... this. Work with a filter ptid
8905 instead of a pid.
8906 (discard_queued_stop_replies): Change parameter to a ptid. Now
8907 extern.
8908 (handle_v_kill, kill_inferior_callback, captured_main)
8909 (process_serial_event): Adjust.
8910 * server.h (discard_queued_stop_replies): Declare.
8911
f0db101d
PA
89122015-08-21 Pedro Alves <palves@redhat.com>
8913
8914 * linux-low.c (wait_for_sigstop): Always switch to no thread
8915 selected if the previously current thread dies.
8916 * lynx-low.c (lynx_request_interrupt): Use the first thread's
8917 process instead of the current thread's.
8918 * remote-utils.c (input_interrupt): Don't check if there's no
8919 current thread.
8920 * server.c (gdb_read_memory, gdb_write_memory): If setting the
8921 current thread to the general thread fails, error out.
8922 (handle_qxfer_auxv, handle_qxfer_libraries)
8923 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
8924 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
8925 (handle_query): Check if there's a thread selected instead of
8926 checking whether there's any thread in the thread list.
8927 (handle_qxfer_threads, handle_qxfer_btrace)
8928 (handle_qxfer_btrace_conf): Don't error out early if there's no
8929 thread in the thread list.
8930 (handle_v_cont, myresume): Don't set the current thread to the
8931 continue thread.
8932 (process_serial_event) <Hg handling>: Also set thread_id if the
8933 previous general thread is still alive.
8934 (process_serial_event) <g/G handling>: If setting the current
8935 thread to the general thread fails, error out.
8936 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
8937 thread's lwp instead of the current thread's.
8938 * target.c (set_desired_thread): If the desired thread was not
8939 found, leave the current thread pointing to NULL. Return an int
8940 (boolean) indicating success.
8941 * target.h (set_desired_thread): Change return type to int.
8942
40045d91
MF
89432015-08-20 Max Filippov <jcmvbkbc@gmail.com>
8944
8945 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
8946 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
8947 #includes.
8948 (ps_get_thread_area): New function.
8949
45face3b
GB
89502015-08-19 Gary Benson <gbenson@redhat.com>
8951
8952 * hostio.c (handle_pread): Do not attempt to read more data
8953 than hostio_reply_with_data can fit in a packet.
8954
16d5f642
JB
89552015-08-18 Joel Brobecker <brobecker@adacore.com>
8956
8957 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
8958
a738da3a
MF
89592015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
8960
8961 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
8962
33ebda9d
PA
89632015-08-06 Pedro Alves <palves@redhat.com>
8964
8965 * tracepoint.c (expr_eval_result): Now an int.
8966
a44892be
PA
89672015-08-06 Pedro Alves <palves@redhat.com>
8968
8969 * gdbthread.h (struct regcache): Forward declare.
8970 (struct thread_info) <regcache_data>: Now a struct regcache
8971 pointer.
8972 * inferiors.c (inferior_regcache_data)
8973 (set_inferior_regcache_data): Now work with struct regcache
8974 pointers.
8975 * inferiors.h (struct regcache): Forward declare.
8976 (inferior_regcache_data, set_inferior_regcache_data): Now work
8977 with struct regcache pointers.
8978 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
8979 (free_register_cache_thread): Remove struct regcache pointer
8980 casts.
8981
608a1e46
PA
89822015-08-06 Pedro Alves <palves@redhat.com>
8983
8984 * server.c (captured_main): On error, print the exception message
8985 to stderr, and if run_once is set, throw a quit.
8986
f0ce0d3a
PA
89872015-08-06 Pedro Alves <palves@redhat.com>
8988
8989 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
8990 the current thread.
8991
bf47e248
PA
89922015-08-06 Pedro Alves <palves@redhat.com>
8993
8994 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
8995 reading beyond the passed in buffer length.
8996
b6b9ffcc
PL
89972015-08-06 Pierre Langlois <pierre.langlois@arm.com>
8998
8999 * tracepoint.c (symbol_list) <required>: Remove.
9000
863d01bd
PA
90012015-08-06 Pedro Alves <palves@redhat.com>
9002
9003 * linux-low.c (handle_extended_wait): Set the fork child's suspend
9004 count if stopping and suspending threads.
9005 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
9006 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
9007 (linux_detach): Complete an ongoing step-over.
9008 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
9009 throughout.
9010 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
9011 (linux_wait_1): If passing a signal to the inferior after
9012 finishing a step-over, unsuspend and re-resume all lwps. If we
9013 see a single-step event but the thread should be continuing, don't
9014 pass the trap to gdb.
9015 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
9016 internal_error instead of gdb_assert.
9017 (enqueue_pending_signal): New function.
9018 (check_ptrace_stopped_lwp_gone): Add debug output.
9019 (start_step_over): Use internal_error instead of gdb_assert.
9020 (complete_ongoing_step_over): New function.
9021 (linux_resume_one_thread): Don't resume a suspended thread.
9022 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
9023 it stepping.
9024
00db26fa
PA
90252015-08-06 Pedro Alves <palves@redhat.com>
9026
9027 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
9028 (linux_thread_alive): Use lwp_is_marked_dead.
9029 (extended_event_reported): Delete.
9030 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
9031 instead of extended_event_reported.
9032 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
9033 as well.
9034 (lwp_is_marked_dead): New function.
9035 (lwp_running): Use lwp_is_marked_dead.
9036 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
9037 comment.
9038
ad071a30
PA
90392015-08-06 Pedro Alves <palves@redhat.com>
9040
9041 * linux-low.c (linux_wait_1): Move fork event output out of the
9042 !report_to_gdb check. Pass event_child->waitstatus to
9043 target_waitstatus_to_string instead of ourstatus.
9044
524b57e6
YQ
90452015-08-04 Yao Qi <yao.qi@linaro.org>
9046
9047 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
9048 if current_thread is 32 bit.
9049
6085d6f6
YQ
90502015-08-04 Yao Qi <yao.qi@linaro.org>
9051
9052 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9053 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9054 * server.c (extended_protocol): Remove "static".
9055 * server.h (extended_protocol): Declare it.
9056
8a7e4587
YQ
90572015-08-04 Yao Qi <yao.qi@linaro.org>
9058
9059 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
9060 both aarch64 and aarch32.
9061 (aarch64_set_pc): Likewise.
9062
3b53ae99
YQ
90632015-08-04 Yao Qi <yao.qi@linaro.org>
9064
9065 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
9066 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
9067 arm-with-neon.xml to srv_xmlfiles.
9068 * linux-aarch64-low.c: Include linux-aarch32-low.h.
9069 (is_64bit_tdesc): New function.
9070 (aarch64_linux_read_description): New function.
9071 (aarch64_arch_setup): Call aarch64_linux_read_description.
9072 (regs_info): Rename to regs_info_aarch64.
9073 (aarch64_regs_info): Return right regs_info.
9074 (initialize_low_arch): Call initialize_low_arch_aarch32.
9075
bd9e6534
YQ
90762015-08-04 Yao Qi <yao.qi@linaro.org>
9077
9078 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
9079 * linux-aarch32-low.c: New file.
9080 * linux-aarch32-low.h: New file.
9081 * linux-arm-low.c (arm_fill_gregset): Move it to
9082 linux-aarch32-low.c.
9083 (arm_store_gregset): Likewise.
9084 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
9085 (arm_store_vfpregset): Call arm_store_vfpregset_num.
9086 (arm_arch_setup): Check if PTRACE_GETREGSET works.
9087 (regs_info): Rename to regs_info_arm.
9088 (arm_regs_info): Return regs_info_aarch32 if
9089 have_ptrace_getregset is 1 and target description is
9090 arm_with_neon or arm_with_vfpv3.
9091 (initialize_low_arch): Don't call init_registers_arm_with_neon.
9092 Call initialize_low_arch_aarch32 instead.
9093
ded48a5e
YQ
90942015-08-04 Yao Qi <yao.qi@linaro.org>
9095
9096 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
9097 * linux-low.c: ... here.
9098 * linux-low.h (have_ptrace_getregset): Declare it.
9099
96e9210f
PA
91002015-08-04 Pedro Alves <palves@redhat.com>
9101
9102 * thread-db.c (struct thread_db): Use new typedefs.
9103 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
9104 CHK calls.
9105 (disable_thread_event_reporting): Cast result of dlsym to
9106 destination function pointer type.
9107 (thread_db_mourn): Use td_ta_delete_ftype.
9108
af60a1ef
SL
91092015-08-03 Sandra Loosemore <sandra@codesourcery.com>
9110
9111 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
9112 arch variant.
9113 (CDX_BREAKPOINT): Define for R2.
9114 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
9115 (the_low_target): Add comments.
9116
e8b41681
YQ
91172015-07-30 Yao Qi <yao.qi@linaro.org>
9118
9119 * linux-arm-low.c (arm_hwcap): Remove it.
9120 (arm_read_description): New local variable arm_hwcap. Don't
9121 set arm_hwcap to zero.
9122
89abb039
YQ
91232015-07-30 Yao Qi <yao.qi@linaro.org>
9124
9125 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
9126 Use regcache->tdesc instead.
9127 (arm_store_wmmxregset): Likewise.
9128 (arm_fill_vfpregset): Likewise.
9129 (arm_store_vfpregset): Likewise.
9130
deca266c
YQ
91312015-07-30 Yao Qi <yao.qi@linaro.org>
9132
9133 * linux-arm-low.c: Include arch/arm.h.
9134 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
9135 (arm_store_gregset): Likewise.
9136
aa58a496
SM
91372015-07-29 Simon Marchi <simon.marchi@ericsson.com>
9138
9139 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
9140 ptrace's 4th parameter.
9141
50904b25
YQ
91422015-07-27 Yao Qi <yao.qi@linaro.org>
9143
9144 * configure.srv (case aarch64*-*-linux*): Don't set
9145 srv_linux_usrregs.
9146
5826e159
PA
91472015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
9148
9149 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
9150 sys/ptrace.h.
9151 * linux-arm-low.c: Likewise.
9152 * linux-cris-low.c: Likewise.
9153 * linux-crisv32-low.c: Likewise.
9154 * linux-low.c: Likewise.
9155 * linux-m68k-low.c: Likewise.
9156 * linux-mips-low.c: Likewise.
9157 * linux-nios2-low.c: Likewise.
9158 * linux-s390-low.c: Likewise.
9159 * linux-sparc-low.c: Likewise.
9160 * linux-tic6x-low.c: Likewise.
9161 * linux-tile-low.c: Likewise.
9162 * linux-x86-low.c: Likewise.
9163
54019719
PA
91642015-07-24 Pedro Alves <palves@redhat.com>
9165
9166 * config.in: Regenerate.
9167 * configure: Regenerate.
9168
eb7aa561
PA
91692015-07-24 Pedro Alves <palves@redhat.com>
9170
9171 * acinclude.m4: Include ../ptrace.m4.
9172 * configure.ac: Call GDB_AC_PTRACE.
9173 * config.in, configure: Regenerate.
9174
55d7b841
YQ
91752015-07-24 Yao Qi <yao.qi@linaro.org>
9176
9177 * linux-low.c (linux_create_inferior): Remove setting to
9178 proc->priv->new_inferior.
9179 (linux_attach): Likewise.
9180 (linux_low_filter_event): Likewise.
9181 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
9182
c06cbd92
YQ
91832015-07-24 Yao Qi <yao.qi@linaro.org>
9184
9185 * linux-low.c (linux_arch_setup): New function.
9186 (linux_low_filter_event): If proc->tdesc is NULL and
9187 proc->attached is true, call the_low_target.arch_setup.
9188 Otherwise, keep status pending, and return.
9189 (linux_resume_one_lwp_throw): Don't call get_pc if
9190 thread->while_stepping isn't NULL. Don't call
9191 get_thread_regcache if proc->tdesc is NULL.
9192 (need_step_over_p): Return 0 if proc->tdesc is NULL.
9193 (linux_target_ops): Install arch_setup.
9194 * server.c (start_inferior): Call the_target->arch_setup.
9195 * target.h (struct target_ops) <arch_setup>: New field.
9196 (target_arch_setup): New marco.
9197 * lynx-low.c (lynx_target_ops): Update.
9198 * nto-low.c (nto_target_ops): Update.
9199 * spu-low.c (spu_target_ops): Update.
9200 * win32-low.c (win32_target_ops): Update.
9201
5ae3ebba
YQ
92022015-07-24 Yao Qi <yao.qi@linaro.org>
9203
9204 * linux-low.c (linux_add_process): Don't set
9205 proc->priv->new_inferior.
9206 (linux_create_inferior): Set proc->priv->new_inferior to 1.
9207 (linux_attach): Likewise.
9208
eb97750b
YQ
92092015-07-24 Yao Qi <yao.qi@linaro.org>
9210
9211 * server.c (start_inferior): Code refactor.
9212
51aee833
YQ
92132015-07-24 Yao Qi <yao.qi@linaro.org>
9214
9215 * server.c (process_serial_event): Set general_thread.
9216
af1b22f3
YQ
92172015-07-21 Yao Qi <yao.qi@linaro.org>
9218
9219 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
9220 aarch64_linux_get_debug_reg_capacity.
9221
554717a3
YQ
92222015-07-17 Yao Qi <yao.qi@linaro.org>
9223
9224 * Makefile.in (aarch64-linux-hw-point.o): New rule.
9225 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
9226 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
9227 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
9228 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
9229 (AARCH64_HWP_ALIGNMENT): Likewise.
9230 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
9231 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
9232 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
9233 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
9234 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
9235 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
9236 (struct aarch64_debug_reg_state): Likewise.
9237 (struct arch_lwp_info): Likewise.
9238 (aarch64_align_watchpoint): Likewise.
9239 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
9240 (aarch64_watchpoint_length): Likewise.
9241 (aarch64_point_encode_ctrl_reg): Likewise
9242 (aarch64_point_is_aligned): Likewise.
9243 (aarch64_align_watchpoint): Likewise.
9244 (aarch64_linux_set_debug_regs):
9245 (aarch64_dr_state_insert_one_point): Likewise.
9246 (aarch64_dr_state_remove_one_point): Likewise.
9247 (aarch64_handle_breakpoint): Likewise.
9248 (aarch64_handle_aligned_watchpoint): Likewise.
9249 (aarch64_handle_unaligned_watchpoint): Likewise.
9250 (aarch64_handle_watchpoint): Likewise.
9251
c67ca4de
YQ
92522015-07-17 Yao Qi <yao.qi@linaro.org>
9253
9254 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
9255 and don't aarch64_get_debug_reg_state. All callers update.
9256 (aarch64_handle_aligned_watchpoint): Likewise.
9257 (aarch64_handle_unaligned_watchpoint): Likewise.
9258 (aarch64_handle_watchpoint): Likewise.
9259 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
9260 (aarch64_remove_point): Likewise.
9261
25abf979
YQ
92622015-07-17 Yao Qi <yao.qi@linaro.org>
9263
9264 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
9265 debug_printf.
9266 (aarch64_handle_unaligned_watchpoint): Likewise.
9267
db1ff28b
JK
92682015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9269
9270 Revert the previous 3 commits:
9271 Move gdb_regex* to common/
9272 Move linux_find_memory_regions_full & co.
9273 gdbserver build-id attribute generator
9274
700ca40f
JK
92752015-07-15 Aleksandar Ristovski <aristovski@qnx.com
9276 Jan Kratochvil <jan.kratochvil@redhat.com>
9277
9278 gdbserver build-id attribute generator.
9279 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
9280 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
9281 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
9282 (find_phdr): New.
9283 (get_dynamic): Use find_pdhr to traverse program headers.
9284 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
9285 (compare_mapping_entry_range, struct find_memory_region_callback_data)
9286 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
9287 (get_hex_build_id): New.
9288 (linux_qxfer_libraries_svr4): Add optional build-id attribute
9289 to reply XML document.
9290
9904185c
JK
92912015-07-15 Aleksandar Ristovski <aristovski@qnx.com
9292 Jan Kratochvil <jan.kratochvil@redhat.com>
9293
9294 * target.c: Include target/target-utils.h and fcntl.h.
9295 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
9296 (target_fileio_read_stralloc): New functions.
9297
6e5b4429
JK
92982015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9299
9300 * Makefile.in (OBS): Add gdb_regex.o.
9301 (gdb_regex.o): New.
9302 * config.in: Rebuilt.
9303 * configure: Rebuilt.
9304
ddc98fbf
JK
93052015-07-15 Aleksandar Ristovski <aristovski@qnx.com
9306 Jan Kratochvil <jan.kratochvil@redhat.com>
9307
9308 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
9309 * Makefile.in (OBS): Add target-utils.o.
9310 (linux-maps.o, target-utils.o): New.
9311 * configure.srv (srv_linux_obj): Add linux-maps.o.
9312
e57bb7a0
PL
93132015-07-15 Pierre Langlois <pierre.langlois@arm.com>
9314
9315 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
9316 function, return 1.
9317 (the_low_target): Install it.
9318
586b02a9
PA
93192015-07-14 Pedro Alves <palves@redhat.com>
9320
9321 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
9322 Instead, ignore ECHILD, and throw an error for other errnos.
9323
58c1b36c
PA
93242015-07-10 Pedro Alves <palves@redhat.com>
9325
9326 * event-loop.c (struct callback_event) <data>: Change type to
9327 gdb_client_data instance instead of gdb_client_data pointer.
9328 (append_callback_event): Adjust.
9329
421530db
PL
93302015-07-10 Pierre Langlois <pierre.langlois@arm.com>
9331
9332 * linux-aarch64-low.c: Add comments for each linux_target_ops
9333 method. Remove comments already covered in target_ops and
9334 linux_target_ops definitions.
9335 (the_low_target): Add comments for each unimplemented method.
9336
c2d65f38
YQ
93372015-07-09 Yao Qi <yao.qi@linaro.org>
9338
9339 * linux-aarch64-low.c (aarch64_regmap): Remove.
9340 (aarch64_usrregs_info): Remove.
9341 (regs_info): Set field usrregs to NULL.
9342
b20a6524
MM
93432015-07-02 Markus Metzger <markus.t.metzger@intel.com>
9344
9345 * linux-low.c: Include "rsp-low.h"
9346 (linux_low_encode_pt_config, linux_low_encode_raw): New.
9347 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
9348 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
9349 (handle_btrace_enable_pt): New.
9350 (handle_btrace_general_set): Support "pt".
9351 (handle_btrace_conf_general_set): Support "pt:size".
9352
96c97461
PL
93532015-06-29 Pierre Langlois <pierre.langlois@arm.com>
9354
9355 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
9356 Z_PACKET_SW_BP.
9357
37d66942
PL
93582015-06-29 Pierre Langlois <pierre.langlois@arm.com>
9359
9360 * linux-aarch64-low.c: Remove comment about endianness.
9361 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
9362 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
9363 memcmp.
9364
dc06243f
GB
93652015-06-24 Gary Benson <gbenson@redhat.com>
9366
9367 * linux-i386-ipa.c (stdint.h): Do not include.
9368 * lynx-i386-low.c (stdint.h): Likewise.
9369 * lynx-ppc-low.c (stdint.h): Likewise.
9370 * mem-break.c (stdint.h): Likewise.
9371 * thread-db.c (stdint.h): Likewise.
9372 * tracepoint.c (stdint.h): Likewise.
9373 * win32-low.c (stdint.h): Likewise.
9374
124e13d9
SM
93752015-06-18 Simon Marchi <simon.marchi@ericsson.com>
9376
9377 * server.c (write_qxfer_response): Update call to
9378 remote_escape_output.
9379
909c2cda
JK
93802015-06-15 Aleksandar Ristovski <aristovski@qnx.com
9381 Jan Kratochvil <jan.kratochvil@redhat.com>
9382
9383 Merge multiple hex conversions.
9384 * gdbreplay.c (tohex): Rename to 'fromhex'.
9385 (logchar): Use fromhex.
9386
24c05f46
JK
93872015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
9388
9389 * server.c (handle_qxfer_libraries): Set `version' attribute for
9390 <library-list>.
9391
14d2069a
GB
93922015-06-10 Gary Benson <gbenson@redhat.com>
9393
9394 * target.h (struct target_ops) <multifs_open>: New field.
9395 <multifs_unlink>: Likewise.
9396 <multifs_readlink>: Likewise.
9397 * linux-low.c (nat/linux-namespaces.h): New include.
9398 (linux_target_ops): Initialize the_target->multifs_open,
9399 the_target->multifs_unlink and the_target->multifs_readlink.
9400 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
9401 * hostio.c (hostio_fs_pid): New static variable.
9402 (hostio_handle_new_gdb_connection): New function.
9403 (handle_setfs): Likewise.
9404 (handle_open): Use the_target->multifs_open as appropriate.
9405 (handle_unlink): Use the_target->multifs_unlink as appropriate.
9406 (handle_readlink): Use the_target->multifs_readlink as
9407 appropriate.
9408 (handle_vFile): Handle vFile:setfs packets.
9409 * server.c (handle_query): Call hostio_handle_new_gdb_connection
9410 after target_handle_new_gdb_connection.
9411
4b8b5e72
GB
94122015-06-10 Gary Benson <gbenson@redhat.com>
9413
9414 * configure.ac (AC_CHECK_FUNCS): Add setns.
9415 * config.in: Regenerate.
9416 * configure: Likewise.
9417 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
9418 (linux-namespaces.o): New rule.
9419 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
9420
3ac2e371
GB
94212015-06-09 Gary Benson <gbenson@redhat.com>
9422
9423 * hostio.c (handle_open): Process mode argument with
9424 fileio_to_host_mode.
9425
ca9b78ce
YQ
94262015-06-01 Yao Qi <yao.qi@linaro.org>
9427
9428 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
9429 * linux-x86-low.c: Likewise.
9430
bfacd19d
DB
94312015-05-28 Don Breazeal <donb@codesourcery.com>
9432
9433 * linux-low.c (handle_extended_wait): Initialize
9434 thread_info.last_resume_kind for new fork children.
9435
452003ef
PA
94362015-05-15 Pedro Alves <palves@redhat.com>
9437
9438 * target.h (target_handle_new_gdb_connection): Rewrite using if
9439 wrapped in do/while.
9440
1041a03c
JB
94412015-05-14 Joel Brobecker <brobecker@adacore.com>
9442
9443 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
9444 * configure, config.in: Regenerate.
9445 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
9446 Declare typedef.
9447
c269dbdb
DB
94482015-05-12 Don Breazeal <donb@codesourcery.com>
9449
9450 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
9451 PTRACE_EVENT_VFORK_DONE.
9452 (linux_low_ptrace_options, extended_event_reported): Add vfork
9453 events.
9454 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
9455 and "vforkdone" for RSP 'T' Stop Reply Packet.
9456 * server.h (report_vfork_events): Declare
9457 global variable.
9458
3a8a0396
DB
94592015-05-12 Don Breazeal <donb@codesourcery.com>
9460
9461 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
9462 (the_low_target) <new_fork>: Initialize new member.
9463 * linux-arm-low.c (arm_new_fork): New function.
9464 (the_low_target) <new_fork>: Initialize new member.
9465 * linux-low.c (handle_extended_wait): Call new target function
9466 new_fork.
9467 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
9468 * linux-mips-low.c (mips_add_watchpoint): New function
9469 extracted from mips_insert_point.
9470 (the_low_target) <new_fork>: Initialize new member.
9471 (mips_linux_new_fork): New function.
9472 (mips_insert_point): Call mips_add_watchpoint.
9473 * linux-x86-low.c (x86_linux_new_fork): New function.
9474 (the_low_target) <new_fork>: Initialize new member.
9475
de0d863e
DB
94762015-05-12 Don Breazeal <donb@codesourcery.com>
9477
9478 * linux-low.c (handle_extended_wait): Implement return value,
9479 rename argument 'event_child' to 'event_lwp', handle
9480 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
9481 (linux_low_ptrace_options): New function.
9482 (linux_low_filter_event): Call linux_low_ptrace_options,
9483 use different argument fo linux_enable_event_reporting,
9484 use return value from handle_extended_wait.
9485 (extended_event_reported): New function.
9486 (linux_wait_1): Call extended_event_reported and set
9487 status to report fork events.
9488 (linux_write_memory): Add pid to debug message.
9489 (reset_lwp_ptrace_options_callback): New function.
9490 (linux_handle_new_gdb_connection): New function.
9491 (linux_target_ops): Initialize new structure member.
9492 * linux-low.h (struct lwp_info) <waitstatus>: New member.
9493 * lynx-low.c: Initialize new structure member.
9494 * remote-utils.c (prepare_resume_reply): Implement stop reason
9495 "fork" for "T" stop message.
9496 * server.c (handle_query): Call handle_new_gdb_connection.
9497 * server.h (report_fork_events): Declare global flag.
9498 * target.h (struct target_ops) <handle_new_gdb_connection>:
9499 New member.
9500 (target_handle_new_gdb_connection): New macro.
9501 * win32-low.c: Initialize new structure member.
9502
ddcbc397
DB
95032015-05-12 Don Breazeal <donb@codesourcery.com>
9504
9505 * mem-break.c (APPEND_TO_LIST): Define macro.
9506 (clone_agent_expr): New function.
9507 (clone_one_breakpoint): New function.
9508 (clone_all_breakpoints): New function.
9509 * mem-break.h: Declare new functions.
9510
89245bc0
DB
95112015-05-12 Don Breazeal <donb@codesourcery.com>
9512
9513 * linux-low.c (linux_supports_fork_events): New function.
9514 (linux_supports_vfork_events): New function.
9515 (linux_target_ops): Initialize new structure members.
9516 (initialize_low): Call linux_check_ptrace_features.
9517 * lynx-low.c (lynx_target_ops): Initialize new structure
9518 members.
9519 * server.c (report_fork_events, report_vfork_events):
9520 New global flags.
9521 (handle_query): Add new features to qSupported packet and
9522 response.
9523 (captured_main): Initialize new global variables.
9524 * target.h (struct target_ops) <supports_fork_events>:
9525 New member.
9526 <supports_vfork_events>: New member.
9527 (target_supports_fork_events): New macro.
9528 (target_supports_vfork_events): New macro.
9529 * win32-low.c (win32_target_ops): Initialize new structure
9530 members.
9531
835205d0
GB
95322015-05-12 Gary Benson <gbenson@redhat.com>
9533
9534 * server.c (handle_qxfer_exec_file): Use current process
9535 if annex is empty.
9536
21e94bd9
SL
95372015-05-08 Sandra Loosemore <sandra@codesourcery.com>
9538
9539 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
9540 Remove HAVE_PTRACE_GETREGS conditionals.
9541 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
9542 instead of PTRACE_GETREGS and PTRACE_SETREGS.
9543
45614f15
YQ
95442015-05-08 Yao Qi <yao.qi@linaro.org>
9545
9546 * linux-low.c (linux_supports_conditional_breakpoints): New
9547 function.
9548 (linux_target_ops): Install new target method.
9549 * lynx-low.c (lynx_target_ops): Install NULL hook for
9550 supports_conditional_breakpoints.
9551 * nto-low.c (nto_target_ops): Likewise.
9552 * spu-low.c (spu_target_ops): Likewise.
9553 * win32-low.c (win32_target_ops): Likewise.
9554 * server.c (handle_query): Check
9555 target_supports_conditional_breakpoints.
9556 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9557 New field.
9558 (target_supports_conditional_breakpoints): New macro.
9559
80ad801e
PA
95602015-05-06 Pedro Alves <palves@redhat.com>
9561
9562 PR server/18081
9563 * server.c (start_inferior): If the process exits, mourn it.
9564
819843c7
GB
95652015-04-21 Gary Benson <gbenson@redhat.com>
9566
9567 * hostio.c (fileio_open_flags_to_host): Factored out to
9568 fileio_to_host_openflags in common/fileio.c. Single use
9569 updated.
9570
a2d5a9d7
MF
95712015-04-17 Max Filippov <jcmvbkbc@gmail.com>
9572
9573 * linux-xtensa-low.c (xtensa_fill_gregset)
9574 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
9575 XCHAL_HAVE_LOOP.
9576
deb44829
MF
95772015-04-17 Max Filippov <jcmvbkbc@gmail.com>
9578
9579 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
9580 (regs_info): Replace usrregs pointer with NULL.
9581
e57f1de3
GB
95822015-04-17 Gary Benson <gbenson@redhat.com>
9583
9584 * target.h (struct target_ops) <pid_to_exec_file>: New field.
9585 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
9586 * server.c (handle_qxfer_exec_file): New function.
9587 (qxfer_packets): Add exec-file entry.
9588 (handle_query): Report qXfer:exec-file:read as supported packet.
9589
62828379
RN
95902015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
9591
9592 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
9593
b88bb450
GB
95942015-04-09 Gary Benson <gbenson@redhat.com>
9595
9596 * hostio-errno.c (errno_to_fileio_error): Remove function.
9597 Update caller to use remote_fileio_to_fio_error.
9598
c8f4bfdd
YQ
95992015-04-09 Yao Qi <yao.qi@linaro.org>
9600
9601 * linux-low.c (linux_insert_point): Call
9602 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
9603 (linux_remove_point): Call remove_memory_breakpoint if type is
9604 raw_bkpt_type_sw.
9605 * linux-x86-low.c (x86_insert_point): Don't call
9606 insert_memory_breakpoint.
9607 (x86_remove_point): Don't call remove_memory_breakpoint.
9608
41f98f02
PA
96092015-04-01 Pedro Alves <palves@redhat.com>
9610 Cleber Rosa <crosa@redhat.com>
9611
9612 * server.c (gdbserver_usage): Reorganize and extend the usage
9613 message.
9614
2bf6fb9d
PA
96152015-03-24 Pedro Alves <palves@redhat.com>
9616
9617 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
9618 output. Also dump TRAP_TRACE.
9619 (linux_low_filter_event): In debug output, distinguish a
9620 resume_stop SIGSTOP from a delayed SIGSTOP.
9621
369f6daa
GB
96222015-03-24 Gary Benson <gbenson@redhat.com>
9623
9624 * linux-x86-low.c (x86_linux_new_thread): Moved to
9625 nat/x86-linux.c.
9626 (x86_linux_prepare_to_resume): Likewise.
9627
8e5d4070
GB
96282015-03-24 Gary Benson <gbenson@redhat.com>
9629
9630 * Makefile.in (x86-linux-dregs.o): New rule.
9631 * configure.srv: Add x86-linux-dregs.o to relevant targets.
9632 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
9633 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
9634 (x86_linux_dr_get): Likewise.
9635 (x86_linux_dr_set): Likewise.
9636 (update_debug_registers_callback): Likewise.
9637 (x86_linux_dr_set_addr): Likewise.
9638 (x86_linux_dr_get_addr): Likewise.
9639 (x86_linux_dr_set_control): Likewise.
9640 (x86_linux_dr_get_control): Likewise.
9641 (x86_linux_dr_get_status): Likewise.
9642 (x86_linux_update_debug_registers): Likewise.
9643
2b95d440
GB
96442015-03-24 Gary Benson <gbenson@redhat.com>
9645
9646 * linux-x86-low.c (x86_linux_update_debug_registers):
9647 New function, factored out from...
9648 (x86_linux_prepare_to_resume): ...this.
9649
14b0bc68
GB
96502015-03-24 Gary Benson <gbenson@redhat.com>
9651
9652 * linux-x86-low.c (x86_linux_dr_get): Update comments.
9653 (x86_linux_dr_set): Likewise.
9654 (update_debug_registers_callback): Likewise.
9655 (x86_linux_dr_set_addr): Likewise.
9656 (x86_linux_dr_get_addr): Likewise.
9657 (x86_linux_dr_set_control): Likewise.
9658 (x86_linux_dr_get_control): Likewise.
9659 (x86_linux_dr_get_status): Likewise.
9660 (x86_linux_prepare_to_resume): Likewise.
9661
5dfe6ca8
GB
96622015-03-24 Gary Benson <gbenson@redhat.com>
9663
9664 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
9665 Use perror_with_name. Pass string through gettext.
9666 (x86_linux_dr_set): Likewise.
9667
d33472ad
GB
96682015-03-24 Gary Benson <gbenson@redhat.com>
9669
9670 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
9671 (x86_linux_dr_set_addr): ...this.
9672 (x86_dr_low_get_addr): Rename to...
9673 (x86_linux_dr_get_addr): ...this.
9674 (x86_dr_low_set_control): Rename to...
9675 (x86_linux_dr_set_control): ...this.
9676 (x86_dr_low_get_control): Rename to...
9677 (x86_linux_dr_get_control): ...this.
9678 (x86_dr_low_get_status): Rename to...
9679 (x86_linux_dr_get_status): ...this.
9680 (x86_dr_low): Update with new function names.
9681
4b134ca1
GB
96822015-03-24 Gary Benson <gbenson@redhat.com>
9683
9684 * Makefile.in (x86-linux.o): New rule.
9685 * configure.srv: Add x86-linux.o to relevant targets.
9686 * linux-low.c (lwp_set_arch_private_info): New function.
9687 (lwp_arch_private_info): Likewise.
9688 * linux-x86-low.c: Include nat/x86-linux.h.
9689 (arch_lwp_info): Removed structure.
9690 (update_debug_registers_callback):
9691 Use lwp_set_debug_registers_changed.
9692 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
9693 and lwp_set_debug_registers_changed.
9694 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
9695
34c703da
GB
96962015-03-24 Gary Benson <gbenson@redhat.com>
9697
9698 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
9699 * linux-arm-low.c (arm_new_thread): Likewise.
9700 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
9701 * linux-mips-low.c (mips_linux_new_thread): Likewise.
9702 * linux-x86-low.c (x86_linux_new_thread): Likewise.
9703 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
9704
cff068da
GB
97052015-03-24 Gary Benson <gbenson@redhat.com>
9706
9707 * linux-low.c (ptid_of_lwp): New function.
9708 (lwp_is_stopped): Likewise.
9709 (lwp_stop_reason): Likewise.
9710 * linux-x86-low.c (update_debug_registers_callback):
9711 Use lwp_is_stopped.
9712 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
9713 lwp_stop_reason.
9714
b2f7c7e8
GB
97152015-03-24 Gary Benson <gbenson@redhat.com>
9716
9717 * linux-low.h (linux_stop_lwp): Remove declaration.
9718
6d4ee8c6
GB
97192015-03-24 Gary Benson <gbenson@redhat.com>
9720
9721 * linux-low.h: Include nat/linux-nat.h.
9722 * linux-low.c (iterate_over_lwps_args): New structure.
9723 (iterate_over_lwps_filter): New function.
9724 (iterate_over_lwps): Likewise.
9725 * linux-x86-low.c (update_debug_registers_callback):
9726 Update signature to what iterate_over_lwps expects.
9727 Remove PID check that iterate_over_lwps now performs.
9728 (x86_dr_low_set_addr): Use iterate_over_lwps.
9729 (x86_dr_low_set_control): Likewise.
9730
70a0bb6b
GB
97312015-03-24 Gary Benson <gbenson@redhat.com>
9732
9733 * linux-x86-low.c (x86_debug_reg_state): New function.
9734 (x86_linux_prepare_to_resume): Use the above.
9735
7b669087
GB
97362015-03-24 Gary Benson <gbenson@redhat.com>
9737
9738 * linux-low.c (current_lwp_ptid): New function.
9739 * linux-x86-low.c: Include nat/linux-nat.h.
9740 (x86_dr_low_get_addr): Use current_lwp_ptid.
9741 (x86_dr_low_get_control): Likewise.
9742 (x86_dr_low_get_status): Likewise.
9743
eef49a3d
PA
97442015-03-20 Pedro Alves <palves@redhat.com>
9745
9746 * tracepoint.c (cmd_qtstatus): Make "str" const.
9747
b2333d22
PA
97482015-03-20 Pedro Alves <palves@redhat.com>
9749
9750 * server.c (handle_general_set): Make "req_str" const.
9751
23f238d3
PA
97522015-03-19 Pedro Alves <palves@redhat.com>
9753
9754 * linux-low.c (linux_resume_one_lwp): Rename to ...
9755 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
9756 instead call perror_with_name.
9757 (check_ptrace_stopped_lwp_gone): New function.
9758 (linux_resume_one_lwp): Reimplement as wrapper around
9759 linux_resume_one_lwp_throw that swallows errors if the LWP is
9760 gone.
9761
91baf43f
PA
97622015-03-19 Pedro Alves <palves@redhat.com>
9763
9764 * linux-low.c (count_events_callback, select_event_lwp_callback):
9765 No longer check whether the thread has resume_stop as last resume
9766 kind.
9767
8bf3b159
PA
97682015-03-19 Pedro Alves <palves@redhat.com>
9769
9770 * linux-low.c (count_events_callback, select_event_lwp_callback):
9771 Use the lwp's status_pending_p field, not the thread's.
9772
b90fc188
PA
97732015-03-19 Pedro Alves <palves@redhat.com>
9774
9775 * linux-low.c (select_event_lwp_callback): Update comments to
9776 no longer mention SIGTRAP.
9777
464b0089
GB
97782015-03-18 Gary Benson <gbenson@redhat.com>
9779
9780 * server.c (handle_query): Do not report vFile:fstat as supported.
9781
aa9e327f
GB
97822015-03-11 Gary Benson <gbenson@redhat.com>
9783
9784 * hostio.c (sys/types.h): New include.
9785 (sys/stat.h): Likewise.
9786 (common-remote-fileio.h): Likewise.
9787 (handle_fstat): New function.
9788 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 9789
791c0056
GB
97902015-03-11 Gary Benson <gbenson@redhat.com>
9791
9792 * configure.ac (AC_CHECK_MEMBERS): Add checks for
9793 struct stat.st_blocks and struct stat.st_blksize.
9794 * configure: Regenerate.
9795 * config.in: Likewise.
9796 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
9797 (OBS): Add common-remote-fileio.o.
9798 (common-remote-fileio.o): New rule.
9799
9a9df970
PA
98002015-03-09 Pedro Alves <palves@redhat.com>
9801
9802 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
9803 'struct sockaddr' pointer in 'accept' call.
9804
9eb1356e
PA
98052015-03-09 Pedro Alves <palves@redhat.com>
9806
9807 Revert:
9808 2015-03-07 Pedro Alves <palves@redhat.com>
9809 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9810 or <winsock2.h> here. Instead include "gdb_socket.h".
9811 (remote_open): Use union gdb_sockaddr_u.
9812 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9813 or <winsock2.h> here. Instead include "gdb_socket.h".
9814 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9815 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9816 or <sys/un.h>.
9817 (init_named_socket, gdb_agent_helper_thread): Use union
9818 gdb_sockaddr_u.
9819
aac331e4
PA
98202015-03-07 Pedro Alves <palves@redhat.com>
9821
9822 * configure.ac (build_warnings): Move
9823 -Wdeclaration-after-statement to the C-specific set.
9824 * configure: Regenerate.
9825
366c75fc
PA
98262015-03-07 Pedro Alves <palves@redhat.com>
9827
9828 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9829 or <winsock2.h> here. Instead include "gdb_socket.h".
9830 (remote_open): Use union gdb_sockaddr_u.
9831 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9832 or <winsock2.h> here. Instead include "gdb_socket.h".
9833 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9834 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9835 or <sys/un.h>.
9836 (init_named_socket, gdb_agent_helper_thread): Use union
9837 gdb_sockaddr_u.
9838
492d29ea
PA
98392015-03-07 Pedro Alves <palves@redhat.com>
9840
9841 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
9842 instead.
9843
60a191ed
YQ
98442015-03-06 Yao Qi <yao.qi@linaro.org>
9845
9846 * linux-aarch64-low.c (aarch64_insert_point): Use
9847 show_debug_regs as a boolean.
9848 (aarch64_remove_point): Likewise.
9849
f5771b1d
PA
98502015-03-05 Pedro Alves <palves@redhat.com>
9851
9852 * lynx-low.c (lynx_target_ops): Install NULL hooks for
9853 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9854 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
9855 * nto-low.c (nto_target_ops): Likewise.
9856 * spu-low.c (spu_target_ops): Likewise.
9857 * win32-low.c (win32_target_ops): Likewise.
9858
3e572f71
PA
98592015-03-04 Pedro Alves <palves@redhat.com>
9860
72f4393d 9861 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
9862 Decide whether a breakpoint triggered based on the SIGTRAP's
9863 siginfo.si_code.
72f4393d
L
9864 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
9865 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
9866 (linux_low_filter_event): Check for breakpoints before checking
9867 watchpoints.
9868 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
9869 siginfo.si_code.
72f4393d
L
9870 (linux_stopped_by_sw_breakpoint)
9871 (linux_supports_stopped_by_sw_breakpoint)
9872 (linux_stopped_by_hw_breakpoint)
9873 (linux_supports_stopped_by_hw_breakpoint): New functions.
9874 (linux_target_ops): Install new target methods.
3e572f71 9875
1ec68e26
PA
98762015-03-04 Pedro Alves <palves@redhat.com>
9877
9878 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
9879 * server.c (swbreak_feature, hwbreak_feature): New globals.
9880 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
9881 (captured_main): Clear swbreak_feature and hwbreak_feature.
9882 * server.h (swbreak_feature, hwbreak_feature): Declare.
9883 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
9884 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
9885 supports_stopped_by_hw_breakpoint>: New fields.
9886 (target_supports_stopped_by_sw_breakpoint)
9887 (target_stopped_by_sw_breakpoint)
9888 (target_supports_stopped_by_hw_breakpoint)
9889 (target_stopped_by_hw_breakpoint): Declare.
9890
15c66dd6
PA
98912015-03-04 Pedro Alves <palves@redhat.com>
9892
9893 enum lwp_stop_reason -> enum target_stop_reason
9894 * linux-low.c (check_stopped_by_breakpoint): Adjust.
9895 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
9896 (linux_wait_1, stuck_in_jump_pad_callback)
9897 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
9898 (linux_stopped_by_watchpoint):
9899 * linux-low.h (enum lwp_stop_reason): Delete.
9900 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
9901 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9902
98fc70d6
YQ
99032015-03-04 Yao Qi <yao.qi@linaro.org>
9904
9905 * Makefile.in (SFILES): Add linux-aarch64-low.c.
9906
dd2ac174
GB
99072015-03-03 Gary Benson <gbenson@redhat.com>
9908
9909 * hostio.c (handle_vFile): Fix prefix lengths.
9910
d68e53f4
MM
99112015-03-03 Markus Metzger <markus.t.metzger@intel.com>
9912
9913 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
9914 ptr_bits.
9915
bf2d68ab
AA
99162015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
9917
9918 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
9919 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
9920 (clean): Add "rm -f" for above C files.
9921 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
9922 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
9923 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
9924 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
9925 * linux-s390-low.c (HWCAP_S390_VX): New macro.
9926 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
9927 (init_registers_s390x_vx_linux64)
9928 (init_registers_s390x_tevx_linux64)
9929 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
9930 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
9931 declarations.
9932 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
9933 (s390_store_vxrs_high): New functions.
9934 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
9935 NT_S390_VXRS_HIGH.
9936 (s390_arch_setup): Add logic for selecting one of the new target
9937 descriptions. Activate the new vector regsets if applicable.
9938 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
9939 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
9940 and init_registers_s390x_tevx_linux64.
9941
c966a859
PA
99422015-03-01 Pedro Alves <palves@redhat.com>
9943
9944 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
9945 parameter.
9946
4180215b
PA
99472015-02-27 Pedro Alves <palves@redhat.com>
9948
9949 * linux-x86-low.c (u_debugreg_offset): New function.
9950 (x86_linux_dr_get, x86_linux_dr_set): Use it.
9951
749bab01
PA
99522015-02-27 Pedro Alves <palves@redhat.com>
9953
9954 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
9955 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
9956 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
9957 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
9958 (ps_lsetfpregs, ps_getpid)
9959 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
9960 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
9961 (ps_lsetxregs, ps_plog): Declare.
9962
3c14e5a3
PA
99632015-02-27 Pedro Alves <palves@redhat.com>
9964
9965 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
9966 IP_AGENT_EXPORT_FUNC.
9967 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
9968 IP_AGENT_EXPORT_FUNC.
9969 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
9970 (IP_AGENT_EXPORT): Delete.
9971 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9972 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9973 (gdb_trampoline_buffer_error, collecting, gdb_collect)
9974 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
9975 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
9976 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
9977 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
9978 (traceframe_read_count, traceframe_write_count)
9979 (traceframes_created, trace_state_variables, get_raw_reg)
9980 (get_trace_state_variable_value, set_trace_state_variable_value)
9981 (ust_loaded, helper_thread_id, cmd_buf): Use
9982 IPA_SYM_EXPORTED_NAME.
9983 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
9984 (tracepoints) Use IP_AGENT_EXPORT_VAR.
9985 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
9986 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9987 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
9988 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
9989 EXTERN_C_PUSH/EXTERN_C_POP.
9990 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
9991 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
9992 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9993 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
9994 (traceframe_write_count, traceframe_read_count)
9995 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
9996 (about_to_request_buffer_space, get_trace_state_variable_value)
9997 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
9998 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
9999 EXTERN_C_PUSH/EXTERN_C_POP.
10000 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
10001 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
10002 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
10003 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10004 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10005 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
10006 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
10007 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
10008 Define.
10009 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
10010 (IP_AGENT_EXPORT_VAR_DECL): Define.
10011 (tracing): Declare.
10012 (gdb_agent_get_raw_reg): Declare.
10013
fe978cb0
PA
100142015-02-27 Tom Tromey <tromey@redhat.com>
10015 Pedro Alves <palves@redhat.com>
10016
10017 Rename symbols whose names are reserved C++ keywords throughout.
10018
3bc3d82a
PA
100192015-02-27 Pedro Alves <palves@redhat.com>
10020
10021 * Makefile.in (COMPILER): New, get it from autoconf.
10022 (CXX): Get from autoconf instead.
10023 (COMPILE.pre): Use COMPILER.
10024 (CC-LD): Rename to ...
10025 (CC_LD): ... this. Use COMPILER.
10026 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
10027 (CXX_FOR_TARGET): Default to g++ instead of gcc.
10028 * acinclude.m4: Include build-with-cxx.m4.
10029 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
10030 Disable -Werror by default if building in C++ mode.
10031 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
10032 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
10033 the C++ compiler. Save/restore CXXFLAGS too.
10034 * configure: Regenerate.
10035
07697489
PA
100362015-02-27 Pedro Alves <palves@redhat.com>
10037
10038 * acinclude.m4: Include libiberty.m4.
10039 * configure.ac: Call libiberty_INIT.
10040 * config.in, configure: Regenerate.
10041
9beb7c4e
PA
100422015-02-26 Pedro Alves <palves@redhat.com>
10043
10044 * linux-low.c (linux_wait_1): When incrementing the PC past a
10045 program breakpoint always use the_low_target.breakpoint_len as
10046 increment, rather than the maximum between that and
10047 the_low_target.decr_pc_after_break.
10048
8090aef2
PA
100492015-02-23 Pedro Alves <palves@redhat.com>
10050
10051 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
10052 thread was doing a step-over; always adjust the PC if
10053 we stepped over a permanent breakpoint.
10054 (linux_wait_1): If we stepped over breakpoint that was on top of a
10055 permanent breakpoint, manually advance the PC past it.
10056
bc9540e8
PA
100572015-02-23 Pedro Alves <palves@redhat.com>
10058
10059 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
10060 modes.
10061 (x86_fill_gregset, x86_store_gregset): Use it when handling
10062 $orig_eax.
10063
2db9a427
PA
100642015-02-20 Pedro Alves <palves@redhat.com>
10065
10066 * thread-db.c: Include "nat/linux-procfs.h".
10067 (thread_db_init): Skip listing new threads if the kernel supports
10068 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
10069
afa8d396
PA
100702015-02-20 Pedro Alves <palves@redhat.com>
10071
10072 * linux-low.c (status_pending_p_callback): Use ptid_match.
10073
c9587f88
AT
100742015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
10075
10076 PR breakpoints/16812
10077 * linux-low.c (wstatus_maybe_breakpoint): Remove.
10078 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
10079 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
10080
b05ec7a5
AT
100812015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
10082
10083 PR breakpoints/15956
10084 * tracepoint.c (cmd_qtinit): Add check for current_thread.
10085
d33501a5
MM
100862015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10087
10088 * linux-low.c (linux_low_btrace_conf): Print size.
10089 * server.c (handle_btrace_conf_general_set): New.
10090 (hanle_general_set): Call handle_btrace_conf_general_set.
10091 (handle_query): Report Qbtrace-conf:bts:size as supported.
10092
f4abbc16
MM
100932015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10094
10095 * linux-low.c (linux_low_enable_btrace): Update parameters.
10096 (linux_low_btrace_conf): New.
10097 (linux_target_ops)<to_btrace_conf>: Initialize.
10098 * server.c (current_btrace_conf): New.
10099 (handle_btrace_enable): Rename to ...
10100 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
10101 to target_enable_btrace. Update comment. Update users.
10102 (handle_qxfer_btrace_conf): New.
10103 (qxfer_packets): Add btrace-conf entry.
10104 (handle_query): Report qXfer:btrace-conf:read as supported packet.
10105 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
10106 (target_ops)<read_btrace_conf>: New.
10107 (target_enable_btrace): Update parameters.
10108 (target_read_btrace_conf): New.
10109
043c3577
MM
101102015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10111
10112 * server.c (handle_btrace_general_set): Remove call to
10113 target_supports_btrace.
10114 (supported_btrace_packets): New.
10115 (handle_query): Call supported_btrace_packets.
10116 * target.h: include btrace-common.h.
10117 (btrace_target_info): Removed.
10118 (supports_btrace, target_supports_btrace): Update parameters.
10119
734b0e4b
MM
101202015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10121
10122 * Makefile.in (SFILES): Add common/btrace-common.c.
10123 (OBS): Add common/btrace-common.o.
10124 (btrace-common.o): Add build rules.
10125 * linux-low: Include btrace-common.h.
10126 (linux_low_read_btrace): Use struct btrace_data. Call
10127 btrace_data_init and btrace_data_fini.
10128
d6c146e9
PA
101292015-02-06 Pedro Alves <palves@redhat.com>
10130
10131 * thread-db.c (find_new_threads_callback): Add debug output.
10132
20ba1ce6
PA
101332015-02-04 Pedro Alves <palves@redhat.com>
10134
10135 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
10136 (resume_stopped_resumed_lwps): New function.
10137 (linux_wait_for_event_filtered): Use it.
10138
8cc73a39
SDJ
101392015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
10140
10141 * Makefile.in (SFILES): Add linux-personality.c.
10142 (linux-personality.o): New rule.
10143 * configure.srv (srv_linux_obj): Add linux-personality.o to the
10144 list of objects to be built.
10145 * linux-low.c: Include nat/linux-personality.h.
10146 (linux_create_inferior): Remove code to disable address space
10147 randomization (moved to ../nat/linux-personality.c). Create
10148 cleanup to disable address space randomization.
10149
fb23d554
SDJ
101502015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
10151
10152 * Makefile.in (posix-strerror.o): New rule.
10153 (mingw-strerror.o): Likewise.
10154 * configure: Regenerated.
10155 * configure.ac: Source file ../common/common.host. Initialize new
10156 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
10157
cdf43629
YQ
101582015-01-14 Yao Qi <yao@codesourcery.com>
10159
10160 * Makefile.in (SFILES): Add nat/ppc-linux.c.
10161 (ppc-linux.o): New rule.
10162 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
10163 * configure.ac: AC_CHECK_FUNCS(getauxval).
10164 * config.in: Re-generated.
10165 * configure: Re-generated.
10166 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
10167 ppc64_64bit_inferior_p
10168
514c5338
YQ
101692015-01-14 Yao Qi <yao@codesourcery.com>
10170
10171 * linux-ppc-low.c: Include "nat/ppc-linux.h".
10172 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
10173 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
10174 (PT_ORIG_R3, PT_TRAP): Likewise.
10175 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
10176 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
10177 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
10178
3368c1e5
JB
101792015-01-10 Joel Brobecker <brobecker@adacore.com>
10180
10181 * i387-fp.c (i387_cache_to_xsave): In look over
10182 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
10183 zmmh_low_space field by use of zmmh_high_space.
10184
582511be
PA
101852015-01-09 Pedro Alves <palves@redhat.com>
10186
10187 * linux-low.c (step_over_bkpt): Move higher up in the file.
10188 (handle_extended_wait): Don't store the stop_pc here.
10189 (get_stop_pc): Adjust comments and rename to ...
10190 (check_stopped_by_breakpoint): ... this. Record whether the LWP
10191 stopped for a software breakpoint or hardware breakpoint.
10192 (thread_still_has_status_pending_p): New function.
10193 (status_pending_p_callback): Use
10194 thread_still_has_status_pending_p. If the event is no longer
10195 interesting, resume the LWP.
10196 (handle_tracepoints): Add assert.
10197 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
10198 (wstatus_maybe_breakpoint): New function.
10199 (cancel_breakpoint): Delete function.
10200 (check_stopped_by_watchpoint): New function, factored out from
10201 linux_low_filter_event.
10202 (lp_status_maybe_breakpoint): Delete function.
10203 (linux_low_filter_event): Remove filter_ptid argument.
10204 Leave thread group exits pending here. Store the LWP's stop PC.
10205 Always leave events pending.
10206 (linux_wait_for_event_filtered): Pull all events out of the
10207 kernel, and leave them all pending.
10208 (count_events_callback, select_event_lwp_callback): Consider all
10209 events.
10210 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
10211 (select_event_lwp): Only give preference to the stepping LWP in
10212 all-stop mode. Adjust comments.
10213 (ignore_event): New function.
10214 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
10215 references to cancel_breakpoints. Adjust to renames. Also give
10216 equal priority to all LWPs that have had events in non-stop mode.
10217 If reporting a software breakpoint event, unadjust the LWP's PC.
10218 (linux_wait): If linux_wait_1 returned an ignored event, retry.
10219 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
10220 Adjust.
10221 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
10222 (resume_status_pending_p): Use thread_still_has_status_pending_p.
10223 (linux_stopped_by_watchpoint): Adjust.
10224 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
10225 * linux-low.h (enum lwp_stop_reason): New.
10226 (struct lwp_info) <stop_pc>: Adjust comment.
10227 <stopped_by_watchpoint>: Delete field.
10228 <stop_reason>: New field.
10229 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
10230 * mem-break.c (software_breakpoint_inserted_here)
10231 (hardware_breakpoint_inserted_here): New function.
10232 * mem-break.h (software_breakpoint_inserted_here)
10233 (hardware_breakpoint_inserted_here): Declare.
10234 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
10235 (cancel_breakpoints): Delete.
10236 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
10237 (upload_fast_traceframes): Remove references to
10238 cancel_breakpoints.
10239
a33e3959
PA
102402015-01-09 Pedro Alves <palves@redhat.com>
10241
10242 * thread-db.c (find_new_threads_callback): Ignore thread if the
10243 kernel thread ID is -1.
10244
8784d563
PA
102452015-01-09 Pedro Alves <palves@redhat.com>
10246
10247 * linux-low.c (linux_attach_fail_reason_string): Move to
10248 nat/linux-ptrace.c, and rename.
10249 (linux_attach_lwp): Update comment.
10250 (attach_proc_task_lwp_callback): New function.
10251 (linux_attach): Adjust to rename and use
10252 linux_proc_attach_tgid_threads.
10253 (linux_attach_fail_reason_string): Delete declaration.
10254
76f2b779
JB
102552015-01-01 Joel Brobecker <brobecker@adacore.com>
10256
10257 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
10258 * server.c (gdbserver_version): Likewise.
10259
fafcc06a
SDJ
102602014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
10261
10262 * remote-utils.c: Include ctype.h.
10263 (input_interrupt): Explicitly handle the case when the char
10264 received is the NUL byte. Improve the printing of non-ASCII
10265 characters.
10266
beed38b8
JB
102672014-12-16 Joel Brobecker <brobecker@adacore.com>
10268
10269 * linux-low.c (linux_low_filter_event): Update call to
10270 linux_enable_event_reporting following the addition of
10271 a new parameter to that function.
10272
bf330350
CU
102732014-12-16 Catalin Udma <catalin.udma@freescale.com>
10274
10275 PR server/17457
10276 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
10277 (AARCH64_FPCR_REGNO): Likewise.
10278 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
10279 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
10280 (aarch64_store_fpregset): Likewise.
10281
5227d625
JB
102822014-12-15 Joel Brobecker <brobecker@adacore.com>
10283
10284 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
10285 Remove FIXME comment about assumption about N.
10286
f93b65a0
JB
102872014-12-13 Joel Brobecker <brobecker@adacore.com>
10288
10289 * configure.ac: If large-file support is disabled in GDBserver,
10290 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
10291 * configure: Regenerate.
10292
e5a9158d
AA
102932014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10294
10295 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
10296 warning upon ENODATA from ptrace.
10297 * linux-s390-low.c (s390_store_tdb): New.
10298 (s390_regsets): Add regset for NT_S390_TDB.
10299
feea5f36
AA
103002014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10301
10302 * linux-low.c (regsets_store_inferior_registers): Skip regsets
10303 without a fill_function.
10304 * linux-s390-low.c (s390_fill_last_break): Remove.
10305 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
10306 (s390_arch_setup): Use regset's size instead of fill_function for
10307 loop end condition.
10308
098dbe61
AA
103092014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10310
10311 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
10312 the regset's store function when ptrace returned an error.
10313 * regcache.c (get_thread_regcache): Invalidate register cache
10314 before fetching inferior's registers.
10315
28eef672
AA
103162014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10317
10318 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
10319 while-loop as for-loop.
10320 (regsets_store_inferior_registers): Likewise.
10321
bdca27a2
YQ
103222014-11-28 Yao Qi <yao@codesourcery.com>
10323
10324 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
10325 * config.in, configure: Re-generate.
10326 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
10327 is defined.
10328
9c232dda
YQ
103292014-11-21 Yao Qi <yao@codesourcery.com>
10330
10331 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
10332 (AC_CHECK_HEADERS): Remove malloc.h.
10333 * configure: Re-generated.
10334 * config.in: Re-generated.
10335 * server.h: Don't include alloca.h and malloc.h.
10336 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
10337 Don't include malloc.h.
10338
43968415
JB
103392014-11-17 Joel Brobecker <brobecker@adacore.com>
10340
10341 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
10342 corresponding ERRNO check in same block.
10343
40e91bc7
PA
103442014-11-12 Pedro Alves <palves@redhat.com>
10345
10346 * server.c (cont_thread): Update comment.
10347 (start_inferior, attach_inferior): No longer clear cont_thread.
10348 (handle_v_cont): No longer set cont_thread.
10349 (captured_main): Clear cont_thread each time a GDB connects.
10350
c2c118cf
PA
103512014-11-12 Pedro Alves <palves@redhat.com>
10352
10353 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
10354 thread, and don't resume all threads if the Hc thread has exited.
10355
78708b7c
PA
103562014-11-12 Pedro Alves <palves@redhat.com>
10357
10358 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
10359 the process group instead of to a specific LWP.
10360
a2abc7de
PA
103612014-10-15 Pedro Alves <palves@redhat.com>
10362
10363 PR server/17487
10364 * win32-arm-low.c (arm_set_thread_context): Remove current_event
10365 parameter.
10366 (arm_set_thread_context): Delete.
10367 (the_low_target): Adjust.
10368 * win32-i386-low.c (debug_registers_changed)
10369 (debug_registers_used): Delete.
10370 (update_debug_registers_callback): New function.
10371 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
10372 needing to update their debug registers.
10373 (win32_get_current_dr): New function.
10374 (x86_dr_low_get_addr, x86_dr_low_get_control)
10375 (x86_dr_low_get_status): Fetch the debug register from the thread
10376 record's context.
10377 (i386_initial_stuff): Adjust.
10378 (i386_get_thread_context): Remove current_event parameter. Don't
10379 clear debug_registers_changed nor copy DR values to
10380 debug_reg_state.
10381 (i386_set_thread_context): Delete.
10382 (i386_prepare_to_resume): New function.
10383 (i386_thread_added): Mark the thread as needing to update irs
10384 debug registers.
10385 (the_low_target): Remove i386_set_thread_context and install
10386 i386_prepare_to_resume.
10387 * win32-low.c (win32_get_thread_context): Adjust.
10388 (win32_set_thread_context): Use SetThreadContext
10389 directly.
10390 (win32_prepare_to_resume): New function.
10391 (win32_require_context): New function, factored out from ...
10392 (thread_rec): ... this.
10393 (continue_one_thread): Call win32_prepare_to_resume on each thread
10394 we're about to continue.
10395 (win32_resume): Call win32_prepare_to_resume on the event thread.
10396 * win32-low.h (struct win32_thread_info)
10397 <debug_registers_changed>: New field.
10398 (struct win32_target_ops): Change prototype of set_thread_context,
10399 delete set_thread_context and add prepare_to_resume.
10400 (win32_require_context): New declaration.
10401
a442d071
GB
104022014-10-08 Gary Benson <gbenson@redhat.com>
10403
10404 * server.h: Do not include common-exceptions.h.
10405
6f1947e8
GB
104062014-10-08 Gary Benson <gbenson@redhat.com>
10407
10408 * server.h: Do not include cleanups.h.
10409
63b434a4
JH
104102014-09-30 James Hogan <james.hogan@imgtec.com>
10411
10412 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
10413 mips64-dsp-linux.c.
10414
c4d9ceb6
YQ
104152014-09-23 Yao Qi <yao@codesourcery.com>
10416
10417 * linux-low.c (lp_status_maybe_breakpoint): New function.
10418 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
10419 (count_events_callback): Likewise.
10420 (select_event_lwp_callback): Likewise.
10421 (cancel_breakpoints_callback): Likewise.
10422
89a5711c
DB
104232014-09-19 Don Breazeal <donb@codesourcery.com>
10424
10425 * linux-low.c (handle_extended_wait): Call
10426 linux_ptrace_get_extended_event.
10427 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
10428 linux_is_extended_waitstatus.
10429
bffc0964
JB
104302014-09-16 Joel Brobecker <brobecker@adacore.com>
10431
10432 * Makefile.in (CPPFLAGS): Define.
10433 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
10434 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
10435
0bfdf32f
GB
104362014-09-16 Gary Benson <gbenson@redhat.com>
10437
10438 * inferiors.h (current_inferior): Renamed as...
10439 (current_thread): New variable. All uses updated.
10440 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
10441 (maybe_move_out_of_jump_pad): Likewise.
10442 (cancel_breakpoint): Likewise.
10443 (linux_low_filter_event): Likewise.
10444 (wait_for_sigstop): Likewise.
10445 (linux_resume_one_lwp): Likewise.
10446 (need_step_over_p): Likewise.
10447 (start_step_over): Likewise.
10448 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
10449 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
10450 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
10451 and save_inferior as saved_thread.
10452 * regcache.c (get_thread_regcache): Renamed saved_inferior as
10453 saved_thread.
10454 (regcache_invalidate_thread): Likewise.
10455 * remote-utils.c (prepare_resume_reply): Likewise.
10456 * thread-db.c (thread_db_get_tls_address): Likewise.
10457 (disable_thread_event_reporting): Likewise.
10458 (remove_thread_event_breakpoints): Likewise.
10459 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
10460 as saved_thread.
10461 * target.h (set_desired_inferior): Renamed as...
10462 (set_desired_thread): New declaration. All uses updated.
10463 * server.c (myresume): Updated comment to reference thread instead
10464 of inferior.
10465 (handle_serial_event): Likewise.
10466 (handle_target_event): Likewise.
10467
361c8ade
GB
104682014-09-12 Tom Tromey <tromey@redhat.com>
10469 Gary Benson <gbenson@redhat.com>
10470
10471 * regcache.h: Include common-regcache.h.
10472 (regcache_read_pc): Don't declare.
10473 * regcache.c (get_thread_regcache_for_ptid): New function.
10474
bd9269f7
GB
104752014-09-11 Tom Tromey <tromey@redhat.com>
10476 Gary Benson <gbenson@redhat.com>
10477
10478 * symbol.c: New file.
10479 * Makefile.in (SFILES): Add symbol.c.
10480 (OBS): Add symbol.o.
10481
f8c1d06b
GB
104822014-09-11 Gary Benson <gbenson@redhat.com>
10483
10484 * target.c (target_stop_ptid, target_continue_ptid): New
10485 functions.
10486
721ec300
GB
104872014-09-11 Tom Tromey <tromey@redhat.com>
10488 Gary Benson <gbenson@redhat.com>
10489
10490 * target.h: Include target/target.h.
10491 * target.c (target_read_memory, target_read_uint32)
10492 (target_write_memory): New functions.
10493
c5e92cca
GB
104942014-09-11 Gary Benson <gbenson@redhat.com>
10495
10496 * server.h (debug_hw_points): Don't declare.
10497 * server.c (debug_hw_points): Don't define. Replace all uses
10498 with show_debug_regs.
10499 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
10500 all uses with show_debug_regs.
10501
2e4bb98a
EBM
105022014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10503
10504 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
10505 endianness into account.
10506 (ppc_supply_ptrace_register): Likewise.
10507
ac740bc7
JH
105082014-09-03 James Hogan <james.hogan@imgtec.com>
10509
10510 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
10511 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
10512
97ea6506
GB
105132014-09-03 Gary Benson <gbenson@redhat.com>
10514
10515 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
10516 ALL_DEBUG_ADDRESS_REGISTERS.
10517
df7e5265
GB
105182014-09-02 Gary Benson <gbenson@redhat.com>
10519
10520 * i386-low.h: Renamed as...
10521 * x86-low.h: New file. All type, function and variable name
10522 prefixes changed from "i386_" to "x86_". All references updated.
10523 * i386-low.c: Renamed as...
10524 * x86-low.c: New file. All type, function and variable name
10525 prefixes changed from "i386_" to "x86_". All references updated.
10526
ed859da7
GB
105272014-09-02 Gary Benson <gbenson@redhat.com>
10528
10529 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
10530 (x86_linux_new_thread): Likewise.
10531
860789c7
GB
105322014-08-29 Gary Benson <gbenson@redhat.com>
10533
10534 * server.h (setjmp.h): Do not include.
10535 (toplevel): Do not declare.
10536 (common-exceptions.h): Include.
10537 (cleanups.h): Likewise.
10538 * server.c (toplevel): Do not define.
10539 (exit_code): New static global.
10540 (detach_or_kill_for_exit_cleanup): New function.
10541 (main): New function. Original main renamed to...
10542 (captured_main): New function.
10543 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
10544
ff55e1b5
GB
105452014-08-29 Gary Benson <gbenson@redhat.com>
10546
10547 * Makefile.in (SFILES): Add common/common-exceptions.c.
10548 (OBS): Add common-exceptions.o.
10549 (common-exceptions.o): New rule.
10550 * utils.c (prepare_to_throw_exception): New function.
10551
e9bcb658
GB
105522014-08-29 Gary Benson <gbenson@redhat.com>
10553
10554 * config.in: Regenerate.
10555 * configure: Likewise.
10556
e3180625
GB
105572014-08-29 Gary Benson <gbenson@redhat.com>
10558
10559 * Makefile.in (SFILES): Add common/cleanups.c.
10560 (OBS): cleanups.o.
10561 (cleanups.o): New rule.
10562
e3d6ba5d
GB
105632014-08-29 Gary Benson <gbenson@redhat.com>
10564
10565 * utils.c (internal_vwarning): New function.
10566
7096e886
GB
105672014-08-28 Gary Benson <gbenson@redhat.com>
10568
10569 * utils.h (fatal): Remove declaration.
10570 * utils.c (fatal): Remove function.
10571
14ce3192
GB
105722014-08-28 Gary Benson <gbenson@redhat.com>
10573
10574 * tracepoint.c (gdb_agent_init): Replace fatal with
10575 perror_with_name.
10576 (initialize_tracepoint): Likewise.
10577
50278d59
GB
105782014-08-28 Gary Benson <gbenson@redhat.com>
10579
10580 * remote-utils.c (remote_prepare): Replace fatal with error.
10581
aa96c426
GB
105822014-08-28 Gary Benson <gbenson@redhat.com>
10583
10584 * linux-low.c (linux_async): Replace fatal with warning.
10585 Tidy up and return.
10586 (linux_start_non_stop): Return -1 if linux_async failed.
10587
f7160e97
GB
105882014-08-28 Gary Benson <gbenson@redhat.com>
10589
10590 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
10591 gdb_assert.
10592 (i386_dr_low_get_addr): Remove vague comment.
10593 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
10594 gdb_assert.
10595
38e08fca
GB
105962014-08-28 Gary Benson <gbenson@redhat.com>
10597
10598 * inferiors.c (get_thread_process): Replace check with gdb_assert.
10599 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
10600 internal_error.
10601 (linux_resume_one_lwp): Likewise.
10602 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
10603 gdb_assert.
10604 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
10605 with internal_error.
10606 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
10607 (init_register_cache): Replace fatal with gdb_assert_not_reached.
10608 (find_register_by_name): Replace fatal with internal_error.
10609 (find_regno): Likewise.
10610 * tdesc.c (init_target_desc): Replace check with gdb_assert.
10611 * thread-db.c (thread_db_create_event): Likewise.
10612 (thread_db_load_search): Likewise.
10613 (try_thread_db_load_1): Likewise.
10614 * tracepoint.c (get_jump_space_head): Replace fatal with
10615 internal_error.
10616 (claim_trampoline_space): Likewise.
10617 (have_fast_tracepoint_trampoline_buffer): Likewise.
10618 (cmd_qtstart): Likewise.
10619 (stop_tracing): Likewise.
10620 (fast_tracepoint_collecting): Likewise.
10621 (target_malloc): Likewise.
10622 (download_tracepoint): Likewise.
10623 (download_trace_state_variables): Replace check with gdb_assert.
10624 (upload_fast_traceframes): Replace fatal with internal_error.
10625
34abf635
GB
106262014-08-19 Tom Tromey <tromey@redhat.com>
10627 Gary Benson <gbenson@redhat.com>
10628
10629 * Makefile.in (SFILES): Add common/common-debug.c.
10630 (OBS): Add common-debug.o.
10631 (common-debug.o): New rule.
10632 * debug.h (debug_printf): Don't declare.
10633 * debug.c (debug_printf): Renamed and rewritten as...
10634 (debug_vprintf): New function.
10635
f6e94d78
GB
106362014-08-19 Gary Benson <gbenson@redhat.com>
10637
10638 * utils.h: Do not include print-utils.h.
10639
9239eeab
GB
106402014-08-19 Tom Tromey <tromey@redhat.com>
10641 Gary Benson <gbenson@redhat.com>
10642
10643 * server.h: Add static assertion.
10644 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
10645
ef87c8bb
GB
106462014-08-19 Tom Tromey <tromey@redhat.com>
10647 Gary Benson <gbenson@redhat.com>
10648
10649 * Makefile.in (SFILES): Add common/errors.c.
10650 (OBS): Add errors.o.
10651 (IPA_OBS): Add errors-ipa.o.
10652 (errors.o): New rule.
10653 (errors-ipa.o): Likewise.
10654 * utils.h (perror_with_name, error, warning): Don't declare.
10655 * utils.c (warning): Renamed and rewritten as...
10656 (vwarning): New function.
10657 (error): Renamed and rewritten as...
10658 (verror): New function.
10659 (internal_error): Renamed and rewritten as...
10660 (internal_verror): New function.
10661
bb974a24
GB
106622014-08-07 Gary Benson <gbenson@redhat.com>
10663
10664 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
10665 * configure: Regenerate.
10666 * config.in: Likewise.
10667 * server.h: Do not include errno.h.
10668 * event-loop.c: Likewise.
10669 * hostio-errno.c: Likewise.
10670 * linux-low.c: Likewise.
10671 * remote-utils.c: Likewise.
10672 * spu-low.c: Likewise.
10673 * utils.c: Likewise.
10674 * gdbreplay.c: Unconditionally include errno.h.
10675
6d3d12eb
GB
106762014-08-07 Gary Benson <gbenson@redhat.com>
10677
10678 * server.h: Do not include string.h.
10679 * event-loop.c: Likewise.
10680 * linux-low.c: Likewise.
10681 * regcache.c: Likewise.
10682 * remote-utils.c: Likewise.
10683 * spu-low.c: Likewise.
10684 * utils.c: Likewise.
10685
dccbb609
GB
106862014-08-07 Gary Benson <gbenson@redhat.com>
10687
10688 * server.h: Do not include gdb_assert.h.
10689
e76df0d0
GB
106902014-08-07 Gary Benson <gbenson@redhat.com>
10691
10692 * server.h: Do not include common-utils.h.
10693
4cb9c816
GB
106942014-08-07 Gary Benson <gbenson@redhat.com>
10695
10696 * server.h: Do not include ptid.h.
10697 * notif.h: Likewise.
10698
3995eeee
GB
106992014-08-07 Gary Benson <gbenson@redhat.com>
10700
10701 * server.h: Do not include gdb_locale.h.
10702
cb9f1a9b
GB
107032014-08-07 Gary Benson <gbenson@redhat.com>
10704
10705 * server.h: Do not include gdb/signals.h.
10706 * win32-low.c: Likewise.
10707
a5fceff8
GB
107082014-08-07 Gary Benson <gbenson@redhat.com>
10709
10710 * server.h: Do not include pathmax.h.
10711
b9391142
GB
107122014-08-07 Gary Benson <gbenson@redhat.com>
10713
10714 * server.h: Do not include libiberty.h.
10715 * linux-bfin-low.c: Likewise.
10716
0e443c87
GB
107172014-08-07 Gary Benson <gbenson@redhat.com>
10718
10719 * server.h: Do not include ansidecl.h.
10720
8ebb3f56
GB
107212014-08-07 Gary Benson <gbenson@redhat.com>
10722
10723 * linux-x86-low.c: Do not include stddef.h.
10724 * lynx-ppc-low.c: Likewise.
10725 * tracepoint.c: Likewise.
10726
8980bdf6
GB
107272014-08-07 Gary Benson <gbenson@redhat.com>
10728
10729 * server.h: Do not include stdarg.h.
10730 * nto-low.c: Likewise.
10731
d7096f71
GB
107322014-08-07 Gary Benson <gbenson@redhat.com>
10733
10734 * server.h: Do not include stdlib.h.
10735 * inferiors.c: Likewise.
10736 * linux-low.c: Likewise.
10737 * regcache.c: Likewise.
10738 * spu-low.c: Likewise.
10739 * tracepoint.c: Likewise.
10740 * utils.c: Likewise.
10741
d02f550d
GB
107422014-08-07 Gary Benson <gbenson@redhat.com>
10743
10744 * server.h: Do not include stdio.h.
10745 * linux-low.c: Likewise.
10746 * remote-utils.c: Likewise.
10747 * spu-low.c: Likewise.
10748 * utils.c: Likewise.
10749 * wincecompat.c: Likewise.
10750
87f6c4e3
GB
107512014-08-06 Gary Benson <gbenson@redhat.com>
10752
10753 * regcache.c (init_register_cache): Move conditionals inside if.
10754
7089dca4
GB
107552014-08-06 Gary Benson <gbenson@redhat.com>
10756
10757 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
10758
462f517e
GB
107592014-07-31 Gary Benson <gbenson@redhat.com>
10760
10761 * ax.h: Do not include server.h.
10762 * gdbthread.h: Likewise.
10763 * lynx-low.h: Likewise.
10764 * notif.h: Likewise.
10765
976411d6
GB
107662014-07-30 Gary Benson <gbenson@redhat.com>
10767
10768 * server.h: Include common-defs.h.
10769 Do not include config.h or build-gnulib-gdbserver/config.h.
10770
d41f6d8e
GB
107712014-07-30 Gary Benson <gbenson@redhat.com>
10772
10773 * hostio-errno.c: Move server.h to top of includes list.
10774 * inferiors.c: Likewise.
10775 * linux-x86-low.c: Likewise.
10776 * notif.c: Include server.h.
10777
314c6a35
TT
107782014-07-24 Tom Tromey <tromey@redhat.com>
10779 Gary Benson <gbenson@redhat.com>
10780
10781 * server.h (CORE_ADDR): Now unsigned.
10782
69ff6be5
PA
107832014-07-16 Pedro Alves <palves@redhat.com>
10784
10785 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
10786
ce9e3fe7
PA
107872014-07-15 Pedro Alves <palves@redhat.com>
10788
10789 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
10790 copy.
10791
e76126e8
PA
107922014-07-11 Pedro Alves <palves@redhat.com>
10793
10794 * linux-low.c (kill_wait_lwp): New function, based on
10795 kill_one_lwp_callback, but use my_waitpid directly.
10796 (kill_one_lwp_callback, linux_kill): Use it.
10797
8e9db26e
PA
107982014-06-23 Pedro Alves <palves@redhat.com>
10799
10800 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
10801 before setting DR0..DR3.
10802
698b3e08
GB
108032014-06-20 Gary Benson <gbenson@redhat.com>
10804
10805 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
10806 * configure: Regenerated.
10807 * config.in: Likewise.
10808
125f8a3d
GB
108092014-06-20 Gary Benson <gbenson@redhat.com>
10810
10811 * Makefile.in (SFILES): Update locations for files moved
10812 from common to nat.
10813 (object file files): Reordered.
10814
42995dbd
GB
108152014-06-20 Gary Benson <gbenson@redhat.com>
10816
10817 * i386-low.h (i386_dr_low_can_set_addr): Removed.
10818 (i386_dr_low_set_addr): Likewise.
10819 (i386_dr_low_get_addr): Likewise.
10820 (i386_dr_low_can_set_control): Likewise.
10821 (i386_dr_low_set_control): Likewise.
10822 (i386_dr_low_get_control): Likewise.
10823 (i386_dr_low_get_status): Likewise.
10824 (i386_get_debug_register_length): Likewise.
10825 * linux-x86-low.c (i386_dr_low_set_addr):
10826 Changed signature. Made static.
10827 (i386_dr_low_get_addr): Likewise.
10828 (i386_dr_low_set_control): Likewise.
10829 (i386_dr_low_get_control): Likewise.
10830 (i386_dr_low_get_status): Likewise.
10831 (i386_dr_low): New global variable.
10832 * win32-i386-low.c (i386_dr_low_set_addr):
10833 Changed signature. Made static.
10834 (i386_dr_low_get_addr): Likewise.
10835 (i386_dr_low_set_control): Likewise.
10836 (i386_dr_low_get_control): Likewise.
10837 (i386_dr_low_get_status): Likewise.
10838 (i386_dr_low): New global variable.
10839
e1d2394b
MS
108402014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
10841
10842 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
10843 * Makefile.in (AR, AR_FLAGS): Define.
10844 * configure: Regenerate.
10845
3a8ee006
GB
108462014-06-19 Gary Benson <gbenson@redhat.com>
10847
10848 * Makefile.in (i386-dregs.o): New rule.
10849 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
10850 * i386-low.c (target.h): Remove include.
10851 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
10852 (DR_CONTROL_SHIFT): Likewise.
10853 (DR_CONTROL_SIZE): Likewise.
10854 (DR_RW_EXECUTE): Likewise.
10855 (DR_RW_WRITE): Likewise.
10856 (DR_RW_READ): Likewise.
10857 (DR_RW_IORW): Likewise.
10858 (DR_LEN_1): Likewise.
10859 (DR_LEN_2): Likewise.
10860 (DR_LEN_4): Likewise.
10861 (DR_LEN_8): Likewise.
10862 (DR_LOCAL_ENABLE_SHIFT): Likewise.
10863 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
10864 (DR_ENABLE_SIZE): Likewise.
10865 (DR_LOCAL_SLOWDOWN): Likewise.
10866 (DR_GLOBAL_SLOWDOWN): Likewise.
10867 (DR_CONTROL_RESERVED): Likewise.
10868 (I386_DR_CONTROL_MASK): Likewise.
10869 (I386_DR_VACANT): Likewise.
10870 (I386_DR_LOCAL_ENABLE): Likewise.
10871 (I386_DR_GLOBAL_ENABLE): Likewise.
10872 (I386_DR_DISABLE): Likewise.
10873 (I386_DR_SET_RW_LEN): Likewise.
10874 (I386_DR_GET_RW_LEN): Likewise.
10875 (I386_DR_WATCH_HIT): Likewise.
10876 (i386_wp_op_t): Likewise.
10877 (i386_show_dr): Likewise.
10878 (i386_length_and_rw_bits): Likewise.
10879 (i386_insert_aligned_watchpoint): Likewise.
10880 (i386_remove_aligned_watchpoint): Likewise.
10881 (i386_handle_nonaligned_watchpoint): Likewise.
10882 i386_update_inferior_debug_regs(): Likewise.
10883 (i386_dr_insert_watchpoint): Likewise.
10884 (i386_dr_remove_watchpoint): Likewise.
10885 (i386_dr_region_ok_for_watchpoint): Likewise.
10886 (i386_dr_stopped_data_address): Likewise.
10887 (i386_dr_stopped_by_watchpoint): Likewise.
10888
8f26655c
GB
108892014-06-19 Gary Benson <gbenson@redhat.com>
10890
10891 * i386-low.c (i386_dr_show): Renamed to
10892 i386_show_dr and made static. All uses updated.
10893 (i386_dr_length_and_rw_bits): Renamed to
10894 i386_length_and_rw_bits and made static.
10895 All uses updated.
10896 (i386_dr_insert_aligned_watchpoint): Renamed to
10897 i386_insert_aligned_watchpoint and made static.
10898 All uses updated.
10899 (i386_dr_remove_aligned_watchpoint): Renamed to
10900 i386_remove_aligned_watchpoint and made static.
10901 All uses updated.
10902 (i386_dr_update_inferior_debug_regs): Renamed to
10903 i386_update_inferior_debug_regs and made static.
10904 All uses updated.
10905
b9228891
GB
109062014-06-18 Gary Benson <gbenson@redhat.com>
10907
5171def3
GB
10908 * i386-low.h (i386_dr_low_can_set_addr): New macro.
10909 (i386_dr_low_can_set_control): Likewise.
10910 (i386_get_debug_register_length): Likewise.
10911 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
10912 (i386_dr_low_can_set_control): Likewise.
10913 (i386_get_debug_register_length): Likewise.
10914
109152014-06-17 Gary Benson <gbenson@redhat.com>
10916
b9228891
GB
10917 * i386-low.h (i386-dregs.h): New include.
10918 (DR_FIRSTADDR): Now in i386-dregs.h.
10919 (DR_LASTADDR): Likewise.
10920 (DR_NADDR): Likewise.
10921 (DR_STATUS): Likewise.
10922 (DR_CONTROL): Likewise.
10923 (i386_debug_reg_state): Likewise.
10924 (i386_dr_insert_watchpoint): Likewise.
10925 (i386_dr_remove_watchpoint): Likewise.
10926 (i386_dr_region_ok_for_watchpoint): Likewise.
10927 (i386_dr_stopped_data_address): Likewise.
10928 (i386_dr_stopped_by_watchpoint): Likewise.
10929 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
10930
4be83cc2
GB
109312014-06-18 Gary Benson <gbenson@redhat.com>
10932
10933 * i386-low.h (i386_low_insert_watchpoint): Renamed to
10934 i386_dr_insert_watchpoint.
10935 (i386_low_remove_watchpoint): Renamed to
10936 i386_dr_remove_watchpoint.
10937 (i386_low_region_ok_for_watchpoint): Renamed to
10938 i386_dr_region_ok_for_watchpoint.
10939 (i386_low_stopped_data_address): Renamed to
10940 i386_dr_stopped_data_address.
10941 (i386_low_stopped_by_watchpoint): Renamed to
10942 i386_dr_stopped_by_watchpoint.
10943 * i386-low.c (i386_show_dr): Renamed to
10944 i386_dr_show and made nonstatic. All uses updated.
10945 (i386_length_and_rw_bits): Renamed to
10946 i386_dr_length_and_rw_bits and made nonstatic.
10947 All uses updated.
10948 (i386_insert_aligned_watchpoint): Renamed to
10949 i386_dr_insert_aligned_watchpoint and made nonstatic.
10950 All uses updated.
10951 (i386_remove_aligned_watchpoint): Renamed to
10952 i386_dr_remove_aligned_watchpoint and made nonstatic.
10953 All uses updated.
10954 (i386_update_inferior_debug_regs): Renamed to
10955 i386_dr_update_inferior_debug_regs and made nonstatic.
10956 All uses updated.
10957 (i386_low_insert_watchpoint): Renamed to
10958 i386_dr_insert_watchpoint. All uses updated.
10959 (i386_low_remove_watchpoint): Renamed to
10960 i386_dr_remove_watchpoint. All uses updated.
10961 (i386_low_region_ok_for_watchpoint): Renamed to
10962 i386_dr_region_ok_for_watchpoint. All uses updated.
10963 (i386_low_stopped_data_address): Renamed to
10964 i386_dr_stopped_data_address. All uses updated.
10965 (i386_low_stopped_by_watchpoint): Renamed to
10966 i386_dr_stopped_by_watchpoint. All uses updated.
10967
131aa0d4
GB
109682014-06-18 Gary Benson <gbenson@redhat.com>
10969
10970 * i386-low.c (i386_dr_low_can_set_addr): New macro.
10971 (i386_dr_low_can_set_control): Likewise.
10972 (i386_insert_aligned_watchpoint): New check.
10973
d9305f7f
GB
109742014-06-18 Gary Benson <gbenson@redhat.com>
10975
10976 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
10977 Renamed to state.
10978
e927c9fc
GB
109792014-06-18 Gary Benson <gbenson@redhat.com>
10980
10981 * i386-low.c (i386_length_and_rw_bits): Use internal_error
10982 instead of fatal and error.
10983 (i386_handle_nonaligned_watchpoint): Likewise.
10984
1b6d4134
GB
109852014-06-18 Gary Benson <gbenson@redhat.com>
10986
10987 * i386-low.c (i386_get_debug_register_length): New macro.
10988 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
10989 (i386_show_dr): Use debug_printf instead of fprintf. Use
10990 phex to format values.
10991
6e62758f
GB
109922014-06-18 Gary Benson <gbenson@redhat.com>
10993
10994 * i386-low.h: Comment changes.
10995 * i386-low.c: Likewise.
10996
fc6e2f03
GB
109972014-06-18 Gary Benson <gbenson@redhat.com>
10998
10999 * i386-low.c: Whitespace changes.
11000
f9d1eeed
TT
110012014-06-12 Tom Tromey <tromey@redhat.com>
11002
11003 * utils.c (freeargv): Remove.
11004
0b04e523
TT
110052014-06-12 Tom Tromey <tromey@redhat.com>
11006
11007 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
11008 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
11009 (parse_debug_format_options): Likewise.
11010 (gdbserver_usage): Likewise.
11011 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
11012 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
11013 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
11014 against libiberty.
11015 ($(LIBGNU)): Depend on libiberty.
11016 (all-lib): Recurse into all subdirs.
11017 (install-only): Invoke "install" target in subdirs.
11018 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
11019 targets.
11020 * configure: Rebuild.
11021 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
11022 for vasprintf, vsnprintf, or gettimeofday.
11023 * configure.srv: Don't add safe-ctype.o or lbasename.o to
11024 srv_tgtobj.
11025
270c9937
JB
110262014-06-05 Joel Brobecker <brobecker@adacore.com>
11027
11028 * development.sh: Delete.
11029 * Makefile.in (config.status): Adjust dependency on development.sh.
11030 * configure.ac: Adjust development.sh source call.
11031 * configure: Regenerate.
11032
0a261ed8
PA
110332014-06-02 Pedro Alves <palves@redhat.com>
11034
11035 * ax.c (gdb_free_agent_expr): New function.
11036 * ax.h (gdb_free_agent_expr): New declaration.
11037 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
11038 list.
11039 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
11040 static.
11041 (clear_breakpoint_conditions_and_commands): New function.
11042 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
11043 (clear_breakpoint_conditions_and_commands): New declaration.
11044
e9dae05e
RR
110452014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
11046
11047 * linux-aarch64-low.c (asm/ptrace.h): Include.
11048
5876f503
JK
110492014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11050
11051 Fix TLS access for -static -pthread.
11052 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
11053 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
11054 (thread_db_load_search, try_thread_db_load_1): Initialize it.
11055
802e8e6d
PA
110562014-05-20 Pedro Alves <palves@redhat.com>
11057
11058 * linux-aarch64-low.c (aarch64_insert_point)
11059 (aarch64_remove_point): No longer check whether the type is
11060 supported here. Adjust to new interface.
11061 (the_low_target): Install aarch64_supports_z_point_type as
11062 supports_z_point_type method.
11063 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
11064 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
11065 instead of a Z packet char. Adjust.
11066 (arm_supports_z_point_type): New function.
11067 (arm_insert_point, arm_remove_point): Adjust to new interface.
11068 (the_low_target): Install arm_supports_z_point_type.
11069 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
11070 (cris_insert_point, cris_remove_point): Adjust to new interface.
11071 Don't check whether the type is supported here.
11072 (the_low_target): Install cris_supports_z_point_type.
11073 * linux-low.c (linux_supports_z_point_type): New function.
11074 (linux_insert_point, linux_remove_point): Adjust to new interface.
11075 * linux-low.h (struct linux_target_ops) <insert_point,
11076 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
11077 raw_breakpoint pointer parameter.
11078 <supports_z_point_type>: New method.
11079 * linux-mips-low.c (mips_supports_z_point_type): New function.
11080 (mips_insert_point, mips_remove_point): Adjust to new interface.
11081 Use mips_supports_z_point_type.
11082 (the_low_target): Install mips_supports_z_point_type.
11083 * linux-ppc-low.c (the_low_target): Install NULL as
11084 supports_z_point_type method.
11085 * linux-s390-low.c (the_low_target): Install NULL as
11086 supports_z_point_type method.
11087 * linux-sparc-low.c (the_low_target): Install NULL as
11088 supports_z_point_type method.
11089 * linux-x86-low.c (x86_supports_z_point_type): New function.
11090 (x86_insert_point): Adjust to new insert_point interface. Use
11091 insert_memory_breakpoint. Adjust to new
11092 i386_low_insert_watchpoint interface.
11093 (x86_remove_point): Adjust to remove_point interface. Use
11094 remove_memory_breakpoint. Adjust to new
11095 i386_low_remove_watchpoint interface.
11096 (the_low_target): Install x86_supports_z_point_type.
11097 * lynx-low.c (lynx_target_ops): Install NULL as
11098 supports_z_point_type callback.
11099 * nto-low.c (nto_supports_z_point_type): New.
11100 (nto_insert_point, nto_remove_point): Adjust to new interface.
11101 (nto_target_ops): Install nto_supports_z_point_type.
11102 * mem-break.c: Adjust intro comment.
11103 (struct raw_breakpoint) <raw_type, size>: New fields.
11104 <inserted>: Update comment.
11105 <shlib_disabled>: Delete field.
11106 (enum bkpt_type) <gdb_breakpoint>: Delete value.
11107 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
11108 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
11109 (raw_bkpt_type_to_target_hw_bp_type): New function.
11110 (find_enabled_raw_code_breakpoint_at): New function.
11111 (find_raw_breakpoint_at): New type and size parameters. Use them.
11112 (insert_memory_breakpoint): New function, based off
11113 set_raw_breakpoint_at.
11114 (remove_memory_breakpoint): New function.
11115 (set_raw_breakpoint_at): Reimplement.
11116 (set_breakpoint): New, based on set_breakpoint_at.
11117 (set_breakpoint_at): Reimplement.
11118 (delete_raw_breakpoint): Go through the_target->remove_point
11119 instead of assuming memory breakpoints.
11120 (find_gdb_breakpoint_at): Delete.
11121 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
11122 (find_gdb_breakpoint): New function.
11123 (set_gdb_breakpoint_at): Delete.
11124 (z_type_supported): New function.
11125 (set_gdb_breakpoint_1): New function, loosely based off
11126 set_gdb_breakpoint_at.
11127 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
11128 (delete_gdb_breakpoint_at): Delete.
11129 (delete_gdb_breakpoint_1): New function, loosely based off
11130 delete_gdb_breakpoint_at.
11131 (delete_gdb_breakpoint): New function.
11132 (clear_gdb_breakpoint_conditions): Rename to ...
11133 (clear_breakpoint_conditions): ... this. Don't handle a NULL
11134 breakpoint.
11135 (add_condition_to_breakpoint): Make static.
11136 (add_breakpoint_condition): Take a struct breakpoint pointer
11137 instead of an address. Adjust.
11138 (gdb_condition_true_at_breakpoint): Rename to ...
11139 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
11140 z_type parameter.
11141 (gdb_condition_true_at_breakpoint): Reimplement.
11142 (add_breakpoint_commands): Take a struct breakpoint pointer
11143 instead of an address. Adjust.
11144 (gdb_no_commands_at_breakpoint): Rename to ...
11145 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
11146 parameter. Return true if no breakpoint was found. Change debug
11147 output.
11148 (gdb_no_commands_at_breakpoint): Reimplement.
11149 (run_breakpoint_commands): Rename to ...
11150 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
11151 and change return type to boolean.
11152 (run_breakpoint_commands): New function.
11153 (gdb_breakpoint_here): Also check for Z1 breakpoints.
11154 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
11155 breakpoint. Go through the_target->remove_point instead of
11156 assuming memory breakpoint.
11157 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
11158 software and hardware breakpoints.
11159 (reinsert_raw_breakpoint): Go through the_target->insert_point
11160 instead of assuming memory breakpoint.
11161 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
11162 software and hardware breakpoints.
11163 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
11164 Check both software and hardware breakpoints.
11165 (validate_inserted_breakpoint): Assert the breakpoint is a
11166 software breakpoint. Set the inserted flag to -1 instead of
11167 setting shlib_disabled.
11168 (delete_disabled_breakpoints): Adjust.
11169 (validate_breakpoints): Only validate software breakpoints.
11170 Adjust to inserted flag change.
11171 (check_mem_read, check_mem_write): Skip breakpoint types other
11172 than software breakpoints. Adjust to inserted flag change.
11173 * mem-break.h (enum raw_bkpt_type): New enum.
11174 (raw_breakpoint, struct process_info): Forward declare.
11175 (Z_packet_to_target_hw_bp_type): Delete declaration.
11176 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
11177 (set_gdb_breakpoint, delete_gdb_breakpoint)
11178 (clear_breakpoint_conditions): New declarations.
11179 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
11180 (breakpoint_inserted_here): Update comment.
11181 (add_breakpoint_condition, add_breakpoint_commands): Replace
11182 address parameter with a breakpoint pointer parameter.
11183 (gdb_breakpoint_here): Update comment.
11184 (delete_gdb_breakpoint_at): Delete.
11185 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
11186 * server.c (process_point_options): Take a struct breakpoint
11187 pointer instead of an address. Adjust.
11188 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
11189 delete_gdb_breakpoint.
11190 * spu-low.c (spu_target_ops): Install NULL as
11191 supports_z_point_type method.
11192 * target.h: Include mem-break.h.
11193 (struct target_ops) <prepare_to_access_memory>: Update comment.
11194 <supports_z_point_type>: New field.
11195 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
11196 instead of a char. Also take a raw breakpoint pointer.
11197 * win32-arm-low.c (the_low_target): Install NULL as
11198 supports_z_point_type.
11199 * win32-i386-low.c (i386_supports_z_point_type): New function.
11200 (i386_insert_point, i386_remove_point): Adjust to new interface.
11201 (the_low_target): Install i386_supports_z_point_type.
11202 * win32-low.c (win32_supports_z_point_type): New function.
11203 (win32_insert_point, win32_remove_point): Adjust to new interface.
11204 (win32_target_ops): Install win32_supports_z_point_type.
11205 * win32-low.h (struct win32_target_ops):
11206 <supports_z_point_type>: New method.
11207 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
11208 instead of a char. Also take a raw breakpoint pointer.
11209
932539e3
PA
112102014-05-20 Pedro Alves <palves@redhat.com>
11211
11212 * mem-break.h: Include break-common.h.
11213 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
11214 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
11215 (Z_packet_to_target_hw_bp_type): New declaration.
11216 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
11217 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
11218 (Z_PACKET_ACCESS_WP): Delete macros.
11219 (Z_packet_to_hw_type): Delete function.
11220 * i386-low.h: Don't include break-common.h here.
11221 (Z_packet_to_hw_type): Delete declaration.
11222 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
11223 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
11224 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
11225 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
11226 * linux-aarch64-low.c: Don't include break-common.h here.
11227 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
11228 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
11229 (Z_packet_to_target_hw_bp_type): Delete function.
11230 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
11231 function.
11232 (mips_insert_point, mips_remove_point): Use
11233 Z_packet_to_target_hw_bp_type.
11234
4ff0d3d8
PA
112352014-05-20 Pedro Alves <palves@redhat.com>
11236
11237 * linux-aarch64-low.c: Include break-common.h.
11238 (enum target_point_type): Delete.
11239 (Z_packet_to_point_type): Rename to ...
11240 (Z_packet_to_target_hw_bp_type): ... this, and return a
11241 target_hw_bp_type instead.
11242 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
11243 instead of an enum target_point_type.
11244 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
11245 breakpoint type.
11246 (aarch64_dr_state_insert_one_point)
11247 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
11248 (aarch64_handle_aligned_watchpoint)
11249 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
11250 Take an enum target_hw_bp_type instead of an enum
11251 target_point_type.
11252 (aarch64_supports_z_point_type): New function.
11253 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
11254 use Z_packet_to_target_hw_bp_type.
11255
786dc519
JB
112562014-05-20 Joel Brobecker <brobecker@adacore.com>
11257
11258 * configure.ac: Only use -Werror by default when DEVELOPMENT
11259 is true.
11260 * configure: Regenerate.
11261
9e0aa64f
JK
112622014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
11263
11264 Fix gdbserver qGetTLSAddr for x86_64 -m32.
11265 * linux-x86-low.c (X86_64_USER_REGS): New.
11266 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
11267
2b577b92
YQ
112682014-04-28 Yao Qi <yao@codesourcery.com>
11269
11270 * Makefile.in (i386-avx512.c): Fix the typo of generated file
11271 name.
11272
94611da2
PA
112732014-04-25 Pedro Alves <palves@redhat.com>
11274
11275 PR server/16255
11276 * linux-low.c (linux_attach_fail_reason_string): New function.
11277 (linux_attach_lwp): Delete.
11278 (linux_attach_lwp_1): Rename to ...
11279 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
11280 argument. Remove "initial" parameter. Return int instead of
11281 void. Don't error or warn here.
11282 (linux_attach): Adjust to call linux_attach_lwp. Call error on
11283 failure to attach to the tgid. Call warning when failing to
11284 attach to an lwp.
11285 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
11286 argument. Remove "initial" parameter. Return int instead of
11287 void. Don't error or warn here.
11288 (linux_attach_fail_reason_string): New declaration.
11289 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
11290 interface change. Use linux_attach_fail_reason_string.
11291
01f9f808
MS
112922014-04-24 Michael Sturm <michael.sturm@mintel.com>
11293 Walfred Tedeschi <walfred.tedeschi@intel.com>
11294
11295 * Makefile.in: Added rules to handle new files
11296 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
11297 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
11298 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
11299 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
11300 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
11301 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
11302 x32-avx512-linux.o.
11303 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
11304 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
11305 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
11306 i386/x32-avx512.xml.
11307 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
11308 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
11309 i386/x32-avx512-linux.xml.
11310 * i387-fp.c (num_avx512_k_registers): New constant for number
11311 of K registers.
11312 (num_avx512_zmmh_low_registers): New constant for number of
11313 lower ZMM registers (0-15).
11314 (num_avx512_zmmh_high_registers): New constant for number of
11315 higher ZMM registers (16-31).
11316 (num_avx512_ymmh_registers): New contant for number of higher
11317 YMM registers (ymm16-31 added by avx521 on x86_64).
11318 (num_avx512_xmm_registers): New constant for number of higher
11319 XMM registers (xmm16-31 added by AVX512 on x86_64).
11320 (struct i387_xsave): Add space for AVX512 registers.
11321 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
11322 Add code to handle AVX512 registers.
11323 (i387_xsave_to_cache): Add code to handle AVX512 registers.
11324 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
11325 prototypei from generated file.
11326 (tdesc_amd64_avx512_linux): Likewise.
11327 (init_registers_x32_avx512_linux): Likewise.
11328 (tdesc_x32_avx512_linux): Likewise.
11329 (init_registers_i386_avx512_linux): Likewise.
11330 (tdesc_i386_avx512_linux): Likewise.
11331 (x86_64_regmap): Add AVX512 registers.
11332 (x86_linux_read_description): Add code to handle AVX512 XSTATE
11333 mask.
11334 (initialize_low_arch): Add code to initialize AVX512 registers.
11335
51aa91f9
PA
113362014-04-23 Pedro Alves <palves@redhat.com>
11337
11338 * mem-break.c (find_gdb_breakpoint_at): Make static.
11339 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
11340
a4165e94
PA
113412014-04-23 Pedro Alves <palves@redhat.com>
11342
11343 * i386-low.c: Don't include break-common.h here.
11344 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
11345 prototype to take target_hw_bp_type as argument instead of a Z
11346 packet char.
11347 * i386-low.h: Include break-common.h here.
11348 (Z_packet_to_hw_type): Declare.
11349 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
11350 prototypes.
11351 * linux-x86-low.c (x86_insert_point): Convert the packet number to
11352 a target_hw_bp_type before calling i386_low_insert_watchpoint.
11353 (x86_remove_point): Convert the packet number to a
11354 target_hw_bp_type before calling i386_low_remove_watchpoint.
11355 * win32-i386-low.c (i386_insert_point): Convert the packet number
11356 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
11357 (i386_remove_point): Convert the packet number to a
11358 target_hw_bp_type before calling i386_low_remove_watchpoint.
11359
b8acf843
PA
113602014-04-23 Pedro Alves <palves@redhat.com>
11361
11362 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
11363
d708bcd1
PA
113642014-04-10 Pedro Alves <palves@redhat.com>
11365
11366 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
11367 Check if the condition or command is NULL before checking if the
11368 breakpoint is known. On success, return true.
11369 * mem-break.h (add_breakpoint_condition): Document return.
11370 (add_breakpoint_commands): Add describing comment.
11371 * server.c (skip_to_semicolon): New function.
11372 (process_point_options): Use it.
11373
2eec7d5b
PA
113742014-04-09 Pedro Alves <palves@redhat.com>
11375
11376 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
11377 to lwpid_of.
11378
fa96cb38
PA
113792014-02-27 Pedro Alves <palves@redhat.com>
11380
11381 PR 12702
11382 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
11383 macros.
11384 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
11385 output.
11386 (last_thread_of_process_p): Take a PID argument instead of a
11387 thread pointer.
11388 (linux_wait_for_lwp): Delete.
11389 (num_lwps, check_zombie_leaders, not_stopped_callback): New
11390 functions.
11391 (linux_low_filter_event): New function, party factored out from
11392 linux_wait_for_event.
11393 (linux_wait_for_event): Rename to ...
11394 (linux_wait_for_event_filtered): ... this. Add new filter ptid
11395 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
11396 sigsuspend. Check for zombie leaders.
11397 (linux_wait_for_event): Reimplement as wrapper around
11398 linux_wait_for_event_filtered.
11399 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
11400 a normal or signal exit is seen, it's the whole process exiting.
11401 (wait_for_sigstop): No longer a for_each_inferior callback.
11402 Rewrite on top of linux_wait_for_event_filtered.
11403 (stop_all_lwps): Call wait_for_sigstop directly.
11404 * server.c (resume, handle_target_event): Handle
11405 TARGET_WAITKIND_NO_RESUMED.
11406
d763de10
JB
114072014-02-26 Joel Brobecker <brobecker@adacore.com>
11408
11409 * win32-low.c (psapi_get_dll_name,
11410 * win32_CreateToolhelp32Snapshot): Delete.
11411 (win32_CreateToolhelp32Snapshot, win32_Module32First)
11412 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
11413 Delete.
11414 (handle_load_dll): Add function description.
11415 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
11416
850a0f76
JB
114172014-02-26 Joel Brobecker <brobecker@adacore.com>
11418
11419 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
11420 Add comment.
11421 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
11422 base address when calling win32_add_one_solib.
11423 (handle_load_dll): Delete local variable load_addr.
11424 Remove 0x1000 offset applied to DLL base address when calling
11425 win32_add_one_solib.
11426 (handle_unload_dll): Add comment.
11427
f25b3fc3
JB
114282014-02-26 Joel Brobecker <brobecker@adacore.com>
11429
11430 * win32-low.c (win32_add_all_dlls): Renames
11431 win32_ensure_ntdll_loaded. Rewrite function documentation.
11432 Adjust implementation to always load all DLLs.
11433 Add 0x1000 offset to DLL base address when calling
11434 win32_add_one_solib.
11435 (child_initialization_done): New static global.
11436 (do_initial_child_stuff): Set child_initialization_done to
11437 zero during child initialization, and 1 after. Replace call
11438 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
11439 Add comment.
11440 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
11441 (handle_unload_dll): Add function documentation.
11442 (get_child_debug_event): Ignore load and unload DLL events
11443 during child initialization.
11444
d86d4aaf
DE
114452014-02-20 Doug Evans <dje@google.com>
11446
3bc32da3 11447 Remove global all_lwps.
d86d4aaf
DE
11448 * inferiors.h (ptid_of): Move here from linux-low.h.
11449 (pid_of, lwpid_of): Ditto.
11450 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
11451 parameter is a struct thread_info * now.
11452 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
11453 directly. Pass &all_threads to find_inferior instead of &all_lwps.
11454 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
11455 directly.
11456 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
11457 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
11458 * linux-arm-low.c (update_registers_callback): Update, "entry"
11459 parameter is a struct thread_info * now.
11460 Fetch lwpid from current_inferior directly.
11461 (arm_insert_point): Pass &all_threads to find_inferior instead of
11462 &all_lwps.
11463 (arm_remove_point): Ditto.
11464 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
11465 (arm_prepare_to_resume): Fetch pid from thread.
11466 (arm_read_description): Fetch lwpid from current_inferior directly.
11467 * linux-low.c (all_lwps): Delete.
11468 (delete_lwp): Delete call to remove_inferior.
11469 (handle_extended_wait): Fetch lwpid from thread.
11470 (add_lwp): Don't set lwp->entry.id. Remove call to
11471 add_inferior_to_list.
11472 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
11473 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
11474 (kill_one_lwp_callback): Ditto.
11475 (linux_kill): Don't dereference NULL pointer.
11476 Fetch ptid,lwpid from thread.
11477 (get_detach_signal): Fetch ptid from thread.
11478 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
11479 Simplify call to regcache_invalidate_thread.
11480 (delete_lwp_callback): Update, "entry" parameter is a
11481 struct thread_info * now. Fetch pid from thread.
11482 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
11483 (status_pending_p_callback): Update, "entry" parameter is a
11484 struct thread_info * now. Fetch ptid from thread.
11485 (find_lwp_pid): Update, "entry" parameter is a
11486 struct thread_info * now.
11487 (linux_wait_for_lwp): Fetch pid from thread.
11488 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
11489 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
11490 (enqueue_one_deferred_signal): Fetch lwpid from thread.
11491 (dequeue_one_deferred_signal): Ditto.
11492 (cancel_breakpoint): Fetch ptid from current_inferior.
11493 (linux_wait_for_event): Pass &all_threads to find_inferior,
11494 not &all_lwps. Fetch ptid, lwpid from thread.
11495 (count_events_callback): Update, "entry" parameter is a
11496 struct thread_info * now.
11497 (select_singlestep_lwp_callback): Ditto.
11498 (select_event_lwp_callback): Ditto.
11499 (cancel_breakpoints_callback): Ditto.
11500 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
11501 not &all_lwps.
11502 (select_event_lwp): Ditto. Fetch ptid from event_thread.
11503 (unsuspend_one_lwp): Update, "entry" parameter is a
11504 struct thread_info * now.
11505 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
11506 not &all_lwps.
11507 (linux_stabilize_threads): Ditto. And for for_each_inferior.
11508 Fetch lwpid from thread, not lwp.
11509 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
11510 Pass &all_threads to find_inferior, not &all_lwps.
11511 (send_sigstop): Fetch lwpid from thread, not lwp.
11512 (send_sigstop_callback): Update, "entry" parameter is a
11513 struct thread_info * now.
11514 (suspend_and_send_sigstop_callback): Ditto.
11515 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
11516 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
11517 struct thread_info * now.
11518 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
11519 from thread, lwp.
11520 (lwp_running): Update, "entry" parameter is a
11521 struct thread_info * now.
11522 (stop_all_lwps): Fetch ptid from thread.
11523 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
11524 (linux_resume_one_lwp): Fetch lwpid from thread.
11525 (linux_set_resume_request): Update, "entry" parameter is a
11526 struct thread_info * now. Fetch pid, lwpid from thread.
11527 (resume_status_pending_p): Update, "entry" parameter is a
11528 struct thread_info * now.
11529 (need_step_over_p): Ditto. Fetch lwpid from thread.
11530 (start_step_over): Fetch lwpid from thread.
11531 (linux_resume_one_thread): Update, "entry" parameter is a
11532 struct thread_info * now. Fetch lwpid from thread.
11533 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
11534 (proceed_one_lwp): Update, "entry" parameter is a
11535 struct thread_info * now. Fetch lwpid from thread.
11536 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
11537 struct thread_info * now.
11538 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
11539 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
11540 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
11541 directly.
11542 (regsets_store_inferior_registers): Ditto.
11543 (fetch_register, store_register): Ditto.
11544 (linux_read_memory, linux_write_memory): Ditto.
11545 (linux_request_interrupt): Ditto.
11546 (linux_read_auxv): Ditto.
11547 (linux_xfer_siginfo): Ditto.
11548 (linux_qxfer_spu): Ditto.
11549 (linux_qxfer_libraries_svr4): Ditto.
11550 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
11551 moved to inferiors.h.
11552 (get_lwp): Delete.
11553 (get_thread_lwp): Update.
11554 (struct lwp_info): Delete member "entry". Simplify comment for
11555 member "thread".
11556 (all_lwps): Delete.
11557 * linux-mips-low.c (mips_read_description): Fetch lwpid from
11558 current_inferior directly.
11559 (update_watch_registers_callback): Update, "entry" parameter is a
11560 struct thread_info * now. Fetch pid from thread.
11561 (mips_linux_prepare_to_resume): Fetch ptid from thread.
11562 (mips_insert_point): Fetch lwpid from current_inferior.
11563 Pass &all_threads to find_inferior, not &all_lwps.
11564 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
11565 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
11566 directly.
11567 (mips_stopped_data_address): Ditto.
11568 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
11569 directly.
11570 * linux-tile-low.c (tile_arch_setup): Ditto.
11571 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
11572 (update_debug_registers_callback): Update, "entry" parameter is a
11573 struct thread_info * now. Fetch pid from thread.
11574 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
11575 Pass &all_threads to find_inferior, not &all_lwps.
11576 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
11577 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
11578 Pass &all_threads to find_inferior, not &all_lwps.
11579 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
11580 (i386_dr_low_get_status): Ditto.
11581 (x86_linux_prepare_to_resume): Fetch ptid from thread.
11582 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
11583 (x86_linux_read_description): Ditto.
11584 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
11585
3b8361aa
DE
115862014-02-20 Doug Evans <dje@google.com>
11587
11588 * inferiors.c (get_first_inferior): Fix buglet.
11589
f7667f0d
DE
115902014-02-19 Doug Evans <dje@google.com>
11591
11592 * gdbthread.h (add_thread): Change result type to struct thread_info *.
11593 * inferiors.c (add_thread): Change result type to struct thread_info *.
11594 All callers updated.
11595 (add_lwp): Call add_thread here instead of in callers.
11596 All callers updated.
11597 * linux-low.h (get_lwp_thread): Rewrite.
11598 (struct lwp_info): New member "thread".
11599
b3312d80
DE
116002014-02-19 Doug Evans <dje@google.com>
11601
11602 * linux-low.c (add_lwp): Change result to struct lwp_info *.
11603 All callers updated.
11604
ecc6f45c
DE
116052014-02-19 Doug Evans <dje@google.com>
11606
11607 * inferiors.c (add_thread): Fix whitespace.
11608
649ebbca
DE
116092014-02-19 Doug Evans <dje@google.com>
11610
11611 * dll.c (clear_dlls): Replace accessing list implemention details
11612 with API function.
11613 * gdbthread.h (get_first_thread): Declare.
11614 * inferiors.c (for_each_inferior_with_data): New function.
11615 (get_first_thread): New function.
11616 (find_thread_ptid): Simplify.
11617 (get_first_inferior): New function.
11618 (clear_list): Delete.
11619 (one_inferior_p): New function.
11620 (clear_inferior_list): New function.
11621 (clear_inferiors): Update.
11622 * inferiors.h (for_each_inferior_with_data): Declare.
11623 (clear_inferior_list): Declare.
11624 (one_inferior_p): Declare.
11625 (get_first_inferior): Declare.
11626 * linux-low.c (linux_wait_for_event): Replace accessing list
11627 implemention details with API function.
11628 * server.c (target_running): Ditto.
11629 (accumulate_file_name_length): New function.
11630 (emit_dll_description): New function.
11631 (handle_qxfer_libraries): Replace accessing list implemention
11632 details with API function.
11633 (handle_qxfer_threads_worker): New function.
11634 (handle_qxfer_threads_proper): Replace accessing list implemention
11635 details with API function.
11636 (handle_query): Ditto.
11637 (visit_actioned_threads_callback_ftype): New typedef.
11638 (visit_actioned_threads_data): New struct.
11639 (visit_actioned_threads): Rewrite to be find_inferior callback.
11640 (resume): Call find_inferior.
11641 (handle_status): Replace accessing list implemention
11642 details with API function.
11643 (process_serial_event): Replace accessing list implemention details
11644 with API function.
11645 * target.c (set_desired_inferior): Replace accessing list implemention
11646 details with API function.
11647 * tracepoint.c (same_process_p): New function.
11648 (gdb_agent_about_to_close): Replace accessing list implemention
11649 details with API function.
11650 * win32-low.c (child_delete_thread): Replace accessing list
11651 implemention details with API function.
11652 (match_dll_by_basename): New function.
11653 (dll_is_loaded_by_basename): New function.
11654 (win32_ensure_ntdll_loaded): Replace accessing list implemention
11655 details call to dll_is_loaded_by_basename.
11656
80894984
DE
116572014-02-19 Doug Evans <dje@google.com>
11658
11659 * dll.h (struct dll_info): Add comment.
11660 * gdbthread.h (struct thread_info): Add comment.
11661 (current_ptid): Simplify.
11662 * inferiors.c (add_process): Update.
11663 (remove_process): Update.
11664 * inferiors.h (struct process_info): Rename member "head" to "entry".
11665 * linux-low.c (delete_lwp): Update.
11666 (add_lwp): Update.
11667 (last_thread_of_process_p): Update.
11668 (kill_one_lwp_callback, linux_kill): Update.
11669 (status_pending_p_callback): Update.
11670 (wait_for_sigstop): Update. Simplify read of ptid.
11671 (start_step_over): Update.
11672 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
11673 (get_lwp_thread): Update.
11674 (struct lwp_info): Rename member "head" to "entry".
11675 * regcache.h (inferior_list_entry): Delete.
11676 * server.c (kill_inferior_callback): Update.
11677 (detach_or_kill_inferior_callback): Update.
11678 (print_started_pid): Update.
11679 (print_attached_pid): Update.
11680 (process_serial_event): Simplify read of ptid.
11681 * thread-db.c (thread_db_create_event): Update.
11682 (thread_db_get_tls_address): Update.
11683 * win32-low.c (current_inferior_ptid): Simplify.
11684
46917d26
TT
116852014-02-19 Tom Tromey <tromey@redhat.com>
11686
11687 * target.h (struct target_ops) <supports_btrace>: Add target_ops
11688 argument.
11689 (target_supports_btrace): Update.
11690
0759a81e
YQ
116912014-02-14 Yao Qi <yao@codesourcery.com>
11692
11693 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
11694 (rsp-low-ipa.o): New target.
11695
a7191e8b
TT
116962014-02-12 Tom Tromey <tromey@redhat.com>
11697
11698 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
11699 convert_ascii_to_int.
11700 * regcache.c (registers_to_string): Likewise.
11701 * remote-utils.c (decode_M_packet): Likewise.
11702 * server.c (process_serial_event): Likewise.
11703
ff0e980e
TT
117042014-02-12 Tom Tromey <tromey@redhat.com>
11705
11706 * server.c (handle_query, handle_v_run): Use hex2bin, not
11707 unhexify.
11708 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
11709
e9371aff
TT
117102014-02-12 Tom Tromey <tromey@redhat.com>
11711
11712 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
11713 convert_int_to_ascii.
11714 * regcache.c (registers_to_string, collect_register_as_string):
11715 Likewise.
11716 * remote-utils.c (look_up_one_symbol, relocate_instruction):
11717 Likewise.
11718 * server.c (process_serial_event): Likewise.
11719 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
11720 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
11721
971dc0b8
TT
117222014-02-12 Tom Tromey <tromey@redhat.com>
11723
11724 * remote-utils.c (look_up_one_symbol, monitor_output): Use
11725 bin2hex, not hexify.
11726 * tracepoint.c (cmd_qtstatus): Likewise.
11727
0a822afb
TT
117282014-02-12 Tom Tromey <tromey@redhat.com>
11729
11730 * remote-utils.c (monitor_output): Pass explicit length to
11731 hexify.
11732
9c3d6531
TT
117332014-02-12 Tom Tromey <tromey@redhat.com>
11734
11735 * tracepoint.c: Include rsp-low.h.
11736 * server.c: Include rsp-low.h.
11737 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
11738 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
11739 declare.
11740 * remote-utils.c: Include rsp-low.h.
11741 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
11742 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
11743 (convert_int_to_ascii, convert_ascii_to_int): Move to
11744 common/rsp-low.c.
11745 * regcache.c: Include rsp-low.h.
11746 * ax.c: Include rsp-low.h.
11747 * Makefile.in (SFILES): Add common/rsp-low.c.
11748 (OBS): Add rsp-low.o.
11749 (rsp-low.o): New target.
11750
01fd3ea5
TT
117512014-02-12 Tom Tromey <tromey@redhat.com>
11752
11753 * utils.h (pulongest, plongest, phex_nz): Don't declare.
11754 Include print-utils.h.
11755 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
11756 (plongest, thirty_two, phex_nz): Remove.
11757 * Makefile.in (SFILES): Add common/print-utils.c.
11758 (OBS): Add print-utils.o.
11759 (print-utils-ipa.o): New target.
11760 (print-utils.o): New target.
11761 (IPA_OBJS): Add print-utils-ipa.o.
11762
e99dc820
TT
117632014-02-06 Tom Tromey <tromey@redhat.com>
11764
11765 * Makefile.in (SFILES): Fix indentation.
11766
ee1e2d4f
DE
117672014-02-05 Doug Evans <dje@google.com>
11768
11769 * linux-low.c (linux_wait_for_event): Improve comment.
11770 (linux_wait_1): Keep current_inferior in sync with event_child.
11771
f5a02773
DE
117722014-01-22 Doug Evans <dje@google.com>
11773
11774 * gdbthread.h (gdb_id_to_thread): Delete, unused.
11775
87ce2a04
DE
117762014-01-22 Doug Evans <dje@google.com>
11777
11778 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
11779 * configure: Regenerate.
11780 * config.in: Regenerate.
11781 * Makefile.in (SFILES): Add debug.c.
11782 (OBS): Add debug.o.
11783 * debug.c: New file.
11784 * debug.h: New file.
11785 * linux-aarch64-low.c (*): Update all debugging printfs to use
11786 debug_printf instead of fprintf.
11787 * linux-arm-low.c (*): Ditto.
11788 * linux-cris-low.c (*): Ditto.
11789 * linux-crisv32-low.c (*): Ditto.
11790 * linux-m32r-low.c (*): Ditto.
11791 * linux-sparc-low.c (*): Ditto.
11792 * linux-x86.c (*): Ditto.
11793 * linux-low.c (*): Ditto.
11794 (linux_wait_1): Add calls to debug_enter, debug_exit.
11795 (linux_wait): Remove redundant debugging printf.
11796 (stop_all_lwps): Add calls to debug_enter, debug_exit.
11797 (linux_resume, unstop_all_lwps): Ditto.
11798 * mem-break.c (*): Update all debugging printfs to use
11799 debug_printf instead of fprintf.
11800 * remote-utils.c (*): Ditto.
11801 * thread-db.c (*): Ditto.
11802 * server.c #include <ctype.h>, "gdb_vecs.h".
11803 (debug_threads): Moved to debug.c.
11804 (*): Update all debugging printfs to use debug_printf instead of
11805 fprintf.
11806 (start_inferior): Replace call to fflush with call to debug_flush.
11807 (monitor_show_help): Mention set debug-format.
11808 (parse_debug_format_options): New function.
11809 (handle_monitor_command): Handle "monitor set debug-format".
11810 (gdbserver_usage): Mention --debug-format.
11811 (main): Parse --debug-format.
11812 * server.h (debug_threads): Declaration moved to debug.h.
11813 #include "debug.h".
11814 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
11815 trace_debug_1 that uses debug_printf.
11816 (tracepoint_look_up_symbols): Update all debugging printfs to use
11817 debug_printf instead of fprintf.
11818
e671835b
BS
118192014-01-20 Baruch Siach <baruch@tkos.co.il>
11820
11821 * linux-xtensa-low.c: Include asm/ptrace.h instead of
11822 sys/ptrace.h.
11823
b5737fa9
PA
118242014-01-17 Pedro Alves <palves@redhat.com>
11825
ea38d2a9 11826 PR build/16445
c7faa97a
PA
11827 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
11828 defined after including gdb_proc_service.h.
b5737fa9 11829
40ed484e
DE
118302014-01-16 Doug Evans <dje@google.com>
11831
11832 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
11833 (match_dll): Use it.
11834
969c39fb
MM
118352014-01-16 Markus Metzger <markus.t.metzger@intel.com>
11836
11837 * target.h (target_ops) <read_btrace>: Change parameters and
11838 return type to allow error reporting.
11839 * server.c (handle_qxfer_btrace): Support delta reads. Pass
11840 trace reading errors on.
11841 * linux-low.c (linux_low_read_btrace): Pass trace reading
11842 errors on.
11843 (linux_low_disable_btrace): New.
11844
ab7f45ba
DE
118452014-01-15 Doug Evans <dje@google.com>
11846
11847 * inferiors.c (thread_id_to_gdb_id): Delete.
11848 * inferiors.h (thread_id_to_gdb_id): Delete.
11849
66af0f44
EZ
118502014-01-13 Eli Zaretskii <eliz@gnu.org>
11851
11852 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
11853 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
11854 versions.
11855
9939e131
PA
118562014-01-08 Pedro Alves <palves@redhat.com>
11857
11858 * server.c (handle_status): Don't discard previous queued stop
11859 replies or thread's pending status here.
11860 (main) <disconnection>: Do it here instead.
11861
b7ea362b
PA
118622014-01-08 Pedro Alves <palves@redhat.com>
11863
11864 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
11865 * server.c (visit_actioned_threads, handle_pending_status): New
11866 function.
11867 (handle_v_cont): Factor out parts to ...
11868 (resume): ... this new function. If in all-stop, and a thread
11869 being resumed has a pending status, report it without actually
11870 resuming.
11871 (myresume): Adjust to use the new 'resume' function.
11872 (clear_pending_status_callback, set_pending_status_callback)
11873 (find_status_pending_thread_callback): New functions.
11874 (handle_status): Handle the case of multiple threads having
11875 interesting statuses to report. Report threads' real last signal
11876 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
11877 with an interesting thread to report the status for, instead of
11878 always reporting the status of the first thread.
11879
28498c42
JB
118802014-01-01 Joel Brobecker <brobecker@adacore.com>
11881
11882 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
11883 * gdbreplay.c (gdbreplay_version): Likewise.
11884
f45c82da
YZ
118852013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
11886
11887 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
11888 iov.iov_len with the real length in use.
11889
379a5e2d
JB
118902013-12-13 Joel Brobecker <brobecker@adacore.com>
11891
11892 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
11893 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
11894 for all targets that use win32-low.c.
11895 * win32-low.c (win32_ensure_ntdll_loaded): New function.
11896 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
11897
4210d83e
PA
118982013-12-13 Pedro Alves <palves@redhat.com>
11899
11900 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
11901 if equal to TARGET_WAITKIND_LOADED.
11902 * win32-low.c (cached_status): New static global.
11903 (win32_wait): Add declaration.
11904 (do_initial_child_stuff): Flush all initial pending debug events
11905 up to the initial breakpoint.
11906 (win32_wait): If CACHED_STATUS was set, return that instead
11907 of doing a real wait. Remove the code resuming the execution
11908 of the inferior after receiving a TARGET_WAITKIND_LOADED event
11909 during the initial phase. Also remove the code changing
11910 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
11911 TARGET_WAITKIND_STOPPED.
11912
e7f0d979
YQ
119132013-12-11 Yao Qi <yao@codesourcery.com>
11914
11915 * notif.c (handle_notif_ack): Return 0 if no notification
11916 matches.
11917
ebcf782c
DE
119182013-11-20 Doug Evans <dje@google.com>
11919
11920 * linux-low.c (linux_set_resume_request): Fix comment.
11921
20ad9378
DE
119222013-11-20 Doug Evans <dje@google.com>
11923
11924 * linux-low.c (resume_status_pending_p): Tweak comment.
11925
a196ebeb
WT
119262013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
11927
11928 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
11929 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
11930 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
11931 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
11932 (srv_amd64_regobj): Add amd64-mpx.o.
11933 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
11934 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
11935 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
11936 * i387-fp.c (num_pl_bnd_register) Added constant.
11937 (num_pl_bnd_cfg_registers) Added constant.
11938 (struct i387_xsave) Added reserved area and MPX fields.
11939 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
11940 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
11941 function.
11942 (tdesc_i386_mpx_linux): Add MPX amd64 target.
11943 (init_registers_amd64_mpx_linux): Declare new function.
11944 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
11945 (x86_64_regmap): Add MPX registers.
11946 (x86_linux_read_description): Add MPX case.
11947 (initialize_low_arch): Initialize MPX targets.
11948
0080a2f6
TT
119492013-11-18 Tom Tromey <tromey@redhat.com>
11950
11951 * configure: Rebuild.
11952 * configure.ac: Don't check for stdlib.h.
11953 * gdbreplay.c: Unconditionally include stdlib.h.
11954
2978b111
TT
119552013-11-18 Tom Tromey <tromey@redhat.com>
11956
11957 * config.in: Rebuild.
11958 * configure: Rebuild.
11959 * configure.ac: Don't use AC_HEADER_DIRENT.
11960
a3d08894
TT
119612013-11-18 Tom Tromey <tromey@redhat.com>
11962
11963 * server.h: Don't check HAVE_STRING_H.
11964 * gdbreplay.c: Don't check HAVE_STRING_H.
11965 * configure: Rebuild.
11966
0a5dd17d
TT
119672013-11-18 Tom Tromey <tromey@redhat.com>
11968
11969 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
11970 LIBGNU.
11971
1bd2f0ba
TT
119722013-11-08 Tom Tromey <tromey@redhat.com>
11973
11974 * configure, config.in: Rebuild.
11975 * configure.ac: Remove unused configury.
11976
3266f10b
TT
119772013-11-08 Tom Tromey <tromey@redhat.com>
11978
11979 * acinclude.m4: Include common.m4, codeset.m4.
11980 * configure, config.in: Rebuild.
11981 * configure.ac: Use GDB_AC_COMMON.
11982
6682d959
AA
119832013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
11984
11985 * linux-s390-low.c (HWCAP_S390_TE): New define.
11986 (s390_arch_setup): Consider the TE field in the HWCAP for
11987 determining 'have_regset_tdb'.
11988
fd0a4d76
SDJ
119892013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
11990
11991 PR gdb/16014
11992 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
11993 call to sizeof.
11994
1a3d890b
PA
119952013-10-02 Pedro Alves <palves@redhat.com>
11996
11997 * server.c (process_serial_event): Don't output "GDBserver
11998 exiting" if GDB is connected through stdio.
11999 * target.c (mywait): Likewise, be silent if GDB is connected
12000 through stdio.
12001
97ad4581
JB
120022013-10-01 Joel Brobecker <brobecker@adacore.com>
12003
12004 * lynx-low.c (lynx_add_threads_after_attach): New function.
12005 (lynx_attach): Remove call to add_thread. Add call to
12006 lynx_add_threads_after_attach instead.
12007
5b4e221c
MF
120082013-09-28 Mike Frysinger <vapier@gentoo.org>
12009
12010 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
12011 * config.in, configure: Regenerated.
12012
ee47b2f8
YQ
120132013-09-18 Yao Qi <yao@codesourcery.com>
12014
12015 PR server/15959
12016 * server.c (start_inferior): Clear 'resume_info'.
12017
d6707650 120182013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 12019
d6707650
JW
12020 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
12021 for each register.
12022
9243dd0e 120232013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 12024
9243dd0e
JW
12025 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
12026 linux-tile-low.o to srv_tgtobj.
12027
c623a6ef
WN
120282013-09-16 Will Newton <will.newton@linaro.org>
12029
12030 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
12031 out regs.
12032
fb71d39e
PA
120332013-09-06 Pedro Alves <palves@redhat.com>
12034
12035 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
12036 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
12037 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
12038 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
12039 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
12040 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
12041
8e7e9910
PA
120422013-09-06 Pedro Alves <palves@redhat.com>
12043
12044 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
12045 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
12046
7c3a12ca
PA
120472013-09-06 Pedro Alves <palves@redhat.com>
12048
12049 * linux-amd64-ipa.c: Include tracepoint.h.
12050 * linux-i386-ipa.c: Include tracepoint.h.
12051
8eb3d7b6
RW
120522013-09-06 Ricard Wanderlof <ricardw@axis.com>
12053
12054 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
12055 (ps_get_thread_area): New function.
12056
eddddb9d
RW
120572013-09-06 Ricard Wanderlof <ricardw@axis.com>
12058
12059 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
12060 (initialize_low_arch): Call init_registers_crisv32 rather than
12061 init_register_crisv32.
12062
533b0600
PA
120632013-09-05 Pedro Alves <palves@redhat.com>
12064
12065 * server.h (handle_vFile, hostio_last_error_from_errno): Move
12066 to ...
12067 * hostio.h: ... this new file.
12068 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
12069 win32-low.c: Include hostio.h.
12070
0ce3d3b5
PA
120712013-09-05 Pedro Alves <palves@redhat.com>
12072
12073 * server.h (gdb_client_data, handler_func, callback_handler_func)
12074 (delete_file_handler, add_file_handler, append_callback_event)
12075 (delete_callback_event, start_event_loop, initialize_event_loop):
12076 Move to event-loop.h and include it.
12077 * event-loop.h: New file.
12078
799cdc37
PA
120792013-09-05 Pedro Alves <palves@redhat.com>
12080
12081 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
12082 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
12083 (loaded_dll, unloaded_dll): Move to ...
12084 * dll.h: ... this new file.
12085 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
12086
6a6bbd9d
PA
120872013-09-05 Pedro Alves <palves@redhat.com>
12088
12089 * server.h (current_process, get_thread_process, all_processes)
12090 (add_inferior_to_list, for_each_inferior, current_inferior)
12091 (remove_inferior, add_process, remove_process, find_process_pid)
12092 (have_started_inferiors_p, have_attached_inferiors_p)
12093 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
12094 (clear_inferiors, find_inferior, find_inferior_id)
12095 (inferior_target_data, set_inferior_target_data)
12096 (inferior_regcache_data, set_inferior_regcache_data): Move to
12097 inferiors.h, and include it.
12098 * inferiors.h: New file.
12099
f699aaba
PA
121002013-09-05 Pedro Alves <palves@redhat.com>
12101
12102 * server.h (struct emit_ops, current_insn_ptr, emit_error):
12103 Move ...
72f4393d 12104 * ax.h: ... here.
f699aaba 12105
c144c7a0
PA
121062013-09-05 Pedro Alves <palves@redhat.com>
12107
12108 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
12109 tracepoint.h.
12110 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
12111 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
12112 (handle_tracepoint_general_set, handle_tracepoint_query)
12113 (tracepoint_finished_step, tracepoint_was_hit)
12114 (release_while_stepping_state_list, current_traceframe)
12115 (in_readonly_region, traceframe_read_mem)
12116 (fetch_traceframe_registers, traceframe_read_sdata)
12117 (traceframe_read_info, struct fast_tpoint_collect_status)
12118 (fast_tracepoint_collecting, force_unlock_trace_buffer)
12119 (handle_tracepoit_bkpts, initialize_low_tracepoint)
12120 (supply_fast_tracepoint_registers)
12121 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
12122 (ipa_tdesc, claim_trampoline_space)
12123 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
12124 (agent_mem_read, agent_get_trace_state_variable_value)
12125 (agent_set_trace_state_variable_value, agent_tsv_read)
12126 (agent_mem_read_string, get_raw_reg_func_addr)
12127 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
12128 * tracepoint.h: ... this new file.
12129
ff42e6ab
PA
121302013-09-05 Pedro Alves <palves@redhat.com>
12131
12132 * server.h (perror_with_name, error, fatal, warning, paddress)
12133 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
12134 include it.
12135 * utils.h: New file.
12136
541af0f4
PA
121372013-09-05 Pedro Alves <palves@redhat.com>
12138
12139 * server.h (remote_debug, noack_mode, transport_is_reliable)
12140 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
12141 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
12142 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
12143 (write_enn, initialize_async_io, enable_async_io)
12144 (disable_async_io, check_remote_input_interrupt_request)
12145 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
12146 (dead_thread_notify, prepare_resume_reply)
12147 (decode_address_to_semicolon, decode_address, decode_m_packet)
12148 (decode_M_packet, decode_X_packet, decode_xfer_write)
12149 (decode_search_memory_packet, unhexify, hexify)
12150 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
12151 (look_up_one_symbol, relocate_instruction)
12152 (monitor_output): Move to remote-utils.h, and include it.
12153 * remote-utils.h: New file.
12154
eebdf26b
PA
121552013-09-05 Pedro Alves <palves@redhat.com>
12156
12157 * server.h (_): Delete.
12158
3aafd2ff
PA
121592013-09-02 Pedro Alves <palves@redhat.com>
12160
12161 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
12162 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
12163 allocated.
12164 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
12165
cee83bcb
PM
121662013-09-02 Pierre Muller <muller@sourceware.org>
12167
12168 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
12169 or WriteProcessMemory complete successfully and handle
12170 ERROR_PARTIAL_COPY error.
12171
9a13b2fa
PA
121722013-09-02 Pedro Alves <palves@redhat.com>
12173
12174 * server.c (gdb_read_memory): Return -1 on traceframe memory read
12175 error instead of EIO.
12176
602e3198
JK
121772013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12178
12179 PR server/15604
12180 * linux-low.c: Include filestuff.h.
12181 (linux_create_inferior) <pid == 0>: Call close_most_fds.
12182 * lynx-low.c: Include filestuff.h.
12183 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
12184 * server.c: Include filestuff.h.
12185 (main): Call notice_open_fds.
12186 * spu-low.c: Include filestuff.h.
12187 (spu_create_inferior) <pid == 0>: Call close_most_fds.
12188
96d7229d
LM
121892013-08-22 Luis Machado <lgustavo@codesourcery.com>
12190
12191 * Makefile.in: Explain why ../target and ../nat are not
12192 listed as include file search paths.
12193 (linux-waitpid.o): New object file rule.
12194 * configure.srv (srv_native_linux_obj): New variable.
12195 Replace all occurrences of linux native object files with
12196 $srv_native_linux_obj.
12197 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
12198 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
12199 (linux_enable_event_reporting): Remove declaration.
12200 (my_waitpid): Moved to common/linux-waitpid.c.
12201 (linux_wait_for_event): Pass ptid when calling
12202 linux_enable_event_reporting.
12203 (linux_supports_tracefork_flag): Remove.
12204 (linux_enable_event_reporting): Likewise.
12205 (linux_tracefork_grandchild): Remove.
12206 (STACK_SIZE): Moved to common/linux-ptrace.c.
12207 (linux_tracefork_child): Remove.
12208 (linux_test_for_tracefork): Remove.
12209 (linux_look_up_symbols): Call linux_supports_traceclone.
12210 (initialize_low): Remove call to linux_test_for_tracefork.
12211 * linux-low.h (PTRACE_TYPE_ARG3): Move to
12212 common/linux-ptrace.h.
12213 (PTRACE_TYPE_ARG4): Likewise.
12214 Include linux-ptrace.h.
12215
32940073
PA
122162013-08-21 Pedro Alves <palves@redhat.com>
12217
12218 * config.in: Renegerate.
12219
33b60d58 122202013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 12221
33b60d58
LM
12222 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
12223 (SFILES): Remove $(srcdir)/common/target-common.c and
12224 add $(srcdir)/target/waitstatus.c.
12225 (OBS): Remove target-common.o and add waitstatus.o.
12226 (server_h): Remove $(srcdir)/../common/target-common.h and
12227 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
12228 and $(srcdir)/../target/waitstatus.h.
12229 (target-common.o): Remove.
12230 (waitstatus.o): New target object file.
12231 * target.h: Do not include target-common.h and
12232 include target/resume.h, target/wait.h and
12233 target/waitstatus.h.
12234
b8e1b30e
LM
122352013-08-13 Luis Machado <lgustavo@codesourcery.com>
12236
12237 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
12238 to PTRACE_TYPE_ARG3.
12239 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
12240 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
12241 PTRACE_TYPE_ARG4.
12242 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
12243 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
12244
7a60ad40
YQ
122452013-07-27 Jie Zhang <jie@codesourcery.com>
12246 Daniel Jacobowitz <dan@codesourcery.com>
12247 Yao Qi <yao@codesourcery.com>
12248
12249 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
12250 (mips-linux-watch.o): New rule.
12251 (mips_linux_watch_h): New variable.
12252 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
12253 srv_tgtobj.
12254 * linux-mips-low.c: Include mips-linux-watch.h.
12255 (struct arch_process_info, struct arch_lwp_info): New.
12256 (update_watch_registers_callback): New function.
12257 (mips_linux_new_process, mips_linux_new_thread) New functions.
12258 (mips_linux_prepare_to_resume, mips_insert_point): New
12259 functions.
12260 (mips_remove_point, mips_stopped_by_watchpoint): New
12261 functions.
12262 (rsp_bp_type_to_target_hw_bp_type): New function.
12263 (mips_stopped_data_address): New function.
12264 (the_low_target): Add watchpoint support functions.
12265
de6f69ad
YQ
122662013-07-27 Yao Qi <yao@codesourcery.com>
12267
12268 * i386-low.c: Include break-common.h.
12269 (enum target_hw_bp_type): Remove.
12270
3360c0bf
LM
122712013-07-24 Luis Machado <lgustavo@codesourcery.com>
12272
12273 * Makefile.in (SFILES): /common/target-common.c.
12274 (OBS): Add target-common.o.
12275 (server_h): Add $(srcdir)/../common/target-common.h.
12276 (target-common.o): New target.
12277 * server.c (queue_stop_reply_callback): Free
12278 status string after use.
12279 * target.c (target_waitstatus_to_string): Remove.
12280 * target.h: Include target-common.h.
12281 (resume_kind): Likewise.
12282 (target_waitkind): Likewise.
12283 (target_waitstatus): Likewise.
12284 (TARGET_WNOHANG): Likewise.
12285
bd885420
YQ
122862013-07-04 Yao Qi <yao@codesourcery.com>
12287
12288 * Makefile.in (host_alias): Use @host_noncanonical@.
12289 (target_alias): Use @target_noncanonical@.
12290 * configure.ac: Use ACX_NONCANONICAL_TARGET and
12291 ACX_NONCANONICAL_HOST.
12292 * configure: Regenerated.
12293
12294 Revert:
12295 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
12296
12297 * configure.ac (version_host, version_target): Set and AC_SUBST them.
12298 * configure: Rebuild.
12299 * Makefile.in (version_host, version_target): Get from configure.
12300 (version.c): Use $(version_host) and $(version_target).
12301
17ef446e
PA
123022013-07-03 Pedro Alves <palves@redhat.com>
12303
12304 * Makefile.in (config.status): Depend on development.sh.
12305 * acinclude.m4: Include libmcheck.m4.
12306 * configure: Regenerate.
12307
7a9a7487
MG
123082013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
12309
12310 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
12311 attribute inside the parentheses.
12312 (winapi_DebugSetProcessKillOnExit): Ditto.
12313 (winapi_DebugBreakProcess): Ditto.
12314 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 12315
49b64de6
MG
123162013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
12317
12318 * notif.h (notif_event): Add a dummy member to avoid compiler
12319 errors.
12320
d5749ee7
PA
123212013-07-01 Pedro Alves <palves@redhat.com>
12322
12323 * hostio.c (HOSTIO_PATH_MAX): Define.
12324 (require_filename, handle_open, handle_unlink, handle_readlink):
12325 Use it.
12326
d8d2a3ee
PA
123272013-07-01 Pedro Alves <palves@redhat.com>
12328
12329 * server.h: Include "pathmax.h".
12330 * linux-low.c: Don't include sys/param.h.
12331 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
12332 MAXPATHLEN.
12333 * win32-low.c: Don't include sys/param.h.
12334 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
12335
bc7dea8d
PA
123362013-07-01 Pedro Alves <palves@redhat.com>
12337
12338 * event-loop.c: Don't check HAVE_UNISTD_H before including
12339 <unistd.h>.
12340 * gdbreplay.c: Likewise.
12341 * remote-utils.c: Likewise.
12342 * server.c: Likewise.
12343 * configure.ac: Don't check for unistd.h.
12344 * configure: Regenerate.
12345
d6c2da54
TT
123462013-06-28 Tom Tromey <tromey@redhat.com>
12347
12348 * Makefile.in (version.c): Use version.in, not
12349 common/version.in.
12350
257b6bec
MG
123512013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
12352
12353 * configure.ac (version_host, version_target): Set and AC_SUBST them.
12354 * configure: Rebuild.
12355 * Makefile.in (version_host, version_target): Get from configure.
12356 (version.c): Use $(version_host) and $(version_target).
12357
86ebe149
DK
123582013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
12359
12360 Fix trace-status to output user name without trailing colon.
12361 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
12362
f30aa5af
DK
123632013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
12364
12365 Fix trace-status to output proper start-time and stop-time.
12366 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
12367 output start time and stop time in hex as gdb expects.
12368
28a93511
YQ
123692013-06-26 Pedro Alves <pedro@codesourcery.com>
12370
12371 * tracepoint.c (build_traceframe_info_xml): Output trace state
12372 variables present in the trace buffer.
12373
01208463
TT
123742013-06-24 Tom Tromey <tromey@redhat.com>
12375
12376 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
12377 create-version.sh.
12378 (version.o): Remove.
12379 * gdbreplay.c: Include version.h.
12380 (version, host_name): Don't declare.
12381 * server.h: Include version.h.
12382 (version, host_name): Don't declare.
12383
760256f9
PA
123842013-06-12 Pedro Alves <palves@redhat.com>
12385
12386 * linux-x86-low.c (linux_is_elf64): Delete global.
12387 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
12388 with local linux_pid_exe_is_elf_64_file use.
12389
030031ee
PA
123902013-06-11 Pedro Alves <palves@redhat.com>
12391
12392 * linux-low.c (regset_disabled, disable_regset): New functions.
12393 (regsets_fetch_inferior_registers)
12394 (regsets_store_inferior_registers): Use them.
12395 (initialize_regsets_info); Don't allocate the disabled_regsets
12396 array here.
12397 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
12398 comment.
12399
5da6eb0a
PA
124002013-06-11 Pedro Alves <palves@redhat.com>
12401
12402 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
12403 xmalloc.
12404
7e5aaa09
PA
124052013-06-11 Pedro Alves <palves@redhat.com>
12406
12407 * linux-x86-low.c (initialize_low_arch): Call
12408 init_registers_x32_avx_linux.
12409
d878444c
JK
124102013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
12411
12412 Fix compatibility with Android Bionic.
12413 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
12414 it is not empty.
12415
3aee8918
PA
124162013-06-07 Pedro Alves <palves@redhat.com>
12417
5f2b57b5 12418 PR server/14823
3aee8918
PA
12419 * Makefile.in (OBS): Add tdesc.o.
12420 (IPA_OBJS): Add tdesc-ipa.o.
12421 (tdesc-ipa.o): New rule.
12422 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
12423 interface.
12424 * linux-low.c (new_inferior): Delete.
12425 (disabled_regsets, num_regsets): Delete.
12426 (linux_add_process): Adjust to set the new per-process
12427 new_inferior flag.
12428 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
12429 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
12430 was a stop. When calling arch_setup, switch the current inferior
12431 to the thread that got an event.
12432 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
12433 (regsets_fetch_inferior_registers)
12434 (regsets_store_inferior_registers): New regsets_info parameter.
12435 Adjust to use it.
12436 (linux_register_in_regsets): New regs_info parameter. Adjust to
12437 use it.
12438 (register_addr, fetch_register, store_register): New usrregs_info
12439 parameter. Adjust to use it.
12440 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
12441 parameter regs_info. Adjust to use it.
12442 (linux_fetch_registers): Get the current inferior's regs_info, and
12443 adjust to use it.
12444 (linux_store_registers): Ditto.
12445 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
12446 (initialize_low): Don't initialize the target_regsets here. Call
12447 initialize_low_arch.
12448 * linux-low.h (target_regsets): Delete declaration.
12449 (struct regsets_info): New.
12450 (struct usrregs_info): New.
12451 (struct regs_info): New.
12452 (struct process_info_private) <new_inferior>: New field.
12453 (struct linux_target_ops): Delete the num_regs, regmap, and
12454 regset_bitmap fields. New field regs_info.
12455 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
12456 * i387-fp.c (num_xmm_registers): Delete.
12457 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
12458 calls to new interface.
12459 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
12460 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
12461 Infer the number of xmm registers from the regcache's target
12462 description.
12463 * i387-fp.h (num_xmm_registers): Delete.
12464 * inferiors.c (add_thread): Don't install the thread's regcache
12465 here.
12466 * proc-service.c (gregset_info): Fetch the current inferior's
12467 regs_info. Adjust to use it.
12468 * regcache.c: Include tdesc.h.
12469 (register_bytes, reg_defs, num_registers)
12470 (gdbserver_expedite_regs): Delete.
12471 (get_thread_regcache): If the thread doesn't have a regcache yet,
12472 create one, instead of aborting gdbserver.
12473 (regcache_invalidate_one): Rename to ...
12474 (regcache_invalidate_thread): ... this.
12475 (regcache_invalidate_one): New.
12476 (regcache_invalidate): Only invalidate registers of the current
12477 process.
12478 (init_register_cache): Add target_desc parameter, and use it.
12479 (new_register_cache): Ditto. Assert the target description has a
12480 non zero registers_size.
12481 (regcache_cpy): Add assertions. Adjust.
12482 (realloc_register_cache, set_register_cache): Delete.
12483 (registers_to_string, registers_from_string): Adjust.
12484 (find_register_by_name, find_regno, find_register_by_number)
12485 (register_cache_size): Add target_desc parameter, and use it.
12486 (free_register_cache_thread, free_register_cache_thread_one)
12487 (regcache_release, register_cache_size): New.
12488 (register_size): Add target_desc parameter, and use it.
12489 (register_data, supply_register, supply_register_zeroed)
12490 (supply_regblock, supply_register_by_name, collect_register)
12491 (collect_register_as_string, collect_register_by_name): Adjust.
12492 * regcache.h (struct target_desc): Forward declare.
12493 (struct regcache) <tdesc>: New field.
12494 (init_register_cache, new_register_cache): Add target_desc
12495 parameter.
12496 (regcache_invalidate_thread): Declare.
12497 (regcache_invalidate_one): Delete declaration.
12498 (regcache_release): Declare.
12499 (find_register_by_number, register_cache_size, register_size)
12500 (find_regno): Add target_desc parameter.
12501 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
12502 declarations.
12503 * remote-utils.c: Include tdesc.h.
12504 (outreg, prepare_resume_reply): Adjust.
12505 * server.c: Include tdesc.h.
12506 (gdbserver_xmltarget): Delete declaration.
12507 (get_features_xml, process_serial_event): Adjust.
12508 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
12509 declare.
12510 (struct process_info) <tdesc>: New field.
12511 (ipa_tdesc): Declare.
12512 * tdesc.c: New file.
12513 * tdesc.h: New file.
12514 * tracepoint.c: Include tdesc.h.
12515 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
12516 (get_context_regcache): Adjust to pass ipa_tdesc down.
12517 (do_action_at_tracepoint): Adjust to get the register cache size
12518 from the context regcache's description.
12519 (traceframe_walk_blocks): Adjust to get the register cache size
12520 from the current trace frame's description.
12521 (traceframe_get_pc): Adjust to get current trace frame's
12522 description and pass it down.
12523 (gdb_collect): Adjust to get the register cache size from the
12524 IPA's description.
12525 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
12526 (gdbserver_xmltarget): Delete.
12527 (initialize_low_tracepoint): Set the ipa's target description.
12528 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
12529 (initialize_low_tracepoint): Set the ipa's target description.
12530 * linux-x86-low.c: Include tdesc.h.
12531 [__x86_64__] (is_64bit_tdesc): New.
12532 (ps_get_thread_area, x86_get_thread_area): Use it.
12533 (i386_cannot_store_register): Rename to ...
12534 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
12535 (i386_cannot_fetch_register): Rename to ...
12536 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
12537 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
12538 to new interface.
12539 (target_regsets): Rename to ...
12540 (x86_regsets): ... this.
12541 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
12542 interface.
12543 (x86_siginfo_fixup): Use is_64bit_tdesc.
12544 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
12545 (tdesc_x32_avx_linux, tdesc_x32_linux)
12546 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
12547 Declare.
12548 (x86_linux_update_xmltarget): Delete.
12549 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
12550 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
12551 (AMD64_LINUX_USER64_CS): New.
12552 (x86_linux_read_description): New, based on
12553 x86_linux_update_xmltarget.
12554 (same_process_callback): New.
12555 (x86_arch_setup_process_callback): New.
12556 (x86_linux_update_xmltarget): New.
12557 (x86_regsets_info): New.
12558 (amd64_linux_regs_info): New.
12559 (i386_linux_usrregs_info): New.
12560 (i386_linux_regs_info): New.
12561 (x86_linux_regs_info): New.
12562 (x86_arch_setup): Reimplement.
12563 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
12564 (x86_emit_ops): Ditto.
12565 (the_low_target): Adjust. Install x86_linux_regs_info,
12566 x86_cannot_fetch_register, and x86_cannot_store_register.
12567 (initialize_low_arch): New.
12568 * linux-ia64-low.c (tdesc_ia64): Declare.
12569 (ia64_fetch_register): Adjust.
12570 (ia64_usrregs_info, regs_info): New globals.
12571 (ia64_regs_info): New function.
12572 (the_low_target): Adjust.
12573 (initialize_low_arch): New function.
12574 * linux-sparc-low.c (tdesc_sparc64): Declare.
12575 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
12576 Adjust.
12577 (sparc_arch_setup): New function.
12578 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
12579 (the_low_target): Adjust.
12580 (initialize_low_arch): New function.
12581 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
12582 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
12583 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
12584 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
12585 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
12586 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
12587 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
12588 (tdesc_powerpc_isa205_vsx64l): Declare.
12589 (ppc_cannot_store_register, ppc_collect_ptrace_register)
12590 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
12591 (ppc_set_pc, ppc_get_hwcap): Adjust.
12592 (ppc_usrregs_info): Forward declare.
12593 (!__powerpc64__) ppc_regmap_adjusted: New global.
12594 (ppc_arch_setup): Adjust to the current process'es target
12595 description.
12596 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
12597 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
12598 (ppc_store_evrregset): Adjust.
12599 (target_regsets): Rename to ...
12600 (ppc_regsets): ... this, and make static.
12601 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
12602 (ppc_regs_info): New function.
12603 (the_low_target): Adjust.
12604 (initialize_low_arch): New function.
12605 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
12606 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
12607 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
12608 (tdesc_s390x_linux64v2): Declare.
12609 (s390_collect_ptrace_register, s390_supply_ptrace_register)
12610 (s390_fill_gregset, s390_store_last_break): Adjust.
12611 (target_regsets): Rename to ...
12612 (s390_regsets): ... this, and make static.
12613 (s390_get_pc, s390_set_pc): Adjust.
12614 (s390_get_hwcap): New target_desc parameter, and use it.
12615 [__s390x__] (have_hwcap_s390_high_gprs): New global.
12616 (s390_arch_setup): Adjust to set the current process'es target
12617 description. Don't adjust the regmap.
12618 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
12619 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
12620 (regs_info_3264): New globals.
12621 (s390_regs_info): New function.
12622 (the_low_target): Adjust.
12623 (initialize_low_arch): New function.
12624 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
12625 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
12626 [__mips64] (init_registers_mips_linux)
12627 (init_registers_mips_dsp_linux): Delete defines.
12628 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
12629 (have_dsp): New global.
12630 (mips_read_description): New, based on mips_arch_setup.
12631 (mips_arch_setup): Reimplement.
12632 (get_usrregs_info): New function.
12633 (mips_cannot_fetch_register, mips_cannot_store_register)
12634 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
12635 (mips_fill_fpregset, mips_store_fpregset): Adjust.
12636 (target_regsets): Rename to ...
12637 (mips_regsets): ... this, and make static.
12638 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
12639 (dsp_regs_info, regs_info): New globals.
12640 (mips_regs_info): New function.
12641 (the_low_target): Adjust.
12642 (initialize_low_arch): New function.
12643 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
12644 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
12645 Declare.
12646 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
12647 (arm_read_description): New, with bits factored from
12648 arm_arch_setup.
12649 (arm_arch_setup): Reimplement.
12650 (target_regsets): Rename to ...
12651 (arm_regsets): ... this, and make static.
12652 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
12653 (arm_regs_info): New function.
12654 (the_low_target): Adjust.
12655 (initialize_low_arch): New function.
12656 * linux-m68k-low.c (tdesc_m68k): Declare.
12657 (target_regsets): Rename to ...
12658 (m68k_regsets): ... this, and make static.
12659 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
12660 (m68k_regs_info): New function.
12661 (m68k_arch_setup): New function.
12662 (the_low_target): Adjust.
12663 (initialize_low_arch): New function.
12664 * linux-sh-low.c (tdesc_sharch): Declare.
12665 (target_regsets): Rename to ...
12666 (sh_regsets): ... this, and make static.
12667 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
12668 (sh_regs_info, sh_arch_setup): New functions.
12669 (the_low_target): Adjust.
12670 (initialize_low_arch): New function.
12671 * linux-bfin-low.c (tdesc_bfin): Declare.
12672 (bfin_arch_setup): New function.
12673 (bfin_usrregs_info, regs_info): New globals.
12674 (bfin_regs_info): New function.
12675 (the_low_target): Adjust.
12676 (initialize_low_arch): New function.
12677 * linux-cris-low.c (tdesc_cris): Declare.
12678 (cris_arch_setup): New function.
12679 (cris_usrregs_info, regs_info): New globals.
12680 (cris_regs_info): New function.
12681 (the_low_target): Adjust.
12682 (initialize_low_arch): New function.
12683 * linux-cris-low.c (tdesc_crisv32): Declare.
12684 (cris_arch_setup): New function.
12685 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
12686 (cris_regs_info): New function.
12687 (the_low_target): Adjust.
12688 (initialize_low_arch): New function.
12689 * linux-m32r-low.c (tdesc_m32r): Declare.
12690 (m32r_arch_setup): New function.
12691 (m32r_usrregs_info, regs_info): New globals.
12692 (m32r_regs_info): Adjust.
12693 (initialize_low_arch): New function.
12694 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
12695 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
12696 (tic6x_usrregs_info): Forward declare.
12697 (tic6x_read_description): New function, based on ...
12698 (tic6x_arch_setup): ... this. Reimplement.
12699 (target_regsets): Rename to ...
12700 (tic6x_regsets): ... this, and make static.
12701 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
12702 (tic6x_regs_info): New function.
12703 (the_low_target): Adjust.
12704 (initialize_low_arch): New function.
12705 * linux-xtensa-low.c (tdesc_xtensa): Declare.
12706 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
12707 (target_regsets): Rename to ...
12708 (xtensa_regsets): ... this, and make static.
12709 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
12710 globals.
12711 (xtensa_arch_setup, xtensa_regs_info): New functions.
12712 (the_low_target): Adjust.
12713 (initialize_low_arch): New function.
12714 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
12715 (nios2_arch_setup): Set the current process'es tdesc.
12716 (target_regsets): Rename to ...
12717 (nios2_regsets): ... this.
12718 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
12719 (nios2_regs_info): New function.
12720 (the_low_target): Adjust.
12721 (initialize_low_arch): New function.
a261b8f5
PA
12722 * linux-aarch64-low.c (tdesc_aarch64): Declare.
12723 (aarch64_arch_setup): Set the current process'es tdesc.
12724 (target_regsets): Rename to ...
12725 (aarch64_regsets): ... this.
12726 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
12727 (aarch64_regs_info): New function.
12728 (the_low_target): Adjust.
12729 (initialize_low_arch): New function.
3aee8918
PA
12730 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
12731 globals.
12732 (target_regsets): Rename to ...
12733 (tile_regsets): ... this.
12734 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
12735 (tile_regs_info): New function.
12736 (tile_arch_setup): Set the current process'es tdesc.
12737 (the_low_target): Adjust.
12738 (initialize_low_arch): New function.
12739 * spu-low.c (tdesc_spu): Declare.
12740 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
12741 * win32-arm-low.c (tdesc_arm): Declare.
12742 (arm_arch_setup): New function.
12743 (the_low_target): Install arm_arch_setup instead of
12744 init_registers_arm.
12745 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
12746 (init_windows_x86): Rename to ...
12747 (i386_arch_setup): ... this. Set `win32_tdesc'.
12748 (the_low_target): Adjust.
12749 * win32-low.c (win32_tdesc): New global.
12750 (child_add_thread): Don't create the thread cache here.
12751 (do_initial_child_stuff): Set the new process'es tdesc.
12752 * win32-low.h (struct target_desc): Forward declare.
12753 (win32_tdesc): Declare.
12754 * lynx-i386-low.c (tdesc_i386): Declare global.
12755 (lynx_i386_arch_setup): Set `lynx_tdesc'.
12756 * lynx-low.c (lynx_tdesc): New global.
12757 (lynx_add_process): Set the new process'es tdesc.
12758 * lynx-low.h (struct target_desc): Forward declare.
12759 (lynx_tdesc): Declare global.
12760 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
12761 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
12762 * nto-low.c (nto_tdesc): New global.
12763 (do_attach): Set the new process'es tdesc.
12764 * nto-low.h (struct target_desc): Forward declare.
12765 (nto_tdesc): Declare.
12766 * nto-x86-low.c (tdesc_i386): Declare.
12767 (nto_x86_arch_setup): Set `nto_tdesc'.
12768
b1fbec62
GB
127692013-06-04 Gary Benson <gbenson@redhat.com>
12770
12771 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
12772 to qSupported response when appropriate.
12773 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
12774 with nonzero-length annex.
12775 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
12776 arguments supplied in annex.
12777
d1ec4ce7
DE
127782013-05-31 Doug Evans <dje@google.com>
12779
ac44adcb 12780 PR server/15594
d1ec4ce7
DE
12781 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
12782 64 bits in 64-cross-32 environment.
12783
9b25f2d3
PA
127842013-05-28 Pedro Alves <palves@redhat.com>
12785
12786 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
12787 (aarch64-without-fpu.c): Delete rule.
12788 * configure.srv (aarch64*-*-linux*): Remove references to
12789 aarch64-without-fpu.o and aarch64-without-fpu.xml.
12790 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
12791 declaration.
12792
6740dc9c
PA
127932013-05-24 Pedro Alves <palves@redhat.com>
12794
12795 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
12796 instead of strchr/decode_address. Error if the range isn't split
12797 with a ','. Don't assume there's be a ':' in the action.
12798
c2d6af84
PA
127992013-05-23 Yao Qi <yao@codesourcery.com>
12800 Pedro Alves <palves@redhat.com>
12801
12802 * linux-low.c (lwp_in_step_range): New function.
12803 (linux_wait_1): If the thread was range stepping and stopped
12804 outside the stepping range, report the stop to GDB. Otherwise,
12805 continue stepping. Add range stepping debug output.
12806 (linux_set_resume_request): Copy the step range from the resume
12807 request to the lwp.
12808 (linux_supports_range_stepping): New.
12809 (linux_target_ops) <supports_range_stepping>: Set to
12810 linux_supports_range_stepping.
12811 * linux-low.h (struct linux_target_ops)
12812 <supports_range_stepping>: New field.
12813 (struct lwp_info) <step_range_start, step_range_end>: New fields.
12814 * linux-x86-low.c (x86_supports_range_stepping): New.
12815 (the_low_target) <supports_range_stepping>: Set to
12816 x86_supports_range_stepping.
12817 * server.c (handle_v_cont): Handle 'r' action.
12818 (handle_v_requests): Append ";r" if the target supports range
12819 stepping.
12820 * target.h (struct thread_resume) <step_range_start,
12821 step_range_end>: New fields.
12822 (struct target_ops) <supports_range_stepping>:
12823 New field.
12824 (target_supports_range_stepping): New macro.
12825
58794e1a
JB
128262013-05-17 Joel Brobecker <brobecker@adacore.com>
12827
12828 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
12829 confusion in comment.
12830
d631c5a7
JB
128312013-05-17 Joel Brobecker <brobecker@adacore.com>
12832
12833 * lynx-low.c (struct process_info_private): New type.
12834 (lynx_add_process): New function.
12835 (lynx_create_inferior, lynx_attach): Replace calls to
12836 add_process by calls to lynx_add_process.
12837 (lynx_resume): If PTID is null, then try using
12838 current_process()->private->last_wait_event_ptid.
12839 Add comments.
12840 (lynx_clear_inferiors): Delete. The contents of that function
12841 has been inlined in lynx_mourn;
12842 (lynx_wait_1): Save the ptid in the process's private data.
12843 (lynx_mourn): Free the process' private data. Replace call
12844 to lynx_clear_inferiors by call to clear_inferiors.
12845
96f7a20f
YQ
128462013-05-17 Yao Qi <yao@codesourcery.com>
12847
12848 * i386-low.c (i386_length_and_rw_bits): Move the comment to
12849 the right place.
12850
db0dfaa0
LM
128512013-05-16 Luis Machado <lgustavo@codesourcery.com>
12852
12853 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
12854 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
12855 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
12856 PT_TEXT_END_ADDR guards. Update comments.
12857 (linux_target_op) <read_offsets>: Conditionally define to
12858 linux_read_offsets if the target is UCLIBC and if it defines
12859 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
12860
68f5f838
SL
128612013-05-06 Sandra Loosemore <sandra@codesourcery.com>
12862 Andrew Jenner <andrew@codesourcery.com>
12863
12864 * Makefile.in (SFILES): Add linux-nios2-low.c.
12865 (clean): Add action to delete nios2-linux.c.
12866 (nios2-linux.c): New rule.
12867 * configure.srv: Add nios2*-*-linux*.
12868 * linux-nios2-low.c: New.
12869
1ebff1fd
HAQ
128702013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
12871
12872 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
12873
f6150862
HZ
128742013-04-25 Hui Zhu <hui@codesourcery.com>
12875
12876 PR gdb/15186
f6150862
HZ
12877 * ax.c (ax_printf): Add fflush.
12878
614c279d
TT
128792013-04-22 Tom Tromey <tromey@redhat.com>
12880
12881 * Makefile.in (SFILES): Add filestuff.c.
12882 (OBS): Add filestuff.o.
12883 (filestuff.o): New target.
12884 * config.in, configure: Rebuild.
12885 * configure.ac: Check for fdwalk, pipe2.
12886
7d4e5717
PA
128872013-04-17 Pedro Alves <palves@redhat.com>
12888
12889 * configure.ac (USE_THREAD_DB): Delete variable.
12890 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
12891 Don't AC_SUBST USE_THREAD_DB.
12892 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
12893 * config.in, configure: Regenerate.
12894
d5c93e41
PA
128952013-04-16 Pedro Alves <palves@redhat.com>
12896
12897 * linux-low.h (struct lwp_info) <thread_known>: Move under
12898 the USE_THREAD_DB #ifdef.
12899
04f5fe89
PA
129002013-04-16 Pedro Alves <palves@redhat.com>
12901
12902 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
12903 (linux-low.o): Delete rule.
12904 * linux-low.h: Always include "gdb_thread_db.h" instead of
12905 conditionally including thread_db.h.
12906 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
12907 HAVE_THREAD_DB_H.
12908
480b27bf
JK
129092013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12910
12911 * Makefile.in (install-only): Fix make install regression.
12912
43662968
JK
129132013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
12914
12915 Convert man pages to texinfo, new gdbinit.5 texinfo page.
12916 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
12917 installation.
12918 * gdbserver.1: Remove.
12919
3e74e146
PA
129202013-03-22 Pedro Alves <palves@redhat.com>
12921
12922 * linux-low.c (handle_extended_wait): Don't call
12923 linux_enable_event_reporting.
12924
a8347a2a
TT
129252013-03-15 Tony Theodore <tonyt@logyst.com>
12926
12927 PR build/9098:
12928 * Makefile.in (SHELL): Use @SHELL@.
12929
eeb56fa7
SDJ
129302013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
12931
12932 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
12933 compiler warning.
12934
4fa7e2ff
JB
129352013-03-13 Joel Brobecker <brobecker@adacore.com>
12936
12937 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
12938 Remove extraneous NULL element.
12939
8ddb1965
YQ
129402013-03-13 Yao Qi <yao@codesourcery.com>
12941
12942 * tracepoint.c (traceframe_read_tsv): Look for the last matched
12943 'V' block in trace frame.
12944
9accd112
MM
129452013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12946
12947 * target.h (struct target_ops): Add btrace ops.
12948 (target_supports_btrace): New macro.
12949 (target_enable_btrace): New macro.
12950 (target_disable_btrace): New macro.
12951 (target_read_btrace): New macro.
12952 * gdbthread.h (struct thread_info): Add btrace field.
12953 * server.c: Include btrace-common.h.
12954 (handle_btrace_general_set): New function.
12955 (handle_btrace_enable): New function.
12956 (handle_btrace_disable): New function.
12957 (handle_general_set): Call handle_btrace_general_set.
12958 (handle_qxfer_btrace): New function.
12959 (struct qxfer qxfer_packets[]): Add btrace entry.
12960 * inferiors.c (remove_thread): Disable btrace.
12961 * linux-low: Include linux-btrace.h.
12962 (linux_low_enable_btrace): New function.
12963 (linux_low_read_btrace): New function.
12964 (linux_target_ops): Add btrace ops.
12965 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
12966 Add srv_linux_btrace=yes.
12967 (x86_64-*-linux*): Add linux-btrace.o.
12968 Add srv_linux_btrace=yes.
12969 * configure.ac: Define HAVE_LINUX_BTRACE.
12970 * config.in: Regenerated.
12971 * configure: Regenerated.
12972
5cc22e4c
MM
129732013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12974
12975 * server.c (handle_qxfer): Preserve error message if -3 is
12976 returned.
12977 (qxfer): Document the -3 return value.
12978
7c97f91e
MM
129792013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12980
12981 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
12982 (linux_btrace_h): New variable.
12983 (linux-btrace.o): New rule.
12984
be9a119c 129852013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
12986 Hafiz Abid Qadeer <abidh@codesourcery.com>
12987
12988 * tracepoint.c (trace_buffer_size): New global.
12989 (DEFAULT_TRACE_BUFFER_SIZE): New define.
12990 (init_trace_buffer): Change to one-argument function. Allocate
12991 trace buffer memory.
12992 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
12993 handle QTBuffer:size packet.
12994 (cmd_bigqtbuffer_size): New function.
12995 (initialize_tracepoint): Call init_trace_buffer with
12996 DEFAULT_TRACE_BUFFER_SIZE.
12997 * server.c (handle_query): Add QTBuffer:size in the
12998 supported packets.
12999
e64f7499
YQ
130002013-03-07 Yao Qi <yao@codesourcery.com>
13001
13002 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
13003 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
13004 of -1.
13005 (cmd_qtsp): Adjust condition. Do post increment.
13006 Set cur_action and cur_step_action back to 0.
13007
f0ae6fc3
PA
130082013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
13009
13010 PR server/15236
13011 * linux-low.c (linux_write_memory): Return early success if LEN is
13012 zero.
13013
b5b0b0af
CV
130142013-03-05 Corinna Vinschen <vinschen@redhat.de>
13015
334ad4a8 13016 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 13017
589bc927
TT
130182013-02-28 Tom Tromey <tromey@redhat.com>
13019
13020 * configure.ac: Invoke AC_SYS_LARGEFILE.
13021 * configure, config.in: Rebuild.
13022
dfe07582
CV
130232013-02-28 Corinna Vinschen <vinschen@redhat.com>
13024
13025 * win32-low.c: Throughout, fix format strings and casts of
13026 printf-like functions to avoid type related warnings on all
13027 platforms.
13028 (get_child_debug_event): Print dwDebugEventCode as hex since
13029 that's how it's usually documented.
13030
736cd585
YQ
130312013-02-28 Yao Qi <yao@codesourcery.com>
13032
13033 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
13034 pulongest.
13035
e1f58301
JW
130362013-02-27 Jiong Wang <jiwang@tilera.com>
13037
13038 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
13039 (reg-tilegx32.c): New rule.
13040 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
13041 * linux-tile-low.c (tile_arch_setup): New function. Invoke
13042 different register info initializer according to elf class.
13043 (init_registers_tilgx32): New function. The tilegx32 register info
13044 initializer.
13045 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
13046 (tile_store_gregset): Likewise.
13047
d171ca78
YQ
130482013-02-27 Yao Qi <yao@codesourcery.com>
13049
13050 * server.c (process_point_options): Print debug message when
13051 debug_threads is true.
13052
282bbdf3
YQ
130532013-02-26 Yao Qi <yao@codesourcery.com>
13054
13055 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
13056
aca22551
PA
130572013-02-19 Pedro Alves <palves@redhat.com>
13058 Kai Tietz <ktietz@redhat.com>
13059
13060 PR gdb/15161
13061
13062 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
13063 instead of strtoul to extract address from packet.
13064 (process_serial_event) <'z'>: Likewise.
13065
4f3cee1c
YQ
130662013-02-18 Yao Qi <yao@codesourcery.com>
13067
13068 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
13069
8e1d55a3
PA
130702013-02-14 Pedro Alves <palves@redhat.com>
13071
13072 Plug memory leak.
13073
13074 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
13075 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
13076
458820da
PA
130772013-02-14 Pedro Alves <palves@redhat.com>
13078
13079 * tracepoint.c (cmd_qtdpsrc): Use savestring.
13080
baea0dae
PA
130812013-02-14 Pedro Alves <palves@redhat.com>
13082
13083 * tracepoint.c (save_string): Delete.
13084 (add_tracepoint_action): Use savestring instead of save_string.
13085
0b1afbb3
PA
130862013-02-12 Pedro Alves <palves@redhat.com>
13087
13088 * linux-xtensa-low.c: Ditto.
13089 * xtensa-xtregs.c: Ditto.
13090
8a4ac37e
PA
130912013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
13092
13093 * thread-db.c (thread_db_get_tls_address): NULL pointer check
13094 thread_db.
13095
148de6bb
MS
130962013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
13097
13098 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
13099 aarch64_num_wp_regs and aarch64_num_bp_regs to
13100 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
13101
55fac6e0
MS
131022013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
13103
13104 * linux-aarch64-low.c (ps_get_thread_area): Replace
13105 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
13106
176eb98c
MS
131072013-02-04 Jim MacArthur <jim.macarthur@arm.com>
13108 Marcus Shawcroft <marcus.shawcroft@arm.com>
13109 Nigel Stephens <nigel.stephens@arm.com>
13110 Yufeng Zhang <yufeng.zhang@arm.com>
13111
13112 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
13113 (aarch64.c, aarch64-without-fpu.c): New targets.
13114 * configure.srv (aarch64*-*-linux*): New.
13115 * linux-aarch64-low.c: New file.
13116
56f7af9c
MS
131172013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
13118
43aaf8b6 13119 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
13120 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
13121 (dequeue_one_deferred_signal, linux_resume_one_thread)
13122 (fetch_register, linux_write_memory, linux_enable_event_reporting)
13123 (linux_tracefork_grandchild, linux_test_for_tracefork)
13124 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
13125 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
13126 where the argument is 0.
13127
60f662b0
YQ
131282013-01-25 Yao Qi <yao@codesourcery.com>
13129
13130 * event-loop.c: Include "queue.h".
13131 (gdb_event_p): New typedef.
13132 (struct gdb_event) <next_event>: Remove.
13133 (event_queue): Change to QUEUE(gdb_event_p).
13134 (async_queue_event): Remove.
13135 (gdb_event_xfree): New.
13136 (initialize_event_loop): New.
13137 (process_event): Use API from QUEUE.
13138 (wait_for_event): Likewise.
13139 * server.c (main): Call initialize_event_loop.
13140 * server.h (initialize_event_loop): Declare.
13141
5ae4861a
YQ
131422013-01-18 Yao Qi <yao@codesourcery.com>
13143
13144 * ax.h (struct eval_agent_expr_context): New.
13145 (gdb_eval_agent_expr): Update declaration.
13146 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
13147 TFRAME. Add new argument CTX.
13148 * server.h (struct eval_agent_expr_context): Declare.
13149 (agent_mem_read, agent_tsv_read): Update declaration.
13150 (agent_mem_read_string): Likewise.
13151 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
13152 (add_traceframe_block): Add new argument TPOINT.
13153 Increase TPOINT->traceframe_usage.
13154 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
13155 eval_tracepoint_agent_expr.
13156 (condition_true_at_tracepoint): Likewise.
13157 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
13158 (agent_mem_read_string, agent_tsv_read): Likewise.
13159
85e00e85
YQ
131602013-01-16 Yao Qi <yao@codesourcery.com>
13161
13162 * linux-low.c (linux_resume_one_lwp): Don't check
13163 'lwp->bp_reinsert != 0'.
13164
4039cf45
JB
131652013-01-07 Joel Brobecker <brobecker@adacore.com>
13166 Pedro Alves <palves@redhat.com>
13167
13168 * lynx-low.c (ptrace_request_to_str): Define a temporary
13169 macro and use it to simplify this function's implementation.
13170
9044dee2
JB
131712013-01-07 Joel Brobecker <brobecker@adacore.com>
13172
13173 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
13174 sets errno.
13175
e6352c8f
JB
131762013-01-07 Joel Brobecker <brobecker@adacore.com>
13177
13178 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
13179
50681a27
JB
131802013-01-07 Joel Brobecker <brobecker@adacore.com>
13181
13182 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
13183
3f6e77ef
JB
131842013-01-07 Joel Brobecker <brobecker@adacore.com>
13185
13186 * lynx-low.c (lynx_resume): Use the resume_info parameter
13187 to determine the ptid for the lynx_ptrace call, unless
13188 it is equal to minus_one_ptid, in which case we use the
13189 ptid of the current_inferior.
13190 (lynx_wait_1): After having received a thread create/exit
13191 event, resume the inferior's execution using the signaling
13192 thread's ptid, rather than the old ptid.
13193
7fda33ae
JB
131942013-01-07 Joel Brobecker <brobecker@adacore.com>
13195
13196 * lynx-low.c (lynx_resume): Delete variable ret.
13197
b9786c74
JB
131982013-01-01 Joel Brobecker <brobecker@adacore.com>
13199
13200 * gdbreplay.c (gdbreplay_version): Update copyright year.
13201 * server.c (gdbserver_version): Likewise.
13202
8b93d60f
JB
132032012-12-17 Joel Brobecker <brobecker@adacore.com>
13204
13205 * lynx-low.c (lynx_wait_1): Add debug trace before adding
13206 new thread.
13207
037335a7
JB
132082012-12-17 Joel Brobecker <brobecker@adacore.com>
13209
13210 * lynx-low.c (ptrace_request_to_str): Add handling for
13211 PTRACE_GETTRACESIG.
13212
52d4cbd8
JB
132132012-12-17 Joel Brobecker <brobecker@adacore.com>
13214
13215 * lynx-low.c (lynx_attach): Delete variable new_process.
13216
ab8f6ca9
JB
132172012-12-17 Joel Brobecker <brobecker@adacore.com>
13218
13219 * lynx-low.c (lynx_create_inferior): Delete variable
13220 new_process.
13221
78cbc024
JB
132222012-12-17 Joel Brobecker <brobecker@adacore.com>
13223
13224 * lynx-low.c (ptrace_request_to_str): Do not handle
13225 PTRACE_GETTHREADLIST if this macro does not exist.
13226
14a00470
YQ
132272012-12-15 Yao Qi <yao@codesourcery.com>
13228
13229 * Makefile.in (OBS): Add notif.o.
13230 * notif.c, notif.h: New.
13231 * server.c: Include "notif.h".
13232 (struct vstop_notif) <next>: Remove.
13233 <base>: New field.
13234 (queue_stop_reply): Update.
13235 (push_event, send_next_stop_reply): Remove.
13236 (discard_queued_stop_replies): Update.
13237 (notif_stop): New variable.
13238 (handle_v_stopped): Remove.
13239 (handle_v_requests): Don't call handle_v_stopped. Call
13240 handle_ack_notif instead.
13241 (queue_stop_reply_callback): Call notif_event_enque instead
13242 of queue_stop_reply.
13243 (handle_status): Don't call send_next_stop_reply, call
13244 notif_write_event instead.
13245 (kill_inferior_callback): Likewise.
13246 (detach_or_kill_inferior_callback): Likewise.
13247 (main): Call initialize_notif.
13248 (process_serial_event): Call QUEUE_is_empty.
13249 (handle_target_event): Call notif_push instead of push event.
13250 * server.h (push_event): Remove declaration.
13251
61c125b9
TT
132522012-12-10 Tom Tromey <tromey@redhat.com>
13253
13254 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
13255 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
13256 macros.
13257 (.c.o): Rewrite.
13258 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
13259 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
13260 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
13261 (amd64-linux-ipa.o, ax.o): Rewrite.
13262 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
13263 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
13264 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
13265 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
13266 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
13267 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
13268 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
13269 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
13270 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
13271 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
13272 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
13273 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
13274 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
13275 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
13276 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
13277 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
13278 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
13279 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
13280 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
13281 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
13282 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
13283 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
13284 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
13285 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
13286 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
13287 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
13288 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
13289 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
13290 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
13291 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
13292 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
13293 (reg-tilegx.o): Remove.
13294 (all_object_files): New macro.
13295 Include .deps files.
13296 * aclocal.m4, configure: Rebuild.
13297 * acinclude.m4: Include depstand.m4, lead-dot.m4.
13298 * configure.ac: Invoke ZW_CREATE_DEPDIR,
13299 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
13300
e90e9ad9
TT
133012012-12-05 Tom Tromey <tromey@redhat.com>
13302
13303 PR gdb/14917:
13304 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
13305
02d403bf 133062012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
13307
13308 * configure.ac: Check for linux/perf_event.h.
13309 * config.in: Regenerated.
13310 * configure: Regenerated.
13311
0270a750
PA
133122012-11-26 Maxime Villard <rustyBSD@gmx.fr>
13313
13314 * hostio.c (handle_readlink): Decrease buffer size
13315 parameter passed to readlink by one byte.
13316
8c29b58e
YQ
133172012-11-26 Yao Qi <yao@codesourcery.com>
13318
13319 * configure.ac (build_warnings): Append '-Wempty-body'.
13320 * configure: Regenerated.
13321 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
13322 body.
13323
8bdce1ff
PM
133242012-11-15 Pierre Muller <muller@sourceware.org>
13325
13326 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
13327 * config.in: Regenerate.
13328 * configure: Regenerate.
13329 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
13330 Use "gdb_wait.h" header instead of <sys/wait.h> header.
13331 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
13332 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
13333 header.
13334 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
13335 instead of <sys/wait.h> header.
13336 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
13337
02d403bf 133382012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
13339
13340 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
13341 (various make rules): Remove -DGDBSERVER
13342
fbd5db48
YQ
133432012-11-09 Yao Qi <yao@codesourcery.com>
13344
13345 * spu-low.c (current_ptid): Move it to ..
13346 * gdbthread.h: ... here. New.
13347 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
13348 * server.c (myresume, process_serial_event): Likewise.
13349 * thread-db.c (thread_db_find_new_threads): Likewise.
13350 * tracepoint.c (run_inferior_command): Likewise.
13351
b3dc46ff
AB
133522012-10-01 Andrew Burgess <aburgess@broadcom.com>
13353
13354 * server.c (handle_search_memory_1): Include access length in
13355 warning message.
13356
07c04788
HPN
133572012-09-05 Michael Brandt <michael.brandt@axis.com>
13358
13359 * linux-crisv32-low.c: Fix compile errors.
13360
918d227b
YQ
133612012-09-04 Yao Qi <yao@codesourcery.com>
13362
13363 * tracepoint.c (cmd_qtsv): Adjust debug message.
13364 Don't check CUR_TPOINT.
13365
18c1b81a
YQ
133662012-08-28 Yao Qi <yao@codesourcery.com>
13367
13368 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
13369 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
13370 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
13371 Remove declarations of xmalloc, xreallloc, xstrdup and
13372 freeargv.
13373 * Makefile.in (libiberty_h): New.
13374 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
13375 (linux-bfin-low.o): Append dependency 'libiberty.h'.
13376
dc82f37b
YQ
133772012-08-23 Yao Qi <yao@codesourcery.com>
13378
13379 * server.h: Remove declaration of 'xsnprintf'.
13380
406b1477
KS
133812012-08-22 Keith Seitz <keiths@redhat.com>
13382
13383 * server.h: Include build-gnulib-gbserver/config.h.
13384 * gdbreplay.c: Likewise.
13385
e6712ff1
DE
133862012-08-08 Doug Evans <dje@google.com>
13387
13388 * Makefile.in (SFILES): Add gdb_vecs.c.
13389 (OBS): Add gdb_vecs.o.
13390 (gdb_vecs_h, host_defs_h): New variables.
13391 (thread-db.o): Add $(gdb_vecs_h) dependency.
13392 (gdb_vecs.o): New rule.
13393 * thread-db.c: #include "gdb_vecs.h".
13394 (thread_db_load_search): Use a vector to iterate over path elements.
13395 Handle text appearing after "$pdir".
13396
13397 * configure.ac: Add check for strstr.
13398 * config.in: Regenerate.
13399 * configure: Regenerate.
13400
7c3270ae
UW
134012012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
13402
13403 * hostio.c (handle_pread): If pread fails, fall back to attempting
13404 lseek/read.
13405 (handle_pwrite): Likewise for pwrite.
13406
b62e2b27
UW
134072012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
13408
13409 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
13410 between unsupported TYPE and unimplementable ADDR/LEN combination.
13411 (arm_insert_point): Act on new return value.
13412
78a99e91
PA
134132012-07-31 Pedro Alves <palves@redhat.com>
13414
13415 * server.c (process_point_options): Only skip tokens if we find
13416 one that is unrecognized. Don't treat 'X' specially while
13417 skipping unrecognized tokens.
13418
fcf303ab
UW
134192012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
13420
13421 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
13422 to 4-byte-align HW breakpoint addresses for Thumb.
13423
7255706c
YQ
134242012-07-27 Yao Qi <yao@codesourcery.com>
13425
13426 PR remote/14161.
13427
13428 * server.h: Declare gdb_agent_about_to_close.
13429 * target.c (kill_inferior): Include "agent.h".
13430 New. Send command 'kill'.
13431 * target.h (kill_inferior): Removed macro.
13432 * tracepoint.c (gdb_agent_about_to_close): New.
13433 (gdb_agent_helper_thread): Handle command 'close'.
13434 Wait endlessly until the inferior stops.
13435 Install gdb_agent_remove_socket to atexit hook.
13436 (agent_socket_name): New static variable.
13437 (gdb_agent_socket_init): Replace local variable 'name' with
13438 'agent_socket_name'.
13439 (gdb_agent_remove_socket): New.
13440
5a3f286f
YQ
134412012-07-27 Yao Qi <yao@codesourcery.com>
13442
13443 * server.c (process_point_options): Stop at 'X' when parsing.
13444
961bd387
ME
134452012-07-19 Michael Eager <eager@eagercon.com>
13446
a261b8f5 13447 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
13448 to hw_execute.
13449 * linux-x86-low.c (x86_insert_point, x86_remove_point):
13450 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
13451 hardware breakpoint.
13452
aa7c7447
JK
134532012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13454
13455 * gdbserver/linux-low.c (initialize_low): Call
13456 linux_ptrace_init_warnings.
13457
7f216e7c
DE
134582012-07-02 Doug Evans <dje@google.com>
13459
13460 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
13461 pointer to int.
13462
d3ce09f5
SS
134632012-07-02 Stan Shebs <stan@codesourcery.com>
13464
13465 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
13466 (ax.o): Add it to build rule.
13467 (ax-ipa.o): Ditto.
13468 (OBS): Add format.o.
13469 (IPA_OBS): Add format.o.
13470 * server.c (handle_query): Claim support for breakpoint commands.
13471 (process_point_options): Add command case.
13472 (process_serial_event): Leave running if there are printfs in
13473 effect.
13474 * mem-break.h (any_persistent_commands): Declare.
13475 (add_breakpoint_commands): Declare.
13476 (gdb_no_commands_at_breakpoint): Declare.
13477 (run_breakpoint_commands): Declare.
13478 * mem-break.c (struct point_command_list): New struct.
13479 (struct breakpoint): New field command_list.
13480 (any_persistent_commands): New function.
13481 (add_commands_to_breakpoint): New function.
13482 (add_breakpoint_commands): New function.
13483 (gdb_no_commands_at_breakpoint): New function.
13484 (run_breakpoint_commands): New function.
13485 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
13486 locally.
13487 * ax.c: Include format.h.
13488 (ax_printf): New function.
13489 (gdb_eval_agent_expr): Add printf opcode.
13490
2f8f6aed
YQ
134912012-06-13 Yao Qi <yao@codesourcery.com>
13492
13493 * server.c (start_inferior): Remove duplicated writes to fields
13494 'last_resume_kind' and 'last_status' of 'current_inferior'.
13495
0c9070b3
YQ
134962012-06-12 Yao Qi <yao@codesourcery.com>
13497 Pedro Alves <palves@redhat.com>
13498
13499 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
13500 comment.
13501 * server.c (handle_v_cont): Extend comment.
13502
c52daf70
YQ
135032012-06-11 Yao Qi <yao@codesourcery.com>
13504
13505 * linux-low.c (linux_attach): Add 'static'.
13506
d38bbb0a
YQ
135072012-06-06 Yao Qi <yao@codesourcery.com>
13508
13509 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
13510
89dc0afd
JK
135112012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
13512
13513 Fix gcc -flto compilation warning.
13514 * server.c (main): Make variable multi_mode and attach volatile.
13515
75f62ce7
TJB
135162012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13517
13518 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
13519 if the platform doesn't know about it.
13520
65f479b6
PA
135212012-05-30 Jeff Kenton <jkenton@tilera.com>
13522
13523 * Makefile.in (SFILES): Add linux-tile-low.c.
13524 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
13525 * configure.srv: Handle tilegx-*-linux*.
13526 * linux-tile-low.c: New file.
13527
0c5bf5a9
JK
135282012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13529
13530 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
13531
a493e3e2
PA
135322012-05-24 Pedro Alves <palves@redhat.com>
13533
13534 PR gdb/7205
13535
43aaf8b6 13536 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 13537
2ea28649
PA
135382012-05-24 Pedro Alves <palves@redhat.com>
13539
13540 PR gdb/7205
13541
13542 Replace target_signal with gdb_signal throughout.
13543
8d409d16
MR
135442012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
13545
13546 * linux-low.c (linux_store_registers): Avoid the copying sequence
13547 when no data has been retrieved by ptrace.
13548
23512c01
MGD
135492012-05-22 Will Deacon <will.deacon@arm.com>
13550
13551 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
13552 Include asm/ptrace.h.
13553 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
13554 already defined.
13555
4934b29e
MR
135562012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
13557
13558 * linux-low.c (linux_store_registers): Don't re-retrieve data
13559 with ptrace that has already been obtained from /proc. Always
13560 copy any data retrieved with ptrace to the buffer supplied.
13561
bde24c0a
PA
135622012-05-11 Yao Qi <yao@codesourcery.com>
13563 Pedro Alves <palves@redhat.com>
13564
13565 * linux-low.c (enum stopping_threads_kind): New.
13566 (stopping_threads): Change type to `enum stopping_threads_kind'.
13567 (handle_extended_wait): If stopping and suspending threads, leave
13568 the new_lwp suspended too.
13569 (linux_wait_for_event): Adjust.
13570 (stop_all_lwps): Set `stopping_threads' to
13571 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
13572 whether we're suspending threads or just stopping them. Assert no
13573 recursion happens.
13574
623b6bdf
YQ
135752012-04-29 Yao Qi <yao@codesourcery.com>
13576
13577 * server.h: Move some code to ...
13578 * gdbthread.h: ... here. New.
13579 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
13580 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
13581 (nto-low.o, win32-low.o): Likewise.
13582 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
13583 * regcache.c, remote-utils.c, server.c: Likewise.
13584 * target.c, tracepoint.c, win32-low.c: Likewise.
13585
f15f9948
TJB
135862012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13587
13588 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
13589 (PTRACE_ARG4_TYPE): Likewise.
13590 (PTRACE_XFER_TYPE): Likewise.
13591 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
13592 ptrace to PTRACE_ARG3_TYPE.
13593 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
13594 (PTRACE_ARG4_TYPE): Likewise.
13595 (PTRACE_XFER_TYPE): Likewise.
13596 (linux_detach_one_lwp): Cast fourth argument of
13597 ptrace to long then PTRACE_ARG4_TYPE.
13598 (regsets_fetch_inferior_registers): Cast third argument of
13599 ptrace to long then PTRACE_ARG3_TYPE.
13600 (regsets_store_inferior_registers): Likewise.
13601
38ea300a
PA
136022012-04-20 Pedro Alves <palves@redhat.com>
13603
13604 * configure: Regenerate.
13605
c971b7fa
PA
136062012-04-19 Pedro Alves <palves@redhat.com>
13607
43aaf8b6 13608 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 13609 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
13610 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
13611 (all, install-only, uninstall, clean-info, all-lib, clean): No
13612 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
13613 (maintainer-clean realclean distclean): Use subdir_do.
13614 (subdir_do): New.
13615 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 13616 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
13617 * acinclude.m4: Include acx_configure_dir.m4.
13618 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
13619 calls. Call AC_PROG_RANLIB. Configure gnulib using
13620 ACX_CONFIGURE_DIR.
13621 (GNULIB): New.
13622 (GNULIB_STDINT_H): Adjust.
13623 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
13624 * gdbreplay.c: Include build-gnulib/config.h.
13625 * server.h: Likewise.
13626 * aclocal.m4: Regenerate.
13627 * config.in: Regenerate.
13628 * configure: Regenerate.
c971b7fa 13629
809277f8
PA
136302012-04-19 Pedro Alves <palves@redhat.com>
13631
13632 * Makefile.in (LIBGNU, INCGNU): Adjust.
13633 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
13634 (all, install-only, uninstall, clean-info, all-lib, clean)
13635 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
13636 * configure.ac: Adjust AC_OUTPUT output.
13637 * aclocal.m4: Regenerate.
13638 * configure: Regenerate.
13639
fd9bb8b8
PA
136402012-04-19 Pedro Alves <palves@redhat.com>
13641
13642 * Makefile.in (generated_files): New.
13643 (server_h): Remove the explicit dependency on config.h, and depend
13644 on $generated_files.
13645
1c298c66
PA
136462012-04-19 Pedro Alves <palves@redhat.com>
13647
13648 * Makefile.in (INCGNU): Add -Ignulib.
13649
57c4b50b
PA
136502012-04-19 Pedro Alves <palves@redhat.com>
13651
13652 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
13653 (INCGNU): ... this, and spell out -I here.
13654 (GNULIB_LIB): Rename to ...
13655 (LIBGNU): ... this.
13656 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
13657
1030e047
PA
136582012-04-19 Pedro Alves <palves@redhat.com>
13659
13660 * config.in: Regenerate.
13661
447d4319
PA
136622012-04-19 Pedro Alves <palves@redhat.com>
13663
13664 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
13665 * server.h (memmem): Remove declaration.
13666 * config.in: Regenerate.
13667 * configure: Regenerate.
13668
aad9eab9
YQ
136692012-04-19 Yao Qi <yao@codesourcery.com>
13670
13671 * Makefile.in (SFILES): Add common/vec.c.
13672 (OBS): Add vec.o.
13673 (vec.o): New rule.
13674
3e10640f
YQ
136752012-04-19 Yao Qi <yao@codesourcery.com>
13676
13677 * remote-utils.c (prepare_resume_reply): Replace with macro
13678 target_core_of_thread.
13679 * server.c (handle_qxfer_threads_proper): Likewise.
13680 * target.h (traget_core_of_thread): New macro.
13681
71622373
PA
136822012-04-18 Pedro Alves <palves@redhat.com>
13683
13684 * aclocal.m4: Regenerate.
13685 * configure: Regenerate.
13686
80d26939
YQ
136872012-04-16 Yao Qi <yao@codesourcery.com>
13688
13689 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
13690 duplicated on address.
13691
42476b70
YQ
136922012-04-16 Yao Qi <yao@codesourcery.com>
13693
13694 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
13695 (struct tracepoint_action_ops) <send>: New field.
13696 (m_tracepoint_action_send, r_tracepoint_action_send): New.
13697 (agent_expr_send, x_tracepoint_action_send): New.
13698 (l_tracepoint_action_send): New.
13699 (cmd_qtdp): Download and install tracepoint
13700 according to `use_agent'.
13701 (run_inferior_command): Add one more parameter `len'.
13702 Update callers.
13703 (tracepoint_send_agent): New.
13704 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
13705
7bc83639
YQ
137062012-04-16 Yao Qi <yao@codesourcery.com>
13707
13708 * tracepoint.c (download_tracepoints): Moved to ...
13709 (cmd_qtstart): ... here.
13710
5f18041e
YQ
137112012-04-14 Yao Qi <yao@codesourcery.com>
13712
13713 * tracepoint.c: Include inttypes.h.
13714 (struct collect_memory_action): Use sized types.
13715 (struct tracepoint): Likewise.
13716 (cmd_qtdp, stop_tracing): Update print specifiers.
13717 (cmd_qtp, response_tracepoint): Likewise.
13718 (collect_data_at_tracepoint): Likewise.
13719 (collect_data_at_step): Likewise.
13720
55a8c076
YQ
137212012-04-14 Yao Qi <yao@codesourcery.com>
13722
13723 Import gnulib module inttypes.
13724 * aclocal.m4, config.in, configure: Regenerated.
13725
dc750257
YQ
137262012-04-14 Yao Qi <yao@codesourcery.com>
13727
13728 * Makefile.in (maintainer-clean, realclean, distclean): Remove
13729 Makefile and config.status at last.
13730
0ab5faf9
YQ
137312012-04-13 Yao Qi <yao@codesourcery.com>
13732
13733 * tracepoint.c: Include stdint.h unconditionally.
13734
18f5fd81
TJB
137352012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13736
13737 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
13738 on BFD_HAVE_SYS_PROCFS_TYPE.
13739 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
13740 * configure: Regenerate.
13741 * config.in: Likewise.
13742
4d47af5c
L
137432012-04-13 H.J. Lu <hongjiu.lu@intel.com>
13744
13745 * Makefile.in (clean): Also remove x32.c x32-linux.c
13746 x32-avx.c x32-avx-linux.c.
13747 (x32.o): New target.
13748 (x32.c): Likewise.
13749 (x32-linux.o): Likewise.
13750 (x32-linux.c): Likewise.
13751 (x32-avx.o): Likewise.
13752 (x32-avx.c): Likewise.
13753 (x32-avx-linux.o): Likewise.
13754 (x32-avx-linux.c): Likewise.
13755
13756 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
13757 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
13758 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
13759 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
13760 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
13761 i386/x32-avx-linux.xml.
13762
13763 * linux-x86-low.c (init_registers_x32_linux): New prototype.
13764 (init_registers_x32_avx_linux): Likwise.
13765 (x86_linux_update_xmltarget): Call init_registers_x32_linux
13766 or init_registers_x32_avx_linux if linux_is_elf64 is false.
13767
ecedbe58
PA
137682012-04-13 Pedro Alves <palves@redhat.com>
13769
13770 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
13771 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
13772 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
13773 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
13774 the sub-make.
13775
c92b5177
L
137762012-04-12 H.J. Lu <hongjiu.lu@intel.com>
13777
13778 * linux-x86-low.c (compat_x32_clock_t): New.
13779 (compat_x32_siginfo_t): Likewise.
13780 (compat_x32_siginfo_from_siginfo): Likewise.
13781 (siginfo_from_compat_x32_siginfo): Likewise.
13782 (linux_is_elf64): Likewise.
13783 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
13784 and siginfo_from_compat_x32_siginfo for x32.
13785 (x86_arch_setup): Set linux_is_elf64.
13786
214d508e
L
137872012-04-12 H.J. Lu <hongjiu.lu@intel.com>
13788
13789 PR gdb/13969
13790 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
13791 e_machine field.
13792 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
13793 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
13794 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
13795 compatible with process.
13796
c9a1864a
YQ
137972012-04-12 Yao Qi <yao@codesourcery.com>
13798
13799 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
13800 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
13801 (install-only, install-info, clean): Handle sub dir gnulib.
13802 (all-lib, am--refresh): New targets.
13803 (memmem.o): Remove target.
13804 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
13805 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
13806 (AC_REPLACE_FUNCS): Remove memmem.
13807 Invoke gl_INIT and AM_INIT_AUTOMAKE.
13808 (AC_OUTPUT): Generate Makefile in gnulib/.
13809 * aclocal.m4, config.in, configure: Regenerated.
13810
367ba2c2
MR
138112012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
13812
13813 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
13814
9d236627
PA
138152012-04-05 Pedro Alves <palves@redhat.com>
13816
13817 -Werror=strict-aliasing
13818
13819 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
13820 pointer.
13821
111217b3
PA
138222012-04-04 Pedro Alves <palves@redhat.com>
13823
13824 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13825 (sparc_store_gregset_from_stack, sparc_store_gregset)
13826 (sparc_breakpoint_at): Fix formatting.
13827
8365dcf5
TJB
138282012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13829
13830 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
13831 are available.
13832 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
13833 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
13834 * config.in: Regenerate.
13835 * configure: Likewise.
13836
689cc2ae
PA
138372012-03-29 Pedro Alves <palves@redhat.com>
13838
13839 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
13840 Correct ptrace arguments.
13841
c14dfd32
PA
138422012-03-28 Pedro Alves <palves@redhat.com>
13843
13844 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
13845 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
13846 (IA64_FR1_REGNUM): New defines.
13847 (ia64_fetch_register): New.
13848 (the_low_target): Install it.
13849 * linux-low.h (struct linux_target_ops) <fetch_register>: New
13850 field.
13851 * linux-low.c (linux_fetch_registers): Try the
13852 the_low_target.fetch_register hook first.
13853
13854 * linux-arm-low.c (the_low_target): Adjust.
13855 * linux-bfin-low.c (the_low_target): Adjust.
13856 * linux-cris-low.c (the_low_target): Adjust.
13857 * linux-crisv32-low.c (the_low_target): Adjust.
13858 * linux-m32r-low.c (the_low_target): Adjust.
13859 * linux-m68k-low.c (the_low_target): Adjust.
13860 * linux-mips-low.c (the_low_target): Adjust.
13861 * linux-ppc-low.c (the_low_target): Adjust.
13862 * linux-s390-low.c (the_low_target): Adjust.
13863 * linux-sh-low.c (the_low_target): Adjust.
13864 * linux-sparc-low.c (the_low_target): Adjust.
13865 * linux-tic6x-low.c (the_low_target): Adjust.
13866 * linux-x86-low.c (the_low_target): Adjust.
13867 * linux-xtensa-low.c (the_low_target): Adjust.
13868
63c88e13
PA
138692012-03-26 Pedro Alves <palves@redhat.com>
13870
13871 * server.c (handle_qxfer_libraries): Don't bail early if
13872 the_target->qxfer_libraries_svr4 is not NULL.
13873
fb723180
PA
138742012-03-26 Pedro Alves <palves@redhat.com>
13875
13876 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
13877
0afae3cf
PA
138782012-03-23 Pedro Alves <palves@redhat.com>
13879
13880 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
13881 "library-list-svr4" element's start tag when the the DSO list is
13882 empty.
13883
485f1ee4
PA
138842012-03-23 Pedro Alves <palves@redhat.com>
13885
13886 * linux-low.c (read_one_ptr): Read the inferior's pointer through
13887 a variable whose type size is the same as the inferior's pointer
13888 size.
13889
a5362b9a
TS
138902012-03-21 Thomas Schwinge <thomas@codesourcery.com>
13891
13892 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
13893 struct siginfo.
13894 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
13895 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
13896 * linux-low.h: Include <signal.h>.
13897 (struct siginfo): Remove forward declaration.
13898 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
13899 struct siginfo.
13900
d226c142
MF
139012012-03-21 Mike Frysinger <vapier@gentoo.org>
13902
13903 * .gitignore: Ignore more files.
13904
122f36ef
PA
139052012-03-19 Pedro Alves <palves@redhat.com>
13906 Jan Kratochvil <jan.kratochvil@redhat.com>
13907
13908 * server.c (cont_thread, general_thread): Add describing comments.
13909 (start_inferior): Clear `cont_thread'.
13910 (handle_v_cont): Don't set `cont_thread' if resuming all threads
13911 of a process.
13912
fc3e5175
YQ
139132012-03-15 Yao Qi <yao@codesourcery.com>
13914
13915 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
13916 handling to ...
13917 (cmd_qtdp): ... here.
13918
8d0d92cd
YQ
139192012-03-15 Yao Qi <yao@codesourcery.com>
13920
13921 * tracepoint.c (struct tracepoint_action_ops): New.
13922 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
13923 (m_tracepoint_action_download): New.
13924 (r_tracepoint_action_download): New.
13925 (x_tracepoint_action_download): New.
13926 (l_tracepoint_action_download): New.
13927 (add_tracepoint_action): Install `action->ops' according type.
13928 (download_tracepoint_1): Move code `download' function pointer
13929 of various tracepoint_action_ops.
13930
87b0bb13
JK
139312012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13932
13933 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
13934 linux_ptrace_attach_warnings.
13935
5f572dec
JK
139362012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13937
13938 * Makefile.in (linux-ptrace.o): New.
13939 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
13940 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
13941 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
13942 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
13943 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
13944 of these targets.
13945 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
13946
f4647387
YQ
139472012-03-08 Yao Qi <yao@codesourcery.com>
13948 Pedro Alves <palves@redhat.com>
13949
13950 Fix PR server/13392.
13951 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
13952 offset of JMP insn.
13953 * tracepoint.c (remove_tracepoint): New.
13954 (cmd_qtdp): Call remove_tracepoint when failed to install.
13955
9b224c5e
PA
139562012-03-07 Pedro Alves <palves@redhat.com>
13957
13958 * linux-low.c (get_detach_signal): New.
13959 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
13960 Pass on pending signals to PTRACE_DETACH. Check the result of the
13961 ptrace call.
13962 * server.c (program_signals, program_signals_p): New.
13963 (handle_general_set): Handle QProgramSignals.
13964 * server.h (program_signals, program_signals_p): Declare.
13965
e237a7e2
JK
139662012-03-05 Pedro Alves <palves@redhat.com>
13967 Jan Kratochvil <jan.kratochvil@redhat.com>
13968
13969 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
13970 New comment why.
13971
5808517f
YQ
139722012-03-03 Yao Qi <yao@codesourcery.com>
13973
13974 * tracepoint.c (tracepoint_look_up_symbols): Update call to
13975 agent_look_up_symbols.
13976
58b4daa5
YQ
139772012-03-03 Yao Qi <yao@codesourcery.com>
13978
13979 * Makefile.in (linux-low.o): Keep dependence on agent.h.
13980 (linux-x86-low.o): Likewise.
13981 * server.h: Remove in_process_agent_loaded.
13982 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
13983 common/agent.c.
13984 Update callers.
13985
8ffcbaaf
YQ
139862012-03-03 Yao Qi <yao@codesourcery.com>
13987
13988 * tracepoint.c (gdb_agent_capability): New global.
13989 (in_process_agent_loaded_ust): Renamed to
13990 `in_process_agent_supports_ust'.
13991 Update callers.
13992 (in_process_agent_supports_ust): Call agent_capability_check.
13993 (clear_installed_tracepoints): Assert that agent supports
13994 agent.
13995
d1feda86
YQ
139962012-03-03 Yao Qi <yao@codesourcery.com>
13997
13998 * linux-low.c (linux_supports_agent): New.
13999 (linux_target_ops): Initialize field `supports_agent' with
14000 linux_supports_agent.
14001 * target.h (struct target_ops) <supports_agent>: New.
14002 (target_supports_agent): New macro.
14003 * server.c (handle_general_set): Handle packet 'QAgent'.
14004 (handle_query): Send `QAgent+'.
14005 * Makefile.in (server.o): Depends on agent.h.
14006
2fa291ac
YQ
140072012-03-03 Yao Qi <yao@codesourcery.com>
14008
14009 * Makefile.in (OBS): Add agent.o.
14010 Add new rule for agent.o.
14011 Track dependence of tracepoint.c on agent.h.
14012 * tracepoint.c (run_inferior_command_1):
14013 (run_inferior_command): Call agent_run_command.
14014 (gdb_ust_connect_sync_socket): Deleted. Move it to
14015 common/agent.c.
14016 (resume_thread, stop_thread): Likewise.
14017 (gdb_ust_socket_init): Renamed to ...
14018 (gdb_agent_socket_init): ... New.
14019 (gdb_ust_thread): Renamed to ...
14020 (gdb_agent_helper_thread): ... New.
14021 (gdb_ust_init): Move some code to ...
14022 (gdb_agent_init): ... here. New.
14023 [HAVE_UST]: Call gdb_ust_init.
14024 (initialize_tracepoint_ftlib): Call gdb_agent_init.
14025 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
14026 * config.in, configure: Regenerated.
14027
05044653
PA
140282012-03-02 Pedro Alves <palves@redhat.com>
14029
14030 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
14031 * linux-low.c (struct simple_pid_list): New.
14032 (stopped_pids): New a struct simple_pid_list pointer.
14033 (add_to_pid_list, pull_pid_from_list): New.
14034 (handle_extended_wait): Don't assume the first signal new children
14035 report is SIGSTOP. Adjust call to pull_pid_from_list.
14036 (linux_wait_for_lwp): Adjust.
14037
8d00225b
YQ
140382012-03-02 Yao Qi <yao@codesourcery.com>
14039
14040 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
14041 debug log.
14042
19560ba5
YQ
140432012-03-02 Yao Qi <yao@codesourcery.com>
14044
14045 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
14046 `stop_pc' and `tpoint'. Update caller.
14047
1faeff08
MR
140482012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
14049
14050 * linux-low.h (linux_target_ops): Add regset_bitmap member.
14051 * linux-low.c (use_linux_regsets): New macro.
14052 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
14053 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
14054 (linux_register_in_regsets): New function.
14055 (usr_fetch_inferior_registers): Skip registers covered by
14056 regsets.
14057 (usr_store_inferior_registers): Likewise.
14058 (usr_fetch_inferior_registers): New macro.
14059 (usr_store_inferior_registers): Likewise.
14060 (linux_fetch_registers): Handle mixed regset/non-regset targets.
14061 (linux_store_registers): Likewise.
14062 * linux-mips-low.c (init_registers_mips_dsp_linux): New
14063 prototype.
14064 (init_registers_mips64_dsp_linux): Likewise.
14065 (init_registers_mips_linux): New macro.
14066 (init_registers_mips_dsp_linux): Likewise.
14067 (mips_dsp_num_regs): Likewise.
14068 (DSP_BASE, DSP_CONTROL): New fallback macros.
14069 (mips_base_regs): New macro.
14070 (mips_regmap): Use it. Fix the size.
14071 (mips_dsp_regmap): New variable.
14072 (mips_dsp_regset_bitmap): Likewise.
14073 (mips_arch_setup): New function.
14074 (mips_cannot_fetch_register): Use the_low_target.regmap rather
14075 than mips_regmap.
14076 (mips_cannot_store_register): Likewise.
14077 (the_low_target): Update .arch_setup, .num_regs and .regmap
14078 initializers. Add .regset_bitmap initializer.
14079 * linux-arm-low.c (the_low_target): Add .regset_bitmap
14080 initializer.
14081 * linux-bfin-low.c (the_low_target): Likewise.
14082 * linux-cris-low.c (the_low_target): Likewise.
14083 * linux-crisv32-low.c (the_low_target): Likewise.
14084 * linux-ia64-low.c (the_low_target): Likewise.
14085 * linux-m32r-low.c (the_low_target): Likewise.
14086 * linux-m68k-low.c (the_low_target): Likewise.
14087 * linux-ppc-low.c (the_low_target): Likewise.
14088 * linux-s390-low.c (the_low_target): Likewise.
14089 * linux-sh-low.c (the_low_target): Likewise.
14090 * linux-sparc-low.c (the_low_target): Likewise.
14091 * linux-tic6x-low.c (the_low_target): Likewise.
14092 * linux-x86-low.c (the_low_target): Likewise.
14093 * linux-xtensa-low.c (the_low_target): Likewise.
14094 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
14095 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
14096 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
14097 srv_xmlfiles.
14098 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
14099 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
14100
c03e6ccc
YQ
141012012-02-29 Yao Qi <yao@codesourcery.com>
14102 Pedro Alves <palves@redhat.com>
14103
14104 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
14105 `step_over_finished' is true.
14106
644cebc9
PA
141072012-02-27 Pedro Alves <palves@redhat.com>
14108
14109 * linux-low.c (pid_is_stopped): Delete, moved to common/.
14110 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
14111
c14d7ab2
PA
141122012-02-27 Pedro Alves <palves@redhat.com>
14113
14114 PR server/9684
14115 * linux-low.c (pid_is_stopped): New.
14116 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
14117
412c89dd
LM
141182012-02-25 Luis Machado <lgustavo@codesourcery.com>
14119
14120 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
14121 of conditions.
14122
b745defe
MR
141232012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
14124
14125 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
14126
9f3a5c85
LM
141272012-02-24 Luis Machado <lgustavo@codesourcery>
14128
14129 * server.c (handle_query): Advertise support for target-side
14130 breakpoint condition evaluation.
14131 (process_point_options): New function.
14132 (process_serial_event): When inserting a breakpoint, check for
14133 a target-side condition that should be evaluated.
14134
14135 * mem-break.c: Include regcache.h and ax.h.
14136 (point_cond_list_t): New data structure.
14137 (breakpoint) <cond_list>: New field.
14138 (find_gdb_breakpoint_at): Make non-static.
14139 (delete_gdb_breakpoint_at): Clear any target-side
14140 conditions.
14141 (clear_gdb_breakpoint_conditions): New function.
14142 (add_condition_to_breakpoint): Likewise.
14143 (add_breakpoint_condition): Likewise.
14144 (gdb_condition_true_at_breakpoint): Likewise.
14145 (gdb_breakpoint_here): Return result directly instead
14146 of going through a local variable.
14147
14148 * mem-break.h (find_gdb_breakpoint_at): New prototype.
14149 (clear_gdb_breakpoint_conditions): Likewise.
14150 (add_breakpoint_condition): Likewise.
14151 (gdb_condition_true_at_breakpoint): Likewise.
14152
14153 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
14154 (need_step_over_p): Take target-side breakpoint condition into
14155 consideration.
14156
5e1dc496
LM
141572012-02-24 Luis Machado <lgustavo@codesourcery>
14158
14159 * server.h: Include tracepoint.h.
14160 (agent_mem_read, agent_get_trace_state_variable_value,
14161 agent_set_trace_state_variable_value,
14162 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
14163 get_set_tsv_func_addr): New prototypes.
14164
14165 * ax.h: New include file.
14166 * ax.c: New source file.
14167
14168 * tracepoint.c: Include ax.h.
14169 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
14170 agent_expr, eval_result_type): Move to ax.h.
14171 (parse_agent_expr): Rename to ...
14172 (gdb_parse_agent_expr): ... this, make it non-static and move
14173 to ax.h.
14174 (unparse_agent_expr) Rename to ...
14175 (gdb_unparse_agent_expr): ... this, make it non-static and move
14176 to ax.h.
14177 (eval_agent_expr): Rename to ...
14178 (eval_tracepoint_agent_expr): ... this.
14179 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
14180 forward declarations.
14181 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
14182 (agent_get_trace_state_variable_value): New function.
14183 (agent_set_trace_state_variable_value): New function.
14184 (cmd_qtdp): Call gdb_parse_agent_expr (...).
14185 (response_tracepoint): Call gdb_unparse_agent_expr (...).
14186 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
14187 (condition_true_at_tracepoint): Likewise.
14188 (parse_agent_expr): Rename to ...
14189 (gdb_parse_agent_expr): ... this and move to ax.c.
14190 (unparse_agent_expr): Rename to ...
14191 (gdb_unparse_agent_expr): ... this and move to ax.c.
14192 (gdb_agent_op_name): Move to ax.c.
14193 (eval_agent_expr): Rename to ...
14194 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
14195 and move to ax.c.
14196 (eval_tracepoint_agent_expr): New function.
14197 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 14198 non-static.
5e1dc496
LM
14199 (current_insn_ptr, emit_error, struct bytecode_address): Move to
14200 ax.c.
14201 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
14202 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
14203 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
14204 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
14205 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
14206 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
14207 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
14208 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
14209 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
14210 (compile_bytecodes): Remove forward declaration.
14211 (is_goto_target): Move to ax.c.
14212 (compile_bytecodes): Move to ax.c and call
14213 agent_get_trace_state_variable_value (...) and
14214 agent_set_trace_state_variable_value (...).
14215
14216 * Makefile.in: Update ax.c and IPA dependencies.
14217
277e4e52
PA
142182012-02-24 Pedro Alves <palves@redhat.com>
14219
14220 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
14221 (cmd_bigqtbuffer_circular): ... this. Only handle
14222 'QTBuffer:circular:'.
14223 (handle_tracepoint_general_set): Adjust.
14224
bf4c19f7
YQ
142252012-02-16 Yao Qi <yao@codesourcery.com>
14226
14227 * inferiors.c: Move code to ...
14228 * dll.c: .... here. New.
14229 * server.h: Declare clear_dlls.
14230 * Makefile.in (SFILES): Add dll.c.
14231 (OBS): Add dll.o
14232 (dll.o): New rule.
14233
d73f2619
YQ
142342012-02-11 Yao Qi <yao@codesourcery.com>
14235
14236 * server.c: (handle_monitor_command): Add a new parameter
14237 `own_buf'.
14238 (handle_query): Update caller.
14239
f8255c2a
JB
142402012-02-09 Joel Brobecker <brobecker@adacore.com>
14241
14242 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
14243 * configure, config.in: Regenerate.
14244 * hostio.c: Provide an alternate implementation if HAVE_READLINK
14245 is not defined.
14246
da84f473
PA
142472012-02-02 Pedro Alves <palves@redhat.com>
14248
14249 Try SIGKILL first, then PTRACE_KILL.
14250 * linux-low.c (linux_kill_one_lwp): New.
14251 (linux_kill_one_lwp): Rename to ...
14252 (kill_one_lwp_callback): ... this. Use the new
14253 linux_kill_one_lwp.
14254
e886a173
PA
142552012-02-02 Pedro Alves <palves@redhat.com>
14256
14257 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
14258 inferior.
14259
be07f1a2
PA
142602012-01-27 Pedro Alves <palves@redhat.com>
14261
14262 * linux-low.c (linux_child_pid_to_exec_file): Delete.
14263 (elf_64_file_p): Make static.
14264 (linux_pid_exe_is_elf_64_file): New.
14265 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
14266 Delete declarations.
14267 (linux_pid_exe_is_elf_64_file): Declare.
14268 * linux-x86-low.c (x86_arch_setup): Use
14269 linux_pid_exe_is_elf_64_file.
14270
d8301ad1
JK
142712012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
14272
14273 * linux-low.c (linux_wait_for_event_1): Rename to ...
14274 (linux_wait_for_event): ... here and merge it with former
14275 linux_wait_for_event - new variable wait_ptid, use it.
14276 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
14277
01b17894
PA
142782012-01-23 Pedro Alves <palves@redhat.com>
14279
14280 * server.c (main): Avoid yet another case of infinite loop while
14281 detaching/killing after a longjmp.
14282
e825046f
JK
142832012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14284
14285 Code cleanup.
14286 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
14287
b9e7b9c3
UW
142882012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
14289
14290 * hostio.c (handle_readlink): New function.
14291 (handle_vFile): Call it to handle "vFile:readlink" packets.
14292
901f9912
UW
142932012-01-20 Pedro Alves <palves@redhat.com>
14294 Ulrich Weigand <ulrich.weigand@linaro.org>
14295
14296 * server.c (handle_v_requests): Only support vAttach and vRun to
14297 start multiple processes when in extended protocol mode.
14298
fc1ab1a0
PA
142992012-01-17 Pedro Alves <palves@redhat.com>
14300
14301 * tracepoint.c (initialize_tracepoint): Use mmap instead of
14302 memalign plus mprotect to allocate the scratch buffer.
14303
7d5d4e98
PA
143042012-01-13 Pedro Alves <palves@redhat.com>
14305
14306 * server.c (attach_inferior): Clear `cont_thread'.
14307
f128d5e9
PA
143082012-01-13 Pedro Alves <palves@redhat.com>
14309
14310 * server.c (main): Avoid infinite loop while detaching/killing
14311 after a longjmp.
14312
06db92f0
DE
143132012-01-09 Doug Evans <dje@google.com>
14314
14315 * server.c (start_inferior): Set last_ptid in --wrapper case.
14316
32d92999
YQ
143172012-01-06 Yao Qi <yao@codesourcery.com>
14318
14319 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
14320 defined.
14321 [IN_PROCESS_AGENT] (debug_agent): New global variable.
14322
5e0a92a9
YQ
143232012-01-04 Yao Qi <yao@codesourcery.com>
14324
14325 * tracepoint.c (cmd_qtdp): Print debug message
14326 for static tracepoint.
14327
ae639e8c
YQ
143282012-01-04 Yao Qi <yao@codesourcery.com>
14329
14330 * tracepoint.c (trace_vdebug): Differentiate debug message
14331 between gdbserver and IPA.
14332
f72429c5
YQ
143332012-01-03 Yao Qi <yao@codesourcery.com>
14334
14335 * tracepoint.c (tracepoint_was_hit): Don't collect for
14336 static tracepoint.
14337
12c3e59c
JB
143382012-01-02 Joel Brobecker <brobecker@adacore.com>
14339
14340 * terminal.h: Reformat copyright header.
14341
67827812
JB
143422012-01-02 Joel Brobecker <brobecker@adacore.com>
14343
14344 * server.c (gdbserver_version): Update copyright year.
14345 * gdbreplay.c (gdbreplay_version): Likewise.
14346
3e52c33d
JK
143472011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
14348
14349 * linux-low.c (linux_create_inferior): Put empty if clause for write.
14350
14351 Revert:
14352 2011-12-18 Hui Zhu <teawater@gmail.com>
14353 * linux-low.c (linux_create_inferior): Save return value to ret.
14354
66f1260e
HZ
143552011-12-18 Hui Zhu <teawater@gmail.com>
14356
14357 * linux-low.c (linux_create_inferior): Save return value to ret.
14358
e77616d7
DE
143592011-12-16 Doug Evans <dje@google.com>
14360
e7b06c57
DE
14361 * linux-low.c (linux_create_inferior): If stdio connection,
14362 redirect stdin from /dev/null, stdout to stderr.
14363 * remote-utils.c (remote_is_stdio): New static global.
14364 (remote_connection_is_stdio): New function.
14365 (remote_prepare): Handle stdio connection.
14366 (remote_open): Ditto.
14367 (remote_close): Don't close stdin for stdio connections.
14368 (read_prim,write_prim): New functions. Replace all calls to
14369 read/write to these.
14370 * server.c (main): Watch for "-" argument. Move call to
14371 remote_prepare before start_inferior.
14372 * server.h (STDIO_CONNECTION_NAME): New macro.
14373 (remote_connection_is_stdio): Declare.
14374
e77616d7
DE
14375 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
14376 in debugging output.
14377
82067193
YQ
143782011-12-15 Yao Qi <yao@codesourcery.com>
14379
14380 * tracepoint.c: Include sys/syscall.h.
14381 (gdb_ust_thread): Remove preprocessor conditional.
14382
82bfbe7e
PA
143832011-12-14 Pedro Alves <pedro@codesourcery.com>
14384
14385 * linux-low.c (linux_detach_one_lwp): Call
14386 the_low_target.prepare_to_resume before detaching.
14387
712c6575
YQ
143882011-12-14 Yao Qi <yao@codesourcery.com>
14389
14390 * tracepoint.c (gdb_ust_thread): Don't ignore return value
14391 of write.
14392
d54d1edf
YQ
143932011-12-14 Yao Qi <yao@codesourcery.com>
14394
14395 * i386-low.c (i386_low_stopped_data_address): Initialize local
14396 variable `control'.
14397
6210a125
PA
143982011-12-13 Pedro Alves <pedro@codesourcery.com>
14399
14400 PR remote/13492
14401
14402 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
14403 DR_CONTROL unless necessary. Extend comments.
14404 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
14405 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
14406
2ece8244
YQ
144072011-12-13 Yao Qi <yao@codesourcery.com>
14408
14409 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
14410 macros.
14411 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
14412
784867a5
JK
144132011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
14414
14415 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
14416 Print new debug message for such case.
14417
6bf36717
JK
144182011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
14419
14420 Fix overlapping memcpy.
14421 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
14422 the read_inferior_memory transfer.
14423 (delete_fast_tracepoint_jump): New variable buf. Use it for the
14424 write_inferior_memory transfer.
14425 (set_fast_tracepoint_jump): New variable buf. Use it for the
14426 read_inferior_memory and write_inferior_memory transfers.
14427 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
14428 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
14429 Use it for the write_inferior_memory transfer.
14430 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
14431 buffers.
14432
50275556
MR
144332011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
14434
14435 * linux-low.c (fetch_register, store_register): Make code
14436 consistent, fix formatting.
14437
7325beb4
MR
144382011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
14439
14440 * linux-low.c (usr_store_inferior_registers): Factor out code
14441 to handle individual registers into...
14442 (store_register): ... this new function.
14443
c642a434
UW
144442011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
14445
14446 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
14447 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
14448 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
14449 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
14450 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
14451 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
14452 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
14453 (srv_xmlfiles): Add new XML files.
14454
14455 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
14456 and <sys/uio.h>.
14457 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
14458 (init_registers_s390_linux32v1): Add prototype.
14459 (init_registers_s390_linux32v2): Likewise.
14460 (init_registers_s390_linux64v1): Likewise.
14461 (init_registers_s390_linux64v2): Likewise.
14462 (init_registers_s390x_linux64v1): Likewise.
14463 (init_registers_s390x_linux64v2): Likewise.
14464 (s390_num_regs): Increment to 52.
14465 (s390_regmap): Add orig_r2 register.
14466 (s390_num_regs_3264): Increment to 68.
14467 (s390_regmap_3264): Add orig_r2 register.
14468 (s390_collect_ptrace_register): Handle orig_r2 register.
14469 (s390_supply_ptrace_register): Likewise.
14470 (s390_fill_last_break): New function.
14471 (s390_store_last_break): Likewise.
14472 (s390_fill_system_call): New function.
14473 (s390_store_system_call): Likewise.
14474 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
14475 register sets.
14476 (s390_check_regset): New function.
14477 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
14478 NT_S390_SYSTEM_CALL regsets and use appropriate description.
14479 Update target_regsets for available register sets.
14480
2268b414
JK
144812011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
14482 Jan Kratochvil <jan.kratochvil@redhat.com>
14483
14484 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
14485 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
14486 New.
14487 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
14488 * linux-low.h (struct process_info_private): New member r_debug.
14489 * server.c (handle_qxfer_libraries): Call
14490 the_target->qxfer_libraries_svr4.
14491 (handle_qxfer_libraries_svr4): New function.
14492 (qxfer_packets): New entry "libraries-svr4".
14493 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
14494 * target.h (struct target_ops): New member qxfer_libraries_svr4.
14495 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
14496 PACKET_qXfer_libraries_svr4.
14497
d6db1fab
UW
144982011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
14499
14500 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
14501 PSW address/mask between 8-byte and 16-byte formats.
14502 (s390_supply_ptrace_register): Likewise.
14503 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
14504 basic addressing mode bit.
14505
242f5f1c
SS
145062011-11-24 Stan Shebs <stan@codesourcery.com>
14507
14508 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
14509
f196051f
SS
145102011-11-17 Stan Shebs <stan@codesourcery.com>
14511
14512 * tracepoint.c (struct tracepoint): New field traceframe_usage.
14513 (tracing_start_time): New global.
14514 (tracing_stop_time): New global.
14515 (tracing_user_name): New global.
14516 (tracing_notes): New global.
14517 (tracing_stop_note): New global.
14518 (cmd_qtstart): Set traceframe_usage, start_time.
14519 (stop_tracing): Set stop_time.
14520 (cmd_qtstatus): Report additional status.
14521 (cmd_qtp): New function.
14522 (handle_tracepoint_query): Call it.
14523 (cmd_qtnotes): New function.
14524 (handle_tracepoint_general_set): Call it.
14525 (get_timestamp): Rename from tsv_get_timestamp.
14526
405f8e94
SS
145272011-11-14 Stan Shebs <stan@codesourcery.com>
14528 Kwok Cheung Yeung <kcy@codesourcery.com>
14529
14530 * linux-x86-low.c (small_jump_insn): New.
14531 (i386_install_fast_tracepoint_jump_pad): Add arguments for
14532 trampoline and error message, build a trampoline and issue a small
14533 jump instruction to it.
14534 (x86_install_fast_tracepoint_jump_pad): Add arguments for
14535 trampoline and error message.
14536 (x86_get_min_fast_tracepoint_insn_len): New.
14537 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
14538 * linux-low.h (struct linux_target_ops): Add arguments to
14539 install_fast_tracepoint_jump_pad operation, add new operation.
14540 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
14541 arguments.
14542 (linux_get_min_fast_tracepoint_insn_len): New function.
14543 (linux_target_op): Add new operation.
14544 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
14545 (gdb_trampoline_buffer_end): Ditto.
14546 (gdb_trampoline_buffer_error): Ditto.
14547 (struct ipa_sym_addresses): Add fields for new IPA variables.
14548 (symbol_list): Add entries for new IPA variables.
14549 (struct tracepoint): Add fields to hold the address range of the
14550 trampoline used by the tracepoint.
14551 (trampoline_buffer_head): New static variable.
14552 (trampoline_buffer_tail): Ditto.
14553 (claim_trampoline_space): New function.
14554 (have_fast_tracepoint_trampoline_buffer): New function.
14555 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
14556 structure.
14557 (install_fast_tracepoint): Ditto, also add error buffer argument.
14558 (cmd_qtminftpilen): New function.
14559 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
14560 (fast_tracepoint_from_trampoline_address): New function.
14561 (fast_tracepoint_collecting): Handle trampoline as part of jump
14562 pad space.
14563 (set_trampoline_buffer_space): New function.
14564 (initialize_tracepoint): Initialize new IPA variables.
14565 * target.h (struct target_ops): Add arguments to
14566 install_fast_tracepoint_jump_pad operation, add new
14567 get_min_fast_tracepoint_insn_len operation.
14568 (target_get_min_fast_tracepoint_insn_len): New.
14569 (install_fast_tracepoint_jump_pad): Add arguments.
14570 * server.h (IPA_BUFSIZ): Define.
14571 * linux-i386-ipa.c: Include extra header files.
14572 (initialize_fast_tracepoint_trampoline_buffer): New function.
14573 (initialize_low_tracepoint): Call it.
14574 * server.h (set_trampoline_buffer_space): Declare.
14575 (claim_trampoline_space): Ditto.
14576 (have_fast_tracepoint_trampoline_buffer): Ditto.
14577
1e4d1764
YQ
145782011-11-14 Yao Qi <yao@codesourcery.com>
14579
14580 * server.c (handle_query): Handle InstallInTrace for qSupported.
14581 * tracepoint.c (add_tracepoint): Sort list.
14582 (install_tracepoint, download_tracepoint): New.
14583 (cmd_qtdp): Call them to install and download tracepoints.
14584 (sort_tracepoints): Removed.
14585 (cmd_qtstart): Update.
14586
5c73ff4e
YQ
145872011-11-14 Yao Qi <yao@codesourcery.com>
14588
14589 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
14590 * mem-break.h: Declare.
14591 * tracepoint.c (cmd_qtstart): Move some code to ...
14592 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
14593 New.
14594 (download_tracepoints): Move some code to ...
14595 (download_tracepoint_1): ... here. New.
14596
86a30030
YQ
145972011-11-08 Yao Qi <yao@codesourcery.com>
14598
14599 * remote-utils.c (relocate_instruction): A comment fix.
14600
8d26e50c
JB
146012011-11-07 Joel Brobecker <brobecker@adacore.com>
14602
14603 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
14604 (i386_dr_low_get_control, i386_dr_low_get_status): Use
14605 dr_status_mirror and dr_control_mirror from debug_reg_state.
14606 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
14607 (i386_initial_stuff): Remove use of deleted globals.
14608 (i386_get_thread_context, i386_set_thread_context,
14609 i386_thread_added): Use dr_status_mirror and dr_control_mirror
14610 from debug_reg_state.
14611
a59306a3
YQ
146122011-11-05 Yao Qi <yao@codesourcery.com>
14613
14614 * tracepoint.c (gdb_collect): Loop over tracepoints of same
14615 address as TPOINT's.
14616
3065dfb6
SS
146172011-11-02 Stan Shebs <stan@codesourcery.com>
14618
14619 * tracepoint.c (agent_mem_read_string): New function.
14620 (eval_agent_expr): Call it for tracenz.
14621 * server.c (handle_query): Report support for tracenz.
14622
fd0d8c7c
YQ
146232011-11-02 Yao Qi <yao@codesourcery.com>
14624
14625 * tracepoint.c (cmd_qtstart): Remove unused local variables.
14626
609086b1
YQ
146272011-11-02 Yao Qi <yao@codesourcery.com>
14628
14629 * target.h: Fix a typo in comment.
14630
b9fd1791
PA
146312011-10-31 Pedro Alves <pedro@codesourcery.com>
14632
14633 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
14634 clobber the breakpoints' shadows with fast tracepoint jumps.
14635 * mem-break.h (check_mem_write): Add `myaddr' parameter.
14636 * target.c (write_inferior_memory): Also pass MYADDR down to
14637 check_mem_write.
14638
03583c20
UW
146392011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
14640
14641 * configure.ac: Check support for personality routine.
14642 * configure: Regenerate.
14643 * config.in: Likewise.
14644 * linux-low.c: Include <sys/personality.h>.
14645 Define ADDR_NO_RANDOMIZE if necessary.
14646 (linux_create_inferior): Disable address space randomization when
14647 forking inferior, if requested.
14648 (linux_supports_disable_randomization): New function.
14649 (linux_target_ops): Install it.
14650 * server.h (disable_randomization): Declare.
14651 * server.c (disable_randomization): New global variable.
14652 (handle_general_set): Handle QDisableRandomization.
14653 (handle_query): Likewise for qSupported.
14654 (main): Support --disable-randomization and --no-disable-randomization
14655 command line arguments.
14656 * target.h (struct target_ops): Add supports_disable_randomization.
14657 (target_supports_disable_randomization): New macro.
14658
723b724b
MF
146592011-09-29 Mike Frysinger <vapier@gentoo.org>
14660
14661 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
14662 ifdef check.
14663 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
14664 [!PT_GETDSBT] (target_loadmap): New definition.
14665 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
14666 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
14667 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
14668 and PT_GETDSBT to LINUX_LOADMAP.
14669 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
14670 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
14671
55329a5c 146722011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
14673
14674 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
14675 (arm_linux_hwbp_cap): New static variable.
14676 (arm_linux_get_hwbp_cap): Replace by ...
14677 (arm_linux_init_hwbp_cap): ... this new function.
14678 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
14679 (arm_linux_get_hw_watchpoint_count): Likewise.
14680 (arm_linux_get_hw_watchpoint_max_length): Likewise.
14681 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
14682 (arm_prepare_to_resume): Use perror_with_name instead of error.
14683
55329a5c 146842011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
14685
14686 * linux-arm-low.c: Include <signal.h>.
14687 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
14688 (struct arm_linux_hwbp_cap): New data type.
14689 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
14690 (struct arm_linux_hw_breakpoint): New data type.
14691 (MAX_BPTS, MAX_WPTS): Define.
14692 (struct arch_process_info, struct arch_lwp_info): New data types.
14693 (arm_linux_get_hwbp_cap): New function.
14694 (arm_linux_get_hw_breakpoint_count): Likewise.
14695 (arm_linux_get_hw_watchpoint_count): Likewise.
14696 (arm_linux_get_hw_watchpoint_max_length): Likewise.
14697 (arm_hwbp_control_initialize): Likewise.
14698 (arm_hwbp_control_is_enabled): Likewise.
14699 (arm_hwbp_control_is_initialized): Likewise.
14700 (arm_hwbp_control_disable): Likewise.
14701 (arm_linux_hw_breakpoint_equal): Likewise.
14702 (arm_linux_hw_point_initialize): Likewise.
14703 (struct update_registers_data): New data structure.
14704 (update_registers_callback: New function.
14705 (arm_insert_point): Likewise.
14706 (arm_remove_point): Likewise.
14707 (arm_stopped_by_watchpoint): Likewise.
14708 (arm_stopped_data_address): Likewise.
14709 (arm_new_process): Likewise.
14710 (arm_new_thread): Likewise.
14711 (arm_prepare_to_resume): Likewise.
14712 (the_low_target): Register arm_insert_point, arm_remove_point,
14713 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
14714 arm_new_thread, and arm_prepare_to_resume.
14715
6b9801d4
SS
147162011-09-15 Stan Shebs <stan@codesourcery.com>
14717
14718 * server.h (struct emit_ops): Add compare-goto fields.
14719 * tracepoint.c (gdb_agent_op_sizes): New table.
14720 (emit_eq_goto): New function.
14721 (emit_ne_goto): New function.
14722 (emit_lt_goto): New function.
14723 (emit_le_goto): New function.
14724 (emit_gt_goto): New function.
14725 (emit_ge_goto): New function.
14726 (is_goto_target): New function.
14727 (compile_bytecodes): Recognize special cases of compare-goto
14728 combinations and call specialized emitters for them.
14729 * linux-x86-low.c (amd64_emit_eq_goto): New function.
14730 (amd64_emit_ne_goto): New function.
14731 (amd64_emit_lt_goto): New function.
14732 (amd64_emit_le_goto): New function.
14733 (amd64_emit_gt_goto): New function.
14734 (amd64_emit_ge_goto): New function.
14735 (amd64_emit_ops): Add the new functions.
14736 (i386_emit_eq_goto): New function.
14737 (i386_emit_ne_goto): New function.
14738 (i386_emit_lt_goto): New function.
14739 (i386_emit_le_goto): New function.
14740 (i386_emit_gt_goto): New function.
14741 (i386_emit_ge_goto): New function.
14742 (i386_emit_ops): Add the new functions.
14743
bf15cbda
SS
147442011-09-08 Stan Shebs <stan@codesourcery.com>
14745
14746 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
14747 (i386_emit_epilogue): Restore %ebx.
14748
943ca1dd
JZ
147492011-08-31 Jie Zhang <jzhang918@gmail.com>
14750
14751 * server.c (step_thread): Remove definition.
14752 (process_serial_event): Don't handle Hs.
14753 * server.h (step_thread): Remove declaration.
14754 * target.c (set_desired_inferior): Remove use of step_thread.
14755
e3deef73
LM
147562011-08-24 Luis Machado <lgustavo@codesourcery.com>
14757
14758 * linux-low.c: Include linux-procfs.h.
14759 (linux_attach_lwp_1): Update comments.
14760 (linux_attach): Scan for existing threads when attaching to a
14761 process that is the tgid.
14762 * Makefile.in: Update dependencies.
14763
13da1c97
LM
147642011-08-24 Luis Machado <lgustavo@codesourcery.com>
14765
14766 * configure.srv: Add linux-procfs.o dependencies.
14767
881127c9
YQ
147682011-08-14 Yao Qi <yao@codesourcery.com>
14769
14770 * target.h (struct target_ops): Fix indent.
14771 * win32-low.c (win32_target_ops): Fix comment.
14772
58dbd541
YQ
147732011-08-14 Andrew Jenner <andrew@codesourcery.com>
14774 Yao Qi <yao@codesourcery.com>
14775
14776 * Makefile.in (clean): Remove tic6x-*.c files.
14777 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
14778 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
14779 (tic6x-c64xp-linux.c): Likewise.
14780 * configure.srv: Add support for tic6x-*-uclinux.
14781 * linux-tic6x-low.c: New.
14782 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
14783
78d85199
YQ
147842011-08-14 Andrew Stubbs <ams@codesourcery.com>
14785 Yao Qi <yao@codesourcery.com>
14786
14787 * target.h (struct target_ops): Add read_loadmap.
14788 * linux-low.c (struct target_loadseg): New type.
14789 (struct target_loadmap): New type.
14790 (linux_read_loadmap): New function.
14791 (linux_target_ops): Add linux_read_loadmap.
14792 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
14793 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
14794 to NULL.
78d85199 14795
a959a88d
EZ
147962011-08-05 Eli Zaretskii <eliz@gnu.org>
14797
14798 * win32-low.c: Include <stdint.h>.
14799
1ced966e
PA
148002011-07-22 Pedro Alves <pedro@codesourcery.com>
14801
14802 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
14803 to the inferior here.
14804 (i386_remove_aligned_watchpoint): Ditto.
14805 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
14806 fit part of the watchpoint in the debug registers.
14807 (i386_update_inferior_debug_regs): New.
14808 (i386_low_insert_watchpoint): Work on a local mirror of the debug
14809 registers, and only update the inferior on success.
14810 (i386_low_remove_watchpoint): Ditto.
14811
d26e3629
KY
148122011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
14813
14814 * linux-low.c (compare_ints, unique, list_threads, show_process,
14815 linux_core_of_thread): Delete.
14816 (linux_target_ops): Change linux_core_of_thread to
14817 linux_common_core_of_thread.
14818 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
14819 * utils.c (malloc_failure): Change type of argument.
14820 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
14821 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
14822 common/linux-osdata.c, common/ptid.c and common/buffer.c.
14823 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
14824 (IPA_OBJS): Add common-utils-ipa.o.
14825 (ptid_h, linux_osdata_h): New macros.
14826 (server_h): Add common/common-utils.h, common/xml-utils.h,
14827 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
14828 common/ptid.h.
14829 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
14830 ptid.o, buffer.o): New rules.
14831 (linux-low.o): Add common/linux-osdata.h as a dependency.
14832 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
14833 * configure.ac: Add AC_HEADER_DIRENT check.
14834 * config.in: Regenerate.
14835 * configure: Regenerate.
14836 * remote-utils.c (xml_escape_text): Delete.
14837 (buffer_grow, buffer_free, buffer_init, buffer_finish,
14838 buffer_xml_printf): Move to common/buffer.c.
14839 * server.c (main): Remove call to initialize_inferiors.
14840 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
14841 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
14842 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
14843 internal_error, gdb_assert, gdb_assert_fail): Delete.
14844 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
14845 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
14846 common/buffer.h.
14847 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
14848 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
14849 initialize_inferiors): Delete.
14850
2275a1a7
PA
148512011-07-20 Pedro Alves <pedro@codesourcery.com>
14852
14853 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
14854 symbol error.
14855
0a5b1e09
PA
148562011-05-31 Pedro Alves <pedro@codesourcery.com>
14857
14858 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
14859 assertion.
14860 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
14861
6938fd34
YQ
148622011-05-26 Yao Qi <yao@codesourcery.com>
14863
14864 * Makefile.in (thread-db.o): Track dependence to
14865 common/gdb_thread_db.h.
14866 * thread-db.c: include gdb_thread_db.h from right place.
14867
b481f9e0
TT
148682011-05-16 Adrian Cornish <gnu@bluedreamer.com>
14869
14870 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
14871 __FILE__ and __LINE__ to internal_error.
14872
98a5dd13
DE
148732011-05-13 Doug Evans <dje@google.com>
14874
14875 * thread-db.c (try_thread_db_load_from_sdir): New function.
14876 (try_thread_db_load_from_dir): New function.
14877 (thread_db_load_search): Handle $sdir, ignore $pdir.
14878 Remove trying of system directories if search of
14879 libthread-db-search-path fails, that is now done via $sdir.
14880
d248b706
KY
148812011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
14882
14883 * server.c (handle_query): Add EnableDisableTracepoints to the list
14884 of supported features.
43aaf8b6 14885 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 14886 tracepoints.
43aaf8b6
PA
14887 (cmd_qtenable_disable): New.
14888 (cmd_qtstart): Install tracepoints even if disabled.
14889 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
14890 receiving a QTEnable or QTDisable packet.
14891 (gdb_collect): Skip data collection if fast tracepoint is disabled.
14892 (ust_marker_to_static_tracepoint): Do not ignore disabled static
14893 tracepoints.
14894 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 14895
84e578fb
DE
148962011-05-10 Doug Evans <dje@google.com>
14897
14898 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
14899
71f55dd8
DE
149002011-05-04 Doug Evans <dje@google.com>
14901
14902 * linux-low.c (linux_join): Skip process lookup.
14903 * spu-low.c (spu_join): Ditto.
14904 * server.c (join_inferiors_callback): Delete.
14905 (process_serial_event): For 'D' packet (detach) call join_inferior
14906 directly.
14907
4d393d60
JM
149082011-05-04 Joseph Myers <joseph@codesourcery.com>
14909
14910 * README: Don't mention xscale*-*-linux*.
14911 * configure.srv (xscale*-*-linux*): Don't handle target.
14912
b00ad6ff
NF
149132011-04-27 Nathan Froyd <froydnj@codesourcery.com>
14914
14915 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
14916 casting pointers.
14917 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
14918 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
14919 (i386_emit_void_call_2): Likewise.
14920
af96c192
YQ
149212011-04-26 Yao Qi <yao@codesourcery.com>
14922
43aaf8b6
PA
14923 * linux-low.c: Move common macros to linux-ptrace.h.
14924 Include linux-ptrace.h.
af96c192
YQ
14925 * Makefile.in (linux_ptrace_h): New.
14926 (linux-low.o): Depends on linux-ptrace.h.
14927
03f2bd59
JK
149282011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
14929
14930 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
14931 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
14932 (remote_prepare): New function with most of the TCP code from ...
14933 (remote_open): ... here. Detect PORT here unconditionally. Move also
14934 setting transport_is_reliable.
14935 * server.c (run_once): New variable.
14936 (gdbserver_usage): Document it.
14937 (main): Set run_once for `--once'. Call remote_prepare. Exit after
14938 the first run if RUN_ONCE.
14939 * server.h (run_once, remote_prepare): New declarations.
14940
7a9dd1b2
TT
149412011-04-19 Tom Tromey <tromey@redhat.com>
14942
14943 * win32-low.c (handle_load_dll): Remove duplicate "the".
14944
81239425
PM
149452011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
14946
14947 Remove support for old Cygwin 1.5 versions.
14948 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
14949 function to avoid warning.
14950 (win32_add_one_solib): Use cygwin_conv_path function to avoid
14951 warning.
14952
9e0627f1
PM
149532011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
14954
14955 * gdbserver/server.h (Macro _): Define it if not available.
14956
588eebee
MS
149572011-03-14 Michael Snyder <msnyder@vmware.com>
14958
348af9f7 14959 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 14960
43f70d4c
JB
149612011-03-10 Joel Brobecker <brobecker@adacore.com>
14962
14963 * Makefile.in (maintainer-clean realclean distclean): Remove
14964 "make ... subdir_do" command.
14965
348af9f7
MS
149662011-03-10 Michael Snyder <msnyder@vmware.com>
14967
14968 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
14969
14970 * server.c (handle_v_run): Free alloced buffer on early return.
14971
e637a4f5
YQ
149722011-03-09 Yao Qi <yao@codesourcery.com>
14973
14974 Revert:
14975 2011-03-04 Yao Qi <yao@codesourcery.com>
14976
14977 * Makefile.in: Remove GNU make feature --directory.
14978
14979 2011-03-05 Yao Qi <yao@codesourcery.com>
14980
14981 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14982 (subdir_do): New make target. Copied from gdb/Makefile.
14983 (maintainer-clean, realclean, distclean, clean): Call corresponding
14984 make targets in common/Makefile.
14985
14986 2011-02-11 Yao Qi <yao@codesourcery.com>
14987
14988 * configure.ac: Call AC_PROG_RANLIB.
14989 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14990 * configure: Regenerate.
14991
e6edda56
JK
149922011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14993
14994 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
14995
e5141119
JB
149962011-03-06 Yao Qi <yao@codesourcery.com>
14997
14998 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
14999
64794aa4
JB
150002011-03-05 Yao Qi <yao@codesourcery.com>
15001
15002 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
15003 (subdir_do): New make target. Copied from gdb/Makefile.
15004 (maintainer-clean, realclean, distclean, clean): Call corresponding
15005 make targets in common/Makefile.
15006
7a762829
YQ
150072011-03-04 Yao Qi <yao@codesourcery.com>
15008
15009 * Makefile.in: Remove GNU make feature --directory.
15010
348af9f7
MS
150112011-03-04 Michael Snyder <msnyder@vmware.com>
15012
15013 * server.c (queue_stop_reply): Call xmalloc not malloc.
15014
150152011-03-02 Michael Snyder <msnyder@vmware.com>
15016
15017 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
15018
9f72fee2
MS
150192011-02-28 Michael Snyder <msnyder@vmware.com>
15020
588eebee
MS
15021 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
15022 (cmd_qtframe): Ditto.
15023 (cmd_qtbuffer): Ditto.
15024 (cmd_bigqtbuffer): Ditto.
15025
9f72fee2
MS
15026 * utils.c (decimal2str): Initialize 'width' to nine, then
15027 don't mess with it.
15028
8040bd49
UW
150292011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15030
15031 * hostio.c (require_data): Free *data, not data.
15032
7e52cbd0
JK
150332011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15034
15035 * hostio.c (require_data): Use free, not xfree.
15036
9130f83e
MS
150372011-02-27 Michael Snyder <msnyder@vmware.com>
15038
4b812f4e
MS
15039 * server.c (handle_query): Discard unused value.
15040
9130f83e
MS
15041 * hostio.c (require_data): Free malloc memory before returning
15042 error.
15043
69d37113
MS
150442011-02-26 Michael Snyder <msnyder@vmware.com>
15045
15046 * linux-low.c (list_threads): Call closedir for dirent.
15047
35f5825a
MS
150482011-02-27 Michael Snyder <msnyder@vmware.com>
15049
2a589cef
MS
15050 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
15051 a case statement falls through.
15052
0adea5f7
MS
15053 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
15054
35f5825a
MS
15055 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
15056 in comparison.
15057
238f1c74
MS
150582011-02-26 Michael Snyder <msnyder@vmware.com>
15059
15060 * utils.c (decimal2str): Eliminate dead code and dead param.
15061 (pulongest): Drop dead param from call to decimal2str.
15062 (plongest): Ditto.
15063
633ff500
JB
150642011-02-24 Joel Brobecker <brobecker@adacore.com>
15065
15066 Revert the following patch (not approved yet):
15067 2011-02-21 Hui Zhu <teawater@gmail.com>
15068 * tracepoint.c (tp_printf): New function.
15069 (eval_agent_expr): Handle gdb_agent_op_printf.
15070
f9c6ff72
HZ
150712011-02-21 Hui Zhu <teawater@gmail.com>
15072
15073 * tracepoint.c (tp_printf): New function.
15074 (eval_agent_expr): Handle gdb_agent_op_printf.
15075
94d5e490
TT
150762011-02-18 Tom Tromey <tromey@redhat.com>
15077
15078 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
15079 (tracepoint.o): Likewise.
15080 * tracepoint.c (enum gdb_agent_op): Use ax.def.
15081 (gdb_agent_op_names): Likewise.
15082
c7f96d2b
TT
150832011-02-18 Tom Tromey <tromey@redhat.com>
15084
15085 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
15086 gdb_agent_op_rot>: New constants.
15087 (gdb_agent_op_names): Add pick and roll.
15088 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
15089 cases.
15090
0feedb2c
JK
150912011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
15092
15093 * aclocal.m4: Regenerated with aclocal-1.11.1.
15094
b3b9301e
PA
150952011-02-14 Pedro Alves <pedro@codesourcery.com>
15096
15097 * server.c (handle_qxfer_traceframe_info): New.
15098 (qxfer_packets): Register "traceframe-info".
15099 (handle_query): Report support for qXfer:traceframe-info:read+.
15100 * tracepoint.c (match_blocktype): New.
15101 (traceframe_find_block_type): Rename to ...
15102 (traceframe_walk_blocks): ... this. Add callback filter argument,
15103 and use it.
15104 (traceframe_find_block_type): New, reimplemented on top of
15105 traceframe_walk_blocks.
15106 (build_traceframe_info_xml): New.
15107 (traceframe_read_info): New.
15108 * server.h (traceframe_read_info): Declare.
15109
4f3e6fb7
YQ
151102011-02-11 Yao Qi <yao@codesourcery.com>
15111
15112 * configure.ac: Call AC_PROG_RANLIB.
15113 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
15114 * configure: Regenerate.
15115
764880b7
PA
151162011-02-07 Pedro Alves <pedro@codesourcery.com>
15117
15118 * server.c (gdb_read_memory): Change return semantics to allow
15119 partial transfers.
15120 (handle_search_memory_1): Adjust.
15121 (process_serial_event) <'m' packet>: Handle partial transfers.
15122 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
15123
1c79eb8a
PA
151242011-01-28 Pedro Alves <pedro@codesourcery.com>
15125
15126 * regcache.c (init_register_cache): Initialize
15127 regcache->register_status.
15128 (free_register_cache): Release regcache->register_status.
15129 (regcache_cpy): Copy register_status.
15130 (registers_to_string): Print 'x's for unavailable registers.
15131 (supply_register): Mark the register's status valid or
15132 unavailable, depending on whether a buffer was passed in or not.
15133 (supply_register_zeroed): New.
15134 (supply_regblock): Mark the registers' status valid or
15135 unavailable, depending on whether a buffer was passed in or not.
15136 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
15137 (struct regcache): New `register_status' field.
15138 (supply_register_zeroed): Declare.
15139 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
15140 supply_register_zeroed, rather than passing a NULL buffer to
15141 supply_register.
15142 * tracepoint.c (fetch_traceframe_registers): Update comment.
15143
85724a0e
PA
151442011-01-28 Pedro Alves <pedro@codesourcery.com>
15145
15146 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
15147 buffer explicit.
15148
d08aafef
PA
151492011-01-25 Pedro Alves <pedro@codesourcery.com>
15150
15151 * server.h (decode_xfer_write): Change prototype.
15152 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
15153 and don't extract the annex here.
15154 * server.c (decode_xfer_read): Remove `annex' parameter,
15155 and don't extract the annex here.
15156 (decode_xfer): New.
15157 (struct qxfer): New.
15158 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
15159 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
15160 (handle_qxfer_statictrace): New functions, abstracted out from
15161 handle_query, and made to use the struct qxfer interface.
15162 (handle_threads_qxfer_proper): Rename to ...
15163 (handle_qxfer_threads_proper): ... this.
15164 (handle_threads_qxfer): Rename to ...
15165 (handle_qxfer_threads): ... this. Adjust.
15166 (qxfer_packets): New array.
15167 (handle_qxfer): New function.
15168 (handle_query): Use handle_qxfer.
15169
493e2a69
MS
151702011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
15171
15172 * gdbreplay.c: Shorten lines of >= 80 columns.
15173 * linux-low.c: Ditto.
15174 * linux-ppc-low.c: Ditto.
15175 * linux-s390-low.c: Ditto.
15176 * linux-sparc-low.c: Ditto.
15177 * linux-x86-low.c: Ditto.
15178 * linux-xtensa-low.c: Ditto.
15179 * mem-break.c: Ditto.
15180 * nto-low.c: Ditto.
15181 * regcache.h: Ditto.
15182 * remote-utils.c: Ditto.
15183 * server.c: Ditto.
15184 * server.h: Ditto.
15185 * thread-db.c: Ditto.
15186 * tracepoint.c: Ditto.
15187 * utils.c: Ditto.
15188 * win32-low.h: Ditto.
15189
44944448
JB
151902011-01-05 Joel Brobecker <brobecker@adacore.com>
15191
15192 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
15193 update.
15194
71ce852c
JB
151952011-01-01 Joel Brobecker <brobecker@adacore.com>
15196
15197 * server.c (gdbserver_version): Update copyright year in version
15198 output.
15199 * gdbreplay.c (gdbreplay_version): Ditto.
15200
eb826dc6
MF
152012010-12-29 Jie Zhang <jie.zhang@analog.com>
15202
15203 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
15204 * linux-bfin-low.c: New file.
15205 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
15206 PT_DATA_ADDR for BFIN targets.
15207 * Makefile.in (SFILES): Add linux-bfin-low.c.
15208 (clean): Remove reg-bfin.c.
15209 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
15210 * README: Mention supported Blackfin targets.
15211
39ab222a
MF
152122010-12-23 Mike Frysinger <vapier@gentoo.org>
15213
15214 * .gitignore: New file.
15215
a1f2ce7d
MF
152162010-11-16 Mike Frysinger <vapier@gentoo.org>
15217
15218 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
15219
f474844c
JZ
152202010-10-22 Jie Zhang <jie@codesourcery.com>
15221
15222 * Makefile.in: Add FLAGS_TO_PASS variable.
15223 (install): Remove dependency of install-only and recursively
15224 invoke make for install-only.
15225
f1048712
DE
152262010-10-04 Doug Evans <dje@google.com>
15227
15228 * Makefile.in (uninstall): Use $(DESTDIR).
15229
b53a1623
PA
152302010-09-24 Pedro Alves <pedro@codesourcery.com>
15231
e6ee044d
PA
15232 PR gdb/11842
15233
b53a1623
PA
15234 * linux-x86-low.c (compat_siginfo_from_siginfo)
15235 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
15236 si_code is < 0. Check for si_code == SI_TIMER before checking for
15237 si_code < 0.
15238
fa1bd1e4
JB
152392010-09-13 Joel Brobecker <brobecker@adacore.com>
15240
15241 * lynx-i386-low.c: New file.
15242 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
15243
47fac8f8
JB
152442010-09-13 Joel Brobecker <brobecker@adacore.com>
15245
15246 * lynx-low.c (ptrace_request_to_str): Remove handling for
15247 request values that have been removed in LynxOS 5.x.
15248
1adfc54d
JB
152492010-09-13 Joel Brobecker <brobecker@adacore.com>
15250
15251 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
15252 <ptrace.h>
15253
c2a66c29
NS
152542010-09-09 Nathan Sidwell <nathan@codesourcery.com>
15255
15256 * configure.ac: Add --enable-inprocess-agent option.
15257 * configure: Rebuilt.
15258
32fcada3
YQ
152592010-09-06 Yao Qi <yao@codesourcery.com>
15260
15261 * linux-low.c (linux_kill): Remove unused variable.
15262 (linux_stabilize_threads): Likewise.
15263 * server.c (start_inferior): Likewise.
15264 (queue_stop_reply_callback): Likewise.
15265 * tracepoint.c (do_action_at_tracepoint): Likewise.
15266
0cccb683
YQ
152672010-09-06 Yao Qi <yao@codesourcery.com>
15268
15269 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
15270 on return.
15271
423ec54c
JK
152722010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15273
15274 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
15275
12ac6819
PA
152762010-09-06 Pedro Alves <pedro@codesourcery.com>
15277
15278 * Makefile.in (install-only): Replace $IPA_DEPFILES with
15279 "$(IPA_DEPFILES)".
15280
8ed54b31
JB
152812010-09-01 Joel Brobecker <brobecker@adacore.com>
15282
15283 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
15284 gdbserver/lynx-ppc-low.c: New files.
15285 * Makefile.in (lynx_low_h): New variable.
15286 (lynx-low.o, lynx-ppc-low.o): New rules.
15287 * configure.ac: On LynxOS, link with -lnetinet.
15288 * configure.srv: Add handling of powerpc-*-lynxos* targets.
15289 * configure: regenerate.
15290
bb0116a4
JB
152912010-09-01 Joel Brobecker <brobecker@adacore.com>
15292
15293 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
15294 * configure.ac: Add check for vasprintf and vsnprintf.
15295 * configure, config.in: Regenerate.
15296 * server.h (vasprintf, vsnprintf): Add conditional declarations.
15297
a778ab81 152982010-09-01 Joel Brobecker <brobecker@adacore.com>
15299
15300 * gdbreplay.c: Move include of alloca.h up, next to include of
15301 malloc.h.
15302 * server.h: Add include of malloc.h.
15303 * mem-break.c: Remove include of malloc.h.
15304 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
15305
8b034a19 153062010-09-01 Joel Brobecker <brobecker@adacore.com>
15307
15308 * Makefile.in (memmem.o): Build with -Wno-error.
15309
153102010-09-01 Joel Brobecker <brobecker@adacore.com>
15311
15312 * utils.c (xsnprintf): Make non-static.
15313 * server.h: Add xsnprintf declaration.
15314 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
15315 replace calls to snprintf by calls to xsnprintf throughout.
15316
153172010-09-01 Joel Brobecker <brobecker@adacore.com>
15318
15319 * configure.ac: Add configure check for alloca.
15320 * configure, config.in: Regenerate.
15321 * server.h: Include alloca.h if it exists.
15322 * gdbreplay.c: Include alloca.h if it exists.
15323
1a981360
PA
153242010-08-28 Pedro Alves <pedro@codesourcery.com>
15325
15326 * linux-low.c (__SIGRTMIN): Define if not already defined.
15327 (linux_create_inferior): Check for __ANDROID__ rather than
15328 __SIGRTMIN.
15329 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
15330 are already deferred.
15331 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
15332 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
15333 stopped and already has a pending signal to report.
15334 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
15335 a pending signal to report or is moving out of a jump pad.
15336 (linux_init_signals): Check for __ANDROID__ rather than
15337 __SIGRTMIN.
15338
b4d51a55
PA
153392010-08-28 Pedro Alves <pedro@codesourcery.com>
15340
15341 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
15342 debug_threads check. Avoid a linear search when not doing debug
15343 output.
15344
ec48365d
PA
153452010-08-27 Pedro Alves <pedro@codesourcery.com>
15346
15347 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
15348 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
15349 (struct file_handler) <fd>: Change type to gdb_fildes_t.
15350 (process_event): Change local fd's type to gdb_fildes_t.
15351 (create_file_handler): Adjust prototype.
15352 (delete_file_handler): Adjust prototype.
15353 (handle_file_event): Adjust prototype. Use pfildes.
15354 (create_file_event): Adjsut prototype.
15355 * remote-utils.c (remote_desc, listen_desc): Change type to
15356 gdb_fildes_t.
15357 * server.h: New gdb_fildes_t typedef.
15358 [USE_WIN32API]: Include winsock2.h.
15359 (delete_file_handler, add_file_handler): Adjust prototypes.
15360 (pfildes): Declare.
15361 * utils.c (pfildes): New.
15362
854d88f0
PA
153632010-08-27 Pedro Alves <pedro@codesourcery.com>
15364
15365 * configure.ac (build_warnings): Add -Wno-char-subscripts.
15366 * configure: Regenerate.
15367
0146f85b
PA
153682010-08-27 Pedro Alves <pedro@codesourcery.com>
15369
15370 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
15371 (linux_done_accessing_memory): ... this.
15372 (linux_target_ops): Adjust.
15373 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
15374 * nto-low.c (nto_target_ops): Adjust comment.
15375 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
15376 * spu-low.c (spu_target_ops): Adjust comment.
15377 * target.h (target_ops): Rename unprepare_to_access_memory field
15378 to done_accessing_memory.
15379 (unprepare_to_access_memory): Rename to ...
15380 (done_accessing_memory): ... this.
15381
90d74c30
PA
153822010-08-26 Pedro Alves <pedro@codesourcery.com>
15383
15384 * linux-low.c (linux_prepare_to_access_memory): New.
15385 (linux_unprepare_to_access_memory): New.
15386 (linux_target_ops): Install them.
15387 * server.c (read_memory): Rename to ...
15388 (gdb_read_memory): ... this. Use
15389 prepare_to_access_memory/prepare_to_access_memory.
15390 (write_memory): Rename to ...
15391 (gdb_write_memory): ... this. Use
15392 prepare_to_access_memory/prepare_to_access_memory.
15393 (handle_search_memory_1): Adjust.
15394 (process_serial_event): Adjust.
15395 * target.h (struct target_ops): New fields
15396 prepare_to_access_memory and unprepare_to_access_memory.
15397 (prepare_to_access_memory, unprepare_to_access_memory): New.
15398 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
15399 prepare_to_access_memory/prepare_to_access_memory.
15400 * nto-low.c (nto_target_ops): Adjust.
15401 * spu-low.c (spu_target_ops): Adjust.
15402 * win32-low.c (win32_target_ops): Adjust.
15403
fd467969
PA
154042010-08-26 Pedro Alves <pedro@codesourcery.com>
15405
15406 * Makefile.in (WARN_CFLAGS): Get it from configure.
15407 (WERROR_CFLAGS): New.
15408 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
15409 * configure.ac: Introduce --enable-werror, which adds -Werror to
15410 the compiler command line. Enabled by default. Disable with
15411 --disable-werror. Add -Wdeclaration-after-statement
15412 Wpointer-arith and -Wformat-nonliteral to warning flags.
15413 * configure: Regenerate.
15414
331e2f5f
PA
154152010-08-26 Pedro Alves <pedro@codesourcery.com>
15416
15417 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
15418
e581f2b4
PA
154192010-08-26 Pedro Alves <pedro@codesourcery.com>
15420
15421 * gdbreplay.c (remote_error): New.
15422 (gdbchar): New.
15423 (expect): Use gdbchar. Check for error reading from GDB.
15424 Clarify sync error output.
15425 (play): Check for errors writing to GDB.
15426 * linux-low.c (sigchld_handler): Really ignore `write' errors.
15427 * remote-utils.c (getpkt): Check for errors writing to the remote
15428 descriptor.
15429
3c11dd79
PA
154302010-08-25 Pedro Alves <pedro@codesourcery.com>
15431
15432 * linux-low.c (linux_wait_1): Move non-debugging code out of
15433 `debug_threads' control.
15434
d20a8ad9
PA
154352010-08-25 Pedro Alves <pedro@codesourcery.com>
15436
15437 * linux-low.c (linux_wait_1): Don't set last_status here.
15438 * server.c (push_event, queue_stop_reply_callback): Assert we're
15439 not pushing a TARGET_WAITKIND_IGNORE event.
15440 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
15441 (myresume, handle_target_event): Set the thread's last_resume_kind
15442 and last_status from the target returned status.
15443
964e4306
PA
154442010-08-25 Pedro Alves <pedro@codesourcery.com>
15445
15446 PR threads/10729
15447
15448 * linux-x86-low.c (update_debug_registers_callback): New.
15449 (i386_dr_low_set_addr): Use it.
15450 (i386_dr_low_get_addr): New.
15451 (i386_dr_low_set_control): Use update_debug_registers_callback.
15452 (i386_dr_low_get_control): New.
15453 (i386_dr_low_get_status): Adjust.
15454 * linux-low.c (linux_stop_lwp): New.
15455 * linux-low.h (linux_stop_lwp): Declare.
15456
15457 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
15458 argument instead of a i386_debug_reg_state.
15459 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
15460 a i386_debug_reg_state.
15461 (i386_insert_aligned_watchpoint): Adjust.
15462 (i386_remove_aligned_watchpoint): Adjust.
15463 (i386_low_stopped_data_address): Read the debug registers from the
15464 inferior instead of from the mirrors.
15465 * i386-low.h (struct i386_debug_reg_state): Extend comment.
15466 (i386_dr_low_get_addr): Declare.
15467 (i386_dr_low_get_control): Declare.
15468 (i386_dr_low_get_status): Change prototype.
15469
15470 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
15471 (i386_dr_low_get_addr): New.
15472 (i386_dr_low_get_control): New.
15473 (i386_dr_low_get_status): Adjust prototype. Return
15474 dr_status_mirror.
15475 (i386_initial_stuff): Clear dr_status_mirror and
15476 dr_control_mirror.
15477 (i386_get_thread_context): Adjust.
15478 (i386_set_thread_context): Adjust.
15479 (i386_thread_added): Adjust.
15480
5f21a75b
PA
154812010-08-24 Pedro Alves <pedro@codesourcery.com>
15482
15483 * linux-low.h (linux_thread_area): Delete declaration.
15484
3e4c1235
TS
154852010-08-11 Thomas Schwinge <thomas@codesourcery.com>
15486
15487 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
15488 after its termination.
15489
1971b033
PA
154902010-08-09 Pedro Alves <pedro@codesourcery.com>
15491
15492 * linux-low.c (gdb_wants_lwp_stopped): Delete.
15493 (gdb_wants_all_stopped): Delete.
15494 (linux_wait_1): Don't call them.
15495 * server.c (handle_v_cont): Tag all threads as want-stopped.
15496 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
15497 stopped as "client-wants-stopped".
15498
310444ac
PA
154992010-07-31 Pedro Alves <pedro@codesourcery.com>
15500
15501 * Makefile.in (signals_h): New.
15502 (server_h): Depend on it.
15503 (server.o): Don't depend on $(signals_def).
15504 (signals.o): Depend on $(signals_def).
15505
a19cae16
JK
155062010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
15507
15508 * Makefile.in (signals_def): New.
15509 (server_h): Append include/gdb/signals.h and signals_def.
15510 (server.o): Append signals_def.
15511
30d50328
JK
155122010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15513
15514 * server.c (handle_target_event): Use target_signal_to_host for
15515 resume_info.sig initialization.
15516 * target.h (struct thread_resume) <sig>: New comment.
15517
5c3216e2
OS
155182010-07-20 Ozkan Sezer <sezeroz@gmail.com>
15519
c6f46ca0
OS
15520 * server.c (handle_query): strcpy() the returned string from paddress()
15521 instead of sprintf().
5c3216e2
OS
15522 * utils.c (paddress): Return phex_nz().
15523
6bd31874
JB
155242010-07-07 Joel Brobecker <brobecker@adacore.com>
15525
15526 * server.c (handle_v_cont): Call mourn_inferior if process
15527 just exited.
15528 (myresume): Likewise.
15529
0fb4aa4b
PA
155302010-07-01 Pedro Alves <pedro@codesourcery.com>
15531
15532 Static tracepoints, and integration with UST.
15533
15534 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
15535 * mem-break.c (uninsert_all_breakpoints)
15536 (reinsert_all_breakpoints): New.
15537 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
15538 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
15539 (gdb_agent_ust_loaded, helper_thread_id)
15540 (gdb_agent_helper_thread_id): New macros.
15541 (struct ipa_sym_addresses): Add addr_ust_loaded,
15542 addr_helper_thread_id, addr_cmd_buf.
15543 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
15544 (in_process_agent_loaded_ust): New.
15545 (write_e_ust_not_loaded): New.
15546 (maybe_write_ipa_ust_not_loaded): New.
15547 (struct collect_static_trace_data_action): New.
15548 (enum tracepoint_type) <static_tracepoint>: New.
15549 (struct tracepoint) <handle>: Mention static tracepoints.
15550 (struct static_tracepoint_ctx): New.
15551 (CMD_BUF_SIZE): New.
15552 (add_tracepoint_action): Handle static tracepoint actions.
15553 (unprobe_marker_at): New.
15554 (clear_installed_tracepoints): Handle static tracepoints.
15555 (cmd_qtdp): Handle static tracepoints.
15556 (probe_marker_at): New.
15557 (cmd_qtstart): Handle static tracepoints.
15558 (response_tracepoint): Handle static tracepoints.
15559 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
15560 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
15561 (get_context_regcache): Handle static tracepoints.
15562 (do_action_at_tracepoint): Handle static tracepoint actions.
15563 (traceframe_find_block_type): Handle static trace data blocks.
15564 (traceframe_read_sdata): New.
15565 (download_tracepoints): Download static tracepoint actions.
15566 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
15567 (GDB_PROBE_NAME): New.
15568 (ust_ops): New.
15569 (GET_UST_SYM): New.
15570 (USTF): New.
15571 (dlsym_ust): New.
15572 (ust_marker_to_static_tracepoint): New.
15573 (gdb_probe): New.
15574 (collect_ust_data_at_tracepoint): New.
15575 (gdb_ust_probe): New.
15576 (UNIX_PATH_MAX, SOCK_DIR): New.
15577 (gdb_ust_connect_sync_socket): New.
15578 (resume_thread, stop_thread): New.
15579 (run_inferior_command): New.
15580 (init_named_socket): New.
15581 (gdb_ust_socket_init): New.
15582 (cstr_to_hexstr): New.
15583 (next_st): New.
15584 (first_marker, next_marker): New.
15585 (response_ust_marker): New.
15586 (cmd_qtfstm, cmd_qtsstm): New.
15587 (unprobe_marker_at, probe_marker_at): New.
15588 (cmd_qtstmat, gdb_ust_thread): New.
15589 (gdb_ust_init): New.
15590 (initialize_tracepoint_ftlib): Call gdb_ust_init.
15591 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
15592 (ST_REGENTRY): New.
15593 (x86_64_st_collect_regmap): New.
15594 (X86_64_NUM_ST_COLLECT_GREGS): New.
15595 (AMD64_RIP_REGNUM): New.
15596 (supply_static_tracepoint_registers): New.
15597 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
15598 (ST_REGENTRY): New.
15599 (i386_st_collect_regmap): New.
15600 (i386_NUM_ST_COLLECT_GREGS): New.
15601 (supply_static_tracepoint_registers): New.
15602 * server.c (handle_query): Handle qXfer:statictrace:read.
15603 <qSupported>: Report support for StaticTracepoints, and
15604 qXfer:statictrace:read features.
15605 * server.h (traceframe_read_sdata)
15606 (supply_static_tracepoint_registers): Declare.
15607 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
15608 (unpack_varlen_hex): Include in IPA build.
15609 * Makefile.in (ustlibs, ustinc): New.
15610 (IPA_OBJS): Add remote-utils-ipa.o.
15611 ($(IPA_LIB)): Link -ldl and -lpthread.
15612 (UST_CFLAGS): New.
15613 (IPAGENT_CFLAGS): Add UST_CFLAGS.
15614 * config.in, configure: Regenerate.
15615
9e4344e5
PA
156162010-06-20 Ian Lance Taylor <iant@google.com>
15617 Pedro Alves <pedro@codesourcery.com>
15618
15619 * linux-x86-low.c (always_true): Delete.
15620 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
15621 trying to fool the compiler with always_true.
15622
c6beb2cb
PA
156232010-06-20 Pedro Alves <pedro@codesourcery.com>
15624
15625 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
15626 conditions in gdbserver.
15627
d2ed6730
UW
156282010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
15629
15630 * spu-low.c (spu_read_memory): Wrap around local store limit.
15631 (spu_write_memory): Likewise.
15632
4e29fb54
PA
156332010-06-15 Pedro Alves <pedro@codesourcery.com>
15634
15635 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
15636 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
15637 LONGEST uses.
15638 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
15639 uses.
15640 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
15641 uses with LONGEST uses.
15642
6a271cae
PA
156432010-06-14 Stan Shebs <stan@codesourcery.com>
15644 Pedro Alves <pedro@codesourcery.com>
15645
15646 Bytecode compiler.
15647
15648 * linux-x86-low.c: Include limits.h.
15649 (add_insns): New.
15650 (always_true): New.
15651 (EMIT_ASM): New.
15652 (EMIT_ASM32): New.
15653 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
15654 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
15655 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
15656 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
15657 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
15658 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
15659 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
15660 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
15661 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
15662 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
15663 (amd64_emit_void_call_2): New.
15664 (amd64_emit_ops): New.
15665 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
15666 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
15667 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
15668 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
15669 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
15670 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
15671 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
15672 (i386_emit_call, i386_emit_reg, i386_emit_pop)
15673 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
15674 (i386_emit_stack_adjust, i386_emit_int_call_1)
15675 (i386_emit_void_call_2): New.
15676 (i386_emit_ops): New.
15677 (x86_emit_ops): New.
15678 (the_low_target): Install x86_emit_ops.
15679 * server.h (struct emit_ops): New.
15680 (get_raw_reg_func_addr): Declare.
15681 (current_insn_ptr, emit_error): Declare.
15682 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
15683 (set_trace_state_variable_value): New defines.
15684 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
15685 addr_get_trace_state_variable_value and
15686 addr_set_trace_state_variable_value.
15687 (symbol_list): New fields for get_raw_reg,
15688 get_trace_state_variable_value and set_trace_state_variable_value.
15689 (condfn): New typedef.
15690 (struct tracepoint): New field `compiled_cond'.
15691 (do_action_at_tracepoint): Clear compiled_cond.
15692 (get_trace_state_variable_value, set_trace_state_variable_value):
15693 Export in the IPA.
15694 (condition_true_at_tracepoint): If there's a compiled condition,
15695 run that.
15696 (current_insn_ptr, emit_error): New globals.
15697 (struct bytecode_address): New.
15698 (get_raw_reg_func_addr): New.
15699 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
15700 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
15701 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
15702 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
15703 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
15704 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
15705 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
15706 (compile_tracepoint_condition, compile_bytecodes): New.
15707 * target.h (emit_ops): Forward declare.
15708 (struct target_ops): New field emit_ops.
15709 (target_emit_ops): New.
15710 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
15711 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
15712 * linux-low.c (linux_emit_ops): New.
15713 (linux_target_ops): Install it.
15714 * linux-low.h (struct linux_target_ops): New field emit_ops.
15715
92b72907
UW
157162010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
15717
15718 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
15719 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
15720
fa593d66
PA
157212010-06-01 Pedro Alves <pedro@codesourcery.com>
15722 Stan Shebs <stan@codesourcery.com>
15723
15724 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
15725 (all): Depend on $(extra_libraries).
15726 (install-only): Install the IPA.
15727 (IPA_OBJS, IPA_LIB): New.
15728 (clean): Remove the IPA lib.
15729 (IPAGENT_CFLAGS): New.
15730 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
15731 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
15732 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
15733 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
15734 * configure.ac: Check for atomic builtins support in the compiler.
15735 (IPA_DEPFILES, extra_libraries): Define.
15736 * configure.srv (ipa_obj): Add description.
15737 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
15738 (i[34567]86-*-linux*): Set ipa_obj.
15739 (x86_64-*-linux*): Set ipa_obj.
15740 * linux-low.c (stabilizing_threads): New.
15741 (supports_fast_tracepoints): New.
15742 (linux_detach): Stabilize threads before detaching.
15743 (handle_tracepoints): Handle internal tracing breakpoints. Assert
15744 the lwp is either not stabilizing, or is moving out of a jump pad.
15745 (linux_fast_tracepoint_collecting): New.
15746 (maybe_move_out_of_jump_pad): New.
15747 (enqueue_one_deferred_signal): New.
15748 (dequeue_one_deferred_signal): New.
15749 (linux_wait_for_event_1): If moving out of a jump pad, defer
15750 pending signals to later.
15751 (linux_stabilize_threads): New.
15752 (linux_wait_1): Check if threads need moving out of jump pads, and
15753 do it if so.
15754 (stuck_in_jump_pad_callback): New.
15755 (move_out_of_jump_pad_callback): New.
15756 (lwp_running): New.
15757 (linux_resume_one_lwp): Handle moving out of jump pads.
15758 (linux_set_resume_request): Dequeue deferred signals.
15759 (need_step_over_p): Also step over fast tracepoint jumps.
15760 (start_step_over): Also uninsert fast tracepoint jumps.
15761 (finish_step_over): Also reinsert fast tracepoint jumps.
15762 (linux_install_fast_tracepoint_jump): New.
15763 (linux_target_ops): Install linux_stabilize_threads and
15764 linux_install_fast_tracepoint_jump_pad.
15765 * linux-low.h (linux_target_ops) <get_thread_area,
15766 install_fast_tracepoint_jump_pad>: New fields.
15767 (struct lwp_info) <collecting_fast_tracepoint,
15768 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
15769 (linux_get_thread_area): Declare.
15770 * linux-x86-low.c (jump_insn): New.
15771 (x86_get_thread_area): New.
15772 (append_insns): New.
15773 (push_opcode): New.
15774 (amd64_install_fast_tracepoint_jump_pad): New.
15775 (i386_install_fast_tracepoint_jump_pad): New.
15776 (x86_install_fast_tracepoint_jump_pad): New.
15777 (the_low_target): Install x86_get_thread_area and
15778 x86_install_fast_tracepoint_jump_pad.
15779 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
15780 (struct fast_tracepoint_jump): New.
15781 (fast_tracepoint_jump_insn): New.
15782 (fast_tracepoint_jump_shadow): New.
15783 (find_fast_tracepoint_jump_at): New.
15784 (fast_tracepoint_jump_here): New.
15785 (delete_fast_tracepoint_jump): New.
15786 (set_fast_tracepoint_jump): New.
15787 (uninsert_fast_tracepoint_jumps_at): New.
15788 (reinsert_fast_tracepoint_jumps_at): New.
15789 (set_breakpoint_at): Use write_inferior_memory.
15790 (uninsert_raw_breakpoint): Use write_inferior_memory.
15791 (check_mem_read): Mask out fast tracepoint jumps.
15792 (check_mem_write): Mask out fast tracepoint jumps.
15793 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
15794 (set_fast_tracepoint_jump): Declare.
15795 (delete_fast_tracepoint_jump)
15796 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
15797 (reinsert_fast_tracepoint_jumps_at): Declare.
15798 * regcache.c: Don't compile many functions when building the
15799 in-process agent library.
15800 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
15801 the register buffer in the heap.
15802 (free_register_cache): If the register buffer isn't owned by the
15803 regcache, don't free it.
15804 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
15805 pre-existing register caches.
15806 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
15807 type.
15808 (convert_ascii_to_int): : Constify `from' parameter type.
15809 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
15810 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
15811 the needed buffer in-place.
15812 (relocate_instruction): New.
15813 * server.c (handle_query) <qSymbols>: If the target supports
15814 tracepoints, give it a chance of looking up symbols. Report
15815 support for fast tracepoints.
15816 (handle_status): Stabilize threads.
15817 (process_serial_event): Adjust.
15818 * server.h (struct fast_tracepoint_jump): Forward declare.
15819 (struct process_info) <fast_tracepoint_jumps>: New field.
15820 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
15821 (decode_X_packet, decode_M_packet): Adjust.
15822 (relocate_instruction): Declare.
15823 (in_process_agent_loaded): Declare.
15824 (tracepoint_look_up_symbols): Declare.
15825 (struct fast_tpoint_collect_status): Declare.
15826 (fast_tracepoint_collecting): Declare.
15827 (force_unlock_trace_buffer): Declare.
15828 (handle_tracepoint_bkpts): Declare.
15829 (initialize_low_tracepoint)
15830 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
15831 * target.h (struct target_ops) <stabilize_threads,
15832 install_fast_tracepoint_jump_pad>: New fields.
15833 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
15834 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
15835 [HAVE_STDINT_H]: Include stdint.h.
15836 (trace_debug_1): Rename to ...
15837 (trace_vdebug): ... this.
15838 (trace_debug): Rename to ...
15839 (trace_debug_1): ... this. Add `level' parameter.
15840 (trace_debug): New.
15841 (ATTR_USED, ATTR_NOINLINE): New.
15842 (IP_AGENT_EXPORT): New.
15843 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
15844 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
15845 (about_to_request_buffer_space, trace_buffer_is_full)
15846 (stopping_tracepoint, expr_eval_result, error_tracepoint)
15847 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
15848 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
15849 (traceframe_write_count, traceframes_created)
15850 (trace_state_variables)
15851 New renaming defines.
15852 (struct ipa_sym_addresses): New.
15853 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
15854 (symbol_list): New.
15855 (ipa_sym_addrs): New.
15856 (all_tracepoint_symbols_looked_up): New.
15857 (in_process_agent_loaded): New.
15858 (write_e_ipa_not_loaded): New.
15859 (maybe_write_ipa_not_loaded): New.
15860 (tracepoint_look_up_symbols): New.
15861 (debug_threads) [IN_PROCESS_AGENT]: New.
15862 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
15863 (UNKNOWN_SIDE_EFFECTS): New.
15864 (stop_tracing): New.
15865 (flush_trace_buffer): New.
15866 (stop_tracing_bkpt): New.
15867 (flush_trace_buffer_bkpt): New.
15868 (read_inferior_integer): New.
15869 (read_inferior_uinteger): New.
15870 (read_inferior_data_pointer): New.
15871 (write_inferior_data_pointer): New.
15872 (write_inferior_integer): New.
15873 (write_inferior_uinteger): New.
15874 (struct collect_static_trace_data_action): Delete.
15875 (enum tracepoint_type): New.
15876 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
15877 <actions_str, step_actions, step_actions_str>: Only include in
15878 GDBserver.
fa593d66
PA
15879 <orig_size, obj_addr_on_target, adjusted_insn_addr>
15880 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
15881 (tracepoints): Use IP_AGENT_EXPORT.
15882 (last_tracepoint): Don't include in the IPA.
15883 (stopping_tracepoint): Use IP_AGENT_EXPORT.
15884 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
15885 (alloced_trace_state_variables): New.
15886 (trace_state_variables): Use IP_AGENT_EXPORT.
15887 (traceframe_t): Delete unused variable.
15888 (circular_trace_buffer): Don't include in the IPA.
15889 (trace_buffer_start): Delete.
15890 (struct trace_buffer_control): New.
15891 (trace_buffer_free): Delete.
15892 (struct ipa_trace_buffer_control): New.
15893 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
15894 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
15895 New.
15896 (trace_buffer_ctrl): New.
15897 (TRACE_BUFFER_CTRL_CURR): New.
15898 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
15899 Reimplement as macros.
15900 (trace_buffer_wrap): Delete.
15901 (traceframe_write_count, traceframe_read_count)
15902 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
15903 (struct tracepoint_hit_ctx) <type>: New field.
15904 (struct fast_tracepoint_ctx): New.
15905 (memory_barrier): New.
15906 (cmpxchg): New.
15907 (record_tracepoint_error): Update atomically in the IPA.
15908 (clear_inferior_trace_buffer): New.
15909 (about_to_request_buffer_space): New.
15910 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
15911 updating the same buffer.
15912 (add_tracepoint): Default the tracepoint's type to trap
15913 tracepoint, and orig_size to -1.
15914 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
15915 internal variables.
15916 (create_trace_state_variable): New parameter `gdb'. Handle it.
15917 (clear_installed_tracepoints): Clear fast tracepoint jumps.
15918 (cmd_qtdp): Handle fast tracepoints.
15919 (cmd_qtdv): Adjust.
15920 (max_jump_pad_size): New.
15921 (gdb_jump_pad_head): New.
15922 (get_jump_space_head): New.
15923 (claim_jump_space): New.
15924 (sort_tracepoints): New.
15925 (MAX_JUMP_SIZE): New.
15926 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
15927 IPA.
15928 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
15929 support. Upload fast traceframes, and delete internal IPA
15930 breakpoints.
15931 (stop_tracing_handler): New.
15932 (flush_trace_buffer_handler): New.
15933 (cmd_qtstop): Upload fast tracepoints.
15934 (response_tracepoint): Handle fast tracepoints.
15935 (tracepoint_finished_step): Upload fast traceframes. Set the
15936 tracepoint hit context's tracepoint type.
15937 (handle_tracepoint_bkpts): New.
15938 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
15939 type. Add comment about fast tracepoints.
15940 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
15941 non-existing action_str field.
15942 (get_context_regcache): Handle fast tracepoints.
15943 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
15944 to the regcache.
15945 (fast_tracepoint_from_jump_pad_address): New.
15946 (fast_tracepoint_from_ipa_tpoint_address): New.
15947 (collecting_t): New.
15948 (force_unlock_trace_buffer): New.
15949 (fast_tracepoint_collecting): New.
15950 (collecting): New.
15951 (gdb_collect): New.
15952 (write_inferior_data_ptr): New.
15953 (target_tp_heap): New.
15954 (target_malloc): New.
15955 (download_agent_expr): New.
15956 (UALIGN): New.
15957 (download_tracepoints): New.
15958 (download_trace_state_variables): New.
15959 (upload_fast_traceframes): New.
15960 (IPA_FIRST_TRACEFRAME): New.
15961 (IPA_NEXT_TRACEFRAME_1): New.
15962 (IPA_NEXT_TRACEFRAME): New.
15963 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
15964 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
15965 (gdb_jump_pad_buffer_end): New.
15966 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
15967 (initialize_tracepoint): Adjust.
15968 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
15969 buffer. Initialize the low module.
15970 * utils.c (PREFIX, TOOLNAME): New.
15971 (malloc_failure): Use PREFIX.
15972 (error): In the IPA, an error causes an exit.
15973 (fatal, warning): Use PREFIX.
15974 (internal_error): Use TOOLNAME.
15975 (NUMCELLS): Increase to 10.
15976 * configure, config.in: Regenerate.
15977
d149dd1d
PA
159782010-06-01 Pedro Alves <pedro@codesourcery.com>
15979
15980 * server.c (handle_query) <qSupported>: Do two passes over the
15981 qSupported string to avoid nesting strtok.
15982
f6528abd
JK
159832010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15984
15985 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
15986 (CDEPS): New.
15987 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
15988 -Wl,--dynamic-list.
15989 * configure: Regenerate.
15990 * proc-service.list: New.
15991
ca2a87a0
JK
159922010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15993
15994 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
15995 New comment.
15996
363a6e9f
OS
159972010-05-26 Ozkan Sezer <sezeroz@gmail.com>
15998
15999 * gdbreplay.c (remote_open): Check error return from socket() call by
16000 its equality to -1 not by it being negative.
16001 * remote-utils.c (remote_open): Likewise.
16002
d23b6cb1
PA
160032010-05-23 Pedro Alves <pedro@codesourcery.com>
16004
16005 * config.h: Regenerate.
16006
28d3cf85
MK
160072010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
16008
16009 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
16010 doesn't provide PTRACE_GET_THREAD_AREA.
16011
fea36a59
MK
160122010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
16013
16014 * linux-m68k-low.c: Include <asm/ptrace.h>
16015 (ps_get_thread_area): Implement.
16016
24b066ba
DE
160172010-05-03 Doug Evans <dje@google.com>
16018
16019 * event-loop.c (struct callback_event): New struct.
16020 (callback_list): New global.
16021 (append_callback_event, delete_callback_event): New functions.
16022 (process_callback): New function.
16023 (start_event_loop): Call it.
16024 * remote-utils.c (NOT_SCHEDULED): Define.
16025 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
16026 moved out of readchar.
16027 (readchar): Rewrite. Call reschedule before returning.
16028 (reset_readchar): New function.
16029 (remote_close): Call it.
16030 (process_remaining, reschedule): New functions.
16031 * server.h (callback_handler_func): New typedef.
16032 (append_callback_event, delete_callback_event): Declare.
16033
9836d6ea
PA
160342010-05-03 Pedro Alves <pedro@codesourcery.com>
16035
16036 * proc-service.c (ps_pglobal_lookup): Use
16037 thread_db_look_up_one_symbol.
16038 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
16039 parameter. Use it instead of all_symbols_looked_up.
16040 * server.h (struct process_info) <all_symbols_looked_up>: Delete
16041 field.
16042 (all_symbols_looked_up): Don't declare.
16043 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
16044 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
16045 field.
16046 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
16047 Set all_symbols_looked_up here.
16048 (thread_db_look_up_one_symbol): New.
16049 (thread_db_get_tls_address): Adjust.
16050 (thread_db_load_search, try_thread_db_load_1): Always allocate the
16051 thread_db object on the heap, and tentatively set it in the
16052 process structure.
16053 (thread_db_init): Don't set all_symbols_looked_up here.
16054 * linux-low.h (thread_db_look_up_one_symbol): Declare.
16055
7984d532
PA
160562010-05-03 Pedro Alves <pedro@codesourcery.com>
16057
16058 * linux-low.c (linux_kill, linux_detach): Adjust.
16059 (status_pending_p_callback): Remove redundant statement. Check
16060 for !TARGET_WAITIKIND_IGNORE, instead of
16061 TARGET_WAITKIND_STOPPED.
16062 (handle_tracepoints): Make sure LWP is locked. Adjust.
16063 (linux_wait_for_event_1): Adjust.
16064 (linux_cancel_breakpoints): New.
16065 (unsuspend_one_lwp): New.
16066 (unsuspend_all_lwps): New.
16067 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
16068 (send_sigstop_callback): Change return type to int, add new
16069 `except' parameter and handle it.
16070 (suspend_and_send_sigstop_callback): New.
16071 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
16072 pass them down. If SUSPEND, also increment the lwp's suspend
16073 count.
16074 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
16075 (need_step_over_p): Don't consider suspended LWPs.
16076 (start_step_over): Adjust.
16077 (proceed_one_lwp): Change return type to int, add new `except'
16078 parameter and handle it.
16079 (unsuspend_and_proceed_one_lwp): New.
16080 (proceed_all_lwps): Use find_inferior instead of
16081 for_each_inferior.
16082 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
16083 also decrement the suspend count of LWPs. Pass `except' down,
16084 instead of hacking its suspend count.
16085 (linux_pause_all): Add `freeze' parameter. Adjust.
16086 (linux_unpause_all): New.
16087 (linux_target_ops): Install linux_unpause_all.
16088 * server.c (handle_status): Adjust.
16089 * target.h (struct target_ops): New fields `unpause_all' and
16090 `cancel_breakpoints'. Add new parameter to `pause_all'.
16091 (pause_all): Add new `freeze' parameter.
16092 (unpause_all): New.
16093 (cancel_breakpoints): New.
16094 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
16095 cancel breakpoints.
16096 (cmd_qtstart): Pause threads.
16097 (stop_tracing): Pause threads, and cancel breakpoints.
16098 * win32-low.c (win32_target_ops): Adjust.
16099
e471f25b
PA
161002010-05-03 Pedro Alves <pedro@codesourcery.com>
16101
16102 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
16103 the inferior right away from here...
16104 (linux_wait_1): ... to here, and adjust to check the thread's
16105 last_resume_kind instead of the lwp's step or stop_expected flags.
16106
1915ef4f
PA
161072010-05-02 Pedro Alves <pedro@codesourcery.com>
16108
16109 * README: Use consistent `GDB' and `GDBserver' spellings.
16110
f9e39928
PA
161112010-05-02 Pedro Alves <pedro@codesourcery.com>
16112
16113 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
16114 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
16115 (linux_detach_one_lwp): Assume the lwp is stopped.
16116 (any_thread_of): Delete.
16117 (linux_detach): Stop all lwps here. Don't blindly delete all
16118 breakpoints.
16119 (delete_lwp_callback): New.
16120 (linux_mourn): Delete all lwps of the process that is gone.
16121 (linux_wait_1): Don't delete the last lwp of the process here.
16122 * mem-break.h (mark_breakpoints_out): Declare.
16123 * mem-break.c (mark_breakpoints_out): New.
16124 (free_all_breakpoints): Use it.
16125 * server.c (handle_target_event): If the process is gone, mark
16126 breakpoints out.
16127 * thread-db.c (struct thread_db) <create_bp>: New field.
16128 (thread_db_enable_reporting): Fix prototype. Store a thread event
16129 breakpoint reference in the thread_db struct.
16130 (thread_db_load_search): Clear the thread_db object.
16131 (try_thread_db_load_1): Ditto.
16132 (switch_to_process): New.
16133 (disable_thread_event_reporting): Use it.
16134 (remove_thread_event_breakpoints): New.
16135 (thread_db_detach, thread_db_mourn): Use it.
16136
1e7fc18c
PA
161372010-05-01 Pedro Alves <pedro@codesourcery.com>
16138
16139 * linux-low.c (linux_enable_event_reporting): New.
16140 (linux_wait_for_event_1, handle_extended_wait): Use it.
16141
02fc4de7
PA
161422010-04-30 Pedro Alves <pedro@codesourcery.com>
16143
16144 * linux-low.c (linux_kill_one_lwp, linux_kill)
16145 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
16146 (send_sigstop): Take an lwp_info as parameter instead. Queue a
16147 SIGSTOP even if the LWP is stopped.
16148 (send_sigstop_callback): New.
16149 (stop_all_lwps): Use send_sigstop_callback instead.
16150 (linux_resume_one_thread): Adjust.
16151 (proceed_one_lwp): Still proceed an LWP that the client has
16152 requested to stop, if we haven't reported it as stopped yet. Make
16153 sure that LWPs the client want stopped, have a pending SIGSTOP.
16154
bc3b5632
DE
161552010-04-26 Doug Evans <dje@google.com>
16156
ae1ada35
DE
16157 * server.c (handle_general_set): Make static.
16158
bc3b5632
DE
16159 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
16160 Print received char after testing for error/eof instead of before.
16161 (input_interrupt): Tweak comment.
16162
65730243
DE
161632010-04-23 Doug Evans <dje@google.com>
16164
16165 * server.c (start_inferior): Print inferior argv if --debug.
16166
a8ae7dc0
AR
161672010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
16168
16169 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
16170 * nto-x86-low.c: Include server.h
16171
1c07cc19
PM
161722010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
16173
16174 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
16175 be consistent with other sources of this directory.
16176 (init_registers_amd64): Correct name of source file of this function
16177 in the comment.
16178
e0a61e09
PM
161792010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16180
16181 * configure.srv (x86_64-*-mingw*): New configuration for Windows
16182 64-bit executables.
16183
54709339
PM
161842010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16185
16186 * win32-i386-low.c: Add 64-bit support.
16187 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
16188 (init_registers_amd64): Declare.
16189 (mappings): Add 64-bit version of array.
16190 (init_windows_x86): New function.
16191 (the_low_target): Change init_arch field to init_windows_x86.
16192
e8f0053d
PM
161932010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16194
16195 * win32-low.c: Adapt to support also 64-bit architecture.
16196 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
16197 (get_image_name): Use SIZE_T type for local variable `done'.
16198 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
16199 (toolhelp_get_dll_name): Idem.
16200 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
16201 Use uintptr_t typecast to avoid warning.
16202 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
16203 (handle_exception): Use phex_nz to avoid warning.
16204 (win32_wait): Remove unused local variable `process'.
16205
c481e77e
PM
162062010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16207
16208 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
16209 `amd64-avx.o'.
16210
12ea4b69
PM
162112010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
16212
16213 * configure.ac: Use `ws2_32' library for srv_mingw.
16214 * configure: Regenerate.
16215 * gdbreplay.c: Include winsock2.h instead of winsock.h.
16216 * remote-utils.c: Likewise.
16217
f6d1620c
L
162182010-04-17 H.J. Lu <hongjiu.lu@intel.com>
16219
16220 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
16221 if __x86_64__ is defined.
16222
8e642873
PM
162232010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
16224
16225 * configure: Regenerate.
16226
711e434b
PM
162272010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
16228
16229 * server.c (handle_query): Handle 'qGetTIBAddr' query.
16230 * target.h (target_ops): New get_tib_address field.
16231 * win32-low.h (win32_thread_info): Add thread_local_base field.
16232 * win32-low.c (child_add_thread): Add tlb argument.
16233 Set thread_local_base field to TLB.
16234 (get_child_debug_event): Adapt to child_add_thread change.
16235 (win32_get_tib_address): New function.
16236 (win32_target_ops): Set get_tib_address field to
16237 win32_get_tib_address.
16238 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
16239
505106cd
PA
162402010-04-12 Pedro Alves <pedro@codesourcery.com>
16241
505106cd
PA
16242 * linux-low.c (linux_mourn): Also remove the process.
16243 * server.c (handle_target_event): Don't remove the process here.
16244 * nto-low.c (nto_mourn): New.
16245 (nto_target_ops): Install it.
16246 * spu-low.c (spu_mourn): New.
16247 (spu_target_ops): Install it.
16248 * win32-low.c (win32_mourn): New.
16249 (win32_target_ops): Install it.
16250
e8470a06
PA
162512010-04-12 Pedro Alves <pedro@codesourcery.com>
16252
16253 * server.h (buffer_xml_printf): Remove redundant `;'.
16254
45ba0d02
PA
162552010-04-12 Pedro Alves <pedro@codesourcery.com>
16256
16257 * regcache.c (set_register_cache): Invalidate regcaches before
16258 changing the register cache layout.
16259 (regcache_invalidate_one): Allow a NULL regcache.
16260 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
16261 regcaches before changing the register cache layout or the target
16262 regsets.
16263
59e04013
L
162642010-04-12 H.J. Lu <hongjiu.lu@intel.com>
16265
16266 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
16267 variable warning on Linux/x86-64.
16268
8336d594
PA
162692010-04-11 Pedro Alves <pedro@codesourcery.com>
16270
16271 GDBserver disconnected tracing support.
16272
16273 * linux-low.c (linux_remove_process): Delete.
16274 (add_lwp): Don't set last_resume_kind here.
16275 (linux_kill): Use `mourn'.
16276 (linux_detach): Use `thread_db_detach', and `mourn'.
16277 (linux_mourn): New.
16278 (linux_attach_lwp_1): Adjust comment.
16279 (linux_attach): last_resume_kind moved the thread_info; adjust.
16280 (status_pending_p_callback): Adjust.
16281 (linux_wait_for_event_1): Adjust.
16282 (count_events_callback, select_singlestep_lwp_callback)
16283 (select_event_lwp_callback, cancel_breakpoints_callback)
16284 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
16285 (proceed_one_lwp): Adjust.
16286 (linux_async): Add debug output.
16287 (linux_thread_stopped): New.
16288 (linux_pause_all): New.
16289 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
16290 linux_pause_all.
16291 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
16292 (thread_db_free): Delete declaration.
16293 (thread_db_detach, thread_db_mourn): Declare.
16294 * thread-db.c (thread_db_init): Use thread_db_mourn.
16295 (thread_db_free): Delete, split in two.
16296 (disable_thread_event_reporting): New.
16297 (thread_db_detach): New.
16298 (thread_db_mourn): New.
16299
16300 * server.h (struct thread_info) <last_resume_kind>: New field.
16301 <attached>: Add comment.
16302 <gdb_detached>: New field.
16303 (handler_func): Change return type to int.
16304 (handle_serial_event, handle_target_event): Ditto.
16305 (gdb_connected): Declare.
16306 (tracing): Delete.
16307 (disconnected_tracing): Declare.
16308 (stop_tracing): Declare.
16309
16310 * server.c (handle_query) <qSupported>: Report support for
16311 disconnected tracing.
16312 (queue_stop_reply_callback): Account for running threads.
16313 (gdb_wants_thread_stopped): New.
16314 (gdb_wants_all_threads_stopped): New.
16315 (gdb_reattached_process): New.
16316 (handle_status): Clear the `gdb_detached' flag of all processes.
16317 In all-stop, stop all threads.
16318 (main): Be sure to leave tfind mode. Handle disconnected tracing.
16319 (process_serial_event): If the remote connection breaks, or if an
16320 exit was forced with "monitor exit", force an event loop exit.
16321 Handle disconnected tracing on detach.
16322 (handle_serial_event): Adjust.
16323 (handle_target_event): If GDB isn't connected, forward events back
16324 to the inferior, unless the last process exited, in which case,
16325 exit gdbserver. Adjust interface.
16326
16327 * remote-utils.c (remote_open): Don't block in accept. Instead
16328 register an event loop source on the listen socket file
16329 descriptor. Refactor bits into ...
16330 (listen_desc): ... this new global.
16331 (gdb_connected): ... this new function.
16332 (enable_async_notification): ... this new function.
16333 (handle_accept_event): ... this new function.
16334 (remote_close): Clear remote_desc.
16335
16336 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
16337
16338 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
16339 New fields.
16340 (mourn_inferior): Define.
16341 (target_process_qsupported): Avoid the dangling else problem.
16342 (thread_stopped): Define.
16343 (pause_all): Define.
16344 (target_waitstatus_to_string): Declare.
16345 * target.c (target_waitstatus_to_string): New.
16346
16347 * tracepoint.c (tracing): Make extern.
16348 (disconnected_tracing): New.
16349 (stop_tracing): Make extern. Handle tracing stops due to GDB
16350 disconnecting.
16351 (cmd_qtdisconnected): New.
16352 (cmd_qtstatus): Report disconnected tracing status in trace reply.
16353 (handle_tracepoint_general_set): Handle QTDisconnected.
16354
16355 * event-loop.c (event_handler_func): Change return type to int.
16356 (process_event): Bail out if the event handler wants the event
16357 loop to stop.
16358 (handle_file_event): Ditto.
16359 (start_event_loop): Bail out if the event handler wants the event
16360 loop to stop.
16361
16362 * nto-low.c (nto_target_ops): Adjust.
16363 * spu-low.c (spu_wait): Don't remove the process here.
16364 (spu_target_ops): Adjust.
16365 * win32-low.c (win32_wait): Don't remove the process here.
16366 (win32_target_ops): Adjust.
16367
5d267c4c
PA
163682010-04-11 Pedro Alves <pedro@codesourcery.com>
16369
16370 * regcache.c (realloc_register_cache): Invalidate inferior's
16371 regcache before recreating it.
16372
623ccd72
PA
163732010-04-09 Pedro Alves <pedro@codesourcery.com>
16374
16375 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
16376
219f2f23
PA
163772010-04-09 Stan Shebs <stan@codesourcery.com>
16378 Pedro Alves <pedro@codesourcery.com>
16379
16380 * server.h (LONGEST): New.
16381 (struct thread_info) <while_stepping>: New field.
16382 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
16383 Declare.
16384 (initialize_tracepoint, handle_tracepoint_general_set)
16385 (handle_tracepoint_query, tracepoint_finished_step)
16386 (tracepoint_was_hit, release_while_stepping_state_list):
16387 (current_traceframe): Declare.
16388 * server.c (handle_general_set): Handle tracepoint packets.
16389 (read_memory): New.
16390 (write_memory): New.
16391 (handle_search_memory_1): Use read_memory.
16392 (handle_query): Report support for conditional tracepoints, trace
16393 state variables, and tracepoint sources. Handle tracepoint
16394 queries.
16395 (main): Initialize the tracepoints module.
16396 (process_serial_event): Handle traceframe reads/writes.
16397
16398 * linux-low.c (handle_tracepoints): New.
16399 (linux_wait_1): Call it.
16400 (linux_resume_one_lwp): Handle while-stepping.
16401 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
16402 (linux_target_ops): Install them.
16403 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
16404 New field.
16405 * linux-x86-low.c (x86_supports_tracepoints): New.
16406 (the_low_target). Install it.
16407
16408 * mem-break.h (delete_breakpoint): Declare.
16409 * mem-break.c (delete_breakpoint): Make external.
16410
16411 * target.h (struct target_ops): Add `supports_tracepoints',
16412 `read_pc', and `write_pc' fields.
16413 (target_supports_tracepoints): Define.
16414 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
16415 (phex_nz): New.
16416
16417 * regcache.h (struct regcache) <registers_owned>: New field.
16418 (init_register_cache, regcache_cpy): Declare.
16419 (regcache_read_pc, regcache_write_pc): Declare.
16420 (register_cache_size): Declare.
16421 (supply_regblock): Declare.
16422 * regcache.c (init_register_cache): New.
16423 (new_register_cache): Use it.
16424 (regcache_cpy): New.
16425 (register_cache_size): New.
16426 (supply_regblock): New.
16427 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 16428
219f2f23
PA
16429 * tracepoint.c: New.
16430
16431 * Makefile.in (OBS): Add tracepoint.o.
16432 (tracepoint.o): New rule.
16433
3a13a53b
L
164342010-04-08 H.J. Lu <hongjiu.lu@intel.com>
16435
16436 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
16437 (i386-mmx.o): New.
16438 (i386-mmx.c): Likewise.
16439 (i386-mmx-linux.o): Likewise.
16440 (i386-mmx-linux.c): Likewise.
16441
16442 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
16443 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
16444 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
16445 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
16446
16447 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
16448 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
16449 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
16450
1570b33e
L
164512010-04-07 H.J. Lu <hongjiu.lu@intel.com>
16452
16453 * Makefile.in (clean): Updated.
16454 (i386-avx.o): New.
16455 (i386-avx.c): Likewise.
16456 (i386-avx-linux.o): Likewise.
16457 (i386-avx-linux.c): Likewise.
16458 (amd64-avx.o): Likewise.
16459 (amd64-avx.c): Likewise.
16460 (amd64-avx-linux.o): Likewise.
16461 (amd64-avx-linux.c): Likewise.
16462
16463 * configure.srv (srv_i386_regobj): Add i386-avx.o.
16464 (srv_i386_linux_regobj): Add i386-avx-linux.o.
16465 (srv_amd64_regobj): Add amd64-avx.o.
16466 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
16467 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
16468 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
16469 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
16470 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
16471 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
16472 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
16473
16474 * i387-fp.c: Include "i386-xstate.h".
16475 (i387_xsave): New.
16476 (i387_cache_to_xsave): Likewise.
16477 (i387_xsave_to_cache): Likewise.
16478 (x86_xcr0): Likewise.
16479
16480 * i387-fp.h (i387_cache_to_xsave): Likewise.
16481 (i387_xsave_to_cache): Likewise.
16482 (x86_xcr0): Likewise.
16483
16484 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
16485 * linux-crisv32-low.c (target_regsets): Likewise.
16486 * linux-m68k-low.c (target_regsets): Likewise.
16487 * linux-mips-low.c (target_regsets): Likewise.
16488 * linux-ppc-low.c (target_regsets): Likewise.
16489 * linux-s390-low.c (target_regsets): Likewise.
16490 * linux-sh-low.c (target_regsets): Likewise.
16491 * linux-sparc-low.c (target_regsets): Likewise.
16492 * linux-xtensa-low.c (target_regsets): Likewise.
16493
16494 * linux-low.c: Include <sys/uio.h>.
16495 (regsets_fetch_inferior_registers): Support nt_type.
16496 (regsets_store_inferior_registers): Likewise.
16497 (linux_process_qsupported): New.
16498 (linux_target_ops): Add linux_process_qsupported.
16499
16500 * linux-low.h (regset_info): Add nt_type.
16501 (linux_target_ops): Add process_qsupported.
16502
16503 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
16504 and <sys/uio.h>.
16505 (init_registers_i386_avx_linux): New.
16506 (init_registers_amd64_avx_linux): Likewise.
16507 (xmltarget_i386_linux_no_xml): Likewise.
16508 (xmltarget_amd64_linux_no_xml): Likewise.
16509 (PTRACE_GETREGSET): Likewise.
16510 (PTRACE_SETREGSET): Likewise.
16511 (x86_fill_xstateregset): Likewise.
16512 (x86_store_xstateregset): Likewise.
16513 (use_xml): Likewise.
16514 (x86_linux_update_xmltarget): Likewise.
16515 (x86_linux_process_qsupported): Likewise.
16516 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
16517 (x86_arch_setup): Don't call init_registers_amd64_linux nor
16518 init_registers_i386_linux here. Call
16519 x86_linux_update_xmltarget.
16520 (the_low_target): Add x86_linux_process_qsupported.
16521
16522 * server.c (handle_query): Call target_process_qsupported.
16523
16524 * target.h (target_ops): Add process_qsupported.
16525 (target_process_qsupported): New.
16526
fc7238bb
PA
165272010-04-03 Pedro Alves <pedro@codesourcery.com>
16528
16529 * inferiors.c (add_thread): Set last_status kind to
16530 TARGET_WAITKIND_IGNORE.
16531 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
16532 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
16533 (linux_wait_1): Move `thread' local definition to block that uses
16534 it. Don't NULL initialize `event_child'.
16535 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
16536 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
16537 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
16538
bdabb078
PA
165392010-04-01 Pedro Alves <pedro@codesourcery.com>
16540
16541 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
16542 an extended waitstatus, or by a watchpoint.
16543 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
16544 thread was stepping or has been stopped by a watchpoint.
16545
d3bbe7a0
PA
165462010-04-01 Pedro Alves <pedro@codesourcery.com>
16547
16548 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
16549 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
16550 of another, then delete the previous, and validate all
16551 breakpoints.
16552 (validate_inserted_breakpoint): New.
16553 (delete_disabled_breakpoints): New.
16554 (validate_breakpoints): New.
16555 (check_mem_read): Validate breakpoints before trusting their
16556 shadow. Delete disabled breakpoints.
16557 (check_mem_write): Validate breakpoints before trusting they
16558 should be inserted. Delete disabled breakpoints.
16559 * mem-break.h (validate_breakpoints):
16560 * server.c (handle_query): Validate breakpoints when we see a
16561 qSymbol query.
16562
8b07ae33
PA
165632010-04-01 Pedro Alves <pedro@codesourcery.com>
16564
16565 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
16566 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
16567 if we could tell there's a GDB breakpoint at stop_pc.
16568 (need_step_over_p): Don't do a step over if we find a GDB
16569 breakpoint at the resume PC.
16570
16571 * mem-break.c (struct raw_breakpoint): New.
16572 (enum bkpt_type): New type `gdb_breakpoint'.
16573 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
16574 fields. New field `raw'.
16575 (find_raw_breakpoint_at): New.
16576 (set_raw_breakpoint_at): Handle refcounting. Create a raw
16577 breakpoint instead.
16578 (set_breakpoint_at): Adjust.
16579 (delete_raw_breakpoint): New.
16580 (release_breakpoint): New.
16581 (delete_breakpoint): Rename to...
16582 (delete_breakpoint_1): ... this. Add proc parameter. Use
16583 release_breakpoint. Return ENOENT.
16584 (delete_breakpoint): Reimplement.
16585 (find_breakpoint_at): Delete.
16586 (find_gdb_breakpoint_at): New.
16587 (delete_breakpoint_at): Delete.
16588 (set_gdb_breakpoint_at): New.
16589 (delete_gdb_breakpoint_at): New.
16590 (gdb_breakpoint_here): New.
16591 (set_reinsert_breakpoint): Use release_breakpoint.
16592 (uninsert_breakpoint): Rename to ...
16593 (uninsert_raw_breakpoint): ... this.
16594 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
16595 (reinsert_raw_breakpoint): Change parameter type to
16596 raw_breakpoint.
16597 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
16598 instead.
16599 (check_breakpoints): Adjust. Use release_breakpoint.
16600 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
16601 (breakpoint_inserted_here): Ditto.
16602 (check_mem_read): Adjust to iterate over raw breakpoints instead.
16603 Don't trust the breakpoint's shadow if it is not inserted.
16604 (check_mem_write): Adjust to iterate over raw breakpoints instead.
16605 (delete_all_breakpoints): Adjust.
16606 (free_all_breakpoints): Mark all breakpoints as uninserted, and
16607 use delete_breakpoint_1.
16608
16609 * mem-break.h (breakpoints_supported): Delete declaration.
16610 (set_gdb_breakpoint_at): Declare.
16611 (gdb_breakpoint_here): Declare.
16612 (delete_breakpoint_at): Delete.
16613 (delete_gdb_breakpoint_at): Declare.
16614
16615 * server.h (struct raw_breakpoint): Forward declare.
16616 (struct process_info): New field `raw_breakpoints'.
16617
16618 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
16619 breakpoints.
16620
6bf5e0ba
PA
166212010-03-24 Pedro Alves <pedro@codesourcery.com>
16622
16623 * linux-low.c (status_pending_p_callback): Fix comment.
16624 (linux_wait_for_event_1): Move most of the internal breakpoint
16625 handling from here...
16626 (linux_wait_1): ... to here.
16627 (count_events_callback): New.
16628 (select_singlestep_lwp_callback): New.
16629 (select_event_lwp_callback): New.
16630 (cancel_breakpoints_callback): New.
16631 (select_event_lwp): New.
16632 (linux_wait_1): Simplify internal breakpoint handling. Give equal
16633 priority to all LWPs that have had events that should be reported
16634 to the client. Cancel breakpoints when about to reporting the
16635 event to the client, not while stopping lwps. No longer cancel
16636 finished single-steps here.
16637 (cancel_finished_single_step): Delete.
16638 (cancel_finished_single_steps): Delete.
16639
414a389f
PA
166402010-03-24 Pedro Alves <pedro@codesourcery.com>
16641
16642 * mem-break.c (enum bkpt_type): New.
16643 (struct breakpoint): New field `type'.
16644 (set_breakpoint_at): Change return type to struct breakpoint
16645 pointer. Set type to `other_breakpoint' by default.
16646 (delete_breakpoint): Rewrite, supporting more than one breakpoint
16647 in the breakpoint list.
16648 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
16649 (reinsert_breakpoint): Rename to ...
16650 (reinsert_raw_breakpoint): ... this.
16651 (reinsert_breakpoints_at): Adjust.
16652 * mem-break.h (struct breakpoint): Declare.
16653 (set_breakpoint_at): Change return type to struct breakpoint
16654 pointer.
16655
2280c721
PA
166562010-03-24 Pedro Alves <pedro@codesourcery.com>
16657
16658 * server.c (handle_query): Assign, not compare.
16659
d50171e4
PA
166602010-03-24 Pedro Alves <pedro@codesourcery.com>
16661
16662 Teach linux gdbserver to step-over-breakpoints.
16663
16664 * linux-low.c (can_hardware_single_step): New.
16665 (supports_breakpoints): New.
16666 (handle_extended_wait): If stopping threads, read the stop pc of
16667 the new cloned LWP.
16668 (get_pc): New.
16669 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
16670 low target doesn't support retrieving the PC.
16671 (add_lwp): Set last_resume_kind to resume_continue.
16672 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
16673 (linux_attach): Don't clear stop_expected. Set the lwp's
16674 last_resume_kind to resume_stop.
16675 (linux_detach_one_lwp): Don't check for removed breakpoints.
16676 (check_removed_breakpoint): Delete.
16677 (status_pending_p): Rename to ...
16678 (status_pending_p_callback): ... this. Don't check for removed
16679 breakpoints. Don't consider threads that are stopped from GDB's
16680 perspective.
16681 (linux_wait_for_lwp): Always read the stop_pc here.
16682 (cancel_breakpoint): New.
16683 (step_over_bkpt): New global.
16684 (linux_wait_for_event_1): Implement stepping over breakpoints.
16685 (gdb_wants_lwp_stopped): New.
16686 (gdb_wants_all_stopped): New.
16687 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
16688 single-step traps here. Store the thread's last reported target
16689 wait status.
16690 (send_sigstop): Don't clear stop_expected. Always set it,
16691 instead.
16692 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
16693 (cancel_finished_single_step): New.
16694 (cancel_finished_single_steps): New.
16695 (wait_for_sigstop): Don't cancel finished single-step traps here.
16696 (linux_resume_one_lwp): Don't check for removed breakpoints.
16697 Don't set `step' on non-hardware step archs.
16698 (linux_set_resume_request): Ignore resume_stop requests if already
16699 stopping or stopped. Set the lwp's last_resume_kind.
16700 (resume_status_pending_p): Don't check for removed breakpoints.
16701 (need_step_over_p): New.
16702 (start_step_over): New.
16703 (finish_step_over): New.
16704 (linux_resume_one_thread): Always queue a sigstop for resume_stop
16705 requests. Clear the thread's last reported target waitstatus.
16706 Don't use the `suspended' flag. Don't consider pending breakpoints.
16707 (linux_resume): Start a step-over if necessary.
16708 (proceed_one_lwp): New.
16709 (proceed_all_lwps): New.
16710 (unstop_all_lwps): New.
16711 * linux-low.h (struct lwp_info): Rewrite comment for the
16712 `suspended' flag. Add the `stop_pc' field. Delete the
16713 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
16714 Add `'last_resume_kind' and `need_step_over' fields.
16715 * inferiors.c (struct thread_info): Delete, moved elsewhere.
16716 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
16717 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
16718 (set_raw_breakpoint_at): New.
16719 (set_breakpoint_at): Rewrite to use it.
16720 (reinsert_breakpoint_handler): Delete.
16721 (set_reinsert_breakpoint): New.
16722 (reinsert_breakpoint_by_bp): Delete.
16723 (delete_reinsert_breakpoints): New.
16724 (uninsert_breakpoint): Rewrite.
16725 (uninsert_breakpoints_at): New.
16726 (reinsert_breakpoint): Rewrite.
16727 (reinsert_breakpoints_at): New.
16728 (check_breakpoints): Rewrite.
16729 (breakpoint_here): New.
16730 (breakpoint_inserted_here): New.
16731 (check_mem_read): Adjust.
16732 * mem-break.h (breakpoints_supported, breakpoint_here)
16733 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
16734 (reinsert_breakpoint_by_bp): Delete declaration.
16735 (delete_reinsert_breakpoints): Declare.
16736 (reinsert_breakpoint): Delete declaration.
16737 (reinsert_breakpoints_at): Declare.
16738 (uninsert_breakpoint): Delete declaration.
16739 (uninsert_breakpoints_at): Declare.
16740 (check_breakpoints): Adjust prototype.
16741 * server.h: Adjust include order.
16742 (struct thread_info): Declare here. Add a `last_status' field.
16743
30ba68cb
MS
167442010-03-23 Michael Snyder <msnyder@vmware.com>
16745
16746 * server.c (crc32): New function.
16747 (handle_query): Add handling for 'qCRC:' request.
16748
b9a881c2
PA
167492010-03-23 Pedro Alves <pedro@codesourcery.com>
16750
16751 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
16752 lwp had been stopped by a watchpoint.
16753
e92d13d5
PA
167542010-03-16 Pedro Alves <pedro@codesourcery.com>
16755
16756 * server.h (internal_error): Declare.
16757 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
16758 * utils.c (internal_error): New function.
16759
64daa791
AS
167602010-03-15 Andreas Schwab <schwab@redhat.com>
16761
16762 * configure.srv: Fix typo setting srv_regobj.
16763
f52cd8cd
PA
167642010-03-15 Pedro Alves <pedro@codesourcery.com>
16765
16766 * linux-low.c (fetch_register): Avoid passing a non string literal
16767 format to `error'.
16768 (usr_store_inferior_registers): Ditto.
16769
93ae6fdc
PA
167702010-03-14 Pedro Alves <pedro@codesourcery.com>
16771
16772 * linux-low.c (linux_write_memory): Bail out early if peeking
16773 memory failed.
16774
c3adc08c
PA
167752010-03-14 Pedro Alves <pedro@codesourcery.com>
16776
16777 * linux-low.h (struct lwp_info): New fields
16778 `stopped_by_watchpoint' and `stopped_data_address'.
16779 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
16780 here, and cache them in the lwp object.
16781 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
16782 directly.
16783 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
16784 field.
16785 (linux_stopped_by_watchpoint): Rewrite.
16786 (linux_stopped_data_address): Rewrite.
16787
bce522a2
PA
167882010-03-06 Simo Melenius <simo.melenius@iki.fi>
16789
16790 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
16791 switching the current inferior, not before.
16792
90884b2b
L
167932010-03-01 H.J. Lu <hongjiu.lu@intel.com>
16794
16795 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
16796 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
16797 i386-linux.c and amd64-linux.c.
16798 (reg-i386.o): Removed.
16799 (reg-i386.c): Likewise.
16800 (reg-i386-linux.o): Likewise.
16801 (reg-i386-linux.c): Likewise.
16802 (reg-x86-64.o): Likewise.
16803 (reg-x86-64.c): Likewise.
16804 (reg-x86-64-linux.o): Likewise.
16805 (reg-x86-64-linux.c): Likewise.
16806 (i386.o): New.
16807 (i386.c): Likewise.
16808 (i386-linux.o): Likewise.
16809 (i386-linux.c): Likewise.
16810 (amd64.o): Likewise.
16811 (amd64.c): Likewise.
16812 (amd64-linux.o): Likewise.
16813 (amd64-linux.c): Likewise.
16814
16815 * configure.srv (srv_i386_regobj): New.
16816 (srv_i386_linux_regobj): Likewise.
16817 (srv_amd64_regobj): Likewise.
16818 (srv_amd64_linux_regobj): Likewise.
16819 (srv_i386_32bit_xmlfiles): Likewise.
16820 (srv_i386_64bit_xmlfiles): Likewise.
16821 (srv_i386_xmlfiles): Likewise.
16822 (srv_amd64_xmlfiles): Likewise.
16823 (srv_i386_linux_xmlfiles): Likewise.
16824 (srv_amd64_linux_xmlfiles): Likewise.
16825 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
16826 srv_xmlfiles to $srv_i386_xmlfiles.
16827 (i[34567]86-*-mingw32ce*): Likewise.
16828 (i[34567]86-*-mingw*): Likewise.
16829 (i[34567]86-*-nto*): Likewise.
16830 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
16831 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
16832 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
16833 (x86_64-*-linux*): Likewise.
16834
16835 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
16836 (init_registers_amd64_linux): New.
16837 (x86_arch_setup): Replace init_registers_x86_64_linux with
16838 init_registers_amd64_linux.
16839
193f13e6
MK
168402010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
16841
16842 * configure.ac: Check for libdl. If it is not available link against
16843 static libthread_db.
16844 * configure: Regenerate.
16845
85d721b8
PA
168462010-02-22 Pedro Alves <pedro@codesourcery.com>
16847
16848 PR9605
16849
16850 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
16851 handing a read watchpoint.
16852 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
16853
6076632b
DE
168542010-02-12 Doug Evans <dje@google.com>
16855
16856 * linux-low.c (linux_supports_tracefork_flag): Document.
16857 (linux_look_up_symbols): Add comment.
16858
3327ccf7
L
168592010-02-03 H.J. Lu <hongjiu.lu@intel.com>
16860
16861 * regcache.c (supply_register): Clear regcache if buf is NULL.
16862
0718675c 168632010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 16864 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
16865
16866 * inferiors.c (find_inferior): Add function documentation.
16867 (unloaded_dll): Handle the case where the unloaded dll has not
16868 been previously registered in the dll list.
16869
177321bd
DJ
168702010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16871
16872 * linux-arm-low.c (thumb_breakpoint_len): Delete.
16873 (thumb2_breakpoint): New.
16874 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
16875
2b009048
DJ
168762010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16877
16878 * linux-low.c (get_stop_pc): Check for SIGTRAP.
16879 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
16880 breakpoints.
16881
3be029c7
PA
168822010-01-21 Pedro Alves <pedro@codesourcery.com>
16883
16884 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
16885
18f5de3b
JK
168862010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16887
16888 * linux-s390-low.c (s390_collect_ptrace_register)
16889 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
16890
3743bb4f
DE
168912010-01-21 Doug Evans <dje@google.com>
16892
14ce3065
DE
16893 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
16894 (PTRACE_ARG4_TYPE): New macro.
16895 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
16896 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
16897 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
16898 (usr_store_inferior_registers): Ditto.
16899 (linux_read_memory, linux_write_memory): Ditto.
16900 (linux_test_for_tracefork): Ditto.
16901
3743bb4f
DE
16902 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
16903 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
16904
8b315be5
PA
169052010-01-21 Pedro Alves <pedro@codesourcery.com>
16906
16907 * proc-service.c (ps_lgetregs): Don't refetch registers from the
16908 target.
16909
85492558
PA
169102010-01-21 Pedro Alves <pedro@codesourcery.com>
16911
16912 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
16913 prototype to take a regcache. Adjust.
16914
442ea881
PA
169152010-01-20 Pedro Alves <pedro@codesourcery.com>
16916
16917 * regcache.h (struct thread_info): Forward declare.
16918 (struct regcache): New.
16919 (new_register_cache): Adjust prototype.
16920 (get_thread_regcache): Declare.
16921 (free_register_cache): Adjust prototype.
16922 (registers_to_string, registers_from_string): Ditto.
16923 (supply_register, supply_register_by_name, collect_register)
16924 (collect_register_as_string, collect_register_by_name): Ditto.
16925 * regcache.c (struct inferior_regcache_data): Delete.
16926 (get_regcache): Rename to ...
16927 (get_thread_regcache): ... this. Adjust. Switch inferior before
16928 fetching registers.
16929 (regcache_invalidate_one): Adjust.
16930 (regcache_invalidate): Fix prototype.
16931 (new_register_cache): Return the new register cache.
16932 (free_register_cache): Change prototype.
16933 (realloc_register_cache): Adjust.
16934 (registers_to_string): Change prototype to take a regcache. Adjust.
16935 (registers_from_string): Ditto.
16936 (register_data): Ditto.
16937 (supply_register): Ditto.
16938 (supply_register_by_name): Ditto.
16939 (collect_register): Ditto.
16940 (collect_register_as_string): Ditto.
16941 (collect_register_by_name): Ditto.
16942 * server.c (process_serial_event): Adjust.
16943 * linux-low.h (regset_fill_func, regset_store_func): Change
16944 prototype.
16945 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
16946 Change prototype.
16947 * linux-low.c (get_stop_pc): Adjust.
16948 (check_removed_breakpoint): Adjust.
16949 (linux_wait_for_event): Adjust.
16950 (linux_resume_one_lwp): Adjust.
16951 (fetch_register): Add regcache parameter. Adjust.
16952 (usr_store_inferior_registers): Ditto.
16953 (regsets_fetch_inferior_registers): Ditto.
16954 (regsets_store_inferior_registers): Ditto.
16955 (linux_fetch_registers, linux_store_registers): Ditto.
16956 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
16957 regcache. Adjust.
43aaf8b6
PA
16958 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
16959 Ditto.
442ea881
PA
16960 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
16961 prototype to take a regcache.
16962 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
16963 * remote-utils.c (convert_ascii_to_int, outreg)
16964 (prepare_resume_reply): Change prototype to take a regcache.
16965 Adjust.
16966 * target.h (struct target_ops) <fetch_registers, store_registers>:
16967 Change prototype to take a regcache.
16968 (fetch_inferior_registers, store_inferior_registers): Change
16969 prototype to take a regcache. Adjust.
16970 * proc-service.c (ps_lgetregs): Adjust.
16971 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
16972 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
16973 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
16974 take a regcache. Adjust.
16975 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
16976 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
16977 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
16978 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
16979 * linux-cris-low.c (cris_get_pc, cris_set_pc)
16980 (cris_cannot_fetch_register):
16981 (cris_breakpoint_at): Change prototype to take a regcache.
16982 Adjust.
16983 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
16984 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
16985 to take a regcache. Adjust.
16986 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
16987 Adjust.
16988 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
16989 take a regcache. Adjust.
16990 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
16991 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
16992 (m68k_set_pc): Change prototype to take a regcache. Adjust.
16993 * linux-mips-low.c (mips_get_pc):
16994 (mips_set_pc): Change prototype to take a regcache. Adjust.
16995 (mips_reinsert_addr): Adjust.
16996 (mips_collect_register): Change prototype to take a regcache.
16997 Adjust.
16998 (mips_supply_register):
16999 (mips_collect_register_32bit, mips_supply_register_32bit)
17000 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
17001 (mips_store_fpregset): Ditto.
43aaf8b6
PA
17002 * linux-ppc-low.c (ppc_supply_ptrace_register)
17003 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
17004 (parse_spufs_run): Adjust.
17005 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
17006 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
17007 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
17008 take a regcache. Adjust.
17009 * linux-s390-low.c (s390_collect_ptrace_register)
17010 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
17011 (s390_set_pc): Change prototype to take a regcache. Adjust.
17012 (s390_arch_setup): Adjust.
17013 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
17014 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
17015 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
17016 (sparc_fill_gregset, sparc_store_gregset_from_stack)
17017 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
17018 regcache. Adjust.
17019 (sparc_breakpoint_at): Adjust.
17020 * linux-xtensa-low.c (xtensa_fill_gregset):
17021 (xtensa_store_gregset):
17022 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
17023 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
17024 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
17025 prototype to take a regcache. Adjust.
17026 * win32-arm-low.c (arm_fetch_inferior_register)
17027 (arm_store_inferior_register): Change prototype to take a
17028 regcache. Adjust.
17029 * win32-i386-low.c (i386_fetch_inferior_register)
17030 (i386_store_inferior_register): Change prototype to take a
17031 regcache. Adjust.
17032 * win32-low.c (child_fetch_inferior_registers)
17033 (child_store_inferior_registers): Change prototype to take a
17034 regcache. Adjust.
17035 (win32_wait): Adjust.
17036 (win32_fetch_inferior_registers): Change prototype to take a
17037 regcache. Adjust.
17038 (win32_store_inferior_registers): Adjust.
17039 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
17040 store_inferior_register>: Change prototype to take a regcache.
17041
60c3d7b0
DE
170422010-01-20 Doug Evans <dje@google.com>
17043
17044 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
17045 #ifdef.
17046 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 17047 (W_STOPCODE): Provide definition if missing.
60c3d7b0 17048
dc146f7c
VP
170492010-01-13 Vladimir Prus <vladimir@codesourcery.com>
17050
17051 * linux-low.c (linux_core_of_thread): New.
17052 (compare_ints, show_process, list_threads): New.
17053 (linux_qxfer_osdata): Report threads and cores.
17054 (linux_target_op): Register linux_core_of_thread.
17055 * remote-utils.c (prepare_resume_reply): Report the core.
17056 (buffer_xml_printf): Support %d specifier.
17057 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
17058 New.
17059 (handle_query): Handle qXfer:threads. Announce availability
17060 thereof.
17061 * target.h (struct target_ops): New field core_of_thread.
17062
7803799a
UW
170632010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
17064
17065 * Makefile.in (clean): Remove new generated files.
17066 (reg-s390.o, reg-s390.c): Remove rules.
17067 (reg-s390x.o, reg-s390x.c): Likewise.
17068 (s390-linux32.o, s390-linux32.c): Add rules.
17069 (s390-linux64.o, s390-linux64.c): Likewise.
17070 (s390x-linux64.o, s390x-linux64.c): Likewise.
17071 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
17072 * linux-s390-low.c: Include <elf.h>.
17073 (HWCAP_S390_HIGH_GPRS): Define if undefined.
17074 (init_registers_s390): Remove prototype.
17075 (init_registers_s390x): Likewise.
17076 (init_registers_s390_linux32): Add prototype.
17077 (init_registers_s390_linux64): Likewise.
17078 (init_registers_s390x_linux64): Likewise.
17079 (s390_num_regs_3264): New define.
17080 (s390_regmap_3264): New global variable.
17081 (s390_cannot_fetch_register): Remove obsolete check.
17082 (s390_cannot_store_register): Likewise.
17083 (s390_collect_ptrace_register): Handle upper/lower register halves.
17084 (s390_supply_ptrace_register): Likewise.
17085 (s390_fill_gregset): Update to register number changes.
17086 (s390_get_hwcap): New routine.
17087 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
17088 Install appropriate regmap and register set.
17089
6e7ffa39
JB
170902010-01-01 Joel Brobecker <brobecker@adacore.com>
17091
17092 * server.c (gdbserver_version): Update copyright year to 2010.
17093 * gdbreplay.c (gdbreplay_version): Likewise.
17094
957f3f49
DE
170952009-12-28 Doug Evans <dje@google.com>
17096
17097 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
17098 elf/external.h. Include <elf.h> instead but only if necessary.
17099
ca5c370d
PA
171002009-12-28 Pedro Alves <pedro@codesourcery.com>
17101
17102 * linux-low.c (linux_remove_process): Remove `detaching'
17103 parameter. Don't release/detach from thread_db here.
17104 (linux_kill): Release/detach from thread_db here, ...
17105 (linux_detach): ... and here, before actually detaching.
17106 (linux_wait_1): ... and here, when a process exits.
17107 * thread-db.c (any_thread_of): New.
17108 (thread_db_free): Switch the current inferior to a thread of the
17109 passed in process.
17110
4ee62156
DE
171112009-12-21 Doug Evans <dje@google.com>
17112
d90e6a88
DE
17113 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
17114
c5f62d5f
DE
17115 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
17116 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
17117 warning ifndef __NR_tkill. Move setting of errno there too.
17118 Delete unnecessary resetting of errno after syscall.
17119 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
17120
10e86dd7
DE
17121 * configure.ac: Check for dladdr.
17122 * config.in: Regenerate.
17123 * configure: Regenerate.
17124 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
17125 (try_thread_db_load): Update.
17126
4ee62156
DE
17127 * linux-low.c (my_waitpid): Delete unnecessary prototype.
17128
00f515da
DE
171292009-12-18 Doug Evans <dje@google.com>
17130
e9464885
DE
17131 * event-loop.c: Include unistd.h if it exists.
17132
07d4f67e
DE
17133 * linux-low.c (my_waitpid): Move definition away from being in
17134 between linux_tracefork_child/linux_test_for_tracefork.
17135
00f515da
DE
17136 * gdb_proc_service.h (psaddr_t): Fix type.
17137 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
17138 signature to match glibc.
17139
1de1badb
DE
171402009-12-16 Doug Evans <dje@google.com>
17141
17142 * linux-low.c (linux_read_memory): Fix argument to read.
17143
aeeb81d1
PA
171442009-11-26 Pedro Alves <pedro@codesourcery.com>
17145
17146 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
17147 events, don't leave current_inferior pointing at null.
17148
10357975
PA
171492009-11-26 Pedro Alves <pedro@codesourcery.com>
17150
17151 * win32-low.c (LOG): Delete.
17152 (OUTMSG): Output to stderr.
17153 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
17154 on compile time LOG macro.
17155 (win32_wait): Fix debug output.
17156
cf6e3471
PA
171572009-11-26 Pedro Alves <pedro@codesourcery.com>
17158
17159 * win32-low.c (win32_add_one_solib): If the dll name is
17160 "ntdll.dll", prepend the system directory to the dll path.
17161
0c85e18e
MK
171622009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
17163
17164 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
17165
9ac544ce 171662009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 17167 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
17168
17169 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
17170 * configure.ac: Check for __mcoldfire__ and set
17171 gdb_cv_m68k_is_coldfire.
17172 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
17173 reg-cf.o and reg-m68k.o.
17174 * configure: Regenerated.
17175
fd7dd3e6
PA
171762009-11-16 Pedro Alves <pedro@codesourcery.com>
17177
17178 * linux-low.c (linux_remove_process): Add `detaching' parameter.
17179 Pass it to thread_db_free.
17180 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
17181 proper `detaching' argument to linux_remove_process.
17182 * linux-low.h (thread_db_free): Add `detaching' parameter.
17183 * thread-db.c (thread_db_init): Pass false as `detaching' argument
17184 to thread_db_free.
17185 (thread_db_free): Add `detaching' parameter. Only
17186 call td_ta_clear_event if detaching from process.
17187
75aa492e
MK
171882009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
17189
17190 * thread-db.c (thread_db_free): Fix typo.
17191
21e1bee4
PP
171922009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
17193
17194 PR gdb/10838
17195 * thread-db.c (thread_db_free): Call td_ta_clear_event.
17196
8838b45e
NS
171972009-11-03 Nathan Sidwell <nathan@codesourcery.com>
17198
17199 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
17200 with an i686 compiler.
17201 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
17202 needed.
17203 * configure: Rebuilt.
17204
8a35fb51
SL
172052009-10-29 Sandra Loosemore <sandra@codesourcery.com>
17206
17207 PR gdb/10783
17208
17209 * server.c (handle_search_memory_1): Correct read_addr initialization
17210 in loop for searching subsequent chunks.
17211
96f15937
PP
172122009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
17213
17214 * configure.ac: New --with-libthread-db option.
17215 * thread-db.c: Allow direct dependence on libthread_db.
17216 (thread_db_free): Adjust.
17217 * config.in: Regenerate.
17218 * configure: Likewise.
889bf7c5 17219
5f7d1694
PP
172202009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
17221
17222 PR gdb/10757
17223 * thread-db.c (attach_thread): New function.
17224 (maybe_attach_thread): Return success/failure.
17225 (find_new_threads_callback): Adjust.
889bf7c5
PA
17226 (thread_db_find_new_threads): Loop until no new threads.
17227
88e3b899
PA
172282009-10-13 Pedro Alves <pedro@codesourcery.com>
17229
17230 * proc-service.c (ps_lgetregs): Formatting.
17231
cdbfd419
PP
172322009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
17233
17234 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
17235 * configure.ac: Adjust.
17236 * linux-low.h (struct process_info_private): Move members to struct
17237 thread_db.
17238 (thread_db_free, thread_db_handle_monitor_command): New prototype.
17239 * linux-low.c (linux_remove_process): Adjust.
17240 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
17241 * server.c (handle_query): Move code ...
17242 (handle_monitor_command): ... here. New function.
17243 * target.h (struct target_ops): New member.
17244 * thread-db.c (struct thread_db): New.
17245 (libthread_db_search_path): New variable.
17246 (thread_db_create_event, thread_db_enable_reporting)
17247 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
17248 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
17249 (try_thread_db_load_1, dladdr_to_soname): New functions.
17250 (try_thread_db_load, thread_db_load_search): New functions.
17251 (thread_db_init): Search for libthread_db.
17252 (thread_db_free): New function.
17253 (thread_db_handle_monitor_command): Likewise.
17254 * config.in: Regenerate.
17255 * configure: Regenerate.
889bf7c5 17256
4168d2d6
UW
172572009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
17258
17259 * spu-low.c (spu_kill): Wait for inferior to terminate.
17260 Call clear_inferiors.
17261 (spu_detach): Call clear_inferiors.
17262
81ecdfbb
RW
172632009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17264
17265 * aclocal.m4: Regenerate.
17266 * config.in: Likewise.
17267 * configure: Likewise.
17268
0b9ff2c0
UW
172692009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
17270
17271 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
17272 (parse_spufs_run): New function.
17273 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
17274 (ppc_breakpoint_at): Handle SPU breakpoints.
17275
efcbbd14
UW
172762009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
17277
17278 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
17279 (SPUFS_MAGIC): Define.
17280 (spu_enumerate_spu_ids): New function.
17281 (linux_qxfer_spu): New function.
17282 (linux_target_ops): Install linux_qxfer_spu.
17283
f4d9bade
UW
172842009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
17285
17286 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
17287 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
17288 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
17289 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
17290 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
17291 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
17292 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
17293 (init_registers_powerpc_cell32l): Add prototype.
17294 (init_registers_powerpc_cell64l): Likewise.
17295 (ppc_arch_setup): Detect Cell/B.E. architecture.
17296
96e946ca
RW
172972009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17298
17299 * Makefile.in (datarootdir): New variable.
17300
58d6951d
DJ
173012009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
17302
17303 * linux-low.c (linux_write_memory): Update debugging output.
17304 * Makefile.in (clean): Add new descriptions.
17305 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
17306 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
17307 * configure.srv: Add new files for arm*-*-linux*.
17308 * linux-arm-low.c: Add new declarations.
17309 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
17310 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
17311 (HWCAP_VFPv3D16): New.
17312 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
17313 instead of __IWMMXT__.
17314 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
17315 (arm_arch_setup): New.
17316 (target_regsets): Remove #ifdef. Add VFP regset.
17317 (the_low_target): Use arm_arch_setup.
17318
12b42a12
DJ
173192009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
17320
17321 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
17322 the main thread again.
17323
ac8c974e
AR
173242009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
17325
17326 Adding Neutrino gdbserver.
17327 * configure: Regenerated.
17328 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
17329 * configure.srv (i[34567]86-*-nto*): New target.
17330 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
17331 * remote-utils.c [__QNX__]: Include sys/iomgr.h
17332 (nto_comctrl) [__QNX__]: New function.
17333 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
17334
4424e0c3 173352009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
17336
17337 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
17338 srv_tgtobj.
17339
912cf4ba
PA
173402009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
17341 Pedro Alves <pedro@codesourcery.com>
17342
17343 * win32-i386-low.c (i386_get_thread_context): Handle systems that
17344 don't support CONTEXT_EXTENDED_REGISTERS.
17345 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
17346 (the_low_target): Install them.
17347 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
17348 failing with ERROR_PIPE_NOT_CONNECTED.
17349
aa5ca48f
DE
173502009-06-30 Doug Evans <dje@google.com>
17351 Pierre Muller <muller@ics.u-strasbg.fr>
17352
17353 Add h/w watchpoint support to x86-linux, win32-i386.
17354 * Makefile.in (SFILES): Add i386-low.c
17355 (i386_low_h): Define.
17356 (i386-low.o): Add dependencies.
17357 (linux-x86-low.o): Add i386-low.h dependency.
17358 (win32-i386-low.o): Ditto.
17359 * i386-low.c: New file.
17360 * i386-low.h: New file.
17361 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
17362 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
17363 * linux-low.c (linux_add_process): Initialize arch_private.
17364 (linux_remove_process): Free arch_private.
17365 (add_lwp): Initialize arch_private.
17366 (delete_lwp): Free arch_private.
17367 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
17368 provided.
17369 * linux-low.h (process_info_private): New member arch_private.
17370 (lwp_info): New member arch_private.
17371 (linux_target_ops): New members new_process, new_thread,
17372 prepare_to_resume.
17373 (ptid_of): New macro.
17374 * linux-x86-low.c: Include stddef.h, i386-low.h.
17375 (arch_process_info): New struct.
17376 (arch_lwp_info): New struct.
17377 (x86_linux_dr_get, x86_linux_dr_set): New functions.
17378 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
17379 (i386_dr_low_get_status): New function.
17380 (x86_insert_point, x86_remove_point): New functions.
17381 (x86_stopped_by_watchpoint): New function.
17382 (x86_stopped_data_address): New function.
17383 (x86_linux_new_process, x86_linux_new_thread): New functions.
17384 (x86_linux_prepare_to_resume): New function.
17385 (the_low_target): Add entries for insert_point, remove_point,
17386 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
17387 prepare_to_resume.
17388 * server.c (debug_hw_points): New global.
17389 (monitor_show_help): Document set debug-hw-points.
17390 (handle_query): Process "set debug-hw-points".
17391 * server.h (debug_hw_points): Declare.
17392 (paddress): Declare.
17393 * utils.c (NUMCELLS, CELLSIZE): New macros.
17394 (get_sell, xsnprintf, paddress): New functions.
17395 * win32-arm-low.c (the_low_target): Add entries for insert_point,
17396 remove_point, stopped_by_watchpoint, stopped_data_address.
17397 * win32-i386-low.c: Include i386-low.h.
17398 (debug_reg_state): Replaces dr.
17399 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
17400 (i386_dr_low_get_status): New function.
17401 (i386_insert_point, i386_remove_point): New functions.
17402 (i386_stopped_by_watchpoint): New function.
17403 (i386_stopped_data_address): New function.
17404 (i386_initial_stuff): Update.
17405 (get_thread_context,set_thread_context,i386_thread_added): Update.
17406 (the_low_target): Add entries for insert_point,
17407 remove_point, stopped_by_watchpoint, stopped_data_address.
17408 * win32-low.c (win32_insert_watchpoint): New function.
17409 (win32_remove_watchpoint): New function.
17410 (win32_stopped_by_watchpoint): New function.
17411 (win32_stopped_data_address): New function.
17412 (win32_target_ops): Add entries for insert_watchpoint,
17413 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
17414 * win32-low.h (win32_target_ops): New members insert_point,
17415 remove_point, stopped_by_watchpoint, stopped_data_address.
17416
d993e290
PA
174172009-06-25 Pedro Alves <pedro@codesourcery.com>
17418
17419 * server.c (process_serial_event): Re-return unsupported, not
17420 error, if the type isn't recognized. Re-allow supporting only
17421 insert or remove packets. Also call require_running for
17422 breakpoints. Add missing break statement to default case. Tidy.
17423 * target.h (struct target_ops): Rename insert_watchpoint to
17424 insert_point, and remove_watchpoint to remove_point.
17425
17426 * linux-low.h (struct linux_target_ops): Likewise.
17427 * linux-low.c (linux_insert_watchpoint): Rename to ...
17428 (linux_insert_point): ... this. Adjust.
17429 (linux_remove_watchpoint): Rename to ...
17430 (linux_remove_point): ... this. Adjust.
17431 (linux_target_ops): Adjust.
17432 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
17433 (cris_insert_point): ... this.
17434 (cris_remove_watchpoint): Rename to ...
17435 (cris_remove_point): ... this.
17436 (the_low_target): Adjust.
17437
0f54c268
PM
174382009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
17439
17440 * server.c (handle_v_kill): Pass signal_pid to
17441 kill_inferior if multi_process is zero.
17442
c6314022
AR
174432009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
17444
17445 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
17446 * target.h (target_ops): Comment for *_watchpoint to make it clear
17447 the functions can get types '0' and '1'.
17448
4463ce24
AR
174492009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
17450
17451 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
17452 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
17453 * regcache.c (get_regcache): Likewise.
17454 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
17455 * win32-low.c (child_fetch_inferior_registers): Remove check for
17456 regno 0.
17457
cf8fd78b
PA
174582009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
17459 Pedro Alves <pedro@codesourcery.com>
17460
17461 * target.h (struct target_ops) <supports_multi_process>: New
17462 callback.
17463 (target_supports_multi_process): New.
17464 * server.c (handle_query): Even if GDB reports support, only
17465 enable multi-process if the target also supports it. Report
17466 multi-process support only if the target backend supports it.
17467 * linux-low.c (linux_supports_multi_process): New function.
17468 (linux_target_ops): Install it as target_supports_multi_process
17469 callback.
17470
47c0c975
DE
174712009-05-24 Doug Evans <dje@google.com>
17472
e09875d4
DE
17473 Global renaming of find_thread_pid to find_thread_ptid.
17474 * server.h (find_thread_ptid): Renamed from find_thread_pid.
17475 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
17476 All callers updated.
17477
e27d73f6
DE
17478 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
17479 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
17480 directly.
17481
47c0c975
DE
17482 * linux-low.c (get_stop_pc): Print pc if debug_threads.
17483 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
17484 (linux_resume_one_lwp): Ditto.
17485
2acc282a
DE
174862009-05-23 Doug Evans <dje@google.com>
17487
17488 * linux-low.c (linux_resume_one_lwp): Change type of first arg
17489 from struct inferior_list_entry * to struct lwp_info *.
17490 All callers updated.
17491
9f1036c1
DE
174922009-05-13 Doug Evans <dje@google.com>
17493
17494 * linux-x86-low.c: Don't include assert.h.
17495 (x86_siginfo_fixup): Use fatal, not assert.
17496 (x86_arch_setup): Fix comment.
17497
d0722149
DE
174982009-05-12 Doug Evans <dje@google.com>
17499
17500 Biarch support for i386/amd64 gdbserver.
17501 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
17502 Add linux-x86-low.c.
17503 (linux-i386-low.o, linux-x86-64-low.o): Delete.
17504 (linux-x86-low.o): Add.
17505 * linux-x86-64-low.c: Delete.
17506 * linux-i386-low.c: Delete.
17507 * linux-x86-low.c: New file.
17508 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
17509 linux-x86-low.o.
17510 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
17511 linux-x86-low.o.
17512 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
17513 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
17514 (linux_child_pid_to_exec_file): New function.
17515 (elf_64_header_p, elf_64_file_p): New functions.
17516 (siginfo_fixup): New function.
17517 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
17518 give target a chance to convert layout.
17519 * linux-low.h (linux_target_ops): New member siginfo_fixup.
17520 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
17521
fdeb2a12
DE
175222009-05-07 Doug Evans <dje@google.com>
17523
17524 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
17525 (regsets_store_inferior_registers): Ditto.
17526
a6dbe5df
PA
175272009-05-06 Pedro Alves <pedro@codesourcery.com>
17528
17529 PR server/10048
17530
17531 * linux-low.c (must_set_ptrace_flags): Delete.
17532 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
17533 of the global.
17534 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
17535 `lwp->must_set_ptrace_flags' instead.
ba42693b 17536 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
17537 (linux_wait_1): ... not here.
17538
5091eb23
DE
175392009-04-30 Doug Evans <dje@google.com>
17540
9f767825
DE
17541 * inferiors.c (started_inferior_callback): New function.
17542 (attached_inferior_callback): New function.
17543 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
17544 * server.c (print_started_pid, print_attached_pid): New functions.
17545 (detach_or_kill_for_exit): New function.
17546 (main): Call it instead of for_each_inferior (kill_inferior_callback).
17547 * server.h (have_started_inferiors_p): Declare.
17548 (have_attached_inferiors_p): Declare.
17549
5091eb23
DE
17550 * inferiors.c (remove_process): Fix memory leak, free process.
17551 * linux-low.c (linux_remove_process): New function.
17552 (linux_kill): Call it instead of remove_process.
17553 (linux_detach, linux_wait_1): Ditto.
17554
155c8968
PA
175552009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
17556
17557 * configure.srv: Add x86 Windows CE target.
17558
7fe519cb
UW
175592009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
17560
17561 * inferiors.c (get_thread_process): Make global.
17562 * server.h (get_thread_process): Add prototype.
17563 * thread-db.c (find_one_thread): Use get_thread_process
17564 instead of current_process.
17565 (thread_db_get_tls_address): Do not crash if called when
17566 thread layer is not yet initialized.
17567
5472f405
UW
175682009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
17569
17570 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
17571 * spu-low.c (current_tid): Rename to ...
17572 (current_ptid): ... this.
17573 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
17574 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
17575 ptid_get_lwp (current_ptid) instead of current_tid.
17576 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
17577 instead of current_tid. Use find_process_pid to verify pid
17578 argument is valid. Pass proper argument to remove_process.
17579 (spu_thread_alive): Compare current_ptid instead of current_tid.
17580 (spu_resume): Likewise.
17581
55ac2b99
PA
175822009-04-02 Pedro Alves <pedro@codesourcery.com>
17583
17584 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
17585 variable.
17586
95954743
PA
175872009-04-01 Pedro Alves <pedro@codesourcery.com>
17588
17589 Implement the multiprocess extensions, and add linux multiprocess
17590 support.
17591
17592 * server.h (ULONGEST): Declare.
17593 (struct ptid, ptid_t): New.
17594 (minus_one_ptid, null_ptid): Declare.
17595 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
17596 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
17597 (struct inferior_list_entry): Change `id' type from unsigned from
17598 to ptid_t.
17599 (struct sym_cache, struct breakpoint, struct
17600 process_info_private): Forward declare.
17601 (struct process_info): Declare.
17602 (current_process): Declare.
17603 (all_processes): Declare.
17604 (initialize_inferiors): Declare.
17605 (add_thread): Adjust to use ptid_t.
17606 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
17607 (add_process, remove_process, find_thread_pid): Declare.
17608 (find_inferior_id): Adjust to use ptid_t.
17609 (cont_thread, general_thread, step_thread): Change type to ptid_t.
17610 (multi_process): Declare.
17611 (push_event): Adjust to use ptid_t.
17612 (read_ptid, write_ptid): Declare.
17613 (prepare_resume_reply): Adjust to use ptid_t.
17614 (clear_symbol_cache): Declare.
17615 * inferiors.c (all_processes): New.
17616 (null_ptid, minus_one_ptid): New.
17617 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
17618 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
17619 (add_thread): Change unsigned long to ptid. Remove gdb_id
17620 parameter. Adjust.
17621 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
17622 (gdb_id_to_thread): Rename to ...
17623 (find_thread_pid): ... this. Change unsigned long to ptid.
17624 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
17625 (loaded_dll, pull_pid_from_list): Adjust.
17626 (add_process, remove_process, find_process_pid)
17627 (get_thread_process, current_process, initialize_inferiors): New.
17628 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
17629 (struct target_waitstatus) <related_pid>: Ditto.
17630 (struct target_ops) <kill, detach>: Add `pid' argument. Change
17631 return type to int.
17632 (struct target_ops) <join>: Add `pid' argument.
17633 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
17634 (struct target_ops) <wait>: Add `ptid' field. Change return type
17635 to ptid.
17636 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
17637 (mywait): Add `ptid' argument. Change return type to ptid_t.
17638 (target_pid_to_str): Declare.
17639 * target.c (set_desired_inferior): Adjust to use ptids.
17640 (mywait): Add new `ptid' argument. Adjust.
17641 (target_pid_to_str): New.
17642 * mem-break.h (free_all_breakpoints): Declare.
17643 * mem-break.c (breakpoints): Delelete.
17644 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
17645 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
17646 to use per-process breakpoint list.
17647 (free_all_breakpoints): New.
17648 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
17649 (symbol_cache, all_symbols_looked_up): Delete.
17650 (hexchars): New.
17651 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
17652 read_ptid): New.
17653 (prepare_resume_reply): Change ptid argument's type from unsigned
17654 long to ptid_t. Adjust. Implement W;process and X;process.
17655 (free_sym_cache, clear_symbol_cache): New.
17656 (look_up_one_symbol): Adjust to per-process symbol cache. *
17657 * server.c (cont_thread, general_thread, step_thread): Change type
17658 to ptid_t.
17659 (attached): Delete.
17660 (multi_process): New.
17661 (last_ptid): Change type to ptid_t.
17662 (struct vstop_notif) <ptid>: Change type to ptid_t.
17663 (queue_stop_reply, push_event): Change `ptid' argument's type to
17664 ptid_t.
17665 (discard_queued_stop_replies): Add `pid' argument.
17666 (start_inferior): Adjust to use ptids. Adjust to mywait interface
17667 changes. Don't reference the `attached' global.
17668 (attach_inferior): Adjust to mywait interface changes.
17669 (handle_query): Adjust to use ptids. Parse GDB's qSupported
17670 features. Handle and report "multiprocess+". Handle
17671 "qAttached:PID".
17672 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
17673 changes.
17674 (handle_v_kill): New.
17675 (handle_v_stopped): Adjust to use target_pid_to_str.
17676 (handle_v_requests): Allow multiple attaches and runs when
17677 multiprocess extensions are in effect. Handle "vKill".
17678 (myresume): Adjust to use ptids.
17679 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
17680 (handle_status): Adjust to discard_queued_stop_replies interface
17681 change.
17682 (first_thread_of, kill_inferior_callback)
17683 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
17684 (main): Call initialize_inferiors. Adjust to use ptids, killing
17685 and detaching from all inferiors. Handle multiprocess packet
17686 variants.
17687 * linux-low.h: Include gdb_proc_service.h.
17688 (struct process_info_private): New.
17689 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
17690 <lwpid_of>: Use ptid_get_lwp.
17691 (get_lwp_thread): Adjust.
17692 (struct lwp_info): Add `dead' member.
17693 (find_lwp_pid): Declare.
17694 * linux-low.c (thread_db_active): Delete.
17695 (new_inferior): Adjust comment.
17696 (inferior_pid): Delete.
17697 (linux_add_process): New.
17698 (handle_extended_wait): Adjust.
17699 (add_lwp): Change unsigned long to ptid.
17700 (linux_create_inferior): Add process to processes table. Adjust
17701 to use ptids. Don't set new_inferior here.
17702 (linux_attach_lwp): Rename to ...
17703 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
17704 it. Adjust to use ptids.
17705 (linux_attach_lwp): New.
17706 (linux_attach): Add process to processes table. Don't set
17707 new_inferior here.
17708 (struct counter): New.
17709 (second_thread_of_pid_p, last_thread_of_process_p): New.
17710 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
17711 multiple processes.
17712 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
17713 processes. Remove process from process table.
17714 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
17715 to multiple processes.
17716 (any_thread_of): New.
17717 (linux_detach): Add `pid' argument, and handle it. Remove process
17718 from processes table.
17719 (linux_join): Add `pid' argument. Handle it.
17720 (linux_thread_alive): Change unsighed long argument to ptid_t.
17721 Consider dead lwps as not being alive.
17722 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
17723 threads we're not interested in.
17724 (same_lwp, find_lwp_pid): New.
17725 (linux_wait_for_lwp): Change `pid' argument's type from int to
17726 ptid_t. Adjust.
17727 (linux_wait_for_event): Rename to ...
17728 (linux_wait_for_event_1): ... this. Change `pid' argument's type
17729 from int to ptid_t. Adjust.
17730 (linux_wait_for_event): New.
17731 (linux_wait_1): Add `ptid' argument. Change return type to
17732 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
17733 that exit from the process table.
17734 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
17735 Adjust.
17736 (mark_lwp_dead): New.
17737 (wait_for_sigstop): Adjust to use ptids. If a process exits while
17738 stopping all threads, mark its main lwp as dead.
17739 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
17740 ptids.
17741 (fetch_register, usr_store_inferior_registers)
17742 (regsets_fetch_inferior_registers)
17743 (regsets_store_inferior_registers, linux_read_memory)
17744 (linux_write_memory): Inline `inferior_pid'.
17745 (linux_look_up_symbols): Adjust to use per-process
17746 `thread_db_active'.
17747 (linux_request_interrupt): Adjust to use ptids.
17748 (linux_read_auxv): Inline `inferior_pid'.
17749 (initialize_low): Don't reference thread_db_active.
17750 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
17751 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
17752 (ps_getpid): Return the pid of the current inferior.
17753 * thread-db.c (proc_handle, thread_agent): Delete.
17754 (thread_db_create_event, thread_db_enable_reporting): Adjust to
17755 per-process data.
17756 (find_one_thread): Change argument type to ptid_t. Adjust to
17757 per-process data.
17758 (maybe_attach_thread): Adjust to per-process data and ptids.
17759 (thread_db_find_new_threads): Ditto.
17760 (thread_db_init): Ditto.
17761 * spu-low.c (spu_create_inferior, spu_attach): Add process to
17762 processes table. Adjust to use ptids.
17763 (spu_kill, spu_detach): Adjust interface. Remove process from
17764 processes table.
17765 (spu_join, spu_thread_alive): Adjust interface.
17766 (spu_wait): Adjust interface. Remove process from processes
17767 table. Adjust to use ptids.
17768 * win32-low.c (current_inferior_tid): Delete.
17769 (current_inferior_ptid): New.
17770 (debug_event_ptid): New.
17771 (thread_rec): Take a ptid. Adjust.
17772 (child_add_thread): Add `pid' argument. Adjust to use ptids.
17773 (child_delete_thread): Ditto.
17774 (do_initial_child_stuff): Add `attached' argument. Add process to
17775 processes table.
17776 (child_fetch_inferior_registers, child_store_inferior_registers):
17777 Adjust.
17778 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
17779 (win32_attach): Pass 1 to do_initial_child_stuff.
17780 (win32_kill): Adjust interface. Remove process from processes
17781 table.
17782 (win32_detach): Ditto.
17783 (win32_join): Adjust interface.
17784 (win32_thread_alive): Take a ptid.
17785 (win32_resume): Adjust to use ptids.
17786 (get_child_debug_event): Ditto.
17787 (win32_wait): Adjust interface. Remove exiting process from
17788 processes table.
17789
bd99dc85
PA
177902009-04-01 Pedro Alves <pedro@codesourcery.com>
17791
17792 Non-stop mode support.
17793
17794 * server.h (non_stop): Declare.
17795 (gdb_client_data, handler_func): Declare.
17796 (delete_file_handler, add_file_handler, start_event_loop):
17797 Declare.
17798 (handle_serial_event, handle_target_event, push_event)
17799 (putpkt_notif): Declare.
17800 * target.h (enum resume_kind): New.
17801 (struct thread_resume): Replace `step' field by `kind' field.
17802 (TARGET_WNOHANG): Define.
17803 (struct target_ops) <wait>: Add `options' argument.
17804 <supports_non_stop, async, start_non_stop>: New fields.
17805 (target_supports_non_stop, target_async): New.
17806 (start_non_stop): Declare.
17807 (mywait): Add `options' argument.
17808 * target.c (mywait): Add `options' argument. Print child exit
17809 notifications here.
17810 (start_non_stop): New.
17811 * server.c (non_stop, own_buf, mem_buf): New globals.
17812 (struct vstop_notif): New.
17813 (notif_queue): New global.
17814 (queue_stop_reply, push_event, discard_queued_stop_replies)
17815 (send_next_stop_reply): New.
17816 (start_inferior): Adjust to use resume_kind. Adjust to mywait
17817 interface changes.
17818 (attach_inferior): In non-stop mode, don't wait for the target
17819 here.
17820 (handle_general_set): Handle QNonStop.
17821 (handle_query): When handling qC, return the current general
17822 thread, instead of the first thread of the list.
17823 (handle_query): If the backend supports non-stop mode, include
17824 QNonStop+ in the qSupported query response.
17825 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
17826 and non-stop mode.
17827 (handle_v_attach, handle_v_run): Handle non-stop mode.
17828 (handle_v_stopped): New.
17829 (handle_v_requests): Report support for vCont;t. Handle vStopped.
17830 (myresume): Adjust to use resume_kind. Handle non-stop.
17831 (queue_stop_reply_callback): New.
17832 (handle_status): Handle non-stop mode.
17833 (main): Clear non_stop flag on reconnection. Use the event-loop.
17834 Refactor serial protocol handling from here ...
17835 (process_serial_event): ... to this new function. When GDB
17836 selects any thread, select one here. In non-stop mode, wait until
17837 GDB acks all pending events before exiting.
17838 (handle_serial_event, handle_target_event): New.
17839 * remote-utils.c (remote_open): Install remote_desc in the event
17840 loop.
17841 (remote_close): Remove remote_desc from the event loop.
17842 (putpkt_binary): Rename to...
17843 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
17844 (putpkt_binary): New as wrapper around putpkt_binary_1.
17845 (putpkt_notif): New.
17846 (prepare_resume_reply): In non-stop mode, don't change the
17847 general_thread.
17848 * event-loop.c: New.
17849 * Makefile.in (OBJ): Add event-loop.o.
17850 (event-loop.o): New rule.
17851
17852 * linux-low.h (pid_of): Moved here.
17853 (lwpid_of): New.
17854 (get_lwp_thread): Use lwpid_of.
17855 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
17856 * linux-low.c (pid_of): Delete.
17857 (inferior_pid): Use lwpid_of.
17858 (linux_event_pipe): New.
17859 (target_is_async_p): New.
17860 (delete_lwp): New.
17861 (handle_extended_wait): Use lwpid_of.
17862 (add_lwp): Don't set lwpid field.
17863 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
17864 (linux_kill_one_lwp): If killing a running lwp, stop it first.
17865 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
17866 (linux_detach_one_lwp): If detaching from a running lwp, stop it
17867 first. Adjust to linux_wait_for_event interface changes. Use
17868 lwpid_of.
17869 (linux_detach): Don't delete the main lwp here.
17870 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
17871 (status_pending_p): Don't consider explicitly suspended lwps.
17872 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
17873 pointer. Add OPTIONS argument. Change return type to int. Use
17874 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
17875 (linux_wait_for_event): Take an integer pid instead of a lwp_info
17876 pointer. Add status pointer argument. Return a pid instead of a
17877 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
17878 changes. In non-stop mode, don't switch to a random thread.
17879 (linux_wait): Rename to...
17880 (linux_wait_1): ... this. Add target_options argument, and handle
17881 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
17882 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
17883 clean exit and signal exit code. Don't stop all threads in
17884 non-stop mode. In all-stop mode, only stop all threads when
17885 reporting a stop to GDB. Handle explicit thread stop requests.
17886 (async_file_flush, async_file_mark): New.
17887 (linux_wait): New.
17888 (send_sigstop): Use lwpid_of.
17889 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
17890 interface changes. In non-stop mode, don't switch to a random
17891 thread.
17892 (linux_resume_one_lwp): Use lwpid_of.
17893 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
17894 (linux_resume_one_thread): ... this. Handle resume_stop. In
17895 non-stop mode, don't look for pending flag in all threads.
17896 (resume_status_pending_p): Don't consider explicitly suspended
17897 threads.
17898 (my_waitpid): Reimplement. Emulate __WALL.
17899 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17900 Use lwpid_of.
17901 (sigchld_handler, linux_supports_non_stop, linux_async)
17902 (linux_start_non_stop): New.
17903 (linux_target_ops): Register linux_supports_non_stop, linux_async
17904 and linux_start_non_stop.
17905 (initialize_low): Install SIGCHLD handler.
17906 * thread-db.c (thread_db_create_event, find_one_thread)
17907 (thread_db_get_tls_address): Use lwpid_of.
17908 * win32-low.c (win32_detach): Adjust to use resume_kind.
17909 (win32_wait): Add `options' argument.
17910 * spu-low.c (spu_resume): Adjust to use resume_kind.
17911 (spu_wait): Add `options' argument.
17912
5b1c542e
PA
179132009-04-01 Pedro Alves <pedro@codesourcery.com>
17914
17915 Decouple target code from remote protocol.
17916
17917 * target.h (enum target_waitkind): New.
17918 (struct target_waitstatus): New.
17919 (struct target_ops) <wait>: Return an unsigned long. Take a
17920 target_waitstatus pointer instead of a char pointer.
17921 (mywait): Likewise.
17922 * target.c (mywait): Change prototype to return an unsigned long.
17923 Take a target_waitstatus pointer instead of a char pointer. Adjust.
17924 * server.h (thread_from_wait, old_thread_from_wait): Delete
17925 declarations.
17926 (prepare_resume_reply): Change prototype to take a
17927 target_waitstatus.
17928 * server.c (thread_from_wait, old_thread_from_wait): Delete.
17929 (last_status, last_ptid): New.
17930 (start_inferior): Remove "statusptr" argument. Adjust. Return a
17931 pid instead of a signal.
17932 (attach_inferior): Remove "status" and "signal" parameters.
17933 Adjust.
17934 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
17935 not as an address.
17936 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
17937 (handle_v_requests, myresume): Remove "status" and "signal"
17938 parameters. Adjust.
17939 (handle_status): New.
17940 (main): Delete local `status'. Adjust.
17941 * remote-utils.c: Include target.h.
17942 (prepare_resume_reply): Change prototype to take a
17943 target_waitstatus. Adjust.
17944
17945 * linux-low.c (linux_wait): Adjust to new target_ops->wait
17946 interface.
17947 * spu-low.c (spu_wait): Adjust.
17948 * win32-low.c (enum target_waitkind, struct target_waitstatus):
17949 Delete.
17950 (win32_wait): Adjust.
17951
2bd7c093
PA
179522009-04-01 Pedro Alves <pedro@codesourcery.com>
17953
17954 * target.h (struct thread_resume): Delete leave_stopped member.
17955 (struct target_ops): Add a `n' argument to the `resume' callback.
17956 * server.c (start_inferior): Adjust.
17957 (handle_v_cont, myresume): Adjust.
17958 * linux-low.c (check_removed_breakpoint): Adjust to resume
17959 interface change, and to removed leave_stopped field.
17960 (resume_ptr): Delete.
17961 (struct thread_resume_array): New.
17962 (linux_set_resume_request): Add new `arg' parameter. Adjust to
17963 resume interface change.
17964 (linux_continue_one_thread, linux_queue_one_thread)
17965 (resume_status_pending_p): Check if the resume field is NULL
17966 instead of checking the leave_stopped member.
17967 (linux_resume): Adjust to the target resume interface change.
17968 * spu-low.c (spu_resume): Adjust to the target resume interface
17969 change.
17970 * win32-low.c (win32_detach, win32_resume): Ditto.
17971
c35fafde
PA
179722009-04-01 Pedro Alves <pedro@codesourcery.com>
17973
17974 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
17975 flag.
17976 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
17977 pending.
17978 (linux_continue_one_thread): Only preserve the stepping flag if
17979 there's a pending breakpoint.
17980
0a59d50b
PA
179812009-03-31 Pedro Alves <pedro@codesourcery.com>
17982
17983 * server.c (main): After the inferior having exited, call
17984 remote_close before exiting gdbserver.
17985
f04c6d38
TJB
179862009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
17987
17988 Fix size of FPSCR in Power 7 processors.
17989 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
17990 (PPC_FEATURE_HAS_DFP): New #define.
17991 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
17992 size of the FPSCR.
17993
78e5cee6
PA
179942009-03-23 Pedro Alves <pedro@codesourcery.com>
17995
17996 * server.c (handle_query) Whitespace and formatting.
17997
1b3f6016
PA
179982009-03-22 Pedro Alves <pedro@codesourcery.com>
17999
18000 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
18001 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
18002 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
18003 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
18004 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
18005 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
18006 Makefile.in, configure.ac: Fix whitespace throughout.
18007 * configure: Regenerate.
18008
a07b2135
PA
180092009-03-22 Pedro Alves <pedro@codesourcery.com>
18010
18011 * inferiors.c (find_inferior): Make it safe for the callback
18012 function to delete the currently iterated inferior.
18013
67cc2626
PA
180142009-03-22 Pedro Alves <pedro@codesourcery.com>
18015
18016 * Makefile.in (linuw_low_h): Move higher.
18017 (thread-db.o): Depend on $(linux_low_h).
18018
54a0b537
PA
180192009-03-17 Pedro Alves <pedro@codesourcery.com>
18020
18021 Rename "process" to "lwp" throughout.
18022
18023 * linux-low.c (all_processes): Rename to...
18024 (all_lwps): ... this.
18025 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
18026 (add_process): Rename to ...
18027 (add_lwp): ... this. Adjust.
18028 (linux_create_inferior): Adjust.
18029 (linux_attach_lwp): Adjust.
18030 (linux_attach): Adjust.
18031 (linux_kill_one_process): Rename to ...
18032 (linux_kill_one_lwp): ... this. Adjust.
18033 (linux_kill): Adjust.
18034 (linux_detach_one_process): Rename to ...
18035 (linux_detach_one_lwp): ... this. Adjust.
18036 (linux_detach): Adjust.
18037 (check_removed_breakpoint): Adjust.
18038 (status_pending_p): Adjust.
18039 (linux_wait_for_process): Rename to ...
18040 (linux_wait_for_lwp): ... this. Adjust.
18041 (linux_wait_for_event): Adjust.
18042 (send_sigstop): Adjust.
18043 (wait_for_sigstop): Adjust.
18044 (stop_all_processes): Rename to ...
18045 (stop_all_lwps): ... this.
18046 (linux_resume_one_process): Rename to ...
18047 (linux_resume_one_lwp): ... this. Adjust.
18048 (linux_set_resume_request, linux_continue_one_thread)
18049 (linux_queue_one_thread, resume_status_pending_p)
18050 (usr_store_inferior_registers, regsets_store_inferior_registers)
18051 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
18052 Adjust.
18053 * linux-low.h (get_process): Rename to ...
18054 (get_lwp): ... this. Adjust.
18055 (get_thread_process): Rename to ...
18056 (get_thread_lwp): ... this. Adjust.
18057 (get_process_thread): Rename to ...
18058 (get_lwp_thread): ... this. Adjust.
18059 (struct process_info): Rename to ...
18060 (struct lwp_info): ... this.
18061 (all_processes): Rename to ...
18062 (all_lwps): ... this.
18063 * proc-service.c (ps_lgetregs): Adjust.
18064 * thread-db.c (thread_db_create_event, find_one_thread)
18065 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
18066
0b16c5cf
PA
180672009-03-14 Pedro Alves <pedro@codesourcery.com>
18068
18069 * server.c (handle_query): Handle "qAttached".
18070
32de4b9d
NS
180712009-03-13 Nathan Sidwell <nathan@codesourcery.com>
18072
18073 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
18074 GPLv3, update license URL.
18075
2aecd87f
DE
180762009-03-01 Doug Evans <dje@google.com>
18077
93efd302 18078 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
18079 (server_h): Add gdb_signals.h.
18080 (signals.o): Update.
18081 * server.h (target_signal_from_host,target_signal_to_host_p)
18082 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
18083
86b1f9c5
PM
180842009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
18085
18086 * remote-utils.c (getpkt): Also generate remote-debug
18087 information if noack_mode is set.
18088
4aa995e1
PA
180892009-02-06 Pedro Alves <pedro@codesourcery.com>
18090
18091 * server.c (handle_query): Report qXfer:siginfo:read and
18092 qXfer:siginfo:write as supported and handle them.
18093 * target.h (struct target_ops) <qxfer_siginfo>: New field.
18094 * linux-low.c (linux_xfer_siginfo): New.
18095 (linux_target_ops): Set it.
18096
62709adf
PA
180972009-01-26 Pedro Alves <pedro@codesourcery.com>
18098
18099 * server.c (gdbserver_usage): Mention --remote-debug.
18100 (main): Accept '--remote-debug' switch.
18101
aef93bd7
DE
181022009-01-18 Doug Evans <dje@google.com>
18103
18104 * regcache.c (new_register_cache): No need to check result of xcalloc.
18105 * server.c (handle_search_memory): Back out calls to xmalloc,
18106 result is checked and error is returned to user upon failure.
18107 (handle_query): Ditto. Add more checks for result of malloc.
18108 (handle_v_cont): Check result of malloc, report error back to
18109 user upon failure.
18110 (handle_v_run): Ditto. Call freeargv.
18111 * server.h (freeargv): Declare.
18112 * utils.c (freeargv): New fn.
18113
54363045
DE
181142009-01-15 Doug Evans <dje@google.com>
18115
f626972c
DE
18116 * gdbreplay.c (perror_with_name): Make arg const char *.
18117 * server.h (target_signal_to_name): Make return type const char *.
0842e787 18118 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 18119 * utils.c (perror_with_name): Make arg const char *.
54363045 18120
18aae699
PA
181212009-01-14 Pedro Alves <pedro@codesourcery.com>
18122
18123 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
18124 when handling a EXIT_PROCESS_DEBUG_EVENT.
18125
ff703abe
JB
181262009-01-06 Joel Brobecker <brobecker@adacore.com>
18127
18128 * gdbreplay.c (gdbreplay_version): Update copyright year.
18129 * server.c (gdbserver_version): Likewise.
18130
f21cc1a2 181312009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
18132
18133 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 18134 (handle_extended_wait): Improve comment.
0e21c1ec 18135
bca929d3
DE
181362008-12-13 Doug Evans <dje@google.com>
18137
18138 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
18139 * server.h (ATTR_MALLOC): New macro.
18140 (xmalloc,xcalloc,xstrdup): Declare.
18141 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
18142 * inferiors.c: Ditto.
18143 * linux-low.c: Ditto.
18144 * mem-break.c: Ditto.
18145 * regcache.c: Ditto.
18146 * remote-utils.c: Ditto.
18147 * server.c: Ditto.
18148 * target.c: Ditto.
18149 * win32-low.c: Ditto.
18150
97438e3f
DE
181512008-12-12 Doug Evans <dje@google.com>
18152
896c7fbb
DE
18153 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
18154 in debugging printf.
18155
97438e3f
DE
18156 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
18157
e3b886f8
DE
181582008-12-09 Doug Evans <dje@google.com>
18159
18160 * linux-low.h (struct process_info): Delete member tid, unused.
18161 * thread-db.c (find_one_thread): Update.
18162 (maybe_attach_thread): Update.
18163
07e059b5
VP
181642008-12-02 Pedro Alves <pedro@codesourcery.com>
18165
889bf7c5
PA
18166 * target.h (struct target_ops): Add qxfer_osdata member.
18167 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
18168 and dirent.h.
18169 (linux_qxfer_osdata): New functions.
18170 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
18171 callback.
18172 * server.c (handle_query): Handle "qXfer:osdata:read:".
18173 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
18174 (buffer_xml_printf): New functions.
18175 * server.h (struct buffer): New.
18176 (buffer_grow_str, buffer_grow_str0): New macros.
18177 (buffer_grow, buffer_free, buffer_init, buffer_finish)
18178 (buffer_xml_printf): Declare.
07e059b5 18179
4cab47ab
DE
181802008-11-24 Doug Evans <dje@google.com>
18181
18182 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
18183
f142445f
DJ
181842008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
18185
18186 * server.c (handle_v_run): Always use the supplied argument list.
18187
d0107bb6 181882008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 18189
d0107bb6
BW
18190 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
18191 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 18192
2c4ad781
TJB
181932008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
18194
18195 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
18196 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
18197 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
18198 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
18199 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
18200 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
18201 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
18202 XML target descriptions.
18203 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
18204 when inferior is running on an ISA 2.05 or later processor. Add
18205 special case to return offset for full 64-bit slot of FPSCR when
18206 in 32-bits.
18207
dfb64f85
DJ
182082008-11-14 Daniel Gutson <dgutson@codesourcery.com>
18209
18210 * Makefile.in (SFILES, clean): Added sparc64 files.
18211 (reg-sparc64.o, reg-sparc64.c): New.
18212 * configure.srv (sparc*-*-linux*): New configuration.
18213 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
18214 syscall arguments for SPARC.
18215 (regsets_store_inferior_registers): Likewise.
18216 * linux-sparc-low.c: New file.
18217
66b6e1dd
DE
182182008-10-21 Doug Evans <dje@google.com>
18219
18220 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
18221 (READLINE_DIR,READLINE_DEP): Delete.
18222 (INTERNAL_CFLAGS): Update.
18223 (LINTFLAGS): Update.
18224
9b710a42
PA
182252008-10-10 Pedro Alves <pedro@codesourcery.com>
18226
18227 * server.c (handle_v_run): If GDB didn't specify an argv, use the
18228 whole argv from the last run, not just argv[0].
18229
5822d809
PA
182302008-09-08 Pedro Alves <pedro@codesourcery.com>
18231
18232 * regcache.c (new_register_cache): Return NULL if the register
18233 cache size isn't known yet.
18234 (free_register_cache): Avoid dereferencing a NULL regcache.
18235
74aac56f
DJ
182362008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18237
18238 * configure.srv: Merge MIPS and MIPS64.
18239
400b20f5
MR
182402008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
18241
18242 * Makefile.in (uninstall): Apply $(EXEEXT) too.
18243
677c5bb1
LM
182442008-08-18 Luis Machado <luisgpm@br.ibm.com>
18245
18246 * Makefile.in: Add required vsx dependencies.
18247
18248 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
18249 Declare init_registers_powerpc_vsx32l.
18250 Declare init_registers_powerpc_vsx64l.
18251 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
18252 (ppc_arch_setup): Check for VSX in hwcap.
18253 (ppc_fill_vsxregset): New function.
18254 (ppc_store_vsxregset): New function.
18255 Add new VSX entry in regset_info target_regsets.
18256
18257 * configure.srv: Add new VSX dependencies.
18258
a6f3e723
SL
182592008-08-12 Pedro Alves <pedro@codesourcery.com>
18260
18261 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
18262 (remote_open): Set or clear transport_is_reliable.
18263 (putpkt_binary): Don't expect acks in noack mode.
18264 (getpkt): Don't send ack/nac in noack mode.
18265 * server.c (handle_general_set): Handle QStartNoAckMode.
18266 (handle_query): If connected by tcp pass QStartNoAckMode+ in
18267 qSupported.
18268 (main): Reset noack_mode on every connection.
18269 * server.h (noack_mode): Declare.
18270
a417dc56
RW
182712008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18272
18273 * Makefile.in (GDBREPLAY_OBS): New variable.
18274 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
18275
3221518c
UW
182762008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
18277 Daniel Jacobowitz <dan@codesourcery.com>
18278
18279 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
18280 (usr_store_inferior_registers): Likewise.
18281 (regsets_store_inferior_registers): Likewise.
18282
ec56be1b
PA
182832008-07-31 Rolf Jansen <rj@surtec.com>
18284 Pedro Alves <pedro@codesourcery.com>
18285
18286 * configure.ac: Check for memmem declaration.
18287 * server.c [HAVE_MALLOC_H]: Include malloc.h.
18288 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
18289 (disable_packet_qfThreadInfo): Unconditionally compile.
18290 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
18291 * configure, config.in: Regenerate.
18292
2fe5e3ff
DE
182932008-07-28 Doug Kwan <dougkwan@google.com>
18294
18295 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
18296 (linux_write_memory): Remove declaration of errno.
18297
836acd6d
UW
182982008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
18299
18300 * linux-low.c (handle_extended_wait): Do not use "status"
18301 variable uninitialized.
18302
aeba519e
PA
183032008-07-07 Pedro Alves <pedro@codesourcery.com>
18304
18305 * server.c (handle_v_attach): Inhibit reporting dll changes.
18306
db42f210
PA
183072008-06-27 Pedro Alves <pedro@codesourcery.com>
18308
18309 * remote-utils.c (prepare_resume_reply): If requested, don't
18310 output "thread:TID" in the T stop reply.
18311
18312 * server.c (disable_packet_vCont, disable_packet_Tthread)
18313 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
18314 (handle_query): If requested, disable support for qC, qfThreadInfo
18315 and qsThreadInfo.
18316 (handle_v_requests): If requested, disable support for vCont.
18317 (gdbserver_show_disableable): New.
18318 (main): Handle --disable-packet and --disable-packet=LIST.
18319
18320 * server.h (disable_packet_vCont, disable_packet_Tthread)
18321 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
18322
8e4c5421
CD
183232008-06-20 Carlos O'Donell <carlos@codesourcery.com>
18324
18325 * server.c (gdbserver_usage): Mention --version.
18326
6e23a804
DJ
183272008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
18328
18329 * Makefile.in (gdbreplay.o): New rule.
18330
90aa6a40
JM
183312008-06-06 Joseph Myers <joseph@codesourcery.com>
18332
18333 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
18334 message, not gdbserver.
18335
c16158bc 183362008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
18337 Nathan Sidwell <nathan@codesourcery.com>
18338 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
18339
18340 * acinclude.m4: Include ../../config/acx.m4.
18341 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
18342 * configure, config.in: Regenerate.
18343 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
18344 * server.c (gdbserver_version): Print PKGVERSION.
18345 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
18346 (main): Adjust gdbserver_usage calls.
18347 * gdbreplay.c (version, host_name): Add declarations.
18348 (gdbreplay_version, gdbreplay_usage): New.
18349 (main): Accept --version and --help options.
18350
aeb75bf5
DJ
183512008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
18352
18353 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
18354 (arm_breakpoint_at): Handle Thumb.
18355 (the_low_target): Add comment.
18356
76b233dd
UW
183572008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
18358
18359 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
18360
08388c79
DE
183612008-05-09 Doug Evans <dje@google.com>
18362
a3c83fae
DE
18363 * server.h (decode_search_memory_packet): Declare.
18364 * remote-utils.c (decode_search_memory_packet): New fn.
18365 * server.c (handle_search_memory_1): New fn.
08388c79
DE
18366 (handle_search_memory): New fn.
18367 (handle_query): Process qSearch:memory packets.
18368
bb9c3d36
UW
183692008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
18370
18371 * regcache.c (registers_length): Remove.
18372 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
18373 full register packet.
18374 * regcache.h (registers_length): Remove prototype.
18375 * server.h (PBUFSIZ): Define to 16384.
18376
7284e1be
UW
183772008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
18378
18379 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
18380 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
18381 powerpc-64l.o, and powerpc-altivec64l.o.
18382 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
18383 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
18384 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
18385 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
18386 rs6000/power-linux.xml, and rs6000/power64-linux.xml
18387 to srv_xmlfiles.
18388
18389 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
18390 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
18391 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
18392 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
18393 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
18394 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
18395 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
18396 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
18397 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
18398 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
18399 (clean): Update.
18400
18401 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
18402 (init_registers_powerpc_32l): ... this new prototype.
18403 (init_registers_powerpc_32): Remove, replace by ...
18404 (init_registers_powerpc_altivec32l): ... this new prototype.
18405 (init_registers_powerpc_e500): Remove, replace by ...
18406 (init_registers_powerpc_e500l): ... this new prototype.
18407 (init_registers_ppc64): Remove, replace by ...
18408 (init_registers_powerpc_64l): ... this new prototype.
18409 (init_registers_powerpc_64): Remove, replace by ...
18410 (init_registers_powerpc_altivec64l): ... this new prototype.
18411 (ppc_num_regs): Set to 73.
18412 (PT_ORIG_R3, PT_TRAP): Define if necessary.
18413 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
18414 (ppc_cannot_store_register): Handle orig_r3 and trap.
18415 (ppc_arch_setup): Update init_registers_... calls.
18416 (ppc_fill_gregset): Handle orig_r3 and trap.
18417
18418 * inferiors.c (clear_inferiors): Reset current_inferior.
18419
fdc59709
PB
184202008-04-23 Paolo Bonzini <bonzini@gnu.org>
18421
889bf7c5
PA
18422 * acinclude.m4: Add override.m4.
18423 * configure: Regenerate.
fdc59709 18424
c9b2f845
UW
184252008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
18426
18427 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
18428 initial call to init_register_ppc64.
18429
550512b8
UW
184302008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
18431
43aaf8b6
PA
18432 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
18433 single powerpc*-*-linux* case.
550512b8
UW
18434 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
18435
b6430ec3
UW
184362008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
18437
18438 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 18439 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
18440 from reg_xmlfiles.
18441 * linux-ppc-low.c: Include <elf.h>.
18442 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
18443 (ppc_hwcap): New global variable.
18444 (ppc_regmap): Remove __SPE__ #ifdef sections.
18445 (ppc_regmap_e500): New global variable.
18446 (ppc_cannot_store_register): Update __SPE__ special case.
18447 (ppc_get_hwcap): New function.
18448 (ppc_arch_setup): Use it to determine whether inferior supports
18449 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
18450 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
18451 Do not access registers if target does not support AltiVec.
18452 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
18453 Do not access registers if target does not support SPE.
18454 (target_regsets): Unconditionally include AltiVec and SPE regsets.
18455
52fa2412
UW
184562008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
18457
18458 * linux-low.c (disabled_regsets, num_regsets): New.
18459 (use_regsets_p): Delete.
18460 (linux_wait_for_process): Clear disabled_regsets.
18461 (regsets_fetch_inferior_registers): Check and set it.
18462 (regsets_store_inferior_registers): Likewise.
18463 (linux_fetch_registers, linux_store_registers): Do not use
18464 use_regsets_p.
18465 (initialize_low): Allocate disabled_regsets.
18466
e28b3332
DJ
184672008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
18468
18469 * Makefile.in (LIBOBJS): New.
18470 (OBS): Use LIBOBJS.
18471 (memmem.o): New rule.
18472 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
18473 * configure: Regenerated.
18474
4536995d
UW
184752008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
18476
18477 * server.c (handle_query): Never return "unsupported" for
18478 qXfer:features:read queries.
18479
221c031f
UW
184802008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
18481
18482 * server.c (get_features_xml): Fix inverted condition.
18483 (handle_query): Always support qXfer:feature:read.
18484
ccd213ac
DJ
184852008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
18486
18487 * server.c (wrapper_argv): New.
18488 (start_inferior): Handle wrapper_argv. If set, expect an extra
18489 trap.
18490 (gdbserver_usage): Document --wrapper.
18491 (main): Parse --wrapper.
18492
6fe305f7
UW
184932008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18494
18495 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
18496 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
18497 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
18498 (ppc_set_pc): Likewise.
18499 (ppc_arch_setup): New function.
18500 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
18501 of collect_register.
889bf7c5 18502 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 18503
5b0a002e
UW
185042008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18505
18506 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
18507 instead of linux-ppc64-low.o.
18508 * linux-ppc64-low.c: Remove file.
18509 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
18510 (linux-ppc64-low.o): Remove rule.
18511
18512 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
18513 (init_registers_powerpc_64): Likewise.
18514 (ppc_regmap): Conditionally define depending on __powerpc64__.
18515 (ppc_cannot_store_register): Do not special-case "fpscr" when
18516 compiled on __powerpc64__.
18517 (ppc_collect_ptrace_register): New function.
18518 (ppc_supply_ptrace_register): New function.
18519 (ppc_breakpoint): Change type to "unsigned int".
18520 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
18521 (the_low_target): Conditionally provide initializers for the
889bf7c5 18522 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
18523 collect_ptrace_register and supply_ptrace_register members.
18524
9b4b61c8
UW
185252008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18526
18527 * regcache.h (gdbserver_xmltarget): Add extern declaration.
18528 * server.c (gdbserver_xmltarget): Define.
18529 (get_features_xml): Use it to replace "target.xml" and arch_string.
18530
18531 * configure.srv: Remove srv_xmltarget. Add XML files that were
18532 mentioned there to srv_xmlfiles instead. Remove conditional tests
18533 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
18534 srv_xmlfiles and srv_regobj to include all possible choices.
18535 * configure.ac (srv_xmltarget): Remove.
18536 (srv_xmlfiles): Do not add "target.xml".
18537 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
18538 checks for supplementary target information.
18539 * configure: Regenerate.
18540 * Makefile.in (XML_TARGET): Remove.
18541 (target.xml): Remove rule.
18542 (clean): Do not clean up target.xml.
18543 (.PRECIOUS): Do not mention target.xml.
18544
18545 * target.h (struct target_ops): Remove arch_string member.
18546 * linux-low.c (linux_arch_string): Remove.
18547 (linux_target_ops): Remove arch_string initializer.
18548 * linux-low.h (struct linux_target_ops): Remove arch_string member.
18549 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
18550 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
18551 * spu-low.c (spu_arch_string): Remove.
18552 (spu_target_ops): Remove arch_string initializer.
18553 * win32-low.c (win32_arch_string): Remove.
18554 (win32_target_ops): Remove arch_string initializer.
18555 * win32-low.h (struct win32_target_ops): Remove arch_string member.
18556 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
18557 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
18558
ee1a7ae4
UW
185592008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18560
18561 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
18562 by collect_ptrace_register and supply_ptrace_register hooks.
18563 * linux-low.c (fetch_register): Use supply_ptrace_register callback
18564 instead of checking for the_low_target.left_pad_xfer.
18565 (usr_store_inferior_registers): Use collect_ptrace_register callback
18566 instead of checking for the_low_target.left_pad_xfer.
18567
18568 * linux-s390-low.c (s390_collect_ptrace_register): New function.
18569 (s390_supply_ptrace_register): Likewise.
18570 (s390_fill_gregset): Call s390_collect_ptrace_register.
18571 (the_low_target): Update.
18572
18573 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
18574 (ppc_supply_ptrace_register): Likewise.
18575 (the_low_target): Update.
18576
18577 * linux-i386-low.c (the_low_target): Update.
18578 * linux-x86-64-low.c (the_low_target): Update.
18579
d61ddec4
UW
185802008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18581
18582 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
18583 reg-s390.o and reg-s390x.o.
18584
18585 * linux-low.c (new_inferior): New global variable.
18586 (linux_create_inferior, linux_attach): Set it.
18587 (linux_wait_for_process): Call the_low_target.arch_setup after the
18588 target has stopped for the first time.
18589 (initialize_low): Do not call the_low_target.arch_setup.
18590
18591 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
18592 (s390_set_pc): Likewise.
18593 (s390_arch_setup): New function.
18594 (the_low_target): Use s390_arch_setup as arch_setup routine.
18595
18596 * regcache.c (realloc_register_cache): New function.
18597 (set_register_cache): Call it for each existing regcache.
18598
d05b4ac3
UW
185992008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18600
18601 * server.h (init_registers): Remove prototype.
18602
18603 * linux-low.h (struct linux_target_ops): Add arch_setup field.
18604 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
18605 instead of init_registers ().
18606 * linux-arm-low.c (init_registers_arm): Add prototype.
18607 (init_registers_arm_with_iwmmxt): Likewise.
18608 (the_low_target): Add initializer for arch_setup field.
18609 * linux-cris-low.c (init_registers_cris): Add prototype.
18610 (the_low_target): Add initializer for arch_setup field.
18611 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
18612 (the_low_target): Add initializer for arch_setup field.
18613 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
18614 (the_low_target): Add initializer for arch_setup field.
18615 * linux-ia64-low.c (init_registers_ia64): Add prototype.
18616 (the_low_target): Add initializer for arch_setup field.
18617 * linux-m32r-low.c (init_registers_m32r): Add prototype.
18618 (the_low_target): Add initializer for arch_setup field.
18619 * linux-m68k-low.c (init_registers_m68k): Add prototype.
18620 (the_low_target): Add initializer for arch_setup field.
18621 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
18622 (init_registers_mips64_linux): Likewise.
18623 (the_low_target): Add initializer for arch_setup field.
18624 * linux-ppc-low.c (init_registers_ppc): Add prototype.
18625 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
18626 (the_low_target): Add initializer for arch_setup field.
18627 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
18628 (init_registers_powerpc_64): Likewise.
18629 (the_low_target): Add initializer for arch_setup field.
18630 * linux-s390-low.c (init_registers_s390): Add prototype.
18631 (init_registers_s390x): Likewise.
18632 (the_low_target): Add initializer for arch_setup field.
18633 * linux-sh-low.c (init_registers_sh): Add prototype.
18634 (the_low_target): Add initializer for arch_setup field.
18635 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
18636 (the_low_target): Add initializer for arch_setup field.
18637 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
18638 (the_low_target): Add initializer for arch_setup field.
18639
18640 * win32-low.h (struct win32_target_ops): Add arch_setup field.
18641 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
18642 instead of init_registers ().
18643 * win32-arm-low.c (init_registers_arm): Add prototype.
18644 (the_low_target): Add initializer for arch_setup field.
18645 * win32-i386-low.c (init_registers_i386): Add prototype.
18646 (the_low_target): Add initializer for arch_setup field.
18647
18648 * spu-low.c (init_registers_spu): Add prototype.
18649 (initialize_low): Call initialie_registers_spu () instead of
18650 initialize_registers ().
18651
fd96d250
PA
186522008-02-19 Pedro Alves <pedro@codesourcery.com>
18653
18654 * server.c (handle_v_requests): When handling the vRun and vAttach
18655 packets, if already debugging a process, don't kill it. Return an
18656 error instead.
18657
d41b6bb4
DJ
186582008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
18659
18660 * server.c (handle_query): Correct length check.
18661
5ac588cf
PA
186622008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
18663
18664 * win32-low.c (do_initial_child_stuff): Add process handle
18665 parameter. Set current_process_handle and current_process_id from the
18666 parameters. Clear globals.
18667 (win32_create_inferior): Don't set current_process_handle and
18668 current_process_id here. Instead pass them on the call to
18669 do_initial_child_stuff.
18670 (win32_attach): Likewise.
18671 (win32_clear_inferiors): New.
18672 (win32_kill): Don't close the current process handle or the
18673 current thread handle here. Instead call win32_clear_inferiors.
18674 (win32_detach): Don't open a new handle to the process. Call
18675 win32_clear_inferiors.
18676 (win32_join): Don't rely on current_process_handle; open a new
18677 handle using the process id.
18678 (win32_wait): Call win32_clear_inferiors when the inferior process
18679 has exited.
18680
ecd7ecbc
DJ
186812008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
18682
18683 * server.c (monitor_show_help): Add "exit".
18684
1525d545
MG
186852008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
18686
ecd7ecbc 18687 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
18688 (clean): Add reg-xtensa.c.
18689 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
18690 * configure.srv (xtensa*-*-linux*) New target.
18691 * linux-xtensa-low.c: New.
18692 * xtensa-xtregs.c: New.
1525d545 18693
59a016f0
PA
186942008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
18695
18696 * hostio.c: Don't include errno.h.
18697 (errno_to_fileio_errno): Move to hostio-errno.
18698 * hostio.c: (hostio_error): Remove the error parameter. Defer the
18699 error number outputting to the target->hostio_last_error callback.
18700 (hostio_packet_error): Use FILEIO_EINVAL directly.
18701 (handle_open, handle_pread, hostio_error, handle_unlink): Update
18702 calls to hostio_error.
18703 * hostio-errno.c: New.
18704 * server.h (hostio_last_error_from_errno): Declare.
18705 * target.h (target_ops): Add hostio_last_error member.
18706 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
18707 as hostio_last_error handler.
889bf7c5 18708 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
18709 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
18710 (wince_hostio_last_error): New functions.
18711 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
18712 as hostio_last_error handler.
18713 (win32_target_ops) [!_WIN32_WCE]: Register
18714 hostio_last_error_from_errno as hostio_last_error handler.
18715 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
18716 (hostio-errno.o): New rule.
18717 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
18718 * configure.srv (srv_hostio_err_objs): New variable. Default to
18719 hostio-errno.o.
18720 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
18721 * configure: Regenerate.
18722
2d717e4f
DJ
187232008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18724
18725 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
18726 (linux_kill, linux_detach): Clean up the process list.
18727 * remote-utils.c (remote_open): Improve port number parsing.
18728 (putpkt_binary, input_interrupt): Only send interrupts if the target
18729 is running.
18730 * server.c (extended_protocol): Make static.
18731 (attached): Define earlier.
18732 (exit_requested, response_needed, program_argv): New variables.
18733 (target_running): New.
18734 (start_inferior): Clear attached here.
18735 (attach_inferior): Set attached here.
18736 (require_running): Define.
18737 (handle_query): Use require_running and target_running. Implement
18738 "monitor exit".
18739 (handle_v_attach, handle_v_run): New.
18740 (handle_v_requests): Use require_running. Handle vAttach and vRun.
18741 (gdbserver_usage): Update.
18742 (main): Redo argument parsing. Handle --debug and --multi. Handle
18743 --attach along with other options or after the port. Save
18744 program_argv. Support no initial program. Resynchronize
18745 communication with GDB after an error. Handle "monitor exit".
18746 Use require_running and target_running. Always allow the extended
18747 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
18748 restart in extended mode.
18749 * README: Refer to the GDB manual. Update --attach usage.
18750
7407e2de
AS
187512007-12-20 Andreas Schwab <schwab@suse.de>
18752
18753 * linux-low.c (STACK_SIZE): Define.
18754 (linux_tracefork_child): Use it. Use __clone2 on ia64.
18755 (linux_test_for_tracefork): Likewise.
18756
b65d95c5
DJ
187572007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
18758
18759 * linux-low.c (linux_wait_for_event): Update messages. Do not
18760 reinsert auto-delete breakpoints.
18761 * mem-break.c (struct breakpoint): Change return type of handler to
18762 int.
18763 (set_breakpoint_at): Update handler type.
18764 (reinsert_breakpoint_handler): Return 1 instead of calling
18765 delete_breakpoint.
18766 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
18767 setting a new one.
18768 (check_breakpoints): Delete auto-delete breakpoints and return 2.
18769 * mem-break.h (set_breakpoint_at): Update handler type.
18770 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
18771 * win32-low.c (auto_delete_breakpoint): New.
18772 (get_child_debug_event): Use it.
18773
4e799345
DJ
187742007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
18775
18776 * configure.ac: Check for pread and pwrite.
18777 * hostio.c (handle_pread): Fall back to lseek and read.
18778 (handle_pwrite): Fall back to lseek and write.
18779 * config.in, configure: Regenerated.
18780
27524b67
DJ
187812007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
18782
18783 * server.c (myresume): Add own_buf argument.
18784 (main): Update calls.
18785
a20d5e98
DJ
187862007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
18787
18788 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
18789 * remote-utils.c (remote_open): Do not call disable_async_io.
18790 (block_async_io): Delete.
18791 (unblock_async_io): Make static.
18792 (initialize_async_io): New.
18793 * server.c (handle_v_cont): Handle async I/O here.
18794 (myresume): Likewise. Move other common resume tasks here...
18795 (main): ... from here. Call initialize_async_io. Disable async
18796 I/O before the main loop.
18797 * server.h (initialize_async_io): Declare.
18798 (block_async_io, unblock_async_io): Delete prototypes.
18799 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
18800
b79d787e
DJ
188012007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
18802
18803 * remote-utils.c (readchar): Allow binary data in received messages.
18804
d97903b2
PA
188052007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18806
18807 * win32-low.c (attaching): New global.
18808 (win32_create_inferior): Clear the `attaching' global.
18809 (win32_attach): Set the `attaching' global.
18810 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
18811 attaching. Only set a breakpoint at the entry point if not
18812 attaching.
18813
311de423
PA
188142007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18815
18816 * server.c (main): Don't report dll events on the initial
18817 connection on attaches.
18818
6c2d16d2
PA
188192007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18820
18821 * server.c (main): Relax numerical bases supported for the pid of
18822 the --attach command line argument.
18823
5ca906e6
PA
188242007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18825
18826 * win32-low.c (win32_attach): Call OpenProcess before
18827 DebugActiveProcess, not after. Add last error output to error
18828 call.
18829
9c6c8194
PA
188302007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18831
18832 * win32-low.c (win32_get_thread_context)
18833 (win32_set_thread_context): New functions.
18834 (thread_rec): Use win32_get_thread_context.
18835 (continue_one_thread, win32_resume): Use win32_set_thread_context.
18836 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
18837 field.
18838
4d5d1aaa
PA
188392007-12-03 Leo Zayas
18840 Pedro Alves <pedro_alves@portugalmail.pt>
18841
18842 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
18843 global variables.
18844 (child_add_thread): Minor cleanup.
18845 (child_continue): Resume artificially suspended threads before
18846 calling ContinueDebugEvent.
18847 (suspend_one_thread): New.
18848 (fake_breakpoint_event): New.
18849 (get_child_debug_event): Change return type to int. Check here if
18850 gdb sent an interrupt request. If a soft interrupt was requested,
18851 fake a breakpoint event. Return 0 if there is no event to handle,
18852 and 1 otherwise.
18853 (win32_wait): Don't check here if gdb sent an interrupt request.
18854 Ensure there is a valid event to handle.
18855 (win32_request_interrupt): Add soft interruption method as last
18856 resort.
18857
c436e841
PA
188582007-12-03 Leo Zayas
18859 Pedro Alves <pedro_alves@portugalmail.pt>
18860
18861 * win32-low.h (win32_thread_info): Add descriptions to the
18862 structure members. Replace `suspend_count' counter by a
18863 `suspended' flag.
18864 * win32-low.c (thread_rec): Update condition of when to get the
18865 context from the inferior. Rely on ContextFlags being set if it
18866 has already been retrieved. Only suspend the inferior thread if
18867 we haven't already. Warn if that fails.
18868 (continue_one_thread): s/suspend_count/suspended/. Only call
18869 ResumeThread once. Warn if that fails.
18870
e7b5fa67
PA
188712007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18872
18873 * win32-low.c (win32_wait): Don't read from the inferior when it
18874 has already exited.
18875
a385171d
PA
188762007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18877
18878 * Makefile.in (win32_low_h): New variable.
18879 (win32-low.o): Add dependency on $(win32_low_h).
18880 (win32-arm-low.o, win32-i386-low.o): New rules.
18881
f80c84b3
DJ
188822007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18883
18884 * hostio.c: Correct copyright year.
18885
a6b151f1
DJ
188862007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18887
18888 * Makefile.in (OBS): Add hostio.o.
18889 (hostio.o): New rule.
18890 * server.h (handle_vFile): Declare.
18891 * hostio.c: New file.
18892 * server.c (handle_v_requests): Take packet_len and new_packet_len
18893 for binary packets. Call handle_vFile.
18894 (main): Update call to handle_v_requests.
18895
f9387fc3
DJ
188962007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
18897
18898 * linux-low.c: Include <sched.h>.
18899
51c2684e
DJ
189002007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
18901
18902 * linux-low.c (linux_tracefork_grandchild): New.
18903 (linux_tracefork_child): Use clone.
18904 (linux_test_for_tracefork): Use clone; allocate and free a stack.
18905
75f83163
JB
189062007-10-31 Joel Brobecker <brobecker@adacore.com>
18907
18908 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
18909
da5898ce
DJ
189102007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
18911
18912 * linux-low.c (handle_extended_wait): Handle unexpected signals.
18913
24a09b5f
DJ
189142007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
18915
18916 * inferiors.c (change_inferior_id): Delete.
18917 (add_pid_to_list, pull_pid_from_list): New.
18918 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
18919 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
18920 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
18921 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
18922 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
18923 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
18924 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
18925 (using_threads): Always set to 1.
18926 (handle_extended_wait): New.
18927 (add_process): Do not set TID.
18928 (linux_create_inferior): Set must_set_ptrace_flags.
18929 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
18930 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
18931 (linux_thread_alive): Rename TID argument to LWPID.
18932 (linux_wait_for_process): Handle unknown processes. Do not use TID.
18933 (linux_wait_for_event): Do not use TID or check using_threads. Update
18934 call to dead_thread_notify. Call handle_extended_wait.
18935 (linux_create_inferior): Use PTRACE_SETOPTIONS.
18936 (send_sigstop): Delete sigstop_sent.
18937 (wait_for_sigstop): Avoid TID.
18938 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
18939 (linux_test_for_tracefork): New.
18940 (linux_lookup_signals): Use thread_db_active and
18941 linux_supports_tracefork_flag.
18942 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
18943 * linux-low.h (get_process_thread): Avoid TID.
18944 (struct process_ifo): Move thread_known and tid to the end. Remove
18945 sigstop_sent.
18946 (linux_attach_lwp, thread_db_init): Update prototypes.
18947 * server.h (change_inferior_id): Delete prototype.
18948 (add_pid_to_list, pull_pid_from_list): New prototypes.
18949 * thread-db.c (thread_db_use_events): New.
18950 (find_first_thread): Rename to...
18951 (find_one_thread): ...this. Update callers and messages. Do not
18952 call fatal. Check thread_db_use_events. Do not call
18953 change_inferior_id or new_thread_notify.
18954 (maybe_attach_thread): Update. Do not call new_thread_notify.
18955 (thread_db_init): Set thread_db_use_events. Check use_events.
18956 * utils.c (fatal, warning): Correct message prefix.
18957
30ed0a8f
DJ
189582007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
18959
18960 * Makefile.in (clean): Remove new files.
18961 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
18962 (powerpc-64.o, powerpc-64.c): New rules.
18963 * configure.srv: Use alternate register sets for powerpc64-*-linux*
18964 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
18965 with SPE.
18966 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
18967 SPE targets.
18968 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
18969 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
18970 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
18971 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
18972 (target_regsets): Add AltiVec and SPE register sets.
18973 * configure.ac: Check for AltiVec and SPE.
18974 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
18975 (ppc_fill_vrregset, ppc_store_vrregset): New.
18976 (target_regsets): Add AltiVec register set.
18977 * configure: Regenerated.
18978
fd462a61
DJ
189792007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
18980
18981 * linux-low.c (O_LARGEFILE): Define.
18982 (linux_read_memory): Use /proc/PID/mem.
18983 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
18984 * configure, config.in: Regenerated.
18985
69f223ed
DJ
189862007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18987
18988 * linux-low.c (linux_wait_for_event): Do not pass signals while
18989 single-stepping.
18990
aec18585
PA
189912007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18992
18993 * win32-low.c (create_process): New.
18994 (win32_create_inferior): Use create_process instead of
18995 CreateProcess. If create_process failed retry appending an ".exe"
18996 suffix. Store the GetLastError result immediatelly after
18997 create_process calls and use it on the call to error.
18998
34d86ddd
PA
189992007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
19000
19001 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
19002
5a0e3bd0
JB
190032007-08-23 Joel Brobecker <brobecker@adacore.com>
19004
19005 * configure.ac: Switch license to GPLv3.
19006
f88c79e6
MS
190072007-08-01 Michael Snyder <msnyder@access-company.com>
19008
19009 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
19010
6b3d9b83
PA
190112007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
19012
19013 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
19014 typedef.
19015 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
19016 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
19017 CloseToolhelp32Snapshot.
19018 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
19019 CloseToolhelp32Snapshot.
19020
c588c53c
MS
190212007-07-27 Michael Snyder <michael.snyder@access-company.com>
19022
19023 * server.c (main): Check for inferior exit before main loop.
19024
aa0403d9
PA
190252007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
19026
19027 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
19028 instead of on tmp_desc.
19029
255e7678
DJ
190302007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
19031 Daniel Jacobowitz <dan@codesourcery.com>
19032
19033 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
19034 (add_thread): Minor cleanups.
19035 (clear_inferiors): Move lower in the file. Clear the DLL
19036 list.
19037 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
19038 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
19039 (xml_escape_text): New.
19040 * server.c (handle_query): Handle qXfer:libraries:read. Report it
19041 for qSupported.
19042 (handle_v_cont): Report errors.
19043 (gdbserver_version): Update.
19044 (main): Correct size of own_buf. Do not report initial DLL events.
19045 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
19046 (unloaded_dll, xml_escape_text): New.
19047 * win32-low.c (enum target_waitkind): Update comments.
19048 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
19049 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
19050 (win32_EnumProcessModules, win32_GetModuleInformation)
19051 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
19052 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
19053 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
19054 (win32_Module32First, win32_Module32Next, load_toolhelp)
19055 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
19056 (get_child_debug_event): Handle DLL events.
19057 (win32_wait): Likewise.
19058
0d37add9
DJ
190592007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
19060
19061 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
19062 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
19063
45e2715e
PA
190642007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
19065
19066 * win32-low.c (handle_output_debug_string): Ignore event if not
19067 waiting.
19068
c5674cf1
PA
190692007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
19070
19071 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
19072
2bbe3cc1
DJ
190732007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
19074
19075 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
19076
ae13219e
DJ
190772007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
19078
19079 * inferiors.c (change_inferior_id): Add comment.
19080 * linux-low.c (check_removed_breakpoint): Add an early
19081 prototype. Improve debug output.
19082 (linux_attach): Doc update.
19083 (linux_detach_one_process, linux_detach): Clean up before releasing
19084 each process.
19085 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
19086 * linux-low.h (struct process_info): Doc improvement.
19087 * mem-break.c (delete_all_breakpoints): New.
19088 * mem-break.h (delete_all_breakpoints): New prototype.
19089 * thread-db.c (find_first_thread): New.
19090 (thread_db_create_event): Call it instead of
19091 thread_db_find_new_threads. Clean up unused variables.
19092 (maybe_attach_thread): Remove first thread handling.
19093 (thread_db_find_new_threads): Use find_first_thread.
19094 (thread_db_get_tls_address): Likewise.
19095
4105de34
DJ
190962007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
19097
19098 * thread-db.c (thread_db_find_new_threads): Add prototype.
19099 (thread_db_create_event): Check for the main thread before adding
19100 a new thread.
19101 (maybe_attach_thread): Only enable event reporting if TID == 0.
19102 (thread_db_get_tls_address): Check for new threads.
19103
2b876972
DJ
191042007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
19105
19106 * linux-low.c (linux_create_inferior): Try execv before execvp.
19107 * spu-low.c (spu_create_inferior): Likewise.
19108
7a245884
DJ
191092007-06-13 Mike Frysinger <vapier@gentoo.org>
19110
19111 * linux-low.c (linux_create_inferior): Change execv to execvp.
19112 * spu-low.c (spu_create_inferior): Likewies.
19113
117ce543
DJ
191142007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
19115
19116 * Makefile.in (clean): Clean new files instead of deleted ones.
19117 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
19118 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
19119 rules.
19120 * configure.srv: Specify XML files and new regformats for MIPS and
19121 MIPS64 GNU/Linux.
19122 * linux-mips-low.c (mips_num_regs): Set to only used registers.
19123 (mips_regmap): Do not fetch $0. Remove unused registers. Add
19124 an entry for the restart register.
19125 (mips_cannot_fetch_register, mips_cannot_store_register)
19126 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
19127 register names to match the XML descriptions.
19128 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
19129 restart register instead of $0.
19130
0e7f50da
UW
191312007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
19132 Markus Deuling <deuling@de.ibm.com>
19133
19134 * remote-utils.c (decode_xfer_write): New function.
19135 * server.h (decode_xfer_write): Add prototype.
19136 * server.c (handle_query): Add PACKET_LEN argument. Support
19137 qXfer:spu:read and qXfer:spu:write packets.
19138 (main): Pass packet_len to handle_query.
19139 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
19140 * target.h (target_ops): Add qxfer_spu.
19141
374c1d38
UW
191422007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
19143
19144 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
19145 accessing non-seekable spufs files.
19146
bb63802a
UW
191472007-05-16 Markus Deuling <deuling@de.ibm.com>
19148
889bf7c5 19149 * server.c (handle_query): Add reply for qC packet.
bb63802a 19150
7390519e
PA
191512007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19152 Leo Zayas <lerele@champenstudios@com>
19153
19154 * server.h (check_remote_input_interrupt_request): New function.
19155 * remote_utils.c (INVALID_DESCRIPTOR): New define.
19156 (remote_desc): Initialize with INVALID_DESCRIPTOR.
19157 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
19158 (check_remote_input_interrupt_request): New function.
19159 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 19160 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
19161 winapi_GenerateConsoleCtrlEvent): New typedefs.
19162 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
19163 to 250 ms.
19164 (win32_wait): Check for remote interrupt request
19165 with check_remote_input_interrupt_request.
19166 (win32_request_interrupt): New function.
19167 (win32_target_op): Set request_interrupt to win32_request_interrupt.
19168
34b34921
PA
191692007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19170
19171 * win32-low.c (debug_registers_changed,
19172 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
19173 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
19174 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
19175 (thread_rec): Get context using the low target.
19176 (child_add_thread): Call thread_added on the low target,
19177 which does the same thing.
19178 (regptr): Delete.
19179 (do_initial_child_stuff): Remove debug registers references.
19180 Set context using the low target. Resume threads after
19181 setting the contexts.
19182 (child_continue): Remove dead variable. Remove debug
19183 registers references.
19184 (child_fetch_inferior_registers): Go through the low target.
19185 (do_child_store_inferior_registers): Remove.
19186 (child_store_inferior_registers): Go through the low target.
19187 (win32_resume): Remove debug registers references.
19188 Set context using the low target.
19189 (handle_exception): Change return type to void. Don't record
19190 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
19191 first chance exception.
889bf7c5 19192 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
19193 goto loop. Always return after waiting for debug event.
19194 (win32_wait): Convert to switch statement. Handle spurious
19195 events.
19196
19197 * win32-i386-low.c (debug_registers_changed,
19198 debug_registers_used): New.
19199 (initial_stuff): Rename to ...
19200 (i386_initial_stuff): ... this. Clear debug registers
19201 state variables.
19202 (store_debug_registers): Delete.
19203 (i386_get_thread_context): New.
19204 (load_debug_registers): Delete.
19205 (i386_set_thread_context): New.
19206 (i386_thread_added): New.
19207 (single_step): Rename to ...
19208 (i386_single_step): ... this.
19209 (do_fetch_inferior_registers): Rename to ...
19210 (i386_fetch_inferior_register): ... this.
19211 (i386_store_inferior_register): New.
19212 (the_low_target): Adapt to new interface.
19213
19214 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
19215 (arm_get_thread_context): New.
19216 (arm_set_thread_context): New.
19217 (regptr): New.
19218 (do_fetch_inferior_registers): Rename to ...
19219 (arm_fetch_inferior_register): ... this.
19220 (arm_store_inferior_register): New.
19221 (arm_wince_breakpoint): Reimplement as unsigned long.
19222 (arm_wince_breakpoint_len): Define.
19223 (the_low_target): Adapt to new interface.
19224
19225 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
19226 load_debug_registers. Add get_thread_context, set_thread_context,
19227 thread_added and store_inferior_register. Rename
19228 fetch_inferior_registers to fetch_inferior_register.
19229 (regptr): Remove declaration.
19230
dd6953e1
PA
192312007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19232
19233 * linux-low.c (linux_detach): Change return type to int. Return 0.
19234 * spu-low.c (spu_detach): Likewise.
19235
444d6139
PA
192362007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19237
19238 * target.h (target_ops): Change return type of detach to int.
19239 Add join.
19240 (join_inferior): New.
19241 * server.c (main): Don't skip detach support on mingw32.
19242 If the inferior doesn't support detaching return error.
19243 Call join_inferior instead of using waitpid.
19244 * linux-low.c (linux_join): New.
19245 (linux_target_op): Add linux_join.
19246 * spu-low.c (spu_join): New.
19247 (spu_target_ops): Add spu_join.
19248 * win32-low.c (win32_detach): Adapt to new interface.
19249 Reopen current_process_handle before detaching. Issue a child
19250 resume before detaching.
19251 (win32_join): New.
19252 (win32_target_op): Add win32_join.
19253
1d5315fe
PA
192542007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19255
19256 * win32-low.c (win32-attach): Fix return value.
19257 * target.h (target_ops): Describe ATTACH return values.
19258
bf914831
PA
192592007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19260
19261 * win32-low.c (GETPROCADDRESS): Define.
19262 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
19263 (winapi_DebugSetProcessKillOnExit): Likewise.
19264 (win32_create_inferior): Force usage of ansi CreateProcessA.
19265 (win32_attach): Use GETPROCADDRESS.
19266 (win32_detach): Likewise.
19267
f72f3e60
PA
192682007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19269
19270 * win32-low.c (win32_wait): Don't use WSTOPSIG.
19271
ed50f18f
PA
192722007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
19273
19274 * win32-low.c: Commit leftover changes from 2007-03-29.
19275
0c2ead7e
DJ
192762007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
19277
19278 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
19279 fields short instead of int. Add explicit padding.
19280 (i387_cache_to_fsave): Remove unnecessary casts.
19281 (i387_fsave_to_cache): Doc fix.
19282 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
19283
73725ff3
DJ
192842007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
19285
19286 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
19287 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
19288
d99f33d8
PA
192892007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
19290
19291 * configure.srv (arm*-*-mingw32ce*): Move near the other
19292 arm targets.
19293
68070c10
PA
192942007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
19295
2482afc6 19296 * configure.ac: Add errno checking.
68070c10
PA
19297 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
19298 sys/file.h and malloc.h.
19299 (AC_CHECK_DECLS): Add perror.
19300 (srv_mingwce): Handle.
2482afc6 19301 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
19302 win32-i386-low.o to srv_tgtobj.
19303 (i[34567]86-*-mingw*): Likewise.
19304 (arm*-*-mingw32ce*): Add case.
19305 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
19306 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
19307 [__MINGW32CE__] (strerror): New function.
19308 [__MINGW32CE__] (errno): Define to GetLastError.
19309 [__MINGW32CE__] (COUNTOF): New macro.
19310 (remote_open): Remove extra close call.
19311 * mem-break.c (delete_breakpoint_at): New function.
19312 * mem-break.h (delete_breakpoint_at): Declare.
19313 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
19314 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
19315 [USE_WIN32API] (read, write): Add char* casts.
19316 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
19317 * server.h: Include wincecompat.h on Windows CE.
19318 [HAVE_ERRNO_H]: Check.
19319 (perror): Declare if not declared.
19320 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
19321 (perror_with_name): Remove errno declaration.
19322 * wincecompat.h: New.
19323 * wincecompat.c: New.
19324 * win32-low.h: New.
19325 * win32-arm-low.c: New.
19326 * win32-i386-low.c: New.
19327 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
19328 (OUTMSG2): Make it safe.
19329 (_T): New macro.
19330 (COUNTOF): New macro.
19331 (NUM_REGS): Get it from the low target.
19332 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
19333 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
19334 (thread_rec): Let low target handle debug registers.
19335 (child_add_thread): Likewise.
19336 (child_init_thread_list): Likewise.
19337 (continue_one_thread): Likewise.
19338 (regptr): New.
19339 (do_child_fetch_inferior_registers): Move to ...
19340 * win32-i386-low.c: ... here, and rename to ...
19341 (do_fetch_inferior_registers): ... this.
889bf7c5 19342 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
19343 Go through the low target.
19344 (do_child_store_inferior_registers): Use regptr.
19345 (strwinerror): New function.
19346 (win32_create_inferior): Handle Windows CE.
19347 Use strwinerror instead of strerror on Windows error
19348 codes. Add program to the error output.
19349 Don't close the main thread handle on Windows CE.
19350 (win32_attach): Use coredll.dll on Windows CE.
19351 (win32_kill): Close current process and current
19352 thread handles.
19353 (win32_detach): Use coredll.dll on Windows CE.
19354 (win32_resume): Let low target handle debug registers, and
19355 step request.
19356 (handle_exception): Add/Remove initial breakpoint. Avoid
19357 non-existant WSTOPSIG on Windows CE.
19358 (win32_read_inferior_memory): Cast to remove warning.
19359 (win32_arch_string): Go through the low target.
19360 (initialize_low): Call set_breakpoint_data with the low
19361 target's breakpoint.
19362 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
19363 FOP_REGNUM, mappings): Move to ...
19364 * win32-i386-low.c: ... here.
19365 * win32-low.c (win32_thread_info): Move to ...
19366 * win32-low.h: ... here.
19367 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
19368 win32-arm-low.c and wincecompat.c.
19369 (all:): Add $EXEEXT.
19370 (install-only:): Likewise.
19371 (gdbserver:): Likewise.
19372 (gdbreplay:): Likewise.
19373 * config.in: Regenerate.
19374 * configure: Regenerate.
19375
41093d81
PA
193762007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
19377
19378 * win32-low.c: Rename typedef thread_info to
19379 win32_thread_info throughout.
19380
544afa54
PA
193812007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
19382
19383 * win32-i386-low.c: Rename to ...
19384 * win32-low.c: ... this.
19385 * configure.srv: Replace win32-i386-low.o with win32-low.o.
19386 * Makefile.in: Likewise.
19387
bce7165d
PA
193882007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
19389
19390 * remote-utils.c (monitor_output): Constify msg parameter.
19391 * server.h (monitor_output): Likewise.
19392 * win32-i386-low.c (handle_output_debug_string): New.
19393 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
19394 handle_output_debug_string.
19395 (get_child_debug_event): Likewise.
19396
506c7aa0
DJ
193972007-03-27 Mat Hostetter <mat@lcs.mit.edu>
19398
19399 * server.c (main): Correct strtoul check.
19400
42c81e2a
DJ
194012007-03-27 Jon Ringle <jon@ringle.org>
19402
19403 * linux-low.c: Check __ARCH_HAS_MMU__ also.
19404
9453113a
DJ
194052007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
19406
19407 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
19408
64a69107
DJ
194092007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
19410
19411 * terminal.h: Check HAVE_SGTTY_H.
19412
194132007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
19414
19415 * remote-utils.c (remote_open): Print out the assigned port number.
19416
c74d0ad8
DJ
194172007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
19418
19419 * remote-utils.c (monitor_output): New function.
19420 * server.c (debug_threads): Define here.
19421 (monitor_show_help): New function.
19422 (handle_query): Handle qRcmd.
19423 (main): Do not handle 'd' packet.
19424 * server.h (debug_threads, remote_debug, monitor_output): Declare.
19425 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
19426 of debug_threads.
19427
de7c3b4a
PA
194282007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
19429
19430 * Makefile.in (EXEEXT): New.
19431 (clean): Use $(EXEEXT).
19432
ef57601b
PA
194332007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
19434
19435 * target.h (target_ops): Rename send_signal to request_interrupt,
19436 and remove enum target_signal parameter.
19437 * linux-low.c (linux_request_interrupt): Rename from
19438 linux_send_signal, and always send SIGINT.
19439 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
19440 and always send SIGINT.
19441 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
19442 of send_signal.
19443 (input_interrupt): Likewise.
19444
820f2bda
PA
194452007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
19446
19447 * server.c (get_features_xml): Check if target implemented
19448 arch_string.
19449 * win32-i386-low.c (win32_arch_string): New.
19450 (win32_target_ops): Add win32_arch_string as arch_string member.
19451
ab39bf24
UW
194522007-02-22 Markus Deuling <deuling@de.ibm.com>
19453
19454 * spu-low.c (spu_arch_string): New.
19455 (spu_target_ops): Add spu_arch_string.
19456
61ff6e04
DJ
194572007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
19458
19459 * remote-utils.c: Remove HAVE_TERMINAL_H check.
19460 * configure.ac: Do not check for terminal.h.
19461 * configure, config.in: Regenerated.
19462
fb1e4ffc
DJ
194632007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
19464
19465 * Makefile.in (OBS): Add $(XML_BUILTIN).
19466 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
19467 (clean): Update.
19468 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
19469 (arm-with-iwmmxt.c): New.
19470 * config.in, configure: Regenerate.
19471 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
19472 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
19473 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
19474 (arm*-*-linux*): Add iWMMXt and regset support.
19475 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
19476 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
19477 (arm_store_wmmxregset, target_regsets): New.
19478 * server.c (get_features_xml): Take annex argument. Check builtin
19479 XML documents.
19480 (handle_query): Handle multiple annexes.
19481
0f48aa01
DJ
194822007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19483
19484 * remote-utils.c [USE_WIN32API] (read, write): Define.
19485 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
19486 write.
19487
23181151
DJ
194882007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
19489
19490 * linux-i386-low.c (the_low_target): Set arch_string.
19491 * linux-x86-64-low.c (the_low_target): Likewise.
19492 * linux-low.c (linux_arch_string): New.
19493 (linux_target_ops): Add it.
19494 * linux-low.h (struct linux_target_ops): Add arch_string.
19495 * server.c (write_qxfer_response): Use const void * for DATA.
19496 (get_features_xml): New.
19497 (handle_query): Handle qXfer:features:read. Report it for qSupported.
19498 * target.h (struct target_ops): Add arch_string method.
19499
9d606399
DJ
195002007-01-03 Denis Pilat <denis.pilat@st.com>
19501 Daniel Jacobowitz <dan@codesourcery.com>
19502
19503 * linux-low.c (linux_kill): Handle being called with no threads.
19504 * win32-i386-low.c (win32_kill): Likewise.
19505 (get_child_debug_event): Clear current_process_handle.
19506
195072006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
19508 Daniel Jacobowitz <dan@codesourcery.com>
19509
19510 * remote-utils.c (remote_open): Check the type of specified
19511 serial port devices before opening them.
19512 * server.c (main): Kill the inferior if an error occurs during
19513 the first remote_open.
19514
a5e13d24
DJ
195152006-12-05 Markus Deuling <deuling@de.ibm.com>
19516
19517 * README: Update supported targets.
19518
186947f7
DJ
195192006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
19520
19521 * Makefile.in (clean): Remove reg-mips64.c.
19522 (reg-mips64.c, reg-mips64.o): New rules.
19523 * configure.srv: Handle mips64. Include regset support for mips.
19524 * linux-mips-low.c (union mips_register): New.
19525 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
19526 (mips_breakpoint, mips_breakpoint_at): Use int.
19527 (mips_collect_register, mips_supply_register)
19528 (mips_collect_register_32bit, mips_supply_register_32bit)
19529 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
19530 (mips_store_fpregset, target_regsets): New.
19531 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
19532
a13e2c95
UW
195332006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
19534
19535 * configure.srv: Add target "spu*-*-*".
19536 * Makefile.in (clean): Remove reg-spu.c.
19537 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
19538 * spu-low.c: New file.
19539
cb7283db
DJ
195402006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
19541
19542 * configure.ac: Correct td_thr_tls_get_addr test.
19543 * configure: Regenerated.
19544
89be2091
DJ
195452006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
19546
19547 * linux-low.c (linux_wait_for_event): Reformat. Use the
19548 pass_signals array.
19549 * remote-utils.c (decode_address_to_semicolon): New.
19550 * server.c (pass_signals, handle_general_set): New.
19551 (handle_query): Mention QPassSignals for qSupported.
19552 (main): Call handle_general_set.
19553 * server.h (pass_signals, decode_address_to_semicolon): New.
19554
000ef4f0
DJ
195552006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
19556
19557 * server.c (handle_query): Correct error handling for read_auxv.
19558
b7149293
UW
195592005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
19560
19561 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
19562 and srv_linux_thread_db to yes.
19563 * linux-s390-low.c (s390_fill_gregset): New function.
19564 (target_regsets): Define data structure.
19565
dae5f5cf
DJ
195662006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
19567
19568 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
19569 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
19570 * config.in, configure: Regenerated.
19571 * inferiors.c (gdb_id_to_thread): New function.
19572 (gdb_id_to_thread_id): Use it.
19573 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
19574 * linux-low.h (struct process_info): Add th member.
19575 (thread_db_get_tls_address): New prototype.
19576 * remote-utils.c (decode_address): Make non-static.
19577 * server.c (handle_query): Handle qGetTLSAddr.
19578 * server.h (gdb_id_to_thread, decode_address): New prototypes.
19579 * target.h (struct target_ops): Add get_tls_address.
19580 * thread-db.c (maybe_attach_thread): Save the thread handle.
19581 (thread_db_get_tls_address): New.
19582
32ca6d61
DJ
195832006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
19584
19585 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
19586 (linux_resume_one_process): Take a siginfo_t *. Update all
19587 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
19588 (struct pending_signals): Add a siginfo_t.
19589 (linux_wait_for_process): Always set last_status.
19590 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
19591 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
19592 * linux-low.h (struct process_info): Add last_status.
19593
5ffff7c1
DJ
195942006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
19595
19596 * remote-utils.c (try_rle): New function.
19597 (putpkt_binary): Use it.
19598
8695c747
DJ
195992006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
19600
19601 * Makefile.in (clean): Clean reg-x86-64-linux.c.
19602 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
19603 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
19604 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
19605 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
19606 point registers.
19607
290fadea
RS
196082006-08-08 Richard Sandiford <richard@codesourcery.com>
19609
19610 * server.c (terminal_fd): New variable.
19611 (old_foreground_pgrp): Likewise.
19612 (restore_old_foreground_pgrp): New function.
19613 (start_inferior): Record the terminal file descriptor in terminal_fd
19614 and its original foreground group in old_foreground_pgrp. Register
19615 restore_old_foreground_pgrp with atexit().
19616
9f2e1e63
DJ
196172006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
19618
19619 * server.c (handle_query): Correct qPart to qXfer.
19620
b80864fb
DJ
196212006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
19622
19623 * configure.ac: Check for more headers which are missing on
19624 Windows. Automatically supply -lwsock32 and USE_WIN32API.
19625 * configure.srv: Add Cygwin and mingw32.
19626 * remote-utils.c: Don't include headers unconditionally which
19627 are missing on mingw32. Include <winsock.h> for mingw32.
19628 (remote_open): Adjust for mingw32 support. Flush
19629 standard error after writing to it.
19630 (remote_close, putpkt_binary, input_interrupt, block_async_io)
19631 (unblock_async_io, enable_async_io, disable_async_io)
19632 (readchar, getpkt): Update for Winsock support.
19633 (prepare_resume_reply): Expect a protocol signal number.
19634 * server.c: Disable <sys/wait.h> on mingw32.
19635 (start_inferior): Adjust for mingw32 support. Flush
19636 standard error after writing to it.
19637 (attach_inferior): Likewise. Use protocol signal
19638 numbers.
19639 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
19640 and names.
19641 * win32-i386-low.c: New file.
19642 * Makefile.in (XM_CLIBS): Set.
19643 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
19644 (win32-i386-low.o): New dependency rule.
19645 * linux-low.c (linux_wait): Use target signal numbers.
19646 * target.h (struct target_ops): Doc fix.
19647 * server.h (target_signal_to_name): New prototype.
19648 * gdbreplay.c: Don't include headers unconditionally which
19649 are missing on mingw32. Include <winsock.h> for mingw32.
19650 (remote_close, remote_open): Adjust for Winsock support.
19651 * configure, config.in: Regenerated.
19652
0876f84a
DJ
196532006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
19654
19655 * server.c (decode_xfer_read, write_qxfer_response): New.
19656 (handle_query): Take a packet length argument. Handle
19657 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
19658 the qSupported response.
19659 (main): Update call to handle_query.
19660
01f9e8fa
DJ
196612006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
19662
19663 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
19664 (putpkt_binary): Renamed from putpkt and adjusted for binary
19665 data.
19666 (putpkt): New wrapper for putpkt_binary.
19667 (readchar): Don't mask off the high bit.
19668 (decode_X_packet): New function.
19669 * server.c (main): Call putpkt_binary if a handler sets the packet
19670 length. Save the length of the incoming packet. Handle 'X'.
19671 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
19672
be2a5f71
DJ
196732006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
19674
19675 * server.c (handle_query): Handle qSupported.
19676
ea025f5f
DJ
196772006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
19678
19679 * remote-utils.c (all_symbols_looked_up): New variable.
19680 (look_up_one_symbol): Check it.
19681 * server.h (look_up_one_symbol): New declaration.
19682 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
19683
9308fc88
DJ
196842006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
19685
19686 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 19687 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
19688 (PTRACE_GET_THREAD_AREA): Define.
19689 (ps_get_thread_area): New function.
19690
52fb6437
NS
196912006-05-09 Nathan Sidwell <nathan@codesourcery.com>
19692
19693 * configure.srv (m68k*-*-uclinux*): New target.
19694 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
19695 (linux_resume_one_process): Remove extraneous cast.
19696 (linux_read_offsets): New.
19697 (linux_target_op): Add linux_read_offsets on mmuless systems.
19698 * server.c (handle_query): Add qOffsets logic.
19699 * target.h (struct target_ops): Add read_offsets.
19700
21b0f40c
DJ
197012006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
19702
19703 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
19704 (PTRACE_GET_THREAD_AREA): Define.
19705 (ps_get_thread_area): New function.
19706 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
19707 (linux-x86-64-low.o): Update.
19708
0050a760
DJ
197092006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
19710
19711 * configure.ac: Remove checks for prfpregset_t.
19712 * gdb_proc_service.h: New file.
19713 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
19714 new "gdb_proc_service.h".
19715 * proc-service.c: Likewise.
19716 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
19717 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
19718 * Makefile.in (gdb_proc_service_h): Updated.
19719 * configure, config.in: Regenerated.
19720
b92a518e
DJ
197212006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19722
19723 * remote-utils.c (prepare_resume_reply): Move declaration
19724 of gdb_id_from_wait to the top of the block.
19725
545587ee
DJ
197262006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
19727
19728 * linux-low.c (regsets_store_inferior_registers): Read the regset
19729 from the target before filling it.
19730
9db87ebd
DJ
197312006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
19732
19733 * server.c (attach_inferior): Return SIGTRAP for a successful
19734 attach.
19735
dd24457d
DJ
197362006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
19737
19738 * Makefile.in (OBS): Add version.o.
19739 (STAGESTUFF): Delete.
19740 (version.o): Add dependencies.
19741 (version.c): Replace rule.
19742 (clean): Remove version.c.
19743 * server.c (gdbserver_version): New.
19744 (gdbserver_usage): Use printf.
19745 (main): Handle --version and --help.
19746 * server.h (version, host_name): Add declarations.
19747
6f0f660e
EZ
197482005-12-23 Eli Zaretskii <eliz@gnu.org>
19749
889bf7c5
PA
19750 * linux-arm-low.c:
19751 * linux-arm-low.c:
19752 * inferiors.c:
19753 * i387-fp.h:
19754 * i387-fp.c:
19755 * gdbreplay.c:
19756 * regcache.c:
19757 * proc-service.c:
19758 * mem-break.h:
19759 * mem-break.c:
19760 * linux-x86-64-low.c:
19761 * linux-sh-low.c:
19762 * linux-s390-low.c:
19763 * linux-ppc64-low.c:
19764 * linux-ppc-low.c:
19765 * linux-mips-low.c:
19766 * linux-m68k-low.c:
19767 * linux-m32r-low.c:
19768 * linux-low.h:
19769 * linux-low.c:
19770 * linux-ia64-low.c:
19771 * linux-i386-low.c:
19772 * linux-crisv32-low.c:
19773 * thread-db.c:
19774 * terminal.h:
19775 * target.h:
19776 * target.c:
19777 * server.h:
19778 * server.c:
19779 * remote-utils.c:
19780 * regcache.h:
19781 * utils.c:
19782 * Makefile.in:
19783 * configure.ac:
6f0f660e
EZ
19784 * gdbserver.1: Add (C) after Copyright. Update the FSF
19785 address.
19786
9d1fb177
DJ
197872005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
19788
19789 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
19790 (arm_breakpoint_at): Recognize both breakpoints.
19791 (the_low_target): Use the correct breakpoint instruction.
19792
011a70c2
DJ
197932005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
19794
19795 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
19796 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
19797 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
19798 (the_low_target): Update.
19799
7fb85e41
AS
198002005-10-25 Andreas Schwab <schwab@suse.de>
19801
19802 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
19803
19804 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
19805 (ia64_num_regs): Reduce to 462.
19806
3db0444b
DJ
198072005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
19808
19809 * acinclude.m4: Correct quoting.
19810 * aclocal.m4: Regenerated.
19811
19812 Suggested by SZOKOVACS Robert <szo@ies.hu>:
19813 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
19814 (thread_db_init): Call thread_db_err_str.
19815 * configure.ac: Check for TD_VERSION.
19816 * config.in, configure: Regenerated.
19817
bee0189a
DJ
198182005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
19819
19820 * server.h (error, fatal, warning): Add ATTR_FORMAT.
19821
e9d25b98
DJ
198222005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19823
19824 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
19825 is not available. Define HAVE_PTRACE_GETREGS if it is.
19826 * config.in, configure: Regenerated.
19827 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
19828 * linux-i386-low.c, linux-m68k-low.c: Update to use
19829 HAVE_PTRACE_GETREGS.
19830 * linux-low.c (regsets_fetch_inferior_registers)
19831 (regsets_store_inferior_registers): Only return 0 if we processed
19832 GENERAL_REGS.
19833 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
19834 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
19835
a06660f7
DJ
198362005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19837
19838 * inferiors.c (struct thread_info): Add gdb_id.
19839 (add_thread): Add gdb_id argument.
19840 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
19841 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
19842 calls to add_thread.
19843 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
19844 * server.c (handle_query): Use thread_to_gdb_id.
19845 (handle_v_cont, main): Use gdb_id_to_thread_id.
19846 * server.h (add_thread): Update prototype.
19847 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
19848 prototypes.
19849
5a1f5858
DJ
198502005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19851
19852 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
19853 left-padded registers.
19854 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
19855 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
19856
e122f1f5
SE
198572005-07-01 Steve Ellcey <sje@cup.hp.com>
19858
19859 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
19860 * configure: Regenerate.
19861 * config.in: Regenerate.
19862 * server.h (NEED_DECLARATION_STRERROR):
19863 Replace with !HAVE_DECL_STRERROR.
19864
d592fa2f
DJ
198652005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
19866
19867 * linux-low.c (linux_wait, linux_send_signal): Don't test
19868 an unsigned long variable for > 0 if it could be MAX_ULONG.
19869 * server.c (myresume): Likewise.
19870 * target.c (set_desired_inferior): Likewise.
19871
ccbd4912
MK
198722005-06-13 Mark Kettenis <kettenis@gnu.org>
19873
19874 * configure.ac: Simplify and improve check for socklen_t.
19875 * configure, config.in: Regenerate.
19876
f450004a
DJ
198772005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
19878
19879 * acconfig.h: Remove.
19880 * configure.ac: Add a test for socklen_t. Use three-argument
19881 AC_DEFINE throughout.
19882 * config.in: Regenerated using autoheader 2.59.
19883 * configure: Regenerated.
19884
19885 * gdbreplay.c (socklen_t): Provide a default.
19886 (remote_open): Use socklen_t.
19887 * remote-utils.c (socklen_t): Provide a default.
19888 (remote_open): Use socklen_t.
19889 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
19890 unsigned char.
19891
19892 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
19893 char for buffers.
19894 * linux-low.c (linux_read_memory, linux_write_memory)
19895 (linux_read_auxv): Likewise.
19896 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
19897 (check_mem_write): Likewise.
19898 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
19899 Likewise.
19900 * regcache.c (struct inferior_rgcache_data, registers_to_string)
19901 (registers_from_string, register_data): Likewise.
19902 * server.c (handle_query, main): Likewise.
19903 * server.h (convert_ascii_to_int, convert_int_to_ascii)
19904 (decode_M_packet): Likewise.
19905 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
19906 * target.h (struct target_ops): Update read_memory, write_memory,
19907 and read_auxv.
19908 (read_inferior_memory, write_inferior_memory): Update.
19909 * linux-low.h (struct linux_target_ops): Change type of breakpoint
19910 to unsigned char *.
19911 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
19912 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
19913 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
19914 linux-s390-low.c, linux-sh-low.c: Update for changes in
19915 read_inferior_memory and the_low_target->breakpoint.
19916
eee84df1
DJ
199172005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
19918
19919 * Makefile.in (SFILES): Add linux-ppc64-low.c.
19920 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
19921 * configure.srv: Add powerpc64-*-linux*.
19922 * linux-ppc64-low.c: New file.
19923
45b134e5
OF
199242005-05-23 Orjan Friberg <orjanf@axis.com>
19925
19926 * linux-cris-low.c: New file with support for CRIS.
19927 * linux-crisv32-low.c: Ditto for CRISv32.
19928 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
19929 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 19930 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
19931 reg-crisv32.o, and reg-crisv32.c to make rules.
19932 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
19933 recognized targets.
19934
48d93c75
UW
199352005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
19936
19937 * linux-low.c (fetch_register): Ensure buffer size is a multiple
19938 of sizeof (PTRACE_XFER_TYPE).
19939 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
19940
e013ee27
OF
199412005-05-12 Orjan Friberg <orjanf@axis.com>
19942
889bf7c5 19943 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
19944 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
19945 pointers for hardware watchpoint support.
19946 * linux-low.h (struct linux_target_ops): Ditto.
19947 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
19948 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
19949 to linux_target_ops.
19950 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
19951 reply packet.
19952 * server.c (main): Recognize 'Z' and 'z' packets.
19953
b0ded00b
UW
199542005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
19955
19956 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
19957 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
19958 (the_low_target): Add new members.
19959
8643e2ad
DJ
199602005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19961
19962 * proc-service.c (ps_lgetregs): Search all_processes instead of
19963 all_threads.
19964
fc620387
DJ
199652005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19966
19967 * server.c (start_inferior): Change return type to int.
19968 (attach_inferior): Change sigptr to int *.
19969 (handle_v_cont, handle_v_requests): Change signal to int *.
19970 (main): Change signal to int.
19971
199722005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
19973
19974 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
19975 * configure.srv: Add m32r*-*-linux*.
19976 * linux-m32r-low.c: New file.
19977
e0e76420
DJ
199782005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
19979
19980 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
19981
a1928bad
DJ
199822005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19983
19984 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
19985 Take unsigned long arguments for PIDs.
19986 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
19987 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
19988 (wait_for_sigstop, linux_resume_one_process)
19989 (regsets_fetch_inferior_registers, linux_send_signal)
19990 (linux_read_auxv): Likewise. Update the types of variables holding
19991 PIDs. Update format string specifiers.
19992 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
19993 * remote-utils.c (prepare_resume_reply): Likewise.
19994 * server.c (cont_thread, general_thread, step_thread)
19995 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
19996 unsigned long.
19997 (handle_query): Update format specifiers.
19998 (handle_v_cont, main): Use strtoul for thread IDs.
19999 * server.h (struct inferior_list_entry): Use unsigned long for ID.
20000 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
20001 (general_thread, step_thread, thread_from_wait)
20002 (old_thread_from_wait): Update.
20003 * target.h (struct thread_resume): Use unsigned long for THREAD.
20004 (struct target_ops): Use unsigned long for arguments to attach and
20005 thread_alive.
20006
dcdb98d2
DJ
200072005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
20008
20009 * acinclude.m4: Include bfd/bfd.m4 directly.
20010 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
20011 <agriffis@toolchain.org>.
20012 * aclocal.m4, configure: Regenerated.
20013
bec39cab
AC
200142005-01-07 Andrew Cagney <cagney@gnu.org>
20015
20016 * configure.ac: Rename configure.in, require autoconf 2.59.
20017 * configure: Re-generate.
20018
434c4c77
DJ
200192004-12-08 Daniel Jacobowitz <dan@debian.org>
20020
20021 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
20022 LIBS when finished.
20023 * aclocal.m4: Regenerated.
20024 * configure: Regenerated.
20025
db1d3e1b
AS
200262004-11-21 Andreas Schwab <schwab@suse.de>
20027
20028 * linux-m68k-low.c (m68k_num_gregs): Define.
20029 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
20030 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
20031 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
20032 (m68k_breakpoint_at): New. Add to the_low_target.
20033
20034 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
20035 srv_linux_thread_db to yes.
20036
43360365
JB
200372004-10-20 Joel Brobecker <brobecker@gnat.com>
20038
20039 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
20040 (ARCH_SET_FS): Likewise.
20041 (ARCH_GET_FS): Likewise.
20042 (ARCH_GET_GS): Likewise.
20043
fd500816
DJ
200442004-10-16 Daniel Jacobowitz <dan@debian.org>
20045
20046 * linux-i386-low.c (ps_get_thread_area): New.
20047 * linux-x86-64-low.c (ps_get_thread_area): New.
20048 * linux-low.c: Include <sys/syscall.h>.
20049 (linux_kill_one_process): Don't kill the first thread here.
20050 (linux_kill): Kill the first thread here.
20051 (kill_lwp): New function.
20052 (send_sigstop, linux_send_signal): Use it.
20053 * proc-service.c: Clean up #ifdefs.
20054 (fpregset_info): Delete.
20055 (ps_lgetregs): Update and enable implementation.
20056 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
20057 implementations.
20058 * remote-utils.c (struct sym_cache, symbol_cache): New.
20059 (input_interrupt): Print a clearer message.
20060 (async_io_enabled): New variable.
20061 (enable_async_io, disable_async_io): Use it. Update comments.
20062 (look_up_one_symbol): Use the symbol cache.
20063 * thread-db.c (thread_db_look_up_symbols): New function.
20064 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
20065
f6de3c42
DJ
200662004-10-16 Daniel Jacobowitz <dan@debian.org>
20067
20068 * configure.in: Test for -rdynamic.
20069 * configure: Regenerated.
20070 * Makefile (INTERNAL_LDFLAGS): New.
20071 (gdbserver, gdbreplay): Use it.
20072
2c0fc042
AC
200732004-09-02 Andrew Cagney <cagney@gnu.org>
20074
20075 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
20076
075b3282
DJ
200772004-03-23 Daniel Jacobowitz <drow@mvista.com>
20078
20079 * linux-low.c (linux_wait): Clear all_processes list also.
20080
fa6a77dc
DJ
200812004-03-12 Daniel Jacobowitz <drow@mvista.com>
20082
20083 * linux-low.c: Include <errno.h>. Remove extern declaration of
20084 errno.
20085
6d782a97
DJ
200862004-03-12 Daniel Jacobowitz <drow@mvista.com>
20087
20088 * gdbreplay.c, server.h, utils.c: Update copyright years.
20089
3a7fb99b
DJ
200902004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
20091
20092 * server.c (main): Print child status or termination signal from
20093 variable 'signal', not 'sig'.
20094
c3e735a6
DJ
200952004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
20096
20097 * linux-low.c (linux_read_memory): Change return type to
20098 int. Check for and return error from ptrace().
20099 * target.c (read_inferior_memory): Change return type to int. Pass
20100 back return status from the_target->read_memory().
20101 * target.h (struct target_ops): Adapt *read_memory() prototype.
20102 Update comment.
20103 (read_inferior_memory): Adapt prototype.
20104 * server.c (main): Return an error packet if
20105 read_inferior_memory() returns an error.
20106
a59d1c82
DJ
201072004-03-04 Daniel Jacobowitz <drow@mvista.com>
20108
20109 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
20110 Unify with other clean targets.
20111
dc3f8883
DJ
201122004-02-29 Daniel Jacobowitz <drow@mvista.com>
20113
20114 * server.c (handle_v_cont): Call set_desired_inferior.
20115
89a208da
DJ
201162004-02-29 Daniel Jacobowitz <drow@mvista.com>
20117
20118 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
20119
62ea82f5
DJ
201202004-02-29 Daniel Jacobowitz <drow@mvista.com>
20121
20122 * linux-low.c (linux_wait): Unblock async I/O.
20123 (linux_resume): Block and enable async I/O.
20124 * remote-utils.c (block_async_io, unblock_async_io): New functions.
20125 * server.h (block_async_io, unblock_async_io): Add prototypes.
20126
6910d122
DJ
201272004-02-29 Daniel Jacobowitz <drow@mvista.com>
20128
20129 * remote-utils.c (remote_open): Print a status notice after
20130 opening a TCP port.
20131 * server.c (attach_inferior): Print a status notice after
20132 attaching.
20133
201342004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
20135
20136 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
20137
c89dc5d4
DJ
201382004-02-26 Daniel Jacobowitz <drow@mvista.com>
20139
20140 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
20141 error packet.
20142 * server.c, target.h: Update copyright years.
20143
4b8dad4a
RM
201442004-02-25 Roland McGrath <roland@redhat.com>
20145
20146 * target.h (struct target_ops): New member `read_auxv'.
20147 * server.c (handle_query): Handle qPart:auxv:read: query using that.
20148 * linux-low.c (linux_read_auxv): New function.
20149 (linux_target_ops): Initialize `read_auxv' member to that.
20150
d7446758
JB
201512004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
20152
20153 Committed by Jim Blandy <jimb@redhat.com>.
20154
20155 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 20156 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
20157 instead of GPR_SIZE to distiguish s390 and s390x targets.
20158
5544ad89
DJ
201592004-01-31 Daniel Jacobowitz <drow@mvista.com>
20160
20161 * linux-low.c: Update copyright year.
20162 (check_removed_breakpoint): Clear pending_is_breakpoint.
20163 (linux_set_resume_request, linux_queue_one_thread)
20164 (resume_status_pending_p): New functions.
20165 (linux_continue_one_thread): Use process->resume.
20166 (linux_resume): Only resume threads if there are no pending events.
20167 * linux-low.h (struct process_info): Add resume request
20168 pointer.
20169
2a68b70e
DJ
201702004-01-30 Daniel Jacobowitz <drow@mvista.com>
20171
20172 * regcache.c (new_register_cache): Clear the allocated register
20173 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
20174
64386c31
DJ
201752003-10-13 Daniel Jacobowitz <drow@mvista.com>
20176
20177 * linux-low.c (linux_resume): Take a struct thread_resume *
20178 argument.
20179 (linux_wait): Update call.
20180 (resume_ptr): New static variable.
20181 (linux_continue_one_thread): Renamed from
20182 linux_continue_one_process. Use resume_ptr.
20183 (linux_resume): Use linux_continue_one_thread.
20184 * server.c (handle_v_cont, handle_v_requests): New functions.
20185 (myresume): New function.
20186 (main): Handle 'v' case.
20187 * target.h (struct thread_resume): New type.
20188 (struct target_ops): Change argument of "resume" to struct
20189 thread_resume *.
20190 (myresume): Delete macro.
20191
c938e9b0
L
201922003-08-08 H.J. Lu <hongjiu.lu@intel.com>
20193
20194 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
20195 (uninstall): Support DESTDIR.
20196
7f313d07
BC
20197Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
20198
20199 * configure.srv: Add xscale*linux copy of arm*linux entry.
20200
3b2fc2ea
DJ
202012003-07-24 Daniel Jacobowitz <drow@mvista.com>
20202
20203 * linux-arm-low.c (arm_reinsert_addr): New function.
20204 (the_low_target): Add arm_reinsert_addr.
20205
1c0a559e
MK
202062003-07-08 Mark Kettenis <kettenis@gnu.org>
20207
20208 * mem-break.c: Remove whitespace at end of file.
20209
43d5792c
DJ
202102003-06-28 Daniel Jacobowitz <drow@mvista.com>
20211
20212 * configure.in: Check whether we need to prototype strerror.
20213 * server.h: Optionally prototype strerror.
20214 * gdbreplay.c (perror_with_name): Use strerror.
20215 * linux-low.c (linux_attach_lwp): Use strerror.
20216 * utils.c (perror_with_name): Use strerror.
20217 * config.in, configure: Regenerated.
20218
c8a86edf
DJ
202192003-06-28 Daniel Jacobowitz <drow@mvista.com>
20220
20221 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
20222 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
20223
73d37363
DJ
202242003-06-20 Daniel Jacobowitz <drow@mvista.com>
20225
20226 * Makefile.in (SFILES): Update.
20227 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
20228 low-sun3.c: Remove files.
20229
6ad8ae5c
DJ
202302003-06-17 Daniel Jacobowitz <drow@mvista.com>
20231
20232 * linux-low.c: Move comment to linux_thread_alive where it belonged.
20233 (linux_detach_one_process, linux_detach): New functions.
20234 (linux_target_ops): Add linux_detach.
20235 * server.c (main): Handle 'D' packet.
20236 * target.h (struct target_ops): Add "detach" member.
20237 (detach_inferior): Define.
20238
1581182a
MK
202392003-06-13 Mark Kettenis <kettenis@gnu.org>
20240
20241 From Kelley Cook <kelleycook@wideopenwest.com>:
20242 * configure.srv: Accept i[34567]86 variants.
20243
e5379b03
DJ
202442003-06-05 Daniel Jacobowitz <drow@mvista.com>
20245
20246 * linux-low.c (linux_wait_for_event): Correct comment typos.
20247 (linux_resume_one_process): Call check_removed_breakpoint.
20248 (linux_send_signal): New function.
20249 (linux_target_ops): Add linux_send_signal.
20250 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
20251 of kill.
20252 * target.h (struct target_ops): Add send_signal.
20253
2ff29de4
JB
202542003-05-29 Jim Blandy <jimb@redhat.com>
20255
20256 * linux-low.c (usr_store_inferior_registers): Transfer buf in
20257 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
20258 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
20259 away part of the register's value.
20260
254787d4
DJ
202612003-03-26 Daniel Jacobowitz <drow@mvista.com>
20262
20263 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
20264 (linux_wait_for_event, linux_init_signals): Likewise.
20265
94e10508
DJ
202662003-03-17 Daniel Jacobowitz <drow@mvista.com>
20267
20268 * configure.in: Check for stdlib.h.
20269 * configure: Regenerated.
20270 * config.in: Regenerated.
20271
4c0711e0
DJ
202722003-01-04 Andreas Schwab <schwab@suse.de>
20273
20274 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
20275
ef66e766
AC
202762003-01-02 Andrew Cagney <ac131313@redhat.com>
20277
20278 * Makefile.in: Remove obsolete code.
20279
a1358604
DJ
202802002-11-20 Daniel Jacobowitz <drow@mvista.com>
20281
20282 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
20283 defined(PT_FPR0_HI).
20284
23ce3b1c
DJ
202852002-11-17 Stuart Hughes <seh@zee2.com>
20286
20287 * linux-arm-low.c (arm_num_regs): Increase.
20288 (arm_regmap): Include status register.
20289
202902002-11-17 Daniel Jacobowitz <drow@mvista.com>
20291
20292 * linux-low.c (register_addr): Remove incorrect -1 check.
20293
a9fa9f7d
DJ
202942002-08-29 Daniel Jacobowitz <drow@mvista.com>
20295
20296 * linux-low.c (linux_create_inferior): Call setpgid. Return
20297 the new PID.
20298 (unstopped_p, linux_signal_pid): Remove.
20299 (linux_target_ops): Remove linux_signal_pid.
20300 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
20301 global instead of target method.
20302 * target.h (struct target_ops): Remove signal_pid. Update comment
20303 for create_inferior.
20304 * server.c (signal_pid): New variable.
20305 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 20306 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
20307 (attach_inferior): Set signal_pid.
20308
17574093
DJ
203092002-08-23 Daniel Jacobowitz <drow@mvista.com>
20310
20311 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
20312
203132002-08-20 Jim Blandy <jimb@redhat.com>
20314
20315 * Makefile.in (LDFLAGS): Allow the configure script to establish a
20316 default for this.
20317
203182002-08-01 Andrew Cagney <cagney@redhat.com>
20319
20320 * Makefile.in: Make chill references obsolete.
20321
203222002-07-24 Kevin Buettner <kevinb@redhat.com>
20323
20324 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
20325 * configure: Regenerate.
20326 * config.in: Regenerate.
20327
203282002-07-09 David O'Brien <obrien@FreeBSD.org>
20329
20330 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
20331 (perror_with_name, remote_close, remote_open, expect, play): Static.
20332
203332002-07-04 Michal Ludvig <mludvig@suse.cz>
20334
4b8dad4a 20335 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
20336 byte offsets instead of an array of indexes.
20337 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
20338
203392002-06-13 Daniel Jacobowitz <drow@mvista.com>
20340
20341 * regcache.c: Add comment.
20342
203432002-06-11 Daniel Jacobowitz <drow@mvista.com>
20344
20345 * thread-db.c: New file.
20346 * proc-service.c: New file.
20347 * acinclude.m4: New file.
20348 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
20349 proc-service.o, and thread-db.o.
20350 (linux-low.o): Add USE_THREAD_DB.
20351 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
20352 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
20353 * aclocal.m4: Regenerated.
20354 * config.in: Regenerated.
20355 * configure: Regenerated.
20356 * configure.in: Check for proc_service.h, sys/procfs.h,
20357 thread_db.h, and linux/elf.h headrs.
20358 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
20359 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
20360 Check for -lthread_db and thread support.
20361 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
20362 PowerPC, and SuperH.
20363 * i387-fp.c: Constify arguments.
20364 * i387-fp.h: Likewise.
20365 * inferiors.c: (struct thread_info): Renamed from
20366 `struct inferior_info'. Remove PID member. Use generic inferior
20367 list header. All uses updated.
20368 (inferiors, signal_pid): Removed.
20369 (all_threads): New variable.
20370 (get_thread): Define.
20371 (add_inferior_to_list): New function.
20372 (for_each_inferior): New function.
20373 (change_inferior_id): New function.
20374 (add_inferior): Removed.
20375 (remove_inferior): New function.
20376 (add_thread): New function.
20377 (free_one_thread): New function.
20378 (remove_thread): New function.
20379 (clear_inferiors): Use for_each_inferior and free_one_thread.
20380 (find_inferior): New function.
20381 (find_inferior_id): New function.
20382 (inferior_target_data): Update argument type.
20383 (set_inferior_target_data): Likewise.
20384 (inferior_regcache_data): Likewise.
20385 (set_inferior_regcache_data): Likewise.
20386 * linux-low.c (linux_bp_reinsert): Remove.
20387 (all_processes, stopping_threads, using_thrads)
20388 (struct pending_signals, debug_threads, pid_of): New.
20389 (inferior_pid): Replace with macro.
20390 (struct inferior_linux_data): Remove.
20391 (get_stop_pc, add_process): New functions.
20392 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
20393 Use add_process and add_thread.
20394 (linux_attach_lwp): New function, based on old linux_attach. Use
20395 add_process and add_thread. Set stop_expected for new threads.
20396 (linux_attach): New function.
20397 (linux_kill_one_process): New function.
20398 (linux_kill): Kill all LWPs.
20399 (linux_thread_alive): Use find_inferior_id.
20400 (check_removed_breakpoints, status_pending_p): New functions.
20401 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
20402 Update. Use WNOHANG. Wait for cloned processes also. Update process
20403 struct for the found process.
20404 (linux_wait_for_event): New function.
20405 (linux_wait): Use it. Support LWPs.
20406 (send_sigstop, wait_for_sigstop, stop_all_processes)
20407 (linux_resume_one_process, linux_continue_one_process): New functions.
20408 (linux_resume): Support LWPs.
20409 (REGISTER_RAW_SIZE): Remove.
20410 (fetch_register): Use register_size instead. Call supply_register.
20411 (usr_store_inferior_registers): Likewise. Call collect_register.
20412 Fix recursive case.
20413 (regsets_fetch_inferior_registers): Improve error message.
20414 (regsets_store_inferior_registers): Add debugging.
20415 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
20416 (unstopped_p, linux_signal_pid): New functions.
20417 (linux_target_ops): Add linux_signal_pid.
20418 (linux_init_signals): New function.
20419 (initialize_low): Call it. Initialize using_threads.
20420 * regcache.c (inferior_regcache_data): Add valid
20421 flag.
20422 (get_regcache): Fetch registers lazily. Add fetch argument
20423 and update all callers.
20424 (regcache_invalidate_one, regcache_invalidate): New
20425 functions.
20426 (new_register_cache): Renamed from create_register_cache.
20427 Return the new regcache.
20428 (free_register_cache): Change argument to a void *.
20429 (registers_to_string, registers_from_string): Call get_regcache
20430 with fetch flag set.
20431 (register_data): Make static. Pass fetch flag to get_regcache.
20432 (supply_register): Call get_regcache with fetch flag clear.
20433 (collect_register): Call get_regcache with fetch flag set.
20434 (collect_register_as_string): New function.
20435 * regcache.h: Update.
20436 * remote-utils.c (putpkt): Flush after debug output and use
20437 stderr.
20438 Handle input interrupts while waiting for an ACK.
20439 (input_interrupt): Use signal_pid method.
20440 (getpkt): Flush after debug output and use stderr.
20441 (outreg): Use collect_register_as_string.
20442 (new_thread_notify, dead_thread_notify): New functions.
20443 (prepare_resume_reply): Check using_threads. Set thread_from_wait
20444 and general_thread.
20445 (look_up_one_symbol): Flush after debug output.
20446 * server.c (step_thread, server_waiting): New variables.
20447 (start_inferior): Don't use signal_pid. Update call to mywait.
20448 (attach_inferior): Update call to mywait.
20449 (handle_query): Handle qfThreadInfo and qsThreadInfo.
20450 (main): Don't fetch/store registers explicitly. Use
20451 set_desired_inferior. Support proposed ``Hs'' packet. Update
20452 calls to mywait.
20453 * server.h: Update.
20454 (struct inferior_list, struct_inferior_list_entry): New.
20455 * target.c (set_desired_inferior): New.
20456 (write_inferior_memory): Constify.
20457 (mywait): New function.
20458 * target.h: Update.
20459 (struct target_ops): New signal_pid method.
20460 (mywait): Removed macro, added prototype.
20461
20462 * linux-low.h (regset_func): Removed.
20463 (regset_fill_func, regset_store_func): New.
20464 (enum regset_type): New.
20465 (struct regset_info): Add type field. Use new operation types.
20466 (struct linux_target_ops): stop_pc renamed to get_pc.
20467 Add decr_pc_after_break and breakpoint_at.
20468 (get_process, get_thread_proess, get_process_thread)
20469 (strut process_info, all_processes, linux_attach_lwp)
20470 (thread_db_init): New.
20471
20472 * linux-arm-low.c (arm_get_pc, arm_set_pc,
20473 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
20474 (the_low_target): Add new members.
20475 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
20476 (i386_store_fpxregset): Constify.
20477 (target_regsets): Add new kind identifier.
20478 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
20479 (i386_set_pc): Add debugging.
20480 (i386_breakpoint_at): New function.
20481 (the_low_target): Add new members.
20482 * linux-mips-low.c (mips_get_pc, mips_set_pc)
20483 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
20484 (mips_breakpoint_at): New.
20485 (the_low_target): Add new members.
20486 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
20487 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
20488 (the_low_target): Add new members.
20489 * linux-sh-low.c (sh_get_pc, sh_set_pc)
20490 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
20491 (the_low_target): Add new members.
20492 * linux-x86-64-low.c (target_regsets): Add new kind
20493 identifier.
20494
204952002-05-15 Daniel Jacobowitz <drow@mvista.com>
20496
20497 From Martin Pool <mbp@samba.org>:
20498 * server.c (gdbserver_usage): New function.
20499 (main): Call it.
20500
205012002-05-14 Daniel Jacobowitz <drow@mvista.com>
20502
20503 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
20504 stop_at -> stop_pc.
20505
205062002-05-04 Andrew Cagney <ac131313@redhat.com>
20507
20508 * Makefile.in: Remove obsolete code.
20509
205102002-04-24 Michal Ludvig <mludvig@suse.cz>
20511
20512 * linux-low.c (regsets_fetch_inferior_registers),
20513 (regsets_store_inferior_registers): Removed cast to int from
20514 ptrace() calls.
20515 * regcache.h: Added declaration of struct inferior_info.
20516
205172002-04-20 Daniel Jacobowitz <drow@mvista.com>
20518
20519 * inferiors.c (struct inferior_info): Add regcache_data.
20520 (add_inferior): Call create_register_cache.
20521 (clear_inferiors): Call free_register_cache.
20522 (inferior_regcache_data, set_inferior_regcache_data): New functions.
20523 * regcache.c (struct inferior_regcache_data): New.
20524 (registers): Remove.
20525 (get_regcache): New function.
20526 (create_register_cache, free_register_cache): New functions.
20527 (set_register_cache): Don't initialize the register cache here.
20528 (registers_to_string, registers_from_string, register_data): Call
20529 get_regcache.
20530 * regcache.h: Add prototypes.
20531 * server.h: Likewise.
20532
205332002-04-20 Daniel Jacobowitz <drow@mvista.com>
20534
20535 * mem-break.c: New file.
20536 * mem-break.h: New file.
20537 * Makefile.in: Add mem-break.o rule; update server.h
20538 dependencies.
20539 * inferiors.c (struct inferior_info): Add target_data
20540 member.
20541 (clear_inferiors): Free target_data member if set.
20542 (inferior_target_data, set_inferior_target_data): New functions.
20543 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
20544 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
20545 * linux-low.c (linux_bp_reinsert): New variable.
20546 (struct inferior_linux_data): New.
20547 (linux_create_inferior): Use set_inferior_target_data.
20548 (linux_attach): Likewise. Call add_inferior.
20549 (linux_wait_for_one_inferior): New function.
20550 (linux_wait): Call it.
20551 (linux_write_memory): Add const.
20552 (initialize_low): Call set_breakpoint_data.
20553 * linux-low.h (struct linux_target_ops): Add breakpoint
20554 handling members.
20555 * server.c (attach_inferior): Remove extra add_inferior
20556 call.
20557 * server.h: Include mem-break.h. Update inferior.c
20558 prototypes.
20559 * target.c (read_inferior_memory)
20560 (write_inferior_memory): New functions.
20561 * target.h (read_inferior_memory)
20562 (write_inferior_memory): Change macros to prototypes.
20563 (struct target_ops): Update comments. Add const to write_memory
20564 definition.
20565
205662002-04-11 Daniel Jacobowitz <drow@mvista.com>
20567
20568 * linux-low.c (usr_store_inferior_registers): Support
20569 registers which are allowed to fail to store.
20570 * linux-low.h (linux_target_ops): Likewise.
20571 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
20572 (ppc_cannot_store_register): FPSCR may not be storable.
20573
205742002-04-09 Daniel Jacobowitz <drow@mvista.com>
20575
20576 * server.h: Include <string.h> if HAVE_STRING_H.
20577 * ChangeLog: Correct paths in last ChangeLog entry.
20578
205792002-04-09 Daniel Jacobowitz <drow@mvista.com>
20580
20581 * linux-low.h: Remove obsolete prototypes.
20582 (struct linux_target_ops): New.
20583 (extern the_low_target): New.
20584 * linux-low.c (num_regs, regmap): Remove declarations.
20585 (register_addr): Use the_low_target explicitly.
20586 (fetch_register): Likewise.
20587 (usr_fetch_inferior_registers): Likewise.
20588 (usr_store_inferior_registers): Likewise.
20589 * linux-arm-low.c (num_regs): Remove.
20590 (arm_num_regs): Define.
20591 (arm_regmap): Renamed from regmap, made static.
20592 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
20593 made static.
20594 (arm_cannot_store_register): Renamed from cannot_store_register,
20595 made static.
20596 (the_low_target): New.
20597 * linux-i386-low.c (num_regs): Remove.
20598 (i386_num_regs): Define.
20599 (i386_regmap): Renamed from regmap, made static.
20600 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
20601 made static.
20602 (i386_cannot_store_register): Renamed from cannot_store_register,
20603 made static.
20604 (the_low_target): New.
20605 * linux-ia64-low.c (num_regs): Remove.
20606 (ia64_num_regs): Define.
20607 (ia64_regmap): Renamed from regmap, made static.
20608 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
20609 made static.
20610 (ia64_cannot_store_register): Renamed from cannot_store_register,
20611 made static.
20612 (the_low_target): New.
20613 * linux-m68k-low.c (num_regs): Remove.
20614 (m68k_num_regs): Define.
20615 (m68k_regmap): Renamed from regmap, made static.
20616 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
20617 made static.
20618 (m68k_cannot_store_register): Renamed from cannot_store_register,
20619 made static.
20620 (the_low_target): New.
20621 * linux-mips-low.c (num_regs): Remove.
20622 (mips_num_regs): Define.
20623 (mips_regmap): Renamed from regmap, made static.
20624 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
20625 made static.
20626 (mips_cannot_store_register): Renamed from cannot_store_register,
20627 made static.
20628 (the_low_target): New.
20629 * linux-ppc-low.c (num_regs): Remove.
20630 (ppc_num_regs): Define.
20631 (ppc_regmap): Renamed from regmap, made static.
20632 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
20633 made static.
20634 (ppc_cannot_store_register): Renamed from cannot_store_register,
20635 made static.
20636 (the_low_target): New.
20637 * linux-s390-low.c (num_regs): Remove.
20638 (s390_num_regs): Define.
20639 (s390_regmap): Renamed from regmap, made static.
20640 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
20641 made static.
20642 (s390_cannot_store_register): Renamed from cannot_store_register,
20643 made static.
20644 (the_low_target): New.
20645 * linux-sh-low.c (num_regs): Remove.
20646 (sh_num_regs): Define.
20647 (sh_regmap): Renamed from regmap, made static.
20648 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
20649 made static.
20650 (sh_cannot_store_register): Renamed from cannot_store_register,
20651 made static.
20652 (the_low_target): New.
20653 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
20654 (the_low_target): New.
20655
206562002-04-09 Daniel Jacobowitz <drow@mvista.com>
20657
20658 * Makefile.in: Add stamp-h target.
20659 * configure.in: Create stamp-h.
20660 * configure: Regenerated.
20661
206622002-04-09 Daniel Jacobowitz <drow@mvista.com>
20663
20664 * inferiors.c: New file.
20665 * target.c: New file.
20666 * target.h: New file.
20667 * Makefile.in: Add target.o and inferiors.o. Update
20668 dependencies.
20669 * linux-low.c (inferior_pid): New static variable,
20670 moved from server.c.
20671 (linux_create_inferior): Renamed from create_inferior.
20672 Call add_inferior. Return 0 on success instead of a PID.
20673 (linux_attach): Renamed from myattach.
20674 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
20675 (linux_thread_alive): Renamed from mythread_alive.
20676 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
20677 child dies.
20678 (linux_resume): Renamed from myresume. Add missing ``return 0''.
20679 (regsets_store_inferior_registers): Correct error message.
20680 Add missing ``return 0''.
20681 (linux_fetch_registers): Renamed from fetch_inferior_registers.
20682 (linux_store_registers): Renamed from store_inferior_registers.
20683 (linux_read_memory): Renamed from read_inferior_memory.
20684 (linux_write_memory): Renamed from write_inferior_memory.
20685 (linux_target_ops): New structure.
20686 (initialize_low): Call set_target_ops ().
20687 * remote-utils.c (unhexify): New function.
20688 (hexify): New function.
20689 (input_interrupt): Send signals to ``signal_pid''.
20690 * server.c (inferior_pid): Remove.
20691 (start_inferior): Update create_inferior call.
20692 (attach_inferior): Call add_inferior.
20693 (handle_query): New function.
20694 (main): Call handle_query for `q' packets.
20695 * server.h: Include "target.h". Remove obsolete prototypes.
20696 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
20697
206982002-04-09 Daniel Jacobowitz <drow@mvista.com>
20699
20700 * Makefile.in: Add WARN_CFLAGS. Update configury
20701 dependencies.
20702 * configure.in: Check for <string.h>
20703 * configure: Regenerate.
20704 * config.in: Regenerate.
20705 * gdbreplay.c: Include needed system headers.
20706 (remote_open): Remove strchr prototype.
20707 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
20708 * regcache.c (supply_register): Change buf argument to const void *.
20709 (supply_register_by_name): Likewise.
20710 (collect_register): Change buf argument to void *.
20711 (collect_register_by_name): Likewise.
20712 * regcache.h: Add missing prototypes.
20713 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
20714 * server.c (handle_query): New function.
20715 (attached): New static variable, moved out of main.
20716 (main): Quiet longjmp clobber warnings.
20717 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
20718 * utils.c (error): Remove NORETURN.
20719 (fatal): Likewise.