a7689caeea36bf924442574e66f3aae171cceb91
[deliverable/binutils-gdb.git] / gdbserver / ChangeLog
1 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2
3 Remove the 'install_fast_tracepoint_jump_pad' and
4 'get_min_fast_tracepoint_insn_len' linux target ops to let the
5 concrete linux target define the ops by overriding the declarations
6 of process_stratum_target.
7
8 * linux-low.h (struct linux_target_ops): Remove the ops.
9 (class linux_process_target) <supports_fast_tracepoints>
10 <install_fast_tracepoint_jump_pad>
11 <get_min_fast_tracepoint_insn_len>: Remove.
12 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
13 (linux_process_target::install_fast_tracepoint_jump_pad)
14 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
15 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
16 <install_fast_tracepoint_jump_pad>
17 <get_min_fast_tracepoint_insn_len>: Declare.
18 (x86_target::supports_fast_tracepoints): Define.
19 (x86_install_fast_tracepoint_jump_pad): Turn into...
20 (x86_target::install_fast_tracepoint_jump_pad): ...this.
21 (x86_get_min_fast_tracepoint_insn_len): Turn into...
22 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
23 (the_low_target): Remove the op fields.
24 * linux-aarch64-low.cc (class aarch64_target)
25 <supports_fast_tracepoints>
26 <install_fast_tracepoint_jump_pad>
27 <get_min_fast_tracepoint_insn_len>: Declare.
28 (aarch64_target::supports_fast_tracepoints): Define.
29 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
30 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
31 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
32 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
33 (the_low_target): Remove the op fields.
34 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
35 <install_fast_tracepoint_jump_pad>
36 <get_min_fast_tracepoint_insn_len>: Declare.
37 (ppc_target::supports_fast_tracepoints): Define.
38 (ppc_install_fast_tracepoint_jump_pad): Turn into...
39 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
40 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
41 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
42 (the_low_target): Remove the op fields.
43 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
44 <install_fast_tracepoint_jump_pad>
45 <get_min_fast_tracepoint_insn_len>: Declare.
46 (s390_target::supports_fast_tracepoints): Define.
47 (s390_install_fast_tracepoint_jump_pad): Turn into...
48 (s390_target::install_fast_tracepoint_jump_pad): ...this.
49 (s390_get_min_fast_tracepoint_insn_len): Turn into...
50 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
51 (the_low_target): Remove the op fields.
52 * linux-arm-low.cc (the_low_target): Remove the op fields.
53 * linux-bfin-low.cc (the_low_target): Ditto.
54 * linux-crisv32-low.cc (the_low_target): Ditto.
55 * linux-m32r-low.cc (the_low_target): Ditto.
56 * linux-m68k-low.cc (the_low_target): Ditto.
57 * linux-sh-low.cc (the_low_target): Ditto.
58 * linux-tic6x-low.cc (the_low_target): Ditto.
59 * linux-tile-low.cc (the_low_target): Ditto.
60 * linux-xtensa-low.cc (the_low_target): Ditto.
61
62 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
63
64 Turn the 'get_thread_area' linux target op into a method of
65 process_stratum_target.
66
67 * linux-low.h (struct linux_target_ops): Remove the op.
68 (class linux_process_target) <stuck_in_jump_pad>
69 <linux_fast_tracepoint_collecting>
70 <low_get_thread_area>: Declare.
71 * linux-low.cc (supports_fast_tracepoints): Remove.
72 (linux_fast_tracepoint_collecting): Turn into...
73 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
74 (linux_process_target::low_get_thread_area): Define.
75 (stuck_in_jump_pad_callback): Turn into...
76 (linux_process_target::stuck_in_jump_pad): ...this.
77
78 Update the caller below.
79
80 (linux_process_target::stabilize_threads)
81
82 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
83 Declare.
84 (x86_get_thread_area): Turn into...
85 (x86_target::low_get_thread_area): ...this.
86 (the_low_target): Remove the op field.
87 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
88 Declare.
89 (aarch64_get_thread_area): Turn into...
90 (aarch64_target::low_get_thread_area): ...this.
91 (the_low_target): Remove the op field.
92 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
93 Declare.
94 (ppc_get_thread_area): Turn into...
95 (ppc_target::low_get_thread_area): ...this.
96 (the_low_target): Remove the op field.
97 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
98 Declare.
99 (s390_get_thread_area): Turn into...
100 (s390_target::low_get_thread_area): ...this.
101 (the_low_target): Remove the op field.
102 * linux-arm-low.cc (the_low_target): Remove the op field.
103 * linux-bfin-low.cc (the_low_target): Ditto.
104 * linux-crisv32-low.cc (the_low_target): Ditto.
105 * linux-m32r-low.cc (the_low_target): Ditto.
106 * linux-m68k-low.cc (the_low_target): Ditto.
107 * linux-sh-low.cc (the_low_target): Ditto.
108 * linux-tic6x-low.cc (the_low_target): Ditto.
109 * linux-tile-low.cc (the_low_target): Ditto.
110 * linux-xtensa-low.cc (the_low_target): Ditto.
111
112 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
113
114 Remote the 'supports_tracepoints' linux target op and let the
115 concrete linux target define it by overriding the op declared in
116 process_stratum_target.
117
118 * linux-low.h (struct linux_target_ops): Remove the op.
119 (class linux_process_target) <supports_tracepoints>: Remove.
120 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
121 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
122 Declare.
123 (x86_supports_tracepoints): Turn into...
124 (x86_target::supports_tracepoints): ...this.
125 (the_low_target): Remove the op field.
126 * linux-aarch64-low.cc (class aarch64_target)
127 <supports_tracepoints>: Declare.
128 (aarch64_supports_tracepoints): Turn into...
129 (aarch64_target::supports_tracepoints): ...this.
130 (the_low_target): Remove the op field.
131 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
132 Declare.
133 (ppc_supports_tracepoints): Turn into...
134 (ppc_target::supports_tracepoints): ...this.
135 (the_low_target): Remove the op field.
136 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
137 Declare.
138 (s390_supports_tracepoints): Turn into...
139 (s390_target::supports_tracepoints): ...this.
140 (the_low_target): Remove the op field.
141 * linux-arm-low.cc (the_low_target): Remove the op field.
142 * linux-bfin-low.cc (the_low_target): Ditto.
143 * linux-crisv32-low.cc (the_low_target): Ditto.
144 * linux-m32r-low.cc (the_low_target): Ditto.
145 * linux-m68k-low.cc (the_low_target): Ditto.
146 * linux-sh-low.cc (the_low_target): Ditto.
147 * linux-tic6x-low.cc (the_low_target): Ditto.
148 * linux-tile-low.cc (the_low_target): Ditto.
149 * linux-xtensa-low.cc (the_low_target): Ditto.
150
151 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
152
153 Remove the 'process_qsupported' linux target op and let a concrete
154 linux target define the op by overriding the op declaration in
155 process_stratum_target.
156
157 * linux-low.h (struct linux_target_ops): Remove the op.
158 (class linux_process_target) <process_qsupported>: Remove.
159 * linux-low.cc (linux_process_target::process_qsupported): Remove.
160 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
161 (x86_linux_process_qsupported): Turn into...
162 (x86_target::process_qsupported): ...this.
163 (the_low_target): Remove the op field.
164 * linux-aarch64-low.cc (the_low_target): Remove the op
165 field.
166 * linux-arm-low.cc (the_low_target): Ditto.
167 * linux-bfin-low.cc (the_low_target): Ditto.
168 * linux-crisv32-low.cc (the_low_target): Ditto.
169 * linux-m32r-low.cc (the_low_target): Ditto.
170 * linux-m68k-low.cc (the_low_target): Ditto.
171 * linux-ppc-low.cc (the_low_target): Ditto.
172 * linux-s390-low.cc (the_low_target): Ditto.
173 * linux-sh-low.cc (the_low_target): Ditto.
174 * linux-tic6x-low.cc (the_low_target): Ditto.
175 * linux-tile-low.cc (the_low_target): Ditto.
176 * linux-xtensa-low.cc (the_low_target): Ditto.
177
178 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
179
180 Turn the 'prepare_to_resume' linux target op into a method of
181 linux_process_target.
182
183 * linux-low.h (struct linux_target_ops): Remove the op.
184 (class linux_process_target) <low_prepare_to_resume>: Declare.
185 * linux-low.cc (linux_process_target::low_prepare_to_resume):
186 Define.
187
188 Update the callers below:
189
190 (linux_process_target::resume_one_lwp_throw)
191 (linux_process_target::low_prepare_to_resume)
192
193 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
194 Declare.
195 (x86_target::low_prepare_to_resume): Define.
196 (the_low_target): Remove the op field.
197 * linux-aarch64-low.cc (class aarch64_target)
198 <low_prepare_to_resume>: Declare.
199 (aarch64_target::low_prepare_to_resume): Define.
200 (the_low_target): Remove the op field.
201 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
202 Declare.
203 (arm_prepare_to_resume): Turn into...
204 (arm_target::low_prepare_to_resume): ...this.
205 (the_low_target): Remove the op field.
206 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
207 Declare.
208 (mips_linux_prepare_to_resume): Turn into...
209 (mips_target::low_prepare_to_resume): ...this.
210 (the_low_target): Remove the op field.
211 * linux-bfin-low.cc (the_low_target): Remove the op field.
212 * linux-crisv32-low.cc (the_low_target): Ditto.
213 * linux-m32r-low.cc (the_low_target): Ditto.
214 * linux-m68k-low.cc (the_low_target): Ditto.
215 * linux-ppc-low.cc (the_low_target): Ditto.
216 * linux-s390-low.cc (the_low_target): Ditto.
217 * linux-sh-low.cc (the_low_target): Ditto.
218 * linux-tic6x-low.cc (the_low_target): Ditto.
219 * linux-tile-low.cc (the_low_target): Ditto.
220 * linux-xtensa-low.cc (the_low_target): Ditto.
221
222 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
223
224 Turn the 'new_process', 'delete_process', 'new_thread',
225 'delete_thread', and 'new_fork' linux target ops into methods
226 of linux_process_target.
227
228 * linux-low.h (struct linux_target_ops): Remove the ops.
229 (class linux_process_target) <add_linux_process>
230 <add_lwp>
231 <delete_lwp>
232 <attach_lwp>
233 <detach_one_lwp>
234 <check_zombie_leaders>
235 <filter_exit_event>
236 <low_new_process>
237 <low_delete_process>
238 <low_new_thread>
239 <low_delete_thread>
240 <low_new_fork>: Declare.
241 * linux-low.cc (delete_lwp): Turn into...
242 (linux_process_target::delete_lwp): ...this.
243 (linux_process_target::low_delete_thread): Define.
244 (linux_add_process): Turn into...
245 (linux_process_target::add_linux_process): ...this.
246 (linux_process_target::low_new_process): Define.
247 (linux_process_target::low_delete_process): Define.
248 (linux_process_target::low_new_fork): Define.
249 (add_lwp): Turn into...
250 (linux_process_target::add_lwp): ...this.
251 (linux_process_target::low_new_thread): Define.
252 (linux_attach_lwp): Turn into...
253 (linux_process_target::attach_lwp): ...this.
254 (linux_detach_one_lwp): Turn into...
255 (linux_process_target::detach_one_lwp): ...this.
256 (linux_detach_lwp_callback): Remove and inline...
257 (linux_process_target::detach): ...here.
258 (check_zombie_leaders): Turn into...
259 (linux_process_target::check_zombie_leaders): ...this.
260 (filter_exit_event): Turn into...
261 (linux_process_target::filter_exit_event): ...this.
262
263 Update the callers below.
264
265 (linux_process_target::handle_extended_wait)
266 (linux_process_target::create_inferior)
267 (attach_proc_task_lwp_callback)
268 (linux_process_target::attach)
269 (linux_process_target::detach)
270 (linux_process_target::mourn)
271 * thread-db.cc (attach_thread)
272
273 * linux-x86-low.cc (class x86_target) <low_new_process>
274 <low_delete_process>
275 <low_new_thread>
276 <low_delete_thread>
277 <low_new_fork>: Declare.
278 (x86_linux_new_process): Turn into...
279 (x86_target::low_new_process): ...this.
280 (x86_linux_delete_process): Turn into...
281 (x86_target::low_delete_process): ...this.
282 (x86_target::low_new_thread): Define.
283 (x86_target::low_delete_thread): Define.
284 (x86_linux_new_fork): Turn into...
285 (x86_target::low_new_fork): ...this.
286 (the_low_target): Remove the op fields.
287 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
288 <low_delete_process>
289 <low_new_thread>
290 <low_delete_thread>
291 <low_new_fork>: Declare.
292 (aarch64_linux_new_process): Turn into...
293 (aarch64_target::low_new_process): ...this.
294 (aarch64_linux_delete_process): Turn into...
295 (aarch64_target::low_delete_process): ...this.
296 (aarch64_target::low_new_thread): Define.
297 (aarch64_target::low_delete_thread): Define.
298 (aarch64_linux_new_fork): Turn into...
299 (aarch64_target::low_new_fork): ...this.
300 (the_low_target): Remove the op fields.
301 * linux-arm-low.cc (class arm_target) <low_new_process>
302 <low_delete_process>
303 <low_new_thread>
304 <low_delete_thread>
305 <low_new_fork>: Declare.
306 (arm_new_process): Turn into...
307 (arm_target::low_new_process): ...this.
308 (arm_delete_process): Turn into...
309 (arm_target::low_delete_process): ...this.
310 (arm_new_thread): Turn into...
311 (arm_target::low_new_thread): ...this.
312 (arm_delete_thread): Turn into...
313 (arm_target::low_delete_thread): ...this.
314 (arm_new_fork): Turn into...
315 (arm_target::low_new_fork): ...this.
316 (the_low_target): Remove the op fields.
317 * linux-mips-low.cc (class mips_target) <low_new_process>
318 <low_delete_process>
319 <low_new_thread>
320 <low_delete_thread>
321 <low_new_fork>: Declare.
322 (mips_linux_new_process): Turn into...
323 (mips_target::low_new_process): ...this.
324 (mips_linux_delete_process): Turn into...
325 (mips_target::low_delete_process): ...this.
326 (mips_linux_new_thread): Turn into...
327 (mips_target::low_new_thread): ...this.
328 (mips_linux_delete_thread): Turn into...
329 (mips_target::low_delete_thread): ...this.
330 (mips_linux_new_fork): Turn into...
331 (mips_target::low_new_fork): ...this.
332 (the_low_target): Remove the op fields.
333 * linux-bfin-low.cc (the_low_target): Remove the op fields.
334 * linux-crisv32-low.cc (the_low_target): Ditto.
335 * linux-m32r-low.cc (the_low_target): Ditto.
336 * linux-m68k-low.cc (the_low_target): Ditto.
337 * linux-ppc-low.cc (the_low_target): Ditto.
338 * linux-s390-low.cc (the_low_target): Ditto.
339 * linux-sh-low.cc (the_low_target): Ditto.
340 * linux-tic6x-low.cc (the_low_target): Ditto.
341 * linux-tile-low.cc (the_low_target): Ditto.
342 * linux-xtensa-low.cc (the_low_target): Ditto.
343
344 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
345
346 Turn the 'siginfo_fixup' linux target op into a method of
347 linux_process_target.
348
349 * linux-low.h (struct linux_target_ops): Remove the op.
350 (class linux_process_target) <siginfo_fixup>
351 <low_siginfo_fixup>: Declare.
352 * linux-low.cc (siginfo_fixup): Turn into...
353 (linux_process_target::siginfo_fixup): ...this.
354 (linux_process_target::low_siginfo_fixup): Define.
355 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
356 (x86_siginfo_fixup): Turn into...
357 (x86_target::low_siginfo_fixup): ...this.
358 (the_low_target): Remove the op field.
359 * linux-aarch64-low.cc (class aarch64_target):
360 <low_siginfo_fixup>: Declare.
361 (aarch64_linux_siginfo_fixup): Turn into...
362 (aarch64_target::low_siginfo_fixup): ...this.
363 (the_low_target): Remove the op field.
364 * linux-arm-low.cc (the_low_target): Remove the op field.
365 * linux-bfin-low.cc (the_low_target): Ditto.
366 * linux-crisv32-low.cc (the_low_target): Ditto.
367 * linux-m32r-low.cc (the_low_target): Ditto.
368 * linux-m68k-low.cc (the_low_target): Ditto.
369 * linux-mips-low.cc (the_low_target): Ditto.
370 * linux-ppc-low.cc (the_low_target): Ditto.
371 * linux-s390-low.cc (the_low_target): Ditto.
372 * linux-sh-low.cc (the_low_target): Ditto.
373 * linux-tic6x-low.cc (the_low_target): Ditto.
374 * linux-tile-low.cc (the_low_target): Ditto.
375 * linux-xtensa-low.cc (the_low_target): Ditto.
376
377 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
378
379 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
380 linux target ops into methods of linux_process_target.
381
382 * linux-low.h (struct linux_target_ops): Remove the ops.
383 (class linux_process_target) <low_collect_ptrace_register>
384 <low_store_ptrace_register>: Declare.
385 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
386 (linux_process_target::low_supply_ptrace_register): Define.
387
388 Update the callers below.
389
390 (linux_process_target::fetch_register)
391 (linux_process_target::store_register)
392
393 * linux-x86-low.cc (the_low_target): Remove the op fields.
394 * linux-aarch64-low.cc (the_low_target): Ditto.
395 * linux-arm-low.cc (the_low_target): Ditto.
396 * linux-bfin-low.cc (the_low_target): Ditto.
397 * linux-crisv32-low.cc (the_low_target): Ditto.
398 * linux-m32r-low.cc (the_low_target): Ditto.
399 * linux-m68k-low.cc (the_low_target): Ditto.
400 * linux-sh-low.cc (the_low_target): Ditto.
401 * linux-sparc-low.cc (the_low_target): Ditto.
402 * linux-tic6x-low.cc (the_low_target): Ditto.
403 * linux-tile-low.cc (the_low_target): Ditto.
404 * linux-xtensa-low.cc (the_low_target): Ditto.
405 * linux-mips-low.cc (class mips_target)
406 <low_collect_ptrace_register>
407 <low_supply_ptrace_register>: Declare.
408 (mips_collect_ptrace_register): Turn into ...
409 (mips_target::low_collect_ptrace_register): ...this.
410 (mips_supply_ptrace_register): Turn into...
411 (mips_target::low_supply_ptrace_register): ...this.
412 (the_low_target): Remove the op fields.
413 * linux-ppc-low.cc (class ppc_target)
414 <low_collect_ptrace_register>
415 <low_supply_ptrace_register>: Declare.
416 (ppc_collect_ptrace_register): Turn into ...
417 (ppc_target::low_collect_ptrace_register): ...this.
418 (ppc_supply_ptrace_register): Turn into ...
419 (ppc_target::low_supply_ptrace_register): ...this.
420 (ppc_fill_gregset): Update for the calls to
421 low_collect_ptrace_register.
422 (the_low_target): Remove the op fields.
423 * linux-s390-low.cc (class s390_target)
424 <low_collect_ptrace_register>
425 <low_supply_ptrace_register>: Declare.
426 (s390_collect_ptrace_register): Turn into ...
427 (s390_target::low_collect_ptrace_register): ...this.
428 (s390_supply_ptrace_register): Turn into ...
429 (s390_target::low_supply_ptrace_register): ...this.
430 (s390_fill_gregset): Update for the calls to
431 low_collect_ptrace_register.
432 (the_low_target): Remove the op fields.
433
434 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
435
436 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
437 target ops into methods of linux_process_target.
438
439 * linux-low.h (struct linux_target_ops): Remove the ops.
440 (class linux_process_target) <check_stopped_by_watchpoint>
441 <low_stopped_by_watchpoint>
442 <low_stopped_data_address>: Declare.
443 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
444 (linux_process_target::check_stopped_by_watchpoint): ...this.
445 (linux_process_target::low_stopped_by_watchpoint): Define.
446 (linux_process_target::low_stopped_data_address): Define.
447 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
448 <low_stopped_data_address>: Declare.
449 (x86_stopped_by_watchpoint): Turn into...
450 (x86_target::low_stopped_by_watchpoint): ...this.
451 (x86_stopped_data_address): Turn into...
452 (x86_target::low_stopped_data_address): ...this.
453 (the_low_target): Remove the op fields.
454 * linux-aarch64-low.cc (class aarch64_target)
455 <low_stopped_by_watchpoint>
456 <low_stopped_data_address>: Declare.
457 (aarch64_stopped_by_watchpoint): Turn into...
458 (aarch64_target::low_stopped_by_watchpoint): ...this.
459 (aarch64_stopped_data_address): Turn into...
460 (aarch64_target::low_stopped_data_address): ...this.
461 (the_low_target): Remove the op fields.
462 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
463 <low_stopped_data_address>: Declare.
464 (arm_stopped_by_watchpoint): Turn into...
465 (arm_target::low_stopped_by_watchpoint): ...this.
466 (arm_stopped_data_address): Turn into...
467 (arm_target::low_stopped_data_address): ...this.
468 (the_low_target): Remove the op fields.
469 * linux-crisv32-low.cc (class crisv32_target)
470 <low_stopped_by_watchpoint>
471 <low_stopped_data_address>: Declare.
472 (cris_stopped_by_watchpoint): Turn into...
473 (crisv32_target::low_stopped_by_watchpoint): ...this.
474 (cris_stopped_data_address): Turn into...
475 (crisv32_target::low_stopped_data_address): ...this.
476 (the_low_target): Remove the op fields.
477 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
478 <low_stopped_data_address>: Declare.
479 (mips_stopped_by_watchpoint): Turn into...
480 (mips_target::low_stopped_by_watchpoint): ...this.
481 (mips_stopped_data_address): Turn into...
482 (mips_target::low_stopped_data_address): ...this.
483 (the_low_target): Remove the op fields.
484 * linux-bfin-low.cc (the_low_target): Remove the op fields.
485 * linux-m32r-low.cc (the_low_target): Ditto.
486 * linux-m68k-low.cc (the_low_target): Ditto.
487 * linux-ppc-low.cc (the_low_target): Ditto.
488 * linux-s390-low.cc (the_low_target): Ditto.
489 * linux-sh-low.cc (the_low_target): Ditto.
490 * linux-sparc-low.cc (the_low_target): Ditto.
491 * linux-tic6x-low.cc (the_low_target): Ditto.
492 * linux-tile-low.cc (the_low_target): Ditto.
493 * linux-xtensa-low.cc (the_low_target): Ditto.
494
495 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
496
497 Turn the 'insert_point' and 'remove_point' linux target ops into
498 methods of linux_process_target.
499
500 * linux-low.h (struct linux_target_ops): Remove the ops.
501 (class linux_process_target) <low_insert_point>
502 <low_remove_point>: Declare.
503 * linux-low.cc (linux_process_target::low_insert_point)
504 (linux_process_target::low_remove_point): Define.
505 (linux_process_target::insert_point)
506 (linux_process_target::remove_point): Update for calls to
507 low_insert_point and low_remove_point.
508 * linux-x86-low.cc (class x86_target) <low_insert_point>
509 <low_remove_point>: Declare.
510 (x86_insert_point): Turn into...
511 (x86_target::low_insert_point): ...this.
512 (x86_remove_point): Turn into...
513 (x86_target::low_remove_point): ...this.
514 (the_low_target): Remove the op fields.
515 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
516 <low_remove_point>: Declare.
517 (aarch64_insert_point): Turn into...
518 (aarch64_target::low_insert_point): ...this.
519 (aarch64_remove_point): Turn into...
520 (aarch64_target::low_remove_point): ...this.
521 (the_low_target): Remove the op fields.
522 * linux-arm-low.cc (class arm_target) <low_insert_point>
523 <low_remove_point>: Declare.
524 (arm_insert_point): Turn into...
525 (arm_target::low_insert_point): ...this.
526 (arm_remove_point): Turn into...
527 (arm_target::low_remove_point): ...this.
528 (the_low_target): Remove the op fields.
529 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
530 <low_remove_point>: Declare.
531 (crisv32_insert_point): Turn into...
532 (crisv32_target::low_insert_point): ...this.
533 (crisv32_remove_point): Turn into...
534 (crisv32_target::low_remove_point): ...this.
535 (the_low_target): Remove the op fields.
536 * linux-mips-low.cc (class mips_target) <low_insert_point>
537 <low_remove_point>: Declare.
538 (mips_insert_point): Turn into...
539 (mips_target::low_insert_point): ...this.
540 (mips_remove_point): Turn into...
541 (mips_target::low_remove_point): ...this.
542 (the_low_target): Remove the op fields.
543 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
544 <low_remove_point>: Declare.
545 (ppc_insert_point): Turn into...
546 (ppc_target::low_insert_point): ...this.
547 (ppc_remove_point): Turn into...
548 (ppc_target::low_remove_point): ...this.
549 (the_low_target): Remove the op fields.
550 * linux-bfin-low.cc (the_low_target): Remove the op fields.
551 * linux-m32r-low.cc (the_low_target): Ditto.
552 * linux-m68k-low.cc (the_low_target): Ditto.
553 * linux-s390-low.cc (the_low_target): Ditto.
554 * linux-sh-low.cc (the_low_target): Ditto.
555 * linux-sparc-low.cc (the_low_target): Ditto.
556 * linux-tic6x-low.cc (the_low_target): Ditto.
557 * linux-tile-low.cc (the_low_target): Ditto.
558 * linux-xtensa-low.cc (the_low_target): Ditto.
559
560 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
561
562 Remove the 'supports_z_point_type' linux target op and let the
563 concrete linux target define it by overriding the op declared in
564 process_stratum_target.
565
566 * linux-low.cc (linux_process_target::supports_z_point_type):
567 Remove.
568 * linux-low.h (struct linux_target_ops): Remove the op.
569 (class linux_process_target) <supports_z_point_type>: Remove.
570 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
571 Declare.
572 (x86_supports_z_point_type): Turn into...
573 (x86_target::supports_z_point_type): ...this.
574 (the_low_target): Remove the op field.
575 * linux-aarch64-low.cc (class aarch64_target)
576 <supports_z_point_type>: Declare.
577 (aarch64_supports_z_point_type): Turn into...
578 (aarch64_target::supports_z_point_type): ...this.
579 (the_low_target): Remove the op field.
580 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
581 Declare.
582 (arm_supports_z_point_type): Turn into...
583 (arm_target::supports_z_point_type): ...this.
584 (the_low_target): Remove the op field.
585 * linux-crisv32-low.cc (class crisv32_target)
586 <supports_z_point_type>: Declare.
587 (cris_supports_z_point_type): Turn into...
588 (crisv32_target::supports_z_point_type): ...this.
589 (the_low_target): Remove the op field.
590 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
591 Declare.
592 (mips_supports_z_point_type): Turn into...
593 (mips_target::supports_z_point_type): ...this.
594 (the_low_target): Remove the op field.
595 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
596 Declare.
597 (ppc_supports_z_point_type): Turn into...
598 (ppc_target::supports_z_point_type): ...this.
599 (the_low_target): Remove the op field.
600 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
601 Declare.
602 (s390_supports_z_point_type): Turn into...
603 (s390_target::supports_z_point_type): ...this.
604 (the_low_target): Remove the op field.
605 * linux-bfin-low.cc (the_low_target): Remove the op field.
606 * linux-m32r-low.cc (the_low_target): Ditto.
607 * linux-m68k-low.cc (the_low_target): Ditto.
608 * linux-sh-low.cc (the_low_target): Ditto.
609 * linux-sparc-low.cc (the_low_target): Ditto.
610 * linux-tic6x-low.cc (the_low_target): Ditto.
611 * linux-tile-low.cc (the_low_target): Ditto.
612 * linux-xtensa-low.cc (the_low_target): Ditto.
613
614 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
615
616 Turn the 'breakpoint_at' linux target op into a method of
617 linux_process_target.
618
619 * linux-low.h (struct linux_target_ops): Remove the op.
620 (class linux_process_target) <low_breakpoint_at>: Declare.
621
622 Update the callers below:
623
624 * linux-low.cc (linux_process_target::save_stop_reason)
625 (linux_process_target::thread_still_has_status_pending)
626 (linux_process_target::wait_1)
627
628 * linux-x86-low.cc (class x86_target)
629 <low_breakpoint_at>: Declare.
630 (x86_breakpoint_at): Turn into...
631 (x86_target::low_breakpoint_at): ...this.
632 (the_low_target): Remove the op field.
633 * linux-aarch64-low.cc (class aarch64_target)
634 <low_breakpoint_at>: Declare.
635 (aarch64_breakpoint_at): Turn into...
636 (aarch64_target::low_breakpoint_at): ...this.
637 (the_low_target): Remove the op field.
638 * linux-arm-low.cc (class arm_target)
639 <low_breakpoint_at>: Declare.
640 (arm_target::low_breakpoint_at): Define.
641 (the_low_target): Remove the op field.
642 * linux-bfin-low.cc (class bfin_target)
643 <low_breakpoint_at>: Declare.
644 (bfin_breakpoint_at): Turn into...
645 (bfin_target::low_breakpoint_at): ...this.
646 (the_low_target): Remove the op field.
647 * linux-cris-low.cc (class cris_target)
648 <low_breakpoint_at>: Declare.
649 (cris_breakpoint_at): Turn into...
650 (cris_target::low_breakpoint_at): ...this.
651 (the_low_target): Remove the op field.
652 * linux-crisv32-low.cc (class crisv32_target)
653 <low_breakpoint_at>: Declare.
654 (crisv32_breakpoint_at): Turn into...
655 (crisv32_target::low_breakpoint_at): ...this.
656 (the_low_target): Remove the op field.
657 * linux-ia64-low.cc (class ia64_target)
658 <low_breakpoint_at>: Declare.
659 (ia64_target::low_breakpoint_at): Define.
660 * linux-m32r-low.cc (class m32r_target)
661 <low_breakpoint_at>: Declare.
662 (m32r_breakpoint_at): Turn into...
663 (m32r_target::low_breakpoint_at): ...this.
664 (the_low_target): Remove the op field.
665 * linux-m68k-low.cc (class m68k_target)
666 <low_breakpoint_at>: Declare.
667 (m68k_breakpoint_at): Turn into...
668 (m68k_target::low_breakpoint_at): ...this.
669 (the_low_target): Remove the op field.
670 * linux-mips-low.cc (class mips_target)
671 <low_breakpoint_at>: Declare.
672 (mips_breakpoint_at): Turn into...
673 (mips_target::low_breakpoint_at): ...this.
674 (the_low_target): Remove the op field.
675 * linux-nios2-low.cc (class nios2_target)
676 <low_breakpoint_at>: Declare.
677 (nios2_breakpoint_at): Turn into...
678 (nios2_target::low_breakpoint_at): ...this.
679 (the_low_target): Remove the op field.
680 * linux-ppc-low.cc (class ppc_target)
681 <low_breakpoint_at>: Declare.
682 (ppc_breakpoint_at): Turn into...
683 (ppc_target::low_breakpoint_at): ...this.
684 (the_low_target): Remove the op field.
685 * linux-riscv-low.cc (class riscv_target)
686 <low_breakpoint_at>: Declare.
687 (riscv_breakpoint_at): Turn into...
688 (riscv_target::low_breakpoint_at): ...this.
689 (the_low_target): Remove the op field.
690 * linux-s390-low.cc (class s390_target)
691 <low_breakpoint_at>: Declare.
692 (s390_breakpoint_at): Turn into...
693 (s390_target::low_breakpoint_at): ...this.
694 (the_low_target): Remove the op field.
695 * linux-sh-low.cc (class sh_target)
696 <low_breakpoint_at>: Declare.
697 (sh_breakpoint_at): Turn into...
698 (sh_target::low_breakpoint_at): ...this.
699 (the_low_target): Remove the op field.
700 * linux-sparc-low.cc (class sparc_target)
701 <low_breakpoint_at>: Declare.
702 (sparc_breakpoint_at): Turn into...
703 (sparc_target::low_breakpoint_at): ...this.
704 (the_low_target): Remove the op field.
705 * linux-tic6x-low.cc (class tic6x_target)
706 <low_breakpoint_at>: Declare.
707 (tic6x_breakpoint_at): Turn into...
708 (tic6x_target::low_breakpoint_at): ...this.
709 (the_low_target): Remove the op field.
710 * linux-tile-low.cc (class tile_target)
711 <low_breakpoint_at>: Declare.
712 (tile_breakpoint_at): Turn into...
713 (tile_target::low_breakpoint_at): ...this.
714 (the_low_target): Remove the op field.
715 * linux-xtensa-low.cc (class xtensa_target)
716 <low_breakpoint_at>: Declare.
717 (xtensa_breakpoint_at): Turn into...
718 (xtensa_target::low_breakpoint_at): ...this.
719 (the_low_target): Remove the op field.
720
721 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
722
723 Turn the 'decr_pc_after_break' linux_target_ops field into
724 a method of linux_process_target.
725
726 * linux-low.h (struct linux_target_ops)
727 <decr_pc_after_break>: Remove.
728 (class linux_process_target) <low_decr_pc_after_break>: New method
729 declaration.
730 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
731 New method implementation.
732
733 Update the users below.
734
735 (linux_process_target::save_stop_reason)
736 (linux_process_target::wait_1)
737 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
738 New declaration.
739 (x86_target::low_decr_pc_after_break): New method implementation.
740 (the_low_target): Remove the field.
741 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
742 New declaration.
743 (bfin_target::low_decr_pc_after_break): New method implementation.
744 (the_low_target): Remove the field.
745 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
746 New declaration.
747 (m68k_target::low_decr_pc_after_break): New method implementation.
748 (the_low_target): Remove the field.
749 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
750 New declaration.
751 (s390_target::low_decr_pc_after_break): New method implementation.
752 (the_low_target): Remove the field.
753 * linux-aarch64-low.cc (the_low_target): Remove the field.
754 * linux-arm-low.cc (the_low_target): Remove the field.
755 * linux-cris-low.cc (the_low_target): Remove the field.
756 * linux-crisv32-low.cc (the_low_target): Remove the field.
757 * linux-m32r-low.cc (the_low_target): Remove the field.
758 * linux-mips-low.cc (the_low_target): Remove the field.
759 * linux-nios2-low.cc (the_low_target): Remove the field.
760 * linux-ppc-low.cc (the_low_target): Remove the field.
761 * linux-riscv-low.cc (the_low_target): Remove the field.
762 * linux-sh-low.cc (the_low_target): Remove the field.
763 * linux-sparc-low.cc (the_low_target): Remove the field.
764 * linux-tic6x-low.cc (the_low_target): Remove the field.
765 * linux-tile-low.cc (the_low_target): Remove the field.
766 * linux-xtensa-low.cc (the_low_target): Remove the field.
767
768 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
769
770 Remove the 'supports_software_single_step' linux target op and let
771 the concrete linux target define it by overriding the op in
772 process_stratum_target.
773 Turn the 'get_next_pcs' linux target op into a method of
774 linux_process_target.
775
776 * linux-low.h (struct linux_target_ops): Remove the ops.
777 (class linux_process_target) <supports_software_single_step>:
778 Remove.
779 <low_get_next_pcs>: Declare.
780 * linux-low.cc (can_software_single_step): Remove.
781 (linux_process_target::low_get_next_pcs): Define.
782 (linux_process_target::supports_software_single_step): Remove.
783
784 Update the callers below.
785
786 (linux_process_target::handle_extended_wait)
787 (linux_process_target::wait_1)
788 (linux_process_target::install_software_single_step_breakpoints)
789 (linux_process_target::single_step)
790 (linux_process_target::thread_needs_step_over)
791 (linux_process_target::proceed_one_lwp)
792 (linux_process_target::supports_range_stepping)
793
794 * linux-x86-low.cc (the_low_target): Remove the op field.
795 * linux-aarch64-low.cc (the_low_target): Ditto.
796 * linux-bfin-low.cc (the_low_target): Ditto.
797 * linux-cris-low.cc (the_low_target): Ditto.
798 * linux-crisv32-low.cc (the_low_target): Ditto.
799 * linux-m32r-low.cc (the_low_target): Ditto.
800 * linux-m68k-low.cc (the_low_target): Ditto.
801 * linux-mips-low.cc (the_low_target): Ditto.
802 * linux-nios2-low.cc (the_low_target): Ditto.
803 * linux-ppc-low.cc (the_low_target): Ditto.
804 * linux-riscv-low.cc (the_low_target): Ditto.
805 * linux-s390-low.cc (the_low_target): Ditto.
806 * linux-sh-low.cc (the_low_target): Ditto.
807 * linux-sparc-low.cc (the_low_target): Ditto.
808 * linux-tic6x-low.cc (the_low_target): Ditto.
809 * linux-tile-low.cc (the_low_target): Ditto.
810 * linux-xtensa-low.cc (the_low_target): Ditto.
811 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
812 <supports_software_single_step>: Declare.
813 (arm_target::supports_software_single_step): Define.
814 (arm_gdbserver_get_next_pcs): Turn into...
815 (arm_target::low_get_next_pcs): ...this.
816 (the_low_target): Remove the op field.
817
818 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
819
820 Remove the 'sw_breakpoint_from_kind' linux target op, and let
821 the concrete linux target define it by overriding the op
822 in process_stratum_target.
823
824 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
825 Remove.
826 * linux-low.h (struct linux_target_ops): Remove the op.
827 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
828 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
829 Declare.
830 (x86_sw_breakpoint_from_kind): Turn into...
831 (x86_target::sw_breakpoint_from_kind): ...this.
832 (the_low_target): Remove the op field.
833 * linux-aarch64-low.cc (class aarch64_target)
834 <sw_breakpoint_from_kind>: Declare.
835 (aarch64_sw_breakpoint_from_kind): Turn into...
836 (aarch64_target::sw_breakpoint_from_kind): ...this.
837 (the_low_target): Remove the op field.
838 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
839 Declare.
840 (arm_target::sw_breakpoint_from_kind): Define.
841 (the_low_target): Remove the op field.
842 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
843 Declare.
844 (bfin_sw_breakpoint_from_kind): Turn into...
845 (bfin_target::sw_breakpoint_from_kind): ...this.
846 (the_low_target): Remove the op field.
847 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
848 Declare.
849 (cris_sw_breakpoint_from_kind): Turn into...
850 (cris_target::sw_breakpoint_from_kind): ...this.
851 (the_low_target): Remove the op field.
852 * linux-crisv32-low.cc (class crisv32_target)
853 <sw_breakpoint_from_kind>: Declare.
854 (cris_sw_breakpoint_from_kind): Turn into...
855 (crisv32_target::sw_breakpoint_from_kind): ...this.
856 (the_low_target): Remove the op field.
857 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
858 Declare.
859 (ia64_target::sw_breakpoint_from_kind): Define.
860 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
861 Declare.
862 (m32r_sw_breakpoint_from_kind): Turn into...
863 (m32r_target::sw_breakpoint_from_kind): ...this.
864 (the_low_target): Remove the op field.
865 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
866 Declare.
867 (m68k_sw_breakpoint_from_kind): Turn into...
868 (m68k_target::sw_breakpoint_from_kind): ...this.
869 (the_low_target): Remove the op field.
870 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
871 Declare.
872 (mips_sw_breakpoint_from_kind): Turn into...
873 (mips_target::sw_breakpoint_from_kind): ...this.
874 (the_low_target): Remove the op field.
875 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
876 Declare.
877 (nios2_sw_breakpoint_from_kind): Turn into...
878 (nios2_target::sw_breakpoint_from_kind): ...this.
879 (the_low_target): Remove the op field.
880 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
881 Declare.
882 (ppc_sw_breakpoint_from_kind): Turn into...
883 (ppc_target::sw_breakpoint_from_kind): ...this.
884 (the_low_target): Remove the op field.
885 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
886 Declare.
887 (riscv_sw_breakpoint_from_kind): Turn into...
888 (riscv_target::sw_breakpoint_from_kind): ...this.
889 (the_low_target): Remove the op field.
890 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
891 Declare.
892 (s390_sw_breakpoint_from_kind): Turn into...
893 (s390_target::sw_breakpoint_from_kind): ...this.
894 (the_low_target): Remove the op field.
895 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
896 Declare.
897 (sh_sw_breakpoint_from_kind): Turn into...
898 (sh_target::sw_breakpoint_from_kind): ...this.
899 (the_low_target): Remove the op field.
900 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
901 Declare.
902 (sparc_sw_breakpoint_from_kind): Turn into...
903 (sparc_target::sw_breakpoint_from_kind): ...this.
904 (the_low_target): Remove the op field.
905 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
906 Declare.
907 (tic6x_sw_breakpoint_from_kind): Turn into...
908 (tic6x_target::sw_breakpoint_from_kind): ...this.
909 (the_low_target): Remove the op field.
910 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
911 Declare.
912 (tile_sw_breakpoint_from_kind): Turn into...
913 (tile_target::sw_breakpoint_from_kind): ...this.
914 (the_low_target): Remove the op field.
915 * linux-xtensa-low.cc (class xtensa_target)
916 <sw_breakpoint_from_kind>: Declare.
917 (xtensa_sw_breakpoint_from_kind): Turn into...
918 (xtensa_target::sw_breakpoint_from_kind): ...this.
919 (the_low_target): Remove the op field.
920
921 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
922
923 Remove the 'breakpoint_kind_from_pc' and
924 'breakpoint_kind_from_current_state' linux target ops, and let the
925 concrete linux target define them by overriding the ops of
926 process_stratum_target.
927
928 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
929 Remove.
930 (linux_process_target::breakpoint_kind_from_current_state): Remove.
931 * linux-low.h (struct linux_target_ops): Remove ops.
932 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
933 <breakpoint_kind_from_current_state>: Remove.
934 * linux-x86-low.cc (the_low_target): Remove the op fields.
935 * linux-bfin-low.cc (the_low_target): Ditto.
936 * linux-cris-low.cc (the_low_target): Ditto.
937 * linux-crisv32-low.cc (the_low_target): Ditto.
938 * linux-m32r-low.cc (the_low_target): Ditto.
939 * linux-m68k-low.cc (the_low_target): Ditto.
940 * linux-mips-low.cc (the_low_target): Ditto.
941 * linux-nios2-low.cc (the_low_target): Ditto.
942 * linux-ppc-low.cc (the_low_target): Ditto.
943 * linux-s390-low.cc (the_low_target): Ditto.
944 * linux-sh-low.cc (the_low_target): Ditto.
945 * linux-sparc-low.cc (the_low_target): Ditto.
946 * linux-tic6x-low.cc (the_low_target): Ditto.
947 * linux-tile-low.cc (the_low_target): Ditto.
948 * linux-xtensa-low.cc (the_low_target): Ditto.
949 * linux-aarch64-low.cc (class aarch64_target)
950 <breakpoint_kind_from_pc>
951 <breakpoint_kind_from_current_state>: Declare.
952 (aarch64_breakpoint_kind_from_pc): Turn into...
953 (aarch64_target::breakpoint_kind_from_pc): ...this.
954 (aarch64_breakpoint_kind_from_current_state): Turn into...
955 (aarch64_target::breakpoint_kind_from_current_state): ...this.
956 (the_low_target): Remove the op fields.
957 * linux-arm-low.cc (class arm_target):
958 <breakpoint_kind_from_pc>
959 <breakpoint_kind_from_current_state>: Declare.
960 (arm_target::breakpoint_kind_from_pc): Define.
961 (arm_target::breakpoint_kind_from_current_state): Define.
962 (the_low_target): Remove the op fields.
963 * linux-riscv-low.cc (class riscv_target):
964 <breakpoint_kind_from_pc>: Declare.
965 (riscv_breakpoint_kind_from_pc): Turn into...
966 (riscv_target::breakpoint_kind_from_pc): ...this.
967 (the_low_target): Remove the op fields.
968
969 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
970
971 Turn the 'get_pc' and 'set_pc' linux target ops into methods
972 of linux_process_target.
973
974 * linux-low.h (struct linux_target_ops): Remove the ops.
975 (class linux_process_target) <low_supports_breakpoints>
976 <low_get_pc>
977 <low_set_pc>: Declare.
978 * linux-low.cc (supports_breakpoints): Turn into...
979 (linux_process_target::low_supports_breakpoints): ...this.
980 (linux_process_target::low_get_pc): Define.
981 (linux_process_target::low_set_pc): Define.
982
983 Update the callers below.
984
985 (linux_process_target::get_pc)
986 (linux_process_target::save_stop_reason)
987 (linux_process_target::maybe_move_out_of_jump_pad)
988 (linux_process_target::wait_1)
989 (linux_process_target::resume_one_lwp_throw)
990 (linux_process_target::resume)
991 (linux_process_target::proceed_all_lwps)
992 (linux_process_target::read_pc)
993 (linux_process_target::write_pc)
994
995 * linux-x86-low.cc (class linux_process_target)
996 <low_supports_breakpoints>
997 <low_get_pc>
998 <low_set_pc>: Declare.
999 (x86_target::low_supports_breakpoints): Define.
1000 (x86_get_pc): Turn into...
1001 (x86_target::low_get_pc): ...this.
1002 (x86_set_pc): Turn into...
1003 (x86_target::low_set_pc): ...this.
1004 (the_low_target): Remove the op fields.
1005 * linux-arm-low.cc (class arm_target)
1006 <low_supports_breakpoints>
1007 <low_get_pc>
1008 <low_set_pc>: Declare.
1009 (arm_target::low_supports_breakpoints)
1010 (arm_target::low_get_pc)
1011 (arm_target::low_set_pc): Define.
1012 (the_low_target): Remove the op fields.
1013 * linux-bfin-low.cc (class bfin_target)
1014 <low_supports_breakpoints>
1015 <low_get_pc>
1016 <low_set_pc>: Declare.
1017 (bfin_target::low_supports_breakpoints)
1018 (bfin_target::low_get_pc)
1019 (bfin_target::low_set_pc): Define.
1020 (the_low_target): Remove the op fields.
1021 * linux-cris-low.cc (class cris_target)
1022 <low_supports_breakpoints>
1023 <low_get_pc>
1024 <low_set_pc>: Declare.
1025 (cris_target::low_supports_breakpoints)
1026 (cris_target::low_get_pc)
1027 (cris_target::low_set_pc): Define.
1028 (the_low_target): Remove the op fields.
1029 * linux-crisv32-low.cc (class crisv32_target)
1030 <low_supports_breakpoints>
1031 <low_get_pc>
1032 <low_set_pc>: Declare.
1033 (crisv32_target::low_supports_breakpoints)
1034 (crisv32_target::low_get_pc)
1035 (crisv32_target::low_set_pc): Define.
1036 (the_low_target): Remove the op fields.
1037 * linux-m32r-low.cc (class m32r_target)
1038 <low_supports_breakpoints>
1039 <low_get_pc>
1040 <low_set_pc>: Declare.
1041 (m32r_target::low_supports_breakpoints)
1042 (m32r_target::low_get_pc)
1043 (m32r_target::low_set_pc): Define.
1044 (the_low_target): Remove the op fields.
1045 * linux-m68k-low.cc (class m68k_target)
1046 <low_supports_breakpoints>
1047 <low_get_pc>
1048 <low_set_pc>: Declare.
1049 (m68k_target::low_supports_breakpoints)
1050 (m68k_target::low_get_pc)
1051 (m68k_target::low_set_pc): Define.
1052 (the_low_target): Remove the op fields.
1053 * linux-nios2-low.cc (class nios2_target)
1054 <low_supports_breakpoints>
1055 <low_get_pc>
1056 <low_set_pc>: Declare.
1057 (nios2_target::low_supports_breakpoints)
1058 (nios2_target::low_get_pc)
1059 (nios2_target::low_set_pc): Define.
1060 (the_low_target): Remove the op fields.
1061 * linux-sh-low.cc (class sh_target)
1062 <low_supports_breakpoints>
1063 <low_get_pc>
1064 <low_set_pc>: Declare.
1065 (sh_target::low_supports_breakpoints)
1066 (sh_target::low_get_pc)
1067 (sh_target::low_set_pc): Define.
1068 (the_low_target): Remove the op fields.
1069 * linux-xtensa-low.cc (class xtensa_target)
1070 <low_supports_breakpoints>
1071 <low_get_pc>
1072 <low_set_pc>: Declare.
1073 (xtensa_target::low_supports_breakpoints)
1074 (xtensa_target::low_get_pc)
1075 (xtensa_target::low_set_pc): Define.
1076 (the_low_target): Remove the op fields.
1077 * linux-sparc-low.cc (class sparc_target)
1078 <low_supports_breakpoints>
1079 <low_get_pc>: Declare.
1080 (sparc_target::low_supports_breakpoints)
1081 (sparc_target::low_get_pc): Define.
1082 (the_low_target): Remove the op fields.
1083 * linux-tile-low.cc (class tile_target)
1084 <low_supports_breakpoints>
1085 <low_get_pc>
1086 <low_set_pc>: Declare.
1087 (tile_target::low_supports_breakpoints)
1088 (tile_target::low_get_pc)
1089 (tile_target::low_set_pc): Define.
1090 (the_low_target): Remove the op fields.
1091 * linux-aarch64-low.cc (class aarch64_target)
1092 <low_supports_breakpoints>
1093 <low_get_pc>
1094 <low_set_pc>: Declare.
1095 (aarch64_target::low_supports_breakpoints): Define.
1096 (aarch64_get_pc): Turn into...
1097 (aarch64_target::low_get_pc): ...this.
1098 (aarch64_set_pc): Turn into...
1099 (aarch64_target::low_set_pc): ...this.
1100 (the_low_target): Remove the op fields.
1101 * linux-mips-low.cc (class mips_target)
1102 <low_supports_breakpoints>
1103 <low_get_pc>
1104 <low_set_pc>: Declare.
1105 (mips_target::low_supports_breakpoints): Define.
1106 (mips_get_pc): Turn into...
1107 (mips_target::low_get_pc): ...this.
1108 (mips_set_pc): Turn into...
1109 (mips_target::low_set_pc): ...this.
1110 (the_low_target): Remove the op fields.
1111 * linux-ppc-low.cc (class ppc_target)
1112 <low_supports_breakpoints>
1113 <low_get_pc>
1114 <low_set_pc>: Declare.
1115 (ppc_target::low_supports_breakpoints): Define.
1116 (ppc_get_pc): Turn into...
1117 (ppc_target::low_get_pc): ...this.
1118 (ppc_set_pc): Turn into...
1119 (ppc_target::low_set_pc): ...this.
1120 (the_low_target): Remove the op fields.
1121 * linux-riscv-low.cc (class riscv_target)
1122 <low_supports_breakpoints>
1123 <low_get_pc>
1124 <low_set_pc>: Declare.
1125 (riscv_target::low_supports_breakpoints): Define.
1126 (riscv_get_pc): Turn into...
1127 (riscv_target::low_get_pc): ...this.
1128 (riscv_set_pc): Turn into...
1129 (riscv_target::low_set_pc): ...this.
1130 (the_low_target): Remove the op fields.
1131 * linux-s390-low.cc (class s390_target)
1132 <low_supports_breakpoints>
1133 <low_get_pc>
1134 <low_set_pc>: Declare.
1135 (s390_target::low_supports_breakpoints): Define.
1136 (s390_get_pc): Turn into...
1137 (s390_target::low_get_pc): ...this.
1138 (s390_set_pc): Turn into...
1139 (s390_target::low_set_pc): ...this.
1140 (the_low_target): Remove the op fields.
1141 * linux-tic6x-low.cc (class tic6x_target)
1142 <low_supports_breakpoints>
1143 <low_get_pc>
1144 <low_set_pc>: Declare.
1145 (tic6x_target::low_supports_breakpoints): Define.
1146 (tic6x_get_pc): Turn into...
1147 (tic6x_target::low_get_pc): ...this.
1148 (tic6x_set_pc): Turn into...
1149 (tic6x_target::low_set_pc): ...this.
1150 (the_low_target): Remove the op fields.
1151
1152 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1153
1154 Turn some more static methods in linux-low into private methods
1155 of linux_process_target.
1156
1157 * linux-low.cc (get_pc): Turn into...
1158 (linux_process_target::get_pc): ...this.
1159 (save_stop_reason): Turn into...
1160 (linux_process_target::save_stop_reason): ...this.
1161 (thread_still_has_status_pending_p): Turn into...
1162 (linux_process_target::thread_still_has_status_pending): ...this.
1163 (status_pending_p_callback): Turn into...
1164 (linux_process_target::status_pending_p_callback): ...this.
1165 (resume_stopped_resumed_lwps): Turn into...
1166 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1167 (install_software_single_step_breakpoints): Turn into...
1168 (linux_process_target::install_software_single_step_breakpoints):
1169 ...this.
1170 (single_step): Turn into...
1171 (linux_process_target::single_step): ...this.
1172 (linux_resume_one_lwp_throw): Turn into...
1173 (linux_process_target::resume_one_lwp_throw): ...this.
1174 (linux_resume_one_lwp): Turn into...
1175 (linux_process_target::resume_one_lwp): ...this.
1176 (resume_status_pending_p): Turn into...
1177 (linux_process_target::resume_status_pending): ...this.
1178 (need_step_over_p): Turn into...
1179 (linux_process_target::thread_needs_step_over): ...this.
1180 (linux_resume_one_thread): Turn into...
1181 (linux_process_target::resume_one_thread): ...this.
1182 (proceed_one_lwp): Turn into...
1183 (linux_process_target::proceed_one_lwp): ...this.
1184 (unsuspend_and_proceed_one_lwp): Turn into...
1185 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1186
1187 Update the calls/references to the above functions below.
1188
1189 (linux_process_target::handle_extended_wait)
1190 (linux_process_target::filter_event)
1191 (linux_process_target::wait_for_event_filtered)
1192 (linux_process_target::wait_1)
1193 (linux_process_target::move_out_of_jump_pad)
1194 (linux_process_target::start_step_over)
1195 (linux_process_target::resume)
1196 (linux_process_target::proceed_all_lwps)
1197 (regsets_store_inferior_registers)
1198 (linux_process_target::store_register)
1199
1200 * linux-low.h (class linux_process_target)
1201 <get_pc>
1202 <save_stop_reason>
1203 <thread_still_has_status_pending>
1204 <status_pending_p_callback>
1205 <resume_stopped_resumed_lwps>
1206 <install_software_single_step_breakpoints>
1207 <single_step>
1208 <resume_one_lwp_throw>
1209 <resume_one_lwp>
1210 <resume_status_pending>
1211 <thread_needs_step_over>
1212 <resume_one_thread>
1213 <proceed_one_lwp>
1214 <unsuspend_and_proceed_one_lwp>: Declare.
1215
1216 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1217
1218 Turn the 'fetch_register' linux target op into a method of
1219 linux_process_target.
1220
1221 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1222 (class linux_process_target) <low_fetch_register>: Declare.
1223 * linux-x86-low.cc (the_low_target)
1224 * linux-aarch64-low.cc (the_low_target)
1225 * linux-arm-low.cc (the_low_target)
1226 * linux-bfin-low.cc (the_low_target)
1227 * linux-cris-low.cc (the_low_target)
1228 * linux-crisv32-low.cc (the_low_target)
1229 * linux-m32r-low.cc (the_low_target)
1230 * linux-m68k-low.cc (the_low_target)
1231 * linux-nios2-low.cc (the_low_target)
1232 * linux-ppc-low.cc (the_low_target)
1233 * linux-s390-low.cc (the_low_target)
1234 * linux-sh-low.cc (the_low_target)
1235 * linux-sparc-low.cc (the_low_target)
1236 * linux-tic6x-low.cc (the_low_target)
1237 * linux-tile-low.cc (the_low_target)
1238 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1239 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1240 Declare.
1241 (ia64_fetch_register): Turn into...
1242 (ia64_target::low_fetch_register): ...this.
1243 (the_low_target): Remove the op field.
1244 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1245 Declare.
1246 (mips_fetch_register): Turn into...
1247 (mips_target::low_fetch_register): ...this.
1248 (the_low_target): Remove the op field.
1249 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1250 Declare.
1251 (riscv_fetch_register): Turn into...
1252 (riscv_target::low_fetch_register): ...this.
1253 (the_low_target): Remove the op field.
1254
1255 Update the callers below.
1256
1257 * linux-low.cc (linux_process_target::fetch_registers)
1258 (linux_process_target::low_fetch_register)
1259
1260 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1261
1262 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1263 linux target ops into methods of linux_process_target.
1264
1265 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1266 (class linux_process_target) <fetch_register>
1267 <store_register>
1268 <usr_fetch_inferior_registers>
1269 <usr_store_inferior_registers>
1270 <low_cannot_fetch_register>
1271 <low_cannot_fetch_register> Declare.
1272 * linux-low.cc (fetch_register): Turn into...
1273 (linux_process_target::fetch_register): ...this.
1274 (store_register): Turn into ...
1275 (linux_process_target::store_register): ...this.
1276 (usr_fetch_inferior_registers): Turn into...
1277 (linux_process_target::usr_fetch_inferior_registers): ...this.
1278 (usr_store_inferior_registers): Turn into...
1279 (linux_process_target::usr_store_inferior_registers): ...this.
1280 * linux-x86-low.cc (class x86_target)
1281 <low_cannot_fetch_register>
1282 <low_cannot_store_register>: Declare.
1283 (x86_cannot_store_register): Turn into...
1284 (x86_target::low_cannot_store_register): ...this.
1285 (x86_cannot_fetch_register): Turn into...
1286 (x86_target::low_cannot_fetch_register): ...this.
1287 (the_low_target): Remove the target op fields.
1288 * linux-aarch64-low.cc (class aarch64_target)
1289 <low_cannot_fetch_register>
1290 <low_cannot_store_register>: Declare.
1291 (aarch64_target::low_cannot_fetch_register)
1292 (aarch64_target::low_cannot_store_register): Define.
1293 (the_low_target): Remove the op fields.
1294 * linux-arm-low.cc (class arm_target)
1295 <low_cannot_fetch_register>
1296 <low_cannot_store_register>: Declare.
1297 (arm_cannot_fetch_register): Turn into...
1298 (arm_target::low_cannot_fetch_register): ...this.
1299 (arm_cannot_store_register): Turn into...
1300 (arm_target::low_cannot_store_register): ...this.
1301 (the_low_target): Remove the op fields.
1302 * linux-bfin-low.cc (class bfin_target)
1303 <low_cannot_fetch_register>
1304 <low_cannot_store_register>: Declare.
1305 (bfin_cannot_fetch_register): Turn into...
1306 (bfin_target::low_cannot_fetch_register): ...this.
1307 (bfin_cannot_store_register): Turn into...
1308 (bfin_target::low_cannot_store_register): ...this.
1309 (the_low_target): Remove the op fields.
1310 * linux-cris-low.cc (class cris_target)
1311 <low_cannot_fetch_register>
1312 <low_cannot_store_register>: Declare.
1313 (cris_cannot_fetch_register): Turn into...
1314 (cris_target::low_cannot_fetch_register): ...this.
1315 (cris_cannot_store_register): Turn into...
1316 (cris_target::low_cannot_store_register): ...this.
1317 (the_low_target): Remove the op fields.
1318 * linux-crisv32-low.cc (class crisv32_target)
1319 <low_cannot_fetch_register>
1320 <low_cannot_store_register>: Declare.
1321 (crisv32_target::low_cannot_fetch_register)
1322 (crisv32_target::low_cannot_store_register): Define.
1323 (the_low_target): Remove the op fields.
1324 * linux-ia64-low.cc (class ia64_target)
1325 <low_cannot_fetch_register>
1326 <low_cannot_store_register>: Declare.
1327 (ia64_cannot_fetch_register): Turn into...
1328 (ia64_target::low_cannot_fetch_register): ...this.
1329 (ia64_cannot_store_register): Turn into...
1330 (ia64_target::low_cannot_store_register): ...this.
1331 (the_low_target): Remove the op fields.
1332 * linux-m32r-low.cc (class m32r_target)
1333 <low_cannot_fetch_register>
1334 <low_cannot_store_register>: Declare.
1335 (m32r_cannot_fetch_register): Turn into...
1336 (m32r_target::low_cannot_fetch_register): ...this.
1337 (m32r_cannot_store_register): Turn into...
1338 (m32r_target::low_cannot_store_register): ...this.
1339 (the_low_target): Remove the op fields.
1340 * linux-m68k-low.cc (class m68k_target)
1341 <low_cannot_fetch_register>
1342 <low_cannot_store_register>: Declare.
1343 (m68k_cannot_fetch_register): Turn into...
1344 (m68k_target::low_cannot_fetch_register): ...this.
1345 (m68k_cannot_store_register): Turn into...
1346 (m68k_target::low_cannot_store_register): ...this.
1347 (the_low_target): Remove the op fields.
1348 * linux-mips-low.cc (class mips_target)
1349 <low_cannot_fetch_register>
1350 <low_cannot_store_register>: Declare.
1351 (mips_cannot_fetch_register): Turn into...
1352 (mips_target::low_cannot_fetch_register): ...this.
1353 (mips_cannot_store_register): Turn into...
1354 (mips_target::low_cannot_store_register): ...this.
1355 (get_usrregs_info): Inline at the call sites in
1356 low_cannot_fetch_register and low_cannot_store_register,
1357 and remove.
1358 (the_low_target): Remove the op fields.
1359 * linux-nios2-low.cc (class nios2_target)
1360 <low_cannot_fetch_register>
1361 <low_cannot_store_register>: Declare.
1362 (nios2_cannot_fetch_register): Turn into...
1363 (nios2_target::low_cannot_fetch_register): ...this.
1364 (nios2_cannot_store_register): Turn into...
1365 (nios2_target::low_cannot_store_register): ...this.
1366 (the_low_target): Remove the op fields.
1367 * linux-ppc-low.cc (class ppc_target)
1368 <low_cannot_fetch_register>
1369 <low_cannot_store_register>: Declare.
1370 (ppc_cannot_fetch_register): Turn into...
1371 (ppc_target::low_cannot_fetch_register): ...this.
1372 (ppc_cannot_store_register): Turn into...
1373 (ppc_target::low_cannot_store_register): ...this.
1374 (the_low_target): Remove the op fields.
1375 * linux-riscv-low.cc (class riscv_target)
1376 <low_cannot_fetch_register>
1377 <low_cannot_store_register>: Declare.
1378 (riscv_target::low_cannot_fetch_register)
1379 (riscv_target::low_cannot_store_register): Define.
1380 (the_low_target): Remove the op fields.
1381 * linux-s390-low.cc (class s390_target)
1382 <low_cannot_fetch_register>
1383 <low_cannot_store_register>: Declare.
1384 (s390_cannot_fetch_register): Turn into...
1385 (s390_target::low_cannot_fetch_register): ...this.
1386 (s390_cannot_store_register): Turn into...
1387 (s390_target::low_cannot_store_register): ...this.
1388 (the_low_target): Remove the op fields.
1389 * linux-sh-low.cc (class sh_target)
1390 <low_cannot_fetch_register>
1391 <low_cannot_store_register>: Declare.
1392 (sh_cannot_fetch_register): Turn into...
1393 (sh_target::low_cannot_fetch_register): ...this.
1394 (sh_cannot_store_register): Turn into...
1395 (sh_target::low_cannot_store_register): ...this.
1396 (the_low_target): Remove the op fields.
1397 * linux-sparc-low.cc (class sparc_target)
1398 <low_cannot_fetch_register>
1399 <low_cannot_store_register>: Declare.
1400 (sparc_cannot_fetch_register): Turn into...
1401 (sparc_target::low_cannot_fetch_register): ...this.
1402 (sparc_cannot_store_register): Turn into...
1403 (sparc_target::low_cannot_store_register): ...this.
1404 (the_low_target): Remove the op fields.
1405 * linux-tic6x-low.cc (class tic6x_target)
1406 <low_cannot_fetch_register>
1407 <low_cannot_store_register>: Declare.
1408 (tic6x_cannot_fetch_register): Turn into...
1409 (tic6x_target::low_cannot_fetch_register): ...this.
1410 (tic6x_cannot_store_register): Turn into...
1411 (tic6x_target::low_cannot_store_register): ...this.
1412 (the_low_target): Remove the op fields.
1413 * linux-tile-low.cc (class tile_target)
1414 <low_cannot_fetch_register>
1415 <low_cannot_store_register>: Declare.
1416 (tile_cannot_fetch_register): Turn into...
1417 (tile_target::low_cannot_fetch_register): ...this.
1418 (tile_cannot_store_register): Turn into...
1419 (tile_target::low_cannot_store_register): ...this.
1420 (the_low_target): Remove the op fields.
1421 * linux-xtensa-low.cc (class xtensa_target)
1422 <low_cannot_fetch_register>
1423 <low_cannot_store_register>: Declare.
1424 (xtensa_target::low_cannot_fetch_register)
1425 (xtensa_target::low_cannot_store_register): Define.
1426 (the_low_target): Remove the op fields.
1427
1428 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1429
1430 Turn the 'regs_info' linux target op into a method of
1431 linux_process_target.
1432
1433 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1434 (class linux_process_target) <get_regs_info>: Define.
1435
1436 Update the callers below.
1437
1438 * linux-low.cc (linux_process_target::fetch_registers)
1439 (linux_process_target::store_registers)
1440 * proc-service.cc (gregset_info)
1441
1442 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1443 (x86_linux_regs_info): Turn into ...
1444 (x86_target::get_regs_info): ...this.
1445 (the_low_target): Remove the op field.
1446 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1447 Declare.
1448 (aarch64_regs_info): Turn into ...
1449 (aarch64_target::get_regs_info): ...this.
1450 (the_low_target): Remove the op field.
1451 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1452 (arm_regs_info): Turn into ...
1453 (arm_target::get_regs_info): ...this.
1454 (the_low_target): Remove the op field.
1455 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1456 (bfin_regs_info): Turn into ...
1457 (bfin_target::get_regs_info): ...this.
1458 (the_low_target): Remove the op field.
1459 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1460 (cris_regs_info): Turn into ...
1461 (cris_target::get_regs_info): ...this.
1462 (the_low_target): Remove the op field.
1463 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1464 Declare.
1465 (crisv32_regs_info): Turn into ...
1466 (crisv32_target::get_regs_info): ...this.
1467 (the_low_target): Remove the op field.
1468 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1469 (ia64_regs_info): Turn into ...
1470 (ia64_target::get_regs_info): ...this.
1471 (the_low_target): Remove the op field.
1472 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1473 (m32r_regs_info): Turn into ...
1474 (m32r_target::get_regs_info): ...this.
1475 (the_low_target): Remove the op field.
1476 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1477 (m68k_regs_info): Turn into ...
1478 (m68k_target::get_regs_info): ...this.
1479 (the_low_target): Remove the op field.
1480 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1481 (mips_regs_info): Turn into ...
1482 (mips_target::get_regs_info): ...this.
1483 (the_low_target): Remove the op field.
1484 (get_usrregs_info): Update the call to the op.
1485 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1486 (nios2_regs_info): Turn into ...
1487 (nios2_target::get_regs_info): ...this.
1488 (the_low_target): Remove the op field.
1489 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1490 (ppc_regs_info): Turn into ...
1491 (ppc_target::get_regs_info): ...this.
1492 (the_low_target): Remove the op field.
1493 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1494 (riscv_regs_info): Turn into ...
1495 (riscv_target::get_regs_info): ...this.
1496 (the_low_target): Remove the op field.
1497 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1498 (s390_regs_info): Turn into ...
1499 (s390_target::get_regs_info): ...this.
1500 (the_low_target): Remove the op field.
1501 (s390_collect_ptrace_register)
1502 (s390_supply_ptrace_register)
1503 (s390_fill_gregset): Update the call to the op.
1504 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1505 (sh_regs_info): Turn into ...
1506 (sh_target::get_regs_info): ...this.
1507 (the_low_target): Remove the op field.
1508 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1509 (sparc_regs_info): Turn into ...
1510 (sparc_target::get_regs_info): ...this.
1511 (the_low_target): Remove the op field.
1512 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1513 (tic6x_regs_info): Turn into ...
1514 (tic6x_target::get_regs_info): ...this.
1515 (the_low_target): Remove the op field.
1516 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1517 (tile_regs_info): Turn into ...
1518 (tile_target::get_regs_info): ...this.
1519 (the_low_target): Remove the op field.
1520 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1521 Declare.
1522 (xtensa_regs_info): Turn into ...
1523 (xtensa_target::get_regs_info): ...this.
1524 (the_low_target): Remove the op field.
1525
1526 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1527
1528 Turn the 'arch_setup' linux target op into a method of
1529 linux_process_target.
1530
1531 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1532 (class linux_process_target) <arch_setup_thread>
1533 <low_arch_setup>: New declarations.
1534 * linux-low.cc (linux_arch_setup): Delete.
1535 (linux_arch_setup_thread): Turn into...
1536 (linux_process_target::arch_setup_thread): ... this.
1537
1538 Update the callers below.
1539
1540 (linux_process_target::handle_extended_wait)
1541 (linux_process_target::post_create_inferior)
1542 (linux_process_target::filter_event)
1543
1544 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1545 declaration.
1546 (x86_linux_update_xmltarget): Turn into...
1547 (x86_target::update_xmltarget): ...this.
1548 (x86_linux_process_qsupported): Update the call to
1549 x86_linux_update_xmltarget.
1550 (x86_arch_setup): Turn into ...
1551 (x86_target::low_arch_setup): ...this.
1552 (the_low_target): Remove the op field.
1553 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1554 declaration.
1555 (aarch64_arch_setup): Turn into ...
1556 (aarch64_target::low_arch_setup): ...this.
1557 (the_low_target): Remove the op field.
1558 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1559 declaration.
1560 (arm_arch_setup): Turn into ...
1561 (arm_target::low_arch_setup): ...this.
1562 (the_low_target): Remove the op field.
1563 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1564 declaration.
1565 (bfin_arch_setup): Turn into ...
1566 (bfin_target::low_arch_setup): ...this.
1567 (the_low_target): Remove the op field.
1568 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1569 declaration.
1570 (cris_arch_setup): Turn into ...
1571 (cris_target::low_arch_setup): ...this.
1572 (the_low_target): Remove the op field.
1573 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1574 declaration.
1575 (crisv32_arch_setup): Turn into ...
1576 (crisv32_target::low_arch_setup): ...this.
1577 (the_low_target): Remove the op field.
1578 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1579 declaration.
1580 (ia64_arch_setup): Turn into ...
1581 (ia64_target::low_arch_setup): ...this.
1582 (the_low_target): Remove the op field.
1583 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1584 declaration.
1585 (m32r_arch_setup): Turn into ...
1586 (m32r_target::low_arch_setup): ...this.
1587 (the_low_target): Remove the op field.
1588 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1589 declaration.
1590 (m68k_arch_setup): Turn into ...
1591 (m68k_target::low_arch_setup): ...this.
1592 (the_low_target): Remove the op field.
1593 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1594 declaration.
1595 (mips_arch_setup): Turn into ...
1596 (mips_target::low_arch_setup): ...this.
1597 (the_low_target): Remove the op field.
1598 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1599 declaration.
1600 (nios2_arch_setup): Turn into ...
1601 (nios2_target::low_arch_setup): ...this.
1602 (the_low_target): Remove the op field.
1603 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1604 declaration.
1605 (ppc_arch_setup): Turn into ...
1606 (ppc_target::low_arch_setup): ...this.
1607 (the_low_target): Remove the op field.
1608 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1609 declaration.
1610 (riscv_arch_setup): Turn into ...
1611 (riscv_target::low_arch_setup): ...this.
1612 (the_low_target): Remove the op field.
1613 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1614 declaration.
1615 (s390_arch_setup): Turn into ...
1616 (s390_target::low_arch_setup): ...this.
1617 (the_low_target): Remove the op field.
1618 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1619 declaration.
1620 (sh_arch_setup): Turn into ...
1621 (sh_target::low_arch_setup): ...this.
1622 (the_low_target): Remove the op field.
1623 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1624 declaration.
1625 (sparc_arch_setup): Turn into ...
1626 (sparc_target::low_arch_setup): ...this.
1627 (the_low_target): Remove the op field.
1628 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1629 declaration.
1630 (tic6x_arch_setup): Turn into ...
1631 (tic6x_target::low_arch_setup): ...this.
1632 (the_low_target): Remove the op field.
1633 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1634 declaration.
1635 (tile_arch_setup): Turn into ...
1636 (tile_target::low_arch_setup): ...this.
1637 (the_low_target): Remove the op field.
1638 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1639 declaration.
1640 (xtensa_arch_setup): Turn into ...
1641 (xtensa_target::low_arch_setup): ...this.
1642 (the_low_target): Remove the op field.
1643
1644 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1645
1646 * linux-low.h (the_linux_target): New extern declaration.
1647 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1648 'the_target'.
1649 (the_linux_target): Remove.
1650 * linux-x86-low.cc (class x86_target): New class.
1651 (the_x86_target): New static object.
1652 (the_linux_target): Define as pointer to the_x86_target.
1653 * linux-aarch64-low.cc (class aarch64_target): New class.
1654 (the_aarch64_target): New static object.
1655 (the_linux_target): Define as pointer to the_aarch64_target.
1656 * linux-arm-low.cc (class arm_target): New class.
1657 (the_arm_target): New static object.
1658 (the_linux_target): Define as pointer to the_arm_target.
1659 * linux-bfin-low.cc (class bfin_target): New class.
1660 (the_bfin_target): New static object.
1661 (the_linux_target): Define as pointer to the_bfin_target.
1662 * linux-cris-low.cc (class cris_target): New class.
1663 (the_cris_target): New static object.
1664 (the_linux_target): Define as pointer to the_cris_target.
1665 * linux-crisv32-low.cc (class crisv32_target): New class.
1666 (the_crisv32_target): New static object.
1667 (the_linux_target): Define as pointer to the_crisv32_target.
1668 * linux-ia64-low.cc (class ia64_target): New class.
1669 (the_ia64_target): New static object.
1670 (the_linux_target): Define as pointer to the_ia64_target.
1671 * linux-m32r-low.cc (class m32r_target): New class.
1672 (the_m32r_target): New static object.
1673 (the_linux_target): Define as pointer to the_m32r_target.
1674 * linux-m68k-low.cc (class m68k_target): New class.
1675 (the_m68k_target): New static object.
1676 (the_linux_target): Define as pointer to the_m68k_target.
1677 * linux-mips-low.cc (class mips_target): New class.
1678 (the_mips_target): New static object.
1679 (the_linux_target): Define as pointer to the_mips_target.
1680 * linux-nios2-low.cc (class nios2_target): New class.
1681 (the_nios2_target): New static object.
1682 (the_linux_target): Define as pointer to the_nios2_target.
1683 * linux-ppc-low.cc (class ppc_target): New class.
1684 (the_ppc_target): New static object.
1685 (the_linux_target): Define as pointer to the_ppc_target.
1686 * linux-riscv-low.cc (class riscv_target): New class.
1687 (the_riscv_target): New static object.
1688 (the_linux_target): Define as pointer to the_riscv_target.
1689 * linux-s390-low.cc (class s390_target): New class.
1690 (the_s390_target): New static object.
1691 (the_linux_target): Define as pointer to the_s390_target.
1692 * linux-sh-low.cc (class sh_target): New class.
1693 (the_sh_target): New static object.
1694 (the_linux_target): Define as pointer to the_sh_target.
1695 * linux-sparc-low.cc (class sparc_target): New class.
1696 (the_sparc_target): New static object.
1697 (the_linux_target): Define as pointer to the_sparc_target.
1698 * linux-tic6x-low.cc (class tic6x_target): New class.
1699 (the_tic6x_target): New static object.
1700 (the_linux_target): Define as pointer to the_tic6x_target.
1701 * linux-tile-low.cc (class tile_target): New class.
1702 (the_tile_target): New static object.
1703 (the_linux_target): Define as pointer to the_tile_target.
1704 * linux-xtensa-low.cc (class xtensa_target): New class.
1705 (the_xtensa_target): New static object.
1706 (the_linux_target): Define as pointer to the_xtensa_target.
1707
1708 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1709
1710 Turn some static functions in linux-low.cc into private methods of
1711 linux_process_target.
1712
1713 * linux-low.cc (handle_extended_wait): Turn into ...
1714 (linux_process_target::handle_extended_wait): ...this. Call
1715 'mourn' on 'this' object instead of 'the_target'.
1716 (maybe_move_out_of_jump_pad): Turn into...
1717 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
1718 (linux_low_filter_event): Turn into...
1719 (linux_process_target::filter_event): ...this.
1720 (linux_wait_for_event_filtered): Turn into...
1721 (linux_process_target::wait_for_event_filtered): ...this.
1722 (linux_wait_for_event): Turn into...
1723 (linux_process_target::wait_for_event): ...this.
1724 (linux_wait_1): Turn into...
1725 (linux_process_target::wait_1): ...this.
1726 (wait_for_sigstop): Turn into...
1727 (linux_process_target::wait_for_sigstop): ...this.
1728 (move_out_of_jump_pad_callback): Turn into...
1729 (linux_process_target::move_out_of_jump_pad): ...this.
1730 (stop_all_lwps): Turn into...
1731 (linux_process_target::stop_all_lwps): ...this.
1732 (start_step_over): Turn into...
1733 (linux_process_target::start_step_over): ...this.
1734 (complete_ongoing_step_over): Turn into...
1735 (linux_process_target::complete_ongoing_step_over): ...this.
1736 (proceed_all_lwps): Turn into...
1737 (linux_process_target::proceed_all_lwps): ...this.
1738 (unstop_all_lwps): Turn into...
1739 (linux_process_target::unstop_all_lwps): ...this.
1740
1741 * linux-low.h (class linux_process_target)
1742 <handle_extended_wait>
1743 <maybe_move_out_of_jump_pad>
1744 filter_event>
1745 <wait_for_event_filtered>
1746 <wait_for_event>
1747 <wait_1>
1748 <wait_for_sigstop>
1749 <move_out_of_jump_pad>
1750 <stop_all_lwps>
1751 <start_step_over>
1752 <complete_ongoing_step_over>
1753 <proceed_all_lwps>
1754 <unstop_all_lwps>: Declare.
1755
1756 Update the callers below.
1757
1758 * linux-low.cc (linux_process_target::attach): Update.
1759 (linux_process_target::stabilize_threads): Ditto.
1760 (linux_process_target::wait): Ditto.
1761
1762 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1763
1764 * linux-low.h (struct linux_target_ops): Update the comment for
1765 'cannot_store_register' to return 0 or 1.
1766 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
1767 of 2.
1768
1769 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
1770
1771 * config.in: Re-generate.
1772 * configure: Re-generate.
1773
1774 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1775
1776 * regcache.cc (find_register_by_number): Update.
1777 * tdesc.cc (init_target_desc): Likewise.
1778 * tdesc.h (target_desc::reg_defs): Likewise.
1779
1780 2020-03-12 Tom Tromey <tom@tromey.com>
1781
1782 * configure: Rebuild.
1783 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
1784 (WIN32APILIBS): New subst.
1785 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
1786 gdbsupport files.
1787 (gdbsupport/%.o): Remove target.
1788 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
1789 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
1790 (WIN32APILIBS): New variable.
1791 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
1792 (gdbreplay$(EXEEXT)): Likewise.
1793
1794 2020-03-12 Tom Tromey <tom@tromey.com>
1795
1796 * config.in, configure: Rebuild.
1797 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
1798 * acinclude.m4: Include gettext-sister.m4.
1799 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
1800 variables.
1801 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
1802 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
1803
1804 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
1805
1806 * acinclude.m4: Update path to selftest.m4.
1807
1808 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
1809
1810 * configure.ac: Don't source bfd/development.sh, move
1811 GDB_AC_COMMON higher.
1812 * configure: Re-generate.
1813
1814 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
1815
1816 * configure: Re-generate.
1817
1818 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
1819
1820 * configure: Re-generate.
1821
1822 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1823
1824 * .dir-locals.el: New file.
1825
1826 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1827
1828 * .gitattributes: New file.
1829
1830 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
1831
1832 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
1833 reply into an S reply.
1834 * server.cc (disable_packet_T): New global.
1835 (captured_main): Set new global when appropriate.
1836 * server.h (disable_packet_T): Declare.
1837
1838 2020-02-21 Tom Tromey <tom@tromey.com>
1839
1840 * Makefile.in (mostlyclean): New target.
1841
1842 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1843
1844 * target.h (struct process_stratum_target): Remove.
1845 (class process_target): Rename to ...
1846 (class process_stratum_target): ... this.
1847 * linux-low.h (class linux_process_target): Derive from
1848 'process_stratum_target'.
1849 * linux-low.cc (linux_target_ops): Remove.
1850 (initialize_low): Set the_target to the singleton instance of
1851 linux_process_target.
1852 * lynx-low.h (class lynx_process_target): Derive from
1853 'process_stratum_target'.
1854 * lynx-low.cc (lynx_target_ops): Remove.
1855 (initialize_low): Set the_target to the singleton instance of
1856 lynx_process_target.
1857 * nto-low.h (class nto_process_target): Derive from
1858 'process_stratum_target'.
1859 * nto-low.cc (nto_target_ops): Remove.
1860 (initialize_low): Set the_target to the singleton instance of
1861 nto_process_target.
1862 * win32-low.h (class win32_process_target): Derive from
1863 'process_stratum_target'.
1864 * win32-low.cc (win32_target_ops): Remove.
1865 (initialize_low): Set the_target to the singleton instance of
1866 win32_process_target.
1867
1868 Replace 'the_target->pt' with 'the_target' in the uses below.
1869
1870 * hostio.cc (hostio_error)
1871 (handle_setfs)
1872 (handle_open)
1873 (handle_unlink)
1874 (handle_readlink)
1875 * linux-aarch32-low.cc (arm_breakpoint_at)
1876 * linux-aarch64-low.cc (aarch64_breakpoint_at)
1877 * linux-arm-low.cc (arm_sigreturn_next_pc)
1878 (arm_get_hwcap)
1879 (arm_get_syscall_trapinfo)
1880 * linux-cris-low.cc (cris_breakpoint_at)
1881 * linux-crisv32-low.cc (cris_breakpoint_at)
1882 * linux-low.cc (handle_extended_wait)
1883 (linux_wait_1)
1884 (linux_read_memory)
1885 (linux_process_target::breakpoint_kind_from_pc)
1886 (linux_get_auxv)
1887 * linux-m32r-low.cc (m32r_breakpoint_at)
1888 * linux-mips-low.cc (mips_breakpoint_at)
1889 * linux-nios2-low.cc (nios2_breakpoint_at)
1890 * linux-ppc-low.cc (ppc_breakpoint_at)
1891 * linux-s390-low.cc (s390_get_hwcap)
1892 * linux-sh-low.cc (sh_breakpoint_at)
1893 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
1894 (sparc_store_gregset_from_stack)
1895 (sparc_breakpoint_at)
1896 * linux-tic6x-low.cc (tic6x_breakpoint_at)
1897 * linux-tile-low.cc (tile_breakpoint_at)
1898 * linux-x86-low.cc (x86_breakpoint_at)
1899 * linux-xtensa-low.cc (xtensa_breakpoint_at)
1900 * mem-break.cc (bp_size)
1901 (bp_opcode)
1902 (insert_memory_breakpoint)
1903 (set_raw_breakpoint_at)
1904 (delete_raw_breakpoint)
1905 (z_type_supported)
1906 (uninsert_raw_breakpoint)
1907 (reinsert_raw_breakpoint)
1908 (validate_inserted_breakpoint)
1909 * regcache.cc (regcache_read_pc)
1910 (regcache_write_pc)
1911 * remote-utils.cc (putpkt_binary_1)
1912 (input_interrupt)
1913 (getpkt)
1914 (prepare_resume_reply)
1915 * server.cc (handle_general_set)
1916 (handle_detach)
1917 (handle_qxfer_auxv)
1918 (handle_qxfer_exec_file)
1919 (handle_qxfer_libraries_svr4)
1920 (handle_qxfer_osdata)
1921 (handle_qxfer_siginfo)
1922 (handle_qxfer_fdpic)
1923 (handle_query)
1924 (resume)
1925 (handle_v_requests)
1926 (queue_stop_reply_callback)
1927 (captured_main)
1928 * target.cc (prepare_to_access_memory)
1929 (done_accessing_memory)
1930 (read_inferior_memory)
1931 (target_write_memory)
1932 (target_stop_and_wait)
1933 (target_wait)
1934 (target_mourn_inferior)
1935 (target_continue_no_signal)
1936 (target_continue)
1937 (target_supports_multi_process)
1938 (kill_inferior)
1939 * target.h
1940 (target_create_inferior)
1941 (target_post_create_inferior)
1942 (myattach)
1943 (target_supports_fork_events)
1944 (target_supports_vfork_events)
1945 (target_supports_exec_events)
1946 (target_handle_new_gdb_connection)
1947 (detach_inferior)
1948 (mythread_alive)
1949 (fetch_inferior_registers)
1950 (store_inferior_registers)
1951 (join_inferior)
1952 (target_supports_non_stop)
1953 (target_async)
1954 (target_process_qsupported)
1955 (target_supports_catch_syscall)
1956 (target_get_ipa_tdesc_idx)
1957 (target_supports_tracepoints)
1958 (target_supports_fast_tracepoints)
1959 (target_get_min_fast_tracepoint_insn_len)
1960 (target_thread_stopped)
1961 (target_pause_all)
1962 (target_unpause_all)
1963 (target_stabilize_threads)
1964 (target_install_fast_tracepoint_jump_pad)
1965 (target_emit_ops)
1966 (target_supports_disable_randomization)
1967 (target_supports_agent)
1968 (target_enable_btrace)
1969 (target_disable_btrace)
1970 (target_read_btrace)
1971 (target_read_btrace_conf)
1972 (target_supports_range_stepping)
1973 (target_supports_stopped_by_sw_breakpoint)
1974 (target_stopped_by_sw_breakpoint)
1975 (target_supports_stopped_by_hw_breakpoint)
1976 (target_supports_hardware_single_step)
1977 (target_stopped_by_hw_breakpoint)
1978 (target_breakpoint_kind_from_pc)
1979 (target_breakpoint_kind_from_current_state)
1980 (target_supports_software_single_step)
1981 (target_core_of_thread)
1982 (target_thread_name)
1983 (target_thread_handle)
1984 * win32-low.cc (do_initial_child_stuff)
1985
1986 Rename target op default definitions listed below.
1987
1988 * target.cc (process_target::post_create_inferior): Rename as ...
1989 (process_stratum_target::post_create_inferior): ... this.
1990 (process_target::prepare_to_access_memory): Rename as ...
1991 (process_stratum_target::prepare_to_access_memory): ... this.
1992 (process_target::done_accessing_memory): Rename as ...
1993 (process_stratum_target::done_accessing_memory): ... this.
1994 (process_target::look_up_symbols): Rename as ...
1995 (process_stratum_target::look_up_symbols): ... this.
1996 (process_target::supports_read_auxv): Rename as ...
1997 (process_stratum_target::supports_read_auxv): ... this.
1998 (process_target::read_auxv): Rename as ...
1999 (process_stratum_target::read_auxv): ... this.
2000 (process_target::supports_z_point_type): Rename as ...
2001 (process_stratum_target::supports_z_point_type): ... this.
2002 (process_target::insert_point): Rename as ...
2003 (process_stratum_target::insert_point): ... this.
2004 (process_target::remove_point): Rename as ...
2005 (process_stratum_target::remove_point): ... this.
2006 (process_target::stopped_by_sw_breakpoint): Rename as ...
2007 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2008 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2009 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2010 (process_target::stopped_by_hw_breakpoint): Rename as ...
2011 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2012 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2013 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2014 (process_target::supports_hardware_single_step): Rename as ...
2015 (process_stratum_target::supports_hardware_single_step): ... this.
2016 (process_target::stopped_by_watchpoint): Rename as ...
2017 (process_stratum_target::stopped_by_watchpoint): ... this.
2018 (process_target::stopped_data_address): Rename as ...
2019 (process_stratum_target::stopped_data_address): ... this.
2020 (process_target::supports_read_offsets): Rename as ...
2021 (process_stratum_target::supports_read_offsets): ... this.
2022 (process_target::read_offsets): Rename as ...
2023 (process_stratum_target::read_offsets): ... this.
2024 (process_target::supports_get_tls_address): Rename as ...
2025 (process_stratum_target::supports_get_tls_address): ... this.
2026 (process_target::get_tls_address): Rename as ...
2027 (process_stratum_target::get_tls_address): ... this.
2028 (process_target::hostio_last_error): Rename as ...
2029 (process_stratum_target::hostio_last_error): ... this.
2030 (process_target::supports_qxfer_osdata): Rename as ...
2031 (process_stratum_target::supports_qxfer_osdata): ... this.
2032 (process_target::qxfer_osdata): Rename as ...
2033 (process_stratum_target::qxfer_osdata): ... this.
2034 (process_target::supports_qxfer_siginfo): Rename as ...
2035 (process_stratum_target::supports_qxfer_siginfo): ... this.
2036 (process_target::qxfer_siginfo): Rename as ...
2037 (process_stratum_target::qxfer_siginfo): ... this.
2038 (process_target::supports_non_stop): Rename as ...
2039 (process_stratum_target::supports_non_stop): ... this.
2040 (process_target::async): Rename as ...
2041 (process_stratum_target::async): ... this.
2042 (process_target::start_non_stop): Rename as ...
2043 (process_stratum_target::start_non_stop): ... this.
2044 (process_target::supports_multi_process): Rename as ...
2045 (process_stratum_target::supports_multi_process): ... this.
2046 (process_target::supports_fork_events): Rename as ...
2047 (process_stratum_target::supports_fork_events): ... this.
2048 (process_target::supports_vfork_events): Rename as ...
2049 (process_stratum_target::supports_vfork_events): ... this.
2050 (process_target::supports_exec_events): Rename as ...
2051 (process_stratum_target::supports_exec_events): ... this.
2052 (process_target::handle_new_gdb_connection): Rename as ...
2053 (process_stratum_target::handle_new_gdb_connection): ... this.
2054 (process_target::handle_monitor_command): Rename as ...
2055 (process_stratum_target::handle_monitor_command): ... this.
2056 (process_target::core_of_thread): Rename as ...
2057 (process_stratum_target::core_of_thread): ... this.
2058 (process_target::supports_read_loadmap): Rename as ...
2059 (process_stratum_target::supports_read_loadmap): ... this.
2060 (process_target::read_loadmap): Rename as ...
2061 (process_stratum_target::read_loadmap): ... this.
2062 (process_target::process_qsupported): Rename as ...
2063 (process_stratum_target::process_qsupported): ... this.
2064 (process_target::supports_tracepoints): Rename as ...
2065 (process_stratum_target::supports_tracepoints): ... this.
2066 (process_target::read_pc): Rename as ...
2067 (process_stratum_target::read_pc): ... this.
2068 (process_target::write_pc): Rename as ...
2069 (process_stratum_target::write_pc): ... this.
2070 (process_target::supports_thread_stopped): Rename as ...
2071 (process_stratum_target::supports_thread_stopped): ... this.
2072 (process_target::thread_stopped): Rename as ...
2073 (process_stratum_target::thread_stopped): ... this.
2074 (process_target::supports_get_tib_address): Rename as ...
2075 (process_stratum_target::supports_get_tib_address): ... this.
2076 (process_target::get_tib_address): Rename as ...
2077 (process_stratum_target::get_tib_address): ... this.
2078 (process_target::pause_all): Rename as ...
2079 (process_stratum_target::pause_all): ... this.
2080 (process_target::unpause_all): Rename as ...
2081 (process_stratum_target::unpause_all): ... this.
2082 (process_target::stabilize_threads): Rename as ...
2083 (process_stratum_target::stabilize_threads): ... this.
2084 (process_target::supports_fast_tracepoints): Rename as ...
2085 (process_stratum_target::supports_fast_tracepoints): ... this.
2086 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2087 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2088 (process_target::emit_ops): Rename as ...
2089 (process_stratum_target::emit_ops): ... this.
2090 (process_target::supports_disable_randomization): Rename as ...
2091 (process_stratum_target::supports_disable_randomization): ... this.
2092 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2093 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2094 (process_target::qxfer_libraries_svr4): Rename as ...
2095 (process_stratum_target::qxfer_libraries_svr4): ... this.
2096 (process_target::supports_agent): Rename as ...
2097 (process_stratum_target::supports_agent): ... this.
2098 (process_target::enable_btrace): Rename as ...
2099 (process_stratum_target::enable_btrace): ... this.
2100 (process_target::disable_btrace): Rename as ...
2101 (process_stratum_target::disable_btrace): ... this.
2102 (process_target::read_btrace): Rename as ...
2103 (process_stratum_target::read_btrace): ... this.
2104 (process_target::read_btrace_conf): Rename as ...
2105 (process_stratum_target::read_btrace_conf): ... this.
2106 (process_target::supports_range_stepping): Rename as ...
2107 (process_stratum_target::supports_range_stepping): ... this.
2108 (process_target::supports_pid_to_exec_file): Rename as ...
2109 (process_stratum_target::supports_pid_to_exec_file): ... this.
2110 (process_target::pid_to_exec_file): Rename as ...
2111 (process_stratum_target::pid_to_exec_file): ... this.
2112 (process_target::supports_multifs): Rename as ...
2113 (process_stratum_target::supports_multifs): ... this.
2114 (process_target::multifs_open): Rename as ...
2115 (process_stratum_target::multifs_open): ... this.
2116 (process_target::multifs_unlink): Rename as ...
2117 (process_stratum_target::multifs_unlink): ... this.
2118 (process_target::multifs_readlink): Rename as ...
2119 (process_stratum_target::multifs_readlink): ... this.
2120 (process_target::breakpoint_kind_from_pc): Rename as ...
2121 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2122 (process_target::breakpoint_kind_from_current_state): Rename as ...
2123 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2124 (process_target::thread_name): Rename as ...
2125 (process_stratum_target::thread_name): ... this.
2126 (process_target::thread_handle): Rename as ...
2127 (process_stratum_target::thread_handle): ... this.
2128 (process_target::supports_software_single_step): Rename as ...
2129 (process_stratum_target::supports_software_single_step): ... this.
2130 (process_target::supports_catch_syscall): Rename as ...
2131 (process_stratum_target::supports_catch_syscall): ... this.
2132 (process_target::get_ipa_tdesc_idx): Rename as ...
2133 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2134
2135 2020-02-20 Pedro Alves <palves@redhat.com>
2136
2137 * target.cc (set_target_ops): Simply copy the given target pointer
2138 instead of creating a copy of the pointed object.
2139
2140 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2141
2142 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2143 of process_target.
2144
2145 * target.h (struct process_stratum_target): Remove the target op.
2146 (class process_target): Add the target op.
2147 (target_get_ipa_tdesc_idx): Update the macro.
2148 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2149
2150 Update the derived classes and callers below.
2151
2152 * linux-low.cc (linux_target_ops): Update.
2153 (linux_get_ipa_tdesc_idx): Turn into ...
2154 (linux_process_target::get_ipa_tdesc_idx): ... this.
2155 * linux-low.h (class linux_process_target): Update.
2156 * lynx-low.cc (lynx_target_ops): Update.
2157 * nto-low.cc (nto_target_ops): Update.
2158 * win32-low.cc (win32_target_ops): Update.
2159
2160 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2161
2162 Turn process_stratum_target's supports_catch_syscall op into a
2163 method of process_target.
2164
2165 * target.h (struct process_stratum_target): Remove the target op.
2166 (class process_target): Add the target op.
2167 (target_supports_catch_syscall): Update the macro.
2168 * target.cc (process_target::supports_catch_syscall): Define.
2169
2170 Update the derived classes and callers below.
2171
2172 * linux-low.cc (linux_target_ops): Update.
2173 (linux_supports_catch_syscall): Turn into ...
2174 (linux_process_target::supports_catch_syscall): ... this.
2175 * linux-low.h (class linux_process_target): Update.
2176 * lynx-low.cc (lynx_target_ops): Update.
2177 * nto-low.cc (nto_target_ops): Update.
2178 * win32-low.cc (win32_target_ops): Update.
2179
2180 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2181
2182 Turn process_stratum_target's supports_software_single_step op
2183 into a method of process_target.
2184
2185 * target.h (struct process_stratum_target): Remove the target op.
2186 (class process_target): Add the target op.
2187 (target_supports_software_single_step): Update the macro.
2188 * target.cc (process_target::supports_software_single_step): Define.
2189
2190 Update the derived classes and callers below.
2191
2192 * linux-low.cc (linux_target_ops): Update.
2193 (linux_supports_software_single_step): Turn into ...
2194 (linux_process_target::supports_software_single_step): ... this.
2195 * linux-low.h (class linux_process_target): Update.
2196 * lynx-low.cc (lynx_target_ops): Update.
2197 * nto-low.cc (nto_target_ops): Update.
2198 * win32-low.cc (win32_target_ops): Update.
2199
2200 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2201
2202 Turn process_stratum_target's thread_name and thread_handle ops
2203 into methods of process_target.
2204
2205 * target.h (struct process_stratum_target): Remove the target ops.
2206 (class process_target): Add the target ops.
2207 (target_thread_name): Update the macro.
2208 (target_thread_handle): Update the macro.
2209 * target.cc (process_target::thread_name): Define.
2210 (process_target::thread_handle): Define.
2211
2212 Update the derived classes and callers below.
2213
2214 * linux-low.cc (linux_target_ops): Update.
2215 (linux_process_target::thread_name): Define.
2216 (linux_process_target::thread_handle): Define.
2217 * linux-low.h (class linux_process_target): Update.
2218 * lynx-low.cc (lynx_target_ops): Update.
2219 * nto-low.cc (nto_target_ops): Update.
2220 * win32-low.cc (win32_target_ops): Update.
2221
2222 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2223
2224 Turn process_stratum_target's breakpoint_kind_from_pc,
2225 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2226 ops into methods of process_target.
2227
2228 * target.h (struct process_stratum_target): Remove the target op.
2229 (class process_target): Add the target op.
2230 (target_breakpoint_kind_from_pc): Update the macro.
2231 (target_breakpoint_kind_from_current_state): Update the macro.
2232 (default_breakpoint_kind_from_pc): Remove declaration.
2233 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2234 (process_target::breakpoint_kind_from_pc): ... this.
2235 (process_target::breakpoint_kind_from_current_state): Define.
2236
2237 Update the derived classes and callers below.
2238
2239 * mem-break.cc (bp_size): Update.
2240 (bp_opcode): Update.
2241 * linux-low.cc (linux_target_ops): Update.
2242 (linux_wait_1): Update.
2243 (linux_breakpoint_kind_from_pc): Turn into ...
2244 (linux_process_target::breakpoint_kind_from_pc): ... this.
2245 (linux_sw_breakpoint_from_kind): Turn into ...
2246 (linux_process_target::sw_breakpoint_from_kind): ... this.
2247 (linux_breakpoint_kind_from_current_state): Turn into ...
2248 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2249 * linux-low.h (class linux_process_target): Update.
2250 * lynx-low.cc (lynx_target_ops): Update.
2251 (lynx_process_target::sw_breakpoint_from_kind): Define.
2252 * lynx-low.h (class lynx_process_target): Update.
2253 * nto-low.cc (nto_target_ops): Update.
2254 (nto_sw_breakpoint_from_kind): Turn into ...
2255 (nto_process_target::sw_breakpoint_from_kind): ... this.
2256 * nto-low.h (class nto_process_target): Update.
2257 * win32-low.cc (win32_target_ops): Update.
2258 (win32_sw_breakpoint_from_kind): Turn into ...
2259 (win32_process_target::sw_breakpoint_from_kind): ... this.
2260 * win32-low.h (class win32_process_target): Update.
2261
2262 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2263
2264 Turn process_stratum_target's multifs_open, multifs_readlink,
2265 multifs_unlink ops into methods of process_target.
2266
2267 * target.h (struct process_stratum_target): Remove the target ops.
2268 (class process_target): Add the target ops. Also add
2269 'supports_multifs'.
2270 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2271 "sys/stat.h".
2272 (process_target::supports_multifs): Define.
2273 (process_target::multifs_open): Define.
2274 (process_target::multifs_readlink): Define.
2275 (process_target::multifs_unlink): Define.
2276
2277 Update the derived classes and callers below.
2278
2279 * hostio.cc (handle_setfs): Update.
2280 (handle_open): Update.
2281 (handle_unlink): Update.
2282 (handle_readlink): Update.
2283 * linux-low.cc (linux_target_ops): Update.
2284 (linux_process_target::supports_multifs): Define.
2285 (linux_process_target::multifs_open): Define.
2286 (linux_process_target::multifs_readlink): Define.
2287 (linux_process_target::multifs_unlink): Define.
2288 * linux-low.h (class linux_process_target): Update.
2289 * lynx-low.cc (lynx_target_ops): Update.
2290 * nto-low.cc (nto_target_ops): Update.
2291 * win32-low.cc (win32_target_ops): Update.
2292
2293 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2294
2295 Turn process_stratum_target's pid_to_exec_file op into a method
2296 of process_target.
2297
2298 * target.h (struct process_stratum_target): Remove the target op.
2299 (class process_target): Add the target op. Also add
2300 'supports_pid_to_exec_file'.
2301 * target.cc (process_target::pid_to_exec_file): Define.
2302 (process_target::supports_pid_to_exec_file): Define.
2303
2304 Update the derived classes and callers below.
2305
2306 * server.cc (handle_qxfer_exec_file): Update.
2307 (handle_query): Update.
2308 * linux-low.cc (linux_target_ops): Update.
2309 (linux_process_target::supports_pid_to_exec_file): Define.
2310 (linux_process_target::pid_to_exec_file): Define.
2311 * linux-low.h (class linux_process_target): Update.
2312 * lynx-low.cc (lynx_target_ops): Update.
2313 * nto-low.cc (nto_target_ops): Update.
2314 * win32-low.cc (win32_target_ops): Update.
2315
2316 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2317
2318 Turn process_stratum_target's supports_range_stepping op into a
2319 method of process_target.
2320
2321 * target.h (struct process_stratum_target): Remove the target op.
2322 (class process_target): Add the target op.
2323 (target_supports_range_stepping): Update the macro.
2324 * target.cc (process_target::supports_range_stepping): Define.
2325
2326 Update the derived classes and callers below.
2327
2328 * linux-low.cc (linux_target_ops): Update.
2329 (linux_supports_range_stepping): Turn into ...
2330 (linux_process_target::supports_range_stepping): ... this.
2331 * linux-low.h (class linux_process_target): Update.
2332 * lynx-low.cc (lynx_target_ops): Update.
2333 * nto-low.cc (nto_target_ops): Update.
2334 * win32-low.cc (win32_target_ops): Update.
2335
2336 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2337
2338 Turn process_stratum_target's btrace-related ops (enable_btrace,
2339 disable_btrace, read_btrace, read_btrace_conf) into methods of
2340 process_target.
2341
2342 * target.h (struct process_stratum_target): Remove the target ops.
2343 (class process_target): Add the target ops.
2344 (target_enable_btrace): Update.
2345 (target_disable_btrace): Update.
2346 (target_read_btrace): Update.
2347 (target_read_btrace_conf): Update.
2348 * target.cc (process_target::enable_btrace): Define.
2349 (process_target::disable_btrace): Define.
2350 (process_target::read_btrace): Define.
2351 (process_target::read_btrace_conf): Define.
2352
2353 Update the derived classes and callers below.
2354
2355 * linux-low.cc (linux_target_ops): Update.
2356 (linux_process_target:enable_btrace): Define as a wrapper around
2357 linux_enable_btrace.
2358 (linux_low_disable_btrace): Turn into ...
2359 (linux_process_target::disable_btrace): ... this.
2360 (linux_low_read_btrace): Turn into ...
2361 (linux_process_target::read_btrace): ... this.
2362 (linux_low_btrace_conf): Turn into ...
2363 (linux_process_target::read_btrace_conf): ... this.
2364 * linux-low.h (class linux_process_target): Update.
2365 * lynx-low.cc (lynx_target_ops): Update.
2366 * nto-low.cc (nto_target_ops): Update.
2367 * win32-low.cc (win32_target_ops): Update.
2368
2369 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2370
2371 Turn process_stratum_target's supports_agent op into a method of
2372 process_target.
2373
2374 * target.h (struct process_stratum_target): Remove the target op.
2375 (class process_target): Add the target op.
2376 (target_supports_agent): Update the macro.
2377 * target.cc (process_target::supports_agent): Define.
2378
2379 Update the derived classes and callers below.
2380
2381 * linux-low.cc (linux_target_ops): Update.
2382 (linux_supports_agent): Turn into ...
2383 (linux_process_target::supports_agent): ... this.
2384 * linux-low.h (class linux_process_target): Update.
2385 * lynx-low.cc (lynx_target_ops): Update.
2386 * nto-low.cc (nto_target_ops): Update.
2387 * win32-low.cc (win32_target_ops): Update.
2388
2389 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2390
2391 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2392 method of process_target.
2393
2394 * target.h (struct process_stratum_target): Remove the target op.
2395 (class process_target): Add the target op. Also add
2396 'supports_qxfer_libraries_svr4'.
2397 * target.cc (process_target::qxfer_libraries_svr4): Define.
2398 (process_target::supports_qxfer_libraries_svr4): Define.
2399
2400 Update the derived classes and callers below.
2401
2402 * server.cc (handle_qxfer_libraries_svr4): Update.
2403 (handle_query): Update.
2404 * linux-low.cc (linux_target_ops): Update.
2405 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2406 (linux_qxfer_libraries_svr4): Turn into ...
2407 (linux_process_target::qxfer_libraries_svr4): ... this.
2408 * linux-low.h (class linux_process_target): Update.
2409 * lynx-low.cc (lynx_target_ops): Update.
2410 * nto-low.cc (nto_target_ops): Update.
2411 * win32-low.cc (win32_target_ops): Update.
2412
2413 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2414
2415 Turn process_stratum_target's supports_disable_randomization op
2416 into a method of process_target.
2417
2418 * target.h (struct process_stratum_target): Remove the target op.
2419 (class process_target): Add the target op.
2420 (target_supports_disable_randomization): Update the macro.
2421 * target.cc (process_target::supports_disable_randomization): Define.
2422
2423 Update the derived classes and callers below.
2424
2425 * linux-low.cc (linux_target_ops): Update.
2426 (linux_supports_disable_randomization): Turn into ...
2427 (linux_process_target::supports_disable_randomization): ... this.
2428 * linux-low.h (class linux_process_target): Update.
2429 * lynx-low.cc (lynx_target_ops): Update.
2430 * nto-low.cc (nto_target_ops): Update.
2431 * win32-low.cc (win32_target_ops): Update.
2432
2433 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2434
2435 Turn process_stratum_target's emit_ops op into a method of
2436 process_target.
2437
2438 * target.h (struct process_stratum_target): Remove the target op.
2439 (class process_target): Add the target op.
2440 (target_emit_ops): Update the macro.
2441 * target.cc (process_target::emit_ops): Define.
2442
2443 Update the derived classes and callers below.
2444
2445 * linux-low.cc (linux_target_ops): Update.
2446 (linux_emit_ops): Turn into ...
2447 (linux_process_target::emit_ops): ... this.
2448 * linux-low.h (class linux_process_target): Update.
2449 * lynx-low.cc (lynx_target_ops): Update.
2450 * nto-low.cc (nto_target_ops): Update.
2451 * win32-low.cc (win32_target_ops): Update.
2452
2453 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2454
2455 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2456 and get_min_fast_tracepoint_insn_len ops into methods of
2457 process_target.
2458
2459 * target.h (struct process_stratum_target): Remove the target ops.
2460 (class process_target): Add the target ops. Also add
2461 'supports_fast_tracepoints'.
2462 (target_supports_fast_tracepoints): Update the macro.
2463 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2464 (install_fast_tracepoint_jump_pad): Update and rename the macro
2465 to ...
2466 (target_install_fast_tracepoint_jump_pad): ... this.
2467 * target.cc (process_target::supports_fast_tracepoints): Define.
2468 (process_target::install_fast_tracepoint_jump_pad): Define.
2469 (process_target::get_min_fast_tracepoint_insn_len): Define.
2470
2471 Update the derived classes and callers below.
2472
2473 * tracepoint.cc (install_fast_tracepoint): Update.
2474 * linux-low.cc (linux_target_ops): Update.
2475 (linux_process_target::supports_fast_tracepoints): Define.
2476 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2477 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2478 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2479 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2480 * linux-low.h (class linux_process_target): Update.
2481 * lynx-low.cc (lynx_target_ops): Update.
2482 * nto-low.cc (nto_target_ops): Update.
2483 * win32-low.cc (win32_target_ops): Update.
2484
2485 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2486
2487 Turn process_stratum_target's stabilize_threads op into a
2488 method of process_target.
2489
2490 * target.h (struct process_stratum_target): Remove the target op.
2491 (class process_target): Add the target op.
2492 (target_stabilize_threads): Update the macro.
2493 * target.cc (process_target::stabilize_threads): Define.
2494
2495 Update the derived classes and callers below.
2496
2497 * server.cc (handle_status): Update.
2498 * tracepoint.cc (cmd_qtdp): Update.
2499 (cmd_qtstart): Update.
2500 * linux-low.cc (linux_target_ops): Update.
2501 (linux_stabilize_threads): Turn into ...
2502 (linux_process_target::stabilize_threads): ... this.
2503 (linux_wait_1): Update.
2504 * linux-low.h (class linux_process_target): Update.
2505 * lynx-low.cc (lynx_target_ops): Update.
2506 * nto-low.cc (nto_target_ops): Update.
2507 * win32-low.cc (win32_target_ops): Update.
2508
2509 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2510
2511 Turn process_stratum_target's pause_all and unpause_all ops
2512 into methods of process_target.
2513
2514 * target.h (struct process_stratum_target): Remove the target ops.
2515 (class process_target): Add the target ops.
2516 (pause_all): Update the macro and rename to...
2517 (target_pause_all): ... this.
2518 (unpause_all): Update the macro and rename to...
2519 (target_unpause_all): ... this.
2520 * target.cc (process_target::pause_all): Define.
2521 (process_target::unpause_all): Define.
2522
2523 Update the derived classes and callers below.
2524
2525 * server.cc (handle_status): Update.
2526 * tracepoint.cc (clear_installed_tracepoints): Update.
2527 (cmd_qtdp): Update.
2528 (cmd_qtstart): Update.
2529 (stop_tracing): Update.
2530 (cmd_qtstatus): Update.
2531 (upload_fast_traceframes): Update.
2532 (run_inferior_command): Update.
2533 * linux-low.cc (linux_target_ops): Update.
2534 (linux_pause_all): Turn into ...
2535 (linux_process_target::pause_all): ... this.
2536 (linux_unpause_all): Turn into ...
2537 (linux_process_target::unpause_all): ... this.
2538 (linux_process_target::prepare_to_access_memory): Update.
2539 (linux_process_target::done_accessing_memory): Update.
2540 * linux-low.h (class linux_process_target): Update.
2541 * lynx-low.cc (lynx_target_ops): Update.
2542 * nto-low.cc (nto_target_ops): Update.
2543 * win32-low.cc (win32_target_ops): Update.
2544
2545 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2546
2547 Turn process_stratum_target's get_tib_address op into a method of
2548 process_target.
2549
2550 * target.h (struct process_stratum_target): Remove the target op.
2551 (class process_target): Add the target op. Also add
2552 'supports_get_tib_address'.
2553 * target.cc (process_target::get_tib_address): Define.
2554 (process_target::supports_get_tib_address): Define.
2555
2556 Update the derived classes and callers below.
2557
2558 * server.cc (handle_query): Update.
2559 * linux-low.cc (win32_target_ops): Update.
2560 * lynx-low.cc (lynx_target_ops): Update.
2561 * nto-low.cc (nto_target_ops): Update.
2562 * win32-low.cc (win32_target_ops): Update.
2563 (win32_process_target::supports_get_tib_address): Define.
2564 (win32_get_tib_address): Turn into ...
2565 (win32_process_target::get_tib_address): ... this.
2566 * win32-low.h (class win32_process_target): Update.
2567
2568 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2569
2570 Turn process_stratum_target's thread_stopped op into a method of
2571 process_target.
2572
2573 * target.h (struct process_stratum_target): Remove the target op.
2574 (class process_target): Add the target op. Also add
2575 'supports_thread_stopped'.
2576 (target_thread_stopped): Update the macro.
2577 * target.cc (process_target::thread_stopped): Define.
2578 (process_target::supports_thread_stopped): Define.
2579 (prepare_to_access_memory): Update.
2580
2581 Update the derived classes and callers below.
2582
2583 * server.cc (queue_stop_reply_callback): Update.
2584 * linux-low.cc (linux_target_ops): Update.
2585 (linux_process_target::supports_thread_stopped): Define.
2586 (linux_thread_stopped): Turn into ...
2587 (linux_process_target::thread_stopped): ... this.
2588 * linux-low.h (class linux_process_target): Update.
2589 * lynx-low.cc (lynx_target_ops): Update.
2590 * nto-low.cc (nto_target_ops): Update.
2591 * win32-low.cc (win32_target_ops): Update.
2592
2593 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2594
2595 Turn process_stratum_target's read_pc and write_pc ops into
2596 methods of process_target.
2597
2598 * target.h (struct process_stratum_target): Remove the target ops.
2599 (class process_target): Add the target ops.
2600 * target.cc (process_target::read_pc): Define.
2601 (process_target::write_pc): Define.
2602
2603 Update the derived classes and callers below.
2604
2605 * regcache.cc (regcache_read_pc): Update.
2606 (regcache_write_pc): Update.
2607 * linux-low.cc (linux_target_ops): Update.
2608 (linux_read_pc): Turn into ...
2609 (linux_process_target::read_pc): ... this.
2610 (linux_write_pc): Turn into ...
2611 (linux_process_target::write_pc): ... this.
2612 * linux-low.h (class linux_process_target): Update.
2613 * lynx-low.cc (lynx_target_ops): Update.
2614 * nto-low.cc (nto_target_ops): Update.
2615 * win32-low.cc (win32_target_ops): Update.
2616
2617 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2618
2619 Turn process_stratum_target's supports_tracepoints op into a
2620 method of process_target.
2621
2622 * target.h (struct process_stratum_target): Remove the target op.
2623 (class process_target): Add the target op.
2624 (target_supports_tracepoints): Update the macro.
2625 * target.cc (process_target::supports_tracepoints): Define.
2626
2627 Update the derived classes and callers below.
2628
2629 * linux-low.cc (linux_target_ops): Update.
2630 (linux_supports_tracepoints): Turn into ...
2631 (linux_process_target::supports_tracepoints): ... this.
2632 * linux-low.h (class linux_process_target): Update.
2633 * lynx-low.cc (lynx_target_ops): Update.
2634 * nto-low.cc (nto_target_ops): Update.
2635 * win32-low.cc (win32_target_ops): Update.
2636
2637 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2638
2639 Turn process_stratum_target's process_qsupported op into a method
2640 of process_target.
2641
2642 * target.h (struct process_stratum_target): Remove the target op.
2643 (class process_target): Add the target op.
2644 (target_process_qsupported): Update the macro.
2645 * target.cc (process_target::process_qsupported): Define.
2646
2647 Update the derived classes and callers below.
2648
2649 * linux-low.cc (linux_target_ops): Update.
2650 (linux_process_qsupported): Turn into ...
2651 (linux_process_target::process_qsupported): ... this.
2652 * linux-low.h (class linux_process_target): Update.
2653 * lynx-low.cc (lynx_target_ops): Update.
2654 * nto-low.cc (nto_target_ops): Update.
2655 * win32-low.cc (win32_target_ops): Update.
2656
2657 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2658
2659 Turn process_stratum_target's read_loadmap op into a method of
2660 process_target.
2661
2662 * target.h (struct process_stratum_target): Remove the target op.
2663 (class process_target): Add the target op. Also add
2664 'supports_read_loadmap'.
2665 * target.cc (process_target::read_loadmap): Define.
2666 (process_target::supports_read_loadmap): Define.
2667
2668 Update the derived classes and callers below.
2669
2670 * server.cc (handle_qxfer_fdpic): Update.
2671 (handle_query): Update.
2672 * linux-low.cc (linux_target_ops): Update.
2673 (linux_process_target::supports_read_loadmap): Define.
2674 (linux_read_loadmap): Turn into ...
2675 (linux_process_target::read_loadmap): ... this.
2676 * linux-low.h (class linux_process_target): Update.
2677 * lynx-low.cc (lynx_target_ops): Update.
2678 * nto-low.cc (nto_target_ops): Update.
2679 * win32-low.cc (win32_target_ops): Update.
2680
2681 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2682
2683 Turn process_stratum_target's core_of_thread op into a method of
2684 process_target.
2685
2686 * target.h (struct process_stratum_target): Remove the target op.
2687 (class process_target): Add the target op.
2688 (target_core_of_thread): Update the macro.
2689 * target.cc (process_target::core_of_thread): Define.
2690
2691 Update the derived classes and callers below.
2692
2693 * linux-low.cc (linux_target_ops): Update.
2694 (linux_process_target::core_of_thread): Define.
2695 * linux-low.h (class linux_process_target): Update.
2696 * lynx-low.cc (lynx_target_ops): Update.
2697 * nto-low.cc (nto_target_ops): Update.
2698 * win32-low.cc (win32_target_ops): Update.
2699
2700 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2701
2702 Turn process_stratum_target's handle_monitor_command op into a
2703 method of process_target.
2704
2705 * target.h (struct process_stratum_target): Remove the target op.
2706 (class process_target): Add the target op.
2707 (target_handle_monitor_command): Update the macro.
2708 * target.cc (process_target::handle_monitor_command): Define.
2709
2710 Update the derived classes and callers below.
2711
2712 * server.cc (handle_query): Update.
2713 * linux-low.cc (linux_target_ops): Update.
2714 (linux_process_target::handle_monitor_command): Define.
2715 * linux-low.h (class linux_process_target): Update.
2716 * lynx-low.cc (lynx_target_ops): Update.
2717 * nto-low.cc (nto_target_ops): Update.
2718 * win32-low.cc (win32_target_ops): Update.
2719
2720 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2721
2722 Turn process_stratum_target's handle_new_gdb_connection op into a
2723 method of process_target.
2724
2725 * target.h (struct process_stratum_target): Remove the target op.
2726 (class process_target): Add the target op.
2727 (target_handle_new_gdb_connection): Update the macro.
2728 * target.cc (process_target::handle_new_gdb_connection): Define.
2729
2730 Update the derived classes and callers below.
2731
2732 * linux-low.cc (linux_target_ops): Update.
2733 (linux_handle_new_gdb_connection): Turn into ...
2734 (linux_process_target::handle_new_gdb_connection): ... this.
2735 * linux-low.h (class linux_process_target): Update.
2736 * lynx-low.cc (lynx_target_ops): Update.
2737 * nto-low.cc (nto_target_ops): Update.
2738 * win32-low.cc (win32_target_ops): Update.
2739
2740 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2741
2742 Turn process_stratum_target's supports_fork_events,
2743 supports_vfork_events, and supports_exec_events ops into methods
2744 of process_target.
2745
2746 * target.h (struct process_stratum_target): Remove the target ops.
2747 (class process_target): Add the target ops.
2748 (target_supports_fork_events): Update the macro.
2749 (target_supports_vfork_events): Update the macro.
2750 (target_supports_exec_events): Update the macro.
2751 * target.cc (process_target::supports_fork_events): Define.
2752 (process_target::supports_vfork_events): Define.
2753 (process_target::supports_exec_events): Define.
2754
2755 Update the derived classes and callers below.
2756
2757 * linux-low.cc (linux_target_ops): Update.
2758 (linux_supports_fork_events): Turn into ...
2759 (linux_process_target::supports_fork_events): ... this.
2760 (linux_supports_vfork_events): Turn into ...
2761 (linux_process_target::supports_vfork_events): ... this.
2762 (linux_supports_exec_events): Turn into ...
2763 (linux_process_target::supports_exec_events): ... this.
2764 * linux-low.h (class linux_process_target): Update.
2765 * lynx-low.cc (lynx_target_ops): Update.
2766 * nto-low.cc (nto_target_ops): Update.
2767 * win32-low.cc (win32_target_ops): Update.
2768
2769 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2770
2771 Turn process_stratum_target's supports_multi_process op into a
2772 method of process_target.
2773
2774 * target.h (struct process_stratum_target): Remove the target op.
2775 (class process_target): Add the target op.
2776 * target.cc (process_target::supports_multi_process): Define.
2777 (target_supports_multi_process): Update.
2778
2779 Update the derived classes and callers below.
2780
2781 * linux-low.cc (linux_target_ops): Update.
2782 (linux_supports_multi_process): Turn into ...
2783 (linux_process_target::supports_multi_process): ... this.
2784 * linux-low.h (class linux_process_target): Update.
2785 * lynx-low.cc (lynx_target_ops): Update.
2786 * nto-low.cc (nto_target_ops): Update.
2787 * win32-low.cc (win32_target_ops): Update.
2788
2789 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2790
2791 Turn process_stratum_target's supports_non_stop, async, and
2792 start_non_stop ops into methods of process_target.
2793
2794 * target.h (struct process_stratum_target): Remove the target ops.
2795 (class process_target): Add the target ops.
2796 (target_supports_non_stop): Update the macro.
2797 (target_async): Update the macro.
2798 (start_non_stop): Remove declaration.
2799 * target.cc (process_target::supports_non_stop): Define.
2800 (process_target::async): Define.
2801 (process_target::start_non_stop): Define.
2802 (start_non_stop): Remove.
2803
2804 Update the derived classes and callers below.
2805
2806 * server.cc (handle_qxfer_siginfo): Update.
2807 (handle_query): Update.
2808 * linux-low.cc (linux_target_ops): Update.
2809 (linux_supports_non_stop): Turn into ...
2810 (linux_process_target::supports_non_stop): ... this.
2811 (linux_async): Turn into ...
2812 (linux_process_target::async): ... this.
2813 (linux_start_non_stop): Turn into ...
2814 (linux_process_target::start_non_stop): ... this.
2815 * linux-low.h (class linux_process_target): Update.
2816 * lynx-low.cc (lynx_target_ops): Update.
2817 * nto-low.cc (nto_target_ops): Update.
2818 (nto_supports_non_stop): Remove; rely on the default behavior
2819 instead.
2820 * win32-low.cc (win32_target_ops): Update.
2821
2822 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2823
2824 Turn process_stratum_target's qxfer_siginfo op into a method of
2825 process_target.
2826
2827 * target.h (struct process_stratum_target): Remove the target op.
2828 (class process_target): Add the target op. Also add
2829 'supports_qxfer_siginfo'.
2830 * target.cc (process_target::qxfer_siginfo): Define.
2831 (process_target::supports_qxfer_siginfo): Define.
2832
2833 Update the derived classes and callers below.
2834
2835 * server.cc (handle_qxfer_siginfo): Update.
2836 (handle_query): Update.
2837 * linux-low.cc (linux_target_ops): Update.
2838 (linux_process_target::supports_qxfer_siginfo): Define.
2839 (linux_xfer_siginfo): Turn into ...
2840 (linux_process_target::qxfer_siginfo): ... this.
2841 * linux-low.h (class linux_process_target): Update.
2842 * lynx-low.cc (lynx_target_ops): Update.
2843 * nto-low.cc (nto_target_ops): Update.
2844 * win32-low.cc (win32_target_ops): Update.
2845
2846 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2847
2848 Turn process_stratum_target's qxfer_osdata op into a method of
2849 process_target.
2850
2851 * target.h (struct process_stratum_target): Remove the target op.
2852 (class process_target): Add the target op. Also add
2853 'supports_qxfer_osdata'.
2854 * target.cc (process_target::qxfer_osdata): Define.
2855 (process_target::supports_qxfer_osdata): Define.
2856
2857 Update the derived classes and callers below.
2858
2859 * server.cc (handle_qxfer_osdata): Update.
2860 (handle_query): Update.
2861 * linux-low.cc (linux_target_ops): Update.
2862 (linux_process_target::supports_qxfer_osdata): Define.
2863 (linux_qxfer_osdata): Turn into ...
2864 (linux_process_target::qxfer_osdata): ... this.
2865 * linux-low.h (class linux_process_target): Update.
2866 * lynx-low.cc (lynx_target_ops): Update.
2867 * nto-low.cc (nto_target_ops): Update.
2868 * win32-low.cc (win32_target_ops): Update.
2869
2870 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2871
2872 Turn process_stratum_target's hostio_last_error op into a
2873 method of process_target.
2874
2875 * target.h (struct process_stratum_target): Remove the target op.
2876 (class process_target): Add the target op.
2877 * target.cc: Add "hostio.h" to includes.
2878 (process_target::hostio_last_error): Define.
2879
2880 Update the derived classes and callers below.
2881
2882 * hostio.cc (hostio_error): Update.
2883 * linux-low.cc: Remove "hostio.h" from includes.
2884 (linux_target_ops): Update.
2885 * lynx-low.cc (lynx_target_ops): Update.
2886 * nto-low.cc (nto_target_ops): Update.
2887 * win32-low.h (class win32_process_target): Update.
2888 * win32-low.cc (win32_target_ops): Update.
2889 (wince_hostio_last_error): Turn into ...
2890 (win32_process_target::hostio_last_error): ... this.
2891
2892 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2893
2894 Turn process_stratum_target's get_tls_address op into a method of
2895 process_target.
2896
2897 * target.h (struct process_stratum_target): Remove the target op.
2898 (class process_target): Add the target op. Also add
2899 'supports_get_tls_address'.
2900 * target.cc (process_target::get_tls_address): Define.
2901 (process_target::supports_get_tls_address): Define.
2902
2903 Update the derived classes and callers below.
2904
2905 * server.cc (handle_query): Update.
2906 * linux-low.cc (linux_target_ops): Update.
2907 (linux_process_target::supports_get_tls_address): Define.
2908 (linux_process_target::get_tls_address): Define.
2909 * linux-low.h (class linux_process_target): Update.
2910 * lynx-low.cc (lynx_target_ops): Update.
2911 * nto-low.cc (nto_target_ops): Update.
2912 * win32-low.cc (win32_target_ops): Update.
2913
2914 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2915
2916 Turn process_stratum_target's read_offsets op into a method of
2917 process_target.
2918
2919 * target.h (struct process_stratum_target): Remove the target op.
2920 (class process_target): Add the target op. Also add
2921 'supports_read_offsets'.
2922 * target.cc (process_target::read_offsets): Define.
2923 (process_target::supports_read_offsets): Define.
2924
2925 Update the derived classes and callers below.
2926
2927 * server.cc (handle_query): Update.
2928 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
2929 (linux_target_ops): Update.
2930 (linux_process_target::supports_read_offsets): Define.
2931 (linux_read_offsets): Turn into ...
2932 (linux_process_target::read_offsets): ... this.
2933 * linux-low.h (class linux_process_target): Update.
2934 * lynx-low.cc (lynx_target_ops): Update.
2935 * nto-low.cc (nto_target_ops): Update.
2936 * win32-low.cc (win32_target_ops): Update.
2937
2938 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2939
2940 Turn process_stratum_target's stopped_by_watchpoint and
2941 stopped_data_address ops into methods of process_target.
2942
2943 * target.h (struct process_stratum_target): Remove the target ops.
2944 (class process_target): Add the target ops.
2945 * target.cc (process_target::stopped_by_watchpoint): Define.
2946 (process_target::stopped_data_address): Define.
2947
2948 Update the derived classes and callers below.
2949
2950 * remote-utils.cc (prepare_resume_reply): Update.
2951 * linux-low.cc (linux_target_ops): Update.
2952 (linux_stopped_by_watchpoint): Turn into ...
2953 (linux_process_target::stopped_by_watchpoint): ... this.
2954 (linux_stopped_data_address): Turn into ...
2955 (linux_process_target::stopped_data_address): ... this.
2956 * linux-low.h (class linux_process_target): Update.
2957 * lynx-low.cc (lynx_target_ops): Update.
2958 * nto-low.cc (nto_target_ops): Update.
2959 (nto_stopped_by_watchpoint): Turn into ...
2960 (nto_process_target::stopped_by_watchpoint): ... this.
2961 (nto_stopped_data_address): Turn into ...
2962 (nto_process_target::stopped_data_address): ... this.
2963 * nto-low.h (class nto_process_target): Update.
2964 * win32-low.cc (win32_target_ops): Update.
2965 (win32_stopped_by_watchpoint): Turn into ...
2966 (win32_process_target::stopped_by_watchpoint): ... this.
2967 (win32_stopped_data_address): Turn into ...
2968 (win32_process_target::stopped_data_address): ... this.
2969 * win32-low.h (class win32_process_target): Update.
2970
2971 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2972
2973 Turn process_stratum_target's supports_hardware_single_step op into
2974 a method of process_target.
2975
2976 * target.h (struct process_stratum_target): Remove the target op.
2977 (class process_target): Add the target op.
2978 (target_supports_hardware_single_step): Update the macro.
2979 (target_can_do_hardware_single_step): Remove declaration.
2980 * target.cc (process_target::supports_hardware_single_step): Define.
2981 (target_can_do_hardware_single_step): Remove.
2982
2983 Update the derived classes and callers below.
2984
2985 * linux-low.h (class linux_process_target): Update.
2986 * linux-low.cc (linux_target_ops): Update.
2987 (linux_supports_hardware_single_step): Turn into ...
2988 (linux_process_target::supports_hardware_single_step): ... this.
2989 * lynx-low.h (class lynx_process_target): Update.
2990 * lynx-low.cc (lynx_target_ops): Update.
2991 (lynx_process_target::supports_hardware_single_step): Define.
2992 * nto-low.h (class nto_process_target): Update.
2993 * nto-low.cc (nto_target_ops): Update.
2994 (nto_process_target::supports_hardware_single_step): Define.
2995 * win32-low.h (class win32_process_target): Update.
2996 * win32-low.cc (win32_target_ops): Update.
2997 (win32_process_target::supports_hardware_single_step): Define.
2998
2999 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3000
3001 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3002 ops into methods of process_target.
3003
3004 * target.h (struct process_stratum_target): Remove the target ops.
3005 (class process_target): Add the target ops.
3006 (target_stopped_by_hw_breakpoint): Update the macro.
3007 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3008 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3009 (process_target::supports_stopped_by_hw_breakpoint): Define.
3010
3011 Update the derived classes and callers below.
3012
3013 * linux-low.cc (linux_target_ops): Update.
3014 (linux_stopped_by_hw_breakpoint): Turn into ...
3015 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3016 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3017 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3018 * linux-low.h (class linux_process_target): Update.
3019 * lynx-low.cc (lynx_target_ops): Update.
3020 * nto-low.cc (nto_target_ops): Update.
3021 * win32-low.cc (win32_target_ops): Update.
3022
3023 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3024
3025 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3026 ops into methods of process_target.
3027
3028 * target.h (struct process_stratum_target): Remove the target ops.
3029 (class process_target): Add the target ops.
3030 (target_stopped_by_sw_breakpoint): Update the macro.
3031 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3032 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3033 (process_target::supports_stopped_by_sw_breakpoint): Define.
3034
3035 Update the derived classes and callers below.
3036
3037 * linux-low.cc (linux_target_ops): Update.
3038 (linux_stopped_by_sw_breakpoint): Turn into ...
3039 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3040 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3041 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3042 * linux-low.h (class linux_process_target): Update.
3043 * lynx-low.cc (lynx_target_ops): Update.
3044 * nto-low.cc (nto_target_ops): Update.
3045 * win32-low.cc (win32_target_ops): Update.
3046
3047 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3048
3049 Turn process_stratum_target's insert_point and remove_point ops
3050 into methods of process_target.
3051
3052 * target.h (struct process_stratum_target): Remove the target ops.
3053 (class process_target): Add the target ops.
3054 * target.cc (process_target::insert_point): Define.
3055 (process_target::remove_point): Define.
3056
3057 Update the derived classes and callers below.
3058
3059 * mem-break.cc (set_raw_breakpoint_at): Update.
3060 (delete_raw_breakpoint): Update.
3061 (uninsert_raw_breakpoint): Update.
3062 (reinsert_raw_breakpoint): Update.
3063 * linux-low.cc (linux_target_ops): Update.
3064 (linux_insert_point): Turn into ...
3065 (linux_process_target::insert_point): ... this.
3066 (linux_remove_point): Turn into ...
3067 (linux_process_target::remove_point): ... this.
3068 * linux-low.h (class linux_process_target): Update.
3069 * lynx-low.cc (lynx_target_ops): Update.
3070 * nto-low.cc (nto_target_ops): Update.
3071 (nto_insert_point): Turn into ...
3072 (nto_process_target::insert_point): ... this.
3073 (nto_remove_point): Turn into ...
3074 (nto_process_target::remove_point): ... this.
3075 * nto-low.h (class nto_process_target): Update.
3076 * win32-low.cc (win32_target_ops): Update.
3077 (win32_insert_point): Turn into ...
3078 (win32_process_target::insert_point): ... this.
3079 (win32_remove_point): Turn into ...
3080 (win32_process_target::remove_point): ... this.
3081 * win32-low.h (class win32_process_target): Update.
3082
3083 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3084
3085 Turn process_stratum_target's supports_z_point_type op into a
3086 method of process_target.
3087
3088 * target.h (struct process_stratum_target): Remove the target op.
3089 (class process_target): Add the target op.
3090 * target.cc (process_target::supports_z_point_type): Define.
3091
3092 Update the derived classes and callers below.
3093
3094 * mem-break.cc (z_type_supported): Update.
3095 * linux-low.cc (linux_target_ops): Update.
3096 (linux_supports_z_point_type): Turn into ...
3097 (linux_process_target::supports_z_point_type): ... this.
3098 * linux-low.h (class linux_process_target): Update.
3099 * lynx-low.cc (lynx_target_ops): Update.
3100 * nto-low.cc (nto_target_ops): Update.
3101 (nto_supports_z_point_type): Turn into ...
3102 (nto_process_target::supports_z_point_type): ... this.
3103 * nto-low.h (class nto_process_target): Update.
3104 * win32-low.cc (win32_target_ops): Update.
3105 (win32_supports_z_point_type): Turn into ...
3106 (win32_process_target::supports_z_point_type): ... this.
3107 * win32-low.h (class win32_process_target): Update.
3108
3109 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3110
3111 Turn process_stratum_target's read_auxv op into a method of
3112 process_target.
3113
3114 * target.h (class process_stratum_target): Remove the target op.
3115 (struct process_target): Add the target op. Also add
3116 'supports_read_auxv'.
3117 * target.cc (process_target::read_auxv): Define.
3118 (process_target::supports_read_auxv): Define.
3119
3120 Update the derived classes and callers below.
3121
3122 * server.cc (handle_qxfer_auxv): Update.
3123 (handle_query): Update.
3124 * linux-low.cc (linux_target_ops): Update.
3125 (linux_process_target::supports_read_auxv): Define.
3126 (linux_read_auxv): Turn into ...
3127 (linux_process_target::read_auxv): ... this.
3128 * linux-low.h (class linux_process_target): Update.
3129 * lynx-low.cc (lynx_target_ops): Update.
3130 * nto-low.cc (nto_target_ops): Update.
3131 (nto_process_target::supports_read_auxv): Define.
3132 (nto_read_auxv): Turn into ...
3133 (nto_process_target::read_auxv): ... this.
3134 * nto-low.h (class nto_process_target): Update.
3135 * win32-low.cc (win32_target_ops): Update.
3136
3137 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3138
3139 Turn process_stratum_target's request_interrupt op into a method of
3140 process_target.
3141
3142 * target.h (struct process_stratum_target): Remove the target op.
3143 (class process_target): Add the target op.
3144
3145 Update the derived classes and callers below.
3146
3147 * remote-utils.cc (putpkt_binary_1): Update.
3148 (input_interrupt): Update.
3149 (getpkt): Update.
3150 * server.cc (handle_v_requests): Update.
3151 * linux-low.cc (linux_target_ops): Update.
3152 (linux_request_interrupt): Turn into ...
3153 (linux_process_target::request_interrupt): ... this.
3154 * linux-low.h (class linux_process_target): Update.
3155 * lynx-low.cc (lynx_target_ops): Update.
3156 (lynx_request_interrupt): Turn into ...
3157 (lynx_process_target::request_interrupt): ... this.
3158 * lynx-low.h (class lynx_process_target): Update.
3159 * nto-low.cc (nto_target_ops): Update.
3160 (nto_request_interrupt): Turn into ...
3161 (nto_process_target::request_interrupt): ... this.
3162 * nto-low.h (class nto_process_target): Update.
3163 * win32-low.cc (win32_target_ops): Update.
3164 (win32_request_interrupt): Turn into ...
3165 (win32_process_target::request_interrupt): ... this.
3166 * win32-low.h (class win32_process_target): Update.
3167
3168 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3169
3170 Turn process_stratum_target's look_up_symbols op into a method of
3171 process_target.
3172
3173 * target.h (struct process_stratum_target): Remove the target op.
3174 (class process_target): Add the target op.
3175 * target.cc (process_target::look_up_symbols): Define.
3176
3177 Update the derived classes and callers below.
3178
3179 * server.cc (handle_query): Update.
3180 * linux-low.cc (linux_target_ops): Update.
3181 (linux_look_up_symbols): Turn into ...
3182 (linux_process_target::look_up_symbols): ... this.
3183 * linux-low.h (class linux_process_target): Update.
3184 * lynx-low.cc (lynx_target_ops): Update.
3185 * nto-low.cc (nto_target_ops): Update.
3186 * win32-low.cc (win32_target_ops): Update.
3187
3188 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3189
3190 Turn process_stratum_target's read_memory and write_memory
3191 ops into methods of process_target.
3192
3193 * target.h (struct process_stratum_target): Remove the target ops.
3194 (class process_target): Add the target ops.
3195
3196 Update the derived classes and callers below.
3197
3198 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3199 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3200 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3201 (arm_get_syscall_trapinfo): Update.
3202 * linux-cris-low.cc (cris_breakpoint_at): Update.
3203 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3204 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3205 * linux-mips-low.cc (mips_breakpoint_at): Update.
3206 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3207 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3208 * linux-sh-low.cc (sh_breakpoint_at): Update.
3209 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3210 (sparc_store_gregset_from_stack): Update.
3211 (sparc_breakpoint_at): Update.
3212 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3213 * linux-tile-low.cc (tile_breakpoint_at): Update.
3214 * linux-x86-low.cc (x86_breakpoint_at): Update.
3215 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3216 * mem-brea.cc (insert_memory_breakpoint): Update.
3217 (validate_inserted_breakpoint): Update.
3218 * target.cc (read_inferior_memory): Update.
3219 (target_write_memory): Update.
3220 * linux-low.cc (linux_target_ops): Update.
3221 (linux_read_memory): Make a wrapper around the read_memory target
3222 op call.
3223 (linux_process_target::read_memory): Rename from linux_read_memory.
3224 (linux_write_memory): Turn into ...
3225 (linux_process_target::write_memory): ... this.
3226 * linux-low.h (class linux_process_target): Update.
3227 * lynx-low.cc (lynx_target_ops): Update.
3228 (lynx_read_memory): Turn into ...
3229 (lynx_process_target::read_memory): ... this.
3230 (lynx_write_memory): Turn into ...
3231 (lynx_process_target::write_memory): ... this.
3232 * lynx-low.h (class lynx_process_target): Update.
3233 * nto-low.cc (nto_target_ops): Update.
3234 (nto_read_memory): Turn into ...
3235 (nto_process_target::read_memory): ... this.
3236 (nto_write_memory): Turn into ...
3237 (nto_process_target::write_memory): ... this.
3238 * nto-low.h (class nto_process_target): Update.
3239 * win32-low.cc (win32_target_ops): Update.
3240 (win32_read_inferior_memory): Turn into ...
3241 (win32_process_target::read_memory): ... this.
3242 (win32_write_inferior_memory): Turn into ...
3243 (win32_process_target::write_memory): ... this.
3244 * win32-low.h (class win32_process_target): Update.
3245
3246 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3247
3248 Turn process_stratum_target's prepare_to_access_memory and
3249 done_accessing_memory ops into methods of process_target.
3250
3251 * target.h (struct process_stratum_target): Remove the target ops.
3252 (class process_target): Add the target ops.
3253 * target.cc (process_target::prepare_to_access_memory): Define.
3254 (process_target::done_accessing_memory): Define.
3255 (prepare_to_access_memory): Update.
3256 (done_accessing_memory): Update.
3257
3258 Update the derived classes and callers below.
3259
3260 * linux-low.cc (linux_target_ops): Update.
3261 (linux_prepare_to_access_memory): Turn into ...
3262 (linux_process_target::prepare_to_access_memory): ... this.
3263 (linux_done_accessing_memory): Turn into ...
3264 (linux_process_target::done_accessing_memory): ... this.
3265 * linux-low.h (class linux_process_target): Update.
3266 * lynx-low.cc (lynx_target_ops): Update.
3267 * nto-low.cc (nto_target_ops): Update.
3268 * win32-low.cc (win32_target_ops): Update.
3269
3270 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3271
3272 Turn process_stratum_target's fetch_registers and store_registers
3273 ops into methods of process_target.
3274
3275 * target.h (struct process_stratum_target): Remove the target ops.
3276 (class process_target): Add the target ops.
3277 (fetch_inferior_registers): Update the macro.
3278 (store_inferior_registers): Update the macro.
3279
3280 Update the derived classes and callers below.
3281
3282 * linux-low.cc (linux_target_ops): Update.
3283 (linux_fetch_registers): Turn into ...
3284 (linux_process_target::fetch_registers): ... this.
3285 (linux_store_registers): Turn into ...
3286 (linux_process_target::store_registers): ... this.
3287 * linux-low.h (class linux_process_target): Update.
3288 * lynx-low.cc (lynx_target_ops): Update.
3289 (lynx_fetch_registers): Turn into ...
3290 (lynx_process_target::fetch_registers): ... this.
3291 (lynx_store_registers): Turn into ...
3292 (lynx_process_target::store_registers): ... this.
3293 * lynx-low.h (class lynx_process_target): Update.
3294 * nto-low.cc (nto_target_ops): Update.
3295 (nto_fetch_registers): Turn into ...
3296 (nto_process_target::fetch_registers): ... this.
3297 (nto_store_registers): Turn into ...
3298 (nto_process_target::store_registers): ... this.
3299 * nto-low.h (class nto_process_target): Update.
3300 * win32-low.cc (win32_target_ops): Update.
3301 (win32_fetch_inferior_registers): Turn into ...
3302 (win32_process_target::fetch_registers): ... this.
3303 (win32_store_inferior_registers): Turn into ...
3304 (win32_process_target::store_registers): ... this.
3305 * win32-low.h (class win32_process_target): Update.
3306
3307 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3308
3309 Turn process_stratum_target's wait op into a method of
3310 process_target.
3311
3312 * target.h (struct process_stratum_target): Remove the target op.
3313 (class process_target): Add the target op.
3314
3315 Update the derived classes and callers below.
3316
3317 * target.cc (target_wait): Update.
3318 * linux-low.cc (linux_target_ops): Update.
3319 (linux_wait): Turn into ...
3320 (linux_process_target::wait): ... this.
3321 * linux-low.h (class linux_process_target): Update.
3322 * lynx-low.cc (lynx_target_ops): Update.
3323 (lynx_wait): Turn into ...
3324 (lynx_process_target::wait): ... this.
3325 * lynx-low.h (class lynx_process_target): Update.
3326 * nto-low.cc (nto_target_ops): Update.
3327 (nto_wait): Turn into ...
3328 (nto_process_target::wait): ... this.
3329 * nto-low.h (class nto_process_target): Update.
3330 * win32-low.cc (win32_target_ops): Update.
3331 (win32_wait): Turn into ...
3332 (win32_process_target::wait): ... this.
3333 (do_initial_child_stuff): Update.
3334 * win32-low.h (class win32_process_target): Update.
3335
3336 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3337
3338 Turn process_stratum_target's resume op into a method of
3339 process_target.
3340
3341 * target.h (struct process_stratum_target): Remove the target op.
3342 (class process_target): Add the target op.
3343
3344 Update the derived classes and callers below.
3345
3346 * server.cc (resume): Update.
3347 * target.cc (target_stop_and_wait): Update.
3348 (target_continue_no_signal): Update.
3349 (target_continue): Update.
3350 * linux-low.cc (linux_target_ops): Update.
3351 (linux_resume): Turn into ...
3352 (linux_process_target::resume): ... this.
3353 * linux-low.h (class linux_process_target): Update.
3354 * lynx-low.cc (lynx_target_ops): Update.
3355 (lynx_resume): Turn into ...
3356 (lynx_process_target::resume): ... this.
3357 * lynx-low.h (class lynx_process_target): Update.
3358 * nto-low.cc (nto_target_ops): Update.
3359 (nto_resume): Turn into ...
3360 (nto_process_target::resume): ... this.
3361 * nto-low.h (class nto_process_target): Update.
3362 * win32-low.cc (win32_target_ops): Update.
3363 (win32_resume): Turn into ...
3364 (win32_process_target::resume): ... this.
3365 (win32_process_target::detach): Update.
3366 (do_initial_child_stuff): Update.
3367 * win32-low.h (class win32_process_target): Update.
3368
3369 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3370
3371 Turn process_stratum_target's thread_alive op into a method of
3372 process_target.
3373
3374 * target.h (struct process_stratum_target): Remove the target op.
3375 (class process_target): Add the target op.
3376 (mythread_alive): Update the macro.
3377
3378 Update the derived classes and callers below.
3379
3380 * linux-low.cc (linux_target_ops): Update.
3381 (linux_thread_alive): Turn into ...
3382 (linux_process_target::thread_alive): ... this.
3383 (wait_for_sigstop): Update.
3384 * linux-low.h (class linux_process_target): Update.
3385 * lynx-low.cc (lynx_target_ops): Update.
3386 (lynx_thread_alive): Turn into ...
3387 (lynx_process_target::thread_alive): ... this.
3388 * lynx-low.h (class lynx_process_target): Update.
3389 * nto-low.cc (nto_target_ops): Update.
3390 (nto_thread_alive): Turn into ...
3391 (nto_process_target::thread_alive): ... this.
3392 * nto-low.h (class nto_process_target): Update.
3393 * win32-low.cc (win32_target_ops): Update.
3394 (win32_thread_alive): Turn into ...
3395 (win32_process_target::thread_alive): ... this.
3396 * win32-low.h (class win32_process_target): Update.
3397
3398 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3399
3400 Turn process_stratum_target's join op into a method of
3401 process_target.
3402
3403 * target.h (struct process_stratum_target): Remove the target op.
3404 (class process_target): Add the target op.
3405 (join_inferior): Update the macro.
3406
3407 Update the derived classes and callers below.
3408
3409 * linux-low.cc (linux_target_ops): Update.
3410 (linux_join): Turn into ...
3411 (linux_process_target::join): ... this.
3412 * linux-low.h (class linux_process_target): Update.
3413 * lynx-low.cc (lynx_target_ops): Update.
3414 (lynx_join): Turn into ...
3415 (lynx_process_target::join): ... this.
3416 * lynx-low.h (class lynx_process_target): Update.
3417 * nto-low.cc (nto_target_ops): Update.
3418 (nto_process_target::join): Define.
3419 * nto-low.h (class nto_process_target): Update.
3420 * win32-low.cc (win32_target_ops): Update.
3421 (win32_join): Turn into ...
3422 (win32_process_target::join): ... this.
3423 * win32-low.h (class win32_process_target): Update.
3424
3425 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3426
3427 Turn process_stratum_target's mourn op into a method of
3428 process_target.
3429
3430 * target.h (struct process_stratum_target): Remove the target op.
3431 (class process_target): Add the target op.
3432
3433 Update the derived classes and callers below.
3434
3435 * target.cc (target_mourn_inferior): Update.
3436 * linux-low.cc (linux_target_ops): Update.
3437 (linux_mourn): Turn into ...
3438 (linux_process_target::mourn): ... this.
3439 (handle_extended_wait): Update.
3440 (linux_process_target::kill): Update.
3441 (linux_process_target::detach): Update.
3442 * linux-low.h (class linux_process_target): Update.
3443 * lynx-low.cc (lynx_target_ops): Update.
3444 (lynx_mourn): Turn into ...
3445 (lynx_process_target::mourn): ... this.
3446 * lynx-low.h (class lynx_process_target): Update.
3447 * nto-low.cc (nto_target_ops): Update.
3448 (nto_mourn): Turn into ...
3449 (nto_process_target::mourn): ... this.
3450 * nto-low.h (class nto_process_target): Update.
3451 * win32-low.cc (win32_target_ops): Update.
3452 (win32_mourn): Turn into ...
3453 (win32_process_target::mourn): ... this.
3454 * win32-low.h (class win32_process_target): Update.
3455
3456 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3457
3458 Turn process_stratum_target's detach op into a method of
3459 process_target.
3460
3461 * target.h (struct process_stratum_target): Remove the target op.
3462 (class process_target): Add the target op.
3463 (detach_inferior): Update the macro.
3464
3465 Update the derived classes and callers below.
3466
3467 * linux-low.cc (linux_target_ops): Update.
3468 (linux_detach): Turn into ...
3469 (linux_process_target::detach): ... this.
3470 * linux-low.h (class linux_process_target): Update.
3471 * lynx-low.cc (lynx_target_ops): Update.
3472 (lynx_detach): Turn into ...
3473 (lynx_process_target::detach): ... this.
3474 * lynx-low.h (class lynx_process_target): Update.
3475 * nto-low.cc (nto_target_ops): Update.
3476 (nto_detach): Turn into ...
3477 (nto_process_target::detach): ... this.
3478 * nto-low.h (class nto_process_target): Update.
3479 * win32-low.cc (win32_target_ops): Update.
3480 (win32_detach): Turn into ...
3481 (win32_process_target::detach): ... this.
3482 * win32-low.h (class win32_process_target): Update.
3483
3484 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3485
3486 Turn process_stratum_target's kill op into a method of
3487 process_target.
3488
3489 * target.h (struct process_stratum_target): Remove the target op.
3490 (class process_target): Add the target op.
3491
3492 Update the derived classes and callers below.
3493
3494 * target.cc (kill_inferior): Update.
3495 * linux-low.cc (linux_target_ops): Update.
3496 (linux_kill): Turn into ...
3497 (linux_process_target::kill): ... this.
3498 * linux-low.h (class linux_process_target): Update.
3499 * lynx-low.cc (lynx_target_ops): Update.
3500 (lynx_kill): Turn into ...
3501 (lynx_process_target::kill): ... this.
3502 * lynx-low.h (class lynx_process_target): Update.
3503 * nto-low.cc (nto_target_ops): Update.
3504 (nto_kill): Turn into ...
3505 (nto_process_target::kill): ... this.
3506 * nto-low.h (class nto_process_target): Update.
3507 * win32-low.cc (win32_target_ops): Update.
3508 (win32_kill): Turn into ...
3509 (win32_process_target::kill): ... this.
3510 * win32-low.h (class win32_process_target): Update.
3511
3512 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3513
3514 Turn process_stratum_target's attach op into a method of
3515 process_target.
3516
3517 * target.h (struct process_stratum_target): Remove the target op.
3518 (class process_target): Add the target op.
3519 (myattach): Update the macro.
3520
3521 Update the derived classes and callers below.
3522
3523 * linux-low.cc (linux_target_ops): Update.
3524 (linux_attach): Turn into ...
3525 (linux_process_target::attach): ... this.
3526 * linux-low.h (class linux_process_target): Update.
3527 * lynx-low.cc (lynx_target_ops): Update.
3528 (lynx_attach): Turn into ...
3529 (lynx_process_target::attach): ... this.
3530 * lynx-low.h (class lynx_process_target): Update.
3531 * nto-low.cc (nto_target_ops): Update.
3532 (nto_attach): Turn into ...
3533 (nto_process_target::attach): ... this.
3534 * nto-low.h (class nto_process_target): Update.
3535 * win32-low.cc (win32_target_ops): Update.
3536 (win32_attach): Turn into ...
3537 (win32_process_target::attach): ... this.
3538 * win32-low.h (class win32_process_target): Update.
3539
3540 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3541
3542 Turn process_stratum_target's post_create_inferior op into a method
3543 of process_target.
3544
3545 * target.h (struct process_stratum_target): Remove the target op.
3546 (class process_target): Add the target op.
3547 (target_post_create_inferior): Update the macro.
3548 * target.cc (process_target::post_create_inferior): Define.
3549
3550 Update the derived classes and callers below.
3551
3552 * linux-low.cc (linux_target_ops): Update.
3553 (linux_post_create_inferior): Turn into ...
3554 (linux_process_target::post_create_inferior): ... this.
3555 * linux-low.h (class linux_process_target): Update.
3556 * lynx-low.cc (lynx_target_ops): Update.
3557 * nto-low.cc (nto_target_ops): Update.
3558 * win32-low.cc (win32_target_ops): Update.
3559
3560 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3561
3562 Turn process_stratum_target's create_inferior op into a method of
3563 process_target.
3564
3565 * target.h (struct process_stratum_target): Remove the target op.
3566 (class process_target): Add the target op.
3567 (create_inferior): Rename the macro to ...
3568 (target_create_inferior): ... this.
3569
3570 Update the derived classes and callers below.
3571
3572 * server.cc (handle_v_run): Update.
3573 (captured_main): Update.
3574 (process_serial_event): Update.
3575 * linux-low.cc (linux_target_ops): Update.
3576 (linux_create_inferior): Turn into ...
3577 (linux_process_target::create_inferior): ... this.
3578 * linux-low.h (class linux_process_target): Update.
3579 * lynx-low.cc (lynx_target_ops): Update.
3580 (lynx_create_inferior): Turn into ...
3581 (lynx_process_target::create_inferior): ... this.
3582 * lynx-low.h (class lynx_process_target): Update.
3583 * nto-low.cc (nto_target_ops): Update.
3584 (nto_create_inferior): Turn into ...
3585 (nto_process_target::create_inferior): ... this.
3586 * nto-low.h (class nto_process_target): Update.
3587 * win32-low.cc (win32_target_ops): Update.
3588 (win32_create_inferior): Turn into ...
3589 (win32_process_target::create_inferior): ... this.
3590 * win32-low.h (class win32_process_target): Update.
3591
3592 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3593
3594 * target.h (class process_target): New class definition.
3595 (struct process_stratum_target) <pt>: New field with type
3596 'process_target*'.
3597 * linux-low.h (class linux_process_target): Define as a derived
3598 class of 'process_target'.
3599 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3600 as the 'pt' field.
3601 * lynx-low.h (class lynx_process_target): Define as a derived
3602 class of 'process_target'.
3603 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3604 as the 'pt' field.
3605 * nto-low.h (class nto_process_target): Define as a derived
3606 class of 'process_target'.
3607 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3608 as the 'pt' field.
3609 * win32-low.h (class win32_process_target): Define as a derived
3610 class of 'process_target'.
3611 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3612 as the 'pt' field.
3613
3614 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3615
3616 * configure: Regenerate.
3617
3618 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
3619 Andrew Burgess <andrew.burgess@embecosm.com>
3620
3621 * linux-riscv-low.cc: New file.
3622 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3623 and nat/riscv-linux-tdesc.c.
3624 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3625 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3626 Define.
3627
3628 2020-02-14 Tom Tromey <tom@tromey.com>
3629
3630 * acinclude.m4: Don't include acx_configure_dir.m4.
3631 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3632 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3633 (all, install-only, uninstall, clean-info, clean)
3634 (maintainer-clean): Don't recurse.
3635 (subdir_do, all-lib): Remove.
3636 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3637 (GNULIB_H): Remove.
3638 (generated_files): Update.
3639 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3640 * configure: Rebuild.
3641 * configure.ac: Don't configure gnulib or libiberty.
3642 (GNULIB): Update.
3643
3644 2020-02-14 Eli Zaretskii <eliz@gnu.org>
3645
3646 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3647 preparing the command line for CreateProcess.
3648 (win32_create_inferior): Reflect the program name in debugging
3649 output that shows the process and its command line.
3650
3651 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3652
3653 * Makefile.in: Rename source files from .c to .cc.
3654 * %.c: Rename to %.cc.
3655 * configure.ac: Rename server.c to server.cc.
3656 * configure: Re-generate.
3657
3658 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3659
3660 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3661
3662 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
3663
3664 * win32-low.c (win32_create_inferior): Set signal_pid.
3665
3666 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
3667 Pedro Alves <palves@redhat.com>
3668
3669 Skip building gdbserver in a cross-configuration.
3670 * configure.srv: Set $gdbserver_host depending on whether $target
3671 is $host. Use $gdbserver_host instead of $host.
3672
3673 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3674
3675 * configure: Re-generate.
3676
3677 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3678
3679 * configure: Re-generate.
3680
3681 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3682
3683 * acinclude.m4: Update warning.m4 path.
3684
3685 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3686
3687 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3688 (handle_exception): Set siginfo_er.
3689 (win32_xfer_siginfo): New function.
3690
3691 2020-02-07 Tom Tromey <tom@tromey.com>
3692 Pedro Alves <palves@redhat.com>
3693
3694 * README: Update build documentation.
3695 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
3696 host, not target.
3697 * configure.ac: Update paths.
3698 * configure: Rebuild.
3699 * acinclude.m4: Update paths.
3700 * Makefile.in: Update include paths.
3701 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
3702 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
3703 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
3704 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
3705 (%-generated.c): Update paths.
3706 * Move entire directory from ../gdb/gdbserver.
3707
3708 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
3709
3710 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
3711
3712 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3713
3714 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
3715 assignment instead of srv_linux_obj.
3716
3717 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
3718
3719 * server.c (handle_qxfer_libraries): Write segment-address with
3720 paddress.
3721
3722 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
3723
3724 * Makefile.in (install-strip): New target.
3725 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
3726 * aclocal.m4: Regenerate.
3727 * configure: Regenerate.
3728 * configure.ac: Add AM_PROG_INSTALL_STRIP.
3729
3730 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
3731
3732 * Makefile.in (SFILES): Adjust paths to point to real files.
3733 (OBS): Move waitstatus.o to target/waitstatus.o.
3734 (TAGS): Transform paths appropriately.
3735 (%.o): Rename to...
3736 (nat/%.o): ... this pattern rule.
3737 (%.o): Rename to...
3738 (target/%.o): ... this pattern rule.
3739 * configure.srv: Adjust paths throughout to include nat/ prefix
3740 with the revant files.
3741 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
3742 * configure: Regenerate.
3743
3744 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
3745
3746 * Makefile.in (TAGS): Remove config files from the recipe.
3747
3748 2020-01-14 Tom Tromey <tom@tromey.com>
3749
3750 * configure: Rebuild.
3751 * configure.ac: Remove any checks that were added to common.m4.
3752 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
3753 lib-link.m4.
3754
3755 2020-01-14 Tom Tromey <tom@tromey.com>
3756
3757 * server.h: Include config.h.
3758 * gdbreplay.c: Include config.h.
3759 * configure: Rebuild.
3760 * configure.ac: Don't source common.host.
3761 * acinclude.m4: Update path.
3762 * Makefile.in (INCSUPPORT): New variable.
3763 (INCLUDE_CFLAGS): Add INCSUPPORT.
3764 (SFILES): Update paths.
3765 (version-generated.c): Update path to create-version.sh.
3766 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
3767
3768 2020-01-14 Tom Tromey <tom@tromey.com>
3769
3770 * configure.ac (LIBS): Use WIN32APILIBS.
3771 (USE_WIN32API): Don't define.
3772 * configure: Rebuild.
3773
3774 2020-01-14 Tom Tromey <tom@tromey.com>
3775
3776 * configure: Rebuild.
3777
3778 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3779
3780 * Makefile.in (%-generated.c): Remove rule for files from
3781 regformats/i386.
3782
3783 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3784
3785 * configure: Re-generate.
3786
3787 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3788
3789 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
3790 Define to static.
3791 * tracepoint.c (stop_tracing, flush_trace_buffer,
3792 about_to_request_buffer_space, get_trace_state_variable_value,
3793 set_trace_state_variable_value, gdb_collect): Add declaration.
3794
3795 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3796
3797 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
3798 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
3799 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
3800 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
3801 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
3802 static.
3803
3804 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3805
3806 * inferiors.c: Include gdbsupport/common-inferior.h.
3807
3808 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3809
3810 * hostio-errno.c: Include hostio.h.
3811
3812 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
3813
3814 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
3815 prerequisite.
3816
3817 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3818
3819 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
3820 * linux-arm-tdesc.h: Include arch/arm.h.
3821
3822 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3823
3824 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
3825
3826 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3827
3828 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
3829 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
3830
3831 2020-01-10 Pedro Alves <palves@redhat.com>
3832
3833 * fork-child.c (post_fork_inferior): Pass target down to
3834 startup_inferior.
3835 * inferiors.c (switch_to_thread): Add process_stratum_target
3836 parameter.
3837 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
3838 * nto-low.c (nto_target_ops): Now a process_stratum_target.
3839 * linux-low.c (linux_target_ops): Now a process_stratum_target.
3840 * remote-utils.c (prepare_resume_reply): Pass the target to
3841 switch_to_thread.
3842 * target.c (the_target): Now a process_stratum_target.
3843 (done_accessing_memory): Pass the target to switch_to_thread.
3844 (set_target_ops): Ajust to use process_stratum_target.
3845 * target.h (struct target_ops): Rename to ...
3846 (struct process_stratum_target): ... this.
3847 (the_target, set_target_ops): Adjust.
3848 (prepare_to_access_memory): Adjust comment.
3849 * win32-low.c (child_xfer_memory): Adjust to use
3850 process_stratum_target.
3851 (win32_target_ops): Now a process_stratum_target.
3852
3853 2020-01-06 Eli Zaretskii <eliz@gnu.org>
3854 Pedro Alves <palves@redhat.com>
3855
3856 * win32-low.c (get_child_debug_event): Extract the fatal exception
3857 from the exit status and convert to the equivalent Posix signal
3858 number.
3859 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
3860 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
3861
3862 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
3863
3864 * Makefile.in: Use INSTALL_PROGRAM_ENV.
3865
3866 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3867
3868 * server.c (gdbserver_version): Change copyright year to 2020.
3869 * gdbreplay.c (gdbreplay_version): Likewise.
3870
3871 2019-12-19 Christian Biesinger <cbiesinger@google.com>
3872
3873 * configure: Regenerate.
3874 * configure.ac: Quote variable arguments of test.
3875
3876 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
3877
3878 * Makefile.in: Fix build with GNU Make 3.81
3879
3880 2019-12-16 Tom Tromey <tromey@adacore.com>
3881
3882 * server.c (get_exec_file): Constify result.
3883
3884 2019-12-10 Christian Biesinger <cbiesinger@google.com>
3885
3886 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
3887 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
3888 * config.in: Regenerate.
3889 * configure: Regenerate.
3890 * configure.ac: Don't check for strerror.
3891 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
3892 Call safe_strerror instead of strerror.
3893 * server.h (strerror): Remove this now-unnecessary declaration.
3894 * tracepoint.c (init_named_socket): Call safe_strerror instead of
3895 strerror.
3896 (gdb_agent_helper_thread): Likewise.
3897 * utils.c (perror_with_name): Likewise.
3898
3899 2019-11-26 Tom Tromey <tom@tromey.com>
3900
3901 * configure, config.in: Rebuild.
3902
3903 2019-11-26 Tom Tromey <tom@tromey.com>
3904
3905 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
3906 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
3907 gdb_sigmask.
3908 * configure, config.in: Rebuild.
3909
3910 2019-11-26 Tom Tromey <tom@tromey.com>
3911
3912 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
3913 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
3914 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
3915 * acinclude.m4: Include ax_pthread.m4.
3916 * config.in, configure: Rebuild.
3917
3918 2019-11-26 Christian Biesinger <cbiesinger@google.com>
3919
3920 * debug.c (debug_set_output): Call safe_strerror instead of
3921 strerror.
3922 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
3923 (linux_kill_one_lwp): Likewise.
3924 (linux_detach_one_lwp): Likewise.
3925 (linux_wait_for_event_filtered): Likewise.
3926 (store_register): Likewise.
3927 * lynx-low.c (lynx_attach): Likewise.
3928 * mem-break.c (insert_memory_breakpoint): Likewise.
3929 (remove_memory_breakpoint): Likewise.
3930 (delete_fast_tracepoint_jump): Likewise.
3931 (set_fast_tracepoint_jump): Likewise.
3932 (uninsert_fast_tracepoint_jumps_at): Likewise.
3933 (reinsert_fast_tracepoint_jumps_at): Likewise.
3934 * nto-low.c (nto_xfer_memory): Likewise.
3935 (nto_resume): Likewise.
3936
3937 2019-11-20 Luis Machado <luis.machado@linaro.org>
3938
3939 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
3940 instead of register count.
3941 * tdesc.c (tdesc_contains_feature): New function.
3942 * tdesc.h (tdesc_contains_feature): New prototype.
3943
3944 2019-11-15 Christian Biesinger <cbiesinger@google.com>
3945
3946 * Makefile.in: Add safe-strerror.c.
3947 * configure: Regenerate.
3948 * configure.ac: Don't source common.host.
3949
3950 2019-11-15 Christian Biesinger <cbiesinger@google.com>
3951
3952 * config.in: Regenerate.
3953 * configure: Regenerate.
3954
3955 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
3956
3957 * ax.c (ax_printf): Handle size_t_arg.
3958
3959 2019-11-06 Christian Biesinger <cbiesinger@google.com>
3960
3961 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
3962 * mi/mi-main.c (output_cores): Likewise.
3963 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
3964 (linux_xfer_osdata_modules): Likewise.
3965 * remote.c (register_remote_support_xml): Likewise.
3966 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
3967 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
3968
3969 2019-11-01 Christian Biesinger <cbiesinger@google.com>
3970
3971 * configure: Regenerate.
3972 * configure.ac: Remove check for strerror_r.
3973
3974 2019-10-31 Christian Biesinger <cbiesinger@google.com>
3975
3976 * config.in: Regenerate.
3977 * configure: Regenerate.
3978 * configure.ac: Also check for strerror_r.
3979
3980 2019-10-31 Christian Biesinger <cbiesinger@google.com>
3981
3982 * ax.h (debug_agent): Remove duplicate declaration.
3983
3984 2019-10-26 Tom de Vries <tdevries@suse.de>
3985
3986 * linux-aarch64-low.c: Fix typos in comments.
3987 * linux-arm-low.c: Same.
3988 * linux-low.c: Same.
3989 * linux-ppc-low.c: Same.
3990 * proc-service.c: Same.
3991 * regcache.h: Same.
3992 * server.c: Same.
3993 * tracepoint.c: Same.
3994 * win32-low.c: Same.
3995
3996 2019-10-25 Tom Tromey <tromey@adacore.com>
3997
3998 * utils.c (xstrdup): Remove.
3999
4000 2019-10-23 Tom Tromey <tom@tromey.com>
4001
4002 * configure, config.in: Rebuild.
4003
4004 2019-10-23 Tom Tromey <tom@tromey.com>
4005
4006 * configure: Rebuild.
4007 * acinclude.m4: Use m4_include, not sinclude.
4008
4009 2019-10-17 Tom Tromey <tromey@adacore.com>
4010
4011 * configure: Rebuild.
4012 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4013 in AC_CONFIG_FILES invocation.
4014 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4015 invocation.
4016
4017 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4018
4019 * server.c: Include xml-builtin.h.
4020 (get_xml_features): Don't declare xml_builtins here.
4021
4022 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4023
4024 * Makefile.in: Remove references to vec-ipa.o.
4025
4026 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4027
4028 * Makefile.in: Remove references to vec.c.
4029
4030 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4031
4032 * server.c (server_waiting): Change to bool.
4033 (extended_protocol): Likewise.
4034 (response_needed): Likewise.
4035 (exit_requested): Likewise.
4036 (run_once): Likewise.
4037 (report_no_resumed): Likewise.
4038 (non_stop): Likewise.
4039 (disable_packet_vCont): Likewise.
4040 (disable_packet_Tthread): Likewise.
4041 (disable_packet_qC): Likewise.
4042 (disable_packet_qfThreadInfo): Likewise.
4043 (handle_general_set): Update.
4044 (handle_detach): Update.
4045 (handle_monitor_command): Update.
4046 (handle_query): Update.
4047 (captured_main): Update.
4048 (process_serial_event): Update.
4049 * server.h (server_waiting): Change to bool.
4050 (disable_packet_vCont): Likewise.
4051 (disable_packet_Tthread): Likewise.
4052 (disable_packet_qC): Likewise.
4053 (disable_packet_qfThreadInfo): Likewise.
4054 (run_once): Likewise.
4055 (non_stop): Likewise.
4056 * target.c (target_stop_and_wait): Update.
4057
4058 2019-10-02 Tom Tromey <tromey@adacore.com>
4059
4060 * Makefile.in (SFILES): Add common-inferior.c.
4061 (OBS): Add common-inferior.o.
4062 * server.c (startup_with_shell): Don't define.
4063
4064 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4065
4066 * linux-low.c (linux_low_read_btrace): Update for change to
4067 std::vector.
4068
4069 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4070
4071 * debug.c (debug_threads): Remove comment in favor of the header.
4072 * debug.h (using_threads): Add declaration.
4073 (debug_threads): Add comment.
4074 * linux-aarch64-low.c: Include debug.h and remove declaration of
4075 debug_threads.
4076 * nto-low.c: Likewise.
4077 * remote-utils.c: Likewise.
4078 * thread-db.c: Likewise.
4079
4080 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4081
4082 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4083 and powerpc-cell64l-ipa.o.
4084 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4085 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4086 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4087 (spu*-*-*): Remove.
4088
4089 * spu-low.c: Remove file.
4090
4091 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4092 (parse_spufs_run): Remove.
4093 (ppc_get_pc): Remove Cell/B.E. support.
4094 (ppc_set_pc): Likewise.
4095 (ppc_breakpoint_at): Likewise.
4096 (ppc_arch_setup): Likewise.
4097 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4098 tdesc_powerpc_cell32l.
4099 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4100 or init_registers_powerpc_cell32l.
4101 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4102 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4103 or init_registers_powerpc_cell32l.
4104 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4105 (init_registers_powerpc_cell32l): Remove prototype.
4106 (init_registers_powerpc_cell64l): Likewise.
4107
4108 * target.h (struct target_ops): Remove qxfer_spu member.
4109 * server.c (handle_qxfer_spu): Remove.
4110 (qxfer_packets): Remove entry for "spu".
4111 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4112 * linux-low.c (SPUFS_MAGIC): Remove.
4113 (spu_enumerate_spu_ids): Remove.
4114 (linux_qxfer_spu): Remove.
4115 (linux_target_ops): Remove qxfer_spu member.
4116 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4117 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4118 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4119
4120 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4121
4122 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4123 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4124 * config.in: Regenerate.
4125 * configure: Regenerate.
4126
4127 2019-08-15 Tom Tromey <tromey@adacore.com>
4128
4129 * target.c (target_write_memory): Use gdb::byte_vector.
4130
4131 2019-08-15 Tom Tromey <tromey@adacore.com>
4132
4133 * tracepoint.c (write_inferior_data_pointer)
4134 (write_inferior_integer, write_inferior_int8)
4135 (write_inferior_uinteger, m_tracepoint_action_download)
4136 (r_tracepoint_action_download, x_tracepoint_action_download)
4137 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4138 (download_agent_expr, download_tracepoint_1)
4139 (download_trace_state_variables, upload_fast_traceframes): Update.
4140 * server.c (gdb_write_memory): Update.
4141 * remote-utils.c (relocate_instruction): Update.
4142 * proc-service.c (ps_pdwrite): Update.
4143 * mem-break.c (remove_memory_breakpoint)
4144 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4145 (uninsert_fast_tracepoint_jumps_at)
4146 (reinsert_fast_tracepoint_jumps_at): Update.
4147 * linux-x86-low.c (append_insns)
4148 (i386_install_fast_tracepoint_jump_pad)
4149 (amd64_write_goto_address, i386_write_goto_address): Update.
4150 * linux-s390-low.c (append_insns, s390_write_goto_address):
4151 Update.
4152 * linux-ppc-low.c (ppc_relocate_instruction)
4153 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4154 (ppc_write_goto_address): Update.
4155 * linux-aarch64-low.c (append_insns): Update.
4156 * target.h (struct target_ops): Update.
4157 (write_inferior_memory): Don't declare.
4158 * target.c (target_write_memory): Rename from
4159 write_inferior_memory. Remove old target_write_memory.
4160
4161 2019-08-15 Tom Tromey <tromey@adacore.com>
4162
4163 * target.c (write_inferior_memory): Use std::vector.
4164
4165 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4166
4167 PR build/24886
4168 * configure.ac: Drop enable-libmcheck support.
4169 * configure, config.in: Rebuild.
4170 * acinclude.m4: Don't include it.
4171
4172 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4173
4174 * configure.srv: Remove Arm xml files.
4175
4176 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4177
4178 * configure.srv: Add new files. Remove xml generated files.
4179 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4180 registers.
4181 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4182 * linux-aarch32-tdesc.c: New file.
4183 * linux-aarch32-tdesc.h: New file.
4184 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4185 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4186 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4187 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4188 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4189 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4190 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4191 (arm_read_description): Call arm_linux_read_description.
4192 (initialize_low_arch): Don't init registers.
4193 * linux-arm-tdesc.c: New file.
4194 * linux-arm-tdesc.h: New file.
4195
4196 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4197
4198 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4199 Move counter inside for.
4200 (arm_read_description): Check ptrace earlier.
4201 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4202
4203 2019-07-09 Tom Tromey <tom@tromey.com>
4204
4205 * configure: Rebuild.
4206 * configure.ac: Change common to gdbsupport.
4207 * acinclude.m4: Change common to gdbsupport.
4208 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4209 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4210 common to gdbsupport.
4211 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4212 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4213 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4214 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4215 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4216 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4217 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4218 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4219 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4220 common to gdbsupport.
4221
4222 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4223
4224 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4225 defines.
4226 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4227
4228 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4229
4230 * configure.srv: Remove legacy xml.
4231 * linux-aarch64-low.c (initialize_low_arch): Remove
4232 initialize_low_tdesc call.
4233 * linux-aarch64-tdesc-selftest.c: Remove file.
4234 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4235 * linux-x86-low.c (initialize_low_arch): Remove
4236 initialize_low_tdesc call.
4237 * linux-x86-tdesc-selftest.c: Remove file.
4238 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4239
4240 2019-06-20 Tom de Vries <tdevries@suse.de>
4241
4242 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4243 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4244
4245 2019-06-19 Tom de Vries <tdevries@suse.de>
4246
4247 * debug.h (debug_write): Change return type to ssize_t.
4248 * debug.c (debug_write): Same.
4249
4250 2019-06-14 Tom Tromey <tom@tromey.com>
4251
4252 * configure.ac: Use new path to gnulib.
4253 * configure: Rebuild.
4254 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4255 to gnulib.
4256
4257 2019-06-11 Tom Tromey <tom@tromey.com>
4258
4259 * Makefile.in (SFILES): Add alloc.c.
4260 (OBS): Add alloc.o.
4261 (IPA_OBJS): Add alloc-ipa.o.
4262 (alloc-ipa.o): New target.
4263 (%.o: ../%.c): New pattern rule.
4264
4265 2019-06-10 Tom Tromey <tromey@adacore.com>
4266
4267 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4268 end warning with a newline.
4269 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4270 newline.
4271 * thread-db.c (attach_thread): Don't end warning with a newline.
4272 (thread_db_notice_clone): Likewise.
4273 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4274 newline.
4275 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4276 end warning with a newline.
4277
4278 2019-06-04 Pedro Alves <palves@redhat.com>
4279
4280 * server.c (captured_main): Use make_unique_xstrdup.
4281
4282 2019-06-02 Tom Tromey <tom@tromey.com>
4283
4284 * gdbreplay.c (fromhex): Remove.
4285 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4286
4287 2019-05-29 Tom Tromey <tromey@adacore.com>
4288
4289 * configure: Rebuild.
4290
4291 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4292
4293 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4294 sign extension code on 32-bit builds.
4295
4296 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4297
4298 * remote-utils.c:
4299 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4300
4301 2019-04-19 Tom Tromey <tom@tromey.com>
4302
4303 * server.c (struct vstop_notif): Derive from notif_event.
4304 <base>: Remove.
4305 (queue_stop_reply): Update.
4306 (remove_all_on_match_ptid): Change type. Rewrite.
4307 (discard_queued_stop_replies): Rewrite.
4308 (in_queued_stop_replies_ptid): Change type.
4309 (in_queued_stop_replies): Rewrite.
4310 (notif_stop): Update.
4311 (queue_stop_reply_callback): Update.
4312 (captured_main): Don't call initialize_notif.
4313 (push_stop_notification): Update.
4314 * notif.c (notif_write_event, handle_notif_ack)
4315 (notif_event_enque, notif_push): Update.
4316 (notif_event_xfree, initialize_notif): Remove.
4317 * notif.h (struct notif_event): Include <list>, not
4318 "common/queue.h".
4319 (struct notif_server) <queue>: Now a std::list.
4320 (notif_event_p): Remove typedef.
4321 (initialize_notif): Don't declare.
4322 (struct notif_event): Add virtual destructor.
4323
4324 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4325
4326 * ax.c (ax_vdebug): Call debug_printf.
4327 * debug.c (debug_write): New function.
4328 * debug.h (debug_write): New declaration.
4329 * linux-low.c (sigchld_handler): Call debug_write.
4330
4331 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4332
4333 * debug.c (debug_set_output): New function.
4334 (debug_vprintf): Send output to debug_file.
4335 (debug_flush): Likewise.
4336 * debug.h (debug_set_output): New declaration.
4337 * server.c (handle_monitor_command): Add debug-file option.
4338 (captured_main): Likewise.
4339
4340 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4341
4342 * debug.c (remote_debug): Add definition.
4343 * debug.h (remote_debug): Add declaration.
4344 * hostio.c (remote_debug): Remove declaration.
4345 * remote-utils.c (struct ui_file): Likewise.
4346 (remote_debug): Likewise.
4347 * remote-utils.h (remote_debug): Likewise,
4348 * server.c (remote_debug): Remove definition.
4349
4350 2019-04-10 Kevin Buettner <kevinb@redhat.com>
4351
4352 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4353 when using a 64-bit gdbserver.
4354
4355 2019-04-09 Tom Tromey <tromey@adacore.com>
4356
4357 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4358
4359 2019-04-08 Tom Tromey <tom@tromey.com>
4360
4361 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4362 throw.
4363 (linux_resume_one_lwp): Likewise.
4364
4365 2019-04-08 Tom Tromey <tom@tromey.com>
4366
4367 * gdbreplay.c: Update.
4368 * linux-low.c: Update.
4369 * server.c: Update.
4370
4371 2019-04-08 Tom Tromey <tom@tromey.com>
4372
4373 * server.c: Use C++ exception handling.
4374 * linux-low.c: Use C++ exception handling.
4375 * gdbreplay.c: Use C++ exception handling.
4376
4377 2019-04-08 Tom Tromey <tom@tromey.com>
4378
4379 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4380 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4381 (captured_main, main): Update.
4382 * gdbreplay.c (main): Update.
4383
4384 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4385
4386 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4387 value in argument pointer, return 1 if the entry is found and 0
4388 otherwise. Move comment.
4389 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4390 * linux-low.h (linux_get_auxv): Declare.
4391 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4392
4393 2019-04-05 Tom Tromey <tromey@adacore.com>
4394
4395 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4396 variables.
4397
4398 2019-03-28 Alan Hayward <alan.hayward@arm.com>
4399
4400 * linux-low.c (AT_HWCAP2): Add define if not already included.
4401
4402 2019-03-26 Alan Hayward <alan.hayward@arm.com>
4403
4404 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4405 (aarch64_arch_setup): Call linux_get_hwcap.
4406 * linux-arm-low.c (arm_get_hwcap): Remove function.
4407 (arm_read_description): Call linux_get_hwcap.
4408 * linux-low.c (linux_get_auxv): New function.
4409 (linux_get_hwcap): Likewise.
4410 (linux_get_hwcap2): Likewise.
4411 * linux-low.h (linux_get_hwcap): New declaration.
4412 (linux_get_hwcap2): Likewise.
4413 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4414 (ppc_arch_setup): Call linux_get_hwcap.
4415 * linux-s390-low.c (s390_get_hwcap): Remove function.
4416 (s390_arch_setup): Call linux_get_hwcap.
4417
4418 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4419 Jiong Wang <jiong.wang@arm.com>
4420
4421 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4422 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4423 to fail.
4424 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4425
4426 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4427 Jiong Wang <jiong.wang@arm.com>
4428
4429 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4430 (aarch64_get_hwcap): New function.
4431 (aarch64_arch_setup): Read APIA hwcap.
4432
4433 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4434 Jiong Wang <jiong.wang@arm.com>
4435
4436 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4437 (initialize_low_tracepoint): Likewise.
4438 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4439 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4440 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4441 (aarch64_linux_read_description): Likewise.
4442 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4443
4444 2019-03-12 John Baldwin <jhb@FreeBSD.org>
4445
4446 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4447 i386_create_target_description for 'segments' parameter.
4448 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4449 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4450 * win32-i386-low.c (i386_arch_setup): Likewise.
4451
4452 2019-03-12 Tom Tromey <tromey@adacore.com>
4453
4454 * linux-low.c (iterate_over_lwps): Update.
4455
4456 2019-03-06 Tom Tromey <tom@tromey.com>
4457
4458 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4459 (captured_main): Use SCOPE_EXIT.
4460
4461 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4462
4463 * configure.srv: Use '$enable_unittest' instead of '$development'
4464 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4465 case.
4466
4467 2019-02-27 Tom Tromey <tromey@adacore.com>
4468
4469 * gdbreplay.c (logchar): Handle \r\n.
4470
4471 2019-02-07 Alan Hayward <alan.hayward@arm.com>
4472
4473 * linux-low.c (linux_attach): Add process before lwp.
4474 * server.c (attach_inferior): Check if already attached.
4475
4476 2019-02-07 Tom Tromey <tom@tromey.com>
4477
4478 * x86-tdesc.h: Rename include guard.
4479 * x86-low.h: Add include guard.
4480 * wincecompat.h: Rename include guard.
4481 * win32-low.h: Add include guard.
4482 * utils.h: Rename include guard.
4483 * tracepoint.h: Rename include guard.
4484 * tdesc.h: Rename include guard.
4485 * target.h: Rename include guard.
4486 * server.h: Rename include guard.
4487 * remote-utils.h: Rename include guard.
4488 * regcache.h: Rename include guard.
4489 * nto-low.h: Rename include guard.
4490 * notif.h: Add include guard.
4491 * mem-break.h: Rename include guard.
4492 * lynx-low.h: Add include guard.
4493 * linux-x86-tdesc.h: Add include guard.
4494 * linux-s390-tdesc.h: Add include guard.
4495 * linux-ppc-tdesc-init.h: Add include guard.
4496 * linux-low.h: Add include guard.
4497 * linux-aarch64-tdesc.h: Add include guard.
4498 * linux-aarch32-low.h: Add include guard.
4499 * inferiors.h: Rename include guard.
4500 * i387-fp.h: Rename include guard.
4501 * hostio.h: Rename include guard.
4502 * gdbthread.h: Rename include guard.
4503 * gdb_proc_service.h: Rename include guard.
4504 * event-loop.h: Rename include guard.
4505 * dll.h: Rename include guard.
4506 * debug.h: Rename include guard.
4507 * ax.h: Rename include guard.
4508
4509 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4510
4511 PR gdb/23985
4512 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4513 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4514
4515 2019-01-25 Tom Tromey <tom@tromey.com>
4516
4517 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4518
4519 2019-01-25 Tom Tromey <tom@tromey.com>
4520
4521 * win32-low.c: Fix common/ includes.
4522 * win32-i386-low.c: Fix common/ includes.
4523 * tracepoint.c: Fix common/ includes.
4524 * thread-db.c: Fix common/ includes.
4525 * target.h: Fix common/ includes.
4526 * symbol.c: Fix common/ includes.
4527 * spu-low.c: Fix common/ includes.
4528 * server.h: Fix common/ includes.
4529 * server.c: Fix common/ includes.
4530 * remote-utils.c: Fix common/ includes.
4531 * regcache.h: Fix common/ includes.
4532 * regcache.c: Fix common/ includes.
4533 * nto-x86-low.c: Fix common/ includes.
4534 * notif.h: Fix common/ includes.
4535 * mem-break.h: Fix common/ includes.
4536 * lynx-low.c: Fix common/ includes.
4537 * lynx-i386-low.c: Fix common/ includes.
4538 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4539 * linux-x86-low.c: Fix common/ includes.
4540 * linux-low.c: Fix common/ includes.
4541 * inferiors.h: Fix common/ includes.
4542 * i387-fp.c: Fix common/ includes.
4543 * hostio.c: Fix common/ includes.
4544 * hostio-errno.c: Fix common/ includes.
4545 * gdbthread.h: Fix common/ includes.
4546 * gdbreplay.c: Fix common/ includes.
4547 * fork-child.c: Fix common/ includes.
4548 * event-loop.c: Fix common/ includes.
4549 * ax.c:
4550 (enum gdb_agent_op): Fix common/ includes.
4551
4552 2019-01-21 Tom Tromey <tom@tromey.com>
4553
4554 * tracepoint.c: Fix includes.
4555 * remote-utils.c: Fix includes.
4556 * linux-x86-low.c: Fix includes.
4557
4558 2019-01-01 Joel Brobecker <brobecker@adacore.com>
4559
4560 * gdbreplay.c (gdbreplay_version): Update copyright year in
4561 version message.
4562 * server.c (gdbserver_version): Likewise.
4563
4564 2018-12-05 Alan Hayward <alan.hayward@arm.com>
4565
4566 * linux-low.c (add_lwp): Switch ordering.
4567
4568 2018-11-29 Tom Tromey <tom@tromey.com>
4569
4570 * win32-low.c (win32_join): Take pid, not process.
4571 * target.h (struct target_ops) <join>: Change argument type.
4572 (join_inferior): Change argument name.
4573 * spu-low.c (spu_join): Take pid, not process.
4574 * server.c (handle_detach): Preserve pid before destroying
4575 process.
4576 * lynx-low.c (lynx_join): Take pid, not process.
4577 * linux-low.c (linux_join): Take pid, not process.
4578
4579 2018-11-23 Alan Hayward <alan.hayward@arm.com>
4580
4581 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4582 (aarch64_cannot_fetch_register): Likewise.
4583 (struct linux_target_ops): Update references.
4584
4585 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4586
4587 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4588
4589 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4590
4591 * configure.srv (ipa_ppc_linux_regobj): Add
4592 powerpc-isa207-htm-vsx32l-ipa.o and
4593 powerpc-isa207-htm-vsx64l-ipa.o.
4594 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4595 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4596 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4597 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4598 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4599 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4600 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4601 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4602 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4603 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4604 (init_registers_powerpc_isa207_htm_vsx32l)
4605 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4606 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4607 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4608 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4609 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4610 (ppc_store_tm_ctarregset): New functions.
4611 (ppc_regsets): Add entries for HTM regsets.
4612 (ppc_arch_setup): Set htm in features struct when needed. Set
4613 sizes for the HTM regsets.
4614 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4615 (initialize_low_arch): Call
4616 init_registers_powerpc_isa207_htm_vsx32l and
4617 init_registers_powerpc_isa207_htm_vsx64l.
4618 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4619 PPC_TDESC_ISA207_HTM_VSX.
4620 (initialize_low_tracepoint): Call
4621 init_registers_powerpc_isa207_htm_vsx32l and
4622 init_registers_powerpc_isa207_htm_vsx64l.
4623
4624 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4625
4626 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4627 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4628 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4629 (ppc_store_pmuregset): New functions.
4630 (ppc_regsets): Add entries for ebb and pmu regsets.
4631 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4632 pmu regsets are available. Set sizes for these regsets.
4633
4634 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4635
4636 * configure.srv (ipa_ppc_linux_regobj): Add
4637 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4638 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4639 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4640 rs6000/powerpc-isa207-vsx32l.xml, and
4641 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4642 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4643 <PPC_TDESC_ISA207_VSX>: New enum value.
4644 (init_registers_powerpc_isa207_vsx32l): Declare.
4645 (init_registers_powerpc_isa207_vsx64l): Declare.
4646 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4647 (ppc_store_tarregset): New function.
4648 (ppc_regsets): Add entry for the TAR regset.
4649 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4650 size for the TAR regsets.
4651 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4652 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4653 and init_registers_powerpc_isa207_vsx64l.
4654 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4655 (initialize_low_tracepoint): Call
4656 init_registers_powerpc_isa207_vsx32l and
4657 init_registers_powerpc_isa207_vsx64l.
4658
4659 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4660 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4661
4662 * configure.srv (ipa_ppc_linux_regobj): Add
4663 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4664 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4665 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4666 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4667 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4668 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4669 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4670 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4671 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4672 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4673 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4674 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4675 (ppc_hwcap): Add comment.
4676 (ppc_hwcap2): New global.
4677 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4678 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4679 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4680 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4681 when needed. Set sizes for the the DSCR and PPR regsets.
4682 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4683 (initialize_low_arch): Call
4684 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4685 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4686 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4687 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4688 (initialize_low_tracepoint): Call
4689 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4690 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4691
4692 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4693
4694 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
4695
4696 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
4697 Simon Marchi <simark@simark.ca>
4698
4699 * acinclude.m4: Include "../selftest.m4".
4700 * configure: Regenerate.
4701 * configure.ac: Use "GDB_AC_SELFTEST".
4702 * configure.srv: Use "$enable_unittests" instead of
4703 "$development" when checking whether unit tests have been
4704 enabled.
4705 * server.c (captured_main): Update message informing that
4706 selftests have been disabled.
4707
4708 2018-10-04 Tom Tromey <tom@tromey.com>
4709
4710 * configure: Rebuild.
4711
4712 2018-10-04 Tom Tromey <tom@tromey.com>
4713
4714 * server.c (handle_status): Rename inner "thread".
4715 (process_serial_event): Declare "res" in 'm' case.
4716 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
4717 (iterate_over_lwps): Rename inner "thread".
4718 (linux_qxfer_libraries_svr4): Rename inner "len".
4719 * gdbthread.h (find_thread_in_random): Rename inner "thread".
4720
4721 2018-10-01 Gary Benson <gbenson@redhat.com>
4722
4723 * gdb_proc_service.h: Moved common code to
4724 common/gdb_proc_service.h.
4725
4726 2018-10-01 Gary Benson <gbenson@redhat.com>
4727
4728 * gdb_proc_service.h: Synchronize comments and whitespace with
4729 GDB's version of this file.
4730
4731 2018-09-25 Tom Tromey <tom@tromey.com>
4732
4733 * configure: Rebuild.
4734 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
4735
4736 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4737
4738 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
4739 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
4740 ($(IPA_LIB)): Sort IPA_OBJS.
4741
4742 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4743
4744 * Makefile.in: Remove references to $(ADD_DEPS).
4745
4746 2018-09-16 Tom Tromey <tom@tromey.com>
4747
4748 * remote-utils.c (remote_open): Use GNU style for metasyntactic
4749 variables.
4750 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
4751 variables.
4752
4753 2018-09-05 Tom Tromey <tom@tromey.com>
4754
4755 * configure: Rebuild.
4756
4757 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4758
4759 PR build/23399
4760 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
4761
4762 2018-08-27 Tom Tromey <tom@tromey.com>
4763
4764 PR build/23087:
4765 * configure: Rebuild.
4766
4767 2018-08-27 Tom Tromey <tom@tromey.com>
4768
4769 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
4770 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
4771 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
4772 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
4773 (s390x_emit_stack_adjust): Add casts to unsigned char.
4774
4775 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
4776
4777 PR gdb/23374
4778 PR gdb/23375
4779 * server.h (struct client_state) <disable_randomization>:
4780 Initialize to 1.
4781
4782 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4783
4784 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
4785 variable.
4786 (mips_supply_ptrace_register): Likewise.
4787
4788 2018-07-22 Tom Tromey <tom@tromey.com>
4789
4790 * configure: Rebuild.
4791
4792 2018-07-22 Tom Tromey <tom@tromey.com>
4793
4794 * win32-low.c (win32_create_inferior): Remove unused variables.
4795 * gdbreplay.c (remote_open): Remove unused variable.
4796 * remote-utils.c (remote_prepare): Remove unused variable.
4797 * x86-tdesc.h (X86_TDESC_H): Define.
4798 (amd64_expedite_regs): Define conditionally.
4799 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
4800 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
4801 * remote-utils.c (readchar): Remove unused variable.
4802
4803 2018-07-13 Pedro Alves <palves@redhat.com>
4804
4805 * linux-low.c (linux_kill): Change parameter to process_info
4806 pointer instead of pid. Adjust.
4807 * lynx-low.c (lynx_kill): Likewise.
4808 * nto-low.c (nto_kill): Likewise.
4809 * spu-low.c (spu_kill): Likewise.
4810 * win32-low.c (win32_kill): Likewise.
4811 * server.c (handle_v_kill, kill_inferior_callback)
4812 (detach_or_kill_for_exit): Adjust.
4813 * target.c (kill_inferior): Change parameter to process_info
4814 pointer instead of pid. Adjust.
4815 * target.h (struct target_ops) <kill>: Change parameter to
4816 process_info pointer instead of pid. Adjust all implementations
4817 and callers.
4818 (kill_inferior): Likewise.
4819
4820 2018-07-13 Pedro Alves <palves@redhat.com>
4821
4822 * linux-low.c (linux_detach, linux_join): Change parameter to
4823 process_info pointer instead of pid. Adjust.
4824 * lynx-low.c (lynx_detach, lynx_join): Likewise.
4825 * nto-low.c (nto_detach): Likewise.
4826 * spu-low.c (spu_detach, spu_join): Likewise.
4827 * win32-low.c (win32_detach, win32_join): Likewise.
4828 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
4829 * target.h (struct target_ops) <detach, join>: Change parameter to
4830 process_info pointer instead of pid. Adjust all implementations
4831 and callers.
4832 (detach_inferior, join_inferior): Rename 'pid' parameter to
4833 'proc'.
4834
4835 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4836 Jan Kratochvil <jan.kratochvil@redhat.com>
4837 Paul Fertser <fercerpav@gmail.com>
4838 Tsutomu Seki <sekiriki@gmail.com>
4839
4840 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
4841 (OBS): Add 'common/netstuff.o'.
4842 (GDBREPLAY_OBS): Likewise.
4843 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
4844 (remote_open): Implement support for IPv6
4845 connections.
4846 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
4847 and 'wspiapi.h'.
4848 (handle_accept_event): Accept connections from IPv6 sources.
4849 (remote_prepare): Handle IPv6-style hostnames; implement
4850 support for IPv6 connections.
4851 (remote_open): Implement support for printing connections from
4852 IPv6 sources.
4853
4854 2018-07-11 Pedro Alves <palves@redhat.com>
4855
4856 PR gdb/23377
4857 * mem-break.c (any_persistent_commands): Add process_info
4858 parameter and use it instead of relying on the current process.
4859 Change return type to bool.
4860 * mem-break.h (any_persistent_commands): Add process_info
4861 parameter and change return type to bool.
4862 * server.c (handle_detach): Remove require_running_or_return call.
4863 Look up the process_info for the process we're about to detach.
4864 If not found, return back error to GDB. Adjust
4865 any_persistent_commands call to pass down a process pointer.
4866
4867 2018-07-11 Pedro Alves <palves@redhat.com>
4868
4869 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
4870 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
4871 instead of collect_register_by_name.
4872 * regcache.c (regcache_raw_get_unsigned_by_name): New.
4873 * regcache.h (regcache_raw_get_unsigned_by_name): New.
4874
4875 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4876 Pedro Alves <palves@redhat.com>
4877
4878 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
4879
4880 2018-07-03 Tom Tromey <tom@tromey.com>
4881
4882 * linux-low.c: Update.
4883 * lynx-low.c: Update.
4884 * mem-break.c: Update.
4885 * nto-low.c: Update.
4886 * remote-utils.c: Update.
4887 * server.c: Update.
4888 * spu-low.c: Update.
4889 * target.c: Update.
4890 * win32-low.c: Update.
4891
4892 2018-07-03 Tom Tromey <tom@tromey.com>
4893
4894 * server.c: Update.
4895
4896 2018-07-03 Tom Tromey <tom@tromey.com>
4897
4898 * linux-low.c: Update.
4899
4900 2018-07-03 Tom Tromey <tom@tromey.com>
4901
4902 * target.c: Update.
4903
4904 2018-07-03 Tom Tromey <tom@tromey.com>
4905
4906 * linux-low.c: Update.
4907 * linux-mips-low.c: Update.
4908 * lynx-low.c: Update.
4909 * nto-low.c: Update.
4910 * remote-utils.c: Update.
4911 * server.c: Update.
4912 * spu-low.c: Update.
4913 * target.c: Update.
4914 * thread-db.c: Update.
4915
4916 2018-07-03 Tom Tromey <tom@tromey.com>
4917
4918 * linux-low.c: Update.
4919 * linux-mips-low.c: Update.
4920 * lynx-low.c: Update.
4921 * mem-break.c: Update.
4922 * nto-low.c: Update.
4923 * remote-utils.c: Update.
4924 * server.c: Update.
4925 * spu-low.c: Update.
4926 * target.c: Update.
4927 * tracepoint.c: Update.
4928
4929 2018-07-03 Tom Tromey <tom@tromey.com>
4930
4931 * linux-low.c: Update.
4932 * linux-ppc-low.c: Update.
4933 * linux-x86-low.c: Update.
4934 * proc-service.c: Update.
4935 * server.c: Update.
4936 * spu-low.c: Update.
4937 * thread-db.c: Update.
4938 * win32-low.c: Update.
4939
4940 2018-07-03 Tom Tromey <tom@tromey.com>
4941
4942 * linux-low.c: Update.
4943 * lynx-low.c: Update.
4944 * nto-low.c: Update.
4945 * remote-utils.c: Update.
4946 * spu-low.c: Update.
4947 * thread-db.c: Update.
4948 * win32-low.c: Update.
4949
4950 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4951
4952 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
4953 parameter in call to 'amd64_create_target_description'.
4954
4955 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
4956
4957 * x86-tdesc.h: Remove executable permission flag.
4958
4959 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4960
4961 * configure.ac: Remove AC_PREREQ, add missing quoting.
4962 * configure: Re-generate.
4963 * config.in: Re-generate.
4964 * aclocal.m4: Re-generate.
4965
4966 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
4967
4968 * tracepoint.h (current_traceframe): Remove declaration.
4969
4970 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4971
4972 * linux-aarch64-low.c (is_sve_tdesc): New function.
4973 (aarch64_sve_regs_copy_to_regcache): Likewise.
4974 (aarch64_sve_regs_copy_from_regcache): Likewise.
4975 (aarch64_regs_info): Add SVE checks.
4976 (initialize_low_arch): Initialize SVE.
4977
4978 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4979
4980 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
4981
4982 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4983
4984 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
4985 (initialize_low_tracepoint): Likewise
4986 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
4987 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
4988 param.
4989 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
4990 checks.
4991 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
4992
4993 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4994
4995 * server.h (PBUFSIZ): Increase size
4996
4997 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4998
4999 * regcache.c (regcache::raw_compare): New function.
5000 * regcache.h (regcache::raw_compare): New declaration.
5001
5002 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5003
5004 * regcache.c (new_register_cache): Use new.
5005 (free_register_cache): Use delete.
5006 (register_data): Use const.
5007 (supply_register): Move body inside regcache.
5008 (regcache::raw_supply): New override function.
5009 (collect_register): Move body inside regcache.
5010 (regcache::raw_collect): New override function.
5011 (regcache::get_register_status): New override function.
5012 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5013
5014 2018-06-09 Tom Tromey <tom@tromey.com>
5015
5016 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5017 declare queue.
5018 (event_queue): Use std::queue.
5019 (gdb_event_xfree): Remove.
5020 (initialize_event_loop, process_event, wait_for_event): Update.
5021
5022 2018-06-08 Stan Cox <scox@redhat.com>
5023
5024 * win32-low.c (win32_create_inferior): last_ptid and last_status
5025 moved to client_state.
5026
5027 2018-06-08 Pedro Alves <palves@redhat.com>
5028
5029 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5030 common/common-exceptions.o, common/common-utils.o,
5031 common/errors.o, common/print-utils.o and utils.o.
5032 * gdbreplay.c: Include "common-defs.h" instead of the two
5033 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5034 string.h or alloca.h.
5035 (perror_with_name): Delete.
5036 (remote_open): Use xstrdup instead of strdup.
5037 (main): Rename to ...
5038 (captured_main): ... this.
5039 (main): New.
5040
5041 2018-06-08 Tom Tromey <tom@tromey.com>
5042
5043 * linux-low.c (linux_low_read_btrace): Update.
5044
5045 2018-06-04 Stan Cox <scox@redhat.com>
5046
5047 * server.h (struct client_state): New.
5048 * server.c (cont_thread, general_thread, multi_process)
5049 (report_fork_events, report_vfork_events, report_exec_events)
5050 (report_thread_events, swbreak_feature, hwbreak_feature)
5051 (vCont_supported, disable_randomization, pass_signals)
5052 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5053 Moved to client_state.
5054 * remote-utils.c (remote_debug, noack_mode)
5055 (transport_is_reliable): Moved to client_state.
5056 * tracepoint.c (current_traceframe): Moved to client_state.
5057
5058 Update all callers.
5059 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5060 linux-low.c, remote-utils.h, target.c: Use client_state.
5061
5062 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5063
5064 * configure.srv: Add new c/h file.
5065
5066 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5067
5068 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5069 null VQ.
5070
5071 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5072
5073 * gdb.arch/mips-fpregset-core.exp: New test.
5074 * gdb.arch/mips-fpregset-core.c: New test source.
5075
5076 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5077
5078 PR server/23198
5079 * hostio.c (require_int): Do not report overflow for integers
5080 between 0xfffffff and 0x7fffffff.
5081
5082 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5083
5084 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5085 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5086 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5087 functions.
5088 (the_low_target): Wire them.
5089
5090 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5091
5092 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5093 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5094 mode. Call collect_register_by_name with vscr using
5095 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5096 (ppc_store_vrregset): Add and set vscr_offset variable as in
5097 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5098 vscr_offset.
5099
5100 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5101
5102 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5103 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5104 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5105
5106 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5107
5108 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5109 (ppc_store_vsxregset): Likewise.
5110 (ppc_fill_vrregset): Likewise.
5111 (ppc_store_vrregset): Likewise.
5112 (ppc_fill_evrregset): Likewise.
5113 (ppc_store_evrregset): Likewise.
5114 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5115 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5116 needed.
5117
5118 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5119
5120 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5121 wordsize of the inferior. Call ppc_linux_target_wordsize.
5122
5123 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5124
5125 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5126 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5127 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5128 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5129 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5130 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5131 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5132 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5133 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5134 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5135 (tdesc_powerpc_e500l): Remove.
5136 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5137 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5138 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5139 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5140 linux-ppc-tdesc.h.
5141 (ppc_arch_setup): Remove target description matching code. Fill a
5142 ppc_linux_features struct and call ppc_linux_match_description
5143 with it.
5144
5145 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5146
5147 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5148 width of the requested register exceeds the width of the
5149 `ptrace' data type.
5150 (mips_cannot_store_register): Likewise.
5151
5152 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5153
5154 * linux-mips-low.c (mips_fetch_register): New function. Update
5155 preceding comment.
5156 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5157 (the_low_target): Wire `mips_fetch_register'.
5158
5159 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5160
5161 * lynx-i386-low.c (LYNXOS_178): New macro.
5162 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5163 the layout on LynxOS-178.
5164 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5165 handle floating point registers that are not supported by
5166 LynxOS-178.
5167
5168 2018-05-10 Tom Tromey <tom@tromey.com>
5169
5170 * configure: Rebuild.
5171
5172 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5173
5174 PR server/23158:
5175 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5176 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5177 Use it to set the expedite_regs field in the given tdesc.
5178 * x86-tdesc.h: New file.
5179 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5180 Adjust following the addition of the new expedite_regs parameter
5181 to init_target_desc.
5182 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5183 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5184 (i386_linux_read_description, amd64_linux_read_description):
5185 Adjust following the addition of the new expedite_regs parameter
5186 to init_target_desc.
5187 * lynx-i386-low.c: #include "x86-tdesc.h".
5188 (lynx_i386_arch_setup): Adjust following the addition of the new
5189 expedite_regs parameter to init_target_desc.
5190 * nto-x86-low.c: #include "x86-tdesc.h".
5191 (nto_x86_arch_setup): Adjust following the addition of the new
5192 expedite_regs parameter to init_target_desc.
5193 * win32-i386-low.c: #include "x86-tdesc.h".
5194 (i386_arch_setup): Adjust following the addition of the new
5195 expedite_regs parameter to init_target_desc.
5196
5197 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5198
5199 PR server/23158:
5200 * win32-low.c (win32_create_inferior): Add call to my_wait
5201 setting last_status global.
5202
5203 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5204
5205 PR server/23158:
5206 * win32-low.c (create_process): Only call gdb_tilde_expand if
5207 inferior_cwd is not NULL.
5208
5209 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5210
5211 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5212 registers to the cache if their values have changed.
5213 (i387_xsave_to_cache): Provide default values for x87 control
5214 registers when these features are available, but disabled.
5215 * regcache.c (supply_register_by_name_zeroed): New function.
5216 * regcache.h (supply_register_by_name_zeroed): Declare new
5217 function.
5218
5219 2018-05-07 Tom Tromey <tom@tromey.com>
5220
5221 * configure: Rebuild.
5222
5223 2018-05-04 Tom Tromey <tom@tromey.com>
5224
5225 * configure: Rebuild.
5226
5227 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5228 Pedro Alves <palves@redhat.com>
5229
5230 * linux-aarch64-low.c (aarch64_stopped_data_address):
5231 Likewise.
5232
5233 2018-04-27 Tom Tromey <tom@tromey.com>
5234
5235 * configure: Rebuild.
5236
5237 2018-04-23 Tom Tromey <tom@tromey.com>
5238
5239 * configure: Rebuild.
5240
5241 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5242
5243 * Makefile.in (depcomp): Add "..".
5244 (all_deps_files): New and use it.
5245
5246 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5247
5248 * configure.srv (aarch64*-*-linux*): Don't include xml.
5249 (i[34567]86-*-cygwin*): Likewise.
5250 (i[34567]86-*-linux*): Likewise.
5251 (i[34567]86-*-lynxos*): Likewise.
5252 (i[34567]86-*-mingw32ce*): Likewise.
5253 (i[34567]86-*-mingw*): Likewise.
5254 (i[34567]86-*-nto*): Likewise.
5255 (tic6x-*-uclinux): Likewise.
5256 (x86_64-*-linux*): Likewise.
5257 (x86_64-*-mingw*): Likewise.
5258 (x86_64-*-cygwin*): Likewise.
5259
5260 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5261
5262 * tdesc.c: Remove xml parameter.
5263
5264 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5265
5266 * server.c (get_features_xml): Remove cast.
5267 * tdesc.c (void target_desc::accept): Fill in function.
5268 (tdesc_get_features_xml): Remove old xml creation.
5269 (print_xml_feature::visit_pre): Add xml vistor.
5270 * tdesc.h (struct target_desc): Make xmltarget mutable.
5271 (tdesc_get_features_xml): Remove declaration.
5272
5273 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5274
5275 * tdesc.c (tdesc_architecture_name): Add new function.
5276 (tdesc_osabi_name): Likewise.
5277 (tdesc_get_features_xml): Use new functions.
5278
5279 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5280
5281 * tdesc.c (tdesc_create_flags): Remove.
5282 (tdesc_add_flag): Likewise.
5283 (tdesc_named_type): Likewise.
5284 (tdesc_create_union): Likewise.
5285 (tdesc_create_struct): Likewise.
5286 (tdesc_create_vector): Likewise.
5287 (tdesc_add_bitfield): Likewise.
5288 (tdesc_add_field): Likewise.
5289 (tdesc_set_struct_size): Likewise.
5290
5291 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5292
5293 * tdesc.c (~target_desc): Remove implictly deleted items.
5294 (init_target_desc): Iterate all features.
5295 (tdesc_get_features_xml): Use vector.
5296 (tdesc_create_feature): Create feature.
5297 * tdesc.h (tdesc_feature) Remove
5298 (target_desc): Add features.
5299
5300 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5301
5302 * Makefile.in: Add common/tdesc.c
5303 * tdesc.c (init_target_desc): init all reg_defs from register
5304 vector.
5305 (tdesc_create_reg): Create tdesc_reg.
5306 * tdesc.h (tdesc_feature): Add register vector.
5307
5308 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5309
5310 * tdesc.h (struct target_desc) <features>: Change type to
5311 std::vector<std::string>.
5312 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5313 changes.
5314 (tdesc_get_features_xml): Likewise.
5315 (tdesc_create_feature): Likewise.
5316
5317 2018-03-26 Alan Hayward <alan.hayward@arm.com>
5318
5319 * regcache.c (find_register_by_number): Return a ref.
5320 (find_regno): Use references.
5321 (register_size): Likewise.
5322 (register_data): Likewise.
5323 * tdesc.c (target_desc::~target_desc): Remove free calls.
5324 (target_desc::operator==): Use std::vector compare.
5325 (init_target_desc): Use reference.
5326 (tdesc_create_reg): Use reg constructors.
5327 * tdesc.h (struct target_desc): Replace pointer with object.
5328
5329 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5330
5331 * regcache.c (find_register_by_number): Make static.
5332 (find_regno): Use find_register_by_number
5333 * regcache.h (struct reg): Remove declaration.
5334
5335 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5336
5337 * tdesc.c (target_desc::~target_desc): Move to here.
5338 (target_desc::operator==): Likewise.
5339 * tdesc.h (target_desc::~target_desc): Move from here.
5340 (target_desc::operator==): Likewise.
5341
5342 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5343
5344 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5345
5346 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5347
5348 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5349 S390_TDESC_GS.
5350 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5351 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5352 and init_registers_s390_gs_linux64.
5353
5354 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5355
5356 * linux-s390-low.c (s390_fill_gs): Remove function.
5357 (s390_fill_gsbc): Remove function.
5358 (s390_regsets): Set fill functions for the guarded storage regsets
5359 to NULL.
5360
5361 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5362
5363 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5364 the word size. Add comment.
5365 (s390_get_wordsize): New function.
5366 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5367 pswm with it. Instead, use s390_get_wordsize to determine the
5368 word size first and derive the correct tdesc from that directly.
5369
5370 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5371
5372 * Makefile.in: Include silent-rules.mk.
5373 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5374 (COMPILE): Add ECHO_CXX.
5375 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5376 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5377 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5378 (version-generated.c): Add ECHO_GEN.
5379 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5380 (IPAGENT_COMPILE): Add ECHO_CXX.
5381 (%-generated.c): Add ECHO_REGDAT.
5382
5383 2018-03-14 Tom Tromey <tom@tromey.com>
5384
5385 PR cli/14977:
5386 * ax.c (ax_printf): Special case for NULL.
5387
5388 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5389
5390 * linux-low.c (linux_qxfer_libraries_svr4): Use
5391 xml_escape_text_append.
5392
5393 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5394
5395 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5396
5397 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5398
5399 * server.c (handle_general_set): Remove unnecessary xstrdup.
5400
5401 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5402
5403 * server.c (parse_debug_format_options): Adjust to
5404 delim_string_to_char_ptr_vec changes.
5405 * thread-db.c (thread_db_load_search): Adjust to
5406 dirnames_to_char_ptr_vec changes.
5407
5408 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5409
5410 * target.h (target_enable_btrace, target_disable_btrace)
5411 (target_read_btrace, target_read_btrace_conf): Turn macro into
5412 inline function. Throw error if target method is not defined.
5413 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5414 check for btrace target method. Be prepared to handle exceptions
5415 from btrace target methods.
5416
5417 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5418
5419 * server.c (captured_main): Change order of error message printed
5420 when the current working directory cannot be found.
5421
5422 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5423
5424 * server.c: Include "filenames.h" and "pathstuff.h".
5425 (program_name): Delete variable.
5426 (program_path): New anonymous class.
5427 (get_exec_wrapper): Use "program_path" instead of
5428 "program_name".
5429 (handle_v_run): Likewise.
5430 (captured_main): Likewise.
5431 (process_serial_event): Likewise.
5432
5433 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5434
5435 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5436 (OBJS): Add "pathstuff.o".
5437 * server.c (current_directory): New global variable.
5438 (captured_main): Initialize "current_directory".
5439
5440 2018-02-26 Alan Hayward <alan.hayward@arm.com>
5441
5442 * tdesc.c: Use common/tdesc.h.
5443 * tdesc.h: Likewise.
5444
5445 2018-02-20 Alan Hayward <alan.hayward@arm.com>
5446 Simon Marchi <simon.marchi@ericsson.com>
5447
5448 * Makefile.in: Switch order of make rules.
5449
5450 2018-02-19 Alan Hayward <alan.hayward@arm.com>
5451
5452 * Makefile.in: Add common directory in build.
5453 * configure.ac: Add common reference.
5454 * configure: Regenerate.
5455
5456 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5457
5458 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5459 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5460 * spu-low.c (spu_target_ops): Likewise.
5461 * win32-low.c (win32_target_ops): Likewise.
5462 * server.c (supported_btrace_packets): Report packets unconditionally.
5463 * target.h (target_ops) <supports_btrace>: Remove.
5464 (target_supports_btrace): Remove.
5465
5466 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5467
5468 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5469 (handle_btrace_disable): Change return type to void. Use exceptions
5470 to report errors.
5471 (handle_btrace_general_set): Catch exception and copy message to
5472 return message.
5473
5474 2018-02-08 Tom Tromey <tom@tromey.com>
5475
5476 * linux-low.c (install_software_single_step_breakpoints): Use
5477 make_scoped_restore.
5478 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5479 (do_restore_current_thread_cleanup): Remove.
5480 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5481 declare.
5482
5483 2018-02-08 Tom Tromey <tom@tromey.com>
5484
5485 * mem-break.c (set_raw_breakpoint_at): Use
5486 gdb::unique_xmalloc_ptr.
5487
5488 2018-01-30 Pedro Alves <palves@redhat.com>
5489
5490 PR gdb/13211
5491 * target.c (target_terminal::terminal_state): Rename to ...
5492 (target_terminal::m_terminal_state): ... this.
5493
5494 2018-01-19 James Clarke <jrtc27@jrtc27.com>
5495
5496 * linux-low.c (handle_extended_wait): Surround call to
5497 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5498
5499 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5500
5501 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5502 linux_ptrace_attach_fail_reason_string now returning an
5503 std::string.
5504 (linux_attach): Likewise.
5505 * thread-db.c (attach_thread): Likewise.
5506
5507 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5508
5509 PR gdb/21559
5510 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5511 checking for fs_base/gs_base fields in struct user_regs_struct.
5512 * configure: Regenerate.
5513
5514 2018-01-16 Yao Qi <yao.qi@linaro.org>
5515
5516 PR gdb/18749
5517 * linux-low.c (fetch_register): Call supply_register instead of
5518 error.
5519
5520 2018-01-08 Yao Qi <yao.qi@linaro.org>
5521 Simon Marchi <simon.marchi@ericsson.com>
5522
5523 * Makefile.in (OBS): Remove selftest.o.
5524 * configure.ac: Set srv_selftest_objs if $development is true.
5525 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5526 * configure: Re-generated.
5527 * server.c (captured_main): Wrap variable selftest_filter with
5528 GDB_SELF_TEST.
5529
5530 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5531
5532 * server.c (parse_debug_format_options): Return std::string.
5533 (handle_monitor_command, captured_main): Adjust.
5534
5535 2018-01-05 Pedro Alves <palves@redhat.com>
5536
5537 PR gdb/18653
5538 * server.c (captured_main): Pass quiet=false to
5539 save_original_signals_state.
5540
5541 2018-01-01 Joel Brobecker <brobecker@adacore.com>
5542
5543 * gdbreplay.c (gdbreplay_version): Update copyright year in
5544 version message.
5545 * server.c (gdbserver_version): Likewise.
5546
5547 2017-12-08 Tom Tromey <tom@tromey.com>
5548
5549 * ax.c (ax_printf): Update.
5550
5551 2017-12-07 Yao Qi <yao.qi@linaro.org>
5552
5553 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5554 aarch64_linux_read_description.
5555 * linux-amd64-ipa.c (idx2mask): New array.
5556 (get_ipa_tdesc): Move idx2mask out.
5557 (initialize_low_tracepoint): Initialize target descriptions.
5558 * linux-i386-ipa.c (idx2mask): New array.
5559 (get_ipa_tdesc): Move idx2mask out.
5560 (initialize_low_tracepoint): Initialize target descriptions.
5561
5562 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5563
5564 * tdesc.c (struct tdesc_type): Change return type.
5565 (tdesc_add_flag): Change parameter type.
5566 (tdesc_add_bitfield): Likewise.
5567 (tdesc_add_field): Likewise.
5568 (tdesc_set_struct_size): Likewise.
5569
5570 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5571
5572 * regcache.c (registers_to_string): Remove unused variable.
5573
5574 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5575
5576 * inferiors.c (for_each_inferior_with_data): Remove.
5577 * inferiors.h (for_each_inferior_with_data): Remove.
5578 * server.c (handle_qxfer_threads_worker): Change parameter type.
5579 (handle_qxfer_threads_proper): Use for_each_thread.
5580
5581 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5582
5583 * inferiors.c (for_each_inferior): Remove.
5584 (clear_inferiors): Use for_each_thread.
5585 * inferiors.h (for_each_inferior): Remove.
5586 * linux-low.c (linux_wait_for_event_filtered): Use
5587 for_each_thread.
5588 (linux_stabilize_threads): Likewise.
5589 * regcache.c (regcache_release): Likewise.
5590 * server.c (gdb_wants_all_threads_stopped): Likewise.
5591 (clear_pending_status_callback): Remove.
5592 (handle_status): Use for_each_thread.
5593 (captured_main): Likewise.
5594 * win32-low.c (child_init_thread_list): Likewise.
5595 (win32_clear_inferiors): Likewise.
5596 (fake_breakpoint_event): Likewise.
5597
5598 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5599
5600 * inferiors.h (find_inferior): Remove.
5601 * inferiors.c (find_inferior): Remove.
5602
5603 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5604
5605 * linux-low.c (resume_status_pending_p): Update comment.
5606 (need_step_over_p): Update comment.
5607
5608 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5609
5610 * linux-low.c (proceed_one_lwp): Return void, change parameter
5611 type.
5612 (unsuspend_and_proceed_one_lwp): Likewise.
5613 (proceed_all_lwps): Use for_each_thread.
5614 (unstop_all_lwps): Likewise.
5615
5616 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5617
5618 * linux-low.c (linux_resume_one_thread): Return void, take
5619 parameter directly.
5620 (linux_resume): Use for_each_thread.
5621
5622 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5623
5624 * linux-low.c (send_sigstop_callback): Return void, change
5625 parameter type. Rename to...
5626 (send_sigstop): ... this.
5627 (suspend_and_send_sigstop_callback): Return void, change parameter
5628 type. Rename to...
5629 (suspend_and_send_sigstop): ... this.
5630 (stop_all_lwps): Use for_each_thread.
5631
5632 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5633
5634 * linux-low.c (lwp_running): Return bool, remove unused
5635 argument.
5636 (linux_stabilize_threads): Use find_thread.
5637
5638 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5639
5640 * linux-low.c (select_singlestep_lwp_callback): Remove.
5641 (count_events_callback): Remove.
5642 (select_event_lwp_callback): Remove.
5643 (select_event_lwp): Use find_thread/for_each_thread.
5644
5645 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5646
5647 * linux-low.c (not_stopped_callback): Return bool, take filter
5648 argument directly.
5649 (linux_wait_for_event_filtered): Use find_thread.
5650 (linux_wait_1): Likewise.
5651
5652 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5653
5654 * linux-low.c (same_lwp): Remove.
5655 (find_lwp_pid): Use find_thread.
5656
5657 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5658
5659 * linux-low.c (delete_lwp_callback): Remove.
5660 (linux_mourn): Use for_each_thread.
5661
5662 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5663
5664 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5665 args parameter, don't check for pid.
5666 (linux_detach): Use for_each_thread.
5667
5668 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5669
5670 * linux-low.c (struct counter): Remove.
5671 (second_thread_of_pid_p): Remove.
5672 (last_thread_of_process_p): Use find_thread.
5673
5674 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5675
5676 * inferiors.c (find_inferior_in_random): Remove.
5677 * inferiors.h (find_inferior_in_random): Remove.
5678 * linux-low.c (status_pending_p_callback): Return bool, accept
5679 parameter ptid directly.
5680 (linux_wait_for_event_filtered): Use find_thread_in_random.
5681 (linux_wait_1): Likewise.
5682
5683 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5684
5685 * inferiors.c (find_inferior_id): Remove.
5686 (find_thread_ptid): Move implemention from find_inferior_id to
5687 here.
5688 * inferiors.h (find_inferior_id): Remove.
5689 * server.c (handle_status): Use find_thread_ptid.
5690 (process_serial_event): Likewise.
5691 * thread-db.c (find_one_thread): Likewise.
5692 (thread_db_thread_handle): Likewise.
5693 * win32-low.c (thread_rec): Likewise.
5694 (child_delete_thread): Likewise.
5695 (win32_thread_alive): Likewise.
5696 (get_child_debug_event): Likewise.
5697
5698 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5699
5700 * linux-mips-low.c (update_watch_registers_callback): Return
5701 void, remove pid_p parameter, don't check for pid.
5702 (mips_insert_point, mips_remove_point): Use for_each_thread.
5703
5704 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5705
5706 * lynx.low (lynx_delete_thread_callback): Remove.
5707 (lynx_mourn): Use for_each_thread.
5708
5709 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5710
5711 * regcache.c (regcache_invalidate_one): Remove.
5712 (regcache_invalidate_pid): use for_each_thread.
5713
5714 2017-11-26 Tom Tromey <tom@tromey.com>
5715
5716 * linux-low.c (linux_create_inferior): Update.
5717
5718 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
5719
5720 * spu-low.c (spu_create_inferior): Fix typo in argument name.
5721
5722 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5723
5724 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
5725 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5726 * linux-aarch64-tdesc-selftest.c: New file.
5727 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5728
5729 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5730
5731 * configure.srv: Add new file.
5732 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5733 * linux-aarch64-tdesc-selftest.c: New file.
5734 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5735
5736 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5737
5738 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
5739 * linux-aarch64-low.c (initialize_low_arch): Remove init.
5740 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
5741
5742 2017-11-24 Alan Hayward <alan.hayward@arm.com>
5743
5744 * configure.srv: Add new files.
5745 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
5746 aarch64_linux_read_description.
5747 * linux-aarch64-low.c (aarch64_linux_read_description):
5748 Merge with aarch64_arch_setup.
5749 (aarch64_arch_setup): Call aarch64_linux_read_description.
5750 * linux-aarch64-tdesc.c: New file.
5751 * linux-aarch64-tdesc.h: New file.
5752
5753 2017-11-24 Yao Qi <yao.qi@linaro.org>
5754
5755 * configure.srv: Set $srv_regobj for tic6x-linux.
5756 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
5757 (tic6x_read_description): Move some code to tic6x_arch_setup.
5758 (tic6x_tdesc_test): New function.
5759 (initialize_low_arch): Call selftests::register_test.
5760
5761 2017-11-22 Yao Qi <yao.qi@linaro.org>
5762
5763 * remote-utils.c (prepare_resume_reply): Use memcpy.
5764
5765 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5766
5767 * linux-low.c (kill_one_lwp_callback): Return void, take
5768 argument directly, don't filter on pid.
5769 (linux_kill): Use for_each_thread.
5770
5771 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5772
5773 * linux-low.c (need_step_over_p): Return bool, remove dummy
5774 argument.
5775 (linux_resume, proceed_all_lwps): Use find_thread.
5776
5777 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5778
5779 * linux-low.c (resume_status_pending_p): Return bool, remove
5780 flag_p argument.
5781 (linux_resume): Use find_thread.
5782
5783 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5784
5785 * linux-low.c (struct thread_resume_array): Remove.
5786 (linux_set_resume_request): Return void, take arguments
5787 directly.
5788 (linux_resume): Use for_each_thread.
5789
5790 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5791
5792 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
5793 return bool, remove data argument.
5794 (linux_stabilize_threads): Use find_thread.
5795
5796 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5797
5798 * linux-low.c (unsuspend_one_lwp): Remove.
5799 (unsuspend_all_lwps): Use for_each_thread, inline code from
5800 unsuspend_one_lwp.
5801
5802 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5803
5804 * gdbthread.h (find_thread): Add overload with ptid_t filter.
5805 * linux-low.c (struct iterate_over_lwps_args): Remove.
5806 (iterate_over_lwps_filter): Remove.
5807 (iterate_over_lwps): Use find_thread.
5808
5809 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5810
5811 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
5812 (linux_handle_new_gdb_connection): Use for_each_thread, inline
5813 code from reset_lwp_ptrace_options_callback.
5814
5815 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5816
5817 * linux-arm-low.c (struct update_registers_data): Remove.
5818 (update_registers_callback): Return void, take arguments
5819 directly, don't check thread's pid.
5820 (arm_insert_point, arm_remove_point): Use for_each_thread.
5821
5822 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5823
5824 * win32-low.c (continue_one_thread): Return void, take argument
5825 directly.
5826 (child_continue): Use for_each_thread.
5827
5828 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5829
5830 * win32-i386-low.c (update_debug_registers_callback): Rename
5831 to ...
5832 (update_debug_registers): ... this, return void, remove pid_p arg.
5833 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
5834
5835 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5836
5837 * inferiors.h (struct process_info): Add constructor, initialize
5838 fields..
5839 <syscalls_to_catch>: Change type to std::vector<int>.
5840 * inferiors.c (add_process): Allocate process_info with new.
5841 (remove_process): Free process_info with delete.
5842 * linux-low.c (handle_extended_wait): Adjust.
5843 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
5844 * server.c (handle_general_set): Adjust.
5845
5846 2017-11-16 Pedro Alves <palves@redhat.com>
5847
5848 * remote-utils.c (remote_close): Block SIGIO signals instead of
5849 uninstalling the SIGIO handler.
5850
5851 2017-11-16 Alan Hayward <alan.hayward@arm.com>
5852
5853 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
5854
5855 2017-11-16 Yao Qi <yao.qi@linaro.org>
5856
5857 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
5858 (tic6x_store_gregset): Likewise.
5859 (tic6x_usrregs_info): Move it up.
5860
5861 2017-11-15 Alan Hayward <alan.hayward@arm.com>
5862
5863 * Makefile.in: Update arch rules.
5864 * configure.srv: Explicitly mark arch/ files.
5865
5866 2017-11-13 Andreas Schwab <schwab@suse.de>
5867
5868 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
5869 function.
5870 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5871
5872 2017-11-06 Pedro Alves <palves@redhat.com>
5873
5874 * config.in, configure: Regenerate.
5875
5876 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
5877
5878 * target.c (struct thread_search): Remove.
5879 (thread_search_callback): Remove.
5880 (prepare_to_access_memory): Use for_each_thread instead of
5881 find_inferior. Inline code from thread_search_callback.
5882
5883 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
5884
5885 * server.c (struct visit_actioned_threads_data): Remove.
5886 (visit_actioned_threads): Change prototype to take arguments
5887 directly.
5888 (resume): Use find_thread instead of find_inferior.
5889
5890 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
5891
5892 * server.c (queue_stop_reply_callback): Change prototype, return
5893 void.
5894 (find_status_pending_thread_callback): Remove.
5895 (handle_status): Replace find_inferior with find_thread and
5896 for_each_thread.
5897
5898 2017-10-25 Alan Hayward <alan.hayward@arm.com>
5899
5900 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
5901 with REGNO.
5902 (aarch64_store_gregset): Likewise.
5903 (aarch64_fill_fpregset): Likewise.
5904 (aarch64_store_fpregset): Likewise.
5905
5906 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
5907
5908 * gdbthread.h (find_thread, for_each_thread): New functions.
5909 * inferiors.c (thread_of_pid): Remove.
5910 (find_any_thread_of_pid): Use find_thread.
5911 * linux-low.c (num_lwps): Use for_each_thread.
5912
5913 2017-10-17 Yao Qi <yao.qi@linaro.org>
5914
5915 * Makefile.in: Remove one rule.
5916 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
5917
5918 2017-10-17 Yao Qi <yao.qi@linaro.org>
5919
5920 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
5921 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
5922
5923 2017-10-17 Yao Qi <yao.qi@linaro.org>
5924
5925 * configure.srv: Rename arm.o with arch/arm.o.
5926
5927 2017-10-17 Yao Qi <yao.qi@linaro.org>
5928
5929 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
5930 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
5931 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
5932 (arch-i386.o, arch-amd64.o): Remove rules.
5933 (arch/%.o): New rule.
5934 Update POSTCOMPILE and COMPILE.pre.
5935 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5936 * configure: Re-generated.
5937 * configure.srv: Replace arch-i386.o with arch/i386.o.
5938 Replace arch-amd64.o with arch/amd64.o.
5939
5940 2017-10-16 Yao Qi <yao.qi@linaro.org>
5941
5942 * configure: Regenerated.
5943
5944 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5945
5946 * inferiors.h: (struct inferior_list): Remove.
5947 (struct inferior_list_entry); Remove.
5948 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
5949 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
5950 get_first_inferior): Remove.
5951 (for_each_inferior, for_each_inferior_with_data, find_inferior,
5952 find_inferior_id, find_inferior_in_random): Change signature.
5953 * inferiors.c (all_threads): Change type to
5954 std::list<thread_info *>.
5955 (get_thread): Remove macro.
5956 (find_inferior, find_inferior_id): Change signature, implement
5957 using find_thread.
5958 (find_inferior_in_random): Change signature, implement using
5959 find_thread_in_random.
5960 (for_each_inferior, for_each_inferior_with_data): Change
5961 signature, implement using for_each_thread.
5962 (add_inferior_to_list, remove_inferior): Remove.
5963 (add_thread, get_first_thread, thread_of_pid,
5964 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
5965 (get_first_inferior, one_inferior_p, clear_inferior_list):
5966 Remove.
5967 (clear_inferiors, get_thread_process): Update.
5968 * gdbthread.h: Include <list>.
5969 (struct thread_info) <entry>: Remove field.
5970 <id>: New field.
5971 (all_threads): Change type to std::list<thread_info *>.
5972 (get_first_inferior): Add doc.
5973 (find_thread, for_each_thread, find_thread_in_random): New
5974 functions.
5975 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
5976 * linux-arm-low.c (update_registers_callback): Update.
5977 * linux-low.c (second_thread_of_pid_p): Update.
5978 (kill_one_lwp_callback, linux_detach_lwp_callback,
5979 delete_lwp_callback, status_pending_p_callback, same_lwp,
5980 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
5981 iterate_over_lwps, not_stopped_callback,
5982 resume_stopped_resumed_lwps, count_events_callback,
5983 select_singlestep_lwp_callback, select_event_lwp_callback,
5984 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
5985 suspend_and_send_sigstop_callback, wait_for_sigstop,
5986 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
5987 lwp_running, linux_set_resume_request, resume_status_pending_p,
5988 need_step_over_p, start_step_over, linux_resume_one_thread,
5989 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
5990 reset_lwp_ptrace_options_callback): Update.
5991 * linux-mips-low.c (update_watch_registers_callback): Update.
5992 * regcache.c (regcache_invalidate_one, regcache_invalidate):
5993 Update.
5994 (free_register_cache_thread_one): Remove.
5995 (regcache_release): Update.
5996 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
5997 handle_qxfer_threads_worker): Update.
5998 (handle_query): Update, use list iterator.
5999 (visit_actioned_threads, handle_pending_status,
6000 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6001 clear_pending_status_callback, set_pending_status_callback,
6002 find_status_pending_thread_callback, handle_status,
6003 process_serial_event): Update.
6004 * target.c (thread_search_callback): Update.
6005 * thread-db.c (thread_db_get_tls_address): Update.
6006 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6007 Update.
6008 * win32-i386-low.c (update_debug_registers_callback): Update.
6009 * win32-low.c (delete_thread_info, child_delete_thread,
6010 continue_one_thread, suspend_one_thread,
6011 get_child_debug_event): Adjust.
6012
6013 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6014
6015 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6016 * inferiors.h: Include <list>.
6017 (struct process_info) <entry>: Remove field.
6018 <pid>: New field.
6019 (pid_of): Change macro to function.
6020 (ptid_of, lwpid_of): Remove macro.
6021 (all_processes): Change type to std::list<process_info *>.
6022 (ALL_PROCESSES): Remove macro.
6023 (for_each_process, find_process): New function.
6024 * inferiors.c (all_processes): Change type to
6025 std::list<process_info *>.
6026 (find_thread_process): Adjust.
6027 (add_process): Likewise.
6028 (remove_process): Likewise.
6029 (find_process_pid): Likewise.
6030 (get_first_process): Likewise.
6031 (started_inferior_callback): Remove.
6032 (have_started_inferiors_p): Adjust.
6033 (attached_inferior_callback): Remove.
6034 (have_attached_inferiors_p): Adjust.
6035 * linux-low.c (check_zombie_leaders): Likewise.
6036 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6037 (x86_linux_update_xmltarget): Adjust.
6038 * server.c (handle_query): Likewise.
6039 (gdb_reattached_process): Remove.
6040 (handle_status): Adjust.
6041 (kill_inferior_callback): Likewise.
6042 (detach_or_kill_inferior): Remove.
6043 (print_started_pid): Likewise.
6044 (print_attached_pid): Likewise.
6045 (detach_or_kill_for_exit): Update.
6046 (process_serial_event): Likewise.
6047 * linux-arm-low.c (arm_new_fork): Likewise.
6048
6049 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6050
6051 * dll.h: Include <list>.
6052 (struct dll_info): Add constructor.
6053 <entry>: Remove field.
6054 (all_dlls): Change type to std::list<dll_info>.
6055 * dll.c: Include <algorithm>.
6056 (get_dll): Remove macro.
6057 (all_dlls): Change type to std::list<dll_info *>.
6058 (free_one_dll): Remove.
6059 (match_dll): Likewise.
6060 (loaded_dll): Adjust.
6061 (unloaded_dll): Adjust to all_dlls type change, use
6062 std::find_if. Inline code from match_dll.
6063 (clear_dlls): Adjust to all_dlls type change.
6064 * server.c (emit_dll_description): Remove.
6065 (handle_qxfer_libraries): Adjust to all_dlls type change,
6066 integrate emit_dll_description's functionality.
6067
6068 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6069
6070 * linux-low.h (struct linux_target_ops) <delete_process>: New
6071 field.
6072 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6073 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6074 (struct linux_target_ops): Add delete_process callback.
6075 * linux-arm-low.c (arm_delete_process): New.
6076 (struct linux_target_ops): Add delete_process callback.
6077 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6078 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6079 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6080 * linux-mips-low.c (mips_linux_delete_process): New.
6081 (struct linux_target_ops): Add delete_process callback.
6082 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6083 * linux-s390-low.c (struct linux_target_ops): Likewise.
6084 * linux-sh-low.c (struct linux_target_ops): Likewise.
6085 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6086 * linux-tile-low.c (struct linux_target_ops): Likewise.
6087 * linux-x86-low.c (x86_linux_delete_process): New.
6088 (struct linux_target_ops): Add delete_process callback.
6089 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6090
6091 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6092
6093 * linux-aarch64-low.c (the_low_target): Add thread delete
6094 callback.
6095 * linux-arm-low.c (arm_delete_thread): New function.
6096 (the_low_target): Add thread delete callback.
6097 * linux-bfin-low.c (the_low_target): Likewise.
6098 * linux-crisv32-low.c (the_low_target): Likewise.
6099 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6100 set.
6101 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6102 field.
6103 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6104 * linux-mips-low.c (mips_linux_delete_thread): New function.
6105 (the_low_target): Add thread delete callback.
6106 * linux-ppc-low.c (the_low_target): Likewise.
6107 * linux-s390-low.c (the_low_target): Likewise.
6108 * linux-sh-low.c (the_low_target): Likewise.
6109 * linux-tic6x-low.c (the_low_target): Likewise.
6110 * linux-tile-low.c (the_low_target): Likewise.
6111 * linux-x86-low.c (the_low_target): Likewise.
6112 * linux-xtensa-low.c (the_low_target): Likewise.
6113
6114 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6115
6116 * win32-low.c: Include "common-inferior.h".
6117
6118 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6119
6120 * inferiors.c (set_inferior_cwd): New function.
6121 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6122 (handle_query): Inform that QSetWorkingDir is supported.
6123 * win32-low.c (create_process): Pass the inferior's cwd to
6124 CreateProcess.
6125
6126 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6127
6128 * inferiors.c (current_inferior_cwd): New global variable.
6129 (get_inferior_cwd): New function.
6130 * inferiors.h (struct process_info) <cwd>: New field.
6131
6132 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6133
6134 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6135 (OBS): Add gdb_tilde_expand.o.
6136
6137 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6138
6139 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6140 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6141
6142 2017-09-29 Pedro Alves <palves@redhat.com>
6143
6144 * ax.c (gdb_parse_agent_expr): Constify.
6145 * ax.h (gdb_parse_agent_expr): Constify.
6146 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6147 Constify.
6148 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6149 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6150 * remote-utils.h (read_ptid): Constify.
6151 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6152 (process_point_options, process_serial_event): Constify.
6153 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6154 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6155 (cmd_qtbuffer): Constify.
6156
6157 2017-09-29 Pedro Alves <palves@redhat.com>
6158
6159 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6160 fails.
6161
6162 2017-09-29 Pedro Alves <palves@redhat.com>
6163
6164 * linux-low.c (handle_extended_wait): Pass parent thread instead
6165 of process to thread_db_notice_clone.
6166 * linux-low.h (thread_db_notice_clone): Replace parent process
6167 parameter with parent thread parameter.
6168 * thread-db.c (find_one_thread): Add comment.
6169 (thread_db_notice_clone): Replace parent process parameter with
6170 parent thread parameter. Temporarily switch to the parent thread.
6171
6172 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6173
6174 * gdbthread.h: Include "common-gdbthread.h".
6175 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6176 "if" when validating the ptid.
6177 * remote-utils.c: Include "gdbthread.h".
6178 (prepare_resume_reply): Use "switch_to_thread".
6179 * target.c (done_accessing_memory): Likewise.
6180
6181 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6182
6183 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6184 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6185 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6186 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6187 s390x-gs-linux64-ipa.o to ipa_obj.
6188 * linux-s390-low.c (HWCAP_S390_GS): New define.
6189 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6190 New functions.
6191 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6192 (s390_arch_setup): Check for guarded-storage support and choose
6193 appropriate tdesc.
6194 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6195 init_registers_s390x_gs_linux64.
6196 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6197 enum value.
6198 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6199 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6200
6201 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6202
6203 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6204
6205 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6206
6207 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6208 (thread_db_thread_handle): Declare.
6209 * linux-low.c (linux_target_ops): Initialize thread_handle.
6210 * server.c (handle_qxfer_threads_worker): Add support for
6211 "handle" attribute.
6212 * target.h (struct target_ops): Add new function pointer,
6213 thread_handle.
6214 (target_thread_handle): Define.
6215 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6216 field in lwp.
6217 (thread_db_thread_handle): New function.
6218
6219 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6220
6221 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6222 * linux-low.h (thread_db_notice_clone): Declare.
6223 * thread-db.c (thread_db_notice_clone): New function.
6224
6225 2017-09-21 Pedro Alves <palves@redhat.com>
6226
6227 * server.c (gdb_read_memory, handle_status, process_serial_event)
6228 (handle_serial_event, handle_target_event): Adjust to
6229 set_desired_thread prototype change.
6230 * target.c (set_desired_thread): Remove 'use_general' parameter
6231 and adjust.
6232 * target.h (set_desired_thread): Remove 'use_general' parameter.
6233
6234 2017-09-20 Tom Tromey <tom@tromey.com>
6235
6236 * target.c (target_terminal::terminal_state): Define.
6237 (target_terminal::init): Rename from target_terminal_init.
6238 (target_terminal::inferior): Rename from
6239 target_terminal_inferior.
6240 (target_terminal::ours): Rename from target_terminal_ours.
6241 (target_terminal::ours_for_output, target_terminal::info): New.
6242
6243 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6244
6245 * server.c (accumulate_file_name_length): Remove.
6246 (emit_dll_description): Adjust to std::string change.
6247 (handle_qxfer_libraries): Use std::string to hold document.
6248
6249 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6250
6251 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6252 return type of xml_escape_text.
6253 * server.c (emit_dll_description): Likewise.
6254
6255 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6256
6257 * server.c (captured_main): Accept argument for --selftest.
6258 Update run_tests call.
6259 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6260 when registering selftests.
6261
6262 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6263
6264 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6265 instead of "VEC" for "target_desc.reg_defs".
6266 (regcache_cpy): Likewise.
6267 (registers_to_string): Likewise.
6268 (registers_from_string): Likewise.
6269 (find_regno): Likewise.
6270 (supply_regblock): Likewise.
6271 (regcache_raw_read_unsigned): Likewise.
6272 * tdesc.c (init_target_desc): Likewise.
6273 (tdesc_create_reg): Likewise.
6274 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6275 (struct target_desc) <reg_defs>: Convert to "std::vector".
6276 (target_desc): Do not initialize "reg_defs".
6277 (~target_desc): Update code to use "std::vector" instead of "VEC"
6278 for "target_desc.reg_defs".
6279 (operator==): Likewise.
6280
6281 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6282
6283 * inferiors.h (thread_to_gdb_id): Remove.
6284 * inferiors.c (thread_to_gdb_id): Remove.
6285 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6286 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6287 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6288 Likewise.
6289 * nto-low.c (nto_fetch_registers, nto_store_registers,
6290 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6291
6292 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6293
6294 * inferiors.h (gdb_id_to_thread_id): Remove.
6295 * inferiors.c (gdb_id_to_thread_id): Remove.
6296 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6297 removal. Move pid declaration closer to where it's used.
6298
6299 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6300
6301 * server.c (handle_detach): New function.
6302 (process_serial_event): Move code out, call handle_detach.
6303
6304 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6305
6306 * server.c (require_running): Rename to ...
6307 (require_running_or_return): ... this ...
6308 (require_running_or_break): ... and this.
6309 (handle_query, process_serial_event): Adjust.
6310
6311 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6312
6313 * linux-low.c (linux_set_resume_request): Remove unused
6314 variables.
6315
6316 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6317
6318 * server.c (first_thread_of): Remove.
6319 (process_serial_event): Replace usage of first_thread_of with
6320 find_any_thread_of_pid.
6321 * tracepoint.c (same_process_p): Remove.
6322 (gdb_agent_about_to_close): Replace usage of same_process_p with
6323 find_any_thread_of_pid.
6324 * linux-x86-low.c (same_process_callback): Remove.
6325 (x86_arch_setup_process_callback): Replace usage of
6326 same_process_callback with find_any_thread_of_pid.
6327 * thread-db.c (any_thread_of): Remove.
6328 (switch_to_process): Replace usage of any_thread_of with
6329 find_any_thread_of_pid.
6330 * inferiors.c (thread_pid_matches_callback): Remove.
6331 (find_thread_process): Adjust to use find_any_thread_of_pid.
6332
6333 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6334
6335 * regcache.c (get_thread_regcache): Guard calls to "memset"
6336 with "!VEC_empty".
6337
6338 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6339
6340 * linux-low.c (handle_extended_wait): Use
6341 "allocate_target_description" instead of "XNEW".
6342 * linux-x86-low.c (initialize_low_arch): Likewise.
6343
6344 2017-09-05 Yao Qi <yao.qi@linaro.org>
6345
6346 * configure.srv (srv_i386_regobj): Remove.
6347 (srv_amd64_regobj): Remove.
6348 (srv_regobj): Set it to "" for x86 non-linux targets.
6349 * linux-x86-tdesc.c (i386_linux_read_description):
6350 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6351 (init_registers_i386): Remove the declaration.
6352 (tdesc_i386): Remove the declaration.
6353 (lynx_i386_arch_setup): Call i386_create_target_description.
6354 * nto-x86-low.c: Likewise.
6355 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6356 [!__x86_64__]: include arch/i386.h.
6357 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6358
6359 2017-09-05 Yao Qi <yao.qi@linaro.org>
6360
6361 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6362 i386/amd64-XXX-linux from it.
6363
6364 2017-09-05 Yao Qi <yao.qi@linaro.org>
6365
6366 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6367 false.
6368 (ipa_amd64_linux_regobj): Remove.
6369 (ipa_x32_linux_regobj): Remove.
6370
6371 2017-09-05 Yao Qi <yao.qi@linaro.org>
6372
6373 * Makefile.in (arch-amd64.o): New rule.
6374 * configure.srv: Append arch-amd64.o.
6375 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6376 (get_ipa_tdesc): Call amd64_linux_read_description.
6377 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6378 and init_registers_amd64_XXX.
6379 * linux-x86-low.c (x86_linux_read_description): Call
6380 amd64_linux_read_description.
6381 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6382 (initialize_low_arch): Don't call init_registers_x32_XXX and
6383 init_registers_amd64_XXX.
6384 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6385 and tdesc_amd64_XXX.
6386 [__x86_64__] (amd64_tdesc_test): New function.
6387 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6388 and init_registers_amd64_XXX.
6389 * linux-x86-tdesc.c: Include arch/amd64.h.
6390 (xcr0_to_tdesc_idx): New function.
6391 (i386_linux_read_description): New function.
6392 (amd64_get_ipa_tdesc_idx): New function.
6393 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6394 (amd64_get_ipa_tdesc): Declare.
6395
6396 2017-09-05 Yao Qi <yao.qi@linaro.org>
6397
6398 * configure.srv (srv_i386_linux_xmlfiles): Remove
6399 i386/i386-XXX-linux.xml from it.
6400
6401 2017-09-05 Yao Qi <yao.qi@linaro.org>
6402
6403 * configure.srv: Set srv_i386_linux_regobj empty if $development
6404 is false.
6405 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6406 initialize_low_tdesc.
6407 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6408 with #if initialize_low_tdesc.
6409 * linux-x86-tdesc-selftest.c: New file.
6410 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6411
6412 2017-09-05 Yao Qi <yao.qi@linaro.org>
6413
6414 * Makefile.in (arch-i386.o): New rule.
6415 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6416 (x86_64-*-linux*): Likewise.
6417 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6418 include arch/i386.h.
6419 (i386_linux_read_description): Remove code and call
6420 i386_create_target_description.
6421 * tdesc.c (allocate_target_description): New function.
6422 * tdesc.h (set_tdesc_architecture): Remove declaration.
6423 (set_tdesc_osabi): Likewise.
6424
6425 2017-09-05 Yao Qi <yao.qi@linaro.org>
6426
6427 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6428 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6429 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6430 .xmltarget.
6431 * server.c (get_features_xml): Call tdesc_get_features_xml.
6432 * tdesc.c (set_tdesc_architecture): New function.
6433 (set_tdesc_osabi): New function.
6434 (tdesc_get_features_xml): New function.
6435 (tdesc_create_feature): Add an argument.
6436 * tdesc.h (struct target_desc) <features>: New field.
6437 <arch, osabi>: New field.
6438 (~target_desc): xfree features, arch, and osabi.
6439 (target_desc::oerator==): Don't compare .xmltarget.
6440 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6441 (set_tdesc_osabi): Likewise.
6442 (tdesc_get_features_xml): Likewise.
6443
6444 2017-09-05 Yao Qi <yao.qi@linaro.org>
6445
6446 * linux-x86-tdesc.c: Include selftest.h.
6447 (i386_tdesc_test): New function.
6448 (initialize_low_tdesc): Call selftests::register_test.
6449 * tdesc.h: Include regdef.h.
6450 (target_desc): Override operator == and !=.
6451
6452 2017-09-05 Yao Qi <yao.qi@linaro.org>
6453
6454 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6455 (ipa_obj): Likewise.
6456 * linux-i386-ipa.c: Include common/x86-xstate.h
6457 (get_ipa_tdesc): Call i386_linux_read_description.
6458 (initialize_low_tracepoint): Don't call init_registers_XXX
6459 functions, call initialize_low_tdesc instead.
6460 * linux-x86-low.c (x86_linux_read_description): Call
6461 i386_linux_read_description.
6462 (initialize_low_arch): Don't call init_registers_i386_XXX
6463 functions, call initialize_low_tdesc.
6464 * linux-x86-tdesc.c: New file.
6465 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6466 (i386_get_ipa_tdesc_idx): Declare.
6467 (i386_get_ipa_tdesc): Declare.
6468 (initialize_low_tdesc): Declare.
6469
6470 2017-09-05 Yao Qi <yao.qi@linaro.org>
6471
6472 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6473 instead of 0.
6474
6475 2017-09-05 Yao Qi <yao.qi@linaro.org>
6476
6477 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6478 * regcache.c (get_thread_regcache): Use VEC_length.
6479 (init_register_cache): Likewise.
6480 (regcache_cpy): Likewise.
6481 (registers_to_string): Iterate reg_defs via VEC_iterate.
6482 (find_regno): Likewise.
6483 (find_register_by_number): Use VEC_index.
6484 (register_size): Call find_register_by_number.
6485 (register_data): Call find_register_by_number.
6486 (supply_regblock): Use VEC_length.
6487 (regcache_raw_read_unsigned): Likewise.
6488 * tdesc.c (init_target_desc): Iterate reg_defs via
6489 VEC_iterate.
6490 (default_description): Update initializer.
6491 (copy_target_description): Don't update field num_registers.
6492 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6493 <num_registers>: Remove.
6494
6495 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6496
6497 * Makefile.in (.SECONDARY): Define target.
6498
6499 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6500
6501 * linux-low.c (linux_wait_1): Adjust.
6502 * server.c (queue_stop_reply_callback): Adjust.
6503
6504 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6505
6506 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6507 QEnvironmentUnset and QEnvironmentReset packets.
6508 (handle_query): Inform remote that QEnvironmentHexEncoded,
6509 QEnvironmentUnset and QEnvironmentReset are supported.
6510
6511 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6512
6513 * inferiors.h (inferior_target_data): Rename to ...
6514 (thread_target_data): ... this.
6515 (inferior_regcache_data): Rename to ...
6516 (thread_regcache_data): ... this.
6517 (set_inferior_regcache_data): Rename to ...
6518 (set_thread_regcache_data): ... this.
6519 * inferiors.c (inferior_target_data): Rename to ...
6520 (thread_target_data): ... this.
6521 (inferior_regcache_data): Rename to ...
6522 (thread_regcache_data): ... this.
6523 (set_inferior_regcache_data): Rename to ...
6524 (set_thread_regcache_data): ... this.
6525 (free_one_thread): Update.
6526 * linux-low.h (get_thread_lwp): Update.
6527 * regcache.c (get_thread_regcache): Update.
6528 (regcache_invalidate_thread): Update.
6529 (free_register_cache_thread): Update.
6530 * win32-i386-low.c (update_debug_registers_callback): Update.
6531 (win32_get_current_dr): Update.
6532 * win32-low.c (thread_rec): Update.
6533 (delete_thread_info): Update.
6534 (continue_one_thread): Update.
6535 (suspend_one_thread): Update.
6536
6537 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6538
6539 * inferiors.c (set_inferior_target_data): Remove.
6540 * inferiors.h (set_inferior_target_data): Remove.
6541
6542 2017-08-18 Yao Qi <yao.qi@linaro.org>
6543
6544 * Makefile.in (OBS): Add selftest.o.
6545 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6546 * configure, config.in: Re-generated.
6547 * server.c: Include common/sefltest.h.
6548 (captured_main): Handle option --selftest.
6549
6550 2017-08-09 Yao Qi <yao.qi@linaro.org>
6551
6552 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6553 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6554 i386-avx-mpx.o and i386-mmx.o.
6555 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6556 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6557 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6558 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6559 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6560 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6561 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6562 i386/amd64-avx-mpx.xml.
6563
6564 2017-08-09 Yao Qi <yao.qi@linaro.org>
6565
6566 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6567 and x32-avx-avx512.o.
6568 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6569 i386/x32-avx-avx512.xml.
6570
6571 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6572
6573 * tracepoint.h (enum class fast_tpoint_collect_result): New
6574 enumeration.
6575 (fast_tracepoint_collecting): Change return type to
6576 fast_tpoint_collect_result.
6577 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6578 * linux-low.h: Include tracepoint.h.
6579 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6580 fast_tpoint_collect_result.
6581 * linux-low.c (handle_tracepoints): Adjust.
6582 (linux_fast_tracepoint_collecting): Change return type to
6583 fast_tpoint_collect_result.
6584 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6585 linux_wait_1, stuck_in_jump_pad_callback,
6586 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6587 proceed_one_lwp): Adjust to type change.
6588
6589 2017-07-10 Yao Qi <yao.qi@linaro.org>
6590
6591 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6592
6593 2017-06-29 Yao Qi <yao.qi@linaro.org>
6594
6595 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6596 Remove.
6597 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6598
6599 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6600
6601 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6602
6603 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6604
6605 * linux-low.c (linux_create_inferior): Adjust code to access the
6606 environment information via 'gdb_environ' class.
6607 * lynx-low.c (lynx_create_inferior): Likewise.
6608 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6609 (get_environ): Return a pointer to 'our_environ'.
6610 (captured_main): Initialize 'our_environ'.
6611 * server.h (get_environ): Adjust prototype.
6612 * spu-low.c (spu_create_inferior): Adjust code to access the
6613 environment information via 'gdb_environ' class.
6614
6615 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6616
6617 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6618 usage of "register" keyword.
6619
6620 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6621
6622 * configure: Re-generate.
6623
6624 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6625
6626 * configure: Re-generate.
6627
6628 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6629
6630 * Makefile.in (COMPILE.pre): Add "-x c++".
6631
6632 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6633
6634 * fork-child.c: Conditionally include <signal.h>.
6635
6636 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6637
6638 * server.c (handle_general_set): Handle new packet
6639 "QStartupWithShell".
6640 (handle_query): Add "QStartupWithShell" to the list of supported
6641 packets.
6642 (gdbserver_usage): Add help text explaining the
6643 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6644 options.
6645 (captured_main): Recognize and act upon the presence of the new
6646 CLI options.
6647
6648 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6649 Pedro Alves <palves@redhat.com>
6650
6651 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6652 * configure: Regenerate.
6653 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6654 "fork-inferior.o".
6655 (i[34567]86-*-lynxos*): Likewise.
6656 (spu*-*-*): Likewise.
6657 * fork-child.c: New file.
6658 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6659 and "environ.h".
6660 (linux_ptrace_fun): New function.
6661 (linux_create_inferior): Adjust function prototype to reflect
6662 change on "target.h". Adjust function code to use
6663 "fork_inferior".
6664 (linux_request_interrupt): Delete "signal_pid".
6665 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6666 (lynx_ptrace_fun): New function.
6667 (lynx_create_inferior): Adjust function prototype to reflect
6668 change on "target.h". Adjust function code to use
6669 "fork_inferior".
6670 * nto-low.c (nto_create_inferior): Adjust function prototype and
6671 code to reflect change on "target.h". Update comments.
6672 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6673 "common-terminal.h" and "environ.h".
6674 (terminal_fd): Moved to fork-child.c.
6675 (old_foreground_pgrp): Likewise.
6676 (restore_old_foreground_pgrp): Likewise.
6677 (last_status): Make it global.
6678 (last_ptid): Likewise.
6679 (our_environ): New variable.
6680 (startup_with_shell): Likewise.
6681 (program_name): Likewise.
6682 (program_argv): Rename to...
6683 (program_args): ...this.
6684 (wrapper_argv): New variable.
6685 (start_inferior): Delete function.
6686 (get_exec_wrapper): New function.
6687 (get_exec_file): Likewise.
6688 (get_environ): Likewise.
6689 (prefork_hook): Likewise.
6690 (post_fork_inferior): Likewise.
6691 (postfork_hook): Likewise.
6692 (postfork_child_hook): Likewise.
6693 (handle_v_run): Update code to deal with arguments coming from the
6694 remote host. Update calls from "start_inferior" to
6695 "create_inferior".
6696 (captured_main): Likewise. Initialize environment variable. Call
6697 "have_job_control".
6698 * server.h (post_fork_inferior): New prototype.
6699 (get_environ): Likewise.
6700 (last_status): Declare.
6701 (last_ptid): Likewise.
6702 (signal_pid): Likewise.
6703 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6704 (spu_ptrace_fun): New function.
6705 (spu_create_inferior): Adjust function prototype to reflect change
6706 on "target.h". Adjust function code to use "fork_inferior".
6707 * target.c (target_terminal_init): New function.
6708 (target_terminal_inferior): Likewise.
6709 (target_terminal_ours): Likewise.
6710 * target.h: Include <vector>.
6711 (struct target_ops) <create_inferior>: Update prototype.
6712 (create_inferior): Update macro.
6713 * utils.c (gdb_flush_out_err): New function.
6714 * win32-low.c (win32_create_inferior): Adjust function prototype
6715 and code to reflect change on "target.h".
6716
6717 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6718
6719 * inferiors.c (switch_to_thread): New function.
6720
6721 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6722
6723 * Makefile.in (SFILE): Add "common/job-control.c".
6724 (OBS): Add "job-control.o".
6725
6726 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6727
6728 * Makefile: Remove "@host_makefile_frag@".
6729
6730 2017-05-05 Pedro Alves <palves@redhat.com>
6731
6732 * configure: Regenerate.
6733
6734 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6735
6736 * configure: Regenerate.
6737
6738 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6739
6740 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
6741 software_single_step change of return type to
6742 std::vector<CORE_ADDR>.
6743 * linux-low.c (install_software_single_step_breakpoints):
6744 Likewise.
6745 * linux-low.h (install_software_single_step_breakpoints):
6746 Likewise.
6747
6748 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6749
6750 * remote-utils.c: Include "gdb_termios.h" instead of
6751 "terminal.h".
6752 * terminal.h: Delete file.
6753
6754 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6755
6756 * server.c: Include <vector>.
6757 <program_argv, wrapper_argv>: Convert to std::vector.
6758 (start_inferior): Rewrite function to use C++.
6759 (handle_v_run): Likewise. Update code that calculates the argv
6760 based on the vRun packet; use C++.
6761 (captured_main): Likewise.
6762
6763 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
6764
6765 * server.c (handle_v_cont): Initialize thread_resume::thread
6766 with null_ptid.
6767
6768 2017-04-05 Pedro Alves <palves@redhat.com>
6769
6770 * configure: Regenerate.
6771
6772 2017-04-05 Pedro Alves <palves@redhat.com>
6773
6774 * gdbreplay.c (sync_error): Constify.
6775 * linux-x86-low.c (push_opcode): Constify.
6776
6777 2017-04-05 Pedro Alves <palves@redhat.com>
6778
6779 * win32-low.c (get_child_debug_event)
6780 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
6781 Report TARGET_WAITKIND_SPURIOUS instead.
6782
6783 2017-04-05 Pedro Alves <palves@redhat.com>
6784
6785 * remote-utils.c (remote_prepare, remote_open): Constify.
6786 * remote-utils.h (remote_prepare, remote_open): Constify.
6787 * server.c (captured_main): Constify 'port' handling.
6788
6789 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
6790
6791 * Makefile.in (clean): Clear .deps.
6792
6793 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
6794
6795 * .gitignore: Remove generated files, replace with wildcard.
6796 * (clean): Replace removal of generated files with wildcard.
6797 (version.c): Replace with...
6798 (version-generated.c): ...this.
6799 (xml-builtin.c): Replace with...
6800 (xml-builtin-generated.c): ...this.
6801 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
6802 (%.c: *regformats*): Replace with...
6803 (%-generated.c: *regformats*): ...this.
6804
6805 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
6806
6807 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
6808 (xtensa_fill_gregset): Call collect_register_by_name for
6809 threadptr register.
6810 (xtensa_store_gregset): Call supply_register_by_name for
6811 threadptr register.
6812
6813 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
6814
6815 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
6816 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
6817 (xtensa_store_gregset): Call supply_register for all registers in
6818 a0_regnum..a0_regnum + C0_NREGS range.
6819
6820 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6821
6822 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
6823 (ax-ipa.o: ax.c): Remove.
6824 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
6825 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
6826 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
6827 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
6828 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
6829
6830 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6831
6832 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
6833 (print-utils-ipa.o: ../common/print-utils.c): Remove.
6834 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
6835 (errors-ipa.o: ../common/errors.c): Remove.
6836 (format-ipa.o: ../common/format.c): Remove.
6837 (common-utils-ipa.o: ../common/common-utils.c): Remove.
6838
6839 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6840
6841 * Makefile.in (%-ipa.o: %.c): New rule.
6842 (tracepoint-ipa.o: tracepoint.c): Remove.
6843 (utils-ipa.o: utils.c): Remove.
6844 (remote-utils-ipa.o: remote-utils.c): Remove.
6845 (regcache-ipa.o: regcache.c): Remove.
6846 (i386-linux-ipa.o: i386-linux.c): Remove.
6847 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
6848 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
6849 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
6850 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
6851 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
6852 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
6853 (amd64-linux-ipa.o: amd64-linux.c): Remove.
6854 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
6855 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
6856 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
6857 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
6858 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
6859 (aarch64-ipa.o: aarch64.c): Remove.
6860 (s390-linux32-ipa.o: s390-linux32.c): Remove.
6861 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
6862 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
6863 (s390-linux64-ipa.o: s390-linux64.c): Remove.
6864 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
6865 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
6866 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
6867 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
6868 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
6869 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
6870 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
6871 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
6872 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
6873 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
6874 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
6875 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
6876 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
6877 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
6878 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
6879 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
6880 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
6881 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
6882 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
6883 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
6884 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
6885 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
6886 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
6887 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
6888 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
6889 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
6890 (tdesc-ipa.o: tdesc.c): Remove.
6891 (x32-linux-ipa.o: x32-linux.c): Remove.
6892 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
6893 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
6894
6895 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6896
6897 * Makefile.in (%.o: ../arch/%.c): New rule.
6898 (arm.o: ../arch/arm.c): Remove.
6899 (arm-linux.o: ../arch/arm-linux.c): Remove.
6900 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
6901 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
6902
6903 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6904
6905 * Makefile.in (%.o: ../nat/%.c): New rule.
6906 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
6907 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
6908 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
6909 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
6910 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
6911 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
6912 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
6913 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
6914 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
6915 (linux-personality.o: ../nat/linux-personality.c): Remove.
6916 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
6917 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
6918 (x86-linux.o: ../nat/x86-linux.c): Remove.
6919 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
6920 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
6921
6922 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6923
6924 * Makefile.in (%.o: ../common/%.c): New rule.
6925 (signals.o: ../common/signals.c): Remove.
6926 (print-utils.o: ../common/print-utils.c): Remove.
6927 (rsp-low.o: ../common/rsp-low.c): Remove.
6928 (common-utils.o: ../common/common-utils.c): Remove.
6929 (posix-strerror.o: ../common/posix-strerror.c): Remove.
6930 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
6931 (vec.o: ../common/vec.c): Remove.
6932 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
6933 (xml-utils.o: ../common/xml-utils.c): Remove.
6934 (ptid.o: ../common/ptid.c): Remove.
6935 (buffer.o: ../common/buffer.c): Remove.
6936 (format.o: ../common/format.c): Remove.
6937 (filestuff.o: ../common/filestuff.c): Remove.
6938 (agent.o: ../common/agent.c): Remove.
6939 (errors.o: ../common/errors.c): Remove.
6940 (environ.o: ../common/environ.c): Remove.
6941 (common-debug.o: ../common/common-debug.c): Remove.
6942 (cleanups.o: ../common/cleanups.c): Remove.
6943 (common-exceptions.o: ../common/common-exceptions.c): Remove.
6944 (fileio.o: ../common/fileio.c): Remove.
6945 (common-regcache.o: ../common/common-regcache.c): Remove.
6946 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
6947 (new-op.o: ../common/new-op.c): Remove.
6948 (btrace-common.o: ../common/btrace-common.c): Remove.
6949
6950 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6951
6952 * Makefile.in (%.o: ../target/%.c): New rule.
6953 (waitstatus.o: ../target/waitstatus.c): Remove.
6954
6955 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6956
6957 * Makefile.in
6958 (%.c: ../regformats/%.dat,
6959 (%.c: ../regformats/arm/%.dat,
6960 (%.c: ../regformats/i386/%.dat,
6961 (%.c: ../regformats/rs6000/%.dat): New rules.
6962 (aarch64.c): Remove.
6963 (reg-arm.c): Remove.
6964 (arm-with-iwmmxt.c): Remove.
6965 (arm-with-vfpv2.c): Remove.
6966 (arm-with-vfpv3.c): Remove.
6967 (arm-with-neon.c): Remove.
6968 (reg-bfin.c): Remove.
6969 (reg-cris.c): Remove.
6970 (reg-crisv32.c): Remove.
6971 (i386.c): Remove.
6972 (i386-linux.c): Remove.
6973 (i386-avx.c): Remove.
6974 (i386-avx-linux.c): Remove.
6975 (i386-avx-avx512.c): Remove.
6976 (i386-avx-avx512-linux.c): Remove.
6977 (i386-mpx.c): Remove.
6978 (i386-mpx-linux.c): Remove.
6979 (i386-avx-mpx-avx512-pku.c): Remove.
6980 (i386-avx-mpx-avx512-pku-linux.c): Remove.
6981 (i386-avx-mpx.c): Remove.
6982 (i386-avx-mpx-linux.c): Remove.
6983 (i386-mmx.c): Remove.
6984 (i386-mmx-linux.c): Remove.
6985 (reg-ia64.c): Remove.
6986 (reg-m32r.c): Remove.
6987 (reg-m68k.c): Remove.
6988 (reg-cf.c): Remove.
6989 (mips-linux.c): Remove.
6990 (mips-dsp-linux.c): Remove.
6991 (mips64-linux.c): Remove.
6992 (mips64-dsp-linux.c): Remove.
6993 (nios2-linux.c): Remove.
6994 (powerpc-32.c): Remove.
6995 (powerpc-32l.c): Remove.
6996 (powerpc-altivec32l.c): Remove.
6997 (powerpc-cell32l.c): Remove.
6998 (powerpc-vsx32l.c): Remove.
6999 (powerpc-isa205-32l.c): Remove.
7000 (powerpc-isa205-altivec32l.c): Remove.
7001 (powerpc-isa205-vsx32l.c): Remove.
7002 (powerpc-e500l.c): Remove.
7003 (powerpc-64l.c): Remove.
7004 (powerpc-altivec64l.c): Remove.
7005 (powerpc-cell64l.c): Remove.
7006 (powerpc-vsx64l.c): Remove.
7007 (powerpc-isa205-64l.c): Remove.
7008 (powerpc-isa205-altivec64l.c): Remove.
7009 (powerpc-isa205-vsx64l.c): Remove.
7010 (s390-linux32.c): Remove.
7011 (s390-linux32v1.c): Remove.
7012 (s390-linux32v2.c): Remove.
7013 (s390-linux64.c): Remove.
7014 (s390-linux64v1.c): Remove.
7015 (s390-linux64v2.c): Remove.
7016 (s390-te-linux64.c): Remove.
7017 (s390-vx-linux64.c): Remove.
7018 (s390-tevx-linux64.c): Remove.
7019 (s390x-linux64.c): Remove.
7020 (s390x-linux64v1.c): Remove.
7021 (s390x-linux64v2.c): Remove.
7022 (s390x-te-linux64.c): Remove.
7023 (s390x-vx-linux64.c): Remove.
7024 (s390x-tevx-linux64.c): Remove.
7025 (tic6x-c64xp-linux.c): Remove.
7026 (tic6x-c64x-linux.c): Remove.
7027 (tic6x-c62x-linux.c): Remove.
7028 (reg-sh.c): Remove.
7029 (reg-sparc64.c): Remove.
7030 (reg-spu.c): Remove.
7031 (amd64.c): Remove.
7032 (amd64-linux.c): Remove.
7033 (amd64-avx.c): Remove.
7034 (amd64-avx-linux.c): Remove.
7035 (amd64-avx-avx512.c): Remove.
7036 (amd64-avx-avx512-linux.c): Remove.
7037 (amd64-mpx.c): Remove.
7038 (amd64-mpx-linux.c): Remove.
7039 (amd64-avx-mpx-avx512-pku.c): Remove.
7040 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7041 (amd64-avx-mpx.c): Remove.
7042 (amd64-avx-mpx-linux.c): Remove.
7043 (x32.c): Remove.
7044 (x32-linux.c): Remove.
7045 (x32-avx.c): Remove.
7046 (x32-avx-linux.c): Remove.
7047 (x32-avx-avx512.c): Remove.
7048 (x32-avx-avx512-linux.c): Remove.
7049 (reg-xtensa.c): Remove.
7050 (reg-tilegx.c): Remove.
7051 (reg-tilegx32.c): Remove.
7052
7053 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7054
7055 * Makefile.in (SFILES): Add "common/environ.c".
7056 (OBJS): Add "common/environ.h".
7057
7058 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7059
7060 * configure.ac: Check if the fs_base and gs_base members of
7061 `struct user_regs_struct' exist.
7062 * config.in: Regenerated.
7063 * configure: Likewise.
7064
7065 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7066
7067 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7068 target_read_memory.
7069 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7070 (get_next_pcs_syscall_next_pc): Likewise.
7071
7072 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7073
7074 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7075 * nto-x86-low.c: Likewise.
7076
7077 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7078
7079 * Makefile.in: Include disable-implicit-rules.mk.
7080
7081 2016-11-23 Pedro Alves <palves@redhat.com>
7082
7083 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7084 (debug_vprintf): Use std::chrono::steady_clock instead of
7085 gettimeofday. Use '.' instead of ':'.
7086 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7087 (get_timestamp): Use std::chrono::steady_clock instead of
7088 gettimeofday.
7089
7090 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7091
7092 * Makefile.in: Fix whitespace formatting.
7093
7094 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7095
7096 * Makefile.in (SFILES, OBS): Flatten list and order
7097 alphabetically.
7098
7099 2016-11-23 Pedro Alves <palves@redhat.com>
7100
7101 * event-loop.c (handle_file_event): Use warning.
7102 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7103 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7104 Use warning.
7105
7106 2016-11-23 Pedro Alves <palves@redhat.com>
7107
7108 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7109 output.
7110 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7111 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7112 debug_printf and debug_flush for debug output.
7113 * server.c (handle_general_set): Likewise.
7114 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7115 output.
7116
7117 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7118
7119 * Makefile.in (.c.o): Replace rule with ...
7120 (%.o: %.c): ... this one.
7121
7122 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7123
7124 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7125 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7126 make.
7127 * configure.ac: Remove checks for the make program.
7128 * configure: Re-generate.
7129
7130 2016-10-28 Pedro Alves <palves@redhat.com>
7131
7132 * Makefile.in (CXX_DIALECT): Get from configure.
7133 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7134 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7135 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7136 * config.in: Regenerate.
7137 * configure: Regenerate.
7138
7139 2016-10-27 Yao Qi <yao.qi@linaro.org>
7140
7141 * linux-low.c (linux_supports_range_stepping): Return true if
7142 can_software_single_step return true.
7143
7144 2016-10-27 Yao Qi <yao.qi@linaro.org>
7145
7146 * inferiors.c (find_inferior_in_random): New function.
7147 * inferiors.h (find_inferior_in_random): Declare.
7148 * linux-low.c (linux_wait_for_event_filtered): Call
7149 find_inferior_in_random instead of find_inferior.
7150
7151 2016-10-27 Yao Qi <yao.qi@linaro.org>
7152
7153 * linux-low.c (linux_wait_1): If single-step breakpoints are
7154 inserted, remove them.
7155
7156 2016-10-26 Pedro Alves <palves@redhat.com>
7157
7158 * linux-low.c (handle_extended_wait): Link parent/child fork
7159 threads.
7160 (linux_wait_1): Unlink them.
7161 (linux_set_resume_request): Ignore resume requests for
7162 already-resumed and unhandled fork child threads.
7163 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7164 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7165 New functions.
7166 (handle_v_requests) <vCont>: Don't call require_running.
7167 * server.h (in_queued_stop_replies): New declaration.
7168
7169 2016-10-24 Yao Qi <yao.qi@linaro.org>
7170
7171 PR server/20733
7172 * linux-aarch64-low.c (append_insns): Cast the return value to
7173 'uint32_t *'.
7174
7175 2016-10-10 Yao Qi <yao.qi@linaro.org>
7176
7177 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7178
7179 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7180
7181 * target.c (target_supports_multi_process): New function, moved
7182 from...
7183 * target.h (target_supports_multi_process): ... here. Remove
7184 macro.
7185
7186 2016-10-05 Tom Tromey <tom@tromey.com>
7187
7188 PR remote/20655:
7189 * tracepoint.c (handle_tracepoint_bkpts): Check
7190 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7191
7192 2016-10-05 Yao Qi <yao.qi@linaro.org>
7193
7194 * configure.srv: Update the path of arm-*.xml files.
7195
7196 2016-10-05 Terry Guo <terry.guo@arm.com>
7197 Yao Qi <yao.qi@linaro.org>
7198
7199 * Makefile.in: Adjust the path of rules.
7200 * configure.srv: Update the path of xml files.
7201 * regformats/arm-with-iwmmxt.dat: Regenerated.
7202 * regformats/arm-with-neon.dat: Likewise.
7203 * regformats/arm-with-vfpv2.dat: Likewise.
7204 * regformats/arm-with-vfpv3.dat Likewise.
7205
7206 2016-09-30 Yao Qi <yao.qi@linaro.org>
7207
7208 PR gdbserver/20627
7209 * target.c (target_stop_and_wait): Don't call
7210 target_continue_no_signal, use resume_stop instead.
7211
7212 2016-09-26 Yao Qi <yao.qi@linaro.org>
7213
7214 * linux-low.c (linux_wait_1): Call debug_exit.
7215
7216 2016-09-23 Pedro Alves <palves@redhat.com>
7217
7218 * Makefile.in (SFILES): Add common/new-op.c.
7219 (OBS): Add common/new-op.o.
7220 (new-op.o): New rule.
7221
7222 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7223
7224 * .gitinore: Ignore more files.
7225
7226 2016-09-21 Yao Qi <yao.qi@linaro.org>
7227
7228 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7229 23.
7230
7231 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7232
7233 * server.c (start_inferior): Call target_mourn_inferior instead of
7234 mourn_inferior; pass ptid_t argument to it.
7235 (resume): Likewise.
7236 (handle_target_event): Likewise.
7237 * target.c (target_mourn_inferior): New function.
7238 * target.h (mourn_inferior): Delete macro.
7239
7240 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7241
7242 * linux-low.c (lwp_is_stepping): New function.
7243
7244 2016-09-06 Carl Love <cel@us.ibm.com>
7245
7246 * server.c (start_inferior): Fixed comment, requested comment change
7247 didn't get updated correctly. Removed reference to ptrace () call as
7248 it is only true on Linux systems.
7249
7250 2016-09-06 Carl Love <cel@us.ibm.com>
7251
7252 * server.c (start_inferior): Do not call
7253 function target_post_create_inferior () if the
7254 inferior process has already exited.
7255
7256 2016-09-05 Pedro Alves <palves@redhat.com>
7257
7258 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7259 (COMPILE.pre, CC_LD): Use CXX directly.
7260 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7261 * acinclude.m4: Don't include build-with-cxx.m4.
7262 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7263 * configure: Regenerate.
7264
7265 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7266
7267 PR gdb/19495
7268 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7269 call writing data to own_buf.
7270
7271 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7272
7273 * target.c (mywait): Call target_wait instead of
7274 the_target->wait.
7275 (target_wait): New function.
7276
7277 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7278
7279 * server.c (start_inferior): New variable 'ptid'. Replace calls
7280 to the_target->resume by target_continue{,_no_signal}, depending
7281 on the case.
7282 * target.c (target_stop_and_wait): Call target_continue_no_signal
7283 instead of the_target->resume.
7284 (target_continue): New function.
7285
7286 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7287
7288 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7289
7290 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7291
7292 PR server/20491
7293 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7294 ps_prochandle.
7295 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7296 * linux-arm-low.c (ps_get_thread_area): Likewise.
7297 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7298 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7299 * linux-mips-low.c (ps_get_thread_area): Likewise.
7300 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7301 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7302 * linux-x86-low.c (ps_get_thread_area): Likewise.
7303 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7304
7305 2016-08-19 Pedro Alves <palves@redhat.com>
7306
7307 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7308
7309 2016-08-19 Pedro Alves <palves@redhat.com>
7310
7311 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7312 comment. Use memcpy instead of casting through unsigned long.
7313
7314 2016-08-19 Pedro Alves <palves@redhat.com>
7315
7316 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7317 allocating around 0x80000000.
7318
7319 2016-08-19 Pedro Alves <palves@redhat.com>
7320
7321 PR gdb/20415
7322 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7323 (x32-avx512-linux-ipa.o): New rules.
7324 * configure.ac (x86_64-*-linux*): New x32 check.
7325 * configure.srv (ipa_x32_linux_regobj): New.
7326 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7327 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7328 descriptions.
7329 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7330 descriptions.
7331 * configure: Regenerate.
7332
7333 2016-08-09 Pedro Alves <palves@redhat.com>
7334
7335 PR gdb/18653
7336 * Makefile.in (OBS): Add signals-state-save-restore.o.
7337 (signals-state-save-restore.o): New rule.
7338 * config.in: Regenerate.
7339 * configure: Regenerate.
7340 * linux-low.c: Include "signals-state-save-restore.h".
7341 (linux_create_inferior): Call
7342 restore_original_signals_state.
7343 * server.c: Include "dispositions-save-restore.h".
7344 (captured_main): Call save_original_signals_state.
7345
7346 2016-08-05 Pedro Alves <palves@redhat.com>
7347
7348 * configure: Regenerate.
7349
7350 2016-08-04 Yao Qi <yao.qi@linaro.org>
7351
7352 * linux-low.c (regsets_fetch_inferior_registers): Check
7353 errno is ESRCH or not.
7354
7355 2016-08-02 Yao Qi <yao.qi@linaro.org>
7356
7357 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7358 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7359 (thread_db_load_search): Update.
7360 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7361 td_ta_set_event and td_ta_event_getmsg.
7362
7363 2016-07-26 Pedro Alves <palves@redhat.com>
7364
7365 PR server/20414
7366 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7367 of unsigned long for 64-bit registers and use uint32_t instead of
7368 unsigned int for 32-bit registers.
7369
7370 2016-07-26 Pedro Alves <palves@redhat.com>
7371
7372 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7373 to 'ptrace'.
7374
7375 2016-07-21 Tom Tromey <tom@tromey.com>
7376
7377 * configure: Rebuild.
7378
7379 2016-07-21 Yao Qi <yao.qi@linaro.org>
7380
7381 * mem-break.c (find_gdb_breakpoint): Cast bp to
7382 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7383
7384 2016-07-21 Yao Qi <yao.qi@linaro.org>
7385
7386 * server.c (handle_v_requests): Support s and S actions
7387 if target_supports_software_single_step return true.
7388
7389 2016-07-21 Yao Qi <yao.qi@linaro.org>
7390
7391 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7392 is resume_step, call maybe_hw_step.
7393 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7394 and unstop them.
7395 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7396 breakpoints or not.
7397 (proceed_one_lwp): If resume request is resume_step, install
7398 reinsert breakpoints and call maybe_hw_step.
7399
7400 2016-07-21 Yao Qi <yao.qi@linaro.org>
7401
7402 * linux-low.c (proceed_one_lwp): Declare.
7403 (linux_resume_one_thread): Remove local variable 'step'.
7404 Lift code enqueue signal. Call proceed_one_lwp instead of
7405 linux_resume_one_lwp.
7406
7407 2016-07-21 Yao Qi <yao.qi@linaro.org>
7408
7409 * linux-low.c (linux_resume_one_thread): Call
7410 enqueue_pending_signal.
7411
7412 2016-07-21 Yao Qi <yao.qi@linaro.org>
7413
7414 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7415 * inferiors.c (do_restore_current_thread_cleanup): New function.
7416 (make_cleanup_restore_current_thread): Likewise.
7417 * linux-low.c (install_software_single_step_breakpoints): Call
7418 make_cleanup_restore_current_thread. Switch current_thread to
7419 thread.
7420
7421 2016-07-21 Yao Qi <yao.qi@linaro.org>
7422
7423 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7424 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7425 (clone_one_breakpoint): Likewise.
7426 (delete_reinsert_breakpoints): Change parameter to thread.
7427 Callers updated.
7428 (has_reinsert_breakpoints): Likewise.
7429 (uninsert_reinsert_breakpoints): Likewise.
7430 (reinsert_reinsert_breakpoints): Likewise.
7431 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7432 (delete_reinsert_breakpoints): Likewise.
7433 (reinsert_reinsert_breakpoints): Likewise.
7434 (uninsert_reinsert_breakpoints): Likewise.
7435 (has_reinsert_breakpoints): Likewise.
7436
7437 2016-07-21 Yao Qi <yao.qi@linaro.org>
7438
7439 * inferiors.c (get_thread_process): Make parameter const.
7440 * inferiors.h (get_thread_process): Update declaration.
7441 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7442 Add new parameters child_thread and parent_thread. Callers
7443 updated.
7444 * mem-break.h (clone_all_breakpoints): Update declaration.
7445
7446 2016-07-21 Yao Qi <yao.qi@linaro.org>
7447
7448 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7449 <command_list, handler>: Remove.
7450 (struct gdb_breakpoint): New.
7451 (struct other_breakpoint): New.
7452 (struct reinsert_breakpoint): New.
7453 (is_gdb_breakpoint): New function.
7454 (any_persistent_commands): Update command_list if
7455 is_gdb_breakpoint returns true.
7456 (set_breakpoint): Create breakpoints according to their types.
7457 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7458 (set_gdb_breakpoint_1): Likewise.
7459 (set_gdb_breakpoint): Likewise.
7460 (clear_breakpoint_conditions): Change parameter type to
7461 'struct gdb_breakpoint *'.
7462 (clear_breakpoint_commands): Likewise.
7463 (clear_breakpoint_conditions_and_commands): Likewise.
7464 (add_condition_to_breakpoint): Likewise.
7465 (add_breakpoint_condition): Likewise.
7466 (add_commands_to_breakpoint): Likewise.
7467 (check_breakpoints): Check other_breakpoint.
7468 (clone_one_breakpoint): Clone breakpopint according to its type.
7469 * mem-break.h (struct gdb_breakpoint): Declare.
7470 (set_gdb_breakpoint): Update declaration.
7471 (clear_breakpoint_conditions_and_commands): Likewise.
7472 (add_breakpoint_condition): Likewise.
7473 (add_breakpoint_commands): Likewise.
7474 * server.c (process_point_options): Change parameter type to
7475 'struct gdb_breakpoint *'.
7476
7477 2016-07-21 Yao Qi <yao.qi@linaro.org>
7478
7479 * mem-break.c (set_breakpoint_at): Rename it to ...
7480 (set_breakpoint_type_at): ... it.
7481 (set_breakpoint_at): Call set_breakpoint_type_at.
7482 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7483 * mem-break.h (set_breakpoint_at): Update comments.
7484
7485 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7486
7487 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7488 to buf parameter.
7489 (nios2_store_gregset): Likewise.
7490
7491 2016-07-01 Pedro Alves <palves@redhat.com>
7492 Antoine Tremblay <antoine.tremblay@ericsson.com>
7493
7494 * linux-low.c: Change interface to take the target lwp_info
7495 pointer directly and return void. Handle detaching from a zombie
7496 thread.
7497 (linux_detach_lwp_callback): New function.
7498 (linux_detach): Detach from the leader thread after detaching from
7499 the clone threads.
7500
7501 2016-06-28 Yao Qi <yao.qi@linaro.org>
7502
7503 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7504 for variable new_offset.
7505 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7506 (aarch64_ftrace_insn_reloc_cb): Likewise.
7507 (aarch64_ftrace_insn_reloc_tb): Likewise.
7508 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7509 PRIx64 instead of PRIx32.
7510
7511 2016-06-28 Yao Qi <yao.qi@linaro.org>
7512
7513 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7514 (the_low_target): Install arm_get_syscall_trapinfo.
7515
7516 2016-06-28 Yao Qi <yao.qi@linaro.org>
7517
7518 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7519 function.
7520 (the_low_target): Install aarch64_get_syscall_trapinfo.
7521
7522 2016-06-28 Yao Qi <yao.qi@linaro.org>
7523
7524 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7525 Callers updated.
7526 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7527 Remove parameter sysno.
7528 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7529 sysret.
7530
7531 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7532
7533 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7534 (s390_emit_ne_goto): Likewise.
7535 (s390_emit_lt_goto): Likewise.
7536 (s390_emit_le_goto): Likewise.
7537 (s390_emit_gt_goto): Likewise.
7538 (s390_emit_ge_goto): Likewise.
7539 (s390x_emit_eq_goto): Likewise.
7540 (s390x_emit_ne_goto): Likewise.
7541 (s390x_emit_lt_goto): Likewise.
7542 (s390x_emit_le_goto): Likewise.
7543 (s390x_emit_gt_goto): Likewise.
7544 (s390x_emit_ge_goto): Likewise.
7545 (s390_emit_ops_impl): Mark variable static.
7546 (s390x_emit_ops): Likewise.
7547
7548 2016-06-17 Yao Qi <yao.qi@linaro.org>
7549
7550 * linux-low.c (handle_extended_wait): Call
7551 uninsert_reinsert_breakpoints for the parent process. Remove
7552 reinsert breakpoints from the child process. Reinsert them to
7553 the parent process when vfork is done.
7554 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7555 (reinsert_reinsert_breakpoints): New function.
7556 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7557 (reinsert_reinsert_breakpoints): Declare.
7558
7559 2016-06-17 Yao Qi <yao.qi@linaro.org>
7560
7561 * linux-low.c (handle_extended_wait): If the parent is doing
7562 step-over, remove the reinsert breakpoints from the forked child.
7563
7564 2016-06-17 Yao Qi <yao.qi@linaro.org>
7565
7566 * linux-low.c (unsuspend_all_lwps): Declare.
7567 (linux_low_filter_event): If thread exited, call finish_step_over.
7568 If step-over is finished, unsuspend other threads.
7569
7570 2016-06-17 Yao Qi <yao.qi@linaro.org>
7571
7572 * linux-low.c (linux_resume_one_lwp_throw): Assert
7573 has_reinsert_breakpoints returns false.
7574 * mem-break.c (delete_disabled_breakpoints): Assert
7575 bp type isn't reinsert_breakpoint.
7576
7577 2016-06-17 Yao Qi <yao.qi@linaro.org>
7578
7579 * linux-low.c (maybe_hw_step): New function.
7580 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7581 (finish_step_over): Switch current_thread to lwp temporarily,
7582 and assert has_reinsert_breakpoints returns true.
7583 (proceed_one_lwp): Call maybe_hw_step.
7584 * mem-break.c (has_reinsert_breakpoints): New function.
7585 * mem-break.h (has_reinsert_breakpoints): Declare.
7586
7587 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7588
7589 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7590
7591 2016-05-17 Yao Qi <yao.qi@linaro.org>
7592
7593 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7594 instead of find_inferior.
7595
7596 2016-05-05 Yao Qi <yao.qi@linaro.org>
7597
7598 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7599 Initialize res to zero.
7600
7601 2016-05-05 Yao Qi <yao.qi@linaro.org>
7602
7603 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7604 to uint32_t.
7605
7606 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7607
7608 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7609 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7610 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7611
7612 2016-04-28 Par Olsson <par.olsson@windriver.com>
7613 Simon Marchi <simon.marchi@ericsson.com>
7614
7615 * tracepoint.c (write_inferior_int8): New function.
7616 (cmd_qtenable_disable): Write enable flag using
7617 write_inferior_int8.
7618
7619 2016-04-25 Yao Qi <yao.qi@linaro.org>
7620
7621 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7622 (need_step_over_p): Return zero if the LWP has pending signals
7623 can be delivered on software single step target.
7624
7625 2016-04-25 Yao Qi <yao.qi@linaro.org>
7626
7627 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7628 return instead of error.
7629
7630 2016-04-22 Yao Qi <yao.qi@linaro.org>
7631
7632 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7633 to 23.
7634
7635 2016-04-22 Yao Qi <yao.qi@linaro.org>
7636
7637 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7638 signal when stepping over breakpoint with software single
7639 step.
7640
7641 2016-04-21 Pedro Alves <palves@redhat.com>
7642
7643 * linux-s390-low.c (s390_collect_ptrace_register)
7644 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7645 add casts.
7646 (s390_check_regset): Use void * instead of gdb_byte *.
7647
7648 2016-04-20 Pedro Alves <palves@redhat.com>
7649
7650 * configure: Renegerate.
7651
7652 2016-04-20 Yao Qi <yao.qi@linaro.org>
7653
7654 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7655 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7656 number 16.
7657 (arm_store_gregset): Likewise.
7658
7659 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7660
7661 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7662 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7663 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7664 (amd64-avx-mpx-linux.c): New rules.
7665 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7666 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7667 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7668 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7669 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7670 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7671 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7672 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7673 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7674 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7675 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7676 * linux-x86-low.c (x86_linux_read_description): Add case for
7677 X86_XSTATE_AVX_MPX_MASK.
7678 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7679 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7680 init_registers_i386_avx_mpx_linux.
7681 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7682 (initialize_low_tracepoint): Call
7683 init_registers_i386_avx_mpx_linux.
7684 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7685 (initialize_low_tracepoint): Call
7686 init_registers_amd64_avx_mpx_linux.
7687 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7688 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7689 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
7690 declarations.
7691
7692 2016-04-18 Pedro Alves <palves@redhat.com>
7693
7694 * configure: Regenerate.
7695
7696 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
7697
7698 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
7699 (aarch64_emit_sub): Likewise.
7700
7701 2016-04-12 Pedro Alves <palves@redhat.com>
7702
7703 * utils.c (prepare_to_throw_exception): Delete.
7704
7705 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
7706
7707 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
7708
7709 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
7710
7711 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
7712
7713 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
7714
7715 * linux-aarch64-ipa.c: Add <elf.h> include.
7716 * linux-ppc-ipa.c: Add <elf.h> include.
7717 * linux-s390-ipa.c: Add <elf.h> include.
7718
7719 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7720
7721 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
7722 (get_raw_reg_ptr): Likewise.
7723 (get_trace_state_variable_value_ptr): Likewise.
7724 (set_trace_state_variable_value_ptr): Likewise.
7725 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
7726 char *.
7727
7728 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
7729 Marcin Kościelnicki <koriakin@0x04.net>
7730
7731 PR/17221
7732 * linux-ppc-low.c (emit_insns): New function.
7733 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
7734 (ppc_emit_prologue): New function.
7735 (ppc_emit_epilogue): New function.
7736 (ppc_emit_add): New function.
7737 (ppc_emit_sub): New function.
7738 (ppc_emit_mul): New function.
7739 (ppc_emit_lsh): New function.
7740 (ppc_emit_rsh_signed): New function.
7741 (ppc_emit_rsh_unsigned): New function.
7742 (ppc_emit_ext): New function.
7743 (ppc_emit_zero_ext): New function.
7744 (ppc_emit_log_not): New function.
7745 (ppc_emit_bit_and): New function.
7746 (ppc_emit_bit_or): New function.
7747 (ppc_emit_bit_xor): New function.
7748 (ppc_emit_bit_not): New function.
7749 (ppc_emit_equal): New function.
7750 (ppc_emit_less_signed): New function.
7751 (ppc_emit_less_unsigned): New function.
7752 (ppc_emit_ref): New function.
7753 (ppc_emit_const): New function.
7754 (ppc_emit_reg): New function.
7755 (ppc_emit_pop): New function.
7756 (ppc_emit_stack_flush): New function.
7757 (ppc_emit_swap): New function.
7758 (ppc_emit_stack_adjust): New function.
7759 (ppc_emit_call): New function.
7760 (ppc_emit_int_call_1): New function.
7761 (ppc_emit_void_call_2): New function.
7762 (ppc_emit_if_goto): New function.
7763 (ppc_emit_goto): New function.
7764 (ppc_emit_eq_goto): New function.
7765 (ppc_emit_ne_goto): New function.
7766 (ppc_emit_lt_goto): New function.
7767 (ppc_emit_le_goto): New function.
7768 (ppc_emit_gt_goto): New function.
7769 (ppc_emit_ge_goto): New function.
7770 (ppc_write_goto_address): New function.
7771 (ppc_emit_ops_impl): New static variable.
7772 (ppc64v1_emit_prologue): New function.
7773 (ppc64v2_emit_prologue): New function.
7774 (ppc64_emit_epilogue): New function.
7775 (ppc64_emit_add): New function.
7776 (ppc64_emit_sub): New function.
7777 (ppc64_emit_mul): New function.
7778 (ppc64_emit_lsh): New function.
7779 (ppc64_emit_rsh_signed): New function.
7780 (ppc64_emit_rsh_unsigned): New function.
7781 (ppc64_emit_ext): New function.
7782 (ppc64_emit_zero_ext): New function.
7783 (ppc64_emit_log_not): New function.
7784 (ppc64_emit_bit_and): New function.
7785 (ppc64_emit_bit_or): New function.
7786 (ppc64_emit_bit_xor): New function.
7787 (ppc64_emit_bit_not): New function.
7788 (ppc64_emit_equal): New function.
7789 (ppc64_emit_less_signed): New function.
7790 (ppc64_emit_less_unsigned): New function.
7791 (ppc64_emit_ref): New function.
7792 (ppc64_emit_const): New function.
7793 (ppc64v1_emit_reg): New function.
7794 (ppc64v2_emit_reg): New function.
7795 (ppc64_emit_pop): New function.
7796 (ppc64_emit_stack_flush): New function.
7797 (ppc64_emit_swap): New function.
7798 (ppc64v1_emit_call): New function.
7799 (ppc64v2_emit_call): New function.
7800 (ppc64v1_emit_int_call_1): New function.
7801 (ppc64v2_emit_int_call_1): New function.
7802 (ppc64v1_emit_void_call_2): New function.
7803 (ppc64v2_emit_void_call_2): New function.
7804 (ppc64_emit_if_goto): New function.
7805 (ppc64_emit_eq_goto): New function.
7806 (ppc64_emit_ne_goto): New function.
7807 (ppc64_emit_lt_goto): New function.
7808 (ppc64_emit_le_goto): New function.
7809 (ppc64_emit_gt_goto): New function.
7810 (ppc64_emit_ge_goto): New function.
7811 (ppc64v1_emit_ops_impl): New static variable.
7812 (ppc64v2_emit_ops_impl): New static variable.
7813 (ppc_emit_ops): New function.
7814 (linux_low_target): Wire in ppc_emit_ops.
7815
7816 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
7817 Marcin Kościelnicki <koriakin@0x04.net>
7818
7819 PR/17221
7820 * Makefile.in: Add powerpc-*-ipa.o
7821 * configure.srv: Add ipa_obj for powerpc*-linux.
7822 * linux-ppc-ipa.c: New file.
7823 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
7824 includes.
7825 (PPC_FIELD): New macro.
7826 (PPC_SEXT): New macro.
7827 (PPC_OP6): New macro.
7828 (PPC_BO): New macro.
7829 (PPC_LI): New macro.
7830 (PPC_BD): New macro.
7831 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
7832 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
7833 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
7834 (ppc_get_thread_area): New function.
7835 (is_elfv2_inferior): New function.
7836 (gen_ds_form): New function.
7837 (GEN_STD): New macro.
7838 (GEN_STDU): New macro.
7839 (GEN_LD): New macro.
7840 (GEN_LDU): New macro.
7841 (gen_d_form): New function.
7842 (GEN_ADDI): New macro.
7843 (GEN_ADDIS): New macro.
7844 (GEN_LI): New macro.
7845 (GEN_LIS): New macro.
7846 (GEN_ORI): New macro.
7847 (GEN_ORIS): New macro.
7848 (GEN_LWZ): New macro.
7849 (GEN_STW): New macro.
7850 (GEN_STWU): New macro.
7851 (gen_xfx_form): New function.
7852 (GEN_MFSPR): New macro.
7853 (GEN_MTSPR): New macro.
7854 (GEN_MFCR): New macro.
7855 (GEN_MTCR): New macro.
7856 (GEN_SYNC): New macro.
7857 (GEN_LWSYNC): New macro.
7858 (gen_x_form): New function.
7859 (GEN_OR): New macro.
7860 (GEN_MR): New macro.
7861 (GEN_LWARX): New macro.
7862 (GEN_STWCX): New macro.
7863 (GEN_CMPW): New macro.
7864 (gen_md_form): New function.
7865 (GEN_RLDICL): New macro.
7866 (GEN_RLDICR): New macro.
7867 (gen_i_form): New function.
7868 (GEN_B): New macro.
7869 (GEN_BL): New macro.
7870 (gen_b_form): New function.
7871 (GEN_BNE): New macro.
7872 (GEN_LOAD): New macro.
7873 (GEN_STORE): New macro.
7874 (gen_limm): New function.
7875 (gen_atomic_xchg): New function.
7876 (gen_call): New function.
7877 (ppc_relocate_instruction): New function.
7878 (ppc_install_fast_tracepoint_jump_pad): New function.
7879 (ppc_get_min_fast_tracepoint_insn_len): New function.
7880 (ppc_get_ipa_tdesc_idx): New function.
7881 (the_low_target): Wire in the new functions.
7882 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
7883 tdescs.
7884 * linux-ppc-tdesc.h: New file.
7885
7886 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7887
7888 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
7889 (alloc_jump_pad_buffer): New function.
7890 * linux-amd64-ipa.c: Add <sys/mman.h> include.
7891 (alloc_jump_pad_buffer): New function.
7892 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
7893 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
7894 (alloc_jump_pad_buffer): New function.
7895 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
7896 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
7897 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
7898 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
7899
7900 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
7901
7902 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
7903 * linux-amd64-ipa.c: Likewise.
7904 * linux-i386-ipa.c: Likewise.
7905 * linux-s390-ipa.c: Likewise.
7906 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
7907 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
7908 set_trace_state_variable_value_ptr.
7909 (struct ipa_sym_addresses): Likewise.
7910 (symbol_list): Likewise.
7911 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
7912 accessing gdb_collect directly.
7913 (gdb_collect_ptr_type): New typedef.
7914 (get_raw_reg_ptr_type): New typedef.
7915 (get_trace_state_variable_value_ptr_type): New typedef.
7916 (set_trace_state_variable_value_ptr_type): New typedef.
7917 (gdb_collect_ptr): New global.
7918 (get_raw_reg_ptr): New global.
7919 (get_trace_state_variable_value_ptr): New global.
7920 (set_trace_state_variable_value_ptr): New global.
7921 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
7922 accessing get_raw_reg directly.
7923 (get_get_tsv_func_addr): Likewise for
7924 get_trace_state_variable_value_ptr.
7925 (get_set_tsv_func_addr): Likewise for
7926 set_trace_state_variable_value_ptr.
7927 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
7928
7929 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
7930
7931 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
7932
7933 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
7934
7935 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
7936 packets.
7937 (relocate_instruction): Remove own_buf.
7938 * server.c (own_buf): Make global.
7939 (handle_v_requests): Make global.
7940 * server.h (own_buf): New declaration.
7941 (handle_v_requests): New prototype.
7942
7943 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
7944
7945 PR 18377
7946 * linux-s390-low.c (add_insns): New function.
7947 (s390_emit_prologue): New function.
7948 (s390_emit_epilogue): New function.
7949 (s390_emit_add): New function.
7950 (s390_emit_sub): New function.
7951 (s390_emit_mul): New function.
7952 (s390_emit_lsh): New function.
7953 (s390_emit_rsh_signed): New function.
7954 (s390_emit_rsh_unsigned): New function.
7955 (s390_emit_ext): New function.
7956 (s390_emit_log_not): New function.
7957 (s390_emit_bit_and): New function.
7958 (s390_emit_bit_or): New function.
7959 (s390_emit_bit_xor): New function.
7960 (s390_emit_bit_not): New function.
7961 (s390_emit_equal): New function.
7962 (s390_emit_less_signed): New function.
7963 (s390_emit_less_unsigned): New function.
7964 (s390_emit_ref): New function.
7965 (s390_emit_if_goto): New function.
7966 (s390_emit_goto): New function.
7967 (s390_write_goto_address): New function.
7968 (s390_emit_litpool): New function.
7969 (s390_emit_const): New function.
7970 (s390_emit_call): New function.
7971 (s390_emit_reg): New function.
7972 (s390_emit_pop): New function.
7973 (s390_emit_stack_flush): New function.
7974 (s390_emit_zero_ext): New function.
7975 (s390_emit_swap): New function.
7976 (s390_emit_stack_adjust): New function.
7977 (s390_emit_set_r2): New function.
7978 (s390_emit_int_call_1): New function.
7979 (s390_emit_void_call_2): New function.
7980 (s390_emit_eq_goto): New function.
7981 (s390_emit_ne_goto): New function.
7982 (s390_emit_lt_goto): New function.
7983 (s390_emit_le_goto): New function.
7984 (s390_emit_gt_goto): New function.
7985 (s390_emit_ge_goto): New function.
7986 (s390x_emit_prologue): New function.
7987 (s390x_emit_epilogue): New function.
7988 (s390x_emit_add): New function.
7989 (s390x_emit_sub): New function.
7990 (s390x_emit_mul): New function.
7991 (s390x_emit_lsh): New function.
7992 (s390x_emit_rsh_signed): New function.
7993 (s390x_emit_rsh_unsigned): New function.
7994 (s390x_emit_ext): New function.
7995 (s390x_emit_log_not): New function.
7996 (s390x_emit_bit_and): New function.
7997 (s390x_emit_bit_or): New function.
7998 (s390x_emit_bit_xor): New function.
7999 (s390x_emit_bit_not): New function.
8000 (s390x_emit_equal): New function.
8001 (s390x_emit_less_signed): New function.
8002 (s390x_emit_less_unsigned): New function.
8003 (s390x_emit_ref): New function.
8004 (s390x_emit_if_goto): New function.
8005 (s390x_emit_const): New function.
8006 (s390x_emit_call): New function.
8007 (s390x_emit_reg): New function.
8008 (s390x_emit_pop): New function.
8009 (s390x_emit_stack_flush): New function.
8010 (s390x_emit_zero_ext): New function.
8011 (s390x_emit_swap): New function.
8012 (s390x_emit_stack_adjust): New function.
8013 (s390x_emit_int_call_1): New function.
8014 (s390x_emit_void_call_2): New function.
8015 (s390x_emit_eq_goto): New function.
8016 (s390x_emit_ne_goto): New function.
8017 (s390x_emit_lt_goto): New function.
8018 (s390x_emit_le_goto): New function.
8019 (s390x_emit_gt_goto): New function.
8020 (s390x_emit_ge_goto): New function.
8021 (s390_emit_ops): New function.
8022 (struct linux_target_ops): Fill in emit_ops hook.
8023
8024 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8025
8026 PR 18377
8027 * Makefile.in: Add s390 IPA files.
8028 * configure.srv: Build IPA for s390.
8029 * linux-s390-ipa.c: New file.
8030 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8031 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8032 (tdesc_s390_linux32): Likewise.
8033 (init_registers_s390_linux32v1): Likewise.
8034 (tdesc_s390_linux32v1): Likewise.
8035 (init_registers_s390_linux32v2): Likewise.
8036 (tdesc_s390_linux32v2): Likewise.
8037 (init_registers_s390_linux64): Likewise.
8038 (tdesc_s390_linux64): Likewise.
8039 (init_registers_s390_linux64v1): Likewise.
8040 (tdesc_s390_linux64v1): Likewise.
8041 (init_registers_s390_linux64v2): Likewise.
8042 (tdesc_s390_linux64v2): Likewise.
8043 (init_registers_s390_te_linux64): Likewise.
8044 (tdesc_s390_te_linux64): Likewise.
8045 (init_registers_s390_vx_linux64): Likewise.
8046 (tdesc_s390_vx_linux64): Likewise.
8047 (init_registers_s390_tevx_linux64): Likewise.
8048 (tdesc_s390_tevx_linux64): Likewise.
8049 (init_registers_s390x_linux64): Likewise.
8050 (tdesc_s390x_linux64): Likewise.
8051 (init_registers_s390x_linux64v1): Likewise.
8052 (tdesc_s390x_linux64v1): Likewise.
8053 (init_registers_s390x_linux64v2): Likewise.
8054 (tdesc_s390x_linux64v2): Likewise.
8055 (init_registers_s390x_te_linux64): Likewise.
8056 (tdesc_s390x_te_linux64): Likewise.
8057 (init_registers_s390x_vx_linux64): Likewise.
8058 (tdesc_s390x_vx_linux64): Likewise.
8059 (init_registers_s390x_tevx_linux64): Likewise.
8060 (tdesc_s390x_tevx_linux64): Likewise.
8061 (have_hwcap_s390_vx): New static variable.
8062 (s390_arch_setup): Fill have_hwcap_s390_vx.
8063 (s390_get_thread_area): New function.
8064 (s390_ft_entry_gpr_esa): New const.
8065 (s390_ft_entry_gpr_zarch): New const.
8066 (s390_ft_entry_misc): New const.
8067 (s390_ft_entry_fr): New const.
8068 (s390_ft_entry_vr): New const.
8069 (s390_ft_main_31): New const.
8070 (s390_ft_main_64): New const.
8071 (s390_ft_exit_fr): New const.
8072 (s390_ft_exit_vr): New const.
8073 (s390_ft_exit_misc): New const.
8074 (s390_ft_exit_gpr_esa): New const.
8075 (s390_ft_exit_gpr_zarch): New const.
8076 (append_insns): New function.
8077 (s390_relocate_instruction): New function.
8078 (s390_install_fast_tracepoint_jump_pad): New function.
8079 (s390_get_min_fast_tracepoint_insn_len): New function.
8080 (s390_get_ipa_tdesc_idx): New function.
8081 (struct linux_target_ops): Wire in the above functions.
8082 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8083 * linux-s390-tdesc.h: New file.
8084
8085 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8086
8087 * linux-s390-low.c (s390_supports_tracepoints): New function.
8088 (struct linux_target_ops): Fill supports_tracepoints hook.
8089
8090 2016-03-18 Yao Qi <yao.qi@linaro.org>
8091
8092 * linux-low.c (lwp_signal_can_be_delivered): New function.
8093 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8094
8095 2016-03-18 Yao Qi <yao.qi@linaro.org>
8096
8097 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8098 0 if signal is enqueued. Remove 'signal' from one debugging
8099 message. Move one debugging message to some lines below.
8100 Remove code setting 'signal' to 0.
8101
8102 2016-03-18 Yao Qi <yao.qi@linaro.org>
8103
8104 * linux-low.c (linux_low_filter_event): Remove redundant
8105 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8106
8107 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8108
8109 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8110 (struct linux_target_ops): Wire in the above.
8111
8112 2016-03-03 Yao Qi <yao.qi@linaro.org>
8113
8114 * linux-low.c: Update comments to start_step_over.
8115
8116 2016-03-03 Yao Qi <yao.qi@linaro.org>
8117
8118 PR server/19736
8119 * linux-low.c (handle_extended_wait): Set child suspended
8120 if event_lwp->bp_reinsert isn't zero.
8121
8122 2016-03-02 Yao Qi <yao.qi@linaro.org>
8123
8124 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8125 enqueue_pending_signal.
8126
8127 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8128
8129 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8130 is actually loaded.
8131
8132 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8133
8134 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8135 (s390_regmap_3264) [!__s390x__]: New global.
8136 (s390_collect_ptrace_register): Skip map entries containing -1.
8137 (s390_supply_ptrace_register): Ditto.
8138 (s390_fill_gprs_high): New function.
8139 (s390_store_gprs_high): New function.
8140 (s390_regsets): Add NT_S390_HIGH_GPRS.
8141 (s390_get_hwcap): Enable on 31-bit.
8142 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8143 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8144 Detect NT_S390_HIGH_GPRS.
8145 (s390_usrregs_info_3264): Enable on 31-bit.
8146 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8147 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8148
8149 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8150
8151 PR gdb/13808
8152 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8153 * configure.srv: Ditto.
8154 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8155 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8156 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8157 (init_registers_amd64_linux): Remove prototype.
8158 (tdesc_amd64_linux): Remove declaration.
8159 (get_ipa_tdesc): New function.
8160 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8161 initialize remaining tdescs.
8162 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8163 (init_registers_i386_linux): Remove prototype.
8164 (tdesc_i386_linux): Remove declaration.
8165 (get_ipa_tdesc): New function.
8166 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8167 initialize remaining tdescs.
8168 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8169 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8170 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8171 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8172 (x86_get_ipa_tdesc_idx): New function.
8173 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8174 * linux-x86-tdesc.h: New file.
8175 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8176 (target_get_ipa_tdesc_idx): New macro.
8177 * tracepoint.c (ipa_tdesc_idx): New macro.
8178 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8179 (symbol_list): Add ipa_tdesc_idx.
8180 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8181 (ipa_tdesc): Remove.
8182 (ipa_tdesc_idx): New variable.
8183 (get_context_regcache): Use get_ipa_tdesc.
8184 (gdb_collect): Ditto.
8185 (gdb_probe): Ditto.
8186 * tracepoint.h (get_ipa_tdesc): New prototype.
8187 (ipa_tdesc): Remove.
8188
8189 2016-02-24 Pedro Alves <palves@redhat.com>
8190
8191 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8192 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8193 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8194 Factor out common code between the USE_SIGTRAP_SIGINFO and
8195 !USE_SIGTRAP_SIGINFO blocks.
8196 (linux_low_filter_event): Call save_stop_reason instead of
8197 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8198 Update comments.
8199 (linux_wait_1): Update comments.
8200
8201 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8202
8203 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8204 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8205 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8206 ppc_insert_point, ppc_remove_point.
8207
8208 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8209
8210 * linux-s390-low.c (s390_supports_z_point_type): New function.
8211 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8212
8213 2016-02-16 Yao Qi <yao.qi@linaro.org>
8214
8215 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8216 PC. Get pc from regcache_read_pc.
8217
8218 2016-02-12 Yao Qi <yao.qi@linaro.org>
8219
8220 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8221 or linux_get_pc_32bit.
8222 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8223
8224 2016-02-12 Yao Qi <yao.qi@linaro.org>
8225
8226 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8227 arm_linux_get_next_pcs_fixup.
8228
8229 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8230
8231 * tracepoint.c (x_tracepoint_action_download): Change
8232 write_inferior_data_ptr to write_inferior_data_pointer.
8233 (cmd_qtstart): Likewise.
8234 (write_inferior_data_ptr): Remove.
8235 (download_agent_expr): Change write_inferior_data_ptr to
8236 write_inferior_data_pointer.
8237 (download_tracepoint_1): Likewise.
8238 (download_tracepoint): Likewise.
8239 (download_trace_state_variables): Likewise.
8240
8241 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8242 Marcin Kościelnicki <koriakin@0x04.net>
8243
8244 * tracepoint.c (struct tracepoint_action_ops): Remove.
8245 (struct tracepoint_action): Remove ops.
8246 (m_tracepoint_action_download, r_tracepoint_action_download)
8247 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8248 size and offset accordingly.
8249 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8250 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8251 (tracepoint_action_send, tracepoint_action_download): New functions.
8252 Helpers for trace action handlers.
8253 (add_tracepoint_action): Remove setup actions ops.
8254 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8255
8256 2016-02-10 Yao Qi <yao.qi@linaro.org>
8257
8258 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8259
8260 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8261
8262 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8263 to AC_OUTPUT.
8264 * configure: Regenerate.
8265
8266 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8267
8268 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8269 void * to gdb_byte *.
8270 * linux-low.c (siginfo_fixup): Likewise.
8271 (linux_xfer_siginfo): Likewise.
8272 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8273 Likewise.
8274 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8275
8276 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8277
8278 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8279 to srv_tgtobj.
8280 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8281 to srv_tgtobj.
8282 * linux-x86-low.c [__x86_64__]: Include
8283 "nat/amd64-linux-siginfo.h".
8284 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8285 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8286 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8287 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8288 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8289 (cpt_si_fd, si_timerid, si_overrun): Move from
8290 nat/amd64-linux-siginfo.c.
8291 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8292
8293 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8294
8295 * server.c (skip_to_semicolon): Remove.
8296 (process_point_options): Use strchrnul instead of
8297 skip_to_semicolon.
8298
8299 2016-01-26 Yao Qi <yao.qi@linaro.org>
8300
8301 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8302 * linux-low.c (install_software_single_step_breakpoints): Don't
8303 call regcache_read_pc.
8304 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8305 argument pc.
8306
8307 2016-01-26 Yao Qi <yao.qi@linaro.org>
8308
8309 * linux-low.c (install_software_single_step_breakpoints): Call
8310 regcache_read_pc instead of get_pc.
8311
8312 2016-01-26 Yao Qi <yao.qi@linaro.org>
8313
8314 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8315 (unblock_async_io): Rename to ...
8316 (block_unblock_async_io): ... it. New function.
8317 (enable_async_io): Don't install SIGIO handler. Unblock it
8318 instead.
8319 (disable_async_io): Don't ignore SIGIO. Block it instead.
8320 (initialize_async_io): Install SIGIO handler. Don't call
8321 unblock_async_io.
8322
8323 2016-01-26 Yao Qi <yao.qi@linaro.org>
8324
8325 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8326 first character is '\003', call *the_target->request_interrupt.
8327
8328 2016-01-25 Yao Qi <yao.qi@linaro.org>
8329
8330 * remote-utils.c (new_thread_notify): Remove.
8331 (dead_thread_notify): Likewise.
8332 * remote-utils.h (new_thread_notify): Remove declaration.
8333 (dead_thread_notify): Likewise.
8334
8335 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8336
8337 * gdb.trace/pending.exp: Fix expected message on continue.
8338
8339 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8340
8341 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8342 it works properly on big-endian machines where sizeof (CORE_ADDR)
8343 != sizeof (void *).
8344
8345 2016-01-21 Pedro Alves <palves@redhat.com>
8346
8347 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8348 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8349 * configure: Regenerate.
8350
8351 2016-01-21 Yao Qi <yao.qi@linaro.org>
8352
8353 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8354 is_thumb and set it according to CPSR saved on the stack.
8355 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8356 arm_sigreturn_next_pc.
8357
8358 2016-01-18 Yao Qi <yao.qi@linaro.org>
8359
8360 * linux-low.c (linux_set_pc_64bit): New function.
8361 (linux_get_pc_64bit): New function.
8362 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8363 Declare.
8364 * linux-sparc-low.c (debug_threads): Remove declaration.
8365 (sparc_get_pc): Remove.
8366 (the_low_target): Use linux_get_pc_64bit instead of
8367 sparc_get_pc.
8368 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8369 (the_low_target): Use linux_get_pc_64bit and
8370 linux_set_pc_64bit.
8371
8372 2016-01-18 Yao Qi <yao.qi@linaro.org>
8373
8374 * linux-arm-low.c (debug_threads): Remove declaration.
8375 (arm_get_pc, arm_set_pc): Remove.
8376 (the_low_target): Use linux_get_pc_32bit and
8377 linux_set_pc_32bit.
8378 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8379 (the_low_target): Use linux_get_pc_32bit and
8380 linux_set_pc_32bit.
8381 * linux-cris-low.c (debug_threads): Remove declaration.
8382 (cris_get_pc, cris_set_pc,): Remove.
8383 (the_low_target): Use linux_get_pc_32bit and
8384 linux_set_pc_32bit.
8385 * linux-crisv32-low.c (debug_threads): Remove declaration.
8386 (cris_get_pc, cris_set_pc): Remove.
8387 (the_low_target): Use linux_get_pc_32bit and
8388 linux_set_pc_32bit.
8389 * linux-low.c: Include inttypes.h.
8390 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8391 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8392 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8393 (the_low_target): Use linux_get_pc_32bit and
8394 linux_set_pc_32bit.
8395 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8396 (the_low_target): Use linux_get_pc_32bit and
8397 linux_set_pc_32bit.
8398 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8399 (the_low_target): Use linux_get_pc_32bit and
8400 linux_set_pc_32bit.
8401 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8402 (the_low_target): Use linux_get_pc_32bit and
8403 linux_set_pc_32bit.
8404 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8405 (the_low_target): Use linux_get_pc_32bit and
8406 linux_set_pc_32bit.
8407
8408 2016-01-18 Gary Benson <gbenson@redhat.com>
8409
8410 * configure.ac (AC_FUNC_FORK): New check.
8411 * config.in: Regenerate.
8412 * configure: Likewise.
8413
8414 2016-01-14 Yao Qi <yao.qi@linaro.org>
8415
8416 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8417 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8418 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8419 arm_get_next_pcs_ctor.
8420
8421 2016-01-12 Josh Stone <jistone@redhat.com>
8422 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8423
8424 * inferiors.h: Include "gdb_vecs.h".
8425 (struct process_info): Add syscalls_to_catch.
8426 * inferiors.c (remove_process): Free syscalls_to_catch.
8427 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8428 syscall_return stops.
8429 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8430 * server.c (handle_general_set): Handle QCatchSyscalls.
8431 (handle_query): Report support for QCatchSyscalls.
8432 * target.h (struct target_ops): Add supports_catch_syscall.
8433 (target_supports_catch_syscall): New macro.
8434 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8435 (struct lwp_info): Add syscall_state.
8436 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8437 Maintain syscall_state and syscalls_to_catch across exec.
8438 (get_syscall_trapinfo): New function, proxy to the_low_target.
8439 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8440 (linux_low_filter_event): Toggle syscall_state entry/return for
8441 syscall traps, and set it ignored for all others.
8442 (gdb_catching_syscalls_p): New function.
8443 (gdb_catch_this_syscall_p): New function.
8444 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8445 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8446 (linux_supports_catch_syscall): New function.
8447 (linux_target_ops): Install it.
8448 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8449 (the_low_target): Install it.
8450
8451 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8452
8453 * acinclude.m4: Include new ../warning.m4 file.
8454 * configure: Regenerated.
8455 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8456
8457 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8458
8459 * ax.c (is_goto_target): Mark static.
8460 * linux-low.c (register_addr): Likewise.
8461 (linux_fetch_registers, linux_store_registers): Likewise.
8462 * mem-break.c (any_persistent_commands): Fix old prototype.
8463 (add_commands_to_breakpoint): Mark static.
8464 * regcache.c (find_register_by_name): Delete unused func.
8465 * remote-utils.c (hex_or_minus_one): Mark static.
8466 * server.c (monitor_show_help): Mark static.
8467 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8468 handle_v_requests): Likewise.
8469
8470 2016-01-12 Pedro Alves <palves@redhat.com>
8471
8472 Remove use of the registered trademark symbol throughout.
8473
8474 2016-01-08 Yao Qi <yao.qi@linaro.org>
8475
8476 * remote-utils.c (getpkt): If c is '\003', call target hook
8477 request_interrupt.
8478
8479 2016-01-06 Yao Qi <yao.qi@linaro.org>
8480
8481 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8482 linux-aarch32-low.c.
8483 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8484 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8485 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8486 (thumb2_breakpoint): Declare.
8487 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8488 linux-aarch32-low.h.
8489 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8490 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8491 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8492
8493 2016-01-01 Joel Brobecker <brobecker@adacore.com>
8494
8495 * gdbreplay.c (gdbreplay_version): Change copyright year in
8496 version message.
8497 * server.c (gdbserver_version): Likewise.
8498
8499 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8500
8501 * server.c (crc32_table): Delete.
8502 (crc32): Use libiberty's xcrc32 function.
8503
8504 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8505
8506 * lynx-low.c (lynx_delete_thread_callback): New function.
8507 (lynx_mourn): Properly delete our process and all of its
8508 threads. Remove call to clear_inferiors.
8509
8510 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8511
8512 * target.c (thread_search_callback): Add check that
8513 the thread_stopped target callback is not NULL before
8514 calling it.
8515
8516 2015-12-21 Yao Qi <yao.qi@linaro.org>
8517
8518 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8519 arm breakpoint.
8520
8521 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8522
8523 * server.c (handle_query): Call target_supports_software_single_step.
8524
8525 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8526
8527 * linux-low.c (single_step): New function.
8528 (linux_resume_one_lwp_throw): Call single_step.
8529 (start_step_over): Likewise.
8530
8531 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8532
8533 * Makefile.in (SFILES): Append arch/arm-linux.c,
8534 arch/arm-get-next-pcs.c.
8535 (arm-linux.o): New rule.
8536 (arm-get-next-pcs.o): New rule.
8537 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8538 arm-linux.o.
8539 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8540 to linux-aarch32-low.c.
8541 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8542 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8543 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8544 (thumb2_breakpoint_len): Likewise.
8545 (arm_is_thumb_mode): Make non-static.
8546 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8547 from linux-aarch32-low.c.
8548 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8549 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8550 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8551 (thumb2_breakpoint_len): Likewise.
8552 (arm_is_thumb_mode): New declaration.
8553 * linux-arm-low.c: Include arch/arm-linux.h
8554 aarch/arm-get-next-pcs.h, sys/syscall.h.
8555 (get_next_pcs_ops): New struct.
8556 (get_next_pcs_addr_bits_remove): New function.
8557 (get_next_pcs_is_thumb): New function.
8558 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8559 (arm_sigreturn_next_pc): Likewise.
8560 (get_next_pcs_syscall_next_pc): Likewise.
8561 (arm_gdbserver_get_next_pcs): Likewise.
8562 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8563 Initialize.
8564 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8565 * server.h: Include gdb_vecs.h.
8566
8567 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8568
8569 * Makefile.in (SFILES): Append common/common-regcache.c.
8570 (OBS): Append common-regcache.o.
8571 (common-regcache.o): New rule.
8572 * regcache.c (init_register_cache): Initialize cache to
8573 REG_UNAVAILABLE.
8574 (regcache_raw_read_unsigned): New function.
8575 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8576 register_status enum.
8577
8578 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8579
8580 * linux-aarch64-low.c (the_low_targets): Rename
8581 breakpoint_reinsert_addr to get_next_pcs.
8582 * linux-arm-low.c (the_low_targets): Likewise.
8583 * linux-bfin-low.c (the_low_targets): Likewise.
8584 * linux-cris-low.c (the_low_targets): Likewise.
8585 * linux-crisv32-low.c (the_low_targets): Likewise.
8586 * linux-low.c (can_software_single_step): Likewise.
8587 (install_software_single_step_breakpoints): New function.
8588 (start_step_over): Use install_software_single_step_breakpoints.
8589 * linux-low.h: New CORE_ADDR vector.
8590 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8591 get_next_pcs.
8592 * linux-mips-low.c (the_low_targets): Likewise.
8593 * linux-nios2-low.c (the_low_targets): Likewise.
8594 * linux-sparc-low.c (the_low_targets): Likewise.
8595
8596 2015-12-17 Pedro Alves <palves@redhat.com>
8597
8598 * linux-low.c (linux_kill_one_lwp): Remove references to
8599 LinuxThreads.
8600 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8601 to 'kill'.
8602 (linux_init_signals): Delete.
8603 (initialize_low): Adjust.
8604 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8605
8606 2015-12-16 Pedro Alves <palves@redhat.com>
8607
8608 * configure.ac (compiler warning flags): When testing a
8609 -Wno-foo option, check whether -Wfoo works instead.
8610 * configure: Regenerate.
8611
8612 2015-12-11 Don Breazeal <donb@codesourcery.com>
8613
8614 * server.c (process_serial_event): Don't exit from gdbserver
8615 in remote mode if there are still active inferiors.
8616
8617 2015-12-11 Yao Qi <yao.qi@linaro.org>
8618
8619 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8620 arm_breakpoint_at if the process is 32-bit.
8621
8622 2015-12-11 Yao Qi <yao.qi@linaro.org>
8623
8624 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8625 arm breakpoint.
8626
8627 2015-12-07 Yao Qi <yao.qi@linaro.org>
8628
8629 * configure.srv: Append arm.o to srv_tgtobj for
8630 aarch64*-*-linux* target.
8631 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8632 from linux-arm-low.c.
8633 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8634 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8635 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8636 (thumb2_breakpoint_len): Likewise.
8637 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8638 (arm_breakpoint_kinds): Likewise.
8639 (arm_breakpoint_kind_from_pc): Likewise.
8640 (arm_sw_breakpoint_from_kind): Likewise.
8641 (arm_breakpoint_kind_from_current_state): Likewise.
8642 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8643 (arm_sw_breakpoint_from_kind): Declare.
8644 (arm_breakpoint_kind_from_current_state): Declare.
8645 (arm_breakpoint_at): Declare.
8646 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8647 arm_sw_breakpoint_from_kind if process is 32-bit.
8648 (aarch64_breakpoint_kind_from_pc): New function.
8649 (aarch64_breakpoint_kind_from_current_state): New function.
8650 (the_low_target): Initialize fields breakpoint_kind_from_pc
8651 and breakpoint_kind_from_current_state.
8652 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8653 linux-aarch32-low.c.
8654 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8655 (arm_breakpoint, arm_breakpoint_len): Likewise.
8656 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8657 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8658 (arm_is_thumb_mode): Likewise.
8659 (arm_breakpoint_at): Likewise.
8660 (arm_breakpoint_kind_from_pc): Likewise.
8661 (arm_sw_breakpoint_from_kind): Likewise.
8662 (arm_breakpoint_kind_from_current_state): Likewise.
8663
8664 Revert:
8665 2015-08-04 Yao Qi <yao.qi@linaro.org>
8666
8667 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8668 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8669 * server.c (extended_protocol): Remove "static".
8670 * server.h (extended_protocol): Declare it.
8671
8672 2015-12-04 Josh Stone <jistone@redhat.com>
8673
8674 * target.h (struct target_ops) <arch_setup>: Rename to ...
8675 (struct target_ops) <post_create_inferior>: ... this.
8676 (target_arch_setup): Rename to ...
8677 (target_post_create_inferior): ... this, calling post_create_inferior.
8678 * server.c (start_inferior): Update target_arch_setup calls to
8679 target_post_create_inferior.
8680 * linux-low.c (linux_low_ptrace_options): Forward declare.
8681 (linux_arch_setup): Update its comment for general use.
8682 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8683 (struct linux_target_ops): Use linux_post_create_inferior.
8684 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8685 to post_create_inferior.
8686 * nto-low.c (struct nto_target_ops): Likewise.
8687 * spu-low.c (struct spu_target_ops): Likewise.
8688 * win32-low.c (struct win32_target_ops): Likewise.
8689
8690 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
8691
8692 * linux-arm-low.c: Remove duplicate arch/arm.h include.
8693
8694 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8695
8696 * linux-arm-low.c (arm_reinsert_addr): Remove function.
8697 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
8698 * linux-cris-low.c (cris_reinsert_addr> Remove function.
8699 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8700 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
8701 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8702 * linux-mips-low.c (mips_reinsert_addr): Remove function.
8703 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8704 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
8705 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8706 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
8707 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8708
8709 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8710
8711 * linux-low.c (linux_look_up_symbols): Don't call
8712 linux_supports_traceclone.
8713 * linux-low.h (thread_db_init): Remove use_events argument.
8714 * thread-db.c (thread_db_use_event): Remove global variable.
8715 (struct thread_db) <td_thr_event_enable_p>: Remove field.
8716 (struct thread_db) <td_create_bp>: Remove field.
8717 (thread_db_create_event): Remove function.
8718 (thread_db_enable_reporting): Likewise.
8719 (find_one_thread): Don't check for thread_db_use_events.
8720 (attach_thread): Likewise.
8721 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
8722 (try_thread_db_load_1): Don't check for thread_db_use_events.
8723 (thread_db_init): Remove use_events argument and thread events
8724 handling.
8725 (remove_thread_event_breakpoints): Remove function.
8726 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
8727
8728 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8729
8730 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
8731 New function.
8732 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8733 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
8734 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8735 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
8736 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
8737 Initialize.
8738 * linux-crisv32-low.c (cris_supports_hardware_single_step):
8739 New function.
8740 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8741 * linux-low.c (can_hardware_single_step): Use
8742 supports_hardware_single_step.
8743 (can_software_single_step): New function.
8744 (start_step_over): Call can_software_single_step.
8745 (linux_supports_hardware_single_step): New function.
8746 (struct target_ops) <supports_software_single_step>: Initialize.
8747 * linux-low.h (struct linux_target_ops)
8748 <supports_hardware_single_step>: Initialize.
8749 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
8750 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8751 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
8752 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
8753 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
8754 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8755 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
8756 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8757 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
8758 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
8759 Initialize.
8760 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
8761 (struct linux_target_ops) <tile_supports_hardware_single_step>:
8762 Initialize.
8763 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
8764 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8765 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
8766 New function.
8767 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8768 * target.h (struct target_ops): <supports_software_single_step>:
8769 New field.
8770 (target_supports_software_single_step): New macro.
8771
8772 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8773
8774 * linux-low.c (linux_wait_1): Fix pc advance condition.
8775 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
8776 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
8777
8778 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8779
8780 * linux-arm-low.c (arm_is_thumb_mode): New function.
8781 (arm_breakpoint_at): Use arm_is_thumb_mode.
8782 (arm_breakpoint_kind_from_current_state): New function.
8783 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
8784 Initialize.
8785 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
8786 (linux_breakpoint_kind_from_current_state): New function.
8787 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
8788 * linux-low.h (struct linux_target_ops)
8789 <breakpoint_kind_from_current_state>: New field.
8790 * target.h (struct target_ops): Likewise.
8791 (target_breakpoint_kind_from_current_state): New macro.
8792
8793 2015-11-30 Pedro Alves <palves@redhat.com>
8794
8795 * linux-low.c (linux_resume): Wake up the event loop before
8796 returning.
8797
8798 2015-11-30 Pedro Alves <palves@redhat.com>
8799
8800 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
8801 check.
8802 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
8803 to -1.
8804 * target.c (struct thread_search): New structure.
8805 (thread_search_callback): New function.
8806 (prev_general_thread): New global.
8807 (prepare_to_access_memory, done_accessing_memory): New functions.
8808 * target.h (prepare_to_access_memory, done_accessing_memory):
8809 Replace macros with function declarations.
8810
8811 2015-11-30 Pedro Alves <palves@redhat.com>
8812
8813 PR 14618
8814 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
8815 report TARGET_WAITKIND_NO_RESUMED.
8816 * remote-utils.c (prepare_resume_reply): Handle
8817 TARGET_WAITKIND_NO_RESUMED.
8818 * server.c (report_no_resumed): New global.
8819 (handle_query) <qSupported>: Handle "no-resumed+". Report
8820 "no-resumed+" support.
8821 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
8822 return error if the client doesn't support no-resumed events.
8823 (push_stop_notification): New function.
8824 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
8825 events if the client supports them.
8826
8827 2015-11-30 Pedro Alves <palves@redhat.com>
8828
8829 * linux-low.c (thread_still_has_status_pending_p): Don't check
8830 vCont;t here.
8831 (lwp_resumed): New function.
8832 (status_pending_p_callback): Return early if the LWP is not
8833 supposed to be resumed.
8834
8835 2015-11-30 Pedro Alves <palves@redhat.com>
8836
8837 * linux-low.c (handle_extended_wait): Assert that the LWP's
8838 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
8839 thread create events, leave the new child's status pending.
8840 (linux_low_filter_event): If GDB wants to hear about thread exit
8841 events, leave the LWP marked dead and don't delete it.
8842 (linux_wait_for_event_filtered): Don't check for thread exit.
8843 (filter_exit_event): New function.
8844 (linux_wait_1): Use it, when returning an exit event.
8845 (linux_resume_one_lwp_throw): Assert that the LWP's
8846 waitstatus is TARGET_WAITKIND_IGNORE.
8847 * remote-utils.c (prepare_resume_reply): Handle
8848 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
8849 * server.c (report_thread_events): New global.
8850 (handle_general_set): Handle QThreadEvents.
8851 (handle_query) <qSupported>: Handle and report QThreadEvents+;
8852 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
8853 TARGET_WAITKIND_THREAD_EXITED.
8854 * server.h (report_thread_events): Declare.
8855
8856 2015-11-30 Pedro Alves <palves@redhat.com>
8857
8858 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
8859 the thread's last_resume_kind was resume_stop.
8860
8861 2015-11-30 Pedro Alves <palves@redhat.com>
8862
8863 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
8864 before returning.
8865
8866 2015-11-30 Pedro Alves <palves@redhat.com>
8867
8868 * server.c (handle_v_requests): Handle vCtrlC.
8869
8870 2015-11-30 Pedro Alves <palves@redhat.com>
8871
8872 * gdbthread.h (find_any_thread_of_pid): Declare.
8873 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
8874 functions.
8875 * server.c (handle_query): If current_thread is NULL, look for
8876 another thread of the selected process.
8877
8878 2015-11-26 Daniel Colascione <dancol@dancol.org>
8879 Simon Marchi <simon.marchi@ericsson.com>
8880
8881 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
8882 * server.c (handle_qxfer_threads_worker): Refactor to include thread
8883 name in reply.
8884 * target.h (struct target_ops) <thread_name>: New field.
8885 (target_thread_name): New macro.
8886
8887 2015-11-23 Joel Brobecker <brobecker@adacore.com>
8888
8889 * regcache.h (regcache_invalidate_pid): Add declaration.
8890 * regcache.c (regcache_invalidate_pid): New function, extracted
8891 from regcache_invalidate.
8892 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
8893 Add trivial documentation comment.
8894 * lynx-low.c: Use regcache_invalidate_pid instead of
8895 regcache_invalidate.
8896
8897 2015-11-23 Joel Brobecker <brobecker@adacore.com>
8898
8899 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
8900 and Elf64_auxv_t if the target is Android.
8901
8902 2015-11-22 Doug Evans <xdje42@gmail.com>
8903
8904 * target.h: #include <sys/types.h>.
8905
8906 2015-11-19 Pedro Alves <palves@redhat.com>
8907
8908 * linux-low.c (linux_process_qsupported): Change prototype.
8909 Adjust.
8910 * linux-low.h (struct linux_target_ops) <process_qsupported>:
8911 Change prototype.
8912 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
8913 and adjust to loop over all features.
8914 * server.c (handle_query) <qSupported>: Adjust to call
8915 target_process_qsupported once, passing it a vector of unprocessed
8916 features.
8917 * target.h (struct target_ops) <process_qsupported>: Change
8918 prototype.
8919 (target_process_qsupported): Adjust.
8920
8921 2015-11-19 Pedro Alves <palves@redhat.com>
8922
8923 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
8924 mode.
8925 * configure: Regenerate.
8926
8927 2015-11-19 Pedro Alves <palves@redhat.com>
8928
8929 * configure: Regenerate.
8930
8931 2015-11-19 Yao Qi <yao.qi@linaro.org>
8932
8933 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
8934 type to uint32_t.
8935
8936 2015-11-19 Yao Qi <yao.qi@linaro.org>
8937
8938 * linux-aarch64-low.c (enum aarch64_operand_type): New.
8939 (struct aarch64_operand): Move enum out.
8940
8941 2015-11-19 Yao Qi <yao.qi@linaro.org>
8942
8943 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
8944 struct user_fpsimd_state *.
8945 (aarch64_store_fpregset): Likewise.
8946
8947 2015-11-19 Yao Qi <yao.qi@linaro.org>
8948
8949 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
8950 struct user_pt_regs *.
8951 (aarch64_store_gregset): Likewise.
8952
8953 2015-11-18 Pedro Alves <palves@redhat.com>
8954
8955 * Makefile.in (all_object_files): Add $IPA_OBJS.
8956
8957 2015-11-17 Pedro Alves <palves@redhat.com>
8958
8959 * win32-low.c (win32_resume): Use gdb_signal_from_host,
8960 GDB_SIGNAL_0 and gdb_signal_to_string.
8961
8962 2015-11-17 Pedro Alves <palves@redhat.com>
8963
8964 * win32-low.c (handle_output_debug_string): Remove parameter.
8965 (win32_kill): Remove our_status local and adjust call to
8966 handle_output_debug_string.
8967 (get_child_debug_event): Adjust call to
8968 handle_output_debug_string.
8969
8970 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8971
8972 * linux-mips-low.c (mips_fill_gregset): Add cast.
8973 (mips_store_gregset): Likewise.
8974 (mips_fill_fpregset): Likewise.
8975 (mips_store_fpregset): Likewise.
8976
8977 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8978
8979 * linux-mips-low.c (mips_add_watchpoint): Rename private to
8980 priv.
8981
8982 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8983
8984 * linux-mips-low.c (mips_linux_new_thread): Change type of
8985 watch_type to enum target_hw_bp_type.
8986
8987 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8988
8989 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
8990 Change return type to arm_hwbp_type.
8991
8992 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8993
8994 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
8995 (arm_store_gregset): Likewise.
8996 * linux-arm-low.c (arm_get_hwcap): Likewise.
8997 (arm_read_description): Likewise.
8998
8999 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9000
9001 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9002
9003 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9004
9005 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9006 (ppc_fill_vsxregset): Likewise.
9007 (ppc_store_vsxregset): Likewise.
9008 (ppc_fill_vrregset): Likewise.
9009 (ppc_store_vrregset): Likewise.
9010 (ppc_fill_evrregset): Likewise.
9011 (ppc_store_evrregset): Likewise.
9012
9013 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9014
9015 * linux-ppc-low.c (ppc_usrregs_info): Remove
9016 forward-declaration.
9017 (ppc_arch_setup): Move lower in file.
9018
9019 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9020
9021 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9022 (ps_pdwrite): Likewise.
9023
9024 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9025
9026 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9027 to after assert checks.
9028
9029 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9030
9031 * proc-service.c (ps_pdread): Add/adjust casts.
9032 (ps_pdwrite): Add/adjust casts.
9033
9034 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9035
9036 * server.c (handle_search_memory_1): Cast return value of
9037 memmem.
9038
9039 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9040
9041 * server.c (write_qxfer_response): Change type of data to
9042 gdb_byte *.
9043
9044 2015-10-29 Pedro Alves <palves@redhat.com>
9045
9046 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9047
9048 2015-10-29 Pedro Alves <palves@redhat.com>
9049
9050 * tracepoint.c (clear_installed_tracepoints): Add casts.
9051
9052 2015-10-29 Pedro Alves <palves@redhat.com>
9053
9054 * server.c (handle_v_cont, process_serial_event): Add enum
9055 gdb_signal casts to signal parsing code.
9056
9057 2015-10-29 Pedro Alves <palves@redhat.com>
9058
9059 * linux-low.h (NULL_REGSET): Define.
9060 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9061 * linux-arm-low.c (arm_regsets): Likewise.
9062 * linux-crisv32-low.c (cris_regsets): Likewise.
9063 * linux-m68k-low.c (m68k_regsets): Likewise.
9064 * linux-mips-low.c (mips_regsets): Likewise.
9065 * linux-nios2-low.c (nios2_regsets): Likewise.
9066 * linux-ppc-low.c (ppc_regsets): Likewise.
9067 * linux-s390-low.c (s390_regsets): Likewise.
9068 * linux-sh-low.c (sh_regsets): Likewise.
9069 * linux-sparc-low.c (sparc_regsets): Likewise.
9070 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9071 * linux-tile-low.c (tile_regsets): Likewise.
9072 * linux-x86-low.c (x86_regsets): Likewise.
9073 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9074
9075 2015-10-29 Pedro Alves <palves@redhat.com>
9076
9077 * linux-low.h (NULL_REGSET): Define.
9078 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9079 * linux-arm-low.c (arm_regsets): Likewise.
9080 * linux-crisv32-low.c (cris_regsets): Likewise.
9081 * linux-m68k-low.c (m68k_regsets): Likewise.
9082 * linux-mips-low.c (mips_regsets): Likewise.
9083 * linux-nios2-low.c (nios2_regsets): Likewise.
9084 * linux-ppc-low.c (ppc_regsets): Likewise.
9085 * linux-s390-low.c (s390_regsets): Likewise.
9086 * linux-sh-low.c (sh_regsets): Likewise.
9087 * linux-sparc-low.c (sparc_regsets): Likewise.
9088 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9089 * linux-tile-low.c (tile_regsets): Likewise.
9090 * linux-x86-low.c (x86_regsets): Likewise.
9091 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9092
9093 2015-10-26 Doug Evans <dje@google.com>
9094
9095 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9096
9097 2015-10-26 Doug Evans <dje@google.com>
9098
9099 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9100
9101 2015-10-26 Doug Evans <dje@google.com>
9102
9103 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9104 for debug_printf.
9105 (attach_thread, find_new_threads_callback): Ditto.
9106
9107 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9108
9109 * mem-break.h (set_breakpoint_data): Remove.
9110
9111 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9112
9113 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9114 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9115 (initialize_low): Remove set_breakpoint_data call.
9116 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9117 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9118 (initialize_low): Remove set_breakpoint_data call.
9119 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9120 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9121 (initialize_low): Remove set_breakpoint_data call.
9122
9123 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9124
9125 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9126 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9127 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9128 * target.h (target_breakpoint_kind_from_pc): New macro.
9129
9130 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9131
9132 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9133 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9134 the default breakpoint kind.
9135
9136 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9137
9138 * linux-arm-low.c (arm_supports_z_point_type): Add software
9139 breakpoint support.
9140
9141 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9142
9143 * linux-arm-low.c: Refactor breakpoint definitions.
9144 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9145 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9146
9147 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9148
9149 * Makefile.in: Add arm.c/o.
9150 * configure.srv: Likewise.
9151 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9152 (arm_breakpoint_kind_from_pc): New function.
9153 (arm_sw_breakpoint_from_kind): Return proper kind.
9154 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9155
9156 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9157
9158 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9159 removal.
9160 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9161 (struct raw_breakpoint) <size>: Remove.
9162 (struct raw_breakpoint) <kind>: Add.
9163 (bp_size): New function.
9164 (bp_opcode): Likewise.
9165 (find_raw_breakpoint_at): Adjust for kind.
9166 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9167 (remove_memory_breakpoint): Adjust for kind call bp_size.
9168 (set_raw_breakpoint_at): Adjust for kind.
9169 (set_breakpoint): Likewise.
9170 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9171 (delete_raw_breakpoint): Adjust for kind.
9172 (delete_breakpoint): Likewise.
9173 (find_gdb_breakpoint): Likewise.
9174 (set_gdb_breakpoint_1): Likewise.
9175 (set_gdb_breakpoint): Likewise.
9176 (delete_gdb_breakpoint_1): Likewise.
9177 (delete_gdb_breakpoint): Likewise.
9178 (uninsert_raw_breakpoint): Likewise.
9179 (reinsert_raw_breakpoint): Likewise.
9180 (set_breakpoint_data): Remove.
9181 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9182 (check_mem_read): Adjust for kind call bp_size.
9183 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9184 (clone_one_breakpoint): Adjust for kind.
9185 * mem-break.h (set_gdb_breakpoint): Likewise.
9186 (delete_gdb_breakpoint): Likewise.
9187 * server.c (process_serial_event): Likewise.
9188
9189 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9190
9191 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9192 (struct linux_target_ops) <breakpoint>: Remove.
9193 (struct linux_target_ops) <breakpoint_len>: Remove.
9194 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9195 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9196 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9197 (arm_sw_breakpoint_from_kind): New function.
9198 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9199 (struct linux_target_ops) <breakpoint>: Remove.
9200 (struct linux_target_ops) <breakpoint_len>: Remove.
9201 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9202 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9203 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9204 (struct linux_target_ops) <breakpoint>: Remove.
9205 (struct linux_target_ops) <breakpoint_len>: Remove.
9206 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9207 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9208 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9209 (struct linux_target_ops) <breakpoint>: Remove.
9210 (struct linux_target_ops) <breakpoint_len>: Remove.
9211 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9212 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9213 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9214 and sw_breakpoint_from_kind to increment the pc.
9215 (linux_breakpoint_kind_from_pc): New function.
9216 (linux_sw_breakpoint_from_kind): New function.
9217 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9218 (initialize_low): Call breakpoint_kind_from_pc and
9219 sw_breakpoint_from_kind to replace breakpoint_data/len.
9220 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9221 New field.
9222 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9223 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9224 (struct linux_target_ops) <breakpoint>: Remove.
9225 (struct linux_target_ops) <breakpoint_len>: Remove.
9226 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9227 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9228 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9229 (struct linux_target_ops) <breakpoint>: Remove.
9230 (struct linux_target_ops) <breakpoint_len>: Remove.
9231 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9232 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9233 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9234 (struct linux_target_ops) <breakpoint>: Remove.
9235 (struct linux_target_ops) <breakpoint_len>: Remove.
9236 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9237 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9238 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9239 (struct linux_target_ops) <breakpoint>: Remove.
9240 (struct linux_target_ops) <breakpoint_len>: Remove.
9241 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9242 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9243 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9244 (struct linux_target_ops) <breakpoint>: Remove.
9245 (struct linux_target_ops) <breakpoint_len>: Remove.
9246 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9247 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9248 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9249 (struct linux_target_ops) <breakpoint>: Remove.
9250 (struct linux_target_ops) <breakpoint_len>: Remove.
9251 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9252 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9253 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9254 (struct linux_target_ops) <breakpoint>: Remove.
9255 (struct linux_target_ops) <breakpoint_len>: Remove.
9256 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9257 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9258 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9259 (struct linux_target_ops) <breakpoint>: Remove.
9260 (struct linux_target_ops) <breakpoint_len>: Remove.
9261 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9262 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9263 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9264 (struct linux_target_ops) <breakpoint>: Remove.
9265 (struct linux_target_ops) <breakpoint_len>: Remove.
9266 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9267 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9268 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9269 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9270 (struct linux_target_ops) <breakpoint>: Remove.
9271 (struct linux_target_ops) <breakpoint_len>: Remove.
9272 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9273 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9274 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9275 (struct linux_target_ops) <breakpoint>: Remove.
9276 (struct linux_target_ops) <breakpoint_len>: Remove.
9277 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9278 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9279
9280 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9281
9282 * linux-cris-low.c (cris_get_pc): Remove void arg.
9283
9284 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9285
9286 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9287 variable name.
9288
9289 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9290
9291 * inferiors.c (thread_pid_matches_callback): New function.
9292 (find_thread_process): New function.
9293 (remove_thread): Reset current_thread.
9294 (remove_process): Assert threads have been removed first.
9295
9296 2015-10-15 Yao Qi <yao.qi@linaro.org>
9297
9298 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9299 if it is 3.
9300 (aarch64_remove_point): Likewise.
9301 * regcache.c (regcache_register_size): New function.
9302
9303 2015-10-12 Yao Qi <yao.qi@linaro.org>
9304
9305 * linux-aarch64-low.c: Update all callers as emit_load_store
9306 is renamed to aarch64_emit_load_store.
9307
9308 2015-10-12 Yao Qi <yao.qi@linaro.org>
9309
9310 * linux-aarch64-low.c: Update all callers of function renaming
9311 from emit_insn to aarch64_emit_insn.
9312
9313 2015-10-12 Yao Qi <yao.qi@linaro.org>
9314
9315 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9316 arch/aarch64-insn.h.
9317 (struct aarch64_memory_operand): Likewise.
9318 (ENCODE): Likewise.
9319 (emit_insn): Move to arch/aarch64-insn.c.
9320 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9321 (emit_load_store): Move to arch/aarch64-insn.c.
9322 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9323 (can_encode_int32): Remove.
9324
9325 2015-10-12 Yao Qi <yao.qi@linaro.org>
9326
9327 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9328 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9329 (aarch64_relocate_instruction): Likewise.
9330 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9331 (struct aarch64_insn_visitor): Likewise.
9332
9333 2015-10-12 Yao Qi <yao.qi@linaro.org>
9334
9335 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9336 (struct aarch64_insn_visitor): New.
9337 (struct aarch64_insn_relocation_data): New.
9338 (aarch64_ftrace_insn_reloc_b): New function.
9339 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9340 (aarch64_ftrace_insn_reloc_cb): Likewise.
9341 (aarch64_ftrace_insn_reloc_tb): Likewise.
9342 (aarch64_ftrace_insn_reloc_adr): Likewise.
9343 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9344 (aarch64_ftrace_insn_reloc_others): Likewise.
9345 (visitor): New.
9346 (aarch64_relocate_instruction): Use visitor.
9347
9348 2015-10-12 Yao Qi <yao.qi@linaro.org>
9349
9350 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9351 int. Add argument buf.
9352 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9353 aarch64_relocate_instruction.
9354
9355 2015-10-12 Yao Qi <yao.qi@linaro.org>
9356
9357 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9358 argument insn. Remove local variable insn. Don't call
9359 target_read_uint32.
9360 (aarch64_install_fast_tracepoint_jump_pad): Call
9361 target_read_uint32.
9362
9363 2015-09-30 Yao Qi <yao.qi@linaro.org>
9364
9365 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9366 (emit_load_store_pair): Likewise.
9367
9368 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9369
9370 * dll.c (match_dll): Add cast(s).
9371 (unloaded_dll): Likewise.
9372 * linux-low.c (second_thread_of_pid_p): Likewise.
9373 (delete_lwp_callback): Likewise.
9374 (count_events_callback): Likewise.
9375 (select_event_lwp_callback): Likewise.
9376 (linux_set_resume_request): Likewise.
9377 * server.c (accumulate_file_name_length): Likewise.
9378 (emit_dll_description): Likewise.
9379 (handle_qxfer_threads_worker): Likewise.
9380 (visit_actioned_threads): Likewise.
9381 * thread-db.c (any_thread_of): Likewise.
9382 * tracepoint.c (same_process_p): Likewise.
9383 (match_blocktype): Likewise.
9384 (build_traceframe_info_xml): Likewise.
9385
9386 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9387
9388 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9389 assignment.
9390 (gdb_unparse_agent_expr): Likewise.
9391 * hostio.c (require_data): Likewise.
9392 (handle_pread): Likewise.
9393 * linux-low.c (disable_regset): Likewise.
9394 (fetch_register): Likewise.
9395 (store_register): Likewise.
9396 (get_dynamic): Likewise.
9397 (linux_qxfer_libraries_svr4): Likewise.
9398 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9399 (set_fast_tracepoint_jump): Likewise.
9400 (uninsert_fast_tracepoint_jumps_at): Likewise.
9401 (reinsert_fast_tracepoint_jumps_at): Likewise.
9402 (validate_inserted_breakpoint): Likewise.
9403 (clone_agent_expr): Likewise.
9404 * regcache.c (init_register_cache): Likewise.
9405 * remote-utils.c (putpkt_binary_1): Likewise.
9406 (decode_M_packet): Likewise.
9407 (decode_X_packet): Likewise.
9408 (look_up_one_symbol): Likewise.
9409 (relocate_instruction): Likewise.
9410 (monitor_output): Likewise.
9411 * server.c (handle_search_memory): Likewise.
9412 (handle_qxfer_exec_file): Likewise.
9413 (handle_qxfer_libraries): Likewise.
9414 (handle_qxfer): Likewise.
9415 (handle_query): Likewise.
9416 (handle_v_cont): Likewise.
9417 (handle_v_run): Likewise.
9418 (captured_main): Likewise.
9419 * target.c (write_inferior_memory): Likewise.
9420 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9421 * tracepoint.c (init_trace_buffer): Likewise.
9422 (add_tracepoint_action): Likewise.
9423 (add_traceframe): Likewise.
9424 (add_traceframe_block): Likewise.
9425 (cmd_qtdpsrc): Likewise.
9426 (cmd_qtdv): Likewise.
9427 (cmd_qtstatus): Likewise.
9428 (response_source): Likewise.
9429 (response_tsv): Likewise.
9430 (cmd_qtnotes): Likewise.
9431 (gdb_collect): Likewise.
9432 (initialize_tracepoint): Likewise.
9433
9434 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9435
9436 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9437 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9438 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9439 <NOP>: New.
9440 (enum aarch64_condition_codes): New enum.
9441 (w0): New static global.
9442 (fp): Likewise.
9443 (lr): Likewise.
9444 (struct aarch64_memory_operand) <type>: New
9445 MEMORY_OPERAND_POSTINDEX type.
9446 (postindex_memory_operand): New helper function.
9447 (emit_ret): New function.
9448 (emit_load_store_pair): New function, factored out of emit_stp
9449 with support for MEMORY_OPERAND_POSTINDEX.
9450 (emit_stp): Rewrite using emit_load_store_pair.
9451 (emit_ldp): New function.
9452 (emit_load_store): Likewise.
9453 (emit_ldr): Mention post-index instruction in comment.
9454 (emit_ldrh): New function.
9455 (emit_ldrb): New function.
9456 (emit_ldrsw): Mention post-index instruction in comment.
9457 (emit_str): Likewise.
9458 (emit_subs): New function.
9459 (emit_cmp): Likewise.
9460 (emit_and): Likewise.
9461 (emit_orr): Likewise.
9462 (emit_orn): Likewise.
9463 (emit_eor): Likewise.
9464 (emit_mvn): Likewise.
9465 (emit_lslv): Likewise.
9466 (emit_lsrv): Likewise.
9467 (emit_asrv): Likewise.
9468 (emit_mul): Likewise.
9469 (emit_sbfm): Likewise.
9470 (emit_sbfx): Likewise.
9471 (emit_ubfm): Likewise.
9472 (emit_ubfx): Likewise.
9473 (emit_csinc): Likewise.
9474 (emit_cset): Likewise.
9475 (emit_nop): Likewise.
9476 (emit_ops_insns): New helper function.
9477 (emit_pop): Likewise.
9478 (emit_push): Likewise.
9479 (aarch64_emit_prologue): New function.
9480 (aarch64_emit_epilogue): Likewise.
9481 (aarch64_emit_add): Likewise.
9482 (aarch64_emit_sub): Likewise.
9483 (aarch64_emit_mul): Likewise.
9484 (aarch64_emit_lsh): Likewise.
9485 (aarch64_emit_rsh_signed): Likewise.
9486 (aarch64_emit_rsh_unsigned): Likewise.
9487 (aarch64_emit_ext): Likewise.
9488 (aarch64_emit_log_not): Likewise.
9489 (aarch64_emit_bit_and): Likewise.
9490 (aarch64_emit_bit_or): Likewise.
9491 (aarch64_emit_bit_xor): Likewise.
9492 (aarch64_emit_bit_not): Likewise.
9493 (aarch64_emit_equal): Likewise.
9494 (aarch64_emit_less_signed): Likewise.
9495 (aarch64_emit_less_unsigned): Likewise.
9496 (aarch64_emit_ref): Likewise.
9497 (aarch64_emit_if_goto): Likewise.
9498 (aarch64_emit_goto): Likewise.
9499 (aarch64_write_goto_address): Likewise.
9500 (aarch64_emit_const): Likewise.
9501 (aarch64_emit_call): Likewise.
9502 (aarch64_emit_reg): Likewise.
9503 (aarch64_emit_pop): Likewise.
9504 (aarch64_emit_stack_flush): Likewise.
9505 (aarch64_emit_zero_ext): Likewise.
9506 (aarch64_emit_swap): Likewise.
9507 (aarch64_emit_stack_adjust): Likewise.
9508 (aarch64_emit_int_call_1): Likewise.
9509 (aarch64_emit_void_call_2): Likewise.
9510 (aarch64_emit_eq_goto): Likewise.
9511 (aarch64_emit_ne_goto): Likewise.
9512 (aarch64_emit_lt_goto): Likewise.
9513 (aarch64_emit_le_goto): Likewise.
9514 (aarch64_emit_gt_goto): Likewise.
9515 (aarch64_emit_ge_got): Likewise.
9516 (aarch64_emit_ops_impl): New static global variable.
9517 (aarch64_emit_ops): New target function, return
9518 &aarch64_emit_ops_impl.
9519 (struct linux_target_ops): Install it.
9520
9521 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9522
9523 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9524 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9525 aarch64-ipa.o.
9526 * linux-aarch64-ipa.c: New file.
9527 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9528 and endian.h.
9529 (aarch64_get_thread_area): New target method.
9530 (extract_signed_bitfield): New helper function.
9531 (aarch64_decode_ldr_literal): New function.
9532 (enum aarch64_opcodes): New enum.
9533 (struct aarch64_register): New struct.
9534 (struct aarch64_operand): New struct.
9535 (x0): New static global.
9536 (x1): Likewise.
9537 (x2): Likewise.
9538 (x3): Likewise.
9539 (x4): Likewise.
9540 (w2): Likewise.
9541 (ip0): Likewise.
9542 (sp): Likewise.
9543 (xzr): Likewise.
9544 (aarch64_register): New helper function.
9545 (register_operand): Likewise.
9546 (immediate_operand): Likewise.
9547 (struct aarch64_memory_operand): New struct.
9548 (offset_memory_operand): New helper function.
9549 (preindex_memory_operand): Likewise.
9550 (enum aarch64_system_control_registers): New enum.
9551 (ENCODE): New macro.
9552 (emit_insn): New helper function.
9553 (emit_b): New function.
9554 (emit_bcond): Likewise.
9555 (emit_cb): Likewise.
9556 (emit_tb): Likewise.
9557 (emit_blr): Likewise.
9558 (emit_stp): Likewise.
9559 (emit_ldp_q_offset): Likewise.
9560 (emit_stp_q_offset): Likewise.
9561 (emit_load_store): Likewise.
9562 (emit_ldr): Likewise.
9563 (emit_ldrsw): Likewise.
9564 (emit_str): Likewise.
9565 (emit_ldaxr): Likewise.
9566 (emit_stxr): Likewise.
9567 (emit_stlr): Likewise.
9568 (emit_data_processing_reg): Likewise.
9569 (emit_data_processing): Likewise.
9570 (emit_add): Likewise.
9571 (emit_sub): Likewise.
9572 (emit_mov): Likewise.
9573 (emit_movk): Likewise.
9574 (emit_mov_addr): Likewise.
9575 (emit_mrs): Likewise.
9576 (emit_msr): Likewise.
9577 (emit_sevl): Likewise.
9578 (emit_wfe): Likewise.
9579 (append_insns): Likewise.
9580 (can_encode_int32_in): New helper function.
9581 (aarch64_relocate_instruction): New function.
9582 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9583 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9584 (struct linux_target_ops): Install aarch64_get_thread_area,
9585 aarch64_install_fast_tracepoint_jump_pad and
9586 aarch64_get_min_fast_tracepoint_insn_len.
9587
9588 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9589
9590 * Makefile.in (aarch64-insn.o): New rule.
9591 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9592
9593 2015-09-21 Yao Qi <yao.qi@linaro.org>
9594
9595 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9596
9597 2015-09-21 Yao Qi <yao.qi@linaro.org>
9598
9599 * tracepoint.c (max_jump_pad_size): Remove.
9600
9601 2015-09-18 Yao Qi <yao.qi@linaro.org>
9602
9603 * linux-aarch64-low.c: Don't include sys/uio.h.
9604 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9605
9606 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
9607
9608 * tracepoint.c (eval_result_type): Change prototype.
9609 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9610
9611 2015-09-15 Pedro Alves <palves@redhat.com>
9612
9613 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9614 Check whether to report exec events instead of checking whether
9615 multiprocess is enabled.
9616
9617 2015-09-15 Pedro Alves <palves@redhat.com>
9618
9619 PR remote/18965
9620 * remote-utils.c (prepare_resume_reply): Merge
9621 TARGET_WAITKIND_VFORK_DONE switch case with the
9622 TARGET_WAITKIND_FORKED case.
9623
9624 2015-09-15 Yao Qi <yao.qi@linaro.org>
9625
9626 * server.c (handle_query): Check string comparison using
9627 "else if" instead of "if".
9628
9629 2015-09-15 Yao Qi <yao.qi@linaro.org>
9630
9631 * server.c (vCont_supported): New global variable.
9632 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9633 matches. Append ";vContSupported+" to own_buf.
9634 (handle_v_requests): Append ";s;S" to own_buf if target supports
9635 hardware single step or vCont_supported is false.
9636 (capture_main): Set vCont_supported to zero.
9637
9638 2015-09-15 Yao Qi <yao.qi@linaro.org>
9639
9640 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9641 it to ...
9642 (linux_supports_hardware_single_step): ... New function.
9643 (linux_target_ops): Update.
9644 * lynx-low.c (lynx_target_ops): Set field
9645 supports_hardware_single_step to target_can_do_hardware_single_step.
9646 * nto-low.c (nto_target_ops): Likewise.
9647 * spu-low.c (spu_target_ops): Likewise.
9648 * win32-low.c (win32_target_ops): Likewise.
9649 * target.c (target_can_do_hardware_single_step): New function.
9650 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9651 Remove. <supports_hardware_single_step>: New field.
9652 (target_supports_conditional_breakpoints): Remove.
9653 (target_supports_hardware_single_step): New macro.
9654 (target_can_do_hardware_single_step): Declare.
9655 * server.c (handle_query): Use target_supports_hardware_single_step
9656 instead of target_supports_conditional_breakpoints.
9657
9658 2015-09-15 Yao Qi <yao.qi@linaro.org>
9659
9660 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9661 function.
9662 (struct linux_target_ops the_low_target): Install
9663 aarch64_linux_siginfo_fixup.
9664
9665 2015-09-11 Don Breazeal <donb@codesourcery.com>
9666 Luis Machado <lgustavo@codesourcery.com>
9667
9668 * linux-low.c (linux_mourn): Static declaration.
9669 (linux_arch_setup): Move in front of
9670 handle_extended_wait.
9671 (linux_arch_setup_thread): New function.
9672 (handle_extended_wait): Handle exec events. Call
9673 linux_arch_setup_thread. Make event_lwp argument a
9674 pointer-to-a-pointer.
9675 (check_zombie_leaders): Do not check stopped threads.
9676 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9677 (linux_low_filter_event): Add lwp and thread for exec'ing
9678 non-leader thread if leader thread has been deleted.
9679 Refactor code into linux_arch_setup_thread and call it.
9680 Pass child lwp pointer by reference to handle_extended_wait.
9681 (linux_wait_for_event_filtered): Update comment.
9682 (linux_wait_1): Prevent clobbering exec event status.
9683 (linux_supports_exec_events): New function.
9684 (linux_target_ops) <supports_exec_events>: Initialize new member.
9685 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9686 new member.
9687 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9688 * server.c (report_exec_events): New global variable.
9689 (handle_query): Handle qSupported query for exec-events feature.
9690 (captured_main): Initialize report_exec_events.
9691 * server.h (report_exec_events): Declare new global variable.
9692 * target.h (struct target_ops) <supports_exec_events>: New
9693 member.
9694 (target_supports_exec_events): New macro.
9695 * win32-low.c (win32_target_ops) <supports_exec_events>:
9696 Initialize new member.
9697
9698 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
9699
9700 * linux-low.c (linux_low_enable_btrace): Remove.
9701 (linux_target_ops): Replace linux_low_enable_btrace with
9702 linux_enable_btrace.
9703
9704 2015-09-03 Yao Qi <yao.qi@linaro.org>
9705
9706 * linux-aarch64-low.c (aarch64_insert_point): Call
9707 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
9708 returns true.
9709
9710 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
9711
9712 * linux-low.c (check_stopped_by_breakpoint): Use
9713 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
9714
9715 2015-08-27 Pedro Alves <palves@redhat.com>
9716
9717 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
9718
9719 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
9720
9721 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
9722 the XNEW-family equivalent.
9723 (compile_bytecodes): Likewise.
9724 * dll.c (loaded_dll): Likewise.
9725 * event-loop.c (append_callback_event): Likewise.
9726 (create_file_handler): Likewise.
9727 (create_file_event): Likewise.
9728 * hostio.c (handle_open): Likewise.
9729 * inferiors.c (add_thread): Likewise.
9730 (add_process): Likewise.
9731 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
9732 * linux-arm-low.c (arm_new_process): Likewise.
9733 (arm_new_thread): Likewise.
9734 * linux-low.c (add_to_pid_list): Likewise.
9735 (linux_add_process): Likewise.
9736 (handle_extended_wait): Likewise.
9737 (add_lwp): Likewise.
9738 (enqueue_one_deferred_signal): Likewise.
9739 (enqueue_pending_signal): Likewise.
9740 (linux_resume_one_lwp_throw): Likewise.
9741 (linux_resume_one_thread): Likewise.
9742 (linux_read_memory): Likewise.
9743 (linux_write_memory): Likewise.
9744 * linux-mips-low.c (mips_linux_new_process): Likewise.
9745 (mips_linux_new_thread): Likewise.
9746 (mips_add_watchpoint): Likewise.
9747 * linux-x86-low.c (initialize_low_arch): Likewise.
9748 * lynx-low.c (lynx_add_process): Likewise.
9749 * mem-break.c (set_raw_breakpoint_at): Likewise.
9750 (set_breakpoint): Likewise.
9751 (add_condition_to_breakpoint): Likewise.
9752 (add_commands_to_breakpoint): Likewise.
9753 (clone_agent_expr): Likewise.
9754 (clone_one_breakpoint): Likewise.
9755 * regcache.c (new_register_cache): Likewise.
9756 * remote-utils.c (look_up_one_symbol): Likewise.
9757 * server.c (queue_stop_reply): Likewise.
9758 (start_inferior): Likewise.
9759 (queue_stop_reply_callback): Likewise.
9760 (handle_target_event): Likewise.
9761 * spu-low.c (fetch_ppc_memory): Likewise.
9762 (store_ppc_memory): Likewise.
9763 * target.c (set_target_ops): Likewise.
9764 * thread-db.c (thread_db_load_search): Likewise.
9765 (try_thread_db_load_1): Likewise.
9766 * tracepoint.c (add_tracepoint): Likewise.
9767 (add_tracepoint_action): Likewise.
9768 (create_trace_state_variable): Likewise.
9769 (cmd_qtdpsrc): Likewise.
9770 (cmd_qtro): Likewise.
9771 (add_while_stepping_state): Likewise.
9772 * win32-low.c (child_add_thread): Likewise.
9773 (get_image_name): Likewise.
9774
9775 2015-08-25 Yao Qi <yao.qi@linaro.org>
9776
9777 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
9778
9779 2015-08-25 Yao Qi <yao.qi@linaro.org>
9780
9781 * Makefile.in (aarch64-linux.o): New rule.
9782 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
9783 srv_tgtobj.
9784 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
9785 (aarch64_init_debug_reg_state): Make it extern.
9786 (aarch64_linux_prepare_to_resume): Remove.
9787
9788 2015-08-25 Yao Qi <yao.qi@linaro.org>
9789
9790 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
9791 lwp_arch_private_info and ptid_of_lwp.
9792
9793 2015-08-25 Yao Qi <yao.qi@linaro.org>
9794
9795 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
9796 Find proc_info by find_process_pid. All callers updated.
9797
9798 2015-08-25 Yao Qi <yao.qi@linaro.org>
9799
9800 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
9801 Remove.
9802 (debug_reg_change_callback): Remove.
9803 (aarch64_notify_debug_reg_change): Remove.
9804
9805 2015-08-25 Yao Qi <yao.qi@linaro.org>
9806
9807 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
9808 Call current_lwp_ptid.
9809
9810 2015-08-25 Yao Qi <yao.qi@linaro.org>
9811
9812 * linux-aarch64-low.c (debug_reg_change_callback): Use
9813 debug_printf.
9814
9815 2015-08-25 Yao Qi <yao.qi@linaro.org>
9816
9817 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
9818
9819 2015-08-25 Yao Qi <yao.qi@linaro.org>
9820
9821 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
9822
9823 2015-08-25 Yao Qi <yao.qi@linaro.org>
9824
9825 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
9826 the code.
9827
9828 2015-08-25 Yao Qi <yao.qi@linaro.org>
9829
9830 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
9831 Remove.
9832 (debug_reg_change_callback): Remove argument entry and add argument
9833 lwp. Remove local variable thread. Don't print thread id in the
9834 debugging output. Don't check whether pid of thread equals to pid.
9835 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
9836 iterate_over_lwps instead find_inferior.
9837
9838 2015-08-24 Pedro Alves <palves@redhat.com>
9839
9840 * inferiors.c (get_first_process): New function.
9841 * inferiors.h (get_first_process): New declaration.
9842 * remote-utils.c (read_ptid): Default to the first process in the
9843 list, instead of to the current thread's process.
9844
9845 2015-08-24 Pedro Alves <palves@redhat.com>
9846
9847 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
9848 * event-loop.c: Likewise.
9849 * remote-utils.c: Likewise.
9850 * tracepoint.c: Likewise.
9851
9852 2015-08-24 Pedro Alves <palves@redhat.com>
9853
9854 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
9855 ptid_get_lwp.
9856
9857 2015-08-21 Pedro Alves <palves@redhat.com>
9858
9859 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
9860 instead of literal 1.
9861
9862 2015-08-21 Pedro Alves <palves@redhat.com>
9863
9864 * tdesc.c (default_description): Explicitly zero-initialize.
9865
9866 2015-08-21 Pedro Alves <palves@redhat.com>
9867
9868 PR gdb/18749
9869 * inferiors.c (remove_thread): Discard any pending stop reply for
9870 this thread.
9871 * server.c (remove_all_on_match_pid): Rename to ...
9872 (remove_all_on_match_ptid): ... this. Work with a filter ptid
9873 instead of a pid.
9874 (discard_queued_stop_replies): Change parameter to a ptid. Now
9875 extern.
9876 (handle_v_kill, kill_inferior_callback, captured_main)
9877 (process_serial_event): Adjust.
9878 * server.h (discard_queued_stop_replies): Declare.
9879
9880 2015-08-21 Pedro Alves <palves@redhat.com>
9881
9882 * linux-low.c (wait_for_sigstop): Always switch to no thread
9883 selected if the previously current thread dies.
9884 * lynx-low.c (lynx_request_interrupt): Use the first thread's
9885 process instead of the current thread's.
9886 * remote-utils.c (input_interrupt): Don't check if there's no
9887 current thread.
9888 * server.c (gdb_read_memory, gdb_write_memory): If setting the
9889 current thread to the general thread fails, error out.
9890 (handle_qxfer_auxv, handle_qxfer_libraries)
9891 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
9892 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
9893 (handle_query): Check if there's a thread selected instead of
9894 checking whether there's any thread in the thread list.
9895 (handle_qxfer_threads, handle_qxfer_btrace)
9896 (handle_qxfer_btrace_conf): Don't error out early if there's no
9897 thread in the thread list.
9898 (handle_v_cont, myresume): Don't set the current thread to the
9899 continue thread.
9900 (process_serial_event) <Hg handling>: Also set thread_id if the
9901 previous general thread is still alive.
9902 (process_serial_event) <g/G handling>: If setting the current
9903 thread to the general thread fails, error out.
9904 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
9905 thread's lwp instead of the current thread's.
9906 * target.c (set_desired_thread): If the desired thread was not
9907 found, leave the current thread pointing to NULL. Return an int
9908 (boolean) indicating success.
9909 * target.h (set_desired_thread): Change return type to int.
9910
9911 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
9912
9913 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
9914 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
9915 #includes.
9916 (ps_get_thread_area): New function.
9917
9918 2015-08-19 Gary Benson <gbenson@redhat.com>
9919
9920 * hostio.c (handle_pread): Do not attempt to read more data
9921 than hostio_reply_with_data can fit in a packet.
9922
9923 2015-08-18 Joel Brobecker <brobecker@adacore.com>
9924
9925 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
9926
9927 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
9928
9929 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
9930
9931 2015-08-06 Pedro Alves <palves@redhat.com>
9932
9933 * tracepoint.c (expr_eval_result): Now an int.
9934
9935 2015-08-06 Pedro Alves <palves@redhat.com>
9936
9937 * gdbthread.h (struct regcache): Forward declare.
9938 (struct thread_info) <regcache_data>: Now a struct regcache
9939 pointer.
9940 * inferiors.c (inferior_regcache_data)
9941 (set_inferior_regcache_data): Now work with struct regcache
9942 pointers.
9943 * inferiors.h (struct regcache): Forward declare.
9944 (inferior_regcache_data, set_inferior_regcache_data): Now work
9945 with struct regcache pointers.
9946 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
9947 (free_register_cache_thread): Remove struct regcache pointer
9948 casts.
9949
9950 2015-08-06 Pedro Alves <palves@redhat.com>
9951
9952 * server.c (captured_main): On error, print the exception message
9953 to stderr, and if run_once is set, throw a quit.
9954
9955 2015-08-06 Pedro Alves <palves@redhat.com>
9956
9957 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
9958 the current thread.
9959
9960 2015-08-06 Pedro Alves <palves@redhat.com>
9961
9962 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
9963 reading beyond the passed in buffer length.
9964
9965 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
9966
9967 * tracepoint.c (symbol_list) <required>: Remove.
9968
9969 2015-08-06 Pedro Alves <palves@redhat.com>
9970
9971 * linux-low.c (handle_extended_wait): Set the fork child's suspend
9972 count if stopping and suspending threads.
9973 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
9974 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
9975 (linux_detach): Complete an ongoing step-over.
9976 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
9977 throughout.
9978 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
9979 (linux_wait_1): If passing a signal to the inferior after
9980 finishing a step-over, unsuspend and re-resume all lwps. If we
9981 see a single-step event but the thread should be continuing, don't
9982 pass the trap to gdb.
9983 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
9984 internal_error instead of gdb_assert.
9985 (enqueue_pending_signal): New function.
9986 (check_ptrace_stopped_lwp_gone): Add debug output.
9987 (start_step_over): Use internal_error instead of gdb_assert.
9988 (complete_ongoing_step_over): New function.
9989 (linux_resume_one_thread): Don't resume a suspended thread.
9990 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
9991 it stepping.
9992
9993 2015-08-06 Pedro Alves <palves@redhat.com>
9994
9995 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
9996 (linux_thread_alive): Use lwp_is_marked_dead.
9997 (extended_event_reported): Delete.
9998 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
9999 instead of extended_event_reported.
10000 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10001 as well.
10002 (lwp_is_marked_dead): New function.
10003 (lwp_running): Use lwp_is_marked_dead.
10004 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10005 comment.
10006
10007 2015-08-06 Pedro Alves <palves@redhat.com>
10008
10009 * linux-low.c (linux_wait_1): Move fork event output out of the
10010 !report_to_gdb check. Pass event_child->waitstatus to
10011 target_waitstatus_to_string instead of ourstatus.
10012
10013 2015-08-04 Yao Qi <yao.qi@linaro.org>
10014
10015 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10016 if current_thread is 32 bit.
10017
10018 2015-08-04 Yao Qi <yao.qi@linaro.org>
10019
10020 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10021 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10022 * server.c (extended_protocol): Remove "static".
10023 * server.h (extended_protocol): Declare it.
10024
10025 2015-08-04 Yao Qi <yao.qi@linaro.org>
10026
10027 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10028 both aarch64 and aarch32.
10029 (aarch64_set_pc): Likewise.
10030
10031 2015-08-04 Yao Qi <yao.qi@linaro.org>
10032
10033 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10034 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10035 arm-with-neon.xml to srv_xmlfiles.
10036 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10037 (is_64bit_tdesc): New function.
10038 (aarch64_linux_read_description): New function.
10039 (aarch64_arch_setup): Call aarch64_linux_read_description.
10040 (regs_info): Rename to regs_info_aarch64.
10041 (aarch64_regs_info): Return right regs_info.
10042 (initialize_low_arch): Call initialize_low_arch_aarch32.
10043
10044 2015-08-04 Yao Qi <yao.qi@linaro.org>
10045
10046 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10047 * linux-aarch32-low.c: New file.
10048 * linux-aarch32-low.h: New file.
10049 * linux-arm-low.c (arm_fill_gregset): Move it to
10050 linux-aarch32-low.c.
10051 (arm_store_gregset): Likewise.
10052 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10053 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10054 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10055 (regs_info): Rename to regs_info_arm.
10056 (arm_regs_info): Return regs_info_aarch32 if
10057 have_ptrace_getregset is 1 and target description is
10058 arm_with_neon or arm_with_vfpv3.
10059 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10060 Call initialize_low_arch_aarch32 instead.
10061
10062 2015-08-04 Yao Qi <yao.qi@linaro.org>
10063
10064 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10065 * linux-low.c: ... here.
10066 * linux-low.h (have_ptrace_getregset): Declare it.
10067
10068 2015-08-04 Pedro Alves <palves@redhat.com>
10069
10070 * thread-db.c (struct thread_db): Use new typedefs.
10071 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10072 CHK calls.
10073 (disable_thread_event_reporting): Cast result of dlsym to
10074 destination function pointer type.
10075 (thread_db_mourn): Use td_ta_delete_ftype.
10076
10077 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10078
10079 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10080 arch variant.
10081 (CDX_BREAKPOINT): Define for R2.
10082 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10083 (the_low_target): Add comments.
10084
10085 2015-07-30 Yao Qi <yao.qi@linaro.org>
10086
10087 * linux-arm-low.c (arm_hwcap): Remove it.
10088 (arm_read_description): New local variable arm_hwcap. Don't
10089 set arm_hwcap to zero.
10090
10091 2015-07-30 Yao Qi <yao.qi@linaro.org>
10092
10093 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10094 Use regcache->tdesc instead.
10095 (arm_store_wmmxregset): Likewise.
10096 (arm_fill_vfpregset): Likewise.
10097 (arm_store_vfpregset): Likewise.
10098
10099 2015-07-30 Yao Qi <yao.qi@linaro.org>
10100
10101 * linux-arm-low.c: Include arch/arm.h.
10102 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10103 (arm_store_gregset): Likewise.
10104
10105 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10106
10107 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10108 ptrace's 4th parameter.
10109
10110 2015-07-27 Yao Qi <yao.qi@linaro.org>
10111
10112 * configure.srv (case aarch64*-*-linux*): Don't set
10113 srv_linux_usrregs.
10114
10115 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10116
10117 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10118 sys/ptrace.h.
10119 * linux-arm-low.c: Likewise.
10120 * linux-cris-low.c: Likewise.
10121 * linux-crisv32-low.c: Likewise.
10122 * linux-low.c: Likewise.
10123 * linux-m68k-low.c: Likewise.
10124 * linux-mips-low.c: Likewise.
10125 * linux-nios2-low.c: Likewise.
10126 * linux-s390-low.c: Likewise.
10127 * linux-sparc-low.c: Likewise.
10128 * linux-tic6x-low.c: Likewise.
10129 * linux-tile-low.c: Likewise.
10130 * linux-x86-low.c: Likewise.
10131
10132 2015-07-24 Pedro Alves <palves@redhat.com>
10133
10134 * config.in: Regenerate.
10135 * configure: Regenerate.
10136
10137 2015-07-24 Pedro Alves <palves@redhat.com>
10138
10139 * acinclude.m4: Include ../ptrace.m4.
10140 * configure.ac: Call GDB_AC_PTRACE.
10141 * config.in, configure: Regenerate.
10142
10143 2015-07-24 Yao Qi <yao.qi@linaro.org>
10144
10145 * linux-low.c (linux_create_inferior): Remove setting to
10146 proc->priv->new_inferior.
10147 (linux_attach): Likewise.
10148 (linux_low_filter_event): Likewise.
10149 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10150
10151 2015-07-24 Yao Qi <yao.qi@linaro.org>
10152
10153 * linux-low.c (linux_arch_setup): New function.
10154 (linux_low_filter_event): If proc->tdesc is NULL and
10155 proc->attached is true, call the_low_target.arch_setup.
10156 Otherwise, keep status pending, and return.
10157 (linux_resume_one_lwp_throw): Don't call get_pc if
10158 thread->while_stepping isn't NULL. Don't call
10159 get_thread_regcache if proc->tdesc is NULL.
10160 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10161 (linux_target_ops): Install arch_setup.
10162 * server.c (start_inferior): Call the_target->arch_setup.
10163 * target.h (struct target_ops) <arch_setup>: New field.
10164 (target_arch_setup): New marco.
10165 * lynx-low.c (lynx_target_ops): Update.
10166 * nto-low.c (nto_target_ops): Update.
10167 * spu-low.c (spu_target_ops): Update.
10168 * win32-low.c (win32_target_ops): Update.
10169
10170 2015-07-24 Yao Qi <yao.qi@linaro.org>
10171
10172 * linux-low.c (linux_add_process): Don't set
10173 proc->priv->new_inferior.
10174 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10175 (linux_attach): Likewise.
10176
10177 2015-07-24 Yao Qi <yao.qi@linaro.org>
10178
10179 * server.c (start_inferior): Code refactor.
10180
10181 2015-07-24 Yao Qi <yao.qi@linaro.org>
10182
10183 * server.c (process_serial_event): Set general_thread.
10184
10185 2015-07-21 Yao Qi <yao.qi@linaro.org>
10186
10187 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10188 aarch64_linux_get_debug_reg_capacity.
10189
10190 2015-07-17 Yao Qi <yao.qi@linaro.org>
10191
10192 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10193 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10194 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10195 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10196 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10197 (AARCH64_HWP_ALIGNMENT): Likewise.
10198 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10199 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10200 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10201 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10202 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10203 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10204 (struct aarch64_debug_reg_state): Likewise.
10205 (struct arch_lwp_info): Likewise.
10206 (aarch64_align_watchpoint): Likewise.
10207 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10208 (aarch64_watchpoint_length): Likewise.
10209 (aarch64_point_encode_ctrl_reg): Likewise
10210 (aarch64_point_is_aligned): Likewise.
10211 (aarch64_align_watchpoint): Likewise.
10212 (aarch64_linux_set_debug_regs):
10213 (aarch64_dr_state_insert_one_point): Likewise.
10214 (aarch64_dr_state_remove_one_point): Likewise.
10215 (aarch64_handle_breakpoint): Likewise.
10216 (aarch64_handle_aligned_watchpoint): Likewise.
10217 (aarch64_handle_unaligned_watchpoint): Likewise.
10218 (aarch64_handle_watchpoint): Likewise.
10219
10220 2015-07-17 Yao Qi <yao.qi@linaro.org>
10221
10222 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10223 and don't aarch64_get_debug_reg_state. All callers update.
10224 (aarch64_handle_aligned_watchpoint): Likewise.
10225 (aarch64_handle_unaligned_watchpoint): Likewise.
10226 (aarch64_handle_watchpoint): Likewise.
10227 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10228 (aarch64_remove_point): Likewise.
10229
10230 2015-07-17 Yao Qi <yao.qi@linaro.org>
10231
10232 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10233 debug_printf.
10234 (aarch64_handle_unaligned_watchpoint): Likewise.
10235
10236 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10237
10238 Revert the previous 3 commits:
10239 Move gdb_regex* to common/
10240 Move linux_find_memory_regions_full & co.
10241 gdbserver build-id attribute generator
10242
10243 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10244 Jan Kratochvil <jan.kratochvil@redhat.com>
10245
10246 gdbserver build-id attribute generator.
10247 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10248 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10249 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10250 (find_phdr): New.
10251 (get_dynamic): Use find_pdhr to traverse program headers.
10252 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10253 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10254 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10255 (get_hex_build_id): New.
10256 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10257 to reply XML document.
10258
10259 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10260 Jan Kratochvil <jan.kratochvil@redhat.com>
10261
10262 * target.c: Include target/target-utils.h and fcntl.h.
10263 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10264 (target_fileio_read_stralloc): New functions.
10265
10266 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10267
10268 * Makefile.in (OBS): Add gdb_regex.o.
10269 (gdb_regex.o): New.
10270 * config.in: Rebuilt.
10271 * configure: Rebuilt.
10272
10273 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10274 Jan Kratochvil <jan.kratochvil@redhat.com>
10275
10276 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10277 * Makefile.in (OBS): Add target-utils.o.
10278 (linux-maps.o, target-utils.o): New.
10279 * configure.srv (srv_linux_obj): Add linux-maps.o.
10280
10281 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10282
10283 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10284 function, return 1.
10285 (the_low_target): Install it.
10286
10287 2015-07-14 Pedro Alves <palves@redhat.com>
10288
10289 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10290 Instead, ignore ECHILD, and throw an error for other errnos.
10291
10292 2015-07-10 Pedro Alves <palves@redhat.com>
10293
10294 * event-loop.c (struct callback_event) <data>: Change type to
10295 gdb_client_data instance instead of gdb_client_data pointer.
10296 (append_callback_event): Adjust.
10297
10298 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10299
10300 * linux-aarch64-low.c: Add comments for each linux_target_ops
10301 method. Remove comments already covered in target_ops and
10302 linux_target_ops definitions.
10303 (the_low_target): Add comments for each unimplemented method.
10304
10305 2015-07-09 Yao Qi <yao.qi@linaro.org>
10306
10307 * linux-aarch64-low.c (aarch64_regmap): Remove.
10308 (aarch64_usrregs_info): Remove.
10309 (regs_info): Set field usrregs to NULL.
10310
10311 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10312
10313 * linux-low.c: Include "rsp-low.h"
10314 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10315 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10316 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10317 (handle_btrace_enable_pt): New.
10318 (handle_btrace_general_set): Support "pt".
10319 (handle_btrace_conf_general_set): Support "pt:size".
10320
10321 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10322
10323 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10324 Z_PACKET_SW_BP.
10325
10326 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10327
10328 * linux-aarch64-low.c: Remove comment about endianness.
10329 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10330 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10331 memcmp.
10332
10333 2015-06-24 Gary Benson <gbenson@redhat.com>
10334
10335 * linux-i386-ipa.c (stdint.h): Do not include.
10336 * lynx-i386-low.c (stdint.h): Likewise.
10337 * lynx-ppc-low.c (stdint.h): Likewise.
10338 * mem-break.c (stdint.h): Likewise.
10339 * thread-db.c (stdint.h): Likewise.
10340 * tracepoint.c (stdint.h): Likewise.
10341 * win32-low.c (stdint.h): Likewise.
10342
10343 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10344
10345 * server.c (write_qxfer_response): Update call to
10346 remote_escape_output.
10347
10348 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10349 Jan Kratochvil <jan.kratochvil@redhat.com>
10350
10351 Merge multiple hex conversions.
10352 * gdbreplay.c (tohex): Rename to 'fromhex'.
10353 (logchar): Use fromhex.
10354
10355 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10356
10357 * server.c (handle_qxfer_libraries): Set `version' attribute for
10358 <library-list>.
10359
10360 2015-06-10 Gary Benson <gbenson@redhat.com>
10361
10362 * target.h (struct target_ops) <multifs_open>: New field.
10363 <multifs_unlink>: Likewise.
10364 <multifs_readlink>: Likewise.
10365 * linux-low.c (nat/linux-namespaces.h): New include.
10366 (linux_target_ops): Initialize the_target->multifs_open,
10367 the_target->multifs_unlink and the_target->multifs_readlink.
10368 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10369 * hostio.c (hostio_fs_pid): New static variable.
10370 (hostio_handle_new_gdb_connection): New function.
10371 (handle_setfs): Likewise.
10372 (handle_open): Use the_target->multifs_open as appropriate.
10373 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10374 (handle_readlink): Use the_target->multifs_readlink as
10375 appropriate.
10376 (handle_vFile): Handle vFile:setfs packets.
10377 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10378 after target_handle_new_gdb_connection.
10379
10380 2015-06-10 Gary Benson <gbenson@redhat.com>
10381
10382 * configure.ac (AC_CHECK_FUNCS): Add setns.
10383 * config.in: Regenerate.
10384 * configure: Likewise.
10385 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10386 (linux-namespaces.o): New rule.
10387 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10388
10389 2015-06-09 Gary Benson <gbenson@redhat.com>
10390
10391 * hostio.c (handle_open): Process mode argument with
10392 fileio_to_host_mode.
10393
10394 2015-06-01 Yao Qi <yao.qi@linaro.org>
10395
10396 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10397 * linux-x86-low.c: Likewise.
10398
10399 2015-05-28 Don Breazeal <donb@codesourcery.com>
10400
10401 * linux-low.c (handle_extended_wait): Initialize
10402 thread_info.last_resume_kind for new fork children.
10403
10404 2015-05-15 Pedro Alves <palves@redhat.com>
10405
10406 * target.h (target_handle_new_gdb_connection): Rewrite using if
10407 wrapped in do/while.
10408
10409 2015-05-14 Joel Brobecker <brobecker@adacore.com>
10410
10411 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10412 * configure, config.in: Regenerate.
10413 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10414 Declare typedef.
10415
10416 2015-05-12 Don Breazeal <donb@codesourcery.com>
10417
10418 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10419 PTRACE_EVENT_VFORK_DONE.
10420 (linux_low_ptrace_options, extended_event_reported): Add vfork
10421 events.
10422 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10423 and "vforkdone" for RSP 'T' Stop Reply Packet.
10424 * server.h (report_vfork_events): Declare
10425 global variable.
10426
10427 2015-05-12 Don Breazeal <donb@codesourcery.com>
10428
10429 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10430 (the_low_target) <new_fork>: Initialize new member.
10431 * linux-arm-low.c (arm_new_fork): New function.
10432 (the_low_target) <new_fork>: Initialize new member.
10433 * linux-low.c (handle_extended_wait): Call new target function
10434 new_fork.
10435 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10436 * linux-mips-low.c (mips_add_watchpoint): New function
10437 extracted from mips_insert_point.
10438 (the_low_target) <new_fork>: Initialize new member.
10439 (mips_linux_new_fork): New function.
10440 (mips_insert_point): Call mips_add_watchpoint.
10441 * linux-x86-low.c (x86_linux_new_fork): New function.
10442 (the_low_target) <new_fork>: Initialize new member.
10443
10444 2015-05-12 Don Breazeal <donb@codesourcery.com>
10445
10446 * linux-low.c (handle_extended_wait): Implement return value,
10447 rename argument 'event_child' to 'event_lwp', handle
10448 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10449 (linux_low_ptrace_options): New function.
10450 (linux_low_filter_event): Call linux_low_ptrace_options,
10451 use different argument fo linux_enable_event_reporting,
10452 use return value from handle_extended_wait.
10453 (extended_event_reported): New function.
10454 (linux_wait_1): Call extended_event_reported and set
10455 status to report fork events.
10456 (linux_write_memory): Add pid to debug message.
10457 (reset_lwp_ptrace_options_callback): New function.
10458 (linux_handle_new_gdb_connection): New function.
10459 (linux_target_ops): Initialize new structure member.
10460 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10461 * lynx-low.c: Initialize new structure member.
10462 * remote-utils.c (prepare_resume_reply): Implement stop reason
10463 "fork" for "T" stop message.
10464 * server.c (handle_query): Call handle_new_gdb_connection.
10465 * server.h (report_fork_events): Declare global flag.
10466 * target.h (struct target_ops) <handle_new_gdb_connection>:
10467 New member.
10468 (target_handle_new_gdb_connection): New macro.
10469 * win32-low.c: Initialize new structure member.
10470
10471 2015-05-12 Don Breazeal <donb@codesourcery.com>
10472
10473 * mem-break.c (APPEND_TO_LIST): Define macro.
10474 (clone_agent_expr): New function.
10475 (clone_one_breakpoint): New function.
10476 (clone_all_breakpoints): New function.
10477 * mem-break.h: Declare new functions.
10478
10479 2015-05-12 Don Breazeal <donb@codesourcery.com>
10480
10481 * linux-low.c (linux_supports_fork_events): New function.
10482 (linux_supports_vfork_events): New function.
10483 (linux_target_ops): Initialize new structure members.
10484 (initialize_low): Call linux_check_ptrace_features.
10485 * lynx-low.c (lynx_target_ops): Initialize new structure
10486 members.
10487 * server.c (report_fork_events, report_vfork_events):
10488 New global flags.
10489 (handle_query): Add new features to qSupported packet and
10490 response.
10491 (captured_main): Initialize new global variables.
10492 * target.h (struct target_ops) <supports_fork_events>:
10493 New member.
10494 <supports_vfork_events>: New member.
10495 (target_supports_fork_events): New macro.
10496 (target_supports_vfork_events): New macro.
10497 * win32-low.c (win32_target_ops): Initialize new structure
10498 members.
10499
10500 2015-05-12 Gary Benson <gbenson@redhat.com>
10501
10502 * server.c (handle_qxfer_exec_file): Use current process
10503 if annex is empty.
10504
10505 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10506
10507 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10508 Remove HAVE_PTRACE_GETREGS conditionals.
10509 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10510 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10511
10512 2015-05-08 Yao Qi <yao.qi@linaro.org>
10513
10514 * linux-low.c (linux_supports_conditional_breakpoints): New
10515 function.
10516 (linux_target_ops): Install new target method.
10517 * lynx-low.c (lynx_target_ops): Install NULL hook for
10518 supports_conditional_breakpoints.
10519 * nto-low.c (nto_target_ops): Likewise.
10520 * spu-low.c (spu_target_ops): Likewise.
10521 * win32-low.c (win32_target_ops): Likewise.
10522 * server.c (handle_query): Check
10523 target_supports_conditional_breakpoints.
10524 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10525 New field.
10526 (target_supports_conditional_breakpoints): New macro.
10527
10528 2015-05-06 Pedro Alves <palves@redhat.com>
10529
10530 PR server/18081
10531 * server.c (start_inferior): If the process exits, mourn it.
10532
10533 2015-04-21 Gary Benson <gbenson@redhat.com>
10534
10535 * hostio.c (fileio_open_flags_to_host): Factored out to
10536 fileio_to_host_openflags in common/fileio.c. Single use
10537 updated.
10538
10539 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10540
10541 * linux-xtensa-low.c (xtensa_fill_gregset)
10542 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10543 XCHAL_HAVE_LOOP.
10544
10545 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10546
10547 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10548 (regs_info): Replace usrregs pointer with NULL.
10549
10550 2015-04-17 Gary Benson <gbenson@redhat.com>
10551
10552 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10553 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10554 * server.c (handle_qxfer_exec_file): New function.
10555 (qxfer_packets): Add exec-file entry.
10556 (handle_query): Report qXfer:exec-file:read as supported packet.
10557
10558 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10559
10560 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10561
10562 2015-04-09 Gary Benson <gbenson@redhat.com>
10563
10564 * hostio-errno.c (errno_to_fileio_error): Remove function.
10565 Update caller to use remote_fileio_to_fio_error.
10566
10567 2015-04-09 Yao Qi <yao.qi@linaro.org>
10568
10569 * linux-low.c (linux_insert_point): Call
10570 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10571 (linux_remove_point): Call remove_memory_breakpoint if type is
10572 raw_bkpt_type_sw.
10573 * linux-x86-low.c (x86_insert_point): Don't call
10574 insert_memory_breakpoint.
10575 (x86_remove_point): Don't call remove_memory_breakpoint.
10576
10577 2015-04-01 Pedro Alves <palves@redhat.com>
10578 Cleber Rosa <crosa@redhat.com>
10579
10580 * server.c (gdbserver_usage): Reorganize and extend the usage
10581 message.
10582
10583 2015-03-24 Pedro Alves <palves@redhat.com>
10584
10585 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10586 output. Also dump TRAP_TRACE.
10587 (linux_low_filter_event): In debug output, distinguish a
10588 resume_stop SIGSTOP from a delayed SIGSTOP.
10589
10590 2015-03-24 Gary Benson <gbenson@redhat.com>
10591
10592 * linux-x86-low.c (x86_linux_new_thread): Moved to
10593 nat/x86-linux.c.
10594 (x86_linux_prepare_to_resume): Likewise.
10595
10596 2015-03-24 Gary Benson <gbenson@redhat.com>
10597
10598 * Makefile.in (x86-linux-dregs.o): New rule.
10599 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10600 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10601 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10602 (x86_linux_dr_get): Likewise.
10603 (x86_linux_dr_set): Likewise.
10604 (update_debug_registers_callback): Likewise.
10605 (x86_linux_dr_set_addr): Likewise.
10606 (x86_linux_dr_get_addr): Likewise.
10607 (x86_linux_dr_set_control): Likewise.
10608 (x86_linux_dr_get_control): Likewise.
10609 (x86_linux_dr_get_status): Likewise.
10610 (x86_linux_update_debug_registers): Likewise.
10611
10612 2015-03-24 Gary Benson <gbenson@redhat.com>
10613
10614 * linux-x86-low.c (x86_linux_update_debug_registers):
10615 New function, factored out from...
10616 (x86_linux_prepare_to_resume): ...this.
10617
10618 2015-03-24 Gary Benson <gbenson@redhat.com>
10619
10620 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10621 (x86_linux_dr_set): Likewise.
10622 (update_debug_registers_callback): Likewise.
10623 (x86_linux_dr_set_addr): Likewise.
10624 (x86_linux_dr_get_addr): Likewise.
10625 (x86_linux_dr_set_control): Likewise.
10626 (x86_linux_dr_get_control): Likewise.
10627 (x86_linux_dr_get_status): Likewise.
10628 (x86_linux_prepare_to_resume): Likewise.
10629
10630 2015-03-24 Gary Benson <gbenson@redhat.com>
10631
10632 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10633 Use perror_with_name. Pass string through gettext.
10634 (x86_linux_dr_set): Likewise.
10635
10636 2015-03-24 Gary Benson <gbenson@redhat.com>
10637
10638 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10639 (x86_linux_dr_set_addr): ...this.
10640 (x86_dr_low_get_addr): Rename to...
10641 (x86_linux_dr_get_addr): ...this.
10642 (x86_dr_low_set_control): Rename to...
10643 (x86_linux_dr_set_control): ...this.
10644 (x86_dr_low_get_control): Rename to...
10645 (x86_linux_dr_get_control): ...this.
10646 (x86_dr_low_get_status): Rename to...
10647 (x86_linux_dr_get_status): ...this.
10648 (x86_dr_low): Update with new function names.
10649
10650 2015-03-24 Gary Benson <gbenson@redhat.com>
10651
10652 * Makefile.in (x86-linux.o): New rule.
10653 * configure.srv: Add x86-linux.o to relevant targets.
10654 * linux-low.c (lwp_set_arch_private_info): New function.
10655 (lwp_arch_private_info): Likewise.
10656 * linux-x86-low.c: Include nat/x86-linux.h.
10657 (arch_lwp_info): Removed structure.
10658 (update_debug_registers_callback):
10659 Use lwp_set_debug_registers_changed.
10660 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10661 and lwp_set_debug_registers_changed.
10662 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10663
10664 2015-03-24 Gary Benson <gbenson@redhat.com>
10665
10666 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10667 * linux-arm-low.c (arm_new_thread): Likewise.
10668 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10669 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10670 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10671 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10672
10673 2015-03-24 Gary Benson <gbenson@redhat.com>
10674
10675 * linux-low.c (ptid_of_lwp): New function.
10676 (lwp_is_stopped): Likewise.
10677 (lwp_stop_reason): Likewise.
10678 * linux-x86-low.c (update_debug_registers_callback):
10679 Use lwp_is_stopped.
10680 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10681 lwp_stop_reason.
10682
10683 2015-03-24 Gary Benson <gbenson@redhat.com>
10684
10685 * linux-low.h (linux_stop_lwp): Remove declaration.
10686
10687 2015-03-24 Gary Benson <gbenson@redhat.com>
10688
10689 * linux-low.h: Include nat/linux-nat.h.
10690 * linux-low.c (iterate_over_lwps_args): New structure.
10691 (iterate_over_lwps_filter): New function.
10692 (iterate_over_lwps): Likewise.
10693 * linux-x86-low.c (update_debug_registers_callback):
10694 Update signature to what iterate_over_lwps expects.
10695 Remove PID check that iterate_over_lwps now performs.
10696 (x86_dr_low_set_addr): Use iterate_over_lwps.
10697 (x86_dr_low_set_control): Likewise.
10698
10699 2015-03-24 Gary Benson <gbenson@redhat.com>
10700
10701 * linux-x86-low.c (x86_debug_reg_state): New function.
10702 (x86_linux_prepare_to_resume): Use the above.
10703
10704 2015-03-24 Gary Benson <gbenson@redhat.com>
10705
10706 * linux-low.c (current_lwp_ptid): New function.
10707 * linux-x86-low.c: Include nat/linux-nat.h.
10708 (x86_dr_low_get_addr): Use current_lwp_ptid.
10709 (x86_dr_low_get_control): Likewise.
10710 (x86_dr_low_get_status): Likewise.
10711
10712 2015-03-20 Pedro Alves <palves@redhat.com>
10713
10714 * tracepoint.c (cmd_qtstatus): Make "str" const.
10715
10716 2015-03-20 Pedro Alves <palves@redhat.com>
10717
10718 * server.c (handle_general_set): Make "req_str" const.
10719
10720 2015-03-19 Pedro Alves <palves@redhat.com>
10721
10722 * linux-low.c (linux_resume_one_lwp): Rename to ...
10723 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
10724 instead call perror_with_name.
10725 (check_ptrace_stopped_lwp_gone): New function.
10726 (linux_resume_one_lwp): Reimplement as wrapper around
10727 linux_resume_one_lwp_throw that swallows errors if the LWP is
10728 gone.
10729
10730 2015-03-19 Pedro Alves <palves@redhat.com>
10731
10732 * linux-low.c (count_events_callback, select_event_lwp_callback):
10733 No longer check whether the thread has resume_stop as last resume
10734 kind.
10735
10736 2015-03-19 Pedro Alves <palves@redhat.com>
10737
10738 * linux-low.c (count_events_callback, select_event_lwp_callback):
10739 Use the lwp's status_pending_p field, not the thread's.
10740
10741 2015-03-19 Pedro Alves <palves@redhat.com>
10742
10743 * linux-low.c (select_event_lwp_callback): Update comments to
10744 no longer mention SIGTRAP.
10745
10746 2015-03-18 Gary Benson <gbenson@redhat.com>
10747
10748 * server.c (handle_query): Do not report vFile:fstat as supported.
10749
10750 2015-03-11 Gary Benson <gbenson@redhat.com>
10751
10752 * hostio.c (sys/types.h): New include.
10753 (sys/stat.h): Likewise.
10754 (common-remote-fileio.h): Likewise.
10755 (handle_fstat): New function.
10756 (handle_vFile): Handle vFile:fstat packets.
10757
10758 2015-03-11 Gary Benson <gbenson@redhat.com>
10759
10760 * configure.ac (AC_CHECK_MEMBERS): Add checks for
10761 struct stat.st_blocks and struct stat.st_blksize.
10762 * configure: Regenerate.
10763 * config.in: Likewise.
10764 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
10765 (OBS): Add common-remote-fileio.o.
10766 (common-remote-fileio.o): New rule.
10767
10768 2015-03-09 Pedro Alves <palves@redhat.com>
10769
10770 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
10771 'struct sockaddr' pointer in 'accept' call.
10772
10773 2015-03-09 Pedro Alves <palves@redhat.com>
10774
10775 Revert:
10776 2015-03-07 Pedro Alves <palves@redhat.com>
10777 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
10778 or <winsock2.h> here. Instead include "gdb_socket.h".
10779 (remote_open): Use union gdb_sockaddr_u.
10780 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
10781 or <winsock2.h> here. Instead include "gdb_socket.h".
10782 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
10783 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
10784 or <sys/un.h>.
10785 (init_named_socket, gdb_agent_helper_thread): Use union
10786 gdb_sockaddr_u.
10787
10788 2015-03-07 Pedro Alves <palves@redhat.com>
10789
10790 * configure.ac (build_warnings): Move
10791 -Wdeclaration-after-statement to the C-specific set.
10792 * configure: Regenerate.
10793
10794 2015-03-07 Pedro Alves <palves@redhat.com>
10795
10796 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
10797 or <winsock2.h> here. Instead include "gdb_socket.h".
10798 (remote_open): Use union gdb_sockaddr_u.
10799 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
10800 or <winsock2.h> here. Instead include "gdb_socket.h".
10801 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
10802 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
10803 or <sys/un.h>.
10804 (init_named_socket, gdb_agent_helper_thread): Use union
10805 gdb_sockaddr_u.
10806
10807 2015-03-07 Pedro Alves <palves@redhat.com>
10808
10809 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
10810 instead.
10811
10812 2015-03-06 Yao Qi <yao.qi@linaro.org>
10813
10814 * linux-aarch64-low.c (aarch64_insert_point): Use
10815 show_debug_regs as a boolean.
10816 (aarch64_remove_point): Likewise.
10817
10818 2015-03-05 Pedro Alves <palves@redhat.com>
10819
10820 * lynx-low.c (lynx_target_ops): Install NULL hooks for
10821 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
10822 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
10823 * nto-low.c (nto_target_ops): Likewise.
10824 * spu-low.c (spu_target_ops): Likewise.
10825 * win32-low.c (win32_target_ops): Likewise.
10826
10827 2015-03-04 Pedro Alves <palves@redhat.com>
10828
10829 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
10830 Decide whether a breakpoint triggered based on the SIGTRAP's
10831 siginfo.si_code.
10832 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
10833 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
10834 (linux_low_filter_event): Check for breakpoints before checking
10835 watchpoints.
10836 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
10837 siginfo.si_code.
10838 (linux_stopped_by_sw_breakpoint)
10839 (linux_supports_stopped_by_sw_breakpoint)
10840 (linux_stopped_by_hw_breakpoint)
10841 (linux_supports_stopped_by_hw_breakpoint): New functions.
10842 (linux_target_ops): Install new target methods.
10843
10844 2015-03-04 Pedro Alves <palves@redhat.com>
10845
10846 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
10847 * server.c (swbreak_feature, hwbreak_feature): New globals.
10848 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
10849 (captured_main): Clear swbreak_feature and hwbreak_feature.
10850 * server.h (swbreak_feature, hwbreak_feature): Declare.
10851 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
10852 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
10853 supports_stopped_by_hw_breakpoint>: New fields.
10854 (target_supports_stopped_by_sw_breakpoint)
10855 (target_stopped_by_sw_breakpoint)
10856 (target_supports_stopped_by_hw_breakpoint)
10857 (target_stopped_by_hw_breakpoint): Declare.
10858
10859 2015-03-04 Pedro Alves <palves@redhat.com>
10860
10861 enum lwp_stop_reason -> enum target_stop_reason
10862 * linux-low.c (check_stopped_by_breakpoint): Adjust.
10863 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
10864 (linux_wait_1, stuck_in_jump_pad_callback)
10865 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
10866 (linux_stopped_by_watchpoint):
10867 * linux-low.h (enum lwp_stop_reason): Delete.
10868 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
10869 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
10870
10871 2015-03-04 Yao Qi <yao.qi@linaro.org>
10872
10873 * Makefile.in (SFILES): Add linux-aarch64-low.c.
10874
10875 2015-03-03 Gary Benson <gbenson@redhat.com>
10876
10877 * hostio.c (handle_vFile): Fix prefix lengths.
10878
10879 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
10880
10881 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
10882 ptr_bits.
10883
10884 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
10885
10886 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
10887 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
10888 (clean): Add "rm -f" for above C files.
10889 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
10890 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
10891 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
10892 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
10893 * linux-s390-low.c (HWCAP_S390_VX): New macro.
10894 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
10895 (init_registers_s390x_vx_linux64)
10896 (init_registers_s390x_tevx_linux64)
10897 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
10898 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
10899 declarations.
10900 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
10901 (s390_store_vxrs_high): New functions.
10902 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
10903 NT_S390_VXRS_HIGH.
10904 (s390_arch_setup): Add logic for selecting one of the new target
10905 descriptions. Activate the new vector regsets if applicable.
10906 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
10907 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
10908 and init_registers_s390x_tevx_linux64.
10909
10910 2015-03-01 Pedro Alves <palves@redhat.com>
10911
10912 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
10913 parameter.
10914
10915 2015-02-27 Pedro Alves <palves@redhat.com>
10916
10917 * linux-x86-low.c (u_debugreg_offset): New function.
10918 (x86_linux_dr_get, x86_linux_dr_set): Use it.
10919
10920 2015-02-27 Pedro Alves <palves@redhat.com>
10921
10922 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
10923 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
10924 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
10925 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
10926 (ps_lsetfpregs, ps_getpid)
10927 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
10928 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
10929 (ps_lsetxregs, ps_plog): Declare.
10930
10931 2015-02-27 Pedro Alves <palves@redhat.com>
10932
10933 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
10934 IP_AGENT_EXPORT_FUNC.
10935 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
10936 IP_AGENT_EXPORT_FUNC.
10937 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
10938 (IP_AGENT_EXPORT): Delete.
10939 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10940 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
10941 (gdb_trampoline_buffer_error, collecting, gdb_collect)
10942 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
10943 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
10944 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
10945 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
10946 (traceframe_read_count, traceframe_write_count)
10947 (traceframes_created, trace_state_variables, get_raw_reg)
10948 (get_trace_state_variable_value, set_trace_state_variable_value)
10949 (ust_loaded, helper_thread_id, cmd_buf): Use
10950 IPA_SYM_EXPORTED_NAME.
10951 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
10952 (tracepoints) Use IP_AGENT_EXPORT_VAR.
10953 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
10954 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10955 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
10956 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
10957 EXTERN_C_PUSH/EXTERN_C_POP.
10958 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
10959 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
10960 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10961 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
10962 (traceframe_write_count, traceframe_read_count)
10963 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
10964 (about_to_request_buffer_space, get_trace_state_variable_value)
10965 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
10966 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
10967 EXTERN_C_PUSH/EXTERN_C_POP.
10968 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
10969 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
10970 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
10971 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10972 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10973 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
10974 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
10975 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
10976 Define.
10977 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
10978 (IP_AGENT_EXPORT_VAR_DECL): Define.
10979 (tracing): Declare.
10980 (gdb_agent_get_raw_reg): Declare.
10981
10982 2015-02-27 Tom Tromey <tromey@redhat.com>
10983 Pedro Alves <palves@redhat.com>
10984
10985 Rename symbols whose names are reserved C++ keywords throughout.
10986
10987 2015-02-27 Pedro Alves <palves@redhat.com>
10988
10989 * Makefile.in (COMPILER): New, get it from autoconf.
10990 (CXX): Get from autoconf instead.
10991 (COMPILE.pre): Use COMPILER.
10992 (CC-LD): Rename to ...
10993 (CC_LD): ... this. Use COMPILER.
10994 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
10995 (CXX_FOR_TARGET): Default to g++ instead of gcc.
10996 * acinclude.m4: Include build-with-cxx.m4.
10997 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
10998 Disable -Werror by default if building in C++ mode.
10999 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11000 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11001 the C++ compiler. Save/restore CXXFLAGS too.
11002 * configure: Regenerate.
11003
11004 2015-02-27 Pedro Alves <palves@redhat.com>
11005
11006 * acinclude.m4: Include libiberty.m4.
11007 * configure.ac: Call libiberty_INIT.
11008 * config.in, configure: Regenerate.
11009
11010 2015-02-26 Pedro Alves <palves@redhat.com>
11011
11012 * linux-low.c (linux_wait_1): When incrementing the PC past a
11013 program breakpoint always use the_low_target.breakpoint_len as
11014 increment, rather than the maximum between that and
11015 the_low_target.decr_pc_after_break.
11016
11017 2015-02-23 Pedro Alves <palves@redhat.com>
11018
11019 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11020 thread was doing a step-over; always adjust the PC if
11021 we stepped over a permanent breakpoint.
11022 (linux_wait_1): If we stepped over breakpoint that was on top of a
11023 permanent breakpoint, manually advance the PC past it.
11024
11025 2015-02-23 Pedro Alves <palves@redhat.com>
11026
11027 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11028 modes.
11029 (x86_fill_gregset, x86_store_gregset): Use it when handling
11030 $orig_eax.
11031
11032 2015-02-20 Pedro Alves <palves@redhat.com>
11033
11034 * thread-db.c: Include "nat/linux-procfs.h".
11035 (thread_db_init): Skip listing new threads if the kernel supports
11036 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11037
11038 2015-02-20 Pedro Alves <palves@redhat.com>
11039
11040 * linux-low.c (status_pending_p_callback): Use ptid_match.
11041
11042 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11043
11044 PR breakpoints/16812
11045 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11046 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11047 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11048
11049 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11050
11051 PR breakpoints/15956
11052 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11053
11054 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11055
11056 * linux-low.c (linux_low_btrace_conf): Print size.
11057 * server.c (handle_btrace_conf_general_set): New.
11058 (hanle_general_set): Call handle_btrace_conf_general_set.
11059 (handle_query): Report Qbtrace-conf:bts:size as supported.
11060
11061 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11062
11063 * linux-low.c (linux_low_enable_btrace): Update parameters.
11064 (linux_low_btrace_conf): New.
11065 (linux_target_ops)<to_btrace_conf>: Initialize.
11066 * server.c (current_btrace_conf): New.
11067 (handle_btrace_enable): Rename to ...
11068 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11069 to target_enable_btrace. Update comment. Update users.
11070 (handle_qxfer_btrace_conf): New.
11071 (qxfer_packets): Add btrace-conf entry.
11072 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11073 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11074 (target_ops)<read_btrace_conf>: New.
11075 (target_enable_btrace): Update parameters.
11076 (target_read_btrace_conf): New.
11077
11078 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11079
11080 * server.c (handle_btrace_general_set): Remove call to
11081 target_supports_btrace.
11082 (supported_btrace_packets): New.
11083 (handle_query): Call supported_btrace_packets.
11084 * target.h: include btrace-common.h.
11085 (btrace_target_info): Removed.
11086 (supports_btrace, target_supports_btrace): Update parameters.
11087
11088 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11089
11090 * Makefile.in (SFILES): Add common/btrace-common.c.
11091 (OBS): Add common/btrace-common.o.
11092 (btrace-common.o): Add build rules.
11093 * linux-low: Include btrace-common.h.
11094 (linux_low_read_btrace): Use struct btrace_data. Call
11095 btrace_data_init and btrace_data_fini.
11096
11097 2015-02-06 Pedro Alves <palves@redhat.com>
11098
11099 * thread-db.c (find_new_threads_callback): Add debug output.
11100
11101 2015-02-04 Pedro Alves <palves@redhat.com>
11102
11103 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11104 (resume_stopped_resumed_lwps): New function.
11105 (linux_wait_for_event_filtered): Use it.
11106
11107 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11108
11109 * Makefile.in (SFILES): Add linux-personality.c.
11110 (linux-personality.o): New rule.
11111 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11112 list of objects to be built.
11113 * linux-low.c: Include nat/linux-personality.h.
11114 (linux_create_inferior): Remove code to disable address space
11115 randomization (moved to ../nat/linux-personality.c). Create
11116 cleanup to disable address space randomization.
11117
11118 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11119
11120 * Makefile.in (posix-strerror.o): New rule.
11121 (mingw-strerror.o): Likewise.
11122 * configure: Regenerated.
11123 * configure.ac: Source file ../common/common.host. Initialize new
11124 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11125
11126 2015-01-14 Yao Qi <yao@codesourcery.com>
11127
11128 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11129 (ppc-linux.o): New rule.
11130 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11131 * configure.ac: AC_CHECK_FUNCS(getauxval).
11132 * config.in: Re-generated.
11133 * configure: Re-generated.
11134 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11135 ppc64_64bit_inferior_p
11136
11137 2015-01-14 Yao Qi <yao@codesourcery.com>
11138
11139 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11140 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11141 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11142 (PT_ORIG_R3, PT_TRAP): Likewise.
11143 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11144 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11145 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11146
11147 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11148
11149 * i387-fp.c (i387_cache_to_xsave): In look over
11150 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11151 zmmh_low_space field by use of zmmh_high_space.
11152
11153 2015-01-09 Pedro Alves <palves@redhat.com>
11154
11155 * linux-low.c (step_over_bkpt): Move higher up in the file.
11156 (handle_extended_wait): Don't store the stop_pc here.
11157 (get_stop_pc): Adjust comments and rename to ...
11158 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11159 stopped for a software breakpoint or hardware breakpoint.
11160 (thread_still_has_status_pending_p): New function.
11161 (status_pending_p_callback): Use
11162 thread_still_has_status_pending_p. If the event is no longer
11163 interesting, resume the LWP.
11164 (handle_tracepoints): Add assert.
11165 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11166 (wstatus_maybe_breakpoint): New function.
11167 (cancel_breakpoint): Delete function.
11168 (check_stopped_by_watchpoint): New function, factored out from
11169 linux_low_filter_event.
11170 (lp_status_maybe_breakpoint): Delete function.
11171 (linux_low_filter_event): Remove filter_ptid argument.
11172 Leave thread group exits pending here. Store the LWP's stop PC.
11173 Always leave events pending.
11174 (linux_wait_for_event_filtered): Pull all events out of the
11175 kernel, and leave them all pending.
11176 (count_events_callback, select_event_lwp_callback): Consider all
11177 events.
11178 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11179 (select_event_lwp): Only give preference to the stepping LWP in
11180 all-stop mode. Adjust comments.
11181 (ignore_event): New function.
11182 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11183 references to cancel_breakpoints. Adjust to renames. Also give
11184 equal priority to all LWPs that have had events in non-stop mode.
11185 If reporting a software breakpoint event, unadjust the LWP's PC.
11186 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11187 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11188 Adjust.
11189 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11190 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11191 (linux_stopped_by_watchpoint): Adjust.
11192 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11193 * linux-low.h (enum lwp_stop_reason): New.
11194 (struct lwp_info) <stop_pc>: Adjust comment.
11195 <stopped_by_watchpoint>: Delete field.
11196 <stop_reason>: New field.
11197 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11198 * mem-break.c (software_breakpoint_inserted_here)
11199 (hardware_breakpoint_inserted_here): New function.
11200 * mem-break.h (software_breakpoint_inserted_here)
11201 (hardware_breakpoint_inserted_here): Declare.
11202 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11203 (cancel_breakpoints): Delete.
11204 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11205 (upload_fast_traceframes): Remove references to
11206 cancel_breakpoints.
11207
11208 2015-01-09 Pedro Alves <palves@redhat.com>
11209
11210 * thread-db.c (find_new_threads_callback): Ignore thread if the
11211 kernel thread ID is -1.
11212
11213 2015-01-09 Pedro Alves <palves@redhat.com>
11214
11215 * linux-low.c (linux_attach_fail_reason_string): Move to
11216 nat/linux-ptrace.c, and rename.
11217 (linux_attach_lwp): Update comment.
11218 (attach_proc_task_lwp_callback): New function.
11219 (linux_attach): Adjust to rename and use
11220 linux_proc_attach_tgid_threads.
11221 (linux_attach_fail_reason_string): Delete declaration.
11222
11223 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11224
11225 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11226 * server.c (gdbserver_version): Likewise.
11227
11228 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11229
11230 * remote-utils.c: Include ctype.h.
11231 (input_interrupt): Explicitly handle the case when the char
11232 received is the NUL byte. Improve the printing of non-ASCII
11233 characters.
11234
11235 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11236
11237 * linux-low.c (linux_low_filter_event): Update call to
11238 linux_enable_event_reporting following the addition of
11239 a new parameter to that function.
11240
11241 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11242
11243 PR server/17457
11244 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11245 (AARCH64_FPCR_REGNO): Likewise.
11246 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11247 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11248 (aarch64_store_fpregset): Likewise.
11249
11250 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11251
11252 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11253 Remove FIXME comment about assumption about N.
11254
11255 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11256
11257 * configure.ac: If large-file support is disabled in GDBserver,
11258 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11259 * configure: Regenerate.
11260
11261 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11262
11263 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11264 warning upon ENODATA from ptrace.
11265 * linux-s390-low.c (s390_store_tdb): New.
11266 (s390_regsets): Add regset for NT_S390_TDB.
11267
11268 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11269
11270 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11271 without a fill_function.
11272 * linux-s390-low.c (s390_fill_last_break): Remove.
11273 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11274 (s390_arch_setup): Use regset's size instead of fill_function for
11275 loop end condition.
11276
11277 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11278
11279 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11280 the regset's store function when ptrace returned an error.
11281 * regcache.c (get_thread_regcache): Invalidate register cache
11282 before fetching inferior's registers.
11283
11284 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11285
11286 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11287 while-loop as for-loop.
11288 (regsets_store_inferior_registers): Likewise.
11289
11290 2014-11-28 Yao Qi <yao@codesourcery.com>
11291
11292 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11293 * config.in, configure: Re-generate.
11294 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11295 is defined.
11296
11297 2014-11-21 Yao Qi <yao@codesourcery.com>
11298
11299 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11300 (AC_CHECK_HEADERS): Remove malloc.h.
11301 * configure: Re-generated.
11302 * config.in: Re-generated.
11303 * server.h: Don't include alloca.h and malloc.h.
11304 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11305 Don't include malloc.h.
11306
11307 2014-11-17 Joel Brobecker <brobecker@adacore.com>
11308
11309 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11310 corresponding ERRNO check in same block.
11311
11312 2014-11-12 Pedro Alves <palves@redhat.com>
11313
11314 * server.c (cont_thread): Update comment.
11315 (start_inferior, attach_inferior): No longer clear cont_thread.
11316 (handle_v_cont): No longer set cont_thread.
11317 (captured_main): Clear cont_thread each time a GDB connects.
11318
11319 2014-11-12 Pedro Alves <palves@redhat.com>
11320
11321 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11322 thread, and don't resume all threads if the Hc thread has exited.
11323
11324 2014-11-12 Pedro Alves <palves@redhat.com>
11325
11326 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11327 the process group instead of to a specific LWP.
11328
11329 2014-10-15 Pedro Alves <palves@redhat.com>
11330
11331 PR server/17487
11332 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11333 parameter.
11334 (arm_set_thread_context): Delete.
11335 (the_low_target): Adjust.
11336 * win32-i386-low.c (debug_registers_changed)
11337 (debug_registers_used): Delete.
11338 (update_debug_registers_callback): New function.
11339 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11340 needing to update their debug registers.
11341 (win32_get_current_dr): New function.
11342 (x86_dr_low_get_addr, x86_dr_low_get_control)
11343 (x86_dr_low_get_status): Fetch the debug register from the thread
11344 record's context.
11345 (i386_initial_stuff): Adjust.
11346 (i386_get_thread_context): Remove current_event parameter. Don't
11347 clear debug_registers_changed nor copy DR values to
11348 debug_reg_state.
11349 (i386_set_thread_context): Delete.
11350 (i386_prepare_to_resume): New function.
11351 (i386_thread_added): Mark the thread as needing to update irs
11352 debug registers.
11353 (the_low_target): Remove i386_set_thread_context and install
11354 i386_prepare_to_resume.
11355 * win32-low.c (win32_get_thread_context): Adjust.
11356 (win32_set_thread_context): Use SetThreadContext
11357 directly.
11358 (win32_prepare_to_resume): New function.
11359 (win32_require_context): New function, factored out from ...
11360 (thread_rec): ... this.
11361 (continue_one_thread): Call win32_prepare_to_resume on each thread
11362 we're about to continue.
11363 (win32_resume): Call win32_prepare_to_resume on the event thread.
11364 * win32-low.h (struct win32_thread_info)
11365 <debug_registers_changed>: New field.
11366 (struct win32_target_ops): Change prototype of set_thread_context,
11367 delete set_thread_context and add prepare_to_resume.
11368 (win32_require_context): New declaration.
11369
11370 2014-10-08 Gary Benson <gbenson@redhat.com>
11371
11372 * server.h: Do not include common-exceptions.h.
11373
11374 2014-10-08 Gary Benson <gbenson@redhat.com>
11375
11376 * server.h: Do not include cleanups.h.
11377
11378 2014-09-30 James Hogan <james.hogan@imgtec.com>
11379
11380 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11381 mips64-dsp-linux.c.
11382
11383 2014-09-23 Yao Qi <yao@codesourcery.com>
11384
11385 * linux-low.c (lp_status_maybe_breakpoint): New function.
11386 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11387 (count_events_callback): Likewise.
11388 (select_event_lwp_callback): Likewise.
11389 (cancel_breakpoints_callback): Likewise.
11390
11391 2014-09-19 Don Breazeal <donb@codesourcery.com>
11392
11393 * linux-low.c (handle_extended_wait): Call
11394 linux_ptrace_get_extended_event.
11395 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11396 linux_is_extended_waitstatus.
11397
11398 2014-09-16 Joel Brobecker <brobecker@adacore.com>
11399
11400 * Makefile.in (CPPFLAGS): Define.
11401 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11402 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11403
11404 2014-09-16 Gary Benson <gbenson@redhat.com>
11405
11406 * inferiors.h (current_inferior): Renamed as...
11407 (current_thread): New variable. All uses updated.
11408 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11409 (maybe_move_out_of_jump_pad): Likewise.
11410 (cancel_breakpoint): Likewise.
11411 (linux_low_filter_event): Likewise.
11412 (wait_for_sigstop): Likewise.
11413 (linux_resume_one_lwp): Likewise.
11414 (need_step_over_p): Likewise.
11415 (start_step_over): Likewise.
11416 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11417 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11418 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11419 and save_inferior as saved_thread.
11420 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11421 saved_thread.
11422 (regcache_invalidate_thread): Likewise.
11423 * remote-utils.c (prepare_resume_reply): Likewise.
11424 * thread-db.c (thread_db_get_tls_address): Likewise.
11425 (disable_thread_event_reporting): Likewise.
11426 (remove_thread_event_breakpoints): Likewise.
11427 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11428 as saved_thread.
11429 * target.h (set_desired_inferior): Renamed as...
11430 (set_desired_thread): New declaration. All uses updated.
11431 * server.c (myresume): Updated comment to reference thread instead
11432 of inferior.
11433 (handle_serial_event): Likewise.
11434 (handle_target_event): Likewise.
11435
11436 2014-09-12 Tom Tromey <tromey@redhat.com>
11437 Gary Benson <gbenson@redhat.com>
11438
11439 * regcache.h: Include common-regcache.h.
11440 (regcache_read_pc): Don't declare.
11441 * regcache.c (get_thread_regcache_for_ptid): New function.
11442
11443 2014-09-11 Tom Tromey <tromey@redhat.com>
11444 Gary Benson <gbenson@redhat.com>
11445
11446 * symbol.c: New file.
11447 * Makefile.in (SFILES): Add symbol.c.
11448 (OBS): Add symbol.o.
11449
11450 2014-09-11 Gary Benson <gbenson@redhat.com>
11451
11452 * target.c (target_stop_ptid, target_continue_ptid): New
11453 functions.
11454
11455 2014-09-11 Tom Tromey <tromey@redhat.com>
11456 Gary Benson <gbenson@redhat.com>
11457
11458 * target.h: Include target/target.h.
11459 * target.c (target_read_memory, target_read_uint32)
11460 (target_write_memory): New functions.
11461
11462 2014-09-11 Gary Benson <gbenson@redhat.com>
11463
11464 * server.h (debug_hw_points): Don't declare.
11465 * server.c (debug_hw_points): Don't define. Replace all uses
11466 with show_debug_regs.
11467 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11468 all uses with show_debug_regs.
11469
11470 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11471
11472 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11473 endianness into account.
11474 (ppc_supply_ptrace_register): Likewise.
11475
11476 2014-09-03 James Hogan <james.hogan@imgtec.com>
11477
11478 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11479 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11480
11481 2014-09-03 Gary Benson <gbenson@redhat.com>
11482
11483 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11484 ALL_DEBUG_ADDRESS_REGISTERS.
11485
11486 2014-09-02 Gary Benson <gbenson@redhat.com>
11487
11488 * i386-low.h: Renamed as...
11489 * x86-low.h: New file. All type, function and variable name
11490 prefixes changed from "i386_" to "x86_". All references updated.
11491 * i386-low.c: Renamed as...
11492 * x86-low.c: New file. All type, function and variable name
11493 prefixes changed from "i386_" to "x86_". All references updated.
11494
11495 2014-09-02 Gary Benson <gbenson@redhat.com>
11496
11497 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11498 (x86_linux_new_thread): Likewise.
11499
11500 2014-08-29 Gary Benson <gbenson@redhat.com>
11501
11502 * server.h (setjmp.h): Do not include.
11503 (toplevel): Do not declare.
11504 (common-exceptions.h): Include.
11505 (cleanups.h): Likewise.
11506 * server.c (toplevel): Do not define.
11507 (exit_code): New static global.
11508 (detach_or_kill_for_exit_cleanup): New function.
11509 (main): New function. Original main renamed to...
11510 (captured_main): New function.
11511 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11512
11513 2014-08-29 Gary Benson <gbenson@redhat.com>
11514
11515 * Makefile.in (SFILES): Add common/common-exceptions.c.
11516 (OBS): Add common-exceptions.o.
11517 (common-exceptions.o): New rule.
11518 * utils.c (prepare_to_throw_exception): New function.
11519
11520 2014-08-29 Gary Benson <gbenson@redhat.com>
11521
11522 * config.in: Regenerate.
11523 * configure: Likewise.
11524
11525 2014-08-29 Gary Benson <gbenson@redhat.com>
11526
11527 * Makefile.in (SFILES): Add common/cleanups.c.
11528 (OBS): cleanups.o.
11529 (cleanups.o): New rule.
11530
11531 2014-08-29 Gary Benson <gbenson@redhat.com>
11532
11533 * utils.c (internal_vwarning): New function.
11534
11535 2014-08-28 Gary Benson <gbenson@redhat.com>
11536
11537 * utils.h (fatal): Remove declaration.
11538 * utils.c (fatal): Remove function.
11539
11540 2014-08-28 Gary Benson <gbenson@redhat.com>
11541
11542 * tracepoint.c (gdb_agent_init): Replace fatal with
11543 perror_with_name.
11544 (initialize_tracepoint): Likewise.
11545
11546 2014-08-28 Gary Benson <gbenson@redhat.com>
11547
11548 * remote-utils.c (remote_prepare): Replace fatal with error.
11549
11550 2014-08-28 Gary Benson <gbenson@redhat.com>
11551
11552 * linux-low.c (linux_async): Replace fatal with warning.
11553 Tidy up and return.
11554 (linux_start_non_stop): Return -1 if linux_async failed.
11555
11556 2014-08-28 Gary Benson <gbenson@redhat.com>
11557
11558 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11559 gdb_assert.
11560 (i386_dr_low_get_addr): Remove vague comment.
11561 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11562 gdb_assert.
11563
11564 2014-08-28 Gary Benson <gbenson@redhat.com>
11565
11566 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11567 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11568 internal_error.
11569 (linux_resume_one_lwp): Likewise.
11570 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11571 gdb_assert.
11572 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11573 with internal_error.
11574 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11575 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11576 (find_register_by_name): Replace fatal with internal_error.
11577 (find_regno): Likewise.
11578 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11579 * thread-db.c (thread_db_create_event): Likewise.
11580 (thread_db_load_search): Likewise.
11581 (try_thread_db_load_1): Likewise.
11582 * tracepoint.c (get_jump_space_head): Replace fatal with
11583 internal_error.
11584 (claim_trampoline_space): Likewise.
11585 (have_fast_tracepoint_trampoline_buffer): Likewise.
11586 (cmd_qtstart): Likewise.
11587 (stop_tracing): Likewise.
11588 (fast_tracepoint_collecting): Likewise.
11589 (target_malloc): Likewise.
11590 (download_tracepoint): Likewise.
11591 (download_trace_state_variables): Replace check with gdb_assert.
11592 (upload_fast_traceframes): Replace fatal with internal_error.
11593
11594 2014-08-19 Tom Tromey <tromey@redhat.com>
11595 Gary Benson <gbenson@redhat.com>
11596
11597 * Makefile.in (SFILES): Add common/common-debug.c.
11598 (OBS): Add common-debug.o.
11599 (common-debug.o): New rule.
11600 * debug.h (debug_printf): Don't declare.
11601 * debug.c (debug_printf): Renamed and rewritten as...
11602 (debug_vprintf): New function.
11603
11604 2014-08-19 Gary Benson <gbenson@redhat.com>
11605
11606 * utils.h: Do not include print-utils.h.
11607
11608 2014-08-19 Tom Tromey <tromey@redhat.com>
11609 Gary Benson <gbenson@redhat.com>
11610
11611 * server.h: Add static assertion.
11612 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11613
11614 2014-08-19 Tom Tromey <tromey@redhat.com>
11615 Gary Benson <gbenson@redhat.com>
11616
11617 * Makefile.in (SFILES): Add common/errors.c.
11618 (OBS): Add errors.o.
11619 (IPA_OBS): Add errors-ipa.o.
11620 (errors.o): New rule.
11621 (errors-ipa.o): Likewise.
11622 * utils.h (perror_with_name, error, warning): Don't declare.
11623 * utils.c (warning): Renamed and rewritten as...
11624 (vwarning): New function.
11625 (error): Renamed and rewritten as...
11626 (verror): New function.
11627 (internal_error): Renamed and rewritten as...
11628 (internal_verror): New function.
11629
11630 2014-08-07 Gary Benson <gbenson@redhat.com>
11631
11632 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11633 * configure: Regenerate.
11634 * config.in: Likewise.
11635 * server.h: Do not include errno.h.
11636 * event-loop.c: Likewise.
11637 * hostio-errno.c: Likewise.
11638 * linux-low.c: Likewise.
11639 * remote-utils.c: Likewise.
11640 * spu-low.c: Likewise.
11641 * utils.c: Likewise.
11642 * gdbreplay.c: Unconditionally include errno.h.
11643
11644 2014-08-07 Gary Benson <gbenson@redhat.com>
11645
11646 * server.h: Do not include string.h.
11647 * event-loop.c: Likewise.
11648 * linux-low.c: Likewise.
11649 * regcache.c: Likewise.
11650 * remote-utils.c: Likewise.
11651 * spu-low.c: Likewise.
11652 * utils.c: Likewise.
11653
11654 2014-08-07 Gary Benson <gbenson@redhat.com>
11655
11656 * server.h: Do not include gdb_assert.h.
11657
11658 2014-08-07 Gary Benson <gbenson@redhat.com>
11659
11660 * server.h: Do not include common-utils.h.
11661
11662 2014-08-07 Gary Benson <gbenson@redhat.com>
11663
11664 * server.h: Do not include ptid.h.
11665 * notif.h: Likewise.
11666
11667 2014-08-07 Gary Benson <gbenson@redhat.com>
11668
11669 * server.h: Do not include gdb_locale.h.
11670
11671 2014-08-07 Gary Benson <gbenson@redhat.com>
11672
11673 * server.h: Do not include gdb/signals.h.
11674 * win32-low.c: Likewise.
11675
11676 2014-08-07 Gary Benson <gbenson@redhat.com>
11677
11678 * server.h: Do not include pathmax.h.
11679
11680 2014-08-07 Gary Benson <gbenson@redhat.com>
11681
11682 * server.h: Do not include libiberty.h.
11683 * linux-bfin-low.c: Likewise.
11684
11685 2014-08-07 Gary Benson <gbenson@redhat.com>
11686
11687 * server.h: Do not include ansidecl.h.
11688
11689 2014-08-07 Gary Benson <gbenson@redhat.com>
11690
11691 * linux-x86-low.c: Do not include stddef.h.
11692 * lynx-ppc-low.c: Likewise.
11693 * tracepoint.c: Likewise.
11694
11695 2014-08-07 Gary Benson <gbenson@redhat.com>
11696
11697 * server.h: Do not include stdarg.h.
11698 * nto-low.c: Likewise.
11699
11700 2014-08-07 Gary Benson <gbenson@redhat.com>
11701
11702 * server.h: Do not include stdlib.h.
11703 * inferiors.c: Likewise.
11704 * linux-low.c: Likewise.
11705 * regcache.c: Likewise.
11706 * spu-low.c: Likewise.
11707 * tracepoint.c: Likewise.
11708 * utils.c: Likewise.
11709
11710 2014-08-07 Gary Benson <gbenson@redhat.com>
11711
11712 * server.h: Do not include stdio.h.
11713 * linux-low.c: Likewise.
11714 * remote-utils.c: Likewise.
11715 * spu-low.c: Likewise.
11716 * utils.c: Likewise.
11717 * wincecompat.c: Likewise.
11718
11719 2014-08-06 Gary Benson <gbenson@redhat.com>
11720
11721 * regcache.c (init_register_cache): Move conditionals inside if.
11722
11723 2014-08-06 Gary Benson <gbenson@redhat.com>
11724
11725 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
11726
11727 2014-07-31 Gary Benson <gbenson@redhat.com>
11728
11729 * ax.h: Do not include server.h.
11730 * gdbthread.h: Likewise.
11731 * lynx-low.h: Likewise.
11732 * notif.h: Likewise.
11733
11734 2014-07-30 Gary Benson <gbenson@redhat.com>
11735
11736 * server.h: Include common-defs.h.
11737 Do not include config.h or build-gnulib-gdbserver/config.h.
11738
11739 2014-07-30 Gary Benson <gbenson@redhat.com>
11740
11741 * hostio-errno.c: Move server.h to top of includes list.
11742 * inferiors.c: Likewise.
11743 * linux-x86-low.c: Likewise.
11744 * notif.c: Include server.h.
11745
11746 2014-07-24 Tom Tromey <tromey@redhat.com>
11747 Gary Benson <gbenson@redhat.com>
11748
11749 * server.h (CORE_ADDR): Now unsigned.
11750
11751 2014-07-16 Pedro Alves <palves@redhat.com>
11752
11753 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
11754
11755 2014-07-15 Pedro Alves <palves@redhat.com>
11756
11757 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
11758 copy.
11759
11760 2014-07-11 Pedro Alves <palves@redhat.com>
11761
11762 * linux-low.c (kill_wait_lwp): New function, based on
11763 kill_one_lwp_callback, but use my_waitpid directly.
11764 (kill_one_lwp_callback, linux_kill): Use it.
11765
11766 2014-06-23 Pedro Alves <palves@redhat.com>
11767
11768 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
11769 before setting DR0..DR3.
11770
11771 2014-06-20 Gary Benson <gbenson@redhat.com>
11772
11773 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
11774 * configure: Regenerated.
11775 * config.in: Likewise.
11776
11777 2014-06-20 Gary Benson <gbenson@redhat.com>
11778
11779 * Makefile.in (SFILES): Update locations for files moved
11780 from common to nat.
11781 (object file files): Reordered.
11782
11783 2014-06-20 Gary Benson <gbenson@redhat.com>
11784
11785 * i386-low.h (i386_dr_low_can_set_addr): Removed.
11786 (i386_dr_low_set_addr): Likewise.
11787 (i386_dr_low_get_addr): Likewise.
11788 (i386_dr_low_can_set_control): Likewise.
11789 (i386_dr_low_set_control): Likewise.
11790 (i386_dr_low_get_control): Likewise.
11791 (i386_dr_low_get_status): Likewise.
11792 (i386_get_debug_register_length): Likewise.
11793 * linux-x86-low.c (i386_dr_low_set_addr):
11794 Changed signature. Made static.
11795 (i386_dr_low_get_addr): Likewise.
11796 (i386_dr_low_set_control): Likewise.
11797 (i386_dr_low_get_control): Likewise.
11798 (i386_dr_low_get_status): Likewise.
11799 (i386_dr_low): New global variable.
11800 * win32-i386-low.c (i386_dr_low_set_addr):
11801 Changed signature. Made static.
11802 (i386_dr_low_get_addr): Likewise.
11803 (i386_dr_low_set_control): Likewise.
11804 (i386_dr_low_get_control): Likewise.
11805 (i386_dr_low_get_status): Likewise.
11806 (i386_dr_low): New global variable.
11807
11808 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
11809
11810 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
11811 * Makefile.in (AR, AR_FLAGS): Define.
11812 * configure: Regenerate.
11813
11814 2014-06-19 Gary Benson <gbenson@redhat.com>
11815
11816 * Makefile.in (i386-dregs.o): New rule.
11817 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
11818 * i386-low.c (target.h): Remove include.
11819 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
11820 (DR_CONTROL_SHIFT): Likewise.
11821 (DR_CONTROL_SIZE): Likewise.
11822 (DR_RW_EXECUTE): Likewise.
11823 (DR_RW_WRITE): Likewise.
11824 (DR_RW_READ): Likewise.
11825 (DR_RW_IORW): Likewise.
11826 (DR_LEN_1): Likewise.
11827 (DR_LEN_2): Likewise.
11828 (DR_LEN_4): Likewise.
11829 (DR_LEN_8): Likewise.
11830 (DR_LOCAL_ENABLE_SHIFT): Likewise.
11831 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
11832 (DR_ENABLE_SIZE): Likewise.
11833 (DR_LOCAL_SLOWDOWN): Likewise.
11834 (DR_GLOBAL_SLOWDOWN): Likewise.
11835 (DR_CONTROL_RESERVED): Likewise.
11836 (I386_DR_CONTROL_MASK): Likewise.
11837 (I386_DR_VACANT): Likewise.
11838 (I386_DR_LOCAL_ENABLE): Likewise.
11839 (I386_DR_GLOBAL_ENABLE): Likewise.
11840 (I386_DR_DISABLE): Likewise.
11841 (I386_DR_SET_RW_LEN): Likewise.
11842 (I386_DR_GET_RW_LEN): Likewise.
11843 (I386_DR_WATCH_HIT): Likewise.
11844 (i386_wp_op_t): Likewise.
11845 (i386_show_dr): Likewise.
11846 (i386_length_and_rw_bits): Likewise.
11847 (i386_insert_aligned_watchpoint): Likewise.
11848 (i386_remove_aligned_watchpoint): Likewise.
11849 (i386_handle_nonaligned_watchpoint): Likewise.
11850 i386_update_inferior_debug_regs(): Likewise.
11851 (i386_dr_insert_watchpoint): Likewise.
11852 (i386_dr_remove_watchpoint): Likewise.
11853 (i386_dr_region_ok_for_watchpoint): Likewise.
11854 (i386_dr_stopped_data_address): Likewise.
11855 (i386_dr_stopped_by_watchpoint): Likewise.
11856
11857 2014-06-19 Gary Benson <gbenson@redhat.com>
11858
11859 * i386-low.c (i386_dr_show): Renamed to
11860 i386_show_dr and made static. All uses updated.
11861 (i386_dr_length_and_rw_bits): Renamed to
11862 i386_length_and_rw_bits and made static.
11863 All uses updated.
11864 (i386_dr_insert_aligned_watchpoint): Renamed to
11865 i386_insert_aligned_watchpoint and made static.
11866 All uses updated.
11867 (i386_dr_remove_aligned_watchpoint): Renamed to
11868 i386_remove_aligned_watchpoint and made static.
11869 All uses updated.
11870 (i386_dr_update_inferior_debug_regs): Renamed to
11871 i386_update_inferior_debug_regs and made static.
11872 All uses updated.
11873
11874 2014-06-18 Gary Benson <gbenson@redhat.com>
11875
11876 * i386-low.h (i386_dr_low_can_set_addr): New macro.
11877 (i386_dr_low_can_set_control): Likewise.
11878 (i386_get_debug_register_length): Likewise.
11879 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
11880 (i386_dr_low_can_set_control): Likewise.
11881 (i386_get_debug_register_length): Likewise.
11882
11883 2014-06-17 Gary Benson <gbenson@redhat.com>
11884
11885 * i386-low.h (i386-dregs.h): New include.
11886 (DR_FIRSTADDR): Now in i386-dregs.h.
11887 (DR_LASTADDR): Likewise.
11888 (DR_NADDR): Likewise.
11889 (DR_STATUS): Likewise.
11890 (DR_CONTROL): Likewise.
11891 (i386_debug_reg_state): Likewise.
11892 (i386_dr_insert_watchpoint): Likewise.
11893 (i386_dr_remove_watchpoint): Likewise.
11894 (i386_dr_region_ok_for_watchpoint): Likewise.
11895 (i386_dr_stopped_data_address): Likewise.
11896 (i386_dr_stopped_by_watchpoint): Likewise.
11897 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
11898
11899 2014-06-18 Gary Benson <gbenson@redhat.com>
11900
11901 * i386-low.h (i386_low_insert_watchpoint): Renamed to
11902 i386_dr_insert_watchpoint.
11903 (i386_low_remove_watchpoint): Renamed to
11904 i386_dr_remove_watchpoint.
11905 (i386_low_region_ok_for_watchpoint): Renamed to
11906 i386_dr_region_ok_for_watchpoint.
11907 (i386_low_stopped_data_address): Renamed to
11908 i386_dr_stopped_data_address.
11909 (i386_low_stopped_by_watchpoint): Renamed to
11910 i386_dr_stopped_by_watchpoint.
11911 * i386-low.c (i386_show_dr): Renamed to
11912 i386_dr_show and made nonstatic. All uses updated.
11913 (i386_length_and_rw_bits): Renamed to
11914 i386_dr_length_and_rw_bits and made nonstatic.
11915 All uses updated.
11916 (i386_insert_aligned_watchpoint): Renamed to
11917 i386_dr_insert_aligned_watchpoint and made nonstatic.
11918 All uses updated.
11919 (i386_remove_aligned_watchpoint): Renamed to
11920 i386_dr_remove_aligned_watchpoint and made nonstatic.
11921 All uses updated.
11922 (i386_update_inferior_debug_regs): Renamed to
11923 i386_dr_update_inferior_debug_regs and made nonstatic.
11924 All uses updated.
11925 (i386_low_insert_watchpoint): Renamed to
11926 i386_dr_insert_watchpoint. All uses updated.
11927 (i386_low_remove_watchpoint): Renamed to
11928 i386_dr_remove_watchpoint. All uses updated.
11929 (i386_low_region_ok_for_watchpoint): Renamed to
11930 i386_dr_region_ok_for_watchpoint. All uses updated.
11931 (i386_low_stopped_data_address): Renamed to
11932 i386_dr_stopped_data_address. All uses updated.
11933 (i386_low_stopped_by_watchpoint): Renamed to
11934 i386_dr_stopped_by_watchpoint. All uses updated.
11935
11936 2014-06-18 Gary Benson <gbenson@redhat.com>
11937
11938 * i386-low.c (i386_dr_low_can_set_addr): New macro.
11939 (i386_dr_low_can_set_control): Likewise.
11940 (i386_insert_aligned_watchpoint): New check.
11941
11942 2014-06-18 Gary Benson <gbenson@redhat.com>
11943
11944 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
11945 Renamed to state.
11946
11947 2014-06-18 Gary Benson <gbenson@redhat.com>
11948
11949 * i386-low.c (i386_length_and_rw_bits): Use internal_error
11950 instead of fatal and error.
11951 (i386_handle_nonaligned_watchpoint): Likewise.
11952
11953 2014-06-18 Gary Benson <gbenson@redhat.com>
11954
11955 * i386-low.c (i386_get_debug_register_length): New macro.
11956 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
11957 (i386_show_dr): Use debug_printf instead of fprintf. Use
11958 phex to format values.
11959
11960 2014-06-18 Gary Benson <gbenson@redhat.com>
11961
11962 * i386-low.h: Comment changes.
11963 * i386-low.c: Likewise.
11964
11965 2014-06-18 Gary Benson <gbenson@redhat.com>
11966
11967 * i386-low.c: Whitespace changes.
11968
11969 2014-06-12 Tom Tromey <tromey@redhat.com>
11970
11971 * utils.c (freeargv): Remove.
11972
11973 2014-06-12 Tom Tromey <tromey@redhat.com>
11974
11975 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
11976 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
11977 (parse_debug_format_options): Likewise.
11978 (gdbserver_usage): Likewise.
11979 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
11980 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
11981 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
11982 against libiberty.
11983 ($(LIBGNU)): Depend on libiberty.
11984 (all-lib): Recurse into all subdirs.
11985 (install-only): Invoke "install" target in subdirs.
11986 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
11987 targets.
11988 * configure: Rebuild.
11989 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
11990 for vasprintf, vsnprintf, or gettimeofday.
11991 * configure.srv: Don't add safe-ctype.o or lbasename.o to
11992 srv_tgtobj.
11993
11994 2014-06-05 Joel Brobecker <brobecker@adacore.com>
11995
11996 * development.sh: Delete.
11997 * Makefile.in (config.status): Adjust dependency on development.sh.
11998 * configure.ac: Adjust development.sh source call.
11999 * configure: Regenerate.
12000
12001 2014-06-02 Pedro Alves <palves@redhat.com>
12002
12003 * ax.c (gdb_free_agent_expr): New function.
12004 * ax.h (gdb_free_agent_expr): New declaration.
12005 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12006 list.
12007 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12008 static.
12009 (clear_breakpoint_conditions_and_commands): New function.
12010 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12011 (clear_breakpoint_conditions_and_commands): New declaration.
12012
12013 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12014
12015 * linux-aarch64-low.c (asm/ptrace.h): Include.
12016
12017 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12018
12019 Fix TLS access for -static -pthread.
12020 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12021 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12022 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12023
12024 2014-05-20 Pedro Alves <palves@redhat.com>
12025
12026 * linux-aarch64-low.c (aarch64_insert_point)
12027 (aarch64_remove_point): No longer check whether the type is
12028 supported here. Adjust to new interface.
12029 (the_low_target): Install aarch64_supports_z_point_type as
12030 supports_z_point_type method.
12031 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12032 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12033 instead of a Z packet char. Adjust.
12034 (arm_supports_z_point_type): New function.
12035 (arm_insert_point, arm_remove_point): Adjust to new interface.
12036 (the_low_target): Install arm_supports_z_point_type.
12037 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12038 (cris_insert_point, cris_remove_point): Adjust to new interface.
12039 Don't check whether the type is supported here.
12040 (the_low_target): Install cris_supports_z_point_type.
12041 * linux-low.c (linux_supports_z_point_type): New function.
12042 (linux_insert_point, linux_remove_point): Adjust to new interface.
12043 * linux-low.h (struct linux_target_ops) <insert_point,
12044 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12045 raw_breakpoint pointer parameter.
12046 <supports_z_point_type>: New method.
12047 * linux-mips-low.c (mips_supports_z_point_type): New function.
12048 (mips_insert_point, mips_remove_point): Adjust to new interface.
12049 Use mips_supports_z_point_type.
12050 (the_low_target): Install mips_supports_z_point_type.
12051 * linux-ppc-low.c (the_low_target): Install NULL as
12052 supports_z_point_type method.
12053 * linux-s390-low.c (the_low_target): Install NULL as
12054 supports_z_point_type method.
12055 * linux-sparc-low.c (the_low_target): Install NULL as
12056 supports_z_point_type method.
12057 * linux-x86-low.c (x86_supports_z_point_type): New function.
12058 (x86_insert_point): Adjust to new insert_point interface. Use
12059 insert_memory_breakpoint. Adjust to new
12060 i386_low_insert_watchpoint interface.
12061 (x86_remove_point): Adjust to remove_point interface. Use
12062 remove_memory_breakpoint. Adjust to new
12063 i386_low_remove_watchpoint interface.
12064 (the_low_target): Install x86_supports_z_point_type.
12065 * lynx-low.c (lynx_target_ops): Install NULL as
12066 supports_z_point_type callback.
12067 * nto-low.c (nto_supports_z_point_type): New.
12068 (nto_insert_point, nto_remove_point): Adjust to new interface.
12069 (nto_target_ops): Install nto_supports_z_point_type.
12070 * mem-break.c: Adjust intro comment.
12071 (struct raw_breakpoint) <raw_type, size>: New fields.
12072 <inserted>: Update comment.
12073 <shlib_disabled>: Delete field.
12074 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12075 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12076 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12077 (raw_bkpt_type_to_target_hw_bp_type): New function.
12078 (find_enabled_raw_code_breakpoint_at): New function.
12079 (find_raw_breakpoint_at): New type and size parameters. Use them.
12080 (insert_memory_breakpoint): New function, based off
12081 set_raw_breakpoint_at.
12082 (remove_memory_breakpoint): New function.
12083 (set_raw_breakpoint_at): Reimplement.
12084 (set_breakpoint): New, based on set_breakpoint_at.
12085 (set_breakpoint_at): Reimplement.
12086 (delete_raw_breakpoint): Go through the_target->remove_point
12087 instead of assuming memory breakpoints.
12088 (find_gdb_breakpoint_at): Delete.
12089 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12090 (find_gdb_breakpoint): New function.
12091 (set_gdb_breakpoint_at): Delete.
12092 (z_type_supported): New function.
12093 (set_gdb_breakpoint_1): New function, loosely based off
12094 set_gdb_breakpoint_at.
12095 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12096 (delete_gdb_breakpoint_at): Delete.
12097 (delete_gdb_breakpoint_1): New function, loosely based off
12098 delete_gdb_breakpoint_at.
12099 (delete_gdb_breakpoint): New function.
12100 (clear_gdb_breakpoint_conditions): Rename to ...
12101 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12102 breakpoint.
12103 (add_condition_to_breakpoint): Make static.
12104 (add_breakpoint_condition): Take a struct breakpoint pointer
12105 instead of an address. Adjust.
12106 (gdb_condition_true_at_breakpoint): Rename to ...
12107 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12108 z_type parameter.
12109 (gdb_condition_true_at_breakpoint): Reimplement.
12110 (add_breakpoint_commands): Take a struct breakpoint pointer
12111 instead of an address. Adjust.
12112 (gdb_no_commands_at_breakpoint): Rename to ...
12113 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12114 parameter. Return true if no breakpoint was found. Change debug
12115 output.
12116 (gdb_no_commands_at_breakpoint): Reimplement.
12117 (run_breakpoint_commands): Rename to ...
12118 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12119 and change return type to boolean.
12120 (run_breakpoint_commands): New function.
12121 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12122 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12123 breakpoint. Go through the_target->remove_point instead of
12124 assuming memory breakpoint.
12125 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12126 software and hardware breakpoints.
12127 (reinsert_raw_breakpoint): Go through the_target->insert_point
12128 instead of assuming memory breakpoint.
12129 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12130 software and hardware breakpoints.
12131 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12132 Check both software and hardware breakpoints.
12133 (validate_inserted_breakpoint): Assert the breakpoint is a
12134 software breakpoint. Set the inserted flag to -1 instead of
12135 setting shlib_disabled.
12136 (delete_disabled_breakpoints): Adjust.
12137 (validate_breakpoints): Only validate software breakpoints.
12138 Adjust to inserted flag change.
12139 (check_mem_read, check_mem_write): Skip breakpoint types other
12140 than software breakpoints. Adjust to inserted flag change.
12141 * mem-break.h (enum raw_bkpt_type): New enum.
12142 (raw_breakpoint, struct process_info): Forward declare.
12143 (Z_packet_to_target_hw_bp_type): Delete declaration.
12144 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12145 (set_gdb_breakpoint, delete_gdb_breakpoint)
12146 (clear_breakpoint_conditions): New declarations.
12147 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12148 (breakpoint_inserted_here): Update comment.
12149 (add_breakpoint_condition, add_breakpoint_commands): Replace
12150 address parameter with a breakpoint pointer parameter.
12151 (gdb_breakpoint_here): Update comment.
12152 (delete_gdb_breakpoint_at): Delete.
12153 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12154 * server.c (process_point_options): Take a struct breakpoint
12155 pointer instead of an address. Adjust.
12156 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12157 delete_gdb_breakpoint.
12158 * spu-low.c (spu_target_ops): Install NULL as
12159 supports_z_point_type method.
12160 * target.h: Include mem-break.h.
12161 (struct target_ops) <prepare_to_access_memory>: Update comment.
12162 <supports_z_point_type>: New field.
12163 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12164 instead of a char. Also take a raw breakpoint pointer.
12165 * win32-arm-low.c (the_low_target): Install NULL as
12166 supports_z_point_type.
12167 * win32-i386-low.c (i386_supports_z_point_type): New function.
12168 (i386_insert_point, i386_remove_point): Adjust to new interface.
12169 (the_low_target): Install i386_supports_z_point_type.
12170 * win32-low.c (win32_supports_z_point_type): New function.
12171 (win32_insert_point, win32_remove_point): Adjust to new interface.
12172 (win32_target_ops): Install win32_supports_z_point_type.
12173 * win32-low.h (struct win32_target_ops):
12174 <supports_z_point_type>: New method.
12175 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12176 instead of a char. Also take a raw breakpoint pointer.
12177
12178 2014-05-20 Pedro Alves <palves@redhat.com>
12179
12180 * mem-break.h: Include break-common.h.
12181 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12182 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12183 (Z_packet_to_target_hw_bp_type): New declaration.
12184 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12185 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12186 (Z_PACKET_ACCESS_WP): Delete macros.
12187 (Z_packet_to_hw_type): Delete function.
12188 * i386-low.h: Don't include break-common.h here.
12189 (Z_packet_to_hw_type): Delete declaration.
12190 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12191 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12192 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12193 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12194 * linux-aarch64-low.c: Don't include break-common.h here.
12195 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12196 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12197 (Z_packet_to_target_hw_bp_type): Delete function.
12198 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12199 function.
12200 (mips_insert_point, mips_remove_point): Use
12201 Z_packet_to_target_hw_bp_type.
12202
12203 2014-05-20 Pedro Alves <palves@redhat.com>
12204
12205 * linux-aarch64-low.c: Include break-common.h.
12206 (enum target_point_type): Delete.
12207 (Z_packet_to_point_type): Rename to ...
12208 (Z_packet_to_target_hw_bp_type): ... this, and return a
12209 target_hw_bp_type instead.
12210 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12211 instead of an enum target_point_type.
12212 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12213 breakpoint type.
12214 (aarch64_dr_state_insert_one_point)
12215 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12216 (aarch64_handle_aligned_watchpoint)
12217 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12218 Take an enum target_hw_bp_type instead of an enum
12219 target_point_type.
12220 (aarch64_supports_z_point_type): New function.
12221 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12222 use Z_packet_to_target_hw_bp_type.
12223
12224 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12225
12226 * configure.ac: Only use -Werror by default when DEVELOPMENT
12227 is true.
12228 * configure: Regenerate.
12229
12230 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12231
12232 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12233 * linux-x86-low.c (X86_64_USER_REGS): New.
12234 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12235
12236 2014-04-28 Yao Qi <yao@codesourcery.com>
12237
12238 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12239 name.
12240
12241 2014-04-25 Pedro Alves <palves@redhat.com>
12242
12243 PR server/16255
12244 * linux-low.c (linux_attach_fail_reason_string): New function.
12245 (linux_attach_lwp): Delete.
12246 (linux_attach_lwp_1): Rename to ...
12247 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12248 argument. Remove "initial" parameter. Return int instead of
12249 void. Don't error or warn here.
12250 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12251 failure to attach to the tgid. Call warning when failing to
12252 attach to an lwp.
12253 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12254 argument. Remove "initial" parameter. Return int instead of
12255 void. Don't error or warn here.
12256 (linux_attach_fail_reason_string): New declaration.
12257 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12258 interface change. Use linux_attach_fail_reason_string.
12259
12260 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12261 Walfred Tedeschi <walfred.tedeschi@intel.com>
12262
12263 * Makefile.in: Added rules to handle new files
12264 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12265 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12266 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12267 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12268 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12269 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12270 x32-avx512-linux.o.
12271 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12272 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12273 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12274 i386/x32-avx512.xml.
12275 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12276 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12277 i386/x32-avx512-linux.xml.
12278 * i387-fp.c (num_avx512_k_registers): New constant for number
12279 of K registers.
12280 (num_avx512_zmmh_low_registers): New constant for number of
12281 lower ZMM registers (0-15).
12282 (num_avx512_zmmh_high_registers): New constant for number of
12283 higher ZMM registers (16-31).
12284 (num_avx512_ymmh_registers): New contant for number of higher
12285 YMM registers (ymm16-31 added by avx521 on x86_64).
12286 (num_avx512_xmm_registers): New constant for number of higher
12287 XMM registers (xmm16-31 added by AVX512 on x86_64).
12288 (struct i387_xsave): Add space for AVX512 registers.
12289 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12290 Add code to handle AVX512 registers.
12291 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12292 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12293 prototypei from generated file.
12294 (tdesc_amd64_avx512_linux): Likewise.
12295 (init_registers_x32_avx512_linux): Likewise.
12296 (tdesc_x32_avx512_linux): Likewise.
12297 (init_registers_i386_avx512_linux): Likewise.
12298 (tdesc_i386_avx512_linux): Likewise.
12299 (x86_64_regmap): Add AVX512 registers.
12300 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12301 mask.
12302 (initialize_low_arch): Add code to initialize AVX512 registers.
12303
12304 2014-04-23 Pedro Alves <palves@redhat.com>
12305
12306 * mem-break.c (find_gdb_breakpoint_at): Make static.
12307 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12308
12309 2014-04-23 Pedro Alves <palves@redhat.com>
12310
12311 * i386-low.c: Don't include break-common.h here.
12312 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12313 prototype to take target_hw_bp_type as argument instead of a Z
12314 packet char.
12315 * i386-low.h: Include break-common.h here.
12316 (Z_packet_to_hw_type): Declare.
12317 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12318 prototypes.
12319 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12320 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12321 (x86_remove_point): Convert the packet number to a
12322 target_hw_bp_type before calling i386_low_remove_watchpoint.
12323 * win32-i386-low.c (i386_insert_point): Convert the packet number
12324 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12325 (i386_remove_point): Convert the packet number to a
12326 target_hw_bp_type before calling i386_low_remove_watchpoint.
12327
12328 2014-04-23 Pedro Alves <palves@redhat.com>
12329
12330 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12331
12332 2014-04-10 Pedro Alves <palves@redhat.com>
12333
12334 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12335 Check if the condition or command is NULL before checking if the
12336 breakpoint is known. On success, return true.
12337 * mem-break.h (add_breakpoint_condition): Document return.
12338 (add_breakpoint_commands): Add describing comment.
12339 * server.c (skip_to_semicolon): New function.
12340 (process_point_options): Use it.
12341
12342 2014-04-09 Pedro Alves <palves@redhat.com>
12343
12344 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12345 to lwpid_of.
12346
12347 2014-02-27 Pedro Alves <palves@redhat.com>
12348
12349 PR 12702
12350 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12351 macros.
12352 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12353 output.
12354 (last_thread_of_process_p): Take a PID argument instead of a
12355 thread pointer.
12356 (linux_wait_for_lwp): Delete.
12357 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12358 functions.
12359 (linux_low_filter_event): New function, party factored out from
12360 linux_wait_for_event.
12361 (linux_wait_for_event): Rename to ...
12362 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12363 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12364 sigsuspend. Check for zombie leaders.
12365 (linux_wait_for_event): Reimplement as wrapper around
12366 linux_wait_for_event_filtered.
12367 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12368 a normal or signal exit is seen, it's the whole process exiting.
12369 (wait_for_sigstop): No longer a for_each_inferior callback.
12370 Rewrite on top of linux_wait_for_event_filtered.
12371 (stop_all_lwps): Call wait_for_sigstop directly.
12372 * server.c (resume, handle_target_event): Handle
12373 TARGET_WAITKIND_NO_RESUMED.
12374
12375 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12376
12377 * win32-low.c (psapi_get_dll_name,
12378 * win32_CreateToolhelp32Snapshot): Delete.
12379 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12380 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12381 Delete.
12382 (handle_load_dll): Add function description.
12383 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12384
12385 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12386
12387 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12388 Add comment.
12389 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12390 base address when calling win32_add_one_solib.
12391 (handle_load_dll): Delete local variable load_addr.
12392 Remove 0x1000 offset applied to DLL base address when calling
12393 win32_add_one_solib.
12394 (handle_unload_dll): Add comment.
12395
12396 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12397
12398 * win32-low.c (win32_add_all_dlls): Renames
12399 win32_ensure_ntdll_loaded. Rewrite function documentation.
12400 Adjust implementation to always load all DLLs.
12401 Add 0x1000 offset to DLL base address when calling
12402 win32_add_one_solib.
12403 (child_initialization_done): New static global.
12404 (do_initial_child_stuff): Set child_initialization_done to
12405 zero during child initialization, and 1 after. Replace call
12406 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12407 Add comment.
12408 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12409 (handle_unload_dll): Add function documentation.
12410 (get_child_debug_event): Ignore load and unload DLL events
12411 during child initialization.
12412
12413 2014-02-20 Doug Evans <dje@google.com>
12414
12415 Remove global all_lwps.
12416 * inferiors.h (ptid_of): Move here from linux-low.h.
12417 (pid_of, lwpid_of): Ditto.
12418 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12419 parameter is a struct thread_info * now.
12420 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12421 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12422 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12423 directly.
12424 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12425 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12426 * linux-arm-low.c (update_registers_callback): Update, "entry"
12427 parameter is a struct thread_info * now.
12428 Fetch lwpid from current_inferior directly.
12429 (arm_insert_point): Pass &all_threads to find_inferior instead of
12430 &all_lwps.
12431 (arm_remove_point): Ditto.
12432 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12433 (arm_prepare_to_resume): Fetch pid from thread.
12434 (arm_read_description): Fetch lwpid from current_inferior directly.
12435 * linux-low.c (all_lwps): Delete.
12436 (delete_lwp): Delete call to remove_inferior.
12437 (handle_extended_wait): Fetch lwpid from thread.
12438 (add_lwp): Don't set lwp->entry.id. Remove call to
12439 add_inferior_to_list.
12440 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12441 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12442 (kill_one_lwp_callback): Ditto.
12443 (linux_kill): Don't dereference NULL pointer.
12444 Fetch ptid,lwpid from thread.
12445 (get_detach_signal): Fetch ptid from thread.
12446 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12447 Simplify call to regcache_invalidate_thread.
12448 (delete_lwp_callback): Update, "entry" parameter is a
12449 struct thread_info * now. Fetch pid from thread.
12450 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12451 (status_pending_p_callback): Update, "entry" parameter is a
12452 struct thread_info * now. Fetch ptid from thread.
12453 (find_lwp_pid): Update, "entry" parameter is a
12454 struct thread_info * now.
12455 (linux_wait_for_lwp): Fetch pid from thread.
12456 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12457 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12458 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12459 (dequeue_one_deferred_signal): Ditto.
12460 (cancel_breakpoint): Fetch ptid from current_inferior.
12461 (linux_wait_for_event): Pass &all_threads to find_inferior,
12462 not &all_lwps. Fetch ptid, lwpid from thread.
12463 (count_events_callback): Update, "entry" parameter is a
12464 struct thread_info * now.
12465 (select_singlestep_lwp_callback): Ditto.
12466 (select_event_lwp_callback): Ditto.
12467 (cancel_breakpoints_callback): Ditto.
12468 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12469 not &all_lwps.
12470 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12471 (unsuspend_one_lwp): Update, "entry" parameter is a
12472 struct thread_info * now.
12473 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12474 not &all_lwps.
12475 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12476 Fetch lwpid from thread, not lwp.
12477 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12478 Pass &all_threads to find_inferior, not &all_lwps.
12479 (send_sigstop): Fetch lwpid from thread, not lwp.
12480 (send_sigstop_callback): Update, "entry" parameter is a
12481 struct thread_info * now.
12482 (suspend_and_send_sigstop_callback): Ditto.
12483 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12484 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12485 struct thread_info * now.
12486 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12487 from thread, lwp.
12488 (lwp_running): Update, "entry" parameter is a
12489 struct thread_info * now.
12490 (stop_all_lwps): Fetch ptid from thread.
12491 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12492 (linux_resume_one_lwp): Fetch lwpid from thread.
12493 (linux_set_resume_request): Update, "entry" parameter is a
12494 struct thread_info * now. Fetch pid, lwpid from thread.
12495 (resume_status_pending_p): Update, "entry" parameter is a
12496 struct thread_info * now.
12497 (need_step_over_p): Ditto. Fetch lwpid from thread.
12498 (start_step_over): Fetch lwpid from thread.
12499 (linux_resume_one_thread): Update, "entry" parameter is a
12500 struct thread_info * now. Fetch lwpid from thread.
12501 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12502 (proceed_one_lwp): Update, "entry" parameter is a
12503 struct thread_info * now. Fetch lwpid from thread.
12504 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12505 struct thread_info * now.
12506 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12507 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12508 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12509 directly.
12510 (regsets_store_inferior_registers): Ditto.
12511 (fetch_register, store_register): Ditto.
12512 (linux_read_memory, linux_write_memory): Ditto.
12513 (linux_request_interrupt): Ditto.
12514 (linux_read_auxv): Ditto.
12515 (linux_xfer_siginfo): Ditto.
12516 (linux_qxfer_spu): Ditto.
12517 (linux_qxfer_libraries_svr4): Ditto.
12518 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12519 moved to inferiors.h.
12520 (get_lwp): Delete.
12521 (get_thread_lwp): Update.
12522 (struct lwp_info): Delete member "entry". Simplify comment for
12523 member "thread".
12524 (all_lwps): Delete.
12525 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12526 current_inferior directly.
12527 (update_watch_registers_callback): Update, "entry" parameter is a
12528 struct thread_info * now. Fetch pid from thread.
12529 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12530 (mips_insert_point): Fetch lwpid from current_inferior.
12531 Pass &all_threads to find_inferior, not &all_lwps.
12532 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12533 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12534 directly.
12535 (mips_stopped_data_address): Ditto.
12536 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12537 directly.
12538 * linux-tile-low.c (tile_arch_setup): Ditto.
12539 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12540 (update_debug_registers_callback): Update, "entry" parameter is a
12541 struct thread_info * now. Fetch pid from thread.
12542 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12543 Pass &all_threads to find_inferior, not &all_lwps.
12544 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12545 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12546 Pass &all_threads to find_inferior, not &all_lwps.
12547 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12548 (i386_dr_low_get_status): Ditto.
12549 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12550 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12551 (x86_linux_read_description): Ditto.
12552 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12553
12554 2014-02-20 Doug Evans <dje@google.com>
12555
12556 * inferiors.c (get_first_inferior): Fix buglet.
12557
12558 2014-02-19 Doug Evans <dje@google.com>
12559
12560 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12561 * inferiors.c (add_thread): Change result type to struct thread_info *.
12562 All callers updated.
12563 (add_lwp): Call add_thread here instead of in callers.
12564 All callers updated.
12565 * linux-low.h (get_lwp_thread): Rewrite.
12566 (struct lwp_info): New member "thread".
12567
12568 2014-02-19 Doug Evans <dje@google.com>
12569
12570 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12571 All callers updated.
12572
12573 2014-02-19 Doug Evans <dje@google.com>
12574
12575 * inferiors.c (add_thread): Fix whitespace.
12576
12577 2014-02-19 Doug Evans <dje@google.com>
12578
12579 * dll.c (clear_dlls): Replace accessing list implemention details
12580 with API function.
12581 * gdbthread.h (get_first_thread): Declare.
12582 * inferiors.c (for_each_inferior_with_data): New function.
12583 (get_first_thread): New function.
12584 (find_thread_ptid): Simplify.
12585 (get_first_inferior): New function.
12586 (clear_list): Delete.
12587 (one_inferior_p): New function.
12588 (clear_inferior_list): New function.
12589 (clear_inferiors): Update.
12590 * inferiors.h (for_each_inferior_with_data): Declare.
12591 (clear_inferior_list): Declare.
12592 (one_inferior_p): Declare.
12593 (get_first_inferior): Declare.
12594 * linux-low.c (linux_wait_for_event): Replace accessing list
12595 implemention details with API function.
12596 * server.c (target_running): Ditto.
12597 (accumulate_file_name_length): New function.
12598 (emit_dll_description): New function.
12599 (handle_qxfer_libraries): Replace accessing list implemention
12600 details with API function.
12601 (handle_qxfer_threads_worker): New function.
12602 (handle_qxfer_threads_proper): Replace accessing list implemention
12603 details with API function.
12604 (handle_query): Ditto.
12605 (visit_actioned_threads_callback_ftype): New typedef.
12606 (visit_actioned_threads_data): New struct.
12607 (visit_actioned_threads): Rewrite to be find_inferior callback.
12608 (resume): Call find_inferior.
12609 (handle_status): Replace accessing list implemention
12610 details with API function.
12611 (process_serial_event): Replace accessing list implemention details
12612 with API function.
12613 * target.c (set_desired_inferior): Replace accessing list implemention
12614 details with API function.
12615 * tracepoint.c (same_process_p): New function.
12616 (gdb_agent_about_to_close): Replace accessing list implemention
12617 details with API function.
12618 * win32-low.c (child_delete_thread): Replace accessing list
12619 implemention details with API function.
12620 (match_dll_by_basename): New function.
12621 (dll_is_loaded_by_basename): New function.
12622 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12623 details call to dll_is_loaded_by_basename.
12624
12625 2014-02-19 Doug Evans <dje@google.com>
12626
12627 * dll.h (struct dll_info): Add comment.
12628 * gdbthread.h (struct thread_info): Add comment.
12629 (current_ptid): Simplify.
12630 * inferiors.c (add_process): Update.
12631 (remove_process): Update.
12632 * inferiors.h (struct process_info): Rename member "head" to "entry".
12633 * linux-low.c (delete_lwp): Update.
12634 (add_lwp): Update.
12635 (last_thread_of_process_p): Update.
12636 (kill_one_lwp_callback, linux_kill): Update.
12637 (status_pending_p_callback): Update.
12638 (wait_for_sigstop): Update. Simplify read of ptid.
12639 (start_step_over): Update.
12640 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12641 (get_lwp_thread): Update.
12642 (struct lwp_info): Rename member "head" to "entry".
12643 * regcache.h (inferior_list_entry): Delete.
12644 * server.c (kill_inferior_callback): Update.
12645 (detach_or_kill_inferior_callback): Update.
12646 (print_started_pid): Update.
12647 (print_attached_pid): Update.
12648 (process_serial_event): Simplify read of ptid.
12649 * thread-db.c (thread_db_create_event): Update.
12650 (thread_db_get_tls_address): Update.
12651 * win32-low.c (current_inferior_ptid): Simplify.
12652
12653 2014-02-19 Tom Tromey <tromey@redhat.com>
12654
12655 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12656 argument.
12657 (target_supports_btrace): Update.
12658
12659 2014-02-14 Yao Qi <yao@codesourcery.com>
12660
12661 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12662 (rsp-low-ipa.o): New target.
12663
12664 2014-02-12 Tom Tromey <tromey@redhat.com>
12665
12666 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12667 convert_ascii_to_int.
12668 * regcache.c (registers_to_string): Likewise.
12669 * remote-utils.c (decode_M_packet): Likewise.
12670 * server.c (process_serial_event): Likewise.
12671
12672 2014-02-12 Tom Tromey <tromey@redhat.com>
12673
12674 * server.c (handle_query, handle_v_run): Use hex2bin, not
12675 unhexify.
12676 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12677
12678 2014-02-12 Tom Tromey <tromey@redhat.com>
12679
12680 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12681 convert_int_to_ascii.
12682 * regcache.c (registers_to_string, collect_register_as_string):
12683 Likewise.
12684 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12685 Likewise.
12686 * server.c (process_serial_event): Likewise.
12687 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12688 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
12689
12690 2014-02-12 Tom Tromey <tromey@redhat.com>
12691
12692 * remote-utils.c (look_up_one_symbol, monitor_output): Use
12693 bin2hex, not hexify.
12694 * tracepoint.c (cmd_qtstatus): Likewise.
12695
12696 2014-02-12 Tom Tromey <tromey@redhat.com>
12697
12698 * remote-utils.c (monitor_output): Pass explicit length to
12699 hexify.
12700
12701 2014-02-12 Tom Tromey <tromey@redhat.com>
12702
12703 * tracepoint.c: Include rsp-low.h.
12704 * server.c: Include rsp-low.h.
12705 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
12706 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
12707 declare.
12708 * remote-utils.c: Include rsp-low.h.
12709 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
12710 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
12711 (convert_int_to_ascii, convert_ascii_to_int): Move to
12712 common/rsp-low.c.
12713 * regcache.c: Include rsp-low.h.
12714 * ax.c: Include rsp-low.h.
12715 * Makefile.in (SFILES): Add common/rsp-low.c.
12716 (OBS): Add rsp-low.o.
12717 (rsp-low.o): New target.
12718
12719 2014-02-12 Tom Tromey <tromey@redhat.com>
12720
12721 * utils.h (pulongest, plongest, phex_nz): Don't declare.
12722 Include print-utils.h.
12723 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
12724 (plongest, thirty_two, phex_nz): Remove.
12725 * Makefile.in (SFILES): Add common/print-utils.c.
12726 (OBS): Add print-utils.o.
12727 (print-utils-ipa.o): New target.
12728 (print-utils.o): New target.
12729 (IPA_OBJS): Add print-utils-ipa.o.
12730
12731 2014-02-06 Tom Tromey <tromey@redhat.com>
12732
12733 * Makefile.in (SFILES): Fix indentation.
12734
12735 2014-02-05 Doug Evans <dje@google.com>
12736
12737 * linux-low.c (linux_wait_for_event): Improve comment.
12738 (linux_wait_1): Keep current_inferior in sync with event_child.
12739
12740 2014-01-22 Doug Evans <dje@google.com>
12741
12742 * gdbthread.h (gdb_id_to_thread): Delete, unused.
12743
12744 2014-01-22 Doug Evans <dje@google.com>
12745
12746 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
12747 * configure: Regenerate.
12748 * config.in: Regenerate.
12749 * Makefile.in (SFILES): Add debug.c.
12750 (OBS): Add debug.o.
12751 * debug.c: New file.
12752 * debug.h: New file.
12753 * linux-aarch64-low.c (*): Update all debugging printfs to use
12754 debug_printf instead of fprintf.
12755 * linux-arm-low.c (*): Ditto.
12756 * linux-cris-low.c (*): Ditto.
12757 * linux-crisv32-low.c (*): Ditto.
12758 * linux-m32r-low.c (*): Ditto.
12759 * linux-sparc-low.c (*): Ditto.
12760 * linux-x86.c (*): Ditto.
12761 * linux-low.c (*): Ditto.
12762 (linux_wait_1): Add calls to debug_enter, debug_exit.
12763 (linux_wait): Remove redundant debugging printf.
12764 (stop_all_lwps): Add calls to debug_enter, debug_exit.
12765 (linux_resume, unstop_all_lwps): Ditto.
12766 * mem-break.c (*): Update all debugging printfs to use
12767 debug_printf instead of fprintf.
12768 * remote-utils.c (*): Ditto.
12769 * thread-db.c (*): Ditto.
12770 * server.c #include <ctype.h>, "gdb_vecs.h".
12771 (debug_threads): Moved to debug.c.
12772 (*): Update all debugging printfs to use debug_printf instead of
12773 fprintf.
12774 (start_inferior): Replace call to fflush with call to debug_flush.
12775 (monitor_show_help): Mention set debug-format.
12776 (parse_debug_format_options): New function.
12777 (handle_monitor_command): Handle "monitor set debug-format".
12778 (gdbserver_usage): Mention --debug-format.
12779 (main): Parse --debug-format.
12780 * server.h (debug_threads): Declaration moved to debug.h.
12781 #include "debug.h".
12782 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
12783 trace_debug_1 that uses debug_printf.
12784 (tracepoint_look_up_symbols): Update all debugging printfs to use
12785 debug_printf instead of fprintf.
12786
12787 2014-01-20 Baruch Siach <baruch@tkos.co.il>
12788
12789 * linux-xtensa-low.c: Include asm/ptrace.h instead of
12790 sys/ptrace.h.
12791
12792 2014-01-17 Pedro Alves <palves@redhat.com>
12793
12794 PR build/16445
12795 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
12796 defined after including gdb_proc_service.h.
12797
12798 2014-01-16 Doug Evans <dje@google.com>
12799
12800 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
12801 (match_dll): Use it.
12802
12803 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
12804
12805 * target.h (target_ops) <read_btrace>: Change parameters and
12806 return type to allow error reporting.
12807 * server.c (handle_qxfer_btrace): Support delta reads. Pass
12808 trace reading errors on.
12809 * linux-low.c (linux_low_read_btrace): Pass trace reading
12810 errors on.
12811 (linux_low_disable_btrace): New.
12812
12813 2014-01-15 Doug Evans <dje@google.com>
12814
12815 * inferiors.c (thread_id_to_gdb_id): Delete.
12816 * inferiors.h (thread_id_to_gdb_id): Delete.
12817
12818 2014-01-13 Eli Zaretskii <eliz@gnu.org>
12819
12820 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
12821 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
12822 versions.
12823
12824 2014-01-08 Pedro Alves <palves@redhat.com>
12825
12826 * server.c (handle_status): Don't discard previous queued stop
12827 replies or thread's pending status here.
12828 (main) <disconnection>: Do it here instead.
12829
12830 2014-01-08 Pedro Alves <palves@redhat.com>
12831
12832 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
12833 * server.c (visit_actioned_threads, handle_pending_status): New
12834 function.
12835 (handle_v_cont): Factor out parts to ...
12836 (resume): ... this new function. If in all-stop, and a thread
12837 being resumed has a pending status, report it without actually
12838 resuming.
12839 (myresume): Adjust to use the new 'resume' function.
12840 (clear_pending_status_callback, set_pending_status_callback)
12841 (find_status_pending_thread_callback): New functions.
12842 (handle_status): Handle the case of multiple threads having
12843 interesting statuses to report. Report threads' real last signal
12844 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
12845 with an interesting thread to report the status for, instead of
12846 always reporting the status of the first thread.
12847
12848 2014-01-01 Joel Brobecker <brobecker@adacore.com>
12849
12850 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
12851 * gdbreplay.c (gdbreplay_version): Likewise.
12852
12853 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
12854
12855 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
12856 iov.iov_len with the real length in use.
12857
12858 2013-12-13 Joel Brobecker <brobecker@adacore.com>
12859
12860 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
12861 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
12862 for all targets that use win32-low.c.
12863 * win32-low.c (win32_ensure_ntdll_loaded): New function.
12864 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
12865
12866 2013-12-13 Pedro Alves <palves@redhat.com>
12867
12868 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
12869 if equal to TARGET_WAITKIND_LOADED.
12870 * win32-low.c (cached_status): New static global.
12871 (win32_wait): Add declaration.
12872 (do_initial_child_stuff): Flush all initial pending debug events
12873 up to the initial breakpoint.
12874 (win32_wait): If CACHED_STATUS was set, return that instead
12875 of doing a real wait. Remove the code resuming the execution
12876 of the inferior after receiving a TARGET_WAITKIND_LOADED event
12877 during the initial phase. Also remove the code changing
12878 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
12879 TARGET_WAITKIND_STOPPED.
12880
12881 2013-12-11 Yao Qi <yao@codesourcery.com>
12882
12883 * notif.c (handle_notif_ack): Return 0 if no notification
12884 matches.
12885
12886 2013-11-20 Doug Evans <dje@google.com>
12887
12888 * linux-low.c (linux_set_resume_request): Fix comment.
12889
12890 2013-11-20 Doug Evans <dje@google.com>
12891
12892 * linux-low.c (resume_status_pending_p): Tweak comment.
12893
12894 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
12895
12896 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
12897 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
12898 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
12899 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
12900 (srv_amd64_regobj): Add amd64-mpx.o.
12901 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
12902 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
12903 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
12904 * i387-fp.c (num_pl_bnd_register) Added constant.
12905 (num_pl_bnd_cfg_registers) Added constant.
12906 (struct i387_xsave) Added reserved area and MPX fields.
12907 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
12908 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
12909 function.
12910 (tdesc_i386_mpx_linux): Add MPX amd64 target.
12911 (init_registers_amd64_mpx_linux): Declare new function.
12912 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
12913 (x86_64_regmap): Add MPX registers.
12914 (x86_linux_read_description): Add MPX case.
12915 (initialize_low_arch): Initialize MPX targets.
12916
12917 2013-11-18 Tom Tromey <tromey@redhat.com>
12918
12919 * configure: Rebuild.
12920 * configure.ac: Don't check for stdlib.h.
12921 * gdbreplay.c: Unconditionally include stdlib.h.
12922
12923 2013-11-18 Tom Tromey <tromey@redhat.com>
12924
12925 * config.in: Rebuild.
12926 * configure: Rebuild.
12927 * configure.ac: Don't use AC_HEADER_DIRENT.
12928
12929 2013-11-18 Tom Tromey <tromey@redhat.com>
12930
12931 * server.h: Don't check HAVE_STRING_H.
12932 * gdbreplay.c: Don't check HAVE_STRING_H.
12933 * configure: Rebuild.
12934
12935 2013-11-18 Tom Tromey <tromey@redhat.com>
12936
12937 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
12938 LIBGNU.
12939
12940 2013-11-08 Tom Tromey <tromey@redhat.com>
12941
12942 * configure, config.in: Rebuild.
12943 * configure.ac: Remove unused configury.
12944
12945 2013-11-08 Tom Tromey <tromey@redhat.com>
12946
12947 * acinclude.m4: Include common.m4, codeset.m4.
12948 * configure, config.in: Rebuild.
12949 * configure.ac: Use GDB_AC_COMMON.
12950
12951 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
12952
12953 * linux-s390-low.c (HWCAP_S390_TE): New define.
12954 (s390_arch_setup): Consider the TE field in the HWCAP for
12955 determining 'have_regset_tdb'.
12956
12957 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
12958
12959 PR gdb/16014
12960 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
12961 call to sizeof.
12962
12963 2013-10-02 Pedro Alves <palves@redhat.com>
12964
12965 * server.c (process_serial_event): Don't output "GDBserver
12966 exiting" if GDB is connected through stdio.
12967 * target.c (mywait): Likewise, be silent if GDB is connected
12968 through stdio.
12969
12970 2013-10-01 Joel Brobecker <brobecker@adacore.com>
12971
12972 * lynx-low.c (lynx_add_threads_after_attach): New function.
12973 (lynx_attach): Remove call to add_thread. Add call to
12974 lynx_add_threads_after_attach instead.
12975
12976 2013-09-28 Mike Frysinger <vapier@gentoo.org>
12977
12978 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
12979 * config.in, configure: Regenerated.
12980
12981 2013-09-18 Yao Qi <yao@codesourcery.com>
12982
12983 PR server/15959
12984 * server.c (start_inferior): Clear 'resume_info'.
12985
12986 2013-09-16 Jiong Wang <jiwang@tilera.com>
12987
12988 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
12989 for each register.
12990
12991 2013-09-16 Jiong Wang <jiwang@tilera.com>
12992
12993 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
12994 linux-tile-low.o to srv_tgtobj.
12995
12996 2013-09-16 Will Newton <will.newton@linaro.org>
12997
12998 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
12999 out regs.
13000
13001 2013-09-06 Pedro Alves <palves@redhat.com>
13002
13003 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13004 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13005 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13006 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13007 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13008 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13009
13010 2013-09-06 Pedro Alves <palves@redhat.com>
13011
13012 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13013 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13014
13015 2013-09-06 Pedro Alves <palves@redhat.com>
13016
13017 * linux-amd64-ipa.c: Include tracepoint.h.
13018 * linux-i386-ipa.c: Include tracepoint.h.
13019
13020 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13021
13022 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13023 (ps_get_thread_area): New function.
13024
13025 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13026
13027 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13028 (initialize_low_arch): Call init_registers_crisv32 rather than
13029 init_register_crisv32.
13030
13031 2013-09-05 Pedro Alves <palves@redhat.com>
13032
13033 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13034 to ...
13035 * hostio.h: ... this new file.
13036 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13037 win32-low.c: Include hostio.h.
13038
13039 2013-09-05 Pedro Alves <palves@redhat.com>
13040
13041 * server.h (gdb_client_data, handler_func, callback_handler_func)
13042 (delete_file_handler, add_file_handler, append_callback_event)
13043 (delete_callback_event, start_event_loop, initialize_event_loop):
13044 Move to event-loop.h and include it.
13045 * event-loop.h: New file.
13046
13047 2013-09-05 Pedro Alves <palves@redhat.com>
13048
13049 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13050 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13051 (loaded_dll, unloaded_dll): Move to ...
13052 * dll.h: ... this new file.
13053 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13054
13055 2013-09-05 Pedro Alves <palves@redhat.com>
13056
13057 * server.h (current_process, get_thread_process, all_processes)
13058 (add_inferior_to_list, for_each_inferior, current_inferior)
13059 (remove_inferior, add_process, remove_process, find_process_pid)
13060 (have_started_inferiors_p, have_attached_inferiors_p)
13061 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13062 (clear_inferiors, find_inferior, find_inferior_id)
13063 (inferior_target_data, set_inferior_target_data)
13064 (inferior_regcache_data, set_inferior_regcache_data): Move to
13065 inferiors.h, and include it.
13066 * inferiors.h: New file.
13067
13068 2013-09-05 Pedro Alves <palves@redhat.com>
13069
13070 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13071 Move ...
13072 * ax.h: ... here.
13073
13074 2013-09-05 Pedro Alves <palves@redhat.com>
13075
13076 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13077 tracepoint.h.
13078 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13079 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13080 (handle_tracepoint_general_set, handle_tracepoint_query)
13081 (tracepoint_finished_step, tracepoint_was_hit)
13082 (release_while_stepping_state_list, current_traceframe)
13083 (in_readonly_region, traceframe_read_mem)
13084 (fetch_traceframe_registers, traceframe_read_sdata)
13085 (traceframe_read_info, struct fast_tpoint_collect_status)
13086 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13087 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13088 (supply_fast_tracepoint_registers)
13089 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13090 (ipa_tdesc, claim_trampoline_space)
13091 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13092 (agent_mem_read, agent_get_trace_state_variable_value)
13093 (agent_set_trace_state_variable_value, agent_tsv_read)
13094 (agent_mem_read_string, get_raw_reg_func_addr)
13095 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13096 * tracepoint.h: ... this new file.
13097
13098 2013-09-05 Pedro Alves <palves@redhat.com>
13099
13100 * server.h (perror_with_name, error, fatal, warning, paddress)
13101 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13102 include it.
13103 * utils.h: New file.
13104
13105 2013-09-05 Pedro Alves <palves@redhat.com>
13106
13107 * server.h (remote_debug, noack_mode, transport_is_reliable)
13108 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13109 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13110 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13111 (write_enn, initialize_async_io, enable_async_io)
13112 (disable_async_io, check_remote_input_interrupt_request)
13113 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13114 (dead_thread_notify, prepare_resume_reply)
13115 (decode_address_to_semicolon, decode_address, decode_m_packet)
13116 (decode_M_packet, decode_X_packet, decode_xfer_write)
13117 (decode_search_memory_packet, unhexify, hexify)
13118 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13119 (look_up_one_symbol, relocate_instruction)
13120 (monitor_output): Move to remote-utils.h, and include it.
13121 * remote-utils.h: New file.
13122
13123 2013-09-05 Pedro Alves <palves@redhat.com>
13124
13125 * server.h (_): Delete.
13126
13127 2013-09-02 Pedro Alves <palves@redhat.com>
13128
13129 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13130 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13131 allocated.
13132 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13133
13134 2013-09-02 Pierre Muller <muller@sourceware.org>
13135
13136 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13137 or WriteProcessMemory complete successfully and handle
13138 ERROR_PARTIAL_COPY error.
13139
13140 2013-09-02 Pedro Alves <palves@redhat.com>
13141
13142 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13143 error instead of EIO.
13144
13145 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13146
13147 PR server/15604
13148 * linux-low.c: Include filestuff.h.
13149 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13150 * lynx-low.c: Include filestuff.h.
13151 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13152 * server.c: Include filestuff.h.
13153 (main): Call notice_open_fds.
13154 * spu-low.c: Include filestuff.h.
13155 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13156
13157 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13158
13159 * Makefile.in: Explain why ../target and ../nat are not
13160 listed as include file search paths.
13161 (linux-waitpid.o): New object file rule.
13162 * configure.srv (srv_native_linux_obj): New variable.
13163 Replace all occurrences of linux native object files with
13164 $srv_native_linux_obj.
13165 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13166 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13167 (linux_enable_event_reporting): Remove declaration.
13168 (my_waitpid): Moved to common/linux-waitpid.c.
13169 (linux_wait_for_event): Pass ptid when calling
13170 linux_enable_event_reporting.
13171 (linux_supports_tracefork_flag): Remove.
13172 (linux_enable_event_reporting): Likewise.
13173 (linux_tracefork_grandchild): Remove.
13174 (STACK_SIZE): Moved to common/linux-ptrace.c.
13175 (linux_tracefork_child): Remove.
13176 (linux_test_for_tracefork): Remove.
13177 (linux_look_up_symbols): Call linux_supports_traceclone.
13178 (initialize_low): Remove call to linux_test_for_tracefork.
13179 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13180 common/linux-ptrace.h.
13181 (PTRACE_TYPE_ARG4): Likewise.
13182 Include linux-ptrace.h.
13183
13184 2013-08-21 Pedro Alves <palves@redhat.com>
13185
13186 * config.in: Renegerate.
13187
13188 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13189
13190 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13191 (SFILES): Remove $(srcdir)/common/target-common.c and
13192 add $(srcdir)/target/waitstatus.c.
13193 (OBS): Remove target-common.o and add waitstatus.o.
13194 (server_h): Remove $(srcdir)/../common/target-common.h and
13195 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13196 and $(srcdir)/../target/waitstatus.h.
13197 (target-common.o): Remove.
13198 (waitstatus.o): New target object file.
13199 * target.h: Do not include target-common.h and
13200 include target/resume.h, target/wait.h and
13201 target/waitstatus.h.
13202
13203 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13204
13205 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13206 to PTRACE_TYPE_ARG3.
13207 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13208 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13209 PTRACE_TYPE_ARG4.
13210 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13211 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13212
13213 2013-07-27 Jie Zhang <jie@codesourcery.com>
13214 Daniel Jacobowitz <dan@codesourcery.com>
13215 Yao Qi <yao@codesourcery.com>
13216
13217 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13218 (mips-linux-watch.o): New rule.
13219 (mips_linux_watch_h): New variable.
13220 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13221 srv_tgtobj.
13222 * linux-mips-low.c: Include mips-linux-watch.h.
13223 (struct arch_process_info, struct arch_lwp_info): New.
13224 (update_watch_registers_callback): New function.
13225 (mips_linux_new_process, mips_linux_new_thread) New functions.
13226 (mips_linux_prepare_to_resume, mips_insert_point): New
13227 functions.
13228 (mips_remove_point, mips_stopped_by_watchpoint): New
13229 functions.
13230 (rsp_bp_type_to_target_hw_bp_type): New function.
13231 (mips_stopped_data_address): New function.
13232 (the_low_target): Add watchpoint support functions.
13233
13234 2013-07-27 Yao Qi <yao@codesourcery.com>
13235
13236 * i386-low.c: Include break-common.h.
13237 (enum target_hw_bp_type): Remove.
13238
13239 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13240
13241 * Makefile.in (SFILES): /common/target-common.c.
13242 (OBS): Add target-common.o.
13243 (server_h): Add $(srcdir)/../common/target-common.h.
13244 (target-common.o): New target.
13245 * server.c (queue_stop_reply_callback): Free
13246 status string after use.
13247 * target.c (target_waitstatus_to_string): Remove.
13248 * target.h: Include target-common.h.
13249 (resume_kind): Likewise.
13250 (target_waitkind): Likewise.
13251 (target_waitstatus): Likewise.
13252 (TARGET_WNOHANG): Likewise.
13253
13254 2013-07-04 Yao Qi <yao@codesourcery.com>
13255
13256 * Makefile.in (host_alias): Use @host_noncanonical@.
13257 (target_alias): Use @target_noncanonical@.
13258 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13259 ACX_NONCANONICAL_HOST.
13260 * configure: Regenerated.
13261
13262 Revert:
13263 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13264
13265 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13266 * configure: Rebuild.
13267 * Makefile.in (version_host, version_target): Get from configure.
13268 (version.c): Use $(version_host) and $(version_target).
13269
13270 2013-07-03 Pedro Alves <palves@redhat.com>
13271
13272 * Makefile.in (config.status): Depend on development.sh.
13273 * acinclude.m4: Include libmcheck.m4.
13274 * configure: Regenerate.
13275
13276 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13277
13278 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13279 attribute inside the parentheses.
13280 (winapi_DebugSetProcessKillOnExit): Ditto.
13281 (winapi_DebugBreakProcess): Ditto.
13282 (winapi_GenerateConsoleCtrlEvent): Ditto.
13283
13284 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13285
13286 * notif.h (notif_event): Add a dummy member to avoid compiler
13287 errors.
13288
13289 2013-07-01 Pedro Alves <palves@redhat.com>
13290
13291 * hostio.c (HOSTIO_PATH_MAX): Define.
13292 (require_filename, handle_open, handle_unlink, handle_readlink):
13293 Use it.
13294
13295 2013-07-01 Pedro Alves <palves@redhat.com>
13296
13297 * server.h: Include "pathmax.h".
13298 * linux-low.c: Don't include sys/param.h.
13299 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13300 MAXPATHLEN.
13301 * win32-low.c: Don't include sys/param.h.
13302 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13303
13304 2013-07-01 Pedro Alves <palves@redhat.com>
13305
13306 * event-loop.c: Don't check HAVE_UNISTD_H before including
13307 <unistd.h>.
13308 * gdbreplay.c: Likewise.
13309 * remote-utils.c: Likewise.
13310 * server.c: Likewise.
13311 * configure.ac: Don't check for unistd.h.
13312 * configure: Regenerate.
13313
13314 2013-06-28 Tom Tromey <tromey@redhat.com>
13315
13316 * Makefile.in (version.c): Use version.in, not
13317 common/version.in.
13318
13319 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13320
13321 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13322 * configure: Rebuild.
13323 * Makefile.in (version_host, version_target): Get from configure.
13324 (version.c): Use $(version_host) and $(version_target).
13325
13326 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13327
13328 Fix trace-status to output user name without trailing colon.
13329 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13330
13331 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13332
13333 Fix trace-status to output proper start-time and stop-time.
13334 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13335 output start time and stop time in hex as gdb expects.
13336
13337 2013-06-26 Pedro Alves <pedro@codesourcery.com>
13338
13339 * tracepoint.c (build_traceframe_info_xml): Output trace state
13340 variables present in the trace buffer.
13341
13342 2013-06-24 Tom Tromey <tromey@redhat.com>
13343
13344 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13345 create-version.sh.
13346 (version.o): Remove.
13347 * gdbreplay.c: Include version.h.
13348 (version, host_name): Don't declare.
13349 * server.h: Include version.h.
13350 (version, host_name): Don't declare.
13351
13352 2013-06-12 Pedro Alves <palves@redhat.com>
13353
13354 * linux-x86-low.c (linux_is_elf64): Delete global.
13355 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13356 with local linux_pid_exe_is_elf_64_file use.
13357
13358 2013-06-11 Pedro Alves <palves@redhat.com>
13359
13360 * linux-low.c (regset_disabled, disable_regset): New functions.
13361 (regsets_fetch_inferior_registers)
13362 (regsets_store_inferior_registers): Use them.
13363 (initialize_regsets_info); Don't allocate the disabled_regsets
13364 array here.
13365 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13366 comment.
13367
13368 2013-06-11 Pedro Alves <palves@redhat.com>
13369
13370 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13371 xmalloc.
13372
13373 2013-06-11 Pedro Alves <palves@redhat.com>
13374
13375 * linux-x86-low.c (initialize_low_arch): Call
13376 init_registers_x32_avx_linux.
13377
13378 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13379
13380 Fix compatibility with Android Bionic.
13381 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13382 it is not empty.
13383
13384 2013-06-07 Pedro Alves <palves@redhat.com>
13385
13386 PR server/14823
13387 * Makefile.in (OBS): Add tdesc.o.
13388 (IPA_OBJS): Add tdesc-ipa.o.
13389 (tdesc-ipa.o): New rule.
13390 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13391 interface.
13392 * linux-low.c (new_inferior): Delete.
13393 (disabled_regsets, num_regsets): Delete.
13394 (linux_add_process): Adjust to set the new per-process
13395 new_inferior flag.
13396 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13397 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13398 was a stop. When calling arch_setup, switch the current inferior
13399 to the thread that got an event.
13400 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13401 (regsets_fetch_inferior_registers)
13402 (regsets_store_inferior_registers): New regsets_info parameter.
13403 Adjust to use it.
13404 (linux_register_in_regsets): New regs_info parameter. Adjust to
13405 use it.
13406 (register_addr, fetch_register, store_register): New usrregs_info
13407 parameter. Adjust to use it.
13408 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13409 parameter regs_info. Adjust to use it.
13410 (linux_fetch_registers): Get the current inferior's regs_info, and
13411 adjust to use it.
13412 (linux_store_registers): Ditto.
13413 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13414 (initialize_low): Don't initialize the target_regsets here. Call
13415 initialize_low_arch.
13416 * linux-low.h (target_regsets): Delete declaration.
13417 (struct regsets_info): New.
13418 (struct usrregs_info): New.
13419 (struct regs_info): New.
13420 (struct process_info_private) <new_inferior>: New field.
13421 (struct linux_target_ops): Delete the num_regs, regmap, and
13422 regset_bitmap fields. New field regs_info.
13423 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13424 * i387-fp.c (num_xmm_registers): Delete.
13425 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13426 calls to new interface.
13427 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13428 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13429 Infer the number of xmm registers from the regcache's target
13430 description.
13431 * i387-fp.h (num_xmm_registers): Delete.
13432 * inferiors.c (add_thread): Don't install the thread's regcache
13433 here.
13434 * proc-service.c (gregset_info): Fetch the current inferior's
13435 regs_info. Adjust to use it.
13436 * regcache.c: Include tdesc.h.
13437 (register_bytes, reg_defs, num_registers)
13438 (gdbserver_expedite_regs): Delete.
13439 (get_thread_regcache): If the thread doesn't have a regcache yet,
13440 create one, instead of aborting gdbserver.
13441 (regcache_invalidate_one): Rename to ...
13442 (regcache_invalidate_thread): ... this.
13443 (regcache_invalidate_one): New.
13444 (regcache_invalidate): Only invalidate registers of the current
13445 process.
13446 (init_register_cache): Add target_desc parameter, and use it.
13447 (new_register_cache): Ditto. Assert the target description has a
13448 non zero registers_size.
13449 (regcache_cpy): Add assertions. Adjust.
13450 (realloc_register_cache, set_register_cache): Delete.
13451 (registers_to_string, registers_from_string): Adjust.
13452 (find_register_by_name, find_regno, find_register_by_number)
13453 (register_cache_size): Add target_desc parameter, and use it.
13454 (free_register_cache_thread, free_register_cache_thread_one)
13455 (regcache_release, register_cache_size): New.
13456 (register_size): Add target_desc parameter, and use it.
13457 (register_data, supply_register, supply_register_zeroed)
13458 (supply_regblock, supply_register_by_name, collect_register)
13459 (collect_register_as_string, collect_register_by_name): Adjust.
13460 * regcache.h (struct target_desc): Forward declare.
13461 (struct regcache) <tdesc>: New field.
13462 (init_register_cache, new_register_cache): Add target_desc
13463 parameter.
13464 (regcache_invalidate_thread): Declare.
13465 (regcache_invalidate_one): Delete declaration.
13466 (regcache_release): Declare.
13467 (find_register_by_number, register_cache_size, register_size)
13468 (find_regno): Add target_desc parameter.
13469 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13470 declarations.
13471 * remote-utils.c: Include tdesc.h.
13472 (outreg, prepare_resume_reply): Adjust.
13473 * server.c: Include tdesc.h.
13474 (gdbserver_xmltarget): Delete declaration.
13475 (get_features_xml, process_serial_event): Adjust.
13476 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13477 declare.
13478 (struct process_info) <tdesc>: New field.
13479 (ipa_tdesc): Declare.
13480 * tdesc.c: New file.
13481 * tdesc.h: New file.
13482 * tracepoint.c: Include tdesc.h.
13483 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13484 (get_context_regcache): Adjust to pass ipa_tdesc down.
13485 (do_action_at_tracepoint): Adjust to get the register cache size
13486 from the context regcache's description.
13487 (traceframe_walk_blocks): Adjust to get the register cache size
13488 from the current trace frame's description.
13489 (traceframe_get_pc): Adjust to get current trace frame's
13490 description and pass it down.
13491 (gdb_collect): Adjust to get the register cache size from the
13492 IPA's description.
13493 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13494 (gdbserver_xmltarget): Delete.
13495 (initialize_low_tracepoint): Set the ipa's target description.
13496 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13497 (initialize_low_tracepoint): Set the ipa's target description.
13498 * linux-x86-low.c: Include tdesc.h.
13499 [__x86_64__] (is_64bit_tdesc): New.
13500 (ps_get_thread_area, x86_get_thread_area): Use it.
13501 (i386_cannot_store_register): Rename to ...
13502 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13503 (i386_cannot_fetch_register): Rename to ...
13504 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13505 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13506 to new interface.
13507 (target_regsets): Rename to ...
13508 (x86_regsets): ... this.
13509 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13510 interface.
13511 (x86_siginfo_fixup): Use is_64bit_tdesc.
13512 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13513 (tdesc_x32_avx_linux, tdesc_x32_linux)
13514 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13515 Declare.
13516 (x86_linux_update_xmltarget): Delete.
13517 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13518 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13519 (AMD64_LINUX_USER64_CS): New.
13520 (x86_linux_read_description): New, based on
13521 x86_linux_update_xmltarget.
13522 (same_process_callback): New.
13523 (x86_arch_setup_process_callback): New.
13524 (x86_linux_update_xmltarget): New.
13525 (x86_regsets_info): New.
13526 (amd64_linux_regs_info): New.
13527 (i386_linux_usrregs_info): New.
13528 (i386_linux_regs_info): New.
13529 (x86_linux_regs_info): New.
13530 (x86_arch_setup): Reimplement.
13531 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13532 (x86_emit_ops): Ditto.
13533 (the_low_target): Adjust. Install x86_linux_regs_info,
13534 x86_cannot_fetch_register, and x86_cannot_store_register.
13535 (initialize_low_arch): New.
13536 * linux-ia64-low.c (tdesc_ia64): Declare.
13537 (ia64_fetch_register): Adjust.
13538 (ia64_usrregs_info, regs_info): New globals.
13539 (ia64_regs_info): New function.
13540 (the_low_target): Adjust.
13541 (initialize_low_arch): New function.
13542 * linux-sparc-low.c (tdesc_sparc64): Declare.
13543 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13544 Adjust.
13545 (sparc_arch_setup): New function.
13546 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13547 (the_low_target): Adjust.
13548 (initialize_low_arch): New function.
13549 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13550 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13551 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13552 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13553 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13554 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13555 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13556 (tdesc_powerpc_isa205_vsx64l): Declare.
13557 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13558 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13559 (ppc_set_pc, ppc_get_hwcap): Adjust.
13560 (ppc_usrregs_info): Forward declare.
13561 (!__powerpc64__) ppc_regmap_adjusted: New global.
13562 (ppc_arch_setup): Adjust to the current process'es target
13563 description.
13564 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13565 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13566 (ppc_store_evrregset): Adjust.
13567 (target_regsets): Rename to ...
13568 (ppc_regsets): ... this, and make static.
13569 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13570 (ppc_regs_info): New function.
13571 (the_low_target): Adjust.
13572 (initialize_low_arch): New function.
13573 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13574 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13575 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13576 (tdesc_s390x_linux64v2): Declare.
13577 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13578 (s390_fill_gregset, s390_store_last_break): Adjust.
13579 (target_regsets): Rename to ...
13580 (s390_regsets): ... this, and make static.
13581 (s390_get_pc, s390_set_pc): Adjust.
13582 (s390_get_hwcap): New target_desc parameter, and use it.
13583 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13584 (s390_arch_setup): Adjust to set the current process'es target
13585 description. Don't adjust the regmap.
13586 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13587 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13588 (regs_info_3264): New globals.
13589 (s390_regs_info): New function.
13590 (the_low_target): Adjust.
13591 (initialize_low_arch): New function.
13592 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13593 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13594 [__mips64] (init_registers_mips_linux)
13595 (init_registers_mips_dsp_linux): Delete defines.
13596 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13597 (have_dsp): New global.
13598 (mips_read_description): New, based on mips_arch_setup.
13599 (mips_arch_setup): Reimplement.
13600 (get_usrregs_info): New function.
13601 (mips_cannot_fetch_register, mips_cannot_store_register)
13602 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13603 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13604 (target_regsets): Rename to ...
13605 (mips_regsets): ... this, and make static.
13606 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13607 (dsp_regs_info, regs_info): New globals.
13608 (mips_regs_info): New function.
13609 (the_low_target): Adjust.
13610 (initialize_low_arch): New function.
13611 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13612 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13613 Declare.
13614 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13615 (arm_read_description): New, with bits factored from
13616 arm_arch_setup.
13617 (arm_arch_setup): Reimplement.
13618 (target_regsets): Rename to ...
13619 (arm_regsets): ... this, and make static.
13620 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13621 (arm_regs_info): New function.
13622 (the_low_target): Adjust.
13623 (initialize_low_arch): New function.
13624 * linux-m68k-low.c (tdesc_m68k): Declare.
13625 (target_regsets): Rename to ...
13626 (m68k_regsets): ... this, and make static.
13627 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13628 (m68k_regs_info): New function.
13629 (m68k_arch_setup): New function.
13630 (the_low_target): Adjust.
13631 (initialize_low_arch): New function.
13632 * linux-sh-low.c (tdesc_sharch): Declare.
13633 (target_regsets): Rename to ...
13634 (sh_regsets): ... this, and make static.
13635 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13636 (sh_regs_info, sh_arch_setup): New functions.
13637 (the_low_target): Adjust.
13638 (initialize_low_arch): New function.
13639 * linux-bfin-low.c (tdesc_bfin): Declare.
13640 (bfin_arch_setup): New function.
13641 (bfin_usrregs_info, regs_info): New globals.
13642 (bfin_regs_info): New function.
13643 (the_low_target): Adjust.
13644 (initialize_low_arch): New function.
13645 * linux-cris-low.c (tdesc_cris): Declare.
13646 (cris_arch_setup): New function.
13647 (cris_usrregs_info, regs_info): New globals.
13648 (cris_regs_info): New function.
13649 (the_low_target): Adjust.
13650 (initialize_low_arch): New function.
13651 * linux-cris-low.c (tdesc_crisv32): Declare.
13652 (cris_arch_setup): New function.
13653 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13654 (cris_regs_info): New function.
13655 (the_low_target): Adjust.
13656 (initialize_low_arch): New function.
13657 * linux-m32r-low.c (tdesc_m32r): Declare.
13658 (m32r_arch_setup): New function.
13659 (m32r_usrregs_info, regs_info): New globals.
13660 (m32r_regs_info): Adjust.
13661 (initialize_low_arch): New function.
13662 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13663 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13664 (tic6x_usrregs_info): Forward declare.
13665 (tic6x_read_description): New function, based on ...
13666 (tic6x_arch_setup): ... this. Reimplement.
13667 (target_regsets): Rename to ...
13668 (tic6x_regsets): ... this, and make static.
13669 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13670 (tic6x_regs_info): New function.
13671 (the_low_target): Adjust.
13672 (initialize_low_arch): New function.
13673 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13674 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13675 (target_regsets): Rename to ...
13676 (xtensa_regsets): ... this, and make static.
13677 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13678 globals.
13679 (xtensa_arch_setup, xtensa_regs_info): New functions.
13680 (the_low_target): Adjust.
13681 (initialize_low_arch): New function.
13682 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13683 (nios2_arch_setup): Set the current process'es tdesc.
13684 (target_regsets): Rename to ...
13685 (nios2_regsets): ... this.
13686 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13687 (nios2_regs_info): New function.
13688 (the_low_target): Adjust.
13689 (initialize_low_arch): New function.
13690 * linux-aarch64-low.c (tdesc_aarch64): Declare.
13691 (aarch64_arch_setup): Set the current process'es tdesc.
13692 (target_regsets): Rename to ...
13693 (aarch64_regsets): ... this.
13694 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
13695 (aarch64_regs_info): New function.
13696 (the_low_target): Adjust.
13697 (initialize_low_arch): New function.
13698 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
13699 globals.
13700 (target_regsets): Rename to ...
13701 (tile_regsets): ... this.
13702 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
13703 (tile_regs_info): New function.
13704 (tile_arch_setup): Set the current process'es tdesc.
13705 (the_low_target): Adjust.
13706 (initialize_low_arch): New function.
13707 * spu-low.c (tdesc_spu): Declare.
13708 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
13709 * win32-arm-low.c (tdesc_arm): Declare.
13710 (arm_arch_setup): New function.
13711 (the_low_target): Install arm_arch_setup instead of
13712 init_registers_arm.
13713 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
13714 (init_windows_x86): Rename to ...
13715 (i386_arch_setup): ... this. Set `win32_tdesc'.
13716 (the_low_target): Adjust.
13717 * win32-low.c (win32_tdesc): New global.
13718 (child_add_thread): Don't create the thread cache here.
13719 (do_initial_child_stuff): Set the new process'es tdesc.
13720 * win32-low.h (struct target_desc): Forward declare.
13721 (win32_tdesc): Declare.
13722 * lynx-i386-low.c (tdesc_i386): Declare global.
13723 (lynx_i386_arch_setup): Set `lynx_tdesc'.
13724 * lynx-low.c (lynx_tdesc): New global.
13725 (lynx_add_process): Set the new process'es tdesc.
13726 * lynx-low.h (struct target_desc): Forward declare.
13727 (lynx_tdesc): Declare global.
13728 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
13729 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
13730 * nto-low.c (nto_tdesc): New global.
13731 (do_attach): Set the new process'es tdesc.
13732 * nto-low.h (struct target_desc): Forward declare.
13733 (nto_tdesc): Declare.
13734 * nto-x86-low.c (tdesc_i386): Declare.
13735 (nto_x86_arch_setup): Set `nto_tdesc'.
13736
13737 2013-06-04 Gary Benson <gbenson@redhat.com>
13738
13739 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
13740 to qSupported response when appropriate.
13741 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
13742 with nonzero-length annex.
13743 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
13744 arguments supplied in annex.
13745
13746 2013-05-31 Doug Evans <dje@google.com>
13747
13748 PR server/15594
13749 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
13750 64 bits in 64-cross-32 environment.
13751
13752 2013-05-28 Pedro Alves <palves@redhat.com>
13753
13754 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
13755 (aarch64-without-fpu.c): Delete rule.
13756 * configure.srv (aarch64*-*-linux*): Remove references to
13757 aarch64-without-fpu.o and aarch64-without-fpu.xml.
13758 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
13759 declaration.
13760
13761 2013-05-24 Pedro Alves <palves@redhat.com>
13762
13763 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
13764 instead of strchr/decode_address. Error if the range isn't split
13765 with a ','. Don't assume there's be a ':' in the action.
13766
13767 2013-05-23 Yao Qi <yao@codesourcery.com>
13768 Pedro Alves <palves@redhat.com>
13769
13770 * linux-low.c (lwp_in_step_range): New function.
13771 (linux_wait_1): If the thread was range stepping and stopped
13772 outside the stepping range, report the stop to GDB. Otherwise,
13773 continue stepping. Add range stepping debug output.
13774 (linux_set_resume_request): Copy the step range from the resume
13775 request to the lwp.
13776 (linux_supports_range_stepping): New.
13777 (linux_target_ops) <supports_range_stepping>: Set to
13778 linux_supports_range_stepping.
13779 * linux-low.h (struct linux_target_ops)
13780 <supports_range_stepping>: New field.
13781 (struct lwp_info) <step_range_start, step_range_end>: New fields.
13782 * linux-x86-low.c (x86_supports_range_stepping): New.
13783 (the_low_target) <supports_range_stepping>: Set to
13784 x86_supports_range_stepping.
13785 * server.c (handle_v_cont): Handle 'r' action.
13786 (handle_v_requests): Append ";r" if the target supports range
13787 stepping.
13788 * target.h (struct thread_resume) <step_range_start,
13789 step_range_end>: New fields.
13790 (struct target_ops) <supports_range_stepping>:
13791 New field.
13792 (target_supports_range_stepping): New macro.
13793
13794 2013-05-17 Joel Brobecker <brobecker@adacore.com>
13795
13796 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
13797 confusion in comment.
13798
13799 2013-05-17 Joel Brobecker <brobecker@adacore.com>
13800
13801 * lynx-low.c (struct process_info_private): New type.
13802 (lynx_add_process): New function.
13803 (lynx_create_inferior, lynx_attach): Replace calls to
13804 add_process by calls to lynx_add_process.
13805 (lynx_resume): If PTID is null, then try using
13806 current_process()->private->last_wait_event_ptid.
13807 Add comments.
13808 (lynx_clear_inferiors): Delete. The contents of that function
13809 has been inlined in lynx_mourn;
13810 (lynx_wait_1): Save the ptid in the process's private data.
13811 (lynx_mourn): Free the process' private data. Replace call
13812 to lynx_clear_inferiors by call to clear_inferiors.
13813
13814 2013-05-17 Yao Qi <yao@codesourcery.com>
13815
13816 * i386-low.c (i386_length_and_rw_bits): Move the comment to
13817 the right place.
13818
13819 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
13820
13821 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
13822 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
13823 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
13824 PT_TEXT_END_ADDR guards. Update comments.
13825 (linux_target_op) <read_offsets>: Conditionally define to
13826 linux_read_offsets if the target is UCLIBC and if it defines
13827 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
13828
13829 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
13830 Andrew Jenner <andrew@codesourcery.com>
13831
13832 * Makefile.in (SFILES): Add linux-nios2-low.c.
13833 (clean): Add action to delete nios2-linux.c.
13834 (nios2-linux.c): New rule.
13835 * configure.srv: Add nios2*-*-linux*.
13836 * linux-nios2-low.c: New.
13837
13838 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
13839
13840 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
13841
13842 2013-04-25 Hui Zhu <hui@codesourcery.com>
13843
13844 PR gdb/15186
13845 * ax.c (ax_printf): Add fflush.
13846
13847 2013-04-22 Tom Tromey <tromey@redhat.com>
13848
13849 * Makefile.in (SFILES): Add filestuff.c.
13850 (OBS): Add filestuff.o.
13851 (filestuff.o): New target.
13852 * config.in, configure: Rebuild.
13853 * configure.ac: Check for fdwalk, pipe2.
13854
13855 2013-04-17 Pedro Alves <palves@redhat.com>
13856
13857 * configure.ac (USE_THREAD_DB): Delete variable.
13858 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
13859 Don't AC_SUBST USE_THREAD_DB.
13860 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
13861 * config.in, configure: Regenerate.
13862
13863 2013-04-16 Pedro Alves <palves@redhat.com>
13864
13865 * linux-low.h (struct lwp_info) <thread_known>: Move under
13866 the USE_THREAD_DB #ifdef.
13867
13868 2013-04-16 Pedro Alves <palves@redhat.com>
13869
13870 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
13871 (linux-low.o): Delete rule.
13872 * linux-low.h: Always include "gdb_thread_db.h" instead of
13873 conditionally including thread_db.h.
13874 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
13875 HAVE_THREAD_DB_H.
13876
13877 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13878
13879 * Makefile.in (install-only): Fix make install regression.
13880
13881 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
13882
13883 Convert man pages to texinfo, new gdbinit.5 texinfo page.
13884 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
13885 installation.
13886 * gdbserver.1: Remove.
13887
13888 2013-03-22 Pedro Alves <palves@redhat.com>
13889
13890 * linux-low.c (handle_extended_wait): Don't call
13891 linux_enable_event_reporting.
13892
13893 2013-03-15 Tony Theodore <tonyt@logyst.com>
13894
13895 PR build/9098:
13896 * Makefile.in (SHELL): Use @SHELL@.
13897
13898 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
13899
13900 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
13901 compiler warning.
13902
13903 2013-03-13 Joel Brobecker <brobecker@adacore.com>
13904
13905 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
13906 Remove extraneous NULL element.
13907
13908 2013-03-13 Yao Qi <yao@codesourcery.com>
13909
13910 * tracepoint.c (traceframe_read_tsv): Look for the last matched
13911 'V' block in trace frame.
13912
13913 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
13914
13915 * target.h (struct target_ops): Add btrace ops.
13916 (target_supports_btrace): New macro.
13917 (target_enable_btrace): New macro.
13918 (target_disable_btrace): New macro.
13919 (target_read_btrace): New macro.
13920 * gdbthread.h (struct thread_info): Add btrace field.
13921 * server.c: Include btrace-common.h.
13922 (handle_btrace_general_set): New function.
13923 (handle_btrace_enable): New function.
13924 (handle_btrace_disable): New function.
13925 (handle_general_set): Call handle_btrace_general_set.
13926 (handle_qxfer_btrace): New function.
13927 (struct qxfer qxfer_packets[]): Add btrace entry.
13928 * inferiors.c (remove_thread): Disable btrace.
13929 * linux-low: Include linux-btrace.h.
13930 (linux_low_enable_btrace): New function.
13931 (linux_low_read_btrace): New function.
13932 (linux_target_ops): Add btrace ops.
13933 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
13934 Add srv_linux_btrace=yes.
13935 (x86_64-*-linux*): Add linux-btrace.o.
13936 Add srv_linux_btrace=yes.
13937 * configure.ac: Define HAVE_LINUX_BTRACE.
13938 * config.in: Regenerated.
13939 * configure: Regenerated.
13940
13941 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
13942
13943 * server.c (handle_qxfer): Preserve error message if -3 is
13944 returned.
13945 (qxfer): Document the -3 return value.
13946
13947 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
13948
13949 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
13950 (linux_btrace_h): New variable.
13951 (linux-btrace.o): New rule.
13952
13953 2013-03-08 Stan Shebs <stan@codesourcery.com>
13954 Hafiz Abid Qadeer <abidh@codesourcery.com>
13955
13956 * tracepoint.c (trace_buffer_size): New global.
13957 (DEFAULT_TRACE_BUFFER_SIZE): New define.
13958 (init_trace_buffer): Change to one-argument function. Allocate
13959 trace buffer memory.
13960 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
13961 handle QTBuffer:size packet.
13962 (cmd_bigqtbuffer_size): New function.
13963 (initialize_tracepoint): Call init_trace_buffer with
13964 DEFAULT_TRACE_BUFFER_SIZE.
13965 * server.c (handle_query): Add QTBuffer:size in the
13966 supported packets.
13967
13968 2013-03-07 Yao Qi <yao@codesourcery.com>
13969
13970 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
13971 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
13972 of -1.
13973 (cmd_qtsp): Adjust condition. Do post increment.
13974 Set cur_action and cur_step_action back to 0.
13975
13976 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
13977
13978 PR server/15236
13979 * linux-low.c (linux_write_memory): Return early success if LEN is
13980 zero.
13981
13982 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
13983
13984 * configure.srv: Add x86_64-*-cygwin* as target.
13985
13986 2013-02-28 Tom Tromey <tromey@redhat.com>
13987
13988 * configure.ac: Invoke AC_SYS_LARGEFILE.
13989 * configure, config.in: Rebuild.
13990
13991 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
13992
13993 * win32-low.c: Throughout, fix format strings and casts of
13994 printf-like functions to avoid type related warnings on all
13995 platforms.
13996 (get_child_debug_event): Print dwDebugEventCode as hex since
13997 that's how it's usually documented.
13998
13999 2013-02-28 Yao Qi <yao@codesourcery.com>
14000
14001 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14002 pulongest.
14003
14004 2013-02-27 Jiong Wang <jiwang@tilera.com>
14005
14006 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14007 (reg-tilegx32.c): New rule.
14008 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14009 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14010 different register info initializer according to elf class.
14011 (init_registers_tilgx32): New function. The tilegx32 register info
14012 initializer.
14013 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14014 (tile_store_gregset): Likewise.
14015
14016 2013-02-27 Yao Qi <yao@codesourcery.com>
14017
14018 * server.c (process_point_options): Print debug message when
14019 debug_threads is true.
14020
14021 2013-02-26 Yao Qi <yao@codesourcery.com>
14022
14023 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14024
14025 2013-02-19 Pedro Alves <palves@redhat.com>
14026 Kai Tietz <ktietz@redhat.com>
14027
14028 PR gdb/15161
14029
14030 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14031 instead of strtoul to extract address from packet.
14032 (process_serial_event) <'z'>: Likewise.
14033
14034 2013-02-18 Yao Qi <yao@codesourcery.com>
14035
14036 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14037
14038 2013-02-14 Pedro Alves <palves@redhat.com>
14039
14040 Plug memory leak.
14041
14042 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14043 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14044
14045 2013-02-14 Pedro Alves <palves@redhat.com>
14046
14047 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14048
14049 2013-02-14 Pedro Alves <palves@redhat.com>
14050
14051 * tracepoint.c (save_string): Delete.
14052 (add_tracepoint_action): Use savestring instead of save_string.
14053
14054 2013-02-12 Pedro Alves <palves@redhat.com>
14055
14056 * linux-xtensa-low.c: Ditto.
14057 * xtensa-xtregs.c: Ditto.
14058
14059 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14060
14061 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14062 thread_db.
14063
14064 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14065
14066 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14067 aarch64_num_wp_regs and aarch64_num_bp_regs to
14068 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14069
14070 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14071
14072 * linux-aarch64-low.c (ps_get_thread_area): Replace
14073 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14074
14075 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14076 Marcus Shawcroft <marcus.shawcroft@arm.com>
14077 Nigel Stephens <nigel.stephens@arm.com>
14078 Yufeng Zhang <yufeng.zhang@arm.com>
14079
14080 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14081 (aarch64.c, aarch64-without-fpu.c): New targets.
14082 * configure.srv (aarch64*-*-linux*): New.
14083 * linux-aarch64-low.c: New file.
14084
14085 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14086
14087 * linux-low.c (handle_extended_wait, linux_create_inferior)
14088 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14089 (dequeue_one_deferred_signal, linux_resume_one_thread)
14090 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14091 (linux_tracefork_grandchild, linux_test_for_tracefork)
14092 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14093 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14094 where the argument is 0.
14095
14096 2013-01-25 Yao Qi <yao@codesourcery.com>
14097
14098 * event-loop.c: Include "queue.h".
14099 (gdb_event_p): New typedef.
14100 (struct gdb_event) <next_event>: Remove.
14101 (event_queue): Change to QUEUE(gdb_event_p).
14102 (async_queue_event): Remove.
14103 (gdb_event_xfree): New.
14104 (initialize_event_loop): New.
14105 (process_event): Use API from QUEUE.
14106 (wait_for_event): Likewise.
14107 * server.c (main): Call initialize_event_loop.
14108 * server.h (initialize_event_loop): Declare.
14109
14110 2013-01-18 Yao Qi <yao@codesourcery.com>
14111
14112 * ax.h (struct eval_agent_expr_context): New.
14113 (gdb_eval_agent_expr): Update declaration.
14114 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14115 TFRAME. Add new argument CTX.
14116 * server.h (struct eval_agent_expr_context): Declare.
14117 (agent_mem_read, agent_tsv_read): Update declaration.
14118 (agent_mem_read_string): Likewise.
14119 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14120 (add_traceframe_block): Add new argument TPOINT.
14121 Increase TPOINT->traceframe_usage.
14122 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14123 eval_tracepoint_agent_expr.
14124 (condition_true_at_tracepoint): Likewise.
14125 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14126 (agent_mem_read_string, agent_tsv_read): Likewise.
14127
14128 2013-01-16 Yao Qi <yao@codesourcery.com>
14129
14130 * linux-low.c (linux_resume_one_lwp): Don't check
14131 'lwp->bp_reinsert != 0'.
14132
14133 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14134 Pedro Alves <palves@redhat.com>
14135
14136 * lynx-low.c (ptrace_request_to_str): Define a temporary
14137 macro and use it to simplify this function's implementation.
14138
14139 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14140
14141 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14142 sets errno.
14143
14144 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14145
14146 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14147
14148 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14149
14150 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14151
14152 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14153
14154 * lynx-low.c (lynx_resume): Use the resume_info parameter
14155 to determine the ptid for the lynx_ptrace call, unless
14156 it is equal to minus_one_ptid, in which case we use the
14157 ptid of the current_inferior.
14158 (lynx_wait_1): After having received a thread create/exit
14159 event, resume the inferior's execution using the signaling
14160 thread's ptid, rather than the old ptid.
14161
14162 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14163
14164 * lynx-low.c (lynx_resume): Delete variable ret.
14165
14166 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14167
14168 * gdbreplay.c (gdbreplay_version): Update copyright year.
14169 * server.c (gdbserver_version): Likewise.
14170
14171 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14172
14173 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14174 new thread.
14175
14176 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14177
14178 * lynx-low.c (ptrace_request_to_str): Add handling for
14179 PTRACE_GETTRACESIG.
14180
14181 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14182
14183 * lynx-low.c (lynx_attach): Delete variable new_process.
14184
14185 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14186
14187 * lynx-low.c (lynx_create_inferior): Delete variable
14188 new_process.
14189
14190 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14191
14192 * lynx-low.c (ptrace_request_to_str): Do not handle
14193 PTRACE_GETTHREADLIST if this macro does not exist.
14194
14195 2012-12-15 Yao Qi <yao@codesourcery.com>
14196
14197 * Makefile.in (OBS): Add notif.o.
14198 * notif.c, notif.h: New.
14199 * server.c: Include "notif.h".
14200 (struct vstop_notif) <next>: Remove.
14201 <base>: New field.
14202 (queue_stop_reply): Update.
14203 (push_event, send_next_stop_reply): Remove.
14204 (discard_queued_stop_replies): Update.
14205 (notif_stop): New variable.
14206 (handle_v_stopped): Remove.
14207 (handle_v_requests): Don't call handle_v_stopped. Call
14208 handle_ack_notif instead.
14209 (queue_stop_reply_callback): Call notif_event_enque instead
14210 of queue_stop_reply.
14211 (handle_status): Don't call send_next_stop_reply, call
14212 notif_write_event instead.
14213 (kill_inferior_callback): Likewise.
14214 (detach_or_kill_inferior_callback): Likewise.
14215 (main): Call initialize_notif.
14216 (process_serial_event): Call QUEUE_is_empty.
14217 (handle_target_event): Call notif_push instead of push event.
14218 * server.h (push_event): Remove declaration.
14219
14220 2012-12-10 Tom Tromey <tromey@redhat.com>
14221
14222 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14223 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14224 macros.
14225 (.c.o): Rewrite.
14226 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14227 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14228 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14229 (amd64-linux-ipa.o, ax.o): Rewrite.
14230 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14231 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14232 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14233 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14234 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14235 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14236 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14237 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14238 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14239 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14240 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14241 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14242 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14243 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14244 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14245 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14246 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14247 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14248 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14249 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14250 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14251 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14252 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14253 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14254 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14255 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14256 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14257 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14258 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14259 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14260 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14261 (reg-tilegx.o): Remove.
14262 (all_object_files): New macro.
14263 Include .deps files.
14264 * aclocal.m4, configure: Rebuild.
14265 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14266 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14267 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14268
14269 2012-12-05 Tom Tromey <tromey@redhat.com>
14270
14271 PR gdb/14917:
14272 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14273
14274 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14275
14276 * configure.ac: Check for linux/perf_event.h.
14277 * config.in: Regenerated.
14278 * configure: Regenerated.
14279
14280 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14281
14282 * hostio.c (handle_readlink): Decrease buffer size
14283 parameter passed to readlink by one byte.
14284
14285 2012-11-26 Yao Qi <yao@codesourcery.com>
14286
14287 * configure.ac (build_warnings): Append '-Wempty-body'.
14288 * configure: Regenerated.
14289 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14290 body.
14291
14292 2012-11-15 Pierre Muller <muller@sourceware.org>
14293
14294 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14295 * config.in: Regenerate.
14296 * configure: Regenerate.
14297 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14298 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14299 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14300 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14301 header.
14302 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14303 instead of <sys/wait.h> header.
14304 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14305
14306 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
14307
14308 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14309 (various make rules): Remove -DGDBSERVER
14310
14311 2012-11-09 Yao Qi <yao@codesourcery.com>
14312
14313 * spu-low.c (current_ptid): Move it to ..
14314 * gdbthread.h: ... here. New.
14315 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14316 * server.c (myresume, process_serial_event): Likewise.
14317 * thread-db.c (thread_db_find_new_threads): Likewise.
14318 * tracepoint.c (run_inferior_command): Likewise.
14319
14320 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
14321
14322 * server.c (handle_search_memory_1): Include access length in
14323 warning message.
14324
14325 2012-09-05 Michael Brandt <michael.brandt@axis.com>
14326
14327 * linux-crisv32-low.c: Fix compile errors.
14328
14329 2012-09-04 Yao Qi <yao@codesourcery.com>
14330
14331 * tracepoint.c (cmd_qtsv): Adjust debug message.
14332 Don't check CUR_TPOINT.
14333
14334 2012-08-28 Yao Qi <yao@codesourcery.com>
14335
14336 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14337 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14338 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14339 Remove declarations of xmalloc, xreallloc, xstrdup and
14340 freeargv.
14341 * Makefile.in (libiberty_h): New.
14342 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14343 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14344
14345 2012-08-23 Yao Qi <yao@codesourcery.com>
14346
14347 * server.h: Remove declaration of 'xsnprintf'.
14348
14349 2012-08-22 Keith Seitz <keiths@redhat.com>
14350
14351 * server.h: Include build-gnulib-gbserver/config.h.
14352 * gdbreplay.c: Likewise.
14353
14354 2012-08-08 Doug Evans <dje@google.com>
14355
14356 * Makefile.in (SFILES): Add gdb_vecs.c.
14357 (OBS): Add gdb_vecs.o.
14358 (gdb_vecs_h, host_defs_h): New variables.
14359 (thread-db.o): Add $(gdb_vecs_h) dependency.
14360 (gdb_vecs.o): New rule.
14361 * thread-db.c: #include "gdb_vecs.h".
14362 (thread_db_load_search): Use a vector to iterate over path elements.
14363 Handle text appearing after "$pdir".
14364
14365 * configure.ac: Add check for strstr.
14366 * config.in: Regenerate.
14367 * configure: Regenerate.
14368
14369 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14370
14371 * hostio.c (handle_pread): If pread fails, fall back to attempting
14372 lseek/read.
14373 (handle_pwrite): Likewise for pwrite.
14374
14375 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14376
14377 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14378 between unsupported TYPE and unimplementable ADDR/LEN combination.
14379 (arm_insert_point): Act on new return value.
14380
14381 2012-07-31 Pedro Alves <palves@redhat.com>
14382
14383 * server.c (process_point_options): Only skip tokens if we find
14384 one that is unrecognized. Don't treat 'X' specially while
14385 skipping unrecognized tokens.
14386
14387 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14388
14389 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14390 to 4-byte-align HW breakpoint addresses for Thumb.
14391
14392 2012-07-27 Yao Qi <yao@codesourcery.com>
14393
14394 PR remote/14161.
14395
14396 * server.h: Declare gdb_agent_about_to_close.
14397 * target.c (kill_inferior): Include "agent.h".
14398 New. Send command 'kill'.
14399 * target.h (kill_inferior): Removed macro.
14400 * tracepoint.c (gdb_agent_about_to_close): New.
14401 (gdb_agent_helper_thread): Handle command 'close'.
14402 Wait endlessly until the inferior stops.
14403 Install gdb_agent_remove_socket to atexit hook.
14404 (agent_socket_name): New static variable.
14405 (gdb_agent_socket_init): Replace local variable 'name' with
14406 'agent_socket_name'.
14407 (gdb_agent_remove_socket): New.
14408
14409 2012-07-27 Yao Qi <yao@codesourcery.com>
14410
14411 * server.c (process_point_options): Stop at 'X' when parsing.
14412
14413 2012-07-19 Michael Eager <eager@eagercon.com>
14414
14415 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
14416 to hw_execute.
14417 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14418 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14419 hardware breakpoint.
14420
14421 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14422
14423 * gdbserver/linux-low.c (initialize_low): Call
14424 linux_ptrace_init_warnings.
14425
14426 2012-07-02 Doug Evans <dje@google.com>
14427
14428 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14429 pointer to int.
14430
14431 2012-07-02 Stan Shebs <stan@codesourcery.com>
14432
14433 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14434 (ax.o): Add it to build rule.
14435 (ax-ipa.o): Ditto.
14436 (OBS): Add format.o.
14437 (IPA_OBS): Add format.o.
14438 * server.c (handle_query): Claim support for breakpoint commands.
14439 (process_point_options): Add command case.
14440 (process_serial_event): Leave running if there are printfs in
14441 effect.
14442 * mem-break.h (any_persistent_commands): Declare.
14443 (add_breakpoint_commands): Declare.
14444 (gdb_no_commands_at_breakpoint): Declare.
14445 (run_breakpoint_commands): Declare.
14446 * mem-break.c (struct point_command_list): New struct.
14447 (struct breakpoint): New field command_list.
14448 (any_persistent_commands): New function.
14449 (add_commands_to_breakpoint): New function.
14450 (add_breakpoint_commands): New function.
14451 (gdb_no_commands_at_breakpoint): New function.
14452 (run_breakpoint_commands): New function.
14453 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14454 locally.
14455 * ax.c: Include format.h.
14456 (ax_printf): New function.
14457 (gdb_eval_agent_expr): Add printf opcode.
14458
14459 2012-06-13 Yao Qi <yao@codesourcery.com>
14460
14461 * server.c (start_inferior): Remove duplicated writes to fields
14462 'last_resume_kind' and 'last_status' of 'current_inferior'.
14463
14464 2012-06-12 Yao Qi <yao@codesourcery.com>
14465 Pedro Alves <palves@redhat.com>
14466
14467 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14468 comment.
14469 * server.c (handle_v_cont): Extend comment.
14470
14471 2012-06-11 Yao Qi <yao@codesourcery.com>
14472
14473 * linux-low.c (linux_attach): Add 'static'.
14474
14475 2012-06-06 Yao Qi <yao@codesourcery.com>
14476
14477 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14478
14479 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14480
14481 Fix gcc -flto compilation warning.
14482 * server.c (main): Make variable multi_mode and attach volatile.
14483
14484 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14485
14486 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14487 if the platform doesn't know about it.
14488
14489 2012-05-30 Jeff Kenton <jkenton@tilera.com>
14490
14491 * Makefile.in (SFILES): Add linux-tile-low.c.
14492 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14493 * configure.srv: Handle tilegx-*-linux*.
14494 * linux-tile-low.c: New file.
14495
14496 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14497
14498 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14499
14500 2012-05-24 Pedro Alves <palves@redhat.com>
14501
14502 PR gdb/7205
14503
14504 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
14505
14506 2012-05-24 Pedro Alves <palves@redhat.com>
14507
14508 PR gdb/7205
14509
14510 Replace target_signal with gdb_signal throughout.
14511
14512 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14513
14514 * linux-low.c (linux_store_registers): Avoid the copying sequence
14515 when no data has been retrieved by ptrace.
14516
14517 2012-05-22 Will Deacon <will.deacon@arm.com>
14518
14519 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14520 Include asm/ptrace.h.
14521 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14522 already defined.
14523
14524 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14525
14526 * linux-low.c (linux_store_registers): Don't re-retrieve data
14527 with ptrace that has already been obtained from /proc. Always
14528 copy any data retrieved with ptrace to the buffer supplied.
14529
14530 2012-05-11 Yao Qi <yao@codesourcery.com>
14531 Pedro Alves <palves@redhat.com>
14532
14533 * linux-low.c (enum stopping_threads_kind): New.
14534 (stopping_threads): Change type to `enum stopping_threads_kind'.
14535 (handle_extended_wait): If stopping and suspending threads, leave
14536 the new_lwp suspended too.
14537 (linux_wait_for_event): Adjust.
14538 (stop_all_lwps): Set `stopping_threads' to
14539 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14540 whether we're suspending threads or just stopping them. Assert no
14541 recursion happens.
14542
14543 2012-04-29 Yao Qi <yao@codesourcery.com>
14544
14545 * server.h: Move some code to ...
14546 * gdbthread.h: ... here. New.
14547 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14548 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14549 (nto-low.o, win32-low.o): Likewise.
14550 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14551 * regcache.c, remote-utils.c, server.c: Likewise.
14552 * target.c, tracepoint.c, win32-low.c: Likewise.
14553
14554 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14555
14556 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14557 (PTRACE_ARG4_TYPE): Likewise.
14558 (PTRACE_XFER_TYPE): Likewise.
14559 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14560 ptrace to PTRACE_ARG3_TYPE.
14561 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14562 (PTRACE_ARG4_TYPE): Likewise.
14563 (PTRACE_XFER_TYPE): Likewise.
14564 (linux_detach_one_lwp): Cast fourth argument of
14565 ptrace to long then PTRACE_ARG4_TYPE.
14566 (regsets_fetch_inferior_registers): Cast third argument of
14567 ptrace to long then PTRACE_ARG3_TYPE.
14568 (regsets_store_inferior_registers): Likewise.
14569
14570 2012-04-20 Pedro Alves <palves@redhat.com>
14571
14572 * configure: Regenerate.
14573
14574 2012-04-19 Pedro Alves <palves@redhat.com>
14575
14576 * Makefile.in (GNULIB_BUILDDIR): New.
14577 (LIBGNU, INCGNU, GNULIB_H): Adjust.
14578 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14579 (all, install-only, uninstall, clean-info, all-lib, clean): No
14580 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14581 (maintainer-clean realclean distclean): Use subdir_do.
14582 (subdir_do): New.
14583 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
14584 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
14585 * acinclude.m4: Include acx_configure_dir.m4.
14586 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14587 calls. Call AC_PROG_RANLIB. Configure gnulib using
14588 ACX_CONFIGURE_DIR.
14589 (GNULIB): New.
14590 (GNULIB_STDINT_H): Adjust.
14591 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14592 * gdbreplay.c: Include build-gnulib/config.h.
14593 * server.h: Likewise.
14594 * aclocal.m4: Regenerate.
14595 * config.in: Regenerate.
14596 * configure: Regenerate.
14597
14598 2012-04-19 Pedro Alves <palves@redhat.com>
14599
14600 * Makefile.in (LIBGNU, INCGNU): Adjust.
14601 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14602 (all, install-only, uninstall, clean-info, all-lib, clean)
14603 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14604 * configure.ac: Adjust AC_OUTPUT output.
14605 * aclocal.m4: Regenerate.
14606 * configure: Regenerate.
14607
14608 2012-04-19 Pedro Alves <palves@redhat.com>
14609
14610 * Makefile.in (generated_files): New.
14611 (server_h): Remove the explicit dependency on config.h, and depend
14612 on $generated_files.
14613
14614 2012-04-19 Pedro Alves <palves@redhat.com>
14615
14616 * Makefile.in (INCGNU): Add -Ignulib.
14617
14618 2012-04-19 Pedro Alves <palves@redhat.com>
14619
14620 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14621 (INCGNU): ... this, and spell out -I here.
14622 (GNULIB_LIB): Rename to ...
14623 (LIBGNU): ... this.
14624 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14625
14626 2012-04-19 Pedro Alves <palves@redhat.com>
14627
14628 * config.in: Regenerate.
14629
14630 2012-04-19 Pedro Alves <palves@redhat.com>
14631
14632 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14633 * server.h (memmem): Remove declaration.
14634 * config.in: Regenerate.
14635 * configure: Regenerate.
14636
14637 2012-04-19 Yao Qi <yao@codesourcery.com>
14638
14639 * Makefile.in (SFILES): Add common/vec.c.
14640 (OBS): Add vec.o.
14641 (vec.o): New rule.
14642
14643 2012-04-19 Yao Qi <yao@codesourcery.com>
14644
14645 * remote-utils.c (prepare_resume_reply): Replace with macro
14646 target_core_of_thread.
14647 * server.c (handle_qxfer_threads_proper): Likewise.
14648 * target.h (traget_core_of_thread): New macro.
14649
14650 2012-04-18 Pedro Alves <palves@redhat.com>
14651
14652 * aclocal.m4: Regenerate.
14653 * configure: Regenerate.
14654
14655 2012-04-16 Yao Qi <yao@codesourcery.com>
14656
14657 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14658 duplicated on address.
14659
14660 2012-04-16 Yao Qi <yao@codesourcery.com>
14661
14662 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14663 (struct tracepoint_action_ops) <send>: New field.
14664 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14665 (agent_expr_send, x_tracepoint_action_send): New.
14666 (l_tracepoint_action_send): New.
14667 (cmd_qtdp): Download and install tracepoint
14668 according to `use_agent'.
14669 (run_inferior_command): Add one more parameter `len'.
14670 Update callers.
14671 (tracepoint_send_agent): New.
14672 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14673
14674 2012-04-16 Yao Qi <yao@codesourcery.com>
14675
14676 * tracepoint.c (download_tracepoints): Moved to ...
14677 (cmd_qtstart): ... here.
14678
14679 2012-04-14 Yao Qi <yao@codesourcery.com>
14680
14681 * tracepoint.c: Include inttypes.h.
14682 (struct collect_memory_action): Use sized types.
14683 (struct tracepoint): Likewise.
14684 (cmd_qtdp, stop_tracing): Update print specifiers.
14685 (cmd_qtp, response_tracepoint): Likewise.
14686 (collect_data_at_tracepoint): Likewise.
14687 (collect_data_at_step): Likewise.
14688
14689 2012-04-14 Yao Qi <yao@codesourcery.com>
14690
14691 Import gnulib module inttypes.
14692 * aclocal.m4, config.in, configure: Regenerated.
14693
14694 2012-04-14 Yao Qi <yao@codesourcery.com>
14695
14696 * Makefile.in (maintainer-clean, realclean, distclean): Remove
14697 Makefile and config.status at last.
14698
14699 2012-04-13 Yao Qi <yao@codesourcery.com>
14700
14701 * tracepoint.c: Include stdint.h unconditionally.
14702
14703 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14704
14705 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
14706 on BFD_HAVE_SYS_PROCFS_TYPE.
14707 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
14708 * configure: Regenerate.
14709 * config.in: Likewise.
14710
14711 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
14712
14713 * Makefile.in (clean): Also remove x32.c x32-linux.c
14714 x32-avx.c x32-avx-linux.c.
14715 (x32.o): New target.
14716 (x32.c): Likewise.
14717 (x32-linux.o): Likewise.
14718 (x32-linux.c): Likewise.
14719 (x32-avx.o): Likewise.
14720 (x32-avx.c): Likewise.
14721 (x32-avx-linux.o): Likewise.
14722 (x32-avx-linux.c): Likewise.
14723
14724 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
14725 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
14726 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
14727 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
14728 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
14729 i386/x32-avx-linux.xml.
14730
14731 * linux-x86-low.c (init_registers_x32_linux): New prototype.
14732 (init_registers_x32_avx_linux): Likwise.
14733 (x86_linux_update_xmltarget): Call init_registers_x32_linux
14734 or init_registers_x32_avx_linux if linux_is_elf64 is false.
14735
14736 2012-04-13 Pedro Alves <palves@redhat.com>
14737
14738 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
14739 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
14740 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
14741 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
14742 the sub-make.
14743
14744 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14745
14746 * linux-x86-low.c (compat_x32_clock_t): New.
14747 (compat_x32_siginfo_t): Likewise.
14748 (compat_x32_siginfo_from_siginfo): Likewise.
14749 (siginfo_from_compat_x32_siginfo): Likewise.
14750 (linux_is_elf64): Likewise.
14751 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
14752 and siginfo_from_compat_x32_siginfo for x32.
14753 (x86_arch_setup): Set linux_is_elf64.
14754
14755 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14756
14757 PR gdb/13969
14758 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
14759 e_machine field.
14760 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
14761 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
14762 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
14763 compatible with process.
14764
14765 2012-04-12 Yao Qi <yao@codesourcery.com>
14766
14767 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
14768 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
14769 (install-only, install-info, clean): Handle sub dir gnulib.
14770 (all-lib, am--refresh): New targets.
14771 (memmem.o): Remove target.
14772 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
14773 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
14774 (AC_REPLACE_FUNCS): Remove memmem.
14775 Invoke gl_INIT and AM_INIT_AUTOMAKE.
14776 (AC_OUTPUT): Generate Makefile in gnulib/.
14777 * aclocal.m4, config.in, configure: Regenerated.
14778
14779 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
14780
14781 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
14782
14783 2012-04-05 Pedro Alves <palves@redhat.com>
14784
14785 -Werror=strict-aliasing
14786
14787 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
14788 pointer.
14789
14790 2012-04-04 Pedro Alves <palves@redhat.com>
14791
14792 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14793 (sparc_store_gregset_from_stack, sparc_store_gregset)
14794 (sparc_breakpoint_at): Fix formatting.
14795
14796 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14797
14798 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
14799 are available.
14800 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
14801 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
14802 * config.in: Regenerate.
14803 * configure: Likewise.
14804
14805 2012-03-29 Pedro Alves <palves@redhat.com>
14806
14807 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
14808 Correct ptrace arguments.
14809
14810 2012-03-28 Pedro Alves <palves@redhat.com>
14811
14812 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
14813 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
14814 (IA64_FR1_REGNUM): New defines.
14815 (ia64_fetch_register): New.
14816 (the_low_target): Install it.
14817 * linux-low.h (struct linux_target_ops) <fetch_register>: New
14818 field.
14819 * linux-low.c (linux_fetch_registers): Try the
14820 the_low_target.fetch_register hook first.
14821
14822 * linux-arm-low.c (the_low_target): Adjust.
14823 * linux-bfin-low.c (the_low_target): Adjust.
14824 * linux-cris-low.c (the_low_target): Adjust.
14825 * linux-crisv32-low.c (the_low_target): Adjust.
14826 * linux-m32r-low.c (the_low_target): Adjust.
14827 * linux-m68k-low.c (the_low_target): Adjust.
14828 * linux-mips-low.c (the_low_target): Adjust.
14829 * linux-ppc-low.c (the_low_target): Adjust.
14830 * linux-s390-low.c (the_low_target): Adjust.
14831 * linux-sh-low.c (the_low_target): Adjust.
14832 * linux-sparc-low.c (the_low_target): Adjust.
14833 * linux-tic6x-low.c (the_low_target): Adjust.
14834 * linux-x86-low.c (the_low_target): Adjust.
14835 * linux-xtensa-low.c (the_low_target): Adjust.
14836
14837 2012-03-26 Pedro Alves <palves@redhat.com>
14838
14839 * server.c (handle_qxfer_libraries): Don't bail early if
14840 the_target->qxfer_libraries_svr4 is not NULL.
14841
14842 2012-03-26 Pedro Alves <palves@redhat.com>
14843
14844 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
14845
14846 2012-03-23 Pedro Alves <palves@redhat.com>
14847
14848 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
14849 "library-list-svr4" element's start tag when the the DSO list is
14850 empty.
14851
14852 2012-03-23 Pedro Alves <palves@redhat.com>
14853
14854 * linux-low.c (read_one_ptr): Read the inferior's pointer through
14855 a variable whose type size is the same as the inferior's pointer
14856 size.
14857
14858 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
14859
14860 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
14861 struct siginfo.
14862 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
14863 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
14864 * linux-low.h: Include <signal.h>.
14865 (struct siginfo): Remove forward declaration.
14866 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
14867 struct siginfo.
14868
14869 2012-03-21 Mike Frysinger <vapier@gentoo.org>
14870
14871 * .gitignore: Ignore more files.
14872
14873 2012-03-19 Pedro Alves <palves@redhat.com>
14874 Jan Kratochvil <jan.kratochvil@redhat.com>
14875
14876 * server.c (cont_thread, general_thread): Add describing comments.
14877 (start_inferior): Clear `cont_thread'.
14878 (handle_v_cont): Don't set `cont_thread' if resuming all threads
14879 of a process.
14880
14881 2012-03-15 Yao Qi <yao@codesourcery.com>
14882
14883 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
14884 handling to ...
14885 (cmd_qtdp): ... here.
14886
14887 2012-03-15 Yao Qi <yao@codesourcery.com>
14888
14889 * tracepoint.c (struct tracepoint_action_ops): New.
14890 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
14891 (m_tracepoint_action_download): New.
14892 (r_tracepoint_action_download): New.
14893 (x_tracepoint_action_download): New.
14894 (l_tracepoint_action_download): New.
14895 (add_tracepoint_action): Install `action->ops' according type.
14896 (download_tracepoint_1): Move code `download' function pointer
14897 of various tracepoint_action_ops.
14898
14899 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
14900
14901 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
14902 linux_ptrace_attach_warnings.
14903
14904 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
14905
14906 * Makefile.in (linux-ptrace.o): New.
14907 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
14908 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
14909 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
14910 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
14911 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
14912 of these targets.
14913 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
14914
14915 2012-03-08 Yao Qi <yao@codesourcery.com>
14916 Pedro Alves <palves@redhat.com>
14917
14918 Fix PR server/13392.
14919 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
14920 offset of JMP insn.
14921 * tracepoint.c (remove_tracepoint): New.
14922 (cmd_qtdp): Call remove_tracepoint when failed to install.
14923
14924 2012-03-07 Pedro Alves <palves@redhat.com>
14925
14926 * linux-low.c (get_detach_signal): New.
14927 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
14928 Pass on pending signals to PTRACE_DETACH. Check the result of the
14929 ptrace call.
14930 * server.c (program_signals, program_signals_p): New.
14931 (handle_general_set): Handle QProgramSignals.
14932 * server.h (program_signals, program_signals_p): Declare.
14933
14934 2012-03-05 Pedro Alves <palves@redhat.com>
14935 Jan Kratochvil <jan.kratochvil@redhat.com>
14936
14937 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
14938 New comment why.
14939
14940 2012-03-03 Yao Qi <yao@codesourcery.com>
14941
14942 * tracepoint.c (tracepoint_look_up_symbols): Update call to
14943 agent_look_up_symbols.
14944
14945 2012-03-03 Yao Qi <yao@codesourcery.com>
14946
14947 * Makefile.in (linux-low.o): Keep dependence on agent.h.
14948 (linux-x86-low.o): Likewise.
14949 * server.h: Remove in_process_agent_loaded.
14950 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
14951 common/agent.c.
14952 Update callers.
14953
14954 2012-03-03 Yao Qi <yao@codesourcery.com>
14955
14956 * tracepoint.c (gdb_agent_capability): New global.
14957 (in_process_agent_loaded_ust): Renamed to
14958 `in_process_agent_supports_ust'.
14959 Update callers.
14960 (in_process_agent_supports_ust): Call agent_capability_check.
14961 (clear_installed_tracepoints): Assert that agent supports
14962 agent.
14963
14964 2012-03-03 Yao Qi <yao@codesourcery.com>
14965
14966 * linux-low.c (linux_supports_agent): New.
14967 (linux_target_ops): Initialize field `supports_agent' with
14968 linux_supports_agent.
14969 * target.h (struct target_ops) <supports_agent>: New.
14970 (target_supports_agent): New macro.
14971 * server.c (handle_general_set): Handle packet 'QAgent'.
14972 (handle_query): Send `QAgent+'.
14973 * Makefile.in (server.o): Depends on agent.h.
14974
14975 2012-03-03 Yao Qi <yao@codesourcery.com>
14976
14977 * Makefile.in (OBS): Add agent.o.
14978 Add new rule for agent.o.
14979 Track dependence of tracepoint.c on agent.h.
14980 * tracepoint.c (run_inferior_command_1):
14981 (run_inferior_command): Call agent_run_command.
14982 (gdb_ust_connect_sync_socket): Deleted. Move it to
14983 common/agent.c.
14984 (resume_thread, stop_thread): Likewise.
14985 (gdb_ust_socket_init): Renamed to ...
14986 (gdb_agent_socket_init): ... New.
14987 (gdb_ust_thread): Renamed to ...
14988 (gdb_agent_helper_thread): ... New.
14989 (gdb_ust_init): Move some code to ...
14990 (gdb_agent_init): ... here. New.
14991 [HAVE_UST]: Call gdb_ust_init.
14992 (initialize_tracepoint_ftlib): Call gdb_agent_init.
14993 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
14994 * config.in, configure: Regenerated.
14995
14996 2012-03-02 Pedro Alves <palves@redhat.com>
14997
14998 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
14999 * linux-low.c (struct simple_pid_list): New.
15000 (stopped_pids): New a struct simple_pid_list pointer.
15001 (add_to_pid_list, pull_pid_from_list): New.
15002 (handle_extended_wait): Don't assume the first signal new children
15003 report is SIGSTOP. Adjust call to pull_pid_from_list.
15004 (linux_wait_for_lwp): Adjust.
15005
15006 2012-03-02 Yao Qi <yao@codesourcery.com>
15007
15008 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15009 debug log.
15010
15011 2012-03-02 Yao Qi <yao@codesourcery.com>
15012
15013 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15014 `stop_pc' and `tpoint'. Update caller.
15015
15016 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15017
15018 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15019 * linux-low.c (use_linux_regsets): New macro.
15020 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15021 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15022 (linux_register_in_regsets): New function.
15023 (usr_fetch_inferior_registers): Skip registers covered by
15024 regsets.
15025 (usr_store_inferior_registers): Likewise.
15026 (usr_fetch_inferior_registers): New macro.
15027 (usr_store_inferior_registers): Likewise.
15028 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15029 (linux_store_registers): Likewise.
15030 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15031 prototype.
15032 (init_registers_mips64_dsp_linux): Likewise.
15033 (init_registers_mips_linux): New macro.
15034 (init_registers_mips_dsp_linux): Likewise.
15035 (mips_dsp_num_regs): Likewise.
15036 (DSP_BASE, DSP_CONTROL): New fallback macros.
15037 (mips_base_regs): New macro.
15038 (mips_regmap): Use it. Fix the size.
15039 (mips_dsp_regmap): New variable.
15040 (mips_dsp_regset_bitmap): Likewise.
15041 (mips_arch_setup): New function.
15042 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15043 than mips_regmap.
15044 (mips_cannot_store_register): Likewise.
15045 (the_low_target): Update .arch_setup, .num_regs and .regmap
15046 initializers. Add .regset_bitmap initializer.
15047 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15048 initializer.
15049 * linux-bfin-low.c (the_low_target): Likewise.
15050 * linux-cris-low.c (the_low_target): Likewise.
15051 * linux-crisv32-low.c (the_low_target): Likewise.
15052 * linux-ia64-low.c (the_low_target): Likewise.
15053 * linux-m32r-low.c (the_low_target): Likewise.
15054 * linux-m68k-low.c (the_low_target): Likewise.
15055 * linux-ppc-low.c (the_low_target): Likewise.
15056 * linux-s390-low.c (the_low_target): Likewise.
15057 * linux-sh-low.c (the_low_target): Likewise.
15058 * linux-sparc-low.c (the_low_target): Likewise.
15059 * linux-tic6x-low.c (the_low_target): Likewise.
15060 * linux-x86-low.c (the_low_target): Likewise.
15061 * linux-xtensa-low.c (the_low_target): Likewise.
15062 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15063 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15064 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15065 srv_xmlfiles.
15066 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15067 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15068
15069 2012-02-29 Yao Qi <yao@codesourcery.com>
15070 Pedro Alves <palves@redhat.com>
15071
15072 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15073 `step_over_finished' is true.
15074
15075 2012-02-27 Pedro Alves <palves@redhat.com>
15076
15077 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15078 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15079
15080 2012-02-27 Pedro Alves <palves@redhat.com>
15081
15082 PR server/9684
15083 * linux-low.c (pid_is_stopped): New.
15084 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15085
15086 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15087
15088 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15089 of conditions.
15090
15091 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15092
15093 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15094
15095 2012-02-24 Luis Machado <lgustavo@codesourcery>
15096
15097 * server.c (handle_query): Advertise support for target-side
15098 breakpoint condition evaluation.
15099 (process_point_options): New function.
15100 (process_serial_event): When inserting a breakpoint, check for
15101 a target-side condition that should be evaluated.
15102
15103 * mem-break.c: Include regcache.h and ax.h.
15104 (point_cond_list_t): New data structure.
15105 (breakpoint) <cond_list>: New field.
15106 (find_gdb_breakpoint_at): Make non-static.
15107 (delete_gdb_breakpoint_at): Clear any target-side
15108 conditions.
15109 (clear_gdb_breakpoint_conditions): New function.
15110 (add_condition_to_breakpoint): Likewise.
15111 (add_breakpoint_condition): Likewise.
15112 (gdb_condition_true_at_breakpoint): Likewise.
15113 (gdb_breakpoint_here): Return result directly instead
15114 of going through a local variable.
15115
15116 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15117 (clear_gdb_breakpoint_conditions): Likewise.
15118 (add_breakpoint_condition): Likewise.
15119 (gdb_condition_true_at_breakpoint): Likewise.
15120
15121 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15122 (need_step_over_p): Take target-side breakpoint condition into
15123 consideration.
15124
15125 2012-02-24 Luis Machado <lgustavo@codesourcery>
15126
15127 * server.h: Include tracepoint.h.
15128 (agent_mem_read, agent_get_trace_state_variable_value,
15129 agent_set_trace_state_variable_value,
15130 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15131 get_set_tsv_func_addr): New prototypes.
15132
15133 * ax.h: New include file.
15134 * ax.c: New source file.
15135
15136 * tracepoint.c: Include ax.h.
15137 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15138 agent_expr, eval_result_type): Move to ax.h.
15139 (parse_agent_expr): Rename to ...
15140 (gdb_parse_agent_expr): ... this, make it non-static and move
15141 to ax.h.
15142 (unparse_agent_expr) Rename to ...
15143 (gdb_unparse_agent_expr): ... this, make it non-static and move
15144 to ax.h.
15145 (eval_agent_expr): Rename to ...
15146 (eval_tracepoint_agent_expr): ... this.
15147 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15148 forward declarations.
15149 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15150 (agent_get_trace_state_variable_value): New function.
15151 (agent_set_trace_state_variable_value): New function.
15152 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15153 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15154 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15155 (condition_true_at_tracepoint): Likewise.
15156 (parse_agent_expr): Rename to ...
15157 (gdb_parse_agent_expr): ... this and move to ax.c.
15158 (unparse_agent_expr): Rename to ...
15159 (gdb_unparse_agent_expr): ... this and move to ax.c.
15160 (gdb_agent_op_name): Move to ax.c.
15161 (eval_agent_expr): Rename to ...
15162 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15163 and move to ax.c.
15164 (eval_tracepoint_agent_expr): New function.
15165 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15166 non-static.
15167 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15168 ax.c.
15169 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15170 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15171 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15172 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15173 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15174 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15175 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15176 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15177 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15178 (compile_bytecodes): Remove forward declaration.
15179 (is_goto_target): Move to ax.c.
15180 (compile_bytecodes): Move to ax.c and call
15181 agent_get_trace_state_variable_value (...) and
15182 agent_set_trace_state_variable_value (...).
15183
15184 * Makefile.in: Update ax.c and IPA dependencies.
15185
15186 2012-02-24 Pedro Alves <palves@redhat.com>
15187
15188 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15189 (cmd_bigqtbuffer_circular): ... this. Only handle
15190 'QTBuffer:circular:'.
15191 (handle_tracepoint_general_set): Adjust.
15192
15193 2012-02-16 Yao Qi <yao@codesourcery.com>
15194
15195 * inferiors.c: Move code to ...
15196 * dll.c: .... here. New.
15197 * server.h: Declare clear_dlls.
15198 * Makefile.in (SFILES): Add dll.c.
15199 (OBS): Add dll.o
15200 (dll.o): New rule.
15201
15202 2012-02-11 Yao Qi <yao@codesourcery.com>
15203
15204 * server.c: (handle_monitor_command): Add a new parameter
15205 `own_buf'.
15206 (handle_query): Update caller.
15207
15208 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15209
15210 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15211 * configure, config.in: Regenerate.
15212 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15213 is not defined.
15214
15215 2012-02-02 Pedro Alves <palves@redhat.com>
15216
15217 Try SIGKILL first, then PTRACE_KILL.
15218 * linux-low.c (linux_kill_one_lwp): New.
15219 (linux_kill_one_lwp): Rename to ...
15220 (kill_one_lwp_callback): ... this. Use the new
15221 linux_kill_one_lwp.
15222
15223 2012-02-02 Pedro Alves <palves@redhat.com>
15224
15225 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15226 inferior.
15227
15228 2012-01-27 Pedro Alves <palves@redhat.com>
15229
15230 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15231 (elf_64_file_p): Make static.
15232 (linux_pid_exe_is_elf_64_file): New.
15233 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15234 Delete declarations.
15235 (linux_pid_exe_is_elf_64_file): Declare.
15236 * linux-x86-low.c (x86_arch_setup): Use
15237 linux_pid_exe_is_elf_64_file.
15238
15239 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15240
15241 * linux-low.c (linux_wait_for_event_1): Rename to ...
15242 (linux_wait_for_event): ... here and merge it with former
15243 linux_wait_for_event - new variable wait_ptid, use it.
15244 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15245
15246 2012-01-23 Pedro Alves <palves@redhat.com>
15247
15248 * server.c (main): Avoid yet another case of infinite loop while
15249 detaching/killing after a longjmp.
15250
15251 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15252
15253 Code cleanup.
15254 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15255
15256 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15257
15258 * hostio.c (handle_readlink): New function.
15259 (handle_vFile): Call it to handle "vFile:readlink" packets.
15260
15261 2012-01-20 Pedro Alves <palves@redhat.com>
15262 Ulrich Weigand <ulrich.weigand@linaro.org>
15263
15264 * server.c (handle_v_requests): Only support vAttach and vRun to
15265 start multiple processes when in extended protocol mode.
15266
15267 2012-01-17 Pedro Alves <palves@redhat.com>
15268
15269 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15270 memalign plus mprotect to allocate the scratch buffer.
15271
15272 2012-01-13 Pedro Alves <palves@redhat.com>
15273
15274 * server.c (attach_inferior): Clear `cont_thread'.
15275
15276 2012-01-13 Pedro Alves <palves@redhat.com>
15277
15278 * server.c (main): Avoid infinite loop while detaching/killing
15279 after a longjmp.
15280
15281 2012-01-09 Doug Evans <dje@google.com>
15282
15283 * server.c (start_inferior): Set last_ptid in --wrapper case.
15284
15285 2012-01-06 Yao Qi <yao@codesourcery.com>
15286
15287 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15288 defined.
15289 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15290
15291 2012-01-04 Yao Qi <yao@codesourcery.com>
15292
15293 * tracepoint.c (cmd_qtdp): Print debug message
15294 for static tracepoint.
15295
15296 2012-01-04 Yao Qi <yao@codesourcery.com>
15297
15298 * tracepoint.c (trace_vdebug): Differentiate debug message
15299 between gdbserver and IPA.
15300
15301 2012-01-03 Yao Qi <yao@codesourcery.com>
15302
15303 * tracepoint.c (tracepoint_was_hit): Don't collect for
15304 static tracepoint.
15305
15306 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15307
15308 * terminal.h: Reformat copyright header.
15309
15310 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15311
15312 * server.c (gdbserver_version): Update copyright year.
15313 * gdbreplay.c (gdbreplay_version): Likewise.
15314
15315 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15316
15317 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15318
15319 Revert:
15320 2011-12-18 Hui Zhu <teawater@gmail.com>
15321 * linux-low.c (linux_create_inferior): Save return value to ret.
15322
15323 2011-12-18 Hui Zhu <teawater@gmail.com>
15324
15325 * linux-low.c (linux_create_inferior): Save return value to ret.
15326
15327 2011-12-16 Doug Evans <dje@google.com>
15328
15329 * linux-low.c (linux_create_inferior): If stdio connection,
15330 redirect stdin from /dev/null, stdout to stderr.
15331 * remote-utils.c (remote_is_stdio): New static global.
15332 (remote_connection_is_stdio): New function.
15333 (remote_prepare): Handle stdio connection.
15334 (remote_open): Ditto.
15335 (remote_close): Don't close stdin for stdio connections.
15336 (read_prim,write_prim): New functions. Replace all calls to
15337 read/write to these.
15338 * server.c (main): Watch for "-" argument. Move call to
15339 remote_prepare before start_inferior.
15340 * server.h (STDIO_CONNECTION_NAME): New macro.
15341 (remote_connection_is_stdio): Declare.
15342
15343 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15344 in debugging output.
15345
15346 2011-12-15 Yao Qi <yao@codesourcery.com>
15347
15348 * tracepoint.c: Include sys/syscall.h.
15349 (gdb_ust_thread): Remove preprocessor conditional.
15350
15351 2011-12-14 Pedro Alves <pedro@codesourcery.com>
15352
15353 * linux-low.c (linux_detach_one_lwp): Call
15354 the_low_target.prepare_to_resume before detaching.
15355
15356 2011-12-14 Yao Qi <yao@codesourcery.com>
15357
15358 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15359 of write.
15360
15361 2011-12-14 Yao Qi <yao@codesourcery.com>
15362
15363 * i386-low.c (i386_low_stopped_data_address): Initialize local
15364 variable `control'.
15365
15366 2011-12-13 Pedro Alves <pedro@codesourcery.com>
15367
15368 PR remote/13492
15369
15370 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15371 DR_CONTROL unless necessary. Extend comments.
15372 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15373 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15374
15375 2011-12-13 Yao Qi <yao@codesourcery.com>
15376
15377 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15378 macros.
15379 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15380
15381 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15382
15383 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15384 Print new debug message for such case.
15385
15386 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15387
15388 Fix overlapping memcpy.
15389 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15390 the read_inferior_memory transfer.
15391 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15392 write_inferior_memory transfer.
15393 (set_fast_tracepoint_jump): New variable buf. Use it for the
15394 read_inferior_memory and write_inferior_memory transfers.
15395 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15396 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15397 Use it for the write_inferior_memory transfer.
15398 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15399 buffers.
15400
15401 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15402
15403 * linux-low.c (fetch_register, store_register): Make code
15404 consistent, fix formatting.
15405
15406 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15407
15408 * linux-low.c (usr_store_inferior_registers): Factor out code
15409 to handle individual registers into...
15410 (store_register): ... this new function.
15411
15412 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15413
15414 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15415 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15416 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15417 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15418 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15419 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15420 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15421 (srv_xmlfiles): Add new XML files.
15422
15423 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15424 and <sys/uio.h>.
15425 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15426 (init_registers_s390_linux32v1): Add prototype.
15427 (init_registers_s390_linux32v2): Likewise.
15428 (init_registers_s390_linux64v1): Likewise.
15429 (init_registers_s390_linux64v2): Likewise.
15430 (init_registers_s390x_linux64v1): Likewise.
15431 (init_registers_s390x_linux64v2): Likewise.
15432 (s390_num_regs): Increment to 52.
15433 (s390_regmap): Add orig_r2 register.
15434 (s390_num_regs_3264): Increment to 68.
15435 (s390_regmap_3264): Add orig_r2 register.
15436 (s390_collect_ptrace_register): Handle orig_r2 register.
15437 (s390_supply_ptrace_register): Likewise.
15438 (s390_fill_last_break): New function.
15439 (s390_store_last_break): Likewise.
15440 (s390_fill_system_call): New function.
15441 (s390_store_system_call): Likewise.
15442 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15443 register sets.
15444 (s390_check_regset): New function.
15445 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15446 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15447 Update target_regsets for available register sets.
15448
15449 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15450 Jan Kratochvil <jan.kratochvil@redhat.com>
15451
15452 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15453 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15454 New.
15455 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15456 * linux-low.h (struct process_info_private): New member r_debug.
15457 * server.c (handle_qxfer_libraries): Call
15458 the_target->qxfer_libraries_svr4.
15459 (handle_qxfer_libraries_svr4): New function.
15460 (qxfer_packets): New entry "libraries-svr4".
15461 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15462 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15463 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15464 PACKET_qXfer_libraries_svr4.
15465
15466 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15467
15468 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15469 PSW address/mask between 8-byte and 16-byte formats.
15470 (s390_supply_ptrace_register): Likewise.
15471 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15472 basic addressing mode bit.
15473
15474 2011-11-24 Stan Shebs <stan@codesourcery.com>
15475
15476 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15477
15478 2011-11-17 Stan Shebs <stan@codesourcery.com>
15479
15480 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15481 (tracing_start_time): New global.
15482 (tracing_stop_time): New global.
15483 (tracing_user_name): New global.
15484 (tracing_notes): New global.
15485 (tracing_stop_note): New global.
15486 (cmd_qtstart): Set traceframe_usage, start_time.
15487 (stop_tracing): Set stop_time.
15488 (cmd_qtstatus): Report additional status.
15489 (cmd_qtp): New function.
15490 (handle_tracepoint_query): Call it.
15491 (cmd_qtnotes): New function.
15492 (handle_tracepoint_general_set): Call it.
15493 (get_timestamp): Rename from tsv_get_timestamp.
15494
15495 2011-11-14 Stan Shebs <stan@codesourcery.com>
15496 Kwok Cheung Yeung <kcy@codesourcery.com>
15497
15498 * linux-x86-low.c (small_jump_insn): New.
15499 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15500 trampoline and error message, build a trampoline and issue a small
15501 jump instruction to it.
15502 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15503 trampoline and error message.
15504 (x86_get_min_fast_tracepoint_insn_len): New.
15505 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15506 * linux-low.h (struct linux_target_ops): Add arguments to
15507 install_fast_tracepoint_jump_pad operation, add new operation.
15508 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15509 arguments.
15510 (linux_get_min_fast_tracepoint_insn_len): New function.
15511 (linux_target_op): Add new operation.
15512 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15513 (gdb_trampoline_buffer_end): Ditto.
15514 (gdb_trampoline_buffer_error): Ditto.
15515 (struct ipa_sym_addresses): Add fields for new IPA variables.
15516 (symbol_list): Add entries for new IPA variables.
15517 (struct tracepoint): Add fields to hold the address range of the
15518 trampoline used by the tracepoint.
15519 (trampoline_buffer_head): New static variable.
15520 (trampoline_buffer_tail): Ditto.
15521 (claim_trampoline_space): New function.
15522 (have_fast_tracepoint_trampoline_buffer): New function.
15523 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15524 structure.
15525 (install_fast_tracepoint): Ditto, also add error buffer argument.
15526 (cmd_qtminftpilen): New function.
15527 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15528 (fast_tracepoint_from_trampoline_address): New function.
15529 (fast_tracepoint_collecting): Handle trampoline as part of jump
15530 pad space.
15531 (set_trampoline_buffer_space): New function.
15532 (initialize_tracepoint): Initialize new IPA variables.
15533 * target.h (struct target_ops): Add arguments to
15534 install_fast_tracepoint_jump_pad operation, add new
15535 get_min_fast_tracepoint_insn_len operation.
15536 (target_get_min_fast_tracepoint_insn_len): New.
15537 (install_fast_tracepoint_jump_pad): Add arguments.
15538 * server.h (IPA_BUFSIZ): Define.
15539 * linux-i386-ipa.c: Include extra header files.
15540 (initialize_fast_tracepoint_trampoline_buffer): New function.
15541 (initialize_low_tracepoint): Call it.
15542 * server.h (set_trampoline_buffer_space): Declare.
15543 (claim_trampoline_space): Ditto.
15544 (have_fast_tracepoint_trampoline_buffer): Ditto.
15545
15546 2011-11-14 Yao Qi <yao@codesourcery.com>
15547
15548 * server.c (handle_query): Handle InstallInTrace for qSupported.
15549 * tracepoint.c (add_tracepoint): Sort list.
15550 (install_tracepoint, download_tracepoint): New.
15551 (cmd_qtdp): Call them to install and download tracepoints.
15552 (sort_tracepoints): Removed.
15553 (cmd_qtstart): Update.
15554
15555 2011-11-14 Yao Qi <yao@codesourcery.com>
15556
15557 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15558 * mem-break.h: Declare.
15559 * tracepoint.c (cmd_qtstart): Move some code to ...
15560 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15561 New.
15562 (download_tracepoints): Move some code to ...
15563 (download_tracepoint_1): ... here. New.
15564
15565 2011-11-08 Yao Qi <yao@codesourcery.com>
15566
15567 * remote-utils.c (relocate_instruction): A comment fix.
15568
15569 2011-11-07 Joel Brobecker <brobecker@adacore.com>
15570
15571 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15572 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15573 dr_status_mirror and dr_control_mirror from debug_reg_state.
15574 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15575 (i386_initial_stuff): Remove use of deleted globals.
15576 (i386_get_thread_context, i386_set_thread_context,
15577 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15578 from debug_reg_state.
15579
15580 2011-11-05 Yao Qi <yao@codesourcery.com>
15581
15582 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15583 address as TPOINT's.
15584
15585 2011-11-02 Stan Shebs <stan@codesourcery.com>
15586
15587 * tracepoint.c (agent_mem_read_string): New function.
15588 (eval_agent_expr): Call it for tracenz.
15589 * server.c (handle_query): Report support for tracenz.
15590
15591 2011-11-02 Yao Qi <yao@codesourcery.com>
15592
15593 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15594
15595 2011-11-02 Yao Qi <yao@codesourcery.com>
15596
15597 * target.h: Fix a typo in comment.
15598
15599 2011-10-31 Pedro Alves <pedro@codesourcery.com>
15600
15601 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15602 clobber the breakpoints' shadows with fast tracepoint jumps.
15603 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15604 * target.c (write_inferior_memory): Also pass MYADDR down to
15605 check_mem_write.
15606
15607 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15608
15609 * configure.ac: Check support for personality routine.
15610 * configure: Regenerate.
15611 * config.in: Likewise.
15612 * linux-low.c: Include <sys/personality.h>.
15613 Define ADDR_NO_RANDOMIZE if necessary.
15614 (linux_create_inferior): Disable address space randomization when
15615 forking inferior, if requested.
15616 (linux_supports_disable_randomization): New function.
15617 (linux_target_ops): Install it.
15618 * server.h (disable_randomization): Declare.
15619 * server.c (disable_randomization): New global variable.
15620 (handle_general_set): Handle QDisableRandomization.
15621 (handle_query): Likewise for qSupported.
15622 (main): Support --disable-randomization and --no-disable-randomization
15623 command line arguments.
15624 * target.h (struct target_ops): Add supports_disable_randomization.
15625 (target_supports_disable_randomization): New macro.
15626
15627 2011-09-29 Mike Frysinger <vapier@gentoo.org>
15628
15629 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15630 ifdef check.
15631 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15632 [!PT_GETDSBT] (target_loadmap): New definition.
15633 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15634 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15635 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15636 and PT_GETDSBT to LINUX_LOADMAP.
15637 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15638 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15639
15640 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15641
15642 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15643 (arm_linux_hwbp_cap): New static variable.
15644 (arm_linux_get_hwbp_cap): Replace by ...
15645 (arm_linux_init_hwbp_cap): ... this new function.
15646 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15647 (arm_linux_get_hw_watchpoint_count): Likewise.
15648 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15649 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15650 (arm_prepare_to_resume): Use perror_with_name instead of error.
15651
15652 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15653
15654 * linux-arm-low.c: Include <signal.h>.
15655 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15656 (struct arm_linux_hwbp_cap): New data type.
15657 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15658 (struct arm_linux_hw_breakpoint): New data type.
15659 (MAX_BPTS, MAX_WPTS): Define.
15660 (struct arch_process_info, struct arch_lwp_info): New data types.
15661 (arm_linux_get_hwbp_cap): New function.
15662 (arm_linux_get_hw_breakpoint_count): Likewise.
15663 (arm_linux_get_hw_watchpoint_count): Likewise.
15664 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15665 (arm_hwbp_control_initialize): Likewise.
15666 (arm_hwbp_control_is_enabled): Likewise.
15667 (arm_hwbp_control_is_initialized): Likewise.
15668 (arm_hwbp_control_disable): Likewise.
15669 (arm_linux_hw_breakpoint_equal): Likewise.
15670 (arm_linux_hw_point_initialize): Likewise.
15671 (struct update_registers_data): New data structure.
15672 (update_registers_callback: New function.
15673 (arm_insert_point): Likewise.
15674 (arm_remove_point): Likewise.
15675 (arm_stopped_by_watchpoint): Likewise.
15676 (arm_stopped_data_address): Likewise.
15677 (arm_new_process): Likewise.
15678 (arm_new_thread): Likewise.
15679 (arm_prepare_to_resume): Likewise.
15680 (the_low_target): Register arm_insert_point, arm_remove_point,
15681 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15682 arm_new_thread, and arm_prepare_to_resume.
15683
15684 2011-09-15 Stan Shebs <stan@codesourcery.com>
15685
15686 * server.h (struct emit_ops): Add compare-goto fields.
15687 * tracepoint.c (gdb_agent_op_sizes): New table.
15688 (emit_eq_goto): New function.
15689 (emit_ne_goto): New function.
15690 (emit_lt_goto): New function.
15691 (emit_le_goto): New function.
15692 (emit_gt_goto): New function.
15693 (emit_ge_goto): New function.
15694 (is_goto_target): New function.
15695 (compile_bytecodes): Recognize special cases of compare-goto
15696 combinations and call specialized emitters for them.
15697 * linux-x86-low.c (amd64_emit_eq_goto): New function.
15698 (amd64_emit_ne_goto): New function.
15699 (amd64_emit_lt_goto): New function.
15700 (amd64_emit_le_goto): New function.
15701 (amd64_emit_gt_goto): New function.
15702 (amd64_emit_ge_goto): New function.
15703 (amd64_emit_ops): Add the new functions.
15704 (i386_emit_eq_goto): New function.
15705 (i386_emit_ne_goto): New function.
15706 (i386_emit_lt_goto): New function.
15707 (i386_emit_le_goto): New function.
15708 (i386_emit_gt_goto): New function.
15709 (i386_emit_ge_goto): New function.
15710 (i386_emit_ops): Add the new functions.
15711
15712 2011-09-08 Stan Shebs <stan@codesourcery.com>
15713
15714 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
15715 (i386_emit_epilogue): Restore %ebx.
15716
15717 2011-08-31 Jie Zhang <jzhang918@gmail.com>
15718
15719 * server.c (step_thread): Remove definition.
15720 (process_serial_event): Don't handle Hs.
15721 * server.h (step_thread): Remove declaration.
15722 * target.c (set_desired_inferior): Remove use of step_thread.
15723
15724 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
15725
15726 * linux-low.c: Include linux-procfs.h.
15727 (linux_attach_lwp_1): Update comments.
15728 (linux_attach): Scan for existing threads when attaching to a
15729 process that is the tgid.
15730 * Makefile.in: Update dependencies.
15731
15732 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
15733
15734 * configure.srv: Add linux-procfs.o dependencies.
15735
15736 2011-08-14 Yao Qi <yao@codesourcery.com>
15737
15738 * target.h (struct target_ops): Fix indent.
15739 * win32-low.c (win32_target_ops): Fix comment.
15740
15741 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
15742 Yao Qi <yao@codesourcery.com>
15743
15744 * Makefile.in (clean): Remove tic6x-*.c files.
15745 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
15746 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
15747 (tic6x-c64xp-linux.c): Likewise.
15748 * configure.srv: Add support for tic6x-*-uclinux.
15749 * linux-tic6x-low.c: New.
15750 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
15751
15752 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
15753 Yao Qi <yao@codesourcery.com>
15754
15755 * target.h (struct target_ops): Add read_loadmap.
15756 * linux-low.c (struct target_loadseg): New type.
15757 (struct target_loadmap): New type.
15758 (linux_read_loadmap): New function.
15759 (linux_target_ops): Add linux_read_loadmap.
15760 * server.c (handle_query): Support qXfer:fdpic:read packet.
15761 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
15762 to NULL.
15763
15764 2011-08-05 Eli Zaretskii <eliz@gnu.org>
15765
15766 * win32-low.c: Include <stdint.h>.
15767
15768 2011-07-22 Pedro Alves <pedro@codesourcery.com>
15769
15770 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
15771 to the inferior here.
15772 (i386_remove_aligned_watchpoint): Ditto.
15773 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
15774 fit part of the watchpoint in the debug registers.
15775 (i386_update_inferior_debug_regs): New.
15776 (i386_low_insert_watchpoint): Work on a local mirror of the debug
15777 registers, and only update the inferior on success.
15778 (i386_low_remove_watchpoint): Ditto.
15779
15780 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
15781
15782 * linux-low.c (compare_ints, unique, list_threads, show_process,
15783 linux_core_of_thread): Delete.
15784 (linux_target_ops): Change linux_core_of_thread to
15785 linux_common_core_of_thread.
15786 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
15787 * utils.c (malloc_failure): Change type of argument.
15788 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
15789 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
15790 common/linux-osdata.c, common/ptid.c and common/buffer.c.
15791 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
15792 (IPA_OBJS): Add common-utils-ipa.o.
15793 (ptid_h, linux_osdata_h): New macros.
15794 (server_h): Add common/common-utils.h, common/xml-utils.h,
15795 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
15796 common/ptid.h.
15797 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
15798 ptid.o, buffer.o): New rules.
15799 (linux-low.o): Add common/linux-osdata.h as a dependency.
15800 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
15801 * configure.ac: Add AC_HEADER_DIRENT check.
15802 * config.in: Regenerate.
15803 * configure: Regenerate.
15804 * remote-utils.c (xml_escape_text): Delete.
15805 (buffer_grow, buffer_free, buffer_init, buffer_finish,
15806 buffer_xml_printf): Move to common/buffer.c.
15807 * server.c (main): Remove call to initialize_inferiors.
15808 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
15809 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
15810 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
15811 internal_error, gdb_assert, gdb_assert_fail): Delete.
15812 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
15813 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
15814 common/buffer.h.
15815 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
15816 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
15817 initialize_inferiors): Delete.
15818
15819 2011-07-20 Pedro Alves <pedro@codesourcery.com>
15820
15821 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
15822 symbol error.
15823
15824 2011-05-31 Pedro Alves <pedro@codesourcery.com>
15825
15826 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
15827 assertion.
15828 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
15829
15830 2011-05-26 Yao Qi <yao@codesourcery.com>
15831
15832 * Makefile.in (thread-db.o): Track dependence to
15833 common/gdb_thread_db.h.
15834 * thread-db.c: include gdb_thread_db.h from right place.
15835
15836 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
15837
15838 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
15839 __FILE__ and __LINE__ to internal_error.
15840
15841 2011-05-13 Doug Evans <dje@google.com>
15842
15843 * thread-db.c (try_thread_db_load_from_sdir): New function.
15844 (try_thread_db_load_from_dir): New function.
15845 (thread_db_load_search): Handle $sdir, ignore $pdir.
15846 Remove trying of system directories if search of
15847 libthread-db-search-path fails, that is now done via $sdir.
15848
15849 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
15850
15851 * server.c (handle_query): Add EnableDisableTracepoints to the list
15852 of supported features.
15853 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
15854 tracepoints.
15855 (cmd_qtenable_disable): New.
15856 (cmd_qtstart): Install tracepoints even if disabled.
15857 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
15858 receiving a QTEnable or QTDisable packet.
15859 (gdb_collect): Skip data collection if fast tracepoint is disabled.
15860 (ust_marker_to_static_tracepoint): Do not ignore disabled static
15861 tracepoints.
15862 (gdb_probe): Skip data collection if static tracepoint is disabled.
15863
15864 2011-05-10 Doug Evans <dje@google.com>
15865
15866 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
15867
15868 2011-05-04 Doug Evans <dje@google.com>
15869
15870 * linux-low.c (linux_join): Skip process lookup.
15871 * spu-low.c (spu_join): Ditto.
15872 * server.c (join_inferiors_callback): Delete.
15873 (process_serial_event): For 'D' packet (detach) call join_inferior
15874 directly.
15875
15876 2011-05-04 Joseph Myers <joseph@codesourcery.com>
15877
15878 * README: Don't mention xscale*-*-linux*.
15879 * configure.srv (xscale*-*-linux*): Don't handle target.
15880
15881 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
15882
15883 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
15884 casting pointers.
15885 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
15886 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
15887 (i386_emit_void_call_2): Likewise.
15888
15889 2011-04-26 Yao Qi <yao@codesourcery.com>
15890
15891 * linux-low.c: Move common macros to linux-ptrace.h.
15892 Include linux-ptrace.h.
15893 * Makefile.in (linux_ptrace_h): New.
15894 (linux-low.o): Depends on linux-ptrace.h.
15895
15896 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
15897
15898 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
15899 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
15900 (remote_prepare): New function with most of the TCP code from ...
15901 (remote_open): ... here. Detect PORT here unconditionally. Move also
15902 setting transport_is_reliable.
15903 * server.c (run_once): New variable.
15904 (gdbserver_usage): Document it.
15905 (main): Set run_once for `--once'. Call remote_prepare. Exit after
15906 the first run if RUN_ONCE.
15907 * server.h (run_once, remote_prepare): New declarations.
15908
15909 2011-04-19 Tom Tromey <tromey@redhat.com>
15910
15911 * win32-low.c (handle_load_dll): Remove duplicate "the".
15912
15913 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
15914
15915 Remove support for old Cygwin 1.5 versions.
15916 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
15917 function to avoid warning.
15918 (win32_add_one_solib): Use cygwin_conv_path function to avoid
15919 warning.
15920
15921 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
15922
15923 * gdbserver/server.h (Macro _): Define it if not available.
15924
15925 2011-03-14 Michael Snyder <msnyder@vmware.com>
15926
15927 * hostio.c (handle_close): Remove unnecessary null test.
15928
15929 2011-03-10 Joel Brobecker <brobecker@adacore.com>
15930
15931 * Makefile.in (maintainer-clean realclean distclean): Remove
15932 "make ... subdir_do" command.
15933
15934 2011-03-10 Michael Snyder <msnyder@vmware.com>
15935
15936 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
15937
15938 * server.c (handle_v_run): Free alloced buffer on early return.
15939
15940 2011-03-09 Yao Qi <yao@codesourcery.com>
15941
15942 Revert:
15943 2011-03-04 Yao Qi <yao@codesourcery.com>
15944
15945 * Makefile.in: Remove GNU make feature --directory.
15946
15947 2011-03-05 Yao Qi <yao@codesourcery.com>
15948
15949 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
15950 (subdir_do): New make target. Copied from gdb/Makefile.
15951 (maintainer-clean, realclean, distclean, clean): Call corresponding
15952 make targets in common/Makefile.
15953
15954 2011-02-11 Yao Qi <yao@codesourcery.com>
15955
15956 * configure.ac: Call AC_PROG_RANLIB.
15957 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
15958 * configure: Regenerate.
15959
15960 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
15961
15962 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
15963
15964 2011-03-06 Yao Qi <yao@codesourcery.com>
15965
15966 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
15967
15968 2011-03-05 Yao Qi <yao@codesourcery.com>
15969
15970 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
15971 (subdir_do): New make target. Copied from gdb/Makefile.
15972 (maintainer-clean, realclean, distclean, clean): Call corresponding
15973 make targets in common/Makefile.
15974
15975 2011-03-04 Yao Qi <yao@codesourcery.com>
15976
15977 * Makefile.in: Remove GNU make feature --directory.
15978
15979 2011-03-04 Michael Snyder <msnyder@vmware.com>
15980
15981 * server.c (queue_stop_reply): Call xmalloc not malloc.
15982
15983 2011-03-02 Michael Snyder <msnyder@vmware.com>
15984
15985 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
15986
15987 2011-02-28 Michael Snyder <msnyder@vmware.com>
15988
15989 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
15990 (cmd_qtframe): Ditto.
15991 (cmd_qtbuffer): Ditto.
15992 (cmd_bigqtbuffer): Ditto.
15993
15994 * utils.c (decimal2str): Initialize 'width' to nine, then
15995 don't mess with it.
15996
15997 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15998
15999 * hostio.c (require_data): Free *data, not data.
16000
16001 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16002
16003 * hostio.c (require_data): Use free, not xfree.
16004
16005 2011-02-27 Michael Snyder <msnyder@vmware.com>
16006
16007 * server.c (handle_query): Discard unused value.
16008
16009 * hostio.c (require_data): Free malloc memory before returning
16010 error.
16011
16012 2011-02-26 Michael Snyder <msnyder@vmware.com>
16013
16014 * linux-low.c (list_threads): Call closedir for dirent.
16015
16016 2011-02-27 Michael Snyder <msnyder@vmware.com>
16017
16018 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16019 a case statement falls through.
16020
16021 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16022
16023 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16024 in comparison.
16025
16026 2011-02-26 Michael Snyder <msnyder@vmware.com>
16027
16028 * utils.c (decimal2str): Eliminate dead code and dead param.
16029 (pulongest): Drop dead param from call to decimal2str.
16030 (plongest): Ditto.
16031
16032 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16033
16034 Revert the following patch (not approved yet):
16035 2011-02-21 Hui Zhu <teawater@gmail.com>
16036 * tracepoint.c (tp_printf): New function.
16037 (eval_agent_expr): Handle gdb_agent_op_printf.
16038
16039 2011-02-21 Hui Zhu <teawater@gmail.com>
16040
16041 * tracepoint.c (tp_printf): New function.
16042 (eval_agent_expr): Handle gdb_agent_op_printf.
16043
16044 2011-02-18 Tom Tromey <tromey@redhat.com>
16045
16046 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16047 (tracepoint.o): Likewise.
16048 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16049 (gdb_agent_op_names): Likewise.
16050
16051 2011-02-18 Tom Tromey <tromey@redhat.com>
16052
16053 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16054 gdb_agent_op_rot>: New constants.
16055 (gdb_agent_op_names): Add pick and roll.
16056 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16057 cases.
16058
16059 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16060
16061 * aclocal.m4: Regenerated with aclocal-1.11.1.
16062
16063 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16064
16065 * server.c (handle_qxfer_traceframe_info): New.
16066 (qxfer_packets): Register "traceframe-info".
16067 (handle_query): Report support for qXfer:traceframe-info:read+.
16068 * tracepoint.c (match_blocktype): New.
16069 (traceframe_find_block_type): Rename to ...
16070 (traceframe_walk_blocks): ... this. Add callback filter argument,
16071 and use it.
16072 (traceframe_find_block_type): New, reimplemented on top of
16073 traceframe_walk_blocks.
16074 (build_traceframe_info_xml): New.
16075 (traceframe_read_info): New.
16076 * server.h (traceframe_read_info): Declare.
16077
16078 2011-02-11 Yao Qi <yao@codesourcery.com>
16079
16080 * configure.ac: Call AC_PROG_RANLIB.
16081 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16082 * configure: Regenerate.
16083
16084 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16085
16086 * server.c (gdb_read_memory): Change return semantics to allow
16087 partial transfers.
16088 (handle_search_memory_1): Adjust.
16089 (process_serial_event) <'m' packet>: Handle partial transfers.
16090 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16091
16092 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16093
16094 * regcache.c (init_register_cache): Initialize
16095 regcache->register_status.
16096 (free_register_cache): Release regcache->register_status.
16097 (regcache_cpy): Copy register_status.
16098 (registers_to_string): Print 'x's for unavailable registers.
16099 (supply_register): Mark the register's status valid or
16100 unavailable, depending on whether a buffer was passed in or not.
16101 (supply_register_zeroed): New.
16102 (supply_regblock): Mark the registers' status valid or
16103 unavailable, depending on whether a buffer was passed in or not.
16104 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16105 (struct regcache): New `register_status' field.
16106 (supply_register_zeroed): Declare.
16107 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16108 supply_register_zeroed, rather than passing a NULL buffer to
16109 supply_register.
16110 * tracepoint.c (fetch_traceframe_registers): Update comment.
16111
16112 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16113
16114 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16115 buffer explicit.
16116
16117 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16118
16119 * server.h (decode_xfer_write): Change prototype.
16120 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16121 and don't extract the annex here.
16122 * server.c (decode_xfer_read): Remove `annex' parameter,
16123 and don't extract the annex here.
16124 (decode_xfer): New.
16125 (struct qxfer): New.
16126 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16127 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16128 (handle_qxfer_statictrace): New functions, abstracted out from
16129 handle_query, and made to use the struct qxfer interface.
16130 (handle_threads_qxfer_proper): Rename to ...
16131 (handle_qxfer_threads_proper): ... this.
16132 (handle_threads_qxfer): Rename to ...
16133 (handle_qxfer_threads): ... this. Adjust.
16134 (qxfer_packets): New array.
16135 (handle_qxfer): New function.
16136 (handle_query): Use handle_qxfer.
16137
16138 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16139
16140 * gdbreplay.c: Shorten lines of >= 80 columns.
16141 * linux-low.c: Ditto.
16142 * linux-ppc-low.c: Ditto.
16143 * linux-s390-low.c: Ditto.
16144 * linux-sparc-low.c: Ditto.
16145 * linux-x86-low.c: Ditto.
16146 * linux-xtensa-low.c: Ditto.
16147 * mem-break.c: Ditto.
16148 * nto-low.c: Ditto.
16149 * regcache.h: Ditto.
16150 * remote-utils.c: Ditto.
16151 * server.c: Ditto.
16152 * server.h: Ditto.
16153 * thread-db.c: Ditto.
16154 * tracepoint.c: Ditto.
16155 * utils.c: Ditto.
16156 * win32-low.h: Ditto.
16157
16158 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16159
16160 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16161 update.
16162
16163 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16164
16165 * server.c (gdbserver_version): Update copyright year in version
16166 output.
16167 * gdbreplay.c (gdbreplay_version): Ditto.
16168
16169 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16170
16171 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16172 * linux-bfin-low.c: New file.
16173 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16174 PT_DATA_ADDR for BFIN targets.
16175 * Makefile.in (SFILES): Add linux-bfin-low.c.
16176 (clean): Remove reg-bfin.c.
16177 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16178 * README: Mention supported Blackfin targets.
16179
16180 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16181
16182 * .gitignore: New file.
16183
16184 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16185
16186 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16187
16188 2010-10-22 Jie Zhang <jie@codesourcery.com>
16189
16190 * Makefile.in: Add FLAGS_TO_PASS variable.
16191 (install): Remove dependency of install-only and recursively
16192 invoke make for install-only.
16193
16194 2010-10-04 Doug Evans <dje@google.com>
16195
16196 * Makefile.in (uninstall): Use $(DESTDIR).
16197
16198 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16199
16200 PR gdb/11842
16201
16202 * linux-x86-low.c (compat_siginfo_from_siginfo)
16203 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16204 si_code is < 0. Check for si_code == SI_TIMER before checking for
16205 si_code < 0.
16206
16207 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16208
16209 * lynx-i386-low.c: New file.
16210 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16211
16212 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16213
16214 * lynx-low.c (ptrace_request_to_str): Remove handling for
16215 request values that have been removed in LynxOS 5.x.
16216
16217 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16218
16219 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16220 <ptrace.h>
16221
16222 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16223
16224 * configure.ac: Add --enable-inprocess-agent option.
16225 * configure: Rebuilt.
16226
16227 2010-09-06 Yao Qi <yao@codesourcery.com>
16228
16229 * linux-low.c (linux_kill): Remove unused variable.
16230 (linux_stabilize_threads): Likewise.
16231 * server.c (start_inferior): Likewise.
16232 (queue_stop_reply_callback): Likewise.
16233 * tracepoint.c (do_action_at_tracepoint): Likewise.
16234
16235 2010-09-06 Yao Qi <yao@codesourcery.com>
16236
16237 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16238 on return.
16239
16240 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16241
16242 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16243
16244 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16245
16246 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16247 "$(IPA_DEPFILES)".
16248
16249 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16250
16251 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16252 gdbserver/lynx-ppc-low.c: New files.
16253 * Makefile.in (lynx_low_h): New variable.
16254 (lynx-low.o, lynx-ppc-low.o): New rules.
16255 * configure.ac: On LynxOS, link with -lnetinet.
16256 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16257 * configure: regenerate.
16258
16259 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16260
16261 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16262 * configure.ac: Add check for vasprintf and vsnprintf.
16263 * configure, config.in: Regenerate.
16264 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16265
16266 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16267
16268 * gdbreplay.c: Move include of alloca.h up, next to include of
16269 malloc.h.
16270 * server.h: Add include of malloc.h.
16271 * mem-break.c: Remove include of malloc.h.
16272 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16273
16274 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16275
16276 * Makefile.in (memmem.o): Build with -Wno-error.
16277
16278 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16279
16280 * utils.c (xsnprintf): Make non-static.
16281 * server.h: Add xsnprintf declaration.
16282 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16283 replace calls to snprintf by calls to xsnprintf throughout.
16284
16285 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16286
16287 * configure.ac: Add configure check for alloca.
16288 * configure, config.in: Regenerate.
16289 * server.h: Include alloca.h if it exists.
16290 * gdbreplay.c: Include alloca.h if it exists.
16291
16292 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16293
16294 * linux-low.c (__SIGRTMIN): Define if not already defined.
16295 (linux_create_inferior): Check for __ANDROID__ rather than
16296 __SIGRTMIN.
16297 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16298 are already deferred.
16299 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16300 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16301 stopped and already has a pending signal to report.
16302 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16303 a pending signal to report or is moving out of a jump pad.
16304 (linux_init_signals): Check for __ANDROID__ rather than
16305 __SIGRTMIN.
16306
16307 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16308
16309 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16310 debug_threads check. Avoid a linear search when not doing debug
16311 output.
16312
16313 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16314
16315 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16316 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16317 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16318 (process_event): Change local fd's type to gdb_fildes_t.
16319 (create_file_handler): Adjust prototype.
16320 (delete_file_handler): Adjust prototype.
16321 (handle_file_event): Adjust prototype. Use pfildes.
16322 (create_file_event): Adjsut prototype.
16323 * remote-utils.c (remote_desc, listen_desc): Change type to
16324 gdb_fildes_t.
16325 * server.h: New gdb_fildes_t typedef.
16326 [USE_WIN32API]: Include winsock2.h.
16327 (delete_file_handler, add_file_handler): Adjust prototypes.
16328 (pfildes): Declare.
16329 * utils.c (pfildes): New.
16330
16331 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16332
16333 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16334 * configure: Regenerate.
16335
16336 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16337
16338 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16339 (linux_done_accessing_memory): ... this.
16340 (linux_target_ops): Adjust.
16341 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16342 * nto-low.c (nto_target_ops): Adjust comment.
16343 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16344 * spu-low.c (spu_target_ops): Adjust comment.
16345 * target.h (target_ops): Rename unprepare_to_access_memory field
16346 to done_accessing_memory.
16347 (unprepare_to_access_memory): Rename to ...
16348 (done_accessing_memory): ... this.
16349
16350 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16351
16352 * linux-low.c (linux_prepare_to_access_memory): New.
16353 (linux_unprepare_to_access_memory): New.
16354 (linux_target_ops): Install them.
16355 * server.c (read_memory): Rename to ...
16356 (gdb_read_memory): ... this. Use
16357 prepare_to_access_memory/prepare_to_access_memory.
16358 (write_memory): Rename to ...
16359 (gdb_write_memory): ... this. Use
16360 prepare_to_access_memory/prepare_to_access_memory.
16361 (handle_search_memory_1): Adjust.
16362 (process_serial_event): Adjust.
16363 * target.h (struct target_ops): New fields
16364 prepare_to_access_memory and unprepare_to_access_memory.
16365 (prepare_to_access_memory, unprepare_to_access_memory): New.
16366 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16367 prepare_to_access_memory/prepare_to_access_memory.
16368 * nto-low.c (nto_target_ops): Adjust.
16369 * spu-low.c (spu_target_ops): Adjust.
16370 * win32-low.c (win32_target_ops): Adjust.
16371
16372 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16373
16374 * Makefile.in (WARN_CFLAGS): Get it from configure.
16375 (WERROR_CFLAGS): New.
16376 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16377 * configure.ac: Introduce --enable-werror, which adds -Werror to
16378 the compiler command line. Enabled by default. Disable with
16379 --disable-werror. Add -Wdeclaration-after-statement
16380 Wpointer-arith and -Wformat-nonliteral to warning flags.
16381 * configure: Regenerate.
16382
16383 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16384
16385 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16386
16387 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16388
16389 * gdbreplay.c (remote_error): New.
16390 (gdbchar): New.
16391 (expect): Use gdbchar. Check for error reading from GDB.
16392 Clarify sync error output.
16393 (play): Check for errors writing to GDB.
16394 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16395 * remote-utils.c (getpkt): Check for errors writing to the remote
16396 descriptor.
16397
16398 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16399
16400 * linux-low.c (linux_wait_1): Move non-debugging code out of
16401 `debug_threads' control.
16402
16403 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16404
16405 * linux-low.c (linux_wait_1): Don't set last_status here.
16406 * server.c (push_event, queue_stop_reply_callback): Assert we're
16407 not pushing a TARGET_WAITKIND_IGNORE event.
16408 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16409 (myresume, handle_target_event): Set the thread's last_resume_kind
16410 and last_status from the target returned status.
16411
16412 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16413
16414 PR threads/10729
16415
16416 * linux-x86-low.c (update_debug_registers_callback): New.
16417 (i386_dr_low_set_addr): Use it.
16418 (i386_dr_low_get_addr): New.
16419 (i386_dr_low_set_control): Use update_debug_registers_callback.
16420 (i386_dr_low_get_control): New.
16421 (i386_dr_low_get_status): Adjust.
16422 * linux-low.c (linux_stop_lwp): New.
16423 * linux-low.h (linux_stop_lwp): Declare.
16424
16425 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16426 argument instead of a i386_debug_reg_state.
16427 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16428 a i386_debug_reg_state.
16429 (i386_insert_aligned_watchpoint): Adjust.
16430 (i386_remove_aligned_watchpoint): Adjust.
16431 (i386_low_stopped_data_address): Read the debug registers from the
16432 inferior instead of from the mirrors.
16433 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16434 (i386_dr_low_get_addr): Declare.
16435 (i386_dr_low_get_control): Declare.
16436 (i386_dr_low_get_status): Change prototype.
16437
16438 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16439 (i386_dr_low_get_addr): New.
16440 (i386_dr_low_get_control): New.
16441 (i386_dr_low_get_status): Adjust prototype. Return
16442 dr_status_mirror.
16443 (i386_initial_stuff): Clear dr_status_mirror and
16444 dr_control_mirror.
16445 (i386_get_thread_context): Adjust.
16446 (i386_set_thread_context): Adjust.
16447 (i386_thread_added): Adjust.
16448
16449 2010-08-24 Pedro Alves <pedro@codesourcery.com>
16450
16451 * linux-low.h (linux_thread_area): Delete declaration.
16452
16453 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16454
16455 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16456 after its termination.
16457
16458 2010-08-09 Pedro Alves <pedro@codesourcery.com>
16459
16460 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16461 (gdb_wants_all_stopped): Delete.
16462 (linux_wait_1): Don't call them.
16463 * server.c (handle_v_cont): Tag all threads as want-stopped.
16464 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16465 stopped as "client-wants-stopped".
16466
16467 2010-07-31 Pedro Alves <pedro@codesourcery.com>
16468
16469 * Makefile.in (signals_h): New.
16470 (server_h): Depend on it.
16471 (server.o): Don't depend on $(signals_def).
16472 (signals.o): Depend on $(signals_def).
16473
16474 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16475
16476 * Makefile.in (signals_def): New.
16477 (server_h): Append include/gdb/signals.h and signals_def.
16478 (server.o): Append signals_def.
16479
16480 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16481
16482 * server.c (handle_target_event): Use target_signal_to_host for
16483 resume_info.sig initialization.
16484 * target.h (struct thread_resume) <sig>: New comment.
16485
16486 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16487
16488 * server.c (handle_query): strcpy() the returned string from paddress()
16489 instead of sprintf().
16490 * utils.c (paddress): Return phex_nz().
16491
16492 2010-07-07 Joel Brobecker <brobecker@adacore.com>
16493
16494 * server.c (handle_v_cont): Call mourn_inferior if process
16495 just exited.
16496 (myresume): Likewise.
16497
16498 2010-07-01 Pedro Alves <pedro@codesourcery.com>
16499
16500 Static tracepoints, and integration with UST.
16501
16502 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16503 * mem-break.c (uninsert_all_breakpoints)
16504 (reinsert_all_breakpoints): New.
16505 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16506 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16507 (gdb_agent_ust_loaded, helper_thread_id)
16508 (gdb_agent_helper_thread_id): New macros.
16509 (struct ipa_sym_addresses): Add addr_ust_loaded,
16510 addr_helper_thread_id, addr_cmd_buf.
16511 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16512 (in_process_agent_loaded_ust): New.
16513 (write_e_ust_not_loaded): New.
16514 (maybe_write_ipa_ust_not_loaded): New.
16515 (struct collect_static_trace_data_action): New.
16516 (enum tracepoint_type) <static_tracepoint>: New.
16517 (struct tracepoint) <handle>: Mention static tracepoints.
16518 (struct static_tracepoint_ctx): New.
16519 (CMD_BUF_SIZE): New.
16520 (add_tracepoint_action): Handle static tracepoint actions.
16521 (unprobe_marker_at): New.
16522 (clear_installed_tracepoints): Handle static tracepoints.
16523 (cmd_qtdp): Handle static tracepoints.
16524 (probe_marker_at): New.
16525 (cmd_qtstart): Handle static tracepoints.
16526 (response_tracepoint): Handle static tracepoints.
16527 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16528 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16529 (get_context_regcache): Handle static tracepoints.
16530 (do_action_at_tracepoint): Handle static tracepoint actions.
16531 (traceframe_find_block_type): Handle static trace data blocks.
16532 (traceframe_read_sdata): New.
16533 (download_tracepoints): Download static tracepoint actions.
16534 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16535 (GDB_PROBE_NAME): New.
16536 (ust_ops): New.
16537 (GET_UST_SYM): New.
16538 (USTF): New.
16539 (dlsym_ust): New.
16540 (ust_marker_to_static_tracepoint): New.
16541 (gdb_probe): New.
16542 (collect_ust_data_at_tracepoint): New.
16543 (gdb_ust_probe): New.
16544 (UNIX_PATH_MAX, SOCK_DIR): New.
16545 (gdb_ust_connect_sync_socket): New.
16546 (resume_thread, stop_thread): New.
16547 (run_inferior_command): New.
16548 (init_named_socket): New.
16549 (gdb_ust_socket_init): New.
16550 (cstr_to_hexstr): New.
16551 (next_st): New.
16552 (first_marker, next_marker): New.
16553 (response_ust_marker): New.
16554 (cmd_qtfstm, cmd_qtsstm): New.
16555 (unprobe_marker_at, probe_marker_at): New.
16556 (cmd_qtstmat, gdb_ust_thread): New.
16557 (gdb_ust_init): New.
16558 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16559 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16560 (ST_REGENTRY): New.
16561 (x86_64_st_collect_regmap): New.
16562 (X86_64_NUM_ST_COLLECT_GREGS): New.
16563 (AMD64_RIP_REGNUM): New.
16564 (supply_static_tracepoint_registers): New.
16565 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16566 (ST_REGENTRY): New.
16567 (i386_st_collect_regmap): New.
16568 (i386_NUM_ST_COLLECT_GREGS): New.
16569 (supply_static_tracepoint_registers): New.
16570 * server.c (handle_query): Handle qXfer:statictrace:read.
16571 <qSupported>: Report support for StaticTracepoints, and
16572 qXfer:statictrace:read features.
16573 * server.h (traceframe_read_sdata)
16574 (supply_static_tracepoint_registers): Declare.
16575 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16576 (unpack_varlen_hex): Include in IPA build.
16577 * Makefile.in (ustlibs, ustinc): New.
16578 (IPA_OBJS): Add remote-utils-ipa.o.
16579 ($(IPA_LIB)): Link -ldl and -lpthread.
16580 (UST_CFLAGS): New.
16581 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16582 * config.in, configure: Regenerate.
16583
16584 2010-06-20 Ian Lance Taylor <iant@google.com>
16585 Pedro Alves <pedro@codesourcery.com>
16586
16587 * linux-x86-low.c (always_true): Delete.
16588 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16589 trying to fool the compiler with always_true.
16590
16591 2010-06-20 Pedro Alves <pedro@codesourcery.com>
16592
16593 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16594 conditions in gdbserver.
16595
16596 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16597
16598 * spu-low.c (spu_read_memory): Wrap around local store limit.
16599 (spu_write_memory): Likewise.
16600
16601 2010-06-15 Pedro Alves <pedro@codesourcery.com>
16602
16603 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16604 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16605 LONGEST uses.
16606 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16607 uses.
16608 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16609 uses with LONGEST uses.
16610
16611 2010-06-14 Stan Shebs <stan@codesourcery.com>
16612 Pedro Alves <pedro@codesourcery.com>
16613
16614 Bytecode compiler.
16615
16616 * linux-x86-low.c: Include limits.h.
16617 (add_insns): New.
16618 (always_true): New.
16619 (EMIT_ASM): New.
16620 (EMIT_ASM32): New.
16621 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16622 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16623 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16624 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16625 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16626 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16627 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16628 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16629 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16630 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16631 (amd64_emit_void_call_2): New.
16632 (amd64_emit_ops): New.
16633 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16634 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16635 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16636 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16637 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16638 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16639 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16640 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16641 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16642 (i386_emit_stack_adjust, i386_emit_int_call_1)
16643 (i386_emit_void_call_2): New.
16644 (i386_emit_ops): New.
16645 (x86_emit_ops): New.
16646 (the_low_target): Install x86_emit_ops.
16647 * server.h (struct emit_ops): New.
16648 (get_raw_reg_func_addr): Declare.
16649 (current_insn_ptr, emit_error): Declare.
16650 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16651 (set_trace_state_variable_value): New defines.
16652 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16653 addr_get_trace_state_variable_value and
16654 addr_set_trace_state_variable_value.
16655 (symbol_list): New fields for get_raw_reg,
16656 get_trace_state_variable_value and set_trace_state_variable_value.
16657 (condfn): New typedef.
16658 (struct tracepoint): New field `compiled_cond'.
16659 (do_action_at_tracepoint): Clear compiled_cond.
16660 (get_trace_state_variable_value, set_trace_state_variable_value):
16661 Export in the IPA.
16662 (condition_true_at_tracepoint): If there's a compiled condition,
16663 run that.
16664 (current_insn_ptr, emit_error): New globals.
16665 (struct bytecode_address): New.
16666 (get_raw_reg_func_addr): New.
16667 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16668 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16669 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16670 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16671 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16672 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16673 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16674 (compile_tracepoint_condition, compile_bytecodes): New.
16675 * target.h (emit_ops): Forward declare.
16676 (struct target_ops): New field emit_ops.
16677 (target_emit_ops): New.
16678 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16679 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16680 * linux-low.c (linux_emit_ops): New.
16681 (linux_target_ops): Install it.
16682 * linux-low.h (struct linux_target_ops): New field emit_ops.
16683
16684 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16685
16686 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16687 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16688
16689 2010-06-01 Pedro Alves <pedro@codesourcery.com>
16690 Stan Shebs <stan@codesourcery.com>
16691
16692 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
16693 (all): Depend on $(extra_libraries).
16694 (install-only): Install the IPA.
16695 (IPA_OBJS, IPA_LIB): New.
16696 (clean): Remove the IPA lib.
16697 (IPAGENT_CFLAGS): New.
16698 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
16699 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
16700 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
16701 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
16702 * configure.ac: Check for atomic builtins support in the compiler.
16703 (IPA_DEPFILES, extra_libraries): Define.
16704 * configure.srv (ipa_obj): Add description.
16705 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
16706 (i[34567]86-*-linux*): Set ipa_obj.
16707 (x86_64-*-linux*): Set ipa_obj.
16708 * linux-low.c (stabilizing_threads): New.
16709 (supports_fast_tracepoints): New.
16710 (linux_detach): Stabilize threads before detaching.
16711 (handle_tracepoints): Handle internal tracing breakpoints. Assert
16712 the lwp is either not stabilizing, or is moving out of a jump pad.
16713 (linux_fast_tracepoint_collecting): New.
16714 (maybe_move_out_of_jump_pad): New.
16715 (enqueue_one_deferred_signal): New.
16716 (dequeue_one_deferred_signal): New.
16717 (linux_wait_for_event_1): If moving out of a jump pad, defer
16718 pending signals to later.
16719 (linux_stabilize_threads): New.
16720 (linux_wait_1): Check if threads need moving out of jump pads, and
16721 do it if so.
16722 (stuck_in_jump_pad_callback): New.
16723 (move_out_of_jump_pad_callback): New.
16724 (lwp_running): New.
16725 (linux_resume_one_lwp): Handle moving out of jump pads.
16726 (linux_set_resume_request): Dequeue deferred signals.
16727 (need_step_over_p): Also step over fast tracepoint jumps.
16728 (start_step_over): Also uninsert fast tracepoint jumps.
16729 (finish_step_over): Also reinsert fast tracepoint jumps.
16730 (linux_install_fast_tracepoint_jump): New.
16731 (linux_target_ops): Install linux_stabilize_threads and
16732 linux_install_fast_tracepoint_jump_pad.
16733 * linux-low.h (linux_target_ops) <get_thread_area,
16734 install_fast_tracepoint_jump_pad>: New fields.
16735 (struct lwp_info) <collecting_fast_tracepoint,
16736 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
16737 (linux_get_thread_area): Declare.
16738 * linux-x86-low.c (jump_insn): New.
16739 (x86_get_thread_area): New.
16740 (append_insns): New.
16741 (push_opcode): New.
16742 (amd64_install_fast_tracepoint_jump_pad): New.
16743 (i386_install_fast_tracepoint_jump_pad): New.
16744 (x86_install_fast_tracepoint_jump_pad): New.
16745 (the_low_target): Install x86_get_thread_area and
16746 x86_install_fast_tracepoint_jump_pad.
16747 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
16748 (struct fast_tracepoint_jump): New.
16749 (fast_tracepoint_jump_insn): New.
16750 (fast_tracepoint_jump_shadow): New.
16751 (find_fast_tracepoint_jump_at): New.
16752 (fast_tracepoint_jump_here): New.
16753 (delete_fast_tracepoint_jump): New.
16754 (set_fast_tracepoint_jump): New.
16755 (uninsert_fast_tracepoint_jumps_at): New.
16756 (reinsert_fast_tracepoint_jumps_at): New.
16757 (set_breakpoint_at): Use write_inferior_memory.
16758 (uninsert_raw_breakpoint): Use write_inferior_memory.
16759 (check_mem_read): Mask out fast tracepoint jumps.
16760 (check_mem_write): Mask out fast tracepoint jumps.
16761 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
16762 (set_fast_tracepoint_jump): Declare.
16763 (delete_fast_tracepoint_jump)
16764 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
16765 (reinsert_fast_tracepoint_jumps_at): Declare.
16766 * regcache.c: Don't compile many functions when building the
16767 in-process agent library.
16768 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
16769 the register buffer in the heap.
16770 (free_register_cache): If the register buffer isn't owned by the
16771 regcache, don't free it.
16772 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
16773 pre-existing register caches.
16774 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
16775 type.
16776 (convert_ascii_to_int): : Constify `from' parameter type.
16777 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
16778 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
16779 the needed buffer in-place.
16780 (relocate_instruction): New.
16781 * server.c (handle_query) <qSymbols>: If the target supports
16782 tracepoints, give it a chance of looking up symbols. Report
16783 support for fast tracepoints.
16784 (handle_status): Stabilize threads.
16785 (process_serial_event): Adjust.
16786 * server.h (struct fast_tracepoint_jump): Forward declare.
16787 (struct process_info) <fast_tracepoint_jumps>: New field.
16788 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
16789 (decode_X_packet, decode_M_packet): Adjust.
16790 (relocate_instruction): Declare.
16791 (in_process_agent_loaded): Declare.
16792 (tracepoint_look_up_symbols): Declare.
16793 (struct fast_tpoint_collect_status): Declare.
16794 (fast_tracepoint_collecting): Declare.
16795 (force_unlock_trace_buffer): Declare.
16796 (handle_tracepoint_bkpts): Declare.
16797 (initialize_low_tracepoint)
16798 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
16799 * target.h (struct target_ops) <stabilize_threads,
16800 install_fast_tracepoint_jump_pad>: New fields.
16801 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
16802 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
16803 [HAVE_STDINT_H]: Include stdint.h.
16804 (trace_debug_1): Rename to ...
16805 (trace_vdebug): ... this.
16806 (trace_debug): Rename to ...
16807 (trace_debug_1): ... this. Add `level' parameter.
16808 (trace_debug): New.
16809 (ATTR_USED, ATTR_NOINLINE): New.
16810 (IP_AGENT_EXPORT): New.
16811 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
16812 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
16813 (about_to_request_buffer_space, trace_buffer_is_full)
16814 (stopping_tracepoint, expr_eval_result, error_tracepoint)
16815 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
16816 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
16817 (traceframe_write_count, traceframes_created)
16818 (trace_state_variables)
16819 New renaming defines.
16820 (struct ipa_sym_addresses): New.
16821 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
16822 (symbol_list): New.
16823 (ipa_sym_addrs): New.
16824 (all_tracepoint_symbols_looked_up): New.
16825 (in_process_agent_loaded): New.
16826 (write_e_ipa_not_loaded): New.
16827 (maybe_write_ipa_not_loaded): New.
16828 (tracepoint_look_up_symbols): New.
16829 (debug_threads) [IN_PROCESS_AGENT]: New.
16830 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
16831 (UNKNOWN_SIDE_EFFECTS): New.
16832 (stop_tracing): New.
16833 (flush_trace_buffer): New.
16834 (stop_tracing_bkpt): New.
16835 (flush_trace_buffer_bkpt): New.
16836 (read_inferior_integer): New.
16837 (read_inferior_uinteger): New.
16838 (read_inferior_data_pointer): New.
16839 (write_inferior_data_pointer): New.
16840 (write_inferior_integer): New.
16841 (write_inferior_uinteger): New.
16842 (struct collect_static_trace_data_action): Delete.
16843 (enum tracepoint_type): New.
16844 (struct tracepoint) <type>: New field `type'.
16845 <actions_str, step_actions, step_actions_str>: Only include in
16846 GDBserver.
16847 <orig_size, obj_addr_on_target, adjusted_insn_addr>
16848 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
16849 (tracepoints): Use IP_AGENT_EXPORT.
16850 (last_tracepoint): Don't include in the IPA.
16851 (stopping_tracepoint): Use IP_AGENT_EXPORT.
16852 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
16853 (alloced_trace_state_variables): New.
16854 (trace_state_variables): Use IP_AGENT_EXPORT.
16855 (traceframe_t): Delete unused variable.
16856 (circular_trace_buffer): Don't include in the IPA.
16857 (trace_buffer_start): Delete.
16858 (struct trace_buffer_control): New.
16859 (trace_buffer_free): Delete.
16860 (struct ipa_trace_buffer_control): New.
16861 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
16862 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
16863 New.
16864 (trace_buffer_ctrl): New.
16865 (TRACE_BUFFER_CTRL_CURR): New.
16866 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
16867 Reimplement as macros.
16868 (trace_buffer_wrap): Delete.
16869 (traceframe_write_count, traceframe_read_count)
16870 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
16871 (struct tracepoint_hit_ctx) <type>: New field.
16872 (struct fast_tracepoint_ctx): New.
16873 (memory_barrier): New.
16874 (cmpxchg): New.
16875 (record_tracepoint_error): Update atomically in the IPA.
16876 (clear_inferior_trace_buffer): New.
16877 (about_to_request_buffer_space): New.
16878 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
16879 updating the same buffer.
16880 (add_tracepoint): Default the tracepoint's type to trap
16881 tracepoint, and orig_size to -1.
16882 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
16883 internal variables.
16884 (create_trace_state_variable): New parameter `gdb'. Handle it.
16885 (clear_installed_tracepoints): Clear fast tracepoint jumps.
16886 (cmd_qtdp): Handle fast tracepoints.
16887 (cmd_qtdv): Adjust.
16888 (max_jump_pad_size): New.
16889 (gdb_jump_pad_head): New.
16890 (get_jump_space_head): New.
16891 (claim_jump_space): New.
16892 (sort_tracepoints): New.
16893 (MAX_JUMP_SIZE): New.
16894 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
16895 IPA.
16896 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
16897 support. Upload fast traceframes, and delete internal IPA
16898 breakpoints.
16899 (stop_tracing_handler): New.
16900 (flush_trace_buffer_handler): New.
16901 (cmd_qtstop): Upload fast tracepoints.
16902 (response_tracepoint): Handle fast tracepoints.
16903 (tracepoint_finished_step): Upload fast traceframes. Set the
16904 tracepoint hit context's tracepoint type.
16905 (handle_tracepoint_bkpts): New.
16906 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
16907 type. Add comment about fast tracepoints.
16908 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
16909 non-existing action_str field.
16910 (get_context_regcache): Handle fast tracepoints.
16911 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
16912 to the regcache.
16913 (fast_tracepoint_from_jump_pad_address): New.
16914 (fast_tracepoint_from_ipa_tpoint_address): New.
16915 (collecting_t): New.
16916 (force_unlock_trace_buffer): New.
16917 (fast_tracepoint_collecting): New.
16918 (collecting): New.
16919 (gdb_collect): New.
16920 (write_inferior_data_ptr): New.
16921 (target_tp_heap): New.
16922 (target_malloc): New.
16923 (download_agent_expr): New.
16924 (UALIGN): New.
16925 (download_tracepoints): New.
16926 (download_trace_state_variables): New.
16927 (upload_fast_traceframes): New.
16928 (IPA_FIRST_TRACEFRAME): New.
16929 (IPA_NEXT_TRACEFRAME_1): New.
16930 (IPA_NEXT_TRACEFRAME): New.
16931 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
16932 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
16933 (gdb_jump_pad_buffer_end): New.
16934 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
16935 (initialize_tracepoint): Adjust.
16936 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
16937 buffer. Initialize the low module.
16938 * utils.c (PREFIX, TOOLNAME): New.
16939 (malloc_failure): Use PREFIX.
16940 (error): In the IPA, an error causes an exit.
16941 (fatal, warning): Use PREFIX.
16942 (internal_error): Use TOOLNAME.
16943 (NUMCELLS): Increase to 10.
16944 * configure, config.in: Regenerate.
16945
16946 2010-06-01 Pedro Alves <pedro@codesourcery.com>
16947
16948 * server.c (handle_query) <qSupported>: Do two passes over the
16949 qSupported string to avoid nesting strtok.
16950
16951 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16952
16953 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
16954 (CDEPS): New.
16955 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
16956 -Wl,--dynamic-list.
16957 * configure: Regenerate.
16958 * proc-service.list: New.
16959
16960 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16961
16962 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
16963 New comment.
16964
16965 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
16966
16967 * gdbreplay.c (remote_open): Check error return from socket() call by
16968 its equality to -1 not by it being negative.
16969 * remote-utils.c (remote_open): Likewise.
16970
16971 2010-05-23 Pedro Alves <pedro@codesourcery.com>
16972
16973 * config.h: Regenerate.
16974
16975 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
16976
16977 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
16978 doesn't provide PTRACE_GET_THREAD_AREA.
16979
16980 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
16981
16982 * linux-m68k-low.c: Include <asm/ptrace.h>
16983 (ps_get_thread_area): Implement.
16984
16985 2010-05-03 Doug Evans <dje@google.com>
16986
16987 * event-loop.c (struct callback_event): New struct.
16988 (callback_list): New global.
16989 (append_callback_event, delete_callback_event): New functions.
16990 (process_callback): New function.
16991 (start_event_loop): Call it.
16992 * remote-utils.c (NOT_SCHEDULED): Define.
16993 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
16994 moved out of readchar.
16995 (readchar): Rewrite. Call reschedule before returning.
16996 (reset_readchar): New function.
16997 (remote_close): Call it.
16998 (process_remaining, reschedule): New functions.
16999 * server.h (callback_handler_func): New typedef.
17000 (append_callback_event, delete_callback_event): Declare.
17001
17002 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17003
17004 * proc-service.c (ps_pglobal_lookup): Use
17005 thread_db_look_up_one_symbol.
17006 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17007 parameter. Use it instead of all_symbols_looked_up.
17008 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17009 field.
17010 (all_symbols_looked_up): Don't declare.
17011 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17012 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17013 field.
17014 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17015 Set all_symbols_looked_up here.
17016 (thread_db_look_up_one_symbol): New.
17017 (thread_db_get_tls_address): Adjust.
17018 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17019 thread_db object on the heap, and tentatively set it in the
17020 process structure.
17021 (thread_db_init): Don't set all_symbols_looked_up here.
17022 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17023
17024 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17025
17026 * linux-low.c (linux_kill, linux_detach): Adjust.
17027 (status_pending_p_callback): Remove redundant statement. Check
17028 for !TARGET_WAITIKIND_IGNORE, instead of
17029 TARGET_WAITKIND_STOPPED.
17030 (handle_tracepoints): Make sure LWP is locked. Adjust.
17031 (linux_wait_for_event_1): Adjust.
17032 (linux_cancel_breakpoints): New.
17033 (unsuspend_one_lwp): New.
17034 (unsuspend_all_lwps): New.
17035 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17036 (send_sigstop_callback): Change return type to int, add new
17037 `except' parameter and handle it.
17038 (suspend_and_send_sigstop_callback): New.
17039 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17040 pass them down. If SUSPEND, also increment the lwp's suspend
17041 count.
17042 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17043 (need_step_over_p): Don't consider suspended LWPs.
17044 (start_step_over): Adjust.
17045 (proceed_one_lwp): Change return type to int, add new `except'
17046 parameter and handle it.
17047 (unsuspend_and_proceed_one_lwp): New.
17048 (proceed_all_lwps): Use find_inferior instead of
17049 for_each_inferior.
17050 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17051 also decrement the suspend count of LWPs. Pass `except' down,
17052 instead of hacking its suspend count.
17053 (linux_pause_all): Add `freeze' parameter. Adjust.
17054 (linux_unpause_all): New.
17055 (linux_target_ops): Install linux_unpause_all.
17056 * server.c (handle_status): Adjust.
17057 * target.h (struct target_ops): New fields `unpause_all' and
17058 `cancel_breakpoints'. Add new parameter to `pause_all'.
17059 (pause_all): Add new `freeze' parameter.
17060 (unpause_all): New.
17061 (cancel_breakpoints): New.
17062 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17063 cancel breakpoints.
17064 (cmd_qtstart): Pause threads.
17065 (stop_tracing): Pause threads, and cancel breakpoints.
17066 * win32-low.c (win32_target_ops): Adjust.
17067
17068 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17069
17070 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17071 the inferior right away from here...
17072 (linux_wait_1): ... to here, and adjust to check the thread's
17073 last_resume_kind instead of the lwp's step or stop_expected flags.
17074
17075 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17076
17077 * README: Use consistent `GDB' and `GDBserver' spellings.
17078
17079 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17080
17081 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17082 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17083 (linux_detach_one_lwp): Assume the lwp is stopped.
17084 (any_thread_of): Delete.
17085 (linux_detach): Stop all lwps here. Don't blindly delete all
17086 breakpoints.
17087 (delete_lwp_callback): New.
17088 (linux_mourn): Delete all lwps of the process that is gone.
17089 (linux_wait_1): Don't delete the last lwp of the process here.
17090 * mem-break.h (mark_breakpoints_out): Declare.
17091 * mem-break.c (mark_breakpoints_out): New.
17092 (free_all_breakpoints): Use it.
17093 * server.c (handle_target_event): If the process is gone, mark
17094 breakpoints out.
17095 * thread-db.c (struct thread_db) <create_bp>: New field.
17096 (thread_db_enable_reporting): Fix prototype. Store a thread event
17097 breakpoint reference in the thread_db struct.
17098 (thread_db_load_search): Clear the thread_db object.
17099 (try_thread_db_load_1): Ditto.
17100 (switch_to_process): New.
17101 (disable_thread_event_reporting): Use it.
17102 (remove_thread_event_breakpoints): New.
17103 (thread_db_detach, thread_db_mourn): Use it.
17104
17105 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17106
17107 * linux-low.c (linux_enable_event_reporting): New.
17108 (linux_wait_for_event_1, handle_extended_wait): Use it.
17109
17110 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17111
17112 * linux-low.c (linux_kill_one_lwp, linux_kill)
17113 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17114 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17115 SIGSTOP even if the LWP is stopped.
17116 (send_sigstop_callback): New.
17117 (stop_all_lwps): Use send_sigstop_callback instead.
17118 (linux_resume_one_thread): Adjust.
17119 (proceed_one_lwp): Still proceed an LWP that the client has
17120 requested to stop, if we haven't reported it as stopped yet. Make
17121 sure that LWPs the client want stopped, have a pending SIGSTOP.
17122
17123 2010-04-26 Doug Evans <dje@google.com>
17124
17125 * server.c (handle_general_set): Make static.
17126
17127 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17128 Print received char after testing for error/eof instead of before.
17129 (input_interrupt): Tweak comment.
17130
17131 2010-04-23 Doug Evans <dje@google.com>
17132
17133 * server.c (start_inferior): Print inferior argv if --debug.
17134
17135 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17136
17137 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17138 * nto-x86-low.c: Include server.h
17139
17140 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17141
17142 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17143 be consistent with other sources of this directory.
17144 (init_registers_amd64): Correct name of source file of this function
17145 in the comment.
17146
17147 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17148
17149 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17150 64-bit executables.
17151
17152 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17153
17154 * win32-i386-low.c: Add 64-bit support.
17155 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17156 (init_registers_amd64): Declare.
17157 (mappings): Add 64-bit version of array.
17158 (init_windows_x86): New function.
17159 (the_low_target): Change init_arch field to init_windows_x86.
17160
17161 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17162
17163 * win32-low.c: Adapt to support also 64-bit architecture.
17164 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17165 (get_image_name): Use SIZE_T type for local variable `done'.
17166 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17167 (toolhelp_get_dll_name): Idem.
17168 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17169 Use uintptr_t typecast to avoid warning.
17170 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17171 (handle_exception): Use phex_nz to avoid warning.
17172 (win32_wait): Remove unused local variable `process'.
17173
17174 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17175
17176 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17177 `amd64-avx.o'.
17178
17179 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17180
17181 * configure.ac: Use `ws2_32' library for srv_mingw.
17182 * configure: Regenerate.
17183 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17184 * remote-utils.c: Likewise.
17185
17186 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17187
17188 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17189 if __x86_64__ is defined.
17190
17191 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17192
17193 * configure: Regenerate.
17194
17195 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17196
17197 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17198 * target.h (target_ops): New get_tib_address field.
17199 * win32-low.h (win32_thread_info): Add thread_local_base field.
17200 * win32-low.c (child_add_thread): Add tlb argument.
17201 Set thread_local_base field to TLB.
17202 (get_child_debug_event): Adapt to child_add_thread change.
17203 (win32_get_tib_address): New function.
17204 (win32_target_ops): Set get_tib_address field to
17205 win32_get_tib_address.
17206 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17207
17208 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17209
17210 * linux-low.c (linux_mourn): Also remove the process.
17211 * server.c (handle_target_event): Don't remove the process here.
17212 * nto-low.c (nto_mourn): New.
17213 (nto_target_ops): Install it.
17214 * spu-low.c (spu_mourn): New.
17215 (spu_target_ops): Install it.
17216 * win32-low.c (win32_mourn): New.
17217 (win32_target_ops): Install it.
17218
17219 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17220
17221 * server.h (buffer_xml_printf): Remove redundant `;'.
17222
17223 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17224
17225 * regcache.c (set_register_cache): Invalidate regcaches before
17226 changing the register cache layout.
17227 (regcache_invalidate_one): Allow a NULL regcache.
17228 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17229 regcaches before changing the register cache layout or the target
17230 regsets.
17231
17232 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17233
17234 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17235 variable warning on Linux/x86-64.
17236
17237 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17238
17239 GDBserver disconnected tracing support.
17240
17241 * linux-low.c (linux_remove_process): Delete.
17242 (add_lwp): Don't set last_resume_kind here.
17243 (linux_kill): Use `mourn'.
17244 (linux_detach): Use `thread_db_detach', and `mourn'.
17245 (linux_mourn): New.
17246 (linux_attach_lwp_1): Adjust comment.
17247 (linux_attach): last_resume_kind moved the thread_info; adjust.
17248 (status_pending_p_callback): Adjust.
17249 (linux_wait_for_event_1): Adjust.
17250 (count_events_callback, select_singlestep_lwp_callback)
17251 (select_event_lwp_callback, cancel_breakpoints_callback)
17252 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17253 (proceed_one_lwp): Adjust.
17254 (linux_async): Add debug output.
17255 (linux_thread_stopped): New.
17256 (linux_pause_all): New.
17257 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17258 linux_pause_all.
17259 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17260 (thread_db_free): Delete declaration.
17261 (thread_db_detach, thread_db_mourn): Declare.
17262 * thread-db.c (thread_db_init): Use thread_db_mourn.
17263 (thread_db_free): Delete, split in two.
17264 (disable_thread_event_reporting): New.
17265 (thread_db_detach): New.
17266 (thread_db_mourn): New.
17267
17268 * server.h (struct thread_info) <last_resume_kind>: New field.
17269 <attached>: Add comment.
17270 <gdb_detached>: New field.
17271 (handler_func): Change return type to int.
17272 (handle_serial_event, handle_target_event): Ditto.
17273 (gdb_connected): Declare.
17274 (tracing): Delete.
17275 (disconnected_tracing): Declare.
17276 (stop_tracing): Declare.
17277
17278 * server.c (handle_query) <qSupported>: Report support for
17279 disconnected tracing.
17280 (queue_stop_reply_callback): Account for running threads.
17281 (gdb_wants_thread_stopped): New.
17282 (gdb_wants_all_threads_stopped): New.
17283 (gdb_reattached_process): New.
17284 (handle_status): Clear the `gdb_detached' flag of all processes.
17285 In all-stop, stop all threads.
17286 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17287 (process_serial_event): If the remote connection breaks, or if an
17288 exit was forced with "monitor exit", force an event loop exit.
17289 Handle disconnected tracing on detach.
17290 (handle_serial_event): Adjust.
17291 (handle_target_event): If GDB isn't connected, forward events back
17292 to the inferior, unless the last process exited, in which case,
17293 exit gdbserver. Adjust interface.
17294
17295 * remote-utils.c (remote_open): Don't block in accept. Instead
17296 register an event loop source on the listen socket file
17297 descriptor. Refactor bits into ...
17298 (listen_desc): ... this new global.
17299 (gdb_connected): ... this new function.
17300 (enable_async_notification): ... this new function.
17301 (handle_accept_event): ... this new function.
17302 (remote_close): Clear remote_desc.
17303
17304 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17305
17306 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17307 New fields.
17308 (mourn_inferior): Define.
17309 (target_process_qsupported): Avoid the dangling else problem.
17310 (thread_stopped): Define.
17311 (pause_all): Define.
17312 (target_waitstatus_to_string): Declare.
17313 * target.c (target_waitstatus_to_string): New.
17314
17315 * tracepoint.c (tracing): Make extern.
17316 (disconnected_tracing): New.
17317 (stop_tracing): Make extern. Handle tracing stops due to GDB
17318 disconnecting.
17319 (cmd_qtdisconnected): New.
17320 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17321 (handle_tracepoint_general_set): Handle QTDisconnected.
17322
17323 * event-loop.c (event_handler_func): Change return type to int.
17324 (process_event): Bail out if the event handler wants the event
17325 loop to stop.
17326 (handle_file_event): Ditto.
17327 (start_event_loop): Bail out if the event handler wants the event
17328 loop to stop.
17329
17330 * nto-low.c (nto_target_ops): Adjust.
17331 * spu-low.c (spu_wait): Don't remove the process here.
17332 (spu_target_ops): Adjust.
17333 * win32-low.c (win32_wait): Don't remove the process here.
17334 (win32_target_ops): Adjust.
17335
17336 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17337
17338 * regcache.c (realloc_register_cache): Invalidate inferior's
17339 regcache before recreating it.
17340
17341 2010-04-09 Pedro Alves <pedro@codesourcery.com>
17342
17343 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17344
17345 2010-04-09 Stan Shebs <stan@codesourcery.com>
17346 Pedro Alves <pedro@codesourcery.com>
17347
17348 * server.h (LONGEST): New.
17349 (struct thread_info) <while_stepping>: New field.
17350 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17351 Declare.
17352 (initialize_tracepoint, handle_tracepoint_general_set)
17353 (handle_tracepoint_query, tracepoint_finished_step)
17354 (tracepoint_was_hit, release_while_stepping_state_list):
17355 (current_traceframe): Declare.
17356 * server.c (handle_general_set): Handle tracepoint packets.
17357 (read_memory): New.
17358 (write_memory): New.
17359 (handle_search_memory_1): Use read_memory.
17360 (handle_query): Report support for conditional tracepoints, trace
17361 state variables, and tracepoint sources. Handle tracepoint
17362 queries.
17363 (main): Initialize the tracepoints module.
17364 (process_serial_event): Handle traceframe reads/writes.
17365
17366 * linux-low.c (handle_tracepoints): New.
17367 (linux_wait_1): Call it.
17368 (linux_resume_one_lwp): Handle while-stepping.
17369 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17370 (linux_target_ops): Install them.
17371 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17372 New field.
17373 * linux-x86-low.c (x86_supports_tracepoints): New.
17374 (the_low_target). Install it.
17375
17376 * mem-break.h (delete_breakpoint): Declare.
17377 * mem-break.c (delete_breakpoint): Make external.
17378
17379 * target.h (struct target_ops): Add `supports_tracepoints',
17380 `read_pc', and `write_pc' fields.
17381 (target_supports_tracepoints): Define.
17382 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17383 (phex_nz): New.
17384
17385 * regcache.h (struct regcache) <registers_owned>: New field.
17386 (init_register_cache, regcache_cpy): Declare.
17387 (regcache_read_pc, regcache_write_pc): Declare.
17388 (register_cache_size): Declare.
17389 (supply_regblock): Declare.
17390 * regcache.c (init_register_cache): New.
17391 (new_register_cache): Use it.
17392 (regcache_cpy): New.
17393 (register_cache_size): New.
17394 (supply_regblock): New.
17395 (regcache_read_pc, regcache_write_pc): New.
17396
17397 * tracepoint.c: New.
17398
17399 * Makefile.in (OBS): Add tracepoint.o.
17400 (tracepoint.o): New rule.
17401
17402 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17403
17404 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17405 (i386-mmx.o): New.
17406 (i386-mmx.c): Likewise.
17407 (i386-mmx-linux.o): Likewise.
17408 (i386-mmx-linux.c): Likewise.
17409
17410 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17411 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17412 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17413 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17414
17415 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17416 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17417 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17418
17419 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17420
17421 * Makefile.in (clean): Updated.
17422 (i386-avx.o): New.
17423 (i386-avx.c): Likewise.
17424 (i386-avx-linux.o): Likewise.
17425 (i386-avx-linux.c): Likewise.
17426 (amd64-avx.o): Likewise.
17427 (amd64-avx.c): Likewise.
17428 (amd64-avx-linux.o): Likewise.
17429 (amd64-avx-linux.c): Likewise.
17430
17431 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17432 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17433 (srv_amd64_regobj): Add amd64-avx.o.
17434 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17435 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17436 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17437 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17438 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17439 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17440 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17441
17442 * i387-fp.c: Include "i386-xstate.h".
17443 (i387_xsave): New.
17444 (i387_cache_to_xsave): Likewise.
17445 (i387_xsave_to_cache): Likewise.
17446 (x86_xcr0): Likewise.
17447
17448 * i387-fp.h (i387_cache_to_xsave): Likewise.
17449 (i387_xsave_to_cache): Likewise.
17450 (x86_xcr0): Likewise.
17451
17452 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17453 * linux-crisv32-low.c (target_regsets): Likewise.
17454 * linux-m68k-low.c (target_regsets): Likewise.
17455 * linux-mips-low.c (target_regsets): Likewise.
17456 * linux-ppc-low.c (target_regsets): Likewise.
17457 * linux-s390-low.c (target_regsets): Likewise.
17458 * linux-sh-low.c (target_regsets): Likewise.
17459 * linux-sparc-low.c (target_regsets): Likewise.
17460 * linux-xtensa-low.c (target_regsets): Likewise.
17461
17462 * linux-low.c: Include <sys/uio.h>.
17463 (regsets_fetch_inferior_registers): Support nt_type.
17464 (regsets_store_inferior_registers): Likewise.
17465 (linux_process_qsupported): New.
17466 (linux_target_ops): Add linux_process_qsupported.
17467
17468 * linux-low.h (regset_info): Add nt_type.
17469 (linux_target_ops): Add process_qsupported.
17470
17471 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17472 and <sys/uio.h>.
17473 (init_registers_i386_avx_linux): New.
17474 (init_registers_amd64_avx_linux): Likewise.
17475 (xmltarget_i386_linux_no_xml): Likewise.
17476 (xmltarget_amd64_linux_no_xml): Likewise.
17477 (PTRACE_GETREGSET): Likewise.
17478 (PTRACE_SETREGSET): Likewise.
17479 (x86_fill_xstateregset): Likewise.
17480 (x86_store_xstateregset): Likewise.
17481 (use_xml): Likewise.
17482 (x86_linux_update_xmltarget): Likewise.
17483 (x86_linux_process_qsupported): Likewise.
17484 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17485 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17486 init_registers_i386_linux here. Call
17487 x86_linux_update_xmltarget.
17488 (the_low_target): Add x86_linux_process_qsupported.
17489
17490 * server.c (handle_query): Call target_process_qsupported.
17491
17492 * target.h (target_ops): Add process_qsupported.
17493 (target_process_qsupported): New.
17494
17495 2010-04-03 Pedro Alves <pedro@codesourcery.com>
17496
17497 * inferiors.c (add_thread): Set last_status kind to
17498 TARGET_WAITKIND_IGNORE.
17499 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17500 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17501 (linux_wait_1): Move `thread' local definition to block that uses
17502 it. Don't NULL initialize `event_child'.
17503 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17504 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17505 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17506
17507 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17508
17509 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17510 an extended waitstatus, or by a watchpoint.
17511 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17512 thread was stepping or has been stopped by a watchpoint.
17513
17514 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17515
17516 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17517 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17518 of another, then delete the previous, and validate all
17519 breakpoints.
17520 (validate_inserted_breakpoint): New.
17521 (delete_disabled_breakpoints): New.
17522 (validate_breakpoints): New.
17523 (check_mem_read): Validate breakpoints before trusting their
17524 shadow. Delete disabled breakpoints.
17525 (check_mem_write): Validate breakpoints before trusting they
17526 should be inserted. Delete disabled breakpoints.
17527 * mem-break.h (validate_breakpoints):
17528 * server.c (handle_query): Validate breakpoints when we see a
17529 qSymbol query.
17530
17531 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17532
17533 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17534 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17535 if we could tell there's a GDB breakpoint at stop_pc.
17536 (need_step_over_p): Don't do a step over if we find a GDB
17537 breakpoint at the resume PC.
17538
17539 * mem-break.c (struct raw_breakpoint): New.
17540 (enum bkpt_type): New type `gdb_breakpoint'.
17541 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17542 fields. New field `raw'.
17543 (find_raw_breakpoint_at): New.
17544 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17545 breakpoint instead.
17546 (set_breakpoint_at): Adjust.
17547 (delete_raw_breakpoint): New.
17548 (release_breakpoint): New.
17549 (delete_breakpoint): Rename to...
17550 (delete_breakpoint_1): ... this. Add proc parameter. Use
17551 release_breakpoint. Return ENOENT.
17552 (delete_breakpoint): Reimplement.
17553 (find_breakpoint_at): Delete.
17554 (find_gdb_breakpoint_at): New.
17555 (delete_breakpoint_at): Delete.
17556 (set_gdb_breakpoint_at): New.
17557 (delete_gdb_breakpoint_at): New.
17558 (gdb_breakpoint_here): New.
17559 (set_reinsert_breakpoint): Use release_breakpoint.
17560 (uninsert_breakpoint): Rename to ...
17561 (uninsert_raw_breakpoint): ... this.
17562 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17563 (reinsert_raw_breakpoint): Change parameter type to
17564 raw_breakpoint.
17565 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17566 instead.
17567 (check_breakpoints): Adjust. Use release_breakpoint.
17568 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17569 (breakpoint_inserted_here): Ditto.
17570 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17571 Don't trust the breakpoint's shadow if it is not inserted.
17572 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17573 (delete_all_breakpoints): Adjust.
17574 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17575 use delete_breakpoint_1.
17576
17577 * mem-break.h (breakpoints_supported): Delete declaration.
17578 (set_gdb_breakpoint_at): Declare.
17579 (gdb_breakpoint_here): Declare.
17580 (delete_breakpoint_at): Delete.
17581 (delete_gdb_breakpoint_at): Declare.
17582
17583 * server.h (struct raw_breakpoint): Forward declare.
17584 (struct process_info): New field `raw_breakpoints'.
17585
17586 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17587 breakpoints.
17588
17589 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17590
17591 * linux-low.c (status_pending_p_callback): Fix comment.
17592 (linux_wait_for_event_1): Move most of the internal breakpoint
17593 handling from here...
17594 (linux_wait_1): ... to here.
17595 (count_events_callback): New.
17596 (select_singlestep_lwp_callback): New.
17597 (select_event_lwp_callback): New.
17598 (cancel_breakpoints_callback): New.
17599 (select_event_lwp): New.
17600 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17601 priority to all LWPs that have had events that should be reported
17602 to the client. Cancel breakpoints when about to reporting the
17603 event to the client, not while stopping lwps. No longer cancel
17604 finished single-steps here.
17605 (cancel_finished_single_step): Delete.
17606 (cancel_finished_single_steps): Delete.
17607
17608 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17609
17610 * mem-break.c (enum bkpt_type): New.
17611 (struct breakpoint): New field `type'.
17612 (set_breakpoint_at): Change return type to struct breakpoint
17613 pointer. Set type to `other_breakpoint' by default.
17614 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17615 in the breakpoint list.
17616 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17617 (reinsert_breakpoint): Rename to ...
17618 (reinsert_raw_breakpoint): ... this.
17619 (reinsert_breakpoints_at): Adjust.
17620 * mem-break.h (struct breakpoint): Declare.
17621 (set_breakpoint_at): Change return type to struct breakpoint
17622 pointer.
17623
17624 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17625
17626 * server.c (handle_query): Assign, not compare.
17627
17628 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17629
17630 Teach linux gdbserver to step-over-breakpoints.
17631
17632 * linux-low.c (can_hardware_single_step): New.
17633 (supports_breakpoints): New.
17634 (handle_extended_wait): If stopping threads, read the stop pc of
17635 the new cloned LWP.
17636 (get_pc): New.
17637 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17638 low target doesn't support retrieving the PC.
17639 (add_lwp): Set last_resume_kind to resume_continue.
17640 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17641 (linux_attach): Don't clear stop_expected. Set the lwp's
17642 last_resume_kind to resume_stop.
17643 (linux_detach_one_lwp): Don't check for removed breakpoints.
17644 (check_removed_breakpoint): Delete.
17645 (status_pending_p): Rename to ...
17646 (status_pending_p_callback): ... this. Don't check for removed
17647 breakpoints. Don't consider threads that are stopped from GDB's
17648 perspective.
17649 (linux_wait_for_lwp): Always read the stop_pc here.
17650 (cancel_breakpoint): New.
17651 (step_over_bkpt): New global.
17652 (linux_wait_for_event_1): Implement stepping over breakpoints.
17653 (gdb_wants_lwp_stopped): New.
17654 (gdb_wants_all_stopped): New.
17655 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17656 single-step traps here. Store the thread's last reported target
17657 wait status.
17658 (send_sigstop): Don't clear stop_expected. Always set it,
17659 instead.
17660 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17661 (cancel_finished_single_step): New.
17662 (cancel_finished_single_steps): New.
17663 (wait_for_sigstop): Don't cancel finished single-step traps here.
17664 (linux_resume_one_lwp): Don't check for removed breakpoints.
17665 Don't set `step' on non-hardware step archs.
17666 (linux_set_resume_request): Ignore resume_stop requests if already
17667 stopping or stopped. Set the lwp's last_resume_kind.
17668 (resume_status_pending_p): Don't check for removed breakpoints.
17669 (need_step_over_p): New.
17670 (start_step_over): New.
17671 (finish_step_over): New.
17672 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17673 requests. Clear the thread's last reported target waitstatus.
17674 Don't use the `suspended' flag. Don't consider pending breakpoints.
17675 (linux_resume): Start a step-over if necessary.
17676 (proceed_one_lwp): New.
17677 (proceed_all_lwps): New.
17678 (unstop_all_lwps): New.
17679 * linux-low.h (struct lwp_info): Rewrite comment for the
17680 `suspended' flag. Add the `stop_pc' field. Delete the
17681 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17682 Add `'last_resume_kind' and `need_step_over' fields.
17683 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17684 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17685 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17686 (set_raw_breakpoint_at): New.
17687 (set_breakpoint_at): Rewrite to use it.
17688 (reinsert_breakpoint_handler): Delete.
17689 (set_reinsert_breakpoint): New.
17690 (reinsert_breakpoint_by_bp): Delete.
17691 (delete_reinsert_breakpoints): New.
17692 (uninsert_breakpoint): Rewrite.
17693 (uninsert_breakpoints_at): New.
17694 (reinsert_breakpoint): Rewrite.
17695 (reinsert_breakpoints_at): New.
17696 (check_breakpoints): Rewrite.
17697 (breakpoint_here): New.
17698 (breakpoint_inserted_here): New.
17699 (check_mem_read): Adjust.
17700 * mem-break.h (breakpoints_supported, breakpoint_here)
17701 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
17702 (reinsert_breakpoint_by_bp): Delete declaration.
17703 (delete_reinsert_breakpoints): Declare.
17704 (reinsert_breakpoint): Delete declaration.
17705 (reinsert_breakpoints_at): Declare.
17706 (uninsert_breakpoint): Delete declaration.
17707 (uninsert_breakpoints_at): Declare.
17708 (check_breakpoints): Adjust prototype.
17709 * server.h: Adjust include order.
17710 (struct thread_info): Declare here. Add a `last_status' field.
17711
17712 2010-03-23 Michael Snyder <msnyder@vmware.com>
17713
17714 * server.c (crc32): New function.
17715 (handle_query): Add handling for 'qCRC:' request.
17716
17717 2010-03-23 Pedro Alves <pedro@codesourcery.com>
17718
17719 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
17720 lwp had been stopped by a watchpoint.
17721
17722 2010-03-16 Pedro Alves <pedro@codesourcery.com>
17723
17724 * server.h (internal_error): Declare.
17725 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
17726 * utils.c (internal_error): New function.
17727
17728 2010-03-15 Andreas Schwab <schwab@redhat.com>
17729
17730 * configure.srv: Fix typo setting srv_regobj.
17731
17732 2010-03-15 Pedro Alves <pedro@codesourcery.com>
17733
17734 * linux-low.c (fetch_register): Avoid passing a non string literal
17735 format to `error'.
17736 (usr_store_inferior_registers): Ditto.
17737
17738 2010-03-14 Pedro Alves <pedro@codesourcery.com>
17739
17740 * linux-low.c (linux_write_memory): Bail out early if peeking
17741 memory failed.
17742
17743 2010-03-14 Pedro Alves <pedro@codesourcery.com>
17744
17745 * linux-low.h (struct lwp_info): New fields
17746 `stopped_by_watchpoint' and `stopped_data_address'.
17747 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
17748 here, and cache them in the lwp object.
17749 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
17750 directly.
17751 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
17752 field.
17753 (linux_stopped_by_watchpoint): Rewrite.
17754 (linux_stopped_data_address): Rewrite.
17755
17756 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
17757
17758 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
17759 switching the current inferior, not before.
17760
17761 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
17762
17763 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
17764 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
17765 i386-linux.c and amd64-linux.c.
17766 (reg-i386.o): Removed.
17767 (reg-i386.c): Likewise.
17768 (reg-i386-linux.o): Likewise.
17769 (reg-i386-linux.c): Likewise.
17770 (reg-x86-64.o): Likewise.
17771 (reg-x86-64.c): Likewise.
17772 (reg-x86-64-linux.o): Likewise.
17773 (reg-x86-64-linux.c): Likewise.
17774 (i386.o): New.
17775 (i386.c): Likewise.
17776 (i386-linux.o): Likewise.
17777 (i386-linux.c): Likewise.
17778 (amd64.o): Likewise.
17779 (amd64.c): Likewise.
17780 (amd64-linux.o): Likewise.
17781 (amd64-linux.c): Likewise.
17782
17783 * configure.srv (srv_i386_regobj): New.
17784 (srv_i386_linux_regobj): Likewise.
17785 (srv_amd64_regobj): Likewise.
17786 (srv_amd64_linux_regobj): Likewise.
17787 (srv_i386_32bit_xmlfiles): Likewise.
17788 (srv_i386_64bit_xmlfiles): Likewise.
17789 (srv_i386_xmlfiles): Likewise.
17790 (srv_amd64_xmlfiles): Likewise.
17791 (srv_i386_linux_xmlfiles): Likewise.
17792 (srv_amd64_linux_xmlfiles): Likewise.
17793 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
17794 srv_xmlfiles to $srv_i386_xmlfiles.
17795 (i[34567]86-*-mingw32ce*): Likewise.
17796 (i[34567]86-*-mingw*): Likewise.
17797 (i[34567]86-*-nto*): Likewise.
17798 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
17799 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
17800 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
17801 (x86_64-*-linux*): Likewise.
17802
17803 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
17804 (init_registers_amd64_linux): New.
17805 (x86_arch_setup): Replace init_registers_x86_64_linux with
17806 init_registers_amd64_linux.
17807
17808 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
17809
17810 * configure.ac: Check for libdl. If it is not available link against
17811 static libthread_db.
17812 * configure: Regenerate.
17813
17814 2010-02-22 Pedro Alves <pedro@codesourcery.com>
17815
17816 PR9605
17817
17818 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
17819 handing a read watchpoint.
17820 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
17821
17822 2010-02-12 Doug Evans <dje@google.com>
17823
17824 * linux-low.c (linux_supports_tracefork_flag): Document.
17825 (linux_look_up_symbols): Add comment.
17826
17827 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
17828
17829 * regcache.c (supply_register): Clear regcache if buf is NULL.
17830
17831 2010-02-02 Nicolas Roche <roche@sourceware.org>
17832 Joel Brobecker <brobecker@adacore.com>
17833
17834 * inferiors.c (find_inferior): Add function documentation.
17835 (unloaded_dll): Handle the case where the unloaded dll has not
17836 been previously registered in the dll list.
17837
17838 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
17839
17840 * linux-arm-low.c (thumb_breakpoint_len): Delete.
17841 (thumb2_breakpoint): New.
17842 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
17843
17844 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17845
17846 * linux-low.c (get_stop_pc): Check for SIGTRAP.
17847 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
17848 breakpoints.
17849
17850 2010-01-21 Pedro Alves <pedro@codesourcery.com>
17851
17852 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
17853
17854 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
17855
17856 * linux-s390-low.c (s390_collect_ptrace_register)
17857 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
17858
17859 2010-01-21 Doug Evans <dje@google.com>
17860
17861 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
17862 (PTRACE_ARG4_TYPE): New macro.
17863 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
17864 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
17865 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
17866 (usr_store_inferior_registers): Ditto.
17867 (linux_read_memory, linux_write_memory): Ditto.
17868 (linux_test_for_tracefork): Ditto.
17869
17870 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
17871 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
17872
17873 2010-01-21 Pedro Alves <pedro@codesourcery.com>
17874
17875 * proc-service.c (ps_lgetregs): Don't refetch registers from the
17876 target.
17877
17878 2010-01-21 Pedro Alves <pedro@codesourcery.com>
17879
17880 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
17881 prototype to take a regcache. Adjust.
17882
17883 2010-01-20 Pedro Alves <pedro@codesourcery.com>
17884
17885 * regcache.h (struct thread_info): Forward declare.
17886 (struct regcache): New.
17887 (new_register_cache): Adjust prototype.
17888 (get_thread_regcache): Declare.
17889 (free_register_cache): Adjust prototype.
17890 (registers_to_string, registers_from_string): Ditto.
17891 (supply_register, supply_register_by_name, collect_register)
17892 (collect_register_as_string, collect_register_by_name): Ditto.
17893 * regcache.c (struct inferior_regcache_data): Delete.
17894 (get_regcache): Rename to ...
17895 (get_thread_regcache): ... this. Adjust. Switch inferior before
17896 fetching registers.
17897 (regcache_invalidate_one): Adjust.
17898 (regcache_invalidate): Fix prototype.
17899 (new_register_cache): Return the new register cache.
17900 (free_register_cache): Change prototype.
17901 (realloc_register_cache): Adjust.
17902 (registers_to_string): Change prototype to take a regcache. Adjust.
17903 (registers_from_string): Ditto.
17904 (register_data): Ditto.
17905 (supply_register): Ditto.
17906 (supply_register_by_name): Ditto.
17907 (collect_register): Ditto.
17908 (collect_register_as_string): Ditto.
17909 (collect_register_by_name): Ditto.
17910 * server.c (process_serial_event): Adjust.
17911 * linux-low.h (regset_fill_func, regset_store_func): Change
17912 prototype.
17913 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
17914 Change prototype.
17915 * linux-low.c (get_stop_pc): Adjust.
17916 (check_removed_breakpoint): Adjust.
17917 (linux_wait_for_event): Adjust.
17918 (linux_resume_one_lwp): Adjust.
17919 (fetch_register): Add regcache parameter. Adjust.
17920 (usr_store_inferior_registers): Ditto.
17921 (regsets_fetch_inferior_registers): Ditto.
17922 (regsets_store_inferior_registers): Ditto.
17923 (linux_fetch_registers, linux_store_registers): Ditto.
17924 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
17925 regcache. Adjust.
17926 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
17927 Ditto.
17928 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
17929 prototype to take a regcache.
17930 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
17931 * remote-utils.c (convert_ascii_to_int, outreg)
17932 (prepare_resume_reply): Change prototype to take a regcache.
17933 Adjust.
17934 * target.h (struct target_ops) <fetch_registers, store_registers>:
17935 Change prototype to take a regcache.
17936 (fetch_inferior_registers, store_inferior_registers): Change
17937 prototype to take a regcache. Adjust.
17938 * proc-service.c (ps_lgetregs): Adjust.
17939 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
17940 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
17941 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
17942 take a regcache. Adjust.
17943 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
17944 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
17945 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
17946 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
17947 * linux-cris-low.c (cris_get_pc, cris_set_pc)
17948 (cris_cannot_fetch_register):
17949 (cris_breakpoint_at): Change prototype to take a regcache.
17950 Adjust.
17951 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
17952 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
17953 to take a regcache. Adjust.
17954 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
17955 Adjust.
17956 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
17957 take a regcache. Adjust.
17958 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
17959 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
17960 (m68k_set_pc): Change prototype to take a regcache. Adjust.
17961 * linux-mips-low.c (mips_get_pc):
17962 (mips_set_pc): Change prototype to take a regcache. Adjust.
17963 (mips_reinsert_addr): Adjust.
17964 (mips_collect_register): Change prototype to take a regcache.
17965 Adjust.
17966 (mips_supply_register):
17967 (mips_collect_register_32bit, mips_supply_register_32bit)
17968 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
17969 (mips_store_fpregset): Ditto.
17970 * linux-ppc-low.c (ppc_supply_ptrace_register)
17971 (ppc_supply_ptrace_register): Ditto.
17972 (parse_spufs_run): Adjust.
17973 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
17974 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
17975 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
17976 take a regcache. Adjust.
17977 * linux-s390-low.c (s390_collect_ptrace_register)
17978 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
17979 (s390_set_pc): Change prototype to take a regcache. Adjust.
17980 (s390_arch_setup): Adjust.
17981 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
17982 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
17983 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
17984 (sparc_fill_gregset, sparc_store_gregset_from_stack)
17985 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
17986 regcache. Adjust.
17987 (sparc_breakpoint_at): Adjust.
17988 * linux-xtensa-low.c (xtensa_fill_gregset):
17989 (xtensa_store_gregset):
17990 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
17991 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
17992 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
17993 prototype to take a regcache. Adjust.
17994 * win32-arm-low.c (arm_fetch_inferior_register)
17995 (arm_store_inferior_register): Change prototype to take a
17996 regcache. Adjust.
17997 * win32-i386-low.c (i386_fetch_inferior_register)
17998 (i386_store_inferior_register): Change prototype to take a
17999 regcache. Adjust.
18000 * win32-low.c (child_fetch_inferior_registers)
18001 (child_store_inferior_registers): Change prototype to take a
18002 regcache. Adjust.
18003 (win32_wait): Adjust.
18004 (win32_fetch_inferior_registers): Change prototype to take a
18005 regcache. Adjust.
18006 (win32_store_inferior_registers): Adjust.
18007 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18008 store_inferior_register>: Change prototype to take a regcache.
18009
18010 2010-01-20 Doug Evans <dje@google.com>
18011
18012 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18013 #ifdef.
18014 (linux_wait_for_event1, linux_init_signals): Ditto.
18015 (W_STOPCODE): Provide definition if missing.
18016
18017 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18018
18019 * linux-low.c (linux_core_of_thread): New.
18020 (compare_ints, show_process, list_threads): New.
18021 (linux_qxfer_osdata): Report threads and cores.
18022 (linux_target_op): Register linux_core_of_thread.
18023 * remote-utils.c (prepare_resume_reply): Report the core.
18024 (buffer_xml_printf): Support %d specifier.
18025 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18026 New.
18027 (handle_query): Handle qXfer:threads. Announce availability
18028 thereof.
18029 * target.h (struct target_ops): New field core_of_thread.
18030
18031 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18032
18033 * Makefile.in (clean): Remove new generated files.
18034 (reg-s390.o, reg-s390.c): Remove rules.
18035 (reg-s390x.o, reg-s390x.c): Likewise.
18036 (s390-linux32.o, s390-linux32.c): Add rules.
18037 (s390-linux64.o, s390-linux64.c): Likewise.
18038 (s390x-linux64.o, s390x-linux64.c): Likewise.
18039 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18040 * linux-s390-low.c: Include <elf.h>.
18041 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18042 (init_registers_s390): Remove prototype.
18043 (init_registers_s390x): Likewise.
18044 (init_registers_s390_linux32): Add prototype.
18045 (init_registers_s390_linux64): Likewise.
18046 (init_registers_s390x_linux64): Likewise.
18047 (s390_num_regs_3264): New define.
18048 (s390_regmap_3264): New global variable.
18049 (s390_cannot_fetch_register): Remove obsolete check.
18050 (s390_cannot_store_register): Likewise.
18051 (s390_collect_ptrace_register): Handle upper/lower register halves.
18052 (s390_supply_ptrace_register): Likewise.
18053 (s390_fill_gregset): Update to register number changes.
18054 (s390_get_hwcap): New routine.
18055 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18056 Install appropriate regmap and register set.
18057
18058 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18059
18060 * server.c (gdbserver_version): Update copyright year to 2010.
18061 * gdbreplay.c (gdbreplay_version): Likewise.
18062
18063 2009-12-28 Doug Evans <dje@google.com>
18064
18065 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18066 elf/external.h. Include <elf.h> instead but only if necessary.
18067
18068 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18069
18070 * linux-low.c (linux_remove_process): Remove `detaching'
18071 parameter. Don't release/detach from thread_db here.
18072 (linux_kill): Release/detach from thread_db here, ...
18073 (linux_detach): ... and here, before actually detaching.
18074 (linux_wait_1): ... and here, when a process exits.
18075 * thread-db.c (any_thread_of): New.
18076 (thread_db_free): Switch the current inferior to a thread of the
18077 passed in process.
18078
18079 2009-12-21 Doug Evans <dje@google.com>
18080
18081 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18082
18083 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18084 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18085 warning ifndef __NR_tkill. Move setting of errno there too.
18086 Delete unnecessary resetting of errno after syscall.
18087 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18088
18089 * configure.ac: Check for dladdr.
18090 * config.in: Regenerate.
18091 * configure: Regenerate.
18092 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18093 (try_thread_db_load): Update.
18094
18095 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18096
18097 2009-12-18 Doug Evans <dje@google.com>
18098
18099 * event-loop.c: Include unistd.h if it exists.
18100
18101 * linux-low.c (my_waitpid): Move definition away from being in
18102 between linux_tracefork_child/linux_test_for_tracefork.
18103
18104 * gdb_proc_service.h (psaddr_t): Fix type.
18105 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18106 signature to match glibc.
18107
18108 2009-12-16 Doug Evans <dje@google.com>
18109
18110 * linux-low.c (linux_read_memory): Fix argument to read.
18111
18112 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18113
18114 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18115 events, don't leave current_inferior pointing at null.
18116
18117 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18118
18119 * win32-low.c (LOG): Delete.
18120 (OUTMSG): Output to stderr.
18121 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18122 on compile time LOG macro.
18123 (win32_wait): Fix debug output.
18124
18125 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18126
18127 * win32-low.c (win32_add_one_solib): If the dll name is
18128 "ntdll.dll", prepend the system directory to the dll path.
18129
18130 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18131
18132 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18133
18134 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18135 Vladimir Prus <vladimir@codesourcery.com>
18136
18137 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18138 * configure.ac: Check for __mcoldfire__ and set
18139 gdb_cv_m68k_is_coldfire.
18140 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18141 reg-cf.o and reg-m68k.o.
18142 * configure: Regenerated.
18143
18144 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18145
18146 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18147 Pass it to thread_db_free.
18148 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18149 proper `detaching' argument to linux_remove_process.
18150 * linux-low.h (thread_db_free): Add `detaching' parameter.
18151 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18152 to thread_db_free.
18153 (thread_db_free): Add `detaching' parameter. Only
18154 call td_ta_clear_event if detaching from process.
18155
18156 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18157
18158 * thread-db.c (thread_db_free): Fix typo.
18159
18160 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18161
18162 PR gdb/10838
18163 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18164
18165 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18166
18167 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18168 with an i686 compiler.
18169 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18170 needed.
18171 * configure: Rebuilt.
18172
18173 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18174
18175 PR gdb/10783
18176
18177 * server.c (handle_search_memory_1): Correct read_addr initialization
18178 in loop for searching subsequent chunks.
18179
18180 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18181
18182 * configure.ac: New --with-libthread-db option.
18183 * thread-db.c: Allow direct dependence on libthread_db.
18184 (thread_db_free): Adjust.
18185 * config.in: Regenerate.
18186 * configure: Likewise.
18187
18188 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18189
18190 PR gdb/10757
18191 * thread-db.c (attach_thread): New function.
18192 (maybe_attach_thread): Return success/failure.
18193 (find_new_threads_callback): Adjust.
18194 (thread_db_find_new_threads): Loop until no new threads.
18195
18196 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18197
18198 * proc-service.c (ps_lgetregs): Formatting.
18199
18200 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18201
18202 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18203 * configure.ac: Adjust.
18204 * linux-low.h (struct process_info_private): Move members to struct
18205 thread_db.
18206 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18207 * linux-low.c (linux_remove_process): Adjust.
18208 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18209 * server.c (handle_query): Move code ...
18210 (handle_monitor_command): ... here. New function.
18211 * target.h (struct target_ops): New member.
18212 * thread-db.c (struct thread_db): New.
18213 (libthread_db_search_path): New variable.
18214 (thread_db_create_event, thread_db_enable_reporting)
18215 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18216 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18217 (try_thread_db_load_1, dladdr_to_soname): New functions.
18218 (try_thread_db_load, thread_db_load_search): New functions.
18219 (thread_db_init): Search for libthread_db.
18220 (thread_db_free): New function.
18221 (thread_db_handle_monitor_command): Likewise.
18222 * config.in: Regenerate.
18223 * configure: Regenerate.
18224
18225 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18226
18227 * spu-low.c (spu_kill): Wait for inferior to terminate.
18228 Call clear_inferiors.
18229 (spu_detach): Call clear_inferiors.
18230
18231 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18232
18233 * aclocal.m4: Regenerate.
18234 * config.in: Likewise.
18235 * configure: Likewise.
18236
18237 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18238
18239 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18240 (parse_spufs_run): New function.
18241 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18242 (ppc_breakpoint_at): Handle SPU breakpoints.
18243
18244 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18245
18246 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18247 (SPUFS_MAGIC): Define.
18248 (spu_enumerate_spu_ids): New function.
18249 (linux_qxfer_spu): New function.
18250 (linux_target_ops): Install linux_qxfer_spu.
18251
18252 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18253
18254 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18255 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18256 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18257 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18258 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18259 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18260 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18261 (init_registers_powerpc_cell32l): Add prototype.
18262 (init_registers_powerpc_cell64l): Likewise.
18263 (ppc_arch_setup): Detect Cell/B.E. architecture.
18264
18265 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18266
18267 * Makefile.in (datarootdir): New variable.
18268
18269 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18270
18271 * linux-low.c (linux_write_memory): Update debugging output.
18272 * Makefile.in (clean): Add new descriptions.
18273 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18274 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18275 * configure.srv: Add new files for arm*-*-linux*.
18276 * linux-arm-low.c: Add new declarations.
18277 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18278 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18279 (HWCAP_VFPv3D16): New.
18280 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18281 instead of __IWMMXT__.
18282 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18283 (arm_arch_setup): New.
18284 (target_regsets): Remove #ifdef. Add VFP regset.
18285 (the_low_target): Use arm_arch_setup.
18286
18287 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18288
18289 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18290 the main thread again.
18291
18292 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18293
18294 Adding Neutrino gdbserver.
18295 * configure: Regenerated.
18296 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18297 * configure.srv (i[34567]86-*-nto*): New target.
18298 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18299 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18300 (nto_comctrl) [__QNX__]: New function.
18301 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18302
18303 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
18304
18305 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18306 srv_tgtobj.
18307
18308 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18309 Pedro Alves <pedro@codesourcery.com>
18310
18311 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18312 don't support CONTEXT_EXTENDED_REGISTERS.
18313 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18314 (the_low_target): Install them.
18315 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18316 failing with ERROR_PIPE_NOT_CONNECTED.
18317
18318 2009-06-30 Doug Evans <dje@google.com>
18319 Pierre Muller <muller@ics.u-strasbg.fr>
18320
18321 Add h/w watchpoint support to x86-linux, win32-i386.
18322 * Makefile.in (SFILES): Add i386-low.c
18323 (i386_low_h): Define.
18324 (i386-low.o): Add dependencies.
18325 (linux-x86-low.o): Add i386-low.h dependency.
18326 (win32-i386-low.o): Ditto.
18327 * i386-low.c: New file.
18328 * i386-low.h: New file.
18329 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18330 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18331 * linux-low.c (linux_add_process): Initialize arch_private.
18332 (linux_remove_process): Free arch_private.
18333 (add_lwp): Initialize arch_private.
18334 (delete_lwp): Free arch_private.
18335 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18336 provided.
18337 * linux-low.h (process_info_private): New member arch_private.
18338 (lwp_info): New member arch_private.
18339 (linux_target_ops): New members new_process, new_thread,
18340 prepare_to_resume.
18341 (ptid_of): New macro.
18342 * linux-x86-low.c: Include stddef.h, i386-low.h.
18343 (arch_process_info): New struct.
18344 (arch_lwp_info): New struct.
18345 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18346 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18347 (i386_dr_low_get_status): New function.
18348 (x86_insert_point, x86_remove_point): New functions.
18349 (x86_stopped_by_watchpoint): New function.
18350 (x86_stopped_data_address): New function.
18351 (x86_linux_new_process, x86_linux_new_thread): New functions.
18352 (x86_linux_prepare_to_resume): New function.
18353 (the_low_target): Add entries for insert_point, remove_point,
18354 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18355 prepare_to_resume.
18356 * server.c (debug_hw_points): New global.
18357 (monitor_show_help): Document set debug-hw-points.
18358 (handle_query): Process "set debug-hw-points".
18359 * server.h (debug_hw_points): Declare.
18360 (paddress): Declare.
18361 * utils.c (NUMCELLS, CELLSIZE): New macros.
18362 (get_sell, xsnprintf, paddress): New functions.
18363 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18364 remove_point, stopped_by_watchpoint, stopped_data_address.
18365 * win32-i386-low.c: Include i386-low.h.
18366 (debug_reg_state): Replaces dr.
18367 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18368 (i386_dr_low_get_status): New function.
18369 (i386_insert_point, i386_remove_point): New functions.
18370 (i386_stopped_by_watchpoint): New function.
18371 (i386_stopped_data_address): New function.
18372 (i386_initial_stuff): Update.
18373 (get_thread_context,set_thread_context,i386_thread_added): Update.
18374 (the_low_target): Add entries for insert_point,
18375 remove_point, stopped_by_watchpoint, stopped_data_address.
18376 * win32-low.c (win32_insert_watchpoint): New function.
18377 (win32_remove_watchpoint): New function.
18378 (win32_stopped_by_watchpoint): New function.
18379 (win32_stopped_data_address): New function.
18380 (win32_target_ops): Add entries for insert_watchpoint,
18381 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18382 * win32-low.h (win32_target_ops): New members insert_point,
18383 remove_point, stopped_by_watchpoint, stopped_data_address.
18384
18385 2009-06-25 Pedro Alves <pedro@codesourcery.com>
18386
18387 * server.c (process_serial_event): Re-return unsupported, not
18388 error, if the type isn't recognized. Re-allow supporting only
18389 insert or remove packets. Also call require_running for
18390 breakpoints. Add missing break statement to default case. Tidy.
18391 * target.h (struct target_ops): Rename insert_watchpoint to
18392 insert_point, and remove_watchpoint to remove_point.
18393
18394 * linux-low.h (struct linux_target_ops): Likewise.
18395 * linux-low.c (linux_insert_watchpoint): Rename to ...
18396 (linux_insert_point): ... this. Adjust.
18397 (linux_remove_watchpoint): Rename to ...
18398 (linux_remove_point): ... this. Adjust.
18399 (linux_target_ops): Adjust.
18400 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18401 (cris_insert_point): ... this.
18402 (cris_remove_watchpoint): Rename to ...
18403 (cris_remove_point): ... this.
18404 (the_low_target): Adjust.
18405
18406 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18407
18408 * server.c (handle_v_kill): Pass signal_pid to
18409 kill_inferior if multi_process is zero.
18410
18411 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18412
18413 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18414 * target.h (target_ops): Comment for *_watchpoint to make it clear
18415 the functions can get types '0' and '1'.
18416
18417 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18418
18419 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18420 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18421 * regcache.c (get_regcache): Likewise.
18422 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18423 * win32-low.c (child_fetch_inferior_registers): Remove check for
18424 regno 0.
18425
18426 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18427 Pedro Alves <pedro@codesourcery.com>
18428
18429 * target.h (struct target_ops) <supports_multi_process>: New
18430 callback.
18431 (target_supports_multi_process): New.
18432 * server.c (handle_query): Even if GDB reports support, only
18433 enable multi-process if the target also supports it. Report
18434 multi-process support only if the target backend supports it.
18435 * linux-low.c (linux_supports_multi_process): New function.
18436 (linux_target_ops): Install it as target_supports_multi_process
18437 callback.
18438
18439 2009-05-24 Doug Evans <dje@google.com>
18440
18441 Global renaming of find_thread_pid to find_thread_ptid.
18442 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18443 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18444 All callers updated.
18445
18446 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18447 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18448 directly.
18449
18450 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18451 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18452 (linux_resume_one_lwp): Ditto.
18453
18454 2009-05-23 Doug Evans <dje@google.com>
18455
18456 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18457 from struct inferior_list_entry * to struct lwp_info *.
18458 All callers updated.
18459
18460 2009-05-13 Doug Evans <dje@google.com>
18461
18462 * linux-x86-low.c: Don't include assert.h.
18463 (x86_siginfo_fixup): Use fatal, not assert.
18464 (x86_arch_setup): Fix comment.
18465
18466 2009-05-12 Doug Evans <dje@google.com>
18467
18468 Biarch support for i386/amd64 gdbserver.
18469 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18470 Add linux-x86-low.c.
18471 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18472 (linux-x86-low.o): Add.
18473 * linux-x86-64-low.c: Delete.
18474 * linux-i386-low.c: Delete.
18475 * linux-x86-low.c: New file.
18476 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18477 linux-x86-low.o.
18478 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18479 linux-x86-low.o.
18480 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18481 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18482 (linux_child_pid_to_exec_file): New function.
18483 (elf_64_header_p, elf_64_file_p): New functions.
18484 (siginfo_fixup): New function.
18485 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18486 give target a chance to convert layout.
18487 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18488 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18489
18490 2009-05-07 Doug Evans <dje@google.com>
18491
18492 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18493 (regsets_store_inferior_registers): Ditto.
18494
18495 2009-05-06 Pedro Alves <pedro@codesourcery.com>
18496
18497 PR server/10048
18498
18499 * linux-low.c (must_set_ptrace_flags): Delete.
18500 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18501 of the global.
18502 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18503 `lwp->must_set_ptrace_flags' instead.
18504 (linux_wait_for_event_1): Set ptrace options here.
18505 (linux_wait_1): ... not here.
18506
18507 2009-04-30 Doug Evans <dje@google.com>
18508
18509 * inferiors.c (started_inferior_callback): New function.
18510 (attached_inferior_callback): New function.
18511 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18512 * server.c (print_started_pid, print_attached_pid): New functions.
18513 (detach_or_kill_for_exit): New function.
18514 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18515 * server.h (have_started_inferiors_p): Declare.
18516 (have_attached_inferiors_p): Declare.
18517
18518 * inferiors.c (remove_process): Fix memory leak, free process.
18519 * linux-low.c (linux_remove_process): New function.
18520 (linux_kill): Call it instead of remove_process.
18521 (linux_detach, linux_wait_1): Ditto.
18522
18523 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18524
18525 * configure.srv: Add x86 Windows CE target.
18526
18527 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18528
18529 * inferiors.c (get_thread_process): Make global.
18530 * server.h (get_thread_process): Add prototype.
18531 * thread-db.c (find_one_thread): Use get_thread_process
18532 instead of current_process.
18533 (thread_db_get_tls_address): Do not crash if called when
18534 thread layer is not yet initialized.
18535
18536 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18537
18538 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18539 * spu-low.c (current_tid): Rename to ...
18540 (current_ptid): ... this.
18541 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18542 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18543 ptid_get_lwp (current_ptid) instead of current_tid.
18544 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18545 instead of current_tid. Use find_process_pid to verify pid
18546 argument is valid. Pass proper argument to remove_process.
18547 (spu_thread_alive): Compare current_ptid instead of current_tid.
18548 (spu_resume): Likewise.
18549
18550 2009-04-02 Pedro Alves <pedro@codesourcery.com>
18551
18552 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18553 variable.
18554
18555 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18556
18557 Implement the multiprocess extensions, and add linux multiprocess
18558 support.
18559
18560 * server.h (ULONGEST): Declare.
18561 (struct ptid, ptid_t): New.
18562 (minus_one_ptid, null_ptid): Declare.
18563 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18564 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18565 (struct inferior_list_entry): Change `id' type from unsigned from
18566 to ptid_t.
18567 (struct sym_cache, struct breakpoint, struct
18568 process_info_private): Forward declare.
18569 (struct process_info): Declare.
18570 (current_process): Declare.
18571 (all_processes): Declare.
18572 (initialize_inferiors): Declare.
18573 (add_thread): Adjust to use ptid_t.
18574 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18575 (add_process, remove_process, find_thread_pid): Declare.
18576 (find_inferior_id): Adjust to use ptid_t.
18577 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18578 (multi_process): Declare.
18579 (push_event): Adjust to use ptid_t.
18580 (read_ptid, write_ptid): Declare.
18581 (prepare_resume_reply): Adjust to use ptid_t.
18582 (clear_symbol_cache): Declare.
18583 * inferiors.c (all_processes): New.
18584 (null_ptid, minus_one_ptid): New.
18585 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18586 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18587 (add_thread): Change unsigned long to ptid. Remove gdb_id
18588 parameter. Adjust.
18589 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18590 (gdb_id_to_thread): Rename to ...
18591 (find_thread_pid): ... this. Change unsigned long to ptid.
18592 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18593 (loaded_dll, pull_pid_from_list): Adjust.
18594 (add_process, remove_process, find_process_pid)
18595 (get_thread_process, current_process, initialize_inferiors): New.
18596 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18597 (struct target_waitstatus) <related_pid>: Ditto.
18598 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18599 return type to int.
18600 (struct target_ops) <join>: Add `pid' argument.
18601 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18602 (struct target_ops) <wait>: Add `ptid' field. Change return type
18603 to ptid.
18604 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18605 (mywait): Add `ptid' argument. Change return type to ptid_t.
18606 (target_pid_to_str): Declare.
18607 * target.c (set_desired_inferior): Adjust to use ptids.
18608 (mywait): Add new `ptid' argument. Adjust.
18609 (target_pid_to_str): New.
18610 * mem-break.h (free_all_breakpoints): Declare.
18611 * mem-break.c (breakpoints): Delelete.
18612 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18613 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18614 to use per-process breakpoint list.
18615 (free_all_breakpoints): New.
18616 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18617 (symbol_cache, all_symbols_looked_up): Delete.
18618 (hexchars): New.
18619 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18620 read_ptid): New.
18621 (prepare_resume_reply): Change ptid argument's type from unsigned
18622 long to ptid_t. Adjust. Implement W;process and X;process.
18623 (free_sym_cache, clear_symbol_cache): New.
18624 (look_up_one_symbol): Adjust to per-process symbol cache. *
18625 * server.c (cont_thread, general_thread, step_thread): Change type
18626 to ptid_t.
18627 (attached): Delete.
18628 (multi_process): New.
18629 (last_ptid): Change type to ptid_t.
18630 (struct vstop_notif) <ptid>: Change type to ptid_t.
18631 (queue_stop_reply, push_event): Change `ptid' argument's type to
18632 ptid_t.
18633 (discard_queued_stop_replies): Add `pid' argument.
18634 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18635 changes. Don't reference the `attached' global.
18636 (attach_inferior): Adjust to mywait interface changes.
18637 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18638 features. Handle and report "multiprocess+". Handle
18639 "qAttached:PID".
18640 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18641 changes.
18642 (handle_v_kill): New.
18643 (handle_v_stopped): Adjust to use target_pid_to_str.
18644 (handle_v_requests): Allow multiple attaches and runs when
18645 multiprocess extensions are in effect. Handle "vKill".
18646 (myresume): Adjust to use ptids.
18647 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18648 (handle_status): Adjust to discard_queued_stop_replies interface
18649 change.
18650 (first_thread_of, kill_inferior_callback)
18651 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18652 (main): Call initialize_inferiors. Adjust to use ptids, killing
18653 and detaching from all inferiors. Handle multiprocess packet
18654 variants.
18655 * linux-low.h: Include gdb_proc_service.h.
18656 (struct process_info_private): New.
18657 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18658 <lwpid_of>: Use ptid_get_lwp.
18659 (get_lwp_thread): Adjust.
18660 (struct lwp_info): Add `dead' member.
18661 (find_lwp_pid): Declare.
18662 * linux-low.c (thread_db_active): Delete.
18663 (new_inferior): Adjust comment.
18664 (inferior_pid): Delete.
18665 (linux_add_process): New.
18666 (handle_extended_wait): Adjust.
18667 (add_lwp): Change unsigned long to ptid.
18668 (linux_create_inferior): Add process to processes table. Adjust
18669 to use ptids. Don't set new_inferior here.
18670 (linux_attach_lwp): Rename to ...
18671 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18672 it. Adjust to use ptids.
18673 (linux_attach_lwp): New.
18674 (linux_attach): Add process to processes table. Don't set
18675 new_inferior here.
18676 (struct counter): New.
18677 (second_thread_of_pid_p, last_thread_of_process_p): New.
18678 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18679 multiple processes.
18680 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18681 processes. Remove process from process table.
18682 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18683 to multiple processes.
18684 (any_thread_of): New.
18685 (linux_detach): Add `pid' argument, and handle it. Remove process
18686 from processes table.
18687 (linux_join): Add `pid' argument. Handle it.
18688 (linux_thread_alive): Change unsighed long argument to ptid_t.
18689 Consider dead lwps as not being alive.
18690 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
18691 threads we're not interested in.
18692 (same_lwp, find_lwp_pid): New.
18693 (linux_wait_for_lwp): Change `pid' argument's type from int to
18694 ptid_t. Adjust.
18695 (linux_wait_for_event): Rename to ...
18696 (linux_wait_for_event_1): ... this. Change `pid' argument's type
18697 from int to ptid_t. Adjust.
18698 (linux_wait_for_event): New.
18699 (linux_wait_1): Add `ptid' argument. Change return type to
18700 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
18701 that exit from the process table.
18702 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
18703 Adjust.
18704 (mark_lwp_dead): New.
18705 (wait_for_sigstop): Adjust to use ptids. If a process exits while
18706 stopping all threads, mark its main lwp as dead.
18707 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
18708 ptids.
18709 (fetch_register, usr_store_inferior_registers)
18710 (regsets_fetch_inferior_registers)
18711 (regsets_store_inferior_registers, linux_read_memory)
18712 (linux_write_memory): Inline `inferior_pid'.
18713 (linux_look_up_symbols): Adjust to use per-process
18714 `thread_db_active'.
18715 (linux_request_interrupt): Adjust to use ptids.
18716 (linux_read_auxv): Inline `inferior_pid'.
18717 (initialize_low): Don't reference thread_db_active.
18718 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
18719 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
18720 (ps_getpid): Return the pid of the current inferior.
18721 * thread-db.c (proc_handle, thread_agent): Delete.
18722 (thread_db_create_event, thread_db_enable_reporting): Adjust to
18723 per-process data.
18724 (find_one_thread): Change argument type to ptid_t. Adjust to
18725 per-process data.
18726 (maybe_attach_thread): Adjust to per-process data and ptids.
18727 (thread_db_find_new_threads): Ditto.
18728 (thread_db_init): Ditto.
18729 * spu-low.c (spu_create_inferior, spu_attach): Add process to
18730 processes table. Adjust to use ptids.
18731 (spu_kill, spu_detach): Adjust interface. Remove process from
18732 processes table.
18733 (spu_join, spu_thread_alive): Adjust interface.
18734 (spu_wait): Adjust interface. Remove process from processes
18735 table. Adjust to use ptids.
18736 * win32-low.c (current_inferior_tid): Delete.
18737 (current_inferior_ptid): New.
18738 (debug_event_ptid): New.
18739 (thread_rec): Take a ptid. Adjust.
18740 (child_add_thread): Add `pid' argument. Adjust to use ptids.
18741 (child_delete_thread): Ditto.
18742 (do_initial_child_stuff): Add `attached' argument. Add process to
18743 processes table.
18744 (child_fetch_inferior_registers, child_store_inferior_registers):
18745 Adjust.
18746 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
18747 (win32_attach): Pass 1 to do_initial_child_stuff.
18748 (win32_kill): Adjust interface. Remove process from processes
18749 table.
18750 (win32_detach): Ditto.
18751 (win32_join): Adjust interface.
18752 (win32_thread_alive): Take a ptid.
18753 (win32_resume): Adjust to use ptids.
18754 (get_child_debug_event): Ditto.
18755 (win32_wait): Adjust interface. Remove exiting process from
18756 processes table.
18757
18758 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18759
18760 Non-stop mode support.
18761
18762 * server.h (non_stop): Declare.
18763 (gdb_client_data, handler_func): Declare.
18764 (delete_file_handler, add_file_handler, start_event_loop):
18765 Declare.
18766 (handle_serial_event, handle_target_event, push_event)
18767 (putpkt_notif): Declare.
18768 * target.h (enum resume_kind): New.
18769 (struct thread_resume): Replace `step' field by `kind' field.
18770 (TARGET_WNOHANG): Define.
18771 (struct target_ops) <wait>: Add `options' argument.
18772 <supports_non_stop, async, start_non_stop>: New fields.
18773 (target_supports_non_stop, target_async): New.
18774 (start_non_stop): Declare.
18775 (mywait): Add `options' argument.
18776 * target.c (mywait): Add `options' argument. Print child exit
18777 notifications here.
18778 (start_non_stop): New.
18779 * server.c (non_stop, own_buf, mem_buf): New globals.
18780 (struct vstop_notif): New.
18781 (notif_queue): New global.
18782 (queue_stop_reply, push_event, discard_queued_stop_replies)
18783 (send_next_stop_reply): New.
18784 (start_inferior): Adjust to use resume_kind. Adjust to mywait
18785 interface changes.
18786 (attach_inferior): In non-stop mode, don't wait for the target
18787 here.
18788 (handle_general_set): Handle QNonStop.
18789 (handle_query): When handling qC, return the current general
18790 thread, instead of the first thread of the list.
18791 (handle_query): If the backend supports non-stop mode, include
18792 QNonStop+ in the qSupported query response.
18793 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
18794 and non-stop mode.
18795 (handle_v_attach, handle_v_run): Handle non-stop mode.
18796 (handle_v_stopped): New.
18797 (handle_v_requests): Report support for vCont;t. Handle vStopped.
18798 (myresume): Adjust to use resume_kind. Handle non-stop.
18799 (queue_stop_reply_callback): New.
18800 (handle_status): Handle non-stop mode.
18801 (main): Clear non_stop flag on reconnection. Use the event-loop.
18802 Refactor serial protocol handling from here ...
18803 (process_serial_event): ... to this new function. When GDB
18804 selects any thread, select one here. In non-stop mode, wait until
18805 GDB acks all pending events before exiting.
18806 (handle_serial_event, handle_target_event): New.
18807 * remote-utils.c (remote_open): Install remote_desc in the event
18808 loop.
18809 (remote_close): Remove remote_desc from the event loop.
18810 (putpkt_binary): Rename to...
18811 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
18812 (putpkt_binary): New as wrapper around putpkt_binary_1.
18813 (putpkt_notif): New.
18814 (prepare_resume_reply): In non-stop mode, don't change the
18815 general_thread.
18816 * event-loop.c: New.
18817 * Makefile.in (OBJ): Add event-loop.o.
18818 (event-loop.o): New rule.
18819
18820 * linux-low.h (pid_of): Moved here.
18821 (lwpid_of): New.
18822 (get_lwp_thread): Use lwpid_of.
18823 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
18824 * linux-low.c (pid_of): Delete.
18825 (inferior_pid): Use lwpid_of.
18826 (linux_event_pipe): New.
18827 (target_is_async_p): New.
18828 (delete_lwp): New.
18829 (handle_extended_wait): Use lwpid_of.
18830 (add_lwp): Don't set lwpid field.
18831 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
18832 (linux_kill_one_lwp): If killing a running lwp, stop it first.
18833 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
18834 (linux_detach_one_lwp): If detaching from a running lwp, stop it
18835 first. Adjust to linux_wait_for_event interface changes. Use
18836 lwpid_of.
18837 (linux_detach): Don't delete the main lwp here.
18838 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
18839 (status_pending_p): Don't consider explicitly suspended lwps.
18840 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
18841 pointer. Add OPTIONS argument. Change return type to int. Use
18842 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
18843 (linux_wait_for_event): Take an integer pid instead of a lwp_info
18844 pointer. Add status pointer argument. Return a pid instead of a
18845 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
18846 changes. In non-stop mode, don't switch to a random thread.
18847 (linux_wait): Rename to...
18848 (linux_wait_1): ... this. Add target_options argument, and handle
18849 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
18850 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
18851 clean exit and signal exit code. Don't stop all threads in
18852 non-stop mode. In all-stop mode, only stop all threads when
18853 reporting a stop to GDB. Handle explicit thread stop requests.
18854 (async_file_flush, async_file_mark): New.
18855 (linux_wait): New.
18856 (send_sigstop): Use lwpid_of.
18857 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
18858 interface changes. In non-stop mode, don't switch to a random
18859 thread.
18860 (linux_resume_one_lwp): Use lwpid_of.
18861 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
18862 (linux_resume_one_thread): ... this. Handle resume_stop. In
18863 non-stop mode, don't look for pending flag in all threads.
18864 (resume_status_pending_p): Don't consider explicitly suspended
18865 threads.
18866 (my_waitpid): Reimplement. Emulate __WALL.
18867 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
18868 Use lwpid_of.
18869 (sigchld_handler, linux_supports_non_stop, linux_async)
18870 (linux_start_non_stop): New.
18871 (linux_target_ops): Register linux_supports_non_stop, linux_async
18872 and linux_start_non_stop.
18873 (initialize_low): Install SIGCHLD handler.
18874 * thread-db.c (thread_db_create_event, find_one_thread)
18875 (thread_db_get_tls_address): Use lwpid_of.
18876 * win32-low.c (win32_detach): Adjust to use resume_kind.
18877 (win32_wait): Add `options' argument.
18878 * spu-low.c (spu_resume): Adjust to use resume_kind.
18879 (spu_wait): Add `options' argument.
18880
18881 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18882
18883 Decouple target code from remote protocol.
18884
18885 * target.h (enum target_waitkind): New.
18886 (struct target_waitstatus): New.
18887 (struct target_ops) <wait>: Return an unsigned long. Take a
18888 target_waitstatus pointer instead of a char pointer.
18889 (mywait): Likewise.
18890 * target.c (mywait): Change prototype to return an unsigned long.
18891 Take a target_waitstatus pointer instead of a char pointer. Adjust.
18892 * server.h (thread_from_wait, old_thread_from_wait): Delete
18893 declarations.
18894 (prepare_resume_reply): Change prototype to take a
18895 target_waitstatus.
18896 * server.c (thread_from_wait, old_thread_from_wait): Delete.
18897 (last_status, last_ptid): New.
18898 (start_inferior): Remove "statusptr" argument. Adjust. Return a
18899 pid instead of a signal.
18900 (attach_inferior): Remove "status" and "signal" parameters.
18901 Adjust.
18902 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
18903 not as an address.
18904 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
18905 (handle_v_requests, myresume): Remove "status" and "signal"
18906 parameters. Adjust.
18907 (handle_status): New.
18908 (main): Delete local `status'. Adjust.
18909 * remote-utils.c: Include target.h.
18910 (prepare_resume_reply): Change prototype to take a
18911 target_waitstatus. Adjust.
18912
18913 * linux-low.c (linux_wait): Adjust to new target_ops->wait
18914 interface.
18915 * spu-low.c (spu_wait): Adjust.
18916 * win32-low.c (enum target_waitkind, struct target_waitstatus):
18917 Delete.
18918 (win32_wait): Adjust.
18919
18920 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18921
18922 * target.h (struct thread_resume): Delete leave_stopped member.
18923 (struct target_ops): Add a `n' argument to the `resume' callback.
18924 * server.c (start_inferior): Adjust.
18925 (handle_v_cont, myresume): Adjust.
18926 * linux-low.c (check_removed_breakpoint): Adjust to resume
18927 interface change, and to removed leave_stopped field.
18928 (resume_ptr): Delete.
18929 (struct thread_resume_array): New.
18930 (linux_set_resume_request): Add new `arg' parameter. Adjust to
18931 resume interface change.
18932 (linux_continue_one_thread, linux_queue_one_thread)
18933 (resume_status_pending_p): Check if the resume field is NULL
18934 instead of checking the leave_stopped member.
18935 (linux_resume): Adjust to the target resume interface change.
18936 * spu-low.c (spu_resume): Adjust to the target resume interface
18937 change.
18938 * win32-low.c (win32_detach, win32_resume): Ditto.
18939
18940 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18941
18942 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
18943 flag.
18944 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
18945 pending.
18946 (linux_continue_one_thread): Only preserve the stepping flag if
18947 there's a pending breakpoint.
18948
18949 2009-03-31 Pedro Alves <pedro@codesourcery.com>
18950
18951 * server.c (main): After the inferior having exited, call
18952 remote_close before exiting gdbserver.
18953
18954 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
18955
18956 Fix size of FPSCR in Power 7 processors.
18957 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
18958 (PPC_FEATURE_HAS_DFP): New #define.
18959 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
18960 size of the FPSCR.
18961
18962 2009-03-23 Pedro Alves <pedro@codesourcery.com>
18963
18964 * server.c (handle_query) Whitespace and formatting.
18965
18966 2009-03-22 Pedro Alves <pedro@codesourcery.com>
18967
18968 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
18969 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
18970 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
18971 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
18972 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
18973 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
18974 Makefile.in, configure.ac: Fix whitespace throughout.
18975 * configure: Regenerate.
18976
18977 2009-03-22 Pedro Alves <pedro@codesourcery.com>
18978
18979 * inferiors.c (find_inferior): Make it safe for the callback
18980 function to delete the currently iterated inferior.
18981
18982 2009-03-22 Pedro Alves <pedro@codesourcery.com>
18983
18984 * Makefile.in (linuw_low_h): Move higher.
18985 (thread-db.o): Depend on $(linux_low_h).
18986
18987 2009-03-17 Pedro Alves <pedro@codesourcery.com>
18988
18989 Rename "process" to "lwp" throughout.
18990
18991 * linux-low.c (all_processes): Rename to...
18992 (all_lwps): ... this.
18993 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
18994 (add_process): Rename to ...
18995 (add_lwp): ... this. Adjust.
18996 (linux_create_inferior): Adjust.
18997 (linux_attach_lwp): Adjust.
18998 (linux_attach): Adjust.
18999 (linux_kill_one_process): Rename to ...
19000 (linux_kill_one_lwp): ... this. Adjust.
19001 (linux_kill): Adjust.
19002 (linux_detach_one_process): Rename to ...
19003 (linux_detach_one_lwp): ... this. Adjust.
19004 (linux_detach): Adjust.
19005 (check_removed_breakpoint): Adjust.
19006 (status_pending_p): Adjust.
19007 (linux_wait_for_process): Rename to ...
19008 (linux_wait_for_lwp): ... this. Adjust.
19009 (linux_wait_for_event): Adjust.
19010 (send_sigstop): Adjust.
19011 (wait_for_sigstop): Adjust.
19012 (stop_all_processes): Rename to ...
19013 (stop_all_lwps): ... this.
19014 (linux_resume_one_process): Rename to ...
19015 (linux_resume_one_lwp): ... this. Adjust.
19016 (linux_set_resume_request, linux_continue_one_thread)
19017 (linux_queue_one_thread, resume_status_pending_p)
19018 (usr_store_inferior_registers, regsets_store_inferior_registers)
19019 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19020 Adjust.
19021 * linux-low.h (get_process): Rename to ...
19022 (get_lwp): ... this. Adjust.
19023 (get_thread_process): Rename to ...
19024 (get_thread_lwp): ... this. Adjust.
19025 (get_process_thread): Rename to ...
19026 (get_lwp_thread): ... this. Adjust.
19027 (struct process_info): Rename to ...
19028 (struct lwp_info): ... this.
19029 (all_processes): Rename to ...
19030 (all_lwps): ... this.
19031 * proc-service.c (ps_lgetregs): Adjust.
19032 * thread-db.c (thread_db_create_event, find_one_thread)
19033 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19034
19035 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19036
19037 * server.c (handle_query): Handle "qAttached".
19038
19039 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19040
19041 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19042 GPLv3, update license URL.
19043
19044 2009-03-01 Doug Evans <dje@google.com>
19045
19046 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19047 (server_h): Add gdb_signals.h.
19048 (signals.o): Update.
19049 * server.h (target_signal_from_host,target_signal_to_host_p)
19050 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19051
19052 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19053
19054 * remote-utils.c (getpkt): Also generate remote-debug
19055 information if noack_mode is set.
19056
19057 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19058
19059 * server.c (handle_query): Report qXfer:siginfo:read and
19060 qXfer:siginfo:write as supported and handle them.
19061 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19062 * linux-low.c (linux_xfer_siginfo): New.
19063 (linux_target_ops): Set it.
19064
19065 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19066
19067 * server.c (gdbserver_usage): Mention --remote-debug.
19068 (main): Accept '--remote-debug' switch.
19069
19070 2009-01-18 Doug Evans <dje@google.com>
19071
19072 * regcache.c (new_register_cache): No need to check result of xcalloc.
19073 * server.c (handle_search_memory): Back out calls to xmalloc,
19074 result is checked and error is returned to user upon failure.
19075 (handle_query): Ditto. Add more checks for result of malloc.
19076 (handle_v_cont): Check result of malloc, report error back to
19077 user upon failure.
19078 (handle_v_run): Ditto. Call freeargv.
19079 * server.h (freeargv): Declare.
19080 * utils.c (freeargv): New fn.
19081
19082 2009-01-15 Doug Evans <dje@google.com>
19083
19084 * gdbreplay.c (perror_with_name): Make arg const char *.
19085 * server.h (target_signal_to_name): Make return type const char *.
19086 * thread-db.c (thread_db_err_str): Make return type const char *.
19087 * utils.c (perror_with_name): Make arg const char *.
19088
19089 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19090
19091 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19092 when handling a EXIT_PROCESS_DEBUG_EVENT.
19093
19094 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19095
19096 * gdbreplay.c (gdbreplay_version): Update copyright year.
19097 * server.c (gdbserver_version): Likewise.
19098
19099 2009-01-05 Doug Evans <dje@google.com>
19100
19101 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19102 (handle_extended_wait): Improve comment.
19103
19104 2008-12-13 Doug Evans <dje@google.com>
19105
19106 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19107 * server.h (ATTR_MALLOC): New macro.
19108 (xmalloc,xcalloc,xstrdup): Declare.
19109 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19110 * inferiors.c: Ditto.
19111 * linux-low.c: Ditto.
19112 * mem-break.c: Ditto.
19113 * regcache.c: Ditto.
19114 * remote-utils.c: Ditto.
19115 * server.c: Ditto.
19116 * target.c: Ditto.
19117 * win32-low.c: Ditto.
19118
19119 2008-12-12 Doug Evans <dje@google.com>
19120
19121 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19122 in debugging printf.
19123
19124 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19125
19126 2008-12-09 Doug Evans <dje@google.com>
19127
19128 * linux-low.h (struct process_info): Delete member tid, unused.
19129 * thread-db.c (find_one_thread): Update.
19130 (maybe_attach_thread): Update.
19131
19132 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19133
19134 * target.h (struct target_ops): Add qxfer_osdata member.
19135 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19136 and dirent.h.
19137 (linux_qxfer_osdata): New functions.
19138 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19139 callback.
19140 * server.c (handle_query): Handle "qXfer:osdata:read:".
19141 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19142 (buffer_xml_printf): New functions.
19143 * server.h (struct buffer): New.
19144 (buffer_grow_str, buffer_grow_str0): New macros.
19145 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19146 (buffer_xml_printf): Declare.
19147
19148 2008-11-24 Doug Evans <dje@google.com>
19149
19150 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19151
19152 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19153
19154 * server.c (handle_v_run): Always use the supplied argument list.
19155
19156 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19157
19158 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19159 (xtensa_regmap_table): Add entry for scompare1.
19160
19161 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19162
19163 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19164 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19165 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19166 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19167 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19168 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19169 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19170 XML target descriptions.
19171 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19172 when inferior is running on an ISA 2.05 or later processor. Add
19173 special case to return offset for full 64-bit slot of FPSCR when
19174 in 32-bits.
19175
19176 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19177
19178 * Makefile.in (SFILES, clean): Added sparc64 files.
19179 (reg-sparc64.o, reg-sparc64.c): New.
19180 * configure.srv (sparc*-*-linux*): New configuration.
19181 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19182 syscall arguments for SPARC.
19183 (regsets_store_inferior_registers): Likewise.
19184 * linux-sparc-low.c: New file.
19185
19186 2008-10-21 Doug Evans <dje@google.com>
19187
19188 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19189 (READLINE_DIR,READLINE_DEP): Delete.
19190 (INTERNAL_CFLAGS): Update.
19191 (LINTFLAGS): Update.
19192
19193 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19194
19195 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19196 whole argv from the last run, not just argv[0].
19197
19198 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19199
19200 * regcache.c (new_register_cache): Return NULL if the register
19201 cache size isn't known yet.
19202 (free_register_cache): Avoid dereferencing a NULL regcache.
19203
19204 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19205
19206 * configure.srv: Merge MIPS and MIPS64.
19207
19208 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19209
19210 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19211
19212 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19213
19214 * Makefile.in: Add required vsx dependencies.
19215
19216 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19217 Declare init_registers_powerpc_vsx32l.
19218 Declare init_registers_powerpc_vsx64l.
19219 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19220 (ppc_arch_setup): Check for VSX in hwcap.
19221 (ppc_fill_vsxregset): New function.
19222 (ppc_store_vsxregset): New function.
19223 Add new VSX entry in regset_info target_regsets.
19224
19225 * configure.srv: Add new VSX dependencies.
19226
19227 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19228
19229 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19230 (remote_open): Set or clear transport_is_reliable.
19231 (putpkt_binary): Don't expect acks in noack mode.
19232 (getpkt): Don't send ack/nac in noack mode.
19233 * server.c (handle_general_set): Handle QStartNoAckMode.
19234 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19235 qSupported.
19236 (main): Reset noack_mode on every connection.
19237 * server.h (noack_mode): Declare.
19238
19239 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19240
19241 * Makefile.in (GDBREPLAY_OBS): New variable.
19242 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19243
19244 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19245 Daniel Jacobowitz <dan@codesourcery.com>
19246
19247 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19248 (usr_store_inferior_registers): Likewise.
19249 (regsets_store_inferior_registers): Likewise.
19250
19251 2008-07-31 Rolf Jansen <rj@surtec.com>
19252 Pedro Alves <pedro@codesourcery.com>
19253
19254 * configure.ac: Check for memmem declaration.
19255 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19256 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19257 (disable_packet_qfThreadInfo): Unconditionally compile.
19258 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19259 * configure, config.in: Regenerate.
19260
19261 2008-07-28 Doug Kwan <dougkwan@google.com>
19262
19263 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19264 (linux_write_memory): Remove declaration of errno.
19265
19266 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19267
19268 * linux-low.c (handle_extended_wait): Do not use "status"
19269 variable uninitialized.
19270
19271 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19272
19273 * server.c (handle_v_attach): Inhibit reporting dll changes.
19274
19275 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19276
19277 * remote-utils.c (prepare_resume_reply): If requested, don't
19278 output "thread:TID" in the T stop reply.
19279
19280 * server.c (disable_packet_vCont, disable_packet_Tthread)
19281 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19282 (handle_query): If requested, disable support for qC, qfThreadInfo
19283 and qsThreadInfo.
19284 (handle_v_requests): If requested, disable support for vCont.
19285 (gdbserver_show_disableable): New.
19286 (main): Handle --disable-packet and --disable-packet=LIST.
19287
19288 * server.h (disable_packet_vCont, disable_packet_Tthread)
19289 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19290
19291 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19292
19293 * server.c (gdbserver_usage): Mention --version.
19294
19295 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19296
19297 * Makefile.in (gdbreplay.o): New rule.
19298
19299 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19300
19301 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19302 message, not gdbserver.
19303
19304 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
19305 Nathan Sidwell <nathan@codesourcery.com>
19306 Joseph Myers <joseph@codesourcery.com>
19307
19308 * acinclude.m4: Include ../../config/acx.m4.
19309 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19310 * configure, config.in: Regenerate.
19311 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19312 * server.c (gdbserver_version): Print PKGVERSION.
19313 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19314 (main): Adjust gdbserver_usage calls.
19315 * gdbreplay.c (version, host_name): Add declarations.
19316 (gdbreplay_version, gdbreplay_usage): New.
19317 (main): Accept --version and --help options.
19318
19319 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19320
19321 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19322 (arm_breakpoint_at): Handle Thumb.
19323 (the_low_target): Add comment.
19324
19325 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19326
19327 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19328
19329 2008-05-09 Doug Evans <dje@google.com>
19330
19331 * server.h (decode_search_memory_packet): Declare.
19332 * remote-utils.c (decode_search_memory_packet): New fn.
19333 * server.c (handle_search_memory_1): New fn.
19334 (handle_search_memory): New fn.
19335 (handle_query): Process qSearch:memory packets.
19336
19337 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19338
19339 * regcache.c (registers_length): Remove.
19340 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19341 full register packet.
19342 * regcache.h (registers_length): Remove prototype.
19343 * server.h (PBUFSIZ): Define to 16384.
19344
19345 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19346
19347 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19348 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19349 powerpc-64l.o, and powerpc-altivec64l.o.
19350 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19351 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19352 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19353 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19354 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19355 to srv_xmlfiles.
19356
19357 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19358 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19359 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19360 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19361 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19362 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19363 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19364 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19365 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19366 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19367 (clean): Update.
19368
19369 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19370 (init_registers_powerpc_32l): ... this new prototype.
19371 (init_registers_powerpc_32): Remove, replace by ...
19372 (init_registers_powerpc_altivec32l): ... this new prototype.
19373 (init_registers_powerpc_e500): Remove, replace by ...
19374 (init_registers_powerpc_e500l): ... this new prototype.
19375 (init_registers_ppc64): Remove, replace by ...
19376 (init_registers_powerpc_64l): ... this new prototype.
19377 (init_registers_powerpc_64): Remove, replace by ...
19378 (init_registers_powerpc_altivec64l): ... this new prototype.
19379 (ppc_num_regs): Set to 73.
19380 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19381 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19382 (ppc_cannot_store_register): Handle orig_r3 and trap.
19383 (ppc_arch_setup): Update init_registers_... calls.
19384 (ppc_fill_gregset): Handle orig_r3 and trap.
19385
19386 * inferiors.c (clear_inferiors): Reset current_inferior.
19387
19388 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
19389
19390 * acinclude.m4: Add override.m4.
19391 * configure: Regenerate.
19392
19393 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19394
19395 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19396 initial call to init_register_ppc64.
19397
19398 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19399
19400 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19401 single powerpc*-*-linux* case.
19402 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19403
19404 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19405
19406 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
19407 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
19408 from reg_xmlfiles.
19409 * linux-ppc-low.c: Include <elf.h>.
19410 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19411 (ppc_hwcap): New global variable.
19412 (ppc_regmap): Remove __SPE__ #ifdef sections.
19413 (ppc_regmap_e500): New global variable.
19414 (ppc_cannot_store_register): Update __SPE__ special case.
19415 (ppc_get_hwcap): New function.
19416 (ppc_arch_setup): Use it to determine whether inferior supports
19417 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19418 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19419 Do not access registers if target does not support AltiVec.
19420 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19421 Do not access registers if target does not support SPE.
19422 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19423
19424 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19425
19426 * linux-low.c (disabled_regsets, num_regsets): New.
19427 (use_regsets_p): Delete.
19428 (linux_wait_for_process): Clear disabled_regsets.
19429 (regsets_fetch_inferior_registers): Check and set it.
19430 (regsets_store_inferior_registers): Likewise.
19431 (linux_fetch_registers, linux_store_registers): Do not use
19432 use_regsets_p.
19433 (initialize_low): Allocate disabled_regsets.
19434
19435 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19436
19437 * Makefile.in (LIBOBJS): New.
19438 (OBS): Use LIBOBJS.
19439 (memmem.o): New rule.
19440 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19441 * configure: Regenerated.
19442
19443 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19444
19445 * server.c (handle_query): Never return "unsupported" for
19446 qXfer:features:read queries.
19447
19448 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19449
19450 * server.c (get_features_xml): Fix inverted condition.
19451 (handle_query): Always support qXfer:feature:read.
19452
19453 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19454
19455 * server.c (wrapper_argv): New.
19456 (start_inferior): Handle wrapper_argv. If set, expect an extra
19457 trap.
19458 (gdbserver_usage): Document --wrapper.
19459 (main): Parse --wrapper.
19460
19461 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19462
19463 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19464 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19465 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19466 (ppc_set_pc): Likewise.
19467 (ppc_arch_setup): New function.
19468 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19469 of collect_register.
19470 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
19471
19472 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19473
19474 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19475 instead of linux-ppc64-low.o.
19476 * linux-ppc64-low.c: Remove file.
19477 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19478 (linux-ppc64-low.o): Remove rule.
19479
19480 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19481 (init_registers_powerpc_64): Likewise.
19482 (ppc_regmap): Conditionally define depending on __powerpc64__.
19483 (ppc_cannot_store_register): Do not special-case "fpscr" when
19484 compiled on __powerpc64__.
19485 (ppc_collect_ptrace_register): New function.
19486 (ppc_supply_ptrace_register): New function.
19487 (ppc_breakpoint): Change type to "unsigned int".
19488 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19489 (the_low_target): Conditionally provide initializers for the
19490 arch_setup member depending on __powerpc64__. Install
19491 collect_ptrace_register and supply_ptrace_register members.
19492
19493 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19494
19495 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19496 * server.c (gdbserver_xmltarget): Define.
19497 (get_features_xml): Use it to replace "target.xml" and arch_string.
19498
19499 * configure.srv: Remove srv_xmltarget. Add XML files that were
19500 mentioned there to srv_xmlfiles instead. Remove conditional tests
19501 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19502 srv_xmlfiles and srv_regobj to include all possible choices.
19503 * configure.ac (srv_xmltarget): Remove.
19504 (srv_xmlfiles): Do not add "target.xml".
19505 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19506 checks for supplementary target information.
19507 * configure: Regenerate.
19508 * Makefile.in (XML_TARGET): Remove.
19509 (target.xml): Remove rule.
19510 (clean): Do not clean up target.xml.
19511 (.PRECIOUS): Do not mention target.xml.
19512
19513 * target.h (struct target_ops): Remove arch_string member.
19514 * linux-low.c (linux_arch_string): Remove.
19515 (linux_target_ops): Remove arch_string initializer.
19516 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19517 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19518 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19519 * spu-low.c (spu_arch_string): Remove.
19520 (spu_target_ops): Remove arch_string initializer.
19521 * win32-low.c (win32_arch_string): Remove.
19522 (win32_target_ops): Remove arch_string initializer.
19523 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19524 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19525 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19526
19527 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19528
19529 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19530 by collect_ptrace_register and supply_ptrace_register hooks.
19531 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19532 instead of checking for the_low_target.left_pad_xfer.
19533 (usr_store_inferior_registers): Use collect_ptrace_register callback
19534 instead of checking for the_low_target.left_pad_xfer.
19535
19536 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19537 (s390_supply_ptrace_register): Likewise.
19538 (s390_fill_gregset): Call s390_collect_ptrace_register.
19539 (the_low_target): Update.
19540
19541 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19542 (ppc_supply_ptrace_register): Likewise.
19543 (the_low_target): Update.
19544
19545 * linux-i386-low.c (the_low_target): Update.
19546 * linux-x86-64-low.c (the_low_target): Update.
19547
19548 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19549
19550 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19551 reg-s390.o and reg-s390x.o.
19552
19553 * linux-low.c (new_inferior): New global variable.
19554 (linux_create_inferior, linux_attach): Set it.
19555 (linux_wait_for_process): Call the_low_target.arch_setup after the
19556 target has stopped for the first time.
19557 (initialize_low): Do not call the_low_target.arch_setup.
19558
19559 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19560 (s390_set_pc): Likewise.
19561 (s390_arch_setup): New function.
19562 (the_low_target): Use s390_arch_setup as arch_setup routine.
19563
19564 * regcache.c (realloc_register_cache): New function.
19565 (set_register_cache): Call it for each existing regcache.
19566
19567 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19568
19569 * server.h (init_registers): Remove prototype.
19570
19571 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19572 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19573 instead of init_registers ().
19574 * linux-arm-low.c (init_registers_arm): Add prototype.
19575 (init_registers_arm_with_iwmmxt): Likewise.
19576 (the_low_target): Add initializer for arch_setup field.
19577 * linux-cris-low.c (init_registers_cris): Add prototype.
19578 (the_low_target): Add initializer for arch_setup field.
19579 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19580 (the_low_target): Add initializer for arch_setup field.
19581 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19582 (the_low_target): Add initializer for arch_setup field.
19583 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19584 (the_low_target): Add initializer for arch_setup field.
19585 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19586 (the_low_target): Add initializer for arch_setup field.
19587 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19588 (the_low_target): Add initializer for arch_setup field.
19589 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19590 (init_registers_mips64_linux): Likewise.
19591 (the_low_target): Add initializer for arch_setup field.
19592 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19593 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19594 (the_low_target): Add initializer for arch_setup field.
19595 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19596 (init_registers_powerpc_64): Likewise.
19597 (the_low_target): Add initializer for arch_setup field.
19598 * linux-s390-low.c (init_registers_s390): Add prototype.
19599 (init_registers_s390x): Likewise.
19600 (the_low_target): Add initializer for arch_setup field.
19601 * linux-sh-low.c (init_registers_sh): Add prototype.
19602 (the_low_target): Add initializer for arch_setup field.
19603 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19604 (the_low_target): Add initializer for arch_setup field.
19605 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19606 (the_low_target): Add initializer for arch_setup field.
19607
19608 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19609 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19610 instead of init_registers ().
19611 * win32-arm-low.c (init_registers_arm): Add prototype.
19612 (the_low_target): Add initializer for arch_setup field.
19613 * win32-i386-low.c (init_registers_i386): Add prototype.
19614 (the_low_target): Add initializer for arch_setup field.
19615
19616 * spu-low.c (init_registers_spu): Add prototype.
19617 (initialize_low): Call initialie_registers_spu () instead of
19618 initialize_registers ().
19619
19620 2008-02-19 Pedro Alves <pedro@codesourcery.com>
19621
19622 * server.c (handle_v_requests): When handling the vRun and vAttach
19623 packets, if already debugging a process, don't kill it. Return an
19624 error instead.
19625
19626 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19627
19628 * server.c (handle_query): Correct length check.
19629
19630 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19631
19632 * win32-low.c (do_initial_child_stuff): Add process handle
19633 parameter. Set current_process_handle and current_process_id from the
19634 parameters. Clear globals.
19635 (win32_create_inferior): Don't set current_process_handle and
19636 current_process_id here. Instead pass them on the call to
19637 do_initial_child_stuff.
19638 (win32_attach): Likewise.
19639 (win32_clear_inferiors): New.
19640 (win32_kill): Don't close the current process handle or the
19641 current thread handle here. Instead call win32_clear_inferiors.
19642 (win32_detach): Don't open a new handle to the process. Call
19643 win32_clear_inferiors.
19644 (win32_join): Don't rely on current_process_handle; open a new
19645 handle using the process id.
19646 (win32_wait): Call win32_clear_inferiors when the inferior process
19647 has exited.
19648
19649 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19650
19651 * server.c (monitor_show_help): Add "exit".
19652
19653 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19654
19655 * Makefile.in (SFILES): Add linux-xtensa-low.c.
19656 (clean): Add reg-xtensa.c.
19657 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
19658 * configure.srv (xtensa*-*-linux*) New target.
19659 * linux-xtensa-low.c: New.
19660 * xtensa-xtregs.c: New.
19661
19662 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19663
19664 * hostio.c: Don't include errno.h.
19665 (errno_to_fileio_errno): Move to hostio-errno.
19666 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19667 error number outputting to the target->hostio_last_error callback.
19668 (hostio_packet_error): Use FILEIO_EINVAL directly.
19669 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19670 calls to hostio_error.
19671 * hostio-errno.c: New.
19672 * server.h (hostio_last_error_from_errno): Declare.
19673 * target.h (target_ops): Add hostio_last_error member.
19674 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19675 as hostio_last_error handler.
19676 * spu-low.c (spu_target_ops): Likewise.
19677 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19678 (wince_hostio_last_error): New functions.
19679 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19680 as hostio_last_error handler.
19681 (win32_target_ops) [!_WIN32_WCE]: Register
19682 hostio_last_error_from_errno as hostio_last_error handler.
19683 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19684 (hostio-errno.o): New rule.
19685 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19686 * configure.srv (srv_hostio_err_objs): New variable. Default to
19687 hostio-errno.o.
19688 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19689 * configure: Regenerate.
19690
19691 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19692
19693 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
19694 (linux_kill, linux_detach): Clean up the process list.
19695 * remote-utils.c (remote_open): Improve port number parsing.
19696 (putpkt_binary, input_interrupt): Only send interrupts if the target
19697 is running.
19698 * server.c (extended_protocol): Make static.
19699 (attached): Define earlier.
19700 (exit_requested, response_needed, program_argv): New variables.
19701 (target_running): New.
19702 (start_inferior): Clear attached here.
19703 (attach_inferior): Set attached here.
19704 (require_running): Define.
19705 (handle_query): Use require_running and target_running. Implement
19706 "monitor exit".
19707 (handle_v_attach, handle_v_run): New.
19708 (handle_v_requests): Use require_running. Handle vAttach and vRun.
19709 (gdbserver_usage): Update.
19710 (main): Redo argument parsing. Handle --debug and --multi. Handle
19711 --attach along with other options or after the port. Save
19712 program_argv. Support no initial program. Resynchronize
19713 communication with GDB after an error. Handle "monitor exit".
19714 Use require_running and target_running. Always allow the extended
19715 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
19716 restart in extended mode.
19717 * README: Refer to the GDB manual. Update --attach usage.
19718
19719 2007-12-20 Andreas Schwab <schwab@suse.de>
19720
19721 * linux-low.c (STACK_SIZE): Define.
19722 (linux_tracefork_child): Use it. Use __clone2 on ia64.
19723 (linux_test_for_tracefork): Likewise.
19724
19725 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
19726
19727 * linux-low.c (linux_wait_for_event): Update messages. Do not
19728 reinsert auto-delete breakpoints.
19729 * mem-break.c (struct breakpoint): Change return type of handler to
19730 int.
19731 (set_breakpoint_at): Update handler type.
19732 (reinsert_breakpoint_handler): Return 1 instead of calling
19733 delete_breakpoint.
19734 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
19735 setting a new one.
19736 (check_breakpoints): Delete auto-delete breakpoints and return 2.
19737 * mem-break.h (set_breakpoint_at): Update handler type.
19738 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
19739 * win32-low.c (auto_delete_breakpoint): New.
19740 (get_child_debug_event): Use it.
19741
19742 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
19743
19744 * configure.ac: Check for pread and pwrite.
19745 * hostio.c (handle_pread): Fall back to lseek and read.
19746 (handle_pwrite): Fall back to lseek and write.
19747 * config.in, configure: Regenerated.
19748
19749 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
19750
19751 * server.c (myresume): Add own_buf argument.
19752 (main): Update calls.
19753
19754 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
19755
19756 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
19757 * remote-utils.c (remote_open): Do not call disable_async_io.
19758 (block_async_io): Delete.
19759 (unblock_async_io): Make static.
19760 (initialize_async_io): New.
19761 * server.c (handle_v_cont): Handle async I/O here.
19762 (myresume): Likewise. Move other common resume tasks here...
19763 (main): ... from here. Call initialize_async_io. Disable async
19764 I/O before the main loop.
19765 * server.h (initialize_async_io): Declare.
19766 (block_async_io, unblock_async_io): Delete prototypes.
19767 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
19768
19769 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
19770
19771 * remote-utils.c (readchar): Allow binary data in received messages.
19772
19773 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19774
19775 * win32-low.c (attaching): New global.
19776 (win32_create_inferior): Clear the `attaching' global.
19777 (win32_attach): Set the `attaching' global.
19778 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
19779 attaching. Only set a breakpoint at the entry point if not
19780 attaching.
19781
19782 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19783
19784 * server.c (main): Don't report dll events on the initial
19785 connection on attaches.
19786
19787 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19788
19789 * server.c (main): Relax numerical bases supported for the pid of
19790 the --attach command line argument.
19791
19792 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19793
19794 * win32-low.c (win32_attach): Call OpenProcess before
19795 DebugActiveProcess, not after. Add last error output to error
19796 call.
19797
19798 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19799
19800 * win32-low.c (win32_get_thread_context)
19801 (win32_set_thread_context): New functions.
19802 (thread_rec): Use win32_get_thread_context.
19803 (continue_one_thread, win32_resume): Use win32_set_thread_context.
19804 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
19805 field.
19806
19807 2007-12-03 Leo Zayas
19808 Pedro Alves <pedro_alves@portugalmail.pt>
19809
19810 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
19811 global variables.
19812 (child_add_thread): Minor cleanup.
19813 (child_continue): Resume artificially suspended threads before
19814 calling ContinueDebugEvent.
19815 (suspend_one_thread): New.
19816 (fake_breakpoint_event): New.
19817 (get_child_debug_event): Change return type to int. Check here if
19818 gdb sent an interrupt request. If a soft interrupt was requested,
19819 fake a breakpoint event. Return 0 if there is no event to handle,
19820 and 1 otherwise.
19821 (win32_wait): Don't check here if gdb sent an interrupt request.
19822 Ensure there is a valid event to handle.
19823 (win32_request_interrupt): Add soft interruption method as last
19824 resort.
19825
19826 2007-12-03 Leo Zayas
19827 Pedro Alves <pedro_alves@portugalmail.pt>
19828
19829 * win32-low.h (win32_thread_info): Add descriptions to the
19830 structure members. Replace `suspend_count' counter by a
19831 `suspended' flag.
19832 * win32-low.c (thread_rec): Update condition of when to get the
19833 context from the inferior. Rely on ContextFlags being set if it
19834 has already been retrieved. Only suspend the inferior thread if
19835 we haven't already. Warn if that fails.
19836 (continue_one_thread): s/suspend_count/suspended/. Only call
19837 ResumeThread once. Warn if that fails.
19838
19839 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
19840
19841 * win32-low.c (win32_wait): Don't read from the inferior when it
19842 has already exited.
19843
19844 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
19845
19846 * Makefile.in (win32_low_h): New variable.
19847 (win32-low.o): Add dependency on $(win32_low_h).
19848 (win32-arm-low.o, win32-i386-low.o): New rules.
19849
19850 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
19851
19852 * hostio.c: Correct copyright year.
19853
19854 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
19855
19856 * Makefile.in (OBS): Add hostio.o.
19857 (hostio.o): New rule.
19858 * server.h (handle_vFile): Declare.
19859 * hostio.c: New file.
19860 * server.c (handle_v_requests): Take packet_len and new_packet_len
19861 for binary packets. Call handle_vFile.
19862 (main): Update call to handle_v_requests.
19863
19864 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
19865
19866 * linux-low.c: Include <sched.h>.
19867
19868 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
19869
19870 * linux-low.c (linux_tracefork_grandchild): New.
19871 (linux_tracefork_child): Use clone.
19872 (linux_test_for_tracefork): Use clone; allocate and free a stack.
19873
19874 2007-10-31 Joel Brobecker <brobecker@adacore.com>
19875
19876 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
19877
19878 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
19879
19880 * linux-low.c (handle_extended_wait): Handle unexpected signals.
19881
19882 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
19883
19884 * inferiors.c (change_inferior_id): Delete.
19885 (add_pid_to_list, pull_pid_from_list): New.
19886 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
19887 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
19888 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
19889 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
19890 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
19891 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
19892 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
19893 (using_threads): Always set to 1.
19894 (handle_extended_wait): New.
19895 (add_process): Do not set TID.
19896 (linux_create_inferior): Set must_set_ptrace_flags.
19897 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
19898 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
19899 (linux_thread_alive): Rename TID argument to LWPID.
19900 (linux_wait_for_process): Handle unknown processes. Do not use TID.
19901 (linux_wait_for_event): Do not use TID or check using_threads. Update
19902 call to dead_thread_notify. Call handle_extended_wait.
19903 (linux_create_inferior): Use PTRACE_SETOPTIONS.
19904 (send_sigstop): Delete sigstop_sent.
19905 (wait_for_sigstop): Avoid TID.
19906 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
19907 (linux_test_for_tracefork): New.
19908 (linux_lookup_signals): Use thread_db_active and
19909 linux_supports_tracefork_flag.
19910 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
19911 * linux-low.h (get_process_thread): Avoid TID.
19912 (struct process_ifo): Move thread_known and tid to the end. Remove
19913 sigstop_sent.
19914 (linux_attach_lwp, thread_db_init): Update prototypes.
19915 * server.h (change_inferior_id): Delete prototype.
19916 (add_pid_to_list, pull_pid_from_list): New prototypes.
19917 * thread-db.c (thread_db_use_events): New.
19918 (find_first_thread): Rename to...
19919 (find_one_thread): ...this. Update callers and messages. Do not
19920 call fatal. Check thread_db_use_events. Do not call
19921 change_inferior_id or new_thread_notify.
19922 (maybe_attach_thread): Update. Do not call new_thread_notify.
19923 (thread_db_init): Set thread_db_use_events. Check use_events.
19924 * utils.c (fatal, warning): Correct message prefix.
19925
19926 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
19927
19928 * Makefile.in (clean): Remove new files.
19929 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
19930 (powerpc-64.o, powerpc-64.c): New rules.
19931 * configure.srv: Use alternate register sets for powerpc64-*-linux*
19932 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
19933 with SPE.
19934 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
19935 SPE targets.
19936 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
19937 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
19938 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
19939 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
19940 (target_regsets): Add AltiVec and SPE register sets.
19941 * configure.ac: Check for AltiVec and SPE.
19942 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
19943 (ppc_fill_vrregset, ppc_store_vrregset): New.
19944 (target_regsets): Add AltiVec register set.
19945 * configure: Regenerated.
19946
19947 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
19948
19949 * linux-low.c (O_LARGEFILE): Define.
19950 (linux_read_memory): Use /proc/PID/mem.
19951 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
19952 * configure, config.in: Regenerated.
19953
19954 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19955
19956 * linux-low.c (linux_wait_for_event): Do not pass signals while
19957 single-stepping.
19958
19959 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
19960
19961 * win32-low.c (create_process): New.
19962 (win32_create_inferior): Use create_process instead of
19963 CreateProcess. If create_process failed retry appending an ".exe"
19964 suffix. Store the GetLastError result immediatelly after
19965 create_process calls and use it on the call to error.
19966
19967 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
19968
19969 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
19970
19971 2007-08-23 Joel Brobecker <brobecker@adacore.com>
19972
19973 * configure.ac: Switch license to GPLv3.
19974
19975 2007-08-01 Michael Snyder <msnyder@access-company.com>
19976
19977 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
19978
19979 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
19980
19981 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
19982 typedef.
19983 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
19984 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
19985 CloseToolhelp32Snapshot.
19986 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
19987 CloseToolhelp32Snapshot.
19988
19989 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
19990
19991 * server.c (main): Check for inferior exit before main loop.
19992
19993 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
19994
19995 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
19996 instead of on tmp_desc.
19997
19998 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
19999 Daniel Jacobowitz <dan@codesourcery.com>
20000
20001 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20002 (add_thread): Minor cleanups.
20003 (clear_inferiors): Move lower in the file. Clear the DLL
20004 list.
20005 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20006 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20007 (xml_escape_text): New.
20008 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20009 for qSupported.
20010 (handle_v_cont): Report errors.
20011 (gdbserver_version): Update.
20012 (main): Correct size of own_buf. Do not report initial DLL events.
20013 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20014 (unloaded_dll, xml_escape_text): New.
20015 * win32-low.c (enum target_waitkind): Update comments.
20016 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20017 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20018 (win32_EnumProcessModules, win32_GetModuleInformation)
20019 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20020 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20021 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20022 (win32_Module32First, win32_Module32Next, load_toolhelp)
20023 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20024 (get_child_debug_event): Handle DLL events.
20025 (win32_wait): Likewise.
20026
20027 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20028
20029 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20030 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20031
20032 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20033
20034 * win32-low.c (handle_output_debug_string): Ignore event if not
20035 waiting.
20036
20037 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20038
20039 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20040
20041 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20042
20043 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20044
20045 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20046
20047 * inferiors.c (change_inferior_id): Add comment.
20048 * linux-low.c (check_removed_breakpoint): Add an early
20049 prototype. Improve debug output.
20050 (linux_attach): Doc update.
20051 (linux_detach_one_process, linux_detach): Clean up before releasing
20052 each process.
20053 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20054 * linux-low.h (struct process_info): Doc improvement.
20055 * mem-break.c (delete_all_breakpoints): New.
20056 * mem-break.h (delete_all_breakpoints): New prototype.
20057 * thread-db.c (find_first_thread): New.
20058 (thread_db_create_event): Call it instead of
20059 thread_db_find_new_threads. Clean up unused variables.
20060 (maybe_attach_thread): Remove first thread handling.
20061 (thread_db_find_new_threads): Use find_first_thread.
20062 (thread_db_get_tls_address): Likewise.
20063
20064 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20065
20066 * thread-db.c (thread_db_find_new_threads): Add prototype.
20067 (thread_db_create_event): Check for the main thread before adding
20068 a new thread.
20069 (maybe_attach_thread): Only enable event reporting if TID == 0.
20070 (thread_db_get_tls_address): Check for new threads.
20071
20072 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20073
20074 * linux-low.c (linux_create_inferior): Try execv before execvp.
20075 * spu-low.c (spu_create_inferior): Likewise.
20076
20077 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20078
20079 * linux-low.c (linux_create_inferior): Change execv to execvp.
20080 * spu-low.c (spu_create_inferior): Likewies.
20081
20082 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20083
20084 * Makefile.in (clean): Clean new files instead of deleted ones.
20085 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20086 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20087 rules.
20088 * configure.srv: Specify XML files and new regformats for MIPS and
20089 MIPS64 GNU/Linux.
20090 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20091 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20092 an entry for the restart register.
20093 (mips_cannot_fetch_register, mips_cannot_store_register)
20094 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20095 register names to match the XML descriptions.
20096 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20097 restart register instead of $0.
20098
20099 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20100 Markus Deuling <deuling@de.ibm.com>
20101
20102 * remote-utils.c (decode_xfer_write): New function.
20103 * server.h (decode_xfer_write): Add prototype.
20104 * server.c (handle_query): Add PACKET_LEN argument. Support
20105 qXfer:spu:read and qXfer:spu:write packets.
20106 (main): Pass packet_len to handle_query.
20107 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20108 * target.h (target_ops): Add qxfer_spu.
20109
20110 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20111
20112 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20113 accessing non-seekable spufs files.
20114
20115 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20116
20117 * server.c (handle_query): Add reply for qC packet.
20118
20119 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20120 Leo Zayas <lerele@champenstudios@com>
20121
20122 * server.h (check_remote_input_interrupt_request): New function.
20123 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20124 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20125 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20126 (check_remote_input_interrupt_request): New function.
20127 * server.h (check_remote_input_interrupt_request): Declare.
20128 * win32-low.c (winapi_DebugBreakProcess,
20129 winapi_GenerateConsoleCtrlEvent): New typedefs.
20130 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20131 to 250 ms.
20132 (win32_wait): Check for remote interrupt request
20133 with check_remote_input_interrupt_request.
20134 (win32_request_interrupt): New function.
20135 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20136
20137 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20138
20139 * win32-low.c (debug_registers_changed,
20140 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20141 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20142 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20143 (thread_rec): Get context using the low target.
20144 (child_add_thread): Call thread_added on the low target,
20145 which does the same thing.
20146 (regptr): Delete.
20147 (do_initial_child_stuff): Remove debug registers references.
20148 Set context using the low target. Resume threads after
20149 setting the contexts.
20150 (child_continue): Remove dead variable. Remove debug
20151 registers references.
20152 (child_fetch_inferior_registers): Go through the low target.
20153 (do_child_store_inferior_registers): Remove.
20154 (child_store_inferior_registers): Go through the low target.
20155 (win32_resume): Remove debug registers references.
20156 Set context using the low target.
20157 (handle_exception): Change return type to void. Don't record
20158 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20159 first chance exception.
20160 (get_child_debug_event): Change return type to void. Remove
20161 goto loop. Always return after waiting for debug event.
20162 (win32_wait): Convert to switch statement. Handle spurious
20163 events.
20164
20165 * win32-i386-low.c (debug_registers_changed,
20166 debug_registers_used): New.
20167 (initial_stuff): Rename to ...
20168 (i386_initial_stuff): ... this. Clear debug registers
20169 state variables.
20170 (store_debug_registers): Delete.
20171 (i386_get_thread_context): New.
20172 (load_debug_registers): Delete.
20173 (i386_set_thread_context): New.
20174 (i386_thread_added): New.
20175 (single_step): Rename to ...
20176 (i386_single_step): ... this.
20177 (do_fetch_inferior_registers): Rename to ...
20178 (i386_fetch_inferior_register): ... this.
20179 (i386_store_inferior_register): New.
20180 (the_low_target): Adapt to new interface.
20181
20182 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20183 (arm_get_thread_context): New.
20184 (arm_set_thread_context): New.
20185 (regptr): New.
20186 (do_fetch_inferior_registers): Rename to ...
20187 (arm_fetch_inferior_register): ... this.
20188 (arm_store_inferior_register): New.
20189 (arm_wince_breakpoint): Reimplement as unsigned long.
20190 (arm_wince_breakpoint_len): Define.
20191 (the_low_target): Adapt to new interface.
20192
20193 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20194 load_debug_registers. Add get_thread_context, set_thread_context,
20195 thread_added and store_inferior_register. Rename
20196 fetch_inferior_registers to fetch_inferior_register.
20197 (regptr): Remove declaration.
20198
20199 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20200
20201 * linux-low.c (linux_detach): Change return type to int. Return 0.
20202 * spu-low.c (spu_detach): Likewise.
20203
20204 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20205
20206 * target.h (target_ops): Change return type of detach to int.
20207 Add join.
20208 (join_inferior): New.
20209 * server.c (main): Don't skip detach support on mingw32.
20210 If the inferior doesn't support detaching return error.
20211 Call join_inferior instead of using waitpid.
20212 * linux-low.c (linux_join): New.
20213 (linux_target_op): Add linux_join.
20214 * spu-low.c (spu_join): New.
20215 (spu_target_ops): Add spu_join.
20216 * win32-low.c (win32_detach): Adapt to new interface.
20217 Reopen current_process_handle before detaching. Issue a child
20218 resume before detaching.
20219 (win32_join): New.
20220 (win32_target_op): Add win32_join.
20221
20222 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20223
20224 * win32-low.c (win32-attach): Fix return value.
20225 * target.h (target_ops): Describe ATTACH return values.
20226
20227 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20228
20229 * win32-low.c (GETPROCADDRESS): Define.
20230 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20231 (winapi_DebugSetProcessKillOnExit): Likewise.
20232 (win32_create_inferior): Force usage of ansi CreateProcessA.
20233 (win32_attach): Use GETPROCADDRESS.
20234 (win32_detach): Likewise.
20235
20236 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20237
20238 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20239
20240 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20241
20242 * win32-low.c: Commit leftover changes from 2007-03-29.
20243
20244 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20245
20246 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20247 fields short instead of int. Add explicit padding.
20248 (i387_cache_to_fsave): Remove unnecessary casts.
20249 (i387_fsave_to_cache): Doc fix.
20250 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20251
20252 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20253
20254 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20255 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20256
20257 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20258
20259 * configure.srv (arm*-*-mingw32ce*): Move near the other
20260 arm targets.
20261
20262 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20263
20264 * configure.ac: Add errno checking.
20265 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20266 sys/file.h and malloc.h.
20267 (AC_CHECK_DECLS): Add perror.
20268 (srv_mingwce): Handle.
20269 * configure.srv (i[34567]86-*-cygwin*): Add
20270 win32-i386-low.o to srv_tgtobj.
20271 (i[34567]86-*-mingw*): Likewise.
20272 (arm*-*-mingw32ce*): Add case.
20273 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20274 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20275 [__MINGW32CE__] (strerror): New function.
20276 [__MINGW32CE__] (errno): Define to GetLastError.
20277 [__MINGW32CE__] (COUNTOF): New macro.
20278 (remote_open): Remove extra close call.
20279 * mem-break.c (delete_breakpoint_at): New function.
20280 * mem-break.h (delete_breakpoint_at): Declare.
20281 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20282 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20283 [USE_WIN32API] (read, write): Add char* casts.
20284 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20285 * server.h: Include wincecompat.h on Windows CE.
20286 [HAVE_ERRNO_H]: Check.
20287 (perror): Declare if not declared.
20288 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20289 (perror_with_name): Remove errno declaration.
20290 * wincecompat.h: New.
20291 * wincecompat.c: New.
20292 * win32-low.h: New.
20293 * win32-arm-low.c: New.
20294 * win32-i386-low.c: New.
20295 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20296 (OUTMSG2): Make it safe.
20297 (_T): New macro.
20298 (COUNTOF): New macro.
20299 (NUM_REGS): Get it from the low target.
20300 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20301 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20302 (thread_rec): Let low target handle debug registers.
20303 (child_add_thread): Likewise.
20304 (child_init_thread_list): Likewise.
20305 (continue_one_thread): Likewise.
20306 (regptr): New.
20307 (do_child_fetch_inferior_registers): Move to ...
20308 * win32-i386-low.c: ... here, and rename to ...
20309 (do_fetch_inferior_registers): ... this.
20310 * win32-low.c (child_fetch_inferior_registers):
20311 Go through the low target.
20312 (do_child_store_inferior_registers): Use regptr.
20313 (strwinerror): New function.
20314 (win32_create_inferior): Handle Windows CE.
20315 Use strwinerror instead of strerror on Windows error
20316 codes. Add program to the error output.
20317 Don't close the main thread handle on Windows CE.
20318 (win32_attach): Use coredll.dll on Windows CE.
20319 (win32_kill): Close current process and current
20320 thread handles.
20321 (win32_detach): Use coredll.dll on Windows CE.
20322 (win32_resume): Let low target handle debug registers, and
20323 step request.
20324 (handle_exception): Add/Remove initial breakpoint. Avoid
20325 non-existant WSTOPSIG on Windows CE.
20326 (win32_read_inferior_memory): Cast to remove warning.
20327 (win32_arch_string): Go through the low target.
20328 (initialize_low): Call set_breakpoint_data with the low
20329 target's breakpoint.
20330 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20331 FOP_REGNUM, mappings): Move to ...
20332 * win32-i386-low.c: ... here.
20333 * win32-low.c (win32_thread_info): Move to ...
20334 * win32-low.h: ... here.
20335 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20336 win32-arm-low.c and wincecompat.c.
20337 (all:): Add $EXEEXT.
20338 (install-only:): Likewise.
20339 (gdbserver:): Likewise.
20340 (gdbreplay:): Likewise.
20341 * config.in: Regenerate.
20342 * configure: Regenerate.
20343
20344 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20345
20346 * win32-low.c: Rename typedef thread_info to
20347 win32_thread_info throughout.
20348
20349 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20350
20351 * win32-i386-low.c: Rename to ...
20352 * win32-low.c: ... this.
20353 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20354 * Makefile.in: Likewise.
20355
20356 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20357
20358 * remote-utils.c (monitor_output): Constify msg parameter.
20359 * server.h (monitor_output): Likewise.
20360 * win32-i386-low.c (handle_output_debug_string): New.
20361 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20362 handle_output_debug_string.
20363 (get_child_debug_event): Likewise.
20364
20365 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20366
20367 * server.c (main): Correct strtoul check.
20368
20369 2007-03-27 Jon Ringle <jon@ringle.org>
20370
20371 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20372
20373 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20374
20375 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20376
20377 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20378
20379 * terminal.h: Check HAVE_SGTTY_H.
20380
20381 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
20382
20383 * remote-utils.c (remote_open): Print out the assigned port number.
20384
20385 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20386
20387 * remote-utils.c (monitor_output): New function.
20388 * server.c (debug_threads): Define here.
20389 (monitor_show_help): New function.
20390 (handle_query): Handle qRcmd.
20391 (main): Do not handle 'd' packet.
20392 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20393 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20394 of debug_threads.
20395
20396 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20397
20398 * Makefile.in (EXEEXT): New.
20399 (clean): Use $(EXEEXT).
20400
20401 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20402
20403 * target.h (target_ops): Rename send_signal to request_interrupt,
20404 and remove enum target_signal parameter.
20405 * linux-low.c (linux_request_interrupt): Rename from
20406 linux_send_signal, and always send SIGINT.
20407 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20408 and always send SIGINT.
20409 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20410 of send_signal.
20411 (input_interrupt): Likewise.
20412
20413 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20414
20415 * server.c (get_features_xml): Check if target implemented
20416 arch_string.
20417 * win32-i386-low.c (win32_arch_string): New.
20418 (win32_target_ops): Add win32_arch_string as arch_string member.
20419
20420 2007-02-22 Markus Deuling <deuling@de.ibm.com>
20421
20422 * spu-low.c (spu_arch_string): New.
20423 (spu_target_ops): Add spu_arch_string.
20424
20425 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20426
20427 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20428 * configure.ac: Do not check for terminal.h.
20429 * configure, config.in: Regenerated.
20430
20431 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20432
20433 * Makefile.in (OBS): Add $(XML_BUILTIN).
20434 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20435 (clean): Update.
20436 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20437 (arm-with-iwmmxt.c): New.
20438 * config.in, configure: Regenerate.
20439 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20440 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20441 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20442 (arm*-*-linux*): Add iWMMXt and regset support.
20443 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20444 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20445 (arm_store_wmmxregset, target_regsets): New.
20446 * server.c (get_features_xml): Take annex argument. Check builtin
20447 XML documents.
20448 (handle_query): Handle multiple annexes.
20449
20450 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20451
20452 * remote-utils.c [USE_WIN32API] (read, write): Define.
20453 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20454 write.
20455
20456 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20457
20458 * linux-i386-low.c (the_low_target): Set arch_string.
20459 * linux-x86-64-low.c (the_low_target): Likewise.
20460 * linux-low.c (linux_arch_string): New.
20461 (linux_target_ops): Add it.
20462 * linux-low.h (struct linux_target_ops): Add arch_string.
20463 * server.c (write_qxfer_response): Use const void * for DATA.
20464 (get_features_xml): New.
20465 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20466 * target.h (struct target_ops): Add arch_string method.
20467
20468 2007-01-03 Denis Pilat <denis.pilat@st.com>
20469 Daniel Jacobowitz <dan@codesourcery.com>
20470
20471 * linux-low.c (linux_kill): Handle being called with no threads.
20472 * win32-i386-low.c (win32_kill): Likewise.
20473 (get_child_debug_event): Clear current_process_handle.
20474
20475 2006-12-30 Denis PILAT <denis.pilat@st.com>
20476 Daniel Jacobowitz <dan@codesourcery.com>
20477
20478 * remote-utils.c (remote_open): Check the type of specified
20479 serial port devices before opening them.
20480 * server.c (main): Kill the inferior if an error occurs during
20481 the first remote_open.
20482
20483 2006-12-05 Markus Deuling <deuling@de.ibm.com>
20484
20485 * README: Update supported targets.
20486
20487 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20488
20489 * Makefile.in (clean): Remove reg-mips64.c.
20490 (reg-mips64.c, reg-mips64.o): New rules.
20491 * configure.srv: Handle mips64. Include regset support for mips.
20492 * linux-mips-low.c (union mips_register): New.
20493 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20494 (mips_breakpoint, mips_breakpoint_at): Use int.
20495 (mips_collect_register, mips_supply_register)
20496 (mips_collect_register_32bit, mips_supply_register_32bit)
20497 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20498 (mips_store_fpregset, target_regsets): New.
20499 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20500
20501 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20502
20503 * configure.srv: Add target "spu*-*-*".
20504 * Makefile.in (clean): Remove reg-spu.c.
20505 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20506 * spu-low.c: New file.
20507
20508 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20509
20510 * configure.ac: Correct td_thr_tls_get_addr test.
20511 * configure: Regenerated.
20512
20513 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20514
20515 * linux-low.c (linux_wait_for_event): Reformat. Use the
20516 pass_signals array.
20517 * remote-utils.c (decode_address_to_semicolon): New.
20518 * server.c (pass_signals, handle_general_set): New.
20519 (handle_query): Mention QPassSignals for qSupported.
20520 (main): Call handle_general_set.
20521 * server.h (pass_signals, decode_address_to_semicolon): New.
20522
20523 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20524
20525 * server.c (handle_query): Correct error handling for read_auxv.
20526
20527 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20528
20529 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20530 and srv_linux_thread_db to yes.
20531 * linux-s390-low.c (s390_fill_gregset): New function.
20532 (target_regsets): Define data structure.
20533
20534 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20535
20536 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20537 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20538 * config.in, configure: Regenerated.
20539 * inferiors.c (gdb_id_to_thread): New function.
20540 (gdb_id_to_thread_id): Use it.
20541 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20542 * linux-low.h (struct process_info): Add th member.
20543 (thread_db_get_tls_address): New prototype.
20544 * remote-utils.c (decode_address): Make non-static.
20545 * server.c (handle_query): Handle qGetTLSAddr.
20546 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20547 * target.h (struct target_ops): Add get_tls_address.
20548 * thread-db.c (maybe_attach_thread): Save the thread handle.
20549 (thread_db_get_tls_address): New.
20550
20551 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20552
20553 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20554 (linux_resume_one_process): Take a siginfo_t *. Update all
20555 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20556 (struct pending_signals): Add a siginfo_t.
20557 (linux_wait_for_process): Always set last_status.
20558 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20559 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20560 * linux-low.h (struct process_info): Add last_status.
20561
20562 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20563
20564 * remote-utils.c (try_rle): New function.
20565 (putpkt_binary): Use it.
20566
20567 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20568
20569 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20570 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20571 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20572 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20573 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20574 point registers.
20575
20576 2006-08-08 Richard Sandiford <richard@codesourcery.com>
20577
20578 * server.c (terminal_fd): New variable.
20579 (old_foreground_pgrp): Likewise.
20580 (restore_old_foreground_pgrp): New function.
20581 (start_inferior): Record the terminal file descriptor in terminal_fd
20582 and its original foreground group in old_foreground_pgrp. Register
20583 restore_old_foreground_pgrp with atexit().
20584
20585 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20586
20587 * server.c (handle_query): Correct qPart to qXfer.
20588
20589 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20590
20591 * configure.ac: Check for more headers which are missing on
20592 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20593 * configure.srv: Add Cygwin and mingw32.
20594 * remote-utils.c: Don't include headers unconditionally which
20595 are missing on mingw32. Include <winsock.h> for mingw32.
20596 (remote_open): Adjust for mingw32 support. Flush
20597 standard error after writing to it.
20598 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20599 (unblock_async_io, enable_async_io, disable_async_io)
20600 (readchar, getpkt): Update for Winsock support.
20601 (prepare_resume_reply): Expect a protocol signal number.
20602 * server.c: Disable <sys/wait.h> on mingw32.
20603 (start_inferior): Adjust for mingw32 support. Flush
20604 standard error after writing to it.
20605 (attach_inferior): Likewise. Use protocol signal
20606 numbers.
20607 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20608 and names.
20609 * win32-i386-low.c: New file.
20610 * Makefile.in (XM_CLIBS): Set.
20611 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20612 (win32-i386-low.o): New dependency rule.
20613 * linux-low.c (linux_wait): Use target signal numbers.
20614 * target.h (struct target_ops): Doc fix.
20615 * server.h (target_signal_to_name): New prototype.
20616 * gdbreplay.c: Don't include headers unconditionally which
20617 are missing on mingw32. Include <winsock.h> for mingw32.
20618 (remote_close, remote_open): Adjust for Winsock support.
20619 * configure, config.in: Regenerated.
20620
20621 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20622
20623 * server.c (decode_xfer_read, write_qxfer_response): New.
20624 (handle_query): Take a packet length argument. Handle
20625 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20626 the qSupported response.
20627 (main): Update call to handle_query.
20628
20629 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20630
20631 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20632 (putpkt_binary): Renamed from putpkt and adjusted for binary
20633 data.
20634 (putpkt): New wrapper for putpkt_binary.
20635 (readchar): Don't mask off the high bit.
20636 (decode_X_packet): New function.
20637 * server.c (main): Call putpkt_binary if a handler sets the packet
20638 length. Save the length of the incoming packet. Handle 'X'.
20639 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20640
20641 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20642
20643 * server.c (handle_query): Handle qSupported.
20644
20645 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20646
20647 * remote-utils.c (all_symbols_looked_up): New variable.
20648 (look_up_one_symbol): Check it.
20649 * server.h (look_up_one_symbol): New declaration.
20650 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20651
20652 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20653
20654 * Makefile.in (linux-arm-low.o): Update dependencies.
20655 * linux-arm-low.c: Include "gdb_proc_service.h".
20656 (PTRACE_GET_THREAD_AREA): Define.
20657 (ps_get_thread_area): New function.
20658
20659 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20660
20661 * configure.srv (m68k*-*-uclinux*): New target.
20662 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20663 (linux_resume_one_process): Remove extraneous cast.
20664 (linux_read_offsets): New.
20665 (linux_target_op): Add linux_read_offsets on mmuless systems.
20666 * server.c (handle_query): Add qOffsets logic.
20667 * target.h (struct target_ops): Add read_offsets.
20668
20669 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20670
20671 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20672 (PTRACE_GET_THREAD_AREA): Define.
20673 (ps_get_thread_area): New function.
20674 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20675 (linux-x86-64-low.o): Update.
20676
20677 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20678
20679 * configure.ac: Remove checks for prfpregset_t.
20680 * gdb_proc_service.h: New file.
20681 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20682 new "gdb_proc_service.h".
20683 * proc-service.c: Likewise.
20684 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20685 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20686 * Makefile.in (gdb_proc_service_h): Updated.
20687 * configure, config.in: Regenerated.
20688
20689 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20690
20691 * remote-utils.c (prepare_resume_reply): Move declaration
20692 of gdb_id_from_wait to the top of the block.
20693
20694 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
20695
20696 * linux-low.c (regsets_store_inferior_registers): Read the regset
20697 from the target before filling it.
20698
20699 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20700
20701 * server.c (attach_inferior): Return SIGTRAP for a successful
20702 attach.
20703
20704 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
20705
20706 * Makefile.in (OBS): Add version.o.
20707 (STAGESTUFF): Delete.
20708 (version.o): Add dependencies.
20709 (version.c): Replace rule.
20710 (clean): Remove version.c.
20711 * server.c (gdbserver_version): New.
20712 (gdbserver_usage): Use printf.
20713 (main): Handle --version and --help.
20714 * server.h (version, host_name): Add declarations.
20715
20716 2005-12-23 Eli Zaretskii <eliz@gnu.org>
20717
20718 * linux-arm-low.c:
20719 * linux-arm-low.c:
20720 * inferiors.c:
20721 * i387-fp.h:
20722 * i387-fp.c:
20723 * gdbreplay.c:
20724 * regcache.c:
20725 * proc-service.c:
20726 * mem-break.h:
20727 * mem-break.c:
20728 * linux-x86-64-low.c:
20729 * linux-sh-low.c:
20730 * linux-s390-low.c:
20731 * linux-ppc64-low.c:
20732 * linux-ppc-low.c:
20733 * linux-mips-low.c:
20734 * linux-m68k-low.c:
20735 * linux-m32r-low.c:
20736 * linux-low.h:
20737 * linux-low.c:
20738 * linux-ia64-low.c:
20739 * linux-i386-low.c:
20740 * linux-crisv32-low.c:
20741 * thread-db.c:
20742 * terminal.h:
20743 * target.h:
20744 * target.c:
20745 * server.h:
20746 * server.c:
20747 * remote-utils.c:
20748 * regcache.h:
20749 * utils.c:
20750 * Makefile.in:
20751 * configure.ac:
20752 * gdbserver.1: Add (C) after Copyright. Update the FSF
20753 address.
20754
20755 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
20756
20757 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
20758 (arm_breakpoint_at): Recognize both breakpoints.
20759 (the_low_target): Use the correct breakpoint instruction.
20760
20761 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
20762
20763 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
20764 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
20765 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
20766 (the_low_target): Update.
20767
20768 2005-10-25 Andreas Schwab <schwab@suse.de>
20769
20770 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
20771
20772 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
20773 (ia64_num_regs): Reduce to 462.
20774
20775 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
20776
20777 * acinclude.m4: Correct quoting.
20778 * aclocal.m4: Regenerated.
20779
20780 Suggested by SZOKOVACS Robert <szo@ies.hu>:
20781 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
20782 (thread_db_init): Call thread_db_err_str.
20783 * configure.ac: Check for TD_VERSION.
20784 * config.in, configure: Regenerated.
20785
20786 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
20787
20788 * server.h (error, fatal, warning): Add ATTR_FORMAT.
20789
20790 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20791
20792 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
20793 is not available. Define HAVE_PTRACE_GETREGS if it is.
20794 * config.in, configure: Regenerated.
20795 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
20796 * linux-i386-low.c, linux-m68k-low.c: Update to use
20797 HAVE_PTRACE_GETREGS.
20798 * linux-low.c (regsets_fetch_inferior_registers)
20799 (regsets_store_inferior_registers): Only return 0 if we processed
20800 GENERAL_REGS.
20801 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
20802 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
20803
20804 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20805
20806 * inferiors.c (struct thread_info): Add gdb_id.
20807 (add_thread): Add gdb_id argument.
20808 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
20809 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
20810 calls to add_thread.
20811 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
20812 * server.c (handle_query): Use thread_to_gdb_id.
20813 (handle_v_cont, main): Use gdb_id_to_thread_id.
20814 * server.h (add_thread): Update prototype.
20815 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
20816 prototypes.
20817
20818 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20819
20820 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
20821 left-padded registers.
20822 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
20823 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
20824
20825 2005-07-01 Steve Ellcey <sje@cup.hp.com>
20826
20827 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
20828 * configure: Regenerate.
20829 * config.in: Regenerate.
20830 * server.h (NEED_DECLARATION_STRERROR):
20831 Replace with !HAVE_DECL_STRERROR.
20832
20833 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
20834
20835 * linux-low.c (linux_wait, linux_send_signal): Don't test
20836 an unsigned long variable for > 0 if it could be MAX_ULONG.
20837 * server.c (myresume): Likewise.
20838 * target.c (set_desired_inferior): Likewise.
20839
20840 2005-06-13 Mark Kettenis <kettenis@gnu.org>
20841
20842 * configure.ac: Simplify and improve check for socklen_t.
20843 * configure, config.in: Regenerate.
20844
20845 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
20846
20847 * acconfig.h: Remove.
20848 * configure.ac: Add a test for socklen_t. Use three-argument
20849 AC_DEFINE throughout.
20850 * config.in: Regenerated using autoheader 2.59.
20851 * configure: Regenerated.
20852
20853 * gdbreplay.c (socklen_t): Provide a default.
20854 (remote_open): Use socklen_t.
20855 * remote-utils.c (socklen_t): Provide a default.
20856 (remote_open): Use socklen_t.
20857 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
20858 unsigned char.
20859
20860 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
20861 char for buffers.
20862 * linux-low.c (linux_read_memory, linux_write_memory)
20863 (linux_read_auxv): Likewise.
20864 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
20865 (check_mem_write): Likewise.
20866 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
20867 Likewise.
20868 * regcache.c (struct inferior_rgcache_data, registers_to_string)
20869 (registers_from_string, register_data): Likewise.
20870 * server.c (handle_query, main): Likewise.
20871 * server.h (convert_ascii_to_int, convert_int_to_ascii)
20872 (decode_M_packet): Likewise.
20873 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
20874 * target.h (struct target_ops): Update read_memory, write_memory,
20875 and read_auxv.
20876 (read_inferior_memory, write_inferior_memory): Update.
20877 * linux-low.h (struct linux_target_ops): Change type of breakpoint
20878 to unsigned char *.
20879 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
20880 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
20881 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
20882 linux-s390-low.c, linux-sh-low.c: Update for changes in
20883 read_inferior_memory and the_low_target->breakpoint.
20884
20885 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
20886
20887 * Makefile.in (SFILES): Add linux-ppc64-low.c.
20888 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
20889 * configure.srv: Add powerpc64-*-linux*.
20890 * linux-ppc64-low.c: New file.
20891
20892 2005-05-23 Orjan Friberg <orjanf@axis.com>
20893
20894 * linux-cris-low.c: New file with support for CRIS.
20895 * linux-crisv32-low.c: Ditto for CRISv32.
20896 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
20897 (clean): Add reg-cris.c and reg-crisv32.c.
20898 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
20899 reg-crisv32.o, and reg-crisv32.c to make rules.
20900 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
20901 recognized targets.
20902
20903 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
20904
20905 * linux-low.c (fetch_register): Ensure buffer size is a multiple
20906 of sizeof (PTRACE_XFER_TYPE).
20907 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
20908
20909 2005-05-12 Orjan Friberg <orjanf@axis.com>
20910
20911 * target.h (struct target_ops): Add insert_watchpoint,
20912 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
20913 pointers for hardware watchpoint support.
20914 * linux-low.h (struct linux_target_ops): Ditto.
20915 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
20916 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
20917 to linux_target_ops.
20918 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
20919 reply packet.
20920 * server.c (main): Recognize 'Z' and 'z' packets.
20921
20922 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
20923
20924 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
20925 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
20926 (the_low_target): Add new members.
20927
20928 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
20929
20930 * proc-service.c (ps_lgetregs): Search all_processes instead of
20931 all_threads.
20932
20933 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
20934
20935 * server.c (start_inferior): Change return type to int.
20936 (attach_inferior): Change sigptr to int *.
20937 (handle_v_cont, handle_v_requests): Change signal to int *.
20938 (main): Change signal to int.
20939
20940 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
20941
20942 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
20943 * configure.srv: Add m32r*-*-linux*.
20944 * linux-m32r-low.c: New file.
20945
20946 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
20947
20948 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
20949
20950 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20951
20952 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
20953 Take unsigned long arguments for PIDs.
20954 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
20955 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
20956 (wait_for_sigstop, linux_resume_one_process)
20957 (regsets_fetch_inferior_registers, linux_send_signal)
20958 (linux_read_auxv): Likewise. Update the types of variables holding
20959 PIDs. Update format string specifiers.
20960 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
20961 * remote-utils.c (prepare_resume_reply): Likewise.
20962 * server.c (cont_thread, general_thread, step_thread)
20963 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
20964 unsigned long.
20965 (handle_query): Update format specifiers.
20966 (handle_v_cont, main): Use strtoul for thread IDs.
20967 * server.h (struct inferior_list_entry): Use unsigned long for ID.
20968 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
20969 (general_thread, step_thread, thread_from_wait)
20970 (old_thread_from_wait): Update.
20971 * target.h (struct thread_resume): Use unsigned long for THREAD.
20972 (struct target_ops): Use unsigned long for arguments to attach and
20973 thread_alive.
20974
20975 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
20976
20977 * acinclude.m4: Include bfd/bfd.m4 directly.
20978 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
20979 <agriffis@toolchain.org>.
20980 * aclocal.m4, configure: Regenerated.
20981
20982 2005-01-07 Andrew Cagney <cagney@gnu.org>
20983
20984 * configure.ac: Rename configure.in, require autoconf 2.59.
20985 * configure: Re-generate.
20986
20987 2004-12-08 Daniel Jacobowitz <dan@debian.org>
20988
20989 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
20990 LIBS when finished.
20991 * aclocal.m4: Regenerated.
20992 * configure: Regenerated.
20993
20994 2004-11-21 Andreas Schwab <schwab@suse.de>
20995
20996 * linux-m68k-low.c (m68k_num_gregs): Define.
20997 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
20998 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
20999 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21000 (m68k_breakpoint_at): New. Add to the_low_target.
21001
21002 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21003 srv_linux_thread_db to yes.
21004
21005 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21006
21007 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21008 (ARCH_SET_FS): Likewise.
21009 (ARCH_GET_FS): Likewise.
21010 (ARCH_GET_GS): Likewise.
21011
21012 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21013
21014 * linux-i386-low.c (ps_get_thread_area): New.
21015 * linux-x86-64-low.c (ps_get_thread_area): New.
21016 * linux-low.c: Include <sys/syscall.h>.
21017 (linux_kill_one_process): Don't kill the first thread here.
21018 (linux_kill): Kill the first thread here.
21019 (kill_lwp): New function.
21020 (send_sigstop, linux_send_signal): Use it.
21021 * proc-service.c: Clean up #ifdefs.
21022 (fpregset_info): Delete.
21023 (ps_lgetregs): Update and enable implementation.
21024 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21025 implementations.
21026 * remote-utils.c (struct sym_cache, symbol_cache): New.
21027 (input_interrupt): Print a clearer message.
21028 (async_io_enabled): New variable.
21029 (enable_async_io, disable_async_io): Use it. Update comments.
21030 (look_up_one_symbol): Use the symbol cache.
21031 * thread-db.c (thread_db_look_up_symbols): New function.
21032 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21033
21034 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21035
21036 * configure.in: Test for -rdynamic.
21037 * configure: Regenerated.
21038 * Makefile (INTERNAL_LDFLAGS): New.
21039 (gdbserver, gdbreplay): Use it.
21040
21041 2004-09-02 Andrew Cagney <cagney@gnu.org>
21042
21043 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21044
21045 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21046
21047 * linux-low.c (linux_wait): Clear all_processes list also.
21048
21049 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21050
21051 * linux-low.c: Include <errno.h>. Remove extern declaration of
21052 errno.
21053
21054 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21055
21056 * gdbreplay.c, server.h, utils.c: Update copyright years.
21057
21058 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21059
21060 * server.c (main): Print child status or termination signal from
21061 variable 'signal', not 'sig'.
21062
21063 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21064
21065 * linux-low.c (linux_read_memory): Change return type to
21066 int. Check for and return error from ptrace().
21067 * target.c (read_inferior_memory): Change return type to int. Pass
21068 back return status from the_target->read_memory().
21069 * target.h (struct target_ops): Adapt *read_memory() prototype.
21070 Update comment.
21071 (read_inferior_memory): Adapt prototype.
21072 * server.c (main): Return an error packet if
21073 read_inferior_memory() returns an error.
21074
21075 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21076
21077 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21078 Unify with other clean targets.
21079
21080 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21081
21082 * server.c (handle_v_cont): Call set_desired_inferior.
21083
21084 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21085
21086 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21087
21088 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21089
21090 * linux-low.c (linux_wait): Unblock async I/O.
21091 (linux_resume): Block and enable async I/O.
21092 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21093 * server.h (block_async_io, unblock_async_io): Add prototypes.
21094
21095 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21096
21097 * remote-utils.c (remote_open): Print a status notice after
21098 opening a TCP port.
21099 * server.c (attach_inferior): Print a status notice after
21100 attaching.
21101
21102 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21103
21104 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21105
21106 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21107
21108 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21109 error packet.
21110 * server.c, target.h: Update copyright years.
21111
21112 2004-02-25 Roland McGrath <roland@redhat.com>
21113
21114 * target.h (struct target_ops): New member `read_auxv'.
21115 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21116 * linux-low.c (linux_read_auxv): New function.
21117 (linux_target_ops): Initialize `read_auxv' member to that.
21118
21119 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21120
21121 Committed by Jim Blandy <jimb@redhat.com>.
21122
21123 * linux-s390-low.c (s390_num_regs): Update.
21124 (s390_regmap): Remove control registers. Use __s390x__ predefine
21125 instead of GPR_SIZE to distiguish s390 and s390x targets.
21126
21127 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21128
21129 * linux-low.c: Update copyright year.
21130 (check_removed_breakpoint): Clear pending_is_breakpoint.
21131 (linux_set_resume_request, linux_queue_one_thread)
21132 (resume_status_pending_p): New functions.
21133 (linux_continue_one_thread): Use process->resume.
21134 (linux_resume): Only resume threads if there are no pending events.
21135 * linux-low.h (struct process_info): Add resume request
21136 pointer.
21137
21138 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21139
21140 * regcache.c (new_register_cache): Clear the allocated register
21141 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21142
21143 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21144
21145 * linux-low.c (linux_resume): Take a struct thread_resume *
21146 argument.
21147 (linux_wait): Update call.
21148 (resume_ptr): New static variable.
21149 (linux_continue_one_thread): Renamed from
21150 linux_continue_one_process. Use resume_ptr.
21151 (linux_resume): Use linux_continue_one_thread.
21152 * server.c (handle_v_cont, handle_v_requests): New functions.
21153 (myresume): New function.
21154 (main): Handle 'v' case.
21155 * target.h (struct thread_resume): New type.
21156 (struct target_ops): Change argument of "resume" to struct
21157 thread_resume *.
21158 (myresume): Delete macro.
21159
21160 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21161
21162 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21163 (uninstall): Support DESTDIR.
21164
21165 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21166
21167 * configure.srv: Add xscale*linux copy of arm*linux entry.
21168
21169 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21170
21171 * linux-arm-low.c (arm_reinsert_addr): New function.
21172 (the_low_target): Add arm_reinsert_addr.
21173
21174 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21175
21176 * mem-break.c: Remove whitespace at end of file.
21177
21178 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21179
21180 * configure.in: Check whether we need to prototype strerror.
21181 * server.h: Optionally prototype strerror.
21182 * gdbreplay.c (perror_with_name): Use strerror.
21183 * linux-low.c (linux_attach_lwp): Use strerror.
21184 * utils.c (perror_with_name): Use strerror.
21185 * config.in, configure: Regenerated.
21186
21187 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21188
21189 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21190 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21191
21192 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21193
21194 * Makefile.in (SFILES): Update.
21195 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21196 low-sun3.c: Remove files.
21197
21198 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21199
21200 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21201 (linux_detach_one_process, linux_detach): New functions.
21202 (linux_target_ops): Add linux_detach.
21203 * server.c (main): Handle 'D' packet.
21204 * target.h (struct target_ops): Add "detach" member.
21205 (detach_inferior): Define.
21206
21207 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21208
21209 From Kelley Cook <kelleycook@wideopenwest.com>:
21210 * configure.srv: Accept i[34567]86 variants.
21211
21212 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21213
21214 * linux-low.c (linux_wait_for_event): Correct comment typos.
21215 (linux_resume_one_process): Call check_removed_breakpoint.
21216 (linux_send_signal): New function.
21217 (linux_target_ops): Add linux_send_signal.
21218 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21219 of kill.
21220 * target.h (struct target_ops): Add send_signal.
21221
21222 2003-05-29 Jim Blandy <jimb@redhat.com>
21223
21224 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21225 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21226 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21227 away part of the register's value.
21228
21229 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21230
21231 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21232 (linux_wait_for_event, linux_init_signals): Likewise.
21233
21234 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21235
21236 * configure.in: Check for stdlib.h.
21237 * configure: Regenerated.
21238 * config.in: Regenerated.
21239
21240 2003-01-04 Andreas Schwab <schwab@suse.de>
21241
21242 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21243
21244 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21245
21246 * Makefile.in: Remove obsolete code.
21247
21248 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21249
21250 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21251 defined(PT_FPR0_HI).
21252
21253 2002-11-17 Stuart Hughes <seh@zee2.com>
21254
21255 * linux-arm-low.c (arm_num_regs): Increase.
21256 (arm_regmap): Include status register.
21257
21258 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21259
21260 * linux-low.c (register_addr): Remove incorrect -1 check.
21261
21262 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21263
21264 * linux-low.c (linux_create_inferior): Call setpgid. Return
21265 the new PID.
21266 (unstopped_p, linux_signal_pid): Remove.
21267 (linux_target_ops): Remove linux_signal_pid.
21268 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21269 global instead of target method.
21270 * target.h (struct target_ops): Remove signal_pid. Update comment
21271 for create_inferior.
21272 * server.c (signal_pid): New variable.
21273 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21274 gdbserver. Set the child to be the foreground process group.
21275 (attach_inferior): Set signal_pid.
21276
21277 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21278
21279 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21280
21281 2002-08-20 Jim Blandy <jimb@redhat.com>
21282
21283 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21284 default for this.
21285
21286 2002-08-01 Andrew Cagney <cagney@redhat.com>
21287
21288 * Makefile.in: Make chill references obsolete.
21289
21290 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21291
21292 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21293 * configure: Regenerate.
21294 * config.in: Regenerate.
21295
21296 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21297
21298 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21299 (perror_with_name, remote_close, remote_open, expect, play): Static.
21300
21301 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21302
21303 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
21304 byte offsets instead of an array of indexes.
21305 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21306
21307 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
21308
21309 * regcache.c: Add comment.
21310
21311 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
21312
21313 * thread-db.c: New file.
21314 * proc-service.c: New file.
21315 * acinclude.m4: New file.
21316 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21317 proc-service.o, and thread-db.o.
21318 (linux-low.o): Add USE_THREAD_DB.
21319 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21320 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21321 * aclocal.m4: Regenerated.
21322 * config.in: Regenerated.
21323 * configure: Regenerated.
21324 * configure.in: Check for proc_service.h, sys/procfs.h,
21325 thread_db.h, and linux/elf.h headrs.
21326 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21327 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21328 Check for -lthread_db and thread support.
21329 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21330 PowerPC, and SuperH.
21331 * i387-fp.c: Constify arguments.
21332 * i387-fp.h: Likewise.
21333 * inferiors.c: (struct thread_info): Renamed from
21334 `struct inferior_info'. Remove PID member. Use generic inferior
21335 list header. All uses updated.
21336 (inferiors, signal_pid): Removed.
21337 (all_threads): New variable.
21338 (get_thread): Define.
21339 (add_inferior_to_list): New function.
21340 (for_each_inferior): New function.
21341 (change_inferior_id): New function.
21342 (add_inferior): Removed.
21343 (remove_inferior): New function.
21344 (add_thread): New function.
21345 (free_one_thread): New function.
21346 (remove_thread): New function.
21347 (clear_inferiors): Use for_each_inferior and free_one_thread.
21348 (find_inferior): New function.
21349 (find_inferior_id): New function.
21350 (inferior_target_data): Update argument type.
21351 (set_inferior_target_data): Likewise.
21352 (inferior_regcache_data): Likewise.
21353 (set_inferior_regcache_data): Likewise.
21354 * linux-low.c (linux_bp_reinsert): Remove.
21355 (all_processes, stopping_threads, using_thrads)
21356 (struct pending_signals, debug_threads, pid_of): New.
21357 (inferior_pid): Replace with macro.
21358 (struct inferior_linux_data): Remove.
21359 (get_stop_pc, add_process): New functions.
21360 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21361 Use add_process and add_thread.
21362 (linux_attach_lwp): New function, based on old linux_attach. Use
21363 add_process and add_thread. Set stop_expected for new threads.
21364 (linux_attach): New function.
21365 (linux_kill_one_process): New function.
21366 (linux_kill): Kill all LWPs.
21367 (linux_thread_alive): Use find_inferior_id.
21368 (check_removed_breakpoints, status_pending_p): New functions.
21369 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21370 Update. Use WNOHANG. Wait for cloned processes also. Update process
21371 struct for the found process.
21372 (linux_wait_for_event): New function.
21373 (linux_wait): Use it. Support LWPs.
21374 (send_sigstop, wait_for_sigstop, stop_all_processes)
21375 (linux_resume_one_process, linux_continue_one_process): New functions.
21376 (linux_resume): Support LWPs.
21377 (REGISTER_RAW_SIZE): Remove.
21378 (fetch_register): Use register_size instead. Call supply_register.
21379 (usr_store_inferior_registers): Likewise. Call collect_register.
21380 Fix recursive case.
21381 (regsets_fetch_inferior_registers): Improve error message.
21382 (regsets_store_inferior_registers): Add debugging.
21383 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21384 (unstopped_p, linux_signal_pid): New functions.
21385 (linux_target_ops): Add linux_signal_pid.
21386 (linux_init_signals): New function.
21387 (initialize_low): Call it. Initialize using_threads.
21388 * regcache.c (inferior_regcache_data): Add valid
21389 flag.
21390 (get_regcache): Fetch registers lazily. Add fetch argument
21391 and update all callers.
21392 (regcache_invalidate_one, regcache_invalidate): New
21393 functions.
21394 (new_register_cache): Renamed from create_register_cache.
21395 Return the new regcache.
21396 (free_register_cache): Change argument to a void *.
21397 (registers_to_string, registers_from_string): Call get_regcache
21398 with fetch flag set.
21399 (register_data): Make static. Pass fetch flag to get_regcache.
21400 (supply_register): Call get_regcache with fetch flag clear.
21401 (collect_register): Call get_regcache with fetch flag set.
21402 (collect_register_as_string): New function.
21403 * regcache.h: Update.
21404 * remote-utils.c (putpkt): Flush after debug output and use
21405 stderr.
21406 Handle input interrupts while waiting for an ACK.
21407 (input_interrupt): Use signal_pid method.
21408 (getpkt): Flush after debug output and use stderr.
21409 (outreg): Use collect_register_as_string.
21410 (new_thread_notify, dead_thread_notify): New functions.
21411 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21412 and general_thread.
21413 (look_up_one_symbol): Flush after debug output.
21414 * server.c (step_thread, server_waiting): New variables.
21415 (start_inferior): Don't use signal_pid. Update call to mywait.
21416 (attach_inferior): Update call to mywait.
21417 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21418 (main): Don't fetch/store registers explicitly. Use
21419 set_desired_inferior. Support proposed ``Hs'' packet. Update
21420 calls to mywait.
21421 * server.h: Update.
21422 (struct inferior_list, struct_inferior_list_entry): New.
21423 * target.c (set_desired_inferior): New.
21424 (write_inferior_memory): Constify.
21425 (mywait): New function.
21426 * target.h: Update.
21427 (struct target_ops): New signal_pid method.
21428 (mywait): Removed macro, added prototype.
21429
21430 * linux-low.h (regset_func): Removed.
21431 (regset_fill_func, regset_store_func): New.
21432 (enum regset_type): New.
21433 (struct regset_info): Add type field. Use new operation types.
21434 (struct linux_target_ops): stop_pc renamed to get_pc.
21435 Add decr_pc_after_break and breakpoint_at.
21436 (get_process, get_thread_proess, get_process_thread)
21437 (strut process_info, all_processes, linux_attach_lwp)
21438 (thread_db_init): New.
21439
21440 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21441 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21442 (the_low_target): Add new members.
21443 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21444 (i386_store_fpxregset): Constify.
21445 (target_regsets): Add new kind identifier.
21446 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21447 (i386_set_pc): Add debugging.
21448 (i386_breakpoint_at): New function.
21449 (the_low_target): Add new members.
21450 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21451 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21452 (mips_breakpoint_at): New.
21453 (the_low_target): Add new members.
21454 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21455 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21456 (the_low_target): Add new members.
21457 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21458 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21459 (the_low_target): Add new members.
21460 * linux-x86-64-low.c (target_regsets): Add new kind
21461 identifier.
21462
21463 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
21464
21465 From Martin Pool <mbp@samba.org>:
21466 * server.c (gdbserver_usage): New function.
21467 (main): Call it.
21468
21469 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
21470
21471 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21472 stop_at -> stop_pc.
21473
21474 2002-05-04 Andrew Cagney <ac131313@redhat.com>
21475
21476 * Makefile.in: Remove obsolete code.
21477
21478 2002-04-24 Michal Ludvig <mludvig@suse.cz>
21479
21480 * linux-low.c (regsets_fetch_inferior_registers),
21481 (regsets_store_inferior_registers): Removed cast to int from
21482 ptrace() calls.
21483 * regcache.h: Added declaration of struct inferior_info.
21484
21485 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21486
21487 * inferiors.c (struct inferior_info): Add regcache_data.
21488 (add_inferior): Call create_register_cache.
21489 (clear_inferiors): Call free_register_cache.
21490 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21491 * regcache.c (struct inferior_regcache_data): New.
21492 (registers): Remove.
21493 (get_regcache): New function.
21494 (create_register_cache, free_register_cache): New functions.
21495 (set_register_cache): Don't initialize the register cache here.
21496 (registers_to_string, registers_from_string, register_data): Call
21497 get_regcache.
21498 * regcache.h: Add prototypes.
21499 * server.h: Likewise.
21500
21501 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21502
21503 * mem-break.c: New file.
21504 * mem-break.h: New file.
21505 * Makefile.in: Add mem-break.o rule; update server.h
21506 dependencies.
21507 * inferiors.c (struct inferior_info): Add target_data
21508 member.
21509 (clear_inferiors): Free target_data member if set.
21510 (inferior_target_data, set_inferior_target_data): New functions.
21511 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21512 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21513 * linux-low.c (linux_bp_reinsert): New variable.
21514 (struct inferior_linux_data): New.
21515 (linux_create_inferior): Use set_inferior_target_data.
21516 (linux_attach): Likewise. Call add_inferior.
21517 (linux_wait_for_one_inferior): New function.
21518 (linux_wait): Call it.
21519 (linux_write_memory): Add const.
21520 (initialize_low): Call set_breakpoint_data.
21521 * linux-low.h (struct linux_target_ops): Add breakpoint
21522 handling members.
21523 * server.c (attach_inferior): Remove extra add_inferior
21524 call.
21525 * server.h: Include mem-break.h. Update inferior.c
21526 prototypes.
21527 * target.c (read_inferior_memory)
21528 (write_inferior_memory): New functions.
21529 * target.h (read_inferior_memory)
21530 (write_inferior_memory): Change macros to prototypes.
21531 (struct target_ops): Update comments. Add const to write_memory
21532 definition.
21533
21534 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
21535
21536 * linux-low.c (usr_store_inferior_registers): Support
21537 registers which are allowed to fail to store.
21538 * linux-low.h (linux_target_ops): Likewise.
21539 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21540 (ppc_cannot_store_register): FPSCR may not be storable.
21541
21542 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21543
21544 * server.h: Include <string.h> if HAVE_STRING_H.
21545 * ChangeLog: Correct paths in last ChangeLog entry.
21546
21547 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21548
21549 * linux-low.h: Remove obsolete prototypes.
21550 (struct linux_target_ops): New.
21551 (extern the_low_target): New.
21552 * linux-low.c (num_regs, regmap): Remove declarations.
21553 (register_addr): Use the_low_target explicitly.
21554 (fetch_register): Likewise.
21555 (usr_fetch_inferior_registers): Likewise.
21556 (usr_store_inferior_registers): Likewise.
21557 * linux-arm-low.c (num_regs): Remove.
21558 (arm_num_regs): Define.
21559 (arm_regmap): Renamed from regmap, made static.
21560 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21561 made static.
21562 (arm_cannot_store_register): Renamed from cannot_store_register,
21563 made static.
21564 (the_low_target): New.
21565 * linux-i386-low.c (num_regs): Remove.
21566 (i386_num_regs): Define.
21567 (i386_regmap): Renamed from regmap, made static.
21568 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21569 made static.
21570 (i386_cannot_store_register): Renamed from cannot_store_register,
21571 made static.
21572 (the_low_target): New.
21573 * linux-ia64-low.c (num_regs): Remove.
21574 (ia64_num_regs): Define.
21575 (ia64_regmap): Renamed from regmap, made static.
21576 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21577 made static.
21578 (ia64_cannot_store_register): Renamed from cannot_store_register,
21579 made static.
21580 (the_low_target): New.
21581 * linux-m68k-low.c (num_regs): Remove.
21582 (m68k_num_regs): Define.
21583 (m68k_regmap): Renamed from regmap, made static.
21584 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21585 made static.
21586 (m68k_cannot_store_register): Renamed from cannot_store_register,
21587 made static.
21588 (the_low_target): New.
21589 * linux-mips-low.c (num_regs): Remove.
21590 (mips_num_regs): Define.
21591 (mips_regmap): Renamed from regmap, made static.
21592 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21593 made static.
21594 (mips_cannot_store_register): Renamed from cannot_store_register,
21595 made static.
21596 (the_low_target): New.
21597 * linux-ppc-low.c (num_regs): Remove.
21598 (ppc_num_regs): Define.
21599 (ppc_regmap): Renamed from regmap, made static.
21600 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21601 made static.
21602 (ppc_cannot_store_register): Renamed from cannot_store_register,
21603 made static.
21604 (the_low_target): New.
21605 * linux-s390-low.c (num_regs): Remove.
21606 (s390_num_regs): Define.
21607 (s390_regmap): Renamed from regmap, made static.
21608 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21609 made static.
21610 (s390_cannot_store_register): Renamed from cannot_store_register,
21611 made static.
21612 (the_low_target): New.
21613 * linux-sh-low.c (num_regs): Remove.
21614 (sh_num_regs): Define.
21615 (sh_regmap): Renamed from regmap, made static.
21616 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21617 made static.
21618 (sh_cannot_store_register): Renamed from cannot_store_register,
21619 made static.
21620 (the_low_target): New.
21621 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21622 (the_low_target): New.
21623
21624 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21625
21626 * Makefile.in: Add stamp-h target.
21627 * configure.in: Create stamp-h.
21628 * configure: Regenerated.
21629
21630 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21631
21632 * inferiors.c: New file.
21633 * target.c: New file.
21634 * target.h: New file.
21635 * Makefile.in: Add target.o and inferiors.o. Update
21636 dependencies.
21637 * linux-low.c (inferior_pid): New static variable,
21638 moved from server.c.
21639 (linux_create_inferior): Renamed from create_inferior.
21640 Call add_inferior. Return 0 on success instead of a PID.
21641 (linux_attach): Renamed from myattach.
21642 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21643 (linux_thread_alive): Renamed from mythread_alive.
21644 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21645 child dies.
21646 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21647 (regsets_store_inferior_registers): Correct error message.
21648 Add missing ``return 0''.
21649 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21650 (linux_store_registers): Renamed from store_inferior_registers.
21651 (linux_read_memory): Renamed from read_inferior_memory.
21652 (linux_write_memory): Renamed from write_inferior_memory.
21653 (linux_target_ops): New structure.
21654 (initialize_low): Call set_target_ops ().
21655 * remote-utils.c (unhexify): New function.
21656 (hexify): New function.
21657 (input_interrupt): Send signals to ``signal_pid''.
21658 * server.c (inferior_pid): Remove.
21659 (start_inferior): Update create_inferior call.
21660 (attach_inferior): Call add_inferior.
21661 (handle_query): New function.
21662 (main): Call handle_query for `q' packets.
21663 * server.h: Include "target.h". Remove obsolete prototypes.
21664 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21665
21666 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21667
21668 * Makefile.in: Add WARN_CFLAGS. Update configury
21669 dependencies.
21670 * configure.in: Check for <string.h>
21671 * configure: Regenerate.
21672 * config.in: Regenerate.
21673 * gdbreplay.c: Include needed system headers.
21674 (remote_open): Remove strchr prototype.
21675 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21676 * regcache.c (supply_register): Change buf argument to const void *.
21677 (supply_register_by_name): Likewise.
21678 (collect_register): Change buf argument to void *.
21679 (collect_register_by_name): Likewise.
21680 * regcache.h: Add missing prototypes.
21681 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21682 * server.c (handle_query): New function.
21683 (attached): New static variable, moved out of main.
21684 (main): Quiet longjmp clobber warnings.
21685 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21686 * utils.c (error): Remove NORETURN.
21687 (fatal): Likewise.
This page took 0.786161 seconds and 3 git commands to generate.