]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdbserver/ChangeLog
gdbserver/linux-low: turn 'emit_ops' into a method
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
ab64c999
TBA
12020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2
3 Remove the 'emit_ops' linux target ops and let the concrete
4 linux target define the op by overriding the declaration of
5 process_stratum_target.
6
7 * linux-low.h (struct linux_target_ops): Remove the op.
8 (class linux_process_target) <emit_ops>: Remove.
9 * linux-low.cc (linux_process_target::emit_ops): Remove.
10 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
11 (x86_emit_ops): Turn into...
12 (x86_target::emit_ops): ...this.
13 (the_low_target): Remove the op field.
14 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
15 (aarch64_emit_ops): Turn into...
16 (aarch64_target::emit_ops): ...this.
17 (the_low_target): Remove the op field.
18 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
19 (ppc_emit_ops): Turn into...
20 (ppc_target::emit_ops): ...this.
21 (the_low_target): Remove the op field.
22 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
23 (s390_emit_ops): Turn into...
24 (s390_target::emit_ops): ...this.
25 (the_low_target): Remove the op field.
26 * linux-arm-low.cc (the_low_target): Remove the op field.
27 * linux-bfin-low.cc (the_low_target): Ditto.
28 * linux-crisv32-low.cc (the_low_target): Ditto.
29 * linux-m32r-low.cc (the_low_target): Ditto.
30 * linux-m68k-low.cc (the_low_target): Ditto.
31 * linux-sh-low.cc (the_low_target): Ditto.
32 * linux-tic6x-low.cc (the_low_target): Ditto.
33 * linux-tile-low.cc (the_low_target): Ditto.
34 * linux-xtensa-low.cc (the_low_target): Ditto.
35
809a0c35
TBA
362020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
37
38 Remove the 'install_fast_tracepoint_jump_pad' and
39 'get_min_fast_tracepoint_insn_len' linux target ops to let the
40 concrete linux target define the ops by overriding the declarations
41 of process_stratum_target.
42
43 * linux-low.h (struct linux_target_ops): Remove the ops.
44 (class linux_process_target) <supports_fast_tracepoints>
45 <install_fast_tracepoint_jump_pad>
46 <get_min_fast_tracepoint_insn_len>: Remove.
47 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
48 (linux_process_target::install_fast_tracepoint_jump_pad)
49 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
50 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
51 <install_fast_tracepoint_jump_pad>
52 <get_min_fast_tracepoint_insn_len>: Declare.
53 (x86_target::supports_fast_tracepoints): Define.
54 (x86_install_fast_tracepoint_jump_pad): Turn into...
55 (x86_target::install_fast_tracepoint_jump_pad): ...this.
56 (x86_get_min_fast_tracepoint_insn_len): Turn into...
57 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
58 (the_low_target): Remove the op fields.
59 * linux-aarch64-low.cc (class aarch64_target)
60 <supports_fast_tracepoints>
61 <install_fast_tracepoint_jump_pad>
62 <get_min_fast_tracepoint_insn_len>: Declare.
63 (aarch64_target::supports_fast_tracepoints): Define.
64 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
65 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
66 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
67 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
68 (the_low_target): Remove the op fields.
69 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
70 <install_fast_tracepoint_jump_pad>
71 <get_min_fast_tracepoint_insn_len>: Declare.
72 (ppc_target::supports_fast_tracepoints): Define.
73 (ppc_install_fast_tracepoint_jump_pad): Turn into...
74 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
75 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
76 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
77 (the_low_target): Remove the op fields.
78 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
79 <install_fast_tracepoint_jump_pad>
80 <get_min_fast_tracepoint_insn_len>: Declare.
81 (s390_target::supports_fast_tracepoints): Define.
82 (s390_install_fast_tracepoint_jump_pad): Turn into...
83 (s390_target::install_fast_tracepoint_jump_pad): ...this.
84 (s390_get_min_fast_tracepoint_insn_len): Turn into...
85 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
86 (the_low_target): Remove the op fields.
87 * linux-arm-low.cc (the_low_target): Remove the op fields.
88 * linux-bfin-low.cc (the_low_target): Ditto.
89 * linux-crisv32-low.cc (the_low_target): Ditto.
90 * linux-m32r-low.cc (the_low_target): Ditto.
91 * linux-m68k-low.cc (the_low_target): Ditto.
92 * linux-sh-low.cc (the_low_target): Ditto.
93 * linux-tic6x-low.cc (the_low_target): Ditto.
94 * linux-tile-low.cc (the_low_target): Ditto.
95 * linux-xtensa-low.cc (the_low_target): Ditto.
96
13e567af
TBA
972020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
98
99 Turn the 'get_thread_area' linux target op into a method of
100 process_stratum_target.
101
102 * linux-low.h (struct linux_target_ops): Remove the op.
103 (class linux_process_target) <stuck_in_jump_pad>
104 <linux_fast_tracepoint_collecting>
105 <low_get_thread_area>: Declare.
106 * linux-low.cc (supports_fast_tracepoints): Remove.
107 (linux_fast_tracepoint_collecting): Turn into...
108 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
109 (linux_process_target::low_get_thread_area): Define.
110 (stuck_in_jump_pad_callback): Turn into...
111 (linux_process_target::stuck_in_jump_pad): ...this.
112
113 Update the caller below.
114
115 (linux_process_target::stabilize_threads)
116
117 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
118 Declare.
119 (x86_get_thread_area): Turn into...
120 (x86_target::low_get_thread_area): ...this.
121 (the_low_target): Remove the op field.
122 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
123 Declare.
124 (aarch64_get_thread_area): Turn into...
125 (aarch64_target::low_get_thread_area): ...this.
126 (the_low_target): Remove the op field.
127 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
128 Declare.
129 (ppc_get_thread_area): Turn into...
130 (ppc_target::low_get_thread_area): ...this.
131 (the_low_target): Remove the op field.
132 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
133 Declare.
134 (s390_get_thread_area): Turn into...
135 (s390_target::low_get_thread_area): ...this.
136 (the_low_target): Remove the op field.
137 * linux-arm-low.cc (the_low_target): Remove the op field.
138 * linux-bfin-low.cc (the_low_target): Ditto.
139 * linux-crisv32-low.cc (the_low_target): Ditto.
140 * linux-m32r-low.cc (the_low_target): Ditto.
141 * linux-m68k-low.cc (the_low_target): Ditto.
142 * linux-sh-low.cc (the_low_target): Ditto.
143 * linux-tic6x-low.cc (the_low_target): Ditto.
144 * linux-tile-low.cc (the_low_target): Ditto.
145 * linux-xtensa-low.cc (the_low_target): Ditto.
146
47f70aa7
TBA
1472020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
148
149 Remote the 'supports_tracepoints' linux target op and let the
150 concrete linux target define it by overriding the op declared in
151 process_stratum_target.
152
153 * linux-low.h (struct linux_target_ops): Remove the op.
154 (class linux_process_target) <supports_tracepoints>: Remove.
155 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
156 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
157 Declare.
158 (x86_supports_tracepoints): Turn into...
159 (x86_target::supports_tracepoints): ...this.
160 (the_low_target): Remove the op field.
161 * linux-aarch64-low.cc (class aarch64_target)
162 <supports_tracepoints>: Declare.
163 (aarch64_supports_tracepoints): Turn into...
164 (aarch64_target::supports_tracepoints): ...this.
165 (the_low_target): Remove the op field.
166 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
167 Declare.
168 (ppc_supports_tracepoints): Turn into...
169 (ppc_target::supports_tracepoints): ...this.
170 (the_low_target): Remove the op field.
171 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
172 Declare.
173 (s390_supports_tracepoints): Turn into...
174 (s390_target::supports_tracepoints): ...this.
175 (the_low_target): Remove the op field.
176 * linux-arm-low.cc (the_low_target): Remove the op field.
177 * linux-bfin-low.cc (the_low_target): Ditto.
178 * linux-crisv32-low.cc (the_low_target): Ditto.
179 * linux-m32r-low.cc (the_low_target): Ditto.
180 * linux-m68k-low.cc (the_low_target): Ditto.
181 * linux-sh-low.cc (the_low_target): Ditto.
182 * linux-tic6x-low.cc (the_low_target): Ditto.
183 * linux-tile-low.cc (the_low_target): Ditto.
184 * linux-xtensa-low.cc (the_low_target): Ditto.
185
a5b5da92
TBA
1862020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
187
188 Remove the 'process_qsupported' linux target op and let a concrete
189 linux target define the op by overriding the op declaration in
190 process_stratum_target.
191
192 * linux-low.h (struct linux_target_ops): Remove the op.
193 (class linux_process_target) <process_qsupported>: Remove.
194 * linux-low.cc (linux_process_target::process_qsupported): Remove.
195 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
196 (x86_linux_process_qsupported): Turn into...
197 (x86_target::process_qsupported): ...this.
198 (the_low_target): Remove the op field.
199 * linux-aarch64-low.cc (the_low_target): Remove the op
200 field.
201 * linux-arm-low.cc (the_low_target): Ditto.
202 * linux-bfin-low.cc (the_low_target): Ditto.
203 * linux-crisv32-low.cc (the_low_target): Ditto.
204 * linux-m32r-low.cc (the_low_target): Ditto.
205 * linux-m68k-low.cc (the_low_target): Ditto.
206 * linux-ppc-low.cc (the_low_target): Ditto.
207 * linux-s390-low.cc (the_low_target): Ditto.
208 * linux-sh-low.cc (the_low_target): Ditto.
209 * linux-tic6x-low.cc (the_low_target): Ditto.
210 * linux-tile-low.cc (the_low_target): Ditto.
211 * linux-xtensa-low.cc (the_low_target): Ditto.
212
d7599cc0
TBA
2132020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
214
215 Turn the 'prepare_to_resume' linux target op into a method of
216 linux_process_target.
217
218 * linux-low.h (struct linux_target_ops): Remove the op.
219 (class linux_process_target) <low_prepare_to_resume>: Declare.
220 * linux-low.cc (linux_process_target::low_prepare_to_resume):
221 Define.
222
223 Update the callers below:
224
225 (linux_process_target::resume_one_lwp_throw)
226 (linux_process_target::low_prepare_to_resume)
227
228 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
229 Declare.
230 (x86_target::low_prepare_to_resume): Define.
231 (the_low_target): Remove the op field.
232 * linux-aarch64-low.cc (class aarch64_target)
233 <low_prepare_to_resume>: Declare.
234 (aarch64_target::low_prepare_to_resume): Define.
235 (the_low_target): Remove the op field.
236 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
237 Declare.
238 (arm_prepare_to_resume): Turn into...
239 (arm_target::low_prepare_to_resume): ...this.
240 (the_low_target): Remove the op field.
241 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
242 Declare.
243 (mips_linux_prepare_to_resume): Turn into...
244 (mips_target::low_prepare_to_resume): ...this.
245 (the_low_target): Remove the op field.
246 * linux-bfin-low.cc (the_low_target): Remove the op field.
247 * linux-crisv32-low.cc (the_low_target): Ditto.
248 * linux-m32r-low.cc (the_low_target): Ditto.
249 * linux-m68k-low.cc (the_low_target): Ditto.
250 * linux-ppc-low.cc (the_low_target): Ditto.
251 * linux-s390-low.cc (the_low_target): Ditto.
252 * linux-sh-low.cc (the_low_target): Ditto.
253 * linux-tic6x-low.cc (the_low_target): Ditto.
254 * linux-tile-low.cc (the_low_target): Ditto.
255 * linux-xtensa-low.cc (the_low_target): Ditto.
256
fd000fb3
TBA
2572020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
258
259 Turn the 'new_process', 'delete_process', 'new_thread',
260 'delete_thread', and 'new_fork' linux target ops into methods
261 of linux_process_target.
262
263 * linux-low.h (struct linux_target_ops): Remove the ops.
264 (class linux_process_target) <add_linux_process>
265 <add_lwp>
266 <delete_lwp>
267 <attach_lwp>
268 <detach_one_lwp>
269 <check_zombie_leaders>
270 <filter_exit_event>
271 <low_new_process>
272 <low_delete_process>
273 <low_new_thread>
274 <low_delete_thread>
275 <low_new_fork>: Declare.
276 * linux-low.cc (delete_lwp): Turn into...
277 (linux_process_target::delete_lwp): ...this.
278 (linux_process_target::low_delete_thread): Define.
279 (linux_add_process): Turn into...
280 (linux_process_target::add_linux_process): ...this.
281 (linux_process_target::low_new_process): Define.
282 (linux_process_target::low_delete_process): Define.
283 (linux_process_target::low_new_fork): Define.
284 (add_lwp): Turn into...
285 (linux_process_target::add_lwp): ...this.
286 (linux_process_target::low_new_thread): Define.
287 (linux_attach_lwp): Turn into...
288 (linux_process_target::attach_lwp): ...this.
289 (linux_detach_one_lwp): Turn into...
290 (linux_process_target::detach_one_lwp): ...this.
291 (linux_detach_lwp_callback): Remove and inline...
292 (linux_process_target::detach): ...here.
293 (check_zombie_leaders): Turn into...
294 (linux_process_target::check_zombie_leaders): ...this.
295 (filter_exit_event): Turn into...
296 (linux_process_target::filter_exit_event): ...this.
297
298 Update the callers below.
299
300 (linux_process_target::handle_extended_wait)
301 (linux_process_target::create_inferior)
302 (attach_proc_task_lwp_callback)
303 (linux_process_target::attach)
304 (linux_process_target::detach)
305 (linux_process_target::mourn)
306 * thread-db.cc (attach_thread)
307
308 * linux-x86-low.cc (class x86_target) <low_new_process>
309 <low_delete_process>
310 <low_new_thread>
311 <low_delete_thread>
312 <low_new_fork>: Declare.
313 (x86_linux_new_process): Turn into...
314 (x86_target::low_new_process): ...this.
315 (x86_linux_delete_process): Turn into...
316 (x86_target::low_delete_process): ...this.
317 (x86_target::low_new_thread): Define.
318 (x86_target::low_delete_thread): Define.
319 (x86_linux_new_fork): Turn into...
320 (x86_target::low_new_fork): ...this.
321 (the_low_target): Remove the op fields.
322 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
323 <low_delete_process>
324 <low_new_thread>
325 <low_delete_thread>
326 <low_new_fork>: Declare.
327 (aarch64_linux_new_process): Turn into...
328 (aarch64_target::low_new_process): ...this.
329 (aarch64_linux_delete_process): Turn into...
330 (aarch64_target::low_delete_process): ...this.
331 (aarch64_target::low_new_thread): Define.
332 (aarch64_target::low_delete_thread): Define.
333 (aarch64_linux_new_fork): Turn into...
334 (aarch64_target::low_new_fork): ...this.
335 (the_low_target): Remove the op fields.
336 * linux-arm-low.cc (class arm_target) <low_new_process>
337 <low_delete_process>
338 <low_new_thread>
339 <low_delete_thread>
340 <low_new_fork>: Declare.
341 (arm_new_process): Turn into...
342 (arm_target::low_new_process): ...this.
343 (arm_delete_process): Turn into...
344 (arm_target::low_delete_process): ...this.
345 (arm_new_thread): Turn into...
346 (arm_target::low_new_thread): ...this.
347 (arm_delete_thread): Turn into...
348 (arm_target::low_delete_thread): ...this.
349 (arm_new_fork): Turn into...
350 (arm_target::low_new_fork): ...this.
351 (the_low_target): Remove the op fields.
352 * linux-mips-low.cc (class mips_target) <low_new_process>
353 <low_delete_process>
354 <low_new_thread>
355 <low_delete_thread>
356 <low_new_fork>: Declare.
357 (mips_linux_new_process): Turn into...
358 (mips_target::low_new_process): ...this.
359 (mips_linux_delete_process): Turn into...
360 (mips_target::low_delete_process): ...this.
361 (mips_linux_new_thread): Turn into...
362 (mips_target::low_new_thread): ...this.
363 (mips_linux_delete_thread): Turn into...
364 (mips_target::low_delete_thread): ...this.
365 (mips_linux_new_fork): Turn into...
366 (mips_target::low_new_fork): ...this.
367 (the_low_target): Remove the op fields.
368 * linux-bfin-low.cc (the_low_target): Remove the op fields.
369 * linux-crisv32-low.cc (the_low_target): Ditto.
370 * linux-m32r-low.cc (the_low_target): Ditto.
371 * linux-m68k-low.cc (the_low_target): Ditto.
372 * linux-ppc-low.cc (the_low_target): Ditto.
373 * linux-s390-low.cc (the_low_target): Ditto.
374 * linux-sh-low.cc (the_low_target): Ditto.
375 * linux-tic6x-low.cc (the_low_target): Ditto.
376 * linux-tile-low.cc (the_low_target): Ditto.
377 * linux-xtensa-low.cc (the_low_target): Ditto.
378
cb63de7c
TBA
3792020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
380
381 Turn the 'siginfo_fixup' linux target op into a method of
382 linux_process_target.
383
384 * linux-low.h (struct linux_target_ops): Remove the op.
385 (class linux_process_target) <siginfo_fixup>
386 <low_siginfo_fixup>: Declare.
387 * linux-low.cc (siginfo_fixup): Turn into...
388 (linux_process_target::siginfo_fixup): ...this.
389 (linux_process_target::low_siginfo_fixup): Define.
390 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
391 (x86_siginfo_fixup): Turn into...
392 (x86_target::low_siginfo_fixup): ...this.
393 (the_low_target): Remove the op field.
394 * linux-aarch64-low.cc (class aarch64_target):
395 <low_siginfo_fixup>: Declare.
396 (aarch64_linux_siginfo_fixup): Turn into...
397 (aarch64_target::low_siginfo_fixup): ...this.
398 (the_low_target): Remove the op field.
399 * linux-arm-low.cc (the_low_target): Remove the op field.
400 * linux-bfin-low.cc (the_low_target): Ditto.
401 * linux-crisv32-low.cc (the_low_target): Ditto.
402 * linux-m32r-low.cc (the_low_target): Ditto.
403 * linux-m68k-low.cc (the_low_target): Ditto.
404 * linux-mips-low.cc (the_low_target): Ditto.
405 * linux-ppc-low.cc (the_low_target): Ditto.
406 * linux-s390-low.cc (the_low_target): Ditto.
407 * linux-sh-low.cc (the_low_target): Ditto.
408 * linux-tic6x-low.cc (the_low_target): Ditto.
409 * linux-tile-low.cc (the_low_target): Ditto.
410 * linux-xtensa-low.cc (the_low_target): Ditto.
411
b35db733
TBA
4122020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
413
414 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
415 linux target ops into methods of linux_process_target.
416
417 * linux-low.h (struct linux_target_ops): Remove the ops.
418 (class linux_process_target) <low_collect_ptrace_register>
419 <low_store_ptrace_register>: Declare.
420 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
421 (linux_process_target::low_supply_ptrace_register): Define.
422
423 Update the callers below.
424
425 (linux_process_target::fetch_register)
426 (linux_process_target::store_register)
427
428 * linux-x86-low.cc (the_low_target): Remove the op fields.
429 * linux-aarch64-low.cc (the_low_target): Ditto.
430 * linux-arm-low.cc (the_low_target): Ditto.
431 * linux-bfin-low.cc (the_low_target): Ditto.
432 * linux-crisv32-low.cc (the_low_target): Ditto.
433 * linux-m32r-low.cc (the_low_target): Ditto.
434 * linux-m68k-low.cc (the_low_target): Ditto.
435 * linux-sh-low.cc (the_low_target): Ditto.
436 * linux-sparc-low.cc (the_low_target): Ditto.
437 * linux-tic6x-low.cc (the_low_target): Ditto.
438 * linux-tile-low.cc (the_low_target): Ditto.
439 * linux-xtensa-low.cc (the_low_target): Ditto.
440 * linux-mips-low.cc (class mips_target)
441 <low_collect_ptrace_register>
442 <low_supply_ptrace_register>: Declare.
443 (mips_collect_ptrace_register): Turn into ...
444 (mips_target::low_collect_ptrace_register): ...this.
445 (mips_supply_ptrace_register): Turn into...
446 (mips_target::low_supply_ptrace_register): ...this.
447 (the_low_target): Remove the op fields.
448 * linux-ppc-low.cc (class ppc_target)
449 <low_collect_ptrace_register>
450 <low_supply_ptrace_register>: Declare.
451 (ppc_collect_ptrace_register): Turn into ...
452 (ppc_target::low_collect_ptrace_register): ...this.
453 (ppc_supply_ptrace_register): Turn into ...
454 (ppc_target::low_supply_ptrace_register): ...this.
455 (ppc_fill_gregset): Update for the calls to
456 low_collect_ptrace_register.
457 (the_low_target): Remove the op fields.
458 * linux-s390-low.cc (class s390_target)
459 <low_collect_ptrace_register>
460 <low_supply_ptrace_register>: Declare.
461 (s390_collect_ptrace_register): Turn into ...
462 (s390_target::low_collect_ptrace_register): ...this.
463 (s390_supply_ptrace_register): Turn into ...
464 (s390_target::low_supply_ptrace_register): ...this.
465 (s390_fill_gregset): Update for the calls to
466 low_collect_ptrace_register.
467 (the_low_target): Remove the op fields.
468
ac1bbaca
TBA
4692020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
470
471 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
472 target ops into methods of linux_process_target.
473
474 * linux-low.h (struct linux_target_ops): Remove the ops.
475 (class linux_process_target) <check_stopped_by_watchpoint>
476 <low_stopped_by_watchpoint>
477 <low_stopped_data_address>: Declare.
478 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
479 (linux_process_target::check_stopped_by_watchpoint): ...this.
480 (linux_process_target::low_stopped_by_watchpoint): Define.
481 (linux_process_target::low_stopped_data_address): Define.
482 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
483 <low_stopped_data_address>: Declare.
484 (x86_stopped_by_watchpoint): Turn into...
485 (x86_target::low_stopped_by_watchpoint): ...this.
486 (x86_stopped_data_address): Turn into...
487 (x86_target::low_stopped_data_address): ...this.
488 (the_low_target): Remove the op fields.
489 * linux-aarch64-low.cc (class aarch64_target)
490 <low_stopped_by_watchpoint>
491 <low_stopped_data_address>: Declare.
492 (aarch64_stopped_by_watchpoint): Turn into...
493 (aarch64_target::low_stopped_by_watchpoint): ...this.
494 (aarch64_stopped_data_address): Turn into...
495 (aarch64_target::low_stopped_data_address): ...this.
496 (the_low_target): Remove the op fields.
497 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
498 <low_stopped_data_address>: Declare.
499 (arm_stopped_by_watchpoint): Turn into...
500 (arm_target::low_stopped_by_watchpoint): ...this.
501 (arm_stopped_data_address): Turn into...
502 (arm_target::low_stopped_data_address): ...this.
503 (the_low_target): Remove the op fields.
504 * linux-crisv32-low.cc (class crisv32_target)
505 <low_stopped_by_watchpoint>
506 <low_stopped_data_address>: Declare.
507 (cris_stopped_by_watchpoint): Turn into...
508 (crisv32_target::low_stopped_by_watchpoint): ...this.
509 (cris_stopped_data_address): Turn into...
510 (crisv32_target::low_stopped_data_address): ...this.
511 (the_low_target): Remove the op fields.
512 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
513 <low_stopped_data_address>: Declare.
514 (mips_stopped_by_watchpoint): Turn into...
515 (mips_target::low_stopped_by_watchpoint): ...this.
516 (mips_stopped_data_address): Turn into...
517 (mips_target::low_stopped_data_address): ...this.
518 (the_low_target): Remove the op fields.
519 * linux-bfin-low.cc (the_low_target): Remove the op fields.
520 * linux-m32r-low.cc (the_low_target): Ditto.
521 * linux-m68k-low.cc (the_low_target): Ditto.
522 * linux-ppc-low.cc (the_low_target): Ditto.
523 * linux-s390-low.cc (the_low_target): Ditto.
524 * linux-sh-low.cc (the_low_target): Ditto.
525 * linux-sparc-low.cc (the_low_target): Ditto.
526 * linux-tic6x-low.cc (the_low_target): Ditto.
527 * linux-tile-low.cc (the_low_target): Ditto.
528 * linux-xtensa-low.cc (the_low_target): Ditto.
529
9db9aa23
TBA
5302020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
531
532 Turn the 'insert_point' and 'remove_point' linux target ops into
533 methods of linux_process_target.
534
535 * linux-low.h (struct linux_target_ops): Remove the ops.
536 (class linux_process_target) <low_insert_point>
537 <low_remove_point>: Declare.
538 * linux-low.cc (linux_process_target::low_insert_point)
539 (linux_process_target::low_remove_point): Define.
540 (linux_process_target::insert_point)
541 (linux_process_target::remove_point): Update for calls to
542 low_insert_point and low_remove_point.
543 * linux-x86-low.cc (class x86_target) <low_insert_point>
544 <low_remove_point>: Declare.
545 (x86_insert_point): Turn into...
546 (x86_target::low_insert_point): ...this.
547 (x86_remove_point): Turn into...
548 (x86_target::low_remove_point): ...this.
549 (the_low_target): Remove the op fields.
550 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
551 <low_remove_point>: Declare.
552 (aarch64_insert_point): Turn into...
553 (aarch64_target::low_insert_point): ...this.
554 (aarch64_remove_point): Turn into...
555 (aarch64_target::low_remove_point): ...this.
556 (the_low_target): Remove the op fields.
557 * linux-arm-low.cc (class arm_target) <low_insert_point>
558 <low_remove_point>: Declare.
559 (arm_insert_point): Turn into...
560 (arm_target::low_insert_point): ...this.
561 (arm_remove_point): Turn into...
562 (arm_target::low_remove_point): ...this.
563 (the_low_target): Remove the op fields.
564 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
565 <low_remove_point>: Declare.
566 (crisv32_insert_point): Turn into...
567 (crisv32_target::low_insert_point): ...this.
568 (crisv32_remove_point): Turn into...
569 (crisv32_target::low_remove_point): ...this.
570 (the_low_target): Remove the op fields.
571 * linux-mips-low.cc (class mips_target) <low_insert_point>
572 <low_remove_point>: Declare.
573 (mips_insert_point): Turn into...
574 (mips_target::low_insert_point): ...this.
575 (mips_remove_point): Turn into...
576 (mips_target::low_remove_point): ...this.
577 (the_low_target): Remove the op fields.
578 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
579 <low_remove_point>: Declare.
580 (ppc_insert_point): Turn into...
581 (ppc_target::low_insert_point): ...this.
582 (ppc_remove_point): Turn into...
583 (ppc_target::low_remove_point): ...this.
584 (the_low_target): Remove the op fields.
585 * linux-bfin-low.cc (the_low_target): Remove the op fields.
586 * linux-m32r-low.cc (the_low_target): Ditto.
587 * linux-m68k-low.cc (the_low_target): Ditto.
588 * linux-s390-low.cc (the_low_target): Ditto.
589 * linux-sh-low.cc (the_low_target): Ditto.
590 * linux-sparc-low.cc (the_low_target): Ditto.
591 * linux-tic6x-low.cc (the_low_target): Ditto.
592 * linux-tile-low.cc (the_low_target): Ditto.
593 * linux-xtensa-low.cc (the_low_target): Ditto.
594
007c9b97
TBA
5952020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
596
597 Remove the 'supports_z_point_type' linux target op and let the
598 concrete linux target define it by overriding the op declared in
599 process_stratum_target.
600
601 * linux-low.cc (linux_process_target::supports_z_point_type):
602 Remove.
603 * linux-low.h (struct linux_target_ops): Remove the op.
604 (class linux_process_target) <supports_z_point_type>: Remove.
605 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
606 Declare.
607 (x86_supports_z_point_type): Turn into...
608 (x86_target::supports_z_point_type): ...this.
609 (the_low_target): Remove the op field.
610 * linux-aarch64-low.cc (class aarch64_target)
611 <supports_z_point_type>: Declare.
612 (aarch64_supports_z_point_type): Turn into...
613 (aarch64_target::supports_z_point_type): ...this.
614 (the_low_target): Remove the op field.
615 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
616 Declare.
617 (arm_supports_z_point_type): Turn into...
618 (arm_target::supports_z_point_type): ...this.
619 (the_low_target): Remove the op field.
620 * linux-crisv32-low.cc (class crisv32_target)
621 <supports_z_point_type>: Declare.
622 (cris_supports_z_point_type): Turn into...
623 (crisv32_target::supports_z_point_type): ...this.
624 (the_low_target): Remove the op field.
625 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
626 Declare.
627 (mips_supports_z_point_type): Turn into...
628 (mips_target::supports_z_point_type): ...this.
629 (the_low_target): Remove the op field.
630 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
631 Declare.
632 (ppc_supports_z_point_type): Turn into...
633 (ppc_target::supports_z_point_type): ...this.
634 (the_low_target): Remove the op field.
635 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
636 Declare.
637 (s390_supports_z_point_type): Turn into...
638 (s390_target::supports_z_point_type): ...this.
639 (the_low_target): Remove the op field.
640 * linux-bfin-low.cc (the_low_target): Remove the op field.
641 * linux-m32r-low.cc (the_low_target): Ditto.
642 * linux-m68k-low.cc (the_low_target): Ditto.
643 * linux-sh-low.cc (the_low_target): Ditto.
644 * linux-sparc-low.cc (the_low_target): Ditto.
645 * linux-tic6x-low.cc (the_low_target): Ditto.
646 * linux-tile-low.cc (the_low_target): Ditto.
647 * linux-xtensa-low.cc (the_low_target): Ditto.
648
d7146cda
TBA
6492020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
650
651 Turn the 'breakpoint_at' linux target op into a method of
652 linux_process_target.
653
654 * linux-low.h (struct linux_target_ops): Remove the op.
655 (class linux_process_target) <low_breakpoint_at>: Declare.
656
657 Update the callers below:
658
659 * linux-low.cc (linux_process_target::save_stop_reason)
660 (linux_process_target::thread_still_has_status_pending)
661 (linux_process_target::wait_1)
662
663 * linux-x86-low.cc (class x86_target)
664 <low_breakpoint_at>: Declare.
665 (x86_breakpoint_at): Turn into...
666 (x86_target::low_breakpoint_at): ...this.
667 (the_low_target): Remove the op field.
668 * linux-aarch64-low.cc (class aarch64_target)
669 <low_breakpoint_at>: Declare.
670 (aarch64_breakpoint_at): Turn into...
671 (aarch64_target::low_breakpoint_at): ...this.
672 (the_low_target): Remove the op field.
673 * linux-arm-low.cc (class arm_target)
674 <low_breakpoint_at>: Declare.
675 (arm_target::low_breakpoint_at): Define.
676 (the_low_target): Remove the op field.
677 * linux-bfin-low.cc (class bfin_target)
678 <low_breakpoint_at>: Declare.
679 (bfin_breakpoint_at): Turn into...
680 (bfin_target::low_breakpoint_at): ...this.
681 (the_low_target): Remove the op field.
682 * linux-cris-low.cc (class cris_target)
683 <low_breakpoint_at>: Declare.
684 (cris_breakpoint_at): Turn into...
685 (cris_target::low_breakpoint_at): ...this.
686 (the_low_target): Remove the op field.
687 * linux-crisv32-low.cc (class crisv32_target)
688 <low_breakpoint_at>: Declare.
689 (crisv32_breakpoint_at): Turn into...
690 (crisv32_target::low_breakpoint_at): ...this.
691 (the_low_target): Remove the op field.
692 * linux-ia64-low.cc (class ia64_target)
693 <low_breakpoint_at>: Declare.
694 (ia64_target::low_breakpoint_at): Define.
695 * linux-m32r-low.cc (class m32r_target)
696 <low_breakpoint_at>: Declare.
697 (m32r_breakpoint_at): Turn into...
698 (m32r_target::low_breakpoint_at): ...this.
699 (the_low_target): Remove the op field.
700 * linux-m68k-low.cc (class m68k_target)
701 <low_breakpoint_at>: Declare.
702 (m68k_breakpoint_at): Turn into...
703 (m68k_target::low_breakpoint_at): ...this.
704 (the_low_target): Remove the op field.
705 * linux-mips-low.cc (class mips_target)
706 <low_breakpoint_at>: Declare.
707 (mips_breakpoint_at): Turn into...
708 (mips_target::low_breakpoint_at): ...this.
709 (the_low_target): Remove the op field.
710 * linux-nios2-low.cc (class nios2_target)
711 <low_breakpoint_at>: Declare.
712 (nios2_breakpoint_at): Turn into...
713 (nios2_target::low_breakpoint_at): ...this.
714 (the_low_target): Remove the op field.
715 * linux-ppc-low.cc (class ppc_target)
716 <low_breakpoint_at>: Declare.
717 (ppc_breakpoint_at): Turn into...
718 (ppc_target::low_breakpoint_at): ...this.
719 (the_low_target): Remove the op field.
720 * linux-riscv-low.cc (class riscv_target)
721 <low_breakpoint_at>: Declare.
722 (riscv_breakpoint_at): Turn into...
723 (riscv_target::low_breakpoint_at): ...this.
724 (the_low_target): Remove the op field.
725 * linux-s390-low.cc (class s390_target)
726 <low_breakpoint_at>: Declare.
727 (s390_breakpoint_at): Turn into...
728 (s390_target::low_breakpoint_at): ...this.
729 (the_low_target): Remove the op field.
730 * linux-sh-low.cc (class sh_target)
731 <low_breakpoint_at>: Declare.
732 (sh_breakpoint_at): Turn into...
733 (sh_target::low_breakpoint_at): ...this.
734 (the_low_target): Remove the op field.
735 * linux-sparc-low.cc (class sparc_target)
736 <low_breakpoint_at>: Declare.
737 (sparc_breakpoint_at): Turn into...
738 (sparc_target::low_breakpoint_at): ...this.
739 (the_low_target): Remove the op field.
740 * linux-tic6x-low.cc (class tic6x_target)
741 <low_breakpoint_at>: Declare.
742 (tic6x_breakpoint_at): Turn into...
743 (tic6x_target::low_breakpoint_at): ...this.
744 (the_low_target): Remove the op field.
745 * linux-tile-low.cc (class tile_target)
746 <low_breakpoint_at>: Declare.
747 (tile_breakpoint_at): Turn into...
748 (tile_target::low_breakpoint_at): ...this.
749 (the_low_target): Remove the op field.
750 * linux-xtensa-low.cc (class xtensa_target)
751 <low_breakpoint_at>: Declare.
752 (xtensa_breakpoint_at): Turn into...
753 (xtensa_target::low_breakpoint_at): ...this.
754 (the_low_target): Remove the op field.
755
d4807ea2
TBA
7562020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
757
758 Turn the 'decr_pc_after_break' linux_target_ops field into
759 a method of linux_process_target.
760
761 * linux-low.h (struct linux_target_ops)
762 <decr_pc_after_break>: Remove.
763 (class linux_process_target) <low_decr_pc_after_break>: New method
764 declaration.
765 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
766 New method implementation.
767
768 Update the users below.
769
770 (linux_process_target::save_stop_reason)
771 (linux_process_target::wait_1)
772 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
773 New declaration.
774 (x86_target::low_decr_pc_after_break): New method implementation.
775 (the_low_target): Remove the field.
776 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
777 New declaration.
778 (bfin_target::low_decr_pc_after_break): New method implementation.
779 (the_low_target): Remove the field.
780 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
781 New declaration.
782 (m68k_target::low_decr_pc_after_break): New method implementation.
783 (the_low_target): Remove the field.
784 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
785 New declaration.
786 (s390_target::low_decr_pc_after_break): New method implementation.
787 (the_low_target): Remove the field.
788 * linux-aarch64-low.cc (the_low_target): Remove the field.
789 * linux-arm-low.cc (the_low_target): Remove the field.
790 * linux-cris-low.cc (the_low_target): Remove the field.
791 * linux-crisv32-low.cc (the_low_target): Remove the field.
792 * linux-m32r-low.cc (the_low_target): Remove the field.
793 * linux-mips-low.cc (the_low_target): Remove the field.
794 * linux-nios2-low.cc (the_low_target): Remove the field.
795 * linux-ppc-low.cc (the_low_target): Remove the field.
796 * linux-riscv-low.cc (the_low_target): Remove the field.
797 * linux-sh-low.cc (the_low_target): Remove the field.
798 * linux-sparc-low.cc (the_low_target): Remove the field.
799 * linux-tic6x-low.cc (the_low_target): Remove the field.
800 * linux-tile-low.cc (the_low_target): Remove the field.
801 * linux-xtensa-low.cc (the_low_target): Remove the field.
802
7582c77c
TBA
8032020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
804
805 Remove the 'supports_software_single_step' linux target op and let
806 the concrete linux target define it by overriding the op in
807 process_stratum_target.
808 Turn the 'get_next_pcs' linux target op into a method of
809 linux_process_target.
810
811 * linux-low.h (struct linux_target_ops): Remove the ops.
812 (class linux_process_target) <supports_software_single_step>:
813 Remove.
814 <low_get_next_pcs>: Declare.
815 * linux-low.cc (can_software_single_step): Remove.
816 (linux_process_target::low_get_next_pcs): Define.
817 (linux_process_target::supports_software_single_step): Remove.
818
819 Update the callers below.
820
821 (linux_process_target::handle_extended_wait)
822 (linux_process_target::wait_1)
823 (linux_process_target::install_software_single_step_breakpoints)
824 (linux_process_target::single_step)
825 (linux_process_target::thread_needs_step_over)
826 (linux_process_target::proceed_one_lwp)
827 (linux_process_target::supports_range_stepping)
828
829 * linux-x86-low.cc (the_low_target): Remove the op field.
830 * linux-aarch64-low.cc (the_low_target): Ditto.
831 * linux-bfin-low.cc (the_low_target): Ditto.
832 * linux-cris-low.cc (the_low_target): Ditto.
833 * linux-crisv32-low.cc (the_low_target): Ditto.
834 * linux-m32r-low.cc (the_low_target): Ditto.
835 * linux-m68k-low.cc (the_low_target): Ditto.
836 * linux-mips-low.cc (the_low_target): Ditto.
837 * linux-nios2-low.cc (the_low_target): Ditto.
838 * linux-ppc-low.cc (the_low_target): Ditto.
839 * linux-riscv-low.cc (the_low_target): Ditto.
840 * linux-s390-low.cc (the_low_target): Ditto.
841 * linux-sh-low.cc (the_low_target): Ditto.
842 * linux-sparc-low.cc (the_low_target): Ditto.
843 * linux-tic6x-low.cc (the_low_target): Ditto.
844 * linux-tile-low.cc (the_low_target): Ditto.
845 * linux-xtensa-low.cc (the_low_target): Ditto.
846 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
847 <supports_software_single_step>: Declare.
848 (arm_target::supports_software_single_step): Define.
849 (arm_gdbserver_get_next_pcs): Turn into...
850 (arm_target::low_get_next_pcs): ...this.
851 (the_low_target): Remove the op field.
852
3ca4edb6
TBA
8532020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
854
855 Remove the 'sw_breakpoint_from_kind' linux target op, and let
856 the concrete linux target define it by overriding the op
857 in process_stratum_target.
858
859 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
860 Remove.
861 * linux-low.h (struct linux_target_ops): Remove the op.
862 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
863 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
864 Declare.
865 (x86_sw_breakpoint_from_kind): Turn into...
866 (x86_target::sw_breakpoint_from_kind): ...this.
867 (the_low_target): Remove the op field.
868 * linux-aarch64-low.cc (class aarch64_target)
869 <sw_breakpoint_from_kind>: Declare.
870 (aarch64_sw_breakpoint_from_kind): Turn into...
871 (aarch64_target::sw_breakpoint_from_kind): ...this.
872 (the_low_target): Remove the op field.
873 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
874 Declare.
875 (arm_target::sw_breakpoint_from_kind): Define.
876 (the_low_target): Remove the op field.
877 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
878 Declare.
879 (bfin_sw_breakpoint_from_kind): Turn into...
880 (bfin_target::sw_breakpoint_from_kind): ...this.
881 (the_low_target): Remove the op field.
882 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
883 Declare.
884 (cris_sw_breakpoint_from_kind): Turn into...
885 (cris_target::sw_breakpoint_from_kind): ...this.
886 (the_low_target): Remove the op field.
887 * linux-crisv32-low.cc (class crisv32_target)
888 <sw_breakpoint_from_kind>: Declare.
889 (cris_sw_breakpoint_from_kind): Turn into...
890 (crisv32_target::sw_breakpoint_from_kind): ...this.
891 (the_low_target): Remove the op field.
892 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
893 Declare.
894 (ia64_target::sw_breakpoint_from_kind): Define.
895 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
896 Declare.
897 (m32r_sw_breakpoint_from_kind): Turn into...
898 (m32r_target::sw_breakpoint_from_kind): ...this.
899 (the_low_target): Remove the op field.
900 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
901 Declare.
902 (m68k_sw_breakpoint_from_kind): Turn into...
903 (m68k_target::sw_breakpoint_from_kind): ...this.
904 (the_low_target): Remove the op field.
905 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
906 Declare.
907 (mips_sw_breakpoint_from_kind): Turn into...
908 (mips_target::sw_breakpoint_from_kind): ...this.
909 (the_low_target): Remove the op field.
910 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
911 Declare.
912 (nios2_sw_breakpoint_from_kind): Turn into...
913 (nios2_target::sw_breakpoint_from_kind): ...this.
914 (the_low_target): Remove the op field.
915 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
916 Declare.
917 (ppc_sw_breakpoint_from_kind): Turn into...
918 (ppc_target::sw_breakpoint_from_kind): ...this.
919 (the_low_target): Remove the op field.
920 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
921 Declare.
922 (riscv_sw_breakpoint_from_kind): Turn into...
923 (riscv_target::sw_breakpoint_from_kind): ...this.
924 (the_low_target): Remove the op field.
925 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
926 Declare.
927 (s390_sw_breakpoint_from_kind): Turn into...
928 (s390_target::sw_breakpoint_from_kind): ...this.
929 (the_low_target): Remove the op field.
930 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
931 Declare.
932 (sh_sw_breakpoint_from_kind): Turn into...
933 (sh_target::sw_breakpoint_from_kind): ...this.
934 (the_low_target): Remove the op field.
935 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
936 Declare.
937 (sparc_sw_breakpoint_from_kind): Turn into...
938 (sparc_target::sw_breakpoint_from_kind): ...this.
939 (the_low_target): Remove the op field.
940 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
941 Declare.
942 (tic6x_sw_breakpoint_from_kind): Turn into...
943 (tic6x_target::sw_breakpoint_from_kind): ...this.
944 (the_low_target): Remove the op field.
945 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
946 Declare.
947 (tile_sw_breakpoint_from_kind): Turn into...
948 (tile_target::sw_breakpoint_from_kind): ...this.
949 (the_low_target): Remove the op field.
950 * linux-xtensa-low.cc (class xtensa_target)
951 <sw_breakpoint_from_kind>: Declare.
952 (xtensa_sw_breakpoint_from_kind): Turn into...
953 (xtensa_target::sw_breakpoint_from_kind): ...this.
954 (the_low_target): Remove the op field.
955
06250e4e
TBA
9562020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
957
958 Remove the 'breakpoint_kind_from_pc' and
959 'breakpoint_kind_from_current_state' linux target ops, and let the
960 concrete linux target define them by overriding the ops of
961 process_stratum_target.
962
963 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
964 Remove.
965 (linux_process_target::breakpoint_kind_from_current_state): Remove.
966 * linux-low.h (struct linux_target_ops): Remove ops.
967 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
968 <breakpoint_kind_from_current_state>: Remove.
969 * linux-x86-low.cc (the_low_target): Remove the op fields.
970 * linux-bfin-low.cc (the_low_target): Ditto.
971 * linux-cris-low.cc (the_low_target): Ditto.
972 * linux-crisv32-low.cc (the_low_target): Ditto.
973 * linux-m32r-low.cc (the_low_target): Ditto.
974 * linux-m68k-low.cc (the_low_target): Ditto.
975 * linux-mips-low.cc (the_low_target): Ditto.
976 * linux-nios2-low.cc (the_low_target): Ditto.
977 * linux-ppc-low.cc (the_low_target): Ditto.
978 * linux-s390-low.cc (the_low_target): Ditto.
979 * linux-sh-low.cc (the_low_target): Ditto.
980 * linux-sparc-low.cc (the_low_target): Ditto.
981 * linux-tic6x-low.cc (the_low_target): Ditto.
982 * linux-tile-low.cc (the_low_target): Ditto.
983 * linux-xtensa-low.cc (the_low_target): Ditto.
984 * linux-aarch64-low.cc (class aarch64_target)
985 <breakpoint_kind_from_pc>
986 <breakpoint_kind_from_current_state>: Declare.
987 (aarch64_breakpoint_kind_from_pc): Turn into...
988 (aarch64_target::breakpoint_kind_from_pc): ...this.
989 (aarch64_breakpoint_kind_from_current_state): Turn into...
990 (aarch64_target::breakpoint_kind_from_current_state): ...this.
991 (the_low_target): Remove the op fields.
992 * linux-arm-low.cc (class arm_target):
993 <breakpoint_kind_from_pc>
994 <breakpoint_kind_from_current_state>: Declare.
995 (arm_target::breakpoint_kind_from_pc): Define.
996 (arm_target::breakpoint_kind_from_current_state): Define.
997 (the_low_target): Remove the op fields.
998 * linux-riscv-low.cc (class riscv_target):
999 <breakpoint_kind_from_pc>: Declare.
1000 (riscv_breakpoint_kind_from_pc): Turn into...
1001 (riscv_target::breakpoint_kind_from_pc): ...this.
1002 (the_low_target): Remove the op fields.
1003
bf9ae9d8
TBA
10042020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1005
1006 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1007 of linux_process_target.
1008
1009 * linux-low.h (struct linux_target_ops): Remove the ops.
1010 (class linux_process_target) <low_supports_breakpoints>
1011 <low_get_pc>
1012 <low_set_pc>: Declare.
1013 * linux-low.cc (supports_breakpoints): Turn into...
1014 (linux_process_target::low_supports_breakpoints): ...this.
1015 (linux_process_target::low_get_pc): Define.
1016 (linux_process_target::low_set_pc): Define.
1017
1018 Update the callers below.
1019
1020 (linux_process_target::get_pc)
1021 (linux_process_target::save_stop_reason)
1022 (linux_process_target::maybe_move_out_of_jump_pad)
1023 (linux_process_target::wait_1)
1024 (linux_process_target::resume_one_lwp_throw)
1025 (linux_process_target::resume)
1026 (linux_process_target::proceed_all_lwps)
1027 (linux_process_target::read_pc)
1028 (linux_process_target::write_pc)
1029
1030 * linux-x86-low.cc (class linux_process_target)
1031 <low_supports_breakpoints>
1032 <low_get_pc>
1033 <low_set_pc>: Declare.
1034 (x86_target::low_supports_breakpoints): Define.
1035 (x86_get_pc): Turn into...
1036 (x86_target::low_get_pc): ...this.
1037 (x86_set_pc): Turn into...
1038 (x86_target::low_set_pc): ...this.
1039 (the_low_target): Remove the op fields.
1040 * linux-arm-low.cc (class arm_target)
1041 <low_supports_breakpoints>
1042 <low_get_pc>
1043 <low_set_pc>: Declare.
1044 (arm_target::low_supports_breakpoints)
1045 (arm_target::low_get_pc)
1046 (arm_target::low_set_pc): Define.
1047 (the_low_target): Remove the op fields.
1048 * linux-bfin-low.cc (class bfin_target)
1049 <low_supports_breakpoints>
1050 <low_get_pc>
1051 <low_set_pc>: Declare.
1052 (bfin_target::low_supports_breakpoints)
1053 (bfin_target::low_get_pc)
1054 (bfin_target::low_set_pc): Define.
1055 (the_low_target): Remove the op fields.
1056 * linux-cris-low.cc (class cris_target)
1057 <low_supports_breakpoints>
1058 <low_get_pc>
1059 <low_set_pc>: Declare.
1060 (cris_target::low_supports_breakpoints)
1061 (cris_target::low_get_pc)
1062 (cris_target::low_set_pc): Define.
1063 (the_low_target): Remove the op fields.
1064 * linux-crisv32-low.cc (class crisv32_target)
1065 <low_supports_breakpoints>
1066 <low_get_pc>
1067 <low_set_pc>: Declare.
1068 (crisv32_target::low_supports_breakpoints)
1069 (crisv32_target::low_get_pc)
1070 (crisv32_target::low_set_pc): Define.
1071 (the_low_target): Remove the op fields.
1072 * linux-m32r-low.cc (class m32r_target)
1073 <low_supports_breakpoints>
1074 <low_get_pc>
1075 <low_set_pc>: Declare.
1076 (m32r_target::low_supports_breakpoints)
1077 (m32r_target::low_get_pc)
1078 (m32r_target::low_set_pc): Define.
1079 (the_low_target): Remove the op fields.
1080 * linux-m68k-low.cc (class m68k_target)
1081 <low_supports_breakpoints>
1082 <low_get_pc>
1083 <low_set_pc>: Declare.
1084 (m68k_target::low_supports_breakpoints)
1085 (m68k_target::low_get_pc)
1086 (m68k_target::low_set_pc): Define.
1087 (the_low_target): Remove the op fields.
1088 * linux-nios2-low.cc (class nios2_target)
1089 <low_supports_breakpoints>
1090 <low_get_pc>
1091 <low_set_pc>: Declare.
1092 (nios2_target::low_supports_breakpoints)
1093 (nios2_target::low_get_pc)
1094 (nios2_target::low_set_pc): Define.
1095 (the_low_target): Remove the op fields.
1096 * linux-sh-low.cc (class sh_target)
1097 <low_supports_breakpoints>
1098 <low_get_pc>
1099 <low_set_pc>: Declare.
1100 (sh_target::low_supports_breakpoints)
1101 (sh_target::low_get_pc)
1102 (sh_target::low_set_pc): Define.
1103 (the_low_target): Remove the op fields.
1104 * linux-xtensa-low.cc (class xtensa_target)
1105 <low_supports_breakpoints>
1106 <low_get_pc>
1107 <low_set_pc>: Declare.
1108 (xtensa_target::low_supports_breakpoints)
1109 (xtensa_target::low_get_pc)
1110 (xtensa_target::low_set_pc): Define.
1111 (the_low_target): Remove the op fields.
1112 * linux-sparc-low.cc (class sparc_target)
1113 <low_supports_breakpoints>
1114 <low_get_pc>: Declare.
1115 (sparc_target::low_supports_breakpoints)
1116 (sparc_target::low_get_pc): Define.
1117 (the_low_target): Remove the op fields.
1118 * linux-tile-low.cc (class tile_target)
1119 <low_supports_breakpoints>
1120 <low_get_pc>
1121 <low_set_pc>: Declare.
1122 (tile_target::low_supports_breakpoints)
1123 (tile_target::low_get_pc)
1124 (tile_target::low_set_pc): Define.
1125 (the_low_target): Remove the op fields.
1126 * linux-aarch64-low.cc (class aarch64_target)
1127 <low_supports_breakpoints>
1128 <low_get_pc>
1129 <low_set_pc>: Declare.
1130 (aarch64_target::low_supports_breakpoints): Define.
1131 (aarch64_get_pc): Turn into...
1132 (aarch64_target::low_get_pc): ...this.
1133 (aarch64_set_pc): Turn into...
1134 (aarch64_target::low_set_pc): ...this.
1135 (the_low_target): Remove the op fields.
1136 * linux-mips-low.cc (class mips_target)
1137 <low_supports_breakpoints>
1138 <low_get_pc>
1139 <low_set_pc>: Declare.
1140 (mips_target::low_supports_breakpoints): Define.
1141 (mips_get_pc): Turn into...
1142 (mips_target::low_get_pc): ...this.
1143 (mips_set_pc): Turn into...
1144 (mips_target::low_set_pc): ...this.
1145 (the_low_target): Remove the op fields.
1146 * linux-ppc-low.cc (class ppc_target)
1147 <low_supports_breakpoints>
1148 <low_get_pc>
1149 <low_set_pc>: Declare.
1150 (ppc_target::low_supports_breakpoints): Define.
1151 (ppc_get_pc): Turn into...
1152 (ppc_target::low_get_pc): ...this.
1153 (ppc_set_pc): Turn into...
1154 (ppc_target::low_set_pc): ...this.
1155 (the_low_target): Remove the op fields.
1156 * linux-riscv-low.cc (class riscv_target)
1157 <low_supports_breakpoints>
1158 <low_get_pc>
1159 <low_set_pc>: Declare.
1160 (riscv_target::low_supports_breakpoints): Define.
1161 (riscv_get_pc): Turn into...
1162 (riscv_target::low_get_pc): ...this.
1163 (riscv_set_pc): Turn into...
1164 (riscv_target::low_set_pc): ...this.
1165 (the_low_target): Remove the op fields.
1166 * linux-s390-low.cc (class s390_target)
1167 <low_supports_breakpoints>
1168 <low_get_pc>
1169 <low_set_pc>: Declare.
1170 (s390_target::low_supports_breakpoints): Define.
1171 (s390_get_pc): Turn into...
1172 (s390_target::low_get_pc): ...this.
1173 (s390_set_pc): Turn into...
1174 (s390_target::low_set_pc): ...this.
1175 (the_low_target): Remove the op fields.
1176 * linux-tic6x-low.cc (class tic6x_target)
1177 <low_supports_breakpoints>
1178 <low_get_pc>
1179 <low_set_pc>: Declare.
1180 (tic6x_target::low_supports_breakpoints): Define.
1181 (tic6x_get_pc): Turn into...
1182 (tic6x_target::low_get_pc): ...this.
1183 (tic6x_set_pc): Turn into...
1184 (tic6x_target::low_set_pc): ...this.
1185 (the_low_target): Remove the op fields.
1186
df95181f
TBA
11872020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1188
1189 Turn some more static methods in linux-low into private methods
1190 of linux_process_target.
1191
1192 * linux-low.cc (get_pc): Turn into...
1193 (linux_process_target::get_pc): ...this.
1194 (save_stop_reason): Turn into...
1195 (linux_process_target::save_stop_reason): ...this.
1196 (thread_still_has_status_pending_p): Turn into...
1197 (linux_process_target::thread_still_has_status_pending): ...this.
1198 (status_pending_p_callback): Turn into...
1199 (linux_process_target::status_pending_p_callback): ...this.
1200 (resume_stopped_resumed_lwps): Turn into...
1201 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1202 (install_software_single_step_breakpoints): Turn into...
1203 (linux_process_target::install_software_single_step_breakpoints):
1204 ...this.
1205 (single_step): Turn into...
1206 (linux_process_target::single_step): ...this.
1207 (linux_resume_one_lwp_throw): Turn into...
1208 (linux_process_target::resume_one_lwp_throw): ...this.
1209 (linux_resume_one_lwp): Turn into...
1210 (linux_process_target::resume_one_lwp): ...this.
1211 (resume_status_pending_p): Turn into...
1212 (linux_process_target::resume_status_pending): ...this.
1213 (need_step_over_p): Turn into...
1214 (linux_process_target::thread_needs_step_over): ...this.
1215 (linux_resume_one_thread): Turn into...
1216 (linux_process_target::resume_one_thread): ...this.
1217 (proceed_one_lwp): Turn into...
1218 (linux_process_target::proceed_one_lwp): ...this.
1219 (unsuspend_and_proceed_one_lwp): Turn into...
1220 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1221
1222 Update the calls/references to the above functions below.
1223
1224 (linux_process_target::handle_extended_wait)
1225 (linux_process_target::filter_event)
1226 (linux_process_target::wait_for_event_filtered)
1227 (linux_process_target::wait_1)
1228 (linux_process_target::move_out_of_jump_pad)
1229 (linux_process_target::start_step_over)
1230 (linux_process_target::resume)
1231 (linux_process_target::proceed_all_lwps)
1232 (regsets_store_inferior_registers)
1233 (linux_process_target::store_register)
1234
1235 * linux-low.h (class linux_process_target)
1236 <get_pc>
1237 <save_stop_reason>
1238 <thread_still_has_status_pending>
1239 <status_pending_p_callback>
1240 <resume_stopped_resumed_lwps>
1241 <install_software_single_step_breakpoints>
1242 <single_step>
1243 <resume_one_lwp_throw>
1244 <resume_one_lwp>
1245 <resume_status_pending>
1246 <thread_needs_step_over>
1247 <resume_one_thread>
1248 <proceed_one_lwp>
1249 <unsuspend_and_proceed_one_lwp>: Declare.
1250
bd70b1f2
TBA
12512020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1252
1253 Turn the 'fetch_register' linux target op into a method of
1254 linux_process_target.
1255
1256 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1257 (class linux_process_target) <low_fetch_register>: Declare.
1258 * linux-x86-low.cc (the_low_target)
1259 * linux-aarch64-low.cc (the_low_target)
1260 * linux-arm-low.cc (the_low_target)
1261 * linux-bfin-low.cc (the_low_target)
1262 * linux-cris-low.cc (the_low_target)
1263 * linux-crisv32-low.cc (the_low_target)
1264 * linux-m32r-low.cc (the_low_target)
1265 * linux-m68k-low.cc (the_low_target)
1266 * linux-nios2-low.cc (the_low_target)
1267 * linux-ppc-low.cc (the_low_target)
1268 * linux-s390-low.cc (the_low_target)
1269 * linux-sh-low.cc (the_low_target)
1270 * linux-sparc-low.cc (the_low_target)
1271 * linux-tic6x-low.cc (the_low_target)
1272 * linux-tile-low.cc (the_low_target)
1273 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1274 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1275 Declare.
1276 (ia64_fetch_register): Turn into...
1277 (ia64_target::low_fetch_register): ...this.
1278 (the_low_target): Remove the op field.
1279 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1280 Declare.
1281 (mips_fetch_register): Turn into...
1282 (mips_target::low_fetch_register): ...this.
1283 (the_low_target): Remove the op field.
1284 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1285 Declare.
1286 (riscv_fetch_register): Turn into...
1287 (riscv_target::low_fetch_register): ...this.
1288 (the_low_target): Remove the op field.
1289
1290 Update the callers below.
1291
1292 * linux-low.cc (linux_process_target::fetch_registers)
1293 (linux_process_target::low_fetch_register)
1294
daca57a7
TBA
12952020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1296
1297 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1298 linux target ops into methods of linux_process_target.
1299
1300 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1301 (class linux_process_target) <fetch_register>
1302 <store_register>
1303 <usr_fetch_inferior_registers>
1304 <usr_store_inferior_registers>
1305 <low_cannot_fetch_register>
1306 <low_cannot_fetch_register> Declare.
1307 * linux-low.cc (fetch_register): Turn into...
1308 (linux_process_target::fetch_register): ...this.
1309 (store_register): Turn into ...
1310 (linux_process_target::store_register): ...this.
1311 (usr_fetch_inferior_registers): Turn into...
1312 (linux_process_target::usr_fetch_inferior_registers): ...this.
1313 (usr_store_inferior_registers): Turn into...
1314 (linux_process_target::usr_store_inferior_registers): ...this.
1315 * linux-x86-low.cc (class x86_target)
1316 <low_cannot_fetch_register>
1317 <low_cannot_store_register>: Declare.
1318 (x86_cannot_store_register): Turn into...
1319 (x86_target::low_cannot_store_register): ...this.
1320 (x86_cannot_fetch_register): Turn into...
1321 (x86_target::low_cannot_fetch_register): ...this.
1322 (the_low_target): Remove the target op fields.
1323 * linux-aarch64-low.cc (class aarch64_target)
1324 <low_cannot_fetch_register>
1325 <low_cannot_store_register>: Declare.
1326 (aarch64_target::low_cannot_fetch_register)
1327 (aarch64_target::low_cannot_store_register): Define.
1328 (the_low_target): Remove the op fields.
1329 * linux-arm-low.cc (class arm_target)
1330 <low_cannot_fetch_register>
1331 <low_cannot_store_register>: Declare.
1332 (arm_cannot_fetch_register): Turn into...
1333 (arm_target::low_cannot_fetch_register): ...this.
1334 (arm_cannot_store_register): Turn into...
1335 (arm_target::low_cannot_store_register): ...this.
1336 (the_low_target): Remove the op fields.
1337 * linux-bfin-low.cc (class bfin_target)
1338 <low_cannot_fetch_register>
1339 <low_cannot_store_register>: Declare.
1340 (bfin_cannot_fetch_register): Turn into...
1341 (bfin_target::low_cannot_fetch_register): ...this.
1342 (bfin_cannot_store_register): Turn into...
1343 (bfin_target::low_cannot_store_register): ...this.
1344 (the_low_target): Remove the op fields.
1345 * linux-cris-low.cc (class cris_target)
1346 <low_cannot_fetch_register>
1347 <low_cannot_store_register>: Declare.
1348 (cris_cannot_fetch_register): Turn into...
1349 (cris_target::low_cannot_fetch_register): ...this.
1350 (cris_cannot_store_register): Turn into...
1351 (cris_target::low_cannot_store_register): ...this.
1352 (the_low_target): Remove the op fields.
1353 * linux-crisv32-low.cc (class crisv32_target)
1354 <low_cannot_fetch_register>
1355 <low_cannot_store_register>: Declare.
1356 (crisv32_target::low_cannot_fetch_register)
1357 (crisv32_target::low_cannot_store_register): Define.
1358 (the_low_target): Remove the op fields.
1359 * linux-ia64-low.cc (class ia64_target)
1360 <low_cannot_fetch_register>
1361 <low_cannot_store_register>: Declare.
1362 (ia64_cannot_fetch_register): Turn into...
1363 (ia64_target::low_cannot_fetch_register): ...this.
1364 (ia64_cannot_store_register): Turn into...
1365 (ia64_target::low_cannot_store_register): ...this.
1366 (the_low_target): Remove the op fields.
1367 * linux-m32r-low.cc (class m32r_target)
1368 <low_cannot_fetch_register>
1369 <low_cannot_store_register>: Declare.
1370 (m32r_cannot_fetch_register): Turn into...
1371 (m32r_target::low_cannot_fetch_register): ...this.
1372 (m32r_cannot_store_register): Turn into...
1373 (m32r_target::low_cannot_store_register): ...this.
1374 (the_low_target): Remove the op fields.
1375 * linux-m68k-low.cc (class m68k_target)
1376 <low_cannot_fetch_register>
1377 <low_cannot_store_register>: Declare.
1378 (m68k_cannot_fetch_register): Turn into...
1379 (m68k_target::low_cannot_fetch_register): ...this.
1380 (m68k_cannot_store_register): Turn into...
1381 (m68k_target::low_cannot_store_register): ...this.
1382 (the_low_target): Remove the op fields.
1383 * linux-mips-low.cc (class mips_target)
1384 <low_cannot_fetch_register>
1385 <low_cannot_store_register>: Declare.
1386 (mips_cannot_fetch_register): Turn into...
1387 (mips_target::low_cannot_fetch_register): ...this.
1388 (mips_cannot_store_register): Turn into...
1389 (mips_target::low_cannot_store_register): ...this.
1390 (get_usrregs_info): Inline at the call sites in
1391 low_cannot_fetch_register and low_cannot_store_register,
1392 and remove.
1393 (the_low_target): Remove the op fields.
1394 * linux-nios2-low.cc (class nios2_target)
1395 <low_cannot_fetch_register>
1396 <low_cannot_store_register>: Declare.
1397 (nios2_cannot_fetch_register): Turn into...
1398 (nios2_target::low_cannot_fetch_register): ...this.
1399 (nios2_cannot_store_register): Turn into...
1400 (nios2_target::low_cannot_store_register): ...this.
1401 (the_low_target): Remove the op fields.
1402 * linux-ppc-low.cc (class ppc_target)
1403 <low_cannot_fetch_register>
1404 <low_cannot_store_register>: Declare.
1405 (ppc_cannot_fetch_register): Turn into...
1406 (ppc_target::low_cannot_fetch_register): ...this.
1407 (ppc_cannot_store_register): Turn into...
1408 (ppc_target::low_cannot_store_register): ...this.
1409 (the_low_target): Remove the op fields.
1410 * linux-riscv-low.cc (class riscv_target)
1411 <low_cannot_fetch_register>
1412 <low_cannot_store_register>: Declare.
1413 (riscv_target::low_cannot_fetch_register)
1414 (riscv_target::low_cannot_store_register): Define.
1415 (the_low_target): Remove the op fields.
1416 * linux-s390-low.cc (class s390_target)
1417 <low_cannot_fetch_register>
1418 <low_cannot_store_register>: Declare.
1419 (s390_cannot_fetch_register): Turn into...
1420 (s390_target::low_cannot_fetch_register): ...this.
1421 (s390_cannot_store_register): Turn into...
1422 (s390_target::low_cannot_store_register): ...this.
1423 (the_low_target): Remove the op fields.
1424 * linux-sh-low.cc (class sh_target)
1425 <low_cannot_fetch_register>
1426 <low_cannot_store_register>: Declare.
1427 (sh_cannot_fetch_register): Turn into...
1428 (sh_target::low_cannot_fetch_register): ...this.
1429 (sh_cannot_store_register): Turn into...
1430 (sh_target::low_cannot_store_register): ...this.
1431 (the_low_target): Remove the op fields.
1432 * linux-sparc-low.cc (class sparc_target)
1433 <low_cannot_fetch_register>
1434 <low_cannot_store_register>: Declare.
1435 (sparc_cannot_fetch_register): Turn into...
1436 (sparc_target::low_cannot_fetch_register): ...this.
1437 (sparc_cannot_store_register): Turn into...
1438 (sparc_target::low_cannot_store_register): ...this.
1439 (the_low_target): Remove the op fields.
1440 * linux-tic6x-low.cc (class tic6x_target)
1441 <low_cannot_fetch_register>
1442 <low_cannot_store_register>: Declare.
1443 (tic6x_cannot_fetch_register): Turn into...
1444 (tic6x_target::low_cannot_fetch_register): ...this.
1445 (tic6x_cannot_store_register): Turn into...
1446 (tic6x_target::low_cannot_store_register): ...this.
1447 (the_low_target): Remove the op fields.
1448 * linux-tile-low.cc (class tile_target)
1449 <low_cannot_fetch_register>
1450 <low_cannot_store_register>: Declare.
1451 (tile_cannot_fetch_register): Turn into...
1452 (tile_target::low_cannot_fetch_register): ...this.
1453 (tile_cannot_store_register): Turn into...
1454 (tile_target::low_cannot_store_register): ...this.
1455 (the_low_target): Remove the op fields.
1456 * linux-xtensa-low.cc (class xtensa_target)
1457 <low_cannot_fetch_register>
1458 <low_cannot_store_register>: Declare.
1459 (xtensa_target::low_cannot_fetch_register)
1460 (xtensa_target::low_cannot_store_register): Define.
1461 (the_low_target): Remove the op fields.
1462
aa8d21c9
TBA
14632020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1464
1465 Turn the 'regs_info' linux target op into a method of
1466 linux_process_target.
1467
1468 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1469 (class linux_process_target) <get_regs_info>: Define.
1470
1471 Update the callers below.
1472
1473 * linux-low.cc (linux_process_target::fetch_registers)
1474 (linux_process_target::store_registers)
1475 * proc-service.cc (gregset_info)
1476
1477 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1478 (x86_linux_regs_info): Turn into ...
1479 (x86_target::get_regs_info): ...this.
1480 (the_low_target): Remove the op field.
1481 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1482 Declare.
1483 (aarch64_regs_info): Turn into ...
1484 (aarch64_target::get_regs_info): ...this.
1485 (the_low_target): Remove the op field.
1486 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1487 (arm_regs_info): Turn into ...
1488 (arm_target::get_regs_info): ...this.
1489 (the_low_target): Remove the op field.
1490 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1491 (bfin_regs_info): Turn into ...
1492 (bfin_target::get_regs_info): ...this.
1493 (the_low_target): Remove the op field.
1494 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1495 (cris_regs_info): Turn into ...
1496 (cris_target::get_regs_info): ...this.
1497 (the_low_target): Remove the op field.
1498 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1499 Declare.
1500 (crisv32_regs_info): Turn into ...
1501 (crisv32_target::get_regs_info): ...this.
1502 (the_low_target): Remove the op field.
1503 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1504 (ia64_regs_info): Turn into ...
1505 (ia64_target::get_regs_info): ...this.
1506 (the_low_target): Remove the op field.
1507 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1508 (m32r_regs_info): Turn into ...
1509 (m32r_target::get_regs_info): ...this.
1510 (the_low_target): Remove the op field.
1511 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1512 (m68k_regs_info): Turn into ...
1513 (m68k_target::get_regs_info): ...this.
1514 (the_low_target): Remove the op field.
1515 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1516 (mips_regs_info): Turn into ...
1517 (mips_target::get_regs_info): ...this.
1518 (the_low_target): Remove the op field.
1519 (get_usrregs_info): Update the call to the op.
1520 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1521 (nios2_regs_info): Turn into ...
1522 (nios2_target::get_regs_info): ...this.
1523 (the_low_target): Remove the op field.
1524 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1525 (ppc_regs_info): Turn into ...
1526 (ppc_target::get_regs_info): ...this.
1527 (the_low_target): Remove the op field.
1528 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1529 (riscv_regs_info): Turn into ...
1530 (riscv_target::get_regs_info): ...this.
1531 (the_low_target): Remove the op field.
1532 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1533 (s390_regs_info): Turn into ...
1534 (s390_target::get_regs_info): ...this.
1535 (the_low_target): Remove the op field.
1536 (s390_collect_ptrace_register)
1537 (s390_supply_ptrace_register)
1538 (s390_fill_gregset): Update the call to the op.
1539 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1540 (sh_regs_info): Turn into ...
1541 (sh_target::get_regs_info): ...this.
1542 (the_low_target): Remove the op field.
1543 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1544 (sparc_regs_info): Turn into ...
1545 (sparc_target::get_regs_info): ...this.
1546 (the_low_target): Remove the op field.
1547 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1548 (tic6x_regs_info): Turn into ...
1549 (tic6x_target::get_regs_info): ...this.
1550 (the_low_target): Remove the op field.
1551 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1552 (tile_regs_info): Turn into ...
1553 (tile_target::get_regs_info): ...this.
1554 (the_low_target): Remove the op field.
1555 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1556 Declare.
1557 (xtensa_regs_info): Turn into ...
1558 (xtensa_target::get_regs_info): ...this.
1559 (the_low_target): Remove the op field.
1560
797bcff5
TBA
15612020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1562
1563 Turn the 'arch_setup' linux target op into a method of
1564 linux_process_target.
1565
1566 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1567 (class linux_process_target) <arch_setup_thread>
1568 <low_arch_setup>: New declarations.
1569 * linux-low.cc (linux_arch_setup): Delete.
1570 (linux_arch_setup_thread): Turn into...
1571 (linux_process_target::arch_setup_thread): ... this.
1572
1573 Update the callers below.
1574
1575 (linux_process_target::handle_extended_wait)
1576 (linux_process_target::post_create_inferior)
1577 (linux_process_target::filter_event)
1578
1579 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1580 declaration.
1581 (x86_linux_update_xmltarget): Turn into...
1582 (x86_target::update_xmltarget): ...this.
1583 (x86_linux_process_qsupported): Update the call to
1584 x86_linux_update_xmltarget.
1585 (x86_arch_setup): Turn into ...
1586 (x86_target::low_arch_setup): ...this.
1587 (the_low_target): Remove the op field.
1588 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1589 declaration.
1590 (aarch64_arch_setup): Turn into ...
1591 (aarch64_target::low_arch_setup): ...this.
1592 (the_low_target): Remove the op field.
1593 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1594 declaration.
1595 (arm_arch_setup): Turn into ...
1596 (arm_target::low_arch_setup): ...this.
1597 (the_low_target): Remove the op field.
1598 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1599 declaration.
1600 (bfin_arch_setup): Turn into ...
1601 (bfin_target::low_arch_setup): ...this.
1602 (the_low_target): Remove the op field.
1603 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1604 declaration.
1605 (cris_arch_setup): Turn into ...
1606 (cris_target::low_arch_setup): ...this.
1607 (the_low_target): Remove the op field.
1608 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1609 declaration.
1610 (crisv32_arch_setup): Turn into ...
1611 (crisv32_target::low_arch_setup): ...this.
1612 (the_low_target): Remove the op field.
1613 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1614 declaration.
1615 (ia64_arch_setup): Turn into ...
1616 (ia64_target::low_arch_setup): ...this.
1617 (the_low_target): Remove the op field.
1618 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1619 declaration.
1620 (m32r_arch_setup): Turn into ...
1621 (m32r_target::low_arch_setup): ...this.
1622 (the_low_target): Remove the op field.
1623 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1624 declaration.
1625 (m68k_arch_setup): Turn into ...
1626 (m68k_target::low_arch_setup): ...this.
1627 (the_low_target): Remove the op field.
1628 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1629 declaration.
1630 (mips_arch_setup): Turn into ...
1631 (mips_target::low_arch_setup): ...this.
1632 (the_low_target): Remove the op field.
1633 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1634 declaration.
1635 (nios2_arch_setup): Turn into ...
1636 (nios2_target::low_arch_setup): ...this.
1637 (the_low_target): Remove the op field.
1638 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1639 declaration.
1640 (ppc_arch_setup): Turn into ...
1641 (ppc_target::low_arch_setup): ...this.
1642 (the_low_target): Remove the op field.
1643 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1644 declaration.
1645 (riscv_arch_setup): Turn into ...
1646 (riscv_target::low_arch_setup): ...this.
1647 (the_low_target): Remove the op field.
1648 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1649 declaration.
1650 (s390_arch_setup): Turn into ...
1651 (s390_target::low_arch_setup): ...this.
1652 (the_low_target): Remove the op field.
1653 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1654 declaration.
1655 (sh_arch_setup): Turn into ...
1656 (sh_target::low_arch_setup): ...this.
1657 (the_low_target): Remove the op field.
1658 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1659 declaration.
1660 (sparc_arch_setup): Turn into ...
1661 (sparc_target::low_arch_setup): ...this.
1662 (the_low_target): Remove the op field.
1663 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1664 declaration.
1665 (tic6x_arch_setup): Turn into ...
1666 (tic6x_target::low_arch_setup): ...this.
1667 (the_low_target): Remove the op field.
1668 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1669 declaration.
1670 (tile_arch_setup): Turn into ...
1671 (tile_target::low_arch_setup): ...this.
1672 (the_low_target): Remove the op field.
1673 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1674 declaration.
1675 (xtensa_arch_setup): Turn into ...
1676 (xtensa_target::low_arch_setup): ...this.
1677 (the_low_target): Remove the op field.
1678
ef0478f6
TBA
16792020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1680
1681 * linux-low.h (the_linux_target): New extern declaration.
1682 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1683 'the_target'.
1684 (the_linux_target): Remove.
1685 * linux-x86-low.cc (class x86_target): New class.
1686 (the_x86_target): New static object.
1687 (the_linux_target): Define as pointer to the_x86_target.
1688 * linux-aarch64-low.cc (class aarch64_target): New class.
1689 (the_aarch64_target): New static object.
1690 (the_linux_target): Define as pointer to the_aarch64_target.
1691 * linux-arm-low.cc (class arm_target): New class.
1692 (the_arm_target): New static object.
1693 (the_linux_target): Define as pointer to the_arm_target.
1694 * linux-bfin-low.cc (class bfin_target): New class.
1695 (the_bfin_target): New static object.
1696 (the_linux_target): Define as pointer to the_bfin_target.
1697 * linux-cris-low.cc (class cris_target): New class.
1698 (the_cris_target): New static object.
1699 (the_linux_target): Define as pointer to the_cris_target.
1700 * linux-crisv32-low.cc (class crisv32_target): New class.
1701 (the_crisv32_target): New static object.
1702 (the_linux_target): Define as pointer to the_crisv32_target.
1703 * linux-ia64-low.cc (class ia64_target): New class.
1704 (the_ia64_target): New static object.
1705 (the_linux_target): Define as pointer to the_ia64_target.
1706 * linux-m32r-low.cc (class m32r_target): New class.
1707 (the_m32r_target): New static object.
1708 (the_linux_target): Define as pointer to the_m32r_target.
1709 * linux-m68k-low.cc (class m68k_target): New class.
1710 (the_m68k_target): New static object.
1711 (the_linux_target): Define as pointer to the_m68k_target.
1712 * linux-mips-low.cc (class mips_target): New class.
1713 (the_mips_target): New static object.
1714 (the_linux_target): Define as pointer to the_mips_target.
1715 * linux-nios2-low.cc (class nios2_target): New class.
1716 (the_nios2_target): New static object.
1717 (the_linux_target): Define as pointer to the_nios2_target.
1718 * linux-ppc-low.cc (class ppc_target): New class.
1719 (the_ppc_target): New static object.
1720 (the_linux_target): Define as pointer to the_ppc_target.
1721 * linux-riscv-low.cc (class riscv_target): New class.
1722 (the_riscv_target): New static object.
1723 (the_linux_target): Define as pointer to the_riscv_target.
1724 * linux-s390-low.cc (class s390_target): New class.
1725 (the_s390_target): New static object.
1726 (the_linux_target): Define as pointer to the_s390_target.
1727 * linux-sh-low.cc (class sh_target): New class.
1728 (the_sh_target): New static object.
1729 (the_linux_target): Define as pointer to the_sh_target.
1730 * linux-sparc-low.cc (class sparc_target): New class.
1731 (the_sparc_target): New static object.
1732 (the_linux_target): Define as pointer to the_sparc_target.
1733 * linux-tic6x-low.cc (class tic6x_target): New class.
1734 (the_tic6x_target): New static object.
1735 (the_linux_target): Define as pointer to the_tic6x_target.
1736 * linux-tile-low.cc (class tile_target): New class.
1737 (the_tile_target): New static object.
1738 (the_linux_target): Define as pointer to the_tile_target.
1739 * linux-xtensa-low.cc (class xtensa_target): New class.
1740 (the_xtensa_target): New static object.
1741 (the_linux_target): Define as pointer to the_xtensa_target.
1742
d16f3f6c
TBA
17432020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1744
1745 Turn some static functions in linux-low.cc into private methods of
1746 linux_process_target.
1747
1748 * linux-low.cc (handle_extended_wait): Turn into ...
1749 (linux_process_target::handle_extended_wait): ...this. Call
1750 'mourn' on 'this' object instead of 'the_target'.
1751 (maybe_move_out_of_jump_pad): Turn into...
1752 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
1753 (linux_low_filter_event): Turn into...
1754 (linux_process_target::filter_event): ...this.
1755 (linux_wait_for_event_filtered): Turn into...
1756 (linux_process_target::wait_for_event_filtered): ...this.
1757 (linux_wait_for_event): Turn into...
1758 (linux_process_target::wait_for_event): ...this.
1759 (linux_wait_1): Turn into...
1760 (linux_process_target::wait_1): ...this.
1761 (wait_for_sigstop): Turn into...
1762 (linux_process_target::wait_for_sigstop): ...this.
1763 (move_out_of_jump_pad_callback): Turn into...
1764 (linux_process_target::move_out_of_jump_pad): ...this.
1765 (stop_all_lwps): Turn into...
1766 (linux_process_target::stop_all_lwps): ...this.
1767 (start_step_over): Turn into...
1768 (linux_process_target::start_step_over): ...this.
1769 (complete_ongoing_step_over): Turn into...
1770 (linux_process_target::complete_ongoing_step_over): ...this.
1771 (proceed_all_lwps): Turn into...
1772 (linux_process_target::proceed_all_lwps): ...this.
1773 (unstop_all_lwps): Turn into...
1774 (linux_process_target::unstop_all_lwps): ...this.
1775
1776 * linux-low.h (class linux_process_target)
1777 <handle_extended_wait>
1778 <maybe_move_out_of_jump_pad>
1779 filter_event>
1780 <wait_for_event_filtered>
1781 <wait_for_event>
1782 <wait_1>
1783 <wait_for_sigstop>
1784 <move_out_of_jump_pad>
1785 <stop_all_lwps>
1786 <start_step_over>
1787 <complete_ongoing_step_over>
1788 <proceed_all_lwps>
1789 <unstop_all_lwps>: Declare.
1790
1791 Update the callers below.
1792
1793 * linux-low.cc (linux_process_target::attach): Update.
1794 (linux_process_target::stabilize_threads): Ditto.
1795 (linux_process_target::wait): Ditto.
1796
a5863204
TBA
17972020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1798
1799 * linux-low.h (struct linux_target_ops): Update the comment for
1800 'cannot_store_register' to return 0 or 1.
1801 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
1802 of 2.
1803
c884cc46
SM
18042020-03-20 Simon Marchi <simon.marchi@efficios.com>
1805
1806 * config.in: Re-generate.
1807 * configure: Re-generate.
1808
5a82b8a1
KR
18092020-03-17 Kamil Rytarowski <n54@gmx.com>
1810
1811 * regcache.cc (find_register_by_number): Update.
1812 * tdesc.cc (init_target_desc): Likewise.
1813 * tdesc.h (target_desc::reg_defs): Likewise.
1814
4635ff97
TT
18152020-03-12 Tom Tromey <tom@tromey.com>
1816
1817 * configure: Rebuild.
1818 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
1819 (WIN32APILIBS): New subst.
1820 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
1821 gdbsupport files.
1822 (gdbsupport/%.o): Remove target.
1823 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
1824 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
1825 (WIN32APILIBS): New variable.
1826 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
1827 (gdbreplay$(EXEEXT)): Likewise.
1828
9a665d62
TT
18292020-03-12 Tom Tromey <tom@tromey.com>
1830
1831 * config.in, configure: Rebuild.
1832 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
1833 * acinclude.m4: Include gettext-sister.m4.
1834 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
1835 variables.
1836 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
1837 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
1838
272cd5a3
SM
18392020-03-12 Simon Marchi <simon.marchi@efficios.com>
1840
1841 * acinclude.m4: Update path to selftest.m4.
1842
db6878ac
SM
18432020-03-12 Simon Marchi <simon.marchi@efficios.com>
1844
1845 * configure.ac: Don't source bfd/development.sh, move
1846 GDB_AC_COMMON higher.
1847 * configure: Re-generate.
1848
4d696a5c
SM
18492020-03-12 Simon Marchi <simon.marchi@efficios.com>
1850
1851 * configure: Re-generate.
1852
a0761e34
SM
18532020-03-11 Simon Marchi <simon.marchi@efficios.com>
1854
1855 * configure: Re-generate.
1856
20ea4a60
AB
18572020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1858
1859 * .dir-locals.el: New file.
1860
842806cb
TBA
18612020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1862
1863 * .gitattributes: New file.
1864
442131c1
AB
18652020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
1866
1867 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
1868 reply into an S reply.
1869 * server.cc (disable_packet_T): New global.
1870 (captured_main): Set new global when appropriate.
1871 * server.h (disable_packet_T): Declare.
1872
dda42c0b
TT
18732020-02-21 Tom Tromey <tom@tromey.com>
1874
1875 * Makefile.in (mostlyclean): New target.
1876
52405d85
TBA
18772020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1878
1879 * target.h (struct process_stratum_target): Remove.
1880 (class process_target): Rename to ...
1881 (class process_stratum_target): ... this.
1882 * linux-low.h (class linux_process_target): Derive from
1883 'process_stratum_target'.
1884 * linux-low.cc (linux_target_ops): Remove.
1885 (initialize_low): Set the_target to the singleton instance of
1886 linux_process_target.
1887 * lynx-low.h (class lynx_process_target): Derive from
1888 'process_stratum_target'.
1889 * lynx-low.cc (lynx_target_ops): Remove.
1890 (initialize_low): Set the_target to the singleton instance of
1891 lynx_process_target.
1892 * nto-low.h (class nto_process_target): Derive from
1893 'process_stratum_target'.
1894 * nto-low.cc (nto_target_ops): Remove.
1895 (initialize_low): Set the_target to the singleton instance of
1896 nto_process_target.
1897 * win32-low.h (class win32_process_target): Derive from
1898 'process_stratum_target'.
1899 * win32-low.cc (win32_target_ops): Remove.
1900 (initialize_low): Set the_target to the singleton instance of
1901 win32_process_target.
1902
1903 Replace 'the_target->pt' with 'the_target' in the uses below.
1904
1905 * hostio.cc (hostio_error)
1906 (handle_setfs)
1907 (handle_open)
1908 (handle_unlink)
1909 (handle_readlink)
1910 * linux-aarch32-low.cc (arm_breakpoint_at)
1911 * linux-aarch64-low.cc (aarch64_breakpoint_at)
1912 * linux-arm-low.cc (arm_sigreturn_next_pc)
1913 (arm_get_hwcap)
1914 (arm_get_syscall_trapinfo)
1915 * linux-cris-low.cc (cris_breakpoint_at)
1916 * linux-crisv32-low.cc (cris_breakpoint_at)
1917 * linux-low.cc (handle_extended_wait)
1918 (linux_wait_1)
1919 (linux_read_memory)
1920 (linux_process_target::breakpoint_kind_from_pc)
1921 (linux_get_auxv)
1922 * linux-m32r-low.cc (m32r_breakpoint_at)
1923 * linux-mips-low.cc (mips_breakpoint_at)
1924 * linux-nios2-low.cc (nios2_breakpoint_at)
1925 * linux-ppc-low.cc (ppc_breakpoint_at)
1926 * linux-s390-low.cc (s390_get_hwcap)
1927 * linux-sh-low.cc (sh_breakpoint_at)
1928 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
1929 (sparc_store_gregset_from_stack)
1930 (sparc_breakpoint_at)
1931 * linux-tic6x-low.cc (tic6x_breakpoint_at)
1932 * linux-tile-low.cc (tile_breakpoint_at)
1933 * linux-x86-low.cc (x86_breakpoint_at)
1934 * linux-xtensa-low.cc (xtensa_breakpoint_at)
1935 * mem-break.cc (bp_size)
1936 (bp_opcode)
1937 (insert_memory_breakpoint)
1938 (set_raw_breakpoint_at)
1939 (delete_raw_breakpoint)
1940 (z_type_supported)
1941 (uninsert_raw_breakpoint)
1942 (reinsert_raw_breakpoint)
1943 (validate_inserted_breakpoint)
1944 * regcache.cc (regcache_read_pc)
1945 (regcache_write_pc)
1946 * remote-utils.cc (putpkt_binary_1)
1947 (input_interrupt)
1948 (getpkt)
1949 (prepare_resume_reply)
1950 * server.cc (handle_general_set)
1951 (handle_detach)
1952 (handle_qxfer_auxv)
1953 (handle_qxfer_exec_file)
1954 (handle_qxfer_libraries_svr4)
1955 (handle_qxfer_osdata)
1956 (handle_qxfer_siginfo)
1957 (handle_qxfer_fdpic)
1958 (handle_query)
1959 (resume)
1960 (handle_v_requests)
1961 (queue_stop_reply_callback)
1962 (captured_main)
1963 * target.cc (prepare_to_access_memory)
1964 (done_accessing_memory)
1965 (read_inferior_memory)
1966 (target_write_memory)
1967 (target_stop_and_wait)
1968 (target_wait)
1969 (target_mourn_inferior)
1970 (target_continue_no_signal)
1971 (target_continue)
1972 (target_supports_multi_process)
1973 (kill_inferior)
1974 * target.h
1975 (target_create_inferior)
1976 (target_post_create_inferior)
1977 (myattach)
1978 (target_supports_fork_events)
1979 (target_supports_vfork_events)
1980 (target_supports_exec_events)
1981 (target_handle_new_gdb_connection)
1982 (detach_inferior)
1983 (mythread_alive)
1984 (fetch_inferior_registers)
1985 (store_inferior_registers)
1986 (join_inferior)
1987 (target_supports_non_stop)
1988 (target_async)
1989 (target_process_qsupported)
1990 (target_supports_catch_syscall)
1991 (target_get_ipa_tdesc_idx)
1992 (target_supports_tracepoints)
1993 (target_supports_fast_tracepoints)
1994 (target_get_min_fast_tracepoint_insn_len)
1995 (target_thread_stopped)
1996 (target_pause_all)
1997 (target_unpause_all)
1998 (target_stabilize_threads)
1999 (target_install_fast_tracepoint_jump_pad)
2000 (target_emit_ops)
2001 (target_supports_disable_randomization)
2002 (target_supports_agent)
2003 (target_enable_btrace)
2004 (target_disable_btrace)
2005 (target_read_btrace)
2006 (target_read_btrace_conf)
2007 (target_supports_range_stepping)
2008 (target_supports_stopped_by_sw_breakpoint)
2009 (target_stopped_by_sw_breakpoint)
2010 (target_supports_stopped_by_hw_breakpoint)
2011 (target_supports_hardware_single_step)
2012 (target_stopped_by_hw_breakpoint)
2013 (target_breakpoint_kind_from_pc)
2014 (target_breakpoint_kind_from_current_state)
2015 (target_supports_software_single_step)
2016 (target_core_of_thread)
2017 (target_thread_name)
2018 (target_thread_handle)
2019 * win32-low.cc (do_initial_child_stuff)
2020
2021 Rename target op default definitions listed below.
2022
2023 * target.cc (process_target::post_create_inferior): Rename as ...
2024 (process_stratum_target::post_create_inferior): ... this.
2025 (process_target::prepare_to_access_memory): Rename as ...
2026 (process_stratum_target::prepare_to_access_memory): ... this.
2027 (process_target::done_accessing_memory): Rename as ...
2028 (process_stratum_target::done_accessing_memory): ... this.
2029 (process_target::look_up_symbols): Rename as ...
2030 (process_stratum_target::look_up_symbols): ... this.
2031 (process_target::supports_read_auxv): Rename as ...
2032 (process_stratum_target::supports_read_auxv): ... this.
2033 (process_target::read_auxv): Rename as ...
2034 (process_stratum_target::read_auxv): ... this.
2035 (process_target::supports_z_point_type): Rename as ...
2036 (process_stratum_target::supports_z_point_type): ... this.
2037 (process_target::insert_point): Rename as ...
2038 (process_stratum_target::insert_point): ... this.
2039 (process_target::remove_point): Rename as ...
2040 (process_stratum_target::remove_point): ... this.
2041 (process_target::stopped_by_sw_breakpoint): Rename as ...
2042 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2043 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2044 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2045 (process_target::stopped_by_hw_breakpoint): Rename as ...
2046 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2047 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2048 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2049 (process_target::supports_hardware_single_step): Rename as ...
2050 (process_stratum_target::supports_hardware_single_step): ... this.
2051 (process_target::stopped_by_watchpoint): Rename as ...
2052 (process_stratum_target::stopped_by_watchpoint): ... this.
2053 (process_target::stopped_data_address): Rename as ...
2054 (process_stratum_target::stopped_data_address): ... this.
2055 (process_target::supports_read_offsets): Rename as ...
2056 (process_stratum_target::supports_read_offsets): ... this.
2057 (process_target::read_offsets): Rename as ...
2058 (process_stratum_target::read_offsets): ... this.
2059 (process_target::supports_get_tls_address): Rename as ...
2060 (process_stratum_target::supports_get_tls_address): ... this.
2061 (process_target::get_tls_address): Rename as ...
2062 (process_stratum_target::get_tls_address): ... this.
2063 (process_target::hostio_last_error): Rename as ...
2064 (process_stratum_target::hostio_last_error): ... this.
2065 (process_target::supports_qxfer_osdata): Rename as ...
2066 (process_stratum_target::supports_qxfer_osdata): ... this.
2067 (process_target::qxfer_osdata): Rename as ...
2068 (process_stratum_target::qxfer_osdata): ... this.
2069 (process_target::supports_qxfer_siginfo): Rename as ...
2070 (process_stratum_target::supports_qxfer_siginfo): ... this.
2071 (process_target::qxfer_siginfo): Rename as ...
2072 (process_stratum_target::qxfer_siginfo): ... this.
2073 (process_target::supports_non_stop): Rename as ...
2074 (process_stratum_target::supports_non_stop): ... this.
2075 (process_target::async): Rename as ...
2076 (process_stratum_target::async): ... this.
2077 (process_target::start_non_stop): Rename as ...
2078 (process_stratum_target::start_non_stop): ... this.
2079 (process_target::supports_multi_process): Rename as ...
2080 (process_stratum_target::supports_multi_process): ... this.
2081 (process_target::supports_fork_events): Rename as ...
2082 (process_stratum_target::supports_fork_events): ... this.
2083 (process_target::supports_vfork_events): Rename as ...
2084 (process_stratum_target::supports_vfork_events): ... this.
2085 (process_target::supports_exec_events): Rename as ...
2086 (process_stratum_target::supports_exec_events): ... this.
2087 (process_target::handle_new_gdb_connection): Rename as ...
2088 (process_stratum_target::handle_new_gdb_connection): ... this.
2089 (process_target::handle_monitor_command): Rename as ...
2090 (process_stratum_target::handle_monitor_command): ... this.
2091 (process_target::core_of_thread): Rename as ...
2092 (process_stratum_target::core_of_thread): ... this.
2093 (process_target::supports_read_loadmap): Rename as ...
2094 (process_stratum_target::supports_read_loadmap): ... this.
2095 (process_target::read_loadmap): Rename as ...
2096 (process_stratum_target::read_loadmap): ... this.
2097 (process_target::process_qsupported): Rename as ...
2098 (process_stratum_target::process_qsupported): ... this.
2099 (process_target::supports_tracepoints): Rename as ...
2100 (process_stratum_target::supports_tracepoints): ... this.
2101 (process_target::read_pc): Rename as ...
2102 (process_stratum_target::read_pc): ... this.
2103 (process_target::write_pc): Rename as ...
2104 (process_stratum_target::write_pc): ... this.
2105 (process_target::supports_thread_stopped): Rename as ...
2106 (process_stratum_target::supports_thread_stopped): ... this.
2107 (process_target::thread_stopped): Rename as ...
2108 (process_stratum_target::thread_stopped): ... this.
2109 (process_target::supports_get_tib_address): Rename as ...
2110 (process_stratum_target::supports_get_tib_address): ... this.
2111 (process_target::get_tib_address): Rename as ...
2112 (process_stratum_target::get_tib_address): ... this.
2113 (process_target::pause_all): Rename as ...
2114 (process_stratum_target::pause_all): ... this.
2115 (process_target::unpause_all): Rename as ...
2116 (process_stratum_target::unpause_all): ... this.
2117 (process_target::stabilize_threads): Rename as ...
2118 (process_stratum_target::stabilize_threads): ... this.
2119 (process_target::supports_fast_tracepoints): Rename as ...
2120 (process_stratum_target::supports_fast_tracepoints): ... this.
2121 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2122 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2123 (process_target::emit_ops): Rename as ...
2124 (process_stratum_target::emit_ops): ... this.
2125 (process_target::supports_disable_randomization): Rename as ...
2126 (process_stratum_target::supports_disable_randomization): ... this.
2127 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2128 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2129 (process_target::qxfer_libraries_svr4): Rename as ...
2130 (process_stratum_target::qxfer_libraries_svr4): ... this.
2131 (process_target::supports_agent): Rename as ...
2132 (process_stratum_target::supports_agent): ... this.
2133 (process_target::enable_btrace): Rename as ...
2134 (process_stratum_target::enable_btrace): ... this.
2135 (process_target::disable_btrace): Rename as ...
2136 (process_stratum_target::disable_btrace): ... this.
2137 (process_target::read_btrace): Rename as ...
2138 (process_stratum_target::read_btrace): ... this.
2139 (process_target::read_btrace_conf): Rename as ...
2140 (process_stratum_target::read_btrace_conf): ... this.
2141 (process_target::supports_range_stepping): Rename as ...
2142 (process_stratum_target::supports_range_stepping): ... this.
2143 (process_target::supports_pid_to_exec_file): Rename as ...
2144 (process_stratum_target::supports_pid_to_exec_file): ... this.
2145 (process_target::pid_to_exec_file): Rename as ...
2146 (process_stratum_target::pid_to_exec_file): ... this.
2147 (process_target::supports_multifs): Rename as ...
2148 (process_stratum_target::supports_multifs): ... this.
2149 (process_target::multifs_open): Rename as ...
2150 (process_stratum_target::multifs_open): ... this.
2151 (process_target::multifs_unlink): Rename as ...
2152 (process_stratum_target::multifs_unlink): ... this.
2153 (process_target::multifs_readlink): Rename as ...
2154 (process_stratum_target::multifs_readlink): ... this.
2155 (process_target::breakpoint_kind_from_pc): Rename as ...
2156 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2157 (process_target::breakpoint_kind_from_current_state): Rename as ...
2158 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2159 (process_target::thread_name): Rename as ...
2160 (process_stratum_target::thread_name): ... this.
2161 (process_target::thread_handle): Rename as ...
2162 (process_stratum_target::thread_handle): ... this.
2163 (process_target::supports_software_single_step): Rename as ...
2164 (process_stratum_target::supports_software_single_step): ... this.
2165 (process_target::supports_catch_syscall): Rename as ...
2166 (process_stratum_target::supports_catch_syscall): ... this.
2167 (process_target::get_ipa_tdesc_idx): Rename as ...
2168 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2169
478f9adf
PA
21702020-02-20 Pedro Alves <palves@redhat.com>
2171
2172 * target.cc (set_target_ops): Simply copy the given target pointer
2173 instead of creating a copy of the pointed object.
2174
d633e831
TBA
21752020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2176
2177 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2178 of process_target.
2179
2180 * target.h (struct process_stratum_target): Remove the target op.
2181 (class process_target): Add the target op.
2182 (target_get_ipa_tdesc_idx): Update the macro.
2183 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2184
2185 Update the derived classes and callers below.
2186
2187 * linux-low.cc (linux_target_ops): Update.
2188 (linux_get_ipa_tdesc_idx): Turn into ...
2189 (linux_process_target::get_ipa_tdesc_idx): ... this.
2190 * linux-low.h (class linux_process_target): Update.
2191 * lynx-low.cc (lynx_target_ops): Update.
2192 * nto-low.cc (nto_target_ops): Update.
2193 * win32-low.cc (win32_target_ops): Update.
2194
bc8d3ae4
TBA
21952020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2196
2197 Turn process_stratum_target's supports_catch_syscall op into a
2198 method of process_target.
2199
2200 * target.h (struct process_stratum_target): Remove the target op.
2201 (class process_target): Add the target op.
2202 (target_supports_catch_syscall): Update the macro.
2203 * target.cc (process_target::supports_catch_syscall): Define.
2204
2205 Update the derived classes and callers below.
2206
2207 * linux-low.cc (linux_target_ops): Update.
2208 (linux_supports_catch_syscall): Turn into ...
2209 (linux_process_target::supports_catch_syscall): ... this.
2210 * linux-low.h (class linux_process_target): Update.
2211 * lynx-low.cc (lynx_target_ops): Update.
2212 * nto-low.cc (nto_target_ops): Update.
2213 * win32-low.cc (win32_target_ops): Update.
2214
5303a34f
TBA
22152020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2216
2217 Turn process_stratum_target's supports_software_single_step op
2218 into a method of process_target.
2219
2220 * target.h (struct process_stratum_target): Remove the target op.
2221 (class process_target): Add the target op.
2222 (target_supports_software_single_step): Update the macro.
2223 * target.cc (process_target::supports_software_single_step): Define.
2224
2225 Update the derived classes and callers below.
2226
2227 * linux-low.cc (linux_target_ops): Update.
2228 (linux_supports_software_single_step): Turn into ...
2229 (linux_process_target::supports_software_single_step): ... this.
2230 * linux-low.h (class linux_process_target): Update.
2231 * lynx-low.cc (lynx_target_ops): Update.
2232 * nto-low.cc (nto_target_ops): Update.
2233 * win32-low.cc (win32_target_ops): Update.
2234
7f63b89b
TBA
22352020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2236
2237 Turn process_stratum_target's thread_name and thread_handle ops
2238 into methods of process_target.
2239
2240 * target.h (struct process_stratum_target): Remove the target ops.
2241 (class process_target): Add the target ops.
2242 (target_thread_name): Update the macro.
2243 (target_thread_handle): Update the macro.
2244 * target.cc (process_target::thread_name): Define.
2245 (process_target::thread_handle): Define.
2246
2247 Update the derived classes and callers below.
2248
2249 * linux-low.cc (linux_target_ops): Update.
2250 (linux_process_target::thread_name): Define.
2251 (linux_process_target::thread_handle): Define.
2252 * linux-low.h (class linux_process_target): Update.
2253 * lynx-low.cc (lynx_target_ops): Update.
2254 * nto-low.cc (nto_target_ops): Update.
2255 * win32-low.cc (win32_target_ops): Update.
2256
d367006f
TBA
22572020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2258
2259 Turn process_stratum_target's breakpoint_kind_from_pc,
2260 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2261 ops into methods of process_target.
2262
2263 * target.h (struct process_stratum_target): Remove the target op.
2264 (class process_target): Add the target op.
2265 (target_breakpoint_kind_from_pc): Update the macro.
2266 (target_breakpoint_kind_from_current_state): Update the macro.
2267 (default_breakpoint_kind_from_pc): Remove declaration.
2268 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2269 (process_target::breakpoint_kind_from_pc): ... this.
2270 (process_target::breakpoint_kind_from_current_state): Define.
2271
2272 Update the derived classes and callers below.
2273
2274 * mem-break.cc (bp_size): Update.
2275 (bp_opcode): Update.
2276 * linux-low.cc (linux_target_ops): Update.
2277 (linux_wait_1): Update.
2278 (linux_breakpoint_kind_from_pc): Turn into ...
2279 (linux_process_target::breakpoint_kind_from_pc): ... this.
2280 (linux_sw_breakpoint_from_kind): Turn into ...
2281 (linux_process_target::sw_breakpoint_from_kind): ... this.
2282 (linux_breakpoint_kind_from_current_state): Turn into ...
2283 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2284 * linux-low.h (class linux_process_target): Update.
2285 * lynx-low.cc (lynx_target_ops): Update.
2286 (lynx_process_target::sw_breakpoint_from_kind): Define.
2287 * lynx-low.h (class lynx_process_target): Update.
2288 * nto-low.cc (nto_target_ops): Update.
2289 (nto_sw_breakpoint_from_kind): Turn into ...
2290 (nto_process_target::sw_breakpoint_from_kind): ... this.
2291 * nto-low.h (class nto_process_target): Update.
2292 * win32-low.cc (win32_target_ops): Update.
2293 (win32_sw_breakpoint_from_kind): Turn into ...
2294 (win32_process_target::sw_breakpoint_from_kind): ... this.
2295 * win32-low.h (class win32_process_target): Update.
2296
c9b7b804
TBA
22972020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2298
2299 Turn process_stratum_target's multifs_open, multifs_readlink,
2300 multifs_unlink ops into methods of process_target.
2301
2302 * target.h (struct process_stratum_target): Remove the target ops.
2303 (class process_target): Add the target ops. Also add
2304 'supports_multifs'.
2305 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2306 "sys/stat.h".
2307 (process_target::supports_multifs): Define.
2308 (process_target::multifs_open): Define.
2309 (process_target::multifs_readlink): Define.
2310 (process_target::multifs_unlink): Define.
2311
2312 Update the derived classes and callers below.
2313
2314 * hostio.cc (handle_setfs): Update.
2315 (handle_open): Update.
2316 (handle_unlink): Update.
2317 (handle_readlink): Update.
2318 * linux-low.cc (linux_target_ops): Update.
2319 (linux_process_target::supports_multifs): Define.
2320 (linux_process_target::multifs_open): Define.
2321 (linux_process_target::multifs_readlink): Define.
2322 (linux_process_target::multifs_unlink): Define.
2323 * linux-low.h (class linux_process_target): Update.
2324 * lynx-low.cc (lynx_target_ops): Update.
2325 * nto-low.cc (nto_target_ops): Update.
2326 * win32-low.cc (win32_target_ops): Update.
2327
8247b823
TBA
23282020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2329
2330 Turn process_stratum_target's pid_to_exec_file op into a method
2331 of process_target.
2332
2333 * target.h (struct process_stratum_target): Remove the target op.
2334 (class process_target): Add the target op. Also add
2335 'supports_pid_to_exec_file'.
2336 * target.cc (process_target::pid_to_exec_file): Define.
2337 (process_target::supports_pid_to_exec_file): Define.
2338
2339 Update the derived classes and callers below.
2340
2341 * server.cc (handle_qxfer_exec_file): Update.
2342 (handle_query): Update.
2343 * linux-low.cc (linux_target_ops): Update.
2344 (linux_process_target::supports_pid_to_exec_file): Define.
2345 (linux_process_target::pid_to_exec_file): Define.
2346 * linux-low.h (class linux_process_target): Update.
2347 * lynx-low.cc (lynx_target_ops): Update.
2348 * nto-low.cc (nto_target_ops): Update.
2349 * win32-low.cc (win32_target_ops): Update.
2350
2526e0cd
TBA
23512020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2352
2353 Turn process_stratum_target's supports_range_stepping op into a
2354 method of process_target.
2355
2356 * target.h (struct process_stratum_target): Remove the target op.
2357 (class process_target): Add the target op.
2358 (target_supports_range_stepping): Update the macro.
2359 * target.cc (process_target::supports_range_stepping): Define.
2360
2361 Update the derived classes and callers below.
2362
2363 * linux-low.cc (linux_target_ops): Update.
2364 (linux_supports_range_stepping): Turn into ...
2365 (linux_process_target::supports_range_stepping): ... this.
2366 * linux-low.h (class linux_process_target): Update.
2367 * lynx-low.cc (lynx_target_ops): Update.
2368 * nto-low.cc (nto_target_ops): Update.
2369 * win32-low.cc (win32_target_ops): Update.
2370
79597bdd
TBA
23712020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2372
2373 Turn process_stratum_target's btrace-related ops (enable_btrace,
2374 disable_btrace, read_btrace, read_btrace_conf) into methods of
2375 process_target.
2376
2377 * target.h (struct process_stratum_target): Remove the target ops.
2378 (class process_target): Add the target ops.
2379 (target_enable_btrace): Update.
2380 (target_disable_btrace): Update.
2381 (target_read_btrace): Update.
2382 (target_read_btrace_conf): Update.
2383 * target.cc (process_target::enable_btrace): Define.
2384 (process_target::disable_btrace): Define.
2385 (process_target::read_btrace): Define.
2386 (process_target::read_btrace_conf): Define.
2387
2388 Update the derived classes and callers below.
2389
2390 * linux-low.cc (linux_target_ops): Update.
2391 (linux_process_target:enable_btrace): Define as a wrapper around
2392 linux_enable_btrace.
2393 (linux_low_disable_btrace): Turn into ...
2394 (linux_process_target::disable_btrace): ... this.
2395 (linux_low_read_btrace): Turn into ...
2396 (linux_process_target::read_btrace): ... this.
2397 (linux_low_btrace_conf): Turn into ...
2398 (linux_process_target::read_btrace_conf): ... this.
2399 * linux-low.h (class linux_process_target): Update.
2400 * lynx-low.cc (lynx_target_ops): Update.
2401 * nto-low.cc (nto_target_ops): Update.
2402 * win32-low.cc (win32_target_ops): Update.
2403
c0245cb9
TBA
24042020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2405
2406 Turn process_stratum_target's supports_agent op into a method of
2407 process_target.
2408
2409 * target.h (struct process_stratum_target): Remove the target op.
2410 (class process_target): Add the target op.
2411 (target_supports_agent): Update the macro.
2412 * target.cc (process_target::supports_agent): Define.
2413
2414 Update the derived classes and callers below.
2415
2416 * linux-low.cc (linux_target_ops): Update.
2417 (linux_supports_agent): Turn into ...
2418 (linux_process_target::supports_agent): ... this.
2419 * linux-low.h (class linux_process_target): Update.
2420 * lynx-low.cc (lynx_target_ops): Update.
2421 * nto-low.cc (nto_target_ops): Update.
2422 * win32-low.cc (win32_target_ops): Update.
2423
974387bb
TBA
24242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2425
2426 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2427 method of process_target.
2428
2429 * target.h (struct process_stratum_target): Remove the target op.
2430 (class process_target): Add the target op. Also add
2431 'supports_qxfer_libraries_svr4'.
2432 * target.cc (process_target::qxfer_libraries_svr4): Define.
2433 (process_target::supports_qxfer_libraries_svr4): Define.
2434
2435 Update the derived classes and callers below.
2436
2437 * server.cc (handle_qxfer_libraries_svr4): Update.
2438 (handle_query): Update.
2439 * linux-low.cc (linux_target_ops): Update.
2440 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2441 (linux_qxfer_libraries_svr4): Turn into ...
2442 (linux_process_target::qxfer_libraries_svr4): ... this.
2443 * linux-low.h (class linux_process_target): Update.
2444 * lynx-low.cc (lynx_target_ops): Update.
2445 * nto-low.cc (nto_target_ops): Update.
2446 * win32-low.cc (win32_target_ops): Update.
2447
c756403b
TBA
24482020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2449
2450 Turn process_stratum_target's supports_disable_randomization op
2451 into a method of process_target.
2452
2453 * target.h (struct process_stratum_target): Remove the target op.
2454 (class process_target): Add the target op.
2455 (target_supports_disable_randomization): Update the macro.
2456 * target.cc (process_target::supports_disable_randomization): Define.
2457
2458 Update the derived classes and callers below.
2459
2460 * linux-low.cc (linux_target_ops): Update.
2461 (linux_supports_disable_randomization): Turn into ...
2462 (linux_process_target::supports_disable_randomization): ... this.
2463 * linux-low.h (class linux_process_target): Update.
2464 * lynx-low.cc (lynx_target_ops): Update.
2465 * nto-low.cc (nto_target_ops): Update.
2466 * win32-low.cc (win32_target_ops): Update.
2467
345dafad
TBA
24682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2469
2470 Turn process_stratum_target's emit_ops op into a method of
2471 process_target.
2472
2473 * target.h (struct process_stratum_target): Remove the target op.
2474 (class process_target): Add the target op.
2475 (target_emit_ops): Update the macro.
2476 * target.cc (process_target::emit_ops): Define.
2477
2478 Update the derived classes and callers below.
2479
2480 * linux-low.cc (linux_target_ops): Update.
2481 (linux_emit_ops): Turn into ...
2482 (linux_process_target::emit_ops): ... this.
2483 * linux-low.h (class linux_process_target): Update.
2484 * lynx-low.cc (lynx_target_ops): Update.
2485 * nto-low.cc (nto_target_ops): Update.
2486 * win32-low.cc (win32_target_ops): Update.
2487
c23c9391
TBA
24882020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2489
2490 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2491 and get_min_fast_tracepoint_insn_len ops into methods of
2492 process_target.
2493
2494 * target.h (struct process_stratum_target): Remove the target ops.
2495 (class process_target): Add the target ops. Also add
2496 'supports_fast_tracepoints'.
2497 (target_supports_fast_tracepoints): Update the macro.
2498 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2499 (install_fast_tracepoint_jump_pad): Update and rename the macro
2500 to ...
2501 (target_install_fast_tracepoint_jump_pad): ... this.
2502 * target.cc (process_target::supports_fast_tracepoints): Define.
2503 (process_target::install_fast_tracepoint_jump_pad): Define.
2504 (process_target::get_min_fast_tracepoint_insn_len): Define.
2505
2506 Update the derived classes and callers below.
2507
2508 * tracepoint.cc (install_fast_tracepoint): Update.
2509 * linux-low.cc (linux_target_ops): Update.
2510 (linux_process_target::supports_fast_tracepoints): Define.
2511 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2512 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2513 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2514 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2515 * linux-low.h (class linux_process_target): Update.
2516 * lynx-low.cc (lynx_target_ops): Update.
2517 * nto-low.cc (nto_target_ops): Update.
2518 * win32-low.cc (win32_target_ops): Update.
2519
5c9eb2f2
TBA
25202020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2521
2522 Turn process_stratum_target's stabilize_threads op into a
2523 method of process_target.
2524
2525 * target.h (struct process_stratum_target): Remove the target op.
2526 (class process_target): Add the target op.
2527 (target_stabilize_threads): Update the macro.
2528 * target.cc (process_target::stabilize_threads): Define.
2529
2530 Update the derived classes and callers below.
2531
2532 * server.cc (handle_status): Update.
2533 * tracepoint.cc (cmd_qtdp): Update.
2534 (cmd_qtstart): Update.
2535 * linux-low.cc (linux_target_ops): Update.
2536 (linux_stabilize_threads): Turn into ...
2537 (linux_process_target::stabilize_threads): ... this.
2538 (linux_wait_1): Update.
2539 * linux-low.h (class linux_process_target): Update.
2540 * lynx-low.cc (lynx_target_ops): Update.
2541 * nto-low.cc (nto_target_ops): Update.
2542 * win32-low.cc (win32_target_ops): Update.
2543
29e8dc09
TBA
25442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2545
2546 Turn process_stratum_target's pause_all and unpause_all ops
2547 into methods of process_target.
2548
2549 * target.h (struct process_stratum_target): Remove the target ops.
2550 (class process_target): Add the target ops.
2551 (pause_all): Update the macro and rename to...
2552 (target_pause_all): ... this.
2553 (unpause_all): Update the macro and rename to...
2554 (target_unpause_all): ... this.
2555 * target.cc (process_target::pause_all): Define.
2556 (process_target::unpause_all): Define.
2557
2558 Update the derived classes and callers below.
2559
2560 * server.cc (handle_status): Update.
2561 * tracepoint.cc (clear_installed_tracepoints): Update.
2562 (cmd_qtdp): Update.
2563 (cmd_qtstart): Update.
2564 (stop_tracing): Update.
2565 (cmd_qtstatus): Update.
2566 (upload_fast_traceframes): Update.
2567 (run_inferior_command): Update.
2568 * linux-low.cc (linux_target_ops): Update.
2569 (linux_pause_all): Turn into ...
2570 (linux_process_target::pause_all): ... this.
2571 (linux_unpause_all): Turn into ...
2572 (linux_process_target::unpause_all): ... this.
2573 (linux_process_target::prepare_to_access_memory): Update.
2574 (linux_process_target::done_accessing_memory): Update.
2575 * linux-low.h (class linux_process_target): Update.
2576 * lynx-low.cc (lynx_target_ops): Update.
2577 * nto-low.cc (nto_target_ops): Update.
2578 * win32-low.cc (win32_target_ops): Update.
2579
4e2e869c
TBA
25802020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2581
2582 Turn process_stratum_target's get_tib_address op into a method of
2583 process_target.
2584
2585 * target.h (struct process_stratum_target): Remove the target op.
2586 (class process_target): Add the target op. Also add
2587 'supports_get_tib_address'.
2588 * target.cc (process_target::get_tib_address): Define.
2589 (process_target::supports_get_tib_address): Define.
2590
2591 Update the derived classes and callers below.
2592
2593 * server.cc (handle_query): Update.
2594 * linux-low.cc (win32_target_ops): Update.
2595 * lynx-low.cc (lynx_target_ops): Update.
2596 * nto-low.cc (nto_target_ops): Update.
2597 * win32-low.cc (win32_target_ops): Update.
2598 (win32_process_target::supports_get_tib_address): Define.
2599 (win32_get_tib_address): Turn into ...
2600 (win32_process_target::get_tib_address): ... this.
2601 * win32-low.h (class win32_process_target): Update.
2602
68119632
TBA
26032020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2604
2605 Turn process_stratum_target's thread_stopped op into a method of
2606 process_target.
2607
2608 * target.h (struct process_stratum_target): Remove the target op.
2609 (class process_target): Add the target op. Also add
2610 'supports_thread_stopped'.
2611 (target_thread_stopped): Update the macro.
2612 * target.cc (process_target::thread_stopped): Define.
2613 (process_target::supports_thread_stopped): Define.
2614 (prepare_to_access_memory): Update.
2615
2616 Update the derived classes and callers below.
2617
2618 * server.cc (queue_stop_reply_callback): Update.
2619 * linux-low.cc (linux_target_ops): Update.
2620 (linux_process_target::supports_thread_stopped): Define.
2621 (linux_thread_stopped): Turn into ...
2622 (linux_process_target::thread_stopped): ... this.
2623 * linux-low.h (class linux_process_target): Update.
2624 * lynx-low.cc (lynx_target_ops): Update.
2625 * nto-low.cc (nto_target_ops): Update.
2626 * win32-low.cc (win32_target_ops): Update.
2627
770d8f6a
TBA
26282020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2629
2630 Turn process_stratum_target's read_pc and write_pc ops into
2631 methods of process_target.
2632
2633 * target.h (struct process_stratum_target): Remove the target ops.
2634 (class process_target): Add the target ops.
2635 * target.cc (process_target::read_pc): Define.
2636 (process_target::write_pc): Define.
2637
2638 Update the derived classes and callers below.
2639
2640 * regcache.cc (regcache_read_pc): Update.
2641 (regcache_write_pc): Update.
2642 * linux-low.cc (linux_target_ops): Update.
2643 (linux_read_pc): Turn into ...
2644 (linux_process_target::read_pc): ... this.
2645 (linux_write_pc): Turn into ...
2646 (linux_process_target::write_pc): ... this.
2647 * linux-low.h (class linux_process_target): Update.
2648 * lynx-low.cc (lynx_target_ops): Update.
2649 * nto-low.cc (nto_target_ops): Update.
2650 * win32-low.cc (win32_target_ops): Update.
2651
290732bf
TBA
26522020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2653
2654 Turn process_stratum_target's supports_tracepoints op into a
2655 method of process_target.
2656
2657 * target.h (struct process_stratum_target): Remove the target op.
2658 (class process_target): Add the target op.
2659 (target_supports_tracepoints): Update the macro.
2660 * target.cc (process_target::supports_tracepoints): Define.
2661
2662 Update the derived classes and callers below.
2663
2664 * linux-low.cc (linux_target_ops): Update.
2665 (linux_supports_tracepoints): Turn into ...
2666 (linux_process_target::supports_tracepoints): ... this.
2667 * linux-low.h (class linux_process_target): Update.
2668 * lynx-low.cc (lynx_target_ops): Update.
2669 * nto-low.cc (nto_target_ops): Update.
2670 * win32-low.cc (win32_target_ops): Update.
2671
0df28b1b
TBA
26722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2673
2674 Turn process_stratum_target's process_qsupported op into a method
2675 of process_target.
2676
2677 * target.h (struct process_stratum_target): Remove the target op.
2678 (class process_target): Add the target op.
2679 (target_process_qsupported): Update the macro.
2680 * target.cc (process_target::process_qsupported): Define.
2681
2682 Update the derived classes and callers below.
2683
2684 * linux-low.cc (linux_target_ops): Update.
2685 (linux_process_qsupported): Turn into ...
2686 (linux_process_target::process_qsupported): ... this.
2687 * linux-low.h (class linux_process_target): Update.
2688 * lynx-low.cc (lynx_target_ops): Update.
2689 * nto-low.cc (nto_target_ops): Update.
2690 * win32-low.cc (win32_target_ops): Update.
2691
9da41fda
TBA
26922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2693
2694 Turn process_stratum_target's read_loadmap op into a method of
2695 process_target.
2696
2697 * target.h (struct process_stratum_target): Remove the target op.
2698 (class process_target): Add the target op. Also add
2699 'supports_read_loadmap'.
2700 * target.cc (process_target::read_loadmap): Define.
2701 (process_target::supports_read_loadmap): Define.
2702
2703 Update the derived classes and callers below.
2704
2705 * server.cc (handle_qxfer_fdpic): Update.
2706 (handle_query): Update.
2707 * linux-low.cc (linux_target_ops): Update.
2708 (linux_process_target::supports_read_loadmap): Define.
2709 (linux_read_loadmap): Turn into ...
2710 (linux_process_target::read_loadmap): ... this.
2711 * linux-low.h (class linux_process_target): Update.
2712 * lynx-low.cc (lynx_target_ops): Update.
2713 * nto-low.cc (nto_target_ops): Update.
2714 * win32-low.cc (win32_target_ops): Update.
2715
95a45fc1
TBA
27162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2717
2718 Turn process_stratum_target's core_of_thread op into a method of
2719 process_target.
2720
2721 * target.h (struct process_stratum_target): Remove the target op.
2722 (class process_target): Add the target op.
2723 (target_core_of_thread): Update the macro.
2724 * target.cc (process_target::core_of_thread): Define.
2725
2726 Update the derived classes and callers below.
2727
2728 * linux-low.cc (linux_target_ops): Update.
2729 (linux_process_target::core_of_thread): Define.
2730 * linux-low.h (class linux_process_target): Update.
2731 * lynx-low.cc (lynx_target_ops): Update.
2732 * nto-low.cc (nto_target_ops): Update.
2733 * win32-low.cc (win32_target_ops): Update.
2734
55cf3021
TBA
27352020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2736
2737 Turn process_stratum_target's handle_monitor_command op into a
2738 method of process_target.
2739
2740 * target.h (struct process_stratum_target): Remove the target op.
2741 (class process_target): Add the target op.
2742 (target_handle_monitor_command): Update the macro.
2743 * target.cc (process_target::handle_monitor_command): Define.
2744
2745 Update the derived classes and callers below.
2746
2747 * server.cc (handle_query): Update.
2748 * linux-low.cc (linux_target_ops): Update.
2749 (linux_process_target::handle_monitor_command): Define.
2750 * linux-low.h (class linux_process_target): Update.
2751 * lynx-low.cc (lynx_target_ops): Update.
2752 * nto-low.cc (nto_target_ops): Update.
2753 * win32-low.cc (win32_target_ops): Update.
2754
fb00dfce
TBA
27552020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2756
2757 Turn process_stratum_target's handle_new_gdb_connection op into a
2758 method of process_target.
2759
2760 * target.h (struct process_stratum_target): Remove the target op.
2761 (class process_target): Add the target op.
2762 (target_handle_new_gdb_connection): Update the macro.
2763 * target.cc (process_target::handle_new_gdb_connection): Define.
2764
2765 Update the derived classes and callers below.
2766
2767 * linux-low.cc (linux_target_ops): Update.
2768 (linux_handle_new_gdb_connection): Turn into ...
2769 (linux_process_target::handle_new_gdb_connection): ... this.
2770 * linux-low.h (class linux_process_target): Update.
2771 * lynx-low.cc (lynx_target_ops): Update.
2772 * nto-low.cc (nto_target_ops): Update.
2773 * win32-low.cc (win32_target_ops): Update.
2774
9690a72a
TBA
27752020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2776
2777 Turn process_stratum_target's supports_fork_events,
2778 supports_vfork_events, and supports_exec_events ops into methods
2779 of process_target.
2780
2781 * target.h (struct process_stratum_target): Remove the target ops.
2782 (class process_target): Add the target ops.
2783 (target_supports_fork_events): Update the macro.
2784 (target_supports_vfork_events): Update the macro.
2785 (target_supports_exec_events): Update the macro.
2786 * target.cc (process_target::supports_fork_events): Define.
2787 (process_target::supports_vfork_events): Define.
2788 (process_target::supports_exec_events): Define.
2789
2790 Update the derived classes and callers below.
2791
2792 * linux-low.cc (linux_target_ops): Update.
2793 (linux_supports_fork_events): Turn into ...
2794 (linux_process_target::supports_fork_events): ... this.
2795 (linux_supports_vfork_events): Turn into ...
2796 (linux_process_target::supports_vfork_events): ... this.
2797 (linux_supports_exec_events): Turn into ...
2798 (linux_process_target::supports_exec_events): ... this.
2799 * linux-low.h (class linux_process_target): Update.
2800 * lynx-low.cc (lynx_target_ops): Update.
2801 * nto-low.cc (nto_target_ops): Update.
2802 * win32-low.cc (win32_target_ops): Update.
2803
652aef77
TBA
28042020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2805
2806 Turn process_stratum_target's supports_multi_process op into a
2807 method of process_target.
2808
2809 * target.h (struct process_stratum_target): Remove the target op.
2810 (class process_target): Add the target op.
2811 * target.cc (process_target::supports_multi_process): Define.
2812 (target_supports_multi_process): Update.
2813
2814 Update the derived classes and callers below.
2815
2816 * linux-low.cc (linux_target_ops): Update.
2817 (linux_supports_multi_process): Turn into ...
2818 (linux_process_target::supports_multi_process): ... this.
2819 * linux-low.h (class linux_process_target): Update.
2820 * lynx-low.cc (lynx_target_ops): Update.
2821 * nto-low.cc (nto_target_ops): Update.
2822 * win32-low.cc (win32_target_ops): Update.
2823
0dc587d4
TBA
28242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2825
2826 Turn process_stratum_target's supports_non_stop, async, and
2827 start_non_stop ops into methods of process_target.
2828
2829 * target.h (struct process_stratum_target): Remove the target ops.
2830 (class process_target): Add the target ops.
2831 (target_supports_non_stop): Update the macro.
2832 (target_async): Update the macro.
2833 (start_non_stop): Remove declaration.
2834 * target.cc (process_target::supports_non_stop): Define.
2835 (process_target::async): Define.
2836 (process_target::start_non_stop): Define.
2837 (start_non_stop): Remove.
2838
2839 Update the derived classes and callers below.
2840
2841 * server.cc (handle_qxfer_siginfo): Update.
2842 (handle_query): Update.
2843 * linux-low.cc (linux_target_ops): Update.
2844 (linux_supports_non_stop): Turn into ...
2845 (linux_process_target::supports_non_stop): ... this.
2846 (linux_async): Turn into ...
2847 (linux_process_target::async): ... this.
2848 (linux_start_non_stop): Turn into ...
2849 (linux_process_target::start_non_stop): ... this.
2850 * linux-low.h (class linux_process_target): Update.
2851 * lynx-low.cc (lynx_target_ops): Update.
2852 * nto-low.cc (nto_target_ops): Update.
2853 (nto_supports_non_stop): Remove; rely on the default behavior
2854 instead.
2855 * win32-low.cc (win32_target_ops): Update.
2856
d7abedf7
TBA
28572020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2858
2859 Turn process_stratum_target's qxfer_siginfo op into a method of
2860 process_target.
2861
2862 * target.h (struct process_stratum_target): Remove the target op.
2863 (class process_target): Add the target op. Also add
2864 'supports_qxfer_siginfo'.
2865 * target.cc (process_target::qxfer_siginfo): Define.
2866 (process_target::supports_qxfer_siginfo): Define.
2867
2868 Update the derived classes and callers below.
2869
2870 * server.cc (handle_qxfer_siginfo): Update.
2871 (handle_query): Update.
2872 * linux-low.cc (linux_target_ops): Update.
2873 (linux_process_target::supports_qxfer_siginfo): Define.
2874 (linux_xfer_siginfo): Turn into ...
2875 (linux_process_target::qxfer_siginfo): ... this.
2876 * linux-low.h (class linux_process_target): Update.
2877 * lynx-low.cc (lynx_target_ops): Update.
2878 * nto-low.cc (nto_target_ops): Update.
2879 * win32-low.cc (win32_target_ops): Update.
2880
2d0795ee
TBA
28812020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2882
2883 Turn process_stratum_target's qxfer_osdata op into a method of
2884 process_target.
2885
2886 * target.h (struct process_stratum_target): Remove the target op.
2887 (class process_target): Add the target op. Also add
2888 'supports_qxfer_osdata'.
2889 * target.cc (process_target::qxfer_osdata): Define.
2890 (process_target::supports_qxfer_osdata): Define.
2891
2892 Update the derived classes and callers below.
2893
2894 * server.cc (handle_qxfer_osdata): Update.
2895 (handle_query): Update.
2896 * linux-low.cc (linux_target_ops): Update.
2897 (linux_process_target::supports_qxfer_osdata): Define.
2898 (linux_qxfer_osdata): Turn into ...
2899 (linux_process_target::qxfer_osdata): ... this.
2900 * linux-low.h (class linux_process_target): Update.
2901 * lynx-low.cc (lynx_target_ops): Update.
2902 * nto-low.cc (nto_target_ops): Update.
2903 * win32-low.cc (win32_target_ops): Update.
2904
ea06bbaa
TBA
29052020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2906
2907 Turn process_stratum_target's hostio_last_error op into a
2908 method of process_target.
2909
2910 * target.h (struct process_stratum_target): Remove the target op.
2911 (class process_target): Add the target op.
2912 * target.cc: Add "hostio.h" to includes.
2913 (process_target::hostio_last_error): Define.
2914
2915 Update the derived classes and callers below.
2916
2917 * hostio.cc (hostio_error): Update.
2918 * linux-low.cc: Remove "hostio.h" from includes.
2919 (linux_target_ops): Update.
2920 * lynx-low.cc (lynx_target_ops): Update.
2921 * nto-low.cc (nto_target_ops): Update.
2922 * win32-low.h (class win32_process_target): Update.
2923 * win32-low.cc (win32_target_ops): Update.
2924 (wince_hostio_last_error): Turn into ...
2925 (win32_process_target::hostio_last_error): ... this.
2926
6e3fd7e9
TBA
29272020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2928
2929 Turn process_stratum_target's get_tls_address op into a method of
2930 process_target.
2931
2932 * target.h (struct process_stratum_target): Remove the target op.
2933 (class process_target): Add the target op. Also add
2934 'supports_get_tls_address'.
2935 * target.cc (process_target::get_tls_address): Define.
2936 (process_target::supports_get_tls_address): Define.
2937
2938 Update the derived classes and callers below.
2939
2940 * server.cc (handle_query): Update.
2941 * linux-low.cc (linux_target_ops): Update.
2942 (linux_process_target::supports_get_tls_address): Define.
2943 (linux_process_target::get_tls_address): Define.
2944 * linux-low.h (class linux_process_target): Update.
2945 * lynx-low.cc (lynx_target_ops): Update.
2946 * nto-low.cc (nto_target_ops): Update.
2947 * win32-low.cc (win32_target_ops): Update.
2948
5203ae1e
TBA
29492020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2950
2951 Turn process_stratum_target's read_offsets op into a method of
2952 process_target.
2953
2954 * target.h (struct process_stratum_target): Remove the target op.
2955 (class process_target): Add the target op. Also add
2956 'supports_read_offsets'.
2957 * target.cc (process_target::read_offsets): Define.
2958 (process_target::supports_read_offsets): Define.
2959
2960 Update the derived classes and callers below.
2961
2962 * server.cc (handle_query): Update.
2963 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
2964 (linux_target_ops): Update.
2965 (linux_process_target::supports_read_offsets): Define.
2966 (linux_read_offsets): Turn into ...
2967 (linux_process_target::read_offsets): ... this.
2968 * linux-low.h (class linux_process_target): Update.
2969 * lynx-low.cc (lynx_target_ops): Update.
2970 * nto-low.cc (nto_target_ops): Update.
2971 * win32-low.cc (win32_target_ops): Update.
2972
6eeb5c55
TBA
29732020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2974
2975 Turn process_stratum_target's stopped_by_watchpoint and
2976 stopped_data_address ops into methods of process_target.
2977
2978 * target.h (struct process_stratum_target): Remove the target ops.
2979 (class process_target): Add the target ops.
2980 * target.cc (process_target::stopped_by_watchpoint): Define.
2981 (process_target::stopped_data_address): Define.
2982
2983 Update the derived classes and callers below.
2984
2985 * remote-utils.cc (prepare_resume_reply): Update.
2986 * linux-low.cc (linux_target_ops): Update.
2987 (linux_stopped_by_watchpoint): Turn into ...
2988 (linux_process_target::stopped_by_watchpoint): ... this.
2989 (linux_stopped_data_address): Turn into ...
2990 (linux_process_target::stopped_data_address): ... this.
2991 * linux-low.h (class linux_process_target): Update.
2992 * lynx-low.cc (lynx_target_ops): Update.
2993 * nto-low.cc (nto_target_ops): Update.
2994 (nto_stopped_by_watchpoint): Turn into ...
2995 (nto_process_target::stopped_by_watchpoint): ... this.
2996 (nto_stopped_data_address): Turn into ...
2997 (nto_process_target::stopped_data_address): ... this.
2998 * nto-low.h (class nto_process_target): Update.
2999 * win32-low.cc (win32_target_ops): Update.
3000 (win32_stopped_by_watchpoint): Turn into ...
3001 (win32_process_target::stopped_by_watchpoint): ... this.
3002 (win32_stopped_data_address): Turn into ...
3003 (win32_process_target::stopped_data_address): ... this.
3004 * win32-low.h (class win32_process_target): Update.
3005
22aa6223
TBA
30062020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3007
3008 Turn process_stratum_target's supports_hardware_single_step op into
3009 a method of process_target.
3010
3011 * target.h (struct process_stratum_target): Remove the target op.
3012 (class process_target): Add the target op.
3013 (target_supports_hardware_single_step): Update the macro.
3014 (target_can_do_hardware_single_step): Remove declaration.
3015 * target.cc (process_target::supports_hardware_single_step): Define.
3016 (target_can_do_hardware_single_step): Remove.
3017
3018 Update the derived classes and callers below.
3019
3020 * linux-low.h (class linux_process_target): Update.
3021 * linux-low.cc (linux_target_ops): Update.
3022 (linux_supports_hardware_single_step): Turn into ...
3023 (linux_process_target::supports_hardware_single_step): ... this.
3024 * lynx-low.h (class lynx_process_target): Update.
3025 * lynx-low.cc (lynx_target_ops): Update.
3026 (lynx_process_target::supports_hardware_single_step): Define.
3027 * nto-low.h (class nto_process_target): Update.
3028 * nto-low.cc (nto_target_ops): Update.
3029 (nto_process_target::supports_hardware_single_step): Define.
3030 * win32-low.h (class win32_process_target): Update.
3031 * win32-low.cc (win32_target_ops): Update.
3032 (win32_process_target::supports_hardware_single_step): Define.
3033
93fe88b2
TBA
30342020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3035
3036 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3037 ops into methods of process_target.
3038
3039 * target.h (struct process_stratum_target): Remove the target ops.
3040 (class process_target): Add the target ops.
3041 (target_stopped_by_hw_breakpoint): Update the macro.
3042 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3043 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3044 (process_target::supports_stopped_by_hw_breakpoint): Define.
3045
3046 Update the derived classes and callers below.
3047
3048 * linux-low.cc (linux_target_ops): Update.
3049 (linux_stopped_by_hw_breakpoint): Turn into ...
3050 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3051 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3052 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3053 * linux-low.h (class linux_process_target): Update.
3054 * lynx-low.cc (lynx_target_ops): Update.
3055 * nto-low.cc (nto_target_ops): Update.
3056 * win32-low.cc (win32_target_ops): Update.
3057
84320c4e
TBA
30582020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3059
3060 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3061 ops into methods of process_target.
3062
3063 * target.h (struct process_stratum_target): Remove the target ops.
3064 (class process_target): Add the target ops.
3065 (target_stopped_by_sw_breakpoint): Update the macro.
3066 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3067 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3068 (process_target::supports_stopped_by_sw_breakpoint): Define.
3069
3070 Update the derived classes and callers below.
3071
3072 * linux-low.cc (linux_target_ops): Update.
3073 (linux_stopped_by_sw_breakpoint): Turn into ...
3074 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3075 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3076 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3077 * linux-low.h (class linux_process_target): Update.
3078 * lynx-low.cc (lynx_target_ops): Update.
3079 * nto-low.cc (nto_target_ops): Update.
3080 * win32-low.cc (win32_target_ops): Update.
3081
7e0bde70
TBA
30822020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3083
3084 Turn process_stratum_target's insert_point and remove_point ops
3085 into methods of process_target.
3086
3087 * target.h (struct process_stratum_target): Remove the target ops.
3088 (class process_target): Add the target ops.
3089 * target.cc (process_target::insert_point): Define.
3090 (process_target::remove_point): Define.
3091
3092 Update the derived classes and callers below.
3093
3094 * mem-break.cc (set_raw_breakpoint_at): Update.
3095 (delete_raw_breakpoint): Update.
3096 (uninsert_raw_breakpoint): Update.
3097 (reinsert_raw_breakpoint): Update.
3098 * linux-low.cc (linux_target_ops): Update.
3099 (linux_insert_point): Turn into ...
3100 (linux_process_target::insert_point): ... this.
3101 (linux_remove_point): Turn into ...
3102 (linux_process_target::remove_point): ... this.
3103 * linux-low.h (class linux_process_target): Update.
3104 * lynx-low.cc (lynx_target_ops): Update.
3105 * nto-low.cc (nto_target_ops): Update.
3106 (nto_insert_point): Turn into ...
3107 (nto_process_target::insert_point): ... this.
3108 (nto_remove_point): Turn into ...
3109 (nto_process_target::remove_point): ... this.
3110 * nto-low.h (class nto_process_target): Update.
3111 * win32-low.cc (win32_target_ops): Update.
3112 (win32_insert_point): Turn into ...
3113 (win32_process_target::insert_point): ... this.
3114 (win32_remove_point): Turn into ...
3115 (win32_process_target::remove_point): ... this.
3116 * win32-low.h (class win32_process_target): Update.
3117
a2b2297a
TBA
31182020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3119
3120 Turn process_stratum_target's supports_z_point_type op into a
3121 method of process_target.
3122
3123 * target.h (struct process_stratum_target): Remove the target op.
3124 (class process_target): Add the target op.
3125 * target.cc (process_target::supports_z_point_type): Define.
3126
3127 Update the derived classes and callers below.
3128
3129 * mem-break.cc (z_type_supported): Update.
3130 * linux-low.cc (linux_target_ops): Update.
3131 (linux_supports_z_point_type): Turn into ...
3132 (linux_process_target::supports_z_point_type): ... this.
3133 * linux-low.h (class linux_process_target): Update.
3134 * lynx-low.cc (lynx_target_ops): Update.
3135 * nto-low.cc (nto_target_ops): Update.
3136 (nto_supports_z_point_type): Turn into ...
3137 (nto_process_target::supports_z_point_type): ... this.
3138 * nto-low.h (class nto_process_target): Update.
3139 * win32-low.cc (win32_target_ops): Update.
3140 (win32_supports_z_point_type): Turn into ...
3141 (win32_process_target::supports_z_point_type): ... this.
3142 * win32-low.h (class win32_process_target): Update.
3143
eac215cc
TBA
31442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3145
3146 Turn process_stratum_target's read_auxv op into a method of
3147 process_target.
3148
3149 * target.h (class process_stratum_target): Remove the target op.
3150 (struct process_target): Add the target op. Also add
3151 'supports_read_auxv'.
3152 * target.cc (process_target::read_auxv): Define.
3153 (process_target::supports_read_auxv): Define.
3154
3155 Update the derived classes and callers below.
3156
3157 * server.cc (handle_qxfer_auxv): Update.
3158 (handle_query): Update.
3159 * linux-low.cc (linux_target_ops): Update.
3160 (linux_process_target::supports_read_auxv): Define.
3161 (linux_read_auxv): Turn into ...
3162 (linux_process_target::read_auxv): ... this.
3163 * linux-low.h (class linux_process_target): Update.
3164 * lynx-low.cc (lynx_target_ops): Update.
3165 * nto-low.cc (nto_target_ops): Update.
3166 (nto_process_target::supports_read_auxv): Define.
3167 (nto_read_auxv): Turn into ...
3168 (nto_process_target::read_auxv): ... this.
3169 * nto-low.h (class nto_process_target): Update.
3170 * win32-low.cc (win32_target_ops): Update.
3171
eb497a2a
TBA
31722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3173
3174 Turn process_stratum_target's request_interrupt op into a method of
3175 process_target.
3176
3177 * target.h (struct process_stratum_target): Remove the target op.
3178 (class process_target): Add the target op.
3179
3180 Update the derived classes and callers below.
3181
3182 * remote-utils.cc (putpkt_binary_1): Update.
3183 (input_interrupt): Update.
3184 (getpkt): Update.
3185 * server.cc (handle_v_requests): Update.
3186 * linux-low.cc (linux_target_ops): Update.
3187 (linux_request_interrupt): Turn into ...
3188 (linux_process_target::request_interrupt): ... this.
3189 * linux-low.h (class linux_process_target): Update.
3190 * lynx-low.cc (lynx_target_ops): Update.
3191 (lynx_request_interrupt): Turn into ...
3192 (lynx_process_target::request_interrupt): ... this.
3193 * lynx-low.h (class lynx_process_target): Update.
3194 * nto-low.cc (nto_target_ops): Update.
3195 (nto_request_interrupt): Turn into ...
3196 (nto_process_target::request_interrupt): ... this.
3197 * nto-low.h (class nto_process_target): Update.
3198 * win32-low.cc (win32_target_ops): Update.
3199 (win32_request_interrupt): Turn into ...
3200 (win32_process_target::request_interrupt): ... this.
3201 * win32-low.h (class win32_process_target): Update.
3202
2a31c7aa
TBA
32032020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3204
3205 Turn process_stratum_target's look_up_symbols op into a method of
3206 process_target.
3207
3208 * target.h (struct process_stratum_target): Remove the target op.
3209 (class process_target): Add the target op.
3210 * target.cc (process_target::look_up_symbols): Define.
3211
3212 Update the derived classes and callers below.
3213
3214 * server.cc (handle_query): Update.
3215 * linux-low.cc (linux_target_ops): Update.
3216 (linux_look_up_symbols): Turn into ...
3217 (linux_process_target::look_up_symbols): ... this.
3218 * linux-low.h (class linux_process_target): Update.
3219 * lynx-low.cc (lynx_target_ops): Update.
3220 * nto-low.cc (nto_target_ops): Update.
3221 * win32-low.cc (win32_target_ops): Update.
3222
e2558df3
TBA
32232020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3224
3225 Turn process_stratum_target's read_memory and write_memory
3226 ops into methods of process_target.
3227
3228 * target.h (struct process_stratum_target): Remove the target ops.
3229 (class process_target): Add the target ops.
3230
3231 Update the derived classes and callers below.
3232
3233 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3234 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3235 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3236 (arm_get_syscall_trapinfo): Update.
3237 * linux-cris-low.cc (cris_breakpoint_at): Update.
3238 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3239 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3240 * linux-mips-low.cc (mips_breakpoint_at): Update.
3241 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3242 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3243 * linux-sh-low.cc (sh_breakpoint_at): Update.
3244 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3245 (sparc_store_gregset_from_stack): Update.
3246 (sparc_breakpoint_at): Update.
3247 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3248 * linux-tile-low.cc (tile_breakpoint_at): Update.
3249 * linux-x86-low.cc (x86_breakpoint_at): Update.
3250 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3251 * mem-brea.cc (insert_memory_breakpoint): Update.
3252 (validate_inserted_breakpoint): Update.
3253 * target.cc (read_inferior_memory): Update.
3254 (target_write_memory): Update.
3255 * linux-low.cc (linux_target_ops): Update.
3256 (linux_read_memory): Make a wrapper around the read_memory target
3257 op call.
3258 (linux_process_target::read_memory): Rename from linux_read_memory.
3259 (linux_write_memory): Turn into ...
3260 (linux_process_target::write_memory): ... this.
3261 * linux-low.h (class linux_process_target): Update.
3262 * lynx-low.cc (lynx_target_ops): Update.
3263 (lynx_read_memory): Turn into ...
3264 (lynx_process_target::read_memory): ... this.
3265 (lynx_write_memory): Turn into ...
3266 (lynx_process_target::write_memory): ... this.
3267 * lynx-low.h (class lynx_process_target): Update.
3268 * nto-low.cc (nto_target_ops): Update.
3269 (nto_read_memory): Turn into ...
3270 (nto_process_target::read_memory): ... this.
3271 (nto_write_memory): Turn into ...
3272 (nto_process_target::write_memory): ... this.
3273 * nto-low.h (class nto_process_target): Update.
3274 * win32-low.cc (win32_target_ops): Update.
3275 (win32_read_inferior_memory): Turn into ...
3276 (win32_process_target::read_memory): ... this.
3277 (win32_write_inferior_memory): Turn into ...
3278 (win32_process_target::write_memory): ... this.
3279 * win32-low.h (class win32_process_target): Update.
3280
79b44087
TBA
32812020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3282
3283 Turn process_stratum_target's prepare_to_access_memory and
3284 done_accessing_memory ops into methods of process_target.
3285
3286 * target.h (struct process_stratum_target): Remove the target ops.
3287 (class process_target): Add the target ops.
3288 * target.cc (process_target::prepare_to_access_memory): Define.
3289 (process_target::done_accessing_memory): Define.
3290 (prepare_to_access_memory): Update.
3291 (done_accessing_memory): Update.
3292
3293 Update the derived classes and callers below.
3294
3295 * linux-low.cc (linux_target_ops): Update.
3296 (linux_prepare_to_access_memory): Turn into ...
3297 (linux_process_target::prepare_to_access_memory): ... this.
3298 (linux_done_accessing_memory): Turn into ...
3299 (linux_process_target::done_accessing_memory): ... this.
3300 * linux-low.h (class linux_process_target): Update.
3301 * lynx-low.cc (lynx_target_ops): Update.
3302 * nto-low.cc (nto_target_ops): Update.
3303 * win32-low.cc (win32_target_ops): Update.
3304
a5a4d4cd
TBA
33052020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3306
3307 Turn process_stratum_target's fetch_registers and store_registers
3308 ops into methods of process_target.
3309
3310 * target.h (struct process_stratum_target): Remove the target ops.
3311 (class process_target): Add the target ops.
3312 (fetch_inferior_registers): Update the macro.
3313 (store_inferior_registers): Update the macro.
3314
3315 Update the derived classes and callers below.
3316
3317 * linux-low.cc (linux_target_ops): Update.
3318 (linux_fetch_registers): Turn into ...
3319 (linux_process_target::fetch_registers): ... this.
3320 (linux_store_registers): Turn into ...
3321 (linux_process_target::store_registers): ... this.
3322 * linux-low.h (class linux_process_target): Update.
3323 * lynx-low.cc (lynx_target_ops): Update.
3324 (lynx_fetch_registers): Turn into ...
3325 (lynx_process_target::fetch_registers): ... this.
3326 (lynx_store_registers): Turn into ...
3327 (lynx_process_target::store_registers): ... this.
3328 * lynx-low.h (class lynx_process_target): Update.
3329 * nto-low.cc (nto_target_ops): Update.
3330 (nto_fetch_registers): Turn into ...
3331 (nto_process_target::fetch_registers): ... this.
3332 (nto_store_registers): Turn into ...
3333 (nto_process_target::store_registers): ... this.
3334 * nto-low.h (class nto_process_target): Update.
3335 * win32-low.cc (win32_target_ops): Update.
3336 (win32_fetch_inferior_registers): Turn into ...
3337 (win32_process_target::fetch_registers): ... this.
3338 (win32_store_inferior_registers): Turn into ...
3339 (win32_process_target::store_registers): ... this.
3340 * win32-low.h (class win32_process_target): Update.
3341
6532e7e3
TBA
33422020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3343
3344 Turn process_stratum_target's wait op into a method of
3345 process_target.
3346
3347 * target.h (struct process_stratum_target): Remove the target op.
3348 (class process_target): Add the target op.
3349
3350 Update the derived classes and callers below.
3351
3352 * target.cc (target_wait): Update.
3353 * linux-low.cc (linux_target_ops): Update.
3354 (linux_wait): Turn into ...
3355 (linux_process_target::wait): ... this.
3356 * linux-low.h (class linux_process_target): Update.
3357 * lynx-low.cc (lynx_target_ops): Update.
3358 (lynx_wait): Turn into ...
3359 (lynx_process_target::wait): ... this.
3360 * lynx-low.h (class lynx_process_target): Update.
3361 * nto-low.cc (nto_target_ops): Update.
3362 (nto_wait): Turn into ...
3363 (nto_process_target::wait): ... this.
3364 * nto-low.h (class nto_process_target): Update.
3365 * win32-low.cc (win32_target_ops): Update.
3366 (win32_wait): Turn into ...
3367 (win32_process_target::wait): ... this.
3368 (do_initial_child_stuff): Update.
3369 * win32-low.h (class win32_process_target): Update.
3370
0e4d7e35
TBA
33712020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3372
3373 Turn process_stratum_target's resume op into a method of
3374 process_target.
3375
3376 * target.h (struct process_stratum_target): Remove the target op.
3377 (class process_target): Add the target op.
3378
3379 Update the derived classes and callers below.
3380
3381 * server.cc (resume): Update.
3382 * target.cc (target_stop_and_wait): Update.
3383 (target_continue_no_signal): Update.
3384 (target_continue): Update.
3385 * linux-low.cc (linux_target_ops): Update.
3386 (linux_resume): Turn into ...
3387 (linux_process_target::resume): ... this.
3388 * linux-low.h (class linux_process_target): Update.
3389 * lynx-low.cc (lynx_target_ops): Update.
3390 (lynx_resume): Turn into ...
3391 (lynx_process_target::resume): ... this.
3392 * lynx-low.h (class lynx_process_target): Update.
3393 * nto-low.cc (nto_target_ops): Update.
3394 (nto_resume): Turn into ...
3395 (nto_process_target::resume): ... this.
3396 * nto-low.h (class nto_process_target): Update.
3397 * win32-low.cc (win32_target_ops): Update.
3398 (win32_resume): Turn into ...
3399 (win32_process_target::resume): ... this.
3400 (win32_process_target::detach): Update.
3401 (do_initial_child_stuff): Update.
3402 * win32-low.h (class win32_process_target): Update.
3403
13d3d99b
TBA
34042020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3405
3406 Turn process_stratum_target's thread_alive op into a method of
3407 process_target.
3408
3409 * target.h (struct process_stratum_target): Remove the target op.
3410 (class process_target): Add the target op.
3411 (mythread_alive): Update the macro.
3412
3413 Update the derived classes and callers below.
3414
3415 * linux-low.cc (linux_target_ops): Update.
3416 (linux_thread_alive): Turn into ...
3417 (linux_process_target::thread_alive): ... this.
3418 (wait_for_sigstop): Update.
3419 * linux-low.h (class linux_process_target): Update.
3420 * lynx-low.cc (lynx_target_ops): Update.
3421 (lynx_thread_alive): Turn into ...
3422 (lynx_process_target::thread_alive): ... this.
3423 * lynx-low.h (class lynx_process_target): Update.
3424 * nto-low.cc (nto_target_ops): Update.
3425 (nto_thread_alive): Turn into ...
3426 (nto_process_target::thread_alive): ... this.
3427 * nto-low.h (class nto_process_target): Update.
3428 * win32-low.cc (win32_target_ops): Update.
3429 (win32_thread_alive): Turn into ...
3430 (win32_process_target::thread_alive): ... this.
3431 * win32-low.h (class win32_process_target): Update.
3432
95a49a39
TBA
34332020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3434
3435 Turn process_stratum_target's join op into a method of
3436 process_target.
3437
3438 * target.h (struct process_stratum_target): Remove the target op.
3439 (class process_target): Add the target op.
3440 (join_inferior): Update the macro.
3441
3442 Update the derived classes and callers below.
3443
3444 * linux-low.cc (linux_target_ops): Update.
3445 (linux_join): Turn into ...
3446 (linux_process_target::join): ... this.
3447 * linux-low.h (class linux_process_target): Update.
3448 * lynx-low.cc (lynx_target_ops): Update.
3449 (lynx_join): Turn into ...
3450 (lynx_process_target::join): ... this.
3451 * lynx-low.h (class lynx_process_target): Update.
3452 * nto-low.cc (nto_target_ops): Update.
3453 (nto_process_target::join): Define.
3454 * nto-low.h (class nto_process_target): Update.
3455 * win32-low.cc (win32_target_ops): Update.
3456 (win32_join): Turn into ...
3457 (win32_process_target::join): ... this.
3458 * win32-low.h (class win32_process_target): Update.
3459
8adb37b9
TBA
34602020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3461
3462 Turn process_stratum_target's mourn op into a method of
3463 process_target.
3464
3465 * target.h (struct process_stratum_target): Remove the target op.
3466 (class process_target): Add the target op.
3467
3468 Update the derived classes and callers below.
3469
3470 * target.cc (target_mourn_inferior): Update.
3471 * linux-low.cc (linux_target_ops): Update.
3472 (linux_mourn): Turn into ...
3473 (linux_process_target::mourn): ... this.
3474 (handle_extended_wait): Update.
3475 (linux_process_target::kill): Update.
3476 (linux_process_target::detach): Update.
3477 * linux-low.h (class linux_process_target): Update.
3478 * lynx-low.cc (lynx_target_ops): Update.
3479 (lynx_mourn): Turn into ...
3480 (lynx_process_target::mourn): ... this.
3481 * lynx-low.h (class lynx_process_target): Update.
3482 * nto-low.cc (nto_target_ops): Update.
3483 (nto_mourn): Turn into ...
3484 (nto_process_target::mourn): ... this.
3485 * nto-low.h (class nto_process_target): Update.
3486 * win32-low.cc (win32_target_ops): Update.
3487 (win32_mourn): Turn into ...
3488 (win32_process_target::mourn): ... this.
3489 * win32-low.h (class win32_process_target): Update.
3490
9061c9cf
TBA
34912020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3492
3493 Turn process_stratum_target's detach op into a method of
3494 process_target.
3495
3496 * target.h (struct process_stratum_target): Remove the target op.
3497 (class process_target): Add the target op.
3498 (detach_inferior): Update the macro.
3499
3500 Update the derived classes and callers below.
3501
3502 * linux-low.cc (linux_target_ops): Update.
3503 (linux_detach): Turn into ...
3504 (linux_process_target::detach): ... this.
3505 * linux-low.h (class linux_process_target): Update.
3506 * lynx-low.cc (lynx_target_ops): Update.
3507 (lynx_detach): Turn into ...
3508 (lynx_process_target::detach): ... this.
3509 * lynx-low.h (class lynx_process_target): Update.
3510 * nto-low.cc (nto_target_ops): Update.
3511 (nto_detach): Turn into ...
3512 (nto_process_target::detach): ... this.
3513 * nto-low.h (class nto_process_target): Update.
3514 * win32-low.cc (win32_target_ops): Update.
3515 (win32_detach): Turn into ...
3516 (win32_process_target::detach): ... this.
3517 * win32-low.h (class win32_process_target): Update.
3518
c6885a57
TBA
35192020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3520
3521 Turn process_stratum_target's kill op into a method of
3522 process_target.
3523
3524 * target.h (struct process_stratum_target): Remove the target op.
3525 (class process_target): Add the target op.
3526
3527 Update the derived classes and callers below.
3528
3529 * target.cc (kill_inferior): Update.
3530 * linux-low.cc (linux_target_ops): Update.
3531 (linux_kill): Turn into ...
3532 (linux_process_target::kill): ... this.
3533 * linux-low.h (class linux_process_target): Update.
3534 * lynx-low.cc (lynx_target_ops): Update.
3535 (lynx_kill): Turn into ...
3536 (lynx_process_target::kill): ... this.
3537 * lynx-low.h (class lynx_process_target): Update.
3538 * nto-low.cc (nto_target_ops): Update.
3539 (nto_kill): Turn into ...
3540 (nto_process_target::kill): ... this.
3541 * nto-low.h (class nto_process_target): Update.
3542 * win32-low.cc (win32_target_ops): Update.
3543 (win32_kill): Turn into ...
3544 (win32_process_target::kill): ... this.
3545 * win32-low.h (class win32_process_target): Update.
3546
ef03dad8
TBA
35472020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3548
3549 Turn process_stratum_target's attach op into a method of
3550 process_target.
3551
3552 * target.h (struct process_stratum_target): Remove the target op.
3553 (class process_target): Add the target op.
3554 (myattach): Update the macro.
3555
3556 Update the derived classes and callers below.
3557
3558 * linux-low.cc (linux_target_ops): Update.
3559 (linux_attach): Turn into ...
3560 (linux_process_target::attach): ... this.
3561 * linux-low.h (class linux_process_target): Update.
3562 * lynx-low.cc (lynx_target_ops): Update.
3563 (lynx_attach): Turn into ...
3564 (lynx_process_target::attach): ... this.
3565 * lynx-low.h (class lynx_process_target): Update.
3566 * nto-low.cc (nto_target_ops): Update.
3567 (nto_attach): Turn into ...
3568 (nto_process_target::attach): ... this.
3569 * nto-low.h (class nto_process_target): Update.
3570 * win32-low.cc (win32_target_ops): Update.
3571 (win32_attach): Turn into ...
3572 (win32_process_target::attach): ... this.
3573 * win32-low.h (class win32_process_target): Update.
3574
6dee9afb
TBA
35752020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3576
3577 Turn process_stratum_target's post_create_inferior op into a method
3578 of process_target.
3579
3580 * target.h (struct process_stratum_target): Remove the target op.
3581 (class process_target): Add the target op.
3582 (target_post_create_inferior): Update the macro.
3583 * target.cc (process_target::post_create_inferior): Define.
3584
3585 Update the derived classes and callers below.
3586
3587 * linux-low.cc (linux_target_ops): Update.
3588 (linux_post_create_inferior): Turn into ...
3589 (linux_process_target::post_create_inferior): ... this.
3590 * linux-low.h (class linux_process_target): Update.
3591 * lynx-low.cc (lynx_target_ops): Update.
3592 * nto-low.cc (nto_target_ops): Update.
3593 * win32-low.cc (win32_target_ops): Update.
3594
15295543
TBA
35952020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3596
3597 Turn process_stratum_target's create_inferior op into a method of
3598 process_target.
3599
3600 * target.h (struct process_stratum_target): Remove the target op.
3601 (class process_target): Add the target op.
3602 (create_inferior): Rename the macro to ...
3603 (target_create_inferior): ... this.
3604
3605 Update the derived classes and callers below.
3606
3607 * server.cc (handle_v_run): Update.
3608 (captured_main): Update.
3609 (process_serial_event): Update.
3610 * linux-low.cc (linux_target_ops): Update.
3611 (linux_create_inferior): Turn into ...
3612 (linux_process_target::create_inferior): ... this.
3613 * linux-low.h (class linux_process_target): Update.
3614 * lynx-low.cc (lynx_target_ops): Update.
3615 (lynx_create_inferior): Turn into ...
3616 (lynx_process_target::create_inferior): ... this.
3617 * lynx-low.h (class lynx_process_target): Update.
3618 * nto-low.cc (nto_target_ops): Update.
3619 (nto_create_inferior): Turn into ...
3620 (nto_process_target::create_inferior): ... this.
3621 * nto-low.h (class nto_process_target): Update.
3622 * win32-low.cc (win32_target_ops): Update.
3623 (win32_create_inferior): Turn into ...
3624 (win32_process_target::create_inferior): ... this.
3625 * win32-low.h (class win32_process_target): Update.
3626
5ef9273d
TBA
36272020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3628
3629 * target.h (class process_target): New class definition.
3630 (struct process_stratum_target) <pt>: New field with type
3631 'process_target*'.
3632 * linux-low.h (class linux_process_target): Define as a derived
3633 class of 'process_target'.
3634 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3635 as the 'pt' field.
3636 * lynx-low.h (class lynx_process_target): Define as a derived
3637 class of 'process_target'.
3638 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3639 as the 'pt' field.
3640 * nto-low.h (class nto_process_target): Define as a derived
3641 class of 'process_target'.
3642 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3643 as the 'pt' field.
3644 * win32-low.h (class win32_process_target): Define as a derived
3645 class of 'process_target'.
3646 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3647 as the 'pt' field.
3648
9f1528a1
AB
36492020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3650
3651 * configure: Regenerate.
3652
bf84f706
MR
36532020-02-19 Maciej W. Rozycki <macro@wdc.com>
3654 Andrew Burgess <andrew.burgess@embecosm.com>
3655
3656 * linux-riscv-low.cc: New file.
3657 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3658 and nat/riscv-linux-tdesc.c.
3659 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3660 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3661 Define.
3662
1a627e7e
TT
36632020-02-14 Tom Tromey <tom@tromey.com>
3664
3665 * acinclude.m4: Don't include acx_configure_dir.m4.
3666 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3667 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3668 (all, install-only, uninstall, clean-info, clean)
3669 (maintainer-clean): Don't recurse.
3670 (subdir_do, all-lib): Remove.
3671 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3672 (GNULIB_H): Remove.
3673 (generated_files): Update.
3674 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3675 * configure: Rebuild.
3676 * configure.ac: Don't configure gnulib or libiberty.
3677 (GNULIB): Update.
3678
a9b34532
EZ
36792020-02-14 Eli Zaretskii <eliz@gnu.org>
3680
3681 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3682 preparing the command line for CreateProcess.
3683 (win32_create_inferior): Reflect the program name in debugging
3684 output that shows the process and its command line.
3685
feacfcac
SM
36862020-02-13 Simon Marchi <simon.marchi@efficios.com>
3687
3688 * Makefile.in: Rename source files from .c to .cc.
3689 * %.c: Rename to %.cc.
3690 * configure.ac: Rename server.c to server.cc.
3691 * configure: Re-generate.
3692
06b3c5bd
SM
36932020-02-13 Simon Marchi <simon.marchi@efficios.com>
3694
3695 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3696
052793ad
HD
36972020-02-12 Hannes Domani <ssbssa@yahoo.de>
3698
3699 * win32-low.c (win32_create_inferior): Set signal_pid.
3700
f20e3e82
MR
37012020-02-12 Maciej W. Rozycki <macro@wdc.com>
3702 Pedro Alves <palves@redhat.com>
3703
3704 Skip building gdbserver in a cross-configuration.
3705 * configure.srv: Set $gdbserver_host depending on whether $target
3706 is $host. Use $gdbserver_host instead of $host.
3707
8ddd8e0e
SM
37082020-02-11 Simon Marchi <simon.marchi@efficios.com>
3709
3710 * configure: Re-generate.
3711
898e7f60
SM
37122020-02-11 Simon Marchi <simon.marchi@efficios.com>
3713
3714 * configure: Re-generate.
3715
58df732b
SM
37162020-02-11 Simon Marchi <simon.marchi@efficios.com>
3717
3718 * acinclude.m4: Update warning.m4 path.
3719
7928d571
HD
37202020-02-09 Hannes Domani <ssbssa@yahoo.de>
3721
3722 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3723 (handle_exception): Set siginfo_er.
3724 (win32_xfer_siginfo): New function.
3725
919adfe8
TT
37262020-02-07 Tom Tromey <tom@tromey.com>
3727 Pedro Alves <palves@redhat.com>
3728
3729 * README: Update build documentation.
3730 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
3731 host, not target.
3732 * configure.ac: Update paths.
3733 * configure: Rebuild.
3734 * acinclude.m4: Update paths.
3735 * Makefile.in: Update include paths.
3736 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
3737 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
3738 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
3739 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
3740 (%-generated.c): Update paths.
3741 * Move entire directory from ../gdb/gdbserver.
3742
287c844a
MR
37432020-01-29 Maciej W. Rozycki <macro@wdc.com>
3744
3745 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
3746
548a204f
PFC
37472020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3748
3749 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
3750 assignment instead of srv_linux_obj.
3751
a2236a08
HD
37522020-01-28 Hannes Domani <ssbssa@yahoo.de>
3753
3754 * server.c (handle_qxfer_libraries): Write segment-address with
3755 paddress.
3756
bdaed379
HD
37572020-01-24 Hannes Domani <ssbssa@yahoo.de>
3758
3759 * Makefile.in (install-strip): New target.
3760 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
3761 * aclocal.m4: Regenerate.
3762 * configure: Regenerate.
3763 * configure.ac: Add AM_PROG_INSTALL_STRIP.
3764
42cd72aa
MR
37652020-01-24 Maciej W. Rozycki <macro@wdc.com>
3766
3767 * Makefile.in (SFILES): Adjust paths to point to real files.
3768 (OBS): Move waitstatus.o to target/waitstatus.o.
3769 (TAGS): Transform paths appropriately.
3770 (%.o): Rename to...
3771 (nat/%.o): ... this pattern rule.
3772 (%.o): Rename to...
3773 (target/%.o): ... this pattern rule.
3774 * configure.srv: Adjust paths throughout to include nat/ prefix
3775 with the revant files.
3776 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
3777 * configure: Regenerate.
3778
42ba50ec
MR
37792020-01-24 Maciej W. Rozycki <macro@wdc.com>
3780
3781 * Makefile.in (TAGS): Remove config files from the recipe.
3782
05ea2a05
TT
37832020-01-14 Tom Tromey <tom@tromey.com>
3784
3785 * configure: Rebuild.
3786 * configure.ac: Remove any checks that were added to common.m4.
3787 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
3788 lib-link.m4.
3789
01027315
TT
37902020-01-14 Tom Tromey <tom@tromey.com>
3791
3792 * server.h: Include config.h.
3793 * gdbreplay.c: Include config.h.
3794 * configure: Rebuild.
3795 * configure.ac: Don't source common.host.
3796 * acinclude.m4: Update path.
3797 * Makefile.in (INCSUPPORT): New variable.
3798 (INCLUDE_CFLAGS): Add INCSUPPORT.
3799 (SFILES): Update paths.
3800 (version-generated.c): Update path to create-version.sh.
3801 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
3802
b2ceabe8
TT
38032020-01-14 Tom Tromey <tom@tromey.com>
3804
3805 * configure.ac (LIBS): Use WIN32APILIBS.
3806 (USE_WIN32API): Don't define.
3807 * configure: Rebuild.
3808
25c51f71
TT
38092020-01-14 Tom Tromey <tom@tromey.com>
3810
3811 * configure: Rebuild.
3812
c0bd321d
SM
38132020-01-13 Simon Marchi <simon.marchi@efficios.com>
3814
3815 * Makefile.in (%-generated.c): Remove rule for files from
3816 regformats/i386.
3817
bb564c58
SM
38182020-01-13 Simon Marchi <simon.marchi@efficios.com>
3819
3820 * configure: Re-generate.
3821
6e37c371
SM
38222020-01-13 Simon Marchi <simon.marchi@efficios.com>
3823
3824 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
3825 Define to static.
3826 * tracepoint.c (stop_tracing, flush_trace_buffer,
3827 about_to_request_buffer_space, get_trace_state_variable_value,
3828 set_trace_state_variable_value, gdb_collect): Add declaration.
3829
df4a0200
SM
38302020-01-13 Simon Marchi <simon.marchi@efficios.com>
3831
3832 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
3833 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
3834 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
3835 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
3836 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
3837 static.
3838
89e94ec9
SM
38392020-01-13 Simon Marchi <simon.marchi@efficios.com>
3840
3841 * inferiors.c: Include gdbsupport/common-inferior.h.
3842
2552728a
SM
38432020-01-13 Simon Marchi <simon.marchi@efficios.com>
3844
3845 * hostio-errno.c: Include hostio.h.
3846
4025fa09
SM
38472020-01-13 Simon Marchi <simon.marchi@efficios.com>
3848
3849 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
3850 prerequisite.
3851
c0b0a142
SM
38522020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3853
3854 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
3855 * linux-arm-tdesc.h: Include arch/arm.h.
3856
bb1183e2
SM
38572020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3858
3859 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
3860
f5df0b5f
SM
38612020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3862
3863 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
3864 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
3865
5b6d1e4f
PA
38662020-01-10 Pedro Alves <palves@redhat.com>
3867
3868 * fork-child.c (post_fork_inferior): Pass target down to
3869 startup_inferior.
3870 * inferiors.c (switch_to_thread): Add process_stratum_target
3871 parameter.
3872 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
3873 * nto-low.c (nto_target_ops): Now a process_stratum_target.
3874 * linux-low.c (linux_target_ops): Now a process_stratum_target.
3875 * remote-utils.c (prepare_resume_reply): Pass the target to
3876 switch_to_thread.
3877 * target.c (the_target): Now a process_stratum_target.
3878 (done_accessing_memory): Pass the target to switch_to_thread.
3879 (set_target_ops): Ajust to use process_stratum_target.
3880 * target.h (struct target_ops): Rename to ...
3881 (struct process_stratum_target): ... this.
3882 (the_target, set_target_ops): Adjust.
3883 (prepare_to_access_memory): Adjust comment.
3884 * win32-low.c (child_xfer_memory): Adjust to use
3885 process_stratum_target.
3886 (win32_target_ops): Now a process_stratum_target.
3887
559e7e50
EZ
38882020-01-06 Eli Zaretskii <eliz@gnu.org>
3889 Pedro Alves <palves@redhat.com>
3890
3891 * win32-low.c (get_child_debug_event): Extract the fatal exception
3892 from the exit status and convert to the equivalent Posix signal
3893 number.
3894 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
3895 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
3896
48189bec
HD
38972020-01-01 Hannes Domani <ssbssa@yahoo.de>
3898
3899 * Makefile.in: Use INSTALL_PROGRAM_ENV.
3900
5dd8bf88
JB
39012020-01-01 Joel Brobecker <brobecker@adacore.com>
3902
3903 * server.c (gdbserver_version): Change copyright year to 2020.
3904 * gdbreplay.c (gdbreplay_version): Likewise.
3905
0ad6b8ee
CB
39062019-12-19 Christian Biesinger <cbiesinger@google.com>
3907
3908 * configure: Regenerate.
3909 * configure.ac: Quote variable arguments of test.
3910
1ee7b812
BE
39112019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
3912
3913 * Makefile.in: Fix build with GNU Make 3.81
3914
d9fa87f4
TT
39152019-12-16 Tom Tromey <tromey@adacore.com>
3916
3917 * server.c (get_exec_file): Constify result.
3918
ab7d13f0
CB
39192019-12-10 Christian Biesinger <cbiesinger@google.com>
3920
3921 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
3922 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
3923 * config.in: Regenerate.
3924 * configure: Regenerate.
3925 * configure.ac: Don't check for strerror.
3926 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
3927 Call safe_strerror instead of strerror.
3928 * server.h (strerror): Remove this now-unnecessary declaration.
3929 * tracepoint.c (init_named_socket): Call safe_strerror instead of
3930 strerror.
3931 (gdb_agent_helper_thread): Likewise.
3932 * utils.c (perror_with_name): Likewise.
3933
4da8c3a8
TT
39342019-11-26 Tom Tromey <tom@tromey.com>
3935
3936 * configure, config.in: Rebuild.
3937
21987b9c
TT
39382019-11-26 Tom Tromey <tom@tromey.com>
3939
3940 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
3941 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
3942 gdb_sigmask.
3943 * configure, config.in: Rebuild.
3944
5e030278
TT
39452019-11-26 Tom Tromey <tom@tromey.com>
3946
3947 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
3948 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
3949 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
3950 * acinclude.m4: Include ax_pthread.m4.
3951 * config.in, configure: Rebuild.
3952
6d91ce9a
CB
39532019-11-26 Christian Biesinger <cbiesinger@google.com>
3954
3955 * debug.c (debug_set_output): Call safe_strerror instead of
3956 strerror.
3957 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
3958 (linux_kill_one_lwp): Likewise.
3959 (linux_detach_one_lwp): Likewise.
3960 (linux_wait_for_event_filtered): Likewise.
3961 (store_register): Likewise.
3962 * lynx-low.c (lynx_attach): Likewise.
3963 * mem-break.c (insert_memory_breakpoint): Likewise.
3964 (remove_memory_breakpoint): Likewise.
3965 (delete_fast_tracepoint_jump): Likewise.
3966 (set_fast_tracepoint_jump): Likewise.
3967 (uninsert_fast_tracepoint_jumps_at): Likewise.
3968 (reinsert_fast_tracepoint_jumps_at): Likewise.
3969 * nto-low.c (nto_xfer_memory): Likewise.
3970 (nto_resume): Likewise.
3971
6cdd651f
LM
39722019-11-20 Luis Machado <luis.machado@linaro.org>
3973
3974 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
3975 instead of register count.
3976 * tdesc.c (tdesc_contains_feature): New function.
3977 * tdesc.h (tdesc_contains_feature): New prototype.
3978
cd850b40
CB
39792019-11-15 Christian Biesinger <cbiesinger@google.com>
3980
3981 * Makefile.in: Add safe-strerror.c.
3982 * configure: Regenerate.
3983 * configure.ac: Don't source common.host.
3984
5abebf3c
CB
39852019-11-15 Christian Biesinger <cbiesinger@google.com>
3986
3987 * config.in: Regenerate.
3988 * configure: Regenerate.
3989
e06f3d6e
AB
39902019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
3991
3992 * ax.c (ax_printf): Handle size_t_arg.
3993
ca3a04f6
CB
39942019-11-06 Christian Biesinger <cbiesinger@google.com>
3995
3996 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
3997 * mi/mi-main.c (output_cores): Likewise.
3998 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
3999 (linux_xfer_osdata_modules): Likewise.
4000 * remote.c (register_remote_support_xml): Likewise.
4001 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4002 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4003
e48f6033
CB
40042019-11-01 Christian Biesinger <cbiesinger@google.com>
4005
4006 * configure: Regenerate.
4007 * configure.ac: Remove check for strerror_r.
4008
e7e97a2e
CB
40092019-10-31 Christian Biesinger <cbiesinger@google.com>
4010
4011 * config.in: Regenerate.
4012 * configure: Regenerate.
4013 * configure.ac: Also check for strerror_r.
4014
75cafaa6
CB
40152019-10-31 Christian Biesinger <cbiesinger@google.com>
4016
4017 * ax.h (debug_agent): Remove duplicate declaration.
4018
30baf67b
TV
40192019-10-26 Tom de Vries <tdevries@suse.de>
4020
4021 * linux-aarch64-low.c: Fix typos in comments.
4022 * linux-arm-low.c: Same.
4023 * linux-low.c: Same.
4024 * linux-ppc-low.c: Same.
4025 * proc-service.c: Same.
4026 * regcache.h: Same.
4027 * server.c: Same.
4028 * tracepoint.c: Same.
4029 * win32-low.c: Same.
4030
52c64cf7
TT
40312019-10-25 Tom Tromey <tromey@adacore.com>
4032
4033 * utils.c (xstrdup): Remove.
4034
c12d372d
TT
40352019-10-23 Tom Tromey <tom@tromey.com>
4036
4037 * configure, config.in: Rebuild.
4038
4d0b984b
TT
40392019-10-23 Tom Tromey <tom@tromey.com>
4040
4041 * configure: Rebuild.
4042 * acinclude.m4: Use m4_include, not sinclude.
4043
c5adaa19
TT
40442019-10-17 Tom Tromey <tromey@adacore.com>
4045
4046 * configure: Rebuild.
4047 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4048 in AC_CONFIG_FILES invocation.
4049 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4050 invocation.
4051
fec4e896
CB
40522019-10-16 Christian Biesinger <cbiesinger@google.com>
4053
4054 * server.c: Include xml-builtin.h.
4055 (get_xml_features): Don't declare xml_builtins here.
4056
00975ff6
AB
40572019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4058
4059 * Makefile.in: Remove references to vec-ipa.o.
4060
0dc32745
AB
40612019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4062
4063 * Makefile.in: Remove references to vec.c.
4064
3e6ec53a
CB
40652019-10-02 Christian Biesinger <cbiesinger@google.com>
4066
4067 * server.c (server_waiting): Change to bool.
4068 (extended_protocol): Likewise.
4069 (response_needed): Likewise.
4070 (exit_requested): Likewise.
4071 (run_once): Likewise.
4072 (report_no_resumed): Likewise.
4073 (non_stop): Likewise.
4074 (disable_packet_vCont): Likewise.
4075 (disable_packet_Tthread): Likewise.
4076 (disable_packet_qC): Likewise.
4077 (disable_packet_qfThreadInfo): Likewise.
4078 (handle_general_set): Update.
4079 (handle_detach): Update.
4080 (handle_monitor_command): Update.
4081 (handle_query): Update.
4082 (captured_main): Update.
4083 (process_serial_event): Update.
4084 * server.h (server_waiting): Change to bool.
4085 (disable_packet_vCont): Likewise.
4086 (disable_packet_Tthread): Likewise.
4087 (disable_packet_qC): Likewise.
4088 (disable_packet_qfThreadInfo): Likewise.
4089 (run_once): Likewise.
4090 (non_stop): Likewise.
4091 * target.c (target_stop_and_wait): Update.
4092
80fd2826
TT
40932019-10-02 Tom Tromey <tromey@adacore.com>
4094
4095 * Makefile.in (SFILES): Add common-inferior.c.
4096 (OBS): Add common-inferior.o.
4097 * server.c (startup_with_shell): Don't define.
4098
46f29a9a
AB
40992019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4100
4101 * linux-low.c (linux_low_read_btrace): Update for change to
4102 std::vector.
4103
f9d949fb
CB
41042019-09-20 Christian Biesinger <cbiesinger@google.com>
4105
4106 * debug.c (debug_threads): Remove comment in favor of the header.
4107 * debug.h (using_threads): Add declaration.
4108 (debug_threads): Add comment.
4109 * linux-aarch64-low.c: Include debug.h and remove declaration of
4110 debug_threads.
4111 * nto-low.c: Likewise.
4112 * remote-utils.c: Likewise.
4113 * thread-db.c: Likewise.
4114
abf516c6
UW
41152019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4116
4117 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4118 and powerpc-cell64l-ipa.o.
4119 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4120 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4121 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4122 (spu*-*-*): Remove.
4123
4124 * spu-low.c: Remove file.
4125
4126 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4127 (parse_spufs_run): Remove.
4128 (ppc_get_pc): Remove Cell/B.E. support.
4129 (ppc_set_pc): Likewise.
4130 (ppc_breakpoint_at): Likewise.
4131 (ppc_arch_setup): Likewise.
4132 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4133 tdesc_powerpc_cell32l.
4134 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4135 or init_registers_powerpc_cell32l.
4136 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4137 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4138 or init_registers_powerpc_cell32l.
4139 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4140 (init_registers_powerpc_cell32l): Remove prototype.
4141 (init_registers_powerpc_cell64l): Likewise.
4142
4143 * target.h (struct target_ops): Remove qxfer_spu member.
4144 * server.c (handle_qxfer_spu): Remove.
4145 (qxfer_packets): Remove entry for "spu".
4146 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4147 * linux-low.c (SPUFS_MAGIC): Remove.
4148 (spu_enumerate_spu_ids): Remove.
4149 (linux_qxfer_spu): Remove.
4150 (linux_target_ops): Remove qxfer_spu member.
4151 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4152 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4153 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4154
2d41fa11
SDJ
41552019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4156
4157 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4158 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4159 * config.in: Regenerate.
4160 * configure: Regenerate.
4161
d59b55f0
TT
41622019-08-15 Tom Tromey <tromey@adacore.com>
4163
4164 * target.c (target_write_memory): Use gdb::byte_vector.
4165
4196ab2a
TT
41662019-08-15 Tom Tromey <tromey@adacore.com>
4167
4168 * tracepoint.c (write_inferior_data_pointer)
4169 (write_inferior_integer, write_inferior_int8)
4170 (write_inferior_uinteger, m_tracepoint_action_download)
4171 (r_tracepoint_action_download, x_tracepoint_action_download)
4172 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4173 (download_agent_expr, download_tracepoint_1)
4174 (download_trace_state_variables, upload_fast_traceframes): Update.
4175 * server.c (gdb_write_memory): Update.
4176 * remote-utils.c (relocate_instruction): Update.
4177 * proc-service.c (ps_pdwrite): Update.
4178 * mem-break.c (remove_memory_breakpoint)
4179 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4180 (uninsert_fast_tracepoint_jumps_at)
4181 (reinsert_fast_tracepoint_jumps_at): Update.
4182 * linux-x86-low.c (append_insns)
4183 (i386_install_fast_tracepoint_jump_pad)
4184 (amd64_write_goto_address, i386_write_goto_address): Update.
4185 * linux-s390-low.c (append_insns, s390_write_goto_address):
4186 Update.
4187 * linux-ppc-low.c (ppc_relocate_instruction)
4188 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4189 (ppc_write_goto_address): Update.
4190 * linux-aarch64-low.c (append_insns): Update.
4191 * target.h (struct target_ops): Update.
4192 (write_inferior_memory): Don't declare.
4193 * target.c (target_write_memory): Rename from
4194 write_inferior_memory. Remove old target_write_memory.
4195
c6778d00
TT
41962019-08-15 Tom Tromey <tromey@adacore.com>
4197
4198 * target.c (write_inferior_memory): Use std::vector.
4199
404f2902
FCE
42002019-08-06 Frank Ch. Eigler <fche@redhat.com>
4201
4202 PR build/24886
4203 * configure.ac: Drop enable-libmcheck support.
4204 * configure, config.in: Rebuild.
4205 * acinclude.m4: Don't include it.
4206
4c5aa8e0
AH
42072019-07-19 Alan Hayward <alan.hayward@arm.com>
4208
4209 * configure.srv: Remove Arm xml files.
4210
7cc17433
AH
42112019-07-19 Alan Hayward <alan.hayward@arm.com>
4212
4213 * configure.srv: Add new files. Remove xml generated files.
4214 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4215 registers.
4216 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4217 * linux-aarch32-tdesc.c: New file.
4218 * linux-aarch32-tdesc.h: New file.
4219 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4220 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4221 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4222 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4223 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4224 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4225 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4226 (arm_read_description): Call arm_linux_read_description.
4227 (initialize_low_arch): Don't init registers.
4228 * linux-arm-tdesc.c: New file.
4229 * linux-arm-tdesc.h: New file.
4230
166a82be
AH
42312019-07-10 Alan Hayward <alan.hayward@arm.com>
4232
4233 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4234 Move counter inside for.
4235 (arm_read_description): Check ptrace earlier.
4236 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4237
268a13a5
TT
42382019-07-09 Tom Tromey <tom@tromey.com>
4239
4240 * configure: Rebuild.
4241 * configure.ac: Change common to gdbsupport.
4242 * acinclude.m4: Change common to gdbsupport.
4243 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4244 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4245 common to gdbsupport.
4246 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4247 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4248 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4249 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4250 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4251 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4252 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4253 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4254 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4255 common to gdbsupport.
4256
350fab54
AH
42572019-07-04 Alan Hayward <alan.hayward@arm.com>
4258
4259 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4260 defines.
4261 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4262
2b40fda7
AH
42632019-07-04 Alan Hayward <alan.hayward@arm.com>
4264
4265 * configure.srv: Remove legacy xml.
4266 * linux-aarch64-low.c (initialize_low_arch): Remove
4267 initialize_low_tdesc call.
4268 * linux-aarch64-tdesc-selftest.c: Remove file.
4269 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4270 * linux-x86-low.c (initialize_low_arch): Remove
4271 initialize_low_tdesc call.
4272 * linux-x86-tdesc-selftest.c: Remove file.
4273 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4274
7d10623d
TV
42752019-06-20 Tom de Vries <tdevries@suse.de>
4276
4277 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4278 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4279
8d6a48df
TV
42802019-06-19 Tom de Vries <tdevries@suse.de>
4281
4282 * debug.h (debug_write): Change return type to ssize_t.
4283 * debug.c (debug_write): Same.
4284
73cc7272
TT
42852019-06-14 Tom Tromey <tom@tromey.com>
4286
4287 * configure.ac: Use new path to gnulib.
4288 * configure: Rebuild.
4289 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4290 to gnulib.
4291
08f10e02
TT
42922019-06-11 Tom Tromey <tom@tromey.com>
4293
4294 * Makefile.in (SFILES): Add alloc.c.
4295 (OBS): Add alloc.o.
4296 (IPA_OBJS): Add alloc-ipa.o.
4297 (alloc-ipa.o): New target.
4298 (%.o: ../%.c): New pattern rule.
4299
422186a9
TT
43002019-06-10 Tom Tromey <tromey@adacore.com>
4301
4302 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4303 end warning with a newline.
4304 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4305 newline.
4306 * thread-db.c (attach_thread): Don't end warning with a newline.
4307 (thread_db_notice_clone): Likewise.
4308 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4309 newline.
4310 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4311 end warning with a newline.
4312
b02f78f9
PA
43132019-06-04 Pedro Alves <palves@redhat.com>
4314
4315 * server.c (captured_main): Use make_unique_xstrdup.
4316
88ed7edb
TT
43172019-06-02 Tom Tromey <tom@tromey.com>
4318
4319 * gdbreplay.c (fromhex): Remove.
4320 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4321
33a6bc35
TT
43222019-05-29 Tom Tromey <tromey@adacore.com>
4323
4324 * configure: Rebuild.
4325
e90a813d
KB
43262019-05-06 Kevin Buettner <kevinb@redhat.com>
4327
4328 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4329 sign extension code on 32-bit builds.
4330
353ea2d1
EZ
43312019-05-03 Eli Zaretskii <eliz@gnu.org>
4332
4333 * remote-utils.c:
4334 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4335
b494cdff
TT
43362019-04-19 Tom Tromey <tom@tromey.com>
4337
4338 * server.c (struct vstop_notif): Derive from notif_event.
4339 <base>: Remove.
4340 (queue_stop_reply): Update.
4341 (remove_all_on_match_ptid): Change type. Rewrite.
4342 (discard_queued_stop_replies): Rewrite.
4343 (in_queued_stop_replies_ptid): Change type.
4344 (in_queued_stop_replies): Rewrite.
4345 (notif_stop): Update.
4346 (queue_stop_reply_callback): Update.
4347 (captured_main): Don't call initialize_notif.
4348 (push_stop_notification): Update.
4349 * notif.c (notif_write_event, handle_notif_ack)
4350 (notif_event_enque, notif_push): Update.
4351 (notif_event_xfree, initialize_notif): Remove.
4352 * notif.h (struct notif_event): Include <list>, not
4353 "common/queue.h".
4354 (struct notif_server) <queue>: Now a std::list.
4355 (notif_event_p): Remove typedef.
4356 (initialize_notif): Don't declare.
4357 (struct notif_event): Add virtual destructor.
4358
a7e559cc
AH
43592019-04-17 Alan Hayward <alan.hayward@arm.com>
4360
4361 * ax.c (ax_vdebug): Call debug_printf.
4362 * debug.c (debug_write): New function.
4363 * debug.h (debug_write): New declaration.
4364 * linux-low.c (sigchld_handler): Call debug_write.
4365
aeb2e706
AH
43662019-04-17 Alan Hayward <alan.hayward@arm.com>
4367
4368 * debug.c (debug_set_output): New function.
4369 (debug_vprintf): Send output to debug_file.
4370 (debug_flush): Likewise.
4371 * debug.h (debug_set_output): New declaration.
4372 * server.c (handle_monitor_command): Add debug-file option.
4373 (captured_main): Likewise.
4374
c1bc0935
AH
43752019-04-17 Alan Hayward <alan.hayward@arm.com>
4376
4377 * debug.c (remote_debug): Add definition.
4378 * debug.h (remote_debug): Add declaration.
4379 * hostio.c (remote_debug): Remove declaration.
4380 * remote-utils.c (struct ui_file): Likewise.
4381 (remote_debug): Likewise.
4382 * remote-utils.h (remote_debug): Likewise,
4383 * server.c (remote_debug): Remove definition.
4384
3f52fdbc
KB
43852019-04-10 Kevin Buettner <kevinb@redhat.com>
4386
4387 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4388 when using a 64-bit gdbserver.
4389
b0319eaa
TT
43902019-04-09 Tom Tromey <tromey@adacore.com>
4391
4392 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4393
eedc3f4f
TT
43942019-04-08 Tom Tromey <tom@tromey.com>
4395
4396 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4397 throw.
4398 (linux_resume_one_lwp): Likewise.
4399
230d2906
TT
44002019-04-08 Tom Tromey <tom@tromey.com>
4401
4402 * gdbreplay.c: Update.
4403 * linux-low.c: Update.
4404 * server.c: Update.
4405
a70b8144
TT
44062019-04-08 Tom Tromey <tom@tromey.com>
4407
4408 * server.c: Use C++ exception handling.
4409 * linux-low.c: Use C++ exception handling.
4410 * gdbreplay.c: Use C++ exception handling.
4411
3d6e9d23
TT
44122019-04-08 Tom Tromey <tom@tromey.com>
4413
4414 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4415 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4416 (captured_main, main): Update.
4417 * gdbreplay.c (main): Update.
4418
0570503d
PFC
44192019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4420
4421 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4422 value in argument pointer, return 1 if the entry is found and 0
4423 otherwise. Move comment.
4424 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4425 * linux-low.h (linux_get_auxv): Declare.
4426 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4427
227a9e65
TT
44282019-04-05 Tom Tromey <tromey@adacore.com>
4429
4430 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4431 variables.
4432
69f4c9cc
AH
44332019-03-28 Alan Hayward <alan.hayward@arm.com>
4434
4435 * linux-low.c (AT_HWCAP2): Add define if not already included.
4436
974c89e0
AH
44372019-03-26 Alan Hayward <alan.hayward@arm.com>
4438
4439 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4440 (aarch64_arch_setup): Call linux_get_hwcap.
4441 * linux-arm-low.c (arm_get_hwcap): Remove function.
4442 (arm_read_description): Call linux_get_hwcap.
4443 * linux-low.c (linux_get_auxv): New function.
4444 (linux_get_hwcap): Likewise.
4445 (linux_get_hwcap2): Likewise.
4446 * linux-low.h (linux_get_hwcap): New declaration.
4447 (linux_get_hwcap2): Likewise.
4448 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4449 (ppc_arch_setup): Call linux_get_hwcap.
4450 * linux-s390-low.c (s390_get_hwcap): Remove function.
4451 (s390_arch_setup): Call linux_get_hwcap.
4452
1ef53e6b
AH
44532019-03-22 Alan Hayward <alan.hayward@arm.com>
4454 Jiong Wang <jiong.wang@arm.com>
4455
4456 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4457 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4458 to fail.
4459 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4460
ee4fbcfa
AH
44612019-03-22 Alan Hayward <alan.hayward@arm.com>
4462 Jiong Wang <jiong.wang@arm.com>
4463
4464 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4465 (aarch64_get_hwcap): New function.
4466 (aarch64_arch_setup): Read APIA hwcap.
4467
6dc0ebde
AH
44682019-03-22 Alan Hayward <alan.hayward@arm.com>
4469 Jiong Wang <jiong.wang@arm.com>
4470
4471 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4472 (initialize_low_tracepoint): Likewise.
4473 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4474 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4475 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4476 (aarch64_linux_read_description): Likewise.
4477 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4478
1163a4b7
JB
44792019-03-12 John Baldwin <jhb@FreeBSD.org>
4480
4481 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4482 i386_create_target_description for 'segments' parameter.
4483 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4484 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4485 * win32-i386-low.c (i386_arch_setup): Likewise.
4486
d3a70e03
TT
44872019-03-12 Tom Tromey <tromey@adacore.com>
4488
4489 * linux-low.c (iterate_over_lwps): Update.
4490
37991b4f
TT
44912019-03-06 Tom Tromey <tom@tromey.com>
4492
4493 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4494 (captured_main): Use SCOPE_EXIT.
4495
45950eb6
SDJ
44962019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4497
4498 * configure.srv: Use '$enable_unittest' instead of '$development'
4499 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4500 case.
4501
43ac54fc
TT
45022019-02-27 Tom Tromey <tromey@adacore.com>
4503
4504 * gdbreplay.c (logchar): Handle \r\n.
4505
df0da8a2
AH
45062019-02-07 Alan Hayward <alan.hayward@arm.com>
4507
4508 * linux-low.c (linux_attach): Add process before lwp.
4509 * server.c (attach_inferior): Check if already attached.
4510
1a5c2598
TT
45112019-02-07 Tom Tromey <tom@tromey.com>
4512
4513 * x86-tdesc.h: Rename include guard.
4514 * x86-low.h: Add include guard.
4515 * wincecompat.h: Rename include guard.
4516 * win32-low.h: Add include guard.
4517 * utils.h: Rename include guard.
4518 * tracepoint.h: Rename include guard.
4519 * tdesc.h: Rename include guard.
4520 * target.h: Rename include guard.
4521 * server.h: Rename include guard.
4522 * remote-utils.h: Rename include guard.
4523 * regcache.h: Rename include guard.
4524 * nto-low.h: Rename include guard.
4525 * notif.h: Add include guard.
4526 * mem-break.h: Rename include guard.
4527 * lynx-low.h: Add include guard.
4528 * linux-x86-tdesc.h: Add include guard.
4529 * linux-s390-tdesc.h: Add include guard.
4530 * linux-ppc-tdesc-init.h: Add include guard.
4531 * linux-low.h: Add include guard.
4532 * linux-aarch64-tdesc.h: Add include guard.
4533 * linux-aarch32-low.h: Add include guard.
4534 * inferiors.h: Rename include guard.
4535 * i387-fp.h: Rename include guard.
4536 * hostio.h: Rename include guard.
4537 * gdbthread.h: Rename include guard.
4538 * gdb_proc_service.h: Rename include guard.
4539 * event-loop.h: Rename include guard.
4540 * dll.h: Rename include guard.
4541 * debug.h: Rename include guard.
4542 * ax.h: Rename include guard.
4543
956cc47c
SN
45442018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4545
4546 PR gdb/23985
4547 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4548 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4549
a0707f3c
TT
45502019-01-25 Tom Tromey <tom@tromey.com>
4551
4552 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4553
0747795c
TT
45542019-01-25 Tom Tromey <tom@tromey.com>
4555
4556 * win32-low.c: Fix common/ includes.
4557 * win32-i386-low.c: Fix common/ includes.
4558 * tracepoint.c: Fix common/ includes.
4559 * thread-db.c: Fix common/ includes.
4560 * target.h: Fix common/ includes.
4561 * symbol.c: Fix common/ includes.
4562 * spu-low.c: Fix common/ includes.
4563 * server.h: Fix common/ includes.
4564 * server.c: Fix common/ includes.
4565 * remote-utils.c: Fix common/ includes.
4566 * regcache.h: Fix common/ includes.
4567 * regcache.c: Fix common/ includes.
4568 * nto-x86-low.c: Fix common/ includes.
4569 * notif.h: Fix common/ includes.
4570 * mem-break.h: Fix common/ includes.
4571 * lynx-low.c: Fix common/ includes.
4572 * lynx-i386-low.c: Fix common/ includes.
4573 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4574 * linux-x86-low.c: Fix common/ includes.
4575 * linux-low.c: Fix common/ includes.
4576 * inferiors.h: Fix common/ includes.
4577 * i387-fp.c: Fix common/ includes.
4578 * hostio.c: Fix common/ includes.
4579 * hostio-errno.c: Fix common/ includes.
4580 * gdbthread.h: Fix common/ includes.
4581 * gdbreplay.c: Fix common/ includes.
4582 * fork-child.c: Fix common/ includes.
4583 * event-loop.c: Fix common/ includes.
4584 * ax.c:
4585 (enum gdb_agent_op): Fix common/ includes.
4586
be6d4f74
TT
45872019-01-21 Tom Tromey <tom@tromey.com>
4588
4589 * tracepoint.c: Fix includes.
4590 * remote-utils.c: Fix includes.
4591 * linux-x86-low.c: Fix includes.
4592
66d91b39
JB
45932019-01-01 Joel Brobecker <brobecker@adacore.com>
4594
4595 * gdbreplay.c (gdbreplay_version): Update copyright year in
4596 version message.
4597 * server.c (gdbserver_version): Likewise.
4598
754e3168
AH
45992018-12-05 Alan Hayward <alan.hayward@arm.com>
4600
4601 * linux-low.c (add_lwp): Switch ordering.
4602
d105de22
TT
46032018-11-29 Tom Tromey <tom@tromey.com>
4604
4605 * win32-low.c (win32_join): Take pid, not process.
4606 * target.h (struct target_ops) <join>: Change argument type.
4607 (join_inferior): Change argument name.
4608 * spu-low.c (spu_join): Take pid, not process.
4609 * server.c (handle_detach): Preserve pid before destroying
4610 process.
4611 * lynx-low.c (lynx_join): Take pid, not process.
4612 * linux-low.c (linux_join): Take pid, not process.
4613
50138245
AH
46142018-11-23 Alan Hayward <alan.hayward@arm.com>
4615
4616 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4617 (aarch64_cannot_fetch_register): Likewise.
4618 (struct linux_target_ops): Update references.
4619
64f57f3d
PFC
46202018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4621
4622 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4623
8d619c01
EBM
46242018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4625
4626 * configure.srv (ipa_ppc_linux_regobj): Add
4627 powerpc-isa207-htm-vsx32l-ipa.o and
4628 powerpc-isa207-htm-vsx64l-ipa.o.
4629 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4630 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4631 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4632 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4633 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4634 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4635 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4636 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4637 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4638 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4639 (init_registers_powerpc_isa207_htm_vsx32l)
4640 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4641 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4642 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4643 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4644 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4645 (ppc_store_tm_ctarregset): New functions.
4646 (ppc_regsets): Add entries for HTM regsets.
4647 (ppc_arch_setup): Set htm in features struct when needed. Set
4648 sizes for the HTM regsets.
4649 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4650 (initialize_low_arch): Call
4651 init_registers_powerpc_isa207_htm_vsx32l and
4652 init_registers_powerpc_isa207_htm_vsx64l.
4653 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4654 PPC_TDESC_ISA207_HTM_VSX.
4655 (initialize_low_tracepoint): Call
4656 init_registers_powerpc_isa207_htm_vsx32l and
4657 init_registers_powerpc_isa207_htm_vsx64l.
4658
232bfb86
EBM
46592018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4660
4661 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4662 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4663 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4664 (ppc_store_pmuregset): New functions.
4665 (ppc_regsets): Add entries for ebb and pmu regsets.
4666 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4667 pmu regsets are available. Set sizes for these regsets.
4668
f2cf6173
EBM
46692018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4670
4671 * configure.srv (ipa_ppc_linux_regobj): Add
4672 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4673 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4674 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4675 rs6000/powerpc-isa207-vsx32l.xml, and
4676 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4677 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4678 <PPC_TDESC_ISA207_VSX>: New enum value.
4679 (init_registers_powerpc_isa207_vsx32l): Declare.
4680 (init_registers_powerpc_isa207_vsx64l): Declare.
4681 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4682 (ppc_store_tarregset): New function.
4683 (ppc_regsets): Add entry for the TAR regset.
4684 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4685 size for the TAR regsets.
4686 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4687 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4688 and init_registers_powerpc_isa207_vsx64l.
4689 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4690 (initialize_low_tracepoint): Call
4691 init_registers_powerpc_isa207_vsx32l and
4692 init_registers_powerpc_isa207_vsx64l.
4693
7ca18ed6
EBM
46942018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4695 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4696
4697 * configure.srv (ipa_ppc_linux_regobj): Add
4698 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4699 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4700 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4701 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4702 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4703 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4704 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4705 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4706 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4707 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4708 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4709 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4710 (ppc_hwcap): Add comment.
4711 (ppc_hwcap2): New global.
4712 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4713 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4714 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4715 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4716 when needed. Set sizes for the the DSCR and PPR regsets.
4717 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4718 (initialize_low_arch): Call
4719 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4720 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4721 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4722 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4723 (initialize_low_tracepoint): Call
4724 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4725 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4726
5c849b22
PFC
47272018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4728
4729 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
4730
8ecfd7bd
SDJ
47312018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
4732 Simon Marchi <simark@simark.ca>
4733
4734 * acinclude.m4: Include "../selftest.m4".
4735 * configure: Regenerate.
4736 * configure.ac: Use "GDB_AC_SELFTEST".
4737 * configure.srv: Use "$enable_unittests" instead of
4738 "$development" when checking whether unit tests have been
4739 enabled.
4740 * server.c (captured_main): Update message informing that
4741 selftests have been disabled.
4742
96643e35
TT
47432018-10-04 Tom Tromey <tom@tromey.com>
4744
4745 * configure: Rebuild.
4746
da4ae14a
TT
47472018-10-04 Tom Tromey <tom@tromey.com>
4748
4749 * server.c (handle_status): Rename inner "thread".
4750 (process_serial_event): Declare "res" in 'm' case.
4751 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
4752 (iterate_over_lwps): Rename inner "thread".
4753 (linux_qxfer_libraries_svr4): Rename inner "len".
4754 * gdbthread.h (find_thread_in_random): Rename inner "thread".
4755
7c619dbd
GB
47562018-10-01 Gary Benson <gbenson@redhat.com>
4757
4758 * gdb_proc_service.h: Moved common code to
4759 common/gdb_proc_service.h.
4760
3795e814
GB
47612018-10-01 Gary Benson <gbenson@redhat.com>
4762
4763 * gdb_proc_service.h: Synchronize comments and whitespace with
4764 GDB's version of this file.
4765
49b036f1
TT
47662018-09-25 Tom Tromey <tom@tromey.com>
4767
4768 * configure: Rebuild.
4769 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
4770
8ff03f0b
SM
47712018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4772
4773 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
4774 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
4775 ($(IPA_LIB)): Sort IPA_OBJS.
4776
a1cd91dc
SM
47772018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4778
4779 * Makefile.in: Remove references to $(ADD_DEPS).
4780
752312ba
TT
47812018-09-16 Tom Tromey <tom@tromey.com>
4782
4783 * remote-utils.c (remote_open): Use GNU style for metasyntactic
4784 variables.
4785 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
4786 variables.
4787
f1628857
TT
47882018-09-05 Tom Tromey <tom@tromey.com>
4789
4790 * configure: Rebuild.
4791
ad202fcc
SM
47922018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4793
4794 PR build/23399
4795 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
4796
d3d8724a
TT
47972018-08-27 Tom Tromey <tom@tromey.com>
4798
4799 PR build/23087:
4800 * configure: Rebuild.
4801
b4f183d2
TT
48022018-08-27 Tom Tromey <tom@tromey.com>
4803
4804 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
4805 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
4806 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
4807 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
4808 (s390x_emit_stack_adjust): Add casts to unsigned char.
4809
4e2aa472
SM
48102018-08-22 Simon Marchi <simon.marchi@ericsson.com>
4811
4812 PR gdb/23374
4813 PR gdb/23375
4814 * server.h (struct client_state) <disable_randomization>:
4815 Initialize to 1.
4816
cf4088a9
SM
48172018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4818
4819 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
4820 variable.
4821 (mips_supply_ptrace_register): Likewise.
4822
a0de763e
TT
48232018-07-22 Tom Tromey <tom@tromey.com>
4824
4825 * configure: Rebuild.
4826
b0a7723d
TT
48272018-07-22 Tom Tromey <tom@tromey.com>
4828
4829 * win32-low.c (win32_create_inferior): Remove unused variables.
4830 * gdbreplay.c (remote_open): Remove unused variable.
4831 * remote-utils.c (remote_prepare): Remove unused variable.
4832 * x86-tdesc.h (X86_TDESC_H): Define.
4833 (amd64_expedite_regs): Define conditionally.
4834 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
4835 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
4836 * remote-utils.c (readchar): Remove unused variable.
4837
a780ef4f
PA
48382018-07-13 Pedro Alves <palves@redhat.com>
4839
4840 * linux-low.c (linux_kill): Change parameter to process_info
4841 pointer instead of pid. Adjust.
4842 * lynx-low.c (lynx_kill): Likewise.
4843 * nto-low.c (nto_kill): Likewise.
4844 * spu-low.c (spu_kill): Likewise.
4845 * win32-low.c (win32_kill): Likewise.
4846 * server.c (handle_v_kill, kill_inferior_callback)
4847 (detach_or_kill_for_exit): Adjust.
4848 * target.c (kill_inferior): Change parameter to process_info
4849 pointer instead of pid. Adjust.
4850 * target.h (struct target_ops) <kill>: Change parameter to
4851 process_info pointer instead of pid. Adjust all implementations
4852 and callers.
4853 (kill_inferior): Likewise.
4854
ef2ddb33
PA
48552018-07-13 Pedro Alves <palves@redhat.com>
4856
4857 * linux-low.c (linux_detach, linux_join): Change parameter to
4858 process_info pointer instead of pid. Adjust.
4859 * lynx-low.c (lynx_detach, lynx_join): Likewise.
4860 * nto-low.c (nto_detach): Likewise.
4861 * spu-low.c (spu_detach, spu_join): Likewise.
4862 * win32-low.c (win32_detach, win32_join): Likewise.
4863 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
4864 * target.h (struct target_ops) <detach, join>: Change parameter to
4865 process_info pointer instead of pid. Adjust all implementations
4866 and callers.
4867 (detach_inferior, join_inferior): Rename 'pid' parameter to
4868 'proc'.
4869
c7ab0aef
SDJ
48702018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4871 Jan Kratochvil <jan.kratochvil@redhat.com>
4872 Paul Fertser <fercerpav@gmail.com>
4873 Tsutomu Seki <sekiriki@gmail.com>
4874
4875 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
4876 (OBS): Add 'common/netstuff.o'.
4877 (GDBREPLAY_OBS): Likewise.
4878 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
4879 (remote_open): Implement support for IPv6
4880 connections.
4881 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
4882 and 'wspiapi.h'.
4883 (handle_accept_event): Accept connections from IPv6 sources.
4884 (remote_prepare): Handle IPv6-style hostnames; implement
4885 support for IPv6 connections.
4886 (remote_open): Implement support for printing connections from
4887 IPv6 sources.
4888
31445d10
PA
48892018-07-11 Pedro Alves <palves@redhat.com>
4890
4891 PR gdb/23377
4892 * mem-break.c (any_persistent_commands): Add process_info
4893 parameter and use it instead of relying on the current process.
4894 Change return type to bool.
4895 * mem-break.h (any_persistent_commands): Add process_info
4896 parameter and change return type to bool.
4897 * server.c (handle_detach): Remove require_running_or_return call.
4898 Look up the process_info for the process we're about to detach.
4899 If not found, return back error to GDB. Adjust
4900 any_persistent_commands call to pass down a process pointer.
4901
cb197132
PA
49022018-07-11 Pedro Alves <palves@redhat.com>
4903
4904 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
4905 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
4906 instead of collect_register_by_name.
4907 * regcache.c (regcache_raw_get_unsigned_by_name): New.
4908 * regcache.h (regcache_raw_get_unsigned_by_name): New.
4909
1b919490
VB
49102018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4911 Pedro Alves <palves@redhat.com>
4912
4913 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
4914
d7e15655
TT
49152018-07-03 Tom Tromey <tom@tromey.com>
4916
4917 * linux-low.c: Update.
4918 * lynx-low.c: Update.
4919 * mem-break.c: Update.
4920 * nto-low.c: Update.
4921 * remote-utils.c: Update.
4922 * server.c: Update.
4923 * spu-low.c: Update.
4924 * target.c: Update.
4925 * win32-low.c: Update.
4926
26a57c92
TT
49272018-07-03 Tom Tromey <tom@tromey.com>
4928
4929 * server.c: Update.
4930
0e998d96
TT
49312018-07-03 Tom Tromey <tom@tromey.com>
4932
4933 * linux-low.c: Update.
4934
cc6bcb54
TT
49352018-07-03 Tom Tromey <tom@tromey.com>
4936
4937 * target.c: Update.
4938
e38504b3
TT
49392018-07-03 Tom Tromey <tom@tromey.com>
4940
4941 * linux-low.c: Update.
4942 * linux-mips-low.c: Update.
4943 * lynx-low.c: Update.
4944 * nto-low.c: Update.
4945 * remote-utils.c: Update.
4946 * server.c: Update.
4947 * spu-low.c: Update.
4948 * target.c: Update.
4949 * thread-db.c: Update.
4950
e99b03dc
TT
49512018-07-03 Tom Tromey <tom@tromey.com>
4952
4953 * linux-low.c: Update.
4954 * linux-mips-low.c: Update.
4955 * lynx-low.c: Update.
4956 * mem-break.c: Update.
4957 * nto-low.c: Update.
4958 * remote-utils.c: Update.
4959 * server.c: Update.
4960 * spu-low.c: Update.
4961 * target.c: Update.
4962 * tracepoint.c: Update.
4963
f2907e49
TT
49642018-07-03 Tom Tromey <tom@tromey.com>
4965
4966 * linux-low.c: Update.
4967 * linux-ppc-low.c: Update.
4968 * linux-x86-low.c: Update.
4969 * proc-service.c: Update.
4970 * server.c: Update.
4971 * spu-low.c: Update.
4972 * thread-db.c: Update.
4973 * win32-low.c: Update.
4974
fd79271b
TT
49752018-07-03 Tom Tromey <tom@tromey.com>
4976
4977 * linux-low.c: Update.
4978 * lynx-low.c: Update.
4979 * nto-low.c: Update.
4980 * remote-utils.c: Update.
4981 * spu-low.c: Update.
4982 * thread-db.c: Update.
4983 * win32-low.c: Update.
4984
c0867626
SDJ
49852018-06-29 Joel Brobecker <brobecker@adacore.com>
4986
4987 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
4988 parameter in call to 'amd64_create_target_description'.
4989
2512d7ef
JK
49902018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
4991
4992 * x86-tdesc.h: Remove executable permission flag.
4993
d0ac1c44
SM
49942018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4995
4996 * configure.ac: Remove AC_PREREQ, add missing quoting.
4997 * configure: Re-generate.
4998 * config.in: Re-generate.
4999 * aclocal.m4: Re-generate.
5000
c4eb05ff
SM
50012018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5002
5003 * tracepoint.h (current_traceframe): Remove declaration.
5004
02895270
AH
50052018-06-18 Alan Hayward <alan.hayward@arm.com>
5006
5007 * linux-aarch64-low.c (is_sve_tdesc): New function.
5008 (aarch64_sve_regs_copy_to_regcache): Likewise.
5009 (aarch64_sve_regs_copy_from_regcache): Likewise.
5010 (aarch64_regs_info): Add SVE checks.
5011 (initialize_low_arch): Initialize SVE.
5012
e9902bfc
AH
50132018-06-18 Alan Hayward <alan.hayward@arm.com>
5014
5015 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5016
fefa175e
AH
50172018-06-11 Alan Hayward <alan.hayward@arm.com>
5018
5019 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5020 (initialize_low_tracepoint): Likewise
5021 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5022 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5023 param.
5024 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5025 checks.
5026 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5027
b91ad3ff
AH
50282018-06-11 Alan Hayward <alan.hayward@arm.com>
5029
5030 * server.h (PBUFSIZ): Increase size
5031
f868386e
AH
50322018-06-11 Alan Hayward <alan.hayward@arm.com>
5033
5034 * regcache.c (regcache::raw_compare): New function.
5035 * regcache.h (regcache::raw_compare): New declaration.
5036
9c861883
AH
50372018-06-11 Alan Hayward <alan.hayward@arm.com>
5038
5039 * regcache.c (new_register_cache): Use new.
5040 (free_register_cache): Use delete.
5041 (register_data): Use const.
5042 (supply_register): Move body inside regcache.
5043 (regcache::raw_supply): New override function.
5044 (collect_register): Move body inside regcache.
5045 (regcache::raw_collect): New override function.
5046 (regcache::get_register_status): New override function.
5047 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5048
40591844
TT
50492018-06-09 Tom Tromey <tom@tromey.com>
5050
5051 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5052 declare queue.
5053 (event_queue): Use std::queue.
5054 (gdb_event_xfree): Remove.
5055 (initialize_event_loop, process_event, wait_for_event): Update.
5056
6341380d
SC
50572018-06-08 Stan Cox <scox@redhat.com>
5058
5059 * win32-low.c (win32_create_inferior): last_ptid and last_status
5060 moved to client_state.
5061
03349c93
PA
50622018-06-08 Pedro Alves <palves@redhat.com>
5063
5064 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5065 common/common-exceptions.o, common/common-utils.o,
5066 common/errors.o, common/print-utils.o and utils.o.
5067 * gdbreplay.c: Include "common-defs.h" instead of the two
5068 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5069 string.h or alloca.h.
5070 (perror_with_name): Delete.
5071 (remote_open): Use xstrdup instead of strdup.
5072 (main): Rename to ...
5073 (captured_main): ... this.
5074 (main): New.
5075
8dcc53b3
TT
50762018-06-08 Tom Tromey <tom@tromey.com>
5077
5078 * linux-low.c (linux_low_read_btrace): Update.
5079
c12a5089
SC
50802018-06-04 Stan Cox <scox@redhat.com>
5081
5082 * server.h (struct client_state): New.
5083 * server.c (cont_thread, general_thread, multi_process)
5084 (report_fork_events, report_vfork_events, report_exec_events)
5085 (report_thread_events, swbreak_feature, hwbreak_feature)
5086 (vCont_supported, disable_randomization, pass_signals)
5087 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5088 Moved to client_state.
5089 * remote-utils.c (remote_debug, noack_mode)
5090 (transport_is_reliable): Moved to client_state.
5091 * tracepoint.c (current_traceframe): Moved to client_state.
5092
5093 Update all callers.
5094 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5095 linux-low.c, remote-utils.h, target.c: Use client_state.
5096
122394f1
AH
50972018-05-31 Alan Hayward <alan.hayward@arm.com>
5098
5099 * configure.srv: Add new c/h file.
5100
95228a0d
AH
51012018-05-31 Alan Hayward <alan.hayward@arm.com>
5102
5103 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5104 null VQ.
5105
d8dab6c3
MR
51062018-05-25 Maciej W. Rozycki <macro@mips.com>
5107
5108 * gdb.arch/mips-fpregset-core.exp: New test.
5109 * gdb.arch/mips-fpregset-core.c: New test source.
5110
81e25b7c
EK
51112018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5112
5113 PR server/23198
5114 * hostio.c (require_int): Do not report overflow for integers
5115 between 0xfffffff and 0x7fffffff.
5116
7e947ad3
MR
51172018-05-22 Maciej W. Rozycki <macro@mips.com>
5118
5119 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5120 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5121 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5122 functions.
5123 (the_low_target): Wire them.
5124
1d75a658
PFC
51252018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5126
5127 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5128 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5129 mode. Call collect_register_by_name with vscr using
5130 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5131 (ppc_store_vrregset): Add and set vscr_offset variable as in
5132 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5133 vscr_offset.
5134
d078308a
PFC
51352018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5136
5137 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5138 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5139 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5140
7273b5fc
PFC
51412018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5142
5143 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5144 (ppc_store_vsxregset): Likewise.
5145 (ppc_fill_vrregset): Likewise.
5146 (ppc_store_vrregset): Likewise.
5147 (ppc_fill_evrregset): Likewise.
5148 (ppc_store_evrregset): Likewise.
5149 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5150 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5151 needed.
5152
2e077f5e
PFC
51532018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5154
5155 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5156 wordsize of the inferior. Call ppc_linux_target_wordsize.
5157
bd64614e
PFC
51582018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5159
5160 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5161 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5162 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5163 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5164 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5165 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5166 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5167 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5168 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5169 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5170 (tdesc_powerpc_e500l): Remove.
5171 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5172 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5173 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5174 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5175 linux-ppc-tdesc.h.
5176 (ppc_arch_setup): Remove target description matching code. Fill a
5177 ppc_linux_features struct and call ppc_linux_match_description
5178 with it.
5179
75d74cca
MR
51802018-05-22 Maciej W. Rozycki <macro@mips.com>
5181
5182 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5183 width of the requested register exceeds the width of the
5184 `ptrace' data type.
5185 (mips_cannot_store_register): Likewise.
5186
e4439e43
MR
51872018-05-21 Maciej W. Rozycki <macro@mips.com>
5188
5189 * linux-mips-low.c (mips_fetch_register): New function. Update
5190 preceding comment.
5191 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5192 (the_low_target): Wire `mips_fetch_register'.
5193
55271bf9
JB
51942018-05-10 Joel Brobecker <brobecker@adacore.com>
5195
5196 * lynx-i386-low.c (LYNXOS_178): New macro.
5197 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5198 the layout on LynxOS-178.
5199 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5200 handle floating point registers that are not supported by
5201 LynxOS-178.
5202
1a34f210
TT
52032018-05-10 Tom Tromey <tom@tromey.com>
5204
5205 * configure: Rebuild.
5206
190852c8
JB
52072018-05-10 Joel Brobecker <brobecker@adacore.com>
5208
5209 PR server/23158:
5210 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5211 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5212 Use it to set the expedite_regs field in the given tdesc.
5213 * x86-tdesc.h: New file.
5214 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5215 Adjust following the addition of the new expedite_regs parameter
5216 to init_target_desc.
5217 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5218 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5219 (i386_linux_read_description, amd64_linux_read_description):
5220 Adjust following the addition of the new expedite_regs parameter
5221 to init_target_desc.
5222 * lynx-i386-low.c: #include "x86-tdesc.h".
5223 (lynx_i386_arch_setup): Adjust following the addition of the new
5224 expedite_regs parameter to init_target_desc.
5225 * nto-x86-low.c: #include "x86-tdesc.h".
5226 (nto_x86_arch_setup): Adjust following the addition of the new
5227 expedite_regs parameter to init_target_desc.
5228 * win32-i386-low.c: #include "x86-tdesc.h".
5229 (i386_arch_setup): Adjust following the addition of the new
5230 expedite_regs parameter to init_target_desc.
5231
7dbac825
JB
52322018-05-10 Joel Brobecker <brobecker@adacore.com>
5233
5234 PR server/23158:
5235 * win32-low.c (win32_create_inferior): Add call to my_wait
5236 setting last_status global.
5237
906994d9
JB
52382018-05-10 Joel Brobecker <brobecker@adacore.com>
5239
5240 PR server/23158:
5241 * win32-low.c (create_process): Only call gdb_tilde_expand if
5242 inferior_cwd is not NULL.
5243
8ee22052
AB
52442018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5245
5246 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5247 registers to the cache if their values have changed.
5248 (i387_xsave_to_cache): Provide default values for x87 control
5249 registers when these features are available, but disabled.
5250 * regcache.c (supply_register_by_name_zeroed): New function.
5251 * regcache.h (supply_register_by_name_zeroed): Declare new
5252 function.
5253
aff689d3
TT
52542018-05-07 Tom Tromey <tom@tromey.com>
5255
5256 * configure: Rebuild.
5257
85e26832
TT
52582018-05-04 Tom Tromey <tom@tromey.com>
5259
5260 * configure: Rebuild.
5261
a3b60e45
JK
52622018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5263 Pedro Alves <palves@redhat.com>
5264
5265 * linux-aarch64-low.c (aarch64_stopped_data_address):
5266 Likewise.
5267
632e107b
TT
52682018-04-27 Tom Tromey <tom@tromey.com>
5269
5270 * configure: Rebuild.
5271
458412c3
TT
52722018-04-23 Tom Tromey <tom@tromey.com>
5273
5274 * configure: Rebuild.
5275
f31c089e
SM
52762018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5277
5278 * Makefile.in (depcomp): Add "..".
5279 (all_deps_files): New and use it.
5280
b319b098
AH
52812018-04-18 Alan Hayward <alan.hayward@arm.com>
5282
5283 * configure.srv (aarch64*-*-linux*): Don't include xml.
5284 (i[34567]86-*-cygwin*): Likewise.
5285 (i[34567]86-*-linux*): Likewise.
5286 (i[34567]86-*-lynxos*): Likewise.
5287 (i[34567]86-*-mingw32ce*): Likewise.
5288 (i[34567]86-*-mingw*): Likewise.
5289 (i[34567]86-*-nto*): Likewise.
5290 (tic6x-*-uclinux): Likewise.
5291 (x86_64-*-linux*): Likewise.
5292 (x86_64-*-mingw*): Likewise.
5293 (x86_64-*-cygwin*): Likewise.
5294
3b74854b
AH
52952018-04-18 Alan Hayward <alan.hayward@arm.com>
5296
5297 * tdesc.c: Remove xml parameter.
5298
e98577a9
AH
52992018-04-18 Alan Hayward <alan.hayward@arm.com>
5300
5301 * server.c (get_features_xml): Remove cast.
5302 * tdesc.c (void target_desc::accept): Fill in function.
5303 (tdesc_get_features_xml): Remove old xml creation.
5304 (print_xml_feature::visit_pre): Add xml vistor.
5305 * tdesc.h (struct target_desc): Make xmltarget mutable.
5306 (tdesc_get_features_xml): Remove declaration.
5307
d278f585
AH
53082018-04-18 Alan Hayward <alan.hayward@arm.com>
5309
5310 * tdesc.c (tdesc_architecture_name): Add new function.
5311 (tdesc_osabi_name): Likewise.
5312 (tdesc_get_features_xml): Use new functions.
5313
eee8a18d
AH
53142018-04-18 Alan Hayward <alan.hayward@arm.com>
5315
5316 * tdesc.c (tdesc_create_flags): Remove.
5317 (tdesc_add_flag): Likewise.
5318 (tdesc_named_type): Likewise.
5319 (tdesc_create_union): Likewise.
5320 (tdesc_create_struct): Likewise.
5321 (tdesc_create_vector): Likewise.
5322 (tdesc_add_bitfield): Likewise.
5323 (tdesc_add_field): Likewise.
5324 (tdesc_set_struct_size): Likewise.
5325
82ec9bc7
AH
53262018-04-18 Alan Hayward <alan.hayward@arm.com>
5327
5328 * tdesc.c (~target_desc): Remove implictly deleted items.
5329 (init_target_desc): Iterate all features.
5330 (tdesc_get_features_xml): Use vector.
5331 (tdesc_create_feature): Create feature.
5332 * tdesc.h (tdesc_feature) Remove
5333 (target_desc): Add features.
5334
ea3e7d71
AH
53352018-04-18 Alan Hayward <alan.hayward@arm.com>
5336
5337 * Makefile.in: Add common/tdesc.c
5338 * tdesc.c (init_target_desc): init all reg_defs from register
5339 vector.
5340 (tdesc_create_reg): Create tdesc_reg.
5341 * tdesc.h (tdesc_feature): Add register vector.
5342
17d08cd4
SM
53432018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5344
5345 * tdesc.h (struct target_desc) <features>: Change type to
5346 std::vector<std::string>.
5347 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5348 changes.
5349 (tdesc_get_features_xml): Likewise.
5350 (tdesc_create_feature): Likewise.
5351
5cd3e386
AH
53522018-03-26 Alan Hayward <alan.hayward@arm.com>
5353
5354 * regcache.c (find_register_by_number): Return a ref.
5355 (find_regno): Use references.
5356 (register_size): Likewise.
5357 (register_data): Likewise.
5358 * tdesc.c (target_desc::~target_desc): Remove free calls.
5359 (target_desc::operator==): Use std::vector compare.
5360 (init_target_desc): Use reference.
5361 (tdesc_create_reg): Use reg constructors.
5362 * tdesc.h (struct target_desc): Replace pointer with object.
5363
dff7492c
AH
53642018-03-23 Alan Hayward <alan.hayward@arm.com>
5365
5366 * regcache.c (find_register_by_number): Make static.
5367 (find_regno): Use find_register_by_number
5368 * regcache.h (struct reg): Remove declaration.
5369
d80e5242
AH
53702018-03-23 Alan Hayward <alan.hayward@arm.com>
5371
5372 * tdesc.c (target_desc::~target_desc): Move to here.
5373 (target_desc::operator==): Likewise.
5374 * tdesc.h (target_desc::~target_desc): Move from here.
5375 (target_desc::operator==): Likewise.
5376
f69c5afb
AA
53772018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5378
5379 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5380
ce29f843
AA
53812018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5382
5383 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5384 S390_TDESC_GS.
5385 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5386 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5387 and init_registers_s390_gs_linux64.
5388
c49bd90b
AA
53892018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5390
5391 * linux-s390-low.c (s390_fill_gs): Remove function.
5392 (s390_fill_gsbc): Remove function.
5393 (s390_regsets): Set fill functions for the guarded storage regsets
5394 to NULL.
5395
7edb9bd3
AA
53962018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5397
5398 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5399 the word size. Add comment.
5400 (s390_get_wordsize): New function.
5401 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5402 pswm with it. Instead, use s390_get_wordsize to determine the
5403 word size first and derive the correct tdesc from that directly.
5404
39be3c7e
SM
54052018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5406
5407 * Makefile.in: Include silent-rules.mk.
5408 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5409 (COMPILE): Add ECHO_CXX.
5410 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5411 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5412 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5413 (version-generated.c): Add ECHO_GEN.
5414 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5415 (IPAGENT_COMPILE): Add ECHO_CXX.
5416 (%-generated.c): Add ECHO_REGDAT.
5417
3ae9ce5d
TT
54182018-03-14 Tom Tromey <tom@tromey.com>
5419
5420 PR cli/14977:
5421 * ax.c (ax_printf): Special case for NULL.
5422
e6a58aa8
SM
54232018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5424
5425 * linux-low.c (linux_qxfer_libraries_svr4): Use
5426 xml_escape_text_append.
5427
f6e8a41e
SM
54282018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5429
5430 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5431
b9671caf
SM
54322018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5433
5434 * server.c (handle_general_set): Remove unnecessary xstrdup.
5435
e80aaf61
SM
54362018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5437
5438 * server.c (parse_debug_format_options): Adjust to
5439 delim_string_to_char_ptr_vec changes.
5440 * thread-db.c (thread_db_load_search): Adjust to
5441 dirnames_to_char_ptr_vec changes.
5442
b1223e78
MM
54432018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5444
5445 * target.h (target_enable_btrace, target_disable_btrace)
5446 (target_read_btrace, target_read_btrace_conf): Turn macro into
5447 inline function. Throw error if target method is not defined.
5448 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5449 check for btrace target method. Be prepared to handle exceptions
5450 from btrace target methods.
5451
81561546
SDJ
54522018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5453
5454 * server.c (captured_main): Change order of error message printed
5455 when the current working directory cannot be found.
5456
25e3c82c
SDJ
54572018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5458
5459 * server.c: Include "filenames.h" and "pathstuff.h".
5460 (program_name): Delete variable.
5461 (program_path): New anonymous class.
5462 (get_exec_wrapper): Use "program_path" instead of
5463 "program_name".
5464 (handle_v_run): Likewise.
5465 (captured_main): Likewise.
5466 (process_serial_event): Likewise.
5467
b4987c95
SDJ
54682018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5469
5470 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5471 (OBJS): Add "pathstuff.o".
5472 * server.c (current_directory): New global variable.
5473 (captured_main): Initialize "current_directory".
5474
f46cd62a
AH
54752018-02-26 Alan Hayward <alan.hayward@arm.com>
5476
5477 * tdesc.c: Use common/tdesc.h.
5478 * tdesc.h: Likewise.
5479
a543c5ca
AH
54802018-02-20 Alan Hayward <alan.hayward@arm.com>
5481 Simon Marchi <simon.marchi@ericsson.com>
5482
5483 * Makefile.in: Switch order of make rules.
5484
b5884fa7
AH
54852018-02-19 Alan Hayward <alan.hayward@arm.com>
5486
5487 * Makefile.in: Add common directory in build.
5488 * configure.ac: Add common reference.
5489 * configure: Regenerate.
5490
de6242d3
MM
54912018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5492
5493 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5494 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5495 * spu-low.c (spu_target_ops): Likewise.
5496 * win32-low.c (win32_target_ops): Likewise.
5497 * server.c (supported_btrace_packets): Report packets unconditionally.
5498 * target.h (target_ops) <supports_btrace>: Remove.
5499 (target_supports_btrace): Remove.
5500
9ee23a85
MM
55012018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5502
5503 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5504 (handle_btrace_disable): Change return type to void. Use exceptions
5505 to report errors.
5506 (handle_btrace_general_set): Catch exception and copy message to
5507 return message.
5508
8ce47547
TT
55092018-02-08 Tom Tromey <tom@tromey.com>
5510
5511 * linux-low.c (install_software_single_step_breakpoints): Use
5512 make_scoped_restore.
5513 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5514 (do_restore_current_thread_cleanup): Remove.
5515 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5516 declare.
5517
45dd3607
TT
55182018-02-08 Tom Tromey <tom@tromey.com>
5519
5520 * mem-break.c (set_raw_breakpoint_at): Use
5521 gdb::unique_xmalloc_ptr.
5522
e671cd59
PA
55232018-01-30 Pedro Alves <palves@redhat.com>
5524
5525 PR gdb/13211
5526 * target.c (target_terminal::terminal_state): Rename to ...
5527 (target_terminal::m_terminal_state): ... this.
5528
a0aad537
JC
55292018-01-19 James Clarke <jrtc27@jrtc27.com>
5530
5531 * linux-low.c (handle_extended_wait): Surround call to
5532 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5533
4d9b86e1
SM
55342018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5535
5536 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5537 linux_ptrace_attach_fail_reason_string now returning an
5538 std::string.
5539 (linux_attach): Likewise.
5540 * thread-db.c (attach_thread): Likewise.
5541
f517c180
EA
55422018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5543
5544 PR gdb/21559
5545 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5546 checking for fs_base/gs_base fields in struct user_regs_struct.
5547 * configure: Regenerate.
5548
9a70f35c
YQ
55492018-01-16 Yao Qi <yao.qi@linaro.org>
5550
5551 PR gdb/18749
5552 * linux-low.c (fetch_register): Call supply_register instead of
5553 error.
5554
605fd3c6
YQ
55552018-01-08 Yao Qi <yao.qi@linaro.org>
5556 Simon Marchi <simon.marchi@ericsson.com>
5557
5558 * Makefile.in (OBS): Remove selftest.o.
5559 * configure.ac: Set srv_selftest_objs if $development is true.
5560 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5561 * configure: Re-generated.
5562 * server.c (captured_main): Wrap variable selftest_filter with
5563 GDB_SELF_TEST.
5564
2cc05030
SM
55652018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5566
5567 * server.c (parse_debug_format_options): Return std::string.
5568 (handle_monitor_command, captured_main): Adjust.
5569
e379cee6
PA
55702018-01-05 Pedro Alves <palves@redhat.com>
5571
5572 PR gdb/18653
5573 * server.c (captured_main): Pass quiet=false to
5574 save_original_signals_state.
5575
82e1e79a
JB
55762018-01-01 Joel Brobecker <brobecker@adacore.com>
5577
5578 * gdbreplay.c (gdbreplay_version): Update copyright year in
5579 version message.
5580 * server.c (gdbserver_version): Likewise.
5581
8e481c3b
TT
55822017-12-08 Tom Tromey <tom@tromey.com>
5583
5584 * ax.c (ax_printf): Update.
5585
a8806230
YQ
55862017-12-07 Yao Qi <yao.qi@linaro.org>
5587
5588 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5589 aarch64_linux_read_description.
5590 * linux-amd64-ipa.c (idx2mask): New array.
5591 (get_ipa_tdesc): Move idx2mask out.
5592 (initialize_low_tracepoint): Initialize target descriptions.
5593 * linux-i386-ipa.c (idx2mask): New array.
5594 (get_ipa_tdesc): Move idx2mask out.
5595 (initialize_low_tracepoint): Initialize target descriptions.
5596
d4a0e8b5
SM
55972017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5598
5599 * tdesc.c (struct tdesc_type): Change return type.
5600 (tdesc_add_flag): Change parameter type.
5601 (tdesc_add_bitfield): Likewise.
5602 (tdesc_add_field): Likewise.
5603 (tdesc_set_struct_size): Likewise.
5604
798a7429
SM
56052017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5606
5607 * regcache.c (registers_to_string): Remove unused variable.
5608
c0e15c9b
SM
56092017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5610
5611 * inferiors.c (for_each_inferior_with_data): Remove.
5612 * inferiors.h (for_each_inferior_with_data): Remove.
5613 * server.c (handle_qxfer_threads_worker): Change parameter type.
5614 (handle_qxfer_threads_proper): Use for_each_thread.
5615
f0045347
SM
56162017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5617
5618 * inferiors.c (for_each_inferior): Remove.
5619 (clear_inferiors): Use for_each_thread.
5620 * inferiors.h (for_each_inferior): Remove.
5621 * linux-low.c (linux_wait_for_event_filtered): Use
5622 for_each_thread.
5623 (linux_stabilize_threads): Likewise.
5624 * regcache.c (regcache_release): Likewise.
5625 * server.c (gdb_wants_all_threads_stopped): Likewise.
5626 (clear_pending_status_callback): Remove.
5627 (handle_status): Use for_each_thread.
5628 (captured_main): Likewise.
5629 * win32-low.c (child_init_thread_list): Likewise.
5630 (win32_clear_inferiors): Likewise.
5631 (fake_breakpoint_event): Likewise.
5632
9521758b
SM
56332017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5634
5635 * inferiors.h (find_inferior): Remove.
5636 * inferiors.c (find_inferior): Remove.
5637
8f86d7aa
SM
56382017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5639
5640 * linux-low.c (resume_status_pending_p): Update comment.
5641 (need_step_over_p): Update comment.
5642
e2b44075
SM
56432017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5644
5645 * linux-low.c (proceed_one_lwp): Return void, change parameter
5646 type.
5647 (unsuspend_and_proceed_one_lwp): Likewise.
5648 (proceed_all_lwps): Use for_each_thread.
5649 (unstop_all_lwps): Likewise.
5650
c80825ff
SM
56512017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5652
5653 * linux-low.c (linux_resume_one_thread): Return void, take
5654 parameter directly.
5655 (linux_resume): Use for_each_thread.
5656
df3e4dbe
SM
56572017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5658
5659 * linux-low.c (send_sigstop_callback): Return void, change
5660 parameter type. Rename to...
5661 (send_sigstop): ... this.
5662 (suspend_and_send_sigstop_callback): Return void, change parameter
5663 type. Rename to...
5664 (suspend_and_send_sigstop): ... this.
5665 (stop_all_lwps): Use for_each_thread.
5666
5a6b0a41
SM
56672017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5668
5669 * linux-low.c (lwp_running): Return bool, remove unused
5670 argument.
5671 (linux_stabilize_threads): Use find_thread.
5672
39a64da5
SM
56732017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5674
5675 * linux-low.c (select_singlestep_lwp_callback): Remove.
5676 (count_events_callback): Remove.
5677 (select_event_lwp_callback): Remove.
5678 (select_event_lwp): Use find_thread/for_each_thread.
5679
a1385b7b
SM
56802017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5681
5682 * linux-low.c (not_stopped_callback): Return bool, take filter
5683 argument directly.
5684 (linux_wait_for_event_filtered): Use find_thread.
5685 (linux_wait_1): Likewise.
5686
454296a2
SM
56872017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5688
5689 * linux-low.c (same_lwp): Remove.
5690 (find_lwp_pid): Use find_thread.
5691
6b2a85da
SM
56922017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5693
5694 * linux-low.c (delete_lwp_callback): Remove.
5695 (linux_mourn): Use for_each_thread.
5696
798a38e8
SM
56972017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5698
5699 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5700 args parameter, don't check for pid.
5701 (linux_detach): Use for_each_thread.
5702
e4eb0dec
SM
57032017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5704
5705 * linux-low.c (struct counter): Remove.
5706 (second_thread_of_pid_p): Remove.
5707 (last_thread_of_process_p): Use find_thread.
5708
83e1b6c1
SM
57092017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5710
5711 * inferiors.c (find_inferior_in_random): Remove.
5712 * inferiors.h (find_inferior_in_random): Remove.
5713 * linux-low.c (status_pending_p_callback): Return bool, accept
5714 parameter ptid directly.
5715 (linux_wait_for_event_filtered): Use find_thread_in_random.
5716 (linux_wait_1): Likewise.
5717
8dc7b443
SM
57182017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5719
5720 * inferiors.c (find_inferior_id): Remove.
5721 (find_thread_ptid): Move implemention from find_inferior_id to
5722 here.
5723 * inferiors.h (find_inferior_id): Remove.
5724 * server.c (handle_status): Use find_thread_ptid.
5725 (process_serial_event): Likewise.
5726 * thread-db.c (find_one_thread): Likewise.
5727 (thread_db_thread_handle): Likewise.
5728 * win32-low.c (thread_rec): Likewise.
5729 (child_delete_thread): Likewise.
5730 (win32_thread_alive): Likewise.
5731 (get_child_debug_event): Likewise.
5732
da25033c
SM
57332017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5734
5735 * linux-mips-low.c (update_watch_registers_callback): Return
5736 void, remove pid_p parameter, don't check for pid.
5737 (mips_insert_point, mips_remove_point): Use for_each_thread.
5738
c91bb56b
SM
57392017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5740
5741 * lynx.low (lynx_delete_thread_callback): Remove.
5742 (lynx_mourn): Use for_each_thread.
5743
634a3254
SM
57442017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5745
5746 * regcache.c (regcache_invalidate_one): Remove.
5747 (regcache_invalidate_pid): use for_each_thread.
5748
41272101
TT
57492017-11-26 Tom Tromey <tom@tromey.com>
5750
5751 * linux-low.c (linux_create_inferior): Update.
5752
f5291a6f
UW
57532017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
5754
5755 * spu-low.c (spu_create_inferior): Fix typo in argument name.
5756
6654d750
AH
57572017-11-24 Alan Hayward <alan.hayward@arm.com>
5758
5759 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
5760 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5761 * linux-aarch64-tdesc-selftest.c: New file.
5762 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5763
57642017-11-24 Alan Hayward <alan.hayward@arm.com>
5765
5766 * configure.srv: Add new file.
5767 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5768 * linux-aarch64-tdesc-selftest.c: New file.
5769 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5770
49bdb7ee
AH
57712017-11-24 Alan Hayward <alan.hayward@arm.com>
5772
5773 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
5774 * linux-aarch64-low.c (initialize_low_arch): Remove init.
5775 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
5776
d6d7ce56
AH
57772017-11-24 Alan Hayward <alan.hayward@arm.com>
5778
5779 * configure.srv: Add new files.
5780 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
5781 aarch64_linux_read_description.
5782 * linux-aarch64-low.c (aarch64_linux_read_description):
5783 Merge with aarch64_arch_setup.
5784 (aarch64_arch_setup): Call aarch64_linux_read_description.
5785 * linux-aarch64-tdesc.c: New file.
5786 * linux-aarch64-tdesc.h: New file.
5787
506fe5f4
YQ
57882017-11-24 Yao Qi <yao.qi@linaro.org>
5789
5790 * configure.srv: Set $srv_regobj for tic6x-linux.
5791 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
5792 (tic6x_read_description): Move some code to tic6x_arch_setup.
5793 (tic6x_tdesc_test): New function.
5794 (initialize_low_arch): Call selftests::register_test.
5795
29f9a567
YQ
57962017-11-22 Yao Qi <yao.qi@linaro.org>
5797
5798 * remote-utils.c (prepare_resume_reply): Use memcpy.
5799
578290ec
SM
58002017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5801
5802 * linux-low.c (kill_one_lwp_callback): Return void, take
5803 argument directly, don't filter on pid.
5804 (linux_kill): Use for_each_thread.
5805
eca55aec
SM
58062017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5807
5808 * linux-low.c (need_step_over_p): Return bool, remove dummy
5809 argument.
5810 (linux_resume, proceed_all_lwps): Use find_thread.
5811
25c28b4d
SM
58122017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5813
5814 * linux-low.c (resume_status_pending_p): Return bool, remove
5815 flag_p argument.
5816 (linux_resume): Use find_thread.
5817
5fdda392
SM
58182017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5819
5820 * linux-low.c (struct thread_resume_array): Remove.
5821 (linux_set_resume_request): Return void, take arguments
5822 directly.
5823 (linux_resume): Use for_each_thread.
5824
fcb056a5
SM
58252017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5826
5827 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
5828 return bool, remove data argument.
5829 (linux_stabilize_threads): Use find_thread.
5830
139720c5
SM
58312017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5832
5833 * linux-low.c (unsuspend_one_lwp): Remove.
5834 (unsuspend_all_lwps): Use for_each_thread, inline code from
5835 unsuspend_one_lwp.
5836
6d1e5673
SM
58372017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5838
5839 * gdbthread.h (find_thread): Add overload with ptid_t filter.
5840 * linux-low.c (struct iterate_over_lwps_args): Remove.
5841 (iterate_over_lwps_filter): Remove.
5842 (iterate_over_lwps): Use find_thread.
5843
bbf550d5
SM
58442017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5845
5846 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
5847 (linux_handle_new_gdb_connection): Use for_each_thread, inline
5848 code from reset_lwp_ptrace_options_callback.
5849
00192f77
SM
58502017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5851
5852 * linux-arm-low.c (struct update_registers_data): Remove.
5853 (update_registers_callback): Return void, take arguments
5854 directly, don't check thread's pid.
5855 (arm_insert_point, arm_remove_point): Use for_each_thread.
5856
2bee2b6c
SM
58572017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5858
5859 * win32-low.c (continue_one_thread): Return void, take argument
5860 directly.
5861 (child_continue): Use for_each_thread.
5862
0b360f19
SM
58632017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5864
5865 * win32-i386-low.c (update_debug_registers_callback): Rename
5866 to ...
5867 (update_debug_registers): ... this, return void, remove pid_p arg.
5868 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
5869
f27866ba
SM
58702017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5871
5872 * inferiors.h (struct process_info): Add constructor, initialize
5873 fields..
5874 <syscalls_to_catch>: Change type to std::vector<int>.
5875 * inferiors.c (add_process): Allocate process_info with new.
5876 (remove_process): Free process_info with delete.
5877 * linux-low.c (handle_extended_wait): Adjust.
5878 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
5879 * server.c (handle_general_set): Adjust.
5880
e849ea89
PA
58812017-11-16 Pedro Alves <palves@redhat.com>
5882
5883 * remote-utils.c (remote_close): Block SIGIO signals instead of
5884 uninstalling the SIGIO handler.
5885
1d0aa65c
AH
58862017-11-16 Alan Hayward <alan.hayward@arm.com>
5887
5888 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
5889
3491a34c
YQ
58902017-11-16 Yao Qi <yao.qi@linaro.org>
5891
5892 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
5893 (tic6x_store_gregset): Likewise.
5894 (tic6x_usrregs_info): Move it up.
5895
a602f924
AH
58962017-11-15 Alan Hayward <alan.hayward@arm.com>
5897
5898 * Makefile.in: Update arch rules.
5899 * configure.srv: Explicitly mark arch/ files.
5900
5616b6c3
AS
59012017-11-13 Andreas Schwab <schwab@suse.de>
5902
5903 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
5904 function.
5905 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5906
d1928160
PA
59072017-11-06 Pedro Alves <palves@redhat.com>
5908
5909 * config.in, configure: Regenerate.
5910
bac608e7
SM
59112017-10-27 Simon Marchi <simon.marchi@ericsson.com>
5912
5913 * target.c (struct thread_search): Remove.
5914 (thread_search_callback): Remove.
5915 (prepare_to_access_memory): Use for_each_thread instead of
5916 find_inferior. Inline code from thread_search_callback.
5917
eaddb425
SM
59182017-10-27 Simon Marchi <simon.marchi@ericsson.com>
5919
5920 * server.c (struct visit_actioned_threads_data): Remove.
5921 (visit_actioned_threads): Change prototype to take arguments
5922 directly.
5923 (resume): Use find_thread instead of find_inferior.
5924
99078d34
SM
59252017-10-27 Simon Marchi <simon.marchi@ericsson.com>
5926
5927 * server.c (queue_stop_reply_callback): Change prototype, return
5928 void.
5929 (find_status_pending_thread_callback): Remove.
5930 (handle_status): Replace find_inferior with find_thread and
5931 for_each_thread.
5932
cc628f3d
AH
59332017-10-25 Alan Hayward <alan.hayward@arm.com>
5934
5935 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
5936 with REGNO.
5937 (aarch64_store_gregset): Likewise.
5938 (aarch64_fill_fpregset): Likewise.
5939 (aarch64_store_fpregset): Likewise.
5940
4d3bb80e
SM
59412017-10-21 Simon Marchi <simon.marchi@ericsson.com>
5942
5943 * gdbthread.h (find_thread, for_each_thread): New functions.
5944 * inferiors.c (thread_of_pid): Remove.
5945 (find_any_thread_of_pid): Use find_thread.
5946 * linux-low.c (num_lwps): Use for_each_thread.
5947
7a7cdfa0
YQ
59482017-10-17 Yao Qi <yao.qi@linaro.org>
5949
5950 * Makefile.in: Remove one rule.
5951 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
5952
e675d170
YQ
59532017-10-17 Yao Qi <yao.qi@linaro.org>
5954
5955 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
5956 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
5957
7eb4e0f9
YQ
59582017-10-17 Yao Qi <yao.qi@linaro.org>
5959
5960 * configure.srv: Rename arm.o with arch/arm.o.
5961
60d6cfc9
YQ
59622017-10-17 Yao Qi <yao.qi@linaro.org>
5963
5964 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
5965 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
5966 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
5967 (arch-i386.o, arch-amd64.o): Remove rules.
5968 (arch/%.o): New rule.
5969 Update POSTCOMPILE and COMPILE.pre.
5970 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5971 * configure: Re-generated.
5972 * configure.srv: Replace arch-i386.o with arch/i386.o.
5973 Replace arch-amd64.o with arch/amd64.o.
5974
5bfda255
YQ
59752017-10-16 Yao Qi <yao.qi@linaro.org>
5976
5977 * configure: Regenerated.
5978
9c80ecd6
SM
59792017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5980
5981 * inferiors.h: (struct inferior_list): Remove.
5982 (struct inferior_list_entry); Remove.
5983 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
5984 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
5985 get_first_inferior): Remove.
5986 (for_each_inferior, for_each_inferior_with_data, find_inferior,
5987 find_inferior_id, find_inferior_in_random): Change signature.
5988 * inferiors.c (all_threads): Change type to
5989 std::list<thread_info *>.
5990 (get_thread): Remove macro.
5991 (find_inferior, find_inferior_id): Change signature, implement
5992 using find_thread.
5993 (find_inferior_in_random): Change signature, implement using
5994 find_thread_in_random.
5995 (for_each_inferior, for_each_inferior_with_data): Change
5996 signature, implement using for_each_thread.
5997 (add_inferior_to_list, remove_inferior): Remove.
5998 (add_thread, get_first_thread, thread_of_pid,
5999 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6000 (get_first_inferior, one_inferior_p, clear_inferior_list):
6001 Remove.
6002 (clear_inferiors, get_thread_process): Update.
6003 * gdbthread.h: Include <list>.
6004 (struct thread_info) <entry>: Remove field.
6005 <id>: New field.
6006 (all_threads): Change type to std::list<thread_info *>.
6007 (get_first_inferior): Add doc.
6008 (find_thread, for_each_thread, find_thread_in_random): New
6009 functions.
6010 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6011 * linux-arm-low.c (update_registers_callback): Update.
6012 * linux-low.c (second_thread_of_pid_p): Update.
6013 (kill_one_lwp_callback, linux_detach_lwp_callback,
6014 delete_lwp_callback, status_pending_p_callback, same_lwp,
6015 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6016 iterate_over_lwps, not_stopped_callback,
6017 resume_stopped_resumed_lwps, count_events_callback,
6018 select_singlestep_lwp_callback, select_event_lwp_callback,
6019 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6020 suspend_and_send_sigstop_callback, wait_for_sigstop,
6021 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6022 lwp_running, linux_set_resume_request, resume_status_pending_p,
6023 need_step_over_p, start_step_over, linux_resume_one_thread,
6024 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6025 reset_lwp_ptrace_options_callback): Update.
6026 * linux-mips-low.c (update_watch_registers_callback): Update.
6027 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6028 Update.
6029 (free_register_cache_thread_one): Remove.
6030 (regcache_release): Update.
6031 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6032 handle_qxfer_threads_worker): Update.
6033 (handle_query): Update, use list iterator.
6034 (visit_actioned_threads, handle_pending_status,
6035 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6036 clear_pending_status_callback, set_pending_status_callback,
6037 find_status_pending_thread_callback, handle_status,
6038 process_serial_event): Update.
6039 * target.c (thread_search_callback): Update.
6040 * thread-db.c (thread_db_get_tls_address): Update.
6041 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6042 Update.
6043 * win32-i386-low.c (update_debug_registers_callback): Update.
6044 * win32-low.c (delete_thread_info, child_delete_thread,
6045 continue_one_thread, suspend_one_thread,
6046 get_child_debug_event): Adjust.
6047
9179355e
SM
60482017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6049
6050 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6051 * inferiors.h: Include <list>.
6052 (struct process_info) <entry>: Remove field.
6053 <pid>: New field.
6054 (pid_of): Change macro to function.
6055 (ptid_of, lwpid_of): Remove macro.
6056 (all_processes): Change type to std::list<process_info *>.
6057 (ALL_PROCESSES): Remove macro.
6058 (for_each_process, find_process): New function.
6059 * inferiors.c (all_processes): Change type to
6060 std::list<process_info *>.
6061 (find_thread_process): Adjust.
6062 (add_process): Likewise.
6063 (remove_process): Likewise.
6064 (find_process_pid): Likewise.
6065 (get_first_process): Likewise.
6066 (started_inferior_callback): Remove.
6067 (have_started_inferiors_p): Adjust.
6068 (attached_inferior_callback): Remove.
6069 (have_attached_inferiors_p): Adjust.
6070 * linux-low.c (check_zombie_leaders): Likewise.
6071 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6072 (x86_linux_update_xmltarget): Adjust.
6073 * server.c (handle_query): Likewise.
6074 (gdb_reattached_process): Remove.
6075 (handle_status): Adjust.
6076 (kill_inferior_callback): Likewise.
6077 (detach_or_kill_inferior): Remove.
6078 (print_started_pid): Likewise.
6079 (print_attached_pid): Likewise.
6080 (detach_or_kill_for_exit): Update.
6081 (process_serial_event): Likewise.
6082 * linux-arm-low.c (arm_new_fork): Likewise.
6083
c9cb8905
SM
60842017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6085
6086 * dll.h: Include <list>.
6087 (struct dll_info): Add constructor.
6088 <entry>: Remove field.
6089 (all_dlls): Change type to std::list<dll_info>.
6090 * dll.c: Include <algorithm>.
6091 (get_dll): Remove macro.
6092 (all_dlls): Change type to std::list<dll_info *>.
6093 (free_one_dll): Remove.
6094 (match_dll): Likewise.
6095 (loaded_dll): Adjust.
6096 (unloaded_dll): Adjust to all_dlls type change, use
6097 std::find_if. Inline code from match_dll.
6098 (clear_dlls): Adjust to all_dlls type change.
6099 * server.c (emit_dll_description): Remove.
6100 (handle_qxfer_libraries): Adjust to all_dlls type change,
6101 integrate emit_dll_description's functionality.
6102
04ec7890
SM
61032017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6104
6105 * linux-low.h (struct linux_target_ops) <delete_process>: New
6106 field.
6107 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6108 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6109 (struct linux_target_ops): Add delete_process callback.
6110 * linux-arm-low.c (arm_delete_process): New.
6111 (struct linux_target_ops): Add delete_process callback.
6112 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6113 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6114 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6115 * linux-mips-low.c (mips_linux_delete_process): New.
6116 (struct linux_target_ops): Add delete_process callback.
6117 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6118 * linux-s390-low.c (struct linux_target_ops): Likewise.
6119 * linux-sh-low.c (struct linux_target_ops): Likewise.
6120 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6121 * linux-tile-low.c (struct linux_target_ops): Likewise.
6122 * linux-x86-low.c (x86_linux_delete_process): New.
6123 (struct linux_target_ops): Add delete_process callback.
6124 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6125
466eecee
SM
61262017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6127
6128 * linux-aarch64-low.c (the_low_target): Add thread delete
6129 callback.
6130 * linux-arm-low.c (arm_delete_thread): New function.
6131 (the_low_target): Add thread delete callback.
6132 * linux-bfin-low.c (the_low_target): Likewise.
6133 * linux-crisv32-low.c (the_low_target): Likewise.
6134 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6135 set.
6136 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6137 field.
6138 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6139 * linux-mips-low.c (mips_linux_delete_thread): New function.
6140 (the_low_target): Add thread delete callback.
6141 * linux-ppc-low.c (the_low_target): Likewise.
6142 * linux-s390-low.c (the_low_target): Likewise.
6143 * linux-sh-low.c (the_low_target): Likewise.
6144 * linux-tic6x-low.c (the_low_target): Likewise.
6145 * linux-tile-low.c (the_low_target): Likewise.
6146 * linux-x86-low.c (the_low_target): Likewise.
6147 * linux-xtensa-low.c (the_low_target): Likewise.
6148
b79f7801
YZ
61492017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6150
6151 * win32-low.c: Include "common-inferior.h".
6152
bc3b087d
SDJ
61532017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6154
6155 * inferiors.c (set_inferior_cwd): New function.
6156 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6157 (handle_query): Inform that QSetWorkingDir is supported.
6158 * win32-low.c (create_process): Pass the inferior's cwd to
6159 CreateProcess.
6160
d092c5a2
SDJ
61612017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6162
6163 * inferiors.c (current_inferior_cwd): New global variable.
6164 (get_inferior_cwd): New function.
6165 * inferiors.h (struct process_info) <cwd>: New field.
6166
7da0a886
SDJ
61672017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6168
6169 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6170 (OBS): Add gdb_tilde_expand.o.
6171
289a6840
SM
61722017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6173
6174 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6175 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6176
256642e8
PA
61772017-09-29 Pedro Alves <palves@redhat.com>
6178
6179 * ax.c (gdb_parse_agent_expr): Constify.
6180 * ax.h (gdb_parse_agent_expr): Constify.
6181 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6182 Constify.
6183 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6184 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6185 * remote-utils.h (read_ptid): Constify.
6186 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6187 (process_point_options, process_serial_event): Constify.
6188 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6189 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6190 (cmd_qtbuffer): Constify.
6191
5b9ca4d4
PA
61922017-09-29 Pedro Alves <palves@redhat.com>
6193
6194 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6195 fails.
6196
94c207e0
PA
61972017-09-29 Pedro Alves <palves@redhat.com>
6198
6199 * linux-low.c (handle_extended_wait): Pass parent thread instead
6200 of process to thread_db_notice_clone.
6201 * linux-low.h (thread_db_notice_clone): Replace parent process
6202 parameter with parent thread parameter.
6203 * thread-db.c (find_one_thread): Add comment.
6204 (thread_db_notice_clone): Replace parent process parameter with
6205 parent thread parameter. Temporarily switch to the parent thread.
6206
75352e28
SDJ
62072017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6208
6209 * gdbthread.h: Include "common-gdbthread.h".
6210 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6211 "if" when validating the ptid.
6212 * remote-utils.c: Include "gdbthread.h".
6213 (prepare_resume_reply): Use "switch_to_thread".
6214 * target.c (done_accessing_memory): Likewise.
6215
ad339634
AA
62162017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6217
6218 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6219 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6220 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6221 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6222 s390x-gs-linux64-ipa.o to ipa_obj.
6223 * linux-s390-low.c (HWCAP_S390_GS): New define.
6224 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6225 New functions.
6226 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6227 (s390_arch_setup): Check for guarded-storage support and choose
6228 appropriate tdesc.
6229 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6230 init_registers_s390x_gs_linux64.
6231 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6232 enum value.
6233 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6234 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6235
cc4d742f
SM
62362017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6237
6238 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6239
f6327dcb
KB
62402017-09-21 Kevin Buettner <kevinb@redhat.com>
6241
6242 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6243 (thread_db_thread_handle): Declare.
6244 * linux-low.c (linux_target_ops): Initialize thread_handle.
6245 * server.c (handle_qxfer_threads_worker): Add support for
6246 "handle" attribute.
6247 * target.h (struct target_ops): Add new function pointer,
6248 thread_handle.
6249 (target_thread_handle): Define.
6250 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6251 field in lwp.
6252 (thread_db_thread_handle): New function.
6253
86299109
KB
62542017-09-21 Kevin Buettner <kevinb@redhat.com>
6255
6256 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6257 * linux-low.h (thread_db_notice_clone): Declare.
6258 * thread-db.c (thread_db_notice_clone): New function.
6259
f557a88a
PA
62602017-09-21 Pedro Alves <palves@redhat.com>
6261
6262 * server.c (gdb_read_memory, handle_status, process_serial_event)
6263 (handle_serial_event, handle_target_event): Adjust to
6264 set_desired_thread prototype change.
6265 * target.c (set_desired_thread): Remove 'use_general' parameter
6266 and adjust.
6267 * target.h (set_desired_thread): Remove 'use_general' parameter.
6268
223ffa71
TT
62692017-09-20 Tom Tromey <tom@tromey.com>
6270
6271 * target.c (target_terminal::terminal_state): Define.
6272 (target_terminal::init): Rename from target_terminal_init.
6273 (target_terminal::inferior): Rename from
6274 target_terminal_inferior.
6275 (target_terminal::ours): Rename from target_terminal_ours.
6276 (target_terminal::ours_for_output, target_terminal::info): New.
6277
04fd3ba9
SM
62782017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6279
6280 * server.c (accumulate_file_name_length): Remove.
6281 (emit_dll_description): Adjust to std::string change.
6282 (handle_qxfer_libraries): Use std::string to hold document.
6283
5e187554
SM
62842017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6285
6286 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6287 return type of xml_escape_text.
6288 * server.c (emit_dll_description): Likewise.
6289
1526853e
SM
62902017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6291
6292 * server.c (captured_main): Accept argument for --selftest.
6293 Update run_tests call.
6294 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6295 when registering selftests.
6296
c4dfafab
SDJ
62972017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6298
6299 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6300 instead of "VEC" for "target_desc.reg_defs".
6301 (regcache_cpy): Likewise.
6302 (registers_to_string): Likewise.
6303 (registers_from_string): Likewise.
6304 (find_regno): Likewise.
6305 (supply_regblock): Likewise.
6306 (regcache_raw_read_unsigned): Likewise.
6307 * tdesc.c (init_target_desc): Likewise.
6308 (tdesc_create_reg): Likewise.
6309 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6310 (struct target_desc) <reg_defs>: Convert to "std::vector".
6311 (target_desc): Do not initialize "reg_defs".
6312 (~target_desc): Update code to use "std::vector" instead of "VEC"
6313 for "target_desc.reg_defs".
6314 (operator==): Likewise.
6315
124aceb4
SM
63162017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6317
6318 * inferiors.h (thread_to_gdb_id): Remove.
6319 * inferiors.c (thread_to_gdb_id): Remove.
6320 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6321 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6322 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6323 Likewise.
6324 * nto-low.c (nto_fetch_registers, nto_store_registers,
6325 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6326
96cde54f
SM
63272017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6328
6329 * inferiors.h (gdb_id_to_thread_id): Remove.
6330 * inferiors.c (gdb_id_to_thread_id): Remove.
6331 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6332 removal. Move pid declaration closer to where it's used.
6333
e8ca139e
SM
63342017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6335
6336 * server.c (handle_detach): New function.
6337 (process_serial_event): Move code out, call handle_detach.
6338
f8a4e119
SM
63392017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6340
6341 * server.c (require_running): Rename to ...
6342 (require_running_or_return): ... this ...
6343 (require_running_or_break): ... and this.
6344 (handle_query, process_serial_event): Adjust.
6345
0eb0a407
SM
63462017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6347
6348 * linux-low.c (linux_set_resume_request): Remove unused
6349 variables.
6350
785922a5
SM
63512017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6352
6353 * server.c (first_thread_of): Remove.
6354 (process_serial_event): Replace usage of first_thread_of with
6355 find_any_thread_of_pid.
6356 * tracepoint.c (same_process_p): Remove.
6357 (gdb_agent_about_to_close): Replace usage of same_process_p with
6358 find_any_thread_of_pid.
6359 * linux-x86-low.c (same_process_callback): Remove.
6360 (x86_arch_setup_process_callback): Replace usage of
6361 same_process_callback with find_any_thread_of_pid.
6362 * thread-db.c (any_thread_of): Remove.
6363 (switch_to_process): Replace usage of any_thread_of with
6364 find_any_thread_of_pid.
6365 * inferiors.c (thread_pid_matches_callback): Remove.
6366 (find_thread_process): Adjust to use find_any_thread_of_pid.
6367
a059f00c
SDJ
63682017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6369
6370 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 6371 with "!VEC_empty".
a059f00c 6372
cc397f3a
SDJ
63732017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6374
6375 * linux-low.c (handle_extended_wait): Use
6376 "allocate_target_description" instead of "XNEW".
6377 * linux-x86-low.c (initialize_low_arch): Likewise.
6378
22916b07
YQ
63792017-09-05 Yao Qi <yao.qi@linaro.org>
6380
6381 * configure.srv (srv_i386_regobj): Remove.
6382 (srv_amd64_regobj): Remove.
6383 (srv_regobj): Set it to "" for x86 non-linux targets.
6384 * linux-x86-tdesc.c (i386_linux_read_description):
6385 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6386 (init_registers_i386): Remove the declaration.
6387 (tdesc_i386): Remove the declaration.
6388 (lynx_i386_arch_setup): Call i386_create_target_description.
6389 * nto-x86-low.c: Likewise.
6390 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6391 [!__x86_64__]: include arch/i386.h.
6392 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6393
38602d55
YQ
63942017-09-05 Yao Qi <yao.qi@linaro.org>
6395
6396 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6397 i386/amd64-XXX-linux from it.
6398
44b886ff
YQ
63992017-09-05 Yao Qi <yao.qi@linaro.org>
6400
6401 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6402 false.
6403 (ipa_amd64_linux_regobj): Remove.
6404 (ipa_x32_linux_regobj): Remove.
6405
b4570e4b
YQ
64062017-09-05 Yao Qi <yao.qi@linaro.org>
6407
6408 * Makefile.in (arch-amd64.o): New rule.
6409 * configure.srv: Append arch-amd64.o.
6410 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6411 (get_ipa_tdesc): Call amd64_linux_read_description.
6412 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6413 and init_registers_amd64_XXX.
6414 * linux-x86-low.c (x86_linux_read_description): Call
6415 amd64_linux_read_description.
6416 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6417 (initialize_low_arch): Don't call init_registers_x32_XXX and
6418 init_registers_amd64_XXX.
6419 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6420 and tdesc_amd64_XXX.
6421 [__x86_64__] (amd64_tdesc_test): New function.
6422 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6423 and init_registers_amd64_XXX.
6424 * linux-x86-tdesc.c: Include arch/amd64.h.
6425 (xcr0_to_tdesc_idx): New function.
6426 (i386_linux_read_description): New function.
6427 (amd64_get_ipa_tdesc_idx): New function.
6428 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6429 (amd64_get_ipa_tdesc): Declare.
6430
d1f28ea2
YQ
64312017-09-05 Yao Qi <yao.qi@linaro.org>
6432
6433 * configure.srv (srv_i386_linux_xmlfiles): Remove
6434 i386/i386-XXX-linux.xml from it.
6435
25a93583
YQ
64362017-09-05 Yao Qi <yao.qi@linaro.org>
6437
6438 * configure.srv: Set srv_i386_linux_regobj empty if $development
6439 is false.
6440 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6441 initialize_low_tdesc.
6442 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6443 with #if initialize_low_tdesc.
6444 * linux-x86-tdesc-selftest.c: New file.
6445 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6446
5f035c07
YQ
64472017-09-05 Yao Qi <yao.qi@linaro.org>
6448
6449 * Makefile.in (arch-i386.o): New rule.
6450 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6451 (x86_64-*-linux*): Likewise.
6452 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6453 include arch/i386.h.
6454 (i386_linux_read_description): Remove code and call
6455 i386_create_target_description.
6456 * tdesc.c (allocate_target_description): New function.
6457 * tdesc.h (set_tdesc_architecture): Remove declaration.
6458 (set_tdesc_osabi): Likewise.
6459
0abe8a89
YQ
64602017-09-05 Yao Qi <yao.qi@linaro.org>
6461
6462 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6463 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6464 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6465 .xmltarget.
6466 * server.c (get_features_xml): Call tdesc_get_features_xml.
6467 * tdesc.c (set_tdesc_architecture): New function.
6468 (set_tdesc_osabi): New function.
6469 (tdesc_get_features_xml): New function.
6470 (tdesc_create_feature): Add an argument.
6471 * tdesc.h (struct target_desc) <features>: New field.
6472 <arch, osabi>: New field.
6473 (~target_desc): xfree features, arch, and osabi.
6474 (target_desc::oerator==): Don't compare .xmltarget.
6475 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6476 (set_tdesc_osabi): Likewise.
6477 (tdesc_get_features_xml): Likewise.
6478
0a188386
YQ
64792017-09-05 Yao Qi <yao.qi@linaro.org>
6480
6481 * linux-x86-tdesc.c: Include selftest.h.
6482 (i386_tdesc_test): New function.
6483 (initialize_low_tdesc): Call selftests::register_test.
6484 * tdesc.h: Include regdef.h.
6485 (target_desc): Override operator == and !=.
6486
f49ff000
YQ
64872017-09-05 Yao Qi <yao.qi@linaro.org>
6488
6489 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6490 (ipa_obj): Likewise.
6491 * linux-i386-ipa.c: Include common/x86-xstate.h
6492 (get_ipa_tdesc): Call i386_linux_read_description.
6493 (initialize_low_tracepoint): Don't call init_registers_XXX
6494 functions, call initialize_low_tdesc instead.
6495 * linux-x86-low.c (x86_linux_read_description): Call
6496 i386_linux_read_description.
6497 (initialize_low_arch): Don't call init_registers_i386_XXX
6498 functions, call initialize_low_tdesc.
6499 * linux-x86-tdesc.c: New file.
6500 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6501 (i386_get_ipa_tdesc_idx): Declare.
6502 (i386_get_ipa_tdesc): Declare.
6503 (initialize_low_tdesc): Declare.
6504
2b68ef2f
YQ
65052017-09-05 Yao Qi <yao.qi@linaro.org>
6506
6507 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6508 instead of 0.
6509
f7000548
YQ
65102017-09-05 Yao Qi <yao.qi@linaro.org>
6511
6512 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6513 * regcache.c (get_thread_regcache): Use VEC_length.
6514 (init_register_cache): Likewise.
6515 (regcache_cpy): Likewise.
6516 (registers_to_string): Iterate reg_defs via VEC_iterate.
6517 (find_regno): Likewise.
6518 (find_register_by_number): Use VEC_index.
6519 (register_size): Call find_register_by_number.
6520 (register_data): Call find_register_by_number.
6521 (supply_regblock): Use VEC_length.
6522 (regcache_raw_read_unsigned): Likewise.
6523 * tdesc.c (init_target_desc): Iterate reg_defs via
6524 VEC_iterate.
6525 (default_description): Update initializer.
6526 (copy_target_description): Don't update field num_registers.
6527 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6528 <num_registers>: Remove.
6529
50a421ac
SM
65302017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6531
6532 * Makefile.in (.SECONDARY): Define target.
6533
23fdd69e
SM
65342017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6535
6536 * linux-low.c (linux_wait_1): Adjust.
6537 * server.c (queue_stop_reply_callback): Adjust.
6538
0a2dde4a
SDJ
65392017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6540
6541 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6542 QEnvironmentUnset and QEnvironmentReset packets.
6543 (handle_query): Inform remote that QEnvironmentHexEncoded,
6544 QEnvironmentUnset and QEnvironmentReset are supported.
6545
6afd337d
SM
65462017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6547
6548 * inferiors.h (inferior_target_data): Rename to ...
6549 (thread_target_data): ... this.
6550 (inferior_regcache_data): Rename to ...
6551 (thread_regcache_data): ... this.
6552 (set_inferior_regcache_data): Rename to ...
6553 (set_thread_regcache_data): ... this.
6554 * inferiors.c (inferior_target_data): Rename to ...
6555 (thread_target_data): ... this.
6556 (inferior_regcache_data): Rename to ...
6557 (thread_regcache_data): ... this.
6558 (set_inferior_regcache_data): Rename to ...
6559 (set_thread_regcache_data): ... this.
6560 (free_one_thread): Update.
6561 * linux-low.h (get_thread_lwp): Update.
6562 * regcache.c (get_thread_regcache): Update.
6563 (regcache_invalidate_thread): Update.
6564 (free_register_cache_thread): Update.
6565 * win32-i386-low.c (update_debug_registers_callback): Update.
6566 (win32_get_current_dr): Update.
6567 * win32-low.c (thread_rec): Update.
6568 (delete_thread_info): Update.
6569 (continue_one_thread): Update.
6570 (suspend_one_thread): Update.
6571
a160cc46
SM
65722017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6573
6574 * inferiors.c (set_inferior_target_data): Remove.
6575 * inferiors.h (set_inferior_target_data): Remove.
6576
6d580b63
YQ
65772017-08-18 Yao Qi <yao.qi@linaro.org>
6578
6579 * Makefile.in (OBS): Add selftest.o.
6580 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6581 * configure, config.in: Re-generated.
6582 * server.c: Include common/sefltest.h.
6583 (captured_main): Handle option --selftest.
6584
f5a29eb0
YQ
65852017-08-09 Yao Qi <yao.qi@linaro.org>
6586
6587 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6588 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6589 i386-avx-mpx.o and i386-mmx.o.
6590 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6591 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6592 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6593 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6594 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6595 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6596 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6597 i386/amd64-avx-mpx.xml.
6598
57757c2f
YQ
65992017-08-09 Yao Qi <yao.qi@linaro.org>
6600
6601 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6602 and x32-avx-avx512.o.
6603 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6604 i386/x32-avx-avx512.xml.
6605
229d26fc
SM
66062017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6607
6608 * tracepoint.h (enum class fast_tpoint_collect_result): New
6609 enumeration.
6610 (fast_tracepoint_collecting): Change return type to
6611 fast_tpoint_collect_result.
6612 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6613 * linux-low.h: Include tracepoint.h.
6614 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6615 fast_tpoint_collect_result.
6616 * linux-low.c (handle_tracepoints): Adjust.
6617 (linux_fast_tracepoint_collecting): Change return type to
6618 fast_tpoint_collect_result.
6619 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6620 linux_wait_1, stuck_in_jump_pad_callback,
6621 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6622 proceed_one_lwp): Adjust to type change.
6623
2e1e43e1
YQ
66242017-07-10 Yao Qi <yao.qi@linaro.org>
6625
6626 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6627
adc764e7
YQ
66282017-06-29 Yao Qi <yao.qi@linaro.org>
6629
6630 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6631 Remove.
6632 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6633
a206891a
SM
66342017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6635
6636 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6637
9a6c7d9c
SDJ
66382017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6639
6640 * linux-low.c (linux_create_inferior): Adjust code to access the
6641 environment information via 'gdb_environ' class.
6642 * lynx-low.c (lynx_create_inferior): Likewise.
6643 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6644 (get_environ): Return a pointer to 'our_environ'.
6645 (captured_main): Initialize 'our_environ'.
6646 * server.h (get_environ): Adjust prototype.
6647 * spu-low.c (spu_create_inferior): Adjust code to access the
6648 environment information via 'gdb_environ' class.
6649
ae3e2ccf
SM
66502017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6651
6652 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6653 usage of "register" keyword.
6654
3e019bdc
SM
66552017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6656
6657 * configure: Re-generate.
6658
8465943a
SM
66592017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6660
6661 * configure: Re-generate.
6662
cf0dd6f0
SM
66632017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6664
6665 * Makefile.in (COMPILE.pre): Add "-x c++".
6666
9845682b
SDJ
66672017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6668
6669 * fork-child.c: Conditionally include <signal.h>.
6670
aefd8b33
SDJ
66712017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6672
6673 * server.c (handle_general_set): Handle new packet
6674 "QStartupWithShell".
6675 (handle_query): Add "QStartupWithShell" to the list of supported
6676 packets.
6677 (gdbserver_usage): Add help text explaining the
6678 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6679 options.
6680 (captured_main): Recognize and act upon the presence of the new
6681 CLI options.
6682
2090129c
SDJ
66832017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6684 Pedro Alves <palves@redhat.com>
6685
6686 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6687 * configure: Regenerate.
6688 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6689 "fork-inferior.o".
6690 (i[34567]86-*-lynxos*): Likewise.
6691 (spu*-*-*): Likewise.
6692 * fork-child.c: New file.
6693 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6694 and "environ.h".
6695 (linux_ptrace_fun): New function.
6696 (linux_create_inferior): Adjust function prototype to reflect
6697 change on "target.h". Adjust function code to use
6698 "fork_inferior".
6699 (linux_request_interrupt): Delete "signal_pid".
6700 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6701 (lynx_ptrace_fun): New function.
6702 (lynx_create_inferior): Adjust function prototype to reflect
6703 change on "target.h". Adjust function code to use
6704 "fork_inferior".
6705 * nto-low.c (nto_create_inferior): Adjust function prototype and
6706 code to reflect change on "target.h". Update comments.
6707 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6708 "common-terminal.h" and "environ.h".
6709 (terminal_fd): Moved to fork-child.c.
6710 (old_foreground_pgrp): Likewise.
6711 (restore_old_foreground_pgrp): Likewise.
6712 (last_status): Make it global.
6713 (last_ptid): Likewise.
6714 (our_environ): New variable.
6715 (startup_with_shell): Likewise.
6716 (program_name): Likewise.
6717 (program_argv): Rename to...
6718 (program_args): ...this.
6719 (wrapper_argv): New variable.
6720 (start_inferior): Delete function.
6721 (get_exec_wrapper): New function.
6722 (get_exec_file): Likewise.
6723 (get_environ): Likewise.
6724 (prefork_hook): Likewise.
6725 (post_fork_inferior): Likewise.
6726 (postfork_hook): Likewise.
6727 (postfork_child_hook): Likewise.
6728 (handle_v_run): Update code to deal with arguments coming from the
6729 remote host. Update calls from "start_inferior" to
6730 "create_inferior".
6731 (captured_main): Likewise. Initialize environment variable. Call
6732 "have_job_control".
6733 * server.h (post_fork_inferior): New prototype.
6734 (get_environ): Likewise.
6735 (last_status): Declare.
6736 (last_ptid): Likewise.
6737 (signal_pid): Likewise.
6738 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6739 (spu_ptrace_fun): New function.
6740 (spu_create_inferior): Adjust function prototype to reflect change
6741 on "target.h". Adjust function code to use "fork_inferior".
6742 * target.c (target_terminal_init): New function.
6743 (target_terminal_inferior): Likewise.
6744 (target_terminal_ours): Likewise.
6745 * target.h: Include <vector>.
6746 (struct target_ops) <create_inferior>: Update prototype.
6747 (create_inferior): Update macro.
6748 * utils.c (gdb_flush_out_err): New function.
6749 * win32-low.c (win32_create_inferior): Adjust function prototype
6750 and code to reflect change on "target.h".
6751
043a4934
SDJ
67522017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6753
6754 * inferiors.c (switch_to_thread): New function.
6755
15652511
SDJ
67562017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6757
6758 * Makefile.in (SFILE): Add "common/job-control.c".
6759 (OBS): Add "job-control.o".
6760
21ea5acd
SDJ
67612017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6762
6763 * Makefile: Remove "@host_makefile_frag@".
6764
e13cb306
PA
67652017-05-05 Pedro Alves <palves@redhat.com>
6766
6767 * configure: Regenerate.
6768
c94fee56
SDJ
67692017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6770
6771 * configure: Regenerate.
6772
a0ff9e1a
SM
67732017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6774
6775 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
6776 software_single_step change of return type to
6777 std::vector<CORE_ADDR>.
6778 * linux-low.c (install_software_single_step_breakpoints):
6779 Likewise.
6780 * linux-low.h (install_software_single_step_breakpoints):
6781 Likewise.
6782
be628ab8
SDJ
67832017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6784
6785 * remote-utils.c: Include "gdb_termios.h" instead of
6786 "terminal.h".
6787 * terminal.h: Delete file.
6788
7c5ded6a
SDJ
67892017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6790
6791 * server.c: Include <vector>.
6792 <program_argv, wrapper_argv>: Convert to std::vector.
6793 (start_inferior): Rewrite function to use C++.
6794 (handle_v_run): Likewise. Update code that calculates the argv
6795 based on the vRun packet; use C++.
6796 (captured_main): Likewise.
6797
436252de
SM
67982017-04-06 Simon Marchi <simon.marchi@ericsson.com>
6799
6800 * server.c (handle_v_cont): Initialize thread_resume::thread
6801 with null_ptid.
6802
9bf2a700
PA
68032017-04-05 Pedro Alves <palves@redhat.com>
6804
6805 * configure: Regenerate.
6806
a121b7c1
PA
68072017-04-05 Pedro Alves <palves@redhat.com>
6808
6809 * gdbreplay.c (sync_error): Constify.
6810 * linux-x86-low.c (push_opcode): Constify.
6811
21c8a587
PA
68122017-04-05 Pedro Alves <palves@redhat.com>
6813
6814 * win32-low.c (get_child_debug_event)
6815 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
6816 Report TARGET_WAITKIND_SPURIOUS instead.
6817
fb32b4f7
PA
68182017-04-05 Pedro Alves <palves@redhat.com>
6819
e79be6e5
SM
6820 * remote-utils.c (remote_prepare, remote_open): Constify.
6821 * remote-utils.h (remote_prepare, remote_open): Constify.
6822 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 6823
65dd1e59
SM
68242017-04-04 Simon Marchi <simon.marchi@ericsson.com>
6825
6826 * Makefile.in (clean): Clear .deps.
6827
8fa5b777
SM
68282017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
6829
6830 * .gitignore: Remove generated files, replace with wildcard.
6831 * (clean): Replace removal of generated files with wildcard.
6832 (version.c): Replace with...
6833 (version-generated.c): ...this.
6834 (xml-builtin.c): Replace with...
6835 (xml-builtin-generated.c): ...this.
6836 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
6837 (%.c: *regformats*): Replace with...
6838 (%-generated.c: *regformats*): ...this.
6839
a12e714b
MF
68402017-03-27 Max Filippov <jcmvbkbc@gmail.com>
6841
6842 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
6843 (xtensa_fill_gregset): Call collect_register_by_name for
6844 threadptr register.
6845 (xtensa_store_gregset): Call supply_register_by_name for
6846 threadptr register.
6847
1a09b50a
MF
68482017-03-27 Max Filippov <jcmvbkbc@gmail.com>
6849
6850 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
6851 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
6852 (xtensa_store_gregset): Call supply_register for all registers in
6853 a0_regnum..a0_regnum + C0_NREGS range.
6854
1a01e7c6
SM
68552017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6856
6857 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
6858 (ax-ipa.o: ax.c): Remove.
6859 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
6860 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
6861 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
6862 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
6863 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
6864
36bc18a8
SM
68652017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6866
6867 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
6868 (print-utils-ipa.o: ../common/print-utils.c): Remove.
6869 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
6870 (errors-ipa.o: ../common/errors.c): Remove.
6871 (format-ipa.o: ../common/format.c): Remove.
6872 (common-utils-ipa.o: ../common/common-utils.c): Remove.
6873
a8ebe3d5
SM
68742017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6875
6876 * Makefile.in (%-ipa.o: %.c): New rule.
6877 (tracepoint-ipa.o: tracepoint.c): Remove.
6878 (utils-ipa.o: utils.c): Remove.
6879 (remote-utils-ipa.o: remote-utils.c): Remove.
6880 (regcache-ipa.o: regcache.c): Remove.
6881 (i386-linux-ipa.o: i386-linux.c): Remove.
6882 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
6883 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
6884 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
6885 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
6886 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
6887 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
6888 (amd64-linux-ipa.o: amd64-linux.c): Remove.
6889 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
6890 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
6891 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
6892 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
6893 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
6894 (aarch64-ipa.o: aarch64.c): Remove.
6895 (s390-linux32-ipa.o: s390-linux32.c): Remove.
6896 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
6897 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
6898 (s390-linux64-ipa.o: s390-linux64.c): Remove.
6899 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
6900 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
6901 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
6902 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
6903 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
6904 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
6905 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
6906 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
6907 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
6908 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
6909 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
6910 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
6911 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
6912 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
6913 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
6914 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
6915 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
6916 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
6917 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
6918 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
6919 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
6920 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
6921 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
6922 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
6923 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
6924 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
6925 (tdesc-ipa.o: tdesc.c): Remove.
6926 (x32-linux-ipa.o: x32-linux.c): Remove.
6927 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
6928 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
6929
50cfacb7
SM
69302017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6931
6932 * Makefile.in (%.o: ../arch/%.c): New rule.
6933 (arm.o: ../arch/arm.c): Remove.
6934 (arm-linux.o: ../arch/arm-linux.c): Remove.
6935 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
6936 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
6937
c5a22423
SM
69382017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6939
6940 * Makefile.in (%.o: ../nat/%.c): New rule.
6941 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
6942 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
6943 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
6944 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
6945 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
6946 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
6947 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
6948 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
6949 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
6950 (linux-personality.o: ../nat/linux-personality.c): Remove.
6951 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
6952 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
6953 (x86-linux.o: ../nat/x86-linux.c): Remove.
6954 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
6955 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
6956
6bda016b
SM
69572017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6958
6959 * Makefile.in (%.o: ../common/%.c): New rule.
6960 (signals.o: ../common/signals.c): Remove.
6961 (print-utils.o: ../common/print-utils.c): Remove.
6962 (rsp-low.o: ../common/rsp-low.c): Remove.
6963 (common-utils.o: ../common/common-utils.c): Remove.
6964 (posix-strerror.o: ../common/posix-strerror.c): Remove.
6965 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
6966 (vec.o: ../common/vec.c): Remove.
6967 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
6968 (xml-utils.o: ../common/xml-utils.c): Remove.
6969 (ptid.o: ../common/ptid.c): Remove.
6970 (buffer.o: ../common/buffer.c): Remove.
6971 (format.o: ../common/format.c): Remove.
6972 (filestuff.o: ../common/filestuff.c): Remove.
6973 (agent.o: ../common/agent.c): Remove.
6974 (errors.o: ../common/errors.c): Remove.
6975 (environ.o: ../common/environ.c): Remove.
6976 (common-debug.o: ../common/common-debug.c): Remove.
6977 (cleanups.o: ../common/cleanups.c): Remove.
6978 (common-exceptions.o: ../common/common-exceptions.c): Remove.
6979 (fileio.o: ../common/fileio.c): Remove.
6980 (common-regcache.o: ../common/common-regcache.c): Remove.
6981 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
6982 (new-op.o: ../common/new-op.c): Remove.
6983 (btrace-common.o: ../common/btrace-common.c): Remove.
6984
21122961
SM
69852017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6986
6987 * Makefile.in (%.o: ../target/%.c): New rule.
6988 (waitstatus.o: ../target/waitstatus.c): Remove.
6989
c362e621
SM
69902017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
6991
6992 * Makefile.in
6993 (%.c: ../regformats/%.dat,
6994 (%.c: ../regformats/arm/%.dat,
6995 (%.c: ../regformats/i386/%.dat,
6996 (%.c: ../regformats/rs6000/%.dat): New rules.
6997 (aarch64.c): Remove.
6998 (reg-arm.c): Remove.
6999 (arm-with-iwmmxt.c): Remove.
7000 (arm-with-vfpv2.c): Remove.
7001 (arm-with-vfpv3.c): Remove.
7002 (arm-with-neon.c): Remove.
7003 (reg-bfin.c): Remove.
7004 (reg-cris.c): Remove.
7005 (reg-crisv32.c): Remove.
7006 (i386.c): Remove.
7007 (i386-linux.c): Remove.
7008 (i386-avx.c): Remove.
7009 (i386-avx-linux.c): Remove.
7010 (i386-avx-avx512.c): Remove.
7011 (i386-avx-avx512-linux.c): Remove.
7012 (i386-mpx.c): Remove.
7013 (i386-mpx-linux.c): Remove.
7014 (i386-avx-mpx-avx512-pku.c): Remove.
7015 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7016 (i386-avx-mpx.c): Remove.
7017 (i386-avx-mpx-linux.c): Remove.
7018 (i386-mmx.c): Remove.
7019 (i386-mmx-linux.c): Remove.
7020 (reg-ia64.c): Remove.
7021 (reg-m32r.c): Remove.
7022 (reg-m68k.c): Remove.
7023 (reg-cf.c): Remove.
7024 (mips-linux.c): Remove.
7025 (mips-dsp-linux.c): Remove.
7026 (mips64-linux.c): Remove.
7027 (mips64-dsp-linux.c): Remove.
7028 (nios2-linux.c): Remove.
7029 (powerpc-32.c): Remove.
7030 (powerpc-32l.c): Remove.
7031 (powerpc-altivec32l.c): Remove.
7032 (powerpc-cell32l.c): Remove.
7033 (powerpc-vsx32l.c): Remove.
7034 (powerpc-isa205-32l.c): Remove.
7035 (powerpc-isa205-altivec32l.c): Remove.
7036 (powerpc-isa205-vsx32l.c): Remove.
7037 (powerpc-e500l.c): Remove.
7038 (powerpc-64l.c): Remove.
7039 (powerpc-altivec64l.c): Remove.
7040 (powerpc-cell64l.c): Remove.
7041 (powerpc-vsx64l.c): Remove.
7042 (powerpc-isa205-64l.c): Remove.
7043 (powerpc-isa205-altivec64l.c): Remove.
7044 (powerpc-isa205-vsx64l.c): Remove.
7045 (s390-linux32.c): Remove.
7046 (s390-linux32v1.c): Remove.
7047 (s390-linux32v2.c): Remove.
7048 (s390-linux64.c): Remove.
7049 (s390-linux64v1.c): Remove.
7050 (s390-linux64v2.c): Remove.
7051 (s390-te-linux64.c): Remove.
7052 (s390-vx-linux64.c): Remove.
7053 (s390-tevx-linux64.c): Remove.
7054 (s390x-linux64.c): Remove.
7055 (s390x-linux64v1.c): Remove.
7056 (s390x-linux64v2.c): Remove.
7057 (s390x-te-linux64.c): Remove.
7058 (s390x-vx-linux64.c): Remove.
7059 (s390x-tevx-linux64.c): Remove.
7060 (tic6x-c64xp-linux.c): Remove.
7061 (tic6x-c64x-linux.c): Remove.
7062 (tic6x-c62x-linux.c): Remove.
7063 (reg-sh.c): Remove.
7064 (reg-sparc64.c): Remove.
7065 (reg-spu.c): Remove.
7066 (amd64.c): Remove.
7067 (amd64-linux.c): Remove.
7068 (amd64-avx.c): Remove.
7069 (amd64-avx-linux.c): Remove.
7070 (amd64-avx-avx512.c): Remove.
7071 (amd64-avx-avx512-linux.c): Remove.
7072 (amd64-mpx.c): Remove.
7073 (amd64-mpx-linux.c): Remove.
7074 (amd64-avx-mpx-avx512-pku.c): Remove.
7075 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7076 (amd64-avx-mpx.c): Remove.
7077 (amd64-avx-mpx-linux.c): Remove.
7078 (x32.c): Remove.
7079 (x32-linux.c): Remove.
7080 (x32-avx.c): Remove.
7081 (x32-avx-linux.c): Remove.
7082 (x32-avx-avx512.c): Remove.
7083 (x32-avx-avx512-linux.c): Remove.
7084 (reg-xtensa.c): Remove.
7085 (reg-tilegx.c): Remove.
7086 (reg-tilegx32.c): Remove.
7087
1672e0d9
SDJ
70882017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7089
7090 * Makefile.in (SFILES): Add "common/environ.c".
7091 (OBJS): Add "common/environ.h".
7092
239b6d10
WT
70932017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7094
7095 * configure.ac: Check if the fs_base and gs_base members of
7096 `struct user_regs_struct' exist.
7097 * config.in: Regenerated.
7098 * configure: Likewise.
7099
694b382c
AT
71002017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7101
7102 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7103 target_read_memory.
7104 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7105 (get_next_pcs_syscall_next_pc): Likewise.
7106
7dc53023
LM
71072016-12-23 Luis Machado <lgustavo@codesourcery.com>
7108
7109 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7110 * nto-x86-low.c: Likewise.
7111
ad02e4fe
SM
71122016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7113
7114 * Makefile.in: Include disable-implicit-rules.mk.
7115
dcb07cfa
PA
71162016-11-23 Pedro Alves <palves@redhat.com>
7117
7118 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7119 (debug_vprintf): Use std::chrono::steady_clock instead of
7120 gettimeofday. Use '.' instead of ':'.
7121 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7122 (get_timestamp): Use std::chrono::steady_clock instead of
7123 gettimeofday.
7124
8629c02c
SM
71252016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7126
7127 * Makefile.in: Fix whitespace formatting.
7128
b593ecca
SM
71292016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7130
7131 * Makefile.in (SFILES, OBS): Flatten list and order
7132 alphabetically.
7133
9986ba08
PA
71342016-11-23 Pedro Alves <palves@redhat.com>
7135
7136 * event-loop.c (handle_file_event): Use warning.
7137 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7138 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7139 Use warning.
7140
4eefa7bc
PA
71412016-11-23 Pedro Alves <palves@redhat.com>
7142
7143 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7144 output.
7145 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7146 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7147 debug_printf and debug_flush for debug output.
7148 * server.c (handle_general_set): Likewise.
7149 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7150 output.
7151
5443506e
SM
71522016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7153
7154 * Makefile.in (.c.o): Replace rule with ...
7155 (%.o: %.c): ... this one.
7156
3b165252
SM
71572016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7158
7159 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7160 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7161 make.
7162 * configure.ac: Remove checks for the make program.
7163 * configure: Re-generate.
7164
0bcda685
PA
71652016-10-28 Pedro Alves <palves@redhat.com>
7166
7167 * Makefile.in (CXX_DIALECT): Get from configure.
7168 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7169 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7170 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7171 * config.in: Regenerate.
7172 * configure: Regenerate.
7173
c3805894
YQ
71742016-10-27 Yao Qi <yao.qi@linaro.org>
7175
7176 * linux-low.c (linux_supports_range_stepping): Return true if
7177 can_software_single_step return true.
7178
89342618
YQ
71792016-10-27 Yao Qi <yao.qi@linaro.org>
7180
7181 * inferiors.c (find_inferior_in_random): New function.
7182 * inferiors.h (find_inferior_in_random): Declare.
7183 * linux-low.c (linux_wait_for_event_filtered): Call
7184 find_inferior_in_random instead of find_inferior.
7185
e3652c84
YQ
71862016-10-27 Yao Qi <yao.qi@linaro.org>
7187
7188 * linux-low.c (linux_wait_1): If single-step breakpoints are
7189 inserted, remove them.
7190
5a04c4cf
PA
71912016-10-26 Pedro Alves <palves@redhat.com>
7192
7193 * linux-low.c (handle_extended_wait): Link parent/child fork
7194 threads.
7195 (linux_wait_1): Unlink them.
7196 (linux_set_resume_request): Ignore resume requests for
7197 already-resumed and unhandled fork child threads.
7198 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7199 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7200 New functions.
7201 (handle_v_requests) <vCont>: Don't call require_running.
7202 * server.h (in_queued_stop_replies): New declaration.
7203
cb93dc7f
YQ
72042016-10-24 Yao Qi <yao.qi@linaro.org>
7205
7206 PR server/20733
7207 * linux-aarch64-low.c (append_insns): Cast the return value to
7208 'uint32_t *'.
7209
a1078bea
YQ
72102016-10-10 Yao Qi <yao.qi@linaro.org>
7211
7212 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7213
1fb77080
SDJ
72142016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7215
7216 * target.c (target_supports_multi_process): New function, moved
7217 from...
7218 * target.h (target_supports_multi_process): ... here. Remove
7219 macro.
7220
39b5a3b9
TT
72212016-10-05 Tom Tromey <tom@tromey.com>
7222
7223 PR remote/20655:
7224 * tracepoint.c (handle_tracepoint_bkpts): Check
7225 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7226
c1d0b70a
YQ
72272016-10-05 Yao Qi <yao.qi@linaro.org>
7228
7229 * configure.srv: Update the path of arm-*.xml files.
7230
0a69eedb
YQ
72312016-10-05 Terry Guo <terry.guo@arm.com>
7232 Yao Qi <yao.qi@linaro.org>
7233
7234 * Makefile.in: Adjust the path of rules.
7235 * configure.srv: Update the path of xml files.
7236 * regformats/arm-with-iwmmxt.dat: Regenerated.
7237 * regformats/arm-with-neon.dat: Likewise.
7238 * regformats/arm-with-vfpv2.dat: Likewise.
7239 * regformats/arm-with-vfpv3.dat Likewise.
7240
17e16485
YQ
72412016-09-30 Yao Qi <yao.qi@linaro.org>
7242
7243 PR gdbserver/20627
7244 * target.c (target_stop_and_wait): Don't call
7245 target_continue_no_signal, use resume_stop instead.
7246
edeeb602
YQ
72472016-09-26 Yao Qi <yao.qi@linaro.org>
7248
7249 * linux-low.c (linux_wait_1): Call debug_exit.
7250
503b1c39
PA
72512016-09-23 Pedro Alves <palves@redhat.com>
7252
7253 * Makefile.in (SFILES): Add common/new-op.c.
7254 (OBS): Add common/new-op.o.
7255 (new-op.o): New rule.
7256
74172ecf
SM
72572016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7258
7259 * .gitinore: Ignore more files.
7260
fc6cda2e
YQ
72612016-09-21 Yao Qi <yao.qi@linaro.org>
7262
7263 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7264 23.
7265
bc1e6c81
SDJ
72662016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7267
7268 * server.c (start_inferior): Call target_mourn_inferior instead of
7269 mourn_inferior; pass ptid_t argument to it.
7270 (resume): Likewise.
7271 (handle_target_event): Likewise.
7272 * target.c (target_mourn_inferior): New function.
7273 * target.h (mourn_inferior): Delete macro.
7274
0e00e962
AA
72752016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7276
7277 * linux-low.c (lwp_is_stepping): New function.
7278
1d8cb77d
CL
72792016-09-06 Carl Love <cel@us.ibm.com>
7280
7281 * server.c (start_inferior): Fixed comment, requested comment change
7282 didn't get updated correctly. Removed reference to ptrace () call as
7283 it is only true on Linux systems.
7284
7313bced
CL
72852016-09-06 Carl Love <cel@us.ibm.com>
7286
7287 * server.c (start_inferior): Do not call
7288 function target_post_create_inferior () if the
7289 inferior process has already exited.
7290
cf6de44d
PA
72912016-09-05 Pedro Alves <palves@redhat.com>
7292
7293 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7294 (COMPILE.pre, CC_LD): Use CXX directly.
7295 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7296 * acinclude.m4: Don't include build-with-cxx.m4.
7297 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7298 * configure: Regenerate.
7299
c1da6748
AT
73002016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7301
7302 PR gdb/19495
7303 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7304 call writing data to own_buf.
7305
f2b9e3df
SDJ
73062016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7307
7308 * target.c (mywait): Call target_wait instead of
7309 the_target->wait.
7310 (target_wait): New function.
7311
049a8570
SDJ
73122016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7313
7314 * server.c (start_inferior): New variable 'ptid'. Replace calls
7315 to the_target->resume by target_continue{,_no_signal}, depending
7316 on the case.
7317 * target.c (target_stop_and_wait): Call target_continue_no_signal
7318 instead of the_target->resume.
7319 (target_continue): New function.
7320
3aa5cfa0
AT
73212016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7322
7323 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7324
754653a7
AZ
73252016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7326
7327 PR server/20491
7328 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7329 ps_prochandle.
7330 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7331 * linux-arm-low.c (ps_get_thread_area): Likewise.
7332 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7333 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7334 * linux-mips-low.c (ps_get_thread_area): Likewise.
7335 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7336 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7337 * linux-x86-low.c (ps_get_thread_area): Likewise.
7338 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7339
ed036b40
PA
73402016-08-19 Pedro Alves <palves@redhat.com>
7341
7342 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7343
c8ef42ee
PA
73442016-08-19 Pedro Alves <palves@redhat.com>
7345
7346 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7347 comment. Use memcpy instead of casting through unsigned long.
7348
9c235a72
PA
73492016-08-19 Pedro Alves <palves@redhat.com>
7350
7351 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7352 allocating around 0x80000000.
7353
201506da
PA
73542016-08-19 Pedro Alves <palves@redhat.com>
7355
7356 PR gdb/20415
7357 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7358 (x32-avx512-linux-ipa.o): New rules.
7359 * configure.ac (x86_64-*-linux*): New x32 check.
7360 * configure.srv (ipa_x32_linux_regobj): New.
7361 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7362 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7363 descriptions.
7364 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7365 descriptions.
7366 * configure: Regenerate.
7367
f348d89a
PA
73682016-08-09 Pedro Alves <palves@redhat.com>
7369
7370 PR gdb/18653
7371 * Makefile.in (OBS): Add signals-state-save-restore.o.
7372 (signals-state-save-restore.o): New rule.
7373 * config.in: Regenerate.
7374 * configure: Regenerate.
7375 * linux-low.c: Include "signals-state-save-restore.h".
7376 (linux_create_inferior): Call
7377 restore_original_signals_state.
7378 * server.c: Include "dispositions-save-restore.h".
7379 (captured_main): Call save_original_signals_state.
7380
1baf5149
PA
73812016-08-05 Pedro Alves <palves@redhat.com>
7382
7383 * configure: Regenerate.
7384
fcd4a73d
YQ
73852016-08-04 Yao Qi <yao.qi@linaro.org>
7386
7387 * linux-low.c (regsets_fetch_inferior_registers): Check
7388 errno is ESRCH or not.
7389
979659d0
YQ
73902016-08-02 Yao Qi <yao.qi@linaro.org>
7391
7392 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7393 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7394 (thread_db_load_search): Update.
7395 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7396 td_ta_set_event and td_ta_event_getmsg.
7397
6598661d
PA
73982016-07-26 Pedro Alves <palves@redhat.com>
7399
7400 PR server/20414
7401 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7402 of unsigned long for 64-bit registers and use uint32_t instead of
7403 unsigned int for 32-bit registers.
7404
9cf12d57
PA
74052016-07-26 Pedro Alves <palves@redhat.com>
7406
7407 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7408 to 'ptrace'.
7409
305450ed
TT
74102016-07-21 Tom Tromey <tom@tromey.com>
7411
7412 * configure: Rebuild.
7413
2583da7c
YQ
74142016-07-21 Yao Qi <yao.qi@linaro.org>
7415
7416 * mem-break.c (find_gdb_breakpoint): Cast bp to
7417 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7418
21536b36
YQ
74192016-07-21 Yao Qi <yao.qi@linaro.org>
7420
7421 * server.c (handle_v_requests): Support s and S actions
7422 if target_supports_software_single_step return true.
7423
8901d193
YQ
74242016-07-21 Yao Qi <yao.qi@linaro.org>
7425
7426 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7427 is resume_step, call maybe_hw_step.
7428 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7429 and unstop them.
7430 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7431 breakpoints or not.
7432 (proceed_one_lwp): If resume request is resume_step, install
7433 reinsert breakpoints and call maybe_hw_step.
7434
0e9a339e
YQ
74352016-07-21 Yao Qi <yao.qi@linaro.org>
7436
7437 * linux-low.c (proceed_one_lwp): Declare.
7438 (linux_resume_one_thread): Remove local variable 'step'.
7439 Lift code enqueue signal. Call proceed_one_lwp instead of
7440 linux_resume_one_lwp.
7441
4281b351
YQ
74422016-07-21 Yao Qi <yao.qi@linaro.org>
7443
7444 * linux-low.c (linux_resume_one_thread): Call
7445 enqueue_pending_signal.
7446
984a2c04
YQ
74472016-07-21 Yao Qi <yao.qi@linaro.org>
7448
7449 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7450 * inferiors.c (do_restore_current_thread_cleanup): New function.
7451 (make_cleanup_restore_current_thread): Likewise.
7452 * linux-low.c (install_software_single_step_breakpoints): Call
7453 make_cleanup_restore_current_thread. Switch current_thread to
7454 thread.
7455
bec903c9
YQ
74562016-07-21 Yao Qi <yao.qi@linaro.org>
7457
7458 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7459 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7460 (clone_one_breakpoint): Likewise.
7461 (delete_reinsert_breakpoints): Change parameter to thread.
7462 Callers updated.
7463 (has_reinsert_breakpoints): Likewise.
7464 (uninsert_reinsert_breakpoints): Likewise.
7465 (reinsert_reinsert_breakpoints): Likewise.
7466 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7467 (delete_reinsert_breakpoints): Likewise.
7468 (reinsert_reinsert_breakpoints): Likewise.
7469 (uninsert_reinsert_breakpoints): Likewise.
7470 (has_reinsert_breakpoints): Likewise.
7471
63c40ec7
YQ
74722016-07-21 Yao Qi <yao.qi@linaro.org>
7473
7474 * inferiors.c (get_thread_process): Make parameter const.
7475 * inferiors.h (get_thread_process): Update declaration.
7476 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7477 Add new parameters child_thread and parent_thread. Callers
7478 updated.
7479 * mem-break.h (clone_all_breakpoints): Update declaration.
7480
9aa76cd0
YQ
74812016-07-21 Yao Qi <yao.qi@linaro.org>
7482
7483 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7484 <command_list, handler>: Remove.
7485 (struct gdb_breakpoint): New.
7486 (struct other_breakpoint): New.
7487 (struct reinsert_breakpoint): New.
7488 (is_gdb_breakpoint): New function.
7489 (any_persistent_commands): Update command_list if
7490 is_gdb_breakpoint returns true.
7491 (set_breakpoint): Create breakpoints according to their types.
7492 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7493 (set_gdb_breakpoint_1): Likewise.
7494 (set_gdb_breakpoint): Likewise.
7495 (clear_breakpoint_conditions): Change parameter type to
7496 'struct gdb_breakpoint *'.
7497 (clear_breakpoint_commands): Likewise.
7498 (clear_breakpoint_conditions_and_commands): Likewise.
7499 (add_condition_to_breakpoint): Likewise.
7500 (add_breakpoint_condition): Likewise.
7501 (add_commands_to_breakpoint): Likewise.
7502 (check_breakpoints): Check other_breakpoint.
7503 (clone_one_breakpoint): Clone breakpopint according to its type.
7504 * mem-break.h (struct gdb_breakpoint): Declare.
7505 (set_gdb_breakpoint): Update declaration.
7506 (clear_breakpoint_conditions_and_commands): Likewise.
7507 (add_breakpoint_condition): Likewise.
7508 (add_breakpoint_commands): Likewise.
7509 * server.c (process_point_options): Change parameter type to
7510 'struct gdb_breakpoint *'.
7511
811f8301
YQ
75122016-07-21 Yao Qi <yao.qi@linaro.org>
7513
7514 * mem-break.c (set_breakpoint_at): Rename it to ...
7515 (set_breakpoint_type_at): ... it.
7516 (set_breakpoint_at): Call set_breakpoint_type_at.
7517 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7518 * mem-break.h (set_breakpoint_at): Update comments.
7519
b1c51e36
CLT
75202016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7521
7522 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7523 to buf parameter.
7524 (nios2_store_gregset): Likewise.
7525
ced2dffb
PA
75262016-07-01 Pedro Alves <palves@redhat.com>
7527 Antoine Tremblay <antoine.tremblay@ericsson.com>
7528
7529 * linux-low.c: Change interface to take the target lwp_info
7530 pointer directly and return void. Handle detaching from a zombie
7531 thread.
7532 (linux_detach_lwp_callback): New function.
7533 (linux_detach): Detach from the leader thread after detaching from
7534 the clone threads.
7535
2ac09a5b
YQ
75362016-06-28 Yao Qi <yao.qi@linaro.org>
7537
7538 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7539 for variable new_offset.
7540 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7541 (aarch64_ftrace_insn_reloc_cb): Likewise.
7542 (aarch64_ftrace_insn_reloc_tb): Likewise.
7543 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7544 PRIx64 instead of PRIx32.
7545
79e7fd4f
YQ
75462016-06-28 Yao Qi <yao.qi@linaro.org>
7547
7548 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7549 (the_low_target): Install arm_get_syscall_trapinfo.
7550
061fc021
YQ
75512016-06-28 Yao Qi <yao.qi@linaro.org>
7552
7553 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7554 function.
7555 (the_low_target): Install aarch64_get_syscall_trapinfo.
7556
4cc32bec
YQ
75572016-06-28 Yao Qi <yao.qi@linaro.org>
7558
7559 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7560 Callers updated.
7561 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7562 Remove parameter sysno.
7563 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7564 sysret.
7565
782c1122
AA
75662016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7567
7568 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7569 (s390_emit_ne_goto): Likewise.
7570 (s390_emit_lt_goto): Likewise.
7571 (s390_emit_le_goto): Likewise.
7572 (s390_emit_gt_goto): Likewise.
7573 (s390_emit_ge_goto): Likewise.
7574 (s390x_emit_eq_goto): Likewise.
7575 (s390x_emit_ne_goto): Likewise.
7576 (s390x_emit_lt_goto): Likewise.
7577 (s390x_emit_le_goto): Likewise.
7578 (s390x_emit_gt_goto): Likewise.
7579 (s390x_emit_ge_goto): Likewise.
7580 (s390_emit_ops_impl): Mark variable static.
7581 (s390x_emit_ops): Likewise.
7582
2e7b624b
YQ
75832016-06-17 Yao Qi <yao.qi@linaro.org>
7584
7585 * linux-low.c (handle_extended_wait): Call
7586 uninsert_reinsert_breakpoints for the parent process. Remove
7587 reinsert breakpoints from the child process. Reinsert them to
7588 the parent process when vfork is done.
7589 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7590 (reinsert_reinsert_breakpoints): New function.
7591 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7592 (reinsert_reinsert_breakpoints): Declare.
7593
8a81c5d7
YQ
75942016-06-17 Yao Qi <yao.qi@linaro.org>
7595
7596 * linux-low.c (handle_extended_wait): If the parent is doing
7597 step-over, remove the reinsert breakpoints from the forked child.
7598
f50bf8e5
YQ
75992016-06-17 Yao Qi <yao.qi@linaro.org>
7600
7601 * linux-low.c (unsuspend_all_lwps): Declare.
7602 (linux_low_filter_event): If thread exited, call finish_step_over.
7603 If step-over is finished, unsuspend other threads.
7604
8376a3cb
YQ
76052016-06-17 Yao Qi <yao.qi@linaro.org>
7606
7607 * linux-low.c (linux_resume_one_lwp_throw): Assert
7608 has_reinsert_breakpoints returns false.
7609 * mem-break.c (delete_disabled_breakpoints): Assert
7610 bp type isn't reinsert_breakpoint.
7611
f79b145d
YQ
76122016-06-17 Yao Qi <yao.qi@linaro.org>
7613
7614 * linux-low.c (maybe_hw_step): New function.
7615 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7616 (finish_step_over): Switch current_thread to lwp temporarily,
7617 and assert has_reinsert_breakpoints returns true.
7618 (proceed_one_lwp): Call maybe_hw_step.
7619 * mem-break.c (has_reinsert_breakpoints): New function.
7620 * mem-break.h (has_reinsert_breakpoints): Declare.
7621
0ae534d2
JT
76222016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7623
7624 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7625
fcdad592
YQ
76262016-05-17 Yao Qi <yao.qi@linaro.org>
7627
7628 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7629 instead of find_inferior.
7630
9e784964
YQ
76312016-05-05 Yao Qi <yao.qi@linaro.org>
7632
7633 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7634 Initialize res to zero.
7635
cf2ebb6e
YQ
76362016-05-05 Yao Qi <yao.qi@linaro.org>
7637
7638 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7639 to uint32_t.
7640
c1aebf87
UW
76412016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7642
7643 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7644 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7645 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7646
35fd2deb 76472016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 7648 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
7649
7650 * tracepoint.c (write_inferior_int8): New function.
7651 (cmd_qtenable_disable): Write enable flag using
7652 write_inferior_int8.
7653
484b3c32
YQ
76542016-04-25 Yao Qi <yao.qi@linaro.org>
7655
7656 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7657 (need_step_over_p): Return zero if the LWP has pending signals
7658 can be delivered on software single step target.
7659
85ba7d86
YQ
76602016-04-25 Yao Qi <yao.qi@linaro.org>
7661
7662 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7663 return instead of error.
7664
3539aa13
YQ
76652016-04-22 Yao Qi <yao.qi@linaro.org>
7666
7667 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7668 to 23.
7669
5b061e98
YQ
76702016-04-22 Yao Qi <yao.qi@linaro.org>
7671
7672 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7673 signal when stepping over breakpoint with software single
7674 step.
7675
3451269c
PA
76762016-04-21 Pedro Alves <palves@redhat.com>
7677
7678 * linux-s390-low.c (s390_collect_ptrace_register)
7679 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7680 add casts.
7681 (s390_check_regset): Use void * instead of gdb_byte *.
7682
a2358508
PA
76832016-04-20 Pedro Alves <palves@redhat.com>
7684
7685 * configure: Renegerate.
7686
6885166d
YQ
76872016-04-20 Yao Qi <yao.qi@linaro.org>
7688
7689 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7690 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7691 number 16.
7692 (arm_store_gregset): Likewise.
7693
2b863f51
WT
76942016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7695
7696 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7697 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7698 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7699 (amd64-avx-mpx-linux.c): New rules.
7700 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7701 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7702 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7703 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7704 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7705 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7706 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7707 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7708 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7709 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7710 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7711 * linux-x86-low.c (x86_linux_read_description): Add case for
7712 X86_XSTATE_AVX_MPX_MASK.
7713 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7714 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7715 init_registers_i386_avx_mpx_linux.
7716 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7717 (initialize_low_tracepoint): Call
7718 init_registers_i386_avx_mpx_linux.
7719 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7720 (initialize_low_tracepoint): Call
7721 init_registers_amd64_avx_mpx_linux.
7722 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7723 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7724 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
7725 declarations.
7726
9b30624b
PA
77272016-04-18 Pedro Alves <palves@redhat.com>
7728
7729 * configure: Regenerate.
7730
45e3745e
AT
77312016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
7732
7733 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
7734 (aarch64_emit_sub): Likewise.
7735
2afc13ff
PA
77362016-04-12 Pedro Alves <palves@redhat.com>
7737
7738 * utils.c (prepare_to_throw_exception): Delete.
7739
6e774b13
SM
77402016-04-05 Simon Marchi <simon.marchi@ericsson.com>
7741
7742 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
7743
4dca19f8
MK
77442016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
7745
7746 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
7747
d0a9981f
MK
77482016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
7749
7750 * linux-aarch64-ipa.c: Add <elf.h> include.
7751 * linux-ppc-ipa.c: Add <elf.h> include.
7752 * linux-s390-ipa.c: Add <elf.h> include.
7753
252db07e
MK
77542016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7755
7756 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
7757 (get_raw_reg_ptr): Likewise.
7758 (get_trace_state_variable_value_ptr): Likewise.
7759 (set_trace_state_variable_value_ptr): Likewise.
7760 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
7761 char *.
7762
14e2b6d9
MK
77632016-03-31 Wei-cheng Wang <cole945@gmail.com>
7764 Marcin Kościelnicki <koriakin@0x04.net>
7765
7766 PR/17221
7767 * linux-ppc-low.c (emit_insns): New function.
7768 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
7769 (ppc_emit_prologue): New function.
7770 (ppc_emit_epilogue): New function.
7771 (ppc_emit_add): New function.
7772 (ppc_emit_sub): New function.
7773 (ppc_emit_mul): New function.
7774 (ppc_emit_lsh): New function.
7775 (ppc_emit_rsh_signed): New function.
7776 (ppc_emit_rsh_unsigned): New function.
7777 (ppc_emit_ext): New function.
7778 (ppc_emit_zero_ext): New function.
7779 (ppc_emit_log_not): New function.
7780 (ppc_emit_bit_and): New function.
7781 (ppc_emit_bit_or): New function.
7782 (ppc_emit_bit_xor): New function.
7783 (ppc_emit_bit_not): New function.
7784 (ppc_emit_equal): New function.
7785 (ppc_emit_less_signed): New function.
7786 (ppc_emit_less_unsigned): New function.
7787 (ppc_emit_ref): New function.
7788 (ppc_emit_const): New function.
7789 (ppc_emit_reg): New function.
7790 (ppc_emit_pop): New function.
7791 (ppc_emit_stack_flush): New function.
7792 (ppc_emit_swap): New function.
7793 (ppc_emit_stack_adjust): New function.
7794 (ppc_emit_call): New function.
7795 (ppc_emit_int_call_1): New function.
7796 (ppc_emit_void_call_2): New function.
7797 (ppc_emit_if_goto): New function.
7798 (ppc_emit_goto): New function.
7799 (ppc_emit_eq_goto): New function.
7800 (ppc_emit_ne_goto): New function.
7801 (ppc_emit_lt_goto): New function.
7802 (ppc_emit_le_goto): New function.
7803 (ppc_emit_gt_goto): New function.
7804 (ppc_emit_ge_goto): New function.
7805 (ppc_write_goto_address): New function.
7806 (ppc_emit_ops_impl): New static variable.
7807 (ppc64v1_emit_prologue): New function.
7808 (ppc64v2_emit_prologue): New function.
7809 (ppc64_emit_epilogue): New function.
7810 (ppc64_emit_add): New function.
7811 (ppc64_emit_sub): New function.
7812 (ppc64_emit_mul): New function.
7813 (ppc64_emit_lsh): New function.
7814 (ppc64_emit_rsh_signed): New function.
7815 (ppc64_emit_rsh_unsigned): New function.
7816 (ppc64_emit_ext): New function.
7817 (ppc64_emit_zero_ext): New function.
7818 (ppc64_emit_log_not): New function.
7819 (ppc64_emit_bit_and): New function.
7820 (ppc64_emit_bit_or): New function.
7821 (ppc64_emit_bit_xor): New function.
7822 (ppc64_emit_bit_not): New function.
7823 (ppc64_emit_equal): New function.
7824 (ppc64_emit_less_signed): New function.
7825 (ppc64_emit_less_unsigned): New function.
7826 (ppc64_emit_ref): New function.
7827 (ppc64_emit_const): New function.
7828 (ppc64v1_emit_reg): New function.
7829 (ppc64v2_emit_reg): New function.
7830 (ppc64_emit_pop): New function.
7831 (ppc64_emit_stack_flush): New function.
7832 (ppc64_emit_swap): New function.
7833 (ppc64v1_emit_call): New function.
7834 (ppc64v2_emit_call): New function.
7835 (ppc64v1_emit_int_call_1): New function.
7836 (ppc64v2_emit_int_call_1): New function.
7837 (ppc64v1_emit_void_call_2): New function.
7838 (ppc64v2_emit_void_call_2): New function.
7839 (ppc64_emit_if_goto): New function.
7840 (ppc64_emit_eq_goto): New function.
7841 (ppc64_emit_ne_goto): New function.
7842 (ppc64_emit_lt_goto): New function.
7843 (ppc64_emit_le_goto): New function.
7844 (ppc64_emit_gt_goto): New function.
7845 (ppc64_emit_ge_goto): New function.
7846 (ppc64v1_emit_ops_impl): New static variable.
7847 (ppc64v2_emit_ops_impl): New static variable.
7848 (ppc_emit_ops): New function.
7849 (linux_low_target): Wire in ppc_emit_ops.
7850
a2174ba4
MK
78512016-03-31 Wei-cheng Wang <cole945@gmail.com>
7852 Marcin Kościelnicki <koriakin@0x04.net>
7853
7854 PR/17221
7855 * Makefile.in: Add powerpc-*-ipa.o
7856 * configure.srv: Add ipa_obj for powerpc*-linux.
7857 * linux-ppc-ipa.c: New file.
7858 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
7859 includes.
7860 (PPC_FIELD): New macro.
7861 (PPC_SEXT): New macro.
7862 (PPC_OP6): New macro.
7863 (PPC_BO): New macro.
7864 (PPC_LI): New macro.
7865 (PPC_BD): New macro.
7866 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
7867 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
7868 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
7869 (ppc_get_thread_area): New function.
7870 (is_elfv2_inferior): New function.
7871 (gen_ds_form): New function.
7872 (GEN_STD): New macro.
7873 (GEN_STDU): New macro.
7874 (GEN_LD): New macro.
7875 (GEN_LDU): New macro.
7876 (gen_d_form): New function.
7877 (GEN_ADDI): New macro.
7878 (GEN_ADDIS): New macro.
7879 (GEN_LI): New macro.
7880 (GEN_LIS): New macro.
7881 (GEN_ORI): New macro.
7882 (GEN_ORIS): New macro.
7883 (GEN_LWZ): New macro.
7884 (GEN_STW): New macro.
7885 (GEN_STWU): New macro.
7886 (gen_xfx_form): New function.
7887 (GEN_MFSPR): New macro.
7888 (GEN_MTSPR): New macro.
7889 (GEN_MFCR): New macro.
7890 (GEN_MTCR): New macro.
7891 (GEN_SYNC): New macro.
7892 (GEN_LWSYNC): New macro.
7893 (gen_x_form): New function.
7894 (GEN_OR): New macro.
7895 (GEN_MR): New macro.
7896 (GEN_LWARX): New macro.
7897 (GEN_STWCX): New macro.
7898 (GEN_CMPW): New macro.
7899 (gen_md_form): New function.
7900 (GEN_RLDICL): New macro.
7901 (GEN_RLDICR): New macro.
7902 (gen_i_form): New function.
7903 (GEN_B): New macro.
7904 (GEN_BL): New macro.
7905 (gen_b_form): New function.
7906 (GEN_BNE): New macro.
7907 (GEN_LOAD): New macro.
7908 (GEN_STORE): New macro.
7909 (gen_limm): New function.
7910 (gen_atomic_xchg): New function.
7911 (gen_call): New function.
7912 (ppc_relocate_instruction): New function.
7913 (ppc_install_fast_tracepoint_jump_pad): New function.
7914 (ppc_get_min_fast_tracepoint_insn_len): New function.
7915 (ppc_get_ipa_tdesc_idx): New function.
7916 (the_low_target): Wire in the new functions.
7917 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
7918 tdescs.
7919 * linux-ppc-tdesc.h: New file.
7920
a13c4696
MK
79212016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7922
7923 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
7924 (alloc_jump_pad_buffer): New function.
7925 * linux-amd64-ipa.c: Add <sys/mman.h> include.
7926 (alloc_jump_pad_buffer): New function.
7927 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
7928 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
7929 (alloc_jump_pad_buffer): New function.
7930 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
7931 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
7932 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
7933 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
7934
1cda1512
MK
79352016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
7936
7937 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
7938 * linux-amd64-ipa.c: Likewise.
7939 * linux-i386-ipa.c: Likewise.
7940 * linux-s390-ipa.c: Likewise.
7941 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
7942 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
7943 set_trace_state_variable_value_ptr.
7944 (struct ipa_sym_addresses): Likewise.
7945 (symbol_list): Likewise.
7946 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
7947 accessing gdb_collect directly.
7948 (gdb_collect_ptr_type): New typedef.
7949 (get_raw_reg_ptr_type): New typedef.
7950 (get_trace_state_variable_value_ptr_type): New typedef.
7951 (set_trace_state_variable_value_ptr_type): New typedef.
7952 (gdb_collect_ptr): New global.
7953 (get_raw_reg_ptr): New global.
7954 (get_trace_state_variable_value_ptr): New global.
7955 (set_trace_state_variable_value_ptr): New global.
7956 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
7957 accessing get_raw_reg directly.
7958 (get_get_tsv_func_addr): Likewise for
7959 get_trace_state_variable_value_ptr.
7960 (get_set_tsv_func_addr): Likewise for
7961 set_trace_state_variable_value_ptr.
7962 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
7963
72fb5488
SM
79642016-03-30 Simon Marchi <simon.marchi@ericsson.com>
7965
7966 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
7967
28170b88
MK
79682016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
7969
7970 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
7971 packets.
7972 (relocate_instruction): Remove own_buf.
7973 * server.c (own_buf): Make global.
7974 (handle_v_requests): Make global.
7975 * server.h (own_buf): New declaration.
7976 (handle_v_requests): New prototype.
7977
f39e8743
MK
79782016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
7979
7980 PR 18377
7981 * linux-s390-low.c (add_insns): New function.
7982 (s390_emit_prologue): New function.
7983 (s390_emit_epilogue): New function.
7984 (s390_emit_add): New function.
7985 (s390_emit_sub): New function.
7986 (s390_emit_mul): New function.
7987 (s390_emit_lsh): New function.
7988 (s390_emit_rsh_signed): New function.
7989 (s390_emit_rsh_unsigned): New function.
7990 (s390_emit_ext): New function.
7991 (s390_emit_log_not): New function.
7992 (s390_emit_bit_and): New function.
7993 (s390_emit_bit_or): New function.
7994 (s390_emit_bit_xor): New function.
7995 (s390_emit_bit_not): New function.
7996 (s390_emit_equal): New function.
7997 (s390_emit_less_signed): New function.
7998 (s390_emit_less_unsigned): New function.
7999 (s390_emit_ref): New function.
8000 (s390_emit_if_goto): New function.
8001 (s390_emit_goto): New function.
8002 (s390_write_goto_address): New function.
8003 (s390_emit_litpool): New function.
8004 (s390_emit_const): New function.
8005 (s390_emit_call): New function.
8006 (s390_emit_reg): New function.
8007 (s390_emit_pop): New function.
8008 (s390_emit_stack_flush): New function.
8009 (s390_emit_zero_ext): New function.
8010 (s390_emit_swap): New function.
8011 (s390_emit_stack_adjust): New function.
8012 (s390_emit_set_r2): New function.
8013 (s390_emit_int_call_1): New function.
8014 (s390_emit_void_call_2): New function.
8015 (s390_emit_eq_goto): New function.
8016 (s390_emit_ne_goto): New function.
8017 (s390_emit_lt_goto): New function.
8018 (s390_emit_le_goto): New function.
8019 (s390_emit_gt_goto): New function.
8020 (s390_emit_ge_goto): New function.
8021 (s390x_emit_prologue): New function.
8022 (s390x_emit_epilogue): New function.
8023 (s390x_emit_add): New function.
8024 (s390x_emit_sub): New function.
8025 (s390x_emit_mul): New function.
8026 (s390x_emit_lsh): New function.
8027 (s390x_emit_rsh_signed): New function.
8028 (s390x_emit_rsh_unsigned): New function.
8029 (s390x_emit_ext): New function.
8030 (s390x_emit_log_not): New function.
8031 (s390x_emit_bit_and): New function.
8032 (s390x_emit_bit_or): New function.
8033 (s390x_emit_bit_xor): New function.
8034 (s390x_emit_bit_not): New function.
8035 (s390x_emit_equal): New function.
8036 (s390x_emit_less_signed): New function.
8037 (s390x_emit_less_unsigned): New function.
8038 (s390x_emit_ref): New function.
8039 (s390x_emit_if_goto): New function.
8040 (s390x_emit_const): New function.
8041 (s390x_emit_call): New function.
8042 (s390x_emit_reg): New function.
8043 (s390x_emit_pop): New function.
8044 (s390x_emit_stack_flush): New function.
8045 (s390x_emit_zero_ext): New function.
8046 (s390x_emit_swap): New function.
8047 (s390x_emit_stack_adjust): New function.
8048 (s390x_emit_int_call_1): New function.
8049 (s390x_emit_void_call_2): New function.
8050 (s390x_emit_eq_goto): New function.
8051 (s390x_emit_ne_goto): New function.
8052 (s390x_emit_lt_goto): New function.
8053 (s390x_emit_le_goto): New function.
8054 (s390x_emit_gt_goto): New function.
8055 (s390x_emit_ge_goto): New function.
8056 (s390_emit_ops): New function.
8057 (struct linux_target_ops): Fill in emit_ops hook.
8058
abd9baf9
MK
80592016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8060
8061 PR 18377
8062 * Makefile.in: Add s390 IPA files.
8063 * configure.srv: Build IPA for s390.
8064 * linux-s390-ipa.c: New file.
8065 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8066 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8067 (tdesc_s390_linux32): Likewise.
8068 (init_registers_s390_linux32v1): Likewise.
8069 (tdesc_s390_linux32v1): Likewise.
8070 (init_registers_s390_linux32v2): Likewise.
8071 (tdesc_s390_linux32v2): Likewise.
8072 (init_registers_s390_linux64): Likewise.
8073 (tdesc_s390_linux64): Likewise.
8074 (init_registers_s390_linux64v1): Likewise.
8075 (tdesc_s390_linux64v1): Likewise.
8076 (init_registers_s390_linux64v2): Likewise.
8077 (tdesc_s390_linux64v2): Likewise.
8078 (init_registers_s390_te_linux64): Likewise.
8079 (tdesc_s390_te_linux64): Likewise.
8080 (init_registers_s390_vx_linux64): Likewise.
8081 (tdesc_s390_vx_linux64): Likewise.
8082 (init_registers_s390_tevx_linux64): Likewise.
8083 (tdesc_s390_tevx_linux64): Likewise.
8084 (init_registers_s390x_linux64): Likewise.
8085 (tdesc_s390x_linux64): Likewise.
8086 (init_registers_s390x_linux64v1): Likewise.
8087 (tdesc_s390x_linux64v1): Likewise.
8088 (init_registers_s390x_linux64v2): Likewise.
8089 (tdesc_s390x_linux64v2): Likewise.
8090 (init_registers_s390x_te_linux64): Likewise.
8091 (tdesc_s390x_te_linux64): Likewise.
8092 (init_registers_s390x_vx_linux64): Likewise.
8093 (tdesc_s390x_vx_linux64): Likewise.
8094 (init_registers_s390x_tevx_linux64): Likewise.
8095 (tdesc_s390x_tevx_linux64): Likewise.
8096 (have_hwcap_s390_vx): New static variable.
8097 (s390_arch_setup): Fill have_hwcap_s390_vx.
8098 (s390_get_thread_area): New function.
8099 (s390_ft_entry_gpr_esa): New const.
8100 (s390_ft_entry_gpr_zarch): New const.
8101 (s390_ft_entry_misc): New const.
8102 (s390_ft_entry_fr): New const.
8103 (s390_ft_entry_vr): New const.
8104 (s390_ft_main_31): New const.
8105 (s390_ft_main_64): New const.
8106 (s390_ft_exit_fr): New const.
8107 (s390_ft_exit_vr): New const.
8108 (s390_ft_exit_misc): New const.
8109 (s390_ft_exit_gpr_esa): New const.
8110 (s390_ft_exit_gpr_zarch): New const.
8111 (append_insns): New function.
8112 (s390_relocate_instruction): New function.
8113 (s390_install_fast_tracepoint_jump_pad): New function.
8114 (s390_get_min_fast_tracepoint_insn_len): New function.
8115 (s390_get_ipa_tdesc_idx): New function.
8116 (struct linux_target_ops): Wire in the above functions.
8117 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8118 * linux-s390-tdesc.h: New file.
8119
a4105d04
MK
81202016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8121
8122 * linux-s390-low.c (s390_supports_tracepoints): New function.
8123 (struct linux_target_ops): Fill supports_tracepoints hook.
8124
35ac8b3e
YQ
81252016-03-18 Yao Qi <yao.qi@linaro.org>
8126
8127 * linux-low.c (lwp_signal_can_be_delivered): New function.
8128 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8129
94610ec4
YQ
81302016-03-18 Yao Qi <yao.qi@linaro.org>
8131
8132 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8133 0 if signal is enqueued. Remove 'signal' from one debugging
8134 message. Move one debugging message to some lines below.
8135 Remove code setting 'signal' to 0.
8136
80aea927
YQ
81372016-03-18 Yao Qi <yao.qi@linaro.org>
8138
8139 * linux-low.c (linux_low_filter_event): Remove redundant
8140 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8141
b04fd3be
MK
81422016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8143
8144 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8145 (struct linux_target_ops): Wire in the above.
8146
c40c8d4b
YQ
81472016-03-03 Yao Qi <yao.qi@linaro.org>
8148
8149 * linux-low.c: Update comments to start_step_over.
8150
0f8288ae
YQ
81512016-03-03 Yao Qi <yao.qi@linaro.org>
8152
8153 PR server/19736
8154 * linux-low.c (handle_extended_wait): Set child suspended
8155 if event_lwp->bp_reinsert isn't zero.
8156
fdbd04a8
YQ
81572016-03-02 Yao Qi <yao.qi@linaro.org>
8158
8159 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8160 enqueue_pending_signal.
8161
6896a8fa
MK
81622016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8163
8164 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8165 is actually loaded.
8166
ab503087
MK
81672016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8168
8169 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8170 (s390_regmap_3264) [!__s390x__]: New global.
8171 (s390_collect_ptrace_register): Skip map entries containing -1.
8172 (s390_supply_ptrace_register): Ditto.
8173 (s390_fill_gprs_high): New function.
8174 (s390_store_gprs_high): New function.
8175 (s390_regsets): Add NT_S390_HIGH_GPRS.
8176 (s390_get_hwcap): Enable on 31-bit.
8177 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8178 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8179 Detect NT_S390_HIGH_GPRS.
8180 (s390_usrregs_info_3264): Enable on 31-bit.
8181 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8182 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8183
ae91f625
MK
81842016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8185
8186 PR gdb/13808
8187 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8188 * configure.srv: Ditto.
8189 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8190 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8191 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8192 (init_registers_amd64_linux): Remove prototype.
8193 (tdesc_amd64_linux): Remove declaration.
8194 (get_ipa_tdesc): New function.
8195 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8196 initialize remaining tdescs.
8197 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8198 (init_registers_i386_linux): Remove prototype.
8199 (tdesc_i386_linux): Remove declaration.
8200 (get_ipa_tdesc): New function.
8201 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8202 initialize remaining tdescs.
8203 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8204 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8205 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8206 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8207 (x86_get_ipa_tdesc_idx): New function.
8208 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8209 * linux-x86-tdesc.h: New file.
8210 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8211 (target_get_ipa_tdesc_idx): New macro.
8212 * tracepoint.c (ipa_tdesc_idx): New macro.
8213 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8214 (symbol_list): Add ipa_tdesc_idx.
8215 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8216 (ipa_tdesc): Remove.
8217 (ipa_tdesc_idx): New variable.
8218 (get_context_regcache): Use get_ipa_tdesc.
8219 (gdb_collect): Ditto.
8220 (gdb_probe): Ditto.
8221 * tracepoint.h (get_ipa_tdesc): New prototype.
8222 (ipa_tdesc): Remove.
8223
e7ad2f14
PA
82242016-02-24 Pedro Alves <palves@redhat.com>
8225
8226 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8227 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8228 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8229 Factor out common code between the USE_SIGTRAP_SIGINFO and
8230 !USE_SIGTRAP_SIGINFO blocks.
8231 (linux_low_filter_event): Call save_stop_reason instead of
8232 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8233 Update comments.
8234 (linux_wait_1): Update comments.
8235
657f9cde
WW
82362016-02-24 Wei-cheng Wang <cole945@gmail.com>
8237
8238 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8239 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8240 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8241 ppc_insert_point, ppc_remove_point.
8242
b00b61e1
MK
82432016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8244
8245 * linux-s390-low.c (s390_supports_z_point_type): New function.
8246 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8247
553cb527
YQ
82482016-02-16 Yao Qi <yao.qi@linaro.org>
8249
8250 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8251 PC. Get pc from regcache_read_pc.
8252
a5652c21
YQ
82532016-02-12 Yao Qi <yao.qi@linaro.org>
8254
8255 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8256 or linux_get_pc_32bit.
8257 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8258
ed443b61
YQ
82592016-02-12 Yao Qi <yao.qi@linaro.org>
8260
8261 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8262 arm_linux_get_next_pcs_fixup.
8263
020ecd38
MK
82642016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8265
8266 * tracepoint.c (x_tracepoint_action_download): Change
8267 write_inferior_data_ptr to write_inferior_data_pointer.
8268 (cmd_qtstart): Likewise.
8269 (write_inferior_data_ptr): Remove.
8270 (download_agent_expr): Change write_inferior_data_ptr to
8271 write_inferior_data_pointer.
8272 (download_tracepoint_1): Likewise.
8273 (download_tracepoint): Likewise.
8274 (download_trace_state_variables): Likewise.
8275
7cae9051
WW
82762016-02-11 Wei-cheng Wang <cole945@gmail.com>
8277 Marcin Kościelnicki <koriakin@0x04.net>
8278
8279 * tracepoint.c (struct tracepoint_action_ops): Remove.
8280 (struct tracepoint_action): Remove ops.
8281 (m_tracepoint_action_download, r_tracepoint_action_download)
8282 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8283 size and offset accordingly.
8284 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8285 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8286 (tracepoint_action_send, tracepoint_action_download): New functions.
8287 Helpers for trace action handlers.
8288 (add_tracepoint_action): Remove setup actions ops.
8289 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8290
9f6a71b4
YQ
82912016-02-10 Yao Qi <yao.qi@linaro.org>
8292
8293 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8294
1e94266c
SM
82952016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8296
8297 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8298 to AC_OUTPUT.
8299 * configure: Regenerate.
8300
8adce034
SM
83012016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8302
8303 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8304 void * to gdb_byte *.
8305 * linux-low.c (siginfo_fixup): Likewise.
8306 (linux_xfer_siginfo): Likewise.
8307 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8308 Likewise.
8309 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8310
93813b37
WT
83112016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8312
8313 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8314 to srv_tgtobj.
8315 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8316 to srv_tgtobj.
8317 * linux-x86-low.c [__x86_64__]: Include
8318 "nat/amd64-linux-siginfo.h".
8319 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8320 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8321 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8322 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8323 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8324 (cpt_si_fd, si_timerid, si_overrun): Move from
8325 nat/amd64-linux-siginfo.c.
8326 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8327
8424cc97
SM
83282016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8329
8330 * server.c (skip_to_semicolon): Remove.
8331 (process_point_options): Use strchrnul instead of
8332 skip_to_semicolon.
8333
4d18591b
YQ
83342016-01-26 Yao Qi <yao.qi@linaro.org>
8335
8336 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8337 * linux-low.c (install_software_single_step_breakpoints): Don't
8338 call regcache_read_pc.
8339 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8340 argument pc.
8341
d8020970
YQ
83422016-01-26 Yao Qi <yao.qi@linaro.org>
8343
8344 * linux-low.c (install_software_single_step_breakpoints): Call
8345 regcache_read_pc instead of get_pc.
8346
8b207339
YQ
83472016-01-26 Yao Qi <yao.qi@linaro.org>
8348
8349 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8350 (unblock_async_io): Rename to ...
8351 (block_unblock_async_io): ... it. New function.
8352 (enable_async_io): Don't install SIGIO handler. Unblock it
8353 instead.
8354 (disable_async_io): Don't ignore SIGIO. Block it instead.
8355 (initialize_async_io): Install SIGIO handler. Don't call
8356 unblock_async_io.
8357
18879fef
YQ
83582016-01-26 Yao Qi <yao.qi@linaro.org>
8359
8360 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8361 first character is '\003', call *the_target->request_interrupt.
8362
a0f8e08a
YQ
83632016-01-25 Yao Qi <yao.qi@linaro.org>
8364
8365 * remote-utils.c (new_thread_notify): Remove.
8366 (dead_thread_notify): Likewise.
8367 * remote-utils.h (new_thread_notify): Remove declaration.
8368 (dead_thread_notify): Likewise.
8369
cc5fd9ab
MK
83702016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8371
8372 * gdb.trace/pending.exp: Fix expected message on continue.
8373
99e8eb11
MK
83742016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8375
8376 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8377 it works properly on big-endian machines where sizeof (CORE_ADDR)
8378 != sizeof (void *).
8379
a994041d
PA
83802016-01-21 Pedro Alves <palves@redhat.com>
8381
8382 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8383 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8384 * configure: Regenerate.
8385
f7a6a40d
YQ
83862016-01-21 Yao Qi <yao.qi@linaro.org>
8387
8388 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8389 is_thumb and set it according to CPSR saved on the stack.
8390 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8391 arm_sigreturn_next_pc.
8392
6f69e520
YQ
83932016-01-18 Yao Qi <yao.qi@linaro.org>
8394
8395 * linux-low.c (linux_set_pc_64bit): New function.
8396 (linux_get_pc_64bit): New function.
8397 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8398 Declare.
8399 * linux-sparc-low.c (debug_threads): Remove declaration.
8400 (sparc_get_pc): Remove.
8401 (the_low_target): Use linux_get_pc_64bit instead of
8402 sparc_get_pc.
8403 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8404 (the_low_target): Use linux_get_pc_64bit and
8405 linux_set_pc_64bit.
8406
276d4552
YQ
84072016-01-18 Yao Qi <yao.qi@linaro.org>
8408
8409 * linux-arm-low.c (debug_threads): Remove declaration.
8410 (arm_get_pc, arm_set_pc): Remove.
8411 (the_low_target): Use linux_get_pc_32bit and
8412 linux_set_pc_32bit.
8413 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8414 (the_low_target): Use linux_get_pc_32bit and
8415 linux_set_pc_32bit.
8416 * linux-cris-low.c (debug_threads): Remove declaration.
8417 (cris_get_pc, cris_set_pc,): Remove.
8418 (the_low_target): Use linux_get_pc_32bit and
8419 linux_set_pc_32bit.
8420 * linux-crisv32-low.c (debug_threads): Remove declaration.
8421 (cris_get_pc, cris_set_pc): Remove.
8422 (the_low_target): Use linux_get_pc_32bit and
8423 linux_set_pc_32bit.
8424 * linux-low.c: Include inttypes.h.
8425 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8426 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8427 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8428 (the_low_target): Use linux_get_pc_32bit and
8429 linux_set_pc_32bit.
8430 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8431 (the_low_target): Use linux_get_pc_32bit and
8432 linux_set_pc_32bit.
8433 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8434 (the_low_target): Use linux_get_pc_32bit and
8435 linux_set_pc_32bit.
8436 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8437 (the_low_target): Use linux_get_pc_32bit and
8438 linux_set_pc_32bit.
8439 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8440 (the_low_target): Use linux_get_pc_32bit and
8441 linux_set_pc_32bit.
8442
eb0edac8
GB
84432016-01-18 Gary Benson <gbenson@redhat.com>
8444
8445 * configure.ac (AC_FUNC_FORK): New check.
8446 * config.in: Regenerate.
8447 * configure: Likewise.
8448
1b451dda
YQ
84492016-01-14 Yao Qi <yao.qi@linaro.org>
8450
8451 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8452 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8453 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8454 arm_get_next_pcs_ctor.
8455
82075af2
JS
84562016-01-12 Josh Stone <jistone@redhat.com>
8457 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8458
8459 * inferiors.h: Include "gdb_vecs.h".
8460 (struct process_info): Add syscalls_to_catch.
8461 * inferiors.c (remove_process): Free syscalls_to_catch.
8462 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8463 syscall_return stops.
8464 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8465 * server.c (handle_general_set): Handle QCatchSyscalls.
8466 (handle_query): Report support for QCatchSyscalls.
8467 * target.h (struct target_ops): Add supports_catch_syscall.
8468 (target_supports_catch_syscall): New macro.
8469 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8470 (struct lwp_info): Add syscall_state.
8471 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8472 Maintain syscall_state and syscalls_to_catch across exec.
8473 (get_syscall_trapinfo): New function, proxy to the_low_target.
8474 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8475 (linux_low_filter_event): Toggle syscall_state entry/return for
8476 syscall traps, and set it ignored for all others.
8477 (gdb_catching_syscalls_p): New function.
8478 (gdb_catch_this_syscall_p): New function.
8479 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8480 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8481 (linux_supports_catch_syscall): New function.
8482 (linux_target_ops): Install it.
8483 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8484 (the_low_target): Install it.
8485
8f13a3ce
MF
84862016-01-12 Mike Frysinger <vapier@gentoo.org>
8487
8488 * acinclude.m4: Include new ../warning.m4 file.
8489 * configure: Regenerated.
8490 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8491
5b3da067
MF
84922016-01-12 Mike Frysinger <vapier@gentoo.org>
8493
8494 * ax.c (is_goto_target): Mark static.
8495 * linux-low.c (register_addr): Likewise.
8496 (linux_fetch_registers, linux_store_registers): Likewise.
8497 * mem-break.c (any_persistent_commands): Fix old prototype.
8498 (add_commands_to_breakpoint): Mark static.
8499 * regcache.c (find_register_by_name): Delete unused func.
8500 * remote-utils.c (hex_or_minus_one): Mark static.
8501 * server.c (monitor_show_help): Mark static.
8502 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8503 handle_v_requests): Likewise.
8504
bc504a31
PA
85052016-01-12 Pedro Alves <palves@redhat.com>
8506
8507 Remove use of the registered trademark symbol throughout.
8508
5a0dd67a
YQ
85092016-01-08 Yao Qi <yao.qi@linaro.org>
8510
8511 * remote-utils.c (getpkt): If c is '\003', call target hook
8512 request_interrupt.
8513
b2ca446f
YQ
85142016-01-06 Yao Qi <yao.qi@linaro.org>
8515
8516 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8517 linux-aarch32-low.c.
8518 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8519 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8520 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8521 (thumb2_breakpoint): Declare.
8522 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8523 linux-aarch32-low.h.
8524 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8525 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8526 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8527
edd88788
JB
85282016-01-01 Joel Brobecker <brobecker@adacore.com>
8529
8530 * gdbreplay.c (gdbreplay_version): Change copyright year in
8531 version message.
8532 * server.c (gdbserver_version): Likewise.
8533
65da7f14
PP
85342015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8535
8536 * server.c (crc32_table): Delete.
8537 (crc32): Use libiberty's xcrc32 function.
8538
4abd5ed2
JB
85392015-12-22 Joel Brobecker <brobecker@adacore.com>
8540
8541 * lynx-low.c (lynx_delete_thread_callback): New function.
8542 (lynx_mourn): Properly delete our process and all of its
8543 threads. Remove call to clear_inferiors.
8544
0e50fe5c
JB
85452015-12-22 Joel Brobecker <brobecker@adacore.com>
8546
8547 * target.c (thread_search_callback): Add check that
8548 the thread_stopped target callback is not NULL before
8549 calling it.
8550
35adc03f
YQ
85512015-12-21 Yao Qi <yao.qi@linaro.org>
8552
8553 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8554 arm breakpoint.
8555
bd2b2909
AT
85562015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8557
8558 * server.c (handle_query): Call target_supports_software_single_step.
8559
7fe5e27e
AT
85602015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8561
8562 * linux-low.c (single_step): New function.
8563 (linux_resume_one_lwp_throw): Call single_step.
8564 (start_step_over): Likewise.
8565
d9311bfa
AT
85662015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8567
8568 * Makefile.in (SFILES): Append arch/arm-linux.c,
8569 arch/arm-get-next-pcs.c.
8570 (arm-linux.o): New rule.
8571 (arm-get-next-pcs.o): New rule.
8572 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8573 arm-linux.o.
8574 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8575 to linux-aarch32-low.c.
8576 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8577 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8578 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8579 (thumb2_breakpoint_len): Likewise.
8580 (arm_is_thumb_mode): Make non-static.
8581 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8582 from linux-aarch32-low.c.
8583 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8584 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8585 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8586 (thumb2_breakpoint_len): Likewise.
8587 (arm_is_thumb_mode): New declaration.
8588 * linux-arm-low.c: Include arch/arm-linux.h
8589 aarch/arm-get-next-pcs.h, sys/syscall.h.
8590 (get_next_pcs_ops): New struct.
8591 (get_next_pcs_addr_bits_remove): New function.
8592 (get_next_pcs_is_thumb): New function.
8593 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8594 (arm_sigreturn_next_pc): Likewise.
8595 (get_next_pcs_syscall_next_pc): Likewise.
8596 (arm_gdbserver_get_next_pcs): Likewise.
8597 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8598 Initialize.
8599 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8600 * server.h: Include gdb_vecs.h.
8601
68ce2059
AT
86022015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8603
8604 * Makefile.in (SFILES): Append common/common-regcache.c.
8605 (OBS): Append common-regcache.o.
8606 (common-regcache.o): New rule.
8607 * regcache.c (init_register_cache): Initialize cache to
8608 REG_UNAVAILABLE.
8609 (regcache_raw_read_unsigned): New function.
8610 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8611 register_status enum.
8612
fa5308bd
AT
86132015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8614
8615 * linux-aarch64-low.c (the_low_targets): Rename
8616 breakpoint_reinsert_addr to get_next_pcs.
8617 * linux-arm-low.c (the_low_targets): Likewise.
8618 * linux-bfin-low.c (the_low_targets): Likewise.
8619 * linux-cris-low.c (the_low_targets): Likewise.
8620 * linux-crisv32-low.c (the_low_targets): Likewise.
8621 * linux-low.c (can_software_single_step): Likewise.
8622 (install_software_single_step_breakpoints): New function.
8623 (start_step_over): Use install_software_single_step_breakpoints.
8624 * linux-low.h: New CORE_ADDR vector.
8625 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8626 get_next_pcs.
8627 * linux-mips-low.c (the_low_targets): Likewise.
8628 * linux-nios2-low.c (the_low_targets): Likewise.
8629 * linux-sparc-low.c (the_low_targets): Likewise.
8630
4a6ed09b
PA
86312015-12-17 Pedro Alves <palves@redhat.com>
8632
8633 * linux-low.c (linux_kill_one_lwp): Remove references to
8634 LinuxThreads.
8635 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8636 to 'kill'.
8637 (linux_init_signals): Delete.
8638 (initialize_low): Adjust.
8639 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8640
7544db95
PA
86412015-12-16 Pedro Alves <palves@redhat.com>
8642
8643 * configure.ac (compiler warning flags): When testing a
8644 -Wno-foo option, check whether -Wfoo works instead.
8645 * configure: Regenerate.
8646
8020350c
DB
86472015-12-11 Don Breazeal <donb@codesourcery.com>
8648
8649 * server.c (process_serial_event): Don't exit from gdbserver
8650 in remote mode if there are still active inferiors.
8651
db91f502
YQ
86522015-12-11 Yao Qi <yao.qi@linaro.org>
8653
8654 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8655 arm_breakpoint_at if the process is 32-bit.
8656
b37a6290
YQ
86572015-12-11 Yao Qi <yao.qi@linaro.org>
8658
8659 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8660 arm breakpoint.
8661
17b1509a
YQ
86622015-12-07 Yao Qi <yao.qi@linaro.org>
8663
8664 * configure.srv: Append arm.o to srv_tgtobj for
8665 aarch64*-*-linux* target.
8666 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8667 from linux-arm-low.c.
8668 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8669 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8670 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8671 (thumb2_breakpoint_len): Likewise.
8672 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8673 (arm_breakpoint_kinds): Likewise.
8674 (arm_breakpoint_kind_from_pc): Likewise.
8675 (arm_sw_breakpoint_from_kind): Likewise.
8676 (arm_breakpoint_kind_from_current_state): Likewise.
8677 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8678 (arm_sw_breakpoint_from_kind): Declare.
8679 (arm_breakpoint_kind_from_current_state): Declare.
8680 (arm_breakpoint_at): Declare.
8681 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8682 arm_sw_breakpoint_from_kind if process is 32-bit.
8683 (aarch64_breakpoint_kind_from_pc): New function.
8684 (aarch64_breakpoint_kind_from_current_state): New function.
8685 (the_low_target): Initialize fields breakpoint_kind_from_pc
8686 and breakpoint_kind_from_current_state.
8687 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8688 linux-aarch32-low.c.
8689 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8690 (arm_breakpoint, arm_breakpoint_len): Likewise.
8691 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8692 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8693 (arm_is_thumb_mode): Likewise.
8694 (arm_breakpoint_at): Likewise.
8695 (arm_breakpoint_kind_from_pc): Likewise.
8696 (arm_sw_breakpoint_from_kind): Likewise.
8697 (arm_breakpoint_kind_from_current_state): Likewise.
8698
8699 Revert:
8700 2015-08-04 Yao Qi <yao.qi@linaro.org>
8701
8702 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8703 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8704 * server.c (extended_protocol): Remove "static".
8705 * server.h (extended_protocol): Declare it.
8706
ece66d65
JS
87072015-12-04 Josh Stone <jistone@redhat.com>
8708
8709 * target.h (struct target_ops) <arch_setup>: Rename to ...
8710 (struct target_ops) <post_create_inferior>: ... this.
8711 (target_arch_setup): Rename to ...
8712 (target_post_create_inferior): ... this, calling post_create_inferior.
8713 * server.c (start_inferior): Update target_arch_setup calls to
8714 target_post_create_inferior.
8715 * linux-low.c (linux_low_ptrace_options): Forward declare.
8716 (linux_arch_setup): Update its comment for general use.
8717 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8718 (struct linux_target_ops): Use linux_post_create_inferior.
8719 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8720 to post_create_inferior.
8721 * nto-low.c (struct nto_target_ops): Likewise.
8722 * spu-low.c (struct spu_target_ops): Likewise.
8723 * win32-low.c (struct win32_target_ops): Likewise.
8724
e58c48b4
AT
87252015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
8726
8727 * linux-arm-low.c: Remove duplicate arch/arm.h include.
8728
fbec8956
AT
87292015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8730
8731 * linux-arm-low.c (arm_reinsert_addr): Remove function.
8732 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
8733 * linux-cris-low.c (cris_reinsert_addr> Remove function.
8734 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8735 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
8736 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8737 * linux-mips-low.c (mips_reinsert_addr): Remove function.
8738 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8739 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
8740 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8741 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
8742 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8743
9b4c5f87
AT
87442015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8745
8746 * linux-low.c (linux_look_up_symbols): Don't call
8747 linux_supports_traceclone.
8748 * linux-low.h (thread_db_init): Remove use_events argument.
8749 * thread-db.c (thread_db_use_event): Remove global variable.
8750 (struct thread_db) <td_thr_event_enable_p>: Remove field.
8751 (struct thread_db) <td_create_bp>: Remove field.
8752 (thread_db_create_event): Remove function.
8753 (thread_db_enable_reporting): Likewise.
8754 (find_one_thread): Don't check for thread_db_use_events.
8755 (attach_thread): Likewise.
8756 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
8757 (try_thread_db_load_1): Don't check for thread_db_use_events.
8758 (thread_db_init): Remove use_events argument and thread events
8759 handling.
8760 (remove_thread_event_breakpoints): Remove function.
8761 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
8762
7d00775e
AT
87632015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8764
8765 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
8766 New function.
8767 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8768 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
8769 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8770 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
8771 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
8772 Initialize.
8773 * linux-crisv32-low.c (cris_supports_hardware_single_step):
8774 New function.
8775 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8776 * linux-low.c (can_hardware_single_step): Use
8777 supports_hardware_single_step.
8778 (can_software_single_step): New function.
8779 (start_step_over): Call can_software_single_step.
8780 (linux_supports_hardware_single_step): New function.
8781 (struct target_ops) <supports_software_single_step>: Initialize.
8782 * linux-low.h (struct linux_target_ops)
8783 <supports_hardware_single_step>: Initialize.
8784 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
8785 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8786 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
8787 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
8788 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
8789 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8790 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
8791 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8792 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
8793 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
8794 Initialize.
8795 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
8796 (struct linux_target_ops) <tile_supports_hardware_single_step>:
8797 Initialize.
8798 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
8799 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8800 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
8801 New function.
8802 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8803 * target.h (struct target_ops): <supports_software_single_step>:
8804 New field.
8805 (target_supports_software_single_step): New macro.
8806
2d97cd35
AT
88072015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8808
8809 * linux-low.c (linux_wait_1): Fix pc advance condition.
8810 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
8811 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
8812
769ef81f
AT
88132015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8814
8815 * linux-arm-low.c (arm_is_thumb_mode): New function.
8816 (arm_breakpoint_at): Use arm_is_thumb_mode.
8817 (arm_breakpoint_kind_from_current_state): New function.
8818 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
8819 Initialize.
8820 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
8821 (linux_breakpoint_kind_from_current_state): New function.
8822 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
8823 * linux-low.h (struct linux_target_ops)
8824 <breakpoint_kind_from_current_state>: New field.
8825 * target.h (struct target_ops): Likewise.
8826 (target_breakpoint_kind_from_current_state): New macro.
8827
1bebeeca
PA
88282015-11-30 Pedro Alves <palves@redhat.com>
8829
8830 * linux-low.c (linux_resume): Wake up the event loop before
8831 returning.
8832
a67a9fae
PA
88332015-11-30 Pedro Alves <palves@redhat.com>
8834
8835 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
8836 check.
8837 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
8838 to -1.
8839 * target.c (struct thread_search): New structure.
8840 (thread_search_callback): New function.
8841 (prev_general_thread): New global.
8842 (prepare_to_access_memory, done_accessing_memory): New functions.
8843 * target.h (prepare_to_access_memory, done_accessing_memory):
8844 Replace macros with function declarations.
8845
f2faf941
PA
88462015-11-30 Pedro Alves <palves@redhat.com>
8847
8848 PR 14618
8849 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
8850 report TARGET_WAITKIND_NO_RESUMED.
8851 * remote-utils.c (prepare_resume_reply): Handle
8852 TARGET_WAITKIND_NO_RESUMED.
8853 * server.c (report_no_resumed): New global.
8854 (handle_query) <qSupported>: Handle "no-resumed+". Report
8855 "no-resumed+" support.
8856 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
8857 return error if the client doesn't support no-resumed events.
8858 (push_stop_notification): New function.
8859 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
8860 events if the client supports them.
8861
a681f9c9
PA
88622015-11-30 Pedro Alves <palves@redhat.com>
8863
8864 * linux-low.c (thread_still_has_status_pending_p): Don't check
8865 vCont;t here.
8866 (lwp_resumed): New function.
8867 (status_pending_p_callback): Return early if the LWP is not
8868 supposed to be resumed.
8869
65706a29
PA
88702015-11-30 Pedro Alves <palves@redhat.com>
8871
8872 * linux-low.c (handle_extended_wait): Assert that the LWP's
8873 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
8874 thread create events, leave the new child's status pending.
8875 (linux_low_filter_event): If GDB wants to hear about thread exit
8876 events, leave the LWP marked dead and don't delete it.
8877 (linux_wait_for_event_filtered): Don't check for thread exit.
8878 (filter_exit_event): New function.
8879 (linux_wait_1): Use it, when returning an exit event.
8880 (linux_resume_one_lwp_throw): Assert that the LWP's
8881 waitstatus is TARGET_WAITKIND_IGNORE.
8882 * remote-utils.c (prepare_resume_reply): Handle
8883 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
8884 * server.c (report_thread_events): New global.
8885 (handle_general_set): Handle QThreadEvents.
8886 (handle_query) <qSupported>: Handle and report QThreadEvents+;
8887 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
8888 TARGET_WAITKIND_THREAD_EXITED.
8889 * server.h (report_thread_events): Declare.
8890
56cf4bed
PA
88912015-11-30 Pedro Alves <palves@redhat.com>
8892
8893 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
8894 the thread's last_resume_kind was resume_stop.
8895
500c1d85
PA
88962015-11-30 Pedro Alves <palves@redhat.com>
8897
8898 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
8899 before returning.
8900
de979965
PA
89012015-11-30 Pedro Alves <palves@redhat.com>
8902
8903 * server.c (handle_v_requests): Handle vCtrlC.
8904
34c65914
PA
89052015-11-30 Pedro Alves <palves@redhat.com>
8906
8907 * gdbthread.h (find_any_thread_of_pid): Declare.
8908 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
8909 functions.
8910 * server.c (handle_query): If current_thread is NULL, look for
8911 another thread of the selected process.
8912
79efa585 89132015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 8914 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
8915
8916 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
8917 * server.c (handle_qxfer_threads_worker): Refactor to include thread
8918 name in reply.
8919 * target.h (struct target_ops) <thread_name>: New field.
8920 (target_thread_name): New macro.
8921
80d82c19
JB
89222015-11-23 Joel Brobecker <brobecker@adacore.com>
8923
8924 * regcache.h (regcache_invalidate_pid): Add declaration.
8925 * regcache.c (regcache_invalidate_pid): New function, extracted
8926 from regcache_invalidate.
8927 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
8928 Add trivial documentation comment.
8929 * lynx-low.c: Use regcache_invalidate_pid instead of
8930 regcache_invalidate.
8931
64da5dd5
JB
89322015-11-23 Joel Brobecker <brobecker@adacore.com>
8933
8934 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
8935 and Elf64_auxv_t if the target is Android.
8936
37ce4055
DE
89372015-11-22 Doug Evans <xdje42@gmail.com>
8938
8939 * target.h: #include <sys/types.h>.
8940
06e03fff
PA
89412015-11-19 Pedro Alves <palves@redhat.com>
8942
8943 * linux-low.c (linux_process_qsupported): Change prototype.
8944 Adjust.
8945 * linux-low.h (struct linux_target_ops) <process_qsupported>:
8946 Change prototype.
8947 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
8948 and adjust to loop over all features.
8949 * server.c (handle_query) <qSupported>: Adjust to call
8950 target_process_qsupported once, passing it a vector of unprocessed
8951 features.
8952 * target.h (struct target_ops) <process_qsupported>: Change
8953 prototype.
8954 (target_process_qsupported): Adjust.
8955
9a084706
PA
89562015-11-19 Pedro Alves <palves@redhat.com>
8957
8958 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
8959 mode.
8960 * configure: Regenerate.
8961
dad44a1f
PA
89622015-11-19 Pedro Alves <palves@redhat.com>
8963
8964 * configure: Regenerate.
8965
231c0592
YQ
89662015-11-19 Yao Qi <yao.qi@linaro.org>
8967
8968 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
8969 type to uint32_t.
8970
6c1c9a8b
YQ
89712015-11-19 Yao Qi <yao.qi@linaro.org>
8972
8973 * linux-aarch64-low.c (enum aarch64_operand_type): New.
8974 (struct aarch64_operand): Move enum out.
8975
9caa3311
YQ
89762015-11-19 Yao Qi <yao.qi@linaro.org>
8977
8978 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
8979 struct user_fpsimd_state *.
8980 (aarch64_store_fpregset): Likewise.
8981
6a69a054
YQ
89822015-11-19 Yao Qi <yao.qi@linaro.org>
8983
8984 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
8985 struct user_pt_regs *.
8986 (aarch64_store_gregset): Likewise.
8987
1798301e
PA
89882015-11-18 Pedro Alves <palves@redhat.com>
8989
8990 * Makefile.in (all_object_files): Add $IPA_OBJS.
8991
ce7715e2
PA
89922015-11-17 Pedro Alves <palves@redhat.com>
8993
8994 * win32-low.c (win32_resume): Use gdb_signal_from_host,
8995 GDB_SIGNAL_0 and gdb_signal_to_string.
8996
c0879059
PA
89972015-11-17 Pedro Alves <palves@redhat.com>
8998
8999 * win32-low.c (handle_output_debug_string): Remove parameter.
9000 (win32_kill): Remove our_status local and adjust call to
9001 handle_output_debug_string.
9002 (get_child_debug_event): Adjust call to
9003 handle_output_debug_string.
9004
1996e237
SM
90052015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9006
9007 * linux-mips-low.c (mips_fill_gregset): Add cast.
9008 (mips_store_gregset): Likewise.
9009 (mips_fill_fpregset): Likewise.
9010 (mips_store_fpregset): Likewise.
9011
cbec665b
SM
90122015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9013
9014 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9015 priv.
9016
eb3e3c67
SM
90172015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9018
9019 * linux-mips-low.c (mips_linux_new_thread): Change type of
9020 watch_type to enum target_hw_bp_type.
9021
171de4b8
SM
90222015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9023
9024 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9025 Change return type to arm_hwbp_type.
9026
04248ead
SM
90272015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9028
9029 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9030 (arm_store_gregset): Likewise.
9031 * linux-arm-low.c (arm_get_hwcap): Likewise.
9032 (arm_read_description): Likewise.
9033
04b3479c
SM
90342015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9035
9036 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9037
2bc84e8a
SM
90382015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9039
9040 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9041 (ppc_fill_vsxregset): Likewise.
9042 (ppc_store_vsxregset): Likewise.
9043 (ppc_fill_vrregset): Likewise.
9044 (ppc_store_vrregset): Likewise.
9045 (ppc_fill_evrregset): Likewise.
9046 (ppc_store_evrregset): Likewise.
9047
e6c5bb05
SM
90482015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9049
9050 * linux-ppc-low.c (ppc_usrregs_info): Remove
9051 forward-declaration.
9052 (ppc_arch_setup): Move lower in file.
9053
7ea45d72
SM
90542015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9055
9056 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9057 (ps_pdwrite): Likewise.
9058
69291610
HW
90592015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9060
9061 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9062 to after assert checks.
9063
b42945fd
SM
90642015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9065
9066 * proc-service.c (ps_pdread): Add/adjust casts.
9067 (ps_pdwrite): Add/adjust casts.
9068
d6f85c84
SM
90692015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9070
9071 * server.c (handle_search_memory_1): Cast return value of
9072 memmem.
9073
f98cd059
SM
90742015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9075
9076 * server.c (write_qxfer_response): Change type of data to
9077 gdb_byte *.
9078
d2412fa5
PA
90792015-10-29 Pedro Alves <palves@redhat.com>
9080
9081 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9082
c17414a2
PA
90832015-10-29 Pedro Alves <palves@redhat.com>
9084
9085 * tracepoint.c (clear_installed_tracepoints): Add casts.
9086
e053fbc4
PA
90872015-10-29 Pedro Alves <palves@redhat.com>
9088
9089 * server.c (handle_v_cont, process_serial_event): Add enum
9090 gdb_signal casts to signal parsing code.
9091
add67df8
PA
90922015-10-29 Pedro Alves <palves@redhat.com>
9093
9094 * linux-low.h (NULL_REGSET): Define.
9095 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9096 * linux-arm-low.c (arm_regsets): Likewise.
9097 * linux-crisv32-low.c (cris_regsets): Likewise.
9098 * linux-m68k-low.c (m68k_regsets): Likewise.
9099 * linux-mips-low.c (mips_regsets): Likewise.
9100 * linux-nios2-low.c (nios2_regsets): Likewise.
9101 * linux-ppc-low.c (ppc_regsets): Likewise.
9102 * linux-s390-low.c (s390_regsets): Likewise.
9103 * linux-sh-low.c (sh_regsets): Likewise.
9104 * linux-sparc-low.c (sparc_regsets): Likewise.
9105 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9106 * linux-tile-low.c (tile_regsets): Likewise.
9107 * linux-x86-low.c (x86_regsets): Likewise.
9108 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9109
50bc912a
PA
91102015-10-29 Pedro Alves <palves@redhat.com>
9111
9112 * linux-low.h (NULL_REGSET): Define.
9113 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9114 * linux-arm-low.c (arm_regsets): Likewise.
9115 * linux-crisv32-low.c (cris_regsets): Likewise.
9116 * linux-m68k-low.c (m68k_regsets): Likewise.
9117 * linux-mips-low.c (mips_regsets): Likewise.
9118 * linux-nios2-low.c (nios2_regsets): Likewise.
9119 * linux-ppc-low.c (ppc_regsets): Likewise.
9120 * linux-s390-low.c (s390_regsets): Likewise.
9121 * linux-sh-low.c (sh_regsets): Likewise.
9122 * linux-sparc-low.c (sparc_regsets): Likewise.
9123 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9124 * linux-tile-low.c (tile_regsets): Likewise.
9125 * linux-x86-low.c (x86_regsets): Likewise.
9126 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9127
682b2546
DE
91282015-10-26 Doug Evans <dje@google.com>
9129
9130 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9131
963843d4
DE
91322015-10-26 Doug Evans <dje@google.com>
9133
9134 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9135
d41401ac
DE
91362015-10-26 Doug Evans <dje@google.com>
9137
9138 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9139 for debug_printf.
9140 (attach_thread, find_new_threads_callback): Ditto.
9141
3db28855
AT
91422015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9143
9144 * mem-break.h (set_breakpoint_data): Remove.
9145
fb78e89c
AT
91462015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9147
9148 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9149 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9150 (initialize_low): Remove set_breakpoint_data call.
9151 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9152 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9153 (initialize_low): Remove set_breakpoint_data call.
9154 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9155 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9156 (initialize_low): Remove set_breakpoint_data call.
9157
2e6ee069
AT
91582015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9159
9160 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9161 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9162 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9163 * target.h (target_breakpoint_kind_from_pc): New macro.
9164
1652a986
AT
91652015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9166
9167 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9168 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9169 the default breakpoint kind.
9170
abeead09
AT
91712015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9172
9173 * linux-arm-low.c (arm_supports_z_point_type): Add software
9174 breakpoint support.
9175
b0b4b501
AT
91762015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9177
9178 * linux-arm-low.c: Refactor breakpoint definitions.
9179 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9180 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9181
8689682c
AT
91822015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9183
9184 * Makefile.in: Add arm.c/o.
9185 * configure.srv: Likewise.
9186 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9187 (arm_breakpoint_kind_from_pc): New function.
9188 (arm_sw_breakpoint_from_kind): Return proper kind.
9189 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9190
27165294
AT
91912015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9192
9193 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9194 removal.
9195 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9196 (struct raw_breakpoint) <size>: Remove.
9197 (struct raw_breakpoint) <kind>: Add.
9198 (bp_size): New function.
9199 (bp_opcode): Likewise.
9200 (find_raw_breakpoint_at): Adjust for kind.
9201 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9202 (remove_memory_breakpoint): Adjust for kind call bp_size.
9203 (set_raw_breakpoint_at): Adjust for kind.
9204 (set_breakpoint): Likewise.
9205 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9206 (delete_raw_breakpoint): Adjust for kind.
9207 (delete_breakpoint): Likewise.
9208 (find_gdb_breakpoint): Likewise.
9209 (set_gdb_breakpoint_1): Likewise.
9210 (set_gdb_breakpoint): Likewise.
9211 (delete_gdb_breakpoint_1): Likewise.
9212 (delete_gdb_breakpoint): Likewise.
9213 (uninsert_raw_breakpoint): Likewise.
9214 (reinsert_raw_breakpoint): Likewise.
9215 (set_breakpoint_data): Remove.
9216 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9217 (check_mem_read): Adjust for kind call bp_size.
9218 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9219 (clone_one_breakpoint): Adjust for kind.
9220 * mem-break.h (set_gdb_breakpoint): Likewise.
9221 (delete_gdb_breakpoint): Likewise.
9222 * server.c (process_serial_event): Likewise.
9223
dd373349
AT
92242015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9225
9226 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9227 (struct linux_target_ops) <breakpoint>: Remove.
9228 (struct linux_target_ops) <breakpoint_len>: Remove.
9229 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9230 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9231 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9232 (arm_sw_breakpoint_from_kind): New function.
9233 * linux-bfin-low.c (bfin_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-cris-low.c (cris_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-crisv32-low.c (cris_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-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9249 and sw_breakpoint_from_kind to increment the pc.
9250 (linux_breakpoint_kind_from_pc): New function.
9251 (linux_sw_breakpoint_from_kind): New function.
9252 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9253 (initialize_low): Call breakpoint_kind_from_pc and
9254 sw_breakpoint_from_kind to replace breakpoint_data/len.
9255 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9256 New field.
9257 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9258 * linux-m32r-low.c (m32r_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-m68k-low.c (m68k_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-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9269 (struct linux_target_ops) <breakpoint>: Remove.
9270 (struct linux_target_ops) <breakpoint_len>: Remove.
9271 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9272 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9273 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9274 (struct linux_target_ops) <breakpoint>: Remove.
9275 (struct linux_target_ops) <breakpoint_len>: Remove.
9276 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9277 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9278 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9279 (struct linux_target_ops) <breakpoint>: Remove.
9280 (struct linux_target_ops) <breakpoint_len>: Remove.
9281 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9282 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9283 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9284 (struct linux_target_ops) <breakpoint>: Remove.
9285 (struct linux_target_ops) <breakpoint_len>: Remove.
9286 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9287 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9288 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9289 (struct linux_target_ops) <breakpoint>: Remove.
9290 (struct linux_target_ops) <breakpoint_len>: Remove.
9291 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9292 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9293 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9294 (struct linux_target_ops) <breakpoint>: Remove.
9295 (struct linux_target_ops) <breakpoint_len>: Remove.
9296 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9297 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9298 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9299 (struct linux_target_ops) <breakpoint>: Remove.
9300 (struct linux_target_ops) <breakpoint_len>: Remove.
9301 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9302 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9303 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9304 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9305 (struct linux_target_ops) <breakpoint>: Remove.
9306 (struct linux_target_ops) <breakpoint_len>: Remove.
9307 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9308 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9309 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9310 (struct linux_target_ops) <breakpoint>: Remove.
9311 (struct linux_target_ops) <breakpoint_len>: Remove.
9312 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9313 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9314
4cd98a19
AT
93152015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9316
9317 * linux-cris-low.c (cris_get_pc): Remove void arg.
9318
774ee6d2
AR
93192015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9320
9321 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9322 variable name.
9323
833dcd29
AR
93242015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9325
9326 * inferiors.c (thread_pid_matches_callback): New function.
9327 (find_thread_process): New function.
9328 (remove_thread): Reset current_thread.
9329 (remove_process): Assert threads have been removed first.
9330
8d689ee5
YQ
93312015-10-15 Yao Qi <yao.qi@linaro.org>
9332
9333 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9334 if it is 3.
9335 (aarch64_remove_point): Likewise.
9336 * regcache.c (regcache_register_size): New function.
9337
1c2e1515
YQ
93382015-10-12 Yao Qi <yao.qi@linaro.org>
9339
9340 * linux-aarch64-low.c: Update all callers as emit_load_store
9341 is renamed to aarch64_emit_load_store.
9342
e1c587c3
YQ
93432015-10-12 Yao Qi <yao.qi@linaro.org>
9344
9345 * linux-aarch64-low.c: Update all callers of function renaming
9346 from emit_insn to aarch64_emit_insn.
9347
b6542f81
YQ
93482015-10-12 Yao Qi <yao.qi@linaro.org>
9349
9350 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9351 arch/aarch64-insn.h.
9352 (struct aarch64_memory_operand): Likewise.
9353 (ENCODE): Likewise.
9354 (emit_insn): Move to arch/aarch64-insn.c.
9355 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9356 (emit_load_store): Move to arch/aarch64-insn.c.
9357 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9358 (can_encode_int32): Remove.
9359
246994ce
YQ
93602015-10-12 Yao Qi <yao.qi@linaro.org>
9361
9362 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9363 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9364 (aarch64_relocate_instruction): Likewise.
9365 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9366 (struct aarch64_insn_visitor): Likewise.
9367
0badd99f
YQ
93682015-10-12 Yao Qi <yao.qi@linaro.org>
9369
9370 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9371 (struct aarch64_insn_visitor): New.
9372 (struct aarch64_insn_relocation_data): New.
9373 (aarch64_ftrace_insn_reloc_b): New function.
9374 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9375 (aarch64_ftrace_insn_reloc_cb): Likewise.
9376 (aarch64_ftrace_insn_reloc_tb): Likewise.
9377 (aarch64_ftrace_insn_reloc_adr): Likewise.
9378 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9379 (aarch64_ftrace_insn_reloc_others): Likewise.
9380 (visitor): New.
9381 (aarch64_relocate_instruction): Use visitor.
9382
dfaffe9d
YQ
93832015-10-12 Yao Qi <yao.qi@linaro.org>
9384
9385 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9386 int. Add argument buf.
9387 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9388 aarch64_relocate_instruction.
9389
70b439f0
YQ
93902015-10-12 Yao Qi <yao.qi@linaro.org>
9391
9392 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9393 argument insn. Remove local variable insn. Don't call
9394 target_read_uint32.
9395 (aarch64_install_fast_tracepoint_jump_pad): Call
9396 target_read_uint32.
9397
7781c06f
YQ
93982015-09-30 Yao Qi <yao.qi@linaro.org>
9399
9400 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9401 (emit_load_store_pair): Likewise.
9402
9a3c8263
SM
94032015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9404
9405 * dll.c (match_dll): Add cast(s).
9406 (unloaded_dll): Likewise.
9407 * linux-low.c (second_thread_of_pid_p): Likewise.
9408 (delete_lwp_callback): Likewise.
9409 (count_events_callback): Likewise.
9410 (select_event_lwp_callback): Likewise.
9411 (linux_set_resume_request): Likewise.
9412 * server.c (accumulate_file_name_length): Likewise.
9413 (emit_dll_description): Likewise.
9414 (handle_qxfer_threads_worker): Likewise.
9415 (visit_actioned_threads): Likewise.
9416 * thread-db.c (any_thread_of): Likewise.
9417 * tracepoint.c (same_process_p): Likewise.
9418 (match_blocktype): Likewise.
9419 (build_traceframe_info_xml): Likewise.
9420
224c3ddb
SM
94212015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9422
9423 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9424 assignment.
9425 (gdb_unparse_agent_expr): Likewise.
9426 * hostio.c (require_data): Likewise.
9427 (handle_pread): Likewise.
9428 * linux-low.c (disable_regset): Likewise.
9429 (fetch_register): Likewise.
9430 (store_register): Likewise.
9431 (get_dynamic): Likewise.
9432 (linux_qxfer_libraries_svr4): Likewise.
9433 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9434 (set_fast_tracepoint_jump): Likewise.
9435 (uninsert_fast_tracepoint_jumps_at): Likewise.
9436 (reinsert_fast_tracepoint_jumps_at): Likewise.
9437 (validate_inserted_breakpoint): Likewise.
9438 (clone_agent_expr): Likewise.
9439 * regcache.c (init_register_cache): Likewise.
9440 * remote-utils.c (putpkt_binary_1): Likewise.
9441 (decode_M_packet): Likewise.
9442 (decode_X_packet): Likewise.
9443 (look_up_one_symbol): Likewise.
9444 (relocate_instruction): Likewise.
9445 (monitor_output): Likewise.
9446 * server.c (handle_search_memory): Likewise.
9447 (handle_qxfer_exec_file): Likewise.
9448 (handle_qxfer_libraries): Likewise.
9449 (handle_qxfer): Likewise.
9450 (handle_query): Likewise.
9451 (handle_v_cont): Likewise.
9452 (handle_v_run): Likewise.
9453 (captured_main): Likewise.
9454 * target.c (write_inferior_memory): Likewise.
9455 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9456 * tracepoint.c (init_trace_buffer): Likewise.
9457 (add_tracepoint_action): Likewise.
9458 (add_traceframe): Likewise.
9459 (add_traceframe_block): Likewise.
9460 (cmd_qtdpsrc): Likewise.
9461 (cmd_qtdv): Likewise.
9462 (cmd_qtstatus): Likewise.
9463 (response_source): Likewise.
9464 (response_tsv): Likewise.
9465 (cmd_qtnotes): Likewise.
9466 (gdb_collect): Likewise.
9467 (initialize_tracepoint): Likewise.
9468
afbe19f8
PL
94692015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9470
9471 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9472 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9473 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9474 <NOP>: New.
9475 (enum aarch64_condition_codes): New enum.
9476 (w0): New static global.
9477 (fp): Likewise.
9478 (lr): Likewise.
9479 (struct aarch64_memory_operand) <type>: New
9480 MEMORY_OPERAND_POSTINDEX type.
9481 (postindex_memory_operand): New helper function.
9482 (emit_ret): New function.
9483 (emit_load_store_pair): New function, factored out of emit_stp
9484 with support for MEMORY_OPERAND_POSTINDEX.
9485 (emit_stp): Rewrite using emit_load_store_pair.
9486 (emit_ldp): New function.
9487 (emit_load_store): Likewise.
9488 (emit_ldr): Mention post-index instruction in comment.
9489 (emit_ldrh): New function.
9490 (emit_ldrb): New function.
9491 (emit_ldrsw): Mention post-index instruction in comment.
9492 (emit_str): Likewise.
9493 (emit_subs): New function.
9494 (emit_cmp): Likewise.
9495 (emit_and): Likewise.
9496 (emit_orr): Likewise.
9497 (emit_orn): Likewise.
9498 (emit_eor): Likewise.
9499 (emit_mvn): Likewise.
9500 (emit_lslv): Likewise.
9501 (emit_lsrv): Likewise.
9502 (emit_asrv): Likewise.
9503 (emit_mul): Likewise.
9504 (emit_sbfm): Likewise.
9505 (emit_sbfx): Likewise.
9506 (emit_ubfm): Likewise.
9507 (emit_ubfx): Likewise.
9508 (emit_csinc): Likewise.
9509 (emit_cset): Likewise.
9510 (emit_nop): Likewise.
9511 (emit_ops_insns): New helper function.
9512 (emit_pop): Likewise.
9513 (emit_push): Likewise.
9514 (aarch64_emit_prologue): New function.
9515 (aarch64_emit_epilogue): Likewise.
9516 (aarch64_emit_add): Likewise.
9517 (aarch64_emit_sub): Likewise.
9518 (aarch64_emit_mul): Likewise.
9519 (aarch64_emit_lsh): Likewise.
9520 (aarch64_emit_rsh_signed): Likewise.
9521 (aarch64_emit_rsh_unsigned): Likewise.
9522 (aarch64_emit_ext): Likewise.
9523 (aarch64_emit_log_not): Likewise.
9524 (aarch64_emit_bit_and): Likewise.
9525 (aarch64_emit_bit_or): Likewise.
9526 (aarch64_emit_bit_xor): Likewise.
9527 (aarch64_emit_bit_not): Likewise.
9528 (aarch64_emit_equal): Likewise.
9529 (aarch64_emit_less_signed): Likewise.
9530 (aarch64_emit_less_unsigned): Likewise.
9531 (aarch64_emit_ref): Likewise.
9532 (aarch64_emit_if_goto): Likewise.
9533 (aarch64_emit_goto): Likewise.
9534 (aarch64_write_goto_address): Likewise.
9535 (aarch64_emit_const): Likewise.
9536 (aarch64_emit_call): Likewise.
9537 (aarch64_emit_reg): Likewise.
9538 (aarch64_emit_pop): Likewise.
9539 (aarch64_emit_stack_flush): Likewise.
9540 (aarch64_emit_zero_ext): Likewise.
9541 (aarch64_emit_swap): Likewise.
9542 (aarch64_emit_stack_adjust): Likewise.
9543 (aarch64_emit_int_call_1): Likewise.
9544 (aarch64_emit_void_call_2): Likewise.
9545 (aarch64_emit_eq_goto): Likewise.
9546 (aarch64_emit_ne_goto): Likewise.
9547 (aarch64_emit_lt_goto): Likewise.
9548 (aarch64_emit_le_goto): Likewise.
9549 (aarch64_emit_gt_goto): Likewise.
9550 (aarch64_emit_ge_got): Likewise.
9551 (aarch64_emit_ops_impl): New static global variable.
9552 (aarch64_emit_ops): New target function, return
9553 &aarch64_emit_ops_impl.
9554 (struct linux_target_ops): Install it.
9555
bb903df0
PL
95562015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9557
9558 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9559 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9560 aarch64-ipa.o.
9561 * linux-aarch64-ipa.c: New file.
9562 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9563 and endian.h.
9564 (aarch64_get_thread_area): New target method.
9565 (extract_signed_bitfield): New helper function.
9566 (aarch64_decode_ldr_literal): New function.
9567 (enum aarch64_opcodes): New enum.
9568 (struct aarch64_register): New struct.
9569 (struct aarch64_operand): New struct.
9570 (x0): New static global.
9571 (x1): Likewise.
9572 (x2): Likewise.
9573 (x3): Likewise.
9574 (x4): Likewise.
9575 (w2): Likewise.
9576 (ip0): Likewise.
9577 (sp): Likewise.
9578 (xzr): Likewise.
9579 (aarch64_register): New helper function.
9580 (register_operand): Likewise.
9581 (immediate_operand): Likewise.
9582 (struct aarch64_memory_operand): New struct.
9583 (offset_memory_operand): New helper function.
9584 (preindex_memory_operand): Likewise.
9585 (enum aarch64_system_control_registers): New enum.
9586 (ENCODE): New macro.
9587 (emit_insn): New helper function.
9588 (emit_b): New function.
9589 (emit_bcond): Likewise.
9590 (emit_cb): Likewise.
9591 (emit_tb): Likewise.
9592 (emit_blr): Likewise.
9593 (emit_stp): Likewise.
9594 (emit_ldp_q_offset): Likewise.
9595 (emit_stp_q_offset): Likewise.
9596 (emit_load_store): Likewise.
9597 (emit_ldr): Likewise.
9598 (emit_ldrsw): Likewise.
9599 (emit_str): Likewise.
9600 (emit_ldaxr): Likewise.
9601 (emit_stxr): Likewise.
9602 (emit_stlr): Likewise.
9603 (emit_data_processing_reg): Likewise.
9604 (emit_data_processing): Likewise.
9605 (emit_add): Likewise.
9606 (emit_sub): Likewise.
9607 (emit_mov): Likewise.
9608 (emit_movk): Likewise.
9609 (emit_mov_addr): Likewise.
9610 (emit_mrs): Likewise.
9611 (emit_msr): Likewise.
9612 (emit_sevl): Likewise.
9613 (emit_wfe): Likewise.
9614 (append_insns): Likewise.
9615 (can_encode_int32_in): New helper function.
9616 (aarch64_relocate_instruction): New function.
9617 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9618 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9619 (struct linux_target_ops): Install aarch64_get_thread_area,
9620 aarch64_install_fast_tracepoint_jump_pad and
9621 aarch64_get_min_fast_tracepoint_insn_len.
9622
787749ea
PL
96232015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9624
9625 * Makefile.in (aarch64-insn.o): New rule.
9626 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9627
9812b2e6
YQ
96282015-09-21 Yao Qi <yao.qi@linaro.org>
9629
9630 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9631
18fe412b
YQ
96322015-09-21 Yao Qi <yao.qi@linaro.org>
9633
9634 * tracepoint.c (max_jump_pad_size): Remove.
9635
a0cc84cd
YQ
96362015-09-18 Yao Qi <yao.qi@linaro.org>
9637
9638 * linux-aarch64-low.c: Don't include sys/uio.h.
9639 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9640
d78908cf
WW
96412015-09-16 Wei-cheng Wang <cole945@gmail.com>
9642
9643 * tracepoint.c (eval_result_type): Change prototype.
9644 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9645
d57e0d50
PA
96462015-09-15 Pedro Alves <palves@redhat.com>
9647
9648 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9649 Check whether to report exec events instead of checking whether
9650 multiprocess is enabled.
9651
5a676acc
PA
96522015-09-15 Pedro Alves <palves@redhat.com>
9653
9654 PR remote/18965
9655 * remote-utils.c (prepare_resume_reply): Merge
9656 TARGET_WAITKIND_VFORK_DONE switch case with the
9657 TARGET_WAITKIND_FORKED case.
9658
7c5d0fad
YQ
96592015-09-15 Yao Qi <yao.qi@linaro.org>
9660
9661 * server.c (handle_query): Check string comparison using
9662 "else if" instead of "if".
9663
750ce8d1
YQ
96642015-09-15 Yao Qi <yao.qi@linaro.org>
9665
9666 * server.c (vCont_supported): New global variable.
9667 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9668 matches. Append ";vContSupported+" to own_buf.
9669 (handle_v_requests): Append ";s;S" to own_buf if target supports
9670 hardware single step or vCont_supported is false.
9671 (capture_main): Set vCont_supported to zero.
9672
70b90b91
YQ
96732015-09-15 Yao Qi <yao.qi@linaro.org>
9674
9675 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9676 it to ...
9677 (linux_supports_hardware_single_step): ... New function.
9678 (linux_target_ops): Update.
9679 * lynx-low.c (lynx_target_ops): Set field
9680 supports_hardware_single_step to target_can_do_hardware_single_step.
9681 * nto-low.c (nto_target_ops): Likewise.
9682 * spu-low.c (spu_target_ops): Likewise.
9683 * win32-low.c (win32_target_ops): Likewise.
9684 * target.c (target_can_do_hardware_single_step): New function.
9685 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9686 Remove. <supports_hardware_single_step>: New field.
9687 (target_supports_conditional_breakpoints): Remove.
9688 (target_supports_hardware_single_step): New macro.
9689 (target_can_do_hardware_single_step): Declare.
9690 * server.c (handle_query): Use target_supports_hardware_single_step
9691 instead of target_supports_conditional_breakpoints.
9692
ade90bde
YQ
96932015-09-15 Yao Qi <yao.qi@linaro.org>
9694
9695 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9696 function.
9697 (struct linux_target_ops the_low_target): Install
9698 aarch64_linux_siginfo_fixup.
9699
94585166
DB
97002015-09-11 Don Breazeal <donb@codesourcery.com>
9701 Luis Machado <lgustavo@codesourcery.com>
9702
9703 * linux-low.c (linux_mourn): Static declaration.
9704 (linux_arch_setup): Move in front of
9705 handle_extended_wait.
9706 (linux_arch_setup_thread): New function.
9707 (handle_extended_wait): Handle exec events. Call
9708 linux_arch_setup_thread. Make event_lwp argument a
9709 pointer-to-a-pointer.
9710 (check_zombie_leaders): Do not check stopped threads.
9711 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9712 (linux_low_filter_event): Add lwp and thread for exec'ing
9713 non-leader thread if leader thread has been deleted.
9714 Refactor code into linux_arch_setup_thread and call it.
9715 Pass child lwp pointer by reference to handle_extended_wait.
9716 (linux_wait_for_event_filtered): Update comment.
9717 (linux_wait_1): Prevent clobbering exec event status.
9718 (linux_supports_exec_events): New function.
9719 (linux_target_ops) <supports_exec_events>: Initialize new member.
9720 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9721 new member.
9722 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9723 * server.c (report_exec_events): New global variable.
9724 (handle_query): Handle qSupported query for exec-events feature.
9725 (captured_main): Initialize report_exec_events.
9726 * server.h (report_exec_events): Declare new global variable.
9727 * target.h (struct target_ops) <supports_exec_events>: New
9728 member.
9729 (target_supports_exec_events): New macro.
9730 * win32-low.c (win32_target_ops) <supports_exec_events>:
9731 Initialize new member.
9732
0568462b
MM
97332015-09-09 Markus Metzger <markus.t.metzger@intel.com>
9734
9735 * linux-low.c (linux_low_enable_btrace): Remove.
9736 (linux_target_ops): Replace linux_low_enable_btrace with
9737 linux_enable_btrace.
9738
39edd165
YQ
97392015-09-03 Yao Qi <yao.qi@linaro.org>
9740
9741 * linux-aarch64-low.c (aarch64_insert_point): Call
9742 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
9743 returns true.
9744
1db33b5a
UW
97452015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
9746
9747 * linux-low.c (check_stopped_by_breakpoint): Use
9748 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
9749
ab290430
PA
97502015-08-27 Pedro Alves <palves@redhat.com>
9751
9752 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
9753
8d749320
SM
97542015-08-26 Simon Marchi <simon.marchi@ericsson.com>
9755
6711b7f8
SM
9756 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
9757 the XNEW-family equivalent.
8d749320
SM
9758 (compile_bytecodes): Likewise.
9759 * dll.c (loaded_dll): Likewise.
9760 * event-loop.c (append_callback_event): Likewise.
9761 (create_file_handler): Likewise.
9762 (create_file_event): Likewise.
9763 * hostio.c (handle_open): Likewise.
9764 * inferiors.c (add_thread): Likewise.
9765 (add_process): Likewise.
9766 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
9767 * linux-arm-low.c (arm_new_process): Likewise.
9768 (arm_new_thread): Likewise.
9769 * linux-low.c (add_to_pid_list): Likewise.
9770 (linux_add_process): Likewise.
9771 (handle_extended_wait): Likewise.
9772 (add_lwp): Likewise.
9773 (enqueue_one_deferred_signal): Likewise.
9774 (enqueue_pending_signal): Likewise.
9775 (linux_resume_one_lwp_throw): Likewise.
9776 (linux_resume_one_thread): Likewise.
9777 (linux_read_memory): Likewise.
9778 (linux_write_memory): Likewise.
9779 * linux-mips-low.c (mips_linux_new_process): Likewise.
9780 (mips_linux_new_thread): Likewise.
9781 (mips_add_watchpoint): Likewise.
9782 * linux-x86-low.c (initialize_low_arch): Likewise.
9783 * lynx-low.c (lynx_add_process): Likewise.
9784 * mem-break.c (set_raw_breakpoint_at): Likewise.
9785 (set_breakpoint): Likewise.
9786 (add_condition_to_breakpoint): Likewise.
9787 (add_commands_to_breakpoint): Likewise.
9788 (clone_agent_expr): Likewise.
9789 (clone_one_breakpoint): Likewise.
9790 * regcache.c (new_register_cache): Likewise.
9791 * remote-utils.c (look_up_one_symbol): Likewise.
9792 * server.c (queue_stop_reply): Likewise.
9793 (start_inferior): Likewise.
9794 (queue_stop_reply_callback): Likewise.
9795 (handle_target_event): Likewise.
9796 * spu-low.c (fetch_ppc_memory): Likewise.
9797 (store_ppc_memory): Likewise.
9798 * target.c (set_target_ops): Likewise.
9799 * thread-db.c (thread_db_load_search): Likewise.
9800 (try_thread_db_load_1): Likewise.
9801 * tracepoint.c (add_tracepoint): Likewise.
9802 (add_tracepoint_action): Likewise.
9803 (create_trace_state_variable): Likewise.
9804 (cmd_qtdpsrc): Likewise.
9805 (cmd_qtro): Likewise.
9806 (add_while_stepping_state): Likewise.
9807 * win32-low.c (child_add_thread): Likewise.
9808 (get_image_name): Likewise.
9809
ed8b7b42
YQ
98102015-08-25 Yao Qi <yao.qi@linaro.org>
9811
9812 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
9813
db3cb7cb
YQ
98142015-08-25 Yao Qi <yao.qi@linaro.org>
9815
9816 * Makefile.in (aarch64-linux.o): New rule.
9817 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
9818 srv_tgtobj.
9819 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
9820 (aarch64_init_debug_reg_state): Make it extern.
9821 (aarch64_linux_prepare_to_resume): Remove.
9822
f6011a1c
YQ
98232015-08-25 Yao Qi <yao.qi@linaro.org>
9824
9825 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
9826 lwp_arch_private_info and ptid_of_lwp.
9827
88e2cf7e
YQ
98282015-08-25 Yao Qi <yao.qi@linaro.org>
9829
9830 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
9831 Find proc_info by find_process_pid. All callers updated.
9832
5e35436e
YQ
98332015-08-25 Yao Qi <yao.qi@linaro.org>
9834
9835 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
9836 Remove.
9837 (debug_reg_change_callback): Remove.
9838 (aarch64_notify_debug_reg_change): Remove.
9839
4a8a7965
YQ
98402015-08-25 Yao Qi <yao.qi@linaro.org>
9841
9842 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
9843 Call current_lwp_ptid.
9844
32a271ee
YQ
98452015-08-25 Yao Qi <yao.qi@linaro.org>
9846
9847 * linux-aarch64-low.c (debug_reg_change_callback): Use
9848 debug_printf.
9849
0d51c8d7
YQ
98502015-08-25 Yao Qi <yao.qi@linaro.org>
9851
9852 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
9853
31a43dd5
YQ
98542015-08-25 Yao Qi <yao.qi@linaro.org>
9855
9856 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
9857
8ee52567
YQ
98582015-08-25 Yao Qi <yao.qi@linaro.org>
9859
9860 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
9861 the code.
9862
ff3f0f45
YQ
98632015-08-25 Yao Qi <yao.qi@linaro.org>
9864
9865 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
9866 Remove.
9867 (debug_reg_change_callback): Remove argument entry and add argument
9868 lwp. Remove local variable thread. Don't print thread id in the
9869 debugging output. Don't check whether pid of thread equals to pid.
9870 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
9871 iterate_over_lwps instead find_inferior.
9872
3d40fbb5
PA
98732015-08-24 Pedro Alves <palves@redhat.com>
9874
9875 * inferiors.c (get_first_process): New function.
9876 * inferiors.h (get_first_process): New declaration.
9877 * remote-utils.c (read_ptid): Default to the first process in the
9878 list, instead of to the current thread's process.
9879
438e1e42
PA
98802015-08-24 Pedro Alves <palves@redhat.com>
9881
9882 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
9883 * event-loop.c: Likewise.
9884 * remote-utils.c: Likewise.
9885 * tracepoint.c: Likewise.
9886
a8c6d4fc
PA
98872015-08-24 Pedro Alves <palves@redhat.com>
9888
9889 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
9890 ptid_get_lwp.
9891
99b0bb12
PA
98922015-08-21 Pedro Alves <palves@redhat.com>
9893
9894 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
9895 instead of literal 1.
9896
f8904751
PA
98972015-08-21 Pedro Alves <palves@redhat.com>
9898
9899 * tdesc.c (default_description): Explicitly zero-initialize.
9900
465a859e
PA
99012015-08-21 Pedro Alves <palves@redhat.com>
9902
9903 PR gdb/18749
9904 * inferiors.c (remove_thread): Discard any pending stop reply for
9905 this thread.
9906 * server.c (remove_all_on_match_pid): Rename to ...
9907 (remove_all_on_match_ptid): ... this. Work with a filter ptid
9908 instead of a pid.
9909 (discard_queued_stop_replies): Change parameter to a ptid. Now
9910 extern.
9911 (handle_v_kill, kill_inferior_callback, captured_main)
9912 (process_serial_event): Adjust.
9913 * server.h (discard_queued_stop_replies): Declare.
9914
f0db101d
PA
99152015-08-21 Pedro Alves <palves@redhat.com>
9916
9917 * linux-low.c (wait_for_sigstop): Always switch to no thread
9918 selected if the previously current thread dies.
9919 * lynx-low.c (lynx_request_interrupt): Use the first thread's
9920 process instead of the current thread's.
9921 * remote-utils.c (input_interrupt): Don't check if there's no
9922 current thread.
9923 * server.c (gdb_read_memory, gdb_write_memory): If setting the
9924 current thread to the general thread fails, error out.
9925 (handle_qxfer_auxv, handle_qxfer_libraries)
9926 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
9927 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
9928 (handle_query): Check if there's a thread selected instead of
9929 checking whether there's any thread in the thread list.
9930 (handle_qxfer_threads, handle_qxfer_btrace)
9931 (handle_qxfer_btrace_conf): Don't error out early if there's no
9932 thread in the thread list.
9933 (handle_v_cont, myresume): Don't set the current thread to the
9934 continue thread.
9935 (process_serial_event) <Hg handling>: Also set thread_id if the
9936 previous general thread is still alive.
9937 (process_serial_event) <g/G handling>: If setting the current
9938 thread to the general thread fails, error out.
9939 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
9940 thread's lwp instead of the current thread's.
9941 * target.c (set_desired_thread): If the desired thread was not
9942 found, leave the current thread pointing to NULL. Return an int
9943 (boolean) indicating success.
9944 * target.h (set_desired_thread): Change return type to int.
9945
40045d91
MF
99462015-08-20 Max Filippov <jcmvbkbc@gmail.com>
9947
9948 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
9949 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
9950 #includes.
9951 (ps_get_thread_area): New function.
9952
45face3b
GB
99532015-08-19 Gary Benson <gbenson@redhat.com>
9954
9955 * hostio.c (handle_pread): Do not attempt to read more data
9956 than hostio_reply_with_data can fit in a packet.
9957
16d5f642
JB
99582015-08-18 Joel Brobecker <brobecker@adacore.com>
9959
9960 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
9961
a738da3a
MF
99622015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
9963
9964 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
9965
33ebda9d
PA
99662015-08-06 Pedro Alves <palves@redhat.com>
9967
9968 * tracepoint.c (expr_eval_result): Now an int.
9969
a44892be
PA
99702015-08-06 Pedro Alves <palves@redhat.com>
9971
9972 * gdbthread.h (struct regcache): Forward declare.
9973 (struct thread_info) <regcache_data>: Now a struct regcache
9974 pointer.
9975 * inferiors.c (inferior_regcache_data)
9976 (set_inferior_regcache_data): Now work with struct regcache
9977 pointers.
9978 * inferiors.h (struct regcache): Forward declare.
9979 (inferior_regcache_data, set_inferior_regcache_data): Now work
9980 with struct regcache pointers.
9981 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
9982 (free_register_cache_thread): Remove struct regcache pointer
9983 casts.
9984
608a1e46
PA
99852015-08-06 Pedro Alves <palves@redhat.com>
9986
9987 * server.c (captured_main): On error, print the exception message
9988 to stderr, and if run_once is set, throw a quit.
9989
f0ce0d3a
PA
99902015-08-06 Pedro Alves <palves@redhat.com>
9991
9992 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
9993 the current thread.
9994
bf47e248
PA
99952015-08-06 Pedro Alves <palves@redhat.com>
9996
9997 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
9998 reading beyond the passed in buffer length.
9999
b6b9ffcc
PL
100002015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10001
10002 * tracepoint.c (symbol_list) <required>: Remove.
10003
863d01bd
PA
100042015-08-06 Pedro Alves <palves@redhat.com>
10005
10006 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10007 count if stopping and suspending threads.
10008 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10009 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10010 (linux_detach): Complete an ongoing step-over.
10011 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10012 throughout.
10013 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10014 (linux_wait_1): If passing a signal to the inferior after
10015 finishing a step-over, unsuspend and re-resume all lwps. If we
10016 see a single-step event but the thread should be continuing, don't
10017 pass the trap to gdb.
10018 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10019 internal_error instead of gdb_assert.
10020 (enqueue_pending_signal): New function.
10021 (check_ptrace_stopped_lwp_gone): Add debug output.
10022 (start_step_over): Use internal_error instead of gdb_assert.
10023 (complete_ongoing_step_over): New function.
10024 (linux_resume_one_thread): Don't resume a suspended thread.
10025 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10026 it stepping.
10027
00db26fa
PA
100282015-08-06 Pedro Alves <palves@redhat.com>
10029
10030 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10031 (linux_thread_alive): Use lwp_is_marked_dead.
10032 (extended_event_reported): Delete.
10033 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10034 instead of extended_event_reported.
10035 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10036 as well.
10037 (lwp_is_marked_dead): New function.
10038 (lwp_running): Use lwp_is_marked_dead.
10039 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10040 comment.
10041
ad071a30
PA
100422015-08-06 Pedro Alves <palves@redhat.com>
10043
10044 * linux-low.c (linux_wait_1): Move fork event output out of the
10045 !report_to_gdb check. Pass event_child->waitstatus to
10046 target_waitstatus_to_string instead of ourstatus.
10047
524b57e6
YQ
100482015-08-04 Yao Qi <yao.qi@linaro.org>
10049
10050 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10051 if current_thread is 32 bit.
10052
6085d6f6
YQ
100532015-08-04 Yao Qi <yao.qi@linaro.org>
10054
10055 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10056 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10057 * server.c (extended_protocol): Remove "static".
10058 * server.h (extended_protocol): Declare it.
10059
8a7e4587
YQ
100602015-08-04 Yao Qi <yao.qi@linaro.org>
10061
10062 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10063 both aarch64 and aarch32.
10064 (aarch64_set_pc): Likewise.
10065
3b53ae99
YQ
100662015-08-04 Yao Qi <yao.qi@linaro.org>
10067
10068 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10069 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10070 arm-with-neon.xml to srv_xmlfiles.
10071 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10072 (is_64bit_tdesc): New function.
10073 (aarch64_linux_read_description): New function.
10074 (aarch64_arch_setup): Call aarch64_linux_read_description.
10075 (regs_info): Rename to regs_info_aarch64.
10076 (aarch64_regs_info): Return right regs_info.
10077 (initialize_low_arch): Call initialize_low_arch_aarch32.
10078
bd9e6534
YQ
100792015-08-04 Yao Qi <yao.qi@linaro.org>
10080
10081 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10082 * linux-aarch32-low.c: New file.
10083 * linux-aarch32-low.h: New file.
10084 * linux-arm-low.c (arm_fill_gregset): Move it to
10085 linux-aarch32-low.c.
10086 (arm_store_gregset): Likewise.
10087 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10088 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10089 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10090 (regs_info): Rename to regs_info_arm.
10091 (arm_regs_info): Return regs_info_aarch32 if
10092 have_ptrace_getregset is 1 and target description is
10093 arm_with_neon or arm_with_vfpv3.
10094 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10095 Call initialize_low_arch_aarch32 instead.
10096
ded48a5e
YQ
100972015-08-04 Yao Qi <yao.qi@linaro.org>
10098
10099 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10100 * linux-low.c: ... here.
10101 * linux-low.h (have_ptrace_getregset): Declare it.
10102
96e9210f
PA
101032015-08-04 Pedro Alves <palves@redhat.com>
10104
10105 * thread-db.c (struct thread_db): Use new typedefs.
10106 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10107 CHK calls.
10108 (disable_thread_event_reporting): Cast result of dlsym to
10109 destination function pointer type.
10110 (thread_db_mourn): Use td_ta_delete_ftype.
10111
af60a1ef
SL
101122015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10113
10114 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10115 arch variant.
10116 (CDX_BREAKPOINT): Define for R2.
10117 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10118 (the_low_target): Add comments.
10119
e8b41681
YQ
101202015-07-30 Yao Qi <yao.qi@linaro.org>
10121
10122 * linux-arm-low.c (arm_hwcap): Remove it.
10123 (arm_read_description): New local variable arm_hwcap. Don't
10124 set arm_hwcap to zero.
10125
89abb039
YQ
101262015-07-30 Yao Qi <yao.qi@linaro.org>
10127
10128 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10129 Use regcache->tdesc instead.
10130 (arm_store_wmmxregset): Likewise.
10131 (arm_fill_vfpregset): Likewise.
10132 (arm_store_vfpregset): Likewise.
10133
deca266c
YQ
101342015-07-30 Yao Qi <yao.qi@linaro.org>
10135
10136 * linux-arm-low.c: Include arch/arm.h.
10137 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10138 (arm_store_gregset): Likewise.
10139
aa58a496
SM
101402015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10141
10142 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10143 ptrace's 4th parameter.
10144
50904b25
YQ
101452015-07-27 Yao Qi <yao.qi@linaro.org>
10146
10147 * configure.srv (case aarch64*-*-linux*): Don't set
10148 srv_linux_usrregs.
10149
5826e159
PA
101502015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10151
10152 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10153 sys/ptrace.h.
10154 * linux-arm-low.c: Likewise.
10155 * linux-cris-low.c: Likewise.
10156 * linux-crisv32-low.c: Likewise.
10157 * linux-low.c: Likewise.
10158 * linux-m68k-low.c: Likewise.
10159 * linux-mips-low.c: Likewise.
10160 * linux-nios2-low.c: Likewise.
10161 * linux-s390-low.c: Likewise.
10162 * linux-sparc-low.c: Likewise.
10163 * linux-tic6x-low.c: Likewise.
10164 * linux-tile-low.c: Likewise.
10165 * linux-x86-low.c: Likewise.
10166
54019719
PA
101672015-07-24 Pedro Alves <palves@redhat.com>
10168
10169 * config.in: Regenerate.
10170 * configure: Regenerate.
10171
eb7aa561
PA
101722015-07-24 Pedro Alves <palves@redhat.com>
10173
10174 * acinclude.m4: Include ../ptrace.m4.
10175 * configure.ac: Call GDB_AC_PTRACE.
10176 * config.in, configure: Regenerate.
10177
55d7b841
YQ
101782015-07-24 Yao Qi <yao.qi@linaro.org>
10179
10180 * linux-low.c (linux_create_inferior): Remove setting to
10181 proc->priv->new_inferior.
10182 (linux_attach): Likewise.
10183 (linux_low_filter_event): Likewise.
10184 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10185
c06cbd92
YQ
101862015-07-24 Yao Qi <yao.qi@linaro.org>
10187
10188 * linux-low.c (linux_arch_setup): New function.
10189 (linux_low_filter_event): If proc->tdesc is NULL and
10190 proc->attached is true, call the_low_target.arch_setup.
10191 Otherwise, keep status pending, and return.
10192 (linux_resume_one_lwp_throw): Don't call get_pc if
10193 thread->while_stepping isn't NULL. Don't call
10194 get_thread_regcache if proc->tdesc is NULL.
10195 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10196 (linux_target_ops): Install arch_setup.
10197 * server.c (start_inferior): Call the_target->arch_setup.
10198 * target.h (struct target_ops) <arch_setup>: New field.
10199 (target_arch_setup): New marco.
10200 * lynx-low.c (lynx_target_ops): Update.
10201 * nto-low.c (nto_target_ops): Update.
10202 * spu-low.c (spu_target_ops): Update.
10203 * win32-low.c (win32_target_ops): Update.
10204
5ae3ebba
YQ
102052015-07-24 Yao Qi <yao.qi@linaro.org>
10206
10207 * linux-low.c (linux_add_process): Don't set
10208 proc->priv->new_inferior.
10209 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10210 (linux_attach): Likewise.
10211
eb97750b
YQ
102122015-07-24 Yao Qi <yao.qi@linaro.org>
10213
10214 * server.c (start_inferior): Code refactor.
10215
51aee833
YQ
102162015-07-24 Yao Qi <yao.qi@linaro.org>
10217
10218 * server.c (process_serial_event): Set general_thread.
10219
af1b22f3
YQ
102202015-07-21 Yao Qi <yao.qi@linaro.org>
10221
10222 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10223 aarch64_linux_get_debug_reg_capacity.
10224
554717a3
YQ
102252015-07-17 Yao Qi <yao.qi@linaro.org>
10226
10227 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10228 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10229 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10230 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10231 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10232 (AARCH64_HWP_ALIGNMENT): Likewise.
10233 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10234 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10235 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10236 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10237 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10238 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10239 (struct aarch64_debug_reg_state): Likewise.
10240 (struct arch_lwp_info): Likewise.
10241 (aarch64_align_watchpoint): Likewise.
10242 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10243 (aarch64_watchpoint_length): Likewise.
10244 (aarch64_point_encode_ctrl_reg): Likewise
10245 (aarch64_point_is_aligned): Likewise.
10246 (aarch64_align_watchpoint): Likewise.
10247 (aarch64_linux_set_debug_regs):
10248 (aarch64_dr_state_insert_one_point): Likewise.
10249 (aarch64_dr_state_remove_one_point): Likewise.
10250 (aarch64_handle_breakpoint): Likewise.
10251 (aarch64_handle_aligned_watchpoint): Likewise.
10252 (aarch64_handle_unaligned_watchpoint): Likewise.
10253 (aarch64_handle_watchpoint): Likewise.
10254
c67ca4de
YQ
102552015-07-17 Yao Qi <yao.qi@linaro.org>
10256
10257 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10258 and don't aarch64_get_debug_reg_state. All callers update.
10259 (aarch64_handle_aligned_watchpoint): Likewise.
10260 (aarch64_handle_unaligned_watchpoint): Likewise.
10261 (aarch64_handle_watchpoint): Likewise.
10262 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10263 (aarch64_remove_point): Likewise.
10264
25abf979
YQ
102652015-07-17 Yao Qi <yao.qi@linaro.org>
10266
10267 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10268 debug_printf.
10269 (aarch64_handle_unaligned_watchpoint): Likewise.
10270
db1ff28b
JK
102712015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10272
10273 Revert the previous 3 commits:
10274 Move gdb_regex* to common/
10275 Move linux_find_memory_regions_full & co.
10276 gdbserver build-id attribute generator
10277
700ca40f
JK
102782015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10279 Jan Kratochvil <jan.kratochvil@redhat.com>
10280
10281 gdbserver build-id attribute generator.
10282 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10283 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10284 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10285 (find_phdr): New.
10286 (get_dynamic): Use find_pdhr to traverse program headers.
10287 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10288 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10289 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10290 (get_hex_build_id): New.
10291 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10292 to reply XML document.
10293
9904185c
JK
102942015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10295 Jan Kratochvil <jan.kratochvil@redhat.com>
10296
10297 * target.c: Include target/target-utils.h and fcntl.h.
10298 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10299 (target_fileio_read_stralloc): New functions.
10300
6e5b4429
JK
103012015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10302
10303 * Makefile.in (OBS): Add gdb_regex.o.
10304 (gdb_regex.o): New.
10305 * config.in: Rebuilt.
10306 * configure: Rebuilt.
10307
ddc98fbf
JK
103082015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10309 Jan Kratochvil <jan.kratochvil@redhat.com>
10310
10311 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10312 * Makefile.in (OBS): Add target-utils.o.
10313 (linux-maps.o, target-utils.o): New.
10314 * configure.srv (srv_linux_obj): Add linux-maps.o.
10315
e57bb7a0
PL
103162015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10317
10318 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10319 function, return 1.
10320 (the_low_target): Install it.
10321
586b02a9
PA
103222015-07-14 Pedro Alves <palves@redhat.com>
10323
10324 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10325 Instead, ignore ECHILD, and throw an error for other errnos.
10326
58c1b36c
PA
103272015-07-10 Pedro Alves <palves@redhat.com>
10328
10329 * event-loop.c (struct callback_event) <data>: Change type to
10330 gdb_client_data instance instead of gdb_client_data pointer.
10331 (append_callback_event): Adjust.
10332
421530db
PL
103332015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10334
10335 * linux-aarch64-low.c: Add comments for each linux_target_ops
10336 method. Remove comments already covered in target_ops and
10337 linux_target_ops definitions.
10338 (the_low_target): Add comments for each unimplemented method.
10339
c2d65f38
YQ
103402015-07-09 Yao Qi <yao.qi@linaro.org>
10341
10342 * linux-aarch64-low.c (aarch64_regmap): Remove.
10343 (aarch64_usrregs_info): Remove.
10344 (regs_info): Set field usrregs to NULL.
10345
b20a6524
MM
103462015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10347
10348 * linux-low.c: Include "rsp-low.h"
10349 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10350 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10351 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10352 (handle_btrace_enable_pt): New.
10353 (handle_btrace_general_set): Support "pt".
10354 (handle_btrace_conf_general_set): Support "pt:size".
10355
96c97461
PL
103562015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10357
10358 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10359 Z_PACKET_SW_BP.
10360
37d66942
PL
103612015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10362
10363 * linux-aarch64-low.c: Remove comment about endianness.
10364 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10365 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10366 memcmp.
10367
dc06243f
GB
103682015-06-24 Gary Benson <gbenson@redhat.com>
10369
10370 * linux-i386-ipa.c (stdint.h): Do not include.
10371 * lynx-i386-low.c (stdint.h): Likewise.
10372 * lynx-ppc-low.c (stdint.h): Likewise.
10373 * mem-break.c (stdint.h): Likewise.
10374 * thread-db.c (stdint.h): Likewise.
10375 * tracepoint.c (stdint.h): Likewise.
10376 * win32-low.c (stdint.h): Likewise.
10377
124e13d9
SM
103782015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10379
10380 * server.c (write_qxfer_response): Update call to
10381 remote_escape_output.
10382
909c2cda
JK
103832015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10384 Jan Kratochvil <jan.kratochvil@redhat.com>
10385
10386 Merge multiple hex conversions.
10387 * gdbreplay.c (tohex): Rename to 'fromhex'.
10388 (logchar): Use fromhex.
10389
24c05f46
JK
103902015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10391
10392 * server.c (handle_qxfer_libraries): Set `version' attribute for
10393 <library-list>.
10394
14d2069a
GB
103952015-06-10 Gary Benson <gbenson@redhat.com>
10396
10397 * target.h (struct target_ops) <multifs_open>: New field.
10398 <multifs_unlink>: Likewise.
10399 <multifs_readlink>: Likewise.
10400 * linux-low.c (nat/linux-namespaces.h): New include.
10401 (linux_target_ops): Initialize the_target->multifs_open,
10402 the_target->multifs_unlink and the_target->multifs_readlink.
10403 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10404 * hostio.c (hostio_fs_pid): New static variable.
10405 (hostio_handle_new_gdb_connection): New function.
10406 (handle_setfs): Likewise.
10407 (handle_open): Use the_target->multifs_open as appropriate.
10408 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10409 (handle_readlink): Use the_target->multifs_readlink as
10410 appropriate.
10411 (handle_vFile): Handle vFile:setfs packets.
10412 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10413 after target_handle_new_gdb_connection.
10414
4b8b5e72
GB
104152015-06-10 Gary Benson <gbenson@redhat.com>
10416
10417 * configure.ac (AC_CHECK_FUNCS): Add setns.
10418 * config.in: Regenerate.
10419 * configure: Likewise.
10420 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10421 (linux-namespaces.o): New rule.
10422 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10423
3ac2e371
GB
104242015-06-09 Gary Benson <gbenson@redhat.com>
10425
10426 * hostio.c (handle_open): Process mode argument with
10427 fileio_to_host_mode.
10428
ca9b78ce
YQ
104292015-06-01 Yao Qi <yao.qi@linaro.org>
10430
10431 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10432 * linux-x86-low.c: Likewise.
10433
bfacd19d
DB
104342015-05-28 Don Breazeal <donb@codesourcery.com>
10435
10436 * linux-low.c (handle_extended_wait): Initialize
10437 thread_info.last_resume_kind for new fork children.
10438
452003ef
PA
104392015-05-15 Pedro Alves <palves@redhat.com>
10440
10441 * target.h (target_handle_new_gdb_connection): Rewrite using if
10442 wrapped in do/while.
10443
1041a03c
JB
104442015-05-14 Joel Brobecker <brobecker@adacore.com>
10445
10446 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10447 * configure, config.in: Regenerate.
10448 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10449 Declare typedef.
10450
c269dbdb
DB
104512015-05-12 Don Breazeal <donb@codesourcery.com>
10452
10453 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10454 PTRACE_EVENT_VFORK_DONE.
10455 (linux_low_ptrace_options, extended_event_reported): Add vfork
10456 events.
10457 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10458 and "vforkdone" for RSP 'T' Stop Reply Packet.
10459 * server.h (report_vfork_events): Declare
10460 global variable.
10461
3a8a0396
DB
104622015-05-12 Don Breazeal <donb@codesourcery.com>
10463
10464 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10465 (the_low_target) <new_fork>: Initialize new member.
10466 * linux-arm-low.c (arm_new_fork): New function.
10467 (the_low_target) <new_fork>: Initialize new member.
10468 * linux-low.c (handle_extended_wait): Call new target function
10469 new_fork.
10470 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10471 * linux-mips-low.c (mips_add_watchpoint): New function
10472 extracted from mips_insert_point.
10473 (the_low_target) <new_fork>: Initialize new member.
10474 (mips_linux_new_fork): New function.
10475 (mips_insert_point): Call mips_add_watchpoint.
10476 * linux-x86-low.c (x86_linux_new_fork): New function.
10477 (the_low_target) <new_fork>: Initialize new member.
10478
de0d863e
DB
104792015-05-12 Don Breazeal <donb@codesourcery.com>
10480
10481 * linux-low.c (handle_extended_wait): Implement return value,
10482 rename argument 'event_child' to 'event_lwp', handle
10483 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10484 (linux_low_ptrace_options): New function.
10485 (linux_low_filter_event): Call linux_low_ptrace_options,
10486 use different argument fo linux_enable_event_reporting,
10487 use return value from handle_extended_wait.
10488 (extended_event_reported): New function.
10489 (linux_wait_1): Call extended_event_reported and set
10490 status to report fork events.
10491 (linux_write_memory): Add pid to debug message.
10492 (reset_lwp_ptrace_options_callback): New function.
10493 (linux_handle_new_gdb_connection): New function.
10494 (linux_target_ops): Initialize new structure member.
10495 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10496 * lynx-low.c: Initialize new structure member.
10497 * remote-utils.c (prepare_resume_reply): Implement stop reason
10498 "fork" for "T" stop message.
10499 * server.c (handle_query): Call handle_new_gdb_connection.
10500 * server.h (report_fork_events): Declare global flag.
10501 * target.h (struct target_ops) <handle_new_gdb_connection>:
10502 New member.
10503 (target_handle_new_gdb_connection): New macro.
10504 * win32-low.c: Initialize new structure member.
10505
ddcbc397
DB
105062015-05-12 Don Breazeal <donb@codesourcery.com>
10507
10508 * mem-break.c (APPEND_TO_LIST): Define macro.
10509 (clone_agent_expr): New function.
10510 (clone_one_breakpoint): New function.
10511 (clone_all_breakpoints): New function.
10512 * mem-break.h: Declare new functions.
10513
89245bc0
DB
105142015-05-12 Don Breazeal <donb@codesourcery.com>
10515
10516 * linux-low.c (linux_supports_fork_events): New function.
10517 (linux_supports_vfork_events): New function.
10518 (linux_target_ops): Initialize new structure members.
10519 (initialize_low): Call linux_check_ptrace_features.
10520 * lynx-low.c (lynx_target_ops): Initialize new structure
10521 members.
10522 * server.c (report_fork_events, report_vfork_events):
10523 New global flags.
10524 (handle_query): Add new features to qSupported packet and
10525 response.
10526 (captured_main): Initialize new global variables.
10527 * target.h (struct target_ops) <supports_fork_events>:
10528 New member.
10529 <supports_vfork_events>: New member.
10530 (target_supports_fork_events): New macro.
10531 (target_supports_vfork_events): New macro.
10532 * win32-low.c (win32_target_ops): Initialize new structure
10533 members.
10534
835205d0
GB
105352015-05-12 Gary Benson <gbenson@redhat.com>
10536
10537 * server.c (handle_qxfer_exec_file): Use current process
10538 if annex is empty.
10539
21e94bd9
SL
105402015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10541
10542 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10543 Remove HAVE_PTRACE_GETREGS conditionals.
10544 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10545 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10546
45614f15
YQ
105472015-05-08 Yao Qi <yao.qi@linaro.org>
10548
10549 * linux-low.c (linux_supports_conditional_breakpoints): New
10550 function.
10551 (linux_target_ops): Install new target method.
10552 * lynx-low.c (lynx_target_ops): Install NULL hook for
10553 supports_conditional_breakpoints.
10554 * nto-low.c (nto_target_ops): Likewise.
10555 * spu-low.c (spu_target_ops): Likewise.
10556 * win32-low.c (win32_target_ops): Likewise.
10557 * server.c (handle_query): Check
10558 target_supports_conditional_breakpoints.
10559 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10560 New field.
10561 (target_supports_conditional_breakpoints): New macro.
10562
80ad801e
PA
105632015-05-06 Pedro Alves <palves@redhat.com>
10564
10565 PR server/18081
10566 * server.c (start_inferior): If the process exits, mourn it.
10567
819843c7
GB
105682015-04-21 Gary Benson <gbenson@redhat.com>
10569
10570 * hostio.c (fileio_open_flags_to_host): Factored out to
10571 fileio_to_host_openflags in common/fileio.c. Single use
10572 updated.
10573
a2d5a9d7
MF
105742015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10575
10576 * linux-xtensa-low.c (xtensa_fill_gregset)
10577 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10578 XCHAL_HAVE_LOOP.
10579
deb44829
MF
105802015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10581
10582 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10583 (regs_info): Replace usrregs pointer with NULL.
10584
e57f1de3
GB
105852015-04-17 Gary Benson <gbenson@redhat.com>
10586
10587 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10588 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10589 * server.c (handle_qxfer_exec_file): New function.
10590 (qxfer_packets): Add exec-file entry.
10591 (handle_query): Report qXfer:exec-file:read as supported packet.
10592
62828379
RN
105932015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10594
10595 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10596
b88bb450
GB
105972015-04-09 Gary Benson <gbenson@redhat.com>
10598
10599 * hostio-errno.c (errno_to_fileio_error): Remove function.
10600 Update caller to use remote_fileio_to_fio_error.
10601
c8f4bfdd
YQ
106022015-04-09 Yao Qi <yao.qi@linaro.org>
10603
10604 * linux-low.c (linux_insert_point): Call
10605 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10606 (linux_remove_point): Call remove_memory_breakpoint if type is
10607 raw_bkpt_type_sw.
10608 * linux-x86-low.c (x86_insert_point): Don't call
10609 insert_memory_breakpoint.
10610 (x86_remove_point): Don't call remove_memory_breakpoint.
10611
41f98f02
PA
106122015-04-01 Pedro Alves <palves@redhat.com>
10613 Cleber Rosa <crosa@redhat.com>
10614
10615 * server.c (gdbserver_usage): Reorganize and extend the usage
10616 message.
10617
2bf6fb9d
PA
106182015-03-24 Pedro Alves <palves@redhat.com>
10619
10620 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10621 output. Also dump TRAP_TRACE.
10622 (linux_low_filter_event): In debug output, distinguish a
10623 resume_stop SIGSTOP from a delayed SIGSTOP.
10624
369f6daa
GB
106252015-03-24 Gary Benson <gbenson@redhat.com>
10626
10627 * linux-x86-low.c (x86_linux_new_thread): Moved to
10628 nat/x86-linux.c.
10629 (x86_linux_prepare_to_resume): Likewise.
10630
8e5d4070
GB
106312015-03-24 Gary Benson <gbenson@redhat.com>
10632
10633 * Makefile.in (x86-linux-dregs.o): New rule.
10634 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10635 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10636 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10637 (x86_linux_dr_get): Likewise.
10638 (x86_linux_dr_set): Likewise.
10639 (update_debug_registers_callback): Likewise.
10640 (x86_linux_dr_set_addr): Likewise.
10641 (x86_linux_dr_get_addr): Likewise.
10642 (x86_linux_dr_set_control): Likewise.
10643 (x86_linux_dr_get_control): Likewise.
10644 (x86_linux_dr_get_status): Likewise.
10645 (x86_linux_update_debug_registers): Likewise.
10646
2b95d440
GB
106472015-03-24 Gary Benson <gbenson@redhat.com>
10648
10649 * linux-x86-low.c (x86_linux_update_debug_registers):
10650 New function, factored out from...
10651 (x86_linux_prepare_to_resume): ...this.
10652
14b0bc68
GB
106532015-03-24 Gary Benson <gbenson@redhat.com>
10654
10655 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10656 (x86_linux_dr_set): Likewise.
10657 (update_debug_registers_callback): Likewise.
10658 (x86_linux_dr_set_addr): Likewise.
10659 (x86_linux_dr_get_addr): Likewise.
10660 (x86_linux_dr_set_control): Likewise.
10661 (x86_linux_dr_get_control): Likewise.
10662 (x86_linux_dr_get_status): Likewise.
10663 (x86_linux_prepare_to_resume): Likewise.
10664
5dfe6ca8
GB
106652015-03-24 Gary Benson <gbenson@redhat.com>
10666
10667 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10668 Use perror_with_name. Pass string through gettext.
10669 (x86_linux_dr_set): Likewise.
10670
d33472ad
GB
106712015-03-24 Gary Benson <gbenson@redhat.com>
10672
10673 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10674 (x86_linux_dr_set_addr): ...this.
10675 (x86_dr_low_get_addr): Rename to...
10676 (x86_linux_dr_get_addr): ...this.
10677 (x86_dr_low_set_control): Rename to...
10678 (x86_linux_dr_set_control): ...this.
10679 (x86_dr_low_get_control): Rename to...
10680 (x86_linux_dr_get_control): ...this.
10681 (x86_dr_low_get_status): Rename to...
10682 (x86_linux_dr_get_status): ...this.
10683 (x86_dr_low): Update with new function names.
10684
4b134ca1
GB
106852015-03-24 Gary Benson <gbenson@redhat.com>
10686
10687 * Makefile.in (x86-linux.o): New rule.
10688 * configure.srv: Add x86-linux.o to relevant targets.
10689 * linux-low.c (lwp_set_arch_private_info): New function.
10690 (lwp_arch_private_info): Likewise.
10691 * linux-x86-low.c: Include nat/x86-linux.h.
10692 (arch_lwp_info): Removed structure.
10693 (update_debug_registers_callback):
10694 Use lwp_set_debug_registers_changed.
10695 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10696 and lwp_set_debug_registers_changed.
10697 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10698
34c703da
GB
106992015-03-24 Gary Benson <gbenson@redhat.com>
10700
10701 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10702 * linux-arm-low.c (arm_new_thread): Likewise.
10703 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10704 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10705 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10706 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10707
cff068da
GB
107082015-03-24 Gary Benson <gbenson@redhat.com>
10709
10710 * linux-low.c (ptid_of_lwp): New function.
10711 (lwp_is_stopped): Likewise.
10712 (lwp_stop_reason): Likewise.
10713 * linux-x86-low.c (update_debug_registers_callback):
10714 Use lwp_is_stopped.
10715 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10716 lwp_stop_reason.
10717
b2f7c7e8
GB
107182015-03-24 Gary Benson <gbenson@redhat.com>
10719
10720 * linux-low.h (linux_stop_lwp): Remove declaration.
10721
6d4ee8c6
GB
107222015-03-24 Gary Benson <gbenson@redhat.com>
10723
10724 * linux-low.h: Include nat/linux-nat.h.
10725 * linux-low.c (iterate_over_lwps_args): New structure.
10726 (iterate_over_lwps_filter): New function.
10727 (iterate_over_lwps): Likewise.
10728 * linux-x86-low.c (update_debug_registers_callback):
10729 Update signature to what iterate_over_lwps expects.
10730 Remove PID check that iterate_over_lwps now performs.
10731 (x86_dr_low_set_addr): Use iterate_over_lwps.
10732 (x86_dr_low_set_control): Likewise.
10733
70a0bb6b
GB
107342015-03-24 Gary Benson <gbenson@redhat.com>
10735
10736 * linux-x86-low.c (x86_debug_reg_state): New function.
10737 (x86_linux_prepare_to_resume): Use the above.
10738
7b669087
GB
107392015-03-24 Gary Benson <gbenson@redhat.com>
10740
10741 * linux-low.c (current_lwp_ptid): New function.
10742 * linux-x86-low.c: Include nat/linux-nat.h.
10743 (x86_dr_low_get_addr): Use current_lwp_ptid.
10744 (x86_dr_low_get_control): Likewise.
10745 (x86_dr_low_get_status): Likewise.
10746
eef49a3d
PA
107472015-03-20 Pedro Alves <palves@redhat.com>
10748
10749 * tracepoint.c (cmd_qtstatus): Make "str" const.
10750
b2333d22
PA
107512015-03-20 Pedro Alves <palves@redhat.com>
10752
10753 * server.c (handle_general_set): Make "req_str" const.
10754
23f238d3
PA
107552015-03-19 Pedro Alves <palves@redhat.com>
10756
10757 * linux-low.c (linux_resume_one_lwp): Rename to ...
10758 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
10759 instead call perror_with_name.
10760 (check_ptrace_stopped_lwp_gone): New function.
10761 (linux_resume_one_lwp): Reimplement as wrapper around
10762 linux_resume_one_lwp_throw that swallows errors if the LWP is
10763 gone.
10764
91baf43f
PA
107652015-03-19 Pedro Alves <palves@redhat.com>
10766
10767 * linux-low.c (count_events_callback, select_event_lwp_callback):
10768 No longer check whether the thread has resume_stop as last resume
10769 kind.
10770
8bf3b159
PA
107712015-03-19 Pedro Alves <palves@redhat.com>
10772
10773 * linux-low.c (count_events_callback, select_event_lwp_callback):
10774 Use the lwp's status_pending_p field, not the thread's.
10775
b90fc188
PA
107762015-03-19 Pedro Alves <palves@redhat.com>
10777
10778 * linux-low.c (select_event_lwp_callback): Update comments to
10779 no longer mention SIGTRAP.
10780
464b0089
GB
107812015-03-18 Gary Benson <gbenson@redhat.com>
10782
10783 * server.c (handle_query): Do not report vFile:fstat as supported.
10784
aa9e327f
GB
107852015-03-11 Gary Benson <gbenson@redhat.com>
10786
10787 * hostio.c (sys/types.h): New include.
10788 (sys/stat.h): Likewise.
10789 (common-remote-fileio.h): Likewise.
10790 (handle_fstat): New function.
10791 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 10792
791c0056
GB
107932015-03-11 Gary Benson <gbenson@redhat.com>
10794
10795 * configure.ac (AC_CHECK_MEMBERS): Add checks for
10796 struct stat.st_blocks and struct stat.st_blksize.
10797 * configure: Regenerate.
10798 * config.in: Likewise.
10799 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
10800 (OBS): Add common-remote-fileio.o.
10801 (common-remote-fileio.o): New rule.
10802
9a9df970
PA
108032015-03-09 Pedro Alves <palves@redhat.com>
10804
10805 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
10806 'struct sockaddr' pointer in 'accept' call.
10807
9eb1356e
PA
108082015-03-09 Pedro Alves <palves@redhat.com>
10809
10810 Revert:
10811 2015-03-07 Pedro Alves <palves@redhat.com>
10812 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
10813 or <winsock2.h> here. Instead include "gdb_socket.h".
10814 (remote_open): Use union gdb_sockaddr_u.
10815 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
10816 or <winsock2.h> here. Instead include "gdb_socket.h".
10817 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
10818 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
10819 or <sys/un.h>.
10820 (init_named_socket, gdb_agent_helper_thread): Use union
10821 gdb_sockaddr_u.
10822
aac331e4
PA
108232015-03-07 Pedro Alves <palves@redhat.com>
10824
10825 * configure.ac (build_warnings): Move
10826 -Wdeclaration-after-statement to the C-specific set.
10827 * configure: Regenerate.
10828
366c75fc
PA
108292015-03-07 Pedro Alves <palves@redhat.com>
10830
10831 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
10832 or <winsock2.h> here. Instead include "gdb_socket.h".
10833 (remote_open): Use union gdb_sockaddr_u.
10834 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
10835 or <winsock2.h> here. Instead include "gdb_socket.h".
10836 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
10837 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
10838 or <sys/un.h>.
10839 (init_named_socket, gdb_agent_helper_thread): Use union
10840 gdb_sockaddr_u.
10841
492d29ea
PA
108422015-03-07 Pedro Alves <palves@redhat.com>
10843
10844 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
10845 instead.
10846
60a191ed
YQ
108472015-03-06 Yao Qi <yao.qi@linaro.org>
10848
10849 * linux-aarch64-low.c (aarch64_insert_point): Use
10850 show_debug_regs as a boolean.
10851 (aarch64_remove_point): Likewise.
10852
f5771b1d
PA
108532015-03-05 Pedro Alves <palves@redhat.com>
10854
10855 * lynx-low.c (lynx_target_ops): Install NULL hooks for
10856 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
10857 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
10858 * nto-low.c (nto_target_ops): Likewise.
10859 * spu-low.c (spu_target_ops): Likewise.
10860 * win32-low.c (win32_target_ops): Likewise.
10861
3e572f71
PA
108622015-03-04 Pedro Alves <palves@redhat.com>
10863
72f4393d 10864 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
10865 Decide whether a breakpoint triggered based on the SIGTRAP's
10866 siginfo.si_code.
72f4393d
L
10867 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
10868 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
10869 (linux_low_filter_event): Check for breakpoints before checking
10870 watchpoints.
10871 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
10872 siginfo.si_code.
72f4393d
L
10873 (linux_stopped_by_sw_breakpoint)
10874 (linux_supports_stopped_by_sw_breakpoint)
10875 (linux_stopped_by_hw_breakpoint)
10876 (linux_supports_stopped_by_hw_breakpoint): New functions.
10877 (linux_target_ops): Install new target methods.
3e572f71 10878
1ec68e26
PA
108792015-03-04 Pedro Alves <palves@redhat.com>
10880
10881 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
10882 * server.c (swbreak_feature, hwbreak_feature): New globals.
10883 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
10884 (captured_main): Clear swbreak_feature and hwbreak_feature.
10885 * server.h (swbreak_feature, hwbreak_feature): Declare.
10886 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
10887 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
10888 supports_stopped_by_hw_breakpoint>: New fields.
10889 (target_supports_stopped_by_sw_breakpoint)
10890 (target_stopped_by_sw_breakpoint)
10891 (target_supports_stopped_by_hw_breakpoint)
10892 (target_stopped_by_hw_breakpoint): Declare.
10893
15c66dd6
PA
108942015-03-04 Pedro Alves <palves@redhat.com>
10895
10896 enum lwp_stop_reason -> enum target_stop_reason
10897 * linux-low.c (check_stopped_by_breakpoint): Adjust.
10898 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
10899 (linux_wait_1, stuck_in_jump_pad_callback)
10900 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
10901 (linux_stopped_by_watchpoint):
10902 * linux-low.h (enum lwp_stop_reason): Delete.
10903 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
10904 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
10905
98fc70d6
YQ
109062015-03-04 Yao Qi <yao.qi@linaro.org>
10907
10908 * Makefile.in (SFILES): Add linux-aarch64-low.c.
10909
dd2ac174
GB
109102015-03-03 Gary Benson <gbenson@redhat.com>
10911
10912 * hostio.c (handle_vFile): Fix prefix lengths.
10913
d68e53f4
MM
109142015-03-03 Markus Metzger <markus.t.metzger@intel.com>
10915
10916 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
10917 ptr_bits.
10918
bf2d68ab
AA
109192015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
10920
10921 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
10922 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
10923 (clean): Add "rm -f" for above C files.
10924 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
10925 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
10926 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
10927 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
10928 * linux-s390-low.c (HWCAP_S390_VX): New macro.
10929 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
10930 (init_registers_s390x_vx_linux64)
10931 (init_registers_s390x_tevx_linux64)
10932 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
10933 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
10934 declarations.
10935 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
10936 (s390_store_vxrs_high): New functions.
10937 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
10938 NT_S390_VXRS_HIGH.
10939 (s390_arch_setup): Add logic for selecting one of the new target
10940 descriptions. Activate the new vector regsets if applicable.
10941 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
10942 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
10943 and init_registers_s390x_tevx_linux64.
10944
c966a859
PA
109452015-03-01 Pedro Alves <palves@redhat.com>
10946
10947 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
10948 parameter.
10949
4180215b
PA
109502015-02-27 Pedro Alves <palves@redhat.com>
10951
10952 * linux-x86-low.c (u_debugreg_offset): New function.
10953 (x86_linux_dr_get, x86_linux_dr_set): Use it.
10954
749bab01
PA
109552015-02-27 Pedro Alves <palves@redhat.com>
10956
10957 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
10958 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
10959 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
10960 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
10961 (ps_lsetfpregs, ps_getpid)
10962 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
10963 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
10964 (ps_lsetxregs, ps_plog): Declare.
10965
3c14e5a3
PA
109662015-02-27 Pedro Alves <palves@redhat.com>
10967
10968 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
10969 IP_AGENT_EXPORT_FUNC.
10970 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
10971 IP_AGENT_EXPORT_FUNC.
10972 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
10973 (IP_AGENT_EXPORT): Delete.
10974 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10975 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
10976 (gdb_trampoline_buffer_error, collecting, gdb_collect)
10977 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
10978 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
10979 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
10980 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
10981 (traceframe_read_count, traceframe_write_count)
10982 (traceframes_created, trace_state_variables, get_raw_reg)
10983 (get_trace_state_variable_value, set_trace_state_variable_value)
10984 (ust_loaded, helper_thread_id, cmd_buf): Use
10985 IPA_SYM_EXPORTED_NAME.
10986 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
10987 (tracepoints) Use IP_AGENT_EXPORT_VAR.
10988 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
10989 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10990 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
10991 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
10992 EXTERN_C_PUSH/EXTERN_C_POP.
10993 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
10994 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
10995 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10996 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
10997 (traceframe_write_count, traceframe_read_count)
10998 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
10999 (about_to_request_buffer_space, get_trace_state_variable_value)
11000 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11001 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11002 EXTERN_C_PUSH/EXTERN_C_POP.
11003 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11004 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11005 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11006 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11007 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11008 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11009 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11010 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11011 Define.
11012 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11013 (IP_AGENT_EXPORT_VAR_DECL): Define.
11014 (tracing): Declare.
11015 (gdb_agent_get_raw_reg): Declare.
11016
fe978cb0
PA
110172015-02-27 Tom Tromey <tromey@redhat.com>
11018 Pedro Alves <palves@redhat.com>
11019
11020 Rename symbols whose names are reserved C++ keywords throughout.
11021
3bc3d82a
PA
110222015-02-27 Pedro Alves <palves@redhat.com>
11023
11024 * Makefile.in (COMPILER): New, get it from autoconf.
11025 (CXX): Get from autoconf instead.
11026 (COMPILE.pre): Use COMPILER.
11027 (CC-LD): Rename to ...
11028 (CC_LD): ... this. Use COMPILER.
11029 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11030 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11031 * acinclude.m4: Include build-with-cxx.m4.
11032 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11033 Disable -Werror by default if building in C++ mode.
11034 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11035 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11036 the C++ compiler. Save/restore CXXFLAGS too.
11037 * configure: Regenerate.
11038
07697489
PA
110392015-02-27 Pedro Alves <palves@redhat.com>
11040
11041 * acinclude.m4: Include libiberty.m4.
11042 * configure.ac: Call libiberty_INIT.
11043 * config.in, configure: Regenerate.
11044
9beb7c4e
PA
110452015-02-26 Pedro Alves <palves@redhat.com>
11046
11047 * linux-low.c (linux_wait_1): When incrementing the PC past a
11048 program breakpoint always use the_low_target.breakpoint_len as
11049 increment, rather than the maximum between that and
11050 the_low_target.decr_pc_after_break.
11051
8090aef2
PA
110522015-02-23 Pedro Alves <palves@redhat.com>
11053
11054 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11055 thread was doing a step-over; always adjust the PC if
11056 we stepped over a permanent breakpoint.
11057 (linux_wait_1): If we stepped over breakpoint that was on top of a
11058 permanent breakpoint, manually advance the PC past it.
11059
bc9540e8
PA
110602015-02-23 Pedro Alves <palves@redhat.com>
11061
11062 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11063 modes.
11064 (x86_fill_gregset, x86_store_gregset): Use it when handling
11065 $orig_eax.
11066
2db9a427
PA
110672015-02-20 Pedro Alves <palves@redhat.com>
11068
11069 * thread-db.c: Include "nat/linux-procfs.h".
11070 (thread_db_init): Skip listing new threads if the kernel supports
11071 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11072
afa8d396
PA
110732015-02-20 Pedro Alves <palves@redhat.com>
11074
11075 * linux-low.c (status_pending_p_callback): Use ptid_match.
11076
c9587f88
AT
110772015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11078
11079 PR breakpoints/16812
11080 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11081 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11082 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11083
b05ec7a5
AT
110842015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11085
11086 PR breakpoints/15956
11087 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11088
d33501a5
MM
110892015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11090
11091 * linux-low.c (linux_low_btrace_conf): Print size.
11092 * server.c (handle_btrace_conf_general_set): New.
11093 (hanle_general_set): Call handle_btrace_conf_general_set.
11094 (handle_query): Report Qbtrace-conf:bts:size as supported.
11095
f4abbc16
MM
110962015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11097
11098 * linux-low.c (linux_low_enable_btrace): Update parameters.
11099 (linux_low_btrace_conf): New.
11100 (linux_target_ops)<to_btrace_conf>: Initialize.
11101 * server.c (current_btrace_conf): New.
11102 (handle_btrace_enable): Rename to ...
11103 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11104 to target_enable_btrace. Update comment. Update users.
11105 (handle_qxfer_btrace_conf): New.
11106 (qxfer_packets): Add btrace-conf entry.
11107 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11108 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11109 (target_ops)<read_btrace_conf>: New.
11110 (target_enable_btrace): Update parameters.
11111 (target_read_btrace_conf): New.
11112
043c3577
MM
111132015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11114
11115 * server.c (handle_btrace_general_set): Remove call to
11116 target_supports_btrace.
11117 (supported_btrace_packets): New.
11118 (handle_query): Call supported_btrace_packets.
11119 * target.h: include btrace-common.h.
11120 (btrace_target_info): Removed.
11121 (supports_btrace, target_supports_btrace): Update parameters.
11122
734b0e4b
MM
111232015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11124
11125 * Makefile.in (SFILES): Add common/btrace-common.c.
11126 (OBS): Add common/btrace-common.o.
11127 (btrace-common.o): Add build rules.
11128 * linux-low: Include btrace-common.h.
11129 (linux_low_read_btrace): Use struct btrace_data. Call
11130 btrace_data_init and btrace_data_fini.
11131
d6c146e9
PA
111322015-02-06 Pedro Alves <palves@redhat.com>
11133
11134 * thread-db.c (find_new_threads_callback): Add debug output.
11135
20ba1ce6
PA
111362015-02-04 Pedro Alves <palves@redhat.com>
11137
11138 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11139 (resume_stopped_resumed_lwps): New function.
11140 (linux_wait_for_event_filtered): Use it.
11141
8cc73a39
SDJ
111422015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11143
11144 * Makefile.in (SFILES): Add linux-personality.c.
11145 (linux-personality.o): New rule.
11146 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11147 list of objects to be built.
11148 * linux-low.c: Include nat/linux-personality.h.
11149 (linux_create_inferior): Remove code to disable address space
11150 randomization (moved to ../nat/linux-personality.c). Create
11151 cleanup to disable address space randomization.
11152
fb23d554
SDJ
111532015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11154
11155 * Makefile.in (posix-strerror.o): New rule.
11156 (mingw-strerror.o): Likewise.
11157 * configure: Regenerated.
11158 * configure.ac: Source file ../common/common.host. Initialize new
11159 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11160
cdf43629
YQ
111612015-01-14 Yao Qi <yao@codesourcery.com>
11162
11163 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11164 (ppc-linux.o): New rule.
11165 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11166 * configure.ac: AC_CHECK_FUNCS(getauxval).
11167 * config.in: Re-generated.
11168 * configure: Re-generated.
11169 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11170 ppc64_64bit_inferior_p
11171
514c5338
YQ
111722015-01-14 Yao Qi <yao@codesourcery.com>
11173
11174 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11175 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11176 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11177 (PT_ORIG_R3, PT_TRAP): Likewise.
11178 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11179 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11180 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11181
3368c1e5
JB
111822015-01-10 Joel Brobecker <brobecker@adacore.com>
11183
11184 * i387-fp.c (i387_cache_to_xsave): In look over
11185 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11186 zmmh_low_space field by use of zmmh_high_space.
11187
582511be
PA
111882015-01-09 Pedro Alves <palves@redhat.com>
11189
11190 * linux-low.c (step_over_bkpt): Move higher up in the file.
11191 (handle_extended_wait): Don't store the stop_pc here.
11192 (get_stop_pc): Adjust comments and rename to ...
11193 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11194 stopped for a software breakpoint or hardware breakpoint.
11195 (thread_still_has_status_pending_p): New function.
11196 (status_pending_p_callback): Use
11197 thread_still_has_status_pending_p. If the event is no longer
11198 interesting, resume the LWP.
11199 (handle_tracepoints): Add assert.
11200 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11201 (wstatus_maybe_breakpoint): New function.
11202 (cancel_breakpoint): Delete function.
11203 (check_stopped_by_watchpoint): New function, factored out from
11204 linux_low_filter_event.
11205 (lp_status_maybe_breakpoint): Delete function.
11206 (linux_low_filter_event): Remove filter_ptid argument.
11207 Leave thread group exits pending here. Store the LWP's stop PC.
11208 Always leave events pending.
11209 (linux_wait_for_event_filtered): Pull all events out of the
11210 kernel, and leave them all pending.
11211 (count_events_callback, select_event_lwp_callback): Consider all
11212 events.
11213 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11214 (select_event_lwp): Only give preference to the stepping LWP in
11215 all-stop mode. Adjust comments.
11216 (ignore_event): New function.
11217 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11218 references to cancel_breakpoints. Adjust to renames. Also give
11219 equal priority to all LWPs that have had events in non-stop mode.
11220 If reporting a software breakpoint event, unadjust the LWP's PC.
11221 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11222 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11223 Adjust.
11224 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11225 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11226 (linux_stopped_by_watchpoint): Adjust.
11227 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11228 * linux-low.h (enum lwp_stop_reason): New.
11229 (struct lwp_info) <stop_pc>: Adjust comment.
11230 <stopped_by_watchpoint>: Delete field.
11231 <stop_reason>: New field.
11232 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11233 * mem-break.c (software_breakpoint_inserted_here)
11234 (hardware_breakpoint_inserted_here): New function.
11235 * mem-break.h (software_breakpoint_inserted_here)
11236 (hardware_breakpoint_inserted_here): Declare.
11237 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11238 (cancel_breakpoints): Delete.
11239 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11240 (upload_fast_traceframes): Remove references to
11241 cancel_breakpoints.
11242
a33e3959
PA
112432015-01-09 Pedro Alves <palves@redhat.com>
11244
11245 * thread-db.c (find_new_threads_callback): Ignore thread if the
11246 kernel thread ID is -1.
11247
8784d563
PA
112482015-01-09 Pedro Alves <palves@redhat.com>
11249
11250 * linux-low.c (linux_attach_fail_reason_string): Move to
11251 nat/linux-ptrace.c, and rename.
11252 (linux_attach_lwp): Update comment.
11253 (attach_proc_task_lwp_callback): New function.
11254 (linux_attach): Adjust to rename and use
11255 linux_proc_attach_tgid_threads.
11256 (linux_attach_fail_reason_string): Delete declaration.
11257
76f2b779
JB
112582015-01-01 Joel Brobecker <brobecker@adacore.com>
11259
11260 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11261 * server.c (gdbserver_version): Likewise.
11262
fafcc06a
SDJ
112632014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11264
11265 * remote-utils.c: Include ctype.h.
11266 (input_interrupt): Explicitly handle the case when the char
11267 received is the NUL byte. Improve the printing of non-ASCII
11268 characters.
11269
beed38b8
JB
112702014-12-16 Joel Brobecker <brobecker@adacore.com>
11271
11272 * linux-low.c (linux_low_filter_event): Update call to
11273 linux_enable_event_reporting following the addition of
11274 a new parameter to that function.
11275
bf330350
CU
112762014-12-16 Catalin Udma <catalin.udma@freescale.com>
11277
11278 PR server/17457
11279 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11280 (AARCH64_FPCR_REGNO): Likewise.
11281 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11282 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11283 (aarch64_store_fpregset): Likewise.
11284
5227d625
JB
112852014-12-15 Joel Brobecker <brobecker@adacore.com>
11286
11287 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11288 Remove FIXME comment about assumption about N.
11289
f93b65a0
JB
112902014-12-13 Joel Brobecker <brobecker@adacore.com>
11291
11292 * configure.ac: If large-file support is disabled in GDBserver,
11293 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11294 * configure: Regenerate.
11295
e5a9158d
AA
112962014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11297
11298 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11299 warning upon ENODATA from ptrace.
11300 * linux-s390-low.c (s390_store_tdb): New.
11301 (s390_regsets): Add regset for NT_S390_TDB.
11302
feea5f36
AA
113032014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11304
11305 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11306 without a fill_function.
11307 * linux-s390-low.c (s390_fill_last_break): Remove.
11308 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11309 (s390_arch_setup): Use regset's size instead of fill_function for
11310 loop end condition.
11311
098dbe61
AA
113122014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11313
11314 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11315 the regset's store function when ptrace returned an error.
11316 * regcache.c (get_thread_regcache): Invalidate register cache
11317 before fetching inferior's registers.
11318
28eef672
AA
113192014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11320
11321 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11322 while-loop as for-loop.
11323 (regsets_store_inferior_registers): Likewise.
11324
bdca27a2
YQ
113252014-11-28 Yao Qi <yao@codesourcery.com>
11326
11327 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11328 * config.in, configure: Re-generate.
11329 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11330 is defined.
11331
9c232dda
YQ
113322014-11-21 Yao Qi <yao@codesourcery.com>
11333
11334 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11335 (AC_CHECK_HEADERS): Remove malloc.h.
11336 * configure: Re-generated.
11337 * config.in: Re-generated.
11338 * server.h: Don't include alloca.h and malloc.h.
11339 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11340 Don't include malloc.h.
11341
43968415
JB
113422014-11-17 Joel Brobecker <brobecker@adacore.com>
11343
11344 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11345 corresponding ERRNO check in same block.
11346
40e91bc7
PA
113472014-11-12 Pedro Alves <palves@redhat.com>
11348
11349 * server.c (cont_thread): Update comment.
11350 (start_inferior, attach_inferior): No longer clear cont_thread.
11351 (handle_v_cont): No longer set cont_thread.
11352 (captured_main): Clear cont_thread each time a GDB connects.
11353
c2c118cf
PA
113542014-11-12 Pedro Alves <palves@redhat.com>
11355
11356 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11357 thread, and don't resume all threads if the Hc thread has exited.
11358
78708b7c
PA
113592014-11-12 Pedro Alves <palves@redhat.com>
11360
11361 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11362 the process group instead of to a specific LWP.
11363
a2abc7de
PA
113642014-10-15 Pedro Alves <palves@redhat.com>
11365
11366 PR server/17487
11367 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11368 parameter.
11369 (arm_set_thread_context): Delete.
11370 (the_low_target): Adjust.
11371 * win32-i386-low.c (debug_registers_changed)
11372 (debug_registers_used): Delete.
11373 (update_debug_registers_callback): New function.
11374 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11375 needing to update their debug registers.
11376 (win32_get_current_dr): New function.
11377 (x86_dr_low_get_addr, x86_dr_low_get_control)
11378 (x86_dr_low_get_status): Fetch the debug register from the thread
11379 record's context.
11380 (i386_initial_stuff): Adjust.
11381 (i386_get_thread_context): Remove current_event parameter. Don't
11382 clear debug_registers_changed nor copy DR values to
11383 debug_reg_state.
11384 (i386_set_thread_context): Delete.
11385 (i386_prepare_to_resume): New function.
11386 (i386_thread_added): Mark the thread as needing to update irs
11387 debug registers.
11388 (the_low_target): Remove i386_set_thread_context and install
11389 i386_prepare_to_resume.
11390 * win32-low.c (win32_get_thread_context): Adjust.
11391 (win32_set_thread_context): Use SetThreadContext
11392 directly.
11393 (win32_prepare_to_resume): New function.
11394 (win32_require_context): New function, factored out from ...
11395 (thread_rec): ... this.
11396 (continue_one_thread): Call win32_prepare_to_resume on each thread
11397 we're about to continue.
11398 (win32_resume): Call win32_prepare_to_resume on the event thread.
11399 * win32-low.h (struct win32_thread_info)
11400 <debug_registers_changed>: New field.
11401 (struct win32_target_ops): Change prototype of set_thread_context,
11402 delete set_thread_context and add prepare_to_resume.
11403 (win32_require_context): New declaration.
11404
a442d071
GB
114052014-10-08 Gary Benson <gbenson@redhat.com>
11406
11407 * server.h: Do not include common-exceptions.h.
11408
6f1947e8
GB
114092014-10-08 Gary Benson <gbenson@redhat.com>
11410
11411 * server.h: Do not include cleanups.h.
11412
63b434a4
JH
114132014-09-30 James Hogan <james.hogan@imgtec.com>
11414
11415 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11416 mips64-dsp-linux.c.
11417
c4d9ceb6
YQ
114182014-09-23 Yao Qi <yao@codesourcery.com>
11419
11420 * linux-low.c (lp_status_maybe_breakpoint): New function.
11421 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11422 (count_events_callback): Likewise.
11423 (select_event_lwp_callback): Likewise.
11424 (cancel_breakpoints_callback): Likewise.
11425
89a5711c
DB
114262014-09-19 Don Breazeal <donb@codesourcery.com>
11427
11428 * linux-low.c (handle_extended_wait): Call
11429 linux_ptrace_get_extended_event.
11430 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11431 linux_is_extended_waitstatus.
11432
bffc0964
JB
114332014-09-16 Joel Brobecker <brobecker@adacore.com>
11434
11435 * Makefile.in (CPPFLAGS): Define.
11436 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11437 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11438
0bfdf32f
GB
114392014-09-16 Gary Benson <gbenson@redhat.com>
11440
11441 * inferiors.h (current_inferior): Renamed as...
11442 (current_thread): New variable. All uses updated.
11443 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11444 (maybe_move_out_of_jump_pad): Likewise.
11445 (cancel_breakpoint): Likewise.
11446 (linux_low_filter_event): Likewise.
11447 (wait_for_sigstop): Likewise.
11448 (linux_resume_one_lwp): Likewise.
11449 (need_step_over_p): Likewise.
11450 (start_step_over): Likewise.
11451 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11452 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11453 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11454 and save_inferior as saved_thread.
11455 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11456 saved_thread.
11457 (regcache_invalidate_thread): Likewise.
11458 * remote-utils.c (prepare_resume_reply): Likewise.
11459 * thread-db.c (thread_db_get_tls_address): Likewise.
11460 (disable_thread_event_reporting): Likewise.
11461 (remove_thread_event_breakpoints): Likewise.
11462 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11463 as saved_thread.
11464 * target.h (set_desired_inferior): Renamed as...
11465 (set_desired_thread): New declaration. All uses updated.
11466 * server.c (myresume): Updated comment to reference thread instead
11467 of inferior.
11468 (handle_serial_event): Likewise.
11469 (handle_target_event): Likewise.
11470
361c8ade
GB
114712014-09-12 Tom Tromey <tromey@redhat.com>
11472 Gary Benson <gbenson@redhat.com>
11473
11474 * regcache.h: Include common-regcache.h.
11475 (regcache_read_pc): Don't declare.
11476 * regcache.c (get_thread_regcache_for_ptid): New function.
11477
bd9269f7
GB
114782014-09-11 Tom Tromey <tromey@redhat.com>
11479 Gary Benson <gbenson@redhat.com>
11480
11481 * symbol.c: New file.
11482 * Makefile.in (SFILES): Add symbol.c.
11483 (OBS): Add symbol.o.
11484
f8c1d06b
GB
114852014-09-11 Gary Benson <gbenson@redhat.com>
11486
11487 * target.c (target_stop_ptid, target_continue_ptid): New
11488 functions.
11489
721ec300
GB
114902014-09-11 Tom Tromey <tromey@redhat.com>
11491 Gary Benson <gbenson@redhat.com>
11492
11493 * target.h: Include target/target.h.
11494 * target.c (target_read_memory, target_read_uint32)
11495 (target_write_memory): New functions.
11496
c5e92cca
GB
114972014-09-11 Gary Benson <gbenson@redhat.com>
11498
11499 * server.h (debug_hw_points): Don't declare.
11500 * server.c (debug_hw_points): Don't define. Replace all uses
11501 with show_debug_regs.
11502 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11503 all uses with show_debug_regs.
11504
2e4bb98a
EBM
115052014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11506
11507 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11508 endianness into account.
11509 (ppc_supply_ptrace_register): Likewise.
11510
ac740bc7
JH
115112014-09-03 James Hogan <james.hogan@imgtec.com>
11512
11513 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11514 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11515
97ea6506
GB
115162014-09-03 Gary Benson <gbenson@redhat.com>
11517
11518 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11519 ALL_DEBUG_ADDRESS_REGISTERS.
11520
df7e5265
GB
115212014-09-02 Gary Benson <gbenson@redhat.com>
11522
11523 * i386-low.h: Renamed as...
11524 * x86-low.h: New file. All type, function and variable name
11525 prefixes changed from "i386_" to "x86_". All references updated.
11526 * i386-low.c: Renamed as...
11527 * x86-low.c: New file. All type, function and variable name
11528 prefixes changed from "i386_" to "x86_". All references updated.
11529
ed859da7
GB
115302014-09-02 Gary Benson <gbenson@redhat.com>
11531
11532 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11533 (x86_linux_new_thread): Likewise.
11534
860789c7
GB
115352014-08-29 Gary Benson <gbenson@redhat.com>
11536
11537 * server.h (setjmp.h): Do not include.
11538 (toplevel): Do not declare.
11539 (common-exceptions.h): Include.
11540 (cleanups.h): Likewise.
11541 * server.c (toplevel): Do not define.
11542 (exit_code): New static global.
11543 (detach_or_kill_for_exit_cleanup): New function.
11544 (main): New function. Original main renamed to...
11545 (captured_main): New function.
11546 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11547
ff55e1b5
GB
115482014-08-29 Gary Benson <gbenson@redhat.com>
11549
11550 * Makefile.in (SFILES): Add common/common-exceptions.c.
11551 (OBS): Add common-exceptions.o.
11552 (common-exceptions.o): New rule.
11553 * utils.c (prepare_to_throw_exception): New function.
11554
e9bcb658
GB
115552014-08-29 Gary Benson <gbenson@redhat.com>
11556
11557 * config.in: Regenerate.
11558 * configure: Likewise.
11559
e3180625
GB
115602014-08-29 Gary Benson <gbenson@redhat.com>
11561
11562 * Makefile.in (SFILES): Add common/cleanups.c.
11563 (OBS): cleanups.o.
11564 (cleanups.o): New rule.
11565
e3d6ba5d
GB
115662014-08-29 Gary Benson <gbenson@redhat.com>
11567
11568 * utils.c (internal_vwarning): New function.
11569
7096e886
GB
115702014-08-28 Gary Benson <gbenson@redhat.com>
11571
11572 * utils.h (fatal): Remove declaration.
11573 * utils.c (fatal): Remove function.
11574
14ce3192
GB
115752014-08-28 Gary Benson <gbenson@redhat.com>
11576
11577 * tracepoint.c (gdb_agent_init): Replace fatal with
11578 perror_with_name.
11579 (initialize_tracepoint): Likewise.
11580
50278d59
GB
115812014-08-28 Gary Benson <gbenson@redhat.com>
11582
11583 * remote-utils.c (remote_prepare): Replace fatal with error.
11584
aa96c426
GB
115852014-08-28 Gary Benson <gbenson@redhat.com>
11586
11587 * linux-low.c (linux_async): Replace fatal with warning.
11588 Tidy up and return.
11589 (linux_start_non_stop): Return -1 if linux_async failed.
11590
f7160e97
GB
115912014-08-28 Gary Benson <gbenson@redhat.com>
11592
11593 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11594 gdb_assert.
11595 (i386_dr_low_get_addr): Remove vague comment.
11596 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11597 gdb_assert.
11598
38e08fca
GB
115992014-08-28 Gary Benson <gbenson@redhat.com>
11600
11601 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11602 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11603 internal_error.
11604 (linux_resume_one_lwp): Likewise.
11605 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11606 gdb_assert.
11607 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11608 with internal_error.
11609 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11610 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11611 (find_register_by_name): Replace fatal with internal_error.
11612 (find_regno): Likewise.
11613 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11614 * thread-db.c (thread_db_create_event): Likewise.
11615 (thread_db_load_search): Likewise.
11616 (try_thread_db_load_1): Likewise.
11617 * tracepoint.c (get_jump_space_head): Replace fatal with
11618 internal_error.
11619 (claim_trampoline_space): Likewise.
11620 (have_fast_tracepoint_trampoline_buffer): Likewise.
11621 (cmd_qtstart): Likewise.
11622 (stop_tracing): Likewise.
11623 (fast_tracepoint_collecting): Likewise.
11624 (target_malloc): Likewise.
11625 (download_tracepoint): Likewise.
11626 (download_trace_state_variables): Replace check with gdb_assert.
11627 (upload_fast_traceframes): Replace fatal with internal_error.
11628
34abf635
GB
116292014-08-19 Tom Tromey <tromey@redhat.com>
11630 Gary Benson <gbenson@redhat.com>
11631
11632 * Makefile.in (SFILES): Add common/common-debug.c.
11633 (OBS): Add common-debug.o.
11634 (common-debug.o): New rule.
11635 * debug.h (debug_printf): Don't declare.
11636 * debug.c (debug_printf): Renamed and rewritten as...
11637 (debug_vprintf): New function.
11638
f6e94d78
GB
116392014-08-19 Gary Benson <gbenson@redhat.com>
11640
11641 * utils.h: Do not include print-utils.h.
11642
9239eeab
GB
116432014-08-19 Tom Tromey <tromey@redhat.com>
11644 Gary Benson <gbenson@redhat.com>
11645
11646 * server.h: Add static assertion.
11647 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11648
ef87c8bb
GB
116492014-08-19 Tom Tromey <tromey@redhat.com>
11650 Gary Benson <gbenson@redhat.com>
11651
11652 * Makefile.in (SFILES): Add common/errors.c.
11653 (OBS): Add errors.o.
11654 (IPA_OBS): Add errors-ipa.o.
11655 (errors.o): New rule.
11656 (errors-ipa.o): Likewise.
11657 * utils.h (perror_with_name, error, warning): Don't declare.
11658 * utils.c (warning): Renamed and rewritten as...
11659 (vwarning): New function.
11660 (error): Renamed and rewritten as...
11661 (verror): New function.
11662 (internal_error): Renamed and rewritten as...
11663 (internal_verror): New function.
11664
bb974a24
GB
116652014-08-07 Gary Benson <gbenson@redhat.com>
11666
11667 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11668 * configure: Regenerate.
11669 * config.in: Likewise.
11670 * server.h: Do not include errno.h.
11671 * event-loop.c: Likewise.
11672 * hostio-errno.c: Likewise.
11673 * linux-low.c: Likewise.
11674 * remote-utils.c: Likewise.
11675 * spu-low.c: Likewise.
11676 * utils.c: Likewise.
11677 * gdbreplay.c: Unconditionally include errno.h.
11678
6d3d12eb
GB
116792014-08-07 Gary Benson <gbenson@redhat.com>
11680
11681 * server.h: Do not include string.h.
11682 * event-loop.c: Likewise.
11683 * linux-low.c: Likewise.
11684 * regcache.c: Likewise.
11685 * remote-utils.c: Likewise.
11686 * spu-low.c: Likewise.
11687 * utils.c: Likewise.
11688
dccbb609
GB
116892014-08-07 Gary Benson <gbenson@redhat.com>
11690
11691 * server.h: Do not include gdb_assert.h.
11692
e76df0d0
GB
116932014-08-07 Gary Benson <gbenson@redhat.com>
11694
11695 * server.h: Do not include common-utils.h.
11696
4cb9c816
GB
116972014-08-07 Gary Benson <gbenson@redhat.com>
11698
11699 * server.h: Do not include ptid.h.
11700 * notif.h: Likewise.
11701
3995eeee
GB
117022014-08-07 Gary Benson <gbenson@redhat.com>
11703
11704 * server.h: Do not include gdb_locale.h.
11705
cb9f1a9b
GB
117062014-08-07 Gary Benson <gbenson@redhat.com>
11707
11708 * server.h: Do not include gdb/signals.h.
11709 * win32-low.c: Likewise.
11710
a5fceff8
GB
117112014-08-07 Gary Benson <gbenson@redhat.com>
11712
11713 * server.h: Do not include pathmax.h.
11714
b9391142
GB
117152014-08-07 Gary Benson <gbenson@redhat.com>
11716
11717 * server.h: Do not include libiberty.h.
11718 * linux-bfin-low.c: Likewise.
11719
0e443c87
GB
117202014-08-07 Gary Benson <gbenson@redhat.com>
11721
11722 * server.h: Do not include ansidecl.h.
11723
8ebb3f56
GB
117242014-08-07 Gary Benson <gbenson@redhat.com>
11725
11726 * linux-x86-low.c: Do not include stddef.h.
11727 * lynx-ppc-low.c: Likewise.
11728 * tracepoint.c: Likewise.
11729
8980bdf6
GB
117302014-08-07 Gary Benson <gbenson@redhat.com>
11731
11732 * server.h: Do not include stdarg.h.
11733 * nto-low.c: Likewise.
11734
d7096f71
GB
117352014-08-07 Gary Benson <gbenson@redhat.com>
11736
11737 * server.h: Do not include stdlib.h.
11738 * inferiors.c: Likewise.
11739 * linux-low.c: Likewise.
11740 * regcache.c: Likewise.
11741 * spu-low.c: Likewise.
11742 * tracepoint.c: Likewise.
11743 * utils.c: Likewise.
11744
d02f550d
GB
117452014-08-07 Gary Benson <gbenson@redhat.com>
11746
11747 * server.h: Do not include stdio.h.
11748 * linux-low.c: Likewise.
11749 * remote-utils.c: Likewise.
11750 * spu-low.c: Likewise.
11751 * utils.c: Likewise.
11752 * wincecompat.c: Likewise.
11753
87f6c4e3
GB
117542014-08-06 Gary Benson <gbenson@redhat.com>
11755
11756 * regcache.c (init_register_cache): Move conditionals inside if.
11757
7089dca4
GB
117582014-08-06 Gary Benson <gbenson@redhat.com>
11759
11760 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
11761
462f517e
GB
117622014-07-31 Gary Benson <gbenson@redhat.com>
11763
11764 * ax.h: Do not include server.h.
11765 * gdbthread.h: Likewise.
11766 * lynx-low.h: Likewise.
11767 * notif.h: Likewise.
11768
976411d6
GB
117692014-07-30 Gary Benson <gbenson@redhat.com>
11770
11771 * server.h: Include common-defs.h.
11772 Do not include config.h or build-gnulib-gdbserver/config.h.
11773
d41f6d8e
GB
117742014-07-30 Gary Benson <gbenson@redhat.com>
11775
11776 * hostio-errno.c: Move server.h to top of includes list.
11777 * inferiors.c: Likewise.
11778 * linux-x86-low.c: Likewise.
11779 * notif.c: Include server.h.
11780
314c6a35
TT
117812014-07-24 Tom Tromey <tromey@redhat.com>
11782 Gary Benson <gbenson@redhat.com>
11783
11784 * server.h (CORE_ADDR): Now unsigned.
11785
69ff6be5
PA
117862014-07-16 Pedro Alves <palves@redhat.com>
11787
11788 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
11789
ce9e3fe7
PA
117902014-07-15 Pedro Alves <palves@redhat.com>
11791
11792 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
11793 copy.
11794
e76126e8
PA
117952014-07-11 Pedro Alves <palves@redhat.com>
11796
11797 * linux-low.c (kill_wait_lwp): New function, based on
11798 kill_one_lwp_callback, but use my_waitpid directly.
11799 (kill_one_lwp_callback, linux_kill): Use it.
11800
8e9db26e
PA
118012014-06-23 Pedro Alves <palves@redhat.com>
11802
11803 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
11804 before setting DR0..DR3.
11805
698b3e08
GB
118062014-06-20 Gary Benson <gbenson@redhat.com>
11807
11808 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
11809 * configure: Regenerated.
11810 * config.in: Likewise.
11811
125f8a3d
GB
118122014-06-20 Gary Benson <gbenson@redhat.com>
11813
11814 * Makefile.in (SFILES): Update locations for files moved
11815 from common to nat.
11816 (object file files): Reordered.
11817
42995dbd
GB
118182014-06-20 Gary Benson <gbenson@redhat.com>
11819
11820 * i386-low.h (i386_dr_low_can_set_addr): Removed.
11821 (i386_dr_low_set_addr): Likewise.
11822 (i386_dr_low_get_addr): Likewise.
11823 (i386_dr_low_can_set_control): Likewise.
11824 (i386_dr_low_set_control): Likewise.
11825 (i386_dr_low_get_control): Likewise.
11826 (i386_dr_low_get_status): Likewise.
11827 (i386_get_debug_register_length): Likewise.
11828 * linux-x86-low.c (i386_dr_low_set_addr):
11829 Changed signature. Made static.
11830 (i386_dr_low_get_addr): Likewise.
11831 (i386_dr_low_set_control): Likewise.
11832 (i386_dr_low_get_control): Likewise.
11833 (i386_dr_low_get_status): Likewise.
11834 (i386_dr_low): New global variable.
11835 * win32-i386-low.c (i386_dr_low_set_addr):
11836 Changed signature. Made static.
11837 (i386_dr_low_get_addr): Likewise.
11838 (i386_dr_low_set_control): Likewise.
11839 (i386_dr_low_get_control): Likewise.
11840 (i386_dr_low_get_status): Likewise.
11841 (i386_dr_low): New global variable.
11842
e1d2394b
MS
118432014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
11844
11845 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
11846 * Makefile.in (AR, AR_FLAGS): Define.
11847 * configure: Regenerate.
11848
3a8ee006
GB
118492014-06-19 Gary Benson <gbenson@redhat.com>
11850
11851 * Makefile.in (i386-dregs.o): New rule.
11852 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
11853 * i386-low.c (target.h): Remove include.
11854 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
11855 (DR_CONTROL_SHIFT): Likewise.
11856 (DR_CONTROL_SIZE): Likewise.
11857 (DR_RW_EXECUTE): Likewise.
11858 (DR_RW_WRITE): Likewise.
11859 (DR_RW_READ): Likewise.
11860 (DR_RW_IORW): Likewise.
11861 (DR_LEN_1): Likewise.
11862 (DR_LEN_2): Likewise.
11863 (DR_LEN_4): Likewise.
11864 (DR_LEN_8): Likewise.
11865 (DR_LOCAL_ENABLE_SHIFT): Likewise.
11866 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
11867 (DR_ENABLE_SIZE): Likewise.
11868 (DR_LOCAL_SLOWDOWN): Likewise.
11869 (DR_GLOBAL_SLOWDOWN): Likewise.
11870 (DR_CONTROL_RESERVED): Likewise.
11871 (I386_DR_CONTROL_MASK): Likewise.
11872 (I386_DR_VACANT): Likewise.
11873 (I386_DR_LOCAL_ENABLE): Likewise.
11874 (I386_DR_GLOBAL_ENABLE): Likewise.
11875 (I386_DR_DISABLE): Likewise.
11876 (I386_DR_SET_RW_LEN): Likewise.
11877 (I386_DR_GET_RW_LEN): Likewise.
11878 (I386_DR_WATCH_HIT): Likewise.
11879 (i386_wp_op_t): Likewise.
11880 (i386_show_dr): Likewise.
11881 (i386_length_and_rw_bits): Likewise.
11882 (i386_insert_aligned_watchpoint): Likewise.
11883 (i386_remove_aligned_watchpoint): Likewise.
11884 (i386_handle_nonaligned_watchpoint): Likewise.
11885 i386_update_inferior_debug_regs(): Likewise.
11886 (i386_dr_insert_watchpoint): Likewise.
11887 (i386_dr_remove_watchpoint): Likewise.
11888 (i386_dr_region_ok_for_watchpoint): Likewise.
11889 (i386_dr_stopped_data_address): Likewise.
11890 (i386_dr_stopped_by_watchpoint): Likewise.
11891
8f26655c
GB
118922014-06-19 Gary Benson <gbenson@redhat.com>
11893
11894 * i386-low.c (i386_dr_show): Renamed to
11895 i386_show_dr and made static. All uses updated.
11896 (i386_dr_length_and_rw_bits): Renamed to
11897 i386_length_and_rw_bits and made static.
11898 All uses updated.
11899 (i386_dr_insert_aligned_watchpoint): Renamed to
11900 i386_insert_aligned_watchpoint and made static.
11901 All uses updated.
11902 (i386_dr_remove_aligned_watchpoint): Renamed to
11903 i386_remove_aligned_watchpoint and made static.
11904 All uses updated.
11905 (i386_dr_update_inferior_debug_regs): Renamed to
11906 i386_update_inferior_debug_regs and made static.
11907 All uses updated.
11908
b9228891
GB
119092014-06-18 Gary Benson <gbenson@redhat.com>
11910
5171def3
GB
11911 * i386-low.h (i386_dr_low_can_set_addr): New macro.
11912 (i386_dr_low_can_set_control): Likewise.
11913 (i386_get_debug_register_length): Likewise.
11914 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
11915 (i386_dr_low_can_set_control): Likewise.
11916 (i386_get_debug_register_length): Likewise.
11917
119182014-06-17 Gary Benson <gbenson@redhat.com>
11919
b9228891
GB
11920 * i386-low.h (i386-dregs.h): New include.
11921 (DR_FIRSTADDR): Now in i386-dregs.h.
11922 (DR_LASTADDR): Likewise.
11923 (DR_NADDR): Likewise.
11924 (DR_STATUS): Likewise.
11925 (DR_CONTROL): Likewise.
11926 (i386_debug_reg_state): Likewise.
11927 (i386_dr_insert_watchpoint): Likewise.
11928 (i386_dr_remove_watchpoint): Likewise.
11929 (i386_dr_region_ok_for_watchpoint): Likewise.
11930 (i386_dr_stopped_data_address): Likewise.
11931 (i386_dr_stopped_by_watchpoint): Likewise.
11932 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
11933
4be83cc2
GB
119342014-06-18 Gary Benson <gbenson@redhat.com>
11935
11936 * i386-low.h (i386_low_insert_watchpoint): Renamed to
11937 i386_dr_insert_watchpoint.
11938 (i386_low_remove_watchpoint): Renamed to
11939 i386_dr_remove_watchpoint.
11940 (i386_low_region_ok_for_watchpoint): Renamed to
11941 i386_dr_region_ok_for_watchpoint.
11942 (i386_low_stopped_data_address): Renamed to
11943 i386_dr_stopped_data_address.
11944 (i386_low_stopped_by_watchpoint): Renamed to
11945 i386_dr_stopped_by_watchpoint.
11946 * i386-low.c (i386_show_dr): Renamed to
11947 i386_dr_show and made nonstatic. All uses updated.
11948 (i386_length_and_rw_bits): Renamed to
11949 i386_dr_length_and_rw_bits and made nonstatic.
11950 All uses updated.
11951 (i386_insert_aligned_watchpoint): Renamed to
11952 i386_dr_insert_aligned_watchpoint and made nonstatic.
11953 All uses updated.
11954 (i386_remove_aligned_watchpoint): Renamed to
11955 i386_dr_remove_aligned_watchpoint and made nonstatic.
11956 All uses updated.
11957 (i386_update_inferior_debug_regs): Renamed to
11958 i386_dr_update_inferior_debug_regs and made nonstatic.
11959 All uses updated.
11960 (i386_low_insert_watchpoint): Renamed to
11961 i386_dr_insert_watchpoint. All uses updated.
11962 (i386_low_remove_watchpoint): Renamed to
11963 i386_dr_remove_watchpoint. All uses updated.
11964 (i386_low_region_ok_for_watchpoint): Renamed to
11965 i386_dr_region_ok_for_watchpoint. All uses updated.
11966 (i386_low_stopped_data_address): Renamed to
11967 i386_dr_stopped_data_address. All uses updated.
11968 (i386_low_stopped_by_watchpoint): Renamed to
11969 i386_dr_stopped_by_watchpoint. All uses updated.
11970
131aa0d4
GB
119712014-06-18 Gary Benson <gbenson@redhat.com>
11972
11973 * i386-low.c (i386_dr_low_can_set_addr): New macro.
11974 (i386_dr_low_can_set_control): Likewise.
11975 (i386_insert_aligned_watchpoint): New check.
11976
d9305f7f
GB
119772014-06-18 Gary Benson <gbenson@redhat.com>
11978
11979 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
11980 Renamed to state.
11981
e927c9fc
GB
119822014-06-18 Gary Benson <gbenson@redhat.com>
11983
11984 * i386-low.c (i386_length_and_rw_bits): Use internal_error
11985 instead of fatal and error.
11986 (i386_handle_nonaligned_watchpoint): Likewise.
11987
1b6d4134
GB
119882014-06-18 Gary Benson <gbenson@redhat.com>
11989
11990 * i386-low.c (i386_get_debug_register_length): New macro.
11991 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
11992 (i386_show_dr): Use debug_printf instead of fprintf. Use
11993 phex to format values.
11994
6e62758f
GB
119952014-06-18 Gary Benson <gbenson@redhat.com>
11996
11997 * i386-low.h: Comment changes.
11998 * i386-low.c: Likewise.
11999
fc6e2f03
GB
120002014-06-18 Gary Benson <gbenson@redhat.com>
12001
12002 * i386-low.c: Whitespace changes.
12003
f9d1eeed
TT
120042014-06-12 Tom Tromey <tromey@redhat.com>
12005
12006 * utils.c (freeargv): Remove.
12007
0b04e523
TT
120082014-06-12 Tom Tromey <tromey@redhat.com>
12009
12010 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12011 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12012 (parse_debug_format_options): Likewise.
12013 (gdbserver_usage): Likewise.
12014 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12015 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12016 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12017 against libiberty.
12018 ($(LIBGNU)): Depend on libiberty.
12019 (all-lib): Recurse into all subdirs.
12020 (install-only): Invoke "install" target in subdirs.
12021 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12022 targets.
12023 * configure: Rebuild.
12024 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12025 for vasprintf, vsnprintf, or gettimeofday.
12026 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12027 srv_tgtobj.
12028
270c9937
JB
120292014-06-05 Joel Brobecker <brobecker@adacore.com>
12030
12031 * development.sh: Delete.
12032 * Makefile.in (config.status): Adjust dependency on development.sh.
12033 * configure.ac: Adjust development.sh source call.
12034 * configure: Regenerate.
12035
0a261ed8
PA
120362014-06-02 Pedro Alves <palves@redhat.com>
12037
12038 * ax.c (gdb_free_agent_expr): New function.
12039 * ax.h (gdb_free_agent_expr): New declaration.
12040 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12041 list.
12042 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12043 static.
12044 (clear_breakpoint_conditions_and_commands): New function.
12045 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12046 (clear_breakpoint_conditions_and_commands): New declaration.
12047
e9dae05e
RR
120482014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12049
12050 * linux-aarch64-low.c (asm/ptrace.h): Include.
12051
5876f503
JK
120522014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12053
12054 Fix TLS access for -static -pthread.
12055 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12056 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12057 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12058
802e8e6d
PA
120592014-05-20 Pedro Alves <palves@redhat.com>
12060
12061 * linux-aarch64-low.c (aarch64_insert_point)
12062 (aarch64_remove_point): No longer check whether the type is
12063 supported here. Adjust to new interface.
12064 (the_low_target): Install aarch64_supports_z_point_type as
12065 supports_z_point_type method.
12066 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12067 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12068 instead of a Z packet char. Adjust.
12069 (arm_supports_z_point_type): New function.
12070 (arm_insert_point, arm_remove_point): Adjust to new interface.
12071 (the_low_target): Install arm_supports_z_point_type.
12072 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12073 (cris_insert_point, cris_remove_point): Adjust to new interface.
12074 Don't check whether the type is supported here.
12075 (the_low_target): Install cris_supports_z_point_type.
12076 * linux-low.c (linux_supports_z_point_type): New function.
12077 (linux_insert_point, linux_remove_point): Adjust to new interface.
12078 * linux-low.h (struct linux_target_ops) <insert_point,
12079 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12080 raw_breakpoint pointer parameter.
12081 <supports_z_point_type>: New method.
12082 * linux-mips-low.c (mips_supports_z_point_type): New function.
12083 (mips_insert_point, mips_remove_point): Adjust to new interface.
12084 Use mips_supports_z_point_type.
12085 (the_low_target): Install mips_supports_z_point_type.
12086 * linux-ppc-low.c (the_low_target): Install NULL as
12087 supports_z_point_type method.
12088 * linux-s390-low.c (the_low_target): Install NULL as
12089 supports_z_point_type method.
12090 * linux-sparc-low.c (the_low_target): Install NULL as
12091 supports_z_point_type method.
12092 * linux-x86-low.c (x86_supports_z_point_type): New function.
12093 (x86_insert_point): Adjust to new insert_point interface. Use
12094 insert_memory_breakpoint. Adjust to new
12095 i386_low_insert_watchpoint interface.
12096 (x86_remove_point): Adjust to remove_point interface. Use
12097 remove_memory_breakpoint. Adjust to new
12098 i386_low_remove_watchpoint interface.
12099 (the_low_target): Install x86_supports_z_point_type.
12100 * lynx-low.c (lynx_target_ops): Install NULL as
12101 supports_z_point_type callback.
12102 * nto-low.c (nto_supports_z_point_type): New.
12103 (nto_insert_point, nto_remove_point): Adjust to new interface.
12104 (nto_target_ops): Install nto_supports_z_point_type.
12105 * mem-break.c: Adjust intro comment.
12106 (struct raw_breakpoint) <raw_type, size>: New fields.
12107 <inserted>: Update comment.
12108 <shlib_disabled>: Delete field.
12109 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12110 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12111 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12112 (raw_bkpt_type_to_target_hw_bp_type): New function.
12113 (find_enabled_raw_code_breakpoint_at): New function.
12114 (find_raw_breakpoint_at): New type and size parameters. Use them.
12115 (insert_memory_breakpoint): New function, based off
12116 set_raw_breakpoint_at.
12117 (remove_memory_breakpoint): New function.
12118 (set_raw_breakpoint_at): Reimplement.
12119 (set_breakpoint): New, based on set_breakpoint_at.
12120 (set_breakpoint_at): Reimplement.
12121 (delete_raw_breakpoint): Go through the_target->remove_point
12122 instead of assuming memory breakpoints.
12123 (find_gdb_breakpoint_at): Delete.
12124 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12125 (find_gdb_breakpoint): New function.
12126 (set_gdb_breakpoint_at): Delete.
12127 (z_type_supported): New function.
12128 (set_gdb_breakpoint_1): New function, loosely based off
12129 set_gdb_breakpoint_at.
12130 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12131 (delete_gdb_breakpoint_at): Delete.
12132 (delete_gdb_breakpoint_1): New function, loosely based off
12133 delete_gdb_breakpoint_at.
12134 (delete_gdb_breakpoint): New function.
12135 (clear_gdb_breakpoint_conditions): Rename to ...
12136 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12137 breakpoint.
12138 (add_condition_to_breakpoint): Make static.
12139 (add_breakpoint_condition): Take a struct breakpoint pointer
12140 instead of an address. Adjust.
12141 (gdb_condition_true_at_breakpoint): Rename to ...
12142 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12143 z_type parameter.
12144 (gdb_condition_true_at_breakpoint): Reimplement.
12145 (add_breakpoint_commands): Take a struct breakpoint pointer
12146 instead of an address. Adjust.
12147 (gdb_no_commands_at_breakpoint): Rename to ...
12148 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12149 parameter. Return true if no breakpoint was found. Change debug
12150 output.
12151 (gdb_no_commands_at_breakpoint): Reimplement.
12152 (run_breakpoint_commands): Rename to ...
12153 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12154 and change return type to boolean.
12155 (run_breakpoint_commands): New function.
12156 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12157 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12158 breakpoint. Go through the_target->remove_point instead of
12159 assuming memory breakpoint.
12160 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12161 software and hardware breakpoints.
12162 (reinsert_raw_breakpoint): Go through the_target->insert_point
12163 instead of assuming memory breakpoint.
12164 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12165 software and hardware breakpoints.
12166 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12167 Check both software and hardware breakpoints.
12168 (validate_inserted_breakpoint): Assert the breakpoint is a
12169 software breakpoint. Set the inserted flag to -1 instead of
12170 setting shlib_disabled.
12171 (delete_disabled_breakpoints): Adjust.
12172 (validate_breakpoints): Only validate software breakpoints.
12173 Adjust to inserted flag change.
12174 (check_mem_read, check_mem_write): Skip breakpoint types other
12175 than software breakpoints. Adjust to inserted flag change.
12176 * mem-break.h (enum raw_bkpt_type): New enum.
12177 (raw_breakpoint, struct process_info): Forward declare.
12178 (Z_packet_to_target_hw_bp_type): Delete declaration.
12179 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12180 (set_gdb_breakpoint, delete_gdb_breakpoint)
12181 (clear_breakpoint_conditions): New declarations.
12182 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12183 (breakpoint_inserted_here): Update comment.
12184 (add_breakpoint_condition, add_breakpoint_commands): Replace
12185 address parameter with a breakpoint pointer parameter.
12186 (gdb_breakpoint_here): Update comment.
12187 (delete_gdb_breakpoint_at): Delete.
12188 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12189 * server.c (process_point_options): Take a struct breakpoint
12190 pointer instead of an address. Adjust.
12191 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12192 delete_gdb_breakpoint.
12193 * spu-low.c (spu_target_ops): Install NULL as
12194 supports_z_point_type method.
12195 * target.h: Include mem-break.h.
12196 (struct target_ops) <prepare_to_access_memory>: Update comment.
12197 <supports_z_point_type>: New field.
12198 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12199 instead of a char. Also take a raw breakpoint pointer.
12200 * win32-arm-low.c (the_low_target): Install NULL as
12201 supports_z_point_type.
12202 * win32-i386-low.c (i386_supports_z_point_type): New function.
12203 (i386_insert_point, i386_remove_point): Adjust to new interface.
12204 (the_low_target): Install i386_supports_z_point_type.
12205 * win32-low.c (win32_supports_z_point_type): New function.
12206 (win32_insert_point, win32_remove_point): Adjust to new interface.
12207 (win32_target_ops): Install win32_supports_z_point_type.
12208 * win32-low.h (struct win32_target_ops):
12209 <supports_z_point_type>: New method.
12210 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12211 instead of a char. Also take a raw breakpoint pointer.
12212
932539e3
PA
122132014-05-20 Pedro Alves <palves@redhat.com>
12214
12215 * mem-break.h: Include break-common.h.
12216 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12217 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12218 (Z_packet_to_target_hw_bp_type): New declaration.
12219 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12220 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12221 (Z_PACKET_ACCESS_WP): Delete macros.
12222 (Z_packet_to_hw_type): Delete function.
12223 * i386-low.h: Don't include break-common.h here.
12224 (Z_packet_to_hw_type): Delete declaration.
12225 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12226 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12227 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12228 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12229 * linux-aarch64-low.c: Don't include break-common.h here.
12230 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12231 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12232 (Z_packet_to_target_hw_bp_type): Delete function.
12233 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12234 function.
12235 (mips_insert_point, mips_remove_point): Use
12236 Z_packet_to_target_hw_bp_type.
12237
4ff0d3d8
PA
122382014-05-20 Pedro Alves <palves@redhat.com>
12239
12240 * linux-aarch64-low.c: Include break-common.h.
12241 (enum target_point_type): Delete.
12242 (Z_packet_to_point_type): Rename to ...
12243 (Z_packet_to_target_hw_bp_type): ... this, and return a
12244 target_hw_bp_type instead.
12245 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12246 instead of an enum target_point_type.
12247 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12248 breakpoint type.
12249 (aarch64_dr_state_insert_one_point)
12250 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12251 (aarch64_handle_aligned_watchpoint)
12252 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12253 Take an enum target_hw_bp_type instead of an enum
12254 target_point_type.
12255 (aarch64_supports_z_point_type): New function.
12256 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12257 use Z_packet_to_target_hw_bp_type.
12258
786dc519
JB
122592014-05-20 Joel Brobecker <brobecker@adacore.com>
12260
12261 * configure.ac: Only use -Werror by default when DEVELOPMENT
12262 is true.
12263 * configure: Regenerate.
12264
9e0aa64f
JK
122652014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12266
12267 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12268 * linux-x86-low.c (X86_64_USER_REGS): New.
12269 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12270
2b577b92
YQ
122712014-04-28 Yao Qi <yao@codesourcery.com>
12272
12273 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12274 name.
12275
94611da2
PA
122762014-04-25 Pedro Alves <palves@redhat.com>
12277
12278 PR server/16255
12279 * linux-low.c (linux_attach_fail_reason_string): New function.
12280 (linux_attach_lwp): Delete.
12281 (linux_attach_lwp_1): Rename to ...
12282 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12283 argument. Remove "initial" parameter. Return int instead of
12284 void. Don't error or warn here.
12285 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12286 failure to attach to the tgid. Call warning when failing to
12287 attach to an lwp.
12288 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12289 argument. Remove "initial" parameter. Return int instead of
12290 void. Don't error or warn here.
12291 (linux_attach_fail_reason_string): New declaration.
12292 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12293 interface change. Use linux_attach_fail_reason_string.
12294
01f9f808
MS
122952014-04-24 Michael Sturm <michael.sturm@mintel.com>
12296 Walfred Tedeschi <walfred.tedeschi@intel.com>
12297
12298 * Makefile.in: Added rules to handle new files
12299 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12300 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12301 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12302 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12303 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12304 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12305 x32-avx512-linux.o.
12306 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12307 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12308 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12309 i386/x32-avx512.xml.
12310 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12311 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12312 i386/x32-avx512-linux.xml.
12313 * i387-fp.c (num_avx512_k_registers): New constant for number
12314 of K registers.
12315 (num_avx512_zmmh_low_registers): New constant for number of
12316 lower ZMM registers (0-15).
12317 (num_avx512_zmmh_high_registers): New constant for number of
12318 higher ZMM registers (16-31).
12319 (num_avx512_ymmh_registers): New contant for number of higher
12320 YMM registers (ymm16-31 added by avx521 on x86_64).
12321 (num_avx512_xmm_registers): New constant for number of higher
12322 XMM registers (xmm16-31 added by AVX512 on x86_64).
12323 (struct i387_xsave): Add space for AVX512 registers.
12324 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12325 Add code to handle AVX512 registers.
12326 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12327 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12328 prototypei from generated file.
12329 (tdesc_amd64_avx512_linux): Likewise.
12330 (init_registers_x32_avx512_linux): Likewise.
12331 (tdesc_x32_avx512_linux): Likewise.
12332 (init_registers_i386_avx512_linux): Likewise.
12333 (tdesc_i386_avx512_linux): Likewise.
12334 (x86_64_regmap): Add AVX512 registers.
12335 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12336 mask.
12337 (initialize_low_arch): Add code to initialize AVX512 registers.
12338
51aa91f9
PA
123392014-04-23 Pedro Alves <palves@redhat.com>
12340
12341 * mem-break.c (find_gdb_breakpoint_at): Make static.
12342 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12343
a4165e94
PA
123442014-04-23 Pedro Alves <palves@redhat.com>
12345
12346 * i386-low.c: Don't include break-common.h here.
12347 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12348 prototype to take target_hw_bp_type as argument instead of a Z
12349 packet char.
12350 * i386-low.h: Include break-common.h here.
12351 (Z_packet_to_hw_type): Declare.
12352 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12353 prototypes.
12354 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12355 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12356 (x86_remove_point): Convert the packet number to a
12357 target_hw_bp_type before calling i386_low_remove_watchpoint.
12358 * win32-i386-low.c (i386_insert_point): Convert the packet number
12359 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12360 (i386_remove_point): Convert the packet number to a
12361 target_hw_bp_type before calling i386_low_remove_watchpoint.
12362
b8acf843
PA
123632014-04-23 Pedro Alves <palves@redhat.com>
12364
12365 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12366
d708bcd1
PA
123672014-04-10 Pedro Alves <palves@redhat.com>
12368
12369 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12370 Check if the condition or command is NULL before checking if the
12371 breakpoint is known. On success, return true.
12372 * mem-break.h (add_breakpoint_condition): Document return.
12373 (add_breakpoint_commands): Add describing comment.
12374 * server.c (skip_to_semicolon): New function.
12375 (process_point_options): Use it.
12376
2eec7d5b
PA
123772014-04-09 Pedro Alves <palves@redhat.com>
12378
12379 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12380 to lwpid_of.
12381
fa96cb38
PA
123822014-02-27 Pedro Alves <palves@redhat.com>
12383
12384 PR 12702
12385 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12386 macros.
12387 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12388 output.
12389 (last_thread_of_process_p): Take a PID argument instead of a
12390 thread pointer.
12391 (linux_wait_for_lwp): Delete.
12392 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12393 functions.
12394 (linux_low_filter_event): New function, party factored out from
12395 linux_wait_for_event.
12396 (linux_wait_for_event): Rename to ...
12397 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12398 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12399 sigsuspend. Check for zombie leaders.
12400 (linux_wait_for_event): Reimplement as wrapper around
12401 linux_wait_for_event_filtered.
12402 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12403 a normal or signal exit is seen, it's the whole process exiting.
12404 (wait_for_sigstop): No longer a for_each_inferior callback.
12405 Rewrite on top of linux_wait_for_event_filtered.
12406 (stop_all_lwps): Call wait_for_sigstop directly.
12407 * server.c (resume, handle_target_event): Handle
12408 TARGET_WAITKIND_NO_RESUMED.
12409
d763de10
JB
124102014-02-26 Joel Brobecker <brobecker@adacore.com>
12411
12412 * win32-low.c (psapi_get_dll_name,
12413 * win32_CreateToolhelp32Snapshot): Delete.
12414 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12415 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12416 Delete.
12417 (handle_load_dll): Add function description.
12418 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12419
850a0f76
JB
124202014-02-26 Joel Brobecker <brobecker@adacore.com>
12421
12422 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12423 Add comment.
12424 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12425 base address when calling win32_add_one_solib.
12426 (handle_load_dll): Delete local variable load_addr.
12427 Remove 0x1000 offset applied to DLL base address when calling
12428 win32_add_one_solib.
12429 (handle_unload_dll): Add comment.
12430
f25b3fc3
JB
124312014-02-26 Joel Brobecker <brobecker@adacore.com>
12432
12433 * win32-low.c (win32_add_all_dlls): Renames
12434 win32_ensure_ntdll_loaded. Rewrite function documentation.
12435 Adjust implementation to always load all DLLs.
12436 Add 0x1000 offset to DLL base address when calling
12437 win32_add_one_solib.
12438 (child_initialization_done): New static global.
12439 (do_initial_child_stuff): Set child_initialization_done to
12440 zero during child initialization, and 1 after. Replace call
12441 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12442 Add comment.
12443 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12444 (handle_unload_dll): Add function documentation.
12445 (get_child_debug_event): Ignore load and unload DLL events
12446 during child initialization.
12447
d86d4aaf
DE
124482014-02-20 Doug Evans <dje@google.com>
12449
3bc32da3 12450 Remove global all_lwps.
d86d4aaf
DE
12451 * inferiors.h (ptid_of): Move here from linux-low.h.
12452 (pid_of, lwpid_of): Ditto.
12453 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12454 parameter is a struct thread_info * now.
12455 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12456 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12457 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12458 directly.
12459 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12460 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12461 * linux-arm-low.c (update_registers_callback): Update, "entry"
12462 parameter is a struct thread_info * now.
12463 Fetch lwpid from current_inferior directly.
12464 (arm_insert_point): Pass &all_threads to find_inferior instead of
12465 &all_lwps.
12466 (arm_remove_point): Ditto.
12467 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12468 (arm_prepare_to_resume): Fetch pid from thread.
12469 (arm_read_description): Fetch lwpid from current_inferior directly.
12470 * linux-low.c (all_lwps): Delete.
12471 (delete_lwp): Delete call to remove_inferior.
12472 (handle_extended_wait): Fetch lwpid from thread.
12473 (add_lwp): Don't set lwp->entry.id. Remove call to
12474 add_inferior_to_list.
12475 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12476 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12477 (kill_one_lwp_callback): Ditto.
12478 (linux_kill): Don't dereference NULL pointer.
12479 Fetch ptid,lwpid from thread.
12480 (get_detach_signal): Fetch ptid from thread.
12481 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12482 Simplify call to regcache_invalidate_thread.
12483 (delete_lwp_callback): Update, "entry" parameter is a
12484 struct thread_info * now. Fetch pid from thread.
12485 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12486 (status_pending_p_callback): Update, "entry" parameter is a
12487 struct thread_info * now. Fetch ptid from thread.
12488 (find_lwp_pid): Update, "entry" parameter is a
12489 struct thread_info * now.
12490 (linux_wait_for_lwp): Fetch pid from thread.
12491 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12492 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12493 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12494 (dequeue_one_deferred_signal): Ditto.
12495 (cancel_breakpoint): Fetch ptid from current_inferior.
12496 (linux_wait_for_event): Pass &all_threads to find_inferior,
12497 not &all_lwps. Fetch ptid, lwpid from thread.
12498 (count_events_callback): Update, "entry" parameter is a
12499 struct thread_info * now.
12500 (select_singlestep_lwp_callback): Ditto.
12501 (select_event_lwp_callback): Ditto.
12502 (cancel_breakpoints_callback): Ditto.
12503 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12504 not &all_lwps.
12505 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12506 (unsuspend_one_lwp): Update, "entry" parameter is a
12507 struct thread_info * now.
12508 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12509 not &all_lwps.
12510 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12511 Fetch lwpid from thread, not lwp.
12512 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12513 Pass &all_threads to find_inferior, not &all_lwps.
12514 (send_sigstop): Fetch lwpid from thread, not lwp.
12515 (send_sigstop_callback): Update, "entry" parameter is a
12516 struct thread_info * now.
12517 (suspend_and_send_sigstop_callback): Ditto.
12518 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12519 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12520 struct thread_info * now.
12521 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12522 from thread, lwp.
12523 (lwp_running): Update, "entry" parameter is a
12524 struct thread_info * now.
12525 (stop_all_lwps): Fetch ptid from thread.
12526 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12527 (linux_resume_one_lwp): Fetch lwpid from thread.
12528 (linux_set_resume_request): Update, "entry" parameter is a
12529 struct thread_info * now. Fetch pid, lwpid from thread.
12530 (resume_status_pending_p): Update, "entry" parameter is a
12531 struct thread_info * now.
12532 (need_step_over_p): Ditto. Fetch lwpid from thread.
12533 (start_step_over): Fetch lwpid from thread.
12534 (linux_resume_one_thread): Update, "entry" parameter is a
12535 struct thread_info * now. Fetch lwpid from thread.
12536 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12537 (proceed_one_lwp): Update, "entry" parameter is a
12538 struct thread_info * now. Fetch lwpid from thread.
12539 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12540 struct thread_info * now.
12541 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12542 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12543 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12544 directly.
12545 (regsets_store_inferior_registers): Ditto.
12546 (fetch_register, store_register): Ditto.
12547 (linux_read_memory, linux_write_memory): Ditto.
12548 (linux_request_interrupt): Ditto.
12549 (linux_read_auxv): Ditto.
12550 (linux_xfer_siginfo): Ditto.
12551 (linux_qxfer_spu): Ditto.
12552 (linux_qxfer_libraries_svr4): Ditto.
12553 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12554 moved to inferiors.h.
12555 (get_lwp): Delete.
12556 (get_thread_lwp): Update.
12557 (struct lwp_info): Delete member "entry". Simplify comment for
12558 member "thread".
12559 (all_lwps): Delete.
12560 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12561 current_inferior directly.
12562 (update_watch_registers_callback): Update, "entry" parameter is a
12563 struct thread_info * now. Fetch pid from thread.
12564 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12565 (mips_insert_point): Fetch lwpid from current_inferior.
12566 Pass &all_threads to find_inferior, not &all_lwps.
12567 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12568 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12569 directly.
12570 (mips_stopped_data_address): Ditto.
12571 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12572 directly.
12573 * linux-tile-low.c (tile_arch_setup): Ditto.
12574 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12575 (update_debug_registers_callback): Update, "entry" parameter is a
12576 struct thread_info * now. Fetch pid from thread.
12577 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12578 Pass &all_threads to find_inferior, not &all_lwps.
12579 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12580 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12581 Pass &all_threads to find_inferior, not &all_lwps.
12582 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12583 (i386_dr_low_get_status): Ditto.
12584 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12585 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12586 (x86_linux_read_description): Ditto.
12587 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12588
3b8361aa
DE
125892014-02-20 Doug Evans <dje@google.com>
12590
12591 * inferiors.c (get_first_inferior): Fix buglet.
12592
f7667f0d
DE
125932014-02-19 Doug Evans <dje@google.com>
12594
12595 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12596 * inferiors.c (add_thread): Change result type to struct thread_info *.
12597 All callers updated.
12598 (add_lwp): Call add_thread here instead of in callers.
12599 All callers updated.
12600 * linux-low.h (get_lwp_thread): Rewrite.
12601 (struct lwp_info): New member "thread".
12602
b3312d80
DE
126032014-02-19 Doug Evans <dje@google.com>
12604
12605 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12606 All callers updated.
12607
ecc6f45c
DE
126082014-02-19 Doug Evans <dje@google.com>
12609
12610 * inferiors.c (add_thread): Fix whitespace.
12611
649ebbca
DE
126122014-02-19 Doug Evans <dje@google.com>
12613
12614 * dll.c (clear_dlls): Replace accessing list implemention details
12615 with API function.
12616 * gdbthread.h (get_first_thread): Declare.
12617 * inferiors.c (for_each_inferior_with_data): New function.
12618 (get_first_thread): New function.
12619 (find_thread_ptid): Simplify.
12620 (get_first_inferior): New function.
12621 (clear_list): Delete.
12622 (one_inferior_p): New function.
12623 (clear_inferior_list): New function.
12624 (clear_inferiors): Update.
12625 * inferiors.h (for_each_inferior_with_data): Declare.
12626 (clear_inferior_list): Declare.
12627 (one_inferior_p): Declare.
12628 (get_first_inferior): Declare.
12629 * linux-low.c (linux_wait_for_event): Replace accessing list
12630 implemention details with API function.
12631 * server.c (target_running): Ditto.
12632 (accumulate_file_name_length): New function.
12633 (emit_dll_description): New function.
12634 (handle_qxfer_libraries): Replace accessing list implemention
12635 details with API function.
12636 (handle_qxfer_threads_worker): New function.
12637 (handle_qxfer_threads_proper): Replace accessing list implemention
12638 details with API function.
12639 (handle_query): Ditto.
12640 (visit_actioned_threads_callback_ftype): New typedef.
12641 (visit_actioned_threads_data): New struct.
12642 (visit_actioned_threads): Rewrite to be find_inferior callback.
12643 (resume): Call find_inferior.
12644 (handle_status): Replace accessing list implemention
12645 details with API function.
12646 (process_serial_event): Replace accessing list implemention details
12647 with API function.
12648 * target.c (set_desired_inferior): Replace accessing list implemention
12649 details with API function.
12650 * tracepoint.c (same_process_p): New function.
12651 (gdb_agent_about_to_close): Replace accessing list implemention
12652 details with API function.
12653 * win32-low.c (child_delete_thread): Replace accessing list
12654 implemention details with API function.
12655 (match_dll_by_basename): New function.
12656 (dll_is_loaded_by_basename): New function.
12657 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12658 details call to dll_is_loaded_by_basename.
12659
80894984
DE
126602014-02-19 Doug Evans <dje@google.com>
12661
12662 * dll.h (struct dll_info): Add comment.
12663 * gdbthread.h (struct thread_info): Add comment.
12664 (current_ptid): Simplify.
12665 * inferiors.c (add_process): Update.
12666 (remove_process): Update.
12667 * inferiors.h (struct process_info): Rename member "head" to "entry".
12668 * linux-low.c (delete_lwp): Update.
12669 (add_lwp): Update.
12670 (last_thread_of_process_p): Update.
12671 (kill_one_lwp_callback, linux_kill): Update.
12672 (status_pending_p_callback): Update.
12673 (wait_for_sigstop): Update. Simplify read of ptid.
12674 (start_step_over): Update.
12675 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12676 (get_lwp_thread): Update.
12677 (struct lwp_info): Rename member "head" to "entry".
12678 * regcache.h (inferior_list_entry): Delete.
12679 * server.c (kill_inferior_callback): Update.
12680 (detach_or_kill_inferior_callback): Update.
12681 (print_started_pid): Update.
12682 (print_attached_pid): Update.
12683 (process_serial_event): Simplify read of ptid.
12684 * thread-db.c (thread_db_create_event): Update.
12685 (thread_db_get_tls_address): Update.
12686 * win32-low.c (current_inferior_ptid): Simplify.
12687
46917d26
TT
126882014-02-19 Tom Tromey <tromey@redhat.com>
12689
12690 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12691 argument.
12692 (target_supports_btrace): Update.
12693
0759a81e
YQ
126942014-02-14 Yao Qi <yao@codesourcery.com>
12695
12696 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12697 (rsp-low-ipa.o): New target.
12698
a7191e8b
TT
126992014-02-12 Tom Tromey <tromey@redhat.com>
12700
12701 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12702 convert_ascii_to_int.
12703 * regcache.c (registers_to_string): Likewise.
12704 * remote-utils.c (decode_M_packet): Likewise.
12705 * server.c (process_serial_event): Likewise.
12706
ff0e980e
TT
127072014-02-12 Tom Tromey <tromey@redhat.com>
12708
12709 * server.c (handle_query, handle_v_run): Use hex2bin, not
12710 unhexify.
12711 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12712
e9371aff
TT
127132014-02-12 Tom Tromey <tromey@redhat.com>
12714
12715 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12716 convert_int_to_ascii.
12717 * regcache.c (registers_to_string, collect_register_as_string):
12718 Likewise.
12719 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12720 Likewise.
12721 * server.c (process_serial_event): Likewise.
12722 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12723 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
12724
971dc0b8
TT
127252014-02-12 Tom Tromey <tromey@redhat.com>
12726
12727 * remote-utils.c (look_up_one_symbol, monitor_output): Use
12728 bin2hex, not hexify.
12729 * tracepoint.c (cmd_qtstatus): Likewise.
12730
0a822afb
TT
127312014-02-12 Tom Tromey <tromey@redhat.com>
12732
12733 * remote-utils.c (monitor_output): Pass explicit length to
12734 hexify.
12735
9c3d6531
TT
127362014-02-12 Tom Tromey <tromey@redhat.com>
12737
12738 * tracepoint.c: Include rsp-low.h.
12739 * server.c: Include rsp-low.h.
12740 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
12741 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
12742 declare.
12743 * remote-utils.c: Include rsp-low.h.
12744 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
12745 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
12746 (convert_int_to_ascii, convert_ascii_to_int): Move to
12747 common/rsp-low.c.
12748 * regcache.c: Include rsp-low.h.
12749 * ax.c: Include rsp-low.h.
12750 * Makefile.in (SFILES): Add common/rsp-low.c.
12751 (OBS): Add rsp-low.o.
12752 (rsp-low.o): New target.
12753
01fd3ea5
TT
127542014-02-12 Tom Tromey <tromey@redhat.com>
12755
12756 * utils.h (pulongest, plongest, phex_nz): Don't declare.
12757 Include print-utils.h.
12758 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
12759 (plongest, thirty_two, phex_nz): Remove.
12760 * Makefile.in (SFILES): Add common/print-utils.c.
12761 (OBS): Add print-utils.o.
12762 (print-utils-ipa.o): New target.
12763 (print-utils.o): New target.
12764 (IPA_OBJS): Add print-utils-ipa.o.
12765
e99dc820
TT
127662014-02-06 Tom Tromey <tromey@redhat.com>
12767
12768 * Makefile.in (SFILES): Fix indentation.
12769
ee1e2d4f
DE
127702014-02-05 Doug Evans <dje@google.com>
12771
12772 * linux-low.c (linux_wait_for_event): Improve comment.
12773 (linux_wait_1): Keep current_inferior in sync with event_child.
12774
f5a02773
DE
127752014-01-22 Doug Evans <dje@google.com>
12776
12777 * gdbthread.h (gdb_id_to_thread): Delete, unused.
12778
87ce2a04
DE
127792014-01-22 Doug Evans <dje@google.com>
12780
12781 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
12782 * configure: Regenerate.
12783 * config.in: Regenerate.
12784 * Makefile.in (SFILES): Add debug.c.
12785 (OBS): Add debug.o.
12786 * debug.c: New file.
12787 * debug.h: New file.
12788 * linux-aarch64-low.c (*): Update all debugging printfs to use
12789 debug_printf instead of fprintf.
12790 * linux-arm-low.c (*): Ditto.
12791 * linux-cris-low.c (*): Ditto.
12792 * linux-crisv32-low.c (*): Ditto.
12793 * linux-m32r-low.c (*): Ditto.
12794 * linux-sparc-low.c (*): Ditto.
12795 * linux-x86.c (*): Ditto.
12796 * linux-low.c (*): Ditto.
12797 (linux_wait_1): Add calls to debug_enter, debug_exit.
12798 (linux_wait): Remove redundant debugging printf.
12799 (stop_all_lwps): Add calls to debug_enter, debug_exit.
12800 (linux_resume, unstop_all_lwps): Ditto.
12801 * mem-break.c (*): Update all debugging printfs to use
12802 debug_printf instead of fprintf.
12803 * remote-utils.c (*): Ditto.
12804 * thread-db.c (*): Ditto.
12805 * server.c #include <ctype.h>, "gdb_vecs.h".
12806 (debug_threads): Moved to debug.c.
12807 (*): Update all debugging printfs to use debug_printf instead of
12808 fprintf.
12809 (start_inferior): Replace call to fflush with call to debug_flush.
12810 (monitor_show_help): Mention set debug-format.
12811 (parse_debug_format_options): New function.
12812 (handle_monitor_command): Handle "monitor set debug-format".
12813 (gdbserver_usage): Mention --debug-format.
12814 (main): Parse --debug-format.
12815 * server.h (debug_threads): Declaration moved to debug.h.
12816 #include "debug.h".
12817 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
12818 trace_debug_1 that uses debug_printf.
12819 (tracepoint_look_up_symbols): Update all debugging printfs to use
12820 debug_printf instead of fprintf.
12821
e671835b
BS
128222014-01-20 Baruch Siach <baruch@tkos.co.il>
12823
12824 * linux-xtensa-low.c: Include asm/ptrace.h instead of
12825 sys/ptrace.h.
12826
b5737fa9
PA
128272014-01-17 Pedro Alves <palves@redhat.com>
12828
ea38d2a9 12829 PR build/16445
c7faa97a
PA
12830 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
12831 defined after including gdb_proc_service.h.
b5737fa9 12832
40ed484e
DE
128332014-01-16 Doug Evans <dje@google.com>
12834
12835 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
12836 (match_dll): Use it.
12837
969c39fb
MM
128382014-01-16 Markus Metzger <markus.t.metzger@intel.com>
12839
12840 * target.h (target_ops) <read_btrace>: Change parameters and
12841 return type to allow error reporting.
12842 * server.c (handle_qxfer_btrace): Support delta reads. Pass
12843 trace reading errors on.
12844 * linux-low.c (linux_low_read_btrace): Pass trace reading
12845 errors on.
12846 (linux_low_disable_btrace): New.
12847
ab7f45ba
DE
128482014-01-15 Doug Evans <dje@google.com>
12849
12850 * inferiors.c (thread_id_to_gdb_id): Delete.
12851 * inferiors.h (thread_id_to_gdb_id): Delete.
12852
66af0f44
EZ
128532014-01-13 Eli Zaretskii <eliz@gnu.org>
12854
12855 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
12856 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
12857 versions.
12858
9939e131
PA
128592014-01-08 Pedro Alves <palves@redhat.com>
12860
12861 * server.c (handle_status): Don't discard previous queued stop
12862 replies or thread's pending status here.
12863 (main) <disconnection>: Do it here instead.
12864
b7ea362b
PA
128652014-01-08 Pedro Alves <palves@redhat.com>
12866
12867 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
12868 * server.c (visit_actioned_threads, handle_pending_status): New
12869 function.
12870 (handle_v_cont): Factor out parts to ...
12871 (resume): ... this new function. If in all-stop, and a thread
12872 being resumed has a pending status, report it without actually
12873 resuming.
12874 (myresume): Adjust to use the new 'resume' function.
12875 (clear_pending_status_callback, set_pending_status_callback)
12876 (find_status_pending_thread_callback): New functions.
12877 (handle_status): Handle the case of multiple threads having
12878 interesting statuses to report. Report threads' real last signal
12879 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
12880 with an interesting thread to report the status for, instead of
12881 always reporting the status of the first thread.
12882
28498c42
JB
128832014-01-01 Joel Brobecker <brobecker@adacore.com>
12884
12885 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
12886 * gdbreplay.c (gdbreplay_version): Likewise.
12887
f45c82da
YZ
128882013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
12889
12890 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
12891 iov.iov_len with the real length in use.
12892
379a5e2d
JB
128932013-12-13 Joel Brobecker <brobecker@adacore.com>
12894
12895 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
12896 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
12897 for all targets that use win32-low.c.
12898 * win32-low.c (win32_ensure_ntdll_loaded): New function.
12899 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
12900
4210d83e
PA
129012013-12-13 Pedro Alves <palves@redhat.com>
12902
12903 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
12904 if equal to TARGET_WAITKIND_LOADED.
12905 * win32-low.c (cached_status): New static global.
12906 (win32_wait): Add declaration.
12907 (do_initial_child_stuff): Flush all initial pending debug events
12908 up to the initial breakpoint.
12909 (win32_wait): If CACHED_STATUS was set, return that instead
12910 of doing a real wait. Remove the code resuming the execution
12911 of the inferior after receiving a TARGET_WAITKIND_LOADED event
12912 during the initial phase. Also remove the code changing
12913 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
12914 TARGET_WAITKIND_STOPPED.
12915
e7f0d979
YQ
129162013-12-11 Yao Qi <yao@codesourcery.com>
12917
12918 * notif.c (handle_notif_ack): Return 0 if no notification
12919 matches.
12920
ebcf782c
DE
129212013-11-20 Doug Evans <dje@google.com>
12922
12923 * linux-low.c (linux_set_resume_request): Fix comment.
12924
20ad9378
DE
129252013-11-20 Doug Evans <dje@google.com>
12926
12927 * linux-low.c (resume_status_pending_p): Tweak comment.
12928
a196ebeb
WT
129292013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
12930
12931 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
12932 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
12933 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
12934 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
12935 (srv_amd64_regobj): Add amd64-mpx.o.
12936 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
12937 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
12938 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
12939 * i387-fp.c (num_pl_bnd_register) Added constant.
12940 (num_pl_bnd_cfg_registers) Added constant.
12941 (struct i387_xsave) Added reserved area and MPX fields.
12942 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
12943 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
12944 function.
12945 (tdesc_i386_mpx_linux): Add MPX amd64 target.
12946 (init_registers_amd64_mpx_linux): Declare new function.
12947 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
12948 (x86_64_regmap): Add MPX registers.
12949 (x86_linux_read_description): Add MPX case.
12950 (initialize_low_arch): Initialize MPX targets.
12951
0080a2f6
TT
129522013-11-18 Tom Tromey <tromey@redhat.com>
12953
12954 * configure: Rebuild.
12955 * configure.ac: Don't check for stdlib.h.
12956 * gdbreplay.c: Unconditionally include stdlib.h.
12957
2978b111
TT
129582013-11-18 Tom Tromey <tromey@redhat.com>
12959
12960 * config.in: Rebuild.
12961 * configure: Rebuild.
12962 * configure.ac: Don't use AC_HEADER_DIRENT.
12963
a3d08894
TT
129642013-11-18 Tom Tromey <tromey@redhat.com>
12965
12966 * server.h: Don't check HAVE_STRING_H.
12967 * gdbreplay.c: Don't check HAVE_STRING_H.
12968 * configure: Rebuild.
12969
0a5dd17d
TT
129702013-11-18 Tom Tromey <tromey@redhat.com>
12971
12972 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
12973 LIBGNU.
12974
1bd2f0ba
TT
129752013-11-08 Tom Tromey <tromey@redhat.com>
12976
12977 * configure, config.in: Rebuild.
12978 * configure.ac: Remove unused configury.
12979
3266f10b
TT
129802013-11-08 Tom Tromey <tromey@redhat.com>
12981
12982 * acinclude.m4: Include common.m4, codeset.m4.
12983 * configure, config.in: Rebuild.
12984 * configure.ac: Use GDB_AC_COMMON.
12985
6682d959
AA
129862013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
12987
12988 * linux-s390-low.c (HWCAP_S390_TE): New define.
12989 (s390_arch_setup): Consider the TE field in the HWCAP for
12990 determining 'have_regset_tdb'.
12991
fd0a4d76
SDJ
129922013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
12993
12994 PR gdb/16014
12995 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
12996 call to sizeof.
12997
1a3d890b
PA
129982013-10-02 Pedro Alves <palves@redhat.com>
12999
13000 * server.c (process_serial_event): Don't output "GDBserver
13001 exiting" if GDB is connected through stdio.
13002 * target.c (mywait): Likewise, be silent if GDB is connected
13003 through stdio.
13004
97ad4581
JB
130052013-10-01 Joel Brobecker <brobecker@adacore.com>
13006
13007 * lynx-low.c (lynx_add_threads_after_attach): New function.
13008 (lynx_attach): Remove call to add_thread. Add call to
13009 lynx_add_threads_after_attach instead.
13010
5b4e221c
MF
130112013-09-28 Mike Frysinger <vapier@gentoo.org>
13012
13013 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13014 * config.in, configure: Regenerated.
13015
ee47b2f8
YQ
130162013-09-18 Yao Qi <yao@codesourcery.com>
13017
13018 PR server/15959
13019 * server.c (start_inferior): Clear 'resume_info'.
13020
d6707650 130212013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13022
d6707650
JW
13023 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13024 for each register.
13025
9243dd0e 130262013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13027
9243dd0e
JW
13028 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13029 linux-tile-low.o to srv_tgtobj.
13030
c623a6ef
WN
130312013-09-16 Will Newton <will.newton@linaro.org>
13032
13033 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13034 out regs.
13035
fb71d39e
PA
130362013-09-06 Pedro Alves <palves@redhat.com>
13037
13038 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13039 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13040 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13041 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13042 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13043 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13044
8e7e9910
PA
130452013-09-06 Pedro Alves <palves@redhat.com>
13046
13047 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13048 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13049
7c3a12ca
PA
130502013-09-06 Pedro Alves <palves@redhat.com>
13051
13052 * linux-amd64-ipa.c: Include tracepoint.h.
13053 * linux-i386-ipa.c: Include tracepoint.h.
13054
8eb3d7b6
RW
130552013-09-06 Ricard Wanderlof <ricardw@axis.com>
13056
13057 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13058 (ps_get_thread_area): New function.
13059
eddddb9d
RW
130602013-09-06 Ricard Wanderlof <ricardw@axis.com>
13061
13062 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13063 (initialize_low_arch): Call init_registers_crisv32 rather than
13064 init_register_crisv32.
13065
533b0600
PA
130662013-09-05 Pedro Alves <palves@redhat.com>
13067
13068 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13069 to ...
13070 * hostio.h: ... this new file.
13071 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13072 win32-low.c: Include hostio.h.
13073
0ce3d3b5
PA
130742013-09-05 Pedro Alves <palves@redhat.com>
13075
13076 * server.h (gdb_client_data, handler_func, callback_handler_func)
13077 (delete_file_handler, add_file_handler, append_callback_event)
13078 (delete_callback_event, start_event_loop, initialize_event_loop):
13079 Move to event-loop.h and include it.
13080 * event-loop.h: New file.
13081
799cdc37
PA
130822013-09-05 Pedro Alves <palves@redhat.com>
13083
13084 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13085 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13086 (loaded_dll, unloaded_dll): Move to ...
13087 * dll.h: ... this new file.
13088 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13089
6a6bbd9d
PA
130902013-09-05 Pedro Alves <palves@redhat.com>
13091
13092 * server.h (current_process, get_thread_process, all_processes)
13093 (add_inferior_to_list, for_each_inferior, current_inferior)
13094 (remove_inferior, add_process, remove_process, find_process_pid)
13095 (have_started_inferiors_p, have_attached_inferiors_p)
13096 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13097 (clear_inferiors, find_inferior, find_inferior_id)
13098 (inferior_target_data, set_inferior_target_data)
13099 (inferior_regcache_data, set_inferior_regcache_data): Move to
13100 inferiors.h, and include it.
13101 * inferiors.h: New file.
13102
f699aaba
PA
131032013-09-05 Pedro Alves <palves@redhat.com>
13104
13105 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13106 Move ...
72f4393d 13107 * ax.h: ... here.
f699aaba 13108
c144c7a0
PA
131092013-09-05 Pedro Alves <palves@redhat.com>
13110
13111 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13112 tracepoint.h.
13113 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13114 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13115 (handle_tracepoint_general_set, handle_tracepoint_query)
13116 (tracepoint_finished_step, tracepoint_was_hit)
13117 (release_while_stepping_state_list, current_traceframe)
13118 (in_readonly_region, traceframe_read_mem)
13119 (fetch_traceframe_registers, traceframe_read_sdata)
13120 (traceframe_read_info, struct fast_tpoint_collect_status)
13121 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13122 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13123 (supply_fast_tracepoint_registers)
13124 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13125 (ipa_tdesc, claim_trampoline_space)
13126 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13127 (agent_mem_read, agent_get_trace_state_variable_value)
13128 (agent_set_trace_state_variable_value, agent_tsv_read)
13129 (agent_mem_read_string, get_raw_reg_func_addr)
13130 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13131 * tracepoint.h: ... this new file.
13132
ff42e6ab
PA
131332013-09-05 Pedro Alves <palves@redhat.com>
13134
13135 * server.h (perror_with_name, error, fatal, warning, paddress)
13136 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13137 include it.
13138 * utils.h: New file.
13139
541af0f4
PA
131402013-09-05 Pedro Alves <palves@redhat.com>
13141
13142 * server.h (remote_debug, noack_mode, transport_is_reliable)
13143 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13144 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13145 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13146 (write_enn, initialize_async_io, enable_async_io)
13147 (disable_async_io, check_remote_input_interrupt_request)
13148 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13149 (dead_thread_notify, prepare_resume_reply)
13150 (decode_address_to_semicolon, decode_address, decode_m_packet)
13151 (decode_M_packet, decode_X_packet, decode_xfer_write)
13152 (decode_search_memory_packet, unhexify, hexify)
13153 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13154 (look_up_one_symbol, relocate_instruction)
13155 (monitor_output): Move to remote-utils.h, and include it.
13156 * remote-utils.h: New file.
13157
eebdf26b
PA
131582013-09-05 Pedro Alves <palves@redhat.com>
13159
13160 * server.h (_): Delete.
13161
3aafd2ff
PA
131622013-09-02 Pedro Alves <palves@redhat.com>
13163
13164 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13165 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13166 allocated.
13167 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13168
cee83bcb
PM
131692013-09-02 Pierre Muller <muller@sourceware.org>
13170
13171 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13172 or WriteProcessMemory complete successfully and handle
13173 ERROR_PARTIAL_COPY error.
13174
9a13b2fa
PA
131752013-09-02 Pedro Alves <palves@redhat.com>
13176
13177 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13178 error instead of EIO.
13179
602e3198
JK
131802013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13181
13182 PR server/15604
13183 * linux-low.c: Include filestuff.h.
13184 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13185 * lynx-low.c: Include filestuff.h.
13186 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13187 * server.c: Include filestuff.h.
13188 (main): Call notice_open_fds.
13189 * spu-low.c: Include filestuff.h.
13190 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13191
96d7229d
LM
131922013-08-22 Luis Machado <lgustavo@codesourcery.com>
13193
13194 * Makefile.in: Explain why ../target and ../nat are not
13195 listed as include file search paths.
13196 (linux-waitpid.o): New object file rule.
13197 * configure.srv (srv_native_linux_obj): New variable.
13198 Replace all occurrences of linux native object files with
13199 $srv_native_linux_obj.
13200 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13201 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13202 (linux_enable_event_reporting): Remove declaration.
13203 (my_waitpid): Moved to common/linux-waitpid.c.
13204 (linux_wait_for_event): Pass ptid when calling
13205 linux_enable_event_reporting.
13206 (linux_supports_tracefork_flag): Remove.
13207 (linux_enable_event_reporting): Likewise.
13208 (linux_tracefork_grandchild): Remove.
13209 (STACK_SIZE): Moved to common/linux-ptrace.c.
13210 (linux_tracefork_child): Remove.
13211 (linux_test_for_tracefork): Remove.
13212 (linux_look_up_symbols): Call linux_supports_traceclone.
13213 (initialize_low): Remove call to linux_test_for_tracefork.
13214 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13215 common/linux-ptrace.h.
13216 (PTRACE_TYPE_ARG4): Likewise.
13217 Include linux-ptrace.h.
13218
32940073
PA
132192013-08-21 Pedro Alves <palves@redhat.com>
13220
13221 * config.in: Renegerate.
13222
33b60d58 132232013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 13224
33b60d58
LM
13225 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13226 (SFILES): Remove $(srcdir)/common/target-common.c and
13227 add $(srcdir)/target/waitstatus.c.
13228 (OBS): Remove target-common.o and add waitstatus.o.
13229 (server_h): Remove $(srcdir)/../common/target-common.h and
13230 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13231 and $(srcdir)/../target/waitstatus.h.
13232 (target-common.o): Remove.
13233 (waitstatus.o): New target object file.
13234 * target.h: Do not include target-common.h and
13235 include target/resume.h, target/wait.h and
13236 target/waitstatus.h.
13237
b8e1b30e
LM
132382013-08-13 Luis Machado <lgustavo@codesourcery.com>
13239
13240 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13241 to PTRACE_TYPE_ARG3.
13242 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13243 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13244 PTRACE_TYPE_ARG4.
13245 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13246 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13247
7a60ad40
YQ
132482013-07-27 Jie Zhang <jie@codesourcery.com>
13249 Daniel Jacobowitz <dan@codesourcery.com>
13250 Yao Qi <yao@codesourcery.com>
13251
13252 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13253 (mips-linux-watch.o): New rule.
13254 (mips_linux_watch_h): New variable.
13255 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13256 srv_tgtobj.
13257 * linux-mips-low.c: Include mips-linux-watch.h.
13258 (struct arch_process_info, struct arch_lwp_info): New.
13259 (update_watch_registers_callback): New function.
13260 (mips_linux_new_process, mips_linux_new_thread) New functions.
13261 (mips_linux_prepare_to_resume, mips_insert_point): New
13262 functions.
13263 (mips_remove_point, mips_stopped_by_watchpoint): New
13264 functions.
13265 (rsp_bp_type_to_target_hw_bp_type): New function.
13266 (mips_stopped_data_address): New function.
13267 (the_low_target): Add watchpoint support functions.
13268
de6f69ad
YQ
132692013-07-27 Yao Qi <yao@codesourcery.com>
13270
13271 * i386-low.c: Include break-common.h.
13272 (enum target_hw_bp_type): Remove.
13273
3360c0bf
LM
132742013-07-24 Luis Machado <lgustavo@codesourcery.com>
13275
13276 * Makefile.in (SFILES): /common/target-common.c.
13277 (OBS): Add target-common.o.
13278 (server_h): Add $(srcdir)/../common/target-common.h.
13279 (target-common.o): New target.
13280 * server.c (queue_stop_reply_callback): Free
13281 status string after use.
13282 * target.c (target_waitstatus_to_string): Remove.
13283 * target.h: Include target-common.h.
13284 (resume_kind): Likewise.
13285 (target_waitkind): Likewise.
13286 (target_waitstatus): Likewise.
13287 (TARGET_WNOHANG): Likewise.
13288
bd885420
YQ
132892013-07-04 Yao Qi <yao@codesourcery.com>
13290
13291 * Makefile.in (host_alias): Use @host_noncanonical@.
13292 (target_alias): Use @target_noncanonical@.
13293 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13294 ACX_NONCANONICAL_HOST.
13295 * configure: Regenerated.
13296
13297 Revert:
13298 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13299
13300 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13301 * configure: Rebuild.
13302 * Makefile.in (version_host, version_target): Get from configure.
13303 (version.c): Use $(version_host) and $(version_target).
13304
17ef446e
PA
133052013-07-03 Pedro Alves <palves@redhat.com>
13306
13307 * Makefile.in (config.status): Depend on development.sh.
13308 * acinclude.m4: Include libmcheck.m4.
13309 * configure: Regenerate.
13310
7a9a7487
MG
133112013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13312
13313 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13314 attribute inside the parentheses.
13315 (winapi_DebugSetProcessKillOnExit): Ditto.
13316 (winapi_DebugBreakProcess): Ditto.
13317 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 13318
49b64de6
MG
133192013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13320
13321 * notif.h (notif_event): Add a dummy member to avoid compiler
13322 errors.
13323
d5749ee7
PA
133242013-07-01 Pedro Alves <palves@redhat.com>
13325
13326 * hostio.c (HOSTIO_PATH_MAX): Define.
13327 (require_filename, handle_open, handle_unlink, handle_readlink):
13328 Use it.
13329
d8d2a3ee
PA
133302013-07-01 Pedro Alves <palves@redhat.com>
13331
13332 * server.h: Include "pathmax.h".
13333 * linux-low.c: Don't include sys/param.h.
13334 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13335 MAXPATHLEN.
13336 * win32-low.c: Don't include sys/param.h.
13337 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13338
bc7dea8d
PA
133392013-07-01 Pedro Alves <palves@redhat.com>
13340
13341 * event-loop.c: Don't check HAVE_UNISTD_H before including
13342 <unistd.h>.
13343 * gdbreplay.c: Likewise.
13344 * remote-utils.c: Likewise.
13345 * server.c: Likewise.
13346 * configure.ac: Don't check for unistd.h.
13347 * configure: Regenerate.
13348
d6c2da54
TT
133492013-06-28 Tom Tromey <tromey@redhat.com>
13350
13351 * Makefile.in (version.c): Use version.in, not
13352 common/version.in.
13353
257b6bec
MG
133542013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13355
13356 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13357 * configure: Rebuild.
13358 * Makefile.in (version_host, version_target): Get from configure.
13359 (version.c): Use $(version_host) and $(version_target).
13360
86ebe149
DK
133612013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13362
13363 Fix trace-status to output user name without trailing colon.
13364 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13365
f30aa5af
DK
133662013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13367
13368 Fix trace-status to output proper start-time and stop-time.
13369 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13370 output start time and stop time in hex as gdb expects.
13371
28a93511
YQ
133722013-06-26 Pedro Alves <pedro@codesourcery.com>
13373
13374 * tracepoint.c (build_traceframe_info_xml): Output trace state
13375 variables present in the trace buffer.
13376
01208463
TT
133772013-06-24 Tom Tromey <tromey@redhat.com>
13378
13379 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13380 create-version.sh.
13381 (version.o): Remove.
13382 * gdbreplay.c: Include version.h.
13383 (version, host_name): Don't declare.
13384 * server.h: Include version.h.
13385 (version, host_name): Don't declare.
13386
760256f9
PA
133872013-06-12 Pedro Alves <palves@redhat.com>
13388
13389 * linux-x86-low.c (linux_is_elf64): Delete global.
13390 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13391 with local linux_pid_exe_is_elf_64_file use.
13392
030031ee
PA
133932013-06-11 Pedro Alves <palves@redhat.com>
13394
13395 * linux-low.c (regset_disabled, disable_regset): New functions.
13396 (regsets_fetch_inferior_registers)
13397 (regsets_store_inferior_registers): Use them.
13398 (initialize_regsets_info); Don't allocate the disabled_regsets
13399 array here.
13400 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13401 comment.
13402
5da6eb0a
PA
134032013-06-11 Pedro Alves <palves@redhat.com>
13404
13405 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13406 xmalloc.
13407
7e5aaa09
PA
134082013-06-11 Pedro Alves <palves@redhat.com>
13409
13410 * linux-x86-low.c (initialize_low_arch): Call
13411 init_registers_x32_avx_linux.
13412
d878444c
JK
134132013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13414
13415 Fix compatibility with Android Bionic.
13416 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13417 it is not empty.
13418
3aee8918
PA
134192013-06-07 Pedro Alves <palves@redhat.com>
13420
5f2b57b5 13421 PR server/14823
3aee8918
PA
13422 * Makefile.in (OBS): Add tdesc.o.
13423 (IPA_OBJS): Add tdesc-ipa.o.
13424 (tdesc-ipa.o): New rule.
13425 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13426 interface.
13427 * linux-low.c (new_inferior): Delete.
13428 (disabled_regsets, num_regsets): Delete.
13429 (linux_add_process): Adjust to set the new per-process
13430 new_inferior flag.
13431 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13432 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13433 was a stop. When calling arch_setup, switch the current inferior
13434 to the thread that got an event.
13435 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13436 (regsets_fetch_inferior_registers)
13437 (regsets_store_inferior_registers): New regsets_info parameter.
13438 Adjust to use it.
13439 (linux_register_in_regsets): New regs_info parameter. Adjust to
13440 use it.
13441 (register_addr, fetch_register, store_register): New usrregs_info
13442 parameter. Adjust to use it.
13443 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13444 parameter regs_info. Adjust to use it.
13445 (linux_fetch_registers): Get the current inferior's regs_info, and
13446 adjust to use it.
13447 (linux_store_registers): Ditto.
13448 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13449 (initialize_low): Don't initialize the target_regsets here. Call
13450 initialize_low_arch.
13451 * linux-low.h (target_regsets): Delete declaration.
13452 (struct regsets_info): New.
13453 (struct usrregs_info): New.
13454 (struct regs_info): New.
13455 (struct process_info_private) <new_inferior>: New field.
13456 (struct linux_target_ops): Delete the num_regs, regmap, and
13457 regset_bitmap fields. New field regs_info.
13458 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13459 * i387-fp.c (num_xmm_registers): Delete.
13460 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13461 calls to new interface.
13462 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13463 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13464 Infer the number of xmm registers from the regcache's target
13465 description.
13466 * i387-fp.h (num_xmm_registers): Delete.
13467 * inferiors.c (add_thread): Don't install the thread's regcache
13468 here.
13469 * proc-service.c (gregset_info): Fetch the current inferior's
13470 regs_info. Adjust to use it.
13471 * regcache.c: Include tdesc.h.
13472 (register_bytes, reg_defs, num_registers)
13473 (gdbserver_expedite_regs): Delete.
13474 (get_thread_regcache): If the thread doesn't have a regcache yet,
13475 create one, instead of aborting gdbserver.
13476 (regcache_invalidate_one): Rename to ...
13477 (regcache_invalidate_thread): ... this.
13478 (regcache_invalidate_one): New.
13479 (regcache_invalidate): Only invalidate registers of the current
13480 process.
13481 (init_register_cache): Add target_desc parameter, and use it.
13482 (new_register_cache): Ditto. Assert the target description has a
13483 non zero registers_size.
13484 (regcache_cpy): Add assertions. Adjust.
13485 (realloc_register_cache, set_register_cache): Delete.
13486 (registers_to_string, registers_from_string): Adjust.
13487 (find_register_by_name, find_regno, find_register_by_number)
13488 (register_cache_size): Add target_desc parameter, and use it.
13489 (free_register_cache_thread, free_register_cache_thread_one)
13490 (regcache_release, register_cache_size): New.
13491 (register_size): Add target_desc parameter, and use it.
13492 (register_data, supply_register, supply_register_zeroed)
13493 (supply_regblock, supply_register_by_name, collect_register)
13494 (collect_register_as_string, collect_register_by_name): Adjust.
13495 * regcache.h (struct target_desc): Forward declare.
13496 (struct regcache) <tdesc>: New field.
13497 (init_register_cache, new_register_cache): Add target_desc
13498 parameter.
13499 (regcache_invalidate_thread): Declare.
13500 (regcache_invalidate_one): Delete declaration.
13501 (regcache_release): Declare.
13502 (find_register_by_number, register_cache_size, register_size)
13503 (find_regno): Add target_desc parameter.
13504 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13505 declarations.
13506 * remote-utils.c: Include tdesc.h.
13507 (outreg, prepare_resume_reply): Adjust.
13508 * server.c: Include tdesc.h.
13509 (gdbserver_xmltarget): Delete declaration.
13510 (get_features_xml, process_serial_event): Adjust.
13511 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13512 declare.
13513 (struct process_info) <tdesc>: New field.
13514 (ipa_tdesc): Declare.
13515 * tdesc.c: New file.
13516 * tdesc.h: New file.
13517 * tracepoint.c: Include tdesc.h.
13518 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13519 (get_context_regcache): Adjust to pass ipa_tdesc down.
13520 (do_action_at_tracepoint): Adjust to get the register cache size
13521 from the context regcache's description.
13522 (traceframe_walk_blocks): Adjust to get the register cache size
13523 from the current trace frame's description.
13524 (traceframe_get_pc): Adjust to get current trace frame's
13525 description and pass it down.
13526 (gdb_collect): Adjust to get the register cache size from the
13527 IPA's description.
13528 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13529 (gdbserver_xmltarget): Delete.
13530 (initialize_low_tracepoint): Set the ipa's target description.
13531 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13532 (initialize_low_tracepoint): Set the ipa's target description.
13533 * linux-x86-low.c: Include tdesc.h.
13534 [__x86_64__] (is_64bit_tdesc): New.
13535 (ps_get_thread_area, x86_get_thread_area): Use it.
13536 (i386_cannot_store_register): Rename to ...
13537 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13538 (i386_cannot_fetch_register): Rename to ...
13539 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13540 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13541 to new interface.
13542 (target_regsets): Rename to ...
13543 (x86_regsets): ... this.
13544 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13545 interface.
13546 (x86_siginfo_fixup): Use is_64bit_tdesc.
13547 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13548 (tdesc_x32_avx_linux, tdesc_x32_linux)
13549 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13550 Declare.
13551 (x86_linux_update_xmltarget): Delete.
13552 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13553 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13554 (AMD64_LINUX_USER64_CS): New.
13555 (x86_linux_read_description): New, based on
13556 x86_linux_update_xmltarget.
13557 (same_process_callback): New.
13558 (x86_arch_setup_process_callback): New.
13559 (x86_linux_update_xmltarget): New.
13560 (x86_regsets_info): New.
13561 (amd64_linux_regs_info): New.
13562 (i386_linux_usrregs_info): New.
13563 (i386_linux_regs_info): New.
13564 (x86_linux_regs_info): New.
13565 (x86_arch_setup): Reimplement.
13566 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13567 (x86_emit_ops): Ditto.
13568 (the_low_target): Adjust. Install x86_linux_regs_info,
13569 x86_cannot_fetch_register, and x86_cannot_store_register.
13570 (initialize_low_arch): New.
13571 * linux-ia64-low.c (tdesc_ia64): Declare.
13572 (ia64_fetch_register): Adjust.
13573 (ia64_usrregs_info, regs_info): New globals.
13574 (ia64_regs_info): New function.
13575 (the_low_target): Adjust.
13576 (initialize_low_arch): New function.
13577 * linux-sparc-low.c (tdesc_sparc64): Declare.
13578 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13579 Adjust.
13580 (sparc_arch_setup): New function.
13581 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13582 (the_low_target): Adjust.
13583 (initialize_low_arch): New function.
13584 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13585 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13586 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13587 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13588 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13589 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13590 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13591 (tdesc_powerpc_isa205_vsx64l): Declare.
13592 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13593 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13594 (ppc_set_pc, ppc_get_hwcap): Adjust.
13595 (ppc_usrregs_info): Forward declare.
13596 (!__powerpc64__) ppc_regmap_adjusted: New global.
13597 (ppc_arch_setup): Adjust to the current process'es target
13598 description.
13599 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13600 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13601 (ppc_store_evrregset): Adjust.
13602 (target_regsets): Rename to ...
13603 (ppc_regsets): ... this, and make static.
13604 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13605 (ppc_regs_info): New function.
13606 (the_low_target): Adjust.
13607 (initialize_low_arch): New function.
13608 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13609 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13610 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13611 (tdesc_s390x_linux64v2): Declare.
13612 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13613 (s390_fill_gregset, s390_store_last_break): Adjust.
13614 (target_regsets): Rename to ...
13615 (s390_regsets): ... this, and make static.
13616 (s390_get_pc, s390_set_pc): Adjust.
13617 (s390_get_hwcap): New target_desc parameter, and use it.
13618 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13619 (s390_arch_setup): Adjust to set the current process'es target
13620 description. Don't adjust the regmap.
13621 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13622 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13623 (regs_info_3264): New globals.
13624 (s390_regs_info): New function.
13625 (the_low_target): Adjust.
13626 (initialize_low_arch): New function.
13627 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13628 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13629 [__mips64] (init_registers_mips_linux)
13630 (init_registers_mips_dsp_linux): Delete defines.
13631 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13632 (have_dsp): New global.
13633 (mips_read_description): New, based on mips_arch_setup.
13634 (mips_arch_setup): Reimplement.
13635 (get_usrregs_info): New function.
13636 (mips_cannot_fetch_register, mips_cannot_store_register)
13637 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13638 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13639 (target_regsets): Rename to ...
13640 (mips_regsets): ... this, and make static.
13641 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13642 (dsp_regs_info, regs_info): New globals.
13643 (mips_regs_info): New function.
13644 (the_low_target): Adjust.
13645 (initialize_low_arch): New function.
13646 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13647 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13648 Declare.
13649 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13650 (arm_read_description): New, with bits factored from
13651 arm_arch_setup.
13652 (arm_arch_setup): Reimplement.
13653 (target_regsets): Rename to ...
13654 (arm_regsets): ... this, and make static.
13655 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13656 (arm_regs_info): New function.
13657 (the_low_target): Adjust.
13658 (initialize_low_arch): New function.
13659 * linux-m68k-low.c (tdesc_m68k): Declare.
13660 (target_regsets): Rename to ...
13661 (m68k_regsets): ... this, and make static.
13662 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13663 (m68k_regs_info): New function.
13664 (m68k_arch_setup): New function.
13665 (the_low_target): Adjust.
13666 (initialize_low_arch): New function.
13667 * linux-sh-low.c (tdesc_sharch): Declare.
13668 (target_regsets): Rename to ...
13669 (sh_regsets): ... this, and make static.
13670 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13671 (sh_regs_info, sh_arch_setup): New functions.
13672 (the_low_target): Adjust.
13673 (initialize_low_arch): New function.
13674 * linux-bfin-low.c (tdesc_bfin): Declare.
13675 (bfin_arch_setup): New function.
13676 (bfin_usrregs_info, regs_info): New globals.
13677 (bfin_regs_info): New function.
13678 (the_low_target): Adjust.
13679 (initialize_low_arch): New function.
13680 * linux-cris-low.c (tdesc_cris): Declare.
13681 (cris_arch_setup): New function.
13682 (cris_usrregs_info, regs_info): New globals.
13683 (cris_regs_info): New function.
13684 (the_low_target): Adjust.
13685 (initialize_low_arch): New function.
13686 * linux-cris-low.c (tdesc_crisv32): Declare.
13687 (cris_arch_setup): New function.
13688 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13689 (cris_regs_info): New function.
13690 (the_low_target): Adjust.
13691 (initialize_low_arch): New function.
13692 * linux-m32r-low.c (tdesc_m32r): Declare.
13693 (m32r_arch_setup): New function.
13694 (m32r_usrregs_info, regs_info): New globals.
13695 (m32r_regs_info): Adjust.
13696 (initialize_low_arch): New function.
13697 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13698 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13699 (tic6x_usrregs_info): Forward declare.
13700 (tic6x_read_description): New function, based on ...
13701 (tic6x_arch_setup): ... this. Reimplement.
13702 (target_regsets): Rename to ...
13703 (tic6x_regsets): ... this, and make static.
13704 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13705 (tic6x_regs_info): New function.
13706 (the_low_target): Adjust.
13707 (initialize_low_arch): New function.
13708 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13709 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13710 (target_regsets): Rename to ...
13711 (xtensa_regsets): ... this, and make static.
13712 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13713 globals.
13714 (xtensa_arch_setup, xtensa_regs_info): New functions.
13715 (the_low_target): Adjust.
13716 (initialize_low_arch): New function.
13717 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13718 (nios2_arch_setup): Set the current process'es tdesc.
13719 (target_regsets): Rename to ...
13720 (nios2_regsets): ... this.
13721 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13722 (nios2_regs_info): New function.
13723 (the_low_target): Adjust.
13724 (initialize_low_arch): New function.
a261b8f5
PA
13725 * linux-aarch64-low.c (tdesc_aarch64): Declare.
13726 (aarch64_arch_setup): Set the current process'es tdesc.
13727 (target_regsets): Rename to ...
13728 (aarch64_regsets): ... this.
13729 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
13730 (aarch64_regs_info): New function.
13731 (the_low_target): Adjust.
13732 (initialize_low_arch): New function.
3aee8918
PA
13733 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
13734 globals.
13735 (target_regsets): Rename to ...
13736 (tile_regsets): ... this.
13737 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
13738 (tile_regs_info): New function.
13739 (tile_arch_setup): Set the current process'es tdesc.
13740 (the_low_target): Adjust.
13741 (initialize_low_arch): New function.
13742 * spu-low.c (tdesc_spu): Declare.
13743 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
13744 * win32-arm-low.c (tdesc_arm): Declare.
13745 (arm_arch_setup): New function.
13746 (the_low_target): Install arm_arch_setup instead of
13747 init_registers_arm.
13748 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
13749 (init_windows_x86): Rename to ...
13750 (i386_arch_setup): ... this. Set `win32_tdesc'.
13751 (the_low_target): Adjust.
13752 * win32-low.c (win32_tdesc): New global.
13753 (child_add_thread): Don't create the thread cache here.
13754 (do_initial_child_stuff): Set the new process'es tdesc.
13755 * win32-low.h (struct target_desc): Forward declare.
13756 (win32_tdesc): Declare.
13757 * lynx-i386-low.c (tdesc_i386): Declare global.
13758 (lynx_i386_arch_setup): Set `lynx_tdesc'.
13759 * lynx-low.c (lynx_tdesc): New global.
13760 (lynx_add_process): Set the new process'es tdesc.
13761 * lynx-low.h (struct target_desc): Forward declare.
13762 (lynx_tdesc): Declare global.
13763 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
13764 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
13765 * nto-low.c (nto_tdesc): New global.
13766 (do_attach): Set the new process'es tdesc.
13767 * nto-low.h (struct target_desc): Forward declare.
13768 (nto_tdesc): Declare.
13769 * nto-x86-low.c (tdesc_i386): Declare.
13770 (nto_x86_arch_setup): Set `nto_tdesc'.
13771
b1fbec62
GB
137722013-06-04 Gary Benson <gbenson@redhat.com>
13773
13774 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
13775 to qSupported response when appropriate.
13776 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
13777 with nonzero-length annex.
13778 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
13779 arguments supplied in annex.
13780
d1ec4ce7
DE
137812013-05-31 Doug Evans <dje@google.com>
13782
ac44adcb 13783 PR server/15594
d1ec4ce7
DE
13784 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
13785 64 bits in 64-cross-32 environment.
13786
9b25f2d3
PA
137872013-05-28 Pedro Alves <palves@redhat.com>
13788
13789 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
13790 (aarch64-without-fpu.c): Delete rule.
13791 * configure.srv (aarch64*-*-linux*): Remove references to
13792 aarch64-without-fpu.o and aarch64-without-fpu.xml.
13793 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
13794 declaration.
13795
6740dc9c
PA
137962013-05-24 Pedro Alves <palves@redhat.com>
13797
13798 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
13799 instead of strchr/decode_address. Error if the range isn't split
13800 with a ','. Don't assume there's be a ':' in the action.
13801
c2d6af84
PA
138022013-05-23 Yao Qi <yao@codesourcery.com>
13803 Pedro Alves <palves@redhat.com>
13804
13805 * linux-low.c (lwp_in_step_range): New function.
13806 (linux_wait_1): If the thread was range stepping and stopped
13807 outside the stepping range, report the stop to GDB. Otherwise,
13808 continue stepping. Add range stepping debug output.
13809 (linux_set_resume_request): Copy the step range from the resume
13810 request to the lwp.
13811 (linux_supports_range_stepping): New.
13812 (linux_target_ops) <supports_range_stepping>: Set to
13813 linux_supports_range_stepping.
13814 * linux-low.h (struct linux_target_ops)
13815 <supports_range_stepping>: New field.
13816 (struct lwp_info) <step_range_start, step_range_end>: New fields.
13817 * linux-x86-low.c (x86_supports_range_stepping): New.
13818 (the_low_target) <supports_range_stepping>: Set to
13819 x86_supports_range_stepping.
13820 * server.c (handle_v_cont): Handle 'r' action.
13821 (handle_v_requests): Append ";r" if the target supports range
13822 stepping.
13823 * target.h (struct thread_resume) <step_range_start,
13824 step_range_end>: New fields.
13825 (struct target_ops) <supports_range_stepping>:
13826 New field.
13827 (target_supports_range_stepping): New macro.
13828
58794e1a
JB
138292013-05-17 Joel Brobecker <brobecker@adacore.com>
13830
13831 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
13832 confusion in comment.
13833
d631c5a7
JB
138342013-05-17 Joel Brobecker <brobecker@adacore.com>
13835
13836 * lynx-low.c (struct process_info_private): New type.
13837 (lynx_add_process): New function.
13838 (lynx_create_inferior, lynx_attach): Replace calls to
13839 add_process by calls to lynx_add_process.
13840 (lynx_resume): If PTID is null, then try using
13841 current_process()->private->last_wait_event_ptid.
13842 Add comments.
13843 (lynx_clear_inferiors): Delete. The contents of that function
13844 has been inlined in lynx_mourn;
13845 (lynx_wait_1): Save the ptid in the process's private data.
13846 (lynx_mourn): Free the process' private data. Replace call
13847 to lynx_clear_inferiors by call to clear_inferiors.
13848
96f7a20f
YQ
138492013-05-17 Yao Qi <yao@codesourcery.com>
13850
13851 * i386-low.c (i386_length_and_rw_bits): Move the comment to
13852 the right place.
13853
db0dfaa0
LM
138542013-05-16 Luis Machado <lgustavo@codesourcery.com>
13855
13856 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
13857 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
13858 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
13859 PT_TEXT_END_ADDR guards. Update comments.
13860 (linux_target_op) <read_offsets>: Conditionally define to
13861 linux_read_offsets if the target is UCLIBC and if it defines
13862 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
13863
68f5f838
SL
138642013-05-06 Sandra Loosemore <sandra@codesourcery.com>
13865 Andrew Jenner <andrew@codesourcery.com>
13866
13867 * Makefile.in (SFILES): Add linux-nios2-low.c.
13868 (clean): Add action to delete nios2-linux.c.
13869 (nios2-linux.c): New rule.
13870 * configure.srv: Add nios2*-*-linux*.
13871 * linux-nios2-low.c: New.
13872
1ebff1fd
HAQ
138732013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
13874
13875 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
13876
f6150862
HZ
138772013-04-25 Hui Zhu <hui@codesourcery.com>
13878
13879 PR gdb/15186
f6150862
HZ
13880 * ax.c (ax_printf): Add fflush.
13881
614c279d
TT
138822013-04-22 Tom Tromey <tromey@redhat.com>
13883
13884 * Makefile.in (SFILES): Add filestuff.c.
13885 (OBS): Add filestuff.o.
13886 (filestuff.o): New target.
13887 * config.in, configure: Rebuild.
13888 * configure.ac: Check for fdwalk, pipe2.
13889
7d4e5717
PA
138902013-04-17 Pedro Alves <palves@redhat.com>
13891
13892 * configure.ac (USE_THREAD_DB): Delete variable.
13893 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
13894 Don't AC_SUBST USE_THREAD_DB.
13895 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
13896 * config.in, configure: Regenerate.
13897
d5c93e41
PA
138982013-04-16 Pedro Alves <palves@redhat.com>
13899
13900 * linux-low.h (struct lwp_info) <thread_known>: Move under
13901 the USE_THREAD_DB #ifdef.
13902
04f5fe89
PA
139032013-04-16 Pedro Alves <palves@redhat.com>
13904
13905 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
13906 (linux-low.o): Delete rule.
13907 * linux-low.h: Always include "gdb_thread_db.h" instead of
13908 conditionally including thread_db.h.
13909 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
13910 HAVE_THREAD_DB_H.
13911
480b27bf
JK
139122013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13913
13914 * Makefile.in (install-only): Fix make install regression.
13915
43662968
JK
139162013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
13917
13918 Convert man pages to texinfo, new gdbinit.5 texinfo page.
13919 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
13920 installation.
13921 * gdbserver.1: Remove.
13922
3e74e146
PA
139232013-03-22 Pedro Alves <palves@redhat.com>
13924
13925 * linux-low.c (handle_extended_wait): Don't call
13926 linux_enable_event_reporting.
13927
a8347a2a
TT
139282013-03-15 Tony Theodore <tonyt@logyst.com>
13929
13930 PR build/9098:
13931 * Makefile.in (SHELL): Use @SHELL@.
13932
eeb56fa7
SDJ
139332013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
13934
13935 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
13936 compiler warning.
13937
4fa7e2ff
JB
139382013-03-13 Joel Brobecker <brobecker@adacore.com>
13939
13940 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
13941 Remove extraneous NULL element.
13942
8ddb1965
YQ
139432013-03-13 Yao Qi <yao@codesourcery.com>
13944
13945 * tracepoint.c (traceframe_read_tsv): Look for the last matched
13946 'V' block in trace frame.
13947
9accd112
MM
139482013-03-11 Markus Metzger <markus.t.metzger@intel.com>
13949
13950 * target.h (struct target_ops): Add btrace ops.
13951 (target_supports_btrace): New macro.
13952 (target_enable_btrace): New macro.
13953 (target_disable_btrace): New macro.
13954 (target_read_btrace): New macro.
13955 * gdbthread.h (struct thread_info): Add btrace field.
13956 * server.c: Include btrace-common.h.
13957 (handle_btrace_general_set): New function.
13958 (handle_btrace_enable): New function.
13959 (handle_btrace_disable): New function.
13960 (handle_general_set): Call handle_btrace_general_set.
13961 (handle_qxfer_btrace): New function.
13962 (struct qxfer qxfer_packets[]): Add btrace entry.
13963 * inferiors.c (remove_thread): Disable btrace.
13964 * linux-low: Include linux-btrace.h.
13965 (linux_low_enable_btrace): New function.
13966 (linux_low_read_btrace): New function.
13967 (linux_target_ops): Add btrace ops.
13968 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
13969 Add srv_linux_btrace=yes.
13970 (x86_64-*-linux*): Add linux-btrace.o.
13971 Add srv_linux_btrace=yes.
13972 * configure.ac: Define HAVE_LINUX_BTRACE.
13973 * config.in: Regenerated.
13974 * configure: Regenerated.
13975
5cc22e4c
MM
139762013-03-11 Markus Metzger <markus.t.metzger@intel.com>
13977
13978 * server.c (handle_qxfer): Preserve error message if -3 is
13979 returned.
13980 (qxfer): Document the -3 return value.
13981
7c97f91e
MM
139822013-03-11 Markus Metzger <markus.t.metzger@intel.com>
13983
13984 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
13985 (linux_btrace_h): New variable.
13986 (linux-btrace.o): New rule.
13987
be9a119c 139882013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
13989 Hafiz Abid Qadeer <abidh@codesourcery.com>
13990
13991 * tracepoint.c (trace_buffer_size): New global.
13992 (DEFAULT_TRACE_BUFFER_SIZE): New define.
13993 (init_trace_buffer): Change to one-argument function. Allocate
13994 trace buffer memory.
13995 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
13996 handle QTBuffer:size packet.
13997 (cmd_bigqtbuffer_size): New function.
13998 (initialize_tracepoint): Call init_trace_buffer with
13999 DEFAULT_TRACE_BUFFER_SIZE.
14000 * server.c (handle_query): Add QTBuffer:size in the
14001 supported packets.
14002
e64f7499
YQ
140032013-03-07 Yao Qi <yao@codesourcery.com>
14004
14005 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14006 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14007 of -1.
14008 (cmd_qtsp): Adjust condition. Do post increment.
14009 Set cur_action and cur_step_action back to 0.
14010
f0ae6fc3
PA
140112013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14012
14013 PR server/15236
14014 * linux-low.c (linux_write_memory): Return early success if LEN is
14015 zero.
14016
b5b0b0af
CV
140172013-03-05 Corinna Vinschen <vinschen@redhat.de>
14018
334ad4a8 14019 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 14020
589bc927
TT
140212013-02-28 Tom Tromey <tromey@redhat.com>
14022
14023 * configure.ac: Invoke AC_SYS_LARGEFILE.
14024 * configure, config.in: Rebuild.
14025
dfe07582
CV
140262013-02-28 Corinna Vinschen <vinschen@redhat.com>
14027
14028 * win32-low.c: Throughout, fix format strings and casts of
14029 printf-like functions to avoid type related warnings on all
14030 platforms.
14031 (get_child_debug_event): Print dwDebugEventCode as hex since
14032 that's how it's usually documented.
14033
736cd585
YQ
140342013-02-28 Yao Qi <yao@codesourcery.com>
14035
14036 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14037 pulongest.
14038
e1f58301
JW
140392013-02-27 Jiong Wang <jiwang@tilera.com>
14040
14041 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14042 (reg-tilegx32.c): New rule.
14043 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14044 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14045 different register info initializer according to elf class.
14046 (init_registers_tilgx32): New function. The tilegx32 register info
14047 initializer.
14048 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14049 (tile_store_gregset): Likewise.
14050
d171ca78
YQ
140512013-02-27 Yao Qi <yao@codesourcery.com>
14052
14053 * server.c (process_point_options): Print debug message when
14054 debug_threads is true.
14055
282bbdf3
YQ
140562013-02-26 Yao Qi <yao@codesourcery.com>
14057
14058 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14059
aca22551
PA
140602013-02-19 Pedro Alves <palves@redhat.com>
14061 Kai Tietz <ktietz@redhat.com>
14062
14063 PR gdb/15161
14064
14065 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14066 instead of strtoul to extract address from packet.
14067 (process_serial_event) <'z'>: Likewise.
14068
4f3cee1c
YQ
140692013-02-18 Yao Qi <yao@codesourcery.com>
14070
14071 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14072
8e1d55a3
PA
140732013-02-14 Pedro Alves <palves@redhat.com>
14074
14075 Plug memory leak.
14076
14077 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14078 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14079
458820da
PA
140802013-02-14 Pedro Alves <palves@redhat.com>
14081
14082 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14083
baea0dae
PA
140842013-02-14 Pedro Alves <palves@redhat.com>
14085
14086 * tracepoint.c (save_string): Delete.
14087 (add_tracepoint_action): Use savestring instead of save_string.
14088
0b1afbb3
PA
140892013-02-12 Pedro Alves <palves@redhat.com>
14090
14091 * linux-xtensa-low.c: Ditto.
14092 * xtensa-xtregs.c: Ditto.
14093
8a4ac37e
PA
140942013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14095
14096 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14097 thread_db.
14098
148de6bb
MS
140992013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14100
14101 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14102 aarch64_num_wp_regs and aarch64_num_bp_regs to
14103 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14104
55fac6e0
MS
141052013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14106
14107 * linux-aarch64-low.c (ps_get_thread_area): Replace
14108 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14109
176eb98c
MS
141102013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14111 Marcus Shawcroft <marcus.shawcroft@arm.com>
14112 Nigel Stephens <nigel.stephens@arm.com>
14113 Yufeng Zhang <yufeng.zhang@arm.com>
14114
14115 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14116 (aarch64.c, aarch64-without-fpu.c): New targets.
14117 * configure.srv (aarch64*-*-linux*): New.
14118 * linux-aarch64-low.c: New file.
14119
56f7af9c
MS
141202013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14121
43aaf8b6 14122 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
14123 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14124 (dequeue_one_deferred_signal, linux_resume_one_thread)
14125 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14126 (linux_tracefork_grandchild, linux_test_for_tracefork)
14127 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14128 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14129 where the argument is 0.
14130
60f662b0
YQ
141312013-01-25 Yao Qi <yao@codesourcery.com>
14132
14133 * event-loop.c: Include "queue.h".
14134 (gdb_event_p): New typedef.
14135 (struct gdb_event) <next_event>: Remove.
14136 (event_queue): Change to QUEUE(gdb_event_p).
14137 (async_queue_event): Remove.
14138 (gdb_event_xfree): New.
14139 (initialize_event_loop): New.
14140 (process_event): Use API from QUEUE.
14141 (wait_for_event): Likewise.
14142 * server.c (main): Call initialize_event_loop.
14143 * server.h (initialize_event_loop): Declare.
14144
5ae4861a
YQ
141452013-01-18 Yao Qi <yao@codesourcery.com>
14146
14147 * ax.h (struct eval_agent_expr_context): New.
14148 (gdb_eval_agent_expr): Update declaration.
14149 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14150 TFRAME. Add new argument CTX.
14151 * server.h (struct eval_agent_expr_context): Declare.
14152 (agent_mem_read, agent_tsv_read): Update declaration.
14153 (agent_mem_read_string): Likewise.
14154 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14155 (add_traceframe_block): Add new argument TPOINT.
14156 Increase TPOINT->traceframe_usage.
14157 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14158 eval_tracepoint_agent_expr.
14159 (condition_true_at_tracepoint): Likewise.
14160 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14161 (agent_mem_read_string, agent_tsv_read): Likewise.
14162
85e00e85
YQ
141632013-01-16 Yao Qi <yao@codesourcery.com>
14164
14165 * linux-low.c (linux_resume_one_lwp): Don't check
14166 'lwp->bp_reinsert != 0'.
14167
4039cf45
JB
141682013-01-07 Joel Brobecker <brobecker@adacore.com>
14169 Pedro Alves <palves@redhat.com>
14170
14171 * lynx-low.c (ptrace_request_to_str): Define a temporary
14172 macro and use it to simplify this function's implementation.
14173
9044dee2
JB
141742013-01-07 Joel Brobecker <brobecker@adacore.com>
14175
14176 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14177 sets errno.
14178
e6352c8f
JB
141792013-01-07 Joel Brobecker <brobecker@adacore.com>
14180
14181 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14182
50681a27
JB
141832013-01-07 Joel Brobecker <brobecker@adacore.com>
14184
14185 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14186
3f6e77ef
JB
141872013-01-07 Joel Brobecker <brobecker@adacore.com>
14188
14189 * lynx-low.c (lynx_resume): Use the resume_info parameter
14190 to determine the ptid for the lynx_ptrace call, unless
14191 it is equal to minus_one_ptid, in which case we use the
14192 ptid of the current_inferior.
14193 (lynx_wait_1): After having received a thread create/exit
14194 event, resume the inferior's execution using the signaling
14195 thread's ptid, rather than the old ptid.
14196
7fda33ae
JB
141972013-01-07 Joel Brobecker <brobecker@adacore.com>
14198
14199 * lynx-low.c (lynx_resume): Delete variable ret.
14200
b9786c74
JB
142012013-01-01 Joel Brobecker <brobecker@adacore.com>
14202
14203 * gdbreplay.c (gdbreplay_version): Update copyright year.
14204 * server.c (gdbserver_version): Likewise.
14205
8b93d60f
JB
142062012-12-17 Joel Brobecker <brobecker@adacore.com>
14207
14208 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14209 new thread.
14210
037335a7
JB
142112012-12-17 Joel Brobecker <brobecker@adacore.com>
14212
14213 * lynx-low.c (ptrace_request_to_str): Add handling for
14214 PTRACE_GETTRACESIG.
14215
52d4cbd8
JB
142162012-12-17 Joel Brobecker <brobecker@adacore.com>
14217
14218 * lynx-low.c (lynx_attach): Delete variable new_process.
14219
ab8f6ca9
JB
142202012-12-17 Joel Brobecker <brobecker@adacore.com>
14221
14222 * lynx-low.c (lynx_create_inferior): Delete variable
14223 new_process.
14224
78cbc024
JB
142252012-12-17 Joel Brobecker <brobecker@adacore.com>
14226
14227 * lynx-low.c (ptrace_request_to_str): Do not handle
14228 PTRACE_GETTHREADLIST if this macro does not exist.
14229
14a00470
YQ
142302012-12-15 Yao Qi <yao@codesourcery.com>
14231
14232 * Makefile.in (OBS): Add notif.o.
14233 * notif.c, notif.h: New.
14234 * server.c: Include "notif.h".
14235 (struct vstop_notif) <next>: Remove.
14236 <base>: New field.
14237 (queue_stop_reply): Update.
14238 (push_event, send_next_stop_reply): Remove.
14239 (discard_queued_stop_replies): Update.
14240 (notif_stop): New variable.
14241 (handle_v_stopped): Remove.
14242 (handle_v_requests): Don't call handle_v_stopped. Call
14243 handle_ack_notif instead.
14244 (queue_stop_reply_callback): Call notif_event_enque instead
14245 of queue_stop_reply.
14246 (handle_status): Don't call send_next_stop_reply, call
14247 notif_write_event instead.
14248 (kill_inferior_callback): Likewise.
14249 (detach_or_kill_inferior_callback): Likewise.
14250 (main): Call initialize_notif.
14251 (process_serial_event): Call QUEUE_is_empty.
14252 (handle_target_event): Call notif_push instead of push event.
14253 * server.h (push_event): Remove declaration.
14254
61c125b9
TT
142552012-12-10 Tom Tromey <tromey@redhat.com>
14256
14257 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14258 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14259 macros.
14260 (.c.o): Rewrite.
14261 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14262 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14263 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14264 (amd64-linux-ipa.o, ax.o): Rewrite.
14265 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14266 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14267 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14268 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14269 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14270 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14271 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14272 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14273 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14274 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14275 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14276 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14277 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14278 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14279 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14280 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14281 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14282 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14283 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14284 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14285 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14286 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14287 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14288 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14289 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14290 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14291 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14292 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14293 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14294 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14295 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14296 (reg-tilegx.o): Remove.
14297 (all_object_files): New macro.
14298 Include .deps files.
14299 * aclocal.m4, configure: Rebuild.
14300 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14301 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14302 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14303
e90e9ad9
TT
143042012-12-05 Tom Tromey <tromey@redhat.com>
14305
14306 PR gdb/14917:
14307 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14308
02d403bf 143092012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
14310
14311 * configure.ac: Check for linux/perf_event.h.
14312 * config.in: Regenerated.
14313 * configure: Regenerated.
14314
0270a750
PA
143152012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14316
14317 * hostio.c (handle_readlink): Decrease buffer size
14318 parameter passed to readlink by one byte.
14319
8c29b58e
YQ
143202012-11-26 Yao Qi <yao@codesourcery.com>
14321
14322 * configure.ac (build_warnings): Append '-Wempty-body'.
14323 * configure: Regenerated.
14324 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14325 body.
14326
8bdce1ff
PM
143272012-11-15 Pierre Muller <muller@sourceware.org>
14328
14329 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14330 * config.in: Regenerate.
14331 * configure: Regenerate.
14332 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14333 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14334 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14335 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14336 header.
14337 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14338 instead of <sys/wait.h> header.
14339 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14340
02d403bf 143412012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
14342
14343 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14344 (various make rules): Remove -DGDBSERVER
14345
fbd5db48
YQ
143462012-11-09 Yao Qi <yao@codesourcery.com>
14347
14348 * spu-low.c (current_ptid): Move it to ..
14349 * gdbthread.h: ... here. New.
14350 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14351 * server.c (myresume, process_serial_event): Likewise.
14352 * thread-db.c (thread_db_find_new_threads): Likewise.
14353 * tracepoint.c (run_inferior_command): Likewise.
14354
b3dc46ff
AB
143552012-10-01 Andrew Burgess <aburgess@broadcom.com>
14356
14357 * server.c (handle_search_memory_1): Include access length in
14358 warning message.
14359
07c04788
HPN
143602012-09-05 Michael Brandt <michael.brandt@axis.com>
14361
14362 * linux-crisv32-low.c: Fix compile errors.
14363
918d227b
YQ
143642012-09-04 Yao Qi <yao@codesourcery.com>
14365
14366 * tracepoint.c (cmd_qtsv): Adjust debug message.
14367 Don't check CUR_TPOINT.
14368
18c1b81a
YQ
143692012-08-28 Yao Qi <yao@codesourcery.com>
14370
14371 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14372 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14373 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14374 Remove declarations of xmalloc, xreallloc, xstrdup and
14375 freeargv.
14376 * Makefile.in (libiberty_h): New.
14377 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14378 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14379
dc82f37b
YQ
143802012-08-23 Yao Qi <yao@codesourcery.com>
14381
14382 * server.h: Remove declaration of 'xsnprintf'.
14383
406b1477
KS
143842012-08-22 Keith Seitz <keiths@redhat.com>
14385
14386 * server.h: Include build-gnulib-gbserver/config.h.
14387 * gdbreplay.c: Likewise.
14388
e6712ff1
DE
143892012-08-08 Doug Evans <dje@google.com>
14390
14391 * Makefile.in (SFILES): Add gdb_vecs.c.
14392 (OBS): Add gdb_vecs.o.
14393 (gdb_vecs_h, host_defs_h): New variables.
14394 (thread-db.o): Add $(gdb_vecs_h) dependency.
14395 (gdb_vecs.o): New rule.
14396 * thread-db.c: #include "gdb_vecs.h".
14397 (thread_db_load_search): Use a vector to iterate over path elements.
14398 Handle text appearing after "$pdir".
14399
14400 * configure.ac: Add check for strstr.
14401 * config.in: Regenerate.
14402 * configure: Regenerate.
14403
7c3270ae
UW
144042012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14405
14406 * hostio.c (handle_pread): If pread fails, fall back to attempting
14407 lseek/read.
14408 (handle_pwrite): Likewise for pwrite.
14409
b62e2b27
UW
144102012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14411
14412 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14413 between unsupported TYPE and unimplementable ADDR/LEN combination.
14414 (arm_insert_point): Act on new return value.
14415
78a99e91
PA
144162012-07-31 Pedro Alves <palves@redhat.com>
14417
14418 * server.c (process_point_options): Only skip tokens if we find
14419 one that is unrecognized. Don't treat 'X' specially while
14420 skipping unrecognized tokens.
14421
fcf303ab
UW
144222012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14423
14424 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14425 to 4-byte-align HW breakpoint addresses for Thumb.
14426
7255706c
YQ
144272012-07-27 Yao Qi <yao@codesourcery.com>
14428
14429 PR remote/14161.
14430
14431 * server.h: Declare gdb_agent_about_to_close.
14432 * target.c (kill_inferior): Include "agent.h".
14433 New. Send command 'kill'.
14434 * target.h (kill_inferior): Removed macro.
14435 * tracepoint.c (gdb_agent_about_to_close): New.
14436 (gdb_agent_helper_thread): Handle command 'close'.
14437 Wait endlessly until the inferior stops.
14438 Install gdb_agent_remove_socket to atexit hook.
14439 (agent_socket_name): New static variable.
14440 (gdb_agent_socket_init): Replace local variable 'name' with
14441 'agent_socket_name'.
14442 (gdb_agent_remove_socket): New.
14443
5a3f286f
YQ
144442012-07-27 Yao Qi <yao@codesourcery.com>
14445
14446 * server.c (process_point_options): Stop at 'X' when parsing.
14447
961bd387
ME
144482012-07-19 Michael Eager <eager@eagercon.com>
14449
a261b8f5 14450 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
14451 to hw_execute.
14452 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14453 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14454 hardware breakpoint.
14455
aa7c7447
JK
144562012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14457
14458 * gdbserver/linux-low.c (initialize_low): Call
14459 linux_ptrace_init_warnings.
14460
7f216e7c
DE
144612012-07-02 Doug Evans <dje@google.com>
14462
14463 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14464 pointer to int.
14465
d3ce09f5
SS
144662012-07-02 Stan Shebs <stan@codesourcery.com>
14467
14468 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14469 (ax.o): Add it to build rule.
14470 (ax-ipa.o): Ditto.
14471 (OBS): Add format.o.
14472 (IPA_OBS): Add format.o.
14473 * server.c (handle_query): Claim support for breakpoint commands.
14474 (process_point_options): Add command case.
14475 (process_serial_event): Leave running if there are printfs in
14476 effect.
14477 * mem-break.h (any_persistent_commands): Declare.
14478 (add_breakpoint_commands): Declare.
14479 (gdb_no_commands_at_breakpoint): Declare.
14480 (run_breakpoint_commands): Declare.
14481 * mem-break.c (struct point_command_list): New struct.
14482 (struct breakpoint): New field command_list.
14483 (any_persistent_commands): New function.
14484 (add_commands_to_breakpoint): New function.
14485 (add_breakpoint_commands): New function.
14486 (gdb_no_commands_at_breakpoint): New function.
14487 (run_breakpoint_commands): New function.
14488 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14489 locally.
14490 * ax.c: Include format.h.
14491 (ax_printf): New function.
14492 (gdb_eval_agent_expr): Add printf opcode.
14493
2f8f6aed
YQ
144942012-06-13 Yao Qi <yao@codesourcery.com>
14495
14496 * server.c (start_inferior): Remove duplicated writes to fields
14497 'last_resume_kind' and 'last_status' of 'current_inferior'.
14498
0c9070b3
YQ
144992012-06-12 Yao Qi <yao@codesourcery.com>
14500 Pedro Alves <palves@redhat.com>
14501
14502 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14503 comment.
14504 * server.c (handle_v_cont): Extend comment.
14505
c52daf70
YQ
145062012-06-11 Yao Qi <yao@codesourcery.com>
14507
14508 * linux-low.c (linux_attach): Add 'static'.
14509
d38bbb0a
YQ
145102012-06-06 Yao Qi <yao@codesourcery.com>
14511
14512 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14513
89dc0afd
JK
145142012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14515
14516 Fix gcc -flto compilation warning.
14517 * server.c (main): Make variable multi_mode and attach volatile.
14518
75f62ce7
TJB
145192012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14520
14521 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14522 if the platform doesn't know about it.
14523
65f479b6
PA
145242012-05-30 Jeff Kenton <jkenton@tilera.com>
14525
14526 * Makefile.in (SFILES): Add linux-tile-low.c.
14527 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14528 * configure.srv: Handle tilegx-*-linux*.
14529 * linux-tile-low.c: New file.
14530
0c5bf5a9
JK
145312012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14532
14533 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14534
a493e3e2
PA
145352012-05-24 Pedro Alves <palves@redhat.com>
14536
14537 PR gdb/7205
14538
43aaf8b6 14539 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 14540
2ea28649
PA
145412012-05-24 Pedro Alves <palves@redhat.com>
14542
14543 PR gdb/7205
14544
14545 Replace target_signal with gdb_signal throughout.
14546
8d409d16
MR
145472012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14548
14549 * linux-low.c (linux_store_registers): Avoid the copying sequence
14550 when no data has been retrieved by ptrace.
14551
23512c01
MGD
145522012-05-22 Will Deacon <will.deacon@arm.com>
14553
14554 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14555 Include asm/ptrace.h.
14556 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14557 already defined.
14558
4934b29e
MR
145592012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14560
14561 * linux-low.c (linux_store_registers): Don't re-retrieve data
14562 with ptrace that has already been obtained from /proc. Always
14563 copy any data retrieved with ptrace to the buffer supplied.
14564
bde24c0a
PA
145652012-05-11 Yao Qi <yao@codesourcery.com>
14566 Pedro Alves <palves@redhat.com>
14567
14568 * linux-low.c (enum stopping_threads_kind): New.
14569 (stopping_threads): Change type to `enum stopping_threads_kind'.
14570 (handle_extended_wait): If stopping and suspending threads, leave
14571 the new_lwp suspended too.
14572 (linux_wait_for_event): Adjust.
14573 (stop_all_lwps): Set `stopping_threads' to
14574 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14575 whether we're suspending threads or just stopping them. Assert no
14576 recursion happens.
14577
623b6bdf
YQ
145782012-04-29 Yao Qi <yao@codesourcery.com>
14579
14580 * server.h: Move some code to ...
14581 * gdbthread.h: ... here. New.
14582 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14583 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14584 (nto-low.o, win32-low.o): Likewise.
14585 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14586 * regcache.c, remote-utils.c, server.c: Likewise.
14587 * target.c, tracepoint.c, win32-low.c: Likewise.
14588
f15f9948
TJB
145892012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14590
14591 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14592 (PTRACE_ARG4_TYPE): Likewise.
14593 (PTRACE_XFER_TYPE): Likewise.
14594 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14595 ptrace to PTRACE_ARG3_TYPE.
14596 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14597 (PTRACE_ARG4_TYPE): Likewise.
14598 (PTRACE_XFER_TYPE): Likewise.
14599 (linux_detach_one_lwp): Cast fourth argument of
14600 ptrace to long then PTRACE_ARG4_TYPE.
14601 (regsets_fetch_inferior_registers): Cast third argument of
14602 ptrace to long then PTRACE_ARG3_TYPE.
14603 (regsets_store_inferior_registers): Likewise.
14604
38ea300a
PA
146052012-04-20 Pedro Alves <palves@redhat.com>
14606
14607 * configure: Regenerate.
14608
c971b7fa
PA
146092012-04-19 Pedro Alves <palves@redhat.com>
14610
43aaf8b6 14611 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 14612 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
14613 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14614 (all, install-only, uninstall, clean-info, all-lib, clean): No
14615 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14616 (maintainer-clean realclean distclean): Use subdir_do.
14617 (subdir_do): New.
14618 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 14619 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
14620 * acinclude.m4: Include acx_configure_dir.m4.
14621 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14622 calls. Call AC_PROG_RANLIB. Configure gnulib using
14623 ACX_CONFIGURE_DIR.
14624 (GNULIB): New.
14625 (GNULIB_STDINT_H): Adjust.
14626 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14627 * gdbreplay.c: Include build-gnulib/config.h.
14628 * server.h: Likewise.
14629 * aclocal.m4: Regenerate.
14630 * config.in: Regenerate.
14631 * configure: Regenerate.
c971b7fa 14632
809277f8
PA
146332012-04-19 Pedro Alves <palves@redhat.com>
14634
14635 * Makefile.in (LIBGNU, INCGNU): Adjust.
14636 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14637 (all, install-only, uninstall, clean-info, all-lib, clean)
14638 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14639 * configure.ac: Adjust AC_OUTPUT output.
14640 * aclocal.m4: Regenerate.
14641 * configure: Regenerate.
14642
fd9bb8b8
PA
146432012-04-19 Pedro Alves <palves@redhat.com>
14644
14645 * Makefile.in (generated_files): New.
14646 (server_h): Remove the explicit dependency on config.h, and depend
14647 on $generated_files.
14648
1c298c66
PA
146492012-04-19 Pedro Alves <palves@redhat.com>
14650
14651 * Makefile.in (INCGNU): Add -Ignulib.
14652
57c4b50b
PA
146532012-04-19 Pedro Alves <palves@redhat.com>
14654
14655 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14656 (INCGNU): ... this, and spell out -I here.
14657 (GNULIB_LIB): Rename to ...
14658 (LIBGNU): ... this.
14659 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14660
1030e047
PA
146612012-04-19 Pedro Alves <palves@redhat.com>
14662
14663 * config.in: Regenerate.
14664
447d4319
PA
146652012-04-19 Pedro Alves <palves@redhat.com>
14666
14667 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14668 * server.h (memmem): Remove declaration.
14669 * config.in: Regenerate.
14670 * configure: Regenerate.
14671
aad9eab9
YQ
146722012-04-19 Yao Qi <yao@codesourcery.com>
14673
14674 * Makefile.in (SFILES): Add common/vec.c.
14675 (OBS): Add vec.o.
14676 (vec.o): New rule.
14677
3e10640f
YQ
146782012-04-19 Yao Qi <yao@codesourcery.com>
14679
14680 * remote-utils.c (prepare_resume_reply): Replace with macro
14681 target_core_of_thread.
14682 * server.c (handle_qxfer_threads_proper): Likewise.
14683 * target.h (traget_core_of_thread): New macro.
14684
71622373
PA
146852012-04-18 Pedro Alves <palves@redhat.com>
14686
14687 * aclocal.m4: Regenerate.
14688 * configure: Regenerate.
14689
80d26939
YQ
146902012-04-16 Yao Qi <yao@codesourcery.com>
14691
14692 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14693 duplicated on address.
14694
42476b70
YQ
146952012-04-16 Yao Qi <yao@codesourcery.com>
14696
14697 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14698 (struct tracepoint_action_ops) <send>: New field.
14699 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14700 (agent_expr_send, x_tracepoint_action_send): New.
14701 (l_tracepoint_action_send): New.
14702 (cmd_qtdp): Download and install tracepoint
14703 according to `use_agent'.
14704 (run_inferior_command): Add one more parameter `len'.
14705 Update callers.
14706 (tracepoint_send_agent): New.
14707 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14708
7bc83639
YQ
147092012-04-16 Yao Qi <yao@codesourcery.com>
14710
14711 * tracepoint.c (download_tracepoints): Moved to ...
14712 (cmd_qtstart): ... here.
14713
5f18041e
YQ
147142012-04-14 Yao Qi <yao@codesourcery.com>
14715
14716 * tracepoint.c: Include inttypes.h.
14717 (struct collect_memory_action): Use sized types.
14718 (struct tracepoint): Likewise.
14719 (cmd_qtdp, stop_tracing): Update print specifiers.
14720 (cmd_qtp, response_tracepoint): Likewise.
14721 (collect_data_at_tracepoint): Likewise.
14722 (collect_data_at_step): Likewise.
14723
55a8c076
YQ
147242012-04-14 Yao Qi <yao@codesourcery.com>
14725
14726 Import gnulib module inttypes.
14727 * aclocal.m4, config.in, configure: Regenerated.
14728
dc750257
YQ
147292012-04-14 Yao Qi <yao@codesourcery.com>
14730
14731 * Makefile.in (maintainer-clean, realclean, distclean): Remove
14732 Makefile and config.status at last.
14733
0ab5faf9
YQ
147342012-04-13 Yao Qi <yao@codesourcery.com>
14735
14736 * tracepoint.c: Include stdint.h unconditionally.
14737
18f5fd81
TJB
147382012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14739
14740 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
14741 on BFD_HAVE_SYS_PROCFS_TYPE.
14742 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
14743 * configure: Regenerate.
14744 * config.in: Likewise.
14745
4d47af5c
L
147462012-04-13 H.J. Lu <hongjiu.lu@intel.com>
14747
14748 * Makefile.in (clean): Also remove x32.c x32-linux.c
14749 x32-avx.c x32-avx-linux.c.
14750 (x32.o): New target.
14751 (x32.c): Likewise.
14752 (x32-linux.o): Likewise.
14753 (x32-linux.c): Likewise.
14754 (x32-avx.o): Likewise.
14755 (x32-avx.c): Likewise.
14756 (x32-avx-linux.o): Likewise.
14757 (x32-avx-linux.c): Likewise.
14758
14759 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
14760 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
14761 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
14762 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
14763 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
14764 i386/x32-avx-linux.xml.
14765
14766 * linux-x86-low.c (init_registers_x32_linux): New prototype.
14767 (init_registers_x32_avx_linux): Likwise.
14768 (x86_linux_update_xmltarget): Call init_registers_x32_linux
14769 or init_registers_x32_avx_linux if linux_is_elf64 is false.
14770
ecedbe58
PA
147712012-04-13 Pedro Alves <palves@redhat.com>
14772
14773 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
14774 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
14775 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
14776 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
14777 the sub-make.
14778
c92b5177
L
147792012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14780
14781 * linux-x86-low.c (compat_x32_clock_t): New.
14782 (compat_x32_siginfo_t): Likewise.
14783 (compat_x32_siginfo_from_siginfo): Likewise.
14784 (siginfo_from_compat_x32_siginfo): Likewise.
14785 (linux_is_elf64): Likewise.
14786 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
14787 and siginfo_from_compat_x32_siginfo for x32.
14788 (x86_arch_setup): Set linux_is_elf64.
14789
214d508e
L
147902012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14791
14792 PR gdb/13969
14793 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
14794 e_machine field.
14795 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
14796 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
14797 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
14798 compatible with process.
14799
c9a1864a
YQ
148002012-04-12 Yao Qi <yao@codesourcery.com>
14801
14802 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
14803 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
14804 (install-only, install-info, clean): Handle sub dir gnulib.
14805 (all-lib, am--refresh): New targets.
14806 (memmem.o): Remove target.
14807 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
14808 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
14809 (AC_REPLACE_FUNCS): Remove memmem.
14810 Invoke gl_INIT and AM_INIT_AUTOMAKE.
14811 (AC_OUTPUT): Generate Makefile in gnulib/.
14812 * aclocal.m4, config.in, configure: Regenerated.
14813
367ba2c2
MR
148142012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
14815
14816 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
14817
9d236627
PA
148182012-04-05 Pedro Alves <palves@redhat.com>
14819
14820 -Werror=strict-aliasing
14821
14822 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
14823 pointer.
14824
111217b3
PA
148252012-04-04 Pedro Alves <palves@redhat.com>
14826
14827 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14828 (sparc_store_gregset_from_stack, sparc_store_gregset)
14829 (sparc_breakpoint_at): Fix formatting.
14830
8365dcf5
TJB
148312012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14832
14833 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
14834 are available.
14835 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
14836 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
14837 * config.in: Regenerate.
14838 * configure: Likewise.
14839
689cc2ae
PA
148402012-03-29 Pedro Alves <palves@redhat.com>
14841
14842 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
14843 Correct ptrace arguments.
14844
c14dfd32
PA
148452012-03-28 Pedro Alves <palves@redhat.com>
14846
14847 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
14848 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
14849 (IA64_FR1_REGNUM): New defines.
14850 (ia64_fetch_register): New.
14851 (the_low_target): Install it.
14852 * linux-low.h (struct linux_target_ops) <fetch_register>: New
14853 field.
14854 * linux-low.c (linux_fetch_registers): Try the
14855 the_low_target.fetch_register hook first.
14856
14857 * linux-arm-low.c (the_low_target): Adjust.
14858 * linux-bfin-low.c (the_low_target): Adjust.
14859 * linux-cris-low.c (the_low_target): Adjust.
14860 * linux-crisv32-low.c (the_low_target): Adjust.
14861 * linux-m32r-low.c (the_low_target): Adjust.
14862 * linux-m68k-low.c (the_low_target): Adjust.
14863 * linux-mips-low.c (the_low_target): Adjust.
14864 * linux-ppc-low.c (the_low_target): Adjust.
14865 * linux-s390-low.c (the_low_target): Adjust.
14866 * linux-sh-low.c (the_low_target): Adjust.
14867 * linux-sparc-low.c (the_low_target): Adjust.
14868 * linux-tic6x-low.c (the_low_target): Adjust.
14869 * linux-x86-low.c (the_low_target): Adjust.
14870 * linux-xtensa-low.c (the_low_target): Adjust.
14871
63c88e13
PA
148722012-03-26 Pedro Alves <palves@redhat.com>
14873
14874 * server.c (handle_qxfer_libraries): Don't bail early if
14875 the_target->qxfer_libraries_svr4 is not NULL.
14876
fb723180
PA
148772012-03-26 Pedro Alves <palves@redhat.com>
14878
14879 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
14880
0afae3cf
PA
148812012-03-23 Pedro Alves <palves@redhat.com>
14882
14883 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
14884 "library-list-svr4" element's start tag when the the DSO list is
14885 empty.
14886
485f1ee4
PA
148872012-03-23 Pedro Alves <palves@redhat.com>
14888
14889 * linux-low.c (read_one_ptr): Read the inferior's pointer through
14890 a variable whose type size is the same as the inferior's pointer
14891 size.
14892
a5362b9a
TS
148932012-03-21 Thomas Schwinge <thomas@codesourcery.com>
14894
14895 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
14896 struct siginfo.
14897 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
14898 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
14899 * linux-low.h: Include <signal.h>.
14900 (struct siginfo): Remove forward declaration.
14901 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
14902 struct siginfo.
14903
d226c142
MF
149042012-03-21 Mike Frysinger <vapier@gentoo.org>
14905
14906 * .gitignore: Ignore more files.
14907
122f36ef
PA
149082012-03-19 Pedro Alves <palves@redhat.com>
14909 Jan Kratochvil <jan.kratochvil@redhat.com>
14910
14911 * server.c (cont_thread, general_thread): Add describing comments.
14912 (start_inferior): Clear `cont_thread'.
14913 (handle_v_cont): Don't set `cont_thread' if resuming all threads
14914 of a process.
14915
fc3e5175
YQ
149162012-03-15 Yao Qi <yao@codesourcery.com>
14917
14918 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
14919 handling to ...
14920 (cmd_qtdp): ... here.
14921
8d0d92cd
YQ
149222012-03-15 Yao Qi <yao@codesourcery.com>
14923
14924 * tracepoint.c (struct tracepoint_action_ops): New.
14925 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
14926 (m_tracepoint_action_download): New.
14927 (r_tracepoint_action_download): New.
14928 (x_tracepoint_action_download): New.
14929 (l_tracepoint_action_download): New.
14930 (add_tracepoint_action): Install `action->ops' according type.
14931 (download_tracepoint_1): Move code `download' function pointer
14932 of various tracepoint_action_ops.
14933
87b0bb13
JK
149342012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
14935
14936 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
14937 linux_ptrace_attach_warnings.
14938
5f572dec
JK
149392012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
14940
14941 * Makefile.in (linux-ptrace.o): New.
14942 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
14943 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
14944 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
14945 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
14946 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
14947 of these targets.
14948 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
14949
f4647387
YQ
149502012-03-08 Yao Qi <yao@codesourcery.com>
14951 Pedro Alves <palves@redhat.com>
14952
14953 Fix PR server/13392.
14954 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
14955 offset of JMP insn.
14956 * tracepoint.c (remove_tracepoint): New.
14957 (cmd_qtdp): Call remove_tracepoint when failed to install.
14958
9b224c5e
PA
149592012-03-07 Pedro Alves <palves@redhat.com>
14960
14961 * linux-low.c (get_detach_signal): New.
14962 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
14963 Pass on pending signals to PTRACE_DETACH. Check the result of the
14964 ptrace call.
14965 * server.c (program_signals, program_signals_p): New.
14966 (handle_general_set): Handle QProgramSignals.
14967 * server.h (program_signals, program_signals_p): Declare.
14968
e237a7e2
JK
149692012-03-05 Pedro Alves <palves@redhat.com>
14970 Jan Kratochvil <jan.kratochvil@redhat.com>
14971
14972 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
14973 New comment why.
14974
5808517f
YQ
149752012-03-03 Yao Qi <yao@codesourcery.com>
14976
14977 * tracepoint.c (tracepoint_look_up_symbols): Update call to
14978 agent_look_up_symbols.
14979
58b4daa5
YQ
149802012-03-03 Yao Qi <yao@codesourcery.com>
14981
14982 * Makefile.in (linux-low.o): Keep dependence on agent.h.
14983 (linux-x86-low.o): Likewise.
14984 * server.h: Remove in_process_agent_loaded.
14985 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
14986 common/agent.c.
14987 Update callers.
14988
8ffcbaaf
YQ
149892012-03-03 Yao Qi <yao@codesourcery.com>
14990
14991 * tracepoint.c (gdb_agent_capability): New global.
14992 (in_process_agent_loaded_ust): Renamed to
14993 `in_process_agent_supports_ust'.
14994 Update callers.
14995 (in_process_agent_supports_ust): Call agent_capability_check.
14996 (clear_installed_tracepoints): Assert that agent supports
14997 agent.
14998
d1feda86
YQ
149992012-03-03 Yao Qi <yao@codesourcery.com>
15000
15001 * linux-low.c (linux_supports_agent): New.
15002 (linux_target_ops): Initialize field `supports_agent' with
15003 linux_supports_agent.
15004 * target.h (struct target_ops) <supports_agent>: New.
15005 (target_supports_agent): New macro.
15006 * server.c (handle_general_set): Handle packet 'QAgent'.
15007 (handle_query): Send `QAgent+'.
15008 * Makefile.in (server.o): Depends on agent.h.
15009
2fa291ac
YQ
150102012-03-03 Yao Qi <yao@codesourcery.com>
15011
15012 * Makefile.in (OBS): Add agent.o.
15013 Add new rule for agent.o.
15014 Track dependence of tracepoint.c on agent.h.
15015 * tracepoint.c (run_inferior_command_1):
15016 (run_inferior_command): Call agent_run_command.
15017 (gdb_ust_connect_sync_socket): Deleted. Move it to
15018 common/agent.c.
15019 (resume_thread, stop_thread): Likewise.
15020 (gdb_ust_socket_init): Renamed to ...
15021 (gdb_agent_socket_init): ... New.
15022 (gdb_ust_thread): Renamed to ...
15023 (gdb_agent_helper_thread): ... New.
15024 (gdb_ust_init): Move some code to ...
15025 (gdb_agent_init): ... here. New.
15026 [HAVE_UST]: Call gdb_ust_init.
15027 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15028 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15029 * config.in, configure: Regenerated.
15030
05044653
PA
150312012-03-02 Pedro Alves <palves@redhat.com>
15032
15033 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15034 * linux-low.c (struct simple_pid_list): New.
15035 (stopped_pids): New a struct simple_pid_list pointer.
15036 (add_to_pid_list, pull_pid_from_list): New.
15037 (handle_extended_wait): Don't assume the first signal new children
15038 report is SIGSTOP. Adjust call to pull_pid_from_list.
15039 (linux_wait_for_lwp): Adjust.
15040
8d00225b
YQ
150412012-03-02 Yao Qi <yao@codesourcery.com>
15042
15043 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15044 debug log.
15045
19560ba5
YQ
150462012-03-02 Yao Qi <yao@codesourcery.com>
15047
15048 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15049 `stop_pc' and `tpoint'. Update caller.
15050
1faeff08
MR
150512012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15052
15053 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15054 * linux-low.c (use_linux_regsets): New macro.
15055 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15056 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15057 (linux_register_in_regsets): New function.
15058 (usr_fetch_inferior_registers): Skip registers covered by
15059 regsets.
15060 (usr_store_inferior_registers): Likewise.
15061 (usr_fetch_inferior_registers): New macro.
15062 (usr_store_inferior_registers): Likewise.
15063 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15064 (linux_store_registers): Likewise.
15065 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15066 prototype.
15067 (init_registers_mips64_dsp_linux): Likewise.
15068 (init_registers_mips_linux): New macro.
15069 (init_registers_mips_dsp_linux): Likewise.
15070 (mips_dsp_num_regs): Likewise.
15071 (DSP_BASE, DSP_CONTROL): New fallback macros.
15072 (mips_base_regs): New macro.
15073 (mips_regmap): Use it. Fix the size.
15074 (mips_dsp_regmap): New variable.
15075 (mips_dsp_regset_bitmap): Likewise.
15076 (mips_arch_setup): New function.
15077 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15078 than mips_regmap.
15079 (mips_cannot_store_register): Likewise.
15080 (the_low_target): Update .arch_setup, .num_regs and .regmap
15081 initializers. Add .regset_bitmap initializer.
15082 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15083 initializer.
15084 * linux-bfin-low.c (the_low_target): Likewise.
15085 * linux-cris-low.c (the_low_target): Likewise.
15086 * linux-crisv32-low.c (the_low_target): Likewise.
15087 * linux-ia64-low.c (the_low_target): Likewise.
15088 * linux-m32r-low.c (the_low_target): Likewise.
15089 * linux-m68k-low.c (the_low_target): Likewise.
15090 * linux-ppc-low.c (the_low_target): Likewise.
15091 * linux-s390-low.c (the_low_target): Likewise.
15092 * linux-sh-low.c (the_low_target): Likewise.
15093 * linux-sparc-low.c (the_low_target): Likewise.
15094 * linux-tic6x-low.c (the_low_target): Likewise.
15095 * linux-x86-low.c (the_low_target): Likewise.
15096 * linux-xtensa-low.c (the_low_target): Likewise.
15097 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15098 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15099 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15100 srv_xmlfiles.
15101 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15102 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15103
c03e6ccc
YQ
151042012-02-29 Yao Qi <yao@codesourcery.com>
15105 Pedro Alves <palves@redhat.com>
15106
15107 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15108 `step_over_finished' is true.
15109
644cebc9
PA
151102012-02-27 Pedro Alves <palves@redhat.com>
15111
15112 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15113 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15114
c14d7ab2
PA
151152012-02-27 Pedro Alves <palves@redhat.com>
15116
15117 PR server/9684
15118 * linux-low.c (pid_is_stopped): New.
15119 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15120
412c89dd
LM
151212012-02-25 Luis Machado <lgustavo@codesourcery.com>
15122
15123 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15124 of conditions.
15125
b745defe
MR
151262012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15127
15128 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15129
9f3a5c85
LM
151302012-02-24 Luis Machado <lgustavo@codesourcery>
15131
15132 * server.c (handle_query): Advertise support for target-side
15133 breakpoint condition evaluation.
15134 (process_point_options): New function.
15135 (process_serial_event): When inserting a breakpoint, check for
15136 a target-side condition that should be evaluated.
15137
15138 * mem-break.c: Include regcache.h and ax.h.
15139 (point_cond_list_t): New data structure.
15140 (breakpoint) <cond_list>: New field.
15141 (find_gdb_breakpoint_at): Make non-static.
15142 (delete_gdb_breakpoint_at): Clear any target-side
15143 conditions.
15144 (clear_gdb_breakpoint_conditions): New function.
15145 (add_condition_to_breakpoint): Likewise.
15146 (add_breakpoint_condition): Likewise.
15147 (gdb_condition_true_at_breakpoint): Likewise.
15148 (gdb_breakpoint_here): Return result directly instead
15149 of going through a local variable.
15150
15151 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15152 (clear_gdb_breakpoint_conditions): Likewise.
15153 (add_breakpoint_condition): Likewise.
15154 (gdb_condition_true_at_breakpoint): Likewise.
15155
15156 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15157 (need_step_over_p): Take target-side breakpoint condition into
15158 consideration.
15159
5e1dc496
LM
151602012-02-24 Luis Machado <lgustavo@codesourcery>
15161
15162 * server.h: Include tracepoint.h.
15163 (agent_mem_read, agent_get_trace_state_variable_value,
15164 agent_set_trace_state_variable_value,
15165 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15166 get_set_tsv_func_addr): New prototypes.
15167
15168 * ax.h: New include file.
15169 * ax.c: New source file.
15170
15171 * tracepoint.c: Include ax.h.
15172 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15173 agent_expr, eval_result_type): Move to ax.h.
15174 (parse_agent_expr): Rename to ...
15175 (gdb_parse_agent_expr): ... this, make it non-static and move
15176 to ax.h.
15177 (unparse_agent_expr) Rename to ...
15178 (gdb_unparse_agent_expr): ... this, make it non-static and move
15179 to ax.h.
15180 (eval_agent_expr): Rename to ...
15181 (eval_tracepoint_agent_expr): ... this.
15182 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15183 forward declarations.
15184 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15185 (agent_get_trace_state_variable_value): New function.
15186 (agent_set_trace_state_variable_value): New function.
15187 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15188 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15189 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15190 (condition_true_at_tracepoint): Likewise.
15191 (parse_agent_expr): Rename to ...
15192 (gdb_parse_agent_expr): ... this and move to ax.c.
15193 (unparse_agent_expr): Rename to ...
15194 (gdb_unparse_agent_expr): ... this and move to ax.c.
15195 (gdb_agent_op_name): Move to ax.c.
15196 (eval_agent_expr): Rename to ...
15197 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15198 and move to ax.c.
15199 (eval_tracepoint_agent_expr): New function.
15200 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 15201 non-static.
5e1dc496
LM
15202 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15203 ax.c.
15204 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15205 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15206 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15207 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15208 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15209 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15210 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15211 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15212 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15213 (compile_bytecodes): Remove forward declaration.
15214 (is_goto_target): Move to ax.c.
15215 (compile_bytecodes): Move to ax.c and call
15216 agent_get_trace_state_variable_value (...) and
15217 agent_set_trace_state_variable_value (...).
15218
15219 * Makefile.in: Update ax.c and IPA dependencies.
15220
277e4e52
PA
152212012-02-24 Pedro Alves <palves@redhat.com>
15222
15223 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15224 (cmd_bigqtbuffer_circular): ... this. Only handle
15225 'QTBuffer:circular:'.
15226 (handle_tracepoint_general_set): Adjust.
15227
bf4c19f7
YQ
152282012-02-16 Yao Qi <yao@codesourcery.com>
15229
15230 * inferiors.c: Move code to ...
15231 * dll.c: .... here. New.
15232 * server.h: Declare clear_dlls.
15233 * Makefile.in (SFILES): Add dll.c.
15234 (OBS): Add dll.o
15235 (dll.o): New rule.
15236
d73f2619
YQ
152372012-02-11 Yao Qi <yao@codesourcery.com>
15238
15239 * server.c: (handle_monitor_command): Add a new parameter
15240 `own_buf'.
15241 (handle_query): Update caller.
15242
f8255c2a
JB
152432012-02-09 Joel Brobecker <brobecker@adacore.com>
15244
15245 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15246 * configure, config.in: Regenerate.
15247 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15248 is not defined.
15249
da84f473
PA
152502012-02-02 Pedro Alves <palves@redhat.com>
15251
15252 Try SIGKILL first, then PTRACE_KILL.
15253 * linux-low.c (linux_kill_one_lwp): New.
15254 (linux_kill_one_lwp): Rename to ...
15255 (kill_one_lwp_callback): ... this. Use the new
15256 linux_kill_one_lwp.
15257
e886a173
PA
152582012-02-02 Pedro Alves <palves@redhat.com>
15259
15260 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15261 inferior.
15262
be07f1a2
PA
152632012-01-27 Pedro Alves <palves@redhat.com>
15264
15265 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15266 (elf_64_file_p): Make static.
15267 (linux_pid_exe_is_elf_64_file): New.
15268 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15269 Delete declarations.
15270 (linux_pid_exe_is_elf_64_file): Declare.
15271 * linux-x86-low.c (x86_arch_setup): Use
15272 linux_pid_exe_is_elf_64_file.
15273
d8301ad1
JK
152742012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15275
15276 * linux-low.c (linux_wait_for_event_1): Rename to ...
15277 (linux_wait_for_event): ... here and merge it with former
15278 linux_wait_for_event - new variable wait_ptid, use it.
15279 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15280
01b17894
PA
152812012-01-23 Pedro Alves <palves@redhat.com>
15282
15283 * server.c (main): Avoid yet another case of infinite loop while
15284 detaching/killing after a longjmp.
15285
e825046f
JK
152862012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15287
15288 Code cleanup.
15289 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15290
b9e7b9c3
UW
152912012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15292
15293 * hostio.c (handle_readlink): New function.
15294 (handle_vFile): Call it to handle "vFile:readlink" packets.
15295
901f9912
UW
152962012-01-20 Pedro Alves <palves@redhat.com>
15297 Ulrich Weigand <ulrich.weigand@linaro.org>
15298
15299 * server.c (handle_v_requests): Only support vAttach and vRun to
15300 start multiple processes when in extended protocol mode.
15301
fc1ab1a0
PA
153022012-01-17 Pedro Alves <palves@redhat.com>
15303
15304 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15305 memalign plus mprotect to allocate the scratch buffer.
15306
7d5d4e98
PA
153072012-01-13 Pedro Alves <palves@redhat.com>
15308
15309 * server.c (attach_inferior): Clear `cont_thread'.
15310
f128d5e9
PA
153112012-01-13 Pedro Alves <palves@redhat.com>
15312
15313 * server.c (main): Avoid infinite loop while detaching/killing
15314 after a longjmp.
15315
06db92f0
DE
153162012-01-09 Doug Evans <dje@google.com>
15317
15318 * server.c (start_inferior): Set last_ptid in --wrapper case.
15319
32d92999
YQ
153202012-01-06 Yao Qi <yao@codesourcery.com>
15321
15322 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15323 defined.
15324 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15325
5e0a92a9
YQ
153262012-01-04 Yao Qi <yao@codesourcery.com>
15327
15328 * tracepoint.c (cmd_qtdp): Print debug message
15329 for static tracepoint.
15330
ae639e8c
YQ
153312012-01-04 Yao Qi <yao@codesourcery.com>
15332
15333 * tracepoint.c (trace_vdebug): Differentiate debug message
15334 between gdbserver and IPA.
15335
f72429c5
YQ
153362012-01-03 Yao Qi <yao@codesourcery.com>
15337
15338 * tracepoint.c (tracepoint_was_hit): Don't collect for
15339 static tracepoint.
15340
12c3e59c
JB
153412012-01-02 Joel Brobecker <brobecker@adacore.com>
15342
15343 * terminal.h: Reformat copyright header.
15344
67827812
JB
153452012-01-02 Joel Brobecker <brobecker@adacore.com>
15346
15347 * server.c (gdbserver_version): Update copyright year.
15348 * gdbreplay.c (gdbreplay_version): Likewise.
15349
3e52c33d
JK
153502011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15351
15352 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15353
15354 Revert:
15355 2011-12-18 Hui Zhu <teawater@gmail.com>
15356 * linux-low.c (linux_create_inferior): Save return value to ret.
15357
66f1260e
HZ
153582011-12-18 Hui Zhu <teawater@gmail.com>
15359
15360 * linux-low.c (linux_create_inferior): Save return value to ret.
15361
e77616d7
DE
153622011-12-16 Doug Evans <dje@google.com>
15363
e7b06c57
DE
15364 * linux-low.c (linux_create_inferior): If stdio connection,
15365 redirect stdin from /dev/null, stdout to stderr.
15366 * remote-utils.c (remote_is_stdio): New static global.
15367 (remote_connection_is_stdio): New function.
15368 (remote_prepare): Handle stdio connection.
15369 (remote_open): Ditto.
15370 (remote_close): Don't close stdin for stdio connections.
15371 (read_prim,write_prim): New functions. Replace all calls to
15372 read/write to these.
15373 * server.c (main): Watch for "-" argument. Move call to
15374 remote_prepare before start_inferior.
15375 * server.h (STDIO_CONNECTION_NAME): New macro.
15376 (remote_connection_is_stdio): Declare.
15377
e77616d7
DE
15378 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15379 in debugging output.
15380
82067193
YQ
153812011-12-15 Yao Qi <yao@codesourcery.com>
15382
15383 * tracepoint.c: Include sys/syscall.h.
15384 (gdb_ust_thread): Remove preprocessor conditional.
15385
82bfbe7e
PA
153862011-12-14 Pedro Alves <pedro@codesourcery.com>
15387
15388 * linux-low.c (linux_detach_one_lwp): Call
15389 the_low_target.prepare_to_resume before detaching.
15390
712c6575
YQ
153912011-12-14 Yao Qi <yao@codesourcery.com>
15392
15393 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15394 of write.
15395
d54d1edf
YQ
153962011-12-14 Yao Qi <yao@codesourcery.com>
15397
15398 * i386-low.c (i386_low_stopped_data_address): Initialize local
15399 variable `control'.
15400
6210a125
PA
154012011-12-13 Pedro Alves <pedro@codesourcery.com>
15402
15403 PR remote/13492
15404
15405 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15406 DR_CONTROL unless necessary. Extend comments.
15407 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15408 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15409
2ece8244
YQ
154102011-12-13 Yao Qi <yao@codesourcery.com>
15411
15412 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15413 macros.
15414 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15415
784867a5
JK
154162011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15417
15418 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15419 Print new debug message for such case.
15420
6bf36717
JK
154212011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15422
15423 Fix overlapping memcpy.
15424 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15425 the read_inferior_memory transfer.
15426 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15427 write_inferior_memory transfer.
15428 (set_fast_tracepoint_jump): New variable buf. Use it for the
15429 read_inferior_memory and write_inferior_memory transfers.
15430 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15431 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15432 Use it for the write_inferior_memory transfer.
15433 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15434 buffers.
15435
50275556
MR
154362011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15437
15438 * linux-low.c (fetch_register, store_register): Make code
15439 consistent, fix formatting.
15440
7325beb4
MR
154412011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15442
15443 * linux-low.c (usr_store_inferior_registers): Factor out code
15444 to handle individual registers into...
15445 (store_register): ... this new function.
15446
c642a434
UW
154472011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15448
15449 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15450 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15451 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15452 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15453 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15454 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15455 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15456 (srv_xmlfiles): Add new XML files.
15457
15458 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15459 and <sys/uio.h>.
15460 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15461 (init_registers_s390_linux32v1): Add prototype.
15462 (init_registers_s390_linux32v2): Likewise.
15463 (init_registers_s390_linux64v1): Likewise.
15464 (init_registers_s390_linux64v2): Likewise.
15465 (init_registers_s390x_linux64v1): Likewise.
15466 (init_registers_s390x_linux64v2): Likewise.
15467 (s390_num_regs): Increment to 52.
15468 (s390_regmap): Add orig_r2 register.
15469 (s390_num_regs_3264): Increment to 68.
15470 (s390_regmap_3264): Add orig_r2 register.
15471 (s390_collect_ptrace_register): Handle orig_r2 register.
15472 (s390_supply_ptrace_register): Likewise.
15473 (s390_fill_last_break): New function.
15474 (s390_store_last_break): Likewise.
15475 (s390_fill_system_call): New function.
15476 (s390_store_system_call): Likewise.
15477 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15478 register sets.
15479 (s390_check_regset): New function.
15480 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15481 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15482 Update target_regsets for available register sets.
15483
2268b414
JK
154842011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15485 Jan Kratochvil <jan.kratochvil@redhat.com>
15486
15487 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15488 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15489 New.
15490 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15491 * linux-low.h (struct process_info_private): New member r_debug.
15492 * server.c (handle_qxfer_libraries): Call
15493 the_target->qxfer_libraries_svr4.
15494 (handle_qxfer_libraries_svr4): New function.
15495 (qxfer_packets): New entry "libraries-svr4".
15496 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15497 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15498 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15499 PACKET_qXfer_libraries_svr4.
15500
d6db1fab
UW
155012011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15502
15503 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15504 PSW address/mask between 8-byte and 16-byte formats.
15505 (s390_supply_ptrace_register): Likewise.
15506 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15507 basic addressing mode bit.
15508
242f5f1c
SS
155092011-11-24 Stan Shebs <stan@codesourcery.com>
15510
15511 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15512
f196051f
SS
155132011-11-17 Stan Shebs <stan@codesourcery.com>
15514
15515 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15516 (tracing_start_time): New global.
15517 (tracing_stop_time): New global.
15518 (tracing_user_name): New global.
15519 (tracing_notes): New global.
15520 (tracing_stop_note): New global.
15521 (cmd_qtstart): Set traceframe_usage, start_time.
15522 (stop_tracing): Set stop_time.
15523 (cmd_qtstatus): Report additional status.
15524 (cmd_qtp): New function.
15525 (handle_tracepoint_query): Call it.
15526 (cmd_qtnotes): New function.
15527 (handle_tracepoint_general_set): Call it.
15528 (get_timestamp): Rename from tsv_get_timestamp.
15529
405f8e94
SS
155302011-11-14 Stan Shebs <stan@codesourcery.com>
15531 Kwok Cheung Yeung <kcy@codesourcery.com>
15532
15533 * linux-x86-low.c (small_jump_insn): New.
15534 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15535 trampoline and error message, build a trampoline and issue a small
15536 jump instruction to it.
15537 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15538 trampoline and error message.
15539 (x86_get_min_fast_tracepoint_insn_len): New.
15540 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15541 * linux-low.h (struct linux_target_ops): Add arguments to
15542 install_fast_tracepoint_jump_pad operation, add new operation.
15543 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15544 arguments.
15545 (linux_get_min_fast_tracepoint_insn_len): New function.
15546 (linux_target_op): Add new operation.
15547 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15548 (gdb_trampoline_buffer_end): Ditto.
15549 (gdb_trampoline_buffer_error): Ditto.
15550 (struct ipa_sym_addresses): Add fields for new IPA variables.
15551 (symbol_list): Add entries for new IPA variables.
15552 (struct tracepoint): Add fields to hold the address range of the
15553 trampoline used by the tracepoint.
15554 (trampoline_buffer_head): New static variable.
15555 (trampoline_buffer_tail): Ditto.
15556 (claim_trampoline_space): New function.
15557 (have_fast_tracepoint_trampoline_buffer): New function.
15558 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15559 structure.
15560 (install_fast_tracepoint): Ditto, also add error buffer argument.
15561 (cmd_qtminftpilen): New function.
15562 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15563 (fast_tracepoint_from_trampoline_address): New function.
15564 (fast_tracepoint_collecting): Handle trampoline as part of jump
15565 pad space.
15566 (set_trampoline_buffer_space): New function.
15567 (initialize_tracepoint): Initialize new IPA variables.
15568 * target.h (struct target_ops): Add arguments to
15569 install_fast_tracepoint_jump_pad operation, add new
15570 get_min_fast_tracepoint_insn_len operation.
15571 (target_get_min_fast_tracepoint_insn_len): New.
15572 (install_fast_tracepoint_jump_pad): Add arguments.
15573 * server.h (IPA_BUFSIZ): Define.
15574 * linux-i386-ipa.c: Include extra header files.
15575 (initialize_fast_tracepoint_trampoline_buffer): New function.
15576 (initialize_low_tracepoint): Call it.
15577 * server.h (set_trampoline_buffer_space): Declare.
15578 (claim_trampoline_space): Ditto.
15579 (have_fast_tracepoint_trampoline_buffer): Ditto.
15580
1e4d1764
YQ
155812011-11-14 Yao Qi <yao@codesourcery.com>
15582
15583 * server.c (handle_query): Handle InstallInTrace for qSupported.
15584 * tracepoint.c (add_tracepoint): Sort list.
15585 (install_tracepoint, download_tracepoint): New.
15586 (cmd_qtdp): Call them to install and download tracepoints.
15587 (sort_tracepoints): Removed.
15588 (cmd_qtstart): Update.
15589
5c73ff4e
YQ
155902011-11-14 Yao Qi <yao@codesourcery.com>
15591
15592 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15593 * mem-break.h: Declare.
15594 * tracepoint.c (cmd_qtstart): Move some code to ...
15595 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15596 New.
15597 (download_tracepoints): Move some code to ...
15598 (download_tracepoint_1): ... here. New.
15599
86a30030
YQ
156002011-11-08 Yao Qi <yao@codesourcery.com>
15601
15602 * remote-utils.c (relocate_instruction): A comment fix.
15603
8d26e50c
JB
156042011-11-07 Joel Brobecker <brobecker@adacore.com>
15605
15606 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15607 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15608 dr_status_mirror and dr_control_mirror from debug_reg_state.
15609 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15610 (i386_initial_stuff): Remove use of deleted globals.
15611 (i386_get_thread_context, i386_set_thread_context,
15612 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15613 from debug_reg_state.
15614
a59306a3
YQ
156152011-11-05 Yao Qi <yao@codesourcery.com>
15616
15617 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15618 address as TPOINT's.
15619
3065dfb6
SS
156202011-11-02 Stan Shebs <stan@codesourcery.com>
15621
15622 * tracepoint.c (agent_mem_read_string): New function.
15623 (eval_agent_expr): Call it for tracenz.
15624 * server.c (handle_query): Report support for tracenz.
15625
fd0d8c7c
YQ
156262011-11-02 Yao Qi <yao@codesourcery.com>
15627
15628 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15629
609086b1
YQ
156302011-11-02 Yao Qi <yao@codesourcery.com>
15631
15632 * target.h: Fix a typo in comment.
15633
b9fd1791
PA
156342011-10-31 Pedro Alves <pedro@codesourcery.com>
15635
15636 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15637 clobber the breakpoints' shadows with fast tracepoint jumps.
15638 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15639 * target.c (write_inferior_memory): Also pass MYADDR down to
15640 check_mem_write.
15641
03583c20
UW
156422011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15643
15644 * configure.ac: Check support for personality routine.
15645 * configure: Regenerate.
15646 * config.in: Likewise.
15647 * linux-low.c: Include <sys/personality.h>.
15648 Define ADDR_NO_RANDOMIZE if necessary.
15649 (linux_create_inferior): Disable address space randomization when
15650 forking inferior, if requested.
15651 (linux_supports_disable_randomization): New function.
15652 (linux_target_ops): Install it.
15653 * server.h (disable_randomization): Declare.
15654 * server.c (disable_randomization): New global variable.
15655 (handle_general_set): Handle QDisableRandomization.
15656 (handle_query): Likewise for qSupported.
15657 (main): Support --disable-randomization and --no-disable-randomization
15658 command line arguments.
15659 * target.h (struct target_ops): Add supports_disable_randomization.
15660 (target_supports_disable_randomization): New macro.
15661
723b724b
MF
156622011-09-29 Mike Frysinger <vapier@gentoo.org>
15663
15664 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15665 ifdef check.
15666 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15667 [!PT_GETDSBT] (target_loadmap): New definition.
15668 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15669 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15670 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15671 and PT_GETDSBT to LINUX_LOADMAP.
15672 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15673 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15674
55329a5c 156752011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
15676
15677 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15678 (arm_linux_hwbp_cap): New static variable.
15679 (arm_linux_get_hwbp_cap): Replace by ...
15680 (arm_linux_init_hwbp_cap): ... this new function.
15681 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15682 (arm_linux_get_hw_watchpoint_count): Likewise.
15683 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15684 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15685 (arm_prepare_to_resume): Use perror_with_name instead of error.
15686
55329a5c 156872011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
15688
15689 * linux-arm-low.c: Include <signal.h>.
15690 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15691 (struct arm_linux_hwbp_cap): New data type.
15692 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15693 (struct arm_linux_hw_breakpoint): New data type.
15694 (MAX_BPTS, MAX_WPTS): Define.
15695 (struct arch_process_info, struct arch_lwp_info): New data types.
15696 (arm_linux_get_hwbp_cap): New function.
15697 (arm_linux_get_hw_breakpoint_count): Likewise.
15698 (arm_linux_get_hw_watchpoint_count): Likewise.
15699 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15700 (arm_hwbp_control_initialize): Likewise.
15701 (arm_hwbp_control_is_enabled): Likewise.
15702 (arm_hwbp_control_is_initialized): Likewise.
15703 (arm_hwbp_control_disable): Likewise.
15704 (arm_linux_hw_breakpoint_equal): Likewise.
15705 (arm_linux_hw_point_initialize): Likewise.
15706 (struct update_registers_data): New data structure.
15707 (update_registers_callback: New function.
15708 (arm_insert_point): Likewise.
15709 (arm_remove_point): Likewise.
15710 (arm_stopped_by_watchpoint): Likewise.
15711 (arm_stopped_data_address): Likewise.
15712 (arm_new_process): Likewise.
15713 (arm_new_thread): Likewise.
15714 (arm_prepare_to_resume): Likewise.
15715 (the_low_target): Register arm_insert_point, arm_remove_point,
15716 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15717 arm_new_thread, and arm_prepare_to_resume.
15718
6b9801d4
SS
157192011-09-15 Stan Shebs <stan@codesourcery.com>
15720
15721 * server.h (struct emit_ops): Add compare-goto fields.
15722 * tracepoint.c (gdb_agent_op_sizes): New table.
15723 (emit_eq_goto): New function.
15724 (emit_ne_goto): New function.
15725 (emit_lt_goto): New function.
15726 (emit_le_goto): New function.
15727 (emit_gt_goto): New function.
15728 (emit_ge_goto): New function.
15729 (is_goto_target): New function.
15730 (compile_bytecodes): Recognize special cases of compare-goto
15731 combinations and call specialized emitters for them.
15732 * linux-x86-low.c (amd64_emit_eq_goto): New function.
15733 (amd64_emit_ne_goto): New function.
15734 (amd64_emit_lt_goto): New function.
15735 (amd64_emit_le_goto): New function.
15736 (amd64_emit_gt_goto): New function.
15737 (amd64_emit_ge_goto): New function.
15738 (amd64_emit_ops): Add the new functions.
15739 (i386_emit_eq_goto): New function.
15740 (i386_emit_ne_goto): New function.
15741 (i386_emit_lt_goto): New function.
15742 (i386_emit_le_goto): New function.
15743 (i386_emit_gt_goto): New function.
15744 (i386_emit_ge_goto): New function.
15745 (i386_emit_ops): Add the new functions.
15746
bf15cbda
SS
157472011-09-08 Stan Shebs <stan@codesourcery.com>
15748
15749 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
15750 (i386_emit_epilogue): Restore %ebx.
15751
943ca1dd
JZ
157522011-08-31 Jie Zhang <jzhang918@gmail.com>
15753
15754 * server.c (step_thread): Remove definition.
15755 (process_serial_event): Don't handle Hs.
15756 * server.h (step_thread): Remove declaration.
15757 * target.c (set_desired_inferior): Remove use of step_thread.
15758
e3deef73
LM
157592011-08-24 Luis Machado <lgustavo@codesourcery.com>
15760
15761 * linux-low.c: Include linux-procfs.h.
15762 (linux_attach_lwp_1): Update comments.
15763 (linux_attach): Scan for existing threads when attaching to a
15764 process that is the tgid.
15765 * Makefile.in: Update dependencies.
15766
13da1c97
LM
157672011-08-24 Luis Machado <lgustavo@codesourcery.com>
15768
15769 * configure.srv: Add linux-procfs.o dependencies.
15770
881127c9
YQ
157712011-08-14 Yao Qi <yao@codesourcery.com>
15772
15773 * target.h (struct target_ops): Fix indent.
15774 * win32-low.c (win32_target_ops): Fix comment.
15775
58dbd541
YQ
157762011-08-14 Andrew Jenner <andrew@codesourcery.com>
15777 Yao Qi <yao@codesourcery.com>
15778
15779 * Makefile.in (clean): Remove tic6x-*.c files.
15780 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
15781 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
15782 (tic6x-c64xp-linux.c): Likewise.
15783 * configure.srv: Add support for tic6x-*-uclinux.
15784 * linux-tic6x-low.c: New.
15785 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
15786
78d85199
YQ
157872011-08-14 Andrew Stubbs <ams@codesourcery.com>
15788 Yao Qi <yao@codesourcery.com>
15789
15790 * target.h (struct target_ops): Add read_loadmap.
15791 * linux-low.c (struct target_loadseg): New type.
15792 (struct target_loadmap): New type.
15793 (linux_read_loadmap): New function.
15794 (linux_target_ops): Add linux_read_loadmap.
15795 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
15796 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
15797 to NULL.
78d85199 15798
a959a88d
EZ
157992011-08-05 Eli Zaretskii <eliz@gnu.org>
15800
15801 * win32-low.c: Include <stdint.h>.
15802
1ced966e
PA
158032011-07-22 Pedro Alves <pedro@codesourcery.com>
15804
15805 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
15806 to the inferior here.
15807 (i386_remove_aligned_watchpoint): Ditto.
15808 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
15809 fit part of the watchpoint in the debug registers.
15810 (i386_update_inferior_debug_regs): New.
15811 (i386_low_insert_watchpoint): Work on a local mirror of the debug
15812 registers, and only update the inferior on success.
15813 (i386_low_remove_watchpoint): Ditto.
15814
d26e3629
KY
158152011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
15816
15817 * linux-low.c (compare_ints, unique, list_threads, show_process,
15818 linux_core_of_thread): Delete.
15819 (linux_target_ops): Change linux_core_of_thread to
15820 linux_common_core_of_thread.
15821 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
15822 * utils.c (malloc_failure): Change type of argument.
15823 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
15824 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
15825 common/linux-osdata.c, common/ptid.c and common/buffer.c.
15826 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
15827 (IPA_OBJS): Add common-utils-ipa.o.
15828 (ptid_h, linux_osdata_h): New macros.
15829 (server_h): Add common/common-utils.h, common/xml-utils.h,
15830 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
15831 common/ptid.h.
15832 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
15833 ptid.o, buffer.o): New rules.
15834 (linux-low.o): Add common/linux-osdata.h as a dependency.
15835 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
15836 * configure.ac: Add AC_HEADER_DIRENT check.
15837 * config.in: Regenerate.
15838 * configure: Regenerate.
15839 * remote-utils.c (xml_escape_text): Delete.
15840 (buffer_grow, buffer_free, buffer_init, buffer_finish,
15841 buffer_xml_printf): Move to common/buffer.c.
15842 * server.c (main): Remove call to initialize_inferiors.
15843 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
15844 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
15845 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
15846 internal_error, gdb_assert, gdb_assert_fail): Delete.
15847 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
15848 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
15849 common/buffer.h.
15850 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
15851 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
15852 initialize_inferiors): Delete.
15853
2275a1a7
PA
158542011-07-20 Pedro Alves <pedro@codesourcery.com>
15855
15856 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
15857 symbol error.
15858
0a5b1e09
PA
158592011-05-31 Pedro Alves <pedro@codesourcery.com>
15860
15861 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
15862 assertion.
15863 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
15864
6938fd34
YQ
158652011-05-26 Yao Qi <yao@codesourcery.com>
15866
15867 * Makefile.in (thread-db.o): Track dependence to
15868 common/gdb_thread_db.h.
15869 * thread-db.c: include gdb_thread_db.h from right place.
15870
b481f9e0
TT
158712011-05-16 Adrian Cornish <gnu@bluedreamer.com>
15872
15873 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
15874 __FILE__ and __LINE__ to internal_error.
15875
98a5dd13
DE
158762011-05-13 Doug Evans <dje@google.com>
15877
15878 * thread-db.c (try_thread_db_load_from_sdir): New function.
15879 (try_thread_db_load_from_dir): New function.
15880 (thread_db_load_search): Handle $sdir, ignore $pdir.
15881 Remove trying of system directories if search of
15882 libthread-db-search-path fails, that is now done via $sdir.
15883
d248b706
KY
158842011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
15885
15886 * server.c (handle_query): Add EnableDisableTracepoints to the list
15887 of supported features.
43aaf8b6 15888 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 15889 tracepoints.
43aaf8b6
PA
15890 (cmd_qtenable_disable): New.
15891 (cmd_qtstart): Install tracepoints even if disabled.
15892 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
15893 receiving a QTEnable or QTDisable packet.
15894 (gdb_collect): Skip data collection if fast tracepoint is disabled.
15895 (ust_marker_to_static_tracepoint): Do not ignore disabled static
15896 tracepoints.
15897 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 15898
84e578fb
DE
158992011-05-10 Doug Evans <dje@google.com>
15900
15901 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
15902
71f55dd8
DE
159032011-05-04 Doug Evans <dje@google.com>
15904
15905 * linux-low.c (linux_join): Skip process lookup.
15906 * spu-low.c (spu_join): Ditto.
15907 * server.c (join_inferiors_callback): Delete.
15908 (process_serial_event): For 'D' packet (detach) call join_inferior
15909 directly.
15910
4d393d60
JM
159112011-05-04 Joseph Myers <joseph@codesourcery.com>
15912
15913 * README: Don't mention xscale*-*-linux*.
15914 * configure.srv (xscale*-*-linux*): Don't handle target.
15915
b00ad6ff
NF
159162011-04-27 Nathan Froyd <froydnj@codesourcery.com>
15917
15918 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
15919 casting pointers.
15920 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
15921 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
15922 (i386_emit_void_call_2): Likewise.
15923
af96c192
YQ
159242011-04-26 Yao Qi <yao@codesourcery.com>
15925
43aaf8b6
PA
15926 * linux-low.c: Move common macros to linux-ptrace.h.
15927 Include linux-ptrace.h.
af96c192
YQ
15928 * Makefile.in (linux_ptrace_h): New.
15929 (linux-low.o): Depends on linux-ptrace.h.
15930
03f2bd59
JK
159312011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
15932
15933 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
15934 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
15935 (remote_prepare): New function with most of the TCP code from ...
15936 (remote_open): ... here. Detect PORT here unconditionally. Move also
15937 setting transport_is_reliable.
15938 * server.c (run_once): New variable.
15939 (gdbserver_usage): Document it.
15940 (main): Set run_once for `--once'. Call remote_prepare. Exit after
15941 the first run if RUN_ONCE.
15942 * server.h (run_once, remote_prepare): New declarations.
15943
7a9dd1b2
TT
159442011-04-19 Tom Tromey <tromey@redhat.com>
15945
15946 * win32-low.c (handle_load_dll): Remove duplicate "the".
15947
81239425
PM
159482011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
15949
15950 Remove support for old Cygwin 1.5 versions.
15951 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
15952 function to avoid warning.
15953 (win32_add_one_solib): Use cygwin_conv_path function to avoid
15954 warning.
15955
9e0627f1
PM
159562011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
15957
15958 * gdbserver/server.h (Macro _): Define it if not available.
15959
588eebee
MS
159602011-03-14 Michael Snyder <msnyder@vmware.com>
15961
348af9f7 15962 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 15963
43f70d4c
JB
159642011-03-10 Joel Brobecker <brobecker@adacore.com>
15965
15966 * Makefile.in (maintainer-clean realclean distclean): Remove
15967 "make ... subdir_do" command.
15968
348af9f7
MS
159692011-03-10 Michael Snyder <msnyder@vmware.com>
15970
15971 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
15972
15973 * server.c (handle_v_run): Free alloced buffer on early return.
15974
e637a4f5
YQ
159752011-03-09 Yao Qi <yao@codesourcery.com>
15976
15977 Revert:
15978 2011-03-04 Yao Qi <yao@codesourcery.com>
15979
15980 * Makefile.in: Remove GNU make feature --directory.
15981
15982 2011-03-05 Yao Qi <yao@codesourcery.com>
15983
15984 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
15985 (subdir_do): New make target. Copied from gdb/Makefile.
15986 (maintainer-clean, realclean, distclean, clean): Call corresponding
15987 make targets in common/Makefile.
15988
15989 2011-02-11 Yao Qi <yao@codesourcery.com>
15990
15991 * configure.ac: Call AC_PROG_RANLIB.
15992 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
15993 * configure: Regenerate.
15994
e6edda56
JK
159952011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
15996
15997 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
15998
e5141119
JB
159992011-03-06 Yao Qi <yao@codesourcery.com>
16000
16001 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16002
64794aa4
JB
160032011-03-05 Yao Qi <yao@codesourcery.com>
16004
16005 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16006 (subdir_do): New make target. Copied from gdb/Makefile.
16007 (maintainer-clean, realclean, distclean, clean): Call corresponding
16008 make targets in common/Makefile.
16009
7a762829
YQ
160102011-03-04 Yao Qi <yao@codesourcery.com>
16011
16012 * Makefile.in: Remove GNU make feature --directory.
16013
348af9f7
MS
160142011-03-04 Michael Snyder <msnyder@vmware.com>
16015
16016 * server.c (queue_stop_reply): Call xmalloc not malloc.
16017
160182011-03-02 Michael Snyder <msnyder@vmware.com>
16019
16020 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16021
9f72fee2
MS
160222011-02-28 Michael Snyder <msnyder@vmware.com>
16023
588eebee
MS
16024 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16025 (cmd_qtframe): Ditto.
16026 (cmd_qtbuffer): Ditto.
16027 (cmd_bigqtbuffer): Ditto.
16028
9f72fee2
MS
16029 * utils.c (decimal2str): Initialize 'width' to nine, then
16030 don't mess with it.
16031
8040bd49
UW
160322011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16033
16034 * hostio.c (require_data): Free *data, not data.
16035
7e52cbd0
JK
160362011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16037
16038 * hostio.c (require_data): Use free, not xfree.
16039
9130f83e
MS
160402011-02-27 Michael Snyder <msnyder@vmware.com>
16041
4b812f4e
MS
16042 * server.c (handle_query): Discard unused value.
16043
9130f83e
MS
16044 * hostio.c (require_data): Free malloc memory before returning
16045 error.
16046
69d37113
MS
160472011-02-26 Michael Snyder <msnyder@vmware.com>
16048
16049 * linux-low.c (list_threads): Call closedir for dirent.
16050
35f5825a
MS
160512011-02-27 Michael Snyder <msnyder@vmware.com>
16052
2a589cef
MS
16053 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16054 a case statement falls through.
16055
0adea5f7
MS
16056 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16057
35f5825a
MS
16058 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16059 in comparison.
16060
238f1c74
MS
160612011-02-26 Michael Snyder <msnyder@vmware.com>
16062
16063 * utils.c (decimal2str): Eliminate dead code and dead param.
16064 (pulongest): Drop dead param from call to decimal2str.
16065 (plongest): Ditto.
16066
633ff500
JB
160672011-02-24 Joel Brobecker <brobecker@adacore.com>
16068
16069 Revert the following patch (not approved yet):
16070 2011-02-21 Hui Zhu <teawater@gmail.com>
16071 * tracepoint.c (tp_printf): New function.
16072 (eval_agent_expr): Handle gdb_agent_op_printf.
16073
f9c6ff72
HZ
160742011-02-21 Hui Zhu <teawater@gmail.com>
16075
16076 * tracepoint.c (tp_printf): New function.
16077 (eval_agent_expr): Handle gdb_agent_op_printf.
16078
94d5e490
TT
160792011-02-18 Tom Tromey <tromey@redhat.com>
16080
16081 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16082 (tracepoint.o): Likewise.
16083 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16084 (gdb_agent_op_names): Likewise.
16085
c7f96d2b
TT
160862011-02-18 Tom Tromey <tromey@redhat.com>
16087
16088 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16089 gdb_agent_op_rot>: New constants.
16090 (gdb_agent_op_names): Add pick and roll.
16091 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16092 cases.
16093
0feedb2c
JK
160942011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16095
16096 * aclocal.m4: Regenerated with aclocal-1.11.1.
16097
b3b9301e
PA
160982011-02-14 Pedro Alves <pedro@codesourcery.com>
16099
16100 * server.c (handle_qxfer_traceframe_info): New.
16101 (qxfer_packets): Register "traceframe-info".
16102 (handle_query): Report support for qXfer:traceframe-info:read+.
16103 * tracepoint.c (match_blocktype): New.
16104 (traceframe_find_block_type): Rename to ...
16105 (traceframe_walk_blocks): ... this. Add callback filter argument,
16106 and use it.
16107 (traceframe_find_block_type): New, reimplemented on top of
16108 traceframe_walk_blocks.
16109 (build_traceframe_info_xml): New.
16110 (traceframe_read_info): New.
16111 * server.h (traceframe_read_info): Declare.
16112
4f3e6fb7
YQ
161132011-02-11 Yao Qi <yao@codesourcery.com>
16114
16115 * configure.ac: Call AC_PROG_RANLIB.
16116 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16117 * configure: Regenerate.
16118
764880b7
PA
161192011-02-07 Pedro Alves <pedro@codesourcery.com>
16120
16121 * server.c (gdb_read_memory): Change return semantics to allow
16122 partial transfers.
16123 (handle_search_memory_1): Adjust.
16124 (process_serial_event) <'m' packet>: Handle partial transfers.
16125 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16126
1c79eb8a
PA
161272011-01-28 Pedro Alves <pedro@codesourcery.com>
16128
16129 * regcache.c (init_register_cache): Initialize
16130 regcache->register_status.
16131 (free_register_cache): Release regcache->register_status.
16132 (regcache_cpy): Copy register_status.
16133 (registers_to_string): Print 'x's for unavailable registers.
16134 (supply_register): Mark the register's status valid or
16135 unavailable, depending on whether a buffer was passed in or not.
16136 (supply_register_zeroed): New.
16137 (supply_regblock): Mark the registers' status valid or
16138 unavailable, depending on whether a buffer was passed in or not.
16139 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16140 (struct regcache): New `register_status' field.
16141 (supply_register_zeroed): Declare.
16142 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16143 supply_register_zeroed, rather than passing a NULL buffer to
16144 supply_register.
16145 * tracepoint.c (fetch_traceframe_registers): Update comment.
16146
85724a0e
PA
161472011-01-28 Pedro Alves <pedro@codesourcery.com>
16148
16149 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16150 buffer explicit.
16151
d08aafef
PA
161522011-01-25 Pedro Alves <pedro@codesourcery.com>
16153
16154 * server.h (decode_xfer_write): Change prototype.
16155 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16156 and don't extract the annex here.
16157 * server.c (decode_xfer_read): Remove `annex' parameter,
16158 and don't extract the annex here.
16159 (decode_xfer): New.
16160 (struct qxfer): New.
16161 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16162 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16163 (handle_qxfer_statictrace): New functions, abstracted out from
16164 handle_query, and made to use the struct qxfer interface.
16165 (handle_threads_qxfer_proper): Rename to ...
16166 (handle_qxfer_threads_proper): ... this.
16167 (handle_threads_qxfer): Rename to ...
16168 (handle_qxfer_threads): ... this. Adjust.
16169 (qxfer_packets): New array.
16170 (handle_qxfer): New function.
16171 (handle_query): Use handle_qxfer.
16172
493e2a69
MS
161732011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16174
16175 * gdbreplay.c: Shorten lines of >= 80 columns.
16176 * linux-low.c: Ditto.
16177 * linux-ppc-low.c: Ditto.
16178 * linux-s390-low.c: Ditto.
16179 * linux-sparc-low.c: Ditto.
16180 * linux-x86-low.c: Ditto.
16181 * linux-xtensa-low.c: Ditto.
16182 * mem-break.c: Ditto.
16183 * nto-low.c: Ditto.
16184 * regcache.h: Ditto.
16185 * remote-utils.c: Ditto.
16186 * server.c: Ditto.
16187 * server.h: Ditto.
16188 * thread-db.c: Ditto.
16189 * tracepoint.c: Ditto.
16190 * utils.c: Ditto.
16191 * win32-low.h: Ditto.
16192
44944448
JB
161932011-01-05 Joel Brobecker <brobecker@adacore.com>
16194
16195 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16196 update.
16197
71ce852c
JB
161982011-01-01 Joel Brobecker <brobecker@adacore.com>
16199
16200 * server.c (gdbserver_version): Update copyright year in version
16201 output.
16202 * gdbreplay.c (gdbreplay_version): Ditto.
16203
eb826dc6
MF
162042010-12-29 Jie Zhang <jie.zhang@analog.com>
16205
16206 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16207 * linux-bfin-low.c: New file.
16208 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16209 PT_DATA_ADDR for BFIN targets.
16210 * Makefile.in (SFILES): Add linux-bfin-low.c.
16211 (clean): Remove reg-bfin.c.
16212 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16213 * README: Mention supported Blackfin targets.
16214
39ab222a
MF
162152010-12-23 Mike Frysinger <vapier@gentoo.org>
16216
16217 * .gitignore: New file.
16218
a1f2ce7d
MF
162192010-11-16 Mike Frysinger <vapier@gentoo.org>
16220
16221 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16222
f474844c
JZ
162232010-10-22 Jie Zhang <jie@codesourcery.com>
16224
16225 * Makefile.in: Add FLAGS_TO_PASS variable.
16226 (install): Remove dependency of install-only and recursively
16227 invoke make for install-only.
16228
f1048712
DE
162292010-10-04 Doug Evans <dje@google.com>
16230
16231 * Makefile.in (uninstall): Use $(DESTDIR).
16232
b53a1623
PA
162332010-09-24 Pedro Alves <pedro@codesourcery.com>
16234
e6ee044d
PA
16235 PR gdb/11842
16236
b53a1623
PA
16237 * linux-x86-low.c (compat_siginfo_from_siginfo)
16238 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16239 si_code is < 0. Check for si_code == SI_TIMER before checking for
16240 si_code < 0.
16241
fa1bd1e4
JB
162422010-09-13 Joel Brobecker <brobecker@adacore.com>
16243
16244 * lynx-i386-low.c: New file.
16245 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16246
47fac8f8
JB
162472010-09-13 Joel Brobecker <brobecker@adacore.com>
16248
16249 * lynx-low.c (ptrace_request_to_str): Remove handling for
16250 request values that have been removed in LynxOS 5.x.
16251
1adfc54d
JB
162522010-09-13 Joel Brobecker <brobecker@adacore.com>
16253
16254 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16255 <ptrace.h>
16256
c2a66c29
NS
162572010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16258
16259 * configure.ac: Add --enable-inprocess-agent option.
16260 * configure: Rebuilt.
16261
32fcada3
YQ
162622010-09-06 Yao Qi <yao@codesourcery.com>
16263
16264 * linux-low.c (linux_kill): Remove unused variable.
16265 (linux_stabilize_threads): Likewise.
16266 * server.c (start_inferior): Likewise.
16267 (queue_stop_reply_callback): Likewise.
16268 * tracepoint.c (do_action_at_tracepoint): Likewise.
16269
0cccb683
YQ
162702010-09-06 Yao Qi <yao@codesourcery.com>
16271
16272 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16273 on return.
16274
423ec54c
JK
162752010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16276
16277 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16278
12ac6819
PA
162792010-09-06 Pedro Alves <pedro@codesourcery.com>
16280
16281 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16282 "$(IPA_DEPFILES)".
16283
8ed54b31
JB
162842010-09-01 Joel Brobecker <brobecker@adacore.com>
16285
16286 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16287 gdbserver/lynx-ppc-low.c: New files.
16288 * Makefile.in (lynx_low_h): New variable.
16289 (lynx-low.o, lynx-ppc-low.o): New rules.
16290 * configure.ac: On LynxOS, link with -lnetinet.
16291 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16292 * configure: regenerate.
16293
bb0116a4
JB
162942010-09-01 Joel Brobecker <brobecker@adacore.com>
16295
16296 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16297 * configure.ac: Add check for vasprintf and vsnprintf.
16298 * configure, config.in: Regenerate.
16299 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16300
a778ab81 163012010-09-01 Joel Brobecker <brobecker@adacore.com>
16302
16303 * gdbreplay.c: Move include of alloca.h up, next to include of
16304 malloc.h.
16305 * server.h: Add include of malloc.h.
16306 * mem-break.c: Remove include of malloc.h.
16307 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16308
8b034a19 163092010-09-01 Joel Brobecker <brobecker@adacore.com>
16310
16311 * Makefile.in (memmem.o): Build with -Wno-error.
16312
163132010-09-01 Joel Brobecker <brobecker@adacore.com>
16314
16315 * utils.c (xsnprintf): Make non-static.
16316 * server.h: Add xsnprintf declaration.
16317 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16318 replace calls to snprintf by calls to xsnprintf throughout.
16319
163202010-09-01 Joel Brobecker <brobecker@adacore.com>
16321
16322 * configure.ac: Add configure check for alloca.
16323 * configure, config.in: Regenerate.
16324 * server.h: Include alloca.h if it exists.
16325 * gdbreplay.c: Include alloca.h if it exists.
16326
1a981360
PA
163272010-08-28 Pedro Alves <pedro@codesourcery.com>
16328
16329 * linux-low.c (__SIGRTMIN): Define if not already defined.
16330 (linux_create_inferior): Check for __ANDROID__ rather than
16331 __SIGRTMIN.
16332 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16333 are already deferred.
16334 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16335 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16336 stopped and already has a pending signal to report.
16337 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16338 a pending signal to report or is moving out of a jump pad.
16339 (linux_init_signals): Check for __ANDROID__ rather than
16340 __SIGRTMIN.
16341
b4d51a55
PA
163422010-08-28 Pedro Alves <pedro@codesourcery.com>
16343
16344 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16345 debug_threads check. Avoid a linear search when not doing debug
16346 output.
16347
ec48365d
PA
163482010-08-27 Pedro Alves <pedro@codesourcery.com>
16349
16350 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16351 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16352 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16353 (process_event): Change local fd's type to gdb_fildes_t.
16354 (create_file_handler): Adjust prototype.
16355 (delete_file_handler): Adjust prototype.
16356 (handle_file_event): Adjust prototype. Use pfildes.
16357 (create_file_event): Adjsut prototype.
16358 * remote-utils.c (remote_desc, listen_desc): Change type to
16359 gdb_fildes_t.
16360 * server.h: New gdb_fildes_t typedef.
16361 [USE_WIN32API]: Include winsock2.h.
16362 (delete_file_handler, add_file_handler): Adjust prototypes.
16363 (pfildes): Declare.
16364 * utils.c (pfildes): New.
16365
854d88f0
PA
163662010-08-27 Pedro Alves <pedro@codesourcery.com>
16367
16368 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16369 * configure: Regenerate.
16370
0146f85b
PA
163712010-08-27 Pedro Alves <pedro@codesourcery.com>
16372
16373 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16374 (linux_done_accessing_memory): ... this.
16375 (linux_target_ops): Adjust.
16376 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16377 * nto-low.c (nto_target_ops): Adjust comment.
16378 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16379 * spu-low.c (spu_target_ops): Adjust comment.
16380 * target.h (target_ops): Rename unprepare_to_access_memory field
16381 to done_accessing_memory.
16382 (unprepare_to_access_memory): Rename to ...
16383 (done_accessing_memory): ... this.
16384
90d74c30
PA
163852010-08-26 Pedro Alves <pedro@codesourcery.com>
16386
16387 * linux-low.c (linux_prepare_to_access_memory): New.
16388 (linux_unprepare_to_access_memory): New.
16389 (linux_target_ops): Install them.
16390 * server.c (read_memory): Rename to ...
16391 (gdb_read_memory): ... this. Use
16392 prepare_to_access_memory/prepare_to_access_memory.
16393 (write_memory): Rename to ...
16394 (gdb_write_memory): ... this. Use
16395 prepare_to_access_memory/prepare_to_access_memory.
16396 (handle_search_memory_1): Adjust.
16397 (process_serial_event): Adjust.
16398 * target.h (struct target_ops): New fields
16399 prepare_to_access_memory and unprepare_to_access_memory.
16400 (prepare_to_access_memory, unprepare_to_access_memory): New.
16401 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16402 prepare_to_access_memory/prepare_to_access_memory.
16403 * nto-low.c (nto_target_ops): Adjust.
16404 * spu-low.c (spu_target_ops): Adjust.
16405 * win32-low.c (win32_target_ops): Adjust.
16406
fd467969
PA
164072010-08-26 Pedro Alves <pedro@codesourcery.com>
16408
16409 * Makefile.in (WARN_CFLAGS): Get it from configure.
16410 (WERROR_CFLAGS): New.
16411 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16412 * configure.ac: Introduce --enable-werror, which adds -Werror to
16413 the compiler command line. Enabled by default. Disable with
16414 --disable-werror. Add -Wdeclaration-after-statement
16415 Wpointer-arith and -Wformat-nonliteral to warning flags.
16416 * configure: Regenerate.
16417
331e2f5f
PA
164182010-08-26 Pedro Alves <pedro@codesourcery.com>
16419
16420 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16421
e581f2b4
PA
164222010-08-26 Pedro Alves <pedro@codesourcery.com>
16423
16424 * gdbreplay.c (remote_error): New.
16425 (gdbchar): New.
16426 (expect): Use gdbchar. Check for error reading from GDB.
16427 Clarify sync error output.
16428 (play): Check for errors writing to GDB.
16429 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16430 * remote-utils.c (getpkt): Check for errors writing to the remote
16431 descriptor.
16432
3c11dd79
PA
164332010-08-25 Pedro Alves <pedro@codesourcery.com>
16434
16435 * linux-low.c (linux_wait_1): Move non-debugging code out of
16436 `debug_threads' control.
16437
d20a8ad9
PA
164382010-08-25 Pedro Alves <pedro@codesourcery.com>
16439
16440 * linux-low.c (linux_wait_1): Don't set last_status here.
16441 * server.c (push_event, queue_stop_reply_callback): Assert we're
16442 not pushing a TARGET_WAITKIND_IGNORE event.
16443 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16444 (myresume, handle_target_event): Set the thread's last_resume_kind
16445 and last_status from the target returned status.
16446
964e4306
PA
164472010-08-25 Pedro Alves <pedro@codesourcery.com>
16448
16449 PR threads/10729
16450
16451 * linux-x86-low.c (update_debug_registers_callback): New.
16452 (i386_dr_low_set_addr): Use it.
16453 (i386_dr_low_get_addr): New.
16454 (i386_dr_low_set_control): Use update_debug_registers_callback.
16455 (i386_dr_low_get_control): New.
16456 (i386_dr_low_get_status): Adjust.
16457 * linux-low.c (linux_stop_lwp): New.
16458 * linux-low.h (linux_stop_lwp): Declare.
16459
16460 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16461 argument instead of a i386_debug_reg_state.
16462 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16463 a i386_debug_reg_state.
16464 (i386_insert_aligned_watchpoint): Adjust.
16465 (i386_remove_aligned_watchpoint): Adjust.
16466 (i386_low_stopped_data_address): Read the debug registers from the
16467 inferior instead of from the mirrors.
16468 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16469 (i386_dr_low_get_addr): Declare.
16470 (i386_dr_low_get_control): Declare.
16471 (i386_dr_low_get_status): Change prototype.
16472
16473 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16474 (i386_dr_low_get_addr): New.
16475 (i386_dr_low_get_control): New.
16476 (i386_dr_low_get_status): Adjust prototype. Return
16477 dr_status_mirror.
16478 (i386_initial_stuff): Clear dr_status_mirror and
16479 dr_control_mirror.
16480 (i386_get_thread_context): Adjust.
16481 (i386_set_thread_context): Adjust.
16482 (i386_thread_added): Adjust.
16483
5f21a75b
PA
164842010-08-24 Pedro Alves <pedro@codesourcery.com>
16485
16486 * linux-low.h (linux_thread_area): Delete declaration.
16487
3e4c1235
TS
164882010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16489
16490 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16491 after its termination.
16492
1971b033
PA
164932010-08-09 Pedro Alves <pedro@codesourcery.com>
16494
16495 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16496 (gdb_wants_all_stopped): Delete.
16497 (linux_wait_1): Don't call them.
16498 * server.c (handle_v_cont): Tag all threads as want-stopped.
16499 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16500 stopped as "client-wants-stopped".
16501
310444ac
PA
165022010-07-31 Pedro Alves <pedro@codesourcery.com>
16503
16504 * Makefile.in (signals_h): New.
16505 (server_h): Depend on it.
16506 (server.o): Don't depend on $(signals_def).
16507 (signals.o): Depend on $(signals_def).
16508
a19cae16
JK
165092010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16510
16511 * Makefile.in (signals_def): New.
16512 (server_h): Append include/gdb/signals.h and signals_def.
16513 (server.o): Append signals_def.
16514
30d50328
JK
165152010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16516
16517 * server.c (handle_target_event): Use target_signal_to_host for
16518 resume_info.sig initialization.
16519 * target.h (struct thread_resume) <sig>: New comment.
16520
5c3216e2
OS
165212010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16522
c6f46ca0
OS
16523 * server.c (handle_query): strcpy() the returned string from paddress()
16524 instead of sprintf().
5c3216e2
OS
16525 * utils.c (paddress): Return phex_nz().
16526
6bd31874
JB
165272010-07-07 Joel Brobecker <brobecker@adacore.com>
16528
16529 * server.c (handle_v_cont): Call mourn_inferior if process
16530 just exited.
16531 (myresume): Likewise.
16532
0fb4aa4b
PA
165332010-07-01 Pedro Alves <pedro@codesourcery.com>
16534
16535 Static tracepoints, and integration with UST.
16536
16537 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16538 * mem-break.c (uninsert_all_breakpoints)
16539 (reinsert_all_breakpoints): New.
16540 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16541 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16542 (gdb_agent_ust_loaded, helper_thread_id)
16543 (gdb_agent_helper_thread_id): New macros.
16544 (struct ipa_sym_addresses): Add addr_ust_loaded,
16545 addr_helper_thread_id, addr_cmd_buf.
16546 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16547 (in_process_agent_loaded_ust): New.
16548 (write_e_ust_not_loaded): New.
16549 (maybe_write_ipa_ust_not_loaded): New.
16550 (struct collect_static_trace_data_action): New.
16551 (enum tracepoint_type) <static_tracepoint>: New.
16552 (struct tracepoint) <handle>: Mention static tracepoints.
16553 (struct static_tracepoint_ctx): New.
16554 (CMD_BUF_SIZE): New.
16555 (add_tracepoint_action): Handle static tracepoint actions.
16556 (unprobe_marker_at): New.
16557 (clear_installed_tracepoints): Handle static tracepoints.
16558 (cmd_qtdp): Handle static tracepoints.
16559 (probe_marker_at): New.
16560 (cmd_qtstart): Handle static tracepoints.
16561 (response_tracepoint): Handle static tracepoints.
16562 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16563 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16564 (get_context_regcache): Handle static tracepoints.
16565 (do_action_at_tracepoint): Handle static tracepoint actions.
16566 (traceframe_find_block_type): Handle static trace data blocks.
16567 (traceframe_read_sdata): New.
16568 (download_tracepoints): Download static tracepoint actions.
16569 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16570 (GDB_PROBE_NAME): New.
16571 (ust_ops): New.
16572 (GET_UST_SYM): New.
16573 (USTF): New.
16574 (dlsym_ust): New.
16575 (ust_marker_to_static_tracepoint): New.
16576 (gdb_probe): New.
16577 (collect_ust_data_at_tracepoint): New.
16578 (gdb_ust_probe): New.
16579 (UNIX_PATH_MAX, SOCK_DIR): New.
16580 (gdb_ust_connect_sync_socket): New.
16581 (resume_thread, stop_thread): New.
16582 (run_inferior_command): New.
16583 (init_named_socket): New.
16584 (gdb_ust_socket_init): New.
16585 (cstr_to_hexstr): New.
16586 (next_st): New.
16587 (first_marker, next_marker): New.
16588 (response_ust_marker): New.
16589 (cmd_qtfstm, cmd_qtsstm): New.
16590 (unprobe_marker_at, probe_marker_at): New.
16591 (cmd_qtstmat, gdb_ust_thread): New.
16592 (gdb_ust_init): New.
16593 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16594 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16595 (ST_REGENTRY): New.
16596 (x86_64_st_collect_regmap): New.
16597 (X86_64_NUM_ST_COLLECT_GREGS): New.
16598 (AMD64_RIP_REGNUM): New.
16599 (supply_static_tracepoint_registers): New.
16600 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16601 (ST_REGENTRY): New.
16602 (i386_st_collect_regmap): New.
16603 (i386_NUM_ST_COLLECT_GREGS): New.
16604 (supply_static_tracepoint_registers): New.
16605 * server.c (handle_query): Handle qXfer:statictrace:read.
16606 <qSupported>: Report support for StaticTracepoints, and
16607 qXfer:statictrace:read features.
16608 * server.h (traceframe_read_sdata)
16609 (supply_static_tracepoint_registers): Declare.
16610 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16611 (unpack_varlen_hex): Include in IPA build.
16612 * Makefile.in (ustlibs, ustinc): New.
16613 (IPA_OBJS): Add remote-utils-ipa.o.
16614 ($(IPA_LIB)): Link -ldl and -lpthread.
16615 (UST_CFLAGS): New.
16616 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16617 * config.in, configure: Regenerate.
16618
9e4344e5
PA
166192010-06-20 Ian Lance Taylor <iant@google.com>
16620 Pedro Alves <pedro@codesourcery.com>
16621
16622 * linux-x86-low.c (always_true): Delete.
16623 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16624 trying to fool the compiler with always_true.
16625
c6beb2cb
PA
166262010-06-20 Pedro Alves <pedro@codesourcery.com>
16627
16628 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16629 conditions in gdbserver.
16630
d2ed6730
UW
166312010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16632
16633 * spu-low.c (spu_read_memory): Wrap around local store limit.
16634 (spu_write_memory): Likewise.
16635
4e29fb54
PA
166362010-06-15 Pedro Alves <pedro@codesourcery.com>
16637
16638 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16639 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16640 LONGEST uses.
16641 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16642 uses.
16643 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16644 uses with LONGEST uses.
16645
6a271cae
PA
166462010-06-14 Stan Shebs <stan@codesourcery.com>
16647 Pedro Alves <pedro@codesourcery.com>
16648
16649 Bytecode compiler.
16650
16651 * linux-x86-low.c: Include limits.h.
16652 (add_insns): New.
16653 (always_true): New.
16654 (EMIT_ASM): New.
16655 (EMIT_ASM32): New.
16656 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16657 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16658 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16659 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16660 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16661 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16662 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16663 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16664 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16665 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16666 (amd64_emit_void_call_2): New.
16667 (amd64_emit_ops): New.
16668 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16669 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16670 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16671 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16672 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16673 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16674 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16675 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16676 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16677 (i386_emit_stack_adjust, i386_emit_int_call_1)
16678 (i386_emit_void_call_2): New.
16679 (i386_emit_ops): New.
16680 (x86_emit_ops): New.
16681 (the_low_target): Install x86_emit_ops.
16682 * server.h (struct emit_ops): New.
16683 (get_raw_reg_func_addr): Declare.
16684 (current_insn_ptr, emit_error): Declare.
16685 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16686 (set_trace_state_variable_value): New defines.
16687 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16688 addr_get_trace_state_variable_value and
16689 addr_set_trace_state_variable_value.
16690 (symbol_list): New fields for get_raw_reg,
16691 get_trace_state_variable_value and set_trace_state_variable_value.
16692 (condfn): New typedef.
16693 (struct tracepoint): New field `compiled_cond'.
16694 (do_action_at_tracepoint): Clear compiled_cond.
16695 (get_trace_state_variable_value, set_trace_state_variable_value):
16696 Export in the IPA.
16697 (condition_true_at_tracepoint): If there's a compiled condition,
16698 run that.
16699 (current_insn_ptr, emit_error): New globals.
16700 (struct bytecode_address): New.
16701 (get_raw_reg_func_addr): New.
16702 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16703 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16704 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16705 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16706 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16707 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16708 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16709 (compile_tracepoint_condition, compile_bytecodes): New.
16710 * target.h (emit_ops): Forward declare.
16711 (struct target_ops): New field emit_ops.
16712 (target_emit_ops): New.
16713 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16714 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16715 * linux-low.c (linux_emit_ops): New.
16716 (linux_target_ops): Install it.
16717 * linux-low.h (struct linux_target_ops): New field emit_ops.
16718
92b72907
UW
167192010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16720
16721 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16722 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16723
fa593d66
PA
167242010-06-01 Pedro Alves <pedro@codesourcery.com>
16725 Stan Shebs <stan@codesourcery.com>
16726
16727 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
16728 (all): Depend on $(extra_libraries).
16729 (install-only): Install the IPA.
16730 (IPA_OBJS, IPA_LIB): New.
16731 (clean): Remove the IPA lib.
16732 (IPAGENT_CFLAGS): New.
16733 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
16734 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
16735 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
16736 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
16737 * configure.ac: Check for atomic builtins support in the compiler.
16738 (IPA_DEPFILES, extra_libraries): Define.
16739 * configure.srv (ipa_obj): Add description.
16740 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
16741 (i[34567]86-*-linux*): Set ipa_obj.
16742 (x86_64-*-linux*): Set ipa_obj.
16743 * linux-low.c (stabilizing_threads): New.
16744 (supports_fast_tracepoints): New.
16745 (linux_detach): Stabilize threads before detaching.
16746 (handle_tracepoints): Handle internal tracing breakpoints. Assert
16747 the lwp is either not stabilizing, or is moving out of a jump pad.
16748 (linux_fast_tracepoint_collecting): New.
16749 (maybe_move_out_of_jump_pad): New.
16750 (enqueue_one_deferred_signal): New.
16751 (dequeue_one_deferred_signal): New.
16752 (linux_wait_for_event_1): If moving out of a jump pad, defer
16753 pending signals to later.
16754 (linux_stabilize_threads): New.
16755 (linux_wait_1): Check if threads need moving out of jump pads, and
16756 do it if so.
16757 (stuck_in_jump_pad_callback): New.
16758 (move_out_of_jump_pad_callback): New.
16759 (lwp_running): New.
16760 (linux_resume_one_lwp): Handle moving out of jump pads.
16761 (linux_set_resume_request): Dequeue deferred signals.
16762 (need_step_over_p): Also step over fast tracepoint jumps.
16763 (start_step_over): Also uninsert fast tracepoint jumps.
16764 (finish_step_over): Also reinsert fast tracepoint jumps.
16765 (linux_install_fast_tracepoint_jump): New.
16766 (linux_target_ops): Install linux_stabilize_threads and
16767 linux_install_fast_tracepoint_jump_pad.
16768 * linux-low.h (linux_target_ops) <get_thread_area,
16769 install_fast_tracepoint_jump_pad>: New fields.
16770 (struct lwp_info) <collecting_fast_tracepoint,
16771 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
16772 (linux_get_thread_area): Declare.
16773 * linux-x86-low.c (jump_insn): New.
16774 (x86_get_thread_area): New.
16775 (append_insns): New.
16776 (push_opcode): New.
16777 (amd64_install_fast_tracepoint_jump_pad): New.
16778 (i386_install_fast_tracepoint_jump_pad): New.
16779 (x86_install_fast_tracepoint_jump_pad): New.
16780 (the_low_target): Install x86_get_thread_area and
16781 x86_install_fast_tracepoint_jump_pad.
16782 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
16783 (struct fast_tracepoint_jump): New.
16784 (fast_tracepoint_jump_insn): New.
16785 (fast_tracepoint_jump_shadow): New.
16786 (find_fast_tracepoint_jump_at): New.
16787 (fast_tracepoint_jump_here): New.
16788 (delete_fast_tracepoint_jump): New.
16789 (set_fast_tracepoint_jump): New.
16790 (uninsert_fast_tracepoint_jumps_at): New.
16791 (reinsert_fast_tracepoint_jumps_at): New.
16792 (set_breakpoint_at): Use write_inferior_memory.
16793 (uninsert_raw_breakpoint): Use write_inferior_memory.
16794 (check_mem_read): Mask out fast tracepoint jumps.
16795 (check_mem_write): Mask out fast tracepoint jumps.
16796 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
16797 (set_fast_tracepoint_jump): Declare.
16798 (delete_fast_tracepoint_jump)
16799 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
16800 (reinsert_fast_tracepoint_jumps_at): Declare.
16801 * regcache.c: Don't compile many functions when building the
16802 in-process agent library.
16803 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
16804 the register buffer in the heap.
16805 (free_register_cache): If the register buffer isn't owned by the
16806 regcache, don't free it.
16807 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
16808 pre-existing register caches.
16809 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
16810 type.
16811 (convert_ascii_to_int): : Constify `from' parameter type.
16812 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
16813 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
16814 the needed buffer in-place.
16815 (relocate_instruction): New.
16816 * server.c (handle_query) <qSymbols>: If the target supports
16817 tracepoints, give it a chance of looking up symbols. Report
16818 support for fast tracepoints.
16819 (handle_status): Stabilize threads.
16820 (process_serial_event): Adjust.
16821 * server.h (struct fast_tracepoint_jump): Forward declare.
16822 (struct process_info) <fast_tracepoint_jumps>: New field.
16823 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
16824 (decode_X_packet, decode_M_packet): Adjust.
16825 (relocate_instruction): Declare.
16826 (in_process_agent_loaded): Declare.
16827 (tracepoint_look_up_symbols): Declare.
16828 (struct fast_tpoint_collect_status): Declare.
16829 (fast_tracepoint_collecting): Declare.
16830 (force_unlock_trace_buffer): Declare.
16831 (handle_tracepoint_bkpts): Declare.
16832 (initialize_low_tracepoint)
16833 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
16834 * target.h (struct target_ops) <stabilize_threads,
16835 install_fast_tracepoint_jump_pad>: New fields.
16836 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
16837 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
16838 [HAVE_STDINT_H]: Include stdint.h.
16839 (trace_debug_1): Rename to ...
16840 (trace_vdebug): ... this.
16841 (trace_debug): Rename to ...
16842 (trace_debug_1): ... this. Add `level' parameter.
16843 (trace_debug): New.
16844 (ATTR_USED, ATTR_NOINLINE): New.
16845 (IP_AGENT_EXPORT): New.
16846 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
16847 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
16848 (about_to_request_buffer_space, trace_buffer_is_full)
16849 (stopping_tracepoint, expr_eval_result, error_tracepoint)
16850 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
16851 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
16852 (traceframe_write_count, traceframes_created)
16853 (trace_state_variables)
16854 New renaming defines.
16855 (struct ipa_sym_addresses): New.
16856 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
16857 (symbol_list): New.
16858 (ipa_sym_addrs): New.
16859 (all_tracepoint_symbols_looked_up): New.
16860 (in_process_agent_loaded): New.
16861 (write_e_ipa_not_loaded): New.
16862 (maybe_write_ipa_not_loaded): New.
16863 (tracepoint_look_up_symbols): New.
16864 (debug_threads) [IN_PROCESS_AGENT]: New.
16865 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
16866 (UNKNOWN_SIDE_EFFECTS): New.
16867 (stop_tracing): New.
16868 (flush_trace_buffer): New.
16869 (stop_tracing_bkpt): New.
16870 (flush_trace_buffer_bkpt): New.
16871 (read_inferior_integer): New.
16872 (read_inferior_uinteger): New.
16873 (read_inferior_data_pointer): New.
16874 (write_inferior_data_pointer): New.
16875 (write_inferior_integer): New.
16876 (write_inferior_uinteger): New.
16877 (struct collect_static_trace_data_action): Delete.
16878 (enum tracepoint_type): New.
16879 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
16880 <actions_str, step_actions, step_actions_str>: Only include in
16881 GDBserver.
fa593d66
PA
16882 <orig_size, obj_addr_on_target, adjusted_insn_addr>
16883 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
16884 (tracepoints): Use IP_AGENT_EXPORT.
16885 (last_tracepoint): Don't include in the IPA.
16886 (stopping_tracepoint): Use IP_AGENT_EXPORT.
16887 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
16888 (alloced_trace_state_variables): New.
16889 (trace_state_variables): Use IP_AGENT_EXPORT.
16890 (traceframe_t): Delete unused variable.
16891 (circular_trace_buffer): Don't include in the IPA.
16892 (trace_buffer_start): Delete.
16893 (struct trace_buffer_control): New.
16894 (trace_buffer_free): Delete.
16895 (struct ipa_trace_buffer_control): New.
16896 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
16897 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
16898 New.
16899 (trace_buffer_ctrl): New.
16900 (TRACE_BUFFER_CTRL_CURR): New.
16901 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
16902 Reimplement as macros.
16903 (trace_buffer_wrap): Delete.
16904 (traceframe_write_count, traceframe_read_count)
16905 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
16906 (struct tracepoint_hit_ctx) <type>: New field.
16907 (struct fast_tracepoint_ctx): New.
16908 (memory_barrier): New.
16909 (cmpxchg): New.
16910 (record_tracepoint_error): Update atomically in the IPA.
16911 (clear_inferior_trace_buffer): New.
16912 (about_to_request_buffer_space): New.
16913 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
16914 updating the same buffer.
16915 (add_tracepoint): Default the tracepoint's type to trap
16916 tracepoint, and orig_size to -1.
16917 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
16918 internal variables.
16919 (create_trace_state_variable): New parameter `gdb'. Handle it.
16920 (clear_installed_tracepoints): Clear fast tracepoint jumps.
16921 (cmd_qtdp): Handle fast tracepoints.
16922 (cmd_qtdv): Adjust.
16923 (max_jump_pad_size): New.
16924 (gdb_jump_pad_head): New.
16925 (get_jump_space_head): New.
16926 (claim_jump_space): New.
16927 (sort_tracepoints): New.
16928 (MAX_JUMP_SIZE): New.
16929 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
16930 IPA.
16931 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
16932 support. Upload fast traceframes, and delete internal IPA
16933 breakpoints.
16934 (stop_tracing_handler): New.
16935 (flush_trace_buffer_handler): New.
16936 (cmd_qtstop): Upload fast tracepoints.
16937 (response_tracepoint): Handle fast tracepoints.
16938 (tracepoint_finished_step): Upload fast traceframes. Set the
16939 tracepoint hit context's tracepoint type.
16940 (handle_tracepoint_bkpts): New.
16941 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
16942 type. Add comment about fast tracepoints.
16943 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
16944 non-existing action_str field.
16945 (get_context_regcache): Handle fast tracepoints.
16946 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
16947 to the regcache.
16948 (fast_tracepoint_from_jump_pad_address): New.
16949 (fast_tracepoint_from_ipa_tpoint_address): New.
16950 (collecting_t): New.
16951 (force_unlock_trace_buffer): New.
16952 (fast_tracepoint_collecting): New.
16953 (collecting): New.
16954 (gdb_collect): New.
16955 (write_inferior_data_ptr): New.
16956 (target_tp_heap): New.
16957 (target_malloc): New.
16958 (download_agent_expr): New.
16959 (UALIGN): New.
16960 (download_tracepoints): New.
16961 (download_trace_state_variables): New.
16962 (upload_fast_traceframes): New.
16963 (IPA_FIRST_TRACEFRAME): New.
16964 (IPA_NEXT_TRACEFRAME_1): New.
16965 (IPA_NEXT_TRACEFRAME): New.
16966 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
16967 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
16968 (gdb_jump_pad_buffer_end): New.
16969 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
16970 (initialize_tracepoint): Adjust.
16971 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
16972 buffer. Initialize the low module.
16973 * utils.c (PREFIX, TOOLNAME): New.
16974 (malloc_failure): Use PREFIX.
16975 (error): In the IPA, an error causes an exit.
16976 (fatal, warning): Use PREFIX.
16977 (internal_error): Use TOOLNAME.
16978 (NUMCELLS): Increase to 10.
16979 * configure, config.in: Regenerate.
16980
d149dd1d
PA
169812010-06-01 Pedro Alves <pedro@codesourcery.com>
16982
16983 * server.c (handle_query) <qSupported>: Do two passes over the
16984 qSupported string to avoid nesting strtok.
16985
f6528abd
JK
169862010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16987
16988 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
16989 (CDEPS): New.
16990 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
16991 -Wl,--dynamic-list.
16992 * configure: Regenerate.
16993 * proc-service.list: New.
16994
ca2a87a0
JK
169952010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16996
16997 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
16998 New comment.
16999
363a6e9f
OS
170002010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17001
17002 * gdbreplay.c (remote_open): Check error return from socket() call by
17003 its equality to -1 not by it being negative.
17004 * remote-utils.c (remote_open): Likewise.
17005
d23b6cb1
PA
170062010-05-23 Pedro Alves <pedro@codesourcery.com>
17007
17008 * config.h: Regenerate.
17009
28d3cf85
MK
170102010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17011
17012 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17013 doesn't provide PTRACE_GET_THREAD_AREA.
17014
fea36a59
MK
170152010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17016
17017 * linux-m68k-low.c: Include <asm/ptrace.h>
17018 (ps_get_thread_area): Implement.
17019
24b066ba
DE
170202010-05-03 Doug Evans <dje@google.com>
17021
17022 * event-loop.c (struct callback_event): New struct.
17023 (callback_list): New global.
17024 (append_callback_event, delete_callback_event): New functions.
17025 (process_callback): New function.
17026 (start_event_loop): Call it.
17027 * remote-utils.c (NOT_SCHEDULED): Define.
17028 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17029 moved out of readchar.
17030 (readchar): Rewrite. Call reschedule before returning.
17031 (reset_readchar): New function.
17032 (remote_close): Call it.
17033 (process_remaining, reschedule): New functions.
17034 * server.h (callback_handler_func): New typedef.
17035 (append_callback_event, delete_callback_event): Declare.
17036
9836d6ea
PA
170372010-05-03 Pedro Alves <pedro@codesourcery.com>
17038
17039 * proc-service.c (ps_pglobal_lookup): Use
17040 thread_db_look_up_one_symbol.
17041 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17042 parameter. Use it instead of all_symbols_looked_up.
17043 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17044 field.
17045 (all_symbols_looked_up): Don't declare.
17046 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17047 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17048 field.
17049 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17050 Set all_symbols_looked_up here.
17051 (thread_db_look_up_one_symbol): New.
17052 (thread_db_get_tls_address): Adjust.
17053 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17054 thread_db object on the heap, and tentatively set it in the
17055 process structure.
17056 (thread_db_init): Don't set all_symbols_looked_up here.
17057 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17058
7984d532
PA
170592010-05-03 Pedro Alves <pedro@codesourcery.com>
17060
17061 * linux-low.c (linux_kill, linux_detach): Adjust.
17062 (status_pending_p_callback): Remove redundant statement. Check
17063 for !TARGET_WAITIKIND_IGNORE, instead of
17064 TARGET_WAITKIND_STOPPED.
17065 (handle_tracepoints): Make sure LWP is locked. Adjust.
17066 (linux_wait_for_event_1): Adjust.
17067 (linux_cancel_breakpoints): New.
17068 (unsuspend_one_lwp): New.
17069 (unsuspend_all_lwps): New.
17070 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17071 (send_sigstop_callback): Change return type to int, add new
17072 `except' parameter and handle it.
17073 (suspend_and_send_sigstop_callback): New.
17074 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17075 pass them down. If SUSPEND, also increment the lwp's suspend
17076 count.
17077 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17078 (need_step_over_p): Don't consider suspended LWPs.
17079 (start_step_over): Adjust.
17080 (proceed_one_lwp): Change return type to int, add new `except'
17081 parameter and handle it.
17082 (unsuspend_and_proceed_one_lwp): New.
17083 (proceed_all_lwps): Use find_inferior instead of
17084 for_each_inferior.
17085 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17086 also decrement the suspend count of LWPs. Pass `except' down,
17087 instead of hacking its suspend count.
17088 (linux_pause_all): Add `freeze' parameter. Adjust.
17089 (linux_unpause_all): New.
17090 (linux_target_ops): Install linux_unpause_all.
17091 * server.c (handle_status): Adjust.
17092 * target.h (struct target_ops): New fields `unpause_all' and
17093 `cancel_breakpoints'. Add new parameter to `pause_all'.
17094 (pause_all): Add new `freeze' parameter.
17095 (unpause_all): New.
17096 (cancel_breakpoints): New.
17097 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17098 cancel breakpoints.
17099 (cmd_qtstart): Pause threads.
17100 (stop_tracing): Pause threads, and cancel breakpoints.
17101 * win32-low.c (win32_target_ops): Adjust.
17102
e471f25b
PA
171032010-05-03 Pedro Alves <pedro@codesourcery.com>
17104
17105 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17106 the inferior right away from here...
17107 (linux_wait_1): ... to here, and adjust to check the thread's
17108 last_resume_kind instead of the lwp's step or stop_expected flags.
17109
1915ef4f
PA
171102010-05-02 Pedro Alves <pedro@codesourcery.com>
17111
17112 * README: Use consistent `GDB' and `GDBserver' spellings.
17113
f9e39928
PA
171142010-05-02 Pedro Alves <pedro@codesourcery.com>
17115
17116 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17117 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17118 (linux_detach_one_lwp): Assume the lwp is stopped.
17119 (any_thread_of): Delete.
17120 (linux_detach): Stop all lwps here. Don't blindly delete all
17121 breakpoints.
17122 (delete_lwp_callback): New.
17123 (linux_mourn): Delete all lwps of the process that is gone.
17124 (linux_wait_1): Don't delete the last lwp of the process here.
17125 * mem-break.h (mark_breakpoints_out): Declare.
17126 * mem-break.c (mark_breakpoints_out): New.
17127 (free_all_breakpoints): Use it.
17128 * server.c (handle_target_event): If the process is gone, mark
17129 breakpoints out.
17130 * thread-db.c (struct thread_db) <create_bp>: New field.
17131 (thread_db_enable_reporting): Fix prototype. Store a thread event
17132 breakpoint reference in the thread_db struct.
17133 (thread_db_load_search): Clear the thread_db object.
17134 (try_thread_db_load_1): Ditto.
17135 (switch_to_process): New.
17136 (disable_thread_event_reporting): Use it.
17137 (remove_thread_event_breakpoints): New.
17138 (thread_db_detach, thread_db_mourn): Use it.
17139
1e7fc18c
PA
171402010-05-01 Pedro Alves <pedro@codesourcery.com>
17141
17142 * linux-low.c (linux_enable_event_reporting): New.
17143 (linux_wait_for_event_1, handle_extended_wait): Use it.
17144
02fc4de7
PA
171452010-04-30 Pedro Alves <pedro@codesourcery.com>
17146
17147 * linux-low.c (linux_kill_one_lwp, linux_kill)
17148 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17149 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17150 SIGSTOP even if the LWP is stopped.
17151 (send_sigstop_callback): New.
17152 (stop_all_lwps): Use send_sigstop_callback instead.
17153 (linux_resume_one_thread): Adjust.
17154 (proceed_one_lwp): Still proceed an LWP that the client has
17155 requested to stop, if we haven't reported it as stopped yet. Make
17156 sure that LWPs the client want stopped, have a pending SIGSTOP.
17157
bc3b5632
DE
171582010-04-26 Doug Evans <dje@google.com>
17159
ae1ada35
DE
17160 * server.c (handle_general_set): Make static.
17161
bc3b5632
DE
17162 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17163 Print received char after testing for error/eof instead of before.
17164 (input_interrupt): Tweak comment.
17165
65730243
DE
171662010-04-23 Doug Evans <dje@google.com>
17167
17168 * server.c (start_inferior): Print inferior argv if --debug.
17169
a8ae7dc0
AR
171702010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17171
17172 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17173 * nto-x86-low.c: Include server.h
17174
1c07cc19
PM
171752010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17176
17177 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17178 be consistent with other sources of this directory.
17179 (init_registers_amd64): Correct name of source file of this function
17180 in the comment.
17181
e0a61e09
PM
171822010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17183
17184 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17185 64-bit executables.
17186
54709339
PM
171872010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17188
17189 * win32-i386-low.c: Add 64-bit support.
17190 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17191 (init_registers_amd64): Declare.
17192 (mappings): Add 64-bit version of array.
17193 (init_windows_x86): New function.
17194 (the_low_target): Change init_arch field to init_windows_x86.
17195
e8f0053d
PM
171962010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17197
17198 * win32-low.c: Adapt to support also 64-bit architecture.
17199 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17200 (get_image_name): Use SIZE_T type for local variable `done'.
17201 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17202 (toolhelp_get_dll_name): Idem.
17203 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17204 Use uintptr_t typecast to avoid warning.
17205 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17206 (handle_exception): Use phex_nz to avoid warning.
17207 (win32_wait): Remove unused local variable `process'.
17208
c481e77e
PM
172092010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17210
17211 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17212 `amd64-avx.o'.
17213
12ea4b69
PM
172142010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17215
17216 * configure.ac: Use `ws2_32' library for srv_mingw.
17217 * configure: Regenerate.
17218 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17219 * remote-utils.c: Likewise.
17220
f6d1620c
L
172212010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17222
17223 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17224 if __x86_64__ is defined.
17225
8e642873
PM
172262010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17227
17228 * configure: Regenerate.
17229
711e434b
PM
172302010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17231
17232 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17233 * target.h (target_ops): New get_tib_address field.
17234 * win32-low.h (win32_thread_info): Add thread_local_base field.
17235 * win32-low.c (child_add_thread): Add tlb argument.
17236 Set thread_local_base field to TLB.
17237 (get_child_debug_event): Adapt to child_add_thread change.
17238 (win32_get_tib_address): New function.
17239 (win32_target_ops): Set get_tib_address field to
17240 win32_get_tib_address.
17241 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17242
505106cd
PA
172432010-04-12 Pedro Alves <pedro@codesourcery.com>
17244
505106cd
PA
17245 * linux-low.c (linux_mourn): Also remove the process.
17246 * server.c (handle_target_event): Don't remove the process here.
17247 * nto-low.c (nto_mourn): New.
17248 (nto_target_ops): Install it.
17249 * spu-low.c (spu_mourn): New.
17250 (spu_target_ops): Install it.
17251 * win32-low.c (win32_mourn): New.
17252 (win32_target_ops): Install it.
17253
e8470a06
PA
172542010-04-12 Pedro Alves <pedro@codesourcery.com>
17255
17256 * server.h (buffer_xml_printf): Remove redundant `;'.
17257
45ba0d02
PA
172582010-04-12 Pedro Alves <pedro@codesourcery.com>
17259
17260 * regcache.c (set_register_cache): Invalidate regcaches before
17261 changing the register cache layout.
17262 (regcache_invalidate_one): Allow a NULL regcache.
17263 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17264 regcaches before changing the register cache layout or the target
17265 regsets.
17266
59e04013
L
172672010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17268
17269 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17270 variable warning on Linux/x86-64.
17271
8336d594
PA
172722010-04-11 Pedro Alves <pedro@codesourcery.com>
17273
17274 GDBserver disconnected tracing support.
17275
17276 * linux-low.c (linux_remove_process): Delete.
17277 (add_lwp): Don't set last_resume_kind here.
17278 (linux_kill): Use `mourn'.
17279 (linux_detach): Use `thread_db_detach', and `mourn'.
17280 (linux_mourn): New.
17281 (linux_attach_lwp_1): Adjust comment.
17282 (linux_attach): last_resume_kind moved the thread_info; adjust.
17283 (status_pending_p_callback): Adjust.
17284 (linux_wait_for_event_1): Adjust.
17285 (count_events_callback, select_singlestep_lwp_callback)
17286 (select_event_lwp_callback, cancel_breakpoints_callback)
17287 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17288 (proceed_one_lwp): Adjust.
17289 (linux_async): Add debug output.
17290 (linux_thread_stopped): New.
17291 (linux_pause_all): New.
17292 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17293 linux_pause_all.
17294 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17295 (thread_db_free): Delete declaration.
17296 (thread_db_detach, thread_db_mourn): Declare.
17297 * thread-db.c (thread_db_init): Use thread_db_mourn.
17298 (thread_db_free): Delete, split in two.
17299 (disable_thread_event_reporting): New.
17300 (thread_db_detach): New.
17301 (thread_db_mourn): New.
17302
17303 * server.h (struct thread_info) <last_resume_kind>: New field.
17304 <attached>: Add comment.
17305 <gdb_detached>: New field.
17306 (handler_func): Change return type to int.
17307 (handle_serial_event, handle_target_event): Ditto.
17308 (gdb_connected): Declare.
17309 (tracing): Delete.
17310 (disconnected_tracing): Declare.
17311 (stop_tracing): Declare.
17312
17313 * server.c (handle_query) <qSupported>: Report support for
17314 disconnected tracing.
17315 (queue_stop_reply_callback): Account for running threads.
17316 (gdb_wants_thread_stopped): New.
17317 (gdb_wants_all_threads_stopped): New.
17318 (gdb_reattached_process): New.
17319 (handle_status): Clear the `gdb_detached' flag of all processes.
17320 In all-stop, stop all threads.
17321 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17322 (process_serial_event): If the remote connection breaks, or if an
17323 exit was forced with "monitor exit", force an event loop exit.
17324 Handle disconnected tracing on detach.
17325 (handle_serial_event): Adjust.
17326 (handle_target_event): If GDB isn't connected, forward events back
17327 to the inferior, unless the last process exited, in which case,
17328 exit gdbserver. Adjust interface.
17329
17330 * remote-utils.c (remote_open): Don't block in accept. Instead
17331 register an event loop source on the listen socket file
17332 descriptor. Refactor bits into ...
17333 (listen_desc): ... this new global.
17334 (gdb_connected): ... this new function.
17335 (enable_async_notification): ... this new function.
17336 (handle_accept_event): ... this new function.
17337 (remote_close): Clear remote_desc.
17338
17339 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17340
17341 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17342 New fields.
17343 (mourn_inferior): Define.
17344 (target_process_qsupported): Avoid the dangling else problem.
17345 (thread_stopped): Define.
17346 (pause_all): Define.
17347 (target_waitstatus_to_string): Declare.
17348 * target.c (target_waitstatus_to_string): New.
17349
17350 * tracepoint.c (tracing): Make extern.
17351 (disconnected_tracing): New.
17352 (stop_tracing): Make extern. Handle tracing stops due to GDB
17353 disconnecting.
17354 (cmd_qtdisconnected): New.
17355 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17356 (handle_tracepoint_general_set): Handle QTDisconnected.
17357
17358 * event-loop.c (event_handler_func): Change return type to int.
17359 (process_event): Bail out if the event handler wants the event
17360 loop to stop.
17361 (handle_file_event): Ditto.
17362 (start_event_loop): Bail out if the event handler wants the event
17363 loop to stop.
17364
17365 * nto-low.c (nto_target_ops): Adjust.
17366 * spu-low.c (spu_wait): Don't remove the process here.
17367 (spu_target_ops): Adjust.
17368 * win32-low.c (win32_wait): Don't remove the process here.
17369 (win32_target_ops): Adjust.
17370
5d267c4c
PA
173712010-04-11 Pedro Alves <pedro@codesourcery.com>
17372
17373 * regcache.c (realloc_register_cache): Invalidate inferior's
17374 regcache before recreating it.
17375
623ccd72
PA
173762010-04-09 Pedro Alves <pedro@codesourcery.com>
17377
17378 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17379
219f2f23
PA
173802010-04-09 Stan Shebs <stan@codesourcery.com>
17381 Pedro Alves <pedro@codesourcery.com>
17382
17383 * server.h (LONGEST): New.
17384 (struct thread_info) <while_stepping>: New field.
17385 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17386 Declare.
17387 (initialize_tracepoint, handle_tracepoint_general_set)
17388 (handle_tracepoint_query, tracepoint_finished_step)
17389 (tracepoint_was_hit, release_while_stepping_state_list):
17390 (current_traceframe): Declare.
17391 * server.c (handle_general_set): Handle tracepoint packets.
17392 (read_memory): New.
17393 (write_memory): New.
17394 (handle_search_memory_1): Use read_memory.
17395 (handle_query): Report support for conditional tracepoints, trace
17396 state variables, and tracepoint sources. Handle tracepoint
17397 queries.
17398 (main): Initialize the tracepoints module.
17399 (process_serial_event): Handle traceframe reads/writes.
17400
17401 * linux-low.c (handle_tracepoints): New.
17402 (linux_wait_1): Call it.
17403 (linux_resume_one_lwp): Handle while-stepping.
17404 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17405 (linux_target_ops): Install them.
17406 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17407 New field.
17408 * linux-x86-low.c (x86_supports_tracepoints): New.
17409 (the_low_target). Install it.
17410
17411 * mem-break.h (delete_breakpoint): Declare.
17412 * mem-break.c (delete_breakpoint): Make external.
17413
17414 * target.h (struct target_ops): Add `supports_tracepoints',
17415 `read_pc', and `write_pc' fields.
17416 (target_supports_tracepoints): Define.
17417 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17418 (phex_nz): New.
17419
17420 * regcache.h (struct regcache) <registers_owned>: New field.
17421 (init_register_cache, regcache_cpy): Declare.
17422 (regcache_read_pc, regcache_write_pc): Declare.
17423 (register_cache_size): Declare.
17424 (supply_regblock): Declare.
17425 * regcache.c (init_register_cache): New.
17426 (new_register_cache): Use it.
17427 (regcache_cpy): New.
17428 (register_cache_size): New.
17429 (supply_regblock): New.
17430 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 17431
219f2f23
PA
17432 * tracepoint.c: New.
17433
17434 * Makefile.in (OBS): Add tracepoint.o.
17435 (tracepoint.o): New rule.
17436
3a13a53b
L
174372010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17438
17439 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17440 (i386-mmx.o): New.
17441 (i386-mmx.c): Likewise.
17442 (i386-mmx-linux.o): Likewise.
17443 (i386-mmx-linux.c): Likewise.
17444
17445 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17446 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17447 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17448 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17449
17450 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17451 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17452 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17453
1570b33e
L
174542010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17455
17456 * Makefile.in (clean): Updated.
17457 (i386-avx.o): New.
17458 (i386-avx.c): Likewise.
17459 (i386-avx-linux.o): Likewise.
17460 (i386-avx-linux.c): Likewise.
17461 (amd64-avx.o): Likewise.
17462 (amd64-avx.c): Likewise.
17463 (amd64-avx-linux.o): Likewise.
17464 (amd64-avx-linux.c): Likewise.
17465
17466 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17467 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17468 (srv_amd64_regobj): Add amd64-avx.o.
17469 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17470 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17471 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17472 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17473 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17474 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17475 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17476
17477 * i387-fp.c: Include "i386-xstate.h".
17478 (i387_xsave): New.
17479 (i387_cache_to_xsave): Likewise.
17480 (i387_xsave_to_cache): Likewise.
17481 (x86_xcr0): Likewise.
17482
17483 * i387-fp.h (i387_cache_to_xsave): Likewise.
17484 (i387_xsave_to_cache): Likewise.
17485 (x86_xcr0): Likewise.
17486
17487 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17488 * linux-crisv32-low.c (target_regsets): Likewise.
17489 * linux-m68k-low.c (target_regsets): Likewise.
17490 * linux-mips-low.c (target_regsets): Likewise.
17491 * linux-ppc-low.c (target_regsets): Likewise.
17492 * linux-s390-low.c (target_regsets): Likewise.
17493 * linux-sh-low.c (target_regsets): Likewise.
17494 * linux-sparc-low.c (target_regsets): Likewise.
17495 * linux-xtensa-low.c (target_regsets): Likewise.
17496
17497 * linux-low.c: Include <sys/uio.h>.
17498 (regsets_fetch_inferior_registers): Support nt_type.
17499 (regsets_store_inferior_registers): Likewise.
17500 (linux_process_qsupported): New.
17501 (linux_target_ops): Add linux_process_qsupported.
17502
17503 * linux-low.h (regset_info): Add nt_type.
17504 (linux_target_ops): Add process_qsupported.
17505
17506 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17507 and <sys/uio.h>.
17508 (init_registers_i386_avx_linux): New.
17509 (init_registers_amd64_avx_linux): Likewise.
17510 (xmltarget_i386_linux_no_xml): Likewise.
17511 (xmltarget_amd64_linux_no_xml): Likewise.
17512 (PTRACE_GETREGSET): Likewise.
17513 (PTRACE_SETREGSET): Likewise.
17514 (x86_fill_xstateregset): Likewise.
17515 (x86_store_xstateregset): Likewise.
17516 (use_xml): Likewise.
17517 (x86_linux_update_xmltarget): Likewise.
17518 (x86_linux_process_qsupported): Likewise.
17519 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17520 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17521 init_registers_i386_linux here. Call
17522 x86_linux_update_xmltarget.
17523 (the_low_target): Add x86_linux_process_qsupported.
17524
17525 * server.c (handle_query): Call target_process_qsupported.
17526
17527 * target.h (target_ops): Add process_qsupported.
17528 (target_process_qsupported): New.
17529
fc7238bb
PA
175302010-04-03 Pedro Alves <pedro@codesourcery.com>
17531
17532 * inferiors.c (add_thread): Set last_status kind to
17533 TARGET_WAITKIND_IGNORE.
17534 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17535 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17536 (linux_wait_1): Move `thread' local definition to block that uses
17537 it. Don't NULL initialize `event_child'.
17538 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17539 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17540 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17541
bdabb078
PA
175422010-04-01 Pedro Alves <pedro@codesourcery.com>
17543
17544 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17545 an extended waitstatus, or by a watchpoint.
17546 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17547 thread was stepping or has been stopped by a watchpoint.
17548
d3bbe7a0
PA
175492010-04-01 Pedro Alves <pedro@codesourcery.com>
17550
17551 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17552 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17553 of another, then delete the previous, and validate all
17554 breakpoints.
17555 (validate_inserted_breakpoint): New.
17556 (delete_disabled_breakpoints): New.
17557 (validate_breakpoints): New.
17558 (check_mem_read): Validate breakpoints before trusting their
17559 shadow. Delete disabled breakpoints.
17560 (check_mem_write): Validate breakpoints before trusting they
17561 should be inserted. Delete disabled breakpoints.
17562 * mem-break.h (validate_breakpoints):
17563 * server.c (handle_query): Validate breakpoints when we see a
17564 qSymbol query.
17565
8b07ae33
PA
175662010-04-01 Pedro Alves <pedro@codesourcery.com>
17567
17568 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17569 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17570 if we could tell there's a GDB breakpoint at stop_pc.
17571 (need_step_over_p): Don't do a step over if we find a GDB
17572 breakpoint at the resume PC.
17573
17574 * mem-break.c (struct raw_breakpoint): New.
17575 (enum bkpt_type): New type `gdb_breakpoint'.
17576 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17577 fields. New field `raw'.
17578 (find_raw_breakpoint_at): New.
17579 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17580 breakpoint instead.
17581 (set_breakpoint_at): Adjust.
17582 (delete_raw_breakpoint): New.
17583 (release_breakpoint): New.
17584 (delete_breakpoint): Rename to...
17585 (delete_breakpoint_1): ... this. Add proc parameter. Use
17586 release_breakpoint. Return ENOENT.
17587 (delete_breakpoint): Reimplement.
17588 (find_breakpoint_at): Delete.
17589 (find_gdb_breakpoint_at): New.
17590 (delete_breakpoint_at): Delete.
17591 (set_gdb_breakpoint_at): New.
17592 (delete_gdb_breakpoint_at): New.
17593 (gdb_breakpoint_here): New.
17594 (set_reinsert_breakpoint): Use release_breakpoint.
17595 (uninsert_breakpoint): Rename to ...
17596 (uninsert_raw_breakpoint): ... this.
17597 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17598 (reinsert_raw_breakpoint): Change parameter type to
17599 raw_breakpoint.
17600 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17601 instead.
17602 (check_breakpoints): Adjust. Use release_breakpoint.
17603 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17604 (breakpoint_inserted_here): Ditto.
17605 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17606 Don't trust the breakpoint's shadow if it is not inserted.
17607 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17608 (delete_all_breakpoints): Adjust.
17609 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17610 use delete_breakpoint_1.
17611
17612 * mem-break.h (breakpoints_supported): Delete declaration.
17613 (set_gdb_breakpoint_at): Declare.
17614 (gdb_breakpoint_here): Declare.
17615 (delete_breakpoint_at): Delete.
17616 (delete_gdb_breakpoint_at): Declare.
17617
17618 * server.h (struct raw_breakpoint): Forward declare.
17619 (struct process_info): New field `raw_breakpoints'.
17620
17621 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17622 breakpoints.
17623
6bf5e0ba
PA
176242010-03-24 Pedro Alves <pedro@codesourcery.com>
17625
17626 * linux-low.c (status_pending_p_callback): Fix comment.
17627 (linux_wait_for_event_1): Move most of the internal breakpoint
17628 handling from here...
17629 (linux_wait_1): ... to here.
17630 (count_events_callback): New.
17631 (select_singlestep_lwp_callback): New.
17632 (select_event_lwp_callback): New.
17633 (cancel_breakpoints_callback): New.
17634 (select_event_lwp): New.
17635 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17636 priority to all LWPs that have had events that should be reported
17637 to the client. Cancel breakpoints when about to reporting the
17638 event to the client, not while stopping lwps. No longer cancel
17639 finished single-steps here.
17640 (cancel_finished_single_step): Delete.
17641 (cancel_finished_single_steps): Delete.
17642
414a389f
PA
176432010-03-24 Pedro Alves <pedro@codesourcery.com>
17644
17645 * mem-break.c (enum bkpt_type): New.
17646 (struct breakpoint): New field `type'.
17647 (set_breakpoint_at): Change return type to struct breakpoint
17648 pointer. Set type to `other_breakpoint' by default.
17649 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17650 in the breakpoint list.
17651 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17652 (reinsert_breakpoint): Rename to ...
17653 (reinsert_raw_breakpoint): ... this.
17654 (reinsert_breakpoints_at): Adjust.
17655 * mem-break.h (struct breakpoint): Declare.
17656 (set_breakpoint_at): Change return type to struct breakpoint
17657 pointer.
17658
2280c721
PA
176592010-03-24 Pedro Alves <pedro@codesourcery.com>
17660
17661 * server.c (handle_query): Assign, not compare.
17662
d50171e4
PA
176632010-03-24 Pedro Alves <pedro@codesourcery.com>
17664
17665 Teach linux gdbserver to step-over-breakpoints.
17666
17667 * linux-low.c (can_hardware_single_step): New.
17668 (supports_breakpoints): New.
17669 (handle_extended_wait): If stopping threads, read the stop pc of
17670 the new cloned LWP.
17671 (get_pc): New.
17672 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17673 low target doesn't support retrieving the PC.
17674 (add_lwp): Set last_resume_kind to resume_continue.
17675 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17676 (linux_attach): Don't clear stop_expected. Set the lwp's
17677 last_resume_kind to resume_stop.
17678 (linux_detach_one_lwp): Don't check for removed breakpoints.
17679 (check_removed_breakpoint): Delete.
17680 (status_pending_p): Rename to ...
17681 (status_pending_p_callback): ... this. Don't check for removed
17682 breakpoints. Don't consider threads that are stopped from GDB's
17683 perspective.
17684 (linux_wait_for_lwp): Always read the stop_pc here.
17685 (cancel_breakpoint): New.
17686 (step_over_bkpt): New global.
17687 (linux_wait_for_event_1): Implement stepping over breakpoints.
17688 (gdb_wants_lwp_stopped): New.
17689 (gdb_wants_all_stopped): New.
17690 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17691 single-step traps here. Store the thread's last reported target
17692 wait status.
17693 (send_sigstop): Don't clear stop_expected. Always set it,
17694 instead.
17695 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17696 (cancel_finished_single_step): New.
17697 (cancel_finished_single_steps): New.
17698 (wait_for_sigstop): Don't cancel finished single-step traps here.
17699 (linux_resume_one_lwp): Don't check for removed breakpoints.
17700 Don't set `step' on non-hardware step archs.
17701 (linux_set_resume_request): Ignore resume_stop requests if already
17702 stopping or stopped. Set the lwp's last_resume_kind.
17703 (resume_status_pending_p): Don't check for removed breakpoints.
17704 (need_step_over_p): New.
17705 (start_step_over): New.
17706 (finish_step_over): New.
17707 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17708 requests. Clear the thread's last reported target waitstatus.
17709 Don't use the `suspended' flag. Don't consider pending breakpoints.
17710 (linux_resume): Start a step-over if necessary.
17711 (proceed_one_lwp): New.
17712 (proceed_all_lwps): New.
17713 (unstop_all_lwps): New.
17714 * linux-low.h (struct lwp_info): Rewrite comment for the
17715 `suspended' flag. Add the `stop_pc' field. Delete the
17716 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17717 Add `'last_resume_kind' and `need_step_over' fields.
17718 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17719 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17720 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17721 (set_raw_breakpoint_at): New.
17722 (set_breakpoint_at): Rewrite to use it.
17723 (reinsert_breakpoint_handler): Delete.
17724 (set_reinsert_breakpoint): New.
17725 (reinsert_breakpoint_by_bp): Delete.
17726 (delete_reinsert_breakpoints): New.
17727 (uninsert_breakpoint): Rewrite.
17728 (uninsert_breakpoints_at): New.
17729 (reinsert_breakpoint): Rewrite.
17730 (reinsert_breakpoints_at): New.
17731 (check_breakpoints): Rewrite.
17732 (breakpoint_here): New.
17733 (breakpoint_inserted_here): New.
17734 (check_mem_read): Adjust.
17735 * mem-break.h (breakpoints_supported, breakpoint_here)
17736 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
17737 (reinsert_breakpoint_by_bp): Delete declaration.
17738 (delete_reinsert_breakpoints): Declare.
17739 (reinsert_breakpoint): Delete declaration.
17740 (reinsert_breakpoints_at): Declare.
17741 (uninsert_breakpoint): Delete declaration.
17742 (uninsert_breakpoints_at): Declare.
17743 (check_breakpoints): Adjust prototype.
17744 * server.h: Adjust include order.
17745 (struct thread_info): Declare here. Add a `last_status' field.
17746
30ba68cb
MS
177472010-03-23 Michael Snyder <msnyder@vmware.com>
17748
17749 * server.c (crc32): New function.
17750 (handle_query): Add handling for 'qCRC:' request.
17751
b9a881c2
PA
177522010-03-23 Pedro Alves <pedro@codesourcery.com>
17753
17754 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
17755 lwp had been stopped by a watchpoint.
17756
e92d13d5
PA
177572010-03-16 Pedro Alves <pedro@codesourcery.com>
17758
17759 * server.h (internal_error): Declare.
17760 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
17761 * utils.c (internal_error): New function.
17762
64daa791
AS
177632010-03-15 Andreas Schwab <schwab@redhat.com>
17764
17765 * configure.srv: Fix typo setting srv_regobj.
17766
f52cd8cd
PA
177672010-03-15 Pedro Alves <pedro@codesourcery.com>
17768
17769 * linux-low.c (fetch_register): Avoid passing a non string literal
17770 format to `error'.
17771 (usr_store_inferior_registers): Ditto.
17772
93ae6fdc
PA
177732010-03-14 Pedro Alves <pedro@codesourcery.com>
17774
17775 * linux-low.c (linux_write_memory): Bail out early if peeking
17776 memory failed.
17777
c3adc08c
PA
177782010-03-14 Pedro Alves <pedro@codesourcery.com>
17779
17780 * linux-low.h (struct lwp_info): New fields
17781 `stopped_by_watchpoint' and `stopped_data_address'.
17782 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
17783 here, and cache them in the lwp object.
17784 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
17785 directly.
17786 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
17787 field.
17788 (linux_stopped_by_watchpoint): Rewrite.
17789 (linux_stopped_data_address): Rewrite.
17790
bce522a2
PA
177912010-03-06 Simo Melenius <simo.melenius@iki.fi>
17792
17793 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
17794 switching the current inferior, not before.
17795
90884b2b
L
177962010-03-01 H.J. Lu <hongjiu.lu@intel.com>
17797
17798 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
17799 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
17800 i386-linux.c and amd64-linux.c.
17801 (reg-i386.o): Removed.
17802 (reg-i386.c): Likewise.
17803 (reg-i386-linux.o): Likewise.
17804 (reg-i386-linux.c): Likewise.
17805 (reg-x86-64.o): Likewise.
17806 (reg-x86-64.c): Likewise.
17807 (reg-x86-64-linux.o): Likewise.
17808 (reg-x86-64-linux.c): Likewise.
17809 (i386.o): New.
17810 (i386.c): Likewise.
17811 (i386-linux.o): Likewise.
17812 (i386-linux.c): Likewise.
17813 (amd64.o): Likewise.
17814 (amd64.c): Likewise.
17815 (amd64-linux.o): Likewise.
17816 (amd64-linux.c): Likewise.
17817
17818 * configure.srv (srv_i386_regobj): New.
17819 (srv_i386_linux_regobj): Likewise.
17820 (srv_amd64_regobj): Likewise.
17821 (srv_amd64_linux_regobj): Likewise.
17822 (srv_i386_32bit_xmlfiles): Likewise.
17823 (srv_i386_64bit_xmlfiles): Likewise.
17824 (srv_i386_xmlfiles): Likewise.
17825 (srv_amd64_xmlfiles): Likewise.
17826 (srv_i386_linux_xmlfiles): Likewise.
17827 (srv_amd64_linux_xmlfiles): Likewise.
17828 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
17829 srv_xmlfiles to $srv_i386_xmlfiles.
17830 (i[34567]86-*-mingw32ce*): Likewise.
17831 (i[34567]86-*-mingw*): Likewise.
17832 (i[34567]86-*-nto*): Likewise.
17833 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
17834 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
17835 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
17836 (x86_64-*-linux*): Likewise.
17837
17838 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
17839 (init_registers_amd64_linux): New.
17840 (x86_arch_setup): Replace init_registers_x86_64_linux with
17841 init_registers_amd64_linux.
17842
193f13e6
MK
178432010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
17844
17845 * configure.ac: Check for libdl. If it is not available link against
17846 static libthread_db.
17847 * configure: Regenerate.
17848
85d721b8
PA
178492010-02-22 Pedro Alves <pedro@codesourcery.com>
17850
17851 PR9605
17852
17853 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
17854 handing a read watchpoint.
17855 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
17856
6076632b
DE
178572010-02-12 Doug Evans <dje@google.com>
17858
17859 * linux-low.c (linux_supports_tracefork_flag): Document.
17860 (linux_look_up_symbols): Add comment.
17861
3327ccf7
L
178622010-02-03 H.J. Lu <hongjiu.lu@intel.com>
17863
17864 * regcache.c (supply_register): Clear regcache if buf is NULL.
17865
0718675c 178662010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 17867 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
17868
17869 * inferiors.c (find_inferior): Add function documentation.
17870 (unloaded_dll): Handle the case where the unloaded dll has not
17871 been previously registered in the dll list.
17872
177321bd
DJ
178732010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
17874
17875 * linux-arm-low.c (thumb_breakpoint_len): Delete.
17876 (thumb2_breakpoint): New.
17877 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
17878
2b009048
DJ
178792010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17880
17881 * linux-low.c (get_stop_pc): Check for SIGTRAP.
17882 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
17883 breakpoints.
17884
3be029c7
PA
178852010-01-21 Pedro Alves <pedro@codesourcery.com>
17886
17887 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
17888
18f5de3b
JK
178892010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
17890
17891 * linux-s390-low.c (s390_collect_ptrace_register)
17892 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
17893
3743bb4f
DE
178942010-01-21 Doug Evans <dje@google.com>
17895
14ce3065
DE
17896 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
17897 (PTRACE_ARG4_TYPE): New macro.
17898 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
17899 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
17900 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
17901 (usr_store_inferior_registers): Ditto.
17902 (linux_read_memory, linux_write_memory): Ditto.
17903 (linux_test_for_tracefork): Ditto.
17904
3743bb4f
DE
17905 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
17906 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
17907
8b315be5
PA
179082010-01-21 Pedro Alves <pedro@codesourcery.com>
17909
17910 * proc-service.c (ps_lgetregs): Don't refetch registers from the
17911 target.
17912
85492558
PA
179132010-01-21 Pedro Alves <pedro@codesourcery.com>
17914
17915 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
17916 prototype to take a regcache. Adjust.
17917
442ea881
PA
179182010-01-20 Pedro Alves <pedro@codesourcery.com>
17919
17920 * regcache.h (struct thread_info): Forward declare.
17921 (struct regcache): New.
17922 (new_register_cache): Adjust prototype.
17923 (get_thread_regcache): Declare.
17924 (free_register_cache): Adjust prototype.
17925 (registers_to_string, registers_from_string): Ditto.
17926 (supply_register, supply_register_by_name, collect_register)
17927 (collect_register_as_string, collect_register_by_name): Ditto.
17928 * regcache.c (struct inferior_regcache_data): Delete.
17929 (get_regcache): Rename to ...
17930 (get_thread_regcache): ... this. Adjust. Switch inferior before
17931 fetching registers.
17932 (regcache_invalidate_one): Adjust.
17933 (regcache_invalidate): Fix prototype.
17934 (new_register_cache): Return the new register cache.
17935 (free_register_cache): Change prototype.
17936 (realloc_register_cache): Adjust.
17937 (registers_to_string): Change prototype to take a regcache. Adjust.
17938 (registers_from_string): Ditto.
17939 (register_data): Ditto.
17940 (supply_register): Ditto.
17941 (supply_register_by_name): Ditto.
17942 (collect_register): Ditto.
17943 (collect_register_as_string): Ditto.
17944 (collect_register_by_name): Ditto.
17945 * server.c (process_serial_event): Adjust.
17946 * linux-low.h (regset_fill_func, regset_store_func): Change
17947 prototype.
17948 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
17949 Change prototype.
17950 * linux-low.c (get_stop_pc): Adjust.
17951 (check_removed_breakpoint): Adjust.
17952 (linux_wait_for_event): Adjust.
17953 (linux_resume_one_lwp): Adjust.
17954 (fetch_register): Add regcache parameter. Adjust.
17955 (usr_store_inferior_registers): Ditto.
17956 (regsets_fetch_inferior_registers): Ditto.
17957 (regsets_store_inferior_registers): Ditto.
17958 (linux_fetch_registers, linux_store_registers): Ditto.
17959 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
17960 regcache. Adjust.
43aaf8b6
PA
17961 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
17962 Ditto.
442ea881
PA
17963 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
17964 prototype to take a regcache.
17965 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
17966 * remote-utils.c (convert_ascii_to_int, outreg)
17967 (prepare_resume_reply): Change prototype to take a regcache.
17968 Adjust.
17969 * target.h (struct target_ops) <fetch_registers, store_registers>:
17970 Change prototype to take a regcache.
17971 (fetch_inferior_registers, store_inferior_registers): Change
17972 prototype to take a regcache. Adjust.
17973 * proc-service.c (ps_lgetregs): Adjust.
17974 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
17975 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
17976 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
17977 take a regcache. Adjust.
17978 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
17979 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
17980 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
17981 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
17982 * linux-cris-low.c (cris_get_pc, cris_set_pc)
17983 (cris_cannot_fetch_register):
17984 (cris_breakpoint_at): Change prototype to take a regcache.
17985 Adjust.
17986 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
17987 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
17988 to take a regcache. Adjust.
17989 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
17990 Adjust.
17991 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
17992 take a regcache. Adjust.
17993 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
17994 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
17995 (m68k_set_pc): Change prototype to take a regcache. Adjust.
17996 * linux-mips-low.c (mips_get_pc):
17997 (mips_set_pc): Change prototype to take a regcache. Adjust.
17998 (mips_reinsert_addr): Adjust.
17999 (mips_collect_register): Change prototype to take a regcache.
18000 Adjust.
18001 (mips_supply_register):
18002 (mips_collect_register_32bit, mips_supply_register_32bit)
18003 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18004 (mips_store_fpregset): Ditto.
43aaf8b6
PA
18005 * linux-ppc-low.c (ppc_supply_ptrace_register)
18006 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
18007 (parse_spufs_run): Adjust.
18008 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18009 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18010 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18011 take a regcache. Adjust.
18012 * linux-s390-low.c (s390_collect_ptrace_register)
18013 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18014 (s390_set_pc): Change prototype to take a regcache. Adjust.
18015 (s390_arch_setup): Adjust.
18016 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18017 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18018 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18019 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18020 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18021 regcache. Adjust.
18022 (sparc_breakpoint_at): Adjust.
18023 * linux-xtensa-low.c (xtensa_fill_gregset):
18024 (xtensa_store_gregset):
18025 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18026 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18027 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18028 prototype to take a regcache. Adjust.
18029 * win32-arm-low.c (arm_fetch_inferior_register)
18030 (arm_store_inferior_register): Change prototype to take a
18031 regcache. Adjust.
18032 * win32-i386-low.c (i386_fetch_inferior_register)
18033 (i386_store_inferior_register): Change prototype to take a
18034 regcache. Adjust.
18035 * win32-low.c (child_fetch_inferior_registers)
18036 (child_store_inferior_registers): Change prototype to take a
18037 regcache. Adjust.
18038 (win32_wait): Adjust.
18039 (win32_fetch_inferior_registers): Change prototype to take a
18040 regcache. Adjust.
18041 (win32_store_inferior_registers): Adjust.
18042 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18043 store_inferior_register>: Change prototype to take a regcache.
18044
60c3d7b0
DE
180452010-01-20 Doug Evans <dje@google.com>
18046
18047 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18048 #ifdef.
18049 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 18050 (W_STOPCODE): Provide definition if missing.
60c3d7b0 18051
dc146f7c
VP
180522010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18053
18054 * linux-low.c (linux_core_of_thread): New.
18055 (compare_ints, show_process, list_threads): New.
18056 (linux_qxfer_osdata): Report threads and cores.
18057 (linux_target_op): Register linux_core_of_thread.
18058 * remote-utils.c (prepare_resume_reply): Report the core.
18059 (buffer_xml_printf): Support %d specifier.
18060 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18061 New.
18062 (handle_query): Handle qXfer:threads. Announce availability
18063 thereof.
18064 * target.h (struct target_ops): New field core_of_thread.
18065
7803799a
UW
180662010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18067
18068 * Makefile.in (clean): Remove new generated files.
18069 (reg-s390.o, reg-s390.c): Remove rules.
18070 (reg-s390x.o, reg-s390x.c): Likewise.
18071 (s390-linux32.o, s390-linux32.c): Add rules.
18072 (s390-linux64.o, s390-linux64.c): Likewise.
18073 (s390x-linux64.o, s390x-linux64.c): Likewise.
18074 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18075 * linux-s390-low.c: Include <elf.h>.
18076 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18077 (init_registers_s390): Remove prototype.
18078 (init_registers_s390x): Likewise.
18079 (init_registers_s390_linux32): Add prototype.
18080 (init_registers_s390_linux64): Likewise.
18081 (init_registers_s390x_linux64): Likewise.
18082 (s390_num_regs_3264): New define.
18083 (s390_regmap_3264): New global variable.
18084 (s390_cannot_fetch_register): Remove obsolete check.
18085 (s390_cannot_store_register): Likewise.
18086 (s390_collect_ptrace_register): Handle upper/lower register halves.
18087 (s390_supply_ptrace_register): Likewise.
18088 (s390_fill_gregset): Update to register number changes.
18089 (s390_get_hwcap): New routine.
18090 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18091 Install appropriate regmap and register set.
18092
6e7ffa39
JB
180932010-01-01 Joel Brobecker <brobecker@adacore.com>
18094
18095 * server.c (gdbserver_version): Update copyright year to 2010.
18096 * gdbreplay.c (gdbreplay_version): Likewise.
18097
957f3f49
DE
180982009-12-28 Doug Evans <dje@google.com>
18099
18100 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18101 elf/external.h. Include <elf.h> instead but only if necessary.
18102
ca5c370d
PA
181032009-12-28 Pedro Alves <pedro@codesourcery.com>
18104
18105 * linux-low.c (linux_remove_process): Remove `detaching'
18106 parameter. Don't release/detach from thread_db here.
18107 (linux_kill): Release/detach from thread_db here, ...
18108 (linux_detach): ... and here, before actually detaching.
18109 (linux_wait_1): ... and here, when a process exits.
18110 * thread-db.c (any_thread_of): New.
18111 (thread_db_free): Switch the current inferior to a thread of the
18112 passed in process.
18113
4ee62156
DE
181142009-12-21 Doug Evans <dje@google.com>
18115
d90e6a88
DE
18116 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18117
c5f62d5f
DE
18118 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18119 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18120 warning ifndef __NR_tkill. Move setting of errno there too.
18121 Delete unnecessary resetting of errno after syscall.
18122 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18123
10e86dd7
DE
18124 * configure.ac: Check for dladdr.
18125 * config.in: Regenerate.
18126 * configure: Regenerate.
18127 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18128 (try_thread_db_load): Update.
18129
4ee62156
DE
18130 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18131
00f515da
DE
181322009-12-18 Doug Evans <dje@google.com>
18133
e9464885
DE
18134 * event-loop.c: Include unistd.h if it exists.
18135
07d4f67e
DE
18136 * linux-low.c (my_waitpid): Move definition away from being in
18137 between linux_tracefork_child/linux_test_for_tracefork.
18138
00f515da
DE
18139 * gdb_proc_service.h (psaddr_t): Fix type.
18140 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18141 signature to match glibc.
18142
1de1badb
DE
181432009-12-16 Doug Evans <dje@google.com>
18144
18145 * linux-low.c (linux_read_memory): Fix argument to read.
18146
aeeb81d1
PA
181472009-11-26 Pedro Alves <pedro@codesourcery.com>
18148
18149 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18150 events, don't leave current_inferior pointing at null.
18151
10357975
PA
181522009-11-26 Pedro Alves <pedro@codesourcery.com>
18153
18154 * win32-low.c (LOG): Delete.
18155 (OUTMSG): Output to stderr.
18156 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18157 on compile time LOG macro.
18158 (win32_wait): Fix debug output.
18159
cf6e3471
PA
181602009-11-26 Pedro Alves <pedro@codesourcery.com>
18161
18162 * win32-low.c (win32_add_one_solib): If the dll name is
18163 "ntdll.dll", prepend the system directory to the dll path.
18164
0c85e18e
MK
181652009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18166
18167 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18168
9ac544ce 181692009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 18170 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
18171
18172 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18173 * configure.ac: Check for __mcoldfire__ and set
18174 gdb_cv_m68k_is_coldfire.
18175 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18176 reg-cf.o and reg-m68k.o.
18177 * configure: Regenerated.
18178
fd7dd3e6
PA
181792009-11-16 Pedro Alves <pedro@codesourcery.com>
18180
18181 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18182 Pass it to thread_db_free.
18183 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18184 proper `detaching' argument to linux_remove_process.
18185 * linux-low.h (thread_db_free): Add `detaching' parameter.
18186 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18187 to thread_db_free.
18188 (thread_db_free): Add `detaching' parameter. Only
18189 call td_ta_clear_event if detaching from process.
18190
75aa492e
MK
181912009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18192
18193 * thread-db.c (thread_db_free): Fix typo.
18194
21e1bee4
PP
181952009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18196
18197 PR gdb/10838
18198 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18199
8838b45e
NS
182002009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18201
18202 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18203 with an i686 compiler.
18204 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18205 needed.
18206 * configure: Rebuilt.
18207
8a35fb51
SL
182082009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18209
18210 PR gdb/10783
18211
18212 * server.c (handle_search_memory_1): Correct read_addr initialization
18213 in loop for searching subsequent chunks.
18214
96f15937
PP
182152009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18216
18217 * configure.ac: New --with-libthread-db option.
18218 * thread-db.c: Allow direct dependence on libthread_db.
18219 (thread_db_free): Adjust.
18220 * config.in: Regenerate.
18221 * configure: Likewise.
889bf7c5 18222
5f7d1694
PP
182232009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18224
18225 PR gdb/10757
18226 * thread-db.c (attach_thread): New function.
18227 (maybe_attach_thread): Return success/failure.
18228 (find_new_threads_callback): Adjust.
889bf7c5
PA
18229 (thread_db_find_new_threads): Loop until no new threads.
18230
88e3b899
PA
182312009-10-13 Pedro Alves <pedro@codesourcery.com>
18232
18233 * proc-service.c (ps_lgetregs): Formatting.
18234
cdbfd419
PP
182352009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18236
18237 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18238 * configure.ac: Adjust.
18239 * linux-low.h (struct process_info_private): Move members to struct
18240 thread_db.
18241 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18242 * linux-low.c (linux_remove_process): Adjust.
18243 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18244 * server.c (handle_query): Move code ...
18245 (handle_monitor_command): ... here. New function.
18246 * target.h (struct target_ops): New member.
18247 * thread-db.c (struct thread_db): New.
18248 (libthread_db_search_path): New variable.
18249 (thread_db_create_event, thread_db_enable_reporting)
18250 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18251 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18252 (try_thread_db_load_1, dladdr_to_soname): New functions.
18253 (try_thread_db_load, thread_db_load_search): New functions.
18254 (thread_db_init): Search for libthread_db.
18255 (thread_db_free): New function.
18256 (thread_db_handle_monitor_command): Likewise.
18257 * config.in: Regenerate.
18258 * configure: Regenerate.
889bf7c5 18259
4168d2d6
UW
182602009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18261
18262 * spu-low.c (spu_kill): Wait for inferior to terminate.
18263 Call clear_inferiors.
18264 (spu_detach): Call clear_inferiors.
18265
81ecdfbb
RW
182662009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18267
18268 * aclocal.m4: Regenerate.
18269 * config.in: Likewise.
18270 * configure: Likewise.
18271
0b9ff2c0
UW
182722009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18273
18274 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18275 (parse_spufs_run): New function.
18276 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18277 (ppc_breakpoint_at): Handle SPU breakpoints.
18278
efcbbd14
UW
182792009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18280
18281 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18282 (SPUFS_MAGIC): Define.
18283 (spu_enumerate_spu_ids): New function.
18284 (linux_qxfer_spu): New function.
18285 (linux_target_ops): Install linux_qxfer_spu.
18286
f4d9bade
UW
182872009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18288
18289 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18290 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18291 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18292 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18293 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18294 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18295 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18296 (init_registers_powerpc_cell32l): Add prototype.
18297 (init_registers_powerpc_cell64l): Likewise.
18298 (ppc_arch_setup): Detect Cell/B.E. architecture.
18299
96e946ca
RW
183002009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18301
18302 * Makefile.in (datarootdir): New variable.
18303
58d6951d
DJ
183042009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18305
18306 * linux-low.c (linux_write_memory): Update debugging output.
18307 * Makefile.in (clean): Add new descriptions.
18308 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18309 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18310 * configure.srv: Add new files for arm*-*-linux*.
18311 * linux-arm-low.c: Add new declarations.
18312 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18313 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18314 (HWCAP_VFPv3D16): New.
18315 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18316 instead of __IWMMXT__.
18317 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18318 (arm_arch_setup): New.
18319 (target_regsets): Remove #ifdef. Add VFP regset.
18320 (the_low_target): Use arm_arch_setup.
18321
12b42a12
DJ
183222009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18323
18324 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18325 the main thread again.
18326
ac8c974e
AR
183272009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18328
18329 Adding Neutrino gdbserver.
18330 * configure: Regenerated.
18331 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18332 * configure.srv (i[34567]86-*-nto*): New target.
18333 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18334 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18335 (nto_comctrl) [__QNX__]: New function.
18336 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18337
4424e0c3 183382009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
18339
18340 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18341 srv_tgtobj.
18342
912cf4ba
PA
183432009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18344 Pedro Alves <pedro@codesourcery.com>
18345
18346 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18347 don't support CONTEXT_EXTENDED_REGISTERS.
18348 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18349 (the_low_target): Install them.
18350 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18351 failing with ERROR_PIPE_NOT_CONNECTED.
18352
aa5ca48f
DE
183532009-06-30 Doug Evans <dje@google.com>
18354 Pierre Muller <muller@ics.u-strasbg.fr>
18355
18356 Add h/w watchpoint support to x86-linux, win32-i386.
18357 * Makefile.in (SFILES): Add i386-low.c
18358 (i386_low_h): Define.
18359 (i386-low.o): Add dependencies.
18360 (linux-x86-low.o): Add i386-low.h dependency.
18361 (win32-i386-low.o): Ditto.
18362 * i386-low.c: New file.
18363 * i386-low.h: New file.
18364 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18365 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18366 * linux-low.c (linux_add_process): Initialize arch_private.
18367 (linux_remove_process): Free arch_private.
18368 (add_lwp): Initialize arch_private.
18369 (delete_lwp): Free arch_private.
18370 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18371 provided.
18372 * linux-low.h (process_info_private): New member arch_private.
18373 (lwp_info): New member arch_private.
18374 (linux_target_ops): New members new_process, new_thread,
18375 prepare_to_resume.
18376 (ptid_of): New macro.
18377 * linux-x86-low.c: Include stddef.h, i386-low.h.
18378 (arch_process_info): New struct.
18379 (arch_lwp_info): New struct.
18380 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18381 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18382 (i386_dr_low_get_status): New function.
18383 (x86_insert_point, x86_remove_point): New functions.
18384 (x86_stopped_by_watchpoint): New function.
18385 (x86_stopped_data_address): New function.
18386 (x86_linux_new_process, x86_linux_new_thread): New functions.
18387 (x86_linux_prepare_to_resume): New function.
18388 (the_low_target): Add entries for insert_point, remove_point,
18389 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18390 prepare_to_resume.
18391 * server.c (debug_hw_points): New global.
18392 (monitor_show_help): Document set debug-hw-points.
18393 (handle_query): Process "set debug-hw-points".
18394 * server.h (debug_hw_points): Declare.
18395 (paddress): Declare.
18396 * utils.c (NUMCELLS, CELLSIZE): New macros.
18397 (get_sell, xsnprintf, paddress): New functions.
18398 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18399 remove_point, stopped_by_watchpoint, stopped_data_address.
18400 * win32-i386-low.c: Include i386-low.h.
18401 (debug_reg_state): Replaces dr.
18402 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18403 (i386_dr_low_get_status): New function.
18404 (i386_insert_point, i386_remove_point): New functions.
18405 (i386_stopped_by_watchpoint): New function.
18406 (i386_stopped_data_address): New function.
18407 (i386_initial_stuff): Update.
18408 (get_thread_context,set_thread_context,i386_thread_added): Update.
18409 (the_low_target): Add entries for insert_point,
18410 remove_point, stopped_by_watchpoint, stopped_data_address.
18411 * win32-low.c (win32_insert_watchpoint): New function.
18412 (win32_remove_watchpoint): New function.
18413 (win32_stopped_by_watchpoint): New function.
18414 (win32_stopped_data_address): New function.
18415 (win32_target_ops): Add entries for insert_watchpoint,
18416 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18417 * win32-low.h (win32_target_ops): New members insert_point,
18418 remove_point, stopped_by_watchpoint, stopped_data_address.
18419
d993e290
PA
184202009-06-25 Pedro Alves <pedro@codesourcery.com>
18421
18422 * server.c (process_serial_event): Re-return unsupported, not
18423 error, if the type isn't recognized. Re-allow supporting only
18424 insert or remove packets. Also call require_running for
18425 breakpoints. Add missing break statement to default case. Tidy.
18426 * target.h (struct target_ops): Rename insert_watchpoint to
18427 insert_point, and remove_watchpoint to remove_point.
18428
18429 * linux-low.h (struct linux_target_ops): Likewise.
18430 * linux-low.c (linux_insert_watchpoint): Rename to ...
18431 (linux_insert_point): ... this. Adjust.
18432 (linux_remove_watchpoint): Rename to ...
18433 (linux_remove_point): ... this. Adjust.
18434 (linux_target_ops): Adjust.
18435 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18436 (cris_insert_point): ... this.
18437 (cris_remove_watchpoint): Rename to ...
18438 (cris_remove_point): ... this.
18439 (the_low_target): Adjust.
18440
0f54c268
PM
184412009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18442
18443 * server.c (handle_v_kill): Pass signal_pid to
18444 kill_inferior if multi_process is zero.
18445
c6314022
AR
184462009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18447
18448 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18449 * target.h (target_ops): Comment for *_watchpoint to make it clear
18450 the functions can get types '0' and '1'.
18451
4463ce24
AR
184522009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18453
18454 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18455 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18456 * regcache.c (get_regcache): Likewise.
18457 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18458 * win32-low.c (child_fetch_inferior_registers): Remove check for
18459 regno 0.
18460
cf8fd78b
PA
184612009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18462 Pedro Alves <pedro@codesourcery.com>
18463
18464 * target.h (struct target_ops) <supports_multi_process>: New
18465 callback.
18466 (target_supports_multi_process): New.
18467 * server.c (handle_query): Even if GDB reports support, only
18468 enable multi-process if the target also supports it. Report
18469 multi-process support only if the target backend supports it.
18470 * linux-low.c (linux_supports_multi_process): New function.
18471 (linux_target_ops): Install it as target_supports_multi_process
18472 callback.
18473
47c0c975
DE
184742009-05-24 Doug Evans <dje@google.com>
18475
e09875d4
DE
18476 Global renaming of find_thread_pid to find_thread_ptid.
18477 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18478 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18479 All callers updated.
18480
e27d73f6
DE
18481 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18482 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18483 directly.
18484
47c0c975
DE
18485 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18486 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18487 (linux_resume_one_lwp): Ditto.
18488
2acc282a
DE
184892009-05-23 Doug Evans <dje@google.com>
18490
18491 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18492 from struct inferior_list_entry * to struct lwp_info *.
18493 All callers updated.
18494
9f1036c1
DE
184952009-05-13 Doug Evans <dje@google.com>
18496
18497 * linux-x86-low.c: Don't include assert.h.
18498 (x86_siginfo_fixup): Use fatal, not assert.
18499 (x86_arch_setup): Fix comment.
18500
d0722149
DE
185012009-05-12 Doug Evans <dje@google.com>
18502
18503 Biarch support for i386/amd64 gdbserver.
18504 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18505 Add linux-x86-low.c.
18506 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18507 (linux-x86-low.o): Add.
18508 * linux-x86-64-low.c: Delete.
18509 * linux-i386-low.c: Delete.
18510 * linux-x86-low.c: New file.
18511 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18512 linux-x86-low.o.
18513 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18514 linux-x86-low.o.
18515 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18516 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18517 (linux_child_pid_to_exec_file): New function.
18518 (elf_64_header_p, elf_64_file_p): New functions.
18519 (siginfo_fixup): New function.
18520 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18521 give target a chance to convert layout.
18522 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18523 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18524
fdeb2a12
DE
185252009-05-07 Doug Evans <dje@google.com>
18526
18527 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18528 (regsets_store_inferior_registers): Ditto.
18529
a6dbe5df
PA
185302009-05-06 Pedro Alves <pedro@codesourcery.com>
18531
18532 PR server/10048
18533
18534 * linux-low.c (must_set_ptrace_flags): Delete.
18535 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18536 of the global.
18537 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18538 `lwp->must_set_ptrace_flags' instead.
ba42693b 18539 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
18540 (linux_wait_1): ... not here.
18541
5091eb23
DE
185422009-04-30 Doug Evans <dje@google.com>
18543
9f767825
DE
18544 * inferiors.c (started_inferior_callback): New function.
18545 (attached_inferior_callback): New function.
18546 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18547 * server.c (print_started_pid, print_attached_pid): New functions.
18548 (detach_or_kill_for_exit): New function.
18549 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18550 * server.h (have_started_inferiors_p): Declare.
18551 (have_attached_inferiors_p): Declare.
18552
5091eb23
DE
18553 * inferiors.c (remove_process): Fix memory leak, free process.
18554 * linux-low.c (linux_remove_process): New function.
18555 (linux_kill): Call it instead of remove_process.
18556 (linux_detach, linux_wait_1): Ditto.
18557
155c8968
PA
185582009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18559
18560 * configure.srv: Add x86 Windows CE target.
18561
7fe519cb
UW
185622009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18563
18564 * inferiors.c (get_thread_process): Make global.
18565 * server.h (get_thread_process): Add prototype.
18566 * thread-db.c (find_one_thread): Use get_thread_process
18567 instead of current_process.
18568 (thread_db_get_tls_address): Do not crash if called when
18569 thread layer is not yet initialized.
18570
5472f405
UW
185712009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18572
18573 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18574 * spu-low.c (current_tid): Rename to ...
18575 (current_ptid): ... this.
18576 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18577 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18578 ptid_get_lwp (current_ptid) instead of current_tid.
18579 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18580 instead of current_tid. Use find_process_pid to verify pid
18581 argument is valid. Pass proper argument to remove_process.
18582 (spu_thread_alive): Compare current_ptid instead of current_tid.
18583 (spu_resume): Likewise.
18584
55ac2b99
PA
185852009-04-02 Pedro Alves <pedro@codesourcery.com>
18586
18587 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18588 variable.
18589
95954743
PA
185902009-04-01 Pedro Alves <pedro@codesourcery.com>
18591
18592 Implement the multiprocess extensions, and add linux multiprocess
18593 support.
18594
18595 * server.h (ULONGEST): Declare.
18596 (struct ptid, ptid_t): New.
18597 (minus_one_ptid, null_ptid): Declare.
18598 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18599 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18600 (struct inferior_list_entry): Change `id' type from unsigned from
18601 to ptid_t.
18602 (struct sym_cache, struct breakpoint, struct
18603 process_info_private): Forward declare.
18604 (struct process_info): Declare.
18605 (current_process): Declare.
18606 (all_processes): Declare.
18607 (initialize_inferiors): Declare.
18608 (add_thread): Adjust to use ptid_t.
18609 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18610 (add_process, remove_process, find_thread_pid): Declare.
18611 (find_inferior_id): Adjust to use ptid_t.
18612 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18613 (multi_process): Declare.
18614 (push_event): Adjust to use ptid_t.
18615 (read_ptid, write_ptid): Declare.
18616 (prepare_resume_reply): Adjust to use ptid_t.
18617 (clear_symbol_cache): Declare.
18618 * inferiors.c (all_processes): New.
18619 (null_ptid, minus_one_ptid): New.
18620 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18621 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18622 (add_thread): Change unsigned long to ptid. Remove gdb_id
18623 parameter. Adjust.
18624 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18625 (gdb_id_to_thread): Rename to ...
18626 (find_thread_pid): ... this. Change unsigned long to ptid.
18627 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18628 (loaded_dll, pull_pid_from_list): Adjust.
18629 (add_process, remove_process, find_process_pid)
18630 (get_thread_process, current_process, initialize_inferiors): New.
18631 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18632 (struct target_waitstatus) <related_pid>: Ditto.
18633 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18634 return type to int.
18635 (struct target_ops) <join>: Add `pid' argument.
18636 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18637 (struct target_ops) <wait>: Add `ptid' field. Change return type
18638 to ptid.
18639 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18640 (mywait): Add `ptid' argument. Change return type to ptid_t.
18641 (target_pid_to_str): Declare.
18642 * target.c (set_desired_inferior): Adjust to use ptids.
18643 (mywait): Add new `ptid' argument. Adjust.
18644 (target_pid_to_str): New.
18645 * mem-break.h (free_all_breakpoints): Declare.
18646 * mem-break.c (breakpoints): Delelete.
18647 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18648 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18649 to use per-process breakpoint list.
18650 (free_all_breakpoints): New.
18651 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18652 (symbol_cache, all_symbols_looked_up): Delete.
18653 (hexchars): New.
18654 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18655 read_ptid): New.
18656 (prepare_resume_reply): Change ptid argument's type from unsigned
18657 long to ptid_t. Adjust. Implement W;process and X;process.
18658 (free_sym_cache, clear_symbol_cache): New.
18659 (look_up_one_symbol): Adjust to per-process symbol cache. *
18660 * server.c (cont_thread, general_thread, step_thread): Change type
18661 to ptid_t.
18662 (attached): Delete.
18663 (multi_process): New.
18664 (last_ptid): Change type to ptid_t.
18665 (struct vstop_notif) <ptid>: Change type to ptid_t.
18666 (queue_stop_reply, push_event): Change `ptid' argument's type to
18667 ptid_t.
18668 (discard_queued_stop_replies): Add `pid' argument.
18669 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18670 changes. Don't reference the `attached' global.
18671 (attach_inferior): Adjust to mywait interface changes.
18672 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18673 features. Handle and report "multiprocess+". Handle
18674 "qAttached:PID".
18675 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18676 changes.
18677 (handle_v_kill): New.
18678 (handle_v_stopped): Adjust to use target_pid_to_str.
18679 (handle_v_requests): Allow multiple attaches and runs when
18680 multiprocess extensions are in effect. Handle "vKill".
18681 (myresume): Adjust to use ptids.
18682 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18683 (handle_status): Adjust to discard_queued_stop_replies interface
18684 change.
18685 (first_thread_of, kill_inferior_callback)
18686 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18687 (main): Call initialize_inferiors. Adjust to use ptids, killing
18688 and detaching from all inferiors. Handle multiprocess packet
18689 variants.
18690 * linux-low.h: Include gdb_proc_service.h.
18691 (struct process_info_private): New.
18692 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18693 <lwpid_of>: Use ptid_get_lwp.
18694 (get_lwp_thread): Adjust.
18695 (struct lwp_info): Add `dead' member.
18696 (find_lwp_pid): Declare.
18697 * linux-low.c (thread_db_active): Delete.
18698 (new_inferior): Adjust comment.
18699 (inferior_pid): Delete.
18700 (linux_add_process): New.
18701 (handle_extended_wait): Adjust.
18702 (add_lwp): Change unsigned long to ptid.
18703 (linux_create_inferior): Add process to processes table. Adjust
18704 to use ptids. Don't set new_inferior here.
18705 (linux_attach_lwp): Rename to ...
18706 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18707 it. Adjust to use ptids.
18708 (linux_attach_lwp): New.
18709 (linux_attach): Add process to processes table. Don't set
18710 new_inferior here.
18711 (struct counter): New.
18712 (second_thread_of_pid_p, last_thread_of_process_p): New.
18713 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18714 multiple processes.
18715 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18716 processes. Remove process from process table.
18717 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18718 to multiple processes.
18719 (any_thread_of): New.
18720 (linux_detach): Add `pid' argument, and handle it. Remove process
18721 from processes table.
18722 (linux_join): Add `pid' argument. Handle it.
18723 (linux_thread_alive): Change unsighed long argument to ptid_t.
18724 Consider dead lwps as not being alive.
18725 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
18726 threads we're not interested in.
18727 (same_lwp, find_lwp_pid): New.
18728 (linux_wait_for_lwp): Change `pid' argument's type from int to
18729 ptid_t. Adjust.
18730 (linux_wait_for_event): Rename to ...
18731 (linux_wait_for_event_1): ... this. Change `pid' argument's type
18732 from int to ptid_t. Adjust.
18733 (linux_wait_for_event): New.
18734 (linux_wait_1): Add `ptid' argument. Change return type to
18735 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
18736 that exit from the process table.
18737 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
18738 Adjust.
18739 (mark_lwp_dead): New.
18740 (wait_for_sigstop): Adjust to use ptids. If a process exits while
18741 stopping all threads, mark its main lwp as dead.
18742 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
18743 ptids.
18744 (fetch_register, usr_store_inferior_registers)
18745 (regsets_fetch_inferior_registers)
18746 (regsets_store_inferior_registers, linux_read_memory)
18747 (linux_write_memory): Inline `inferior_pid'.
18748 (linux_look_up_symbols): Adjust to use per-process
18749 `thread_db_active'.
18750 (linux_request_interrupt): Adjust to use ptids.
18751 (linux_read_auxv): Inline `inferior_pid'.
18752 (initialize_low): Don't reference thread_db_active.
18753 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
18754 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
18755 (ps_getpid): Return the pid of the current inferior.
18756 * thread-db.c (proc_handle, thread_agent): Delete.
18757 (thread_db_create_event, thread_db_enable_reporting): Adjust to
18758 per-process data.
18759 (find_one_thread): Change argument type to ptid_t. Adjust to
18760 per-process data.
18761 (maybe_attach_thread): Adjust to per-process data and ptids.
18762 (thread_db_find_new_threads): Ditto.
18763 (thread_db_init): Ditto.
18764 * spu-low.c (spu_create_inferior, spu_attach): Add process to
18765 processes table. Adjust to use ptids.
18766 (spu_kill, spu_detach): Adjust interface. Remove process from
18767 processes table.
18768 (spu_join, spu_thread_alive): Adjust interface.
18769 (spu_wait): Adjust interface. Remove process from processes
18770 table. Adjust to use ptids.
18771 * win32-low.c (current_inferior_tid): Delete.
18772 (current_inferior_ptid): New.
18773 (debug_event_ptid): New.
18774 (thread_rec): Take a ptid. Adjust.
18775 (child_add_thread): Add `pid' argument. Adjust to use ptids.
18776 (child_delete_thread): Ditto.
18777 (do_initial_child_stuff): Add `attached' argument. Add process to
18778 processes table.
18779 (child_fetch_inferior_registers, child_store_inferior_registers):
18780 Adjust.
18781 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
18782 (win32_attach): Pass 1 to do_initial_child_stuff.
18783 (win32_kill): Adjust interface. Remove process from processes
18784 table.
18785 (win32_detach): Ditto.
18786 (win32_join): Adjust interface.
18787 (win32_thread_alive): Take a ptid.
18788 (win32_resume): Adjust to use ptids.
18789 (get_child_debug_event): Ditto.
18790 (win32_wait): Adjust interface. Remove exiting process from
18791 processes table.
18792
bd99dc85
PA
187932009-04-01 Pedro Alves <pedro@codesourcery.com>
18794
18795 Non-stop mode support.
18796
18797 * server.h (non_stop): Declare.
18798 (gdb_client_data, handler_func): Declare.
18799 (delete_file_handler, add_file_handler, start_event_loop):
18800 Declare.
18801 (handle_serial_event, handle_target_event, push_event)
18802 (putpkt_notif): Declare.
18803 * target.h (enum resume_kind): New.
18804 (struct thread_resume): Replace `step' field by `kind' field.
18805 (TARGET_WNOHANG): Define.
18806 (struct target_ops) <wait>: Add `options' argument.
18807 <supports_non_stop, async, start_non_stop>: New fields.
18808 (target_supports_non_stop, target_async): New.
18809 (start_non_stop): Declare.
18810 (mywait): Add `options' argument.
18811 * target.c (mywait): Add `options' argument. Print child exit
18812 notifications here.
18813 (start_non_stop): New.
18814 * server.c (non_stop, own_buf, mem_buf): New globals.
18815 (struct vstop_notif): New.
18816 (notif_queue): New global.
18817 (queue_stop_reply, push_event, discard_queued_stop_replies)
18818 (send_next_stop_reply): New.
18819 (start_inferior): Adjust to use resume_kind. Adjust to mywait
18820 interface changes.
18821 (attach_inferior): In non-stop mode, don't wait for the target
18822 here.
18823 (handle_general_set): Handle QNonStop.
18824 (handle_query): When handling qC, return the current general
18825 thread, instead of the first thread of the list.
18826 (handle_query): If the backend supports non-stop mode, include
18827 QNonStop+ in the qSupported query response.
18828 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
18829 and non-stop mode.
18830 (handle_v_attach, handle_v_run): Handle non-stop mode.
18831 (handle_v_stopped): New.
18832 (handle_v_requests): Report support for vCont;t. Handle vStopped.
18833 (myresume): Adjust to use resume_kind. Handle non-stop.
18834 (queue_stop_reply_callback): New.
18835 (handle_status): Handle non-stop mode.
18836 (main): Clear non_stop flag on reconnection. Use the event-loop.
18837 Refactor serial protocol handling from here ...
18838 (process_serial_event): ... to this new function. When GDB
18839 selects any thread, select one here. In non-stop mode, wait until
18840 GDB acks all pending events before exiting.
18841 (handle_serial_event, handle_target_event): New.
18842 * remote-utils.c (remote_open): Install remote_desc in the event
18843 loop.
18844 (remote_close): Remove remote_desc from the event loop.
18845 (putpkt_binary): Rename to...
18846 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
18847 (putpkt_binary): New as wrapper around putpkt_binary_1.
18848 (putpkt_notif): New.
18849 (prepare_resume_reply): In non-stop mode, don't change the
18850 general_thread.
18851 * event-loop.c: New.
18852 * Makefile.in (OBJ): Add event-loop.o.
18853 (event-loop.o): New rule.
18854
18855 * linux-low.h (pid_of): Moved here.
18856 (lwpid_of): New.
18857 (get_lwp_thread): Use lwpid_of.
18858 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
18859 * linux-low.c (pid_of): Delete.
18860 (inferior_pid): Use lwpid_of.
18861 (linux_event_pipe): New.
18862 (target_is_async_p): New.
18863 (delete_lwp): New.
18864 (handle_extended_wait): Use lwpid_of.
18865 (add_lwp): Don't set lwpid field.
18866 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
18867 (linux_kill_one_lwp): If killing a running lwp, stop it first.
18868 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
18869 (linux_detach_one_lwp): If detaching from a running lwp, stop it
18870 first. Adjust to linux_wait_for_event interface changes. Use
18871 lwpid_of.
18872 (linux_detach): Don't delete the main lwp here.
18873 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
18874 (status_pending_p): Don't consider explicitly suspended lwps.
18875 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
18876 pointer. Add OPTIONS argument. Change return type to int. Use
18877 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
18878 (linux_wait_for_event): Take an integer pid instead of a lwp_info
18879 pointer. Add status pointer argument. Return a pid instead of a
18880 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
18881 changes. In non-stop mode, don't switch to a random thread.
18882 (linux_wait): Rename to...
18883 (linux_wait_1): ... this. Add target_options argument, and handle
18884 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
18885 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
18886 clean exit and signal exit code. Don't stop all threads in
18887 non-stop mode. In all-stop mode, only stop all threads when
18888 reporting a stop to GDB. Handle explicit thread stop requests.
18889 (async_file_flush, async_file_mark): New.
18890 (linux_wait): New.
18891 (send_sigstop): Use lwpid_of.
18892 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
18893 interface changes. In non-stop mode, don't switch to a random
18894 thread.
18895 (linux_resume_one_lwp): Use lwpid_of.
18896 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
18897 (linux_resume_one_thread): ... this. Handle resume_stop. In
18898 non-stop mode, don't look for pending flag in all threads.
18899 (resume_status_pending_p): Don't consider explicitly suspended
18900 threads.
18901 (my_waitpid): Reimplement. Emulate __WALL.
18902 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
18903 Use lwpid_of.
18904 (sigchld_handler, linux_supports_non_stop, linux_async)
18905 (linux_start_non_stop): New.
18906 (linux_target_ops): Register linux_supports_non_stop, linux_async
18907 and linux_start_non_stop.
18908 (initialize_low): Install SIGCHLD handler.
18909 * thread-db.c (thread_db_create_event, find_one_thread)
18910 (thread_db_get_tls_address): Use lwpid_of.
18911 * win32-low.c (win32_detach): Adjust to use resume_kind.
18912 (win32_wait): Add `options' argument.
18913 * spu-low.c (spu_resume): Adjust to use resume_kind.
18914 (spu_wait): Add `options' argument.
18915
5b1c542e
PA
189162009-04-01 Pedro Alves <pedro@codesourcery.com>
18917
18918 Decouple target code from remote protocol.
18919
18920 * target.h (enum target_waitkind): New.
18921 (struct target_waitstatus): New.
18922 (struct target_ops) <wait>: Return an unsigned long. Take a
18923 target_waitstatus pointer instead of a char pointer.
18924 (mywait): Likewise.
18925 * target.c (mywait): Change prototype to return an unsigned long.
18926 Take a target_waitstatus pointer instead of a char pointer. Adjust.
18927 * server.h (thread_from_wait, old_thread_from_wait): Delete
18928 declarations.
18929 (prepare_resume_reply): Change prototype to take a
18930 target_waitstatus.
18931 * server.c (thread_from_wait, old_thread_from_wait): Delete.
18932 (last_status, last_ptid): New.
18933 (start_inferior): Remove "statusptr" argument. Adjust. Return a
18934 pid instead of a signal.
18935 (attach_inferior): Remove "status" and "signal" parameters.
18936 Adjust.
18937 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
18938 not as an address.
18939 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
18940 (handle_v_requests, myresume): Remove "status" and "signal"
18941 parameters. Adjust.
18942 (handle_status): New.
18943 (main): Delete local `status'. Adjust.
18944 * remote-utils.c: Include target.h.
18945 (prepare_resume_reply): Change prototype to take a
18946 target_waitstatus. Adjust.
18947
18948 * linux-low.c (linux_wait): Adjust to new target_ops->wait
18949 interface.
18950 * spu-low.c (spu_wait): Adjust.
18951 * win32-low.c (enum target_waitkind, struct target_waitstatus):
18952 Delete.
18953 (win32_wait): Adjust.
18954
2bd7c093
PA
189552009-04-01 Pedro Alves <pedro@codesourcery.com>
18956
18957 * target.h (struct thread_resume): Delete leave_stopped member.
18958 (struct target_ops): Add a `n' argument to the `resume' callback.
18959 * server.c (start_inferior): Adjust.
18960 (handle_v_cont, myresume): Adjust.
18961 * linux-low.c (check_removed_breakpoint): Adjust to resume
18962 interface change, and to removed leave_stopped field.
18963 (resume_ptr): Delete.
18964 (struct thread_resume_array): New.
18965 (linux_set_resume_request): Add new `arg' parameter. Adjust to
18966 resume interface change.
18967 (linux_continue_one_thread, linux_queue_one_thread)
18968 (resume_status_pending_p): Check if the resume field is NULL
18969 instead of checking the leave_stopped member.
18970 (linux_resume): Adjust to the target resume interface change.
18971 * spu-low.c (spu_resume): Adjust to the target resume interface
18972 change.
18973 * win32-low.c (win32_detach, win32_resume): Ditto.
18974
c35fafde
PA
189752009-04-01 Pedro Alves <pedro@codesourcery.com>
18976
18977 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
18978 flag.
18979 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
18980 pending.
18981 (linux_continue_one_thread): Only preserve the stepping flag if
18982 there's a pending breakpoint.
18983
0a59d50b
PA
189842009-03-31 Pedro Alves <pedro@codesourcery.com>
18985
18986 * server.c (main): After the inferior having exited, call
18987 remote_close before exiting gdbserver.
18988
f04c6d38
TJB
189892009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
18990
18991 Fix size of FPSCR in Power 7 processors.
18992 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
18993 (PPC_FEATURE_HAS_DFP): New #define.
18994 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
18995 size of the FPSCR.
18996
78e5cee6
PA
189972009-03-23 Pedro Alves <pedro@codesourcery.com>
18998
18999 * server.c (handle_query) Whitespace and formatting.
19000
1b3f6016
PA
190012009-03-22 Pedro Alves <pedro@codesourcery.com>
19002
19003 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19004 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19005 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19006 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19007 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19008 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19009 Makefile.in, configure.ac: Fix whitespace throughout.
19010 * configure: Regenerate.
19011
a07b2135
PA
190122009-03-22 Pedro Alves <pedro@codesourcery.com>
19013
19014 * inferiors.c (find_inferior): Make it safe for the callback
19015 function to delete the currently iterated inferior.
19016
67cc2626
PA
190172009-03-22 Pedro Alves <pedro@codesourcery.com>
19018
19019 * Makefile.in (linuw_low_h): Move higher.
19020 (thread-db.o): Depend on $(linux_low_h).
19021
54a0b537
PA
190222009-03-17 Pedro Alves <pedro@codesourcery.com>
19023
19024 Rename "process" to "lwp" throughout.
19025
19026 * linux-low.c (all_processes): Rename to...
19027 (all_lwps): ... this.
19028 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19029 (add_process): Rename to ...
19030 (add_lwp): ... this. Adjust.
19031 (linux_create_inferior): Adjust.
19032 (linux_attach_lwp): Adjust.
19033 (linux_attach): Adjust.
19034 (linux_kill_one_process): Rename to ...
19035 (linux_kill_one_lwp): ... this. Adjust.
19036 (linux_kill): Adjust.
19037 (linux_detach_one_process): Rename to ...
19038 (linux_detach_one_lwp): ... this. Adjust.
19039 (linux_detach): Adjust.
19040 (check_removed_breakpoint): Adjust.
19041 (status_pending_p): Adjust.
19042 (linux_wait_for_process): Rename to ...
19043 (linux_wait_for_lwp): ... this. Adjust.
19044 (linux_wait_for_event): Adjust.
19045 (send_sigstop): Adjust.
19046 (wait_for_sigstop): Adjust.
19047 (stop_all_processes): Rename to ...
19048 (stop_all_lwps): ... this.
19049 (linux_resume_one_process): Rename to ...
19050 (linux_resume_one_lwp): ... this. Adjust.
19051 (linux_set_resume_request, linux_continue_one_thread)
19052 (linux_queue_one_thread, resume_status_pending_p)
19053 (usr_store_inferior_registers, regsets_store_inferior_registers)
19054 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19055 Adjust.
19056 * linux-low.h (get_process): Rename to ...
19057 (get_lwp): ... this. Adjust.
19058 (get_thread_process): Rename to ...
19059 (get_thread_lwp): ... this. Adjust.
19060 (get_process_thread): Rename to ...
19061 (get_lwp_thread): ... this. Adjust.
19062 (struct process_info): Rename to ...
19063 (struct lwp_info): ... this.
19064 (all_processes): Rename to ...
19065 (all_lwps): ... this.
19066 * proc-service.c (ps_lgetregs): Adjust.
19067 * thread-db.c (thread_db_create_event, find_one_thread)
19068 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19069
0b16c5cf
PA
190702009-03-14 Pedro Alves <pedro@codesourcery.com>
19071
19072 * server.c (handle_query): Handle "qAttached".
19073
32de4b9d
NS
190742009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19075
19076 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19077 GPLv3, update license URL.
19078
2aecd87f
DE
190792009-03-01 Doug Evans <dje@google.com>
19080
93efd302 19081 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
19082 (server_h): Add gdb_signals.h.
19083 (signals.o): Update.
19084 * server.h (target_signal_from_host,target_signal_to_host_p)
19085 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19086
86b1f9c5
PM
190872009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19088
19089 * remote-utils.c (getpkt): Also generate remote-debug
19090 information if noack_mode is set.
19091
4aa995e1
PA
190922009-02-06 Pedro Alves <pedro@codesourcery.com>
19093
19094 * server.c (handle_query): Report qXfer:siginfo:read and
19095 qXfer:siginfo:write as supported and handle them.
19096 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19097 * linux-low.c (linux_xfer_siginfo): New.
19098 (linux_target_ops): Set it.
19099
62709adf
PA
191002009-01-26 Pedro Alves <pedro@codesourcery.com>
19101
19102 * server.c (gdbserver_usage): Mention --remote-debug.
19103 (main): Accept '--remote-debug' switch.
19104
aef93bd7
DE
191052009-01-18 Doug Evans <dje@google.com>
19106
19107 * regcache.c (new_register_cache): No need to check result of xcalloc.
19108 * server.c (handle_search_memory): Back out calls to xmalloc,
19109 result is checked and error is returned to user upon failure.
19110 (handle_query): Ditto. Add more checks for result of malloc.
19111 (handle_v_cont): Check result of malloc, report error back to
19112 user upon failure.
19113 (handle_v_run): Ditto. Call freeargv.
19114 * server.h (freeargv): Declare.
19115 * utils.c (freeargv): New fn.
19116
54363045
DE
191172009-01-15 Doug Evans <dje@google.com>
19118
f626972c
DE
19119 * gdbreplay.c (perror_with_name): Make arg const char *.
19120 * server.h (target_signal_to_name): Make return type const char *.
0842e787 19121 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 19122 * utils.c (perror_with_name): Make arg const char *.
54363045 19123
18aae699
PA
191242009-01-14 Pedro Alves <pedro@codesourcery.com>
19125
19126 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19127 when handling a EXIT_PROCESS_DEBUG_EVENT.
19128
ff703abe
JB
191292009-01-06 Joel Brobecker <brobecker@adacore.com>
19130
19131 * gdbreplay.c (gdbreplay_version): Update copyright year.
19132 * server.c (gdbserver_version): Likewise.
19133
f21cc1a2 191342009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
19135
19136 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 19137 (handle_extended_wait): Improve comment.
0e21c1ec 19138
bca929d3
DE
191392008-12-13 Doug Evans <dje@google.com>
19140
19141 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19142 * server.h (ATTR_MALLOC): New macro.
19143 (xmalloc,xcalloc,xstrdup): Declare.
19144 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19145 * inferiors.c: Ditto.
19146 * linux-low.c: Ditto.
19147 * mem-break.c: Ditto.
19148 * regcache.c: Ditto.
19149 * remote-utils.c: Ditto.
19150 * server.c: Ditto.
19151 * target.c: Ditto.
19152 * win32-low.c: Ditto.
19153
97438e3f
DE
191542008-12-12 Doug Evans <dje@google.com>
19155
896c7fbb
DE
19156 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19157 in debugging printf.
19158
97438e3f
DE
19159 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19160
e3b886f8
DE
191612008-12-09 Doug Evans <dje@google.com>
19162
19163 * linux-low.h (struct process_info): Delete member tid, unused.
19164 * thread-db.c (find_one_thread): Update.
19165 (maybe_attach_thread): Update.
19166
07e059b5
VP
191672008-12-02 Pedro Alves <pedro@codesourcery.com>
19168
889bf7c5
PA
19169 * target.h (struct target_ops): Add qxfer_osdata member.
19170 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19171 and dirent.h.
19172 (linux_qxfer_osdata): New functions.
19173 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19174 callback.
19175 * server.c (handle_query): Handle "qXfer:osdata:read:".
19176 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19177 (buffer_xml_printf): New functions.
19178 * server.h (struct buffer): New.
19179 (buffer_grow_str, buffer_grow_str0): New macros.
19180 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19181 (buffer_xml_printf): Declare.
07e059b5 19182
4cab47ab
DE
191832008-11-24 Doug Evans <dje@google.com>
19184
19185 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19186
f142445f
DJ
191872008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19188
19189 * server.c (handle_v_run): Always use the supplied argument list.
19190
d0107bb6 191912008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 19192
d0107bb6
BW
19193 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19194 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 19195
2c4ad781
TJB
191962008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19197
19198 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19199 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19200 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19201 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19202 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19203 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19204 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19205 XML target descriptions.
19206 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19207 when inferior is running on an ISA 2.05 or later processor. Add
19208 special case to return offset for full 64-bit slot of FPSCR when
19209 in 32-bits.
19210
dfb64f85
DJ
192112008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19212
19213 * Makefile.in (SFILES, clean): Added sparc64 files.
19214 (reg-sparc64.o, reg-sparc64.c): New.
19215 * configure.srv (sparc*-*-linux*): New configuration.
19216 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19217 syscall arguments for SPARC.
19218 (regsets_store_inferior_registers): Likewise.
19219 * linux-sparc-low.c: New file.
19220
66b6e1dd
DE
192212008-10-21 Doug Evans <dje@google.com>
19222
19223 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19224 (READLINE_DIR,READLINE_DEP): Delete.
19225 (INTERNAL_CFLAGS): Update.
19226 (LINTFLAGS): Update.
19227
9b710a42
PA
192282008-10-10 Pedro Alves <pedro@codesourcery.com>
19229
19230 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19231 whole argv from the last run, not just argv[0].
19232
5822d809
PA
192332008-09-08 Pedro Alves <pedro@codesourcery.com>
19234
19235 * regcache.c (new_register_cache): Return NULL if the register
19236 cache size isn't known yet.
19237 (free_register_cache): Avoid dereferencing a NULL regcache.
19238
74aac56f
DJ
192392008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19240
19241 * configure.srv: Merge MIPS and MIPS64.
19242
400b20f5
MR
192432008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19244
19245 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19246
677c5bb1
LM
192472008-08-18 Luis Machado <luisgpm@br.ibm.com>
19248
19249 * Makefile.in: Add required vsx dependencies.
19250
19251 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19252 Declare init_registers_powerpc_vsx32l.
19253 Declare init_registers_powerpc_vsx64l.
19254 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19255 (ppc_arch_setup): Check for VSX in hwcap.
19256 (ppc_fill_vsxregset): New function.
19257 (ppc_store_vsxregset): New function.
19258 Add new VSX entry in regset_info target_regsets.
19259
19260 * configure.srv: Add new VSX dependencies.
19261
a6f3e723
SL
192622008-08-12 Pedro Alves <pedro@codesourcery.com>
19263
19264 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19265 (remote_open): Set or clear transport_is_reliable.
19266 (putpkt_binary): Don't expect acks in noack mode.
19267 (getpkt): Don't send ack/nac in noack mode.
19268 * server.c (handle_general_set): Handle QStartNoAckMode.
19269 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19270 qSupported.
19271 (main): Reset noack_mode on every connection.
19272 * server.h (noack_mode): Declare.
19273
a417dc56
RW
192742008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19275
19276 * Makefile.in (GDBREPLAY_OBS): New variable.
19277 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19278
3221518c
UW
192792008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19280 Daniel Jacobowitz <dan@codesourcery.com>
19281
19282 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19283 (usr_store_inferior_registers): Likewise.
19284 (regsets_store_inferior_registers): Likewise.
19285
ec56be1b
PA
192862008-07-31 Rolf Jansen <rj@surtec.com>
19287 Pedro Alves <pedro@codesourcery.com>
19288
19289 * configure.ac: Check for memmem declaration.
19290 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19291 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19292 (disable_packet_qfThreadInfo): Unconditionally compile.
19293 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19294 * configure, config.in: Regenerate.
19295
2fe5e3ff
DE
192962008-07-28 Doug Kwan <dougkwan@google.com>
19297
19298 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19299 (linux_write_memory): Remove declaration of errno.
19300
836acd6d
UW
193012008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19302
19303 * linux-low.c (handle_extended_wait): Do not use "status"
19304 variable uninitialized.
19305
aeba519e
PA
193062008-07-07 Pedro Alves <pedro@codesourcery.com>
19307
19308 * server.c (handle_v_attach): Inhibit reporting dll changes.
19309
db42f210
PA
193102008-06-27 Pedro Alves <pedro@codesourcery.com>
19311
19312 * remote-utils.c (prepare_resume_reply): If requested, don't
19313 output "thread:TID" in the T stop reply.
19314
19315 * server.c (disable_packet_vCont, disable_packet_Tthread)
19316 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19317 (handle_query): If requested, disable support for qC, qfThreadInfo
19318 and qsThreadInfo.
19319 (handle_v_requests): If requested, disable support for vCont.
19320 (gdbserver_show_disableable): New.
19321 (main): Handle --disable-packet and --disable-packet=LIST.
19322
19323 * server.h (disable_packet_vCont, disable_packet_Tthread)
19324 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19325
8e4c5421
CD
193262008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19327
19328 * server.c (gdbserver_usage): Mention --version.
19329
6e23a804
DJ
193302008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19331
19332 * Makefile.in (gdbreplay.o): New rule.
19333
90aa6a40
JM
193342008-06-06 Joseph Myers <joseph@codesourcery.com>
19335
19336 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19337 message, not gdbserver.
19338
c16158bc 193392008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
19340 Nathan Sidwell <nathan@codesourcery.com>
19341 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
19342
19343 * acinclude.m4: Include ../../config/acx.m4.
19344 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19345 * configure, config.in: Regenerate.
19346 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19347 * server.c (gdbserver_version): Print PKGVERSION.
19348 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19349 (main): Adjust gdbserver_usage calls.
19350 * gdbreplay.c (version, host_name): Add declarations.
19351 (gdbreplay_version, gdbreplay_usage): New.
19352 (main): Accept --version and --help options.
19353
aeb75bf5
DJ
193542008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19355
19356 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19357 (arm_breakpoint_at): Handle Thumb.
19358 (the_low_target): Add comment.
19359
76b233dd
UW
193602008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19361
19362 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19363
08388c79
DE
193642008-05-09 Doug Evans <dje@google.com>
19365
a3c83fae
DE
19366 * server.h (decode_search_memory_packet): Declare.
19367 * remote-utils.c (decode_search_memory_packet): New fn.
19368 * server.c (handle_search_memory_1): New fn.
08388c79
DE
19369 (handle_search_memory): New fn.
19370 (handle_query): Process qSearch:memory packets.
19371
bb9c3d36
UW
193722008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19373
19374 * regcache.c (registers_length): Remove.
19375 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19376 full register packet.
19377 * regcache.h (registers_length): Remove prototype.
19378 * server.h (PBUFSIZ): Define to 16384.
19379
7284e1be
UW
193802008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19381
19382 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19383 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19384 powerpc-64l.o, and powerpc-altivec64l.o.
19385 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19386 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19387 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19388 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19389 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19390 to srv_xmlfiles.
19391
19392 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19393 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19394 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19395 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19396 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19397 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19398 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19399 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19400 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19401 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19402 (clean): Update.
19403
19404 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19405 (init_registers_powerpc_32l): ... this new prototype.
19406 (init_registers_powerpc_32): Remove, replace by ...
19407 (init_registers_powerpc_altivec32l): ... this new prototype.
19408 (init_registers_powerpc_e500): Remove, replace by ...
19409 (init_registers_powerpc_e500l): ... this new prototype.
19410 (init_registers_ppc64): Remove, replace by ...
19411 (init_registers_powerpc_64l): ... this new prototype.
19412 (init_registers_powerpc_64): Remove, replace by ...
19413 (init_registers_powerpc_altivec64l): ... this new prototype.
19414 (ppc_num_regs): Set to 73.
19415 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19416 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19417 (ppc_cannot_store_register): Handle orig_r3 and trap.
19418 (ppc_arch_setup): Update init_registers_... calls.
19419 (ppc_fill_gregset): Handle orig_r3 and trap.
19420
19421 * inferiors.c (clear_inferiors): Reset current_inferior.
19422
fdc59709
PB
194232008-04-23 Paolo Bonzini <bonzini@gnu.org>
19424
889bf7c5
PA
19425 * acinclude.m4: Add override.m4.
19426 * configure: Regenerate.
fdc59709 19427
c9b2f845
UW
194282008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19429
19430 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19431 initial call to init_register_ppc64.
19432
550512b8
UW
194332008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19434
43aaf8b6
PA
19435 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19436 single powerpc*-*-linux* case.
550512b8
UW
19437 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19438
b6430ec3
UW
194392008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19440
19441 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 19442 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
19443 from reg_xmlfiles.
19444 * linux-ppc-low.c: Include <elf.h>.
19445 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19446 (ppc_hwcap): New global variable.
19447 (ppc_regmap): Remove __SPE__ #ifdef sections.
19448 (ppc_regmap_e500): New global variable.
19449 (ppc_cannot_store_register): Update __SPE__ special case.
19450 (ppc_get_hwcap): New function.
19451 (ppc_arch_setup): Use it to determine whether inferior supports
19452 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19453 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19454 Do not access registers if target does not support AltiVec.
19455 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19456 Do not access registers if target does not support SPE.
19457 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19458
52fa2412
UW
194592008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19460
19461 * linux-low.c (disabled_regsets, num_regsets): New.
19462 (use_regsets_p): Delete.
19463 (linux_wait_for_process): Clear disabled_regsets.
19464 (regsets_fetch_inferior_registers): Check and set it.
19465 (regsets_store_inferior_registers): Likewise.
19466 (linux_fetch_registers, linux_store_registers): Do not use
19467 use_regsets_p.
19468 (initialize_low): Allocate disabled_regsets.
19469
e28b3332
DJ
194702008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19471
19472 * Makefile.in (LIBOBJS): New.
19473 (OBS): Use LIBOBJS.
19474 (memmem.o): New rule.
19475 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19476 * configure: Regenerated.
19477
4536995d
UW
194782008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19479
19480 * server.c (handle_query): Never return "unsupported" for
19481 qXfer:features:read queries.
19482
221c031f
UW
194832008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19484
19485 * server.c (get_features_xml): Fix inverted condition.
19486 (handle_query): Always support qXfer:feature:read.
19487
ccd213ac
DJ
194882008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19489
19490 * server.c (wrapper_argv): New.
19491 (start_inferior): Handle wrapper_argv. If set, expect an extra
19492 trap.
19493 (gdbserver_usage): Document --wrapper.
19494 (main): Parse --wrapper.
19495
6fe305f7
UW
194962008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19497
19498 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19499 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19500 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19501 (ppc_set_pc): Likewise.
19502 (ppc_arch_setup): New function.
19503 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19504 of collect_register.
889bf7c5 19505 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 19506
5b0a002e
UW
195072008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19508
19509 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19510 instead of linux-ppc64-low.o.
19511 * linux-ppc64-low.c: Remove file.
19512 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19513 (linux-ppc64-low.o): Remove rule.
19514
19515 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19516 (init_registers_powerpc_64): Likewise.
19517 (ppc_regmap): Conditionally define depending on __powerpc64__.
19518 (ppc_cannot_store_register): Do not special-case "fpscr" when
19519 compiled on __powerpc64__.
19520 (ppc_collect_ptrace_register): New function.
19521 (ppc_supply_ptrace_register): New function.
19522 (ppc_breakpoint): Change type to "unsigned int".
19523 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19524 (the_low_target): Conditionally provide initializers for the
889bf7c5 19525 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
19526 collect_ptrace_register and supply_ptrace_register members.
19527
9b4b61c8
UW
195282008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19529
19530 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19531 * server.c (gdbserver_xmltarget): Define.
19532 (get_features_xml): Use it to replace "target.xml" and arch_string.
19533
19534 * configure.srv: Remove srv_xmltarget. Add XML files that were
19535 mentioned there to srv_xmlfiles instead. Remove conditional tests
19536 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19537 srv_xmlfiles and srv_regobj to include all possible choices.
19538 * configure.ac (srv_xmltarget): Remove.
19539 (srv_xmlfiles): Do not add "target.xml".
19540 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19541 checks for supplementary target information.
19542 * configure: Regenerate.
19543 * Makefile.in (XML_TARGET): Remove.
19544 (target.xml): Remove rule.
19545 (clean): Do not clean up target.xml.
19546 (.PRECIOUS): Do not mention target.xml.
19547
19548 * target.h (struct target_ops): Remove arch_string member.
19549 * linux-low.c (linux_arch_string): Remove.
19550 (linux_target_ops): Remove arch_string initializer.
19551 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19552 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19553 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19554 * spu-low.c (spu_arch_string): Remove.
19555 (spu_target_ops): Remove arch_string initializer.
19556 * win32-low.c (win32_arch_string): Remove.
19557 (win32_target_ops): Remove arch_string initializer.
19558 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19559 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19560 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19561
ee1a7ae4
UW
195622008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19563
19564 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19565 by collect_ptrace_register and supply_ptrace_register hooks.
19566 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19567 instead of checking for the_low_target.left_pad_xfer.
19568 (usr_store_inferior_registers): Use collect_ptrace_register callback
19569 instead of checking for the_low_target.left_pad_xfer.
19570
19571 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19572 (s390_supply_ptrace_register): Likewise.
19573 (s390_fill_gregset): Call s390_collect_ptrace_register.
19574 (the_low_target): Update.
19575
19576 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19577 (ppc_supply_ptrace_register): Likewise.
19578 (the_low_target): Update.
19579
19580 * linux-i386-low.c (the_low_target): Update.
19581 * linux-x86-64-low.c (the_low_target): Update.
19582
d61ddec4
UW
195832008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19584
19585 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19586 reg-s390.o and reg-s390x.o.
19587
19588 * linux-low.c (new_inferior): New global variable.
19589 (linux_create_inferior, linux_attach): Set it.
19590 (linux_wait_for_process): Call the_low_target.arch_setup after the
19591 target has stopped for the first time.
19592 (initialize_low): Do not call the_low_target.arch_setup.
19593
19594 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19595 (s390_set_pc): Likewise.
19596 (s390_arch_setup): New function.
19597 (the_low_target): Use s390_arch_setup as arch_setup routine.
19598
19599 * regcache.c (realloc_register_cache): New function.
19600 (set_register_cache): Call it for each existing regcache.
19601
d05b4ac3
UW
196022008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19603
19604 * server.h (init_registers): Remove prototype.
19605
19606 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19607 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19608 instead of init_registers ().
19609 * linux-arm-low.c (init_registers_arm): Add prototype.
19610 (init_registers_arm_with_iwmmxt): Likewise.
19611 (the_low_target): Add initializer for arch_setup field.
19612 * linux-cris-low.c (init_registers_cris): Add prototype.
19613 (the_low_target): Add initializer for arch_setup field.
19614 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19615 (the_low_target): Add initializer for arch_setup field.
19616 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19617 (the_low_target): Add initializer for arch_setup field.
19618 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19619 (the_low_target): Add initializer for arch_setup field.
19620 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19621 (the_low_target): Add initializer for arch_setup field.
19622 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19623 (the_low_target): Add initializer for arch_setup field.
19624 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19625 (init_registers_mips64_linux): Likewise.
19626 (the_low_target): Add initializer for arch_setup field.
19627 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19628 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19629 (the_low_target): Add initializer for arch_setup field.
19630 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19631 (init_registers_powerpc_64): Likewise.
19632 (the_low_target): Add initializer for arch_setup field.
19633 * linux-s390-low.c (init_registers_s390): Add prototype.
19634 (init_registers_s390x): Likewise.
19635 (the_low_target): Add initializer for arch_setup field.
19636 * linux-sh-low.c (init_registers_sh): Add prototype.
19637 (the_low_target): Add initializer for arch_setup field.
19638 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19639 (the_low_target): Add initializer for arch_setup field.
19640 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19641 (the_low_target): Add initializer for arch_setup field.
19642
19643 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19644 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19645 instead of init_registers ().
19646 * win32-arm-low.c (init_registers_arm): Add prototype.
19647 (the_low_target): Add initializer for arch_setup field.
19648 * win32-i386-low.c (init_registers_i386): Add prototype.
19649 (the_low_target): Add initializer for arch_setup field.
19650
19651 * spu-low.c (init_registers_spu): Add prototype.
19652 (initialize_low): Call initialie_registers_spu () instead of
19653 initialize_registers ().
19654
fd96d250
PA
196552008-02-19 Pedro Alves <pedro@codesourcery.com>
19656
19657 * server.c (handle_v_requests): When handling the vRun and vAttach
19658 packets, if already debugging a process, don't kill it. Return an
19659 error instead.
19660
d41b6bb4
DJ
196612008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19662
19663 * server.c (handle_query): Correct length check.
19664
5ac588cf
PA
196652008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19666
19667 * win32-low.c (do_initial_child_stuff): Add process handle
19668 parameter. Set current_process_handle and current_process_id from the
19669 parameters. Clear globals.
19670 (win32_create_inferior): Don't set current_process_handle and
19671 current_process_id here. Instead pass them on the call to
19672 do_initial_child_stuff.
19673 (win32_attach): Likewise.
19674 (win32_clear_inferiors): New.
19675 (win32_kill): Don't close the current process handle or the
19676 current thread handle here. Instead call win32_clear_inferiors.
19677 (win32_detach): Don't open a new handle to the process. Call
19678 win32_clear_inferiors.
19679 (win32_join): Don't rely on current_process_handle; open a new
19680 handle using the process id.
19681 (win32_wait): Call win32_clear_inferiors when the inferior process
19682 has exited.
19683
ecd7ecbc
DJ
196842008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19685
19686 * server.c (monitor_show_help): Add "exit".
19687
1525d545
MG
196882008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19689
ecd7ecbc 19690 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
19691 (clean): Add reg-xtensa.c.
19692 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
19693 * configure.srv (xtensa*-*-linux*) New target.
19694 * linux-xtensa-low.c: New.
19695 * xtensa-xtregs.c: New.
1525d545 19696
59a016f0
PA
196972008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19698
19699 * hostio.c: Don't include errno.h.
19700 (errno_to_fileio_errno): Move to hostio-errno.
19701 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19702 error number outputting to the target->hostio_last_error callback.
19703 (hostio_packet_error): Use FILEIO_EINVAL directly.
19704 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19705 calls to hostio_error.
19706 * hostio-errno.c: New.
19707 * server.h (hostio_last_error_from_errno): Declare.
19708 * target.h (target_ops): Add hostio_last_error member.
19709 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19710 as hostio_last_error handler.
889bf7c5 19711 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
19712 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19713 (wince_hostio_last_error): New functions.
19714 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19715 as hostio_last_error handler.
19716 (win32_target_ops) [!_WIN32_WCE]: Register
19717 hostio_last_error_from_errno as hostio_last_error handler.
19718 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19719 (hostio-errno.o): New rule.
19720 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19721 * configure.srv (srv_hostio_err_objs): New variable. Default to
19722 hostio-errno.o.
19723 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19724 * configure: Regenerate.
19725
2d717e4f
DJ
197262008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19727
19728 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
19729 (linux_kill, linux_detach): Clean up the process list.
19730 * remote-utils.c (remote_open): Improve port number parsing.
19731 (putpkt_binary, input_interrupt): Only send interrupts if the target
19732 is running.
19733 * server.c (extended_protocol): Make static.
19734 (attached): Define earlier.
19735 (exit_requested, response_needed, program_argv): New variables.
19736 (target_running): New.
19737 (start_inferior): Clear attached here.
19738 (attach_inferior): Set attached here.
19739 (require_running): Define.
19740 (handle_query): Use require_running and target_running. Implement
19741 "monitor exit".
19742 (handle_v_attach, handle_v_run): New.
19743 (handle_v_requests): Use require_running. Handle vAttach and vRun.
19744 (gdbserver_usage): Update.
19745 (main): Redo argument parsing. Handle --debug and --multi. Handle
19746 --attach along with other options or after the port. Save
19747 program_argv. Support no initial program. Resynchronize
19748 communication with GDB after an error. Handle "monitor exit".
19749 Use require_running and target_running. Always allow the extended
19750 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
19751 restart in extended mode.
19752 * README: Refer to the GDB manual. Update --attach usage.
19753
7407e2de
AS
197542007-12-20 Andreas Schwab <schwab@suse.de>
19755
19756 * linux-low.c (STACK_SIZE): Define.
19757 (linux_tracefork_child): Use it. Use __clone2 on ia64.
19758 (linux_test_for_tracefork): Likewise.
19759
b65d95c5
DJ
197602007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
19761
19762 * linux-low.c (linux_wait_for_event): Update messages. Do not
19763 reinsert auto-delete breakpoints.
19764 * mem-break.c (struct breakpoint): Change return type of handler to
19765 int.
19766 (set_breakpoint_at): Update handler type.
19767 (reinsert_breakpoint_handler): Return 1 instead of calling
19768 delete_breakpoint.
19769 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
19770 setting a new one.
19771 (check_breakpoints): Delete auto-delete breakpoints and return 2.
19772 * mem-break.h (set_breakpoint_at): Update handler type.
19773 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
19774 * win32-low.c (auto_delete_breakpoint): New.
19775 (get_child_debug_event): Use it.
19776
4e799345
DJ
197772007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
19778
19779 * configure.ac: Check for pread and pwrite.
19780 * hostio.c (handle_pread): Fall back to lseek and read.
19781 (handle_pwrite): Fall back to lseek and write.
19782 * config.in, configure: Regenerated.
19783
27524b67
DJ
197842007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
19785
19786 * server.c (myresume): Add own_buf argument.
19787 (main): Update calls.
19788
a20d5e98
DJ
197892007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
19790
19791 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
19792 * remote-utils.c (remote_open): Do not call disable_async_io.
19793 (block_async_io): Delete.
19794 (unblock_async_io): Make static.
19795 (initialize_async_io): New.
19796 * server.c (handle_v_cont): Handle async I/O here.
19797 (myresume): Likewise. Move other common resume tasks here...
19798 (main): ... from here. Call initialize_async_io. Disable async
19799 I/O before the main loop.
19800 * server.h (initialize_async_io): Declare.
19801 (block_async_io, unblock_async_io): Delete prototypes.
19802 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
19803
b79d787e
DJ
198042007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
19805
19806 * remote-utils.c (readchar): Allow binary data in received messages.
19807
d97903b2
PA
198082007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19809
19810 * win32-low.c (attaching): New global.
19811 (win32_create_inferior): Clear the `attaching' global.
19812 (win32_attach): Set the `attaching' global.
19813 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
19814 attaching. Only set a breakpoint at the entry point if not
19815 attaching.
19816
311de423
PA
198172007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19818
19819 * server.c (main): Don't report dll events on the initial
19820 connection on attaches.
19821
6c2d16d2
PA
198222007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19823
19824 * server.c (main): Relax numerical bases supported for the pid of
19825 the --attach command line argument.
19826
5ca906e6
PA
198272007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19828
19829 * win32-low.c (win32_attach): Call OpenProcess before
19830 DebugActiveProcess, not after. Add last error output to error
19831 call.
19832
9c6c8194
PA
198332007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
19834
19835 * win32-low.c (win32_get_thread_context)
19836 (win32_set_thread_context): New functions.
19837 (thread_rec): Use win32_get_thread_context.
19838 (continue_one_thread, win32_resume): Use win32_set_thread_context.
19839 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
19840 field.
19841
4d5d1aaa
PA
198422007-12-03 Leo Zayas
19843 Pedro Alves <pedro_alves@portugalmail.pt>
19844
19845 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
19846 global variables.
19847 (child_add_thread): Minor cleanup.
19848 (child_continue): Resume artificially suspended threads before
19849 calling ContinueDebugEvent.
19850 (suspend_one_thread): New.
19851 (fake_breakpoint_event): New.
19852 (get_child_debug_event): Change return type to int. Check here if
19853 gdb sent an interrupt request. If a soft interrupt was requested,
19854 fake a breakpoint event. Return 0 if there is no event to handle,
19855 and 1 otherwise.
19856 (win32_wait): Don't check here if gdb sent an interrupt request.
19857 Ensure there is a valid event to handle.
19858 (win32_request_interrupt): Add soft interruption method as last
19859 resort.
19860
c436e841
PA
198612007-12-03 Leo Zayas
19862 Pedro Alves <pedro_alves@portugalmail.pt>
19863
19864 * win32-low.h (win32_thread_info): Add descriptions to the
19865 structure members. Replace `suspend_count' counter by a
19866 `suspended' flag.
19867 * win32-low.c (thread_rec): Update condition of when to get the
19868 context from the inferior. Rely on ContextFlags being set if it
19869 has already been retrieved. Only suspend the inferior thread if
19870 we haven't already. Warn if that fails.
19871 (continue_one_thread): s/suspend_count/suspended/. Only call
19872 ResumeThread once. Warn if that fails.
19873
e7b5fa67
PA
198742007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
19875
19876 * win32-low.c (win32_wait): Don't read from the inferior when it
19877 has already exited.
19878
a385171d
PA
198792007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
19880
19881 * Makefile.in (win32_low_h): New variable.
19882 (win32-low.o): Add dependency on $(win32_low_h).
19883 (win32-arm-low.o, win32-i386-low.o): New rules.
19884
f80c84b3
DJ
198852007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
19886
19887 * hostio.c: Correct copyright year.
19888
a6b151f1
DJ
198892007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
19890
19891 * Makefile.in (OBS): Add hostio.o.
19892 (hostio.o): New rule.
19893 * server.h (handle_vFile): Declare.
19894 * hostio.c: New file.
19895 * server.c (handle_v_requests): Take packet_len and new_packet_len
19896 for binary packets. Call handle_vFile.
19897 (main): Update call to handle_v_requests.
19898
f9387fc3
DJ
198992007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
19900
19901 * linux-low.c: Include <sched.h>.
19902
51c2684e
DJ
199032007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
19904
19905 * linux-low.c (linux_tracefork_grandchild): New.
19906 (linux_tracefork_child): Use clone.
19907 (linux_test_for_tracefork): Use clone; allocate and free a stack.
19908
75f83163
JB
199092007-10-31 Joel Brobecker <brobecker@adacore.com>
19910
19911 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
19912
da5898ce
DJ
199132007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
19914
19915 * linux-low.c (handle_extended_wait): Handle unexpected signals.
19916
24a09b5f
DJ
199172007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
19918
19919 * inferiors.c (change_inferior_id): Delete.
19920 (add_pid_to_list, pull_pid_from_list): New.
19921 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
19922 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
19923 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
19924 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
19925 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
19926 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
19927 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
19928 (using_threads): Always set to 1.
19929 (handle_extended_wait): New.
19930 (add_process): Do not set TID.
19931 (linux_create_inferior): Set must_set_ptrace_flags.
19932 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
19933 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
19934 (linux_thread_alive): Rename TID argument to LWPID.
19935 (linux_wait_for_process): Handle unknown processes. Do not use TID.
19936 (linux_wait_for_event): Do not use TID or check using_threads. Update
19937 call to dead_thread_notify. Call handle_extended_wait.
19938 (linux_create_inferior): Use PTRACE_SETOPTIONS.
19939 (send_sigstop): Delete sigstop_sent.
19940 (wait_for_sigstop): Avoid TID.
19941 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
19942 (linux_test_for_tracefork): New.
19943 (linux_lookup_signals): Use thread_db_active and
19944 linux_supports_tracefork_flag.
19945 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
19946 * linux-low.h (get_process_thread): Avoid TID.
19947 (struct process_ifo): Move thread_known and tid to the end. Remove
19948 sigstop_sent.
19949 (linux_attach_lwp, thread_db_init): Update prototypes.
19950 * server.h (change_inferior_id): Delete prototype.
19951 (add_pid_to_list, pull_pid_from_list): New prototypes.
19952 * thread-db.c (thread_db_use_events): New.
19953 (find_first_thread): Rename to...
19954 (find_one_thread): ...this. Update callers and messages. Do not
19955 call fatal. Check thread_db_use_events. Do not call
19956 change_inferior_id or new_thread_notify.
19957 (maybe_attach_thread): Update. Do not call new_thread_notify.
19958 (thread_db_init): Set thread_db_use_events. Check use_events.
19959 * utils.c (fatal, warning): Correct message prefix.
19960
30ed0a8f
DJ
199612007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
19962
19963 * Makefile.in (clean): Remove new files.
19964 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
19965 (powerpc-64.o, powerpc-64.c): New rules.
19966 * configure.srv: Use alternate register sets for powerpc64-*-linux*
19967 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
19968 with SPE.
19969 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
19970 SPE targets.
19971 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
19972 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
19973 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
19974 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
19975 (target_regsets): Add AltiVec and SPE register sets.
19976 * configure.ac: Check for AltiVec and SPE.
19977 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
19978 (ppc_fill_vrregset, ppc_store_vrregset): New.
19979 (target_regsets): Add AltiVec register set.
19980 * configure: Regenerated.
19981
fd462a61
DJ
199822007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
19983
19984 * linux-low.c (O_LARGEFILE): Define.
19985 (linux_read_memory): Use /proc/PID/mem.
19986 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
19987 * configure, config.in: Regenerated.
19988
69f223ed
DJ
199892007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19990
19991 * linux-low.c (linux_wait_for_event): Do not pass signals while
19992 single-stepping.
19993
aec18585
PA
199942007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
19995
19996 * win32-low.c (create_process): New.
19997 (win32_create_inferior): Use create_process instead of
19998 CreateProcess. If create_process failed retry appending an ".exe"
19999 suffix. Store the GetLastError result immediatelly after
20000 create_process calls and use it on the call to error.
20001
34d86ddd
PA
200022007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20003
20004 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20005
5a0e3bd0
JB
200062007-08-23 Joel Brobecker <brobecker@adacore.com>
20007
20008 * configure.ac: Switch license to GPLv3.
20009
f88c79e6
MS
200102007-08-01 Michael Snyder <msnyder@access-company.com>
20011
20012 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20013
6b3d9b83
PA
200142007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20015
20016 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20017 typedef.
20018 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20019 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20020 CloseToolhelp32Snapshot.
20021 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20022 CloseToolhelp32Snapshot.
20023
c588c53c
MS
200242007-07-27 Michael Snyder <michael.snyder@access-company.com>
20025
20026 * server.c (main): Check for inferior exit before main loop.
20027
aa0403d9
PA
200282007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20029
20030 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20031 instead of on tmp_desc.
20032
255e7678
DJ
200332007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20034 Daniel Jacobowitz <dan@codesourcery.com>
20035
20036 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20037 (add_thread): Minor cleanups.
20038 (clear_inferiors): Move lower in the file. Clear the DLL
20039 list.
20040 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20041 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20042 (xml_escape_text): New.
20043 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20044 for qSupported.
20045 (handle_v_cont): Report errors.
20046 (gdbserver_version): Update.
20047 (main): Correct size of own_buf. Do not report initial DLL events.
20048 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20049 (unloaded_dll, xml_escape_text): New.
20050 * win32-low.c (enum target_waitkind): Update comments.
20051 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20052 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20053 (win32_EnumProcessModules, win32_GetModuleInformation)
20054 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20055 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20056 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20057 (win32_Module32First, win32_Module32Next, load_toolhelp)
20058 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20059 (get_child_debug_event): Handle DLL events.
20060 (win32_wait): Likewise.
20061
0d37add9
DJ
200622007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20063
20064 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20065 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20066
45e2715e
PA
200672007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20068
20069 * win32-low.c (handle_output_debug_string): Ignore event if not
20070 waiting.
20071
c5674cf1
PA
200722007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20073
20074 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20075
2bbe3cc1
DJ
200762007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20077
20078 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20079
ae13219e
DJ
200802007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20081
20082 * inferiors.c (change_inferior_id): Add comment.
20083 * linux-low.c (check_removed_breakpoint): Add an early
20084 prototype. Improve debug output.
20085 (linux_attach): Doc update.
20086 (linux_detach_one_process, linux_detach): Clean up before releasing
20087 each process.
20088 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20089 * linux-low.h (struct process_info): Doc improvement.
20090 * mem-break.c (delete_all_breakpoints): New.
20091 * mem-break.h (delete_all_breakpoints): New prototype.
20092 * thread-db.c (find_first_thread): New.
20093 (thread_db_create_event): Call it instead of
20094 thread_db_find_new_threads. Clean up unused variables.
20095 (maybe_attach_thread): Remove first thread handling.
20096 (thread_db_find_new_threads): Use find_first_thread.
20097 (thread_db_get_tls_address): Likewise.
20098
4105de34
DJ
200992007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20100
20101 * thread-db.c (thread_db_find_new_threads): Add prototype.
20102 (thread_db_create_event): Check for the main thread before adding
20103 a new thread.
20104 (maybe_attach_thread): Only enable event reporting if TID == 0.
20105 (thread_db_get_tls_address): Check for new threads.
20106
2b876972
DJ
201072007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20108
20109 * linux-low.c (linux_create_inferior): Try execv before execvp.
20110 * spu-low.c (spu_create_inferior): Likewise.
20111
7a245884
DJ
201122007-06-13 Mike Frysinger <vapier@gentoo.org>
20113
20114 * linux-low.c (linux_create_inferior): Change execv to execvp.
20115 * spu-low.c (spu_create_inferior): Likewies.
20116
117ce543
DJ
201172007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20118
20119 * Makefile.in (clean): Clean new files instead of deleted ones.
20120 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20121 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20122 rules.
20123 * configure.srv: Specify XML files and new regformats for MIPS and
20124 MIPS64 GNU/Linux.
20125 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20126 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20127 an entry for the restart register.
20128 (mips_cannot_fetch_register, mips_cannot_store_register)
20129 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20130 register names to match the XML descriptions.
20131 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20132 restart register instead of $0.
20133
0e7f50da
UW
201342007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20135 Markus Deuling <deuling@de.ibm.com>
20136
20137 * remote-utils.c (decode_xfer_write): New function.
20138 * server.h (decode_xfer_write): Add prototype.
20139 * server.c (handle_query): Add PACKET_LEN argument. Support
20140 qXfer:spu:read and qXfer:spu:write packets.
20141 (main): Pass packet_len to handle_query.
20142 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20143 * target.h (target_ops): Add qxfer_spu.
20144
374c1d38
UW
201452007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20146
20147 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20148 accessing non-seekable spufs files.
20149
bb63802a
UW
201502007-05-16 Markus Deuling <deuling@de.ibm.com>
20151
889bf7c5 20152 * server.c (handle_query): Add reply for qC packet.
bb63802a 20153
7390519e
PA
201542007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20155 Leo Zayas <lerele@champenstudios@com>
20156
20157 * server.h (check_remote_input_interrupt_request): New function.
20158 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20159 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20160 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20161 (check_remote_input_interrupt_request): New function.
20162 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 20163 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
20164 winapi_GenerateConsoleCtrlEvent): New typedefs.
20165 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20166 to 250 ms.
20167 (win32_wait): Check for remote interrupt request
20168 with check_remote_input_interrupt_request.
20169 (win32_request_interrupt): New function.
20170 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20171
34b34921
PA
201722007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20173
20174 * win32-low.c (debug_registers_changed,
20175 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20176 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20177 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20178 (thread_rec): Get context using the low target.
20179 (child_add_thread): Call thread_added on the low target,
20180 which does the same thing.
20181 (regptr): Delete.
20182 (do_initial_child_stuff): Remove debug registers references.
20183 Set context using the low target. Resume threads after
20184 setting the contexts.
20185 (child_continue): Remove dead variable. Remove debug
20186 registers references.
20187 (child_fetch_inferior_registers): Go through the low target.
20188 (do_child_store_inferior_registers): Remove.
20189 (child_store_inferior_registers): Go through the low target.
20190 (win32_resume): Remove debug registers references.
20191 Set context using the low target.
20192 (handle_exception): Change return type to void. Don't record
20193 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20194 first chance exception.
889bf7c5 20195 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
20196 goto loop. Always return after waiting for debug event.
20197 (win32_wait): Convert to switch statement. Handle spurious
20198 events.
20199
20200 * win32-i386-low.c (debug_registers_changed,
20201 debug_registers_used): New.
20202 (initial_stuff): Rename to ...
20203 (i386_initial_stuff): ... this. Clear debug registers
20204 state variables.
20205 (store_debug_registers): Delete.
20206 (i386_get_thread_context): New.
20207 (load_debug_registers): Delete.
20208 (i386_set_thread_context): New.
20209 (i386_thread_added): New.
20210 (single_step): Rename to ...
20211 (i386_single_step): ... this.
20212 (do_fetch_inferior_registers): Rename to ...
20213 (i386_fetch_inferior_register): ... this.
20214 (i386_store_inferior_register): New.
20215 (the_low_target): Adapt to new interface.
20216
20217 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20218 (arm_get_thread_context): New.
20219 (arm_set_thread_context): New.
20220 (regptr): New.
20221 (do_fetch_inferior_registers): Rename to ...
20222 (arm_fetch_inferior_register): ... this.
20223 (arm_store_inferior_register): New.
20224 (arm_wince_breakpoint): Reimplement as unsigned long.
20225 (arm_wince_breakpoint_len): Define.
20226 (the_low_target): Adapt to new interface.
20227
20228 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20229 load_debug_registers. Add get_thread_context, set_thread_context,
20230 thread_added and store_inferior_register. Rename
20231 fetch_inferior_registers to fetch_inferior_register.
20232 (regptr): Remove declaration.
20233
dd6953e1
PA
202342007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20235
20236 * linux-low.c (linux_detach): Change return type to int. Return 0.
20237 * spu-low.c (spu_detach): Likewise.
20238
444d6139
PA
202392007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20240
20241 * target.h (target_ops): Change return type of detach to int.
20242 Add join.
20243 (join_inferior): New.
20244 * server.c (main): Don't skip detach support on mingw32.
20245 If the inferior doesn't support detaching return error.
20246 Call join_inferior instead of using waitpid.
20247 * linux-low.c (linux_join): New.
20248 (linux_target_op): Add linux_join.
20249 * spu-low.c (spu_join): New.
20250 (spu_target_ops): Add spu_join.
20251 * win32-low.c (win32_detach): Adapt to new interface.
20252 Reopen current_process_handle before detaching. Issue a child
20253 resume before detaching.
20254 (win32_join): New.
20255 (win32_target_op): Add win32_join.
20256
1d5315fe
PA
202572007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20258
20259 * win32-low.c (win32-attach): Fix return value.
20260 * target.h (target_ops): Describe ATTACH return values.
20261
bf914831
PA
202622007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20263
20264 * win32-low.c (GETPROCADDRESS): Define.
20265 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20266 (winapi_DebugSetProcessKillOnExit): Likewise.
20267 (win32_create_inferior): Force usage of ansi CreateProcessA.
20268 (win32_attach): Use GETPROCADDRESS.
20269 (win32_detach): Likewise.
20270
f72f3e60
PA
202712007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20272
20273 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20274
ed50f18f
PA
202752007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20276
20277 * win32-low.c: Commit leftover changes from 2007-03-29.
20278
0c2ead7e
DJ
202792007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20280
20281 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20282 fields short instead of int. Add explicit padding.
20283 (i387_cache_to_fsave): Remove unnecessary casts.
20284 (i387_fsave_to_cache): Doc fix.
20285 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20286
73725ff3
DJ
202872007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20288
20289 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20290 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20291
d99f33d8
PA
202922007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20293
20294 * configure.srv (arm*-*-mingw32ce*): Move near the other
20295 arm targets.
20296
68070c10
PA
202972007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20298
2482afc6 20299 * configure.ac: Add errno checking.
68070c10
PA
20300 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20301 sys/file.h and malloc.h.
20302 (AC_CHECK_DECLS): Add perror.
20303 (srv_mingwce): Handle.
2482afc6 20304 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
20305 win32-i386-low.o to srv_tgtobj.
20306 (i[34567]86-*-mingw*): Likewise.
20307 (arm*-*-mingw32ce*): Add case.
20308 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20309 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20310 [__MINGW32CE__] (strerror): New function.
20311 [__MINGW32CE__] (errno): Define to GetLastError.
20312 [__MINGW32CE__] (COUNTOF): New macro.
20313 (remote_open): Remove extra close call.
20314 * mem-break.c (delete_breakpoint_at): New function.
20315 * mem-break.h (delete_breakpoint_at): Declare.
20316 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20317 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20318 [USE_WIN32API] (read, write): Add char* casts.
20319 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20320 * server.h: Include wincecompat.h on Windows CE.
20321 [HAVE_ERRNO_H]: Check.
20322 (perror): Declare if not declared.
20323 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20324 (perror_with_name): Remove errno declaration.
20325 * wincecompat.h: New.
20326 * wincecompat.c: New.
20327 * win32-low.h: New.
20328 * win32-arm-low.c: New.
20329 * win32-i386-low.c: New.
20330 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20331 (OUTMSG2): Make it safe.
20332 (_T): New macro.
20333 (COUNTOF): New macro.
20334 (NUM_REGS): Get it from the low target.
20335 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20336 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20337 (thread_rec): Let low target handle debug registers.
20338 (child_add_thread): Likewise.
20339 (child_init_thread_list): Likewise.
20340 (continue_one_thread): Likewise.
20341 (regptr): New.
20342 (do_child_fetch_inferior_registers): Move to ...
20343 * win32-i386-low.c: ... here, and rename to ...
20344 (do_fetch_inferior_registers): ... this.
889bf7c5 20345 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
20346 Go through the low target.
20347 (do_child_store_inferior_registers): Use regptr.
20348 (strwinerror): New function.
20349 (win32_create_inferior): Handle Windows CE.
20350 Use strwinerror instead of strerror on Windows error
20351 codes. Add program to the error output.
20352 Don't close the main thread handle on Windows CE.
20353 (win32_attach): Use coredll.dll on Windows CE.
20354 (win32_kill): Close current process and current
20355 thread handles.
20356 (win32_detach): Use coredll.dll on Windows CE.
20357 (win32_resume): Let low target handle debug registers, and
20358 step request.
20359 (handle_exception): Add/Remove initial breakpoint. Avoid
20360 non-existant WSTOPSIG on Windows CE.
20361 (win32_read_inferior_memory): Cast to remove warning.
20362 (win32_arch_string): Go through the low target.
20363 (initialize_low): Call set_breakpoint_data with the low
20364 target's breakpoint.
20365 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20366 FOP_REGNUM, mappings): Move to ...
20367 * win32-i386-low.c: ... here.
20368 * win32-low.c (win32_thread_info): Move to ...
20369 * win32-low.h: ... here.
20370 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20371 win32-arm-low.c and wincecompat.c.
20372 (all:): Add $EXEEXT.
20373 (install-only:): Likewise.
20374 (gdbserver:): Likewise.
20375 (gdbreplay:): Likewise.
20376 * config.in: Regenerate.
20377 * configure: Regenerate.
20378
41093d81
PA
203792007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20380
20381 * win32-low.c: Rename typedef thread_info to
20382 win32_thread_info throughout.
20383
544afa54
PA
203842007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20385
20386 * win32-i386-low.c: Rename to ...
20387 * win32-low.c: ... this.
20388 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20389 * Makefile.in: Likewise.
20390
bce7165d
PA
203912007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20392
20393 * remote-utils.c (monitor_output): Constify msg parameter.
20394 * server.h (monitor_output): Likewise.
20395 * win32-i386-low.c (handle_output_debug_string): New.
20396 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20397 handle_output_debug_string.
20398 (get_child_debug_event): Likewise.
20399
506c7aa0
DJ
204002007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20401
20402 * server.c (main): Correct strtoul check.
20403
42c81e2a
DJ
204042007-03-27 Jon Ringle <jon@ringle.org>
20405
20406 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20407
9453113a
DJ
204082007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20409
20410 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20411
64a69107
DJ
204122007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20413
20414 * terminal.h: Check HAVE_SGTTY_H.
20415
204162007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
20417
20418 * remote-utils.c (remote_open): Print out the assigned port number.
20419
c74d0ad8
DJ
204202007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20421
20422 * remote-utils.c (monitor_output): New function.
20423 * server.c (debug_threads): Define here.
20424 (monitor_show_help): New function.
20425 (handle_query): Handle qRcmd.
20426 (main): Do not handle 'd' packet.
20427 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20428 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20429 of debug_threads.
20430
de7c3b4a
PA
204312007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20432
20433 * Makefile.in (EXEEXT): New.
20434 (clean): Use $(EXEEXT).
20435
ef57601b
PA
204362007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20437
20438 * target.h (target_ops): Rename send_signal to request_interrupt,
20439 and remove enum target_signal parameter.
20440 * linux-low.c (linux_request_interrupt): Rename from
20441 linux_send_signal, and always send SIGINT.
20442 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20443 and always send SIGINT.
20444 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20445 of send_signal.
20446 (input_interrupt): Likewise.
20447
820f2bda
PA
204482007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20449
20450 * server.c (get_features_xml): Check if target implemented
20451 arch_string.
20452 * win32-i386-low.c (win32_arch_string): New.
20453 (win32_target_ops): Add win32_arch_string as arch_string member.
20454
ab39bf24
UW
204552007-02-22 Markus Deuling <deuling@de.ibm.com>
20456
20457 * spu-low.c (spu_arch_string): New.
20458 (spu_target_ops): Add spu_arch_string.
20459
61ff6e04
DJ
204602007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20461
20462 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20463 * configure.ac: Do not check for terminal.h.
20464 * configure, config.in: Regenerated.
20465
fb1e4ffc
DJ
204662007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20467
20468 * Makefile.in (OBS): Add $(XML_BUILTIN).
20469 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20470 (clean): Update.
20471 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20472 (arm-with-iwmmxt.c): New.
20473 * config.in, configure: Regenerate.
20474 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20475 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20476 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20477 (arm*-*-linux*): Add iWMMXt and regset support.
20478 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20479 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20480 (arm_store_wmmxregset, target_regsets): New.
20481 * server.c (get_features_xml): Take annex argument. Check builtin
20482 XML documents.
20483 (handle_query): Handle multiple annexes.
20484
0f48aa01
DJ
204852007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20486
20487 * remote-utils.c [USE_WIN32API] (read, write): Define.
20488 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20489 write.
20490
23181151
DJ
204912007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20492
20493 * linux-i386-low.c (the_low_target): Set arch_string.
20494 * linux-x86-64-low.c (the_low_target): Likewise.
20495 * linux-low.c (linux_arch_string): New.
20496 (linux_target_ops): Add it.
20497 * linux-low.h (struct linux_target_ops): Add arch_string.
20498 * server.c (write_qxfer_response): Use const void * for DATA.
20499 (get_features_xml): New.
20500 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20501 * target.h (struct target_ops): Add arch_string method.
20502
9d606399
DJ
205032007-01-03 Denis Pilat <denis.pilat@st.com>
20504 Daniel Jacobowitz <dan@codesourcery.com>
20505
20506 * linux-low.c (linux_kill): Handle being called with no threads.
20507 * win32-i386-low.c (win32_kill): Likewise.
20508 (get_child_debug_event): Clear current_process_handle.
20509
205102006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
20511 Daniel Jacobowitz <dan@codesourcery.com>
20512
20513 * remote-utils.c (remote_open): Check the type of specified
20514 serial port devices before opening them.
20515 * server.c (main): Kill the inferior if an error occurs during
20516 the first remote_open.
20517
a5e13d24
DJ
205182006-12-05 Markus Deuling <deuling@de.ibm.com>
20519
20520 * README: Update supported targets.
20521
186947f7
DJ
205222006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20523
20524 * Makefile.in (clean): Remove reg-mips64.c.
20525 (reg-mips64.c, reg-mips64.o): New rules.
20526 * configure.srv: Handle mips64. Include regset support for mips.
20527 * linux-mips-low.c (union mips_register): New.
20528 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20529 (mips_breakpoint, mips_breakpoint_at): Use int.
20530 (mips_collect_register, mips_supply_register)
20531 (mips_collect_register_32bit, mips_supply_register_32bit)
20532 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20533 (mips_store_fpregset, target_regsets): New.
20534 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20535
a13e2c95
UW
205362006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20537
20538 * configure.srv: Add target "spu*-*-*".
20539 * Makefile.in (clean): Remove reg-spu.c.
20540 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20541 * spu-low.c: New file.
20542
cb7283db
DJ
205432006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20544
20545 * configure.ac: Correct td_thr_tls_get_addr test.
20546 * configure: Regenerated.
20547
89be2091
DJ
205482006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20549
20550 * linux-low.c (linux_wait_for_event): Reformat. Use the
20551 pass_signals array.
20552 * remote-utils.c (decode_address_to_semicolon): New.
20553 * server.c (pass_signals, handle_general_set): New.
20554 (handle_query): Mention QPassSignals for qSupported.
20555 (main): Call handle_general_set.
20556 * server.h (pass_signals, decode_address_to_semicolon): New.
20557
000ef4f0
DJ
205582006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20559
20560 * server.c (handle_query): Correct error handling for read_auxv.
20561
b7149293
UW
205622005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20563
20564 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20565 and srv_linux_thread_db to yes.
20566 * linux-s390-low.c (s390_fill_gregset): New function.
20567 (target_regsets): Define data structure.
20568
dae5f5cf
DJ
205692006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20570
20571 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20572 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20573 * config.in, configure: Regenerated.
20574 * inferiors.c (gdb_id_to_thread): New function.
20575 (gdb_id_to_thread_id): Use it.
20576 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20577 * linux-low.h (struct process_info): Add th member.
20578 (thread_db_get_tls_address): New prototype.
20579 * remote-utils.c (decode_address): Make non-static.
20580 * server.c (handle_query): Handle qGetTLSAddr.
20581 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20582 * target.h (struct target_ops): Add get_tls_address.
20583 * thread-db.c (maybe_attach_thread): Save the thread handle.
20584 (thread_db_get_tls_address): New.
20585
32ca6d61
DJ
205862006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20587
20588 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20589 (linux_resume_one_process): Take a siginfo_t *. Update all
20590 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20591 (struct pending_signals): Add a siginfo_t.
20592 (linux_wait_for_process): Always set last_status.
20593 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20594 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20595 * linux-low.h (struct process_info): Add last_status.
20596
5ffff7c1
DJ
205972006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20598
20599 * remote-utils.c (try_rle): New function.
20600 (putpkt_binary): Use it.
20601
8695c747
DJ
206022006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20603
20604 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20605 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20606 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20607 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20608 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20609 point registers.
20610
290fadea
RS
206112006-08-08 Richard Sandiford <richard@codesourcery.com>
20612
20613 * server.c (terminal_fd): New variable.
20614 (old_foreground_pgrp): Likewise.
20615 (restore_old_foreground_pgrp): New function.
20616 (start_inferior): Record the terminal file descriptor in terminal_fd
20617 and its original foreground group in old_foreground_pgrp. Register
20618 restore_old_foreground_pgrp with atexit().
20619
9f2e1e63
DJ
206202006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20621
20622 * server.c (handle_query): Correct qPart to qXfer.
20623
b80864fb
DJ
206242006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20625
20626 * configure.ac: Check for more headers which are missing on
20627 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20628 * configure.srv: Add Cygwin and mingw32.
20629 * remote-utils.c: Don't include headers unconditionally which
20630 are missing on mingw32. Include <winsock.h> for mingw32.
20631 (remote_open): Adjust for mingw32 support. Flush
20632 standard error after writing to it.
20633 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20634 (unblock_async_io, enable_async_io, disable_async_io)
20635 (readchar, getpkt): Update for Winsock support.
20636 (prepare_resume_reply): Expect a protocol signal number.
20637 * server.c: Disable <sys/wait.h> on mingw32.
20638 (start_inferior): Adjust for mingw32 support. Flush
20639 standard error after writing to it.
20640 (attach_inferior): Likewise. Use protocol signal
20641 numbers.
20642 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20643 and names.
20644 * win32-i386-low.c: New file.
20645 * Makefile.in (XM_CLIBS): Set.
20646 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20647 (win32-i386-low.o): New dependency rule.
20648 * linux-low.c (linux_wait): Use target signal numbers.
20649 * target.h (struct target_ops): Doc fix.
20650 * server.h (target_signal_to_name): New prototype.
20651 * gdbreplay.c: Don't include headers unconditionally which
20652 are missing on mingw32. Include <winsock.h> for mingw32.
20653 (remote_close, remote_open): Adjust for Winsock support.
20654 * configure, config.in: Regenerated.
20655
0876f84a
DJ
206562006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20657
20658 * server.c (decode_xfer_read, write_qxfer_response): New.
20659 (handle_query): Take a packet length argument. Handle
20660 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20661 the qSupported response.
20662 (main): Update call to handle_query.
20663
01f9e8fa
DJ
206642006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20665
20666 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20667 (putpkt_binary): Renamed from putpkt and adjusted for binary
20668 data.
20669 (putpkt): New wrapper for putpkt_binary.
20670 (readchar): Don't mask off the high bit.
20671 (decode_X_packet): New function.
20672 * server.c (main): Call putpkt_binary if a handler sets the packet
20673 length. Save the length of the incoming packet. Handle 'X'.
20674 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20675
be2a5f71
DJ
206762006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20677
20678 * server.c (handle_query): Handle qSupported.
20679
ea025f5f
DJ
206802006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20681
20682 * remote-utils.c (all_symbols_looked_up): New variable.
20683 (look_up_one_symbol): Check it.
20684 * server.h (look_up_one_symbol): New declaration.
20685 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20686
9308fc88
DJ
206872006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20688
20689 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 20690 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
20691 (PTRACE_GET_THREAD_AREA): Define.
20692 (ps_get_thread_area): New function.
20693
52fb6437
NS
206942006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20695
20696 * configure.srv (m68k*-*-uclinux*): New target.
20697 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20698 (linux_resume_one_process): Remove extraneous cast.
20699 (linux_read_offsets): New.
20700 (linux_target_op): Add linux_read_offsets on mmuless systems.
20701 * server.c (handle_query): Add qOffsets logic.
20702 * target.h (struct target_ops): Add read_offsets.
20703
21b0f40c
DJ
207042006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20705
20706 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20707 (PTRACE_GET_THREAD_AREA): Define.
20708 (ps_get_thread_area): New function.
20709 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20710 (linux-x86-64-low.o): Update.
20711
0050a760
DJ
207122006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20713
20714 * configure.ac: Remove checks for prfpregset_t.
20715 * gdb_proc_service.h: New file.
20716 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20717 new "gdb_proc_service.h".
20718 * proc-service.c: Likewise.
20719 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20720 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20721 * Makefile.in (gdb_proc_service_h): Updated.
20722 * configure, config.in: Regenerated.
20723
b92a518e
DJ
207242006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20725
20726 * remote-utils.c (prepare_resume_reply): Move declaration
20727 of gdb_id_from_wait to the top of the block.
20728
545587ee
DJ
207292006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
20730
20731 * linux-low.c (regsets_store_inferior_registers): Read the regset
20732 from the target before filling it.
20733
9db87ebd
DJ
207342006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20735
20736 * server.c (attach_inferior): Return SIGTRAP for a successful
20737 attach.
20738
dd24457d
DJ
207392006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
20740
20741 * Makefile.in (OBS): Add version.o.
20742 (STAGESTUFF): Delete.
20743 (version.o): Add dependencies.
20744 (version.c): Replace rule.
20745 (clean): Remove version.c.
20746 * server.c (gdbserver_version): New.
20747 (gdbserver_usage): Use printf.
20748 (main): Handle --version and --help.
20749 * server.h (version, host_name): Add declarations.
20750
6f0f660e
EZ
207512005-12-23 Eli Zaretskii <eliz@gnu.org>
20752
889bf7c5
PA
20753 * linux-arm-low.c:
20754 * linux-arm-low.c:
20755 * inferiors.c:
20756 * i387-fp.h:
20757 * i387-fp.c:
20758 * gdbreplay.c:
20759 * regcache.c:
20760 * proc-service.c:
20761 * mem-break.h:
20762 * mem-break.c:
20763 * linux-x86-64-low.c:
20764 * linux-sh-low.c:
20765 * linux-s390-low.c:
20766 * linux-ppc64-low.c:
20767 * linux-ppc-low.c:
20768 * linux-mips-low.c:
20769 * linux-m68k-low.c:
20770 * linux-m32r-low.c:
20771 * linux-low.h:
20772 * linux-low.c:
20773 * linux-ia64-low.c:
20774 * linux-i386-low.c:
20775 * linux-crisv32-low.c:
20776 * thread-db.c:
20777 * terminal.h:
20778 * target.h:
20779 * target.c:
20780 * server.h:
20781 * server.c:
20782 * remote-utils.c:
20783 * regcache.h:
20784 * utils.c:
20785 * Makefile.in:
20786 * configure.ac:
6f0f660e
EZ
20787 * gdbserver.1: Add (C) after Copyright. Update the FSF
20788 address.
20789
9d1fb177
DJ
207902005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
20791
20792 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
20793 (arm_breakpoint_at): Recognize both breakpoints.
20794 (the_low_target): Use the correct breakpoint instruction.
20795
011a70c2
DJ
207962005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
20797
20798 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
20799 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
20800 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
20801 (the_low_target): Update.
20802
7fb85e41
AS
208032005-10-25 Andreas Schwab <schwab@suse.de>
20804
20805 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
20806
20807 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
20808 (ia64_num_regs): Reduce to 462.
20809
3db0444b
DJ
208102005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
20811
20812 * acinclude.m4: Correct quoting.
20813 * aclocal.m4: Regenerated.
20814
20815 Suggested by SZOKOVACS Robert <szo@ies.hu>:
20816 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
20817 (thread_db_init): Call thread_db_err_str.
20818 * configure.ac: Check for TD_VERSION.
20819 * config.in, configure: Regenerated.
20820
bee0189a
DJ
208212005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
20822
20823 * server.h (error, fatal, warning): Add ATTR_FORMAT.
20824
e9d25b98
DJ
208252005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20826
20827 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
20828 is not available. Define HAVE_PTRACE_GETREGS if it is.
20829 * config.in, configure: Regenerated.
20830 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
20831 * linux-i386-low.c, linux-m68k-low.c: Update to use
20832 HAVE_PTRACE_GETREGS.
20833 * linux-low.c (regsets_fetch_inferior_registers)
20834 (regsets_store_inferior_registers): Only return 0 if we processed
20835 GENERAL_REGS.
20836 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
20837 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
20838
a06660f7
DJ
208392005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20840
20841 * inferiors.c (struct thread_info): Add gdb_id.
20842 (add_thread): Add gdb_id argument.
20843 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
20844 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
20845 calls to add_thread.
20846 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
20847 * server.c (handle_query): Use thread_to_gdb_id.
20848 (handle_v_cont, main): Use gdb_id_to_thread_id.
20849 * server.h (add_thread): Update prototype.
20850 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
20851 prototypes.
20852
5a1f5858
DJ
208532005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
20854
20855 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
20856 left-padded registers.
20857 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
20858 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
20859
e122f1f5
SE
208602005-07-01 Steve Ellcey <sje@cup.hp.com>
20861
20862 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
20863 * configure: Regenerate.
20864 * config.in: Regenerate.
20865 * server.h (NEED_DECLARATION_STRERROR):
20866 Replace with !HAVE_DECL_STRERROR.
20867
d592fa2f
DJ
208682005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
20869
20870 * linux-low.c (linux_wait, linux_send_signal): Don't test
20871 an unsigned long variable for > 0 if it could be MAX_ULONG.
20872 * server.c (myresume): Likewise.
20873 * target.c (set_desired_inferior): Likewise.
20874
ccbd4912
MK
208752005-06-13 Mark Kettenis <kettenis@gnu.org>
20876
20877 * configure.ac: Simplify and improve check for socklen_t.
20878 * configure, config.in: Regenerate.
20879
f450004a
DJ
208802005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
20881
20882 * acconfig.h: Remove.
20883 * configure.ac: Add a test for socklen_t. Use three-argument
20884 AC_DEFINE throughout.
20885 * config.in: Regenerated using autoheader 2.59.
20886 * configure: Regenerated.
20887
20888 * gdbreplay.c (socklen_t): Provide a default.
20889 (remote_open): Use socklen_t.
20890 * remote-utils.c (socklen_t): Provide a default.
20891 (remote_open): Use socklen_t.
20892 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
20893 unsigned char.
20894
20895 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
20896 char for buffers.
20897 * linux-low.c (linux_read_memory, linux_write_memory)
20898 (linux_read_auxv): Likewise.
20899 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
20900 (check_mem_write): Likewise.
20901 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
20902 Likewise.
20903 * regcache.c (struct inferior_rgcache_data, registers_to_string)
20904 (registers_from_string, register_data): Likewise.
20905 * server.c (handle_query, main): Likewise.
20906 * server.h (convert_ascii_to_int, convert_int_to_ascii)
20907 (decode_M_packet): Likewise.
20908 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
20909 * target.h (struct target_ops): Update read_memory, write_memory,
20910 and read_auxv.
20911 (read_inferior_memory, write_inferior_memory): Update.
20912 * linux-low.h (struct linux_target_ops): Change type of breakpoint
20913 to unsigned char *.
20914 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
20915 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
20916 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
20917 linux-s390-low.c, linux-sh-low.c: Update for changes in
20918 read_inferior_memory and the_low_target->breakpoint.
20919
eee84df1
DJ
209202005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
20921
20922 * Makefile.in (SFILES): Add linux-ppc64-low.c.
20923 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
20924 * configure.srv: Add powerpc64-*-linux*.
20925 * linux-ppc64-low.c: New file.
20926
45b134e5
OF
209272005-05-23 Orjan Friberg <orjanf@axis.com>
20928
20929 * linux-cris-low.c: New file with support for CRIS.
20930 * linux-crisv32-low.c: Ditto for CRISv32.
20931 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
20932 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 20933 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
20934 reg-crisv32.o, and reg-crisv32.c to make rules.
20935 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
20936 recognized targets.
20937
48d93c75
UW
209382005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
20939
20940 * linux-low.c (fetch_register): Ensure buffer size is a multiple
20941 of sizeof (PTRACE_XFER_TYPE).
20942 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
20943
e013ee27
OF
209442005-05-12 Orjan Friberg <orjanf@axis.com>
20945
889bf7c5 20946 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
20947 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
20948 pointers for hardware watchpoint support.
20949 * linux-low.h (struct linux_target_ops): Ditto.
20950 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
20951 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
20952 to linux_target_ops.
20953 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
20954 reply packet.
20955 * server.c (main): Recognize 'Z' and 'z' packets.
20956
b0ded00b
UW
209572005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
20958
20959 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
20960 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
20961 (the_low_target): Add new members.
20962
8643e2ad
DJ
209632005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
20964
20965 * proc-service.c (ps_lgetregs): Search all_processes instead of
20966 all_threads.
20967
fc620387
DJ
209682005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
20969
20970 * server.c (start_inferior): Change return type to int.
20971 (attach_inferior): Change sigptr to int *.
20972 (handle_v_cont, handle_v_requests): Change signal to int *.
20973 (main): Change signal to int.
20974
209752005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
20976
20977 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
20978 * configure.srv: Add m32r*-*-linux*.
20979 * linux-m32r-low.c: New file.
20980
e0e76420
DJ
209812005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
20982
20983 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
20984
a1928bad
DJ
209852005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20986
20987 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
20988 Take unsigned long arguments for PIDs.
20989 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
20990 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
20991 (wait_for_sigstop, linux_resume_one_process)
20992 (regsets_fetch_inferior_registers, linux_send_signal)
20993 (linux_read_auxv): Likewise. Update the types of variables holding
20994 PIDs. Update format string specifiers.
20995 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
20996 * remote-utils.c (prepare_resume_reply): Likewise.
20997 * server.c (cont_thread, general_thread, step_thread)
20998 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
20999 unsigned long.
21000 (handle_query): Update format specifiers.
21001 (handle_v_cont, main): Use strtoul for thread IDs.
21002 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21003 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21004 (general_thread, step_thread, thread_from_wait)
21005 (old_thread_from_wait): Update.
21006 * target.h (struct thread_resume): Use unsigned long for THREAD.
21007 (struct target_ops): Use unsigned long for arguments to attach and
21008 thread_alive.
21009
dcdb98d2
DJ
210102005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21011
21012 * acinclude.m4: Include bfd/bfd.m4 directly.
21013 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21014 <agriffis@toolchain.org>.
21015 * aclocal.m4, configure: Regenerated.
21016
bec39cab
AC
210172005-01-07 Andrew Cagney <cagney@gnu.org>
21018
21019 * configure.ac: Rename configure.in, require autoconf 2.59.
21020 * configure: Re-generate.
21021
434c4c77
DJ
210222004-12-08 Daniel Jacobowitz <dan@debian.org>
21023
21024 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21025 LIBS when finished.
21026 * aclocal.m4: Regenerated.
21027 * configure: Regenerated.
21028
db1d3e1b
AS
210292004-11-21 Andreas Schwab <schwab@suse.de>
21030
21031 * linux-m68k-low.c (m68k_num_gregs): Define.
21032 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21033 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21034 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21035 (m68k_breakpoint_at): New. Add to the_low_target.
21036
21037 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21038 srv_linux_thread_db to yes.
21039
43360365
JB
210402004-10-20 Joel Brobecker <brobecker@gnat.com>
21041
21042 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21043 (ARCH_SET_FS): Likewise.
21044 (ARCH_GET_FS): Likewise.
21045 (ARCH_GET_GS): Likewise.
21046
fd500816
DJ
210472004-10-16 Daniel Jacobowitz <dan@debian.org>
21048
21049 * linux-i386-low.c (ps_get_thread_area): New.
21050 * linux-x86-64-low.c (ps_get_thread_area): New.
21051 * linux-low.c: Include <sys/syscall.h>.
21052 (linux_kill_one_process): Don't kill the first thread here.
21053 (linux_kill): Kill the first thread here.
21054 (kill_lwp): New function.
21055 (send_sigstop, linux_send_signal): Use it.
21056 * proc-service.c: Clean up #ifdefs.
21057 (fpregset_info): Delete.
21058 (ps_lgetregs): Update and enable implementation.
21059 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21060 implementations.
21061 * remote-utils.c (struct sym_cache, symbol_cache): New.
21062 (input_interrupt): Print a clearer message.
21063 (async_io_enabled): New variable.
21064 (enable_async_io, disable_async_io): Use it. Update comments.
21065 (look_up_one_symbol): Use the symbol cache.
21066 * thread-db.c (thread_db_look_up_symbols): New function.
21067 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21068
f6de3c42
DJ
210692004-10-16 Daniel Jacobowitz <dan@debian.org>
21070
21071 * configure.in: Test for -rdynamic.
21072 * configure: Regenerated.
21073 * Makefile (INTERNAL_LDFLAGS): New.
21074 (gdbserver, gdbreplay): Use it.
21075
2c0fc042
AC
210762004-09-02 Andrew Cagney <cagney@gnu.org>
21077
21078 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21079
075b3282
DJ
210802004-03-23 Daniel Jacobowitz <drow@mvista.com>
21081
21082 * linux-low.c (linux_wait): Clear all_processes list also.
21083
fa6a77dc
DJ
210842004-03-12 Daniel Jacobowitz <drow@mvista.com>
21085
21086 * linux-low.c: Include <errno.h>. Remove extern declaration of
21087 errno.
21088
6d782a97
DJ
210892004-03-12 Daniel Jacobowitz <drow@mvista.com>
21090
21091 * gdbreplay.c, server.h, utils.c: Update copyright years.
21092
3a7fb99b
DJ
210932004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21094
21095 * server.c (main): Print child status or termination signal from
21096 variable 'signal', not 'sig'.
21097
c3e735a6
DJ
210982004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21099
21100 * linux-low.c (linux_read_memory): Change return type to
21101 int. Check for and return error from ptrace().
21102 * target.c (read_inferior_memory): Change return type to int. Pass
21103 back return status from the_target->read_memory().
21104 * target.h (struct target_ops): Adapt *read_memory() prototype.
21105 Update comment.
21106 (read_inferior_memory): Adapt prototype.
21107 * server.c (main): Return an error packet if
21108 read_inferior_memory() returns an error.
21109
a59d1c82
DJ
211102004-03-04 Daniel Jacobowitz <drow@mvista.com>
21111
21112 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21113 Unify with other clean targets.
21114
dc3f8883
DJ
211152004-02-29 Daniel Jacobowitz <drow@mvista.com>
21116
21117 * server.c (handle_v_cont): Call set_desired_inferior.
21118
89a208da
DJ
211192004-02-29 Daniel Jacobowitz <drow@mvista.com>
21120
21121 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21122
62ea82f5
DJ
211232004-02-29 Daniel Jacobowitz <drow@mvista.com>
21124
21125 * linux-low.c (linux_wait): Unblock async I/O.
21126 (linux_resume): Block and enable async I/O.
21127 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21128 * server.h (block_async_io, unblock_async_io): Add prototypes.
21129
6910d122
DJ
211302004-02-29 Daniel Jacobowitz <drow@mvista.com>
21131
21132 * remote-utils.c (remote_open): Print a status notice after
21133 opening a TCP port.
21134 * server.c (attach_inferior): Print a status notice after
21135 attaching.
21136
211372004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
21138
21139 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21140
c89dc5d4
DJ
211412004-02-26 Daniel Jacobowitz <drow@mvista.com>
21142
21143 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21144 error packet.
21145 * server.c, target.h: Update copyright years.
21146
4b8dad4a
RM
211472004-02-25 Roland McGrath <roland@redhat.com>
21148
21149 * target.h (struct target_ops): New member `read_auxv'.
21150 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21151 * linux-low.c (linux_read_auxv): New function.
21152 (linux_target_ops): Initialize `read_auxv' member to that.
21153
d7446758
JB
211542004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21155
21156 Committed by Jim Blandy <jimb@redhat.com>.
21157
21158 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 21159 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
21160 instead of GPR_SIZE to distiguish s390 and s390x targets.
21161
5544ad89
DJ
211622004-01-31 Daniel Jacobowitz <drow@mvista.com>
21163
21164 * linux-low.c: Update copyright year.
21165 (check_removed_breakpoint): Clear pending_is_breakpoint.
21166 (linux_set_resume_request, linux_queue_one_thread)
21167 (resume_status_pending_p): New functions.
21168 (linux_continue_one_thread): Use process->resume.
21169 (linux_resume): Only resume threads if there are no pending events.
21170 * linux-low.h (struct process_info): Add resume request
21171 pointer.
21172
2a68b70e
DJ
211732004-01-30 Daniel Jacobowitz <drow@mvista.com>
21174
21175 * regcache.c (new_register_cache): Clear the allocated register
21176 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21177
64386c31
DJ
211782003-10-13 Daniel Jacobowitz <drow@mvista.com>
21179
21180 * linux-low.c (linux_resume): Take a struct thread_resume *
21181 argument.
21182 (linux_wait): Update call.
21183 (resume_ptr): New static variable.
21184 (linux_continue_one_thread): Renamed from
21185 linux_continue_one_process. Use resume_ptr.
21186 (linux_resume): Use linux_continue_one_thread.
21187 * server.c (handle_v_cont, handle_v_requests): New functions.
21188 (myresume): New function.
21189 (main): Handle 'v' case.
21190 * target.h (struct thread_resume): New type.
21191 (struct target_ops): Change argument of "resume" to struct
21192 thread_resume *.
21193 (myresume): Delete macro.
21194
c938e9b0
L
211952003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21196
21197 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21198 (uninstall): Support DESTDIR.
21199
7f313d07
BC
21200Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21201
21202 * configure.srv: Add xscale*linux copy of arm*linux entry.
21203
3b2fc2ea
DJ
212042003-07-24 Daniel Jacobowitz <drow@mvista.com>
21205
21206 * linux-arm-low.c (arm_reinsert_addr): New function.
21207 (the_low_target): Add arm_reinsert_addr.
21208
1c0a559e
MK
212092003-07-08 Mark Kettenis <kettenis@gnu.org>
21210
21211 * mem-break.c: Remove whitespace at end of file.
21212
43d5792c
DJ
212132003-06-28 Daniel Jacobowitz <drow@mvista.com>
21214
21215 * configure.in: Check whether we need to prototype strerror.
21216 * server.h: Optionally prototype strerror.
21217 * gdbreplay.c (perror_with_name): Use strerror.
21218 * linux-low.c (linux_attach_lwp): Use strerror.
21219 * utils.c (perror_with_name): Use strerror.
21220 * config.in, configure: Regenerated.
21221
c8a86edf
DJ
212222003-06-28 Daniel Jacobowitz <drow@mvista.com>
21223
21224 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21225 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21226
73d37363
DJ
212272003-06-20 Daniel Jacobowitz <drow@mvista.com>
21228
21229 * Makefile.in (SFILES): Update.
21230 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21231 low-sun3.c: Remove files.
21232
6ad8ae5c
DJ
212332003-06-17 Daniel Jacobowitz <drow@mvista.com>
21234
21235 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21236 (linux_detach_one_process, linux_detach): New functions.
21237 (linux_target_ops): Add linux_detach.
21238 * server.c (main): Handle 'D' packet.
21239 * target.h (struct target_ops): Add "detach" member.
21240 (detach_inferior): Define.
21241
1581182a
MK
212422003-06-13 Mark Kettenis <kettenis@gnu.org>
21243
21244 From Kelley Cook <kelleycook@wideopenwest.com>:
21245 * configure.srv: Accept i[34567]86 variants.
21246
e5379b03
DJ
212472003-06-05 Daniel Jacobowitz <drow@mvista.com>
21248
21249 * linux-low.c (linux_wait_for_event): Correct comment typos.
21250 (linux_resume_one_process): Call check_removed_breakpoint.
21251 (linux_send_signal): New function.
21252 (linux_target_ops): Add linux_send_signal.
21253 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21254 of kill.
21255 * target.h (struct target_ops): Add send_signal.
21256
2ff29de4
JB
212572003-05-29 Jim Blandy <jimb@redhat.com>
21258
21259 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21260 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21261 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21262 away part of the register's value.
21263
254787d4
DJ
212642003-03-26 Daniel Jacobowitz <drow@mvista.com>
21265
21266 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21267 (linux_wait_for_event, linux_init_signals): Likewise.
21268
94e10508
DJ
212692003-03-17 Daniel Jacobowitz <drow@mvista.com>
21270
21271 * configure.in: Check for stdlib.h.
21272 * configure: Regenerated.
21273 * config.in: Regenerated.
21274
4c0711e0
DJ
212752003-01-04 Andreas Schwab <schwab@suse.de>
21276
21277 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21278
ef66e766
AC
212792003-01-02 Andrew Cagney <ac131313@redhat.com>
21280
21281 * Makefile.in: Remove obsolete code.
21282
a1358604
DJ
212832002-11-20 Daniel Jacobowitz <drow@mvista.com>
21284
21285 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21286 defined(PT_FPR0_HI).
21287
23ce3b1c
DJ
212882002-11-17 Stuart Hughes <seh@zee2.com>
21289
21290 * linux-arm-low.c (arm_num_regs): Increase.
21291 (arm_regmap): Include status register.
21292
212932002-11-17 Daniel Jacobowitz <drow@mvista.com>
21294
21295 * linux-low.c (register_addr): Remove incorrect -1 check.
21296
a9fa9f7d
DJ
212972002-08-29 Daniel Jacobowitz <drow@mvista.com>
21298
21299 * linux-low.c (linux_create_inferior): Call setpgid. Return
21300 the new PID.
21301 (unstopped_p, linux_signal_pid): Remove.
21302 (linux_target_ops): Remove linux_signal_pid.
21303 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21304 global instead of target method.
21305 * target.h (struct target_ops): Remove signal_pid. Update comment
21306 for create_inferior.
21307 * server.c (signal_pid): New variable.
21308 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 21309 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
21310 (attach_inferior): Set signal_pid.
21311
17574093
DJ
213122002-08-23 Daniel Jacobowitz <drow@mvista.com>
21313
21314 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21315
213162002-08-20 Jim Blandy <jimb@redhat.com>
21317
21318 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21319 default for this.
21320
213212002-08-01 Andrew Cagney <cagney@redhat.com>
21322
21323 * Makefile.in: Make chill references obsolete.
21324
213252002-07-24 Kevin Buettner <kevinb@redhat.com>
21326
21327 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21328 * configure: Regenerate.
21329 * config.in: Regenerate.
21330
213312002-07-09 David O'Brien <obrien@FreeBSD.org>
21332
21333 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21334 (perror_with_name, remote_close, remote_open, expect, play): Static.
21335
213362002-07-04 Michal Ludvig <mludvig@suse.cz>
21337
4b8dad4a 21338 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
21339 byte offsets instead of an array of indexes.
21340 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21341
213422002-06-13 Daniel Jacobowitz <drow@mvista.com>
21343
21344 * regcache.c: Add comment.
21345
213462002-06-11 Daniel Jacobowitz <drow@mvista.com>
21347
21348 * thread-db.c: New file.
21349 * proc-service.c: New file.
21350 * acinclude.m4: New file.
21351 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21352 proc-service.o, and thread-db.o.
21353 (linux-low.o): Add USE_THREAD_DB.
21354 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21355 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21356 * aclocal.m4: Regenerated.
21357 * config.in: Regenerated.
21358 * configure: Regenerated.
21359 * configure.in: Check for proc_service.h, sys/procfs.h,
21360 thread_db.h, and linux/elf.h headrs.
21361 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21362 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21363 Check for -lthread_db and thread support.
21364 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21365 PowerPC, and SuperH.
21366 * i387-fp.c: Constify arguments.
21367 * i387-fp.h: Likewise.
21368 * inferiors.c: (struct thread_info): Renamed from
21369 `struct inferior_info'. Remove PID member. Use generic inferior
21370 list header. All uses updated.
21371 (inferiors, signal_pid): Removed.
21372 (all_threads): New variable.
21373 (get_thread): Define.
21374 (add_inferior_to_list): New function.
21375 (for_each_inferior): New function.
21376 (change_inferior_id): New function.
21377 (add_inferior): Removed.
21378 (remove_inferior): New function.
21379 (add_thread): New function.
21380 (free_one_thread): New function.
21381 (remove_thread): New function.
21382 (clear_inferiors): Use for_each_inferior and free_one_thread.
21383 (find_inferior): New function.
21384 (find_inferior_id): New function.
21385 (inferior_target_data): Update argument type.
21386 (set_inferior_target_data): Likewise.
21387 (inferior_regcache_data): Likewise.
21388 (set_inferior_regcache_data): Likewise.
21389 * linux-low.c (linux_bp_reinsert): Remove.
21390 (all_processes, stopping_threads, using_thrads)
21391 (struct pending_signals, debug_threads, pid_of): New.
21392 (inferior_pid): Replace with macro.
21393 (struct inferior_linux_data): Remove.
21394 (get_stop_pc, add_process): New functions.
21395 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21396 Use add_process and add_thread.
21397 (linux_attach_lwp): New function, based on old linux_attach. Use
21398 add_process and add_thread. Set stop_expected for new threads.
21399 (linux_attach): New function.
21400 (linux_kill_one_process): New function.
21401 (linux_kill): Kill all LWPs.
21402 (linux_thread_alive): Use find_inferior_id.
21403 (check_removed_breakpoints, status_pending_p): New functions.
21404 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21405 Update. Use WNOHANG. Wait for cloned processes also. Update process
21406 struct for the found process.
21407 (linux_wait_for_event): New function.
21408 (linux_wait): Use it. Support LWPs.
21409 (send_sigstop, wait_for_sigstop, stop_all_processes)
21410 (linux_resume_one_process, linux_continue_one_process): New functions.
21411 (linux_resume): Support LWPs.
21412 (REGISTER_RAW_SIZE): Remove.
21413 (fetch_register): Use register_size instead. Call supply_register.
21414 (usr_store_inferior_registers): Likewise. Call collect_register.
21415 Fix recursive case.
21416 (regsets_fetch_inferior_registers): Improve error message.
21417 (regsets_store_inferior_registers): Add debugging.
21418 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21419 (unstopped_p, linux_signal_pid): New functions.
21420 (linux_target_ops): Add linux_signal_pid.
21421 (linux_init_signals): New function.
21422 (initialize_low): Call it. Initialize using_threads.
21423 * regcache.c (inferior_regcache_data): Add valid
21424 flag.
21425 (get_regcache): Fetch registers lazily. Add fetch argument
21426 and update all callers.
21427 (regcache_invalidate_one, regcache_invalidate): New
21428 functions.
21429 (new_register_cache): Renamed from create_register_cache.
21430 Return the new regcache.
21431 (free_register_cache): Change argument to a void *.
21432 (registers_to_string, registers_from_string): Call get_regcache
21433 with fetch flag set.
21434 (register_data): Make static. Pass fetch flag to get_regcache.
21435 (supply_register): Call get_regcache with fetch flag clear.
21436 (collect_register): Call get_regcache with fetch flag set.
21437 (collect_register_as_string): New function.
21438 * regcache.h: Update.
21439 * remote-utils.c (putpkt): Flush after debug output and use
21440 stderr.
21441 Handle input interrupts while waiting for an ACK.
21442 (input_interrupt): Use signal_pid method.
21443 (getpkt): Flush after debug output and use stderr.
21444 (outreg): Use collect_register_as_string.
21445 (new_thread_notify, dead_thread_notify): New functions.
21446 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21447 and general_thread.
21448 (look_up_one_symbol): Flush after debug output.
21449 * server.c (step_thread, server_waiting): New variables.
21450 (start_inferior): Don't use signal_pid. Update call to mywait.
21451 (attach_inferior): Update call to mywait.
21452 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21453 (main): Don't fetch/store registers explicitly. Use
21454 set_desired_inferior. Support proposed ``Hs'' packet. Update
21455 calls to mywait.
21456 * server.h: Update.
21457 (struct inferior_list, struct_inferior_list_entry): New.
21458 * target.c (set_desired_inferior): New.
21459 (write_inferior_memory): Constify.
21460 (mywait): New function.
21461 * target.h: Update.
21462 (struct target_ops): New signal_pid method.
21463 (mywait): Removed macro, added prototype.
21464
21465 * linux-low.h (regset_func): Removed.
21466 (regset_fill_func, regset_store_func): New.
21467 (enum regset_type): New.
21468 (struct regset_info): Add type field. Use new operation types.
21469 (struct linux_target_ops): stop_pc renamed to get_pc.
21470 Add decr_pc_after_break and breakpoint_at.
21471 (get_process, get_thread_proess, get_process_thread)
21472 (strut process_info, all_processes, linux_attach_lwp)
21473 (thread_db_init): New.
21474
21475 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21476 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21477 (the_low_target): Add new members.
21478 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21479 (i386_store_fpxregset): Constify.
21480 (target_regsets): Add new kind identifier.
21481 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21482 (i386_set_pc): Add debugging.
21483 (i386_breakpoint_at): New function.
21484 (the_low_target): Add new members.
21485 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21486 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21487 (mips_breakpoint_at): New.
21488 (the_low_target): Add new members.
21489 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21490 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21491 (the_low_target): Add new members.
21492 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21493 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21494 (the_low_target): Add new members.
21495 * linux-x86-64-low.c (target_regsets): Add new kind
21496 identifier.
21497
214982002-05-15 Daniel Jacobowitz <drow@mvista.com>
21499
21500 From Martin Pool <mbp@samba.org>:
21501 * server.c (gdbserver_usage): New function.
21502 (main): Call it.
21503
215042002-05-14 Daniel Jacobowitz <drow@mvista.com>
21505
21506 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21507 stop_at -> stop_pc.
21508
215092002-05-04 Andrew Cagney <ac131313@redhat.com>
21510
21511 * Makefile.in: Remove obsolete code.
21512
215132002-04-24 Michal Ludvig <mludvig@suse.cz>
21514
21515 * linux-low.c (regsets_fetch_inferior_registers),
21516 (regsets_store_inferior_registers): Removed cast to int from
21517 ptrace() calls.
21518 * regcache.h: Added declaration of struct inferior_info.
21519
215202002-04-20 Daniel Jacobowitz <drow@mvista.com>
21521
21522 * inferiors.c (struct inferior_info): Add regcache_data.
21523 (add_inferior): Call create_register_cache.
21524 (clear_inferiors): Call free_register_cache.
21525 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21526 * regcache.c (struct inferior_regcache_data): New.
21527 (registers): Remove.
21528 (get_regcache): New function.
21529 (create_register_cache, free_register_cache): New functions.
21530 (set_register_cache): Don't initialize the register cache here.
21531 (registers_to_string, registers_from_string, register_data): Call
21532 get_regcache.
21533 * regcache.h: Add prototypes.
21534 * server.h: Likewise.
21535
215362002-04-20 Daniel Jacobowitz <drow@mvista.com>
21537
21538 * mem-break.c: New file.
21539 * mem-break.h: New file.
21540 * Makefile.in: Add mem-break.o rule; update server.h
21541 dependencies.
21542 * inferiors.c (struct inferior_info): Add target_data
21543 member.
21544 (clear_inferiors): Free target_data member if set.
21545 (inferior_target_data, set_inferior_target_data): New functions.
21546 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21547 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21548 * linux-low.c (linux_bp_reinsert): New variable.
21549 (struct inferior_linux_data): New.
21550 (linux_create_inferior): Use set_inferior_target_data.
21551 (linux_attach): Likewise. Call add_inferior.
21552 (linux_wait_for_one_inferior): New function.
21553 (linux_wait): Call it.
21554 (linux_write_memory): Add const.
21555 (initialize_low): Call set_breakpoint_data.
21556 * linux-low.h (struct linux_target_ops): Add breakpoint
21557 handling members.
21558 * server.c (attach_inferior): Remove extra add_inferior
21559 call.
21560 * server.h: Include mem-break.h. Update inferior.c
21561 prototypes.
21562 * target.c (read_inferior_memory)
21563 (write_inferior_memory): New functions.
21564 * target.h (read_inferior_memory)
21565 (write_inferior_memory): Change macros to prototypes.
21566 (struct target_ops): Update comments. Add const to write_memory
21567 definition.
21568
215692002-04-11 Daniel Jacobowitz <drow@mvista.com>
21570
21571 * linux-low.c (usr_store_inferior_registers): Support
21572 registers which are allowed to fail to store.
21573 * linux-low.h (linux_target_ops): Likewise.
21574 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21575 (ppc_cannot_store_register): FPSCR may not be storable.
21576
215772002-04-09 Daniel Jacobowitz <drow@mvista.com>
21578
21579 * server.h: Include <string.h> if HAVE_STRING_H.
21580 * ChangeLog: Correct paths in last ChangeLog entry.
21581
215822002-04-09 Daniel Jacobowitz <drow@mvista.com>
21583
21584 * linux-low.h: Remove obsolete prototypes.
21585 (struct linux_target_ops): New.
21586 (extern the_low_target): New.
21587 * linux-low.c (num_regs, regmap): Remove declarations.
21588 (register_addr): Use the_low_target explicitly.
21589 (fetch_register): Likewise.
21590 (usr_fetch_inferior_registers): Likewise.
21591 (usr_store_inferior_registers): Likewise.
21592 * linux-arm-low.c (num_regs): Remove.
21593 (arm_num_regs): Define.
21594 (arm_regmap): Renamed from regmap, made static.
21595 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21596 made static.
21597 (arm_cannot_store_register): Renamed from cannot_store_register,
21598 made static.
21599 (the_low_target): New.
21600 * linux-i386-low.c (num_regs): Remove.
21601 (i386_num_regs): Define.
21602 (i386_regmap): Renamed from regmap, made static.
21603 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21604 made static.
21605 (i386_cannot_store_register): Renamed from cannot_store_register,
21606 made static.
21607 (the_low_target): New.
21608 * linux-ia64-low.c (num_regs): Remove.
21609 (ia64_num_regs): Define.
21610 (ia64_regmap): Renamed from regmap, made static.
21611 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21612 made static.
21613 (ia64_cannot_store_register): Renamed from cannot_store_register,
21614 made static.
21615 (the_low_target): New.
21616 * linux-m68k-low.c (num_regs): Remove.
21617 (m68k_num_regs): Define.
21618 (m68k_regmap): Renamed from regmap, made static.
21619 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21620 made static.
21621 (m68k_cannot_store_register): Renamed from cannot_store_register,
21622 made static.
21623 (the_low_target): New.
21624 * linux-mips-low.c (num_regs): Remove.
21625 (mips_num_regs): Define.
21626 (mips_regmap): Renamed from regmap, made static.
21627 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21628 made static.
21629 (mips_cannot_store_register): Renamed from cannot_store_register,
21630 made static.
21631 (the_low_target): New.
21632 * linux-ppc-low.c (num_regs): Remove.
21633 (ppc_num_regs): Define.
21634 (ppc_regmap): Renamed from regmap, made static.
21635 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21636 made static.
21637 (ppc_cannot_store_register): Renamed from cannot_store_register,
21638 made static.
21639 (the_low_target): New.
21640 * linux-s390-low.c (num_regs): Remove.
21641 (s390_num_regs): Define.
21642 (s390_regmap): Renamed from regmap, made static.
21643 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21644 made static.
21645 (s390_cannot_store_register): Renamed from cannot_store_register,
21646 made static.
21647 (the_low_target): New.
21648 * linux-sh-low.c (num_regs): Remove.
21649 (sh_num_regs): Define.
21650 (sh_regmap): Renamed from regmap, made static.
21651 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21652 made static.
21653 (sh_cannot_store_register): Renamed from cannot_store_register,
21654 made static.
21655 (the_low_target): New.
21656 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21657 (the_low_target): New.
21658
216592002-04-09 Daniel Jacobowitz <drow@mvista.com>
21660
21661 * Makefile.in: Add stamp-h target.
21662 * configure.in: Create stamp-h.
21663 * configure: Regenerated.
21664
216652002-04-09 Daniel Jacobowitz <drow@mvista.com>
21666
21667 * inferiors.c: New file.
21668 * target.c: New file.
21669 * target.h: New file.
21670 * Makefile.in: Add target.o and inferiors.o. Update
21671 dependencies.
21672 * linux-low.c (inferior_pid): New static variable,
21673 moved from server.c.
21674 (linux_create_inferior): Renamed from create_inferior.
21675 Call add_inferior. Return 0 on success instead of a PID.
21676 (linux_attach): Renamed from myattach.
21677 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21678 (linux_thread_alive): Renamed from mythread_alive.
21679 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21680 child dies.
21681 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21682 (regsets_store_inferior_registers): Correct error message.
21683 Add missing ``return 0''.
21684 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21685 (linux_store_registers): Renamed from store_inferior_registers.
21686 (linux_read_memory): Renamed from read_inferior_memory.
21687 (linux_write_memory): Renamed from write_inferior_memory.
21688 (linux_target_ops): New structure.
21689 (initialize_low): Call set_target_ops ().
21690 * remote-utils.c (unhexify): New function.
21691 (hexify): New function.
21692 (input_interrupt): Send signals to ``signal_pid''.
21693 * server.c (inferior_pid): Remove.
21694 (start_inferior): Update create_inferior call.
21695 (attach_inferior): Call add_inferior.
21696 (handle_query): New function.
21697 (main): Call handle_query for `q' packets.
21698 * server.h: Include "target.h". Remove obsolete prototypes.
21699 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21700
217012002-04-09 Daniel Jacobowitz <drow@mvista.com>
21702
21703 * Makefile.in: Add WARN_CFLAGS. Update configury
21704 dependencies.
21705 * configure.in: Check for <string.h>
21706 * configure: Regenerate.
21707 * config.in: Regenerate.
21708 * gdbreplay.c: Include needed system headers.
21709 (remote_open): Remove strchr prototype.
21710 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21711 * regcache.c (supply_register): Change buf argument to const void *.
21712 (supply_register_by_name): Likewise.
21713 (collect_register): Change buf argument to void *.
21714 (collect_register_by_name): Likewise.
21715 * regcache.h: Add missing prototypes.
21716 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21717 * server.c (handle_query): New function.
21718 (attached): New static variable, moved out of main.
21719 (main): Quiet longjmp clobber warnings.
21720 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21721 * utils.c (error): Remove NORETURN.
21722 (fatal): Likewise.