]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdbserver/ChangeLog
Rename windows_thread_info::id to "tid"
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
e56f8ccb
TT
12020-04-08 Tom Tromey <tromey@adacore.com>
2
3 * win32-low.h (struct windows_thread_info): Rename from
4 win32_thread_info. Remove typedef.
5 (struct win32_target_ops, win32_require_context): Update.
6 * win32-low.c (win32_get_thread_context)
7 (win32_set_thread_context, win32_prepare_to_resume)
8 (win32_require_context, thread_rec, child_add_thread)
9 (delete_thread_info, continue_one_thread)
10 (child_fetch_inferior_registers, child_store_inferior_registers)
11 (win32_resume, suspend_one_thread, win32_get_tib_address):
12 Update.
13 * win32-i386-low.c (update_debug_registers)
14 (win32_get_current_dr, i386_get_thread_context)
15 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
16 (i386_fetch_inferior_register, i386_store_inferior_register):
17 Update.
18 * win32-arm-low.c (arm_get_thread_context)
19 (arm_fetch_inferior_register, arm_store_inferior_register):
20 Update.
21
0dd7b52e
TBA
222020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
23
24 * linux-low.h (struct linux_target_ops): Remove.
25 (the_low_target): Remove.
26 * linux-x86-low.cc (the_low_target): Remove.
27 * linux-aarch64-low.cc (the_low_target): Ditto.
28 * linux-arm-low.cc (the_low_target): Ditto.
29 * linux-bfin-low.cc (the_low_target): Ditto.
30 * linux-cris-low.cc (the_low_target): Ditto.
31 * linux-crisv32-low.cc (the_low_target): Ditto.
32 * linux-ia64-low.cc (the_low_target): Ditto.
33 * linux-m32r-low.cc (the_low_target): Ditto.
34 * linux-m68k-low.cc (the_low_target): Ditto.
35 * linux-mips-low.cc (the_low_target): Ditto.
36 * linux-nios2-low.cc (the_low_target): Ditto.
37 * linux-ppc-low.cc (the_low_target): Ditto.
38 * linux-riscv-low.cc (the_low_target): Ditto.
39 * linux-s390-low.cc (the_low_target): Ditto.
40 * linux-sh-low.cc (the_low_target): Ditto.
41 * linux-sparc-low.cc (the_low_target): Ditto.
42 * linux-tic6x-low.cc (the_low_target): Ditto.
43 * linux-tile-low.cc (the_low_target): Ditto.
44 * linux-xtensa-low.cc (the_low_target): Ditto.
45
fc5ecdb6
TBA
462020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
47
48 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
49 linux target define the op by overriding the declaration in
50 process_stratum_target.
51
52 * linux-low.h (struct linux_target_ops): Remove the op.
53 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
54 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
55 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
56 (x86_get_ipa_tdesc_idx): Turn into...
57 (x86_target::get_ipa_tdesc_idx): ...this.
58 (the_low_target): Remove the op field.
59 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
60 (ppc_get_ipa_tdesc_idx): Turn into...
61 (ppc_target::get_ipa_tdesc_idx): ...this.
62 (the_low_target): Remove the op field.
63 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
64 (s390_get_ipa_tdesc_idx): Turn into...
65 (s390_target::get_ipa_tdesc_idx): ...this.
66 (the_low_target): Remove the op field.
67
9eedd27d
TBA
682020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
69
70 Turn the 'get_syscall_trapinfo' linux target op into a method
71 of process_stratum_target.
72
73 * linux-low.h (struct linux_target_ops): Remove the op.
74 (class linux_process_target) <get_syscall_trapinfo>
75 <gdb_catch_this_syscall>
76 <low_supports_catch_syscall>
77 <low_get_syscall_trapinfo>: Declare.
78 * linux-low.cc (get_syscall_trapinfo): Turn into...
79 (linux_process_target::get_syscall_trapinfo): ...this.
80 (linux_process_target::low_get_syscall_trapinfo): Define.
81 (gdb_catch_this_syscall_p): Turn into...
82 (linux_process_target::gdb_catch_this_syscall): ...this.
83 (linux_process_target::low_supports_catch_syscall): Define.
84
85 Update the callers below.
86
87 (linux_process_target::wait_1)
88 (linux_process_target::supports_catch_syscall)
89
90 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
91 <low_get_syscall_trapinfo>: Declare.
92 (x86_target::low_supports_catch_syscall): Define.
93 (x86_get_syscall_trapinfo): Turn into...
94 (x86_target::low_get_syscall_trapinfo): ...this.
95 (the_low_target): Remove the op field.
96 * linux-aarch64-low.cc (class aarch64_target)
97 <low_supports_catch_syscall>
98 <low_get_syscall_trapinfo>: Declare.
99 (aarch64_target::low_supports_catch_syscall): Define.
100 (aarch64_get_syscall_trapinfo): Turn into...
101 (aarch64_target::low_get_syscall_trapinfo): ...this.
102 (the_low_target): Remove the op field.
103 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
104 <low_get_syscall_trapinfo>: Declare.
105 (arm_target::low_supports_catch_syscall): Define.
106 (arm_get_syscall_trapinfo): Turn into...
107 (arm_target::low_get_syscall_trapinfo): ...this.
108 (the_low_target): Remove the op field.
109 * linux-ppc-low.cc (the_low_target): Remove the op field.
110 * linux-s390-low.cc (the_low_target): Remove the op field.
111
b31cdfa6
TBA
1122020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
113
114 Remove the 'supports_hardware_single_step' linux target op and
115 override the process_stratum_target's op definition in
116 linux_process_target to return true.
117
118 * linux-low.h (struct linux_target_ops): Remove the op.
119 (class linux_process_target) <finish_step_over>
120 <maybe_hw_step>: Declare.
121 * linux-low.cc (can_hardware_single_step): Remove.
122 (maybe_hw_step): Turn into...
123 (linux_process_target::maybe_hw_step): ...this.
124 (finish_step_over): Turn into...
125 (linux_process_target::finish_step_over): ...this.
126 (linux_process_target::supports_hardware_single_step): Update
127 to return true.
128
129 Update the callers below.
130
131 (linux_process_target::single_step)
132 (linux_process_target::resume_one_lwp_throw)
133
134 * linux-arm-low.cc (class arm_target)
135 <supports_hardware_single_step>: Declare.
136 (arm_supports_hardware_single_step): Turn into...
137 (arm_target::supports_hardware_single_step): ...this.
138 (the_low_target): Remove the op field.
139 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
140 (the_low_target): Remove the op field.
141 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
142 Remove.
143 (the_low_target): Remove the op field.
144 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
145 (the_low_target): Remove the op field.
146 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
147 (the_low_target): Remove the op field.
148 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
149 (the_low_target): Remove the op field.
150 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
151 (the_low_target): Remove the op field.
152 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
153 (the_low_target): Remove the op field.
154 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
155 (the_low_target): Remove the op field.
156 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
157 (the_low_target): Remove the op field.
158 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
159 (the_low_target): Remove the op field.
160 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
161 (the_low_target): Remove the op field.
162 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
163 Remove.
164 (the_low_target): Remove the op field.
165
9cfd8715
TBA
1662020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
167
168 Turn the 'supports_range_stepping' linux target op into a method
169 of linux_process_target.
170
171 * linux-low.h (struct linux_target_ops): Remove the op.
172 (class linux_process_target) <low_supports_range_stepping>: Declare.
173 * linux-low.cc (linux_process_target::low_supports_range_stepping):
174 Define.
175 (linux_process_target::supports_range_stepping): Update the call
176 site.
177 * linux-x86-low.cc (class x86_target)
178 <low_supports_range_stepping>: Declare.
179 (x86_supports_range_stepping): Turn into...
180 (x86_target::low_supports_range_stepping): ...this.
181 (the_low_target): Remove the op field.
182 * linux-aarch64-low.cc (class aarch64_target)
183 <low_supports_range_stepping>: Declare.
184 (aarch64_supports_range_stepping): Turn into...
185 (aarch64_target::low_supports_range_stepping): ...this.
186 (the_low_target): Remove the op field.
187 * linux-arm-low.cc (the_low_target): Remove the op field.
188 * linux-bfin-low.cc (the_low_target): Ditto.
189 * linux-crisv32-low.cc (the_low_target): Ditto.
190 * linux-m32r-low.cc (the_low_target): Ditto.
191 * linux-m68k-low.cc (the_low_target): Ditto.
192 * linux-ppc-low.cc (the_low_target): Ditto.
193 * linux-s390-low.cc (the_low_target): Ditto.
194 * linux-sh-low.cc (the_low_target): Ditto.
195 * linux-tic6x-low.cc (the_low_target): Ditto.
196 * linux-tile-low.cc (the_low_target): Ditto.
197 * linux-xtensa-low.cc (the_low_target): Ditto.
198
ab64c999
TBA
1992020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
200
201 Remove the 'emit_ops' linux target ops and let the concrete
202 linux target define the op by overriding the declaration of
203 process_stratum_target.
204
205 * linux-low.h (struct linux_target_ops): Remove the op.
206 (class linux_process_target) <emit_ops>: Remove.
207 * linux-low.cc (linux_process_target::emit_ops): Remove.
208 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
209 (x86_emit_ops): Turn into...
210 (x86_target::emit_ops): ...this.
211 (the_low_target): Remove the op field.
212 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
213 (aarch64_emit_ops): Turn into...
214 (aarch64_target::emit_ops): ...this.
215 (the_low_target): Remove the op field.
216 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
217 (ppc_emit_ops): Turn into...
218 (ppc_target::emit_ops): ...this.
219 (the_low_target): Remove the op field.
220 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
221 (s390_emit_ops): Turn into...
222 (s390_target::emit_ops): ...this.
223 (the_low_target): Remove the op field.
224 * linux-arm-low.cc (the_low_target): Remove the op field.
225 * linux-bfin-low.cc (the_low_target): Ditto.
226 * linux-crisv32-low.cc (the_low_target): Ditto.
227 * linux-m32r-low.cc (the_low_target): Ditto.
228 * linux-m68k-low.cc (the_low_target): Ditto.
229 * linux-sh-low.cc (the_low_target): Ditto.
230 * linux-tic6x-low.cc (the_low_target): Ditto.
231 * linux-tile-low.cc (the_low_target): Ditto.
232 * linux-xtensa-low.cc (the_low_target): Ditto.
233
809a0c35
TBA
2342020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
235
236 Remove the 'install_fast_tracepoint_jump_pad' and
237 'get_min_fast_tracepoint_insn_len' linux target ops to let the
238 concrete linux target define the ops by overriding the declarations
239 of process_stratum_target.
240
241 * linux-low.h (struct linux_target_ops): Remove the ops.
242 (class linux_process_target) <supports_fast_tracepoints>
243 <install_fast_tracepoint_jump_pad>
244 <get_min_fast_tracepoint_insn_len>: Remove.
245 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
246 (linux_process_target::install_fast_tracepoint_jump_pad)
247 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
248 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
249 <install_fast_tracepoint_jump_pad>
250 <get_min_fast_tracepoint_insn_len>: Declare.
251 (x86_target::supports_fast_tracepoints): Define.
252 (x86_install_fast_tracepoint_jump_pad): Turn into...
253 (x86_target::install_fast_tracepoint_jump_pad): ...this.
254 (x86_get_min_fast_tracepoint_insn_len): Turn into...
255 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
256 (the_low_target): Remove the op fields.
257 * linux-aarch64-low.cc (class aarch64_target)
258 <supports_fast_tracepoints>
259 <install_fast_tracepoint_jump_pad>
260 <get_min_fast_tracepoint_insn_len>: Declare.
261 (aarch64_target::supports_fast_tracepoints): Define.
262 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
263 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
264 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
265 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
266 (the_low_target): Remove the op fields.
267 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
268 <install_fast_tracepoint_jump_pad>
269 <get_min_fast_tracepoint_insn_len>: Declare.
270 (ppc_target::supports_fast_tracepoints): Define.
271 (ppc_install_fast_tracepoint_jump_pad): Turn into...
272 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
273 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
274 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
275 (the_low_target): Remove the op fields.
276 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
277 <install_fast_tracepoint_jump_pad>
278 <get_min_fast_tracepoint_insn_len>: Declare.
279 (s390_target::supports_fast_tracepoints): Define.
280 (s390_install_fast_tracepoint_jump_pad): Turn into...
281 (s390_target::install_fast_tracepoint_jump_pad): ...this.
282 (s390_get_min_fast_tracepoint_insn_len): Turn into...
283 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
284 (the_low_target): Remove the op fields.
285 * linux-arm-low.cc (the_low_target): Remove the op fields.
286 * linux-bfin-low.cc (the_low_target): Ditto.
287 * linux-crisv32-low.cc (the_low_target): Ditto.
288 * linux-m32r-low.cc (the_low_target): Ditto.
289 * linux-m68k-low.cc (the_low_target): Ditto.
290 * linux-sh-low.cc (the_low_target): Ditto.
291 * linux-tic6x-low.cc (the_low_target): Ditto.
292 * linux-tile-low.cc (the_low_target): Ditto.
293 * linux-xtensa-low.cc (the_low_target): Ditto.
294
13e567af
TBA
2952020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
296
297 Turn the 'get_thread_area' linux target op into a method of
298 process_stratum_target.
299
300 * linux-low.h (struct linux_target_ops): Remove the op.
301 (class linux_process_target) <stuck_in_jump_pad>
302 <linux_fast_tracepoint_collecting>
303 <low_get_thread_area>: Declare.
304 * linux-low.cc (supports_fast_tracepoints): Remove.
305 (linux_fast_tracepoint_collecting): Turn into...
306 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
307 (linux_process_target::low_get_thread_area): Define.
308 (stuck_in_jump_pad_callback): Turn into...
309 (linux_process_target::stuck_in_jump_pad): ...this.
310
311 Update the caller below.
312
313 (linux_process_target::stabilize_threads)
314
315 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
316 Declare.
317 (x86_get_thread_area): Turn into...
318 (x86_target::low_get_thread_area): ...this.
319 (the_low_target): Remove the op field.
320 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
321 Declare.
322 (aarch64_get_thread_area): Turn into...
323 (aarch64_target::low_get_thread_area): ...this.
324 (the_low_target): Remove the op field.
325 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
326 Declare.
327 (ppc_get_thread_area): Turn into...
328 (ppc_target::low_get_thread_area): ...this.
329 (the_low_target): Remove the op field.
330 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
331 Declare.
332 (s390_get_thread_area): Turn into...
333 (s390_target::low_get_thread_area): ...this.
334 (the_low_target): Remove the op field.
335 * linux-arm-low.cc (the_low_target): Remove the op field.
336 * linux-bfin-low.cc (the_low_target): Ditto.
337 * linux-crisv32-low.cc (the_low_target): Ditto.
338 * linux-m32r-low.cc (the_low_target): Ditto.
339 * linux-m68k-low.cc (the_low_target): Ditto.
340 * linux-sh-low.cc (the_low_target): Ditto.
341 * linux-tic6x-low.cc (the_low_target): Ditto.
342 * linux-tile-low.cc (the_low_target): Ditto.
343 * linux-xtensa-low.cc (the_low_target): Ditto.
344
47f70aa7
TBA
3452020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
346
347 Remote the 'supports_tracepoints' linux target op and let the
348 concrete linux target define it by overriding the op declared in
349 process_stratum_target.
350
351 * linux-low.h (struct linux_target_ops): Remove the op.
352 (class linux_process_target) <supports_tracepoints>: Remove.
353 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
354 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
355 Declare.
356 (x86_supports_tracepoints): Turn into...
357 (x86_target::supports_tracepoints): ...this.
358 (the_low_target): Remove the op field.
359 * linux-aarch64-low.cc (class aarch64_target)
360 <supports_tracepoints>: Declare.
361 (aarch64_supports_tracepoints): Turn into...
362 (aarch64_target::supports_tracepoints): ...this.
363 (the_low_target): Remove the op field.
364 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
365 Declare.
366 (ppc_supports_tracepoints): Turn into...
367 (ppc_target::supports_tracepoints): ...this.
368 (the_low_target): Remove the op field.
369 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
370 Declare.
371 (s390_supports_tracepoints): Turn into...
372 (s390_target::supports_tracepoints): ...this.
373 (the_low_target): Remove the op field.
374 * linux-arm-low.cc (the_low_target): Remove the op field.
375 * linux-bfin-low.cc (the_low_target): Ditto.
376 * linux-crisv32-low.cc (the_low_target): Ditto.
377 * linux-m32r-low.cc (the_low_target): Ditto.
378 * linux-m68k-low.cc (the_low_target): Ditto.
379 * linux-sh-low.cc (the_low_target): Ditto.
380 * linux-tic6x-low.cc (the_low_target): Ditto.
381 * linux-tile-low.cc (the_low_target): Ditto.
382 * linux-xtensa-low.cc (the_low_target): Ditto.
383
a5b5da92
TBA
3842020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
385
386 Remove the 'process_qsupported' linux target op and let a concrete
387 linux target define the op by overriding the op declaration in
388 process_stratum_target.
389
390 * linux-low.h (struct linux_target_ops): Remove the op.
391 (class linux_process_target) <process_qsupported>: Remove.
392 * linux-low.cc (linux_process_target::process_qsupported): Remove.
393 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
394 (x86_linux_process_qsupported): Turn into...
395 (x86_target::process_qsupported): ...this.
396 (the_low_target): Remove the op field.
397 * linux-aarch64-low.cc (the_low_target): Remove the op
398 field.
399 * linux-arm-low.cc (the_low_target): Ditto.
400 * linux-bfin-low.cc (the_low_target): Ditto.
401 * linux-crisv32-low.cc (the_low_target): Ditto.
402 * linux-m32r-low.cc (the_low_target): Ditto.
403 * linux-m68k-low.cc (the_low_target): Ditto.
404 * linux-ppc-low.cc (the_low_target): Ditto.
405 * linux-s390-low.cc (the_low_target): Ditto.
406 * linux-sh-low.cc (the_low_target): Ditto.
407 * linux-tic6x-low.cc (the_low_target): Ditto.
408 * linux-tile-low.cc (the_low_target): Ditto.
409 * linux-xtensa-low.cc (the_low_target): Ditto.
410
d7599cc0
TBA
4112020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
412
413 Turn the 'prepare_to_resume' linux target op into a method of
414 linux_process_target.
415
416 * linux-low.h (struct linux_target_ops): Remove the op.
417 (class linux_process_target) <low_prepare_to_resume>: Declare.
418 * linux-low.cc (linux_process_target::low_prepare_to_resume):
419 Define.
420
421 Update the callers below:
422
423 (linux_process_target::resume_one_lwp_throw)
424 (linux_process_target::low_prepare_to_resume)
425
426 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
427 Declare.
428 (x86_target::low_prepare_to_resume): Define.
429 (the_low_target): Remove the op field.
430 * linux-aarch64-low.cc (class aarch64_target)
431 <low_prepare_to_resume>: Declare.
432 (aarch64_target::low_prepare_to_resume): Define.
433 (the_low_target): Remove the op field.
434 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
435 Declare.
436 (arm_prepare_to_resume): Turn into...
437 (arm_target::low_prepare_to_resume): ...this.
438 (the_low_target): Remove the op field.
439 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
440 Declare.
441 (mips_linux_prepare_to_resume): Turn into...
442 (mips_target::low_prepare_to_resume): ...this.
443 (the_low_target): Remove the op field.
444 * linux-bfin-low.cc (the_low_target): Remove the op field.
445 * linux-crisv32-low.cc (the_low_target): Ditto.
446 * linux-m32r-low.cc (the_low_target): Ditto.
447 * linux-m68k-low.cc (the_low_target): Ditto.
448 * linux-ppc-low.cc (the_low_target): Ditto.
449 * linux-s390-low.cc (the_low_target): Ditto.
450 * linux-sh-low.cc (the_low_target): Ditto.
451 * linux-tic6x-low.cc (the_low_target): Ditto.
452 * linux-tile-low.cc (the_low_target): Ditto.
453 * linux-xtensa-low.cc (the_low_target): Ditto.
454
fd000fb3
TBA
4552020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
456
457 Turn the 'new_process', 'delete_process', 'new_thread',
458 'delete_thread', and 'new_fork' linux target ops into methods
459 of linux_process_target.
460
461 * linux-low.h (struct linux_target_ops): Remove the ops.
462 (class linux_process_target) <add_linux_process>
463 <add_lwp>
464 <delete_lwp>
465 <attach_lwp>
466 <detach_one_lwp>
467 <check_zombie_leaders>
468 <filter_exit_event>
469 <low_new_process>
470 <low_delete_process>
471 <low_new_thread>
472 <low_delete_thread>
473 <low_new_fork>: Declare.
474 * linux-low.cc (delete_lwp): Turn into...
475 (linux_process_target::delete_lwp): ...this.
476 (linux_process_target::low_delete_thread): Define.
477 (linux_add_process): Turn into...
478 (linux_process_target::add_linux_process): ...this.
479 (linux_process_target::low_new_process): Define.
480 (linux_process_target::low_delete_process): Define.
481 (linux_process_target::low_new_fork): Define.
482 (add_lwp): Turn into...
483 (linux_process_target::add_lwp): ...this.
484 (linux_process_target::low_new_thread): Define.
485 (linux_attach_lwp): Turn into...
486 (linux_process_target::attach_lwp): ...this.
487 (linux_detach_one_lwp): Turn into...
488 (linux_process_target::detach_one_lwp): ...this.
489 (linux_detach_lwp_callback): Remove and inline...
490 (linux_process_target::detach): ...here.
491 (check_zombie_leaders): Turn into...
492 (linux_process_target::check_zombie_leaders): ...this.
493 (filter_exit_event): Turn into...
494 (linux_process_target::filter_exit_event): ...this.
495
496 Update the callers below.
497
498 (linux_process_target::handle_extended_wait)
499 (linux_process_target::create_inferior)
500 (attach_proc_task_lwp_callback)
501 (linux_process_target::attach)
502 (linux_process_target::detach)
503 (linux_process_target::mourn)
504 * thread-db.cc (attach_thread)
505
506 * linux-x86-low.cc (class x86_target) <low_new_process>
507 <low_delete_process>
508 <low_new_thread>
509 <low_delete_thread>
510 <low_new_fork>: Declare.
511 (x86_linux_new_process): Turn into...
512 (x86_target::low_new_process): ...this.
513 (x86_linux_delete_process): Turn into...
514 (x86_target::low_delete_process): ...this.
515 (x86_target::low_new_thread): Define.
516 (x86_target::low_delete_thread): Define.
517 (x86_linux_new_fork): Turn into...
518 (x86_target::low_new_fork): ...this.
519 (the_low_target): Remove the op fields.
520 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
521 <low_delete_process>
522 <low_new_thread>
523 <low_delete_thread>
524 <low_new_fork>: Declare.
525 (aarch64_linux_new_process): Turn into...
526 (aarch64_target::low_new_process): ...this.
527 (aarch64_linux_delete_process): Turn into...
528 (aarch64_target::low_delete_process): ...this.
529 (aarch64_target::low_new_thread): Define.
530 (aarch64_target::low_delete_thread): Define.
531 (aarch64_linux_new_fork): Turn into...
532 (aarch64_target::low_new_fork): ...this.
533 (the_low_target): Remove the op fields.
534 * linux-arm-low.cc (class arm_target) <low_new_process>
535 <low_delete_process>
536 <low_new_thread>
537 <low_delete_thread>
538 <low_new_fork>: Declare.
539 (arm_new_process): Turn into...
540 (arm_target::low_new_process): ...this.
541 (arm_delete_process): Turn into...
542 (arm_target::low_delete_process): ...this.
543 (arm_new_thread): Turn into...
544 (arm_target::low_new_thread): ...this.
545 (arm_delete_thread): Turn into...
546 (arm_target::low_delete_thread): ...this.
547 (arm_new_fork): Turn into...
548 (arm_target::low_new_fork): ...this.
549 (the_low_target): Remove the op fields.
550 * linux-mips-low.cc (class mips_target) <low_new_process>
551 <low_delete_process>
552 <low_new_thread>
553 <low_delete_thread>
554 <low_new_fork>: Declare.
555 (mips_linux_new_process): Turn into...
556 (mips_target::low_new_process): ...this.
557 (mips_linux_delete_process): Turn into...
558 (mips_target::low_delete_process): ...this.
559 (mips_linux_new_thread): Turn into...
560 (mips_target::low_new_thread): ...this.
561 (mips_linux_delete_thread): Turn into...
562 (mips_target::low_delete_thread): ...this.
563 (mips_linux_new_fork): Turn into...
564 (mips_target::low_new_fork): ...this.
565 (the_low_target): Remove the op fields.
566 * linux-bfin-low.cc (the_low_target): Remove the op fields.
567 * linux-crisv32-low.cc (the_low_target): Ditto.
568 * linux-m32r-low.cc (the_low_target): Ditto.
569 * linux-m68k-low.cc (the_low_target): Ditto.
570 * linux-ppc-low.cc (the_low_target): Ditto.
571 * linux-s390-low.cc (the_low_target): Ditto.
572 * linux-sh-low.cc (the_low_target): Ditto.
573 * linux-tic6x-low.cc (the_low_target): Ditto.
574 * linux-tile-low.cc (the_low_target): Ditto.
575 * linux-xtensa-low.cc (the_low_target): Ditto.
576
cb63de7c
TBA
5772020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
578
579 Turn the 'siginfo_fixup' linux target op into a method of
580 linux_process_target.
581
582 * linux-low.h (struct linux_target_ops): Remove the op.
583 (class linux_process_target) <siginfo_fixup>
584 <low_siginfo_fixup>: Declare.
585 * linux-low.cc (siginfo_fixup): Turn into...
586 (linux_process_target::siginfo_fixup): ...this.
587 (linux_process_target::low_siginfo_fixup): Define.
588 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
589 (x86_siginfo_fixup): Turn into...
590 (x86_target::low_siginfo_fixup): ...this.
591 (the_low_target): Remove the op field.
592 * linux-aarch64-low.cc (class aarch64_target):
593 <low_siginfo_fixup>: Declare.
594 (aarch64_linux_siginfo_fixup): Turn into...
595 (aarch64_target::low_siginfo_fixup): ...this.
596 (the_low_target): Remove the op field.
597 * linux-arm-low.cc (the_low_target): Remove the op field.
598 * linux-bfin-low.cc (the_low_target): Ditto.
599 * linux-crisv32-low.cc (the_low_target): Ditto.
600 * linux-m32r-low.cc (the_low_target): Ditto.
601 * linux-m68k-low.cc (the_low_target): Ditto.
602 * linux-mips-low.cc (the_low_target): Ditto.
603 * linux-ppc-low.cc (the_low_target): Ditto.
604 * linux-s390-low.cc (the_low_target): Ditto.
605 * linux-sh-low.cc (the_low_target): Ditto.
606 * linux-tic6x-low.cc (the_low_target): Ditto.
607 * linux-tile-low.cc (the_low_target): Ditto.
608 * linux-xtensa-low.cc (the_low_target): Ditto.
609
b35db733
TBA
6102020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
611
612 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
613 linux target ops into methods of linux_process_target.
614
615 * linux-low.h (struct linux_target_ops): Remove the ops.
616 (class linux_process_target) <low_collect_ptrace_register>
617 <low_store_ptrace_register>: Declare.
618 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
619 (linux_process_target::low_supply_ptrace_register): Define.
620
621 Update the callers below.
622
623 (linux_process_target::fetch_register)
624 (linux_process_target::store_register)
625
626 * linux-x86-low.cc (the_low_target): Remove the op fields.
627 * linux-aarch64-low.cc (the_low_target): Ditto.
628 * linux-arm-low.cc (the_low_target): Ditto.
629 * linux-bfin-low.cc (the_low_target): Ditto.
630 * linux-crisv32-low.cc (the_low_target): Ditto.
631 * linux-m32r-low.cc (the_low_target): Ditto.
632 * linux-m68k-low.cc (the_low_target): Ditto.
633 * linux-sh-low.cc (the_low_target): Ditto.
634 * linux-sparc-low.cc (the_low_target): Ditto.
635 * linux-tic6x-low.cc (the_low_target): Ditto.
636 * linux-tile-low.cc (the_low_target): Ditto.
637 * linux-xtensa-low.cc (the_low_target): Ditto.
638 * linux-mips-low.cc (class mips_target)
639 <low_collect_ptrace_register>
640 <low_supply_ptrace_register>: Declare.
641 (mips_collect_ptrace_register): Turn into ...
642 (mips_target::low_collect_ptrace_register): ...this.
643 (mips_supply_ptrace_register): Turn into...
644 (mips_target::low_supply_ptrace_register): ...this.
645 (the_low_target): Remove the op fields.
646 * linux-ppc-low.cc (class ppc_target)
647 <low_collect_ptrace_register>
648 <low_supply_ptrace_register>: Declare.
649 (ppc_collect_ptrace_register): Turn into ...
650 (ppc_target::low_collect_ptrace_register): ...this.
651 (ppc_supply_ptrace_register): Turn into ...
652 (ppc_target::low_supply_ptrace_register): ...this.
653 (ppc_fill_gregset): Update for the calls to
654 low_collect_ptrace_register.
655 (the_low_target): Remove the op fields.
656 * linux-s390-low.cc (class s390_target)
657 <low_collect_ptrace_register>
658 <low_supply_ptrace_register>: Declare.
659 (s390_collect_ptrace_register): Turn into ...
660 (s390_target::low_collect_ptrace_register): ...this.
661 (s390_supply_ptrace_register): Turn into ...
662 (s390_target::low_supply_ptrace_register): ...this.
663 (s390_fill_gregset): Update for the calls to
664 low_collect_ptrace_register.
665 (the_low_target): Remove the op fields.
666
ac1bbaca
TBA
6672020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
668
669 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
670 target ops into methods of linux_process_target.
671
672 * linux-low.h (struct linux_target_ops): Remove the ops.
673 (class linux_process_target) <check_stopped_by_watchpoint>
674 <low_stopped_by_watchpoint>
675 <low_stopped_data_address>: Declare.
676 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
677 (linux_process_target::check_stopped_by_watchpoint): ...this.
678 (linux_process_target::low_stopped_by_watchpoint): Define.
679 (linux_process_target::low_stopped_data_address): Define.
680 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
681 <low_stopped_data_address>: Declare.
682 (x86_stopped_by_watchpoint): Turn into...
683 (x86_target::low_stopped_by_watchpoint): ...this.
684 (x86_stopped_data_address): Turn into...
685 (x86_target::low_stopped_data_address): ...this.
686 (the_low_target): Remove the op fields.
687 * linux-aarch64-low.cc (class aarch64_target)
688 <low_stopped_by_watchpoint>
689 <low_stopped_data_address>: Declare.
690 (aarch64_stopped_by_watchpoint): Turn into...
691 (aarch64_target::low_stopped_by_watchpoint): ...this.
692 (aarch64_stopped_data_address): Turn into...
693 (aarch64_target::low_stopped_data_address): ...this.
694 (the_low_target): Remove the op fields.
695 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
696 <low_stopped_data_address>: Declare.
697 (arm_stopped_by_watchpoint): Turn into...
698 (arm_target::low_stopped_by_watchpoint): ...this.
699 (arm_stopped_data_address): Turn into...
700 (arm_target::low_stopped_data_address): ...this.
701 (the_low_target): Remove the op fields.
702 * linux-crisv32-low.cc (class crisv32_target)
703 <low_stopped_by_watchpoint>
704 <low_stopped_data_address>: Declare.
705 (cris_stopped_by_watchpoint): Turn into...
706 (crisv32_target::low_stopped_by_watchpoint): ...this.
707 (cris_stopped_data_address): Turn into...
708 (crisv32_target::low_stopped_data_address): ...this.
709 (the_low_target): Remove the op fields.
710 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
711 <low_stopped_data_address>: Declare.
712 (mips_stopped_by_watchpoint): Turn into...
713 (mips_target::low_stopped_by_watchpoint): ...this.
714 (mips_stopped_data_address): Turn into...
715 (mips_target::low_stopped_data_address): ...this.
716 (the_low_target): Remove the op fields.
717 * linux-bfin-low.cc (the_low_target): Remove the op fields.
718 * linux-m32r-low.cc (the_low_target): Ditto.
719 * linux-m68k-low.cc (the_low_target): Ditto.
720 * linux-ppc-low.cc (the_low_target): Ditto.
721 * linux-s390-low.cc (the_low_target): Ditto.
722 * linux-sh-low.cc (the_low_target): Ditto.
723 * linux-sparc-low.cc (the_low_target): Ditto.
724 * linux-tic6x-low.cc (the_low_target): Ditto.
725 * linux-tile-low.cc (the_low_target): Ditto.
726 * linux-xtensa-low.cc (the_low_target): Ditto.
727
9db9aa23
TBA
7282020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
729
730 Turn the 'insert_point' and 'remove_point' linux target ops into
731 methods of linux_process_target.
732
733 * linux-low.h (struct linux_target_ops): Remove the ops.
734 (class linux_process_target) <low_insert_point>
735 <low_remove_point>: Declare.
736 * linux-low.cc (linux_process_target::low_insert_point)
737 (linux_process_target::low_remove_point): Define.
738 (linux_process_target::insert_point)
739 (linux_process_target::remove_point): Update for calls to
740 low_insert_point and low_remove_point.
741 * linux-x86-low.cc (class x86_target) <low_insert_point>
742 <low_remove_point>: Declare.
743 (x86_insert_point): Turn into...
744 (x86_target::low_insert_point): ...this.
745 (x86_remove_point): Turn into...
746 (x86_target::low_remove_point): ...this.
747 (the_low_target): Remove the op fields.
748 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
749 <low_remove_point>: Declare.
750 (aarch64_insert_point): Turn into...
751 (aarch64_target::low_insert_point): ...this.
752 (aarch64_remove_point): Turn into...
753 (aarch64_target::low_remove_point): ...this.
754 (the_low_target): Remove the op fields.
755 * linux-arm-low.cc (class arm_target) <low_insert_point>
756 <low_remove_point>: Declare.
757 (arm_insert_point): Turn into...
758 (arm_target::low_insert_point): ...this.
759 (arm_remove_point): Turn into...
760 (arm_target::low_remove_point): ...this.
761 (the_low_target): Remove the op fields.
762 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
763 <low_remove_point>: Declare.
764 (crisv32_insert_point): Turn into...
765 (crisv32_target::low_insert_point): ...this.
766 (crisv32_remove_point): Turn into...
767 (crisv32_target::low_remove_point): ...this.
768 (the_low_target): Remove the op fields.
769 * linux-mips-low.cc (class mips_target) <low_insert_point>
770 <low_remove_point>: Declare.
771 (mips_insert_point): Turn into...
772 (mips_target::low_insert_point): ...this.
773 (mips_remove_point): Turn into...
774 (mips_target::low_remove_point): ...this.
775 (the_low_target): Remove the op fields.
776 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
777 <low_remove_point>: Declare.
778 (ppc_insert_point): Turn into...
779 (ppc_target::low_insert_point): ...this.
780 (ppc_remove_point): Turn into...
781 (ppc_target::low_remove_point): ...this.
782 (the_low_target): Remove the op fields.
783 * linux-bfin-low.cc (the_low_target): Remove the op fields.
784 * linux-m32r-low.cc (the_low_target): Ditto.
785 * linux-m68k-low.cc (the_low_target): Ditto.
786 * linux-s390-low.cc (the_low_target): Ditto.
787 * linux-sh-low.cc (the_low_target): Ditto.
788 * linux-sparc-low.cc (the_low_target): Ditto.
789 * linux-tic6x-low.cc (the_low_target): Ditto.
790 * linux-tile-low.cc (the_low_target): Ditto.
791 * linux-xtensa-low.cc (the_low_target): Ditto.
792
007c9b97
TBA
7932020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
794
795 Remove the 'supports_z_point_type' linux target op and let the
796 concrete linux target define it by overriding the op declared in
797 process_stratum_target.
798
799 * linux-low.cc (linux_process_target::supports_z_point_type):
800 Remove.
801 * linux-low.h (struct linux_target_ops): Remove the op.
802 (class linux_process_target) <supports_z_point_type>: Remove.
803 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
804 Declare.
805 (x86_supports_z_point_type): Turn into...
806 (x86_target::supports_z_point_type): ...this.
807 (the_low_target): Remove the op field.
808 * linux-aarch64-low.cc (class aarch64_target)
809 <supports_z_point_type>: Declare.
810 (aarch64_supports_z_point_type): Turn into...
811 (aarch64_target::supports_z_point_type): ...this.
812 (the_low_target): Remove the op field.
813 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
814 Declare.
815 (arm_supports_z_point_type): Turn into...
816 (arm_target::supports_z_point_type): ...this.
817 (the_low_target): Remove the op field.
818 * linux-crisv32-low.cc (class crisv32_target)
819 <supports_z_point_type>: Declare.
820 (cris_supports_z_point_type): Turn into...
821 (crisv32_target::supports_z_point_type): ...this.
822 (the_low_target): Remove the op field.
823 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
824 Declare.
825 (mips_supports_z_point_type): Turn into...
826 (mips_target::supports_z_point_type): ...this.
827 (the_low_target): Remove the op field.
828 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
829 Declare.
830 (ppc_supports_z_point_type): Turn into...
831 (ppc_target::supports_z_point_type): ...this.
832 (the_low_target): Remove the op field.
833 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
834 Declare.
835 (s390_supports_z_point_type): Turn into...
836 (s390_target::supports_z_point_type): ...this.
837 (the_low_target): Remove the op field.
838 * linux-bfin-low.cc (the_low_target): Remove the op field.
839 * linux-m32r-low.cc (the_low_target): Ditto.
840 * linux-m68k-low.cc (the_low_target): Ditto.
841 * linux-sh-low.cc (the_low_target): Ditto.
842 * linux-sparc-low.cc (the_low_target): Ditto.
843 * linux-tic6x-low.cc (the_low_target): Ditto.
844 * linux-tile-low.cc (the_low_target): Ditto.
845 * linux-xtensa-low.cc (the_low_target): Ditto.
846
d7146cda
TBA
8472020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
848
849 Turn the 'breakpoint_at' linux target op into a method of
850 linux_process_target.
851
852 * linux-low.h (struct linux_target_ops): Remove the op.
853 (class linux_process_target) <low_breakpoint_at>: Declare.
854
855 Update the callers below:
856
857 * linux-low.cc (linux_process_target::save_stop_reason)
858 (linux_process_target::thread_still_has_status_pending)
859 (linux_process_target::wait_1)
860
861 * linux-x86-low.cc (class x86_target)
862 <low_breakpoint_at>: Declare.
863 (x86_breakpoint_at): Turn into...
864 (x86_target::low_breakpoint_at): ...this.
865 (the_low_target): Remove the op field.
866 * linux-aarch64-low.cc (class aarch64_target)
867 <low_breakpoint_at>: Declare.
868 (aarch64_breakpoint_at): Turn into...
869 (aarch64_target::low_breakpoint_at): ...this.
870 (the_low_target): Remove the op field.
871 * linux-arm-low.cc (class arm_target)
872 <low_breakpoint_at>: Declare.
873 (arm_target::low_breakpoint_at): Define.
874 (the_low_target): Remove the op field.
875 * linux-bfin-low.cc (class bfin_target)
876 <low_breakpoint_at>: Declare.
877 (bfin_breakpoint_at): Turn into...
878 (bfin_target::low_breakpoint_at): ...this.
879 (the_low_target): Remove the op field.
880 * linux-cris-low.cc (class cris_target)
881 <low_breakpoint_at>: Declare.
882 (cris_breakpoint_at): Turn into...
883 (cris_target::low_breakpoint_at): ...this.
884 (the_low_target): Remove the op field.
885 * linux-crisv32-low.cc (class crisv32_target)
886 <low_breakpoint_at>: Declare.
887 (crisv32_breakpoint_at): Turn into...
888 (crisv32_target::low_breakpoint_at): ...this.
889 (the_low_target): Remove the op field.
890 * linux-ia64-low.cc (class ia64_target)
891 <low_breakpoint_at>: Declare.
892 (ia64_target::low_breakpoint_at): Define.
893 * linux-m32r-low.cc (class m32r_target)
894 <low_breakpoint_at>: Declare.
895 (m32r_breakpoint_at): Turn into...
896 (m32r_target::low_breakpoint_at): ...this.
897 (the_low_target): Remove the op field.
898 * linux-m68k-low.cc (class m68k_target)
899 <low_breakpoint_at>: Declare.
900 (m68k_breakpoint_at): Turn into...
901 (m68k_target::low_breakpoint_at): ...this.
902 (the_low_target): Remove the op field.
903 * linux-mips-low.cc (class mips_target)
904 <low_breakpoint_at>: Declare.
905 (mips_breakpoint_at): Turn into...
906 (mips_target::low_breakpoint_at): ...this.
907 (the_low_target): Remove the op field.
908 * linux-nios2-low.cc (class nios2_target)
909 <low_breakpoint_at>: Declare.
910 (nios2_breakpoint_at): Turn into...
911 (nios2_target::low_breakpoint_at): ...this.
912 (the_low_target): Remove the op field.
913 * linux-ppc-low.cc (class ppc_target)
914 <low_breakpoint_at>: Declare.
915 (ppc_breakpoint_at): Turn into...
916 (ppc_target::low_breakpoint_at): ...this.
917 (the_low_target): Remove the op field.
918 * linux-riscv-low.cc (class riscv_target)
919 <low_breakpoint_at>: Declare.
920 (riscv_breakpoint_at): Turn into...
921 (riscv_target::low_breakpoint_at): ...this.
922 (the_low_target): Remove the op field.
923 * linux-s390-low.cc (class s390_target)
924 <low_breakpoint_at>: Declare.
925 (s390_breakpoint_at): Turn into...
926 (s390_target::low_breakpoint_at): ...this.
927 (the_low_target): Remove the op field.
928 * linux-sh-low.cc (class sh_target)
929 <low_breakpoint_at>: Declare.
930 (sh_breakpoint_at): Turn into...
931 (sh_target::low_breakpoint_at): ...this.
932 (the_low_target): Remove the op field.
933 * linux-sparc-low.cc (class sparc_target)
934 <low_breakpoint_at>: Declare.
935 (sparc_breakpoint_at): Turn into...
936 (sparc_target::low_breakpoint_at): ...this.
937 (the_low_target): Remove the op field.
938 * linux-tic6x-low.cc (class tic6x_target)
939 <low_breakpoint_at>: Declare.
940 (tic6x_breakpoint_at): Turn into...
941 (tic6x_target::low_breakpoint_at): ...this.
942 (the_low_target): Remove the op field.
943 * linux-tile-low.cc (class tile_target)
944 <low_breakpoint_at>: Declare.
945 (tile_breakpoint_at): Turn into...
946 (tile_target::low_breakpoint_at): ...this.
947 (the_low_target): Remove the op field.
948 * linux-xtensa-low.cc (class xtensa_target)
949 <low_breakpoint_at>: Declare.
950 (xtensa_breakpoint_at): Turn into...
951 (xtensa_target::low_breakpoint_at): ...this.
952 (the_low_target): Remove the op field.
953
d4807ea2
TBA
9542020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
955
956 Turn the 'decr_pc_after_break' linux_target_ops field into
957 a method of linux_process_target.
958
959 * linux-low.h (struct linux_target_ops)
960 <decr_pc_after_break>: Remove.
961 (class linux_process_target) <low_decr_pc_after_break>: New method
962 declaration.
963 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
964 New method implementation.
965
966 Update the users below.
967
968 (linux_process_target::save_stop_reason)
969 (linux_process_target::wait_1)
970 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
971 New declaration.
972 (x86_target::low_decr_pc_after_break): New method implementation.
973 (the_low_target): Remove the field.
974 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
975 New declaration.
976 (bfin_target::low_decr_pc_after_break): New method implementation.
977 (the_low_target): Remove the field.
978 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
979 New declaration.
980 (m68k_target::low_decr_pc_after_break): New method implementation.
981 (the_low_target): Remove the field.
982 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
983 New declaration.
984 (s390_target::low_decr_pc_after_break): New method implementation.
985 (the_low_target): Remove the field.
986 * linux-aarch64-low.cc (the_low_target): Remove the field.
987 * linux-arm-low.cc (the_low_target): Remove the field.
988 * linux-cris-low.cc (the_low_target): Remove the field.
989 * linux-crisv32-low.cc (the_low_target): Remove the field.
990 * linux-m32r-low.cc (the_low_target): Remove the field.
991 * linux-mips-low.cc (the_low_target): Remove the field.
992 * linux-nios2-low.cc (the_low_target): Remove the field.
993 * linux-ppc-low.cc (the_low_target): Remove the field.
994 * linux-riscv-low.cc (the_low_target): Remove the field.
995 * linux-sh-low.cc (the_low_target): Remove the field.
996 * linux-sparc-low.cc (the_low_target): Remove the field.
997 * linux-tic6x-low.cc (the_low_target): Remove the field.
998 * linux-tile-low.cc (the_low_target): Remove the field.
999 * linux-xtensa-low.cc (the_low_target): Remove the field.
1000
7582c77c
TBA
10012020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1002
1003 Remove the 'supports_software_single_step' linux target op and let
1004 the concrete linux target define it by overriding the op in
1005 process_stratum_target.
1006 Turn the 'get_next_pcs' linux target op into a method of
1007 linux_process_target.
1008
1009 * linux-low.h (struct linux_target_ops): Remove the ops.
1010 (class linux_process_target) <supports_software_single_step>:
1011 Remove.
1012 <low_get_next_pcs>: Declare.
1013 * linux-low.cc (can_software_single_step): Remove.
1014 (linux_process_target::low_get_next_pcs): Define.
1015 (linux_process_target::supports_software_single_step): Remove.
1016
1017 Update the callers below.
1018
1019 (linux_process_target::handle_extended_wait)
1020 (linux_process_target::wait_1)
1021 (linux_process_target::install_software_single_step_breakpoints)
1022 (linux_process_target::single_step)
1023 (linux_process_target::thread_needs_step_over)
1024 (linux_process_target::proceed_one_lwp)
1025 (linux_process_target::supports_range_stepping)
1026
1027 * linux-x86-low.cc (the_low_target): Remove the op field.
1028 * linux-aarch64-low.cc (the_low_target): Ditto.
1029 * linux-bfin-low.cc (the_low_target): Ditto.
1030 * linux-cris-low.cc (the_low_target): Ditto.
1031 * linux-crisv32-low.cc (the_low_target): Ditto.
1032 * linux-m32r-low.cc (the_low_target): Ditto.
1033 * linux-m68k-low.cc (the_low_target): Ditto.
1034 * linux-mips-low.cc (the_low_target): Ditto.
1035 * linux-nios2-low.cc (the_low_target): Ditto.
1036 * linux-ppc-low.cc (the_low_target): Ditto.
1037 * linux-riscv-low.cc (the_low_target): Ditto.
1038 * linux-s390-low.cc (the_low_target): Ditto.
1039 * linux-sh-low.cc (the_low_target): Ditto.
1040 * linux-sparc-low.cc (the_low_target): Ditto.
1041 * linux-tic6x-low.cc (the_low_target): Ditto.
1042 * linux-tile-low.cc (the_low_target): Ditto.
1043 * linux-xtensa-low.cc (the_low_target): Ditto.
1044 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1045 <supports_software_single_step>: Declare.
1046 (arm_target::supports_software_single_step): Define.
1047 (arm_gdbserver_get_next_pcs): Turn into...
1048 (arm_target::low_get_next_pcs): ...this.
1049 (the_low_target): Remove the op field.
1050
3ca4edb6
TBA
10512020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1052
1053 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1054 the concrete linux target define it by overriding the op
1055 in process_stratum_target.
1056
1057 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1058 Remove.
1059 * linux-low.h (struct linux_target_ops): Remove the op.
1060 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1061 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1062 Declare.
1063 (x86_sw_breakpoint_from_kind): Turn into...
1064 (x86_target::sw_breakpoint_from_kind): ...this.
1065 (the_low_target): Remove the op field.
1066 * linux-aarch64-low.cc (class aarch64_target)
1067 <sw_breakpoint_from_kind>: Declare.
1068 (aarch64_sw_breakpoint_from_kind): Turn into...
1069 (aarch64_target::sw_breakpoint_from_kind): ...this.
1070 (the_low_target): Remove the op field.
1071 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1072 Declare.
1073 (arm_target::sw_breakpoint_from_kind): Define.
1074 (the_low_target): Remove the op field.
1075 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1076 Declare.
1077 (bfin_sw_breakpoint_from_kind): Turn into...
1078 (bfin_target::sw_breakpoint_from_kind): ...this.
1079 (the_low_target): Remove the op field.
1080 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1081 Declare.
1082 (cris_sw_breakpoint_from_kind): Turn into...
1083 (cris_target::sw_breakpoint_from_kind): ...this.
1084 (the_low_target): Remove the op field.
1085 * linux-crisv32-low.cc (class crisv32_target)
1086 <sw_breakpoint_from_kind>: Declare.
1087 (cris_sw_breakpoint_from_kind): Turn into...
1088 (crisv32_target::sw_breakpoint_from_kind): ...this.
1089 (the_low_target): Remove the op field.
1090 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1091 Declare.
1092 (ia64_target::sw_breakpoint_from_kind): Define.
1093 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1094 Declare.
1095 (m32r_sw_breakpoint_from_kind): Turn into...
1096 (m32r_target::sw_breakpoint_from_kind): ...this.
1097 (the_low_target): Remove the op field.
1098 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1099 Declare.
1100 (m68k_sw_breakpoint_from_kind): Turn into...
1101 (m68k_target::sw_breakpoint_from_kind): ...this.
1102 (the_low_target): Remove the op field.
1103 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1104 Declare.
1105 (mips_sw_breakpoint_from_kind): Turn into...
1106 (mips_target::sw_breakpoint_from_kind): ...this.
1107 (the_low_target): Remove the op field.
1108 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1109 Declare.
1110 (nios2_sw_breakpoint_from_kind): Turn into...
1111 (nios2_target::sw_breakpoint_from_kind): ...this.
1112 (the_low_target): Remove the op field.
1113 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1114 Declare.
1115 (ppc_sw_breakpoint_from_kind): Turn into...
1116 (ppc_target::sw_breakpoint_from_kind): ...this.
1117 (the_low_target): Remove the op field.
1118 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1119 Declare.
1120 (riscv_sw_breakpoint_from_kind): Turn into...
1121 (riscv_target::sw_breakpoint_from_kind): ...this.
1122 (the_low_target): Remove the op field.
1123 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1124 Declare.
1125 (s390_sw_breakpoint_from_kind): Turn into...
1126 (s390_target::sw_breakpoint_from_kind): ...this.
1127 (the_low_target): Remove the op field.
1128 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1129 Declare.
1130 (sh_sw_breakpoint_from_kind): Turn into...
1131 (sh_target::sw_breakpoint_from_kind): ...this.
1132 (the_low_target): Remove the op field.
1133 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1134 Declare.
1135 (sparc_sw_breakpoint_from_kind): Turn into...
1136 (sparc_target::sw_breakpoint_from_kind): ...this.
1137 (the_low_target): Remove the op field.
1138 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1139 Declare.
1140 (tic6x_sw_breakpoint_from_kind): Turn into...
1141 (tic6x_target::sw_breakpoint_from_kind): ...this.
1142 (the_low_target): Remove the op field.
1143 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1144 Declare.
1145 (tile_sw_breakpoint_from_kind): Turn into...
1146 (tile_target::sw_breakpoint_from_kind): ...this.
1147 (the_low_target): Remove the op field.
1148 * linux-xtensa-low.cc (class xtensa_target)
1149 <sw_breakpoint_from_kind>: Declare.
1150 (xtensa_sw_breakpoint_from_kind): Turn into...
1151 (xtensa_target::sw_breakpoint_from_kind): ...this.
1152 (the_low_target): Remove the op field.
1153
06250e4e
TBA
11542020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1155
1156 Remove the 'breakpoint_kind_from_pc' and
1157 'breakpoint_kind_from_current_state' linux target ops, and let the
1158 concrete linux target define them by overriding the ops of
1159 process_stratum_target.
1160
1161 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1162 Remove.
1163 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1164 * linux-low.h (struct linux_target_ops): Remove ops.
1165 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1166 <breakpoint_kind_from_current_state>: Remove.
1167 * linux-x86-low.cc (the_low_target): Remove the op fields.
1168 * linux-bfin-low.cc (the_low_target): Ditto.
1169 * linux-cris-low.cc (the_low_target): Ditto.
1170 * linux-crisv32-low.cc (the_low_target): Ditto.
1171 * linux-m32r-low.cc (the_low_target): Ditto.
1172 * linux-m68k-low.cc (the_low_target): Ditto.
1173 * linux-mips-low.cc (the_low_target): Ditto.
1174 * linux-nios2-low.cc (the_low_target): Ditto.
1175 * linux-ppc-low.cc (the_low_target): Ditto.
1176 * linux-s390-low.cc (the_low_target): Ditto.
1177 * linux-sh-low.cc (the_low_target): Ditto.
1178 * linux-sparc-low.cc (the_low_target): Ditto.
1179 * linux-tic6x-low.cc (the_low_target): Ditto.
1180 * linux-tile-low.cc (the_low_target): Ditto.
1181 * linux-xtensa-low.cc (the_low_target): Ditto.
1182 * linux-aarch64-low.cc (class aarch64_target)
1183 <breakpoint_kind_from_pc>
1184 <breakpoint_kind_from_current_state>: Declare.
1185 (aarch64_breakpoint_kind_from_pc): Turn into...
1186 (aarch64_target::breakpoint_kind_from_pc): ...this.
1187 (aarch64_breakpoint_kind_from_current_state): Turn into...
1188 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1189 (the_low_target): Remove the op fields.
1190 * linux-arm-low.cc (class arm_target):
1191 <breakpoint_kind_from_pc>
1192 <breakpoint_kind_from_current_state>: Declare.
1193 (arm_target::breakpoint_kind_from_pc): Define.
1194 (arm_target::breakpoint_kind_from_current_state): Define.
1195 (the_low_target): Remove the op fields.
1196 * linux-riscv-low.cc (class riscv_target):
1197 <breakpoint_kind_from_pc>: Declare.
1198 (riscv_breakpoint_kind_from_pc): Turn into...
1199 (riscv_target::breakpoint_kind_from_pc): ...this.
1200 (the_low_target): Remove the op fields.
1201
bf9ae9d8
TBA
12022020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1203
1204 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1205 of linux_process_target.
1206
1207 * linux-low.h (struct linux_target_ops): Remove the ops.
1208 (class linux_process_target) <low_supports_breakpoints>
1209 <low_get_pc>
1210 <low_set_pc>: Declare.
1211 * linux-low.cc (supports_breakpoints): Turn into...
1212 (linux_process_target::low_supports_breakpoints): ...this.
1213 (linux_process_target::low_get_pc): Define.
1214 (linux_process_target::low_set_pc): Define.
1215
1216 Update the callers below.
1217
1218 (linux_process_target::get_pc)
1219 (linux_process_target::save_stop_reason)
1220 (linux_process_target::maybe_move_out_of_jump_pad)
1221 (linux_process_target::wait_1)
1222 (linux_process_target::resume_one_lwp_throw)
1223 (linux_process_target::resume)
1224 (linux_process_target::proceed_all_lwps)
1225 (linux_process_target::read_pc)
1226 (linux_process_target::write_pc)
1227
1228 * linux-x86-low.cc (class linux_process_target)
1229 <low_supports_breakpoints>
1230 <low_get_pc>
1231 <low_set_pc>: Declare.
1232 (x86_target::low_supports_breakpoints): Define.
1233 (x86_get_pc): Turn into...
1234 (x86_target::low_get_pc): ...this.
1235 (x86_set_pc): Turn into...
1236 (x86_target::low_set_pc): ...this.
1237 (the_low_target): Remove the op fields.
1238 * linux-arm-low.cc (class arm_target)
1239 <low_supports_breakpoints>
1240 <low_get_pc>
1241 <low_set_pc>: Declare.
1242 (arm_target::low_supports_breakpoints)
1243 (arm_target::low_get_pc)
1244 (arm_target::low_set_pc): Define.
1245 (the_low_target): Remove the op fields.
1246 * linux-bfin-low.cc (class bfin_target)
1247 <low_supports_breakpoints>
1248 <low_get_pc>
1249 <low_set_pc>: Declare.
1250 (bfin_target::low_supports_breakpoints)
1251 (bfin_target::low_get_pc)
1252 (bfin_target::low_set_pc): Define.
1253 (the_low_target): Remove the op fields.
1254 * linux-cris-low.cc (class cris_target)
1255 <low_supports_breakpoints>
1256 <low_get_pc>
1257 <low_set_pc>: Declare.
1258 (cris_target::low_supports_breakpoints)
1259 (cris_target::low_get_pc)
1260 (cris_target::low_set_pc): Define.
1261 (the_low_target): Remove the op fields.
1262 * linux-crisv32-low.cc (class crisv32_target)
1263 <low_supports_breakpoints>
1264 <low_get_pc>
1265 <low_set_pc>: Declare.
1266 (crisv32_target::low_supports_breakpoints)
1267 (crisv32_target::low_get_pc)
1268 (crisv32_target::low_set_pc): Define.
1269 (the_low_target): Remove the op fields.
1270 * linux-m32r-low.cc (class m32r_target)
1271 <low_supports_breakpoints>
1272 <low_get_pc>
1273 <low_set_pc>: Declare.
1274 (m32r_target::low_supports_breakpoints)
1275 (m32r_target::low_get_pc)
1276 (m32r_target::low_set_pc): Define.
1277 (the_low_target): Remove the op fields.
1278 * linux-m68k-low.cc (class m68k_target)
1279 <low_supports_breakpoints>
1280 <low_get_pc>
1281 <low_set_pc>: Declare.
1282 (m68k_target::low_supports_breakpoints)
1283 (m68k_target::low_get_pc)
1284 (m68k_target::low_set_pc): Define.
1285 (the_low_target): Remove the op fields.
1286 * linux-nios2-low.cc (class nios2_target)
1287 <low_supports_breakpoints>
1288 <low_get_pc>
1289 <low_set_pc>: Declare.
1290 (nios2_target::low_supports_breakpoints)
1291 (nios2_target::low_get_pc)
1292 (nios2_target::low_set_pc): Define.
1293 (the_low_target): Remove the op fields.
1294 * linux-sh-low.cc (class sh_target)
1295 <low_supports_breakpoints>
1296 <low_get_pc>
1297 <low_set_pc>: Declare.
1298 (sh_target::low_supports_breakpoints)
1299 (sh_target::low_get_pc)
1300 (sh_target::low_set_pc): Define.
1301 (the_low_target): Remove the op fields.
1302 * linux-xtensa-low.cc (class xtensa_target)
1303 <low_supports_breakpoints>
1304 <low_get_pc>
1305 <low_set_pc>: Declare.
1306 (xtensa_target::low_supports_breakpoints)
1307 (xtensa_target::low_get_pc)
1308 (xtensa_target::low_set_pc): Define.
1309 (the_low_target): Remove the op fields.
1310 * linux-sparc-low.cc (class sparc_target)
1311 <low_supports_breakpoints>
1312 <low_get_pc>: Declare.
1313 (sparc_target::low_supports_breakpoints)
1314 (sparc_target::low_get_pc): Define.
1315 (the_low_target): Remove the op fields.
1316 * linux-tile-low.cc (class tile_target)
1317 <low_supports_breakpoints>
1318 <low_get_pc>
1319 <low_set_pc>: Declare.
1320 (tile_target::low_supports_breakpoints)
1321 (tile_target::low_get_pc)
1322 (tile_target::low_set_pc): Define.
1323 (the_low_target): Remove the op fields.
1324 * linux-aarch64-low.cc (class aarch64_target)
1325 <low_supports_breakpoints>
1326 <low_get_pc>
1327 <low_set_pc>: Declare.
1328 (aarch64_target::low_supports_breakpoints): Define.
1329 (aarch64_get_pc): Turn into...
1330 (aarch64_target::low_get_pc): ...this.
1331 (aarch64_set_pc): Turn into...
1332 (aarch64_target::low_set_pc): ...this.
1333 (the_low_target): Remove the op fields.
1334 * linux-mips-low.cc (class mips_target)
1335 <low_supports_breakpoints>
1336 <low_get_pc>
1337 <low_set_pc>: Declare.
1338 (mips_target::low_supports_breakpoints): Define.
1339 (mips_get_pc): Turn into...
1340 (mips_target::low_get_pc): ...this.
1341 (mips_set_pc): Turn into...
1342 (mips_target::low_set_pc): ...this.
1343 (the_low_target): Remove the op fields.
1344 * linux-ppc-low.cc (class ppc_target)
1345 <low_supports_breakpoints>
1346 <low_get_pc>
1347 <low_set_pc>: Declare.
1348 (ppc_target::low_supports_breakpoints): Define.
1349 (ppc_get_pc): Turn into...
1350 (ppc_target::low_get_pc): ...this.
1351 (ppc_set_pc): Turn into...
1352 (ppc_target::low_set_pc): ...this.
1353 (the_low_target): Remove the op fields.
1354 * linux-riscv-low.cc (class riscv_target)
1355 <low_supports_breakpoints>
1356 <low_get_pc>
1357 <low_set_pc>: Declare.
1358 (riscv_target::low_supports_breakpoints): Define.
1359 (riscv_get_pc): Turn into...
1360 (riscv_target::low_get_pc): ...this.
1361 (riscv_set_pc): Turn into...
1362 (riscv_target::low_set_pc): ...this.
1363 (the_low_target): Remove the op fields.
1364 * linux-s390-low.cc (class s390_target)
1365 <low_supports_breakpoints>
1366 <low_get_pc>
1367 <low_set_pc>: Declare.
1368 (s390_target::low_supports_breakpoints): Define.
1369 (s390_get_pc): Turn into...
1370 (s390_target::low_get_pc): ...this.
1371 (s390_set_pc): Turn into...
1372 (s390_target::low_set_pc): ...this.
1373 (the_low_target): Remove the op fields.
1374 * linux-tic6x-low.cc (class tic6x_target)
1375 <low_supports_breakpoints>
1376 <low_get_pc>
1377 <low_set_pc>: Declare.
1378 (tic6x_target::low_supports_breakpoints): Define.
1379 (tic6x_get_pc): Turn into...
1380 (tic6x_target::low_get_pc): ...this.
1381 (tic6x_set_pc): Turn into...
1382 (tic6x_target::low_set_pc): ...this.
1383 (the_low_target): Remove the op fields.
1384
df95181f
TBA
13852020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1386
1387 Turn some more static methods in linux-low into private methods
1388 of linux_process_target.
1389
1390 * linux-low.cc (get_pc): Turn into...
1391 (linux_process_target::get_pc): ...this.
1392 (save_stop_reason): Turn into...
1393 (linux_process_target::save_stop_reason): ...this.
1394 (thread_still_has_status_pending_p): Turn into...
1395 (linux_process_target::thread_still_has_status_pending): ...this.
1396 (status_pending_p_callback): Turn into...
1397 (linux_process_target::status_pending_p_callback): ...this.
1398 (resume_stopped_resumed_lwps): Turn into...
1399 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1400 (install_software_single_step_breakpoints): Turn into...
1401 (linux_process_target::install_software_single_step_breakpoints):
1402 ...this.
1403 (single_step): Turn into...
1404 (linux_process_target::single_step): ...this.
1405 (linux_resume_one_lwp_throw): Turn into...
1406 (linux_process_target::resume_one_lwp_throw): ...this.
1407 (linux_resume_one_lwp): Turn into...
1408 (linux_process_target::resume_one_lwp): ...this.
1409 (resume_status_pending_p): Turn into...
1410 (linux_process_target::resume_status_pending): ...this.
1411 (need_step_over_p): Turn into...
1412 (linux_process_target::thread_needs_step_over): ...this.
1413 (linux_resume_one_thread): Turn into...
1414 (linux_process_target::resume_one_thread): ...this.
1415 (proceed_one_lwp): Turn into...
1416 (linux_process_target::proceed_one_lwp): ...this.
1417 (unsuspend_and_proceed_one_lwp): Turn into...
1418 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1419
1420 Update the calls/references to the above functions below.
1421
1422 (linux_process_target::handle_extended_wait)
1423 (linux_process_target::filter_event)
1424 (linux_process_target::wait_for_event_filtered)
1425 (linux_process_target::wait_1)
1426 (linux_process_target::move_out_of_jump_pad)
1427 (linux_process_target::start_step_over)
1428 (linux_process_target::resume)
1429 (linux_process_target::proceed_all_lwps)
1430 (regsets_store_inferior_registers)
1431 (linux_process_target::store_register)
1432
1433 * linux-low.h (class linux_process_target)
1434 <get_pc>
1435 <save_stop_reason>
1436 <thread_still_has_status_pending>
1437 <status_pending_p_callback>
1438 <resume_stopped_resumed_lwps>
1439 <install_software_single_step_breakpoints>
1440 <single_step>
1441 <resume_one_lwp_throw>
1442 <resume_one_lwp>
1443 <resume_status_pending>
1444 <thread_needs_step_over>
1445 <resume_one_thread>
1446 <proceed_one_lwp>
1447 <unsuspend_and_proceed_one_lwp>: Declare.
1448
bd70b1f2
TBA
14492020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1450
1451 Turn the 'fetch_register' linux target op into a method of
1452 linux_process_target.
1453
1454 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1455 (class linux_process_target) <low_fetch_register>: Declare.
1456 * linux-x86-low.cc (the_low_target)
1457 * linux-aarch64-low.cc (the_low_target)
1458 * linux-arm-low.cc (the_low_target)
1459 * linux-bfin-low.cc (the_low_target)
1460 * linux-cris-low.cc (the_low_target)
1461 * linux-crisv32-low.cc (the_low_target)
1462 * linux-m32r-low.cc (the_low_target)
1463 * linux-m68k-low.cc (the_low_target)
1464 * linux-nios2-low.cc (the_low_target)
1465 * linux-ppc-low.cc (the_low_target)
1466 * linux-s390-low.cc (the_low_target)
1467 * linux-sh-low.cc (the_low_target)
1468 * linux-sparc-low.cc (the_low_target)
1469 * linux-tic6x-low.cc (the_low_target)
1470 * linux-tile-low.cc (the_low_target)
1471 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1472 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1473 Declare.
1474 (ia64_fetch_register): Turn into...
1475 (ia64_target::low_fetch_register): ...this.
1476 (the_low_target): Remove the op field.
1477 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1478 Declare.
1479 (mips_fetch_register): Turn into...
1480 (mips_target::low_fetch_register): ...this.
1481 (the_low_target): Remove the op field.
1482 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1483 Declare.
1484 (riscv_fetch_register): Turn into...
1485 (riscv_target::low_fetch_register): ...this.
1486 (the_low_target): Remove the op field.
1487
1488 Update the callers below.
1489
1490 * linux-low.cc (linux_process_target::fetch_registers)
1491 (linux_process_target::low_fetch_register)
1492
daca57a7
TBA
14932020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1494
1495 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1496 linux target ops into methods of linux_process_target.
1497
1498 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1499 (class linux_process_target) <fetch_register>
1500 <store_register>
1501 <usr_fetch_inferior_registers>
1502 <usr_store_inferior_registers>
1503 <low_cannot_fetch_register>
1504 <low_cannot_fetch_register> Declare.
1505 * linux-low.cc (fetch_register): Turn into...
1506 (linux_process_target::fetch_register): ...this.
1507 (store_register): Turn into ...
1508 (linux_process_target::store_register): ...this.
1509 (usr_fetch_inferior_registers): Turn into...
1510 (linux_process_target::usr_fetch_inferior_registers): ...this.
1511 (usr_store_inferior_registers): Turn into...
1512 (linux_process_target::usr_store_inferior_registers): ...this.
1513 * linux-x86-low.cc (class x86_target)
1514 <low_cannot_fetch_register>
1515 <low_cannot_store_register>: Declare.
1516 (x86_cannot_store_register): Turn into...
1517 (x86_target::low_cannot_store_register): ...this.
1518 (x86_cannot_fetch_register): Turn into...
1519 (x86_target::low_cannot_fetch_register): ...this.
1520 (the_low_target): Remove the target op fields.
1521 * linux-aarch64-low.cc (class aarch64_target)
1522 <low_cannot_fetch_register>
1523 <low_cannot_store_register>: Declare.
1524 (aarch64_target::low_cannot_fetch_register)
1525 (aarch64_target::low_cannot_store_register): Define.
1526 (the_low_target): Remove the op fields.
1527 * linux-arm-low.cc (class arm_target)
1528 <low_cannot_fetch_register>
1529 <low_cannot_store_register>: Declare.
1530 (arm_cannot_fetch_register): Turn into...
1531 (arm_target::low_cannot_fetch_register): ...this.
1532 (arm_cannot_store_register): Turn into...
1533 (arm_target::low_cannot_store_register): ...this.
1534 (the_low_target): Remove the op fields.
1535 * linux-bfin-low.cc (class bfin_target)
1536 <low_cannot_fetch_register>
1537 <low_cannot_store_register>: Declare.
1538 (bfin_cannot_fetch_register): Turn into...
1539 (bfin_target::low_cannot_fetch_register): ...this.
1540 (bfin_cannot_store_register): Turn into...
1541 (bfin_target::low_cannot_store_register): ...this.
1542 (the_low_target): Remove the op fields.
1543 * linux-cris-low.cc (class cris_target)
1544 <low_cannot_fetch_register>
1545 <low_cannot_store_register>: Declare.
1546 (cris_cannot_fetch_register): Turn into...
1547 (cris_target::low_cannot_fetch_register): ...this.
1548 (cris_cannot_store_register): Turn into...
1549 (cris_target::low_cannot_store_register): ...this.
1550 (the_low_target): Remove the op fields.
1551 * linux-crisv32-low.cc (class crisv32_target)
1552 <low_cannot_fetch_register>
1553 <low_cannot_store_register>: Declare.
1554 (crisv32_target::low_cannot_fetch_register)
1555 (crisv32_target::low_cannot_store_register): Define.
1556 (the_low_target): Remove the op fields.
1557 * linux-ia64-low.cc (class ia64_target)
1558 <low_cannot_fetch_register>
1559 <low_cannot_store_register>: Declare.
1560 (ia64_cannot_fetch_register): Turn into...
1561 (ia64_target::low_cannot_fetch_register): ...this.
1562 (ia64_cannot_store_register): Turn into...
1563 (ia64_target::low_cannot_store_register): ...this.
1564 (the_low_target): Remove the op fields.
1565 * linux-m32r-low.cc (class m32r_target)
1566 <low_cannot_fetch_register>
1567 <low_cannot_store_register>: Declare.
1568 (m32r_cannot_fetch_register): Turn into...
1569 (m32r_target::low_cannot_fetch_register): ...this.
1570 (m32r_cannot_store_register): Turn into...
1571 (m32r_target::low_cannot_store_register): ...this.
1572 (the_low_target): Remove the op fields.
1573 * linux-m68k-low.cc (class m68k_target)
1574 <low_cannot_fetch_register>
1575 <low_cannot_store_register>: Declare.
1576 (m68k_cannot_fetch_register): Turn into...
1577 (m68k_target::low_cannot_fetch_register): ...this.
1578 (m68k_cannot_store_register): Turn into...
1579 (m68k_target::low_cannot_store_register): ...this.
1580 (the_low_target): Remove the op fields.
1581 * linux-mips-low.cc (class mips_target)
1582 <low_cannot_fetch_register>
1583 <low_cannot_store_register>: Declare.
1584 (mips_cannot_fetch_register): Turn into...
1585 (mips_target::low_cannot_fetch_register): ...this.
1586 (mips_cannot_store_register): Turn into...
1587 (mips_target::low_cannot_store_register): ...this.
1588 (get_usrregs_info): Inline at the call sites in
1589 low_cannot_fetch_register and low_cannot_store_register,
1590 and remove.
1591 (the_low_target): Remove the op fields.
1592 * linux-nios2-low.cc (class nios2_target)
1593 <low_cannot_fetch_register>
1594 <low_cannot_store_register>: Declare.
1595 (nios2_cannot_fetch_register): Turn into...
1596 (nios2_target::low_cannot_fetch_register): ...this.
1597 (nios2_cannot_store_register): Turn into...
1598 (nios2_target::low_cannot_store_register): ...this.
1599 (the_low_target): Remove the op fields.
1600 * linux-ppc-low.cc (class ppc_target)
1601 <low_cannot_fetch_register>
1602 <low_cannot_store_register>: Declare.
1603 (ppc_cannot_fetch_register): Turn into...
1604 (ppc_target::low_cannot_fetch_register): ...this.
1605 (ppc_cannot_store_register): Turn into...
1606 (ppc_target::low_cannot_store_register): ...this.
1607 (the_low_target): Remove the op fields.
1608 * linux-riscv-low.cc (class riscv_target)
1609 <low_cannot_fetch_register>
1610 <low_cannot_store_register>: Declare.
1611 (riscv_target::low_cannot_fetch_register)
1612 (riscv_target::low_cannot_store_register): Define.
1613 (the_low_target): Remove the op fields.
1614 * linux-s390-low.cc (class s390_target)
1615 <low_cannot_fetch_register>
1616 <low_cannot_store_register>: Declare.
1617 (s390_cannot_fetch_register): Turn into...
1618 (s390_target::low_cannot_fetch_register): ...this.
1619 (s390_cannot_store_register): Turn into...
1620 (s390_target::low_cannot_store_register): ...this.
1621 (the_low_target): Remove the op fields.
1622 * linux-sh-low.cc (class sh_target)
1623 <low_cannot_fetch_register>
1624 <low_cannot_store_register>: Declare.
1625 (sh_cannot_fetch_register): Turn into...
1626 (sh_target::low_cannot_fetch_register): ...this.
1627 (sh_cannot_store_register): Turn into...
1628 (sh_target::low_cannot_store_register): ...this.
1629 (the_low_target): Remove the op fields.
1630 * linux-sparc-low.cc (class sparc_target)
1631 <low_cannot_fetch_register>
1632 <low_cannot_store_register>: Declare.
1633 (sparc_cannot_fetch_register): Turn into...
1634 (sparc_target::low_cannot_fetch_register): ...this.
1635 (sparc_cannot_store_register): Turn into...
1636 (sparc_target::low_cannot_store_register): ...this.
1637 (the_low_target): Remove the op fields.
1638 * linux-tic6x-low.cc (class tic6x_target)
1639 <low_cannot_fetch_register>
1640 <low_cannot_store_register>: Declare.
1641 (tic6x_cannot_fetch_register): Turn into...
1642 (tic6x_target::low_cannot_fetch_register): ...this.
1643 (tic6x_cannot_store_register): Turn into...
1644 (tic6x_target::low_cannot_store_register): ...this.
1645 (the_low_target): Remove the op fields.
1646 * linux-tile-low.cc (class tile_target)
1647 <low_cannot_fetch_register>
1648 <low_cannot_store_register>: Declare.
1649 (tile_cannot_fetch_register): Turn into...
1650 (tile_target::low_cannot_fetch_register): ...this.
1651 (tile_cannot_store_register): Turn into...
1652 (tile_target::low_cannot_store_register): ...this.
1653 (the_low_target): Remove the op fields.
1654 * linux-xtensa-low.cc (class xtensa_target)
1655 <low_cannot_fetch_register>
1656 <low_cannot_store_register>: Declare.
1657 (xtensa_target::low_cannot_fetch_register)
1658 (xtensa_target::low_cannot_store_register): Define.
1659 (the_low_target): Remove the op fields.
1660
aa8d21c9
TBA
16612020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1662
1663 Turn the 'regs_info' linux target op into a method of
1664 linux_process_target.
1665
1666 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1667 (class linux_process_target) <get_regs_info>: Define.
1668
1669 Update the callers below.
1670
1671 * linux-low.cc (linux_process_target::fetch_registers)
1672 (linux_process_target::store_registers)
1673 * proc-service.cc (gregset_info)
1674
1675 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1676 (x86_linux_regs_info): Turn into ...
1677 (x86_target::get_regs_info): ...this.
1678 (the_low_target): Remove the op field.
1679 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1680 Declare.
1681 (aarch64_regs_info): Turn into ...
1682 (aarch64_target::get_regs_info): ...this.
1683 (the_low_target): Remove the op field.
1684 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1685 (arm_regs_info): Turn into ...
1686 (arm_target::get_regs_info): ...this.
1687 (the_low_target): Remove the op field.
1688 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1689 (bfin_regs_info): Turn into ...
1690 (bfin_target::get_regs_info): ...this.
1691 (the_low_target): Remove the op field.
1692 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1693 (cris_regs_info): Turn into ...
1694 (cris_target::get_regs_info): ...this.
1695 (the_low_target): Remove the op field.
1696 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1697 Declare.
1698 (crisv32_regs_info): Turn into ...
1699 (crisv32_target::get_regs_info): ...this.
1700 (the_low_target): Remove the op field.
1701 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1702 (ia64_regs_info): Turn into ...
1703 (ia64_target::get_regs_info): ...this.
1704 (the_low_target): Remove the op field.
1705 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1706 (m32r_regs_info): Turn into ...
1707 (m32r_target::get_regs_info): ...this.
1708 (the_low_target): Remove the op field.
1709 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1710 (m68k_regs_info): Turn into ...
1711 (m68k_target::get_regs_info): ...this.
1712 (the_low_target): Remove the op field.
1713 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1714 (mips_regs_info): Turn into ...
1715 (mips_target::get_regs_info): ...this.
1716 (the_low_target): Remove the op field.
1717 (get_usrregs_info): Update the call to the op.
1718 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1719 (nios2_regs_info): Turn into ...
1720 (nios2_target::get_regs_info): ...this.
1721 (the_low_target): Remove the op field.
1722 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1723 (ppc_regs_info): Turn into ...
1724 (ppc_target::get_regs_info): ...this.
1725 (the_low_target): Remove the op field.
1726 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1727 (riscv_regs_info): Turn into ...
1728 (riscv_target::get_regs_info): ...this.
1729 (the_low_target): Remove the op field.
1730 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1731 (s390_regs_info): Turn into ...
1732 (s390_target::get_regs_info): ...this.
1733 (the_low_target): Remove the op field.
1734 (s390_collect_ptrace_register)
1735 (s390_supply_ptrace_register)
1736 (s390_fill_gregset): Update the call to the op.
1737 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1738 (sh_regs_info): Turn into ...
1739 (sh_target::get_regs_info): ...this.
1740 (the_low_target): Remove the op field.
1741 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1742 (sparc_regs_info): Turn into ...
1743 (sparc_target::get_regs_info): ...this.
1744 (the_low_target): Remove the op field.
1745 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1746 (tic6x_regs_info): Turn into ...
1747 (tic6x_target::get_regs_info): ...this.
1748 (the_low_target): Remove the op field.
1749 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1750 (tile_regs_info): Turn into ...
1751 (tile_target::get_regs_info): ...this.
1752 (the_low_target): Remove the op field.
1753 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1754 Declare.
1755 (xtensa_regs_info): Turn into ...
1756 (xtensa_target::get_regs_info): ...this.
1757 (the_low_target): Remove the op field.
1758
797bcff5
TBA
17592020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1760
1761 Turn the 'arch_setup' linux target op into a method of
1762 linux_process_target.
1763
1764 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1765 (class linux_process_target) <arch_setup_thread>
1766 <low_arch_setup>: New declarations.
1767 * linux-low.cc (linux_arch_setup): Delete.
1768 (linux_arch_setup_thread): Turn into...
1769 (linux_process_target::arch_setup_thread): ... this.
1770
1771 Update the callers below.
1772
1773 (linux_process_target::handle_extended_wait)
1774 (linux_process_target::post_create_inferior)
1775 (linux_process_target::filter_event)
1776
1777 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1778 declaration.
1779 (x86_linux_update_xmltarget): Turn into...
1780 (x86_target::update_xmltarget): ...this.
1781 (x86_linux_process_qsupported): Update the call to
1782 x86_linux_update_xmltarget.
1783 (x86_arch_setup): Turn into ...
1784 (x86_target::low_arch_setup): ...this.
1785 (the_low_target): Remove the op field.
1786 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1787 declaration.
1788 (aarch64_arch_setup): Turn into ...
1789 (aarch64_target::low_arch_setup): ...this.
1790 (the_low_target): Remove the op field.
1791 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1792 declaration.
1793 (arm_arch_setup): Turn into ...
1794 (arm_target::low_arch_setup): ...this.
1795 (the_low_target): Remove the op field.
1796 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1797 declaration.
1798 (bfin_arch_setup): Turn into ...
1799 (bfin_target::low_arch_setup): ...this.
1800 (the_low_target): Remove the op field.
1801 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1802 declaration.
1803 (cris_arch_setup): Turn into ...
1804 (cris_target::low_arch_setup): ...this.
1805 (the_low_target): Remove the op field.
1806 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1807 declaration.
1808 (crisv32_arch_setup): Turn into ...
1809 (crisv32_target::low_arch_setup): ...this.
1810 (the_low_target): Remove the op field.
1811 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1812 declaration.
1813 (ia64_arch_setup): Turn into ...
1814 (ia64_target::low_arch_setup): ...this.
1815 (the_low_target): Remove the op field.
1816 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1817 declaration.
1818 (m32r_arch_setup): Turn into ...
1819 (m32r_target::low_arch_setup): ...this.
1820 (the_low_target): Remove the op field.
1821 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1822 declaration.
1823 (m68k_arch_setup): Turn into ...
1824 (m68k_target::low_arch_setup): ...this.
1825 (the_low_target): Remove the op field.
1826 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1827 declaration.
1828 (mips_arch_setup): Turn into ...
1829 (mips_target::low_arch_setup): ...this.
1830 (the_low_target): Remove the op field.
1831 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1832 declaration.
1833 (nios2_arch_setup): Turn into ...
1834 (nios2_target::low_arch_setup): ...this.
1835 (the_low_target): Remove the op field.
1836 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1837 declaration.
1838 (ppc_arch_setup): Turn into ...
1839 (ppc_target::low_arch_setup): ...this.
1840 (the_low_target): Remove the op field.
1841 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1842 declaration.
1843 (riscv_arch_setup): Turn into ...
1844 (riscv_target::low_arch_setup): ...this.
1845 (the_low_target): Remove the op field.
1846 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1847 declaration.
1848 (s390_arch_setup): Turn into ...
1849 (s390_target::low_arch_setup): ...this.
1850 (the_low_target): Remove the op field.
1851 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1852 declaration.
1853 (sh_arch_setup): Turn into ...
1854 (sh_target::low_arch_setup): ...this.
1855 (the_low_target): Remove the op field.
1856 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1857 declaration.
1858 (sparc_arch_setup): Turn into ...
1859 (sparc_target::low_arch_setup): ...this.
1860 (the_low_target): Remove the op field.
1861 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1862 declaration.
1863 (tic6x_arch_setup): Turn into ...
1864 (tic6x_target::low_arch_setup): ...this.
1865 (the_low_target): Remove the op field.
1866 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1867 declaration.
1868 (tile_arch_setup): Turn into ...
1869 (tile_target::low_arch_setup): ...this.
1870 (the_low_target): Remove the op field.
1871 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1872 declaration.
1873 (xtensa_arch_setup): Turn into ...
1874 (xtensa_target::low_arch_setup): ...this.
1875 (the_low_target): Remove the op field.
1876
ef0478f6
TBA
18772020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1878
1879 * linux-low.h (the_linux_target): New extern declaration.
1880 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1881 'the_target'.
1882 (the_linux_target): Remove.
1883 * linux-x86-low.cc (class x86_target): New class.
1884 (the_x86_target): New static object.
1885 (the_linux_target): Define as pointer to the_x86_target.
1886 * linux-aarch64-low.cc (class aarch64_target): New class.
1887 (the_aarch64_target): New static object.
1888 (the_linux_target): Define as pointer to the_aarch64_target.
1889 * linux-arm-low.cc (class arm_target): New class.
1890 (the_arm_target): New static object.
1891 (the_linux_target): Define as pointer to the_arm_target.
1892 * linux-bfin-low.cc (class bfin_target): New class.
1893 (the_bfin_target): New static object.
1894 (the_linux_target): Define as pointer to the_bfin_target.
1895 * linux-cris-low.cc (class cris_target): New class.
1896 (the_cris_target): New static object.
1897 (the_linux_target): Define as pointer to the_cris_target.
1898 * linux-crisv32-low.cc (class crisv32_target): New class.
1899 (the_crisv32_target): New static object.
1900 (the_linux_target): Define as pointer to the_crisv32_target.
1901 * linux-ia64-low.cc (class ia64_target): New class.
1902 (the_ia64_target): New static object.
1903 (the_linux_target): Define as pointer to the_ia64_target.
1904 * linux-m32r-low.cc (class m32r_target): New class.
1905 (the_m32r_target): New static object.
1906 (the_linux_target): Define as pointer to the_m32r_target.
1907 * linux-m68k-low.cc (class m68k_target): New class.
1908 (the_m68k_target): New static object.
1909 (the_linux_target): Define as pointer to the_m68k_target.
1910 * linux-mips-low.cc (class mips_target): New class.
1911 (the_mips_target): New static object.
1912 (the_linux_target): Define as pointer to the_mips_target.
1913 * linux-nios2-low.cc (class nios2_target): New class.
1914 (the_nios2_target): New static object.
1915 (the_linux_target): Define as pointer to the_nios2_target.
1916 * linux-ppc-low.cc (class ppc_target): New class.
1917 (the_ppc_target): New static object.
1918 (the_linux_target): Define as pointer to the_ppc_target.
1919 * linux-riscv-low.cc (class riscv_target): New class.
1920 (the_riscv_target): New static object.
1921 (the_linux_target): Define as pointer to the_riscv_target.
1922 * linux-s390-low.cc (class s390_target): New class.
1923 (the_s390_target): New static object.
1924 (the_linux_target): Define as pointer to the_s390_target.
1925 * linux-sh-low.cc (class sh_target): New class.
1926 (the_sh_target): New static object.
1927 (the_linux_target): Define as pointer to the_sh_target.
1928 * linux-sparc-low.cc (class sparc_target): New class.
1929 (the_sparc_target): New static object.
1930 (the_linux_target): Define as pointer to the_sparc_target.
1931 * linux-tic6x-low.cc (class tic6x_target): New class.
1932 (the_tic6x_target): New static object.
1933 (the_linux_target): Define as pointer to the_tic6x_target.
1934 * linux-tile-low.cc (class tile_target): New class.
1935 (the_tile_target): New static object.
1936 (the_linux_target): Define as pointer to the_tile_target.
1937 * linux-xtensa-low.cc (class xtensa_target): New class.
1938 (the_xtensa_target): New static object.
1939 (the_linux_target): Define as pointer to the_xtensa_target.
1940
d16f3f6c
TBA
19412020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1942
1943 Turn some static functions in linux-low.cc into private methods of
1944 linux_process_target.
1945
1946 * linux-low.cc (handle_extended_wait): Turn into ...
1947 (linux_process_target::handle_extended_wait): ...this. Call
1948 'mourn' on 'this' object instead of 'the_target'.
1949 (maybe_move_out_of_jump_pad): Turn into...
1950 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
1951 (linux_low_filter_event): Turn into...
1952 (linux_process_target::filter_event): ...this.
1953 (linux_wait_for_event_filtered): Turn into...
1954 (linux_process_target::wait_for_event_filtered): ...this.
1955 (linux_wait_for_event): Turn into...
1956 (linux_process_target::wait_for_event): ...this.
1957 (linux_wait_1): Turn into...
1958 (linux_process_target::wait_1): ...this.
1959 (wait_for_sigstop): Turn into...
1960 (linux_process_target::wait_for_sigstop): ...this.
1961 (move_out_of_jump_pad_callback): Turn into...
1962 (linux_process_target::move_out_of_jump_pad): ...this.
1963 (stop_all_lwps): Turn into...
1964 (linux_process_target::stop_all_lwps): ...this.
1965 (start_step_over): Turn into...
1966 (linux_process_target::start_step_over): ...this.
1967 (complete_ongoing_step_over): Turn into...
1968 (linux_process_target::complete_ongoing_step_over): ...this.
1969 (proceed_all_lwps): Turn into...
1970 (linux_process_target::proceed_all_lwps): ...this.
1971 (unstop_all_lwps): Turn into...
1972 (linux_process_target::unstop_all_lwps): ...this.
1973
1974 * linux-low.h (class linux_process_target)
1975 <handle_extended_wait>
1976 <maybe_move_out_of_jump_pad>
1977 filter_event>
1978 <wait_for_event_filtered>
1979 <wait_for_event>
1980 <wait_1>
1981 <wait_for_sigstop>
1982 <move_out_of_jump_pad>
1983 <stop_all_lwps>
1984 <start_step_over>
1985 <complete_ongoing_step_over>
1986 <proceed_all_lwps>
1987 <unstop_all_lwps>: Declare.
1988
1989 Update the callers below.
1990
1991 * linux-low.cc (linux_process_target::attach): Update.
1992 (linux_process_target::stabilize_threads): Ditto.
1993 (linux_process_target::wait): Ditto.
1994
a5863204
TBA
19952020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1996
1997 * linux-low.h (struct linux_target_ops): Update the comment for
1998 'cannot_store_register' to return 0 or 1.
1999 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2000 of 2.
2001
c884cc46
SM
20022020-03-20 Simon Marchi <simon.marchi@efficios.com>
2003
2004 * config.in: Re-generate.
2005 * configure: Re-generate.
2006
5a82b8a1
KR
20072020-03-17 Kamil Rytarowski <n54@gmx.com>
2008
2009 * regcache.cc (find_register_by_number): Update.
2010 * tdesc.cc (init_target_desc): Likewise.
2011 * tdesc.h (target_desc::reg_defs): Likewise.
2012
4635ff97
TT
20132020-03-12 Tom Tromey <tom@tromey.com>
2014
2015 * configure: Rebuild.
2016 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2017 (WIN32APILIBS): New subst.
2018 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2019 gdbsupport files.
2020 (gdbsupport/%.o): Remove target.
2021 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2022 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2023 (WIN32APILIBS): New variable.
2024 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2025 (gdbreplay$(EXEEXT)): Likewise.
2026
9a665d62
TT
20272020-03-12 Tom Tromey <tom@tromey.com>
2028
2029 * config.in, configure: Rebuild.
2030 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2031 * acinclude.m4: Include gettext-sister.m4.
2032 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2033 variables.
2034 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2035 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2036
272cd5a3
SM
20372020-03-12 Simon Marchi <simon.marchi@efficios.com>
2038
2039 * acinclude.m4: Update path to selftest.m4.
2040
db6878ac
SM
20412020-03-12 Simon Marchi <simon.marchi@efficios.com>
2042
2043 * configure.ac: Don't source bfd/development.sh, move
2044 GDB_AC_COMMON higher.
2045 * configure: Re-generate.
2046
4d696a5c
SM
20472020-03-12 Simon Marchi <simon.marchi@efficios.com>
2048
2049 * configure: Re-generate.
2050
a0761e34
SM
20512020-03-11 Simon Marchi <simon.marchi@efficios.com>
2052
2053 * configure: Re-generate.
2054
20ea4a60
AB
20552020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2056
2057 * .dir-locals.el: New file.
2058
842806cb
TBA
20592020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2060
2061 * .gitattributes: New file.
2062
442131c1
AB
20632020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2064
2065 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2066 reply into an S reply.
2067 * server.cc (disable_packet_T): New global.
2068 (captured_main): Set new global when appropriate.
2069 * server.h (disable_packet_T): Declare.
2070
dda42c0b
TT
20712020-02-21 Tom Tromey <tom@tromey.com>
2072
2073 * Makefile.in (mostlyclean): New target.
2074
52405d85
TBA
20752020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2076
2077 * target.h (struct process_stratum_target): Remove.
2078 (class process_target): Rename to ...
2079 (class process_stratum_target): ... this.
2080 * linux-low.h (class linux_process_target): Derive from
2081 'process_stratum_target'.
2082 * linux-low.cc (linux_target_ops): Remove.
2083 (initialize_low): Set the_target to the singleton instance of
2084 linux_process_target.
2085 * lynx-low.h (class lynx_process_target): Derive from
2086 'process_stratum_target'.
2087 * lynx-low.cc (lynx_target_ops): Remove.
2088 (initialize_low): Set the_target to the singleton instance of
2089 lynx_process_target.
2090 * nto-low.h (class nto_process_target): Derive from
2091 'process_stratum_target'.
2092 * nto-low.cc (nto_target_ops): Remove.
2093 (initialize_low): Set the_target to the singleton instance of
2094 nto_process_target.
2095 * win32-low.h (class win32_process_target): Derive from
2096 'process_stratum_target'.
2097 * win32-low.cc (win32_target_ops): Remove.
2098 (initialize_low): Set the_target to the singleton instance of
2099 win32_process_target.
2100
2101 Replace 'the_target->pt' with 'the_target' in the uses below.
2102
2103 * hostio.cc (hostio_error)
2104 (handle_setfs)
2105 (handle_open)
2106 (handle_unlink)
2107 (handle_readlink)
2108 * linux-aarch32-low.cc (arm_breakpoint_at)
2109 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2110 * linux-arm-low.cc (arm_sigreturn_next_pc)
2111 (arm_get_hwcap)
2112 (arm_get_syscall_trapinfo)
2113 * linux-cris-low.cc (cris_breakpoint_at)
2114 * linux-crisv32-low.cc (cris_breakpoint_at)
2115 * linux-low.cc (handle_extended_wait)
2116 (linux_wait_1)
2117 (linux_read_memory)
2118 (linux_process_target::breakpoint_kind_from_pc)
2119 (linux_get_auxv)
2120 * linux-m32r-low.cc (m32r_breakpoint_at)
2121 * linux-mips-low.cc (mips_breakpoint_at)
2122 * linux-nios2-low.cc (nios2_breakpoint_at)
2123 * linux-ppc-low.cc (ppc_breakpoint_at)
2124 * linux-s390-low.cc (s390_get_hwcap)
2125 * linux-sh-low.cc (sh_breakpoint_at)
2126 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2127 (sparc_store_gregset_from_stack)
2128 (sparc_breakpoint_at)
2129 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2130 * linux-tile-low.cc (tile_breakpoint_at)
2131 * linux-x86-low.cc (x86_breakpoint_at)
2132 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2133 * mem-break.cc (bp_size)
2134 (bp_opcode)
2135 (insert_memory_breakpoint)
2136 (set_raw_breakpoint_at)
2137 (delete_raw_breakpoint)
2138 (z_type_supported)
2139 (uninsert_raw_breakpoint)
2140 (reinsert_raw_breakpoint)
2141 (validate_inserted_breakpoint)
2142 * regcache.cc (regcache_read_pc)
2143 (regcache_write_pc)
2144 * remote-utils.cc (putpkt_binary_1)
2145 (input_interrupt)
2146 (getpkt)
2147 (prepare_resume_reply)
2148 * server.cc (handle_general_set)
2149 (handle_detach)
2150 (handle_qxfer_auxv)
2151 (handle_qxfer_exec_file)
2152 (handle_qxfer_libraries_svr4)
2153 (handle_qxfer_osdata)
2154 (handle_qxfer_siginfo)
2155 (handle_qxfer_fdpic)
2156 (handle_query)
2157 (resume)
2158 (handle_v_requests)
2159 (queue_stop_reply_callback)
2160 (captured_main)
2161 * target.cc (prepare_to_access_memory)
2162 (done_accessing_memory)
2163 (read_inferior_memory)
2164 (target_write_memory)
2165 (target_stop_and_wait)
2166 (target_wait)
2167 (target_mourn_inferior)
2168 (target_continue_no_signal)
2169 (target_continue)
2170 (target_supports_multi_process)
2171 (kill_inferior)
2172 * target.h
2173 (target_create_inferior)
2174 (target_post_create_inferior)
2175 (myattach)
2176 (target_supports_fork_events)
2177 (target_supports_vfork_events)
2178 (target_supports_exec_events)
2179 (target_handle_new_gdb_connection)
2180 (detach_inferior)
2181 (mythread_alive)
2182 (fetch_inferior_registers)
2183 (store_inferior_registers)
2184 (join_inferior)
2185 (target_supports_non_stop)
2186 (target_async)
2187 (target_process_qsupported)
2188 (target_supports_catch_syscall)
2189 (target_get_ipa_tdesc_idx)
2190 (target_supports_tracepoints)
2191 (target_supports_fast_tracepoints)
2192 (target_get_min_fast_tracepoint_insn_len)
2193 (target_thread_stopped)
2194 (target_pause_all)
2195 (target_unpause_all)
2196 (target_stabilize_threads)
2197 (target_install_fast_tracepoint_jump_pad)
2198 (target_emit_ops)
2199 (target_supports_disable_randomization)
2200 (target_supports_agent)
2201 (target_enable_btrace)
2202 (target_disable_btrace)
2203 (target_read_btrace)
2204 (target_read_btrace_conf)
2205 (target_supports_range_stepping)
2206 (target_supports_stopped_by_sw_breakpoint)
2207 (target_stopped_by_sw_breakpoint)
2208 (target_supports_stopped_by_hw_breakpoint)
2209 (target_supports_hardware_single_step)
2210 (target_stopped_by_hw_breakpoint)
2211 (target_breakpoint_kind_from_pc)
2212 (target_breakpoint_kind_from_current_state)
2213 (target_supports_software_single_step)
2214 (target_core_of_thread)
2215 (target_thread_name)
2216 (target_thread_handle)
2217 * win32-low.cc (do_initial_child_stuff)
2218
2219 Rename target op default definitions listed below.
2220
2221 * target.cc (process_target::post_create_inferior): Rename as ...
2222 (process_stratum_target::post_create_inferior): ... this.
2223 (process_target::prepare_to_access_memory): Rename as ...
2224 (process_stratum_target::prepare_to_access_memory): ... this.
2225 (process_target::done_accessing_memory): Rename as ...
2226 (process_stratum_target::done_accessing_memory): ... this.
2227 (process_target::look_up_symbols): Rename as ...
2228 (process_stratum_target::look_up_symbols): ... this.
2229 (process_target::supports_read_auxv): Rename as ...
2230 (process_stratum_target::supports_read_auxv): ... this.
2231 (process_target::read_auxv): Rename as ...
2232 (process_stratum_target::read_auxv): ... this.
2233 (process_target::supports_z_point_type): Rename as ...
2234 (process_stratum_target::supports_z_point_type): ... this.
2235 (process_target::insert_point): Rename as ...
2236 (process_stratum_target::insert_point): ... this.
2237 (process_target::remove_point): Rename as ...
2238 (process_stratum_target::remove_point): ... this.
2239 (process_target::stopped_by_sw_breakpoint): Rename as ...
2240 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2241 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2242 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2243 (process_target::stopped_by_hw_breakpoint): Rename as ...
2244 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2245 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2246 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2247 (process_target::supports_hardware_single_step): Rename as ...
2248 (process_stratum_target::supports_hardware_single_step): ... this.
2249 (process_target::stopped_by_watchpoint): Rename as ...
2250 (process_stratum_target::stopped_by_watchpoint): ... this.
2251 (process_target::stopped_data_address): Rename as ...
2252 (process_stratum_target::stopped_data_address): ... this.
2253 (process_target::supports_read_offsets): Rename as ...
2254 (process_stratum_target::supports_read_offsets): ... this.
2255 (process_target::read_offsets): Rename as ...
2256 (process_stratum_target::read_offsets): ... this.
2257 (process_target::supports_get_tls_address): Rename as ...
2258 (process_stratum_target::supports_get_tls_address): ... this.
2259 (process_target::get_tls_address): Rename as ...
2260 (process_stratum_target::get_tls_address): ... this.
2261 (process_target::hostio_last_error): Rename as ...
2262 (process_stratum_target::hostio_last_error): ... this.
2263 (process_target::supports_qxfer_osdata): Rename as ...
2264 (process_stratum_target::supports_qxfer_osdata): ... this.
2265 (process_target::qxfer_osdata): Rename as ...
2266 (process_stratum_target::qxfer_osdata): ... this.
2267 (process_target::supports_qxfer_siginfo): Rename as ...
2268 (process_stratum_target::supports_qxfer_siginfo): ... this.
2269 (process_target::qxfer_siginfo): Rename as ...
2270 (process_stratum_target::qxfer_siginfo): ... this.
2271 (process_target::supports_non_stop): Rename as ...
2272 (process_stratum_target::supports_non_stop): ... this.
2273 (process_target::async): Rename as ...
2274 (process_stratum_target::async): ... this.
2275 (process_target::start_non_stop): Rename as ...
2276 (process_stratum_target::start_non_stop): ... this.
2277 (process_target::supports_multi_process): Rename as ...
2278 (process_stratum_target::supports_multi_process): ... this.
2279 (process_target::supports_fork_events): Rename as ...
2280 (process_stratum_target::supports_fork_events): ... this.
2281 (process_target::supports_vfork_events): Rename as ...
2282 (process_stratum_target::supports_vfork_events): ... this.
2283 (process_target::supports_exec_events): Rename as ...
2284 (process_stratum_target::supports_exec_events): ... this.
2285 (process_target::handle_new_gdb_connection): Rename as ...
2286 (process_stratum_target::handle_new_gdb_connection): ... this.
2287 (process_target::handle_monitor_command): Rename as ...
2288 (process_stratum_target::handle_monitor_command): ... this.
2289 (process_target::core_of_thread): Rename as ...
2290 (process_stratum_target::core_of_thread): ... this.
2291 (process_target::supports_read_loadmap): Rename as ...
2292 (process_stratum_target::supports_read_loadmap): ... this.
2293 (process_target::read_loadmap): Rename as ...
2294 (process_stratum_target::read_loadmap): ... this.
2295 (process_target::process_qsupported): Rename as ...
2296 (process_stratum_target::process_qsupported): ... this.
2297 (process_target::supports_tracepoints): Rename as ...
2298 (process_stratum_target::supports_tracepoints): ... this.
2299 (process_target::read_pc): Rename as ...
2300 (process_stratum_target::read_pc): ... this.
2301 (process_target::write_pc): Rename as ...
2302 (process_stratum_target::write_pc): ... this.
2303 (process_target::supports_thread_stopped): Rename as ...
2304 (process_stratum_target::supports_thread_stopped): ... this.
2305 (process_target::thread_stopped): Rename as ...
2306 (process_stratum_target::thread_stopped): ... this.
2307 (process_target::supports_get_tib_address): Rename as ...
2308 (process_stratum_target::supports_get_tib_address): ... this.
2309 (process_target::get_tib_address): Rename as ...
2310 (process_stratum_target::get_tib_address): ... this.
2311 (process_target::pause_all): Rename as ...
2312 (process_stratum_target::pause_all): ... this.
2313 (process_target::unpause_all): Rename as ...
2314 (process_stratum_target::unpause_all): ... this.
2315 (process_target::stabilize_threads): Rename as ...
2316 (process_stratum_target::stabilize_threads): ... this.
2317 (process_target::supports_fast_tracepoints): Rename as ...
2318 (process_stratum_target::supports_fast_tracepoints): ... this.
2319 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2320 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2321 (process_target::emit_ops): Rename as ...
2322 (process_stratum_target::emit_ops): ... this.
2323 (process_target::supports_disable_randomization): Rename as ...
2324 (process_stratum_target::supports_disable_randomization): ... this.
2325 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2326 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2327 (process_target::qxfer_libraries_svr4): Rename as ...
2328 (process_stratum_target::qxfer_libraries_svr4): ... this.
2329 (process_target::supports_agent): Rename as ...
2330 (process_stratum_target::supports_agent): ... this.
2331 (process_target::enable_btrace): Rename as ...
2332 (process_stratum_target::enable_btrace): ... this.
2333 (process_target::disable_btrace): Rename as ...
2334 (process_stratum_target::disable_btrace): ... this.
2335 (process_target::read_btrace): Rename as ...
2336 (process_stratum_target::read_btrace): ... this.
2337 (process_target::read_btrace_conf): Rename as ...
2338 (process_stratum_target::read_btrace_conf): ... this.
2339 (process_target::supports_range_stepping): Rename as ...
2340 (process_stratum_target::supports_range_stepping): ... this.
2341 (process_target::supports_pid_to_exec_file): Rename as ...
2342 (process_stratum_target::supports_pid_to_exec_file): ... this.
2343 (process_target::pid_to_exec_file): Rename as ...
2344 (process_stratum_target::pid_to_exec_file): ... this.
2345 (process_target::supports_multifs): Rename as ...
2346 (process_stratum_target::supports_multifs): ... this.
2347 (process_target::multifs_open): Rename as ...
2348 (process_stratum_target::multifs_open): ... this.
2349 (process_target::multifs_unlink): Rename as ...
2350 (process_stratum_target::multifs_unlink): ... this.
2351 (process_target::multifs_readlink): Rename as ...
2352 (process_stratum_target::multifs_readlink): ... this.
2353 (process_target::breakpoint_kind_from_pc): Rename as ...
2354 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2355 (process_target::breakpoint_kind_from_current_state): Rename as ...
2356 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2357 (process_target::thread_name): Rename as ...
2358 (process_stratum_target::thread_name): ... this.
2359 (process_target::thread_handle): Rename as ...
2360 (process_stratum_target::thread_handle): ... this.
2361 (process_target::supports_software_single_step): Rename as ...
2362 (process_stratum_target::supports_software_single_step): ... this.
2363 (process_target::supports_catch_syscall): Rename as ...
2364 (process_stratum_target::supports_catch_syscall): ... this.
2365 (process_target::get_ipa_tdesc_idx): Rename as ...
2366 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2367
478f9adf
PA
23682020-02-20 Pedro Alves <palves@redhat.com>
2369
2370 * target.cc (set_target_ops): Simply copy the given target pointer
2371 instead of creating a copy of the pointed object.
2372
d633e831
TBA
23732020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2374
2375 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2376 of process_target.
2377
2378 * target.h (struct process_stratum_target): Remove the target op.
2379 (class process_target): Add the target op.
2380 (target_get_ipa_tdesc_idx): Update the macro.
2381 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2382
2383 Update the derived classes and callers below.
2384
2385 * linux-low.cc (linux_target_ops): Update.
2386 (linux_get_ipa_tdesc_idx): Turn into ...
2387 (linux_process_target::get_ipa_tdesc_idx): ... this.
2388 * linux-low.h (class linux_process_target): Update.
2389 * lynx-low.cc (lynx_target_ops): Update.
2390 * nto-low.cc (nto_target_ops): Update.
2391 * win32-low.cc (win32_target_ops): Update.
2392
bc8d3ae4
TBA
23932020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2394
2395 Turn process_stratum_target's supports_catch_syscall op into a
2396 method of process_target.
2397
2398 * target.h (struct process_stratum_target): Remove the target op.
2399 (class process_target): Add the target op.
2400 (target_supports_catch_syscall): Update the macro.
2401 * target.cc (process_target::supports_catch_syscall): Define.
2402
2403 Update the derived classes and callers below.
2404
2405 * linux-low.cc (linux_target_ops): Update.
2406 (linux_supports_catch_syscall): Turn into ...
2407 (linux_process_target::supports_catch_syscall): ... this.
2408 * linux-low.h (class linux_process_target): Update.
2409 * lynx-low.cc (lynx_target_ops): Update.
2410 * nto-low.cc (nto_target_ops): Update.
2411 * win32-low.cc (win32_target_ops): Update.
2412
5303a34f
TBA
24132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2414
2415 Turn process_stratum_target's supports_software_single_step op
2416 into a method of process_target.
2417
2418 * target.h (struct process_stratum_target): Remove the target op.
2419 (class process_target): Add the target op.
2420 (target_supports_software_single_step): Update the macro.
2421 * target.cc (process_target::supports_software_single_step): Define.
2422
2423 Update the derived classes and callers below.
2424
2425 * linux-low.cc (linux_target_ops): Update.
2426 (linux_supports_software_single_step): Turn into ...
2427 (linux_process_target::supports_software_single_step): ... this.
2428 * linux-low.h (class linux_process_target): Update.
2429 * lynx-low.cc (lynx_target_ops): Update.
2430 * nto-low.cc (nto_target_ops): Update.
2431 * win32-low.cc (win32_target_ops): Update.
2432
7f63b89b
TBA
24332020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2434
2435 Turn process_stratum_target's thread_name and thread_handle ops
2436 into methods of process_target.
2437
2438 * target.h (struct process_stratum_target): Remove the target ops.
2439 (class process_target): Add the target ops.
2440 (target_thread_name): Update the macro.
2441 (target_thread_handle): Update the macro.
2442 * target.cc (process_target::thread_name): Define.
2443 (process_target::thread_handle): Define.
2444
2445 Update the derived classes and callers below.
2446
2447 * linux-low.cc (linux_target_ops): Update.
2448 (linux_process_target::thread_name): Define.
2449 (linux_process_target::thread_handle): Define.
2450 * linux-low.h (class linux_process_target): Update.
2451 * lynx-low.cc (lynx_target_ops): Update.
2452 * nto-low.cc (nto_target_ops): Update.
2453 * win32-low.cc (win32_target_ops): Update.
2454
d367006f
TBA
24552020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2456
2457 Turn process_stratum_target's breakpoint_kind_from_pc,
2458 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2459 ops into methods of process_target.
2460
2461 * target.h (struct process_stratum_target): Remove the target op.
2462 (class process_target): Add the target op.
2463 (target_breakpoint_kind_from_pc): Update the macro.
2464 (target_breakpoint_kind_from_current_state): Update the macro.
2465 (default_breakpoint_kind_from_pc): Remove declaration.
2466 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2467 (process_target::breakpoint_kind_from_pc): ... this.
2468 (process_target::breakpoint_kind_from_current_state): Define.
2469
2470 Update the derived classes and callers below.
2471
2472 * mem-break.cc (bp_size): Update.
2473 (bp_opcode): Update.
2474 * linux-low.cc (linux_target_ops): Update.
2475 (linux_wait_1): Update.
2476 (linux_breakpoint_kind_from_pc): Turn into ...
2477 (linux_process_target::breakpoint_kind_from_pc): ... this.
2478 (linux_sw_breakpoint_from_kind): Turn into ...
2479 (linux_process_target::sw_breakpoint_from_kind): ... this.
2480 (linux_breakpoint_kind_from_current_state): Turn into ...
2481 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2482 * linux-low.h (class linux_process_target): Update.
2483 * lynx-low.cc (lynx_target_ops): Update.
2484 (lynx_process_target::sw_breakpoint_from_kind): Define.
2485 * lynx-low.h (class lynx_process_target): Update.
2486 * nto-low.cc (nto_target_ops): Update.
2487 (nto_sw_breakpoint_from_kind): Turn into ...
2488 (nto_process_target::sw_breakpoint_from_kind): ... this.
2489 * nto-low.h (class nto_process_target): Update.
2490 * win32-low.cc (win32_target_ops): Update.
2491 (win32_sw_breakpoint_from_kind): Turn into ...
2492 (win32_process_target::sw_breakpoint_from_kind): ... this.
2493 * win32-low.h (class win32_process_target): Update.
2494
c9b7b804
TBA
24952020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2496
2497 Turn process_stratum_target's multifs_open, multifs_readlink,
2498 multifs_unlink ops into methods of process_target.
2499
2500 * target.h (struct process_stratum_target): Remove the target ops.
2501 (class process_target): Add the target ops. Also add
2502 'supports_multifs'.
2503 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2504 "sys/stat.h".
2505 (process_target::supports_multifs): Define.
2506 (process_target::multifs_open): Define.
2507 (process_target::multifs_readlink): Define.
2508 (process_target::multifs_unlink): Define.
2509
2510 Update the derived classes and callers below.
2511
2512 * hostio.cc (handle_setfs): Update.
2513 (handle_open): Update.
2514 (handle_unlink): Update.
2515 (handle_readlink): Update.
2516 * linux-low.cc (linux_target_ops): Update.
2517 (linux_process_target::supports_multifs): Define.
2518 (linux_process_target::multifs_open): Define.
2519 (linux_process_target::multifs_readlink): Define.
2520 (linux_process_target::multifs_unlink): Define.
2521 * linux-low.h (class linux_process_target): Update.
2522 * lynx-low.cc (lynx_target_ops): Update.
2523 * nto-low.cc (nto_target_ops): Update.
2524 * win32-low.cc (win32_target_ops): Update.
2525
8247b823
TBA
25262020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2527
2528 Turn process_stratum_target's pid_to_exec_file op into a method
2529 of process_target.
2530
2531 * target.h (struct process_stratum_target): Remove the target op.
2532 (class process_target): Add the target op. Also add
2533 'supports_pid_to_exec_file'.
2534 * target.cc (process_target::pid_to_exec_file): Define.
2535 (process_target::supports_pid_to_exec_file): Define.
2536
2537 Update the derived classes and callers below.
2538
2539 * server.cc (handle_qxfer_exec_file): Update.
2540 (handle_query): Update.
2541 * linux-low.cc (linux_target_ops): Update.
2542 (linux_process_target::supports_pid_to_exec_file): Define.
2543 (linux_process_target::pid_to_exec_file): Define.
2544 * linux-low.h (class linux_process_target): Update.
2545 * lynx-low.cc (lynx_target_ops): Update.
2546 * nto-low.cc (nto_target_ops): Update.
2547 * win32-low.cc (win32_target_ops): Update.
2548
2526e0cd
TBA
25492020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2550
2551 Turn process_stratum_target's supports_range_stepping op into a
2552 method of process_target.
2553
2554 * target.h (struct process_stratum_target): Remove the target op.
2555 (class process_target): Add the target op.
2556 (target_supports_range_stepping): Update the macro.
2557 * target.cc (process_target::supports_range_stepping): Define.
2558
2559 Update the derived classes and callers below.
2560
2561 * linux-low.cc (linux_target_ops): Update.
2562 (linux_supports_range_stepping): Turn into ...
2563 (linux_process_target::supports_range_stepping): ... this.
2564 * linux-low.h (class linux_process_target): Update.
2565 * lynx-low.cc (lynx_target_ops): Update.
2566 * nto-low.cc (nto_target_ops): Update.
2567 * win32-low.cc (win32_target_ops): Update.
2568
79597bdd
TBA
25692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2570
2571 Turn process_stratum_target's btrace-related ops (enable_btrace,
2572 disable_btrace, read_btrace, read_btrace_conf) into methods of
2573 process_target.
2574
2575 * target.h (struct process_stratum_target): Remove the target ops.
2576 (class process_target): Add the target ops.
2577 (target_enable_btrace): Update.
2578 (target_disable_btrace): Update.
2579 (target_read_btrace): Update.
2580 (target_read_btrace_conf): Update.
2581 * target.cc (process_target::enable_btrace): Define.
2582 (process_target::disable_btrace): Define.
2583 (process_target::read_btrace): Define.
2584 (process_target::read_btrace_conf): Define.
2585
2586 Update the derived classes and callers below.
2587
2588 * linux-low.cc (linux_target_ops): Update.
2589 (linux_process_target:enable_btrace): Define as a wrapper around
2590 linux_enable_btrace.
2591 (linux_low_disable_btrace): Turn into ...
2592 (linux_process_target::disable_btrace): ... this.
2593 (linux_low_read_btrace): Turn into ...
2594 (linux_process_target::read_btrace): ... this.
2595 (linux_low_btrace_conf): Turn into ...
2596 (linux_process_target::read_btrace_conf): ... this.
2597 * linux-low.h (class linux_process_target): Update.
2598 * lynx-low.cc (lynx_target_ops): Update.
2599 * nto-low.cc (nto_target_ops): Update.
2600 * win32-low.cc (win32_target_ops): Update.
2601
c0245cb9
TBA
26022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2603
2604 Turn process_stratum_target's supports_agent op into a method of
2605 process_target.
2606
2607 * target.h (struct process_stratum_target): Remove the target op.
2608 (class process_target): Add the target op.
2609 (target_supports_agent): Update the macro.
2610 * target.cc (process_target::supports_agent): Define.
2611
2612 Update the derived classes and callers below.
2613
2614 * linux-low.cc (linux_target_ops): Update.
2615 (linux_supports_agent): Turn into ...
2616 (linux_process_target::supports_agent): ... this.
2617 * linux-low.h (class linux_process_target): Update.
2618 * lynx-low.cc (lynx_target_ops): Update.
2619 * nto-low.cc (nto_target_ops): Update.
2620 * win32-low.cc (win32_target_ops): Update.
2621
974387bb
TBA
26222020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2623
2624 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2625 method of process_target.
2626
2627 * target.h (struct process_stratum_target): Remove the target op.
2628 (class process_target): Add the target op. Also add
2629 'supports_qxfer_libraries_svr4'.
2630 * target.cc (process_target::qxfer_libraries_svr4): Define.
2631 (process_target::supports_qxfer_libraries_svr4): Define.
2632
2633 Update the derived classes and callers below.
2634
2635 * server.cc (handle_qxfer_libraries_svr4): Update.
2636 (handle_query): Update.
2637 * linux-low.cc (linux_target_ops): Update.
2638 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2639 (linux_qxfer_libraries_svr4): Turn into ...
2640 (linux_process_target::qxfer_libraries_svr4): ... this.
2641 * linux-low.h (class linux_process_target): Update.
2642 * lynx-low.cc (lynx_target_ops): Update.
2643 * nto-low.cc (nto_target_ops): Update.
2644 * win32-low.cc (win32_target_ops): Update.
2645
c756403b
TBA
26462020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2647
2648 Turn process_stratum_target's supports_disable_randomization op
2649 into a method of process_target.
2650
2651 * target.h (struct process_stratum_target): Remove the target op.
2652 (class process_target): Add the target op.
2653 (target_supports_disable_randomization): Update the macro.
2654 * target.cc (process_target::supports_disable_randomization): Define.
2655
2656 Update the derived classes and callers below.
2657
2658 * linux-low.cc (linux_target_ops): Update.
2659 (linux_supports_disable_randomization): Turn into ...
2660 (linux_process_target::supports_disable_randomization): ... this.
2661 * linux-low.h (class linux_process_target): Update.
2662 * lynx-low.cc (lynx_target_ops): Update.
2663 * nto-low.cc (nto_target_ops): Update.
2664 * win32-low.cc (win32_target_ops): Update.
2665
345dafad
TBA
26662020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2667
2668 Turn process_stratum_target's emit_ops op into a method of
2669 process_target.
2670
2671 * target.h (struct process_stratum_target): Remove the target op.
2672 (class process_target): Add the target op.
2673 (target_emit_ops): Update the macro.
2674 * target.cc (process_target::emit_ops): Define.
2675
2676 Update the derived classes and callers below.
2677
2678 * linux-low.cc (linux_target_ops): Update.
2679 (linux_emit_ops): Turn into ...
2680 (linux_process_target::emit_ops): ... this.
2681 * linux-low.h (class linux_process_target): Update.
2682 * lynx-low.cc (lynx_target_ops): Update.
2683 * nto-low.cc (nto_target_ops): Update.
2684 * win32-low.cc (win32_target_ops): Update.
2685
c23c9391
TBA
26862020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2687
2688 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2689 and get_min_fast_tracepoint_insn_len ops into methods of
2690 process_target.
2691
2692 * target.h (struct process_stratum_target): Remove the target ops.
2693 (class process_target): Add the target ops. Also add
2694 'supports_fast_tracepoints'.
2695 (target_supports_fast_tracepoints): Update the macro.
2696 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2697 (install_fast_tracepoint_jump_pad): Update and rename the macro
2698 to ...
2699 (target_install_fast_tracepoint_jump_pad): ... this.
2700 * target.cc (process_target::supports_fast_tracepoints): Define.
2701 (process_target::install_fast_tracepoint_jump_pad): Define.
2702 (process_target::get_min_fast_tracepoint_insn_len): Define.
2703
2704 Update the derived classes and callers below.
2705
2706 * tracepoint.cc (install_fast_tracepoint): Update.
2707 * linux-low.cc (linux_target_ops): Update.
2708 (linux_process_target::supports_fast_tracepoints): Define.
2709 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2710 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2711 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2712 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2713 * linux-low.h (class linux_process_target): Update.
2714 * lynx-low.cc (lynx_target_ops): Update.
2715 * nto-low.cc (nto_target_ops): Update.
2716 * win32-low.cc (win32_target_ops): Update.
2717
5c9eb2f2
TBA
27182020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2719
2720 Turn process_stratum_target's stabilize_threads op into a
2721 method of process_target.
2722
2723 * target.h (struct process_stratum_target): Remove the target op.
2724 (class process_target): Add the target op.
2725 (target_stabilize_threads): Update the macro.
2726 * target.cc (process_target::stabilize_threads): Define.
2727
2728 Update the derived classes and callers below.
2729
2730 * server.cc (handle_status): Update.
2731 * tracepoint.cc (cmd_qtdp): Update.
2732 (cmd_qtstart): Update.
2733 * linux-low.cc (linux_target_ops): Update.
2734 (linux_stabilize_threads): Turn into ...
2735 (linux_process_target::stabilize_threads): ... this.
2736 (linux_wait_1): Update.
2737 * linux-low.h (class linux_process_target): Update.
2738 * lynx-low.cc (lynx_target_ops): Update.
2739 * nto-low.cc (nto_target_ops): Update.
2740 * win32-low.cc (win32_target_ops): Update.
2741
29e8dc09
TBA
27422020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2743
2744 Turn process_stratum_target's pause_all and unpause_all ops
2745 into methods of process_target.
2746
2747 * target.h (struct process_stratum_target): Remove the target ops.
2748 (class process_target): Add the target ops.
2749 (pause_all): Update the macro and rename to...
2750 (target_pause_all): ... this.
2751 (unpause_all): Update the macro and rename to...
2752 (target_unpause_all): ... this.
2753 * target.cc (process_target::pause_all): Define.
2754 (process_target::unpause_all): Define.
2755
2756 Update the derived classes and callers below.
2757
2758 * server.cc (handle_status): Update.
2759 * tracepoint.cc (clear_installed_tracepoints): Update.
2760 (cmd_qtdp): Update.
2761 (cmd_qtstart): Update.
2762 (stop_tracing): Update.
2763 (cmd_qtstatus): Update.
2764 (upload_fast_traceframes): Update.
2765 (run_inferior_command): Update.
2766 * linux-low.cc (linux_target_ops): Update.
2767 (linux_pause_all): Turn into ...
2768 (linux_process_target::pause_all): ... this.
2769 (linux_unpause_all): Turn into ...
2770 (linux_process_target::unpause_all): ... this.
2771 (linux_process_target::prepare_to_access_memory): Update.
2772 (linux_process_target::done_accessing_memory): Update.
2773 * linux-low.h (class linux_process_target): Update.
2774 * lynx-low.cc (lynx_target_ops): Update.
2775 * nto-low.cc (nto_target_ops): Update.
2776 * win32-low.cc (win32_target_ops): Update.
2777
4e2e869c
TBA
27782020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2779
2780 Turn process_stratum_target's get_tib_address op into a method of
2781 process_target.
2782
2783 * target.h (struct process_stratum_target): Remove the target op.
2784 (class process_target): Add the target op. Also add
2785 'supports_get_tib_address'.
2786 * target.cc (process_target::get_tib_address): Define.
2787 (process_target::supports_get_tib_address): Define.
2788
2789 Update the derived classes and callers below.
2790
2791 * server.cc (handle_query): Update.
2792 * linux-low.cc (win32_target_ops): Update.
2793 * lynx-low.cc (lynx_target_ops): Update.
2794 * nto-low.cc (nto_target_ops): Update.
2795 * win32-low.cc (win32_target_ops): Update.
2796 (win32_process_target::supports_get_tib_address): Define.
2797 (win32_get_tib_address): Turn into ...
2798 (win32_process_target::get_tib_address): ... this.
2799 * win32-low.h (class win32_process_target): Update.
2800
68119632
TBA
28012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2802
2803 Turn process_stratum_target's thread_stopped op into a method of
2804 process_target.
2805
2806 * target.h (struct process_stratum_target): Remove the target op.
2807 (class process_target): Add the target op. Also add
2808 'supports_thread_stopped'.
2809 (target_thread_stopped): Update the macro.
2810 * target.cc (process_target::thread_stopped): Define.
2811 (process_target::supports_thread_stopped): Define.
2812 (prepare_to_access_memory): Update.
2813
2814 Update the derived classes and callers below.
2815
2816 * server.cc (queue_stop_reply_callback): Update.
2817 * linux-low.cc (linux_target_ops): Update.
2818 (linux_process_target::supports_thread_stopped): Define.
2819 (linux_thread_stopped): Turn into ...
2820 (linux_process_target::thread_stopped): ... this.
2821 * linux-low.h (class linux_process_target): Update.
2822 * lynx-low.cc (lynx_target_ops): Update.
2823 * nto-low.cc (nto_target_ops): Update.
2824 * win32-low.cc (win32_target_ops): Update.
2825
770d8f6a
TBA
28262020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2827
2828 Turn process_stratum_target's read_pc and write_pc ops into
2829 methods of process_target.
2830
2831 * target.h (struct process_stratum_target): Remove the target ops.
2832 (class process_target): Add the target ops.
2833 * target.cc (process_target::read_pc): Define.
2834 (process_target::write_pc): Define.
2835
2836 Update the derived classes and callers below.
2837
2838 * regcache.cc (regcache_read_pc): Update.
2839 (regcache_write_pc): Update.
2840 * linux-low.cc (linux_target_ops): Update.
2841 (linux_read_pc): Turn into ...
2842 (linux_process_target::read_pc): ... this.
2843 (linux_write_pc): Turn into ...
2844 (linux_process_target::write_pc): ... this.
2845 * linux-low.h (class linux_process_target): Update.
2846 * lynx-low.cc (lynx_target_ops): Update.
2847 * nto-low.cc (nto_target_ops): Update.
2848 * win32-low.cc (win32_target_ops): Update.
2849
290732bf
TBA
28502020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2851
2852 Turn process_stratum_target's supports_tracepoints op into a
2853 method of process_target.
2854
2855 * target.h (struct process_stratum_target): Remove the target op.
2856 (class process_target): Add the target op.
2857 (target_supports_tracepoints): Update the macro.
2858 * target.cc (process_target::supports_tracepoints): Define.
2859
2860 Update the derived classes and callers below.
2861
2862 * linux-low.cc (linux_target_ops): Update.
2863 (linux_supports_tracepoints): Turn into ...
2864 (linux_process_target::supports_tracepoints): ... this.
2865 * linux-low.h (class linux_process_target): Update.
2866 * lynx-low.cc (lynx_target_ops): Update.
2867 * nto-low.cc (nto_target_ops): Update.
2868 * win32-low.cc (win32_target_ops): Update.
2869
0df28b1b
TBA
28702020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2871
2872 Turn process_stratum_target's process_qsupported op into a method
2873 of process_target.
2874
2875 * target.h (struct process_stratum_target): Remove the target op.
2876 (class process_target): Add the target op.
2877 (target_process_qsupported): Update the macro.
2878 * target.cc (process_target::process_qsupported): Define.
2879
2880 Update the derived classes and callers below.
2881
2882 * linux-low.cc (linux_target_ops): Update.
2883 (linux_process_qsupported): Turn into ...
2884 (linux_process_target::process_qsupported): ... this.
2885 * linux-low.h (class linux_process_target): Update.
2886 * lynx-low.cc (lynx_target_ops): Update.
2887 * nto-low.cc (nto_target_ops): Update.
2888 * win32-low.cc (win32_target_ops): Update.
2889
9da41fda
TBA
28902020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2891
2892 Turn process_stratum_target's read_loadmap op into a method of
2893 process_target.
2894
2895 * target.h (struct process_stratum_target): Remove the target op.
2896 (class process_target): Add the target op. Also add
2897 'supports_read_loadmap'.
2898 * target.cc (process_target::read_loadmap): Define.
2899 (process_target::supports_read_loadmap): Define.
2900
2901 Update the derived classes and callers below.
2902
2903 * server.cc (handle_qxfer_fdpic): Update.
2904 (handle_query): Update.
2905 * linux-low.cc (linux_target_ops): Update.
2906 (linux_process_target::supports_read_loadmap): Define.
2907 (linux_read_loadmap): Turn into ...
2908 (linux_process_target::read_loadmap): ... this.
2909 * linux-low.h (class linux_process_target): Update.
2910 * lynx-low.cc (lynx_target_ops): Update.
2911 * nto-low.cc (nto_target_ops): Update.
2912 * win32-low.cc (win32_target_ops): Update.
2913
95a45fc1
TBA
29142020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2915
2916 Turn process_stratum_target's core_of_thread op into a method of
2917 process_target.
2918
2919 * target.h (struct process_stratum_target): Remove the target op.
2920 (class process_target): Add the target op.
2921 (target_core_of_thread): Update the macro.
2922 * target.cc (process_target::core_of_thread): Define.
2923
2924 Update the derived classes and callers below.
2925
2926 * linux-low.cc (linux_target_ops): Update.
2927 (linux_process_target::core_of_thread): Define.
2928 * linux-low.h (class linux_process_target): Update.
2929 * lynx-low.cc (lynx_target_ops): Update.
2930 * nto-low.cc (nto_target_ops): Update.
2931 * win32-low.cc (win32_target_ops): Update.
2932
55cf3021
TBA
29332020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2934
2935 Turn process_stratum_target's handle_monitor_command op into a
2936 method of process_target.
2937
2938 * target.h (struct process_stratum_target): Remove the target op.
2939 (class process_target): Add the target op.
2940 (target_handle_monitor_command): Update the macro.
2941 * target.cc (process_target::handle_monitor_command): Define.
2942
2943 Update the derived classes and callers below.
2944
2945 * server.cc (handle_query): Update.
2946 * linux-low.cc (linux_target_ops): Update.
2947 (linux_process_target::handle_monitor_command): Define.
2948 * linux-low.h (class linux_process_target): Update.
2949 * lynx-low.cc (lynx_target_ops): Update.
2950 * nto-low.cc (nto_target_ops): Update.
2951 * win32-low.cc (win32_target_ops): Update.
2952
fb00dfce
TBA
29532020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2954
2955 Turn process_stratum_target's handle_new_gdb_connection op into a
2956 method of process_target.
2957
2958 * target.h (struct process_stratum_target): Remove the target op.
2959 (class process_target): Add the target op.
2960 (target_handle_new_gdb_connection): Update the macro.
2961 * target.cc (process_target::handle_new_gdb_connection): Define.
2962
2963 Update the derived classes and callers below.
2964
2965 * linux-low.cc (linux_target_ops): Update.
2966 (linux_handle_new_gdb_connection): Turn into ...
2967 (linux_process_target::handle_new_gdb_connection): ... this.
2968 * linux-low.h (class linux_process_target): Update.
2969 * lynx-low.cc (lynx_target_ops): Update.
2970 * nto-low.cc (nto_target_ops): Update.
2971 * win32-low.cc (win32_target_ops): Update.
2972
9690a72a
TBA
29732020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2974
2975 Turn process_stratum_target's supports_fork_events,
2976 supports_vfork_events, and supports_exec_events ops into methods
2977 of process_target.
2978
2979 * target.h (struct process_stratum_target): Remove the target ops.
2980 (class process_target): Add the target ops.
2981 (target_supports_fork_events): Update the macro.
2982 (target_supports_vfork_events): Update the macro.
2983 (target_supports_exec_events): Update the macro.
2984 * target.cc (process_target::supports_fork_events): Define.
2985 (process_target::supports_vfork_events): Define.
2986 (process_target::supports_exec_events): Define.
2987
2988 Update the derived classes and callers below.
2989
2990 * linux-low.cc (linux_target_ops): Update.
2991 (linux_supports_fork_events): Turn into ...
2992 (linux_process_target::supports_fork_events): ... this.
2993 (linux_supports_vfork_events): Turn into ...
2994 (linux_process_target::supports_vfork_events): ... this.
2995 (linux_supports_exec_events): Turn into ...
2996 (linux_process_target::supports_exec_events): ... this.
2997 * linux-low.h (class linux_process_target): Update.
2998 * lynx-low.cc (lynx_target_ops): Update.
2999 * nto-low.cc (nto_target_ops): Update.
3000 * win32-low.cc (win32_target_ops): Update.
3001
652aef77
TBA
30022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3003
3004 Turn process_stratum_target's supports_multi_process op into a
3005 method of process_target.
3006
3007 * target.h (struct process_stratum_target): Remove the target op.
3008 (class process_target): Add the target op.
3009 * target.cc (process_target::supports_multi_process): Define.
3010 (target_supports_multi_process): Update.
3011
3012 Update the derived classes and callers below.
3013
3014 * linux-low.cc (linux_target_ops): Update.
3015 (linux_supports_multi_process): Turn into ...
3016 (linux_process_target::supports_multi_process): ... this.
3017 * linux-low.h (class linux_process_target): Update.
3018 * lynx-low.cc (lynx_target_ops): Update.
3019 * nto-low.cc (nto_target_ops): Update.
3020 * win32-low.cc (win32_target_ops): Update.
3021
0dc587d4
TBA
30222020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3023
3024 Turn process_stratum_target's supports_non_stop, async, and
3025 start_non_stop ops into methods of process_target.
3026
3027 * target.h (struct process_stratum_target): Remove the target ops.
3028 (class process_target): Add the target ops.
3029 (target_supports_non_stop): Update the macro.
3030 (target_async): Update the macro.
3031 (start_non_stop): Remove declaration.
3032 * target.cc (process_target::supports_non_stop): Define.
3033 (process_target::async): Define.
3034 (process_target::start_non_stop): Define.
3035 (start_non_stop): Remove.
3036
3037 Update the derived classes and callers below.
3038
3039 * server.cc (handle_qxfer_siginfo): Update.
3040 (handle_query): Update.
3041 * linux-low.cc (linux_target_ops): Update.
3042 (linux_supports_non_stop): Turn into ...
3043 (linux_process_target::supports_non_stop): ... this.
3044 (linux_async): Turn into ...
3045 (linux_process_target::async): ... this.
3046 (linux_start_non_stop): Turn into ...
3047 (linux_process_target::start_non_stop): ... this.
3048 * linux-low.h (class linux_process_target): Update.
3049 * lynx-low.cc (lynx_target_ops): Update.
3050 * nto-low.cc (nto_target_ops): Update.
3051 (nto_supports_non_stop): Remove; rely on the default behavior
3052 instead.
3053 * win32-low.cc (win32_target_ops): Update.
3054
d7abedf7
TBA
30552020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3056
3057 Turn process_stratum_target's qxfer_siginfo op into a method of
3058 process_target.
3059
3060 * target.h (struct process_stratum_target): Remove the target op.
3061 (class process_target): Add the target op. Also add
3062 'supports_qxfer_siginfo'.
3063 * target.cc (process_target::qxfer_siginfo): Define.
3064 (process_target::supports_qxfer_siginfo): Define.
3065
3066 Update the derived classes and callers below.
3067
3068 * server.cc (handle_qxfer_siginfo): Update.
3069 (handle_query): Update.
3070 * linux-low.cc (linux_target_ops): Update.
3071 (linux_process_target::supports_qxfer_siginfo): Define.
3072 (linux_xfer_siginfo): Turn into ...
3073 (linux_process_target::qxfer_siginfo): ... this.
3074 * linux-low.h (class linux_process_target): Update.
3075 * lynx-low.cc (lynx_target_ops): Update.
3076 * nto-low.cc (nto_target_ops): Update.
3077 * win32-low.cc (win32_target_ops): Update.
3078
2d0795ee
TBA
30792020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3080
3081 Turn process_stratum_target's qxfer_osdata op into a method of
3082 process_target.
3083
3084 * target.h (struct process_stratum_target): Remove the target op.
3085 (class process_target): Add the target op. Also add
3086 'supports_qxfer_osdata'.
3087 * target.cc (process_target::qxfer_osdata): Define.
3088 (process_target::supports_qxfer_osdata): Define.
3089
3090 Update the derived classes and callers below.
3091
3092 * server.cc (handle_qxfer_osdata): Update.
3093 (handle_query): Update.
3094 * linux-low.cc (linux_target_ops): Update.
3095 (linux_process_target::supports_qxfer_osdata): Define.
3096 (linux_qxfer_osdata): Turn into ...
3097 (linux_process_target::qxfer_osdata): ... this.
3098 * linux-low.h (class linux_process_target): Update.
3099 * lynx-low.cc (lynx_target_ops): Update.
3100 * nto-low.cc (nto_target_ops): Update.
3101 * win32-low.cc (win32_target_ops): Update.
3102
ea06bbaa
TBA
31032020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3104
3105 Turn process_stratum_target's hostio_last_error op into a
3106 method of process_target.
3107
3108 * target.h (struct process_stratum_target): Remove the target op.
3109 (class process_target): Add the target op.
3110 * target.cc: Add "hostio.h" to includes.
3111 (process_target::hostio_last_error): Define.
3112
3113 Update the derived classes and callers below.
3114
3115 * hostio.cc (hostio_error): Update.
3116 * linux-low.cc: Remove "hostio.h" from includes.
3117 (linux_target_ops): Update.
3118 * lynx-low.cc (lynx_target_ops): Update.
3119 * nto-low.cc (nto_target_ops): Update.
3120 * win32-low.h (class win32_process_target): Update.
3121 * win32-low.cc (win32_target_ops): Update.
3122 (wince_hostio_last_error): Turn into ...
3123 (win32_process_target::hostio_last_error): ... this.
3124
6e3fd7e9
TBA
31252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3126
3127 Turn process_stratum_target's get_tls_address op into a method of
3128 process_target.
3129
3130 * target.h (struct process_stratum_target): Remove the target op.
3131 (class process_target): Add the target op. Also add
3132 'supports_get_tls_address'.
3133 * target.cc (process_target::get_tls_address): Define.
3134 (process_target::supports_get_tls_address): Define.
3135
3136 Update the derived classes and callers below.
3137
3138 * server.cc (handle_query): Update.
3139 * linux-low.cc (linux_target_ops): Update.
3140 (linux_process_target::supports_get_tls_address): Define.
3141 (linux_process_target::get_tls_address): Define.
3142 * linux-low.h (class linux_process_target): Update.
3143 * lynx-low.cc (lynx_target_ops): Update.
3144 * nto-low.cc (nto_target_ops): Update.
3145 * win32-low.cc (win32_target_ops): Update.
3146
5203ae1e
TBA
31472020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3148
3149 Turn process_stratum_target's read_offsets op into a method of
3150 process_target.
3151
3152 * target.h (struct process_stratum_target): Remove the target op.
3153 (class process_target): Add the target op. Also add
3154 'supports_read_offsets'.
3155 * target.cc (process_target::read_offsets): Define.
3156 (process_target::supports_read_offsets): Define.
3157
3158 Update the derived classes and callers below.
3159
3160 * server.cc (handle_query): Update.
3161 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3162 (linux_target_ops): Update.
3163 (linux_process_target::supports_read_offsets): Define.
3164 (linux_read_offsets): Turn into ...
3165 (linux_process_target::read_offsets): ... this.
3166 * linux-low.h (class linux_process_target): Update.
3167 * lynx-low.cc (lynx_target_ops): Update.
3168 * nto-low.cc (nto_target_ops): Update.
3169 * win32-low.cc (win32_target_ops): Update.
3170
6eeb5c55
TBA
31712020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3172
3173 Turn process_stratum_target's stopped_by_watchpoint and
3174 stopped_data_address ops into methods of process_target.
3175
3176 * target.h (struct process_stratum_target): Remove the target ops.
3177 (class process_target): Add the target ops.
3178 * target.cc (process_target::stopped_by_watchpoint): Define.
3179 (process_target::stopped_data_address): Define.
3180
3181 Update the derived classes and callers below.
3182
3183 * remote-utils.cc (prepare_resume_reply): Update.
3184 * linux-low.cc (linux_target_ops): Update.
3185 (linux_stopped_by_watchpoint): Turn into ...
3186 (linux_process_target::stopped_by_watchpoint): ... this.
3187 (linux_stopped_data_address): Turn into ...
3188 (linux_process_target::stopped_data_address): ... this.
3189 * linux-low.h (class linux_process_target): Update.
3190 * lynx-low.cc (lynx_target_ops): Update.
3191 * nto-low.cc (nto_target_ops): Update.
3192 (nto_stopped_by_watchpoint): Turn into ...
3193 (nto_process_target::stopped_by_watchpoint): ... this.
3194 (nto_stopped_data_address): Turn into ...
3195 (nto_process_target::stopped_data_address): ... this.
3196 * nto-low.h (class nto_process_target): Update.
3197 * win32-low.cc (win32_target_ops): Update.
3198 (win32_stopped_by_watchpoint): Turn into ...
3199 (win32_process_target::stopped_by_watchpoint): ... this.
3200 (win32_stopped_data_address): Turn into ...
3201 (win32_process_target::stopped_data_address): ... this.
3202 * win32-low.h (class win32_process_target): Update.
3203
22aa6223
TBA
32042020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3205
3206 Turn process_stratum_target's supports_hardware_single_step op into
3207 a method of process_target.
3208
3209 * target.h (struct process_stratum_target): Remove the target op.
3210 (class process_target): Add the target op.
3211 (target_supports_hardware_single_step): Update the macro.
3212 (target_can_do_hardware_single_step): Remove declaration.
3213 * target.cc (process_target::supports_hardware_single_step): Define.
3214 (target_can_do_hardware_single_step): Remove.
3215
3216 Update the derived classes and callers below.
3217
3218 * linux-low.h (class linux_process_target): Update.
3219 * linux-low.cc (linux_target_ops): Update.
3220 (linux_supports_hardware_single_step): Turn into ...
3221 (linux_process_target::supports_hardware_single_step): ... this.
3222 * lynx-low.h (class lynx_process_target): Update.
3223 * lynx-low.cc (lynx_target_ops): Update.
3224 (lynx_process_target::supports_hardware_single_step): Define.
3225 * nto-low.h (class nto_process_target): Update.
3226 * nto-low.cc (nto_target_ops): Update.
3227 (nto_process_target::supports_hardware_single_step): Define.
3228 * win32-low.h (class win32_process_target): Update.
3229 * win32-low.cc (win32_target_ops): Update.
3230 (win32_process_target::supports_hardware_single_step): Define.
3231
93fe88b2
TBA
32322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3233
3234 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3235 ops into methods of process_target.
3236
3237 * target.h (struct process_stratum_target): Remove the target ops.
3238 (class process_target): Add the target ops.
3239 (target_stopped_by_hw_breakpoint): Update the macro.
3240 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3241 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3242 (process_target::supports_stopped_by_hw_breakpoint): Define.
3243
3244 Update the derived classes and callers below.
3245
3246 * linux-low.cc (linux_target_ops): Update.
3247 (linux_stopped_by_hw_breakpoint): Turn into ...
3248 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3249 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3250 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3251 * linux-low.h (class linux_process_target): Update.
3252 * lynx-low.cc (lynx_target_ops): Update.
3253 * nto-low.cc (nto_target_ops): Update.
3254 * win32-low.cc (win32_target_ops): Update.
3255
84320c4e
TBA
32562020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3257
3258 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3259 ops into methods of process_target.
3260
3261 * target.h (struct process_stratum_target): Remove the target ops.
3262 (class process_target): Add the target ops.
3263 (target_stopped_by_sw_breakpoint): Update the macro.
3264 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3265 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3266 (process_target::supports_stopped_by_sw_breakpoint): Define.
3267
3268 Update the derived classes and callers below.
3269
3270 * linux-low.cc (linux_target_ops): Update.
3271 (linux_stopped_by_sw_breakpoint): Turn into ...
3272 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3273 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3274 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3275 * linux-low.h (class linux_process_target): Update.
3276 * lynx-low.cc (lynx_target_ops): Update.
3277 * nto-low.cc (nto_target_ops): Update.
3278 * win32-low.cc (win32_target_ops): Update.
3279
7e0bde70
TBA
32802020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3281
3282 Turn process_stratum_target's insert_point and remove_point ops
3283 into methods of process_target.
3284
3285 * target.h (struct process_stratum_target): Remove the target ops.
3286 (class process_target): Add the target ops.
3287 * target.cc (process_target::insert_point): Define.
3288 (process_target::remove_point): Define.
3289
3290 Update the derived classes and callers below.
3291
3292 * mem-break.cc (set_raw_breakpoint_at): Update.
3293 (delete_raw_breakpoint): Update.
3294 (uninsert_raw_breakpoint): Update.
3295 (reinsert_raw_breakpoint): Update.
3296 * linux-low.cc (linux_target_ops): Update.
3297 (linux_insert_point): Turn into ...
3298 (linux_process_target::insert_point): ... this.
3299 (linux_remove_point): Turn into ...
3300 (linux_process_target::remove_point): ... this.
3301 * linux-low.h (class linux_process_target): Update.
3302 * lynx-low.cc (lynx_target_ops): Update.
3303 * nto-low.cc (nto_target_ops): Update.
3304 (nto_insert_point): Turn into ...
3305 (nto_process_target::insert_point): ... this.
3306 (nto_remove_point): Turn into ...
3307 (nto_process_target::remove_point): ... this.
3308 * nto-low.h (class nto_process_target): Update.
3309 * win32-low.cc (win32_target_ops): Update.
3310 (win32_insert_point): Turn into ...
3311 (win32_process_target::insert_point): ... this.
3312 (win32_remove_point): Turn into ...
3313 (win32_process_target::remove_point): ... this.
3314 * win32-low.h (class win32_process_target): Update.
3315
a2b2297a
TBA
33162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3317
3318 Turn process_stratum_target's supports_z_point_type op into a
3319 method of process_target.
3320
3321 * target.h (struct process_stratum_target): Remove the target op.
3322 (class process_target): Add the target op.
3323 * target.cc (process_target::supports_z_point_type): Define.
3324
3325 Update the derived classes and callers below.
3326
3327 * mem-break.cc (z_type_supported): Update.
3328 * linux-low.cc (linux_target_ops): Update.
3329 (linux_supports_z_point_type): Turn into ...
3330 (linux_process_target::supports_z_point_type): ... this.
3331 * linux-low.h (class linux_process_target): Update.
3332 * lynx-low.cc (lynx_target_ops): Update.
3333 * nto-low.cc (nto_target_ops): Update.
3334 (nto_supports_z_point_type): Turn into ...
3335 (nto_process_target::supports_z_point_type): ... this.
3336 * nto-low.h (class nto_process_target): Update.
3337 * win32-low.cc (win32_target_ops): Update.
3338 (win32_supports_z_point_type): Turn into ...
3339 (win32_process_target::supports_z_point_type): ... this.
3340 * win32-low.h (class win32_process_target): Update.
3341
eac215cc
TBA
33422020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3343
3344 Turn process_stratum_target's read_auxv op into a method of
3345 process_target.
3346
3347 * target.h (class process_stratum_target): Remove the target op.
3348 (struct process_target): Add the target op. Also add
3349 'supports_read_auxv'.
3350 * target.cc (process_target::read_auxv): Define.
3351 (process_target::supports_read_auxv): Define.
3352
3353 Update the derived classes and callers below.
3354
3355 * server.cc (handle_qxfer_auxv): Update.
3356 (handle_query): Update.
3357 * linux-low.cc (linux_target_ops): Update.
3358 (linux_process_target::supports_read_auxv): Define.
3359 (linux_read_auxv): Turn into ...
3360 (linux_process_target::read_auxv): ... this.
3361 * linux-low.h (class linux_process_target): Update.
3362 * lynx-low.cc (lynx_target_ops): Update.
3363 * nto-low.cc (nto_target_ops): Update.
3364 (nto_process_target::supports_read_auxv): Define.
3365 (nto_read_auxv): Turn into ...
3366 (nto_process_target::read_auxv): ... this.
3367 * nto-low.h (class nto_process_target): Update.
3368 * win32-low.cc (win32_target_ops): Update.
3369
eb497a2a
TBA
33702020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3371
3372 Turn process_stratum_target's request_interrupt op into a method of
3373 process_target.
3374
3375 * target.h (struct process_stratum_target): Remove the target op.
3376 (class process_target): Add the target op.
3377
3378 Update the derived classes and callers below.
3379
3380 * remote-utils.cc (putpkt_binary_1): Update.
3381 (input_interrupt): Update.
3382 (getpkt): Update.
3383 * server.cc (handle_v_requests): Update.
3384 * linux-low.cc (linux_target_ops): Update.
3385 (linux_request_interrupt): Turn into ...
3386 (linux_process_target::request_interrupt): ... this.
3387 * linux-low.h (class linux_process_target): Update.
3388 * lynx-low.cc (lynx_target_ops): Update.
3389 (lynx_request_interrupt): Turn into ...
3390 (lynx_process_target::request_interrupt): ... this.
3391 * lynx-low.h (class lynx_process_target): Update.
3392 * nto-low.cc (nto_target_ops): Update.
3393 (nto_request_interrupt): Turn into ...
3394 (nto_process_target::request_interrupt): ... this.
3395 * nto-low.h (class nto_process_target): Update.
3396 * win32-low.cc (win32_target_ops): Update.
3397 (win32_request_interrupt): Turn into ...
3398 (win32_process_target::request_interrupt): ... this.
3399 * win32-low.h (class win32_process_target): Update.
3400
2a31c7aa
TBA
34012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3402
3403 Turn process_stratum_target's look_up_symbols op into a method of
3404 process_target.
3405
3406 * target.h (struct process_stratum_target): Remove the target op.
3407 (class process_target): Add the target op.
3408 * target.cc (process_target::look_up_symbols): Define.
3409
3410 Update the derived classes and callers below.
3411
3412 * server.cc (handle_query): Update.
3413 * linux-low.cc (linux_target_ops): Update.
3414 (linux_look_up_symbols): Turn into ...
3415 (linux_process_target::look_up_symbols): ... this.
3416 * linux-low.h (class linux_process_target): Update.
3417 * lynx-low.cc (lynx_target_ops): Update.
3418 * nto-low.cc (nto_target_ops): Update.
3419 * win32-low.cc (win32_target_ops): Update.
3420
e2558df3
TBA
34212020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3422
3423 Turn process_stratum_target's read_memory and write_memory
3424 ops into methods of process_target.
3425
3426 * target.h (struct process_stratum_target): Remove the target ops.
3427 (class process_target): Add the target ops.
3428
3429 Update the derived classes and callers below.
3430
3431 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3432 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3433 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3434 (arm_get_syscall_trapinfo): Update.
3435 * linux-cris-low.cc (cris_breakpoint_at): Update.
3436 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3437 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3438 * linux-mips-low.cc (mips_breakpoint_at): Update.
3439 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3440 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3441 * linux-sh-low.cc (sh_breakpoint_at): Update.
3442 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3443 (sparc_store_gregset_from_stack): Update.
3444 (sparc_breakpoint_at): Update.
3445 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3446 * linux-tile-low.cc (tile_breakpoint_at): Update.
3447 * linux-x86-low.cc (x86_breakpoint_at): Update.
3448 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3449 * mem-brea.cc (insert_memory_breakpoint): Update.
3450 (validate_inserted_breakpoint): Update.
3451 * target.cc (read_inferior_memory): Update.
3452 (target_write_memory): Update.
3453 * linux-low.cc (linux_target_ops): Update.
3454 (linux_read_memory): Make a wrapper around the read_memory target
3455 op call.
3456 (linux_process_target::read_memory): Rename from linux_read_memory.
3457 (linux_write_memory): Turn into ...
3458 (linux_process_target::write_memory): ... this.
3459 * linux-low.h (class linux_process_target): Update.
3460 * lynx-low.cc (lynx_target_ops): Update.
3461 (lynx_read_memory): Turn into ...
3462 (lynx_process_target::read_memory): ... this.
3463 (lynx_write_memory): Turn into ...
3464 (lynx_process_target::write_memory): ... this.
3465 * lynx-low.h (class lynx_process_target): Update.
3466 * nto-low.cc (nto_target_ops): Update.
3467 (nto_read_memory): Turn into ...
3468 (nto_process_target::read_memory): ... this.
3469 (nto_write_memory): Turn into ...
3470 (nto_process_target::write_memory): ... this.
3471 * nto-low.h (class nto_process_target): Update.
3472 * win32-low.cc (win32_target_ops): Update.
3473 (win32_read_inferior_memory): Turn into ...
3474 (win32_process_target::read_memory): ... this.
3475 (win32_write_inferior_memory): Turn into ...
3476 (win32_process_target::write_memory): ... this.
3477 * win32-low.h (class win32_process_target): Update.
3478
79b44087
TBA
34792020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3480
3481 Turn process_stratum_target's prepare_to_access_memory and
3482 done_accessing_memory ops into methods of process_target.
3483
3484 * target.h (struct process_stratum_target): Remove the target ops.
3485 (class process_target): Add the target ops.
3486 * target.cc (process_target::prepare_to_access_memory): Define.
3487 (process_target::done_accessing_memory): Define.
3488 (prepare_to_access_memory): Update.
3489 (done_accessing_memory): Update.
3490
3491 Update the derived classes and callers below.
3492
3493 * linux-low.cc (linux_target_ops): Update.
3494 (linux_prepare_to_access_memory): Turn into ...
3495 (linux_process_target::prepare_to_access_memory): ... this.
3496 (linux_done_accessing_memory): Turn into ...
3497 (linux_process_target::done_accessing_memory): ... this.
3498 * linux-low.h (class linux_process_target): Update.
3499 * lynx-low.cc (lynx_target_ops): Update.
3500 * nto-low.cc (nto_target_ops): Update.
3501 * win32-low.cc (win32_target_ops): Update.
3502
a5a4d4cd
TBA
35032020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3504
3505 Turn process_stratum_target's fetch_registers and store_registers
3506 ops into methods of process_target.
3507
3508 * target.h (struct process_stratum_target): Remove the target ops.
3509 (class process_target): Add the target ops.
3510 (fetch_inferior_registers): Update the macro.
3511 (store_inferior_registers): Update the macro.
3512
3513 Update the derived classes and callers below.
3514
3515 * linux-low.cc (linux_target_ops): Update.
3516 (linux_fetch_registers): Turn into ...
3517 (linux_process_target::fetch_registers): ... this.
3518 (linux_store_registers): Turn into ...
3519 (linux_process_target::store_registers): ... this.
3520 * linux-low.h (class linux_process_target): Update.
3521 * lynx-low.cc (lynx_target_ops): Update.
3522 (lynx_fetch_registers): Turn into ...
3523 (lynx_process_target::fetch_registers): ... this.
3524 (lynx_store_registers): Turn into ...
3525 (lynx_process_target::store_registers): ... this.
3526 * lynx-low.h (class lynx_process_target): Update.
3527 * nto-low.cc (nto_target_ops): Update.
3528 (nto_fetch_registers): Turn into ...
3529 (nto_process_target::fetch_registers): ... this.
3530 (nto_store_registers): Turn into ...
3531 (nto_process_target::store_registers): ... this.
3532 * nto-low.h (class nto_process_target): Update.
3533 * win32-low.cc (win32_target_ops): Update.
3534 (win32_fetch_inferior_registers): Turn into ...
3535 (win32_process_target::fetch_registers): ... this.
3536 (win32_store_inferior_registers): Turn into ...
3537 (win32_process_target::store_registers): ... this.
3538 * win32-low.h (class win32_process_target): Update.
3539
6532e7e3
TBA
35402020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3541
3542 Turn process_stratum_target's wait op into a method of
3543 process_target.
3544
3545 * target.h (struct process_stratum_target): Remove the target op.
3546 (class process_target): Add the target op.
3547
3548 Update the derived classes and callers below.
3549
3550 * target.cc (target_wait): Update.
3551 * linux-low.cc (linux_target_ops): Update.
3552 (linux_wait): Turn into ...
3553 (linux_process_target::wait): ... this.
3554 * linux-low.h (class linux_process_target): Update.
3555 * lynx-low.cc (lynx_target_ops): Update.
3556 (lynx_wait): Turn into ...
3557 (lynx_process_target::wait): ... this.
3558 * lynx-low.h (class lynx_process_target): Update.
3559 * nto-low.cc (nto_target_ops): Update.
3560 (nto_wait): Turn into ...
3561 (nto_process_target::wait): ... this.
3562 * nto-low.h (class nto_process_target): Update.
3563 * win32-low.cc (win32_target_ops): Update.
3564 (win32_wait): Turn into ...
3565 (win32_process_target::wait): ... this.
3566 (do_initial_child_stuff): Update.
3567 * win32-low.h (class win32_process_target): Update.
3568
0e4d7e35
TBA
35692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3570
3571 Turn process_stratum_target's resume op into a method of
3572 process_target.
3573
3574 * target.h (struct process_stratum_target): Remove the target op.
3575 (class process_target): Add the target op.
3576
3577 Update the derived classes and callers below.
3578
3579 * server.cc (resume): Update.
3580 * target.cc (target_stop_and_wait): Update.
3581 (target_continue_no_signal): Update.
3582 (target_continue): Update.
3583 * linux-low.cc (linux_target_ops): Update.
3584 (linux_resume): Turn into ...
3585 (linux_process_target::resume): ... this.
3586 * linux-low.h (class linux_process_target): Update.
3587 * lynx-low.cc (lynx_target_ops): Update.
3588 (lynx_resume): Turn into ...
3589 (lynx_process_target::resume): ... this.
3590 * lynx-low.h (class lynx_process_target): Update.
3591 * nto-low.cc (nto_target_ops): Update.
3592 (nto_resume): Turn into ...
3593 (nto_process_target::resume): ... this.
3594 * nto-low.h (class nto_process_target): Update.
3595 * win32-low.cc (win32_target_ops): Update.
3596 (win32_resume): Turn into ...
3597 (win32_process_target::resume): ... this.
3598 (win32_process_target::detach): Update.
3599 (do_initial_child_stuff): Update.
3600 * win32-low.h (class win32_process_target): Update.
3601
13d3d99b
TBA
36022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3603
3604 Turn process_stratum_target's thread_alive op into a method of
3605 process_target.
3606
3607 * target.h (struct process_stratum_target): Remove the target op.
3608 (class process_target): Add the target op.
3609 (mythread_alive): Update the macro.
3610
3611 Update the derived classes and callers below.
3612
3613 * linux-low.cc (linux_target_ops): Update.
3614 (linux_thread_alive): Turn into ...
3615 (linux_process_target::thread_alive): ... this.
3616 (wait_for_sigstop): Update.
3617 * linux-low.h (class linux_process_target): Update.
3618 * lynx-low.cc (lynx_target_ops): Update.
3619 (lynx_thread_alive): Turn into ...
3620 (lynx_process_target::thread_alive): ... this.
3621 * lynx-low.h (class lynx_process_target): Update.
3622 * nto-low.cc (nto_target_ops): Update.
3623 (nto_thread_alive): Turn into ...
3624 (nto_process_target::thread_alive): ... this.
3625 * nto-low.h (class nto_process_target): Update.
3626 * win32-low.cc (win32_target_ops): Update.
3627 (win32_thread_alive): Turn into ...
3628 (win32_process_target::thread_alive): ... this.
3629 * win32-low.h (class win32_process_target): Update.
3630
95a49a39
TBA
36312020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3632
3633 Turn process_stratum_target's join op into a method of
3634 process_target.
3635
3636 * target.h (struct process_stratum_target): Remove the target op.
3637 (class process_target): Add the target op.
3638 (join_inferior): Update the macro.
3639
3640 Update the derived classes and callers below.
3641
3642 * linux-low.cc (linux_target_ops): Update.
3643 (linux_join): Turn into ...
3644 (linux_process_target::join): ... this.
3645 * linux-low.h (class linux_process_target): Update.
3646 * lynx-low.cc (lynx_target_ops): Update.
3647 (lynx_join): Turn into ...
3648 (lynx_process_target::join): ... this.
3649 * lynx-low.h (class lynx_process_target): Update.
3650 * nto-low.cc (nto_target_ops): Update.
3651 (nto_process_target::join): Define.
3652 * nto-low.h (class nto_process_target): Update.
3653 * win32-low.cc (win32_target_ops): Update.
3654 (win32_join): Turn into ...
3655 (win32_process_target::join): ... this.
3656 * win32-low.h (class win32_process_target): Update.
3657
8adb37b9
TBA
36582020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3659
3660 Turn process_stratum_target's mourn op into a method of
3661 process_target.
3662
3663 * target.h (struct process_stratum_target): Remove the target op.
3664 (class process_target): Add the target op.
3665
3666 Update the derived classes and callers below.
3667
3668 * target.cc (target_mourn_inferior): Update.
3669 * linux-low.cc (linux_target_ops): Update.
3670 (linux_mourn): Turn into ...
3671 (linux_process_target::mourn): ... this.
3672 (handle_extended_wait): Update.
3673 (linux_process_target::kill): Update.
3674 (linux_process_target::detach): Update.
3675 * linux-low.h (class linux_process_target): Update.
3676 * lynx-low.cc (lynx_target_ops): Update.
3677 (lynx_mourn): Turn into ...
3678 (lynx_process_target::mourn): ... this.
3679 * lynx-low.h (class lynx_process_target): Update.
3680 * nto-low.cc (nto_target_ops): Update.
3681 (nto_mourn): Turn into ...
3682 (nto_process_target::mourn): ... this.
3683 * nto-low.h (class nto_process_target): Update.
3684 * win32-low.cc (win32_target_ops): Update.
3685 (win32_mourn): Turn into ...
3686 (win32_process_target::mourn): ... this.
3687 * win32-low.h (class win32_process_target): Update.
3688
9061c9cf
TBA
36892020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3690
3691 Turn process_stratum_target's detach op into a method of
3692 process_target.
3693
3694 * target.h (struct process_stratum_target): Remove the target op.
3695 (class process_target): Add the target op.
3696 (detach_inferior): Update the macro.
3697
3698 Update the derived classes and callers below.
3699
3700 * linux-low.cc (linux_target_ops): Update.
3701 (linux_detach): Turn into ...
3702 (linux_process_target::detach): ... this.
3703 * linux-low.h (class linux_process_target): Update.
3704 * lynx-low.cc (lynx_target_ops): Update.
3705 (lynx_detach): Turn into ...
3706 (lynx_process_target::detach): ... this.
3707 * lynx-low.h (class lynx_process_target): Update.
3708 * nto-low.cc (nto_target_ops): Update.
3709 (nto_detach): Turn into ...
3710 (nto_process_target::detach): ... this.
3711 * nto-low.h (class nto_process_target): Update.
3712 * win32-low.cc (win32_target_ops): Update.
3713 (win32_detach): Turn into ...
3714 (win32_process_target::detach): ... this.
3715 * win32-low.h (class win32_process_target): Update.
3716
c6885a57
TBA
37172020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3718
3719 Turn process_stratum_target's kill op into a method of
3720 process_target.
3721
3722 * target.h (struct process_stratum_target): Remove the target op.
3723 (class process_target): Add the target op.
3724
3725 Update the derived classes and callers below.
3726
3727 * target.cc (kill_inferior): Update.
3728 * linux-low.cc (linux_target_ops): Update.
3729 (linux_kill): Turn into ...
3730 (linux_process_target::kill): ... this.
3731 * linux-low.h (class linux_process_target): Update.
3732 * lynx-low.cc (lynx_target_ops): Update.
3733 (lynx_kill): Turn into ...
3734 (lynx_process_target::kill): ... this.
3735 * lynx-low.h (class lynx_process_target): Update.
3736 * nto-low.cc (nto_target_ops): Update.
3737 (nto_kill): Turn into ...
3738 (nto_process_target::kill): ... this.
3739 * nto-low.h (class nto_process_target): Update.
3740 * win32-low.cc (win32_target_ops): Update.
3741 (win32_kill): Turn into ...
3742 (win32_process_target::kill): ... this.
3743 * win32-low.h (class win32_process_target): Update.
3744
ef03dad8
TBA
37452020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3746
3747 Turn process_stratum_target's attach op into a method of
3748 process_target.
3749
3750 * target.h (struct process_stratum_target): Remove the target op.
3751 (class process_target): Add the target op.
3752 (myattach): Update the macro.
3753
3754 Update the derived classes and callers below.
3755
3756 * linux-low.cc (linux_target_ops): Update.
3757 (linux_attach): Turn into ...
3758 (linux_process_target::attach): ... this.
3759 * linux-low.h (class linux_process_target): Update.
3760 * lynx-low.cc (lynx_target_ops): Update.
3761 (lynx_attach): Turn into ...
3762 (lynx_process_target::attach): ... this.
3763 * lynx-low.h (class lynx_process_target): Update.
3764 * nto-low.cc (nto_target_ops): Update.
3765 (nto_attach): Turn into ...
3766 (nto_process_target::attach): ... this.
3767 * nto-low.h (class nto_process_target): Update.
3768 * win32-low.cc (win32_target_ops): Update.
3769 (win32_attach): Turn into ...
3770 (win32_process_target::attach): ... this.
3771 * win32-low.h (class win32_process_target): Update.
3772
6dee9afb
TBA
37732020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3774
3775 Turn process_stratum_target's post_create_inferior op into a method
3776 of process_target.
3777
3778 * target.h (struct process_stratum_target): Remove the target op.
3779 (class process_target): Add the target op.
3780 (target_post_create_inferior): Update the macro.
3781 * target.cc (process_target::post_create_inferior): Define.
3782
3783 Update the derived classes and callers below.
3784
3785 * linux-low.cc (linux_target_ops): Update.
3786 (linux_post_create_inferior): Turn into ...
3787 (linux_process_target::post_create_inferior): ... this.
3788 * linux-low.h (class linux_process_target): Update.
3789 * lynx-low.cc (lynx_target_ops): Update.
3790 * nto-low.cc (nto_target_ops): Update.
3791 * win32-low.cc (win32_target_ops): Update.
3792
15295543
TBA
37932020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3794
3795 Turn process_stratum_target's create_inferior op into a method of
3796 process_target.
3797
3798 * target.h (struct process_stratum_target): Remove the target op.
3799 (class process_target): Add the target op.
3800 (create_inferior): Rename the macro to ...
3801 (target_create_inferior): ... this.
3802
3803 Update the derived classes and callers below.
3804
3805 * server.cc (handle_v_run): Update.
3806 (captured_main): Update.
3807 (process_serial_event): Update.
3808 * linux-low.cc (linux_target_ops): Update.
3809 (linux_create_inferior): Turn into ...
3810 (linux_process_target::create_inferior): ... this.
3811 * linux-low.h (class linux_process_target): Update.
3812 * lynx-low.cc (lynx_target_ops): Update.
3813 (lynx_create_inferior): Turn into ...
3814 (lynx_process_target::create_inferior): ... this.
3815 * lynx-low.h (class lynx_process_target): Update.
3816 * nto-low.cc (nto_target_ops): Update.
3817 (nto_create_inferior): Turn into ...
3818 (nto_process_target::create_inferior): ... this.
3819 * nto-low.h (class nto_process_target): Update.
3820 * win32-low.cc (win32_target_ops): Update.
3821 (win32_create_inferior): Turn into ...
3822 (win32_process_target::create_inferior): ... this.
3823 * win32-low.h (class win32_process_target): Update.
3824
5ef9273d
TBA
38252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3826
3827 * target.h (class process_target): New class definition.
3828 (struct process_stratum_target) <pt>: New field with type
3829 'process_target*'.
3830 * linux-low.h (class linux_process_target): Define as a derived
3831 class of 'process_target'.
3832 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3833 as the 'pt' field.
3834 * lynx-low.h (class lynx_process_target): Define as a derived
3835 class of 'process_target'.
3836 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3837 as the 'pt' field.
3838 * nto-low.h (class nto_process_target): Define as a derived
3839 class of 'process_target'.
3840 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3841 as the 'pt' field.
3842 * win32-low.h (class win32_process_target): Define as a derived
3843 class of 'process_target'.
3844 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3845 as the 'pt' field.
3846
9f1528a1
AB
38472020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3848
3849 * configure: Regenerate.
3850
bf84f706
MR
38512020-02-19 Maciej W. Rozycki <macro@wdc.com>
3852 Andrew Burgess <andrew.burgess@embecosm.com>
3853
3854 * linux-riscv-low.cc: New file.
3855 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3856 and nat/riscv-linux-tdesc.c.
3857 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3858 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3859 Define.
3860
1a627e7e
TT
38612020-02-14 Tom Tromey <tom@tromey.com>
3862
3863 * acinclude.m4: Don't include acx_configure_dir.m4.
3864 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3865 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3866 (all, install-only, uninstall, clean-info, clean)
3867 (maintainer-clean): Don't recurse.
3868 (subdir_do, all-lib): Remove.
3869 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3870 (GNULIB_H): Remove.
3871 (generated_files): Update.
3872 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3873 * configure: Rebuild.
3874 * configure.ac: Don't configure gnulib or libiberty.
3875 (GNULIB): Update.
3876
a9b34532
EZ
38772020-02-14 Eli Zaretskii <eliz@gnu.org>
3878
3879 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3880 preparing the command line for CreateProcess.
3881 (win32_create_inferior): Reflect the program name in debugging
3882 output that shows the process and its command line.
3883
feacfcac
SM
38842020-02-13 Simon Marchi <simon.marchi@efficios.com>
3885
3886 * Makefile.in: Rename source files from .c to .cc.
3887 * %.c: Rename to %.cc.
3888 * configure.ac: Rename server.c to server.cc.
3889 * configure: Re-generate.
3890
06b3c5bd
SM
38912020-02-13 Simon Marchi <simon.marchi@efficios.com>
3892
3893 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3894
052793ad
HD
38952020-02-12 Hannes Domani <ssbssa@yahoo.de>
3896
3897 * win32-low.c (win32_create_inferior): Set signal_pid.
3898
f20e3e82
MR
38992020-02-12 Maciej W. Rozycki <macro@wdc.com>
3900 Pedro Alves <palves@redhat.com>
3901
3902 Skip building gdbserver in a cross-configuration.
3903 * configure.srv: Set $gdbserver_host depending on whether $target
3904 is $host. Use $gdbserver_host instead of $host.
3905
8ddd8e0e
SM
39062020-02-11 Simon Marchi <simon.marchi@efficios.com>
3907
3908 * configure: Re-generate.
3909
898e7f60
SM
39102020-02-11 Simon Marchi <simon.marchi@efficios.com>
3911
3912 * configure: Re-generate.
3913
58df732b
SM
39142020-02-11 Simon Marchi <simon.marchi@efficios.com>
3915
3916 * acinclude.m4: Update warning.m4 path.
3917
7928d571
HD
39182020-02-09 Hannes Domani <ssbssa@yahoo.de>
3919
3920 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3921 (handle_exception): Set siginfo_er.
3922 (win32_xfer_siginfo): New function.
3923
919adfe8
TT
39242020-02-07 Tom Tromey <tom@tromey.com>
3925 Pedro Alves <palves@redhat.com>
3926
3927 * README: Update build documentation.
3928 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
3929 host, not target.
3930 * configure.ac: Update paths.
3931 * configure: Rebuild.
3932 * acinclude.m4: Update paths.
3933 * Makefile.in: Update include paths.
3934 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
3935 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
3936 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
3937 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
3938 (%-generated.c): Update paths.
3939 * Move entire directory from ../gdb/gdbserver.
3940
287c844a
MR
39412020-01-29 Maciej W. Rozycki <macro@wdc.com>
3942
3943 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
3944
548a204f
PFC
39452020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3946
3947 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
3948 assignment instead of srv_linux_obj.
3949
a2236a08
HD
39502020-01-28 Hannes Domani <ssbssa@yahoo.de>
3951
3952 * server.c (handle_qxfer_libraries): Write segment-address with
3953 paddress.
3954
bdaed379
HD
39552020-01-24 Hannes Domani <ssbssa@yahoo.de>
3956
3957 * Makefile.in (install-strip): New target.
3958 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
3959 * aclocal.m4: Regenerate.
3960 * configure: Regenerate.
3961 * configure.ac: Add AM_PROG_INSTALL_STRIP.
3962
42cd72aa
MR
39632020-01-24 Maciej W. Rozycki <macro@wdc.com>
3964
3965 * Makefile.in (SFILES): Adjust paths to point to real files.
3966 (OBS): Move waitstatus.o to target/waitstatus.o.
3967 (TAGS): Transform paths appropriately.
3968 (%.o): Rename to...
3969 (nat/%.o): ... this pattern rule.
3970 (%.o): Rename to...
3971 (target/%.o): ... this pattern rule.
3972 * configure.srv: Adjust paths throughout to include nat/ prefix
3973 with the revant files.
3974 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
3975 * configure: Regenerate.
3976
42ba50ec
MR
39772020-01-24 Maciej W. Rozycki <macro@wdc.com>
3978
3979 * Makefile.in (TAGS): Remove config files from the recipe.
3980
05ea2a05
TT
39812020-01-14 Tom Tromey <tom@tromey.com>
3982
3983 * configure: Rebuild.
3984 * configure.ac: Remove any checks that were added to common.m4.
3985 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
3986 lib-link.m4.
3987
01027315
TT
39882020-01-14 Tom Tromey <tom@tromey.com>
3989
3990 * server.h: Include config.h.
3991 * gdbreplay.c: Include config.h.
3992 * configure: Rebuild.
3993 * configure.ac: Don't source common.host.
3994 * acinclude.m4: Update path.
3995 * Makefile.in (INCSUPPORT): New variable.
3996 (INCLUDE_CFLAGS): Add INCSUPPORT.
3997 (SFILES): Update paths.
3998 (version-generated.c): Update path to create-version.sh.
3999 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4000
b2ceabe8
TT
40012020-01-14 Tom Tromey <tom@tromey.com>
4002
4003 * configure.ac (LIBS): Use WIN32APILIBS.
4004 (USE_WIN32API): Don't define.
4005 * configure: Rebuild.
4006
25c51f71
TT
40072020-01-14 Tom Tromey <tom@tromey.com>
4008
4009 * configure: Rebuild.
4010
c0bd321d
SM
40112020-01-13 Simon Marchi <simon.marchi@efficios.com>
4012
4013 * Makefile.in (%-generated.c): Remove rule for files from
4014 regformats/i386.
4015
bb564c58
SM
40162020-01-13 Simon Marchi <simon.marchi@efficios.com>
4017
4018 * configure: Re-generate.
4019
6e37c371
SM
40202020-01-13 Simon Marchi <simon.marchi@efficios.com>
4021
4022 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4023 Define to static.
4024 * tracepoint.c (stop_tracing, flush_trace_buffer,
4025 about_to_request_buffer_space, get_trace_state_variable_value,
4026 set_trace_state_variable_value, gdb_collect): Add declaration.
4027
df4a0200
SM
40282020-01-13 Simon Marchi <simon.marchi@efficios.com>
4029
4030 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4031 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4032 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4033 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4034 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4035 static.
4036
89e94ec9
SM
40372020-01-13 Simon Marchi <simon.marchi@efficios.com>
4038
4039 * inferiors.c: Include gdbsupport/common-inferior.h.
4040
2552728a
SM
40412020-01-13 Simon Marchi <simon.marchi@efficios.com>
4042
4043 * hostio-errno.c: Include hostio.h.
4044
4025fa09
SM
40452020-01-13 Simon Marchi <simon.marchi@efficios.com>
4046
4047 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4048 prerequisite.
4049
c0b0a142
SM
40502020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4051
4052 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4053 * linux-arm-tdesc.h: Include arch/arm.h.
4054
bb1183e2
SM
40552020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4056
4057 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4058
f5df0b5f
SM
40592020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4060
4061 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4062 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4063
5b6d1e4f
PA
40642020-01-10 Pedro Alves <palves@redhat.com>
4065
4066 * fork-child.c (post_fork_inferior): Pass target down to
4067 startup_inferior.
4068 * inferiors.c (switch_to_thread): Add process_stratum_target
4069 parameter.
4070 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4071 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4072 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4073 * remote-utils.c (prepare_resume_reply): Pass the target to
4074 switch_to_thread.
4075 * target.c (the_target): Now a process_stratum_target.
4076 (done_accessing_memory): Pass the target to switch_to_thread.
4077 (set_target_ops): Ajust to use process_stratum_target.
4078 * target.h (struct target_ops): Rename to ...
4079 (struct process_stratum_target): ... this.
4080 (the_target, set_target_ops): Adjust.
4081 (prepare_to_access_memory): Adjust comment.
4082 * win32-low.c (child_xfer_memory): Adjust to use
4083 process_stratum_target.
4084 (win32_target_ops): Now a process_stratum_target.
4085
559e7e50
EZ
40862020-01-06 Eli Zaretskii <eliz@gnu.org>
4087 Pedro Alves <palves@redhat.com>
4088
4089 * win32-low.c (get_child_debug_event): Extract the fatal exception
4090 from the exit status and convert to the equivalent Posix signal
4091 number.
4092 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4093 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4094
48189bec
HD
40952020-01-01 Hannes Domani <ssbssa@yahoo.de>
4096
4097 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4098
5dd8bf88
JB
40992020-01-01 Joel Brobecker <brobecker@adacore.com>
4100
4101 * server.c (gdbserver_version): Change copyright year to 2020.
4102 * gdbreplay.c (gdbreplay_version): Likewise.
4103
0ad6b8ee
CB
41042019-12-19 Christian Biesinger <cbiesinger@google.com>
4105
4106 * configure: Regenerate.
4107 * configure.ac: Quote variable arguments of test.
4108
1ee7b812
BE
41092019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4110
4111 * Makefile.in: Fix build with GNU Make 3.81
4112
d9fa87f4
TT
41132019-12-16 Tom Tromey <tromey@adacore.com>
4114
4115 * server.c (get_exec_file): Constify result.
4116
ab7d13f0
CB
41172019-12-10 Christian Biesinger <cbiesinger@google.com>
4118
4119 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4120 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4121 * config.in: Regenerate.
4122 * configure: Regenerate.
4123 * configure.ac: Don't check for strerror.
4124 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4125 Call safe_strerror instead of strerror.
4126 * server.h (strerror): Remove this now-unnecessary declaration.
4127 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4128 strerror.
4129 (gdb_agent_helper_thread): Likewise.
4130 * utils.c (perror_with_name): Likewise.
4131
4da8c3a8
TT
41322019-11-26 Tom Tromey <tom@tromey.com>
4133
4134 * configure, config.in: Rebuild.
4135
21987b9c
TT
41362019-11-26 Tom Tromey <tom@tromey.com>
4137
4138 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4139 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4140 gdb_sigmask.
4141 * configure, config.in: Rebuild.
4142
5e030278
TT
41432019-11-26 Tom Tromey <tom@tromey.com>
4144
4145 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4146 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4147 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4148 * acinclude.m4: Include ax_pthread.m4.
4149 * config.in, configure: Rebuild.
4150
6d91ce9a
CB
41512019-11-26 Christian Biesinger <cbiesinger@google.com>
4152
4153 * debug.c (debug_set_output): Call safe_strerror instead of
4154 strerror.
4155 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4156 (linux_kill_one_lwp): Likewise.
4157 (linux_detach_one_lwp): Likewise.
4158 (linux_wait_for_event_filtered): Likewise.
4159 (store_register): Likewise.
4160 * lynx-low.c (lynx_attach): Likewise.
4161 * mem-break.c (insert_memory_breakpoint): Likewise.
4162 (remove_memory_breakpoint): Likewise.
4163 (delete_fast_tracepoint_jump): Likewise.
4164 (set_fast_tracepoint_jump): Likewise.
4165 (uninsert_fast_tracepoint_jumps_at): Likewise.
4166 (reinsert_fast_tracepoint_jumps_at): Likewise.
4167 * nto-low.c (nto_xfer_memory): Likewise.
4168 (nto_resume): Likewise.
4169
6cdd651f
LM
41702019-11-20 Luis Machado <luis.machado@linaro.org>
4171
4172 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4173 instead of register count.
4174 * tdesc.c (tdesc_contains_feature): New function.
4175 * tdesc.h (tdesc_contains_feature): New prototype.
4176
cd850b40
CB
41772019-11-15 Christian Biesinger <cbiesinger@google.com>
4178
4179 * Makefile.in: Add safe-strerror.c.
4180 * configure: Regenerate.
4181 * configure.ac: Don't source common.host.
4182
5abebf3c
CB
41832019-11-15 Christian Biesinger <cbiesinger@google.com>
4184
4185 * config.in: Regenerate.
4186 * configure: Regenerate.
4187
e06f3d6e
AB
41882019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4189
4190 * ax.c (ax_printf): Handle size_t_arg.
4191
ca3a04f6
CB
41922019-11-06 Christian Biesinger <cbiesinger@google.com>
4193
4194 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4195 * mi/mi-main.c (output_cores): Likewise.
4196 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4197 (linux_xfer_osdata_modules): Likewise.
4198 * remote.c (register_remote_support_xml): Likewise.
4199 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4200 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4201
e48f6033
CB
42022019-11-01 Christian Biesinger <cbiesinger@google.com>
4203
4204 * configure: Regenerate.
4205 * configure.ac: Remove check for strerror_r.
4206
e7e97a2e
CB
42072019-10-31 Christian Biesinger <cbiesinger@google.com>
4208
4209 * config.in: Regenerate.
4210 * configure: Regenerate.
4211 * configure.ac: Also check for strerror_r.
4212
75cafaa6
CB
42132019-10-31 Christian Biesinger <cbiesinger@google.com>
4214
4215 * ax.h (debug_agent): Remove duplicate declaration.
4216
30baf67b
TV
42172019-10-26 Tom de Vries <tdevries@suse.de>
4218
4219 * linux-aarch64-low.c: Fix typos in comments.
4220 * linux-arm-low.c: Same.
4221 * linux-low.c: Same.
4222 * linux-ppc-low.c: Same.
4223 * proc-service.c: Same.
4224 * regcache.h: Same.
4225 * server.c: Same.
4226 * tracepoint.c: Same.
4227 * win32-low.c: Same.
4228
52c64cf7
TT
42292019-10-25 Tom Tromey <tromey@adacore.com>
4230
4231 * utils.c (xstrdup): Remove.
4232
c12d372d
TT
42332019-10-23 Tom Tromey <tom@tromey.com>
4234
4235 * configure, config.in: Rebuild.
4236
4d0b984b
TT
42372019-10-23 Tom Tromey <tom@tromey.com>
4238
4239 * configure: Rebuild.
4240 * acinclude.m4: Use m4_include, not sinclude.
4241
c5adaa19
TT
42422019-10-17 Tom Tromey <tromey@adacore.com>
4243
4244 * configure: Rebuild.
4245 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4246 in AC_CONFIG_FILES invocation.
4247 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4248 invocation.
4249
fec4e896
CB
42502019-10-16 Christian Biesinger <cbiesinger@google.com>
4251
4252 * server.c: Include xml-builtin.h.
4253 (get_xml_features): Don't declare xml_builtins here.
4254
00975ff6
AB
42552019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4256
4257 * Makefile.in: Remove references to vec-ipa.o.
4258
0dc32745
AB
42592019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4260
4261 * Makefile.in: Remove references to vec.c.
4262
3e6ec53a
CB
42632019-10-02 Christian Biesinger <cbiesinger@google.com>
4264
4265 * server.c (server_waiting): Change to bool.
4266 (extended_protocol): Likewise.
4267 (response_needed): Likewise.
4268 (exit_requested): Likewise.
4269 (run_once): Likewise.
4270 (report_no_resumed): Likewise.
4271 (non_stop): Likewise.
4272 (disable_packet_vCont): Likewise.
4273 (disable_packet_Tthread): Likewise.
4274 (disable_packet_qC): Likewise.
4275 (disable_packet_qfThreadInfo): Likewise.
4276 (handle_general_set): Update.
4277 (handle_detach): Update.
4278 (handle_monitor_command): Update.
4279 (handle_query): Update.
4280 (captured_main): Update.
4281 (process_serial_event): Update.
4282 * server.h (server_waiting): Change to bool.
4283 (disable_packet_vCont): Likewise.
4284 (disable_packet_Tthread): Likewise.
4285 (disable_packet_qC): Likewise.
4286 (disable_packet_qfThreadInfo): Likewise.
4287 (run_once): Likewise.
4288 (non_stop): Likewise.
4289 * target.c (target_stop_and_wait): Update.
4290
80fd2826
TT
42912019-10-02 Tom Tromey <tromey@adacore.com>
4292
4293 * Makefile.in (SFILES): Add common-inferior.c.
4294 (OBS): Add common-inferior.o.
4295 * server.c (startup_with_shell): Don't define.
4296
46f29a9a
AB
42972019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4298
4299 * linux-low.c (linux_low_read_btrace): Update for change to
4300 std::vector.
4301
f9d949fb
CB
43022019-09-20 Christian Biesinger <cbiesinger@google.com>
4303
4304 * debug.c (debug_threads): Remove comment in favor of the header.
4305 * debug.h (using_threads): Add declaration.
4306 (debug_threads): Add comment.
4307 * linux-aarch64-low.c: Include debug.h and remove declaration of
4308 debug_threads.
4309 * nto-low.c: Likewise.
4310 * remote-utils.c: Likewise.
4311 * thread-db.c: Likewise.
4312
abf516c6
UW
43132019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4314
4315 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4316 and powerpc-cell64l-ipa.o.
4317 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4318 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4319 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4320 (spu*-*-*): Remove.
4321
4322 * spu-low.c: Remove file.
4323
4324 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4325 (parse_spufs_run): Remove.
4326 (ppc_get_pc): Remove Cell/B.E. support.
4327 (ppc_set_pc): Likewise.
4328 (ppc_breakpoint_at): Likewise.
4329 (ppc_arch_setup): Likewise.
4330 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4331 tdesc_powerpc_cell32l.
4332 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4333 or init_registers_powerpc_cell32l.
4334 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4335 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4336 or init_registers_powerpc_cell32l.
4337 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4338 (init_registers_powerpc_cell32l): Remove prototype.
4339 (init_registers_powerpc_cell64l): Likewise.
4340
4341 * target.h (struct target_ops): Remove qxfer_spu member.
4342 * server.c (handle_qxfer_spu): Remove.
4343 (qxfer_packets): Remove entry for "spu".
4344 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4345 * linux-low.c (SPUFS_MAGIC): Remove.
4346 (spu_enumerate_spu_ids): Remove.
4347 (linux_qxfer_spu): Remove.
4348 (linux_target_ops): Remove qxfer_spu member.
4349 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4350 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4351 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4352
2d41fa11
SDJ
43532019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4354
4355 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4356 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4357 * config.in: Regenerate.
4358 * configure: Regenerate.
4359
d59b55f0
TT
43602019-08-15 Tom Tromey <tromey@adacore.com>
4361
4362 * target.c (target_write_memory): Use gdb::byte_vector.
4363
4196ab2a
TT
43642019-08-15 Tom Tromey <tromey@adacore.com>
4365
4366 * tracepoint.c (write_inferior_data_pointer)
4367 (write_inferior_integer, write_inferior_int8)
4368 (write_inferior_uinteger, m_tracepoint_action_download)
4369 (r_tracepoint_action_download, x_tracepoint_action_download)
4370 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4371 (download_agent_expr, download_tracepoint_1)
4372 (download_trace_state_variables, upload_fast_traceframes): Update.
4373 * server.c (gdb_write_memory): Update.
4374 * remote-utils.c (relocate_instruction): Update.
4375 * proc-service.c (ps_pdwrite): Update.
4376 * mem-break.c (remove_memory_breakpoint)
4377 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4378 (uninsert_fast_tracepoint_jumps_at)
4379 (reinsert_fast_tracepoint_jumps_at): Update.
4380 * linux-x86-low.c (append_insns)
4381 (i386_install_fast_tracepoint_jump_pad)
4382 (amd64_write_goto_address, i386_write_goto_address): Update.
4383 * linux-s390-low.c (append_insns, s390_write_goto_address):
4384 Update.
4385 * linux-ppc-low.c (ppc_relocate_instruction)
4386 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4387 (ppc_write_goto_address): Update.
4388 * linux-aarch64-low.c (append_insns): Update.
4389 * target.h (struct target_ops): Update.
4390 (write_inferior_memory): Don't declare.
4391 * target.c (target_write_memory): Rename from
4392 write_inferior_memory. Remove old target_write_memory.
4393
c6778d00
TT
43942019-08-15 Tom Tromey <tromey@adacore.com>
4395
4396 * target.c (write_inferior_memory): Use std::vector.
4397
404f2902
FCE
43982019-08-06 Frank Ch. Eigler <fche@redhat.com>
4399
4400 PR build/24886
4401 * configure.ac: Drop enable-libmcheck support.
4402 * configure, config.in: Rebuild.
4403 * acinclude.m4: Don't include it.
4404
4c5aa8e0
AH
44052019-07-19 Alan Hayward <alan.hayward@arm.com>
4406
4407 * configure.srv: Remove Arm xml files.
4408
7cc17433
AH
44092019-07-19 Alan Hayward <alan.hayward@arm.com>
4410
4411 * configure.srv: Add new files. Remove xml generated files.
4412 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4413 registers.
4414 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4415 * linux-aarch32-tdesc.c: New file.
4416 * linux-aarch32-tdesc.h: New file.
4417 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4418 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4419 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4420 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4421 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4422 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4423 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4424 (arm_read_description): Call arm_linux_read_description.
4425 (initialize_low_arch): Don't init registers.
4426 * linux-arm-tdesc.c: New file.
4427 * linux-arm-tdesc.h: New file.
4428
166a82be
AH
44292019-07-10 Alan Hayward <alan.hayward@arm.com>
4430
4431 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4432 Move counter inside for.
4433 (arm_read_description): Check ptrace earlier.
4434 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4435
268a13a5
TT
44362019-07-09 Tom Tromey <tom@tromey.com>
4437
4438 * configure: Rebuild.
4439 * configure.ac: Change common to gdbsupport.
4440 * acinclude.m4: Change common to gdbsupport.
4441 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4442 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4443 common to gdbsupport.
4444 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4445 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4446 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4447 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4448 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4449 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4450 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4451 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4452 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4453 common to gdbsupport.
4454
350fab54
AH
44552019-07-04 Alan Hayward <alan.hayward@arm.com>
4456
4457 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4458 defines.
4459 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4460
2b40fda7
AH
44612019-07-04 Alan Hayward <alan.hayward@arm.com>
4462
4463 * configure.srv: Remove legacy xml.
4464 * linux-aarch64-low.c (initialize_low_arch): Remove
4465 initialize_low_tdesc call.
4466 * linux-aarch64-tdesc-selftest.c: Remove file.
4467 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4468 * linux-x86-low.c (initialize_low_arch): Remove
4469 initialize_low_tdesc call.
4470 * linux-x86-tdesc-selftest.c: Remove file.
4471 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4472
7d10623d
TV
44732019-06-20 Tom de Vries <tdevries@suse.de>
4474
4475 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4476 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4477
8d6a48df
TV
44782019-06-19 Tom de Vries <tdevries@suse.de>
4479
4480 * debug.h (debug_write): Change return type to ssize_t.
4481 * debug.c (debug_write): Same.
4482
73cc7272
TT
44832019-06-14 Tom Tromey <tom@tromey.com>
4484
4485 * configure.ac: Use new path to gnulib.
4486 * configure: Rebuild.
4487 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4488 to gnulib.
4489
08f10e02
TT
44902019-06-11 Tom Tromey <tom@tromey.com>
4491
4492 * Makefile.in (SFILES): Add alloc.c.
4493 (OBS): Add alloc.o.
4494 (IPA_OBJS): Add alloc-ipa.o.
4495 (alloc-ipa.o): New target.
4496 (%.o: ../%.c): New pattern rule.
4497
422186a9
TT
44982019-06-10 Tom Tromey <tromey@adacore.com>
4499
4500 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4501 end warning with a newline.
4502 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4503 newline.
4504 * thread-db.c (attach_thread): Don't end warning with a newline.
4505 (thread_db_notice_clone): Likewise.
4506 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4507 newline.
4508 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4509 end warning with a newline.
4510
b02f78f9
PA
45112019-06-04 Pedro Alves <palves@redhat.com>
4512
4513 * server.c (captured_main): Use make_unique_xstrdup.
4514
88ed7edb
TT
45152019-06-02 Tom Tromey <tom@tromey.com>
4516
4517 * gdbreplay.c (fromhex): Remove.
4518 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4519
33a6bc35
TT
45202019-05-29 Tom Tromey <tromey@adacore.com>
4521
4522 * configure: Rebuild.
4523
e90a813d
KB
45242019-05-06 Kevin Buettner <kevinb@redhat.com>
4525
4526 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4527 sign extension code on 32-bit builds.
4528
353ea2d1
EZ
45292019-05-03 Eli Zaretskii <eliz@gnu.org>
4530
4531 * remote-utils.c:
4532 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4533
b494cdff
TT
45342019-04-19 Tom Tromey <tom@tromey.com>
4535
4536 * server.c (struct vstop_notif): Derive from notif_event.
4537 <base>: Remove.
4538 (queue_stop_reply): Update.
4539 (remove_all_on_match_ptid): Change type. Rewrite.
4540 (discard_queued_stop_replies): Rewrite.
4541 (in_queued_stop_replies_ptid): Change type.
4542 (in_queued_stop_replies): Rewrite.
4543 (notif_stop): Update.
4544 (queue_stop_reply_callback): Update.
4545 (captured_main): Don't call initialize_notif.
4546 (push_stop_notification): Update.
4547 * notif.c (notif_write_event, handle_notif_ack)
4548 (notif_event_enque, notif_push): Update.
4549 (notif_event_xfree, initialize_notif): Remove.
4550 * notif.h (struct notif_event): Include <list>, not
4551 "common/queue.h".
4552 (struct notif_server) <queue>: Now a std::list.
4553 (notif_event_p): Remove typedef.
4554 (initialize_notif): Don't declare.
4555 (struct notif_event): Add virtual destructor.
4556
a7e559cc
AH
45572019-04-17 Alan Hayward <alan.hayward@arm.com>
4558
4559 * ax.c (ax_vdebug): Call debug_printf.
4560 * debug.c (debug_write): New function.
4561 * debug.h (debug_write): New declaration.
4562 * linux-low.c (sigchld_handler): Call debug_write.
4563
aeb2e706
AH
45642019-04-17 Alan Hayward <alan.hayward@arm.com>
4565
4566 * debug.c (debug_set_output): New function.
4567 (debug_vprintf): Send output to debug_file.
4568 (debug_flush): Likewise.
4569 * debug.h (debug_set_output): New declaration.
4570 * server.c (handle_monitor_command): Add debug-file option.
4571 (captured_main): Likewise.
4572
c1bc0935
AH
45732019-04-17 Alan Hayward <alan.hayward@arm.com>
4574
4575 * debug.c (remote_debug): Add definition.
4576 * debug.h (remote_debug): Add declaration.
4577 * hostio.c (remote_debug): Remove declaration.
4578 * remote-utils.c (struct ui_file): Likewise.
4579 (remote_debug): Likewise.
4580 * remote-utils.h (remote_debug): Likewise,
4581 * server.c (remote_debug): Remove definition.
4582
3f52fdbc
KB
45832019-04-10 Kevin Buettner <kevinb@redhat.com>
4584
4585 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4586 when using a 64-bit gdbserver.
4587
b0319eaa
TT
45882019-04-09 Tom Tromey <tromey@adacore.com>
4589
4590 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4591
eedc3f4f
TT
45922019-04-08 Tom Tromey <tom@tromey.com>
4593
4594 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4595 throw.
4596 (linux_resume_one_lwp): Likewise.
4597
230d2906
TT
45982019-04-08 Tom Tromey <tom@tromey.com>
4599
4600 * gdbreplay.c: Update.
4601 * linux-low.c: Update.
4602 * server.c: Update.
4603
a70b8144
TT
46042019-04-08 Tom Tromey <tom@tromey.com>
4605
4606 * server.c: Use C++ exception handling.
4607 * linux-low.c: Use C++ exception handling.
4608 * gdbreplay.c: Use C++ exception handling.
4609
3d6e9d23
TT
46102019-04-08 Tom Tromey <tom@tromey.com>
4611
4612 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4613 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4614 (captured_main, main): Update.
4615 * gdbreplay.c (main): Update.
4616
0570503d
PFC
46172019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4618
4619 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4620 value in argument pointer, return 1 if the entry is found and 0
4621 otherwise. Move comment.
4622 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4623 * linux-low.h (linux_get_auxv): Declare.
4624 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4625
227a9e65
TT
46262019-04-05 Tom Tromey <tromey@adacore.com>
4627
4628 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4629 variables.
4630
69f4c9cc
AH
46312019-03-28 Alan Hayward <alan.hayward@arm.com>
4632
4633 * linux-low.c (AT_HWCAP2): Add define if not already included.
4634
974c89e0
AH
46352019-03-26 Alan Hayward <alan.hayward@arm.com>
4636
4637 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4638 (aarch64_arch_setup): Call linux_get_hwcap.
4639 * linux-arm-low.c (arm_get_hwcap): Remove function.
4640 (arm_read_description): Call linux_get_hwcap.
4641 * linux-low.c (linux_get_auxv): New function.
4642 (linux_get_hwcap): Likewise.
4643 (linux_get_hwcap2): Likewise.
4644 * linux-low.h (linux_get_hwcap): New declaration.
4645 (linux_get_hwcap2): Likewise.
4646 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4647 (ppc_arch_setup): Call linux_get_hwcap.
4648 * linux-s390-low.c (s390_get_hwcap): Remove function.
4649 (s390_arch_setup): Call linux_get_hwcap.
4650
1ef53e6b
AH
46512019-03-22 Alan Hayward <alan.hayward@arm.com>
4652 Jiong Wang <jiong.wang@arm.com>
4653
4654 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4655 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4656 to fail.
4657 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4658
ee4fbcfa
AH
46592019-03-22 Alan Hayward <alan.hayward@arm.com>
4660 Jiong Wang <jiong.wang@arm.com>
4661
4662 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4663 (aarch64_get_hwcap): New function.
4664 (aarch64_arch_setup): Read APIA hwcap.
4665
6dc0ebde
AH
46662019-03-22 Alan Hayward <alan.hayward@arm.com>
4667 Jiong Wang <jiong.wang@arm.com>
4668
4669 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4670 (initialize_low_tracepoint): Likewise.
4671 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4672 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4673 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4674 (aarch64_linux_read_description): Likewise.
4675 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4676
1163a4b7
JB
46772019-03-12 John Baldwin <jhb@FreeBSD.org>
4678
4679 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4680 i386_create_target_description for 'segments' parameter.
4681 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4682 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4683 * win32-i386-low.c (i386_arch_setup): Likewise.
4684
d3a70e03
TT
46852019-03-12 Tom Tromey <tromey@adacore.com>
4686
4687 * linux-low.c (iterate_over_lwps): Update.
4688
37991b4f
TT
46892019-03-06 Tom Tromey <tom@tromey.com>
4690
4691 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4692 (captured_main): Use SCOPE_EXIT.
4693
45950eb6
SDJ
46942019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4695
4696 * configure.srv: Use '$enable_unittest' instead of '$development'
4697 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4698 case.
4699
43ac54fc
TT
47002019-02-27 Tom Tromey <tromey@adacore.com>
4701
4702 * gdbreplay.c (logchar): Handle \r\n.
4703
df0da8a2
AH
47042019-02-07 Alan Hayward <alan.hayward@arm.com>
4705
4706 * linux-low.c (linux_attach): Add process before lwp.
4707 * server.c (attach_inferior): Check if already attached.
4708
1a5c2598
TT
47092019-02-07 Tom Tromey <tom@tromey.com>
4710
4711 * x86-tdesc.h: Rename include guard.
4712 * x86-low.h: Add include guard.
4713 * wincecompat.h: Rename include guard.
4714 * win32-low.h: Add include guard.
4715 * utils.h: Rename include guard.
4716 * tracepoint.h: Rename include guard.
4717 * tdesc.h: Rename include guard.
4718 * target.h: Rename include guard.
4719 * server.h: Rename include guard.
4720 * remote-utils.h: Rename include guard.
4721 * regcache.h: Rename include guard.
4722 * nto-low.h: Rename include guard.
4723 * notif.h: Add include guard.
4724 * mem-break.h: Rename include guard.
4725 * lynx-low.h: Add include guard.
4726 * linux-x86-tdesc.h: Add include guard.
4727 * linux-s390-tdesc.h: Add include guard.
4728 * linux-ppc-tdesc-init.h: Add include guard.
4729 * linux-low.h: Add include guard.
4730 * linux-aarch64-tdesc.h: Add include guard.
4731 * linux-aarch32-low.h: Add include guard.
4732 * inferiors.h: Rename include guard.
4733 * i387-fp.h: Rename include guard.
4734 * hostio.h: Rename include guard.
4735 * gdbthread.h: Rename include guard.
4736 * gdb_proc_service.h: Rename include guard.
4737 * event-loop.h: Rename include guard.
4738 * dll.h: Rename include guard.
4739 * debug.h: Rename include guard.
4740 * ax.h: Rename include guard.
4741
956cc47c
SN
47422018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4743
4744 PR gdb/23985
4745 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4746 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4747
a0707f3c
TT
47482019-01-25 Tom Tromey <tom@tromey.com>
4749
4750 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4751
0747795c
TT
47522019-01-25 Tom Tromey <tom@tromey.com>
4753
4754 * win32-low.c: Fix common/ includes.
4755 * win32-i386-low.c: Fix common/ includes.
4756 * tracepoint.c: Fix common/ includes.
4757 * thread-db.c: Fix common/ includes.
4758 * target.h: Fix common/ includes.
4759 * symbol.c: Fix common/ includes.
4760 * spu-low.c: Fix common/ includes.
4761 * server.h: Fix common/ includes.
4762 * server.c: Fix common/ includes.
4763 * remote-utils.c: Fix common/ includes.
4764 * regcache.h: Fix common/ includes.
4765 * regcache.c: Fix common/ includes.
4766 * nto-x86-low.c: Fix common/ includes.
4767 * notif.h: Fix common/ includes.
4768 * mem-break.h: Fix common/ includes.
4769 * lynx-low.c: Fix common/ includes.
4770 * lynx-i386-low.c: Fix common/ includes.
4771 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4772 * linux-x86-low.c: Fix common/ includes.
4773 * linux-low.c: Fix common/ includes.
4774 * inferiors.h: Fix common/ includes.
4775 * i387-fp.c: Fix common/ includes.
4776 * hostio.c: Fix common/ includes.
4777 * hostio-errno.c: Fix common/ includes.
4778 * gdbthread.h: Fix common/ includes.
4779 * gdbreplay.c: Fix common/ includes.
4780 * fork-child.c: Fix common/ includes.
4781 * event-loop.c: Fix common/ includes.
4782 * ax.c:
4783 (enum gdb_agent_op): Fix common/ includes.
4784
be6d4f74
TT
47852019-01-21 Tom Tromey <tom@tromey.com>
4786
4787 * tracepoint.c: Fix includes.
4788 * remote-utils.c: Fix includes.
4789 * linux-x86-low.c: Fix includes.
4790
66d91b39
JB
47912019-01-01 Joel Brobecker <brobecker@adacore.com>
4792
4793 * gdbreplay.c (gdbreplay_version): Update copyright year in
4794 version message.
4795 * server.c (gdbserver_version): Likewise.
4796
754e3168
AH
47972018-12-05 Alan Hayward <alan.hayward@arm.com>
4798
4799 * linux-low.c (add_lwp): Switch ordering.
4800
d105de22
TT
48012018-11-29 Tom Tromey <tom@tromey.com>
4802
4803 * win32-low.c (win32_join): Take pid, not process.
4804 * target.h (struct target_ops) <join>: Change argument type.
4805 (join_inferior): Change argument name.
4806 * spu-low.c (spu_join): Take pid, not process.
4807 * server.c (handle_detach): Preserve pid before destroying
4808 process.
4809 * lynx-low.c (lynx_join): Take pid, not process.
4810 * linux-low.c (linux_join): Take pid, not process.
4811
50138245
AH
48122018-11-23 Alan Hayward <alan.hayward@arm.com>
4813
4814 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4815 (aarch64_cannot_fetch_register): Likewise.
4816 (struct linux_target_ops): Update references.
4817
64f57f3d
PFC
48182018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4819
4820 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4821
8d619c01
EBM
48222018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4823
4824 * configure.srv (ipa_ppc_linux_regobj): Add
4825 powerpc-isa207-htm-vsx32l-ipa.o and
4826 powerpc-isa207-htm-vsx64l-ipa.o.
4827 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4828 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4829 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4830 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4831 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4832 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4833 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4834 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4835 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4836 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4837 (init_registers_powerpc_isa207_htm_vsx32l)
4838 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4839 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4840 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4841 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4842 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4843 (ppc_store_tm_ctarregset): New functions.
4844 (ppc_regsets): Add entries for HTM regsets.
4845 (ppc_arch_setup): Set htm in features struct when needed. Set
4846 sizes for the HTM regsets.
4847 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4848 (initialize_low_arch): Call
4849 init_registers_powerpc_isa207_htm_vsx32l and
4850 init_registers_powerpc_isa207_htm_vsx64l.
4851 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4852 PPC_TDESC_ISA207_HTM_VSX.
4853 (initialize_low_tracepoint): Call
4854 init_registers_powerpc_isa207_htm_vsx32l and
4855 init_registers_powerpc_isa207_htm_vsx64l.
4856
232bfb86
EBM
48572018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4858
4859 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4860 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4861 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4862 (ppc_store_pmuregset): New functions.
4863 (ppc_regsets): Add entries for ebb and pmu regsets.
4864 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4865 pmu regsets are available. Set sizes for these regsets.
4866
f2cf6173
EBM
48672018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4868
4869 * configure.srv (ipa_ppc_linux_regobj): Add
4870 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4871 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4872 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4873 rs6000/powerpc-isa207-vsx32l.xml, and
4874 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4875 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4876 <PPC_TDESC_ISA207_VSX>: New enum value.
4877 (init_registers_powerpc_isa207_vsx32l): Declare.
4878 (init_registers_powerpc_isa207_vsx64l): Declare.
4879 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4880 (ppc_store_tarregset): New function.
4881 (ppc_regsets): Add entry for the TAR regset.
4882 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4883 size for the TAR regsets.
4884 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4885 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4886 and init_registers_powerpc_isa207_vsx64l.
4887 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4888 (initialize_low_tracepoint): Call
4889 init_registers_powerpc_isa207_vsx32l and
4890 init_registers_powerpc_isa207_vsx64l.
4891
7ca18ed6
EBM
48922018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4893 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4894
4895 * configure.srv (ipa_ppc_linux_regobj): Add
4896 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4897 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4898 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4899 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4900 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4901 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4902 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4903 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4904 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4905 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4906 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4907 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4908 (ppc_hwcap): Add comment.
4909 (ppc_hwcap2): New global.
4910 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4911 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4912 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4913 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4914 when needed. Set sizes for the the DSCR and PPR regsets.
4915 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4916 (initialize_low_arch): Call
4917 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4918 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4919 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4920 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4921 (initialize_low_tracepoint): Call
4922 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4923 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4924
5c849b22
PFC
49252018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4926
4927 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
4928
8ecfd7bd
SDJ
49292018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
4930 Simon Marchi <simark@simark.ca>
4931
4932 * acinclude.m4: Include "../selftest.m4".
4933 * configure: Regenerate.
4934 * configure.ac: Use "GDB_AC_SELFTEST".
4935 * configure.srv: Use "$enable_unittests" instead of
4936 "$development" when checking whether unit tests have been
4937 enabled.
4938 * server.c (captured_main): Update message informing that
4939 selftests have been disabled.
4940
96643e35
TT
49412018-10-04 Tom Tromey <tom@tromey.com>
4942
4943 * configure: Rebuild.
4944
da4ae14a
TT
49452018-10-04 Tom Tromey <tom@tromey.com>
4946
4947 * server.c (handle_status): Rename inner "thread".
4948 (process_serial_event): Declare "res" in 'm' case.
4949 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
4950 (iterate_over_lwps): Rename inner "thread".
4951 (linux_qxfer_libraries_svr4): Rename inner "len".
4952 * gdbthread.h (find_thread_in_random): Rename inner "thread".
4953
7c619dbd
GB
49542018-10-01 Gary Benson <gbenson@redhat.com>
4955
4956 * gdb_proc_service.h: Moved common code to
4957 common/gdb_proc_service.h.
4958
3795e814
GB
49592018-10-01 Gary Benson <gbenson@redhat.com>
4960
4961 * gdb_proc_service.h: Synchronize comments and whitespace with
4962 GDB's version of this file.
4963
49b036f1
TT
49642018-09-25 Tom Tromey <tom@tromey.com>
4965
4966 * configure: Rebuild.
4967 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
4968
8ff03f0b
SM
49692018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4970
4971 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
4972 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
4973 ($(IPA_LIB)): Sort IPA_OBJS.
4974
a1cd91dc
SM
49752018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
4976
4977 * Makefile.in: Remove references to $(ADD_DEPS).
4978
752312ba
TT
49792018-09-16 Tom Tromey <tom@tromey.com>
4980
4981 * remote-utils.c (remote_open): Use GNU style for metasyntactic
4982 variables.
4983 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
4984 variables.
4985
f1628857
TT
49862018-09-05 Tom Tromey <tom@tromey.com>
4987
4988 * configure: Rebuild.
4989
ad202fcc
SM
49902018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4991
4992 PR build/23399
4993 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
4994
d3d8724a
TT
49952018-08-27 Tom Tromey <tom@tromey.com>
4996
4997 PR build/23087:
4998 * configure: Rebuild.
4999
b4f183d2
TT
50002018-08-27 Tom Tromey <tom@tromey.com>
5001
5002 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5003 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5004 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5005 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5006 (s390x_emit_stack_adjust): Add casts to unsigned char.
5007
4e2aa472
SM
50082018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5009
5010 PR gdb/23374
5011 PR gdb/23375
5012 * server.h (struct client_state) <disable_randomization>:
5013 Initialize to 1.
5014
cf4088a9
SM
50152018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5016
5017 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5018 variable.
5019 (mips_supply_ptrace_register): Likewise.
5020
a0de763e
TT
50212018-07-22 Tom Tromey <tom@tromey.com>
5022
5023 * configure: Rebuild.
5024
b0a7723d
TT
50252018-07-22 Tom Tromey <tom@tromey.com>
5026
5027 * win32-low.c (win32_create_inferior): Remove unused variables.
5028 * gdbreplay.c (remote_open): Remove unused variable.
5029 * remote-utils.c (remote_prepare): Remove unused variable.
5030 * x86-tdesc.h (X86_TDESC_H): Define.
5031 (amd64_expedite_regs): Define conditionally.
5032 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5033 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5034 * remote-utils.c (readchar): Remove unused variable.
5035
a780ef4f
PA
50362018-07-13 Pedro Alves <palves@redhat.com>
5037
5038 * linux-low.c (linux_kill): Change parameter to process_info
5039 pointer instead of pid. Adjust.
5040 * lynx-low.c (lynx_kill): Likewise.
5041 * nto-low.c (nto_kill): Likewise.
5042 * spu-low.c (spu_kill): Likewise.
5043 * win32-low.c (win32_kill): Likewise.
5044 * server.c (handle_v_kill, kill_inferior_callback)
5045 (detach_or_kill_for_exit): Adjust.
5046 * target.c (kill_inferior): Change parameter to process_info
5047 pointer instead of pid. Adjust.
5048 * target.h (struct target_ops) <kill>: Change parameter to
5049 process_info pointer instead of pid. Adjust all implementations
5050 and callers.
5051 (kill_inferior): Likewise.
5052
ef2ddb33
PA
50532018-07-13 Pedro Alves <palves@redhat.com>
5054
5055 * linux-low.c (linux_detach, linux_join): Change parameter to
5056 process_info pointer instead of pid. Adjust.
5057 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5058 * nto-low.c (nto_detach): Likewise.
5059 * spu-low.c (spu_detach, spu_join): Likewise.
5060 * win32-low.c (win32_detach, win32_join): Likewise.
5061 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5062 * target.h (struct target_ops) <detach, join>: Change parameter to
5063 process_info pointer instead of pid. Adjust all implementations
5064 and callers.
5065 (detach_inferior, join_inferior): Rename 'pid' parameter to
5066 'proc'.
5067
c7ab0aef
SDJ
50682018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5069 Jan Kratochvil <jan.kratochvil@redhat.com>
5070 Paul Fertser <fercerpav@gmail.com>
5071 Tsutomu Seki <sekiriki@gmail.com>
5072
5073 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5074 (OBS): Add 'common/netstuff.o'.
5075 (GDBREPLAY_OBS): Likewise.
5076 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5077 (remote_open): Implement support for IPv6
5078 connections.
5079 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5080 and 'wspiapi.h'.
5081 (handle_accept_event): Accept connections from IPv6 sources.
5082 (remote_prepare): Handle IPv6-style hostnames; implement
5083 support for IPv6 connections.
5084 (remote_open): Implement support for printing connections from
5085 IPv6 sources.
5086
31445d10
PA
50872018-07-11 Pedro Alves <palves@redhat.com>
5088
5089 PR gdb/23377
5090 * mem-break.c (any_persistent_commands): Add process_info
5091 parameter and use it instead of relying on the current process.
5092 Change return type to bool.
5093 * mem-break.h (any_persistent_commands): Add process_info
5094 parameter and change return type to bool.
5095 * server.c (handle_detach): Remove require_running_or_return call.
5096 Look up the process_info for the process we're about to detach.
5097 If not found, return back error to GDB. Adjust
5098 any_persistent_commands call to pass down a process pointer.
5099
cb197132
PA
51002018-07-11 Pedro Alves <palves@redhat.com>
5101
5102 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5103 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5104 instead of collect_register_by_name.
5105 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5106 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5107
1b919490
VB
51082018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5109 Pedro Alves <palves@redhat.com>
5110
5111 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5112
d7e15655
TT
51132018-07-03 Tom Tromey <tom@tromey.com>
5114
5115 * linux-low.c: Update.
5116 * lynx-low.c: Update.
5117 * mem-break.c: Update.
5118 * nto-low.c: Update.
5119 * remote-utils.c: Update.
5120 * server.c: Update.
5121 * spu-low.c: Update.
5122 * target.c: Update.
5123 * win32-low.c: Update.
5124
26a57c92
TT
51252018-07-03 Tom Tromey <tom@tromey.com>
5126
5127 * server.c: Update.
5128
0e998d96
TT
51292018-07-03 Tom Tromey <tom@tromey.com>
5130
5131 * linux-low.c: Update.
5132
cc6bcb54
TT
51332018-07-03 Tom Tromey <tom@tromey.com>
5134
5135 * target.c: Update.
5136
e38504b3
TT
51372018-07-03 Tom Tromey <tom@tromey.com>
5138
5139 * linux-low.c: Update.
5140 * linux-mips-low.c: Update.
5141 * lynx-low.c: Update.
5142 * nto-low.c: Update.
5143 * remote-utils.c: Update.
5144 * server.c: Update.
5145 * spu-low.c: Update.
5146 * target.c: Update.
5147 * thread-db.c: Update.
5148
e99b03dc
TT
51492018-07-03 Tom Tromey <tom@tromey.com>
5150
5151 * linux-low.c: Update.
5152 * linux-mips-low.c: Update.
5153 * lynx-low.c: Update.
5154 * mem-break.c: Update.
5155 * nto-low.c: Update.
5156 * remote-utils.c: Update.
5157 * server.c: Update.
5158 * spu-low.c: Update.
5159 * target.c: Update.
5160 * tracepoint.c: Update.
5161
f2907e49
TT
51622018-07-03 Tom Tromey <tom@tromey.com>
5163
5164 * linux-low.c: Update.
5165 * linux-ppc-low.c: Update.
5166 * linux-x86-low.c: Update.
5167 * proc-service.c: Update.
5168 * server.c: Update.
5169 * spu-low.c: Update.
5170 * thread-db.c: Update.
5171 * win32-low.c: Update.
5172
fd79271b
TT
51732018-07-03 Tom Tromey <tom@tromey.com>
5174
5175 * linux-low.c: Update.
5176 * lynx-low.c: Update.
5177 * nto-low.c: Update.
5178 * remote-utils.c: Update.
5179 * spu-low.c: Update.
5180 * thread-db.c: Update.
5181 * win32-low.c: Update.
5182
c0867626
SDJ
51832018-06-29 Joel Brobecker <brobecker@adacore.com>
5184
5185 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5186 parameter in call to 'amd64_create_target_description'.
5187
2512d7ef
JK
51882018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5189
5190 * x86-tdesc.h: Remove executable permission flag.
5191
d0ac1c44
SM
51922018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5193
5194 * configure.ac: Remove AC_PREREQ, add missing quoting.
5195 * configure: Re-generate.
5196 * config.in: Re-generate.
5197 * aclocal.m4: Re-generate.
5198
c4eb05ff
SM
51992018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5200
5201 * tracepoint.h (current_traceframe): Remove declaration.
5202
02895270
AH
52032018-06-18 Alan Hayward <alan.hayward@arm.com>
5204
5205 * linux-aarch64-low.c (is_sve_tdesc): New function.
5206 (aarch64_sve_regs_copy_to_regcache): Likewise.
5207 (aarch64_sve_regs_copy_from_regcache): Likewise.
5208 (aarch64_regs_info): Add SVE checks.
5209 (initialize_low_arch): Initialize SVE.
5210
e9902bfc
AH
52112018-06-18 Alan Hayward <alan.hayward@arm.com>
5212
5213 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5214
fefa175e
AH
52152018-06-11 Alan Hayward <alan.hayward@arm.com>
5216
5217 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5218 (initialize_low_tracepoint): Likewise
5219 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5220 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5221 param.
5222 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5223 checks.
5224 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5225
b91ad3ff
AH
52262018-06-11 Alan Hayward <alan.hayward@arm.com>
5227
5228 * server.h (PBUFSIZ): Increase size
5229
f868386e
AH
52302018-06-11 Alan Hayward <alan.hayward@arm.com>
5231
5232 * regcache.c (regcache::raw_compare): New function.
5233 * regcache.h (regcache::raw_compare): New declaration.
5234
9c861883
AH
52352018-06-11 Alan Hayward <alan.hayward@arm.com>
5236
5237 * regcache.c (new_register_cache): Use new.
5238 (free_register_cache): Use delete.
5239 (register_data): Use const.
5240 (supply_register): Move body inside regcache.
5241 (regcache::raw_supply): New override function.
5242 (collect_register): Move body inside regcache.
5243 (regcache::raw_collect): New override function.
5244 (regcache::get_register_status): New override function.
5245 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5246
40591844
TT
52472018-06-09 Tom Tromey <tom@tromey.com>
5248
5249 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5250 declare queue.
5251 (event_queue): Use std::queue.
5252 (gdb_event_xfree): Remove.
5253 (initialize_event_loop, process_event, wait_for_event): Update.
5254
6341380d
SC
52552018-06-08 Stan Cox <scox@redhat.com>
5256
5257 * win32-low.c (win32_create_inferior): last_ptid and last_status
5258 moved to client_state.
5259
03349c93
PA
52602018-06-08 Pedro Alves <palves@redhat.com>
5261
5262 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5263 common/common-exceptions.o, common/common-utils.o,
5264 common/errors.o, common/print-utils.o and utils.o.
5265 * gdbreplay.c: Include "common-defs.h" instead of the two
5266 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5267 string.h or alloca.h.
5268 (perror_with_name): Delete.
5269 (remote_open): Use xstrdup instead of strdup.
5270 (main): Rename to ...
5271 (captured_main): ... this.
5272 (main): New.
5273
8dcc53b3
TT
52742018-06-08 Tom Tromey <tom@tromey.com>
5275
5276 * linux-low.c (linux_low_read_btrace): Update.
5277
c12a5089
SC
52782018-06-04 Stan Cox <scox@redhat.com>
5279
5280 * server.h (struct client_state): New.
5281 * server.c (cont_thread, general_thread, multi_process)
5282 (report_fork_events, report_vfork_events, report_exec_events)
5283 (report_thread_events, swbreak_feature, hwbreak_feature)
5284 (vCont_supported, disable_randomization, pass_signals)
5285 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5286 Moved to client_state.
5287 * remote-utils.c (remote_debug, noack_mode)
5288 (transport_is_reliable): Moved to client_state.
5289 * tracepoint.c (current_traceframe): Moved to client_state.
5290
5291 Update all callers.
5292 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5293 linux-low.c, remote-utils.h, target.c: Use client_state.
5294
122394f1
AH
52952018-05-31 Alan Hayward <alan.hayward@arm.com>
5296
5297 * configure.srv: Add new c/h file.
5298
95228a0d
AH
52992018-05-31 Alan Hayward <alan.hayward@arm.com>
5300
5301 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5302 null VQ.
5303
d8dab6c3
MR
53042018-05-25 Maciej W. Rozycki <macro@mips.com>
5305
5306 * gdb.arch/mips-fpregset-core.exp: New test.
5307 * gdb.arch/mips-fpregset-core.c: New test source.
5308
81e25b7c
EK
53092018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5310
5311 PR server/23198
5312 * hostio.c (require_int): Do not report overflow for integers
5313 between 0xfffffff and 0x7fffffff.
5314
7e947ad3
MR
53152018-05-22 Maciej W. Rozycki <macro@mips.com>
5316
5317 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5318 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5319 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5320 functions.
5321 (the_low_target): Wire them.
5322
1d75a658
PFC
53232018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5324
5325 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5326 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5327 mode. Call collect_register_by_name with vscr using
5328 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5329 (ppc_store_vrregset): Add and set vscr_offset variable as in
5330 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5331 vscr_offset.
5332
d078308a
PFC
53332018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5334
5335 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5336 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5337 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5338
7273b5fc
PFC
53392018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5340
5341 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5342 (ppc_store_vsxregset): Likewise.
5343 (ppc_fill_vrregset): Likewise.
5344 (ppc_store_vrregset): Likewise.
5345 (ppc_fill_evrregset): Likewise.
5346 (ppc_store_evrregset): Likewise.
5347 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5348 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5349 needed.
5350
2e077f5e
PFC
53512018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5352
5353 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5354 wordsize of the inferior. Call ppc_linux_target_wordsize.
5355
bd64614e
PFC
53562018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5357
5358 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5359 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5360 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5361 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5362 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5363 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5364 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5365 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5366 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5367 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5368 (tdesc_powerpc_e500l): Remove.
5369 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5370 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5371 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5372 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5373 linux-ppc-tdesc.h.
5374 (ppc_arch_setup): Remove target description matching code. Fill a
5375 ppc_linux_features struct and call ppc_linux_match_description
5376 with it.
5377
75d74cca
MR
53782018-05-22 Maciej W. Rozycki <macro@mips.com>
5379
5380 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5381 width of the requested register exceeds the width of the
5382 `ptrace' data type.
5383 (mips_cannot_store_register): Likewise.
5384
e4439e43
MR
53852018-05-21 Maciej W. Rozycki <macro@mips.com>
5386
5387 * linux-mips-low.c (mips_fetch_register): New function. Update
5388 preceding comment.
5389 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5390 (the_low_target): Wire `mips_fetch_register'.
5391
55271bf9
JB
53922018-05-10 Joel Brobecker <brobecker@adacore.com>
5393
5394 * lynx-i386-low.c (LYNXOS_178): New macro.
5395 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5396 the layout on LynxOS-178.
5397 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5398 handle floating point registers that are not supported by
5399 LynxOS-178.
5400
1a34f210
TT
54012018-05-10 Tom Tromey <tom@tromey.com>
5402
5403 * configure: Rebuild.
5404
190852c8
JB
54052018-05-10 Joel Brobecker <brobecker@adacore.com>
5406
5407 PR server/23158:
5408 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5409 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5410 Use it to set the expedite_regs field in the given tdesc.
5411 * x86-tdesc.h: New file.
5412 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5413 Adjust following the addition of the new expedite_regs parameter
5414 to init_target_desc.
5415 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5416 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5417 (i386_linux_read_description, amd64_linux_read_description):
5418 Adjust following the addition of the new expedite_regs parameter
5419 to init_target_desc.
5420 * lynx-i386-low.c: #include "x86-tdesc.h".
5421 (lynx_i386_arch_setup): Adjust following the addition of the new
5422 expedite_regs parameter to init_target_desc.
5423 * nto-x86-low.c: #include "x86-tdesc.h".
5424 (nto_x86_arch_setup): Adjust following the addition of the new
5425 expedite_regs parameter to init_target_desc.
5426 * win32-i386-low.c: #include "x86-tdesc.h".
5427 (i386_arch_setup): Adjust following the addition of the new
5428 expedite_regs parameter to init_target_desc.
5429
7dbac825
JB
54302018-05-10 Joel Brobecker <brobecker@adacore.com>
5431
5432 PR server/23158:
5433 * win32-low.c (win32_create_inferior): Add call to my_wait
5434 setting last_status global.
5435
906994d9
JB
54362018-05-10 Joel Brobecker <brobecker@adacore.com>
5437
5438 PR server/23158:
5439 * win32-low.c (create_process): Only call gdb_tilde_expand if
5440 inferior_cwd is not NULL.
5441
8ee22052
AB
54422018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5443
5444 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5445 registers to the cache if their values have changed.
5446 (i387_xsave_to_cache): Provide default values for x87 control
5447 registers when these features are available, but disabled.
5448 * regcache.c (supply_register_by_name_zeroed): New function.
5449 * regcache.h (supply_register_by_name_zeroed): Declare new
5450 function.
5451
aff689d3
TT
54522018-05-07 Tom Tromey <tom@tromey.com>
5453
5454 * configure: Rebuild.
5455
85e26832
TT
54562018-05-04 Tom Tromey <tom@tromey.com>
5457
5458 * configure: Rebuild.
5459
a3b60e45
JK
54602018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5461 Pedro Alves <palves@redhat.com>
5462
5463 * linux-aarch64-low.c (aarch64_stopped_data_address):
5464 Likewise.
5465
632e107b
TT
54662018-04-27 Tom Tromey <tom@tromey.com>
5467
5468 * configure: Rebuild.
5469
458412c3
TT
54702018-04-23 Tom Tromey <tom@tromey.com>
5471
5472 * configure: Rebuild.
5473
f31c089e
SM
54742018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5475
5476 * Makefile.in (depcomp): Add "..".
5477 (all_deps_files): New and use it.
5478
b319b098
AH
54792018-04-18 Alan Hayward <alan.hayward@arm.com>
5480
5481 * configure.srv (aarch64*-*-linux*): Don't include xml.
5482 (i[34567]86-*-cygwin*): Likewise.
5483 (i[34567]86-*-linux*): Likewise.
5484 (i[34567]86-*-lynxos*): Likewise.
5485 (i[34567]86-*-mingw32ce*): Likewise.
5486 (i[34567]86-*-mingw*): Likewise.
5487 (i[34567]86-*-nto*): Likewise.
5488 (tic6x-*-uclinux): Likewise.
5489 (x86_64-*-linux*): Likewise.
5490 (x86_64-*-mingw*): Likewise.
5491 (x86_64-*-cygwin*): Likewise.
5492
3b74854b
AH
54932018-04-18 Alan Hayward <alan.hayward@arm.com>
5494
5495 * tdesc.c: Remove xml parameter.
5496
e98577a9
AH
54972018-04-18 Alan Hayward <alan.hayward@arm.com>
5498
5499 * server.c (get_features_xml): Remove cast.
5500 * tdesc.c (void target_desc::accept): Fill in function.
5501 (tdesc_get_features_xml): Remove old xml creation.
5502 (print_xml_feature::visit_pre): Add xml vistor.
5503 * tdesc.h (struct target_desc): Make xmltarget mutable.
5504 (tdesc_get_features_xml): Remove declaration.
5505
d278f585
AH
55062018-04-18 Alan Hayward <alan.hayward@arm.com>
5507
5508 * tdesc.c (tdesc_architecture_name): Add new function.
5509 (tdesc_osabi_name): Likewise.
5510 (tdesc_get_features_xml): Use new functions.
5511
eee8a18d
AH
55122018-04-18 Alan Hayward <alan.hayward@arm.com>
5513
5514 * tdesc.c (tdesc_create_flags): Remove.
5515 (tdesc_add_flag): Likewise.
5516 (tdesc_named_type): Likewise.
5517 (tdesc_create_union): Likewise.
5518 (tdesc_create_struct): Likewise.
5519 (tdesc_create_vector): Likewise.
5520 (tdesc_add_bitfield): Likewise.
5521 (tdesc_add_field): Likewise.
5522 (tdesc_set_struct_size): Likewise.
5523
82ec9bc7
AH
55242018-04-18 Alan Hayward <alan.hayward@arm.com>
5525
5526 * tdesc.c (~target_desc): Remove implictly deleted items.
5527 (init_target_desc): Iterate all features.
5528 (tdesc_get_features_xml): Use vector.
5529 (tdesc_create_feature): Create feature.
5530 * tdesc.h (tdesc_feature) Remove
5531 (target_desc): Add features.
5532
ea3e7d71
AH
55332018-04-18 Alan Hayward <alan.hayward@arm.com>
5534
5535 * Makefile.in: Add common/tdesc.c
5536 * tdesc.c (init_target_desc): init all reg_defs from register
5537 vector.
5538 (tdesc_create_reg): Create tdesc_reg.
5539 * tdesc.h (tdesc_feature): Add register vector.
5540
17d08cd4
SM
55412018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5542
5543 * tdesc.h (struct target_desc) <features>: Change type to
5544 std::vector<std::string>.
5545 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5546 changes.
5547 (tdesc_get_features_xml): Likewise.
5548 (tdesc_create_feature): Likewise.
5549
5cd3e386
AH
55502018-03-26 Alan Hayward <alan.hayward@arm.com>
5551
5552 * regcache.c (find_register_by_number): Return a ref.
5553 (find_regno): Use references.
5554 (register_size): Likewise.
5555 (register_data): Likewise.
5556 * tdesc.c (target_desc::~target_desc): Remove free calls.
5557 (target_desc::operator==): Use std::vector compare.
5558 (init_target_desc): Use reference.
5559 (tdesc_create_reg): Use reg constructors.
5560 * tdesc.h (struct target_desc): Replace pointer with object.
5561
dff7492c
AH
55622018-03-23 Alan Hayward <alan.hayward@arm.com>
5563
5564 * regcache.c (find_register_by_number): Make static.
5565 (find_regno): Use find_register_by_number
5566 * regcache.h (struct reg): Remove declaration.
5567
d80e5242
AH
55682018-03-23 Alan Hayward <alan.hayward@arm.com>
5569
5570 * tdesc.c (target_desc::~target_desc): Move to here.
5571 (target_desc::operator==): Likewise.
5572 * tdesc.h (target_desc::~target_desc): Move from here.
5573 (target_desc::operator==): Likewise.
5574
f69c5afb
AA
55752018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5576
5577 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5578
ce29f843
AA
55792018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5580
5581 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5582 S390_TDESC_GS.
5583 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5584 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5585 and init_registers_s390_gs_linux64.
5586
c49bd90b
AA
55872018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5588
5589 * linux-s390-low.c (s390_fill_gs): Remove function.
5590 (s390_fill_gsbc): Remove function.
5591 (s390_regsets): Set fill functions for the guarded storage regsets
5592 to NULL.
5593
7edb9bd3
AA
55942018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5595
5596 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5597 the word size. Add comment.
5598 (s390_get_wordsize): New function.
5599 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5600 pswm with it. Instead, use s390_get_wordsize to determine the
5601 word size first and derive the correct tdesc from that directly.
5602
39be3c7e
SM
56032018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5604
5605 * Makefile.in: Include silent-rules.mk.
5606 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5607 (COMPILE): Add ECHO_CXX.
5608 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5609 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5610 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5611 (version-generated.c): Add ECHO_GEN.
5612 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5613 (IPAGENT_COMPILE): Add ECHO_CXX.
5614 (%-generated.c): Add ECHO_REGDAT.
5615
3ae9ce5d
TT
56162018-03-14 Tom Tromey <tom@tromey.com>
5617
5618 PR cli/14977:
5619 * ax.c (ax_printf): Special case for NULL.
5620
e6a58aa8
SM
56212018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5622
5623 * linux-low.c (linux_qxfer_libraries_svr4): Use
5624 xml_escape_text_append.
5625
f6e8a41e
SM
56262018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5627
5628 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5629
b9671caf
SM
56302018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5631
5632 * server.c (handle_general_set): Remove unnecessary xstrdup.
5633
e80aaf61
SM
56342018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5635
5636 * server.c (parse_debug_format_options): Adjust to
5637 delim_string_to_char_ptr_vec changes.
5638 * thread-db.c (thread_db_load_search): Adjust to
5639 dirnames_to_char_ptr_vec changes.
5640
b1223e78
MM
56412018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5642
5643 * target.h (target_enable_btrace, target_disable_btrace)
5644 (target_read_btrace, target_read_btrace_conf): Turn macro into
5645 inline function. Throw error if target method is not defined.
5646 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5647 check for btrace target method. Be prepared to handle exceptions
5648 from btrace target methods.
5649
81561546
SDJ
56502018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5651
5652 * server.c (captured_main): Change order of error message printed
5653 when the current working directory cannot be found.
5654
25e3c82c
SDJ
56552018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5656
5657 * server.c: Include "filenames.h" and "pathstuff.h".
5658 (program_name): Delete variable.
5659 (program_path): New anonymous class.
5660 (get_exec_wrapper): Use "program_path" instead of
5661 "program_name".
5662 (handle_v_run): Likewise.
5663 (captured_main): Likewise.
5664 (process_serial_event): Likewise.
5665
b4987c95
SDJ
56662018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5667
5668 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5669 (OBJS): Add "pathstuff.o".
5670 * server.c (current_directory): New global variable.
5671 (captured_main): Initialize "current_directory".
5672
f46cd62a
AH
56732018-02-26 Alan Hayward <alan.hayward@arm.com>
5674
5675 * tdesc.c: Use common/tdesc.h.
5676 * tdesc.h: Likewise.
5677
a543c5ca
AH
56782018-02-20 Alan Hayward <alan.hayward@arm.com>
5679 Simon Marchi <simon.marchi@ericsson.com>
5680
5681 * Makefile.in: Switch order of make rules.
5682
b5884fa7
AH
56832018-02-19 Alan Hayward <alan.hayward@arm.com>
5684
5685 * Makefile.in: Add common directory in build.
5686 * configure.ac: Add common reference.
5687 * configure: Regenerate.
5688
de6242d3
MM
56892018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5690
5691 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5692 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5693 * spu-low.c (spu_target_ops): Likewise.
5694 * win32-low.c (win32_target_ops): Likewise.
5695 * server.c (supported_btrace_packets): Report packets unconditionally.
5696 * target.h (target_ops) <supports_btrace>: Remove.
5697 (target_supports_btrace): Remove.
5698
9ee23a85
MM
56992018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5700
5701 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5702 (handle_btrace_disable): Change return type to void. Use exceptions
5703 to report errors.
5704 (handle_btrace_general_set): Catch exception and copy message to
5705 return message.
5706
8ce47547
TT
57072018-02-08 Tom Tromey <tom@tromey.com>
5708
5709 * linux-low.c (install_software_single_step_breakpoints): Use
5710 make_scoped_restore.
5711 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5712 (do_restore_current_thread_cleanup): Remove.
5713 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5714 declare.
5715
45dd3607
TT
57162018-02-08 Tom Tromey <tom@tromey.com>
5717
5718 * mem-break.c (set_raw_breakpoint_at): Use
5719 gdb::unique_xmalloc_ptr.
5720
e671cd59
PA
57212018-01-30 Pedro Alves <palves@redhat.com>
5722
5723 PR gdb/13211
5724 * target.c (target_terminal::terminal_state): Rename to ...
5725 (target_terminal::m_terminal_state): ... this.
5726
a0aad537
JC
57272018-01-19 James Clarke <jrtc27@jrtc27.com>
5728
5729 * linux-low.c (handle_extended_wait): Surround call to
5730 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5731
4d9b86e1
SM
57322018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5733
5734 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5735 linux_ptrace_attach_fail_reason_string now returning an
5736 std::string.
5737 (linux_attach): Likewise.
5738 * thread-db.c (attach_thread): Likewise.
5739
f517c180
EA
57402018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5741
5742 PR gdb/21559
5743 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5744 checking for fs_base/gs_base fields in struct user_regs_struct.
5745 * configure: Regenerate.
5746
9a70f35c
YQ
57472018-01-16 Yao Qi <yao.qi@linaro.org>
5748
5749 PR gdb/18749
5750 * linux-low.c (fetch_register): Call supply_register instead of
5751 error.
5752
605fd3c6
YQ
57532018-01-08 Yao Qi <yao.qi@linaro.org>
5754 Simon Marchi <simon.marchi@ericsson.com>
5755
5756 * Makefile.in (OBS): Remove selftest.o.
5757 * configure.ac: Set srv_selftest_objs if $development is true.
5758 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5759 * configure: Re-generated.
5760 * server.c (captured_main): Wrap variable selftest_filter with
5761 GDB_SELF_TEST.
5762
2cc05030
SM
57632018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5764
5765 * server.c (parse_debug_format_options): Return std::string.
5766 (handle_monitor_command, captured_main): Adjust.
5767
e379cee6
PA
57682018-01-05 Pedro Alves <palves@redhat.com>
5769
5770 PR gdb/18653
5771 * server.c (captured_main): Pass quiet=false to
5772 save_original_signals_state.
5773
82e1e79a
JB
57742018-01-01 Joel Brobecker <brobecker@adacore.com>
5775
5776 * gdbreplay.c (gdbreplay_version): Update copyright year in
5777 version message.
5778 * server.c (gdbserver_version): Likewise.
5779
8e481c3b
TT
57802017-12-08 Tom Tromey <tom@tromey.com>
5781
5782 * ax.c (ax_printf): Update.
5783
a8806230
YQ
57842017-12-07 Yao Qi <yao.qi@linaro.org>
5785
5786 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5787 aarch64_linux_read_description.
5788 * linux-amd64-ipa.c (idx2mask): New array.
5789 (get_ipa_tdesc): Move idx2mask out.
5790 (initialize_low_tracepoint): Initialize target descriptions.
5791 * linux-i386-ipa.c (idx2mask): New array.
5792 (get_ipa_tdesc): Move idx2mask out.
5793 (initialize_low_tracepoint): Initialize target descriptions.
5794
d4a0e8b5
SM
57952017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5796
5797 * tdesc.c (struct tdesc_type): Change return type.
5798 (tdesc_add_flag): Change parameter type.
5799 (tdesc_add_bitfield): Likewise.
5800 (tdesc_add_field): Likewise.
5801 (tdesc_set_struct_size): Likewise.
5802
798a7429
SM
58032017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5804
5805 * regcache.c (registers_to_string): Remove unused variable.
5806
c0e15c9b
SM
58072017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5808
5809 * inferiors.c (for_each_inferior_with_data): Remove.
5810 * inferiors.h (for_each_inferior_with_data): Remove.
5811 * server.c (handle_qxfer_threads_worker): Change parameter type.
5812 (handle_qxfer_threads_proper): Use for_each_thread.
5813
f0045347
SM
58142017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5815
5816 * inferiors.c (for_each_inferior): Remove.
5817 (clear_inferiors): Use for_each_thread.
5818 * inferiors.h (for_each_inferior): Remove.
5819 * linux-low.c (linux_wait_for_event_filtered): Use
5820 for_each_thread.
5821 (linux_stabilize_threads): Likewise.
5822 * regcache.c (regcache_release): Likewise.
5823 * server.c (gdb_wants_all_threads_stopped): Likewise.
5824 (clear_pending_status_callback): Remove.
5825 (handle_status): Use for_each_thread.
5826 (captured_main): Likewise.
5827 * win32-low.c (child_init_thread_list): Likewise.
5828 (win32_clear_inferiors): Likewise.
5829 (fake_breakpoint_event): Likewise.
5830
9521758b
SM
58312017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5832
5833 * inferiors.h (find_inferior): Remove.
5834 * inferiors.c (find_inferior): Remove.
5835
8f86d7aa
SM
58362017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5837
5838 * linux-low.c (resume_status_pending_p): Update comment.
5839 (need_step_over_p): Update comment.
5840
e2b44075
SM
58412017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5842
5843 * linux-low.c (proceed_one_lwp): Return void, change parameter
5844 type.
5845 (unsuspend_and_proceed_one_lwp): Likewise.
5846 (proceed_all_lwps): Use for_each_thread.
5847 (unstop_all_lwps): Likewise.
5848
c80825ff
SM
58492017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5850
5851 * linux-low.c (linux_resume_one_thread): Return void, take
5852 parameter directly.
5853 (linux_resume): Use for_each_thread.
5854
df3e4dbe
SM
58552017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5856
5857 * linux-low.c (send_sigstop_callback): Return void, change
5858 parameter type. Rename to...
5859 (send_sigstop): ... this.
5860 (suspend_and_send_sigstop_callback): Return void, change parameter
5861 type. Rename to...
5862 (suspend_and_send_sigstop): ... this.
5863 (stop_all_lwps): Use for_each_thread.
5864
5a6b0a41
SM
58652017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5866
5867 * linux-low.c (lwp_running): Return bool, remove unused
5868 argument.
5869 (linux_stabilize_threads): Use find_thread.
5870
39a64da5
SM
58712017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5872
5873 * linux-low.c (select_singlestep_lwp_callback): Remove.
5874 (count_events_callback): Remove.
5875 (select_event_lwp_callback): Remove.
5876 (select_event_lwp): Use find_thread/for_each_thread.
5877
a1385b7b
SM
58782017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5879
5880 * linux-low.c (not_stopped_callback): Return bool, take filter
5881 argument directly.
5882 (linux_wait_for_event_filtered): Use find_thread.
5883 (linux_wait_1): Likewise.
5884
454296a2
SM
58852017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5886
5887 * linux-low.c (same_lwp): Remove.
5888 (find_lwp_pid): Use find_thread.
5889
6b2a85da
SM
58902017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5891
5892 * linux-low.c (delete_lwp_callback): Remove.
5893 (linux_mourn): Use for_each_thread.
5894
798a38e8
SM
58952017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5896
5897 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5898 args parameter, don't check for pid.
5899 (linux_detach): Use for_each_thread.
5900
e4eb0dec
SM
59012017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5902
5903 * linux-low.c (struct counter): Remove.
5904 (second_thread_of_pid_p): Remove.
5905 (last_thread_of_process_p): Use find_thread.
5906
83e1b6c1
SM
59072017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5908
5909 * inferiors.c (find_inferior_in_random): Remove.
5910 * inferiors.h (find_inferior_in_random): Remove.
5911 * linux-low.c (status_pending_p_callback): Return bool, accept
5912 parameter ptid directly.
5913 (linux_wait_for_event_filtered): Use find_thread_in_random.
5914 (linux_wait_1): Likewise.
5915
8dc7b443
SM
59162017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5917
5918 * inferiors.c (find_inferior_id): Remove.
5919 (find_thread_ptid): Move implemention from find_inferior_id to
5920 here.
5921 * inferiors.h (find_inferior_id): Remove.
5922 * server.c (handle_status): Use find_thread_ptid.
5923 (process_serial_event): Likewise.
5924 * thread-db.c (find_one_thread): Likewise.
5925 (thread_db_thread_handle): Likewise.
5926 * win32-low.c (thread_rec): Likewise.
5927 (child_delete_thread): Likewise.
5928 (win32_thread_alive): Likewise.
5929 (get_child_debug_event): Likewise.
5930
da25033c
SM
59312017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5932
5933 * linux-mips-low.c (update_watch_registers_callback): Return
5934 void, remove pid_p parameter, don't check for pid.
5935 (mips_insert_point, mips_remove_point): Use for_each_thread.
5936
c91bb56b
SM
59372017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5938
5939 * lynx.low (lynx_delete_thread_callback): Remove.
5940 (lynx_mourn): Use for_each_thread.
5941
634a3254
SM
59422017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5943
5944 * regcache.c (regcache_invalidate_one): Remove.
5945 (regcache_invalidate_pid): use for_each_thread.
5946
41272101
TT
59472017-11-26 Tom Tromey <tom@tromey.com>
5948
5949 * linux-low.c (linux_create_inferior): Update.
5950
f5291a6f
UW
59512017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
5952
5953 * spu-low.c (spu_create_inferior): Fix typo in argument name.
5954
6654d750
AH
59552017-11-24 Alan Hayward <alan.hayward@arm.com>
5956
5957 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
5958 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5959 * linux-aarch64-tdesc-selftest.c: New file.
5960 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5961
59622017-11-24 Alan Hayward <alan.hayward@arm.com>
5963
5964 * configure.srv: Add new file.
5965 * linux-aarch64-low.c (initialize_low_arch): Call init func.
5966 * linux-aarch64-tdesc-selftest.c: New file.
5967 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
5968
49bdb7ee
AH
59692017-11-24 Alan Hayward <alan.hayward@arm.com>
5970
5971 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
5972 * linux-aarch64-low.c (initialize_low_arch): Remove init.
5973 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
5974
d6d7ce56
AH
59752017-11-24 Alan Hayward <alan.hayward@arm.com>
5976
5977 * configure.srv: Add new files.
5978 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
5979 aarch64_linux_read_description.
5980 * linux-aarch64-low.c (aarch64_linux_read_description):
5981 Merge with aarch64_arch_setup.
5982 (aarch64_arch_setup): Call aarch64_linux_read_description.
5983 * linux-aarch64-tdesc.c: New file.
5984 * linux-aarch64-tdesc.h: New file.
5985
506fe5f4
YQ
59862017-11-24 Yao Qi <yao.qi@linaro.org>
5987
5988 * configure.srv: Set $srv_regobj for tic6x-linux.
5989 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
5990 (tic6x_read_description): Move some code to tic6x_arch_setup.
5991 (tic6x_tdesc_test): New function.
5992 (initialize_low_arch): Call selftests::register_test.
5993
29f9a567
YQ
59942017-11-22 Yao Qi <yao.qi@linaro.org>
5995
5996 * remote-utils.c (prepare_resume_reply): Use memcpy.
5997
578290ec
SM
59982017-11-19 Simon Marchi <simon.marchi@ericsson.com>
5999
6000 * linux-low.c (kill_one_lwp_callback): Return void, take
6001 argument directly, don't filter on pid.
6002 (linux_kill): Use for_each_thread.
6003
eca55aec
SM
60042017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6005
6006 * linux-low.c (need_step_over_p): Return bool, remove dummy
6007 argument.
6008 (linux_resume, proceed_all_lwps): Use find_thread.
6009
25c28b4d
SM
60102017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6011
6012 * linux-low.c (resume_status_pending_p): Return bool, remove
6013 flag_p argument.
6014 (linux_resume): Use find_thread.
6015
5fdda392
SM
60162017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6017
6018 * linux-low.c (struct thread_resume_array): Remove.
6019 (linux_set_resume_request): Return void, take arguments
6020 directly.
6021 (linux_resume): Use for_each_thread.
6022
fcb056a5
SM
60232017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6024
6025 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6026 return bool, remove data argument.
6027 (linux_stabilize_threads): Use find_thread.
6028
139720c5
SM
60292017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6030
6031 * linux-low.c (unsuspend_one_lwp): Remove.
6032 (unsuspend_all_lwps): Use for_each_thread, inline code from
6033 unsuspend_one_lwp.
6034
6d1e5673
SM
60352017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6036
6037 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6038 * linux-low.c (struct iterate_over_lwps_args): Remove.
6039 (iterate_over_lwps_filter): Remove.
6040 (iterate_over_lwps): Use find_thread.
6041
bbf550d5
SM
60422017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6043
6044 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6045 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6046 code from reset_lwp_ptrace_options_callback.
6047
00192f77
SM
60482017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6049
6050 * linux-arm-low.c (struct update_registers_data): Remove.
6051 (update_registers_callback): Return void, take arguments
6052 directly, don't check thread's pid.
6053 (arm_insert_point, arm_remove_point): Use for_each_thread.
6054
2bee2b6c
SM
60552017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6056
6057 * win32-low.c (continue_one_thread): Return void, take argument
6058 directly.
6059 (child_continue): Use for_each_thread.
6060
0b360f19
SM
60612017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6062
6063 * win32-i386-low.c (update_debug_registers_callback): Rename
6064 to ...
6065 (update_debug_registers): ... this, return void, remove pid_p arg.
6066 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6067
f27866ba
SM
60682017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6069
6070 * inferiors.h (struct process_info): Add constructor, initialize
6071 fields..
6072 <syscalls_to_catch>: Change type to std::vector<int>.
6073 * inferiors.c (add_process): Allocate process_info with new.
6074 (remove_process): Free process_info with delete.
6075 * linux-low.c (handle_extended_wait): Adjust.
6076 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6077 * server.c (handle_general_set): Adjust.
6078
e849ea89
PA
60792017-11-16 Pedro Alves <palves@redhat.com>
6080
6081 * remote-utils.c (remote_close): Block SIGIO signals instead of
6082 uninstalling the SIGIO handler.
6083
1d0aa65c
AH
60842017-11-16 Alan Hayward <alan.hayward@arm.com>
6085
6086 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6087
3491a34c
YQ
60882017-11-16 Yao Qi <yao.qi@linaro.org>
6089
6090 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6091 (tic6x_store_gregset): Likewise.
6092 (tic6x_usrregs_info): Move it up.
6093
a602f924
AH
60942017-11-15 Alan Hayward <alan.hayward@arm.com>
6095
6096 * Makefile.in: Update arch rules.
6097 * configure.srv: Explicitly mark arch/ files.
6098
5616b6c3
AS
60992017-11-13 Andreas Schwab <schwab@suse.de>
6100
6101 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6102 function.
6103 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6104
d1928160
PA
61052017-11-06 Pedro Alves <palves@redhat.com>
6106
6107 * config.in, configure: Regenerate.
6108
bac608e7
SM
61092017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6110
6111 * target.c (struct thread_search): Remove.
6112 (thread_search_callback): Remove.
6113 (prepare_to_access_memory): Use for_each_thread instead of
6114 find_inferior. Inline code from thread_search_callback.
6115
eaddb425
SM
61162017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6117
6118 * server.c (struct visit_actioned_threads_data): Remove.
6119 (visit_actioned_threads): Change prototype to take arguments
6120 directly.
6121 (resume): Use find_thread instead of find_inferior.
6122
99078d34
SM
61232017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6124
6125 * server.c (queue_stop_reply_callback): Change prototype, return
6126 void.
6127 (find_status_pending_thread_callback): Remove.
6128 (handle_status): Replace find_inferior with find_thread and
6129 for_each_thread.
6130
cc628f3d
AH
61312017-10-25 Alan Hayward <alan.hayward@arm.com>
6132
6133 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6134 with REGNO.
6135 (aarch64_store_gregset): Likewise.
6136 (aarch64_fill_fpregset): Likewise.
6137 (aarch64_store_fpregset): Likewise.
6138
4d3bb80e
SM
61392017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6140
6141 * gdbthread.h (find_thread, for_each_thread): New functions.
6142 * inferiors.c (thread_of_pid): Remove.
6143 (find_any_thread_of_pid): Use find_thread.
6144 * linux-low.c (num_lwps): Use for_each_thread.
6145
7a7cdfa0
YQ
61462017-10-17 Yao Qi <yao.qi@linaro.org>
6147
6148 * Makefile.in: Remove one rule.
6149 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6150
e675d170
YQ
61512017-10-17 Yao Qi <yao.qi@linaro.org>
6152
6153 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6154 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6155
7eb4e0f9
YQ
61562017-10-17 Yao Qi <yao.qi@linaro.org>
6157
6158 * configure.srv: Rename arm.o with arch/arm.o.
6159
60d6cfc9
YQ
61602017-10-17 Yao Qi <yao.qi@linaro.org>
6161
6162 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6163 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6164 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6165 (arch-i386.o, arch-amd64.o): Remove rules.
6166 (arch/%.o): New rule.
6167 Update POSTCOMPILE and COMPILE.pre.
6168 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6169 * configure: Re-generated.
6170 * configure.srv: Replace arch-i386.o with arch/i386.o.
6171 Replace arch-amd64.o with arch/amd64.o.
6172
5bfda255
YQ
61732017-10-16 Yao Qi <yao.qi@linaro.org>
6174
6175 * configure: Regenerated.
6176
9c80ecd6
SM
61772017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6178
6179 * inferiors.h: (struct inferior_list): Remove.
6180 (struct inferior_list_entry); Remove.
6181 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6182 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6183 get_first_inferior): Remove.
6184 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6185 find_inferior_id, find_inferior_in_random): Change signature.
6186 * inferiors.c (all_threads): Change type to
6187 std::list<thread_info *>.
6188 (get_thread): Remove macro.
6189 (find_inferior, find_inferior_id): Change signature, implement
6190 using find_thread.
6191 (find_inferior_in_random): Change signature, implement using
6192 find_thread_in_random.
6193 (for_each_inferior, for_each_inferior_with_data): Change
6194 signature, implement using for_each_thread.
6195 (add_inferior_to_list, remove_inferior): Remove.
6196 (add_thread, get_first_thread, thread_of_pid,
6197 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6198 (get_first_inferior, one_inferior_p, clear_inferior_list):
6199 Remove.
6200 (clear_inferiors, get_thread_process): Update.
6201 * gdbthread.h: Include <list>.
6202 (struct thread_info) <entry>: Remove field.
6203 <id>: New field.
6204 (all_threads): Change type to std::list<thread_info *>.
6205 (get_first_inferior): Add doc.
6206 (find_thread, for_each_thread, find_thread_in_random): New
6207 functions.
6208 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6209 * linux-arm-low.c (update_registers_callback): Update.
6210 * linux-low.c (second_thread_of_pid_p): Update.
6211 (kill_one_lwp_callback, linux_detach_lwp_callback,
6212 delete_lwp_callback, status_pending_p_callback, same_lwp,
6213 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6214 iterate_over_lwps, not_stopped_callback,
6215 resume_stopped_resumed_lwps, count_events_callback,
6216 select_singlestep_lwp_callback, select_event_lwp_callback,
6217 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6218 suspend_and_send_sigstop_callback, wait_for_sigstop,
6219 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6220 lwp_running, linux_set_resume_request, resume_status_pending_p,
6221 need_step_over_p, start_step_over, linux_resume_one_thread,
6222 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6223 reset_lwp_ptrace_options_callback): Update.
6224 * linux-mips-low.c (update_watch_registers_callback): Update.
6225 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6226 Update.
6227 (free_register_cache_thread_one): Remove.
6228 (regcache_release): Update.
6229 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6230 handle_qxfer_threads_worker): Update.
6231 (handle_query): Update, use list iterator.
6232 (visit_actioned_threads, handle_pending_status,
6233 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6234 clear_pending_status_callback, set_pending_status_callback,
6235 find_status_pending_thread_callback, handle_status,
6236 process_serial_event): Update.
6237 * target.c (thread_search_callback): Update.
6238 * thread-db.c (thread_db_get_tls_address): Update.
6239 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6240 Update.
6241 * win32-i386-low.c (update_debug_registers_callback): Update.
6242 * win32-low.c (delete_thread_info, child_delete_thread,
6243 continue_one_thread, suspend_one_thread,
6244 get_child_debug_event): Adjust.
6245
9179355e
SM
62462017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6247
6248 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6249 * inferiors.h: Include <list>.
6250 (struct process_info) <entry>: Remove field.
6251 <pid>: New field.
6252 (pid_of): Change macro to function.
6253 (ptid_of, lwpid_of): Remove macro.
6254 (all_processes): Change type to std::list<process_info *>.
6255 (ALL_PROCESSES): Remove macro.
6256 (for_each_process, find_process): New function.
6257 * inferiors.c (all_processes): Change type to
6258 std::list<process_info *>.
6259 (find_thread_process): Adjust.
6260 (add_process): Likewise.
6261 (remove_process): Likewise.
6262 (find_process_pid): Likewise.
6263 (get_first_process): Likewise.
6264 (started_inferior_callback): Remove.
6265 (have_started_inferiors_p): Adjust.
6266 (attached_inferior_callback): Remove.
6267 (have_attached_inferiors_p): Adjust.
6268 * linux-low.c (check_zombie_leaders): Likewise.
6269 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6270 (x86_linux_update_xmltarget): Adjust.
6271 * server.c (handle_query): Likewise.
6272 (gdb_reattached_process): Remove.
6273 (handle_status): Adjust.
6274 (kill_inferior_callback): Likewise.
6275 (detach_or_kill_inferior): Remove.
6276 (print_started_pid): Likewise.
6277 (print_attached_pid): Likewise.
6278 (detach_or_kill_for_exit): Update.
6279 (process_serial_event): Likewise.
6280 * linux-arm-low.c (arm_new_fork): Likewise.
6281
c9cb8905
SM
62822017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6283
6284 * dll.h: Include <list>.
6285 (struct dll_info): Add constructor.
6286 <entry>: Remove field.
6287 (all_dlls): Change type to std::list<dll_info>.
6288 * dll.c: Include <algorithm>.
6289 (get_dll): Remove macro.
6290 (all_dlls): Change type to std::list<dll_info *>.
6291 (free_one_dll): Remove.
6292 (match_dll): Likewise.
6293 (loaded_dll): Adjust.
6294 (unloaded_dll): Adjust to all_dlls type change, use
6295 std::find_if. Inline code from match_dll.
6296 (clear_dlls): Adjust to all_dlls type change.
6297 * server.c (emit_dll_description): Remove.
6298 (handle_qxfer_libraries): Adjust to all_dlls type change,
6299 integrate emit_dll_description's functionality.
6300
04ec7890
SM
63012017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6302
6303 * linux-low.h (struct linux_target_ops) <delete_process>: New
6304 field.
6305 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6306 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6307 (struct linux_target_ops): Add delete_process callback.
6308 * linux-arm-low.c (arm_delete_process): New.
6309 (struct linux_target_ops): Add delete_process callback.
6310 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6311 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6312 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6313 * linux-mips-low.c (mips_linux_delete_process): New.
6314 (struct linux_target_ops): Add delete_process callback.
6315 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6316 * linux-s390-low.c (struct linux_target_ops): Likewise.
6317 * linux-sh-low.c (struct linux_target_ops): Likewise.
6318 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6319 * linux-tile-low.c (struct linux_target_ops): Likewise.
6320 * linux-x86-low.c (x86_linux_delete_process): New.
6321 (struct linux_target_ops): Add delete_process callback.
6322 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6323
466eecee
SM
63242017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6325
6326 * linux-aarch64-low.c (the_low_target): Add thread delete
6327 callback.
6328 * linux-arm-low.c (arm_delete_thread): New function.
6329 (the_low_target): Add thread delete callback.
6330 * linux-bfin-low.c (the_low_target): Likewise.
6331 * linux-crisv32-low.c (the_low_target): Likewise.
6332 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6333 set.
6334 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6335 field.
6336 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6337 * linux-mips-low.c (mips_linux_delete_thread): New function.
6338 (the_low_target): Add thread delete callback.
6339 * linux-ppc-low.c (the_low_target): Likewise.
6340 * linux-s390-low.c (the_low_target): Likewise.
6341 * linux-sh-low.c (the_low_target): Likewise.
6342 * linux-tic6x-low.c (the_low_target): Likewise.
6343 * linux-tile-low.c (the_low_target): Likewise.
6344 * linux-x86-low.c (the_low_target): Likewise.
6345 * linux-xtensa-low.c (the_low_target): Likewise.
6346
b79f7801
YZ
63472017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6348
6349 * win32-low.c: Include "common-inferior.h".
6350
bc3b087d
SDJ
63512017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6352
6353 * inferiors.c (set_inferior_cwd): New function.
6354 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6355 (handle_query): Inform that QSetWorkingDir is supported.
6356 * win32-low.c (create_process): Pass the inferior's cwd to
6357 CreateProcess.
6358
d092c5a2
SDJ
63592017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6360
6361 * inferiors.c (current_inferior_cwd): New global variable.
6362 (get_inferior_cwd): New function.
6363 * inferiors.h (struct process_info) <cwd>: New field.
6364
7da0a886
SDJ
63652017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6366
6367 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6368 (OBS): Add gdb_tilde_expand.o.
6369
289a6840
SM
63702017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6371
6372 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6373 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6374
256642e8
PA
63752017-09-29 Pedro Alves <palves@redhat.com>
6376
6377 * ax.c (gdb_parse_agent_expr): Constify.
6378 * ax.h (gdb_parse_agent_expr): Constify.
6379 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6380 Constify.
6381 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6382 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6383 * remote-utils.h (read_ptid): Constify.
6384 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6385 (process_point_options, process_serial_event): Constify.
6386 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6387 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6388 (cmd_qtbuffer): Constify.
6389
5b9ca4d4
PA
63902017-09-29 Pedro Alves <palves@redhat.com>
6391
6392 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6393 fails.
6394
94c207e0
PA
63952017-09-29 Pedro Alves <palves@redhat.com>
6396
6397 * linux-low.c (handle_extended_wait): Pass parent thread instead
6398 of process to thread_db_notice_clone.
6399 * linux-low.h (thread_db_notice_clone): Replace parent process
6400 parameter with parent thread parameter.
6401 * thread-db.c (find_one_thread): Add comment.
6402 (thread_db_notice_clone): Replace parent process parameter with
6403 parent thread parameter. Temporarily switch to the parent thread.
6404
75352e28
SDJ
64052017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6406
6407 * gdbthread.h: Include "common-gdbthread.h".
6408 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6409 "if" when validating the ptid.
6410 * remote-utils.c: Include "gdbthread.h".
6411 (prepare_resume_reply): Use "switch_to_thread".
6412 * target.c (done_accessing_memory): Likewise.
6413
ad339634
AA
64142017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6415
6416 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6417 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6418 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6419 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6420 s390x-gs-linux64-ipa.o to ipa_obj.
6421 * linux-s390-low.c (HWCAP_S390_GS): New define.
6422 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6423 New functions.
6424 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6425 (s390_arch_setup): Check for guarded-storage support and choose
6426 appropriate tdesc.
6427 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6428 init_registers_s390x_gs_linux64.
6429 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6430 enum value.
6431 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6432 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6433
cc4d742f
SM
64342017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6435
6436 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6437
f6327dcb
KB
64382017-09-21 Kevin Buettner <kevinb@redhat.com>
6439
6440 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6441 (thread_db_thread_handle): Declare.
6442 * linux-low.c (linux_target_ops): Initialize thread_handle.
6443 * server.c (handle_qxfer_threads_worker): Add support for
6444 "handle" attribute.
6445 * target.h (struct target_ops): Add new function pointer,
6446 thread_handle.
6447 (target_thread_handle): Define.
6448 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6449 field in lwp.
6450 (thread_db_thread_handle): New function.
6451
86299109
KB
64522017-09-21 Kevin Buettner <kevinb@redhat.com>
6453
6454 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6455 * linux-low.h (thread_db_notice_clone): Declare.
6456 * thread-db.c (thread_db_notice_clone): New function.
6457
f557a88a
PA
64582017-09-21 Pedro Alves <palves@redhat.com>
6459
6460 * server.c (gdb_read_memory, handle_status, process_serial_event)
6461 (handle_serial_event, handle_target_event): Adjust to
6462 set_desired_thread prototype change.
6463 * target.c (set_desired_thread): Remove 'use_general' parameter
6464 and adjust.
6465 * target.h (set_desired_thread): Remove 'use_general' parameter.
6466
223ffa71
TT
64672017-09-20 Tom Tromey <tom@tromey.com>
6468
6469 * target.c (target_terminal::terminal_state): Define.
6470 (target_terminal::init): Rename from target_terminal_init.
6471 (target_terminal::inferior): Rename from
6472 target_terminal_inferior.
6473 (target_terminal::ours): Rename from target_terminal_ours.
6474 (target_terminal::ours_for_output, target_terminal::info): New.
6475
04fd3ba9
SM
64762017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6477
6478 * server.c (accumulate_file_name_length): Remove.
6479 (emit_dll_description): Adjust to std::string change.
6480 (handle_qxfer_libraries): Use std::string to hold document.
6481
5e187554
SM
64822017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6483
6484 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6485 return type of xml_escape_text.
6486 * server.c (emit_dll_description): Likewise.
6487
1526853e
SM
64882017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6489
6490 * server.c (captured_main): Accept argument for --selftest.
6491 Update run_tests call.
6492 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6493 when registering selftests.
6494
c4dfafab
SDJ
64952017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6496
6497 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6498 instead of "VEC" for "target_desc.reg_defs".
6499 (regcache_cpy): Likewise.
6500 (registers_to_string): Likewise.
6501 (registers_from_string): Likewise.
6502 (find_regno): Likewise.
6503 (supply_regblock): Likewise.
6504 (regcache_raw_read_unsigned): Likewise.
6505 * tdesc.c (init_target_desc): Likewise.
6506 (tdesc_create_reg): Likewise.
6507 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6508 (struct target_desc) <reg_defs>: Convert to "std::vector".
6509 (target_desc): Do not initialize "reg_defs".
6510 (~target_desc): Update code to use "std::vector" instead of "VEC"
6511 for "target_desc.reg_defs".
6512 (operator==): Likewise.
6513
124aceb4
SM
65142017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6515
6516 * inferiors.h (thread_to_gdb_id): Remove.
6517 * inferiors.c (thread_to_gdb_id): Remove.
6518 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6519 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6520 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6521 Likewise.
6522 * nto-low.c (nto_fetch_registers, nto_store_registers,
6523 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6524
96cde54f
SM
65252017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6526
6527 * inferiors.h (gdb_id_to_thread_id): Remove.
6528 * inferiors.c (gdb_id_to_thread_id): Remove.
6529 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6530 removal. Move pid declaration closer to where it's used.
6531
e8ca139e
SM
65322017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6533
6534 * server.c (handle_detach): New function.
6535 (process_serial_event): Move code out, call handle_detach.
6536
f8a4e119
SM
65372017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6538
6539 * server.c (require_running): Rename to ...
6540 (require_running_or_return): ... this ...
6541 (require_running_or_break): ... and this.
6542 (handle_query, process_serial_event): Adjust.
6543
0eb0a407
SM
65442017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6545
6546 * linux-low.c (linux_set_resume_request): Remove unused
6547 variables.
6548
785922a5
SM
65492017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6550
6551 * server.c (first_thread_of): Remove.
6552 (process_serial_event): Replace usage of first_thread_of with
6553 find_any_thread_of_pid.
6554 * tracepoint.c (same_process_p): Remove.
6555 (gdb_agent_about_to_close): Replace usage of same_process_p with
6556 find_any_thread_of_pid.
6557 * linux-x86-low.c (same_process_callback): Remove.
6558 (x86_arch_setup_process_callback): Replace usage of
6559 same_process_callback with find_any_thread_of_pid.
6560 * thread-db.c (any_thread_of): Remove.
6561 (switch_to_process): Replace usage of any_thread_of with
6562 find_any_thread_of_pid.
6563 * inferiors.c (thread_pid_matches_callback): Remove.
6564 (find_thread_process): Adjust to use find_any_thread_of_pid.
6565
a059f00c
SDJ
65662017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6567
6568 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 6569 with "!VEC_empty".
a059f00c 6570
cc397f3a
SDJ
65712017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6572
6573 * linux-low.c (handle_extended_wait): Use
6574 "allocate_target_description" instead of "XNEW".
6575 * linux-x86-low.c (initialize_low_arch): Likewise.
6576
22916b07
YQ
65772017-09-05 Yao Qi <yao.qi@linaro.org>
6578
6579 * configure.srv (srv_i386_regobj): Remove.
6580 (srv_amd64_regobj): Remove.
6581 (srv_regobj): Set it to "" for x86 non-linux targets.
6582 * linux-x86-tdesc.c (i386_linux_read_description):
6583 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6584 (init_registers_i386): Remove the declaration.
6585 (tdesc_i386): Remove the declaration.
6586 (lynx_i386_arch_setup): Call i386_create_target_description.
6587 * nto-x86-low.c: Likewise.
6588 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6589 [!__x86_64__]: include arch/i386.h.
6590 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6591
38602d55
YQ
65922017-09-05 Yao Qi <yao.qi@linaro.org>
6593
6594 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6595 i386/amd64-XXX-linux from it.
6596
44b886ff
YQ
65972017-09-05 Yao Qi <yao.qi@linaro.org>
6598
6599 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6600 false.
6601 (ipa_amd64_linux_regobj): Remove.
6602 (ipa_x32_linux_regobj): Remove.
6603
b4570e4b
YQ
66042017-09-05 Yao Qi <yao.qi@linaro.org>
6605
6606 * Makefile.in (arch-amd64.o): New rule.
6607 * configure.srv: Append arch-amd64.o.
6608 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6609 (get_ipa_tdesc): Call amd64_linux_read_description.
6610 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6611 and init_registers_amd64_XXX.
6612 * linux-x86-low.c (x86_linux_read_description): Call
6613 amd64_linux_read_description.
6614 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6615 (initialize_low_arch): Don't call init_registers_x32_XXX and
6616 init_registers_amd64_XXX.
6617 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6618 and tdesc_amd64_XXX.
6619 [__x86_64__] (amd64_tdesc_test): New function.
6620 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6621 and init_registers_amd64_XXX.
6622 * linux-x86-tdesc.c: Include arch/amd64.h.
6623 (xcr0_to_tdesc_idx): New function.
6624 (i386_linux_read_description): New function.
6625 (amd64_get_ipa_tdesc_idx): New function.
6626 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6627 (amd64_get_ipa_tdesc): Declare.
6628
d1f28ea2
YQ
66292017-09-05 Yao Qi <yao.qi@linaro.org>
6630
6631 * configure.srv (srv_i386_linux_xmlfiles): Remove
6632 i386/i386-XXX-linux.xml from it.
6633
25a93583
YQ
66342017-09-05 Yao Qi <yao.qi@linaro.org>
6635
6636 * configure.srv: Set srv_i386_linux_regobj empty if $development
6637 is false.
6638 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6639 initialize_low_tdesc.
6640 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6641 with #if initialize_low_tdesc.
6642 * linux-x86-tdesc-selftest.c: New file.
6643 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6644
5f035c07
YQ
66452017-09-05 Yao Qi <yao.qi@linaro.org>
6646
6647 * Makefile.in (arch-i386.o): New rule.
6648 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6649 (x86_64-*-linux*): Likewise.
6650 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6651 include arch/i386.h.
6652 (i386_linux_read_description): Remove code and call
6653 i386_create_target_description.
6654 * tdesc.c (allocate_target_description): New function.
6655 * tdesc.h (set_tdesc_architecture): Remove declaration.
6656 (set_tdesc_osabi): Likewise.
6657
0abe8a89
YQ
66582017-09-05 Yao Qi <yao.qi@linaro.org>
6659
6660 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6661 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6662 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6663 .xmltarget.
6664 * server.c (get_features_xml): Call tdesc_get_features_xml.
6665 * tdesc.c (set_tdesc_architecture): New function.
6666 (set_tdesc_osabi): New function.
6667 (tdesc_get_features_xml): New function.
6668 (tdesc_create_feature): Add an argument.
6669 * tdesc.h (struct target_desc) <features>: New field.
6670 <arch, osabi>: New field.
6671 (~target_desc): xfree features, arch, and osabi.
6672 (target_desc::oerator==): Don't compare .xmltarget.
6673 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6674 (set_tdesc_osabi): Likewise.
6675 (tdesc_get_features_xml): Likewise.
6676
0a188386
YQ
66772017-09-05 Yao Qi <yao.qi@linaro.org>
6678
6679 * linux-x86-tdesc.c: Include selftest.h.
6680 (i386_tdesc_test): New function.
6681 (initialize_low_tdesc): Call selftests::register_test.
6682 * tdesc.h: Include regdef.h.
6683 (target_desc): Override operator == and !=.
6684
f49ff000
YQ
66852017-09-05 Yao Qi <yao.qi@linaro.org>
6686
6687 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6688 (ipa_obj): Likewise.
6689 * linux-i386-ipa.c: Include common/x86-xstate.h
6690 (get_ipa_tdesc): Call i386_linux_read_description.
6691 (initialize_low_tracepoint): Don't call init_registers_XXX
6692 functions, call initialize_low_tdesc instead.
6693 * linux-x86-low.c (x86_linux_read_description): Call
6694 i386_linux_read_description.
6695 (initialize_low_arch): Don't call init_registers_i386_XXX
6696 functions, call initialize_low_tdesc.
6697 * linux-x86-tdesc.c: New file.
6698 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6699 (i386_get_ipa_tdesc_idx): Declare.
6700 (i386_get_ipa_tdesc): Declare.
6701 (initialize_low_tdesc): Declare.
6702
2b68ef2f
YQ
67032017-09-05 Yao Qi <yao.qi@linaro.org>
6704
6705 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6706 instead of 0.
6707
f7000548
YQ
67082017-09-05 Yao Qi <yao.qi@linaro.org>
6709
6710 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6711 * regcache.c (get_thread_regcache): Use VEC_length.
6712 (init_register_cache): Likewise.
6713 (regcache_cpy): Likewise.
6714 (registers_to_string): Iterate reg_defs via VEC_iterate.
6715 (find_regno): Likewise.
6716 (find_register_by_number): Use VEC_index.
6717 (register_size): Call find_register_by_number.
6718 (register_data): Call find_register_by_number.
6719 (supply_regblock): Use VEC_length.
6720 (regcache_raw_read_unsigned): Likewise.
6721 * tdesc.c (init_target_desc): Iterate reg_defs via
6722 VEC_iterate.
6723 (default_description): Update initializer.
6724 (copy_target_description): Don't update field num_registers.
6725 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6726 <num_registers>: Remove.
6727
50a421ac
SM
67282017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6729
6730 * Makefile.in (.SECONDARY): Define target.
6731
23fdd69e
SM
67322017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6733
6734 * linux-low.c (linux_wait_1): Adjust.
6735 * server.c (queue_stop_reply_callback): Adjust.
6736
0a2dde4a
SDJ
67372017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6738
6739 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6740 QEnvironmentUnset and QEnvironmentReset packets.
6741 (handle_query): Inform remote that QEnvironmentHexEncoded,
6742 QEnvironmentUnset and QEnvironmentReset are supported.
6743
6afd337d
SM
67442017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6745
6746 * inferiors.h (inferior_target_data): Rename to ...
6747 (thread_target_data): ... this.
6748 (inferior_regcache_data): Rename to ...
6749 (thread_regcache_data): ... this.
6750 (set_inferior_regcache_data): Rename to ...
6751 (set_thread_regcache_data): ... this.
6752 * inferiors.c (inferior_target_data): Rename to ...
6753 (thread_target_data): ... this.
6754 (inferior_regcache_data): Rename to ...
6755 (thread_regcache_data): ... this.
6756 (set_inferior_regcache_data): Rename to ...
6757 (set_thread_regcache_data): ... this.
6758 (free_one_thread): Update.
6759 * linux-low.h (get_thread_lwp): Update.
6760 * regcache.c (get_thread_regcache): Update.
6761 (regcache_invalidate_thread): Update.
6762 (free_register_cache_thread): Update.
6763 * win32-i386-low.c (update_debug_registers_callback): Update.
6764 (win32_get_current_dr): Update.
6765 * win32-low.c (thread_rec): Update.
6766 (delete_thread_info): Update.
6767 (continue_one_thread): Update.
6768 (suspend_one_thread): Update.
6769
a160cc46
SM
67702017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6771
6772 * inferiors.c (set_inferior_target_data): Remove.
6773 * inferiors.h (set_inferior_target_data): Remove.
6774
6d580b63
YQ
67752017-08-18 Yao Qi <yao.qi@linaro.org>
6776
6777 * Makefile.in (OBS): Add selftest.o.
6778 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6779 * configure, config.in: Re-generated.
6780 * server.c: Include common/sefltest.h.
6781 (captured_main): Handle option --selftest.
6782
f5a29eb0
YQ
67832017-08-09 Yao Qi <yao.qi@linaro.org>
6784
6785 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6786 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6787 i386-avx-mpx.o and i386-mmx.o.
6788 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6789 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6790 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6791 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6792 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6793 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6794 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6795 i386/amd64-avx-mpx.xml.
6796
57757c2f
YQ
67972017-08-09 Yao Qi <yao.qi@linaro.org>
6798
6799 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6800 and x32-avx-avx512.o.
6801 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6802 i386/x32-avx-avx512.xml.
6803
229d26fc
SM
68042017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6805
6806 * tracepoint.h (enum class fast_tpoint_collect_result): New
6807 enumeration.
6808 (fast_tracepoint_collecting): Change return type to
6809 fast_tpoint_collect_result.
6810 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6811 * linux-low.h: Include tracepoint.h.
6812 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6813 fast_tpoint_collect_result.
6814 * linux-low.c (handle_tracepoints): Adjust.
6815 (linux_fast_tracepoint_collecting): Change return type to
6816 fast_tpoint_collect_result.
6817 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6818 linux_wait_1, stuck_in_jump_pad_callback,
6819 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6820 proceed_one_lwp): Adjust to type change.
6821
2e1e43e1
YQ
68222017-07-10 Yao Qi <yao.qi@linaro.org>
6823
6824 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6825
adc764e7
YQ
68262017-06-29 Yao Qi <yao.qi@linaro.org>
6827
6828 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6829 Remove.
6830 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6831
a206891a
SM
68322017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6833
6834 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6835
9a6c7d9c
SDJ
68362017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6837
6838 * linux-low.c (linux_create_inferior): Adjust code to access the
6839 environment information via 'gdb_environ' class.
6840 * lynx-low.c (lynx_create_inferior): Likewise.
6841 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6842 (get_environ): Return a pointer to 'our_environ'.
6843 (captured_main): Initialize 'our_environ'.
6844 * server.h (get_environ): Adjust prototype.
6845 * spu-low.c (spu_create_inferior): Adjust code to access the
6846 environment information via 'gdb_environ' class.
6847
ae3e2ccf
SM
68482017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6849
6850 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6851 usage of "register" keyword.
6852
3e019bdc
SM
68532017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6854
6855 * configure: Re-generate.
6856
8465943a
SM
68572017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6858
6859 * configure: Re-generate.
6860
cf0dd6f0
SM
68612017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6862
6863 * Makefile.in (COMPILE.pre): Add "-x c++".
6864
9845682b
SDJ
68652017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6866
6867 * fork-child.c: Conditionally include <signal.h>.
6868
aefd8b33
SDJ
68692017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6870
6871 * server.c (handle_general_set): Handle new packet
6872 "QStartupWithShell".
6873 (handle_query): Add "QStartupWithShell" to the list of supported
6874 packets.
6875 (gdbserver_usage): Add help text explaining the
6876 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6877 options.
6878 (captured_main): Recognize and act upon the presence of the new
6879 CLI options.
6880
2090129c
SDJ
68812017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6882 Pedro Alves <palves@redhat.com>
6883
6884 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6885 * configure: Regenerate.
6886 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6887 "fork-inferior.o".
6888 (i[34567]86-*-lynxos*): Likewise.
6889 (spu*-*-*): Likewise.
6890 * fork-child.c: New file.
6891 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6892 and "environ.h".
6893 (linux_ptrace_fun): New function.
6894 (linux_create_inferior): Adjust function prototype to reflect
6895 change on "target.h". Adjust function code to use
6896 "fork_inferior".
6897 (linux_request_interrupt): Delete "signal_pid".
6898 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6899 (lynx_ptrace_fun): New function.
6900 (lynx_create_inferior): Adjust function prototype to reflect
6901 change on "target.h". Adjust function code to use
6902 "fork_inferior".
6903 * nto-low.c (nto_create_inferior): Adjust function prototype and
6904 code to reflect change on "target.h". Update comments.
6905 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6906 "common-terminal.h" and "environ.h".
6907 (terminal_fd): Moved to fork-child.c.
6908 (old_foreground_pgrp): Likewise.
6909 (restore_old_foreground_pgrp): Likewise.
6910 (last_status): Make it global.
6911 (last_ptid): Likewise.
6912 (our_environ): New variable.
6913 (startup_with_shell): Likewise.
6914 (program_name): Likewise.
6915 (program_argv): Rename to...
6916 (program_args): ...this.
6917 (wrapper_argv): New variable.
6918 (start_inferior): Delete function.
6919 (get_exec_wrapper): New function.
6920 (get_exec_file): Likewise.
6921 (get_environ): Likewise.
6922 (prefork_hook): Likewise.
6923 (post_fork_inferior): Likewise.
6924 (postfork_hook): Likewise.
6925 (postfork_child_hook): Likewise.
6926 (handle_v_run): Update code to deal with arguments coming from the
6927 remote host. Update calls from "start_inferior" to
6928 "create_inferior".
6929 (captured_main): Likewise. Initialize environment variable. Call
6930 "have_job_control".
6931 * server.h (post_fork_inferior): New prototype.
6932 (get_environ): Likewise.
6933 (last_status): Declare.
6934 (last_ptid): Likewise.
6935 (signal_pid): Likewise.
6936 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6937 (spu_ptrace_fun): New function.
6938 (spu_create_inferior): Adjust function prototype to reflect change
6939 on "target.h". Adjust function code to use "fork_inferior".
6940 * target.c (target_terminal_init): New function.
6941 (target_terminal_inferior): Likewise.
6942 (target_terminal_ours): Likewise.
6943 * target.h: Include <vector>.
6944 (struct target_ops) <create_inferior>: Update prototype.
6945 (create_inferior): Update macro.
6946 * utils.c (gdb_flush_out_err): New function.
6947 * win32-low.c (win32_create_inferior): Adjust function prototype
6948 and code to reflect change on "target.h".
6949
043a4934
SDJ
69502017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6951
6952 * inferiors.c (switch_to_thread): New function.
6953
15652511
SDJ
69542017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6955
6956 * Makefile.in (SFILE): Add "common/job-control.c".
6957 (OBS): Add "job-control.o".
6958
21ea5acd
SDJ
69592017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6960
6961 * Makefile: Remove "@host_makefile_frag@".
6962
e13cb306
PA
69632017-05-05 Pedro Alves <palves@redhat.com>
6964
6965 * configure: Regenerate.
6966
c94fee56
SDJ
69672017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6968
6969 * configure: Regenerate.
6970
a0ff9e1a
SM
69712017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6972
6973 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
6974 software_single_step change of return type to
6975 std::vector<CORE_ADDR>.
6976 * linux-low.c (install_software_single_step_breakpoints):
6977 Likewise.
6978 * linux-low.h (install_software_single_step_breakpoints):
6979 Likewise.
6980
be628ab8
SDJ
69812017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6982
6983 * remote-utils.c: Include "gdb_termios.h" instead of
6984 "terminal.h".
6985 * terminal.h: Delete file.
6986
7c5ded6a
SDJ
69872017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6988
6989 * server.c: Include <vector>.
6990 <program_argv, wrapper_argv>: Convert to std::vector.
6991 (start_inferior): Rewrite function to use C++.
6992 (handle_v_run): Likewise. Update code that calculates the argv
6993 based on the vRun packet; use C++.
6994 (captured_main): Likewise.
6995
436252de
SM
69962017-04-06 Simon Marchi <simon.marchi@ericsson.com>
6997
6998 * server.c (handle_v_cont): Initialize thread_resume::thread
6999 with null_ptid.
7000
9bf2a700
PA
70012017-04-05 Pedro Alves <palves@redhat.com>
7002
7003 * configure: Regenerate.
7004
a121b7c1
PA
70052017-04-05 Pedro Alves <palves@redhat.com>
7006
7007 * gdbreplay.c (sync_error): Constify.
7008 * linux-x86-low.c (push_opcode): Constify.
7009
21c8a587
PA
70102017-04-05 Pedro Alves <palves@redhat.com>
7011
7012 * win32-low.c (get_child_debug_event)
7013 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7014 Report TARGET_WAITKIND_SPURIOUS instead.
7015
fb32b4f7
PA
70162017-04-05 Pedro Alves <palves@redhat.com>
7017
e79be6e5
SM
7018 * remote-utils.c (remote_prepare, remote_open): Constify.
7019 * remote-utils.h (remote_prepare, remote_open): Constify.
7020 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 7021
65dd1e59
SM
70222017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7023
7024 * Makefile.in (clean): Clear .deps.
7025
8fa5b777
SM
70262017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7027
7028 * .gitignore: Remove generated files, replace with wildcard.
7029 * (clean): Replace removal of generated files with wildcard.
7030 (version.c): Replace with...
7031 (version-generated.c): ...this.
7032 (xml-builtin.c): Replace with...
7033 (xml-builtin-generated.c): ...this.
7034 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7035 (%.c: *regformats*): Replace with...
7036 (%-generated.c: *regformats*): ...this.
7037
a12e714b
MF
70382017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7039
7040 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7041 (xtensa_fill_gregset): Call collect_register_by_name for
7042 threadptr register.
7043 (xtensa_store_gregset): Call supply_register_by_name for
7044 threadptr register.
7045
1a09b50a
MF
70462017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7047
7048 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7049 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7050 (xtensa_store_gregset): Call supply_register for all registers in
7051 a0_regnum..a0_regnum + C0_NREGS range.
7052
1a01e7c6
SM
70532017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7054
7055 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7056 (ax-ipa.o: ax.c): Remove.
7057 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7058 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7059 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7060 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7061 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7062
36bc18a8
SM
70632017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7064
7065 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7066 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7067 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7068 (errors-ipa.o: ../common/errors.c): Remove.
7069 (format-ipa.o: ../common/format.c): Remove.
7070 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7071
a8ebe3d5
SM
70722017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7073
7074 * Makefile.in (%-ipa.o: %.c): New rule.
7075 (tracepoint-ipa.o: tracepoint.c): Remove.
7076 (utils-ipa.o: utils.c): Remove.
7077 (remote-utils-ipa.o: remote-utils.c): Remove.
7078 (regcache-ipa.o: regcache.c): Remove.
7079 (i386-linux-ipa.o: i386-linux.c): Remove.
7080 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7081 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7082 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7083 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7084 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7085 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7086 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7087 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7088 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7089 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7090 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7091 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7092 (aarch64-ipa.o: aarch64.c): Remove.
7093 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7094 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7095 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7096 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7097 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7098 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7099 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7100 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7101 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7102 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7103 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7104 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7105 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7106 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7107 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7108 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7109 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7110 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7111 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7112 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7113 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7114 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7115 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7116 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7117 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7118 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7119 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7120 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7121 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7122 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7123 (tdesc-ipa.o: tdesc.c): Remove.
7124 (x32-linux-ipa.o: x32-linux.c): Remove.
7125 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7126 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7127
50cfacb7
SM
71282017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7129
7130 * Makefile.in (%.o: ../arch/%.c): New rule.
7131 (arm.o: ../arch/arm.c): Remove.
7132 (arm-linux.o: ../arch/arm-linux.c): Remove.
7133 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7134 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7135
c5a22423
SM
71362017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7137
7138 * Makefile.in (%.o: ../nat/%.c): New rule.
7139 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7140 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7141 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7142 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7143 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7144 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7145 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7146 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7147 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7148 (linux-personality.o: ../nat/linux-personality.c): Remove.
7149 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7150 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7151 (x86-linux.o: ../nat/x86-linux.c): Remove.
7152 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7153 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7154
6bda016b
SM
71552017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7156
7157 * Makefile.in (%.o: ../common/%.c): New rule.
7158 (signals.o: ../common/signals.c): Remove.
7159 (print-utils.o: ../common/print-utils.c): Remove.
7160 (rsp-low.o: ../common/rsp-low.c): Remove.
7161 (common-utils.o: ../common/common-utils.c): Remove.
7162 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7163 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7164 (vec.o: ../common/vec.c): Remove.
7165 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7166 (xml-utils.o: ../common/xml-utils.c): Remove.
7167 (ptid.o: ../common/ptid.c): Remove.
7168 (buffer.o: ../common/buffer.c): Remove.
7169 (format.o: ../common/format.c): Remove.
7170 (filestuff.o: ../common/filestuff.c): Remove.
7171 (agent.o: ../common/agent.c): Remove.
7172 (errors.o: ../common/errors.c): Remove.
7173 (environ.o: ../common/environ.c): Remove.
7174 (common-debug.o: ../common/common-debug.c): Remove.
7175 (cleanups.o: ../common/cleanups.c): Remove.
7176 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7177 (fileio.o: ../common/fileio.c): Remove.
7178 (common-regcache.o: ../common/common-regcache.c): Remove.
7179 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7180 (new-op.o: ../common/new-op.c): Remove.
7181 (btrace-common.o: ../common/btrace-common.c): Remove.
7182
21122961
SM
71832017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7184
7185 * Makefile.in (%.o: ../target/%.c): New rule.
7186 (waitstatus.o: ../target/waitstatus.c): Remove.
7187
c362e621
SM
71882017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7189
7190 * Makefile.in
7191 (%.c: ../regformats/%.dat,
7192 (%.c: ../regformats/arm/%.dat,
7193 (%.c: ../regformats/i386/%.dat,
7194 (%.c: ../regformats/rs6000/%.dat): New rules.
7195 (aarch64.c): Remove.
7196 (reg-arm.c): Remove.
7197 (arm-with-iwmmxt.c): Remove.
7198 (arm-with-vfpv2.c): Remove.
7199 (arm-with-vfpv3.c): Remove.
7200 (arm-with-neon.c): Remove.
7201 (reg-bfin.c): Remove.
7202 (reg-cris.c): Remove.
7203 (reg-crisv32.c): Remove.
7204 (i386.c): Remove.
7205 (i386-linux.c): Remove.
7206 (i386-avx.c): Remove.
7207 (i386-avx-linux.c): Remove.
7208 (i386-avx-avx512.c): Remove.
7209 (i386-avx-avx512-linux.c): Remove.
7210 (i386-mpx.c): Remove.
7211 (i386-mpx-linux.c): Remove.
7212 (i386-avx-mpx-avx512-pku.c): Remove.
7213 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7214 (i386-avx-mpx.c): Remove.
7215 (i386-avx-mpx-linux.c): Remove.
7216 (i386-mmx.c): Remove.
7217 (i386-mmx-linux.c): Remove.
7218 (reg-ia64.c): Remove.
7219 (reg-m32r.c): Remove.
7220 (reg-m68k.c): Remove.
7221 (reg-cf.c): Remove.
7222 (mips-linux.c): Remove.
7223 (mips-dsp-linux.c): Remove.
7224 (mips64-linux.c): Remove.
7225 (mips64-dsp-linux.c): Remove.
7226 (nios2-linux.c): Remove.
7227 (powerpc-32.c): Remove.
7228 (powerpc-32l.c): Remove.
7229 (powerpc-altivec32l.c): Remove.
7230 (powerpc-cell32l.c): Remove.
7231 (powerpc-vsx32l.c): Remove.
7232 (powerpc-isa205-32l.c): Remove.
7233 (powerpc-isa205-altivec32l.c): Remove.
7234 (powerpc-isa205-vsx32l.c): Remove.
7235 (powerpc-e500l.c): Remove.
7236 (powerpc-64l.c): Remove.
7237 (powerpc-altivec64l.c): Remove.
7238 (powerpc-cell64l.c): Remove.
7239 (powerpc-vsx64l.c): Remove.
7240 (powerpc-isa205-64l.c): Remove.
7241 (powerpc-isa205-altivec64l.c): Remove.
7242 (powerpc-isa205-vsx64l.c): Remove.
7243 (s390-linux32.c): Remove.
7244 (s390-linux32v1.c): Remove.
7245 (s390-linux32v2.c): Remove.
7246 (s390-linux64.c): Remove.
7247 (s390-linux64v1.c): Remove.
7248 (s390-linux64v2.c): Remove.
7249 (s390-te-linux64.c): Remove.
7250 (s390-vx-linux64.c): Remove.
7251 (s390-tevx-linux64.c): Remove.
7252 (s390x-linux64.c): Remove.
7253 (s390x-linux64v1.c): Remove.
7254 (s390x-linux64v2.c): Remove.
7255 (s390x-te-linux64.c): Remove.
7256 (s390x-vx-linux64.c): Remove.
7257 (s390x-tevx-linux64.c): Remove.
7258 (tic6x-c64xp-linux.c): Remove.
7259 (tic6x-c64x-linux.c): Remove.
7260 (tic6x-c62x-linux.c): Remove.
7261 (reg-sh.c): Remove.
7262 (reg-sparc64.c): Remove.
7263 (reg-spu.c): Remove.
7264 (amd64.c): Remove.
7265 (amd64-linux.c): Remove.
7266 (amd64-avx.c): Remove.
7267 (amd64-avx-linux.c): Remove.
7268 (amd64-avx-avx512.c): Remove.
7269 (amd64-avx-avx512-linux.c): Remove.
7270 (amd64-mpx.c): Remove.
7271 (amd64-mpx-linux.c): Remove.
7272 (amd64-avx-mpx-avx512-pku.c): Remove.
7273 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7274 (amd64-avx-mpx.c): Remove.
7275 (amd64-avx-mpx-linux.c): Remove.
7276 (x32.c): Remove.
7277 (x32-linux.c): Remove.
7278 (x32-avx.c): Remove.
7279 (x32-avx-linux.c): Remove.
7280 (x32-avx-avx512.c): Remove.
7281 (x32-avx-avx512-linux.c): Remove.
7282 (reg-xtensa.c): Remove.
7283 (reg-tilegx.c): Remove.
7284 (reg-tilegx32.c): Remove.
7285
1672e0d9
SDJ
72862017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7287
7288 * Makefile.in (SFILES): Add "common/environ.c".
7289 (OBJS): Add "common/environ.h".
7290
239b6d10
WT
72912017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7292
7293 * configure.ac: Check if the fs_base and gs_base members of
7294 `struct user_regs_struct' exist.
7295 * config.in: Regenerated.
7296 * configure: Likewise.
7297
694b382c
AT
72982017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7299
7300 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7301 target_read_memory.
7302 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7303 (get_next_pcs_syscall_next_pc): Likewise.
7304
7dc53023
LM
73052016-12-23 Luis Machado <lgustavo@codesourcery.com>
7306
7307 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7308 * nto-x86-low.c: Likewise.
7309
ad02e4fe
SM
73102016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7311
7312 * Makefile.in: Include disable-implicit-rules.mk.
7313
dcb07cfa
PA
73142016-11-23 Pedro Alves <palves@redhat.com>
7315
7316 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7317 (debug_vprintf): Use std::chrono::steady_clock instead of
7318 gettimeofday. Use '.' instead of ':'.
7319 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7320 (get_timestamp): Use std::chrono::steady_clock instead of
7321 gettimeofday.
7322
8629c02c
SM
73232016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7324
7325 * Makefile.in: Fix whitespace formatting.
7326
b593ecca
SM
73272016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7328
7329 * Makefile.in (SFILES, OBS): Flatten list and order
7330 alphabetically.
7331
9986ba08
PA
73322016-11-23 Pedro Alves <palves@redhat.com>
7333
7334 * event-loop.c (handle_file_event): Use warning.
7335 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7336 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7337 Use warning.
7338
4eefa7bc
PA
73392016-11-23 Pedro Alves <palves@redhat.com>
7340
7341 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7342 output.
7343 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7344 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7345 debug_printf and debug_flush for debug output.
7346 * server.c (handle_general_set): Likewise.
7347 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7348 output.
7349
5443506e
SM
73502016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7351
7352 * Makefile.in (.c.o): Replace rule with ...
7353 (%.o: %.c): ... this one.
7354
3b165252
SM
73552016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7356
7357 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7358 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7359 make.
7360 * configure.ac: Remove checks for the make program.
7361 * configure: Re-generate.
7362
0bcda685
PA
73632016-10-28 Pedro Alves <palves@redhat.com>
7364
7365 * Makefile.in (CXX_DIALECT): Get from configure.
7366 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7367 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7368 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7369 * config.in: Regenerate.
7370 * configure: Regenerate.
7371
c3805894
YQ
73722016-10-27 Yao Qi <yao.qi@linaro.org>
7373
7374 * linux-low.c (linux_supports_range_stepping): Return true if
7375 can_software_single_step return true.
7376
89342618
YQ
73772016-10-27 Yao Qi <yao.qi@linaro.org>
7378
7379 * inferiors.c (find_inferior_in_random): New function.
7380 * inferiors.h (find_inferior_in_random): Declare.
7381 * linux-low.c (linux_wait_for_event_filtered): Call
7382 find_inferior_in_random instead of find_inferior.
7383
e3652c84
YQ
73842016-10-27 Yao Qi <yao.qi@linaro.org>
7385
7386 * linux-low.c (linux_wait_1): If single-step breakpoints are
7387 inserted, remove them.
7388
5a04c4cf
PA
73892016-10-26 Pedro Alves <palves@redhat.com>
7390
7391 * linux-low.c (handle_extended_wait): Link parent/child fork
7392 threads.
7393 (linux_wait_1): Unlink them.
7394 (linux_set_resume_request): Ignore resume requests for
7395 already-resumed and unhandled fork child threads.
7396 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7397 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7398 New functions.
7399 (handle_v_requests) <vCont>: Don't call require_running.
7400 * server.h (in_queued_stop_replies): New declaration.
7401
cb93dc7f
YQ
74022016-10-24 Yao Qi <yao.qi@linaro.org>
7403
7404 PR server/20733
7405 * linux-aarch64-low.c (append_insns): Cast the return value to
7406 'uint32_t *'.
7407
a1078bea
YQ
74082016-10-10 Yao Qi <yao.qi@linaro.org>
7409
7410 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7411
1fb77080
SDJ
74122016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7413
7414 * target.c (target_supports_multi_process): New function, moved
7415 from...
7416 * target.h (target_supports_multi_process): ... here. Remove
7417 macro.
7418
39b5a3b9
TT
74192016-10-05 Tom Tromey <tom@tromey.com>
7420
7421 PR remote/20655:
7422 * tracepoint.c (handle_tracepoint_bkpts): Check
7423 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7424
c1d0b70a
YQ
74252016-10-05 Yao Qi <yao.qi@linaro.org>
7426
7427 * configure.srv: Update the path of arm-*.xml files.
7428
0a69eedb
YQ
74292016-10-05 Terry Guo <terry.guo@arm.com>
7430 Yao Qi <yao.qi@linaro.org>
7431
7432 * Makefile.in: Adjust the path of rules.
7433 * configure.srv: Update the path of xml files.
7434 * regformats/arm-with-iwmmxt.dat: Regenerated.
7435 * regformats/arm-with-neon.dat: Likewise.
7436 * regformats/arm-with-vfpv2.dat: Likewise.
7437 * regformats/arm-with-vfpv3.dat Likewise.
7438
17e16485
YQ
74392016-09-30 Yao Qi <yao.qi@linaro.org>
7440
7441 PR gdbserver/20627
7442 * target.c (target_stop_and_wait): Don't call
7443 target_continue_no_signal, use resume_stop instead.
7444
edeeb602
YQ
74452016-09-26 Yao Qi <yao.qi@linaro.org>
7446
7447 * linux-low.c (linux_wait_1): Call debug_exit.
7448
503b1c39
PA
74492016-09-23 Pedro Alves <palves@redhat.com>
7450
7451 * Makefile.in (SFILES): Add common/new-op.c.
7452 (OBS): Add common/new-op.o.
7453 (new-op.o): New rule.
7454
74172ecf
SM
74552016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7456
7457 * .gitinore: Ignore more files.
7458
fc6cda2e
YQ
74592016-09-21 Yao Qi <yao.qi@linaro.org>
7460
7461 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7462 23.
7463
bc1e6c81
SDJ
74642016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7465
7466 * server.c (start_inferior): Call target_mourn_inferior instead of
7467 mourn_inferior; pass ptid_t argument to it.
7468 (resume): Likewise.
7469 (handle_target_event): Likewise.
7470 * target.c (target_mourn_inferior): New function.
7471 * target.h (mourn_inferior): Delete macro.
7472
0e00e962
AA
74732016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7474
7475 * linux-low.c (lwp_is_stepping): New function.
7476
1d8cb77d
CL
74772016-09-06 Carl Love <cel@us.ibm.com>
7478
7479 * server.c (start_inferior): Fixed comment, requested comment change
7480 didn't get updated correctly. Removed reference to ptrace () call as
7481 it is only true on Linux systems.
7482
7313bced
CL
74832016-09-06 Carl Love <cel@us.ibm.com>
7484
7485 * server.c (start_inferior): Do not call
7486 function target_post_create_inferior () if the
7487 inferior process has already exited.
7488
cf6de44d
PA
74892016-09-05 Pedro Alves <palves@redhat.com>
7490
7491 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7492 (COMPILE.pre, CC_LD): Use CXX directly.
7493 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7494 * acinclude.m4: Don't include build-with-cxx.m4.
7495 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7496 * configure: Regenerate.
7497
c1da6748
AT
74982016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7499
7500 PR gdb/19495
7501 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7502 call writing data to own_buf.
7503
f2b9e3df
SDJ
75042016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7505
7506 * target.c (mywait): Call target_wait instead of
7507 the_target->wait.
7508 (target_wait): New function.
7509
049a8570
SDJ
75102016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7511
7512 * server.c (start_inferior): New variable 'ptid'. Replace calls
7513 to the_target->resume by target_continue{,_no_signal}, depending
7514 on the case.
7515 * target.c (target_stop_and_wait): Call target_continue_no_signal
7516 instead of the_target->resume.
7517 (target_continue): New function.
7518
3aa5cfa0
AT
75192016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7520
7521 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7522
754653a7
AZ
75232016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7524
7525 PR server/20491
7526 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7527 ps_prochandle.
7528 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7529 * linux-arm-low.c (ps_get_thread_area): Likewise.
7530 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7531 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7532 * linux-mips-low.c (ps_get_thread_area): Likewise.
7533 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7534 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7535 * linux-x86-low.c (ps_get_thread_area): Likewise.
7536 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7537
ed036b40
PA
75382016-08-19 Pedro Alves <palves@redhat.com>
7539
7540 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7541
c8ef42ee
PA
75422016-08-19 Pedro Alves <palves@redhat.com>
7543
7544 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7545 comment. Use memcpy instead of casting through unsigned long.
7546
9c235a72
PA
75472016-08-19 Pedro Alves <palves@redhat.com>
7548
7549 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7550 allocating around 0x80000000.
7551
201506da
PA
75522016-08-19 Pedro Alves <palves@redhat.com>
7553
7554 PR gdb/20415
7555 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7556 (x32-avx512-linux-ipa.o): New rules.
7557 * configure.ac (x86_64-*-linux*): New x32 check.
7558 * configure.srv (ipa_x32_linux_regobj): New.
7559 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7560 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7561 descriptions.
7562 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7563 descriptions.
7564 * configure: Regenerate.
7565
f348d89a
PA
75662016-08-09 Pedro Alves <palves@redhat.com>
7567
7568 PR gdb/18653
7569 * Makefile.in (OBS): Add signals-state-save-restore.o.
7570 (signals-state-save-restore.o): New rule.
7571 * config.in: Regenerate.
7572 * configure: Regenerate.
7573 * linux-low.c: Include "signals-state-save-restore.h".
7574 (linux_create_inferior): Call
7575 restore_original_signals_state.
7576 * server.c: Include "dispositions-save-restore.h".
7577 (captured_main): Call save_original_signals_state.
7578
1baf5149
PA
75792016-08-05 Pedro Alves <palves@redhat.com>
7580
7581 * configure: Regenerate.
7582
fcd4a73d
YQ
75832016-08-04 Yao Qi <yao.qi@linaro.org>
7584
7585 * linux-low.c (regsets_fetch_inferior_registers): Check
7586 errno is ESRCH or not.
7587
979659d0
YQ
75882016-08-02 Yao Qi <yao.qi@linaro.org>
7589
7590 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7591 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7592 (thread_db_load_search): Update.
7593 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7594 td_ta_set_event and td_ta_event_getmsg.
7595
6598661d
PA
75962016-07-26 Pedro Alves <palves@redhat.com>
7597
7598 PR server/20414
7599 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7600 of unsigned long for 64-bit registers and use uint32_t instead of
7601 unsigned int for 32-bit registers.
7602
9cf12d57
PA
76032016-07-26 Pedro Alves <palves@redhat.com>
7604
7605 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7606 to 'ptrace'.
7607
305450ed
TT
76082016-07-21 Tom Tromey <tom@tromey.com>
7609
7610 * configure: Rebuild.
7611
2583da7c
YQ
76122016-07-21 Yao Qi <yao.qi@linaro.org>
7613
7614 * mem-break.c (find_gdb_breakpoint): Cast bp to
7615 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7616
21536b36
YQ
76172016-07-21 Yao Qi <yao.qi@linaro.org>
7618
7619 * server.c (handle_v_requests): Support s and S actions
7620 if target_supports_software_single_step return true.
7621
8901d193
YQ
76222016-07-21 Yao Qi <yao.qi@linaro.org>
7623
7624 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7625 is resume_step, call maybe_hw_step.
7626 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7627 and unstop them.
7628 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7629 breakpoints or not.
7630 (proceed_one_lwp): If resume request is resume_step, install
7631 reinsert breakpoints and call maybe_hw_step.
7632
0e9a339e
YQ
76332016-07-21 Yao Qi <yao.qi@linaro.org>
7634
7635 * linux-low.c (proceed_one_lwp): Declare.
7636 (linux_resume_one_thread): Remove local variable 'step'.
7637 Lift code enqueue signal. Call proceed_one_lwp instead of
7638 linux_resume_one_lwp.
7639
4281b351
YQ
76402016-07-21 Yao Qi <yao.qi@linaro.org>
7641
7642 * linux-low.c (linux_resume_one_thread): Call
7643 enqueue_pending_signal.
7644
984a2c04
YQ
76452016-07-21 Yao Qi <yao.qi@linaro.org>
7646
7647 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7648 * inferiors.c (do_restore_current_thread_cleanup): New function.
7649 (make_cleanup_restore_current_thread): Likewise.
7650 * linux-low.c (install_software_single_step_breakpoints): Call
7651 make_cleanup_restore_current_thread. Switch current_thread to
7652 thread.
7653
bec903c9
YQ
76542016-07-21 Yao Qi <yao.qi@linaro.org>
7655
7656 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7657 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7658 (clone_one_breakpoint): Likewise.
7659 (delete_reinsert_breakpoints): Change parameter to thread.
7660 Callers updated.
7661 (has_reinsert_breakpoints): Likewise.
7662 (uninsert_reinsert_breakpoints): Likewise.
7663 (reinsert_reinsert_breakpoints): Likewise.
7664 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7665 (delete_reinsert_breakpoints): Likewise.
7666 (reinsert_reinsert_breakpoints): Likewise.
7667 (uninsert_reinsert_breakpoints): Likewise.
7668 (has_reinsert_breakpoints): Likewise.
7669
63c40ec7
YQ
76702016-07-21 Yao Qi <yao.qi@linaro.org>
7671
7672 * inferiors.c (get_thread_process): Make parameter const.
7673 * inferiors.h (get_thread_process): Update declaration.
7674 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7675 Add new parameters child_thread and parent_thread. Callers
7676 updated.
7677 * mem-break.h (clone_all_breakpoints): Update declaration.
7678
9aa76cd0
YQ
76792016-07-21 Yao Qi <yao.qi@linaro.org>
7680
7681 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7682 <command_list, handler>: Remove.
7683 (struct gdb_breakpoint): New.
7684 (struct other_breakpoint): New.
7685 (struct reinsert_breakpoint): New.
7686 (is_gdb_breakpoint): New function.
7687 (any_persistent_commands): Update command_list if
7688 is_gdb_breakpoint returns true.
7689 (set_breakpoint): Create breakpoints according to their types.
7690 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7691 (set_gdb_breakpoint_1): Likewise.
7692 (set_gdb_breakpoint): Likewise.
7693 (clear_breakpoint_conditions): Change parameter type to
7694 'struct gdb_breakpoint *'.
7695 (clear_breakpoint_commands): Likewise.
7696 (clear_breakpoint_conditions_and_commands): Likewise.
7697 (add_condition_to_breakpoint): Likewise.
7698 (add_breakpoint_condition): Likewise.
7699 (add_commands_to_breakpoint): Likewise.
7700 (check_breakpoints): Check other_breakpoint.
7701 (clone_one_breakpoint): Clone breakpopint according to its type.
7702 * mem-break.h (struct gdb_breakpoint): Declare.
7703 (set_gdb_breakpoint): Update declaration.
7704 (clear_breakpoint_conditions_and_commands): Likewise.
7705 (add_breakpoint_condition): Likewise.
7706 (add_breakpoint_commands): Likewise.
7707 * server.c (process_point_options): Change parameter type to
7708 'struct gdb_breakpoint *'.
7709
811f8301
YQ
77102016-07-21 Yao Qi <yao.qi@linaro.org>
7711
7712 * mem-break.c (set_breakpoint_at): Rename it to ...
7713 (set_breakpoint_type_at): ... it.
7714 (set_breakpoint_at): Call set_breakpoint_type_at.
7715 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7716 * mem-break.h (set_breakpoint_at): Update comments.
7717
b1c51e36
CLT
77182016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7719
7720 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7721 to buf parameter.
7722 (nios2_store_gregset): Likewise.
7723
ced2dffb
PA
77242016-07-01 Pedro Alves <palves@redhat.com>
7725 Antoine Tremblay <antoine.tremblay@ericsson.com>
7726
7727 * linux-low.c: Change interface to take the target lwp_info
7728 pointer directly and return void. Handle detaching from a zombie
7729 thread.
7730 (linux_detach_lwp_callback): New function.
7731 (linux_detach): Detach from the leader thread after detaching from
7732 the clone threads.
7733
2ac09a5b
YQ
77342016-06-28 Yao Qi <yao.qi@linaro.org>
7735
7736 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7737 for variable new_offset.
7738 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7739 (aarch64_ftrace_insn_reloc_cb): Likewise.
7740 (aarch64_ftrace_insn_reloc_tb): Likewise.
7741 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7742 PRIx64 instead of PRIx32.
7743
79e7fd4f
YQ
77442016-06-28 Yao Qi <yao.qi@linaro.org>
7745
7746 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7747 (the_low_target): Install arm_get_syscall_trapinfo.
7748
061fc021
YQ
77492016-06-28 Yao Qi <yao.qi@linaro.org>
7750
7751 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7752 function.
7753 (the_low_target): Install aarch64_get_syscall_trapinfo.
7754
4cc32bec
YQ
77552016-06-28 Yao Qi <yao.qi@linaro.org>
7756
7757 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7758 Callers updated.
7759 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7760 Remove parameter sysno.
7761 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7762 sysret.
7763
782c1122
AA
77642016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7765
7766 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7767 (s390_emit_ne_goto): Likewise.
7768 (s390_emit_lt_goto): Likewise.
7769 (s390_emit_le_goto): Likewise.
7770 (s390_emit_gt_goto): Likewise.
7771 (s390_emit_ge_goto): Likewise.
7772 (s390x_emit_eq_goto): Likewise.
7773 (s390x_emit_ne_goto): Likewise.
7774 (s390x_emit_lt_goto): Likewise.
7775 (s390x_emit_le_goto): Likewise.
7776 (s390x_emit_gt_goto): Likewise.
7777 (s390x_emit_ge_goto): Likewise.
7778 (s390_emit_ops_impl): Mark variable static.
7779 (s390x_emit_ops): Likewise.
7780
2e7b624b
YQ
77812016-06-17 Yao Qi <yao.qi@linaro.org>
7782
7783 * linux-low.c (handle_extended_wait): Call
7784 uninsert_reinsert_breakpoints for the parent process. Remove
7785 reinsert breakpoints from the child process. Reinsert them to
7786 the parent process when vfork is done.
7787 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7788 (reinsert_reinsert_breakpoints): New function.
7789 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7790 (reinsert_reinsert_breakpoints): Declare.
7791
8a81c5d7
YQ
77922016-06-17 Yao Qi <yao.qi@linaro.org>
7793
7794 * linux-low.c (handle_extended_wait): If the parent is doing
7795 step-over, remove the reinsert breakpoints from the forked child.
7796
f50bf8e5
YQ
77972016-06-17 Yao Qi <yao.qi@linaro.org>
7798
7799 * linux-low.c (unsuspend_all_lwps): Declare.
7800 (linux_low_filter_event): If thread exited, call finish_step_over.
7801 If step-over is finished, unsuspend other threads.
7802
8376a3cb
YQ
78032016-06-17 Yao Qi <yao.qi@linaro.org>
7804
7805 * linux-low.c (linux_resume_one_lwp_throw): Assert
7806 has_reinsert_breakpoints returns false.
7807 * mem-break.c (delete_disabled_breakpoints): Assert
7808 bp type isn't reinsert_breakpoint.
7809
f79b145d
YQ
78102016-06-17 Yao Qi <yao.qi@linaro.org>
7811
7812 * linux-low.c (maybe_hw_step): New function.
7813 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7814 (finish_step_over): Switch current_thread to lwp temporarily,
7815 and assert has_reinsert_breakpoints returns true.
7816 (proceed_one_lwp): Call maybe_hw_step.
7817 * mem-break.c (has_reinsert_breakpoints): New function.
7818 * mem-break.h (has_reinsert_breakpoints): Declare.
7819
0ae534d2
JT
78202016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7821
7822 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7823
fcdad592
YQ
78242016-05-17 Yao Qi <yao.qi@linaro.org>
7825
7826 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7827 instead of find_inferior.
7828
9e784964
YQ
78292016-05-05 Yao Qi <yao.qi@linaro.org>
7830
7831 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7832 Initialize res to zero.
7833
cf2ebb6e
YQ
78342016-05-05 Yao Qi <yao.qi@linaro.org>
7835
7836 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7837 to uint32_t.
7838
c1aebf87
UW
78392016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7840
7841 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7842 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7843 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7844
35fd2deb 78452016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 7846 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
7847
7848 * tracepoint.c (write_inferior_int8): New function.
7849 (cmd_qtenable_disable): Write enable flag using
7850 write_inferior_int8.
7851
484b3c32
YQ
78522016-04-25 Yao Qi <yao.qi@linaro.org>
7853
7854 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7855 (need_step_over_p): Return zero if the LWP has pending signals
7856 can be delivered on software single step target.
7857
85ba7d86
YQ
78582016-04-25 Yao Qi <yao.qi@linaro.org>
7859
7860 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7861 return instead of error.
7862
3539aa13
YQ
78632016-04-22 Yao Qi <yao.qi@linaro.org>
7864
7865 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7866 to 23.
7867
5b061e98
YQ
78682016-04-22 Yao Qi <yao.qi@linaro.org>
7869
7870 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7871 signal when stepping over breakpoint with software single
7872 step.
7873
3451269c
PA
78742016-04-21 Pedro Alves <palves@redhat.com>
7875
7876 * linux-s390-low.c (s390_collect_ptrace_register)
7877 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7878 add casts.
7879 (s390_check_regset): Use void * instead of gdb_byte *.
7880
a2358508
PA
78812016-04-20 Pedro Alves <palves@redhat.com>
7882
7883 * configure: Renegerate.
7884
6885166d
YQ
78852016-04-20 Yao Qi <yao.qi@linaro.org>
7886
7887 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7888 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7889 number 16.
7890 (arm_store_gregset): Likewise.
7891
2b863f51
WT
78922016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7893
7894 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7895 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7896 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7897 (amd64-avx-mpx-linux.c): New rules.
7898 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7899 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7900 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7901 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7902 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7903 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7904 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7905 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7906 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7907 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7908 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7909 * linux-x86-low.c (x86_linux_read_description): Add case for
7910 X86_XSTATE_AVX_MPX_MASK.
7911 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7912 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7913 init_registers_i386_avx_mpx_linux.
7914 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7915 (initialize_low_tracepoint): Call
7916 init_registers_i386_avx_mpx_linux.
7917 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7918 (initialize_low_tracepoint): Call
7919 init_registers_amd64_avx_mpx_linux.
7920 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7921 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7922 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
7923 declarations.
7924
9b30624b
PA
79252016-04-18 Pedro Alves <palves@redhat.com>
7926
7927 * configure: Regenerate.
7928
45e3745e
AT
79292016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
7930
7931 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
7932 (aarch64_emit_sub): Likewise.
7933
2afc13ff
PA
79342016-04-12 Pedro Alves <palves@redhat.com>
7935
7936 * utils.c (prepare_to_throw_exception): Delete.
7937
6e774b13
SM
79382016-04-05 Simon Marchi <simon.marchi@ericsson.com>
7939
7940 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
7941
4dca19f8
MK
79422016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
7943
7944 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
7945
d0a9981f
MK
79462016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
7947
7948 * linux-aarch64-ipa.c: Add <elf.h> include.
7949 * linux-ppc-ipa.c: Add <elf.h> include.
7950 * linux-s390-ipa.c: Add <elf.h> include.
7951
252db07e
MK
79522016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
7953
7954 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
7955 (get_raw_reg_ptr): Likewise.
7956 (get_trace_state_variable_value_ptr): Likewise.
7957 (set_trace_state_variable_value_ptr): Likewise.
7958 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
7959 char *.
7960
14e2b6d9
MK
79612016-03-31 Wei-cheng Wang <cole945@gmail.com>
7962 Marcin Kościelnicki <koriakin@0x04.net>
7963
7964 PR/17221
7965 * linux-ppc-low.c (emit_insns): New function.
7966 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
7967 (ppc_emit_prologue): New function.
7968 (ppc_emit_epilogue): New function.
7969 (ppc_emit_add): New function.
7970 (ppc_emit_sub): New function.
7971 (ppc_emit_mul): New function.
7972 (ppc_emit_lsh): New function.
7973 (ppc_emit_rsh_signed): New function.
7974 (ppc_emit_rsh_unsigned): New function.
7975 (ppc_emit_ext): New function.
7976 (ppc_emit_zero_ext): New function.
7977 (ppc_emit_log_not): New function.
7978 (ppc_emit_bit_and): New function.
7979 (ppc_emit_bit_or): New function.
7980 (ppc_emit_bit_xor): New function.
7981 (ppc_emit_bit_not): New function.
7982 (ppc_emit_equal): New function.
7983 (ppc_emit_less_signed): New function.
7984 (ppc_emit_less_unsigned): New function.
7985 (ppc_emit_ref): New function.
7986 (ppc_emit_const): New function.
7987 (ppc_emit_reg): New function.
7988 (ppc_emit_pop): New function.
7989 (ppc_emit_stack_flush): New function.
7990 (ppc_emit_swap): New function.
7991 (ppc_emit_stack_adjust): New function.
7992 (ppc_emit_call): New function.
7993 (ppc_emit_int_call_1): New function.
7994 (ppc_emit_void_call_2): New function.
7995 (ppc_emit_if_goto): New function.
7996 (ppc_emit_goto): New function.
7997 (ppc_emit_eq_goto): New function.
7998 (ppc_emit_ne_goto): New function.
7999 (ppc_emit_lt_goto): New function.
8000 (ppc_emit_le_goto): New function.
8001 (ppc_emit_gt_goto): New function.
8002 (ppc_emit_ge_goto): New function.
8003 (ppc_write_goto_address): New function.
8004 (ppc_emit_ops_impl): New static variable.
8005 (ppc64v1_emit_prologue): New function.
8006 (ppc64v2_emit_prologue): New function.
8007 (ppc64_emit_epilogue): New function.
8008 (ppc64_emit_add): New function.
8009 (ppc64_emit_sub): New function.
8010 (ppc64_emit_mul): New function.
8011 (ppc64_emit_lsh): New function.
8012 (ppc64_emit_rsh_signed): New function.
8013 (ppc64_emit_rsh_unsigned): New function.
8014 (ppc64_emit_ext): New function.
8015 (ppc64_emit_zero_ext): New function.
8016 (ppc64_emit_log_not): New function.
8017 (ppc64_emit_bit_and): New function.
8018 (ppc64_emit_bit_or): New function.
8019 (ppc64_emit_bit_xor): New function.
8020 (ppc64_emit_bit_not): New function.
8021 (ppc64_emit_equal): New function.
8022 (ppc64_emit_less_signed): New function.
8023 (ppc64_emit_less_unsigned): New function.
8024 (ppc64_emit_ref): New function.
8025 (ppc64_emit_const): New function.
8026 (ppc64v1_emit_reg): New function.
8027 (ppc64v2_emit_reg): New function.
8028 (ppc64_emit_pop): New function.
8029 (ppc64_emit_stack_flush): New function.
8030 (ppc64_emit_swap): New function.
8031 (ppc64v1_emit_call): New function.
8032 (ppc64v2_emit_call): New function.
8033 (ppc64v1_emit_int_call_1): New function.
8034 (ppc64v2_emit_int_call_1): New function.
8035 (ppc64v1_emit_void_call_2): New function.
8036 (ppc64v2_emit_void_call_2): New function.
8037 (ppc64_emit_if_goto): New function.
8038 (ppc64_emit_eq_goto): New function.
8039 (ppc64_emit_ne_goto): New function.
8040 (ppc64_emit_lt_goto): New function.
8041 (ppc64_emit_le_goto): New function.
8042 (ppc64_emit_gt_goto): New function.
8043 (ppc64_emit_ge_goto): New function.
8044 (ppc64v1_emit_ops_impl): New static variable.
8045 (ppc64v2_emit_ops_impl): New static variable.
8046 (ppc_emit_ops): New function.
8047 (linux_low_target): Wire in ppc_emit_ops.
8048
a2174ba4
MK
80492016-03-31 Wei-cheng Wang <cole945@gmail.com>
8050 Marcin Kościelnicki <koriakin@0x04.net>
8051
8052 PR/17221
8053 * Makefile.in: Add powerpc-*-ipa.o
8054 * configure.srv: Add ipa_obj for powerpc*-linux.
8055 * linux-ppc-ipa.c: New file.
8056 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8057 includes.
8058 (PPC_FIELD): New macro.
8059 (PPC_SEXT): New macro.
8060 (PPC_OP6): New macro.
8061 (PPC_BO): New macro.
8062 (PPC_LI): New macro.
8063 (PPC_BD): New macro.
8064 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8065 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8066 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8067 (ppc_get_thread_area): New function.
8068 (is_elfv2_inferior): New function.
8069 (gen_ds_form): New function.
8070 (GEN_STD): New macro.
8071 (GEN_STDU): New macro.
8072 (GEN_LD): New macro.
8073 (GEN_LDU): New macro.
8074 (gen_d_form): New function.
8075 (GEN_ADDI): New macro.
8076 (GEN_ADDIS): New macro.
8077 (GEN_LI): New macro.
8078 (GEN_LIS): New macro.
8079 (GEN_ORI): New macro.
8080 (GEN_ORIS): New macro.
8081 (GEN_LWZ): New macro.
8082 (GEN_STW): New macro.
8083 (GEN_STWU): New macro.
8084 (gen_xfx_form): New function.
8085 (GEN_MFSPR): New macro.
8086 (GEN_MTSPR): New macro.
8087 (GEN_MFCR): New macro.
8088 (GEN_MTCR): New macro.
8089 (GEN_SYNC): New macro.
8090 (GEN_LWSYNC): New macro.
8091 (gen_x_form): New function.
8092 (GEN_OR): New macro.
8093 (GEN_MR): New macro.
8094 (GEN_LWARX): New macro.
8095 (GEN_STWCX): New macro.
8096 (GEN_CMPW): New macro.
8097 (gen_md_form): New function.
8098 (GEN_RLDICL): New macro.
8099 (GEN_RLDICR): New macro.
8100 (gen_i_form): New function.
8101 (GEN_B): New macro.
8102 (GEN_BL): New macro.
8103 (gen_b_form): New function.
8104 (GEN_BNE): New macro.
8105 (GEN_LOAD): New macro.
8106 (GEN_STORE): New macro.
8107 (gen_limm): New function.
8108 (gen_atomic_xchg): New function.
8109 (gen_call): New function.
8110 (ppc_relocate_instruction): New function.
8111 (ppc_install_fast_tracepoint_jump_pad): New function.
8112 (ppc_get_min_fast_tracepoint_insn_len): New function.
8113 (ppc_get_ipa_tdesc_idx): New function.
8114 (the_low_target): Wire in the new functions.
8115 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8116 tdescs.
8117 * linux-ppc-tdesc.h: New file.
8118
a13c4696
MK
81192016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8120
8121 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8122 (alloc_jump_pad_buffer): New function.
8123 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8124 (alloc_jump_pad_buffer): New function.
8125 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8126 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8127 (alloc_jump_pad_buffer): New function.
8128 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8129 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8130 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8131 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8132
1cda1512
MK
81332016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8134
8135 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8136 * linux-amd64-ipa.c: Likewise.
8137 * linux-i386-ipa.c: Likewise.
8138 * linux-s390-ipa.c: Likewise.
8139 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8140 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8141 set_trace_state_variable_value_ptr.
8142 (struct ipa_sym_addresses): Likewise.
8143 (symbol_list): Likewise.
8144 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8145 accessing gdb_collect directly.
8146 (gdb_collect_ptr_type): New typedef.
8147 (get_raw_reg_ptr_type): New typedef.
8148 (get_trace_state_variable_value_ptr_type): New typedef.
8149 (set_trace_state_variable_value_ptr_type): New typedef.
8150 (gdb_collect_ptr): New global.
8151 (get_raw_reg_ptr): New global.
8152 (get_trace_state_variable_value_ptr): New global.
8153 (set_trace_state_variable_value_ptr): New global.
8154 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8155 accessing get_raw_reg directly.
8156 (get_get_tsv_func_addr): Likewise for
8157 get_trace_state_variable_value_ptr.
8158 (get_set_tsv_func_addr): Likewise for
8159 set_trace_state_variable_value_ptr.
8160 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8161
72fb5488
SM
81622016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8163
8164 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8165
28170b88
MK
81662016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8167
8168 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8169 packets.
8170 (relocate_instruction): Remove own_buf.
8171 * server.c (own_buf): Make global.
8172 (handle_v_requests): Make global.
8173 * server.h (own_buf): New declaration.
8174 (handle_v_requests): New prototype.
8175
f39e8743
MK
81762016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8177
8178 PR 18377
8179 * linux-s390-low.c (add_insns): New function.
8180 (s390_emit_prologue): New function.
8181 (s390_emit_epilogue): New function.
8182 (s390_emit_add): New function.
8183 (s390_emit_sub): New function.
8184 (s390_emit_mul): New function.
8185 (s390_emit_lsh): New function.
8186 (s390_emit_rsh_signed): New function.
8187 (s390_emit_rsh_unsigned): New function.
8188 (s390_emit_ext): New function.
8189 (s390_emit_log_not): New function.
8190 (s390_emit_bit_and): New function.
8191 (s390_emit_bit_or): New function.
8192 (s390_emit_bit_xor): New function.
8193 (s390_emit_bit_not): New function.
8194 (s390_emit_equal): New function.
8195 (s390_emit_less_signed): New function.
8196 (s390_emit_less_unsigned): New function.
8197 (s390_emit_ref): New function.
8198 (s390_emit_if_goto): New function.
8199 (s390_emit_goto): New function.
8200 (s390_write_goto_address): New function.
8201 (s390_emit_litpool): New function.
8202 (s390_emit_const): New function.
8203 (s390_emit_call): New function.
8204 (s390_emit_reg): New function.
8205 (s390_emit_pop): New function.
8206 (s390_emit_stack_flush): New function.
8207 (s390_emit_zero_ext): New function.
8208 (s390_emit_swap): New function.
8209 (s390_emit_stack_adjust): New function.
8210 (s390_emit_set_r2): New function.
8211 (s390_emit_int_call_1): New function.
8212 (s390_emit_void_call_2): New function.
8213 (s390_emit_eq_goto): New function.
8214 (s390_emit_ne_goto): New function.
8215 (s390_emit_lt_goto): New function.
8216 (s390_emit_le_goto): New function.
8217 (s390_emit_gt_goto): New function.
8218 (s390_emit_ge_goto): New function.
8219 (s390x_emit_prologue): New function.
8220 (s390x_emit_epilogue): New function.
8221 (s390x_emit_add): New function.
8222 (s390x_emit_sub): New function.
8223 (s390x_emit_mul): New function.
8224 (s390x_emit_lsh): New function.
8225 (s390x_emit_rsh_signed): New function.
8226 (s390x_emit_rsh_unsigned): New function.
8227 (s390x_emit_ext): New function.
8228 (s390x_emit_log_not): New function.
8229 (s390x_emit_bit_and): New function.
8230 (s390x_emit_bit_or): New function.
8231 (s390x_emit_bit_xor): New function.
8232 (s390x_emit_bit_not): New function.
8233 (s390x_emit_equal): New function.
8234 (s390x_emit_less_signed): New function.
8235 (s390x_emit_less_unsigned): New function.
8236 (s390x_emit_ref): New function.
8237 (s390x_emit_if_goto): New function.
8238 (s390x_emit_const): New function.
8239 (s390x_emit_call): New function.
8240 (s390x_emit_reg): New function.
8241 (s390x_emit_pop): New function.
8242 (s390x_emit_stack_flush): New function.
8243 (s390x_emit_zero_ext): New function.
8244 (s390x_emit_swap): New function.
8245 (s390x_emit_stack_adjust): New function.
8246 (s390x_emit_int_call_1): New function.
8247 (s390x_emit_void_call_2): New function.
8248 (s390x_emit_eq_goto): New function.
8249 (s390x_emit_ne_goto): New function.
8250 (s390x_emit_lt_goto): New function.
8251 (s390x_emit_le_goto): New function.
8252 (s390x_emit_gt_goto): New function.
8253 (s390x_emit_ge_goto): New function.
8254 (s390_emit_ops): New function.
8255 (struct linux_target_ops): Fill in emit_ops hook.
8256
abd9baf9
MK
82572016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8258
8259 PR 18377
8260 * Makefile.in: Add s390 IPA files.
8261 * configure.srv: Build IPA for s390.
8262 * linux-s390-ipa.c: New file.
8263 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8264 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8265 (tdesc_s390_linux32): Likewise.
8266 (init_registers_s390_linux32v1): Likewise.
8267 (tdesc_s390_linux32v1): Likewise.
8268 (init_registers_s390_linux32v2): Likewise.
8269 (tdesc_s390_linux32v2): Likewise.
8270 (init_registers_s390_linux64): Likewise.
8271 (tdesc_s390_linux64): Likewise.
8272 (init_registers_s390_linux64v1): Likewise.
8273 (tdesc_s390_linux64v1): Likewise.
8274 (init_registers_s390_linux64v2): Likewise.
8275 (tdesc_s390_linux64v2): Likewise.
8276 (init_registers_s390_te_linux64): Likewise.
8277 (tdesc_s390_te_linux64): Likewise.
8278 (init_registers_s390_vx_linux64): Likewise.
8279 (tdesc_s390_vx_linux64): Likewise.
8280 (init_registers_s390_tevx_linux64): Likewise.
8281 (tdesc_s390_tevx_linux64): Likewise.
8282 (init_registers_s390x_linux64): Likewise.
8283 (tdesc_s390x_linux64): Likewise.
8284 (init_registers_s390x_linux64v1): Likewise.
8285 (tdesc_s390x_linux64v1): Likewise.
8286 (init_registers_s390x_linux64v2): Likewise.
8287 (tdesc_s390x_linux64v2): Likewise.
8288 (init_registers_s390x_te_linux64): Likewise.
8289 (tdesc_s390x_te_linux64): Likewise.
8290 (init_registers_s390x_vx_linux64): Likewise.
8291 (tdesc_s390x_vx_linux64): Likewise.
8292 (init_registers_s390x_tevx_linux64): Likewise.
8293 (tdesc_s390x_tevx_linux64): Likewise.
8294 (have_hwcap_s390_vx): New static variable.
8295 (s390_arch_setup): Fill have_hwcap_s390_vx.
8296 (s390_get_thread_area): New function.
8297 (s390_ft_entry_gpr_esa): New const.
8298 (s390_ft_entry_gpr_zarch): New const.
8299 (s390_ft_entry_misc): New const.
8300 (s390_ft_entry_fr): New const.
8301 (s390_ft_entry_vr): New const.
8302 (s390_ft_main_31): New const.
8303 (s390_ft_main_64): New const.
8304 (s390_ft_exit_fr): New const.
8305 (s390_ft_exit_vr): New const.
8306 (s390_ft_exit_misc): New const.
8307 (s390_ft_exit_gpr_esa): New const.
8308 (s390_ft_exit_gpr_zarch): New const.
8309 (append_insns): New function.
8310 (s390_relocate_instruction): New function.
8311 (s390_install_fast_tracepoint_jump_pad): New function.
8312 (s390_get_min_fast_tracepoint_insn_len): New function.
8313 (s390_get_ipa_tdesc_idx): New function.
8314 (struct linux_target_ops): Wire in the above functions.
8315 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8316 * linux-s390-tdesc.h: New file.
8317
a4105d04
MK
83182016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8319
8320 * linux-s390-low.c (s390_supports_tracepoints): New function.
8321 (struct linux_target_ops): Fill supports_tracepoints hook.
8322
35ac8b3e
YQ
83232016-03-18 Yao Qi <yao.qi@linaro.org>
8324
8325 * linux-low.c (lwp_signal_can_be_delivered): New function.
8326 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8327
94610ec4
YQ
83282016-03-18 Yao Qi <yao.qi@linaro.org>
8329
8330 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8331 0 if signal is enqueued. Remove 'signal' from one debugging
8332 message. Move one debugging message to some lines below.
8333 Remove code setting 'signal' to 0.
8334
80aea927
YQ
83352016-03-18 Yao Qi <yao.qi@linaro.org>
8336
8337 * linux-low.c (linux_low_filter_event): Remove redundant
8338 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8339
b04fd3be
MK
83402016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8341
8342 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8343 (struct linux_target_ops): Wire in the above.
8344
c40c8d4b
YQ
83452016-03-03 Yao Qi <yao.qi@linaro.org>
8346
8347 * linux-low.c: Update comments to start_step_over.
8348
0f8288ae
YQ
83492016-03-03 Yao Qi <yao.qi@linaro.org>
8350
8351 PR server/19736
8352 * linux-low.c (handle_extended_wait): Set child suspended
8353 if event_lwp->bp_reinsert isn't zero.
8354
fdbd04a8
YQ
83552016-03-02 Yao Qi <yao.qi@linaro.org>
8356
8357 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8358 enqueue_pending_signal.
8359
6896a8fa
MK
83602016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8361
8362 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8363 is actually loaded.
8364
ab503087
MK
83652016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8366
8367 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8368 (s390_regmap_3264) [!__s390x__]: New global.
8369 (s390_collect_ptrace_register): Skip map entries containing -1.
8370 (s390_supply_ptrace_register): Ditto.
8371 (s390_fill_gprs_high): New function.
8372 (s390_store_gprs_high): New function.
8373 (s390_regsets): Add NT_S390_HIGH_GPRS.
8374 (s390_get_hwcap): Enable on 31-bit.
8375 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8376 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8377 Detect NT_S390_HIGH_GPRS.
8378 (s390_usrregs_info_3264): Enable on 31-bit.
8379 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8380 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8381
ae91f625
MK
83822016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8383
8384 PR gdb/13808
8385 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8386 * configure.srv: Ditto.
8387 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8388 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8389 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8390 (init_registers_amd64_linux): Remove prototype.
8391 (tdesc_amd64_linux): Remove declaration.
8392 (get_ipa_tdesc): New function.
8393 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8394 initialize remaining tdescs.
8395 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8396 (init_registers_i386_linux): Remove prototype.
8397 (tdesc_i386_linux): Remove declaration.
8398 (get_ipa_tdesc): New function.
8399 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8400 initialize remaining tdescs.
8401 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8402 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8403 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8404 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8405 (x86_get_ipa_tdesc_idx): New function.
8406 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8407 * linux-x86-tdesc.h: New file.
8408 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8409 (target_get_ipa_tdesc_idx): New macro.
8410 * tracepoint.c (ipa_tdesc_idx): New macro.
8411 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8412 (symbol_list): Add ipa_tdesc_idx.
8413 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8414 (ipa_tdesc): Remove.
8415 (ipa_tdesc_idx): New variable.
8416 (get_context_regcache): Use get_ipa_tdesc.
8417 (gdb_collect): Ditto.
8418 (gdb_probe): Ditto.
8419 * tracepoint.h (get_ipa_tdesc): New prototype.
8420 (ipa_tdesc): Remove.
8421
e7ad2f14
PA
84222016-02-24 Pedro Alves <palves@redhat.com>
8423
8424 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8425 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8426 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8427 Factor out common code between the USE_SIGTRAP_SIGINFO and
8428 !USE_SIGTRAP_SIGINFO blocks.
8429 (linux_low_filter_event): Call save_stop_reason instead of
8430 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8431 Update comments.
8432 (linux_wait_1): Update comments.
8433
657f9cde
WW
84342016-02-24 Wei-cheng Wang <cole945@gmail.com>
8435
8436 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8437 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8438 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8439 ppc_insert_point, ppc_remove_point.
8440
b00b61e1
MK
84412016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8442
8443 * linux-s390-low.c (s390_supports_z_point_type): New function.
8444 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8445
553cb527
YQ
84462016-02-16 Yao Qi <yao.qi@linaro.org>
8447
8448 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8449 PC. Get pc from regcache_read_pc.
8450
a5652c21
YQ
84512016-02-12 Yao Qi <yao.qi@linaro.org>
8452
8453 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8454 or linux_get_pc_32bit.
8455 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8456
ed443b61
YQ
84572016-02-12 Yao Qi <yao.qi@linaro.org>
8458
8459 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8460 arm_linux_get_next_pcs_fixup.
8461
020ecd38
MK
84622016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8463
8464 * tracepoint.c (x_tracepoint_action_download): Change
8465 write_inferior_data_ptr to write_inferior_data_pointer.
8466 (cmd_qtstart): Likewise.
8467 (write_inferior_data_ptr): Remove.
8468 (download_agent_expr): Change write_inferior_data_ptr to
8469 write_inferior_data_pointer.
8470 (download_tracepoint_1): Likewise.
8471 (download_tracepoint): Likewise.
8472 (download_trace_state_variables): Likewise.
8473
7cae9051
WW
84742016-02-11 Wei-cheng Wang <cole945@gmail.com>
8475 Marcin Kościelnicki <koriakin@0x04.net>
8476
8477 * tracepoint.c (struct tracepoint_action_ops): Remove.
8478 (struct tracepoint_action): Remove ops.
8479 (m_tracepoint_action_download, r_tracepoint_action_download)
8480 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8481 size and offset accordingly.
8482 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8483 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8484 (tracepoint_action_send, tracepoint_action_download): New functions.
8485 Helpers for trace action handlers.
8486 (add_tracepoint_action): Remove setup actions ops.
8487 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8488
9f6a71b4
YQ
84892016-02-10 Yao Qi <yao.qi@linaro.org>
8490
8491 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8492
1e94266c
SM
84932016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8494
8495 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8496 to AC_OUTPUT.
8497 * configure: Regenerate.
8498
8adce034
SM
84992016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8500
8501 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8502 void * to gdb_byte *.
8503 * linux-low.c (siginfo_fixup): Likewise.
8504 (linux_xfer_siginfo): Likewise.
8505 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8506 Likewise.
8507 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8508
93813b37
WT
85092016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8510
8511 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8512 to srv_tgtobj.
8513 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8514 to srv_tgtobj.
8515 * linux-x86-low.c [__x86_64__]: Include
8516 "nat/amd64-linux-siginfo.h".
8517 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8518 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8519 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8520 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8521 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8522 (cpt_si_fd, si_timerid, si_overrun): Move from
8523 nat/amd64-linux-siginfo.c.
8524 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8525
8424cc97
SM
85262016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8527
8528 * server.c (skip_to_semicolon): Remove.
8529 (process_point_options): Use strchrnul instead of
8530 skip_to_semicolon.
8531
4d18591b
YQ
85322016-01-26 Yao Qi <yao.qi@linaro.org>
8533
8534 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8535 * linux-low.c (install_software_single_step_breakpoints): Don't
8536 call regcache_read_pc.
8537 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8538 argument pc.
8539
d8020970
YQ
85402016-01-26 Yao Qi <yao.qi@linaro.org>
8541
8542 * linux-low.c (install_software_single_step_breakpoints): Call
8543 regcache_read_pc instead of get_pc.
8544
8b207339
YQ
85452016-01-26 Yao Qi <yao.qi@linaro.org>
8546
8547 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8548 (unblock_async_io): Rename to ...
8549 (block_unblock_async_io): ... it. New function.
8550 (enable_async_io): Don't install SIGIO handler. Unblock it
8551 instead.
8552 (disable_async_io): Don't ignore SIGIO. Block it instead.
8553 (initialize_async_io): Install SIGIO handler. Don't call
8554 unblock_async_io.
8555
18879fef
YQ
85562016-01-26 Yao Qi <yao.qi@linaro.org>
8557
8558 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8559 first character is '\003', call *the_target->request_interrupt.
8560
a0f8e08a
YQ
85612016-01-25 Yao Qi <yao.qi@linaro.org>
8562
8563 * remote-utils.c (new_thread_notify): Remove.
8564 (dead_thread_notify): Likewise.
8565 * remote-utils.h (new_thread_notify): Remove declaration.
8566 (dead_thread_notify): Likewise.
8567
cc5fd9ab
MK
85682016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8569
8570 * gdb.trace/pending.exp: Fix expected message on continue.
8571
99e8eb11
MK
85722016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8573
8574 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8575 it works properly on big-endian machines where sizeof (CORE_ADDR)
8576 != sizeof (void *).
8577
a994041d
PA
85782016-01-21 Pedro Alves <palves@redhat.com>
8579
8580 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8581 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8582 * configure: Regenerate.
8583
f7a6a40d
YQ
85842016-01-21 Yao Qi <yao.qi@linaro.org>
8585
8586 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8587 is_thumb and set it according to CPSR saved on the stack.
8588 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8589 arm_sigreturn_next_pc.
8590
6f69e520
YQ
85912016-01-18 Yao Qi <yao.qi@linaro.org>
8592
8593 * linux-low.c (linux_set_pc_64bit): New function.
8594 (linux_get_pc_64bit): New function.
8595 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8596 Declare.
8597 * linux-sparc-low.c (debug_threads): Remove declaration.
8598 (sparc_get_pc): Remove.
8599 (the_low_target): Use linux_get_pc_64bit instead of
8600 sparc_get_pc.
8601 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8602 (the_low_target): Use linux_get_pc_64bit and
8603 linux_set_pc_64bit.
8604
276d4552
YQ
86052016-01-18 Yao Qi <yao.qi@linaro.org>
8606
8607 * linux-arm-low.c (debug_threads): Remove declaration.
8608 (arm_get_pc, arm_set_pc): Remove.
8609 (the_low_target): Use linux_get_pc_32bit and
8610 linux_set_pc_32bit.
8611 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8612 (the_low_target): Use linux_get_pc_32bit and
8613 linux_set_pc_32bit.
8614 * linux-cris-low.c (debug_threads): Remove declaration.
8615 (cris_get_pc, cris_set_pc,): Remove.
8616 (the_low_target): Use linux_get_pc_32bit and
8617 linux_set_pc_32bit.
8618 * linux-crisv32-low.c (debug_threads): Remove declaration.
8619 (cris_get_pc, cris_set_pc): Remove.
8620 (the_low_target): Use linux_get_pc_32bit and
8621 linux_set_pc_32bit.
8622 * linux-low.c: Include inttypes.h.
8623 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8624 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8625 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8626 (the_low_target): Use linux_get_pc_32bit and
8627 linux_set_pc_32bit.
8628 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8629 (the_low_target): Use linux_get_pc_32bit and
8630 linux_set_pc_32bit.
8631 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8632 (the_low_target): Use linux_get_pc_32bit and
8633 linux_set_pc_32bit.
8634 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8635 (the_low_target): Use linux_get_pc_32bit and
8636 linux_set_pc_32bit.
8637 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8638 (the_low_target): Use linux_get_pc_32bit and
8639 linux_set_pc_32bit.
8640
eb0edac8
GB
86412016-01-18 Gary Benson <gbenson@redhat.com>
8642
8643 * configure.ac (AC_FUNC_FORK): New check.
8644 * config.in: Regenerate.
8645 * configure: Likewise.
8646
1b451dda
YQ
86472016-01-14 Yao Qi <yao.qi@linaro.org>
8648
8649 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8650 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8651 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8652 arm_get_next_pcs_ctor.
8653
82075af2
JS
86542016-01-12 Josh Stone <jistone@redhat.com>
8655 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8656
8657 * inferiors.h: Include "gdb_vecs.h".
8658 (struct process_info): Add syscalls_to_catch.
8659 * inferiors.c (remove_process): Free syscalls_to_catch.
8660 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8661 syscall_return stops.
8662 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8663 * server.c (handle_general_set): Handle QCatchSyscalls.
8664 (handle_query): Report support for QCatchSyscalls.
8665 * target.h (struct target_ops): Add supports_catch_syscall.
8666 (target_supports_catch_syscall): New macro.
8667 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8668 (struct lwp_info): Add syscall_state.
8669 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8670 Maintain syscall_state and syscalls_to_catch across exec.
8671 (get_syscall_trapinfo): New function, proxy to the_low_target.
8672 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8673 (linux_low_filter_event): Toggle syscall_state entry/return for
8674 syscall traps, and set it ignored for all others.
8675 (gdb_catching_syscalls_p): New function.
8676 (gdb_catch_this_syscall_p): New function.
8677 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8678 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8679 (linux_supports_catch_syscall): New function.
8680 (linux_target_ops): Install it.
8681 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8682 (the_low_target): Install it.
8683
8f13a3ce
MF
86842016-01-12 Mike Frysinger <vapier@gentoo.org>
8685
8686 * acinclude.m4: Include new ../warning.m4 file.
8687 * configure: Regenerated.
8688 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8689
5b3da067
MF
86902016-01-12 Mike Frysinger <vapier@gentoo.org>
8691
8692 * ax.c (is_goto_target): Mark static.
8693 * linux-low.c (register_addr): Likewise.
8694 (linux_fetch_registers, linux_store_registers): Likewise.
8695 * mem-break.c (any_persistent_commands): Fix old prototype.
8696 (add_commands_to_breakpoint): Mark static.
8697 * regcache.c (find_register_by_name): Delete unused func.
8698 * remote-utils.c (hex_or_minus_one): Mark static.
8699 * server.c (monitor_show_help): Mark static.
8700 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8701 handle_v_requests): Likewise.
8702
bc504a31
PA
87032016-01-12 Pedro Alves <palves@redhat.com>
8704
8705 Remove use of the registered trademark symbol throughout.
8706
5a0dd67a
YQ
87072016-01-08 Yao Qi <yao.qi@linaro.org>
8708
8709 * remote-utils.c (getpkt): If c is '\003', call target hook
8710 request_interrupt.
8711
b2ca446f
YQ
87122016-01-06 Yao Qi <yao.qi@linaro.org>
8713
8714 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8715 linux-aarch32-low.c.
8716 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8717 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8718 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8719 (thumb2_breakpoint): Declare.
8720 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8721 linux-aarch32-low.h.
8722 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8723 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8724 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8725
edd88788
JB
87262016-01-01 Joel Brobecker <brobecker@adacore.com>
8727
8728 * gdbreplay.c (gdbreplay_version): Change copyright year in
8729 version message.
8730 * server.c (gdbserver_version): Likewise.
8731
65da7f14
PP
87322015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8733
8734 * server.c (crc32_table): Delete.
8735 (crc32): Use libiberty's xcrc32 function.
8736
4abd5ed2
JB
87372015-12-22 Joel Brobecker <brobecker@adacore.com>
8738
8739 * lynx-low.c (lynx_delete_thread_callback): New function.
8740 (lynx_mourn): Properly delete our process and all of its
8741 threads. Remove call to clear_inferiors.
8742
0e50fe5c
JB
87432015-12-22 Joel Brobecker <brobecker@adacore.com>
8744
8745 * target.c (thread_search_callback): Add check that
8746 the thread_stopped target callback is not NULL before
8747 calling it.
8748
35adc03f
YQ
87492015-12-21 Yao Qi <yao.qi@linaro.org>
8750
8751 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8752 arm breakpoint.
8753
bd2b2909
AT
87542015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8755
8756 * server.c (handle_query): Call target_supports_software_single_step.
8757
7fe5e27e
AT
87582015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8759
8760 * linux-low.c (single_step): New function.
8761 (linux_resume_one_lwp_throw): Call single_step.
8762 (start_step_over): Likewise.
8763
d9311bfa
AT
87642015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8765
8766 * Makefile.in (SFILES): Append arch/arm-linux.c,
8767 arch/arm-get-next-pcs.c.
8768 (arm-linux.o): New rule.
8769 (arm-get-next-pcs.o): New rule.
8770 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8771 arm-linux.o.
8772 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8773 to linux-aarch32-low.c.
8774 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8775 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8776 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8777 (thumb2_breakpoint_len): Likewise.
8778 (arm_is_thumb_mode): Make non-static.
8779 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8780 from linux-aarch32-low.c.
8781 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8782 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8783 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8784 (thumb2_breakpoint_len): Likewise.
8785 (arm_is_thumb_mode): New declaration.
8786 * linux-arm-low.c: Include arch/arm-linux.h
8787 aarch/arm-get-next-pcs.h, sys/syscall.h.
8788 (get_next_pcs_ops): New struct.
8789 (get_next_pcs_addr_bits_remove): New function.
8790 (get_next_pcs_is_thumb): New function.
8791 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8792 (arm_sigreturn_next_pc): Likewise.
8793 (get_next_pcs_syscall_next_pc): Likewise.
8794 (arm_gdbserver_get_next_pcs): Likewise.
8795 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8796 Initialize.
8797 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8798 * server.h: Include gdb_vecs.h.
8799
68ce2059
AT
88002015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8801
8802 * Makefile.in (SFILES): Append common/common-regcache.c.
8803 (OBS): Append common-regcache.o.
8804 (common-regcache.o): New rule.
8805 * regcache.c (init_register_cache): Initialize cache to
8806 REG_UNAVAILABLE.
8807 (regcache_raw_read_unsigned): New function.
8808 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8809 register_status enum.
8810
fa5308bd
AT
88112015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8812
8813 * linux-aarch64-low.c (the_low_targets): Rename
8814 breakpoint_reinsert_addr to get_next_pcs.
8815 * linux-arm-low.c (the_low_targets): Likewise.
8816 * linux-bfin-low.c (the_low_targets): Likewise.
8817 * linux-cris-low.c (the_low_targets): Likewise.
8818 * linux-crisv32-low.c (the_low_targets): Likewise.
8819 * linux-low.c (can_software_single_step): Likewise.
8820 (install_software_single_step_breakpoints): New function.
8821 (start_step_over): Use install_software_single_step_breakpoints.
8822 * linux-low.h: New CORE_ADDR vector.
8823 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8824 get_next_pcs.
8825 * linux-mips-low.c (the_low_targets): Likewise.
8826 * linux-nios2-low.c (the_low_targets): Likewise.
8827 * linux-sparc-low.c (the_low_targets): Likewise.
8828
4a6ed09b
PA
88292015-12-17 Pedro Alves <palves@redhat.com>
8830
8831 * linux-low.c (linux_kill_one_lwp): Remove references to
8832 LinuxThreads.
8833 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8834 to 'kill'.
8835 (linux_init_signals): Delete.
8836 (initialize_low): Adjust.
8837 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8838
7544db95
PA
88392015-12-16 Pedro Alves <palves@redhat.com>
8840
8841 * configure.ac (compiler warning flags): When testing a
8842 -Wno-foo option, check whether -Wfoo works instead.
8843 * configure: Regenerate.
8844
8020350c
DB
88452015-12-11 Don Breazeal <donb@codesourcery.com>
8846
8847 * server.c (process_serial_event): Don't exit from gdbserver
8848 in remote mode if there are still active inferiors.
8849
db91f502
YQ
88502015-12-11 Yao Qi <yao.qi@linaro.org>
8851
8852 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8853 arm_breakpoint_at if the process is 32-bit.
8854
b37a6290
YQ
88552015-12-11 Yao Qi <yao.qi@linaro.org>
8856
8857 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8858 arm breakpoint.
8859
17b1509a
YQ
88602015-12-07 Yao Qi <yao.qi@linaro.org>
8861
8862 * configure.srv: Append arm.o to srv_tgtobj for
8863 aarch64*-*-linux* target.
8864 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8865 from linux-arm-low.c.
8866 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8867 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8868 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8869 (thumb2_breakpoint_len): Likewise.
8870 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8871 (arm_breakpoint_kinds): Likewise.
8872 (arm_breakpoint_kind_from_pc): Likewise.
8873 (arm_sw_breakpoint_from_kind): Likewise.
8874 (arm_breakpoint_kind_from_current_state): Likewise.
8875 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8876 (arm_sw_breakpoint_from_kind): Declare.
8877 (arm_breakpoint_kind_from_current_state): Declare.
8878 (arm_breakpoint_at): Declare.
8879 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8880 arm_sw_breakpoint_from_kind if process is 32-bit.
8881 (aarch64_breakpoint_kind_from_pc): New function.
8882 (aarch64_breakpoint_kind_from_current_state): New function.
8883 (the_low_target): Initialize fields breakpoint_kind_from_pc
8884 and breakpoint_kind_from_current_state.
8885 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8886 linux-aarch32-low.c.
8887 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8888 (arm_breakpoint, arm_breakpoint_len): Likewise.
8889 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8890 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8891 (arm_is_thumb_mode): Likewise.
8892 (arm_breakpoint_at): Likewise.
8893 (arm_breakpoint_kind_from_pc): Likewise.
8894 (arm_sw_breakpoint_from_kind): Likewise.
8895 (arm_breakpoint_kind_from_current_state): Likewise.
8896
8897 Revert:
8898 2015-08-04 Yao Qi <yao.qi@linaro.org>
8899
8900 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8901 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8902 * server.c (extended_protocol): Remove "static".
8903 * server.h (extended_protocol): Declare it.
8904
ece66d65
JS
89052015-12-04 Josh Stone <jistone@redhat.com>
8906
8907 * target.h (struct target_ops) <arch_setup>: Rename to ...
8908 (struct target_ops) <post_create_inferior>: ... this.
8909 (target_arch_setup): Rename to ...
8910 (target_post_create_inferior): ... this, calling post_create_inferior.
8911 * server.c (start_inferior): Update target_arch_setup calls to
8912 target_post_create_inferior.
8913 * linux-low.c (linux_low_ptrace_options): Forward declare.
8914 (linux_arch_setup): Update its comment for general use.
8915 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8916 (struct linux_target_ops): Use linux_post_create_inferior.
8917 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8918 to post_create_inferior.
8919 * nto-low.c (struct nto_target_ops): Likewise.
8920 * spu-low.c (struct spu_target_ops): Likewise.
8921 * win32-low.c (struct win32_target_ops): Likewise.
8922
e58c48b4
AT
89232015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
8924
8925 * linux-arm-low.c: Remove duplicate arch/arm.h include.
8926
fbec8956
AT
89272015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8928
8929 * linux-arm-low.c (arm_reinsert_addr): Remove function.
8930 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
8931 * linux-cris-low.c (cris_reinsert_addr> Remove function.
8932 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8933 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
8934 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8935 * linux-mips-low.c (mips_reinsert_addr): Remove function.
8936 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8937 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
8938 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8939 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
8940 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
8941
9b4c5f87
AT
89422015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8943
8944 * linux-low.c (linux_look_up_symbols): Don't call
8945 linux_supports_traceclone.
8946 * linux-low.h (thread_db_init): Remove use_events argument.
8947 * thread-db.c (thread_db_use_event): Remove global variable.
8948 (struct thread_db) <td_thr_event_enable_p>: Remove field.
8949 (struct thread_db) <td_create_bp>: Remove field.
8950 (thread_db_create_event): Remove function.
8951 (thread_db_enable_reporting): Likewise.
8952 (find_one_thread): Don't check for thread_db_use_events.
8953 (attach_thread): Likewise.
8954 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
8955 (try_thread_db_load_1): Don't check for thread_db_use_events.
8956 (thread_db_init): Remove use_events argument and thread events
8957 handling.
8958 (remove_thread_event_breakpoints): Remove function.
8959 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
8960
7d00775e
AT
89612015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
8962
8963 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
8964 New function.
8965 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8966 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
8967 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8968 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
8969 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
8970 Initialize.
8971 * linux-crisv32-low.c (cris_supports_hardware_single_step):
8972 New function.
8973 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8974 * linux-low.c (can_hardware_single_step): Use
8975 supports_hardware_single_step.
8976 (can_software_single_step): New function.
8977 (start_step_over): Call can_software_single_step.
8978 (linux_supports_hardware_single_step): New function.
8979 (struct target_ops) <supports_software_single_step>: Initialize.
8980 * linux-low.h (struct linux_target_ops)
8981 <supports_hardware_single_step>: Initialize.
8982 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
8983 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8984 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
8985 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
8986 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
8987 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8988 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
8989 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8990 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
8991 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
8992 Initialize.
8993 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
8994 (struct linux_target_ops) <tile_supports_hardware_single_step>:
8995 Initialize.
8996 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
8997 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
8998 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
8999 New function.
9000 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9001 * target.h (struct target_ops): <supports_software_single_step>:
9002 New field.
9003 (target_supports_software_single_step): New macro.
9004
2d97cd35
AT
90052015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9006
9007 * linux-low.c (linux_wait_1): Fix pc advance condition.
9008 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9009 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9010
769ef81f
AT
90112015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9012
9013 * linux-arm-low.c (arm_is_thumb_mode): New function.
9014 (arm_breakpoint_at): Use arm_is_thumb_mode.
9015 (arm_breakpoint_kind_from_current_state): New function.
9016 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9017 Initialize.
9018 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9019 (linux_breakpoint_kind_from_current_state): New function.
9020 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9021 * linux-low.h (struct linux_target_ops)
9022 <breakpoint_kind_from_current_state>: New field.
9023 * target.h (struct target_ops): Likewise.
9024 (target_breakpoint_kind_from_current_state): New macro.
9025
1bebeeca
PA
90262015-11-30 Pedro Alves <palves@redhat.com>
9027
9028 * linux-low.c (linux_resume): Wake up the event loop before
9029 returning.
9030
a67a9fae
PA
90312015-11-30 Pedro Alves <palves@redhat.com>
9032
9033 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9034 check.
9035 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9036 to -1.
9037 * target.c (struct thread_search): New structure.
9038 (thread_search_callback): New function.
9039 (prev_general_thread): New global.
9040 (prepare_to_access_memory, done_accessing_memory): New functions.
9041 * target.h (prepare_to_access_memory, done_accessing_memory):
9042 Replace macros with function declarations.
9043
f2faf941
PA
90442015-11-30 Pedro Alves <palves@redhat.com>
9045
9046 PR 14618
9047 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9048 report TARGET_WAITKIND_NO_RESUMED.
9049 * remote-utils.c (prepare_resume_reply): Handle
9050 TARGET_WAITKIND_NO_RESUMED.
9051 * server.c (report_no_resumed): New global.
9052 (handle_query) <qSupported>: Handle "no-resumed+". Report
9053 "no-resumed+" support.
9054 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9055 return error if the client doesn't support no-resumed events.
9056 (push_stop_notification): New function.
9057 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9058 events if the client supports them.
9059
a681f9c9
PA
90602015-11-30 Pedro Alves <palves@redhat.com>
9061
9062 * linux-low.c (thread_still_has_status_pending_p): Don't check
9063 vCont;t here.
9064 (lwp_resumed): New function.
9065 (status_pending_p_callback): Return early if the LWP is not
9066 supposed to be resumed.
9067
65706a29
PA
90682015-11-30 Pedro Alves <palves@redhat.com>
9069
9070 * linux-low.c (handle_extended_wait): Assert that the LWP's
9071 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9072 thread create events, leave the new child's status pending.
9073 (linux_low_filter_event): If GDB wants to hear about thread exit
9074 events, leave the LWP marked dead and don't delete it.
9075 (linux_wait_for_event_filtered): Don't check for thread exit.
9076 (filter_exit_event): New function.
9077 (linux_wait_1): Use it, when returning an exit event.
9078 (linux_resume_one_lwp_throw): Assert that the LWP's
9079 waitstatus is TARGET_WAITKIND_IGNORE.
9080 * remote-utils.c (prepare_resume_reply): Handle
9081 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9082 * server.c (report_thread_events): New global.
9083 (handle_general_set): Handle QThreadEvents.
9084 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9085 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9086 TARGET_WAITKIND_THREAD_EXITED.
9087 * server.h (report_thread_events): Declare.
9088
56cf4bed
PA
90892015-11-30 Pedro Alves <palves@redhat.com>
9090
9091 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9092 the thread's last_resume_kind was resume_stop.
9093
500c1d85
PA
90942015-11-30 Pedro Alves <palves@redhat.com>
9095
9096 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9097 before returning.
9098
de979965
PA
90992015-11-30 Pedro Alves <palves@redhat.com>
9100
9101 * server.c (handle_v_requests): Handle vCtrlC.
9102
34c65914
PA
91032015-11-30 Pedro Alves <palves@redhat.com>
9104
9105 * gdbthread.h (find_any_thread_of_pid): Declare.
9106 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9107 functions.
9108 * server.c (handle_query): If current_thread is NULL, look for
9109 another thread of the selected process.
9110
79efa585 91112015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 9112 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
9113
9114 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9115 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9116 name in reply.
9117 * target.h (struct target_ops) <thread_name>: New field.
9118 (target_thread_name): New macro.
9119
80d82c19
JB
91202015-11-23 Joel Brobecker <brobecker@adacore.com>
9121
9122 * regcache.h (regcache_invalidate_pid): Add declaration.
9123 * regcache.c (regcache_invalidate_pid): New function, extracted
9124 from regcache_invalidate.
9125 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9126 Add trivial documentation comment.
9127 * lynx-low.c: Use regcache_invalidate_pid instead of
9128 regcache_invalidate.
9129
64da5dd5
JB
91302015-11-23 Joel Brobecker <brobecker@adacore.com>
9131
9132 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9133 and Elf64_auxv_t if the target is Android.
9134
37ce4055
DE
91352015-11-22 Doug Evans <xdje42@gmail.com>
9136
9137 * target.h: #include <sys/types.h>.
9138
06e03fff
PA
91392015-11-19 Pedro Alves <palves@redhat.com>
9140
9141 * linux-low.c (linux_process_qsupported): Change prototype.
9142 Adjust.
9143 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9144 Change prototype.
9145 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9146 and adjust to loop over all features.
9147 * server.c (handle_query) <qSupported>: Adjust to call
9148 target_process_qsupported once, passing it a vector of unprocessed
9149 features.
9150 * target.h (struct target_ops) <process_qsupported>: Change
9151 prototype.
9152 (target_process_qsupported): Adjust.
9153
9a084706
PA
91542015-11-19 Pedro Alves <palves@redhat.com>
9155
9156 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9157 mode.
9158 * configure: Regenerate.
9159
dad44a1f
PA
91602015-11-19 Pedro Alves <palves@redhat.com>
9161
9162 * configure: Regenerate.
9163
231c0592
YQ
91642015-11-19 Yao Qi <yao.qi@linaro.org>
9165
9166 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9167 type to uint32_t.
9168
6c1c9a8b
YQ
91692015-11-19 Yao Qi <yao.qi@linaro.org>
9170
9171 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9172 (struct aarch64_operand): Move enum out.
9173
9caa3311
YQ
91742015-11-19 Yao Qi <yao.qi@linaro.org>
9175
9176 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9177 struct user_fpsimd_state *.
9178 (aarch64_store_fpregset): Likewise.
9179
6a69a054
YQ
91802015-11-19 Yao Qi <yao.qi@linaro.org>
9181
9182 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9183 struct user_pt_regs *.
9184 (aarch64_store_gregset): Likewise.
9185
1798301e
PA
91862015-11-18 Pedro Alves <palves@redhat.com>
9187
9188 * Makefile.in (all_object_files): Add $IPA_OBJS.
9189
ce7715e2
PA
91902015-11-17 Pedro Alves <palves@redhat.com>
9191
9192 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9193 GDB_SIGNAL_0 and gdb_signal_to_string.
9194
c0879059
PA
91952015-11-17 Pedro Alves <palves@redhat.com>
9196
9197 * win32-low.c (handle_output_debug_string): Remove parameter.
9198 (win32_kill): Remove our_status local and adjust call to
9199 handle_output_debug_string.
9200 (get_child_debug_event): Adjust call to
9201 handle_output_debug_string.
9202
1996e237
SM
92032015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9204
9205 * linux-mips-low.c (mips_fill_gregset): Add cast.
9206 (mips_store_gregset): Likewise.
9207 (mips_fill_fpregset): Likewise.
9208 (mips_store_fpregset): Likewise.
9209
cbec665b
SM
92102015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9211
9212 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9213 priv.
9214
eb3e3c67
SM
92152015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9216
9217 * linux-mips-low.c (mips_linux_new_thread): Change type of
9218 watch_type to enum target_hw_bp_type.
9219
171de4b8
SM
92202015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9221
9222 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9223 Change return type to arm_hwbp_type.
9224
04248ead
SM
92252015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9226
9227 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9228 (arm_store_gregset): Likewise.
9229 * linux-arm-low.c (arm_get_hwcap): Likewise.
9230 (arm_read_description): Likewise.
9231
04b3479c
SM
92322015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9233
9234 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9235
2bc84e8a
SM
92362015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9237
9238 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9239 (ppc_fill_vsxregset): Likewise.
9240 (ppc_store_vsxregset): Likewise.
9241 (ppc_fill_vrregset): Likewise.
9242 (ppc_store_vrregset): Likewise.
9243 (ppc_fill_evrregset): Likewise.
9244 (ppc_store_evrregset): Likewise.
9245
e6c5bb05
SM
92462015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9247
9248 * linux-ppc-low.c (ppc_usrregs_info): Remove
9249 forward-declaration.
9250 (ppc_arch_setup): Move lower in file.
9251
7ea45d72
SM
92522015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9253
9254 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9255 (ps_pdwrite): Likewise.
9256
69291610
HW
92572015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9258
9259 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9260 to after assert checks.
9261
b42945fd
SM
92622015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9263
9264 * proc-service.c (ps_pdread): Add/adjust casts.
9265 (ps_pdwrite): Add/adjust casts.
9266
d6f85c84
SM
92672015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9268
9269 * server.c (handle_search_memory_1): Cast return value of
9270 memmem.
9271
f98cd059
SM
92722015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9273
9274 * server.c (write_qxfer_response): Change type of data to
9275 gdb_byte *.
9276
d2412fa5
PA
92772015-10-29 Pedro Alves <palves@redhat.com>
9278
9279 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9280
c17414a2
PA
92812015-10-29 Pedro Alves <palves@redhat.com>
9282
9283 * tracepoint.c (clear_installed_tracepoints): Add casts.
9284
e053fbc4
PA
92852015-10-29 Pedro Alves <palves@redhat.com>
9286
9287 * server.c (handle_v_cont, process_serial_event): Add enum
9288 gdb_signal casts to signal parsing code.
9289
add67df8
PA
92902015-10-29 Pedro Alves <palves@redhat.com>
9291
9292 * linux-low.h (NULL_REGSET): Define.
9293 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9294 * linux-arm-low.c (arm_regsets): Likewise.
9295 * linux-crisv32-low.c (cris_regsets): Likewise.
9296 * linux-m68k-low.c (m68k_regsets): Likewise.
9297 * linux-mips-low.c (mips_regsets): Likewise.
9298 * linux-nios2-low.c (nios2_regsets): Likewise.
9299 * linux-ppc-low.c (ppc_regsets): Likewise.
9300 * linux-s390-low.c (s390_regsets): Likewise.
9301 * linux-sh-low.c (sh_regsets): Likewise.
9302 * linux-sparc-low.c (sparc_regsets): Likewise.
9303 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9304 * linux-tile-low.c (tile_regsets): Likewise.
9305 * linux-x86-low.c (x86_regsets): Likewise.
9306 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9307
50bc912a
PA
93082015-10-29 Pedro Alves <palves@redhat.com>
9309
9310 * linux-low.h (NULL_REGSET): Define.
9311 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9312 * linux-arm-low.c (arm_regsets): Likewise.
9313 * linux-crisv32-low.c (cris_regsets): Likewise.
9314 * linux-m68k-low.c (m68k_regsets): Likewise.
9315 * linux-mips-low.c (mips_regsets): Likewise.
9316 * linux-nios2-low.c (nios2_regsets): Likewise.
9317 * linux-ppc-low.c (ppc_regsets): Likewise.
9318 * linux-s390-low.c (s390_regsets): Likewise.
9319 * linux-sh-low.c (sh_regsets): Likewise.
9320 * linux-sparc-low.c (sparc_regsets): Likewise.
9321 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9322 * linux-tile-low.c (tile_regsets): Likewise.
9323 * linux-x86-low.c (x86_regsets): Likewise.
9324 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9325
682b2546
DE
93262015-10-26 Doug Evans <dje@google.com>
9327
9328 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9329
963843d4
DE
93302015-10-26 Doug Evans <dje@google.com>
9331
9332 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9333
d41401ac
DE
93342015-10-26 Doug Evans <dje@google.com>
9335
9336 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9337 for debug_printf.
9338 (attach_thread, find_new_threads_callback): Ditto.
9339
3db28855
AT
93402015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9341
9342 * mem-break.h (set_breakpoint_data): Remove.
9343
fb78e89c
AT
93442015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9345
9346 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9347 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9348 (initialize_low): Remove set_breakpoint_data call.
9349 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9350 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9351 (initialize_low): Remove set_breakpoint_data call.
9352 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9353 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9354 (initialize_low): Remove set_breakpoint_data call.
9355
2e6ee069
AT
93562015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9357
9358 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9359 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9360 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9361 * target.h (target_breakpoint_kind_from_pc): New macro.
9362
1652a986
AT
93632015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9364
9365 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9366 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9367 the default breakpoint kind.
9368
abeead09
AT
93692015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9370
9371 * linux-arm-low.c (arm_supports_z_point_type): Add software
9372 breakpoint support.
9373
b0b4b501
AT
93742015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9375
9376 * linux-arm-low.c: Refactor breakpoint definitions.
9377 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9378 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9379
8689682c
AT
93802015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9381
9382 * Makefile.in: Add arm.c/o.
9383 * configure.srv: Likewise.
9384 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9385 (arm_breakpoint_kind_from_pc): New function.
9386 (arm_sw_breakpoint_from_kind): Return proper kind.
9387 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9388
27165294
AT
93892015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9390
9391 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9392 removal.
9393 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9394 (struct raw_breakpoint) <size>: Remove.
9395 (struct raw_breakpoint) <kind>: Add.
9396 (bp_size): New function.
9397 (bp_opcode): Likewise.
9398 (find_raw_breakpoint_at): Adjust for kind.
9399 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9400 (remove_memory_breakpoint): Adjust for kind call bp_size.
9401 (set_raw_breakpoint_at): Adjust for kind.
9402 (set_breakpoint): Likewise.
9403 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9404 (delete_raw_breakpoint): Adjust for kind.
9405 (delete_breakpoint): Likewise.
9406 (find_gdb_breakpoint): Likewise.
9407 (set_gdb_breakpoint_1): Likewise.
9408 (set_gdb_breakpoint): Likewise.
9409 (delete_gdb_breakpoint_1): Likewise.
9410 (delete_gdb_breakpoint): Likewise.
9411 (uninsert_raw_breakpoint): Likewise.
9412 (reinsert_raw_breakpoint): Likewise.
9413 (set_breakpoint_data): Remove.
9414 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9415 (check_mem_read): Adjust for kind call bp_size.
9416 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9417 (clone_one_breakpoint): Adjust for kind.
9418 * mem-break.h (set_gdb_breakpoint): Likewise.
9419 (delete_gdb_breakpoint): Likewise.
9420 * server.c (process_serial_event): Likewise.
9421
dd373349
AT
94222015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9423
9424 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9425 (struct linux_target_ops) <breakpoint>: Remove.
9426 (struct linux_target_ops) <breakpoint_len>: Remove.
9427 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9428 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9429 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9430 (arm_sw_breakpoint_from_kind): New function.
9431 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9432 (struct linux_target_ops) <breakpoint>: Remove.
9433 (struct linux_target_ops) <breakpoint_len>: Remove.
9434 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9435 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9436 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9437 (struct linux_target_ops) <breakpoint>: Remove.
9438 (struct linux_target_ops) <breakpoint_len>: Remove.
9439 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9440 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9441 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9442 (struct linux_target_ops) <breakpoint>: Remove.
9443 (struct linux_target_ops) <breakpoint_len>: Remove.
9444 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9445 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9446 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9447 and sw_breakpoint_from_kind to increment the pc.
9448 (linux_breakpoint_kind_from_pc): New function.
9449 (linux_sw_breakpoint_from_kind): New function.
9450 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9451 (initialize_low): Call breakpoint_kind_from_pc and
9452 sw_breakpoint_from_kind to replace breakpoint_data/len.
9453 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9454 New field.
9455 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9456 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9457 (struct linux_target_ops) <breakpoint>: Remove.
9458 (struct linux_target_ops) <breakpoint_len>: Remove.
9459 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9460 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9461 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9462 (struct linux_target_ops) <breakpoint>: Remove.
9463 (struct linux_target_ops) <breakpoint_len>: Remove.
9464 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9465 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9466 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9467 (struct linux_target_ops) <breakpoint>: Remove.
9468 (struct linux_target_ops) <breakpoint_len>: Remove.
9469 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9470 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9471 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9472 (struct linux_target_ops) <breakpoint>: Remove.
9473 (struct linux_target_ops) <breakpoint_len>: Remove.
9474 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9475 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9476 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9477 (struct linux_target_ops) <breakpoint>: Remove.
9478 (struct linux_target_ops) <breakpoint_len>: Remove.
9479 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9480 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9481 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9482 (struct linux_target_ops) <breakpoint>: Remove.
9483 (struct linux_target_ops) <breakpoint_len>: Remove.
9484 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9485 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9486 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9487 (struct linux_target_ops) <breakpoint>: Remove.
9488 (struct linux_target_ops) <breakpoint_len>: Remove.
9489 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9490 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9491 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9492 (struct linux_target_ops) <breakpoint>: Remove.
9493 (struct linux_target_ops) <breakpoint_len>: Remove.
9494 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9495 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9496 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9497 (struct linux_target_ops) <breakpoint>: Remove.
9498 (struct linux_target_ops) <breakpoint_len>: Remove.
9499 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9500 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9501 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9502 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9503 (struct linux_target_ops) <breakpoint>: Remove.
9504 (struct linux_target_ops) <breakpoint_len>: Remove.
9505 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9506 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9507 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9508 (struct linux_target_ops) <breakpoint>: Remove.
9509 (struct linux_target_ops) <breakpoint_len>: Remove.
9510 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9511 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9512
4cd98a19
AT
95132015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9514
9515 * linux-cris-low.c (cris_get_pc): Remove void arg.
9516
774ee6d2
AR
95172015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9518
9519 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9520 variable name.
9521
833dcd29
AR
95222015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9523
9524 * inferiors.c (thread_pid_matches_callback): New function.
9525 (find_thread_process): New function.
9526 (remove_thread): Reset current_thread.
9527 (remove_process): Assert threads have been removed first.
9528
8d689ee5
YQ
95292015-10-15 Yao Qi <yao.qi@linaro.org>
9530
9531 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9532 if it is 3.
9533 (aarch64_remove_point): Likewise.
9534 * regcache.c (regcache_register_size): New function.
9535
1c2e1515
YQ
95362015-10-12 Yao Qi <yao.qi@linaro.org>
9537
9538 * linux-aarch64-low.c: Update all callers as emit_load_store
9539 is renamed to aarch64_emit_load_store.
9540
e1c587c3
YQ
95412015-10-12 Yao Qi <yao.qi@linaro.org>
9542
9543 * linux-aarch64-low.c: Update all callers of function renaming
9544 from emit_insn to aarch64_emit_insn.
9545
b6542f81
YQ
95462015-10-12 Yao Qi <yao.qi@linaro.org>
9547
9548 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9549 arch/aarch64-insn.h.
9550 (struct aarch64_memory_operand): Likewise.
9551 (ENCODE): Likewise.
9552 (emit_insn): Move to arch/aarch64-insn.c.
9553 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9554 (emit_load_store): Move to arch/aarch64-insn.c.
9555 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9556 (can_encode_int32): Remove.
9557
246994ce
YQ
95582015-10-12 Yao Qi <yao.qi@linaro.org>
9559
9560 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9561 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9562 (aarch64_relocate_instruction): Likewise.
9563 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9564 (struct aarch64_insn_visitor): Likewise.
9565
0badd99f
YQ
95662015-10-12 Yao Qi <yao.qi@linaro.org>
9567
9568 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9569 (struct aarch64_insn_visitor): New.
9570 (struct aarch64_insn_relocation_data): New.
9571 (aarch64_ftrace_insn_reloc_b): New function.
9572 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9573 (aarch64_ftrace_insn_reloc_cb): Likewise.
9574 (aarch64_ftrace_insn_reloc_tb): Likewise.
9575 (aarch64_ftrace_insn_reloc_adr): Likewise.
9576 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9577 (aarch64_ftrace_insn_reloc_others): Likewise.
9578 (visitor): New.
9579 (aarch64_relocate_instruction): Use visitor.
9580
dfaffe9d
YQ
95812015-10-12 Yao Qi <yao.qi@linaro.org>
9582
9583 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9584 int. Add argument buf.
9585 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9586 aarch64_relocate_instruction.
9587
70b439f0
YQ
95882015-10-12 Yao Qi <yao.qi@linaro.org>
9589
9590 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9591 argument insn. Remove local variable insn. Don't call
9592 target_read_uint32.
9593 (aarch64_install_fast_tracepoint_jump_pad): Call
9594 target_read_uint32.
9595
7781c06f
YQ
95962015-09-30 Yao Qi <yao.qi@linaro.org>
9597
9598 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9599 (emit_load_store_pair): Likewise.
9600
9a3c8263
SM
96012015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9602
9603 * dll.c (match_dll): Add cast(s).
9604 (unloaded_dll): Likewise.
9605 * linux-low.c (second_thread_of_pid_p): Likewise.
9606 (delete_lwp_callback): Likewise.
9607 (count_events_callback): Likewise.
9608 (select_event_lwp_callback): Likewise.
9609 (linux_set_resume_request): Likewise.
9610 * server.c (accumulate_file_name_length): Likewise.
9611 (emit_dll_description): Likewise.
9612 (handle_qxfer_threads_worker): Likewise.
9613 (visit_actioned_threads): Likewise.
9614 * thread-db.c (any_thread_of): Likewise.
9615 * tracepoint.c (same_process_p): Likewise.
9616 (match_blocktype): Likewise.
9617 (build_traceframe_info_xml): Likewise.
9618
224c3ddb
SM
96192015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9620
9621 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9622 assignment.
9623 (gdb_unparse_agent_expr): Likewise.
9624 * hostio.c (require_data): Likewise.
9625 (handle_pread): Likewise.
9626 * linux-low.c (disable_regset): Likewise.
9627 (fetch_register): Likewise.
9628 (store_register): Likewise.
9629 (get_dynamic): Likewise.
9630 (linux_qxfer_libraries_svr4): Likewise.
9631 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9632 (set_fast_tracepoint_jump): Likewise.
9633 (uninsert_fast_tracepoint_jumps_at): Likewise.
9634 (reinsert_fast_tracepoint_jumps_at): Likewise.
9635 (validate_inserted_breakpoint): Likewise.
9636 (clone_agent_expr): Likewise.
9637 * regcache.c (init_register_cache): Likewise.
9638 * remote-utils.c (putpkt_binary_1): Likewise.
9639 (decode_M_packet): Likewise.
9640 (decode_X_packet): Likewise.
9641 (look_up_one_symbol): Likewise.
9642 (relocate_instruction): Likewise.
9643 (monitor_output): Likewise.
9644 * server.c (handle_search_memory): Likewise.
9645 (handle_qxfer_exec_file): Likewise.
9646 (handle_qxfer_libraries): Likewise.
9647 (handle_qxfer): Likewise.
9648 (handle_query): Likewise.
9649 (handle_v_cont): Likewise.
9650 (handle_v_run): Likewise.
9651 (captured_main): Likewise.
9652 * target.c (write_inferior_memory): Likewise.
9653 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9654 * tracepoint.c (init_trace_buffer): Likewise.
9655 (add_tracepoint_action): Likewise.
9656 (add_traceframe): Likewise.
9657 (add_traceframe_block): Likewise.
9658 (cmd_qtdpsrc): Likewise.
9659 (cmd_qtdv): Likewise.
9660 (cmd_qtstatus): Likewise.
9661 (response_source): Likewise.
9662 (response_tsv): Likewise.
9663 (cmd_qtnotes): Likewise.
9664 (gdb_collect): Likewise.
9665 (initialize_tracepoint): Likewise.
9666
afbe19f8
PL
96672015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9668
9669 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9670 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9671 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9672 <NOP>: New.
9673 (enum aarch64_condition_codes): New enum.
9674 (w0): New static global.
9675 (fp): Likewise.
9676 (lr): Likewise.
9677 (struct aarch64_memory_operand) <type>: New
9678 MEMORY_OPERAND_POSTINDEX type.
9679 (postindex_memory_operand): New helper function.
9680 (emit_ret): New function.
9681 (emit_load_store_pair): New function, factored out of emit_stp
9682 with support for MEMORY_OPERAND_POSTINDEX.
9683 (emit_stp): Rewrite using emit_load_store_pair.
9684 (emit_ldp): New function.
9685 (emit_load_store): Likewise.
9686 (emit_ldr): Mention post-index instruction in comment.
9687 (emit_ldrh): New function.
9688 (emit_ldrb): New function.
9689 (emit_ldrsw): Mention post-index instruction in comment.
9690 (emit_str): Likewise.
9691 (emit_subs): New function.
9692 (emit_cmp): Likewise.
9693 (emit_and): Likewise.
9694 (emit_orr): Likewise.
9695 (emit_orn): Likewise.
9696 (emit_eor): Likewise.
9697 (emit_mvn): Likewise.
9698 (emit_lslv): Likewise.
9699 (emit_lsrv): Likewise.
9700 (emit_asrv): Likewise.
9701 (emit_mul): Likewise.
9702 (emit_sbfm): Likewise.
9703 (emit_sbfx): Likewise.
9704 (emit_ubfm): Likewise.
9705 (emit_ubfx): Likewise.
9706 (emit_csinc): Likewise.
9707 (emit_cset): Likewise.
9708 (emit_nop): Likewise.
9709 (emit_ops_insns): New helper function.
9710 (emit_pop): Likewise.
9711 (emit_push): Likewise.
9712 (aarch64_emit_prologue): New function.
9713 (aarch64_emit_epilogue): Likewise.
9714 (aarch64_emit_add): Likewise.
9715 (aarch64_emit_sub): Likewise.
9716 (aarch64_emit_mul): Likewise.
9717 (aarch64_emit_lsh): Likewise.
9718 (aarch64_emit_rsh_signed): Likewise.
9719 (aarch64_emit_rsh_unsigned): Likewise.
9720 (aarch64_emit_ext): Likewise.
9721 (aarch64_emit_log_not): Likewise.
9722 (aarch64_emit_bit_and): Likewise.
9723 (aarch64_emit_bit_or): Likewise.
9724 (aarch64_emit_bit_xor): Likewise.
9725 (aarch64_emit_bit_not): Likewise.
9726 (aarch64_emit_equal): Likewise.
9727 (aarch64_emit_less_signed): Likewise.
9728 (aarch64_emit_less_unsigned): Likewise.
9729 (aarch64_emit_ref): Likewise.
9730 (aarch64_emit_if_goto): Likewise.
9731 (aarch64_emit_goto): Likewise.
9732 (aarch64_write_goto_address): Likewise.
9733 (aarch64_emit_const): Likewise.
9734 (aarch64_emit_call): Likewise.
9735 (aarch64_emit_reg): Likewise.
9736 (aarch64_emit_pop): Likewise.
9737 (aarch64_emit_stack_flush): Likewise.
9738 (aarch64_emit_zero_ext): Likewise.
9739 (aarch64_emit_swap): Likewise.
9740 (aarch64_emit_stack_adjust): Likewise.
9741 (aarch64_emit_int_call_1): Likewise.
9742 (aarch64_emit_void_call_2): Likewise.
9743 (aarch64_emit_eq_goto): Likewise.
9744 (aarch64_emit_ne_goto): Likewise.
9745 (aarch64_emit_lt_goto): Likewise.
9746 (aarch64_emit_le_goto): Likewise.
9747 (aarch64_emit_gt_goto): Likewise.
9748 (aarch64_emit_ge_got): Likewise.
9749 (aarch64_emit_ops_impl): New static global variable.
9750 (aarch64_emit_ops): New target function, return
9751 &aarch64_emit_ops_impl.
9752 (struct linux_target_ops): Install it.
9753
bb903df0
PL
97542015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9755
9756 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9757 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9758 aarch64-ipa.o.
9759 * linux-aarch64-ipa.c: New file.
9760 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9761 and endian.h.
9762 (aarch64_get_thread_area): New target method.
9763 (extract_signed_bitfield): New helper function.
9764 (aarch64_decode_ldr_literal): New function.
9765 (enum aarch64_opcodes): New enum.
9766 (struct aarch64_register): New struct.
9767 (struct aarch64_operand): New struct.
9768 (x0): New static global.
9769 (x1): Likewise.
9770 (x2): Likewise.
9771 (x3): Likewise.
9772 (x4): Likewise.
9773 (w2): Likewise.
9774 (ip0): Likewise.
9775 (sp): Likewise.
9776 (xzr): Likewise.
9777 (aarch64_register): New helper function.
9778 (register_operand): Likewise.
9779 (immediate_operand): Likewise.
9780 (struct aarch64_memory_operand): New struct.
9781 (offset_memory_operand): New helper function.
9782 (preindex_memory_operand): Likewise.
9783 (enum aarch64_system_control_registers): New enum.
9784 (ENCODE): New macro.
9785 (emit_insn): New helper function.
9786 (emit_b): New function.
9787 (emit_bcond): Likewise.
9788 (emit_cb): Likewise.
9789 (emit_tb): Likewise.
9790 (emit_blr): Likewise.
9791 (emit_stp): Likewise.
9792 (emit_ldp_q_offset): Likewise.
9793 (emit_stp_q_offset): Likewise.
9794 (emit_load_store): Likewise.
9795 (emit_ldr): Likewise.
9796 (emit_ldrsw): Likewise.
9797 (emit_str): Likewise.
9798 (emit_ldaxr): Likewise.
9799 (emit_stxr): Likewise.
9800 (emit_stlr): Likewise.
9801 (emit_data_processing_reg): Likewise.
9802 (emit_data_processing): Likewise.
9803 (emit_add): Likewise.
9804 (emit_sub): Likewise.
9805 (emit_mov): Likewise.
9806 (emit_movk): Likewise.
9807 (emit_mov_addr): Likewise.
9808 (emit_mrs): Likewise.
9809 (emit_msr): Likewise.
9810 (emit_sevl): Likewise.
9811 (emit_wfe): Likewise.
9812 (append_insns): Likewise.
9813 (can_encode_int32_in): New helper function.
9814 (aarch64_relocate_instruction): New function.
9815 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9816 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9817 (struct linux_target_ops): Install aarch64_get_thread_area,
9818 aarch64_install_fast_tracepoint_jump_pad and
9819 aarch64_get_min_fast_tracepoint_insn_len.
9820
787749ea
PL
98212015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9822
9823 * Makefile.in (aarch64-insn.o): New rule.
9824 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9825
9812b2e6
YQ
98262015-09-21 Yao Qi <yao.qi@linaro.org>
9827
9828 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9829
18fe412b
YQ
98302015-09-21 Yao Qi <yao.qi@linaro.org>
9831
9832 * tracepoint.c (max_jump_pad_size): Remove.
9833
a0cc84cd
YQ
98342015-09-18 Yao Qi <yao.qi@linaro.org>
9835
9836 * linux-aarch64-low.c: Don't include sys/uio.h.
9837 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9838
d78908cf
WW
98392015-09-16 Wei-cheng Wang <cole945@gmail.com>
9840
9841 * tracepoint.c (eval_result_type): Change prototype.
9842 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9843
d57e0d50
PA
98442015-09-15 Pedro Alves <palves@redhat.com>
9845
9846 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9847 Check whether to report exec events instead of checking whether
9848 multiprocess is enabled.
9849
5a676acc
PA
98502015-09-15 Pedro Alves <palves@redhat.com>
9851
9852 PR remote/18965
9853 * remote-utils.c (prepare_resume_reply): Merge
9854 TARGET_WAITKIND_VFORK_DONE switch case with the
9855 TARGET_WAITKIND_FORKED case.
9856
7c5d0fad
YQ
98572015-09-15 Yao Qi <yao.qi@linaro.org>
9858
9859 * server.c (handle_query): Check string comparison using
9860 "else if" instead of "if".
9861
750ce8d1
YQ
98622015-09-15 Yao Qi <yao.qi@linaro.org>
9863
9864 * server.c (vCont_supported): New global variable.
9865 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9866 matches. Append ";vContSupported+" to own_buf.
9867 (handle_v_requests): Append ";s;S" to own_buf if target supports
9868 hardware single step or vCont_supported is false.
9869 (capture_main): Set vCont_supported to zero.
9870
70b90b91
YQ
98712015-09-15 Yao Qi <yao.qi@linaro.org>
9872
9873 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9874 it to ...
9875 (linux_supports_hardware_single_step): ... New function.
9876 (linux_target_ops): Update.
9877 * lynx-low.c (lynx_target_ops): Set field
9878 supports_hardware_single_step to target_can_do_hardware_single_step.
9879 * nto-low.c (nto_target_ops): Likewise.
9880 * spu-low.c (spu_target_ops): Likewise.
9881 * win32-low.c (win32_target_ops): Likewise.
9882 * target.c (target_can_do_hardware_single_step): New function.
9883 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9884 Remove. <supports_hardware_single_step>: New field.
9885 (target_supports_conditional_breakpoints): Remove.
9886 (target_supports_hardware_single_step): New macro.
9887 (target_can_do_hardware_single_step): Declare.
9888 * server.c (handle_query): Use target_supports_hardware_single_step
9889 instead of target_supports_conditional_breakpoints.
9890
ade90bde
YQ
98912015-09-15 Yao Qi <yao.qi@linaro.org>
9892
9893 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9894 function.
9895 (struct linux_target_ops the_low_target): Install
9896 aarch64_linux_siginfo_fixup.
9897
94585166
DB
98982015-09-11 Don Breazeal <donb@codesourcery.com>
9899 Luis Machado <lgustavo@codesourcery.com>
9900
9901 * linux-low.c (linux_mourn): Static declaration.
9902 (linux_arch_setup): Move in front of
9903 handle_extended_wait.
9904 (linux_arch_setup_thread): New function.
9905 (handle_extended_wait): Handle exec events. Call
9906 linux_arch_setup_thread. Make event_lwp argument a
9907 pointer-to-a-pointer.
9908 (check_zombie_leaders): Do not check stopped threads.
9909 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9910 (linux_low_filter_event): Add lwp and thread for exec'ing
9911 non-leader thread if leader thread has been deleted.
9912 Refactor code into linux_arch_setup_thread and call it.
9913 Pass child lwp pointer by reference to handle_extended_wait.
9914 (linux_wait_for_event_filtered): Update comment.
9915 (linux_wait_1): Prevent clobbering exec event status.
9916 (linux_supports_exec_events): New function.
9917 (linux_target_ops) <supports_exec_events>: Initialize new member.
9918 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9919 new member.
9920 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9921 * server.c (report_exec_events): New global variable.
9922 (handle_query): Handle qSupported query for exec-events feature.
9923 (captured_main): Initialize report_exec_events.
9924 * server.h (report_exec_events): Declare new global variable.
9925 * target.h (struct target_ops) <supports_exec_events>: New
9926 member.
9927 (target_supports_exec_events): New macro.
9928 * win32-low.c (win32_target_ops) <supports_exec_events>:
9929 Initialize new member.
9930
0568462b
MM
99312015-09-09 Markus Metzger <markus.t.metzger@intel.com>
9932
9933 * linux-low.c (linux_low_enable_btrace): Remove.
9934 (linux_target_ops): Replace linux_low_enable_btrace with
9935 linux_enable_btrace.
9936
39edd165
YQ
99372015-09-03 Yao Qi <yao.qi@linaro.org>
9938
9939 * linux-aarch64-low.c (aarch64_insert_point): Call
9940 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
9941 returns true.
9942
1db33b5a
UW
99432015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
9944
9945 * linux-low.c (check_stopped_by_breakpoint): Use
9946 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
9947
ab290430
PA
99482015-08-27 Pedro Alves <palves@redhat.com>
9949
9950 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
9951
8d749320
SM
99522015-08-26 Simon Marchi <simon.marchi@ericsson.com>
9953
6711b7f8
SM
9954 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
9955 the XNEW-family equivalent.
8d749320
SM
9956 (compile_bytecodes): Likewise.
9957 * dll.c (loaded_dll): Likewise.
9958 * event-loop.c (append_callback_event): Likewise.
9959 (create_file_handler): Likewise.
9960 (create_file_event): Likewise.
9961 * hostio.c (handle_open): Likewise.
9962 * inferiors.c (add_thread): Likewise.
9963 (add_process): Likewise.
9964 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
9965 * linux-arm-low.c (arm_new_process): Likewise.
9966 (arm_new_thread): Likewise.
9967 * linux-low.c (add_to_pid_list): Likewise.
9968 (linux_add_process): Likewise.
9969 (handle_extended_wait): Likewise.
9970 (add_lwp): Likewise.
9971 (enqueue_one_deferred_signal): Likewise.
9972 (enqueue_pending_signal): Likewise.
9973 (linux_resume_one_lwp_throw): Likewise.
9974 (linux_resume_one_thread): Likewise.
9975 (linux_read_memory): Likewise.
9976 (linux_write_memory): Likewise.
9977 * linux-mips-low.c (mips_linux_new_process): Likewise.
9978 (mips_linux_new_thread): Likewise.
9979 (mips_add_watchpoint): Likewise.
9980 * linux-x86-low.c (initialize_low_arch): Likewise.
9981 * lynx-low.c (lynx_add_process): Likewise.
9982 * mem-break.c (set_raw_breakpoint_at): Likewise.
9983 (set_breakpoint): Likewise.
9984 (add_condition_to_breakpoint): Likewise.
9985 (add_commands_to_breakpoint): Likewise.
9986 (clone_agent_expr): Likewise.
9987 (clone_one_breakpoint): Likewise.
9988 * regcache.c (new_register_cache): Likewise.
9989 * remote-utils.c (look_up_one_symbol): Likewise.
9990 * server.c (queue_stop_reply): Likewise.
9991 (start_inferior): Likewise.
9992 (queue_stop_reply_callback): Likewise.
9993 (handle_target_event): Likewise.
9994 * spu-low.c (fetch_ppc_memory): Likewise.
9995 (store_ppc_memory): Likewise.
9996 * target.c (set_target_ops): Likewise.
9997 * thread-db.c (thread_db_load_search): Likewise.
9998 (try_thread_db_load_1): Likewise.
9999 * tracepoint.c (add_tracepoint): Likewise.
10000 (add_tracepoint_action): Likewise.
10001 (create_trace_state_variable): Likewise.
10002 (cmd_qtdpsrc): Likewise.
10003 (cmd_qtro): Likewise.
10004 (add_while_stepping_state): Likewise.
10005 * win32-low.c (child_add_thread): Likewise.
10006 (get_image_name): Likewise.
10007
ed8b7b42
YQ
100082015-08-25 Yao Qi <yao.qi@linaro.org>
10009
10010 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10011
db3cb7cb
YQ
100122015-08-25 Yao Qi <yao.qi@linaro.org>
10013
10014 * Makefile.in (aarch64-linux.o): New rule.
10015 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10016 srv_tgtobj.
10017 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10018 (aarch64_init_debug_reg_state): Make it extern.
10019 (aarch64_linux_prepare_to_resume): Remove.
10020
f6011a1c
YQ
100212015-08-25 Yao Qi <yao.qi@linaro.org>
10022
10023 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10024 lwp_arch_private_info and ptid_of_lwp.
10025
88e2cf7e
YQ
100262015-08-25 Yao Qi <yao.qi@linaro.org>
10027
10028 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10029 Find proc_info by find_process_pid. All callers updated.
10030
5e35436e
YQ
100312015-08-25 Yao Qi <yao.qi@linaro.org>
10032
10033 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10034 Remove.
10035 (debug_reg_change_callback): Remove.
10036 (aarch64_notify_debug_reg_change): Remove.
10037
4a8a7965
YQ
100382015-08-25 Yao Qi <yao.qi@linaro.org>
10039
10040 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10041 Call current_lwp_ptid.
10042
32a271ee
YQ
100432015-08-25 Yao Qi <yao.qi@linaro.org>
10044
10045 * linux-aarch64-low.c (debug_reg_change_callback): Use
10046 debug_printf.
10047
0d51c8d7
YQ
100482015-08-25 Yao Qi <yao.qi@linaro.org>
10049
10050 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10051
31a43dd5
YQ
100522015-08-25 Yao Qi <yao.qi@linaro.org>
10053
10054 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10055
8ee52567
YQ
100562015-08-25 Yao Qi <yao.qi@linaro.org>
10057
10058 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10059 the code.
10060
ff3f0f45
YQ
100612015-08-25 Yao Qi <yao.qi@linaro.org>
10062
10063 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10064 Remove.
10065 (debug_reg_change_callback): Remove argument entry and add argument
10066 lwp. Remove local variable thread. Don't print thread id in the
10067 debugging output. Don't check whether pid of thread equals to pid.
10068 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10069 iterate_over_lwps instead find_inferior.
10070
3d40fbb5
PA
100712015-08-24 Pedro Alves <palves@redhat.com>
10072
10073 * inferiors.c (get_first_process): New function.
10074 * inferiors.h (get_first_process): New declaration.
10075 * remote-utils.c (read_ptid): Default to the first process in the
10076 list, instead of to the current thread's process.
10077
438e1e42
PA
100782015-08-24 Pedro Alves <palves@redhat.com>
10079
10080 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10081 * event-loop.c: Likewise.
10082 * remote-utils.c: Likewise.
10083 * tracepoint.c: Likewise.
10084
a8c6d4fc
PA
100852015-08-24 Pedro Alves <palves@redhat.com>
10086
10087 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10088 ptid_get_lwp.
10089
99b0bb12
PA
100902015-08-21 Pedro Alves <palves@redhat.com>
10091
10092 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10093 instead of literal 1.
10094
f8904751
PA
100952015-08-21 Pedro Alves <palves@redhat.com>
10096
10097 * tdesc.c (default_description): Explicitly zero-initialize.
10098
465a859e
PA
100992015-08-21 Pedro Alves <palves@redhat.com>
10100
10101 PR gdb/18749
10102 * inferiors.c (remove_thread): Discard any pending stop reply for
10103 this thread.
10104 * server.c (remove_all_on_match_pid): Rename to ...
10105 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10106 instead of a pid.
10107 (discard_queued_stop_replies): Change parameter to a ptid. Now
10108 extern.
10109 (handle_v_kill, kill_inferior_callback, captured_main)
10110 (process_serial_event): Adjust.
10111 * server.h (discard_queued_stop_replies): Declare.
10112
f0db101d
PA
101132015-08-21 Pedro Alves <palves@redhat.com>
10114
10115 * linux-low.c (wait_for_sigstop): Always switch to no thread
10116 selected if the previously current thread dies.
10117 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10118 process instead of the current thread's.
10119 * remote-utils.c (input_interrupt): Don't check if there's no
10120 current thread.
10121 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10122 current thread to the general thread fails, error out.
10123 (handle_qxfer_auxv, handle_qxfer_libraries)
10124 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10125 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10126 (handle_query): Check if there's a thread selected instead of
10127 checking whether there's any thread in the thread list.
10128 (handle_qxfer_threads, handle_qxfer_btrace)
10129 (handle_qxfer_btrace_conf): Don't error out early if there's no
10130 thread in the thread list.
10131 (handle_v_cont, myresume): Don't set the current thread to the
10132 continue thread.
10133 (process_serial_event) <Hg handling>: Also set thread_id if the
10134 previous general thread is still alive.
10135 (process_serial_event) <g/G handling>: If setting the current
10136 thread to the general thread fails, error out.
10137 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10138 thread's lwp instead of the current thread's.
10139 * target.c (set_desired_thread): If the desired thread was not
10140 found, leave the current thread pointing to NULL. Return an int
10141 (boolean) indicating success.
10142 * target.h (set_desired_thread): Change return type to int.
10143
40045d91
MF
101442015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10145
10146 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10147 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10148 #includes.
10149 (ps_get_thread_area): New function.
10150
45face3b
GB
101512015-08-19 Gary Benson <gbenson@redhat.com>
10152
10153 * hostio.c (handle_pread): Do not attempt to read more data
10154 than hostio_reply_with_data can fit in a packet.
10155
16d5f642
JB
101562015-08-18 Joel Brobecker <brobecker@adacore.com>
10157
10158 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10159
a738da3a
MF
101602015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10161
10162 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10163
33ebda9d
PA
101642015-08-06 Pedro Alves <palves@redhat.com>
10165
10166 * tracepoint.c (expr_eval_result): Now an int.
10167
a44892be
PA
101682015-08-06 Pedro Alves <palves@redhat.com>
10169
10170 * gdbthread.h (struct regcache): Forward declare.
10171 (struct thread_info) <regcache_data>: Now a struct regcache
10172 pointer.
10173 * inferiors.c (inferior_regcache_data)
10174 (set_inferior_regcache_data): Now work with struct regcache
10175 pointers.
10176 * inferiors.h (struct regcache): Forward declare.
10177 (inferior_regcache_data, set_inferior_regcache_data): Now work
10178 with struct regcache pointers.
10179 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10180 (free_register_cache_thread): Remove struct regcache pointer
10181 casts.
10182
608a1e46
PA
101832015-08-06 Pedro Alves <palves@redhat.com>
10184
10185 * server.c (captured_main): On error, print the exception message
10186 to stderr, and if run_once is set, throw a quit.
10187
f0ce0d3a
PA
101882015-08-06 Pedro Alves <palves@redhat.com>
10189
10190 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10191 the current thread.
10192
bf47e248
PA
101932015-08-06 Pedro Alves <palves@redhat.com>
10194
10195 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10196 reading beyond the passed in buffer length.
10197
b6b9ffcc
PL
101982015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10199
10200 * tracepoint.c (symbol_list) <required>: Remove.
10201
863d01bd
PA
102022015-08-06 Pedro Alves <palves@redhat.com>
10203
10204 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10205 count if stopping and suspending threads.
10206 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10207 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10208 (linux_detach): Complete an ongoing step-over.
10209 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10210 throughout.
10211 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10212 (linux_wait_1): If passing a signal to the inferior after
10213 finishing a step-over, unsuspend and re-resume all lwps. If we
10214 see a single-step event but the thread should be continuing, don't
10215 pass the trap to gdb.
10216 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10217 internal_error instead of gdb_assert.
10218 (enqueue_pending_signal): New function.
10219 (check_ptrace_stopped_lwp_gone): Add debug output.
10220 (start_step_over): Use internal_error instead of gdb_assert.
10221 (complete_ongoing_step_over): New function.
10222 (linux_resume_one_thread): Don't resume a suspended thread.
10223 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10224 it stepping.
10225
00db26fa
PA
102262015-08-06 Pedro Alves <palves@redhat.com>
10227
10228 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10229 (linux_thread_alive): Use lwp_is_marked_dead.
10230 (extended_event_reported): Delete.
10231 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10232 instead of extended_event_reported.
10233 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10234 as well.
10235 (lwp_is_marked_dead): New function.
10236 (lwp_running): Use lwp_is_marked_dead.
10237 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10238 comment.
10239
ad071a30
PA
102402015-08-06 Pedro Alves <palves@redhat.com>
10241
10242 * linux-low.c (linux_wait_1): Move fork event output out of the
10243 !report_to_gdb check. Pass event_child->waitstatus to
10244 target_waitstatus_to_string instead of ourstatus.
10245
524b57e6
YQ
102462015-08-04 Yao Qi <yao.qi@linaro.org>
10247
10248 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10249 if current_thread is 32 bit.
10250
6085d6f6
YQ
102512015-08-04 Yao Qi <yao.qi@linaro.org>
10252
10253 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10254 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10255 * server.c (extended_protocol): Remove "static".
10256 * server.h (extended_protocol): Declare it.
10257
8a7e4587
YQ
102582015-08-04 Yao Qi <yao.qi@linaro.org>
10259
10260 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10261 both aarch64 and aarch32.
10262 (aarch64_set_pc): Likewise.
10263
3b53ae99
YQ
102642015-08-04 Yao Qi <yao.qi@linaro.org>
10265
10266 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10267 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10268 arm-with-neon.xml to srv_xmlfiles.
10269 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10270 (is_64bit_tdesc): New function.
10271 (aarch64_linux_read_description): New function.
10272 (aarch64_arch_setup): Call aarch64_linux_read_description.
10273 (regs_info): Rename to regs_info_aarch64.
10274 (aarch64_regs_info): Return right regs_info.
10275 (initialize_low_arch): Call initialize_low_arch_aarch32.
10276
bd9e6534
YQ
102772015-08-04 Yao Qi <yao.qi@linaro.org>
10278
10279 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10280 * linux-aarch32-low.c: New file.
10281 * linux-aarch32-low.h: New file.
10282 * linux-arm-low.c (arm_fill_gregset): Move it to
10283 linux-aarch32-low.c.
10284 (arm_store_gregset): Likewise.
10285 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10286 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10287 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10288 (regs_info): Rename to regs_info_arm.
10289 (arm_regs_info): Return regs_info_aarch32 if
10290 have_ptrace_getregset is 1 and target description is
10291 arm_with_neon or arm_with_vfpv3.
10292 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10293 Call initialize_low_arch_aarch32 instead.
10294
ded48a5e
YQ
102952015-08-04 Yao Qi <yao.qi@linaro.org>
10296
10297 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10298 * linux-low.c: ... here.
10299 * linux-low.h (have_ptrace_getregset): Declare it.
10300
96e9210f
PA
103012015-08-04 Pedro Alves <palves@redhat.com>
10302
10303 * thread-db.c (struct thread_db): Use new typedefs.
10304 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10305 CHK calls.
10306 (disable_thread_event_reporting): Cast result of dlsym to
10307 destination function pointer type.
10308 (thread_db_mourn): Use td_ta_delete_ftype.
10309
af60a1ef
SL
103102015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10311
10312 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10313 arch variant.
10314 (CDX_BREAKPOINT): Define for R2.
10315 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10316 (the_low_target): Add comments.
10317
e8b41681
YQ
103182015-07-30 Yao Qi <yao.qi@linaro.org>
10319
10320 * linux-arm-low.c (arm_hwcap): Remove it.
10321 (arm_read_description): New local variable arm_hwcap. Don't
10322 set arm_hwcap to zero.
10323
89abb039
YQ
103242015-07-30 Yao Qi <yao.qi@linaro.org>
10325
10326 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10327 Use regcache->tdesc instead.
10328 (arm_store_wmmxregset): Likewise.
10329 (arm_fill_vfpregset): Likewise.
10330 (arm_store_vfpregset): Likewise.
10331
deca266c
YQ
103322015-07-30 Yao Qi <yao.qi@linaro.org>
10333
10334 * linux-arm-low.c: Include arch/arm.h.
10335 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10336 (arm_store_gregset): Likewise.
10337
aa58a496
SM
103382015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10339
10340 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10341 ptrace's 4th parameter.
10342
50904b25
YQ
103432015-07-27 Yao Qi <yao.qi@linaro.org>
10344
10345 * configure.srv (case aarch64*-*-linux*): Don't set
10346 srv_linux_usrregs.
10347
5826e159
PA
103482015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10349
10350 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10351 sys/ptrace.h.
10352 * linux-arm-low.c: Likewise.
10353 * linux-cris-low.c: Likewise.
10354 * linux-crisv32-low.c: Likewise.
10355 * linux-low.c: Likewise.
10356 * linux-m68k-low.c: Likewise.
10357 * linux-mips-low.c: Likewise.
10358 * linux-nios2-low.c: Likewise.
10359 * linux-s390-low.c: Likewise.
10360 * linux-sparc-low.c: Likewise.
10361 * linux-tic6x-low.c: Likewise.
10362 * linux-tile-low.c: Likewise.
10363 * linux-x86-low.c: Likewise.
10364
54019719
PA
103652015-07-24 Pedro Alves <palves@redhat.com>
10366
10367 * config.in: Regenerate.
10368 * configure: Regenerate.
10369
eb7aa561
PA
103702015-07-24 Pedro Alves <palves@redhat.com>
10371
10372 * acinclude.m4: Include ../ptrace.m4.
10373 * configure.ac: Call GDB_AC_PTRACE.
10374 * config.in, configure: Regenerate.
10375
55d7b841
YQ
103762015-07-24 Yao Qi <yao.qi@linaro.org>
10377
10378 * linux-low.c (linux_create_inferior): Remove setting to
10379 proc->priv->new_inferior.
10380 (linux_attach): Likewise.
10381 (linux_low_filter_event): Likewise.
10382 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10383
c06cbd92
YQ
103842015-07-24 Yao Qi <yao.qi@linaro.org>
10385
10386 * linux-low.c (linux_arch_setup): New function.
10387 (linux_low_filter_event): If proc->tdesc is NULL and
10388 proc->attached is true, call the_low_target.arch_setup.
10389 Otherwise, keep status pending, and return.
10390 (linux_resume_one_lwp_throw): Don't call get_pc if
10391 thread->while_stepping isn't NULL. Don't call
10392 get_thread_regcache if proc->tdesc is NULL.
10393 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10394 (linux_target_ops): Install arch_setup.
10395 * server.c (start_inferior): Call the_target->arch_setup.
10396 * target.h (struct target_ops) <arch_setup>: New field.
10397 (target_arch_setup): New marco.
10398 * lynx-low.c (lynx_target_ops): Update.
10399 * nto-low.c (nto_target_ops): Update.
10400 * spu-low.c (spu_target_ops): Update.
10401 * win32-low.c (win32_target_ops): Update.
10402
5ae3ebba
YQ
104032015-07-24 Yao Qi <yao.qi@linaro.org>
10404
10405 * linux-low.c (linux_add_process): Don't set
10406 proc->priv->new_inferior.
10407 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10408 (linux_attach): Likewise.
10409
eb97750b
YQ
104102015-07-24 Yao Qi <yao.qi@linaro.org>
10411
10412 * server.c (start_inferior): Code refactor.
10413
51aee833
YQ
104142015-07-24 Yao Qi <yao.qi@linaro.org>
10415
10416 * server.c (process_serial_event): Set general_thread.
10417
af1b22f3
YQ
104182015-07-21 Yao Qi <yao.qi@linaro.org>
10419
10420 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10421 aarch64_linux_get_debug_reg_capacity.
10422
554717a3
YQ
104232015-07-17 Yao Qi <yao.qi@linaro.org>
10424
10425 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10426 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10427 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10428 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10429 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10430 (AARCH64_HWP_ALIGNMENT): Likewise.
10431 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10432 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10433 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10434 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10435 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10436 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10437 (struct aarch64_debug_reg_state): Likewise.
10438 (struct arch_lwp_info): Likewise.
10439 (aarch64_align_watchpoint): Likewise.
10440 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10441 (aarch64_watchpoint_length): Likewise.
10442 (aarch64_point_encode_ctrl_reg): Likewise
10443 (aarch64_point_is_aligned): Likewise.
10444 (aarch64_align_watchpoint): Likewise.
10445 (aarch64_linux_set_debug_regs):
10446 (aarch64_dr_state_insert_one_point): Likewise.
10447 (aarch64_dr_state_remove_one_point): Likewise.
10448 (aarch64_handle_breakpoint): Likewise.
10449 (aarch64_handle_aligned_watchpoint): Likewise.
10450 (aarch64_handle_unaligned_watchpoint): Likewise.
10451 (aarch64_handle_watchpoint): Likewise.
10452
c67ca4de
YQ
104532015-07-17 Yao Qi <yao.qi@linaro.org>
10454
10455 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10456 and don't aarch64_get_debug_reg_state. All callers update.
10457 (aarch64_handle_aligned_watchpoint): Likewise.
10458 (aarch64_handle_unaligned_watchpoint): Likewise.
10459 (aarch64_handle_watchpoint): Likewise.
10460 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10461 (aarch64_remove_point): Likewise.
10462
25abf979
YQ
104632015-07-17 Yao Qi <yao.qi@linaro.org>
10464
10465 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10466 debug_printf.
10467 (aarch64_handle_unaligned_watchpoint): Likewise.
10468
db1ff28b
JK
104692015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10470
10471 Revert the previous 3 commits:
10472 Move gdb_regex* to common/
10473 Move linux_find_memory_regions_full & co.
10474 gdbserver build-id attribute generator
10475
700ca40f
JK
104762015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10477 Jan Kratochvil <jan.kratochvil@redhat.com>
10478
10479 gdbserver build-id attribute generator.
10480 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10481 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10482 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10483 (find_phdr): New.
10484 (get_dynamic): Use find_pdhr to traverse program headers.
10485 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10486 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10487 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10488 (get_hex_build_id): New.
10489 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10490 to reply XML document.
10491
9904185c
JK
104922015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10493 Jan Kratochvil <jan.kratochvil@redhat.com>
10494
10495 * target.c: Include target/target-utils.h and fcntl.h.
10496 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10497 (target_fileio_read_stralloc): New functions.
10498
6e5b4429
JK
104992015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10500
10501 * Makefile.in (OBS): Add gdb_regex.o.
10502 (gdb_regex.o): New.
10503 * config.in: Rebuilt.
10504 * configure: Rebuilt.
10505
ddc98fbf
JK
105062015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10507 Jan Kratochvil <jan.kratochvil@redhat.com>
10508
10509 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10510 * Makefile.in (OBS): Add target-utils.o.
10511 (linux-maps.o, target-utils.o): New.
10512 * configure.srv (srv_linux_obj): Add linux-maps.o.
10513
e57bb7a0
PL
105142015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10515
10516 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10517 function, return 1.
10518 (the_low_target): Install it.
10519
586b02a9
PA
105202015-07-14 Pedro Alves <palves@redhat.com>
10521
10522 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10523 Instead, ignore ECHILD, and throw an error for other errnos.
10524
58c1b36c
PA
105252015-07-10 Pedro Alves <palves@redhat.com>
10526
10527 * event-loop.c (struct callback_event) <data>: Change type to
10528 gdb_client_data instance instead of gdb_client_data pointer.
10529 (append_callback_event): Adjust.
10530
421530db
PL
105312015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10532
10533 * linux-aarch64-low.c: Add comments for each linux_target_ops
10534 method. Remove comments already covered in target_ops and
10535 linux_target_ops definitions.
10536 (the_low_target): Add comments for each unimplemented method.
10537
c2d65f38
YQ
105382015-07-09 Yao Qi <yao.qi@linaro.org>
10539
10540 * linux-aarch64-low.c (aarch64_regmap): Remove.
10541 (aarch64_usrregs_info): Remove.
10542 (regs_info): Set field usrregs to NULL.
10543
b20a6524
MM
105442015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10545
10546 * linux-low.c: Include "rsp-low.h"
10547 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10548 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10549 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10550 (handle_btrace_enable_pt): New.
10551 (handle_btrace_general_set): Support "pt".
10552 (handle_btrace_conf_general_set): Support "pt:size".
10553
96c97461
PL
105542015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10555
10556 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10557 Z_PACKET_SW_BP.
10558
37d66942
PL
105592015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10560
10561 * linux-aarch64-low.c: Remove comment about endianness.
10562 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10563 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10564 memcmp.
10565
dc06243f
GB
105662015-06-24 Gary Benson <gbenson@redhat.com>
10567
10568 * linux-i386-ipa.c (stdint.h): Do not include.
10569 * lynx-i386-low.c (stdint.h): Likewise.
10570 * lynx-ppc-low.c (stdint.h): Likewise.
10571 * mem-break.c (stdint.h): Likewise.
10572 * thread-db.c (stdint.h): Likewise.
10573 * tracepoint.c (stdint.h): Likewise.
10574 * win32-low.c (stdint.h): Likewise.
10575
124e13d9
SM
105762015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10577
10578 * server.c (write_qxfer_response): Update call to
10579 remote_escape_output.
10580
909c2cda
JK
105812015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10582 Jan Kratochvil <jan.kratochvil@redhat.com>
10583
10584 Merge multiple hex conversions.
10585 * gdbreplay.c (tohex): Rename to 'fromhex'.
10586 (logchar): Use fromhex.
10587
24c05f46
JK
105882015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10589
10590 * server.c (handle_qxfer_libraries): Set `version' attribute for
10591 <library-list>.
10592
14d2069a
GB
105932015-06-10 Gary Benson <gbenson@redhat.com>
10594
10595 * target.h (struct target_ops) <multifs_open>: New field.
10596 <multifs_unlink>: Likewise.
10597 <multifs_readlink>: Likewise.
10598 * linux-low.c (nat/linux-namespaces.h): New include.
10599 (linux_target_ops): Initialize the_target->multifs_open,
10600 the_target->multifs_unlink and the_target->multifs_readlink.
10601 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10602 * hostio.c (hostio_fs_pid): New static variable.
10603 (hostio_handle_new_gdb_connection): New function.
10604 (handle_setfs): Likewise.
10605 (handle_open): Use the_target->multifs_open as appropriate.
10606 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10607 (handle_readlink): Use the_target->multifs_readlink as
10608 appropriate.
10609 (handle_vFile): Handle vFile:setfs packets.
10610 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10611 after target_handle_new_gdb_connection.
10612
4b8b5e72
GB
106132015-06-10 Gary Benson <gbenson@redhat.com>
10614
10615 * configure.ac (AC_CHECK_FUNCS): Add setns.
10616 * config.in: Regenerate.
10617 * configure: Likewise.
10618 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10619 (linux-namespaces.o): New rule.
10620 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10621
3ac2e371
GB
106222015-06-09 Gary Benson <gbenson@redhat.com>
10623
10624 * hostio.c (handle_open): Process mode argument with
10625 fileio_to_host_mode.
10626
ca9b78ce
YQ
106272015-06-01 Yao Qi <yao.qi@linaro.org>
10628
10629 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10630 * linux-x86-low.c: Likewise.
10631
bfacd19d
DB
106322015-05-28 Don Breazeal <donb@codesourcery.com>
10633
10634 * linux-low.c (handle_extended_wait): Initialize
10635 thread_info.last_resume_kind for new fork children.
10636
452003ef
PA
106372015-05-15 Pedro Alves <palves@redhat.com>
10638
10639 * target.h (target_handle_new_gdb_connection): Rewrite using if
10640 wrapped in do/while.
10641
1041a03c
JB
106422015-05-14 Joel Brobecker <brobecker@adacore.com>
10643
10644 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10645 * configure, config.in: Regenerate.
10646 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10647 Declare typedef.
10648
c269dbdb
DB
106492015-05-12 Don Breazeal <donb@codesourcery.com>
10650
10651 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10652 PTRACE_EVENT_VFORK_DONE.
10653 (linux_low_ptrace_options, extended_event_reported): Add vfork
10654 events.
10655 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10656 and "vforkdone" for RSP 'T' Stop Reply Packet.
10657 * server.h (report_vfork_events): Declare
10658 global variable.
10659
3a8a0396
DB
106602015-05-12 Don Breazeal <donb@codesourcery.com>
10661
10662 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10663 (the_low_target) <new_fork>: Initialize new member.
10664 * linux-arm-low.c (arm_new_fork): New function.
10665 (the_low_target) <new_fork>: Initialize new member.
10666 * linux-low.c (handle_extended_wait): Call new target function
10667 new_fork.
10668 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10669 * linux-mips-low.c (mips_add_watchpoint): New function
10670 extracted from mips_insert_point.
10671 (the_low_target) <new_fork>: Initialize new member.
10672 (mips_linux_new_fork): New function.
10673 (mips_insert_point): Call mips_add_watchpoint.
10674 * linux-x86-low.c (x86_linux_new_fork): New function.
10675 (the_low_target) <new_fork>: Initialize new member.
10676
de0d863e
DB
106772015-05-12 Don Breazeal <donb@codesourcery.com>
10678
10679 * linux-low.c (handle_extended_wait): Implement return value,
10680 rename argument 'event_child' to 'event_lwp', handle
10681 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10682 (linux_low_ptrace_options): New function.
10683 (linux_low_filter_event): Call linux_low_ptrace_options,
10684 use different argument fo linux_enable_event_reporting,
10685 use return value from handle_extended_wait.
10686 (extended_event_reported): New function.
10687 (linux_wait_1): Call extended_event_reported and set
10688 status to report fork events.
10689 (linux_write_memory): Add pid to debug message.
10690 (reset_lwp_ptrace_options_callback): New function.
10691 (linux_handle_new_gdb_connection): New function.
10692 (linux_target_ops): Initialize new structure member.
10693 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10694 * lynx-low.c: Initialize new structure member.
10695 * remote-utils.c (prepare_resume_reply): Implement stop reason
10696 "fork" for "T" stop message.
10697 * server.c (handle_query): Call handle_new_gdb_connection.
10698 * server.h (report_fork_events): Declare global flag.
10699 * target.h (struct target_ops) <handle_new_gdb_connection>:
10700 New member.
10701 (target_handle_new_gdb_connection): New macro.
10702 * win32-low.c: Initialize new structure member.
10703
ddcbc397
DB
107042015-05-12 Don Breazeal <donb@codesourcery.com>
10705
10706 * mem-break.c (APPEND_TO_LIST): Define macro.
10707 (clone_agent_expr): New function.
10708 (clone_one_breakpoint): New function.
10709 (clone_all_breakpoints): New function.
10710 * mem-break.h: Declare new functions.
10711
89245bc0
DB
107122015-05-12 Don Breazeal <donb@codesourcery.com>
10713
10714 * linux-low.c (linux_supports_fork_events): New function.
10715 (linux_supports_vfork_events): New function.
10716 (linux_target_ops): Initialize new structure members.
10717 (initialize_low): Call linux_check_ptrace_features.
10718 * lynx-low.c (lynx_target_ops): Initialize new structure
10719 members.
10720 * server.c (report_fork_events, report_vfork_events):
10721 New global flags.
10722 (handle_query): Add new features to qSupported packet and
10723 response.
10724 (captured_main): Initialize new global variables.
10725 * target.h (struct target_ops) <supports_fork_events>:
10726 New member.
10727 <supports_vfork_events>: New member.
10728 (target_supports_fork_events): New macro.
10729 (target_supports_vfork_events): New macro.
10730 * win32-low.c (win32_target_ops): Initialize new structure
10731 members.
10732
835205d0
GB
107332015-05-12 Gary Benson <gbenson@redhat.com>
10734
10735 * server.c (handle_qxfer_exec_file): Use current process
10736 if annex is empty.
10737
21e94bd9
SL
107382015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10739
10740 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10741 Remove HAVE_PTRACE_GETREGS conditionals.
10742 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10743 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10744
45614f15
YQ
107452015-05-08 Yao Qi <yao.qi@linaro.org>
10746
10747 * linux-low.c (linux_supports_conditional_breakpoints): New
10748 function.
10749 (linux_target_ops): Install new target method.
10750 * lynx-low.c (lynx_target_ops): Install NULL hook for
10751 supports_conditional_breakpoints.
10752 * nto-low.c (nto_target_ops): Likewise.
10753 * spu-low.c (spu_target_ops): Likewise.
10754 * win32-low.c (win32_target_ops): Likewise.
10755 * server.c (handle_query): Check
10756 target_supports_conditional_breakpoints.
10757 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10758 New field.
10759 (target_supports_conditional_breakpoints): New macro.
10760
80ad801e
PA
107612015-05-06 Pedro Alves <palves@redhat.com>
10762
10763 PR server/18081
10764 * server.c (start_inferior): If the process exits, mourn it.
10765
819843c7
GB
107662015-04-21 Gary Benson <gbenson@redhat.com>
10767
10768 * hostio.c (fileio_open_flags_to_host): Factored out to
10769 fileio_to_host_openflags in common/fileio.c. Single use
10770 updated.
10771
a2d5a9d7
MF
107722015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10773
10774 * linux-xtensa-low.c (xtensa_fill_gregset)
10775 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10776 XCHAL_HAVE_LOOP.
10777
deb44829
MF
107782015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10779
10780 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10781 (regs_info): Replace usrregs pointer with NULL.
10782
e57f1de3
GB
107832015-04-17 Gary Benson <gbenson@redhat.com>
10784
10785 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10786 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10787 * server.c (handle_qxfer_exec_file): New function.
10788 (qxfer_packets): Add exec-file entry.
10789 (handle_query): Report qXfer:exec-file:read as supported packet.
10790
62828379
RN
107912015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10792
10793 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10794
b88bb450
GB
107952015-04-09 Gary Benson <gbenson@redhat.com>
10796
10797 * hostio-errno.c (errno_to_fileio_error): Remove function.
10798 Update caller to use remote_fileio_to_fio_error.
10799
c8f4bfdd
YQ
108002015-04-09 Yao Qi <yao.qi@linaro.org>
10801
10802 * linux-low.c (linux_insert_point): Call
10803 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10804 (linux_remove_point): Call remove_memory_breakpoint if type is
10805 raw_bkpt_type_sw.
10806 * linux-x86-low.c (x86_insert_point): Don't call
10807 insert_memory_breakpoint.
10808 (x86_remove_point): Don't call remove_memory_breakpoint.
10809
41f98f02
PA
108102015-04-01 Pedro Alves <palves@redhat.com>
10811 Cleber Rosa <crosa@redhat.com>
10812
10813 * server.c (gdbserver_usage): Reorganize and extend the usage
10814 message.
10815
2bf6fb9d
PA
108162015-03-24 Pedro Alves <palves@redhat.com>
10817
10818 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10819 output. Also dump TRAP_TRACE.
10820 (linux_low_filter_event): In debug output, distinguish a
10821 resume_stop SIGSTOP from a delayed SIGSTOP.
10822
369f6daa
GB
108232015-03-24 Gary Benson <gbenson@redhat.com>
10824
10825 * linux-x86-low.c (x86_linux_new_thread): Moved to
10826 nat/x86-linux.c.
10827 (x86_linux_prepare_to_resume): Likewise.
10828
8e5d4070
GB
108292015-03-24 Gary Benson <gbenson@redhat.com>
10830
10831 * Makefile.in (x86-linux-dregs.o): New rule.
10832 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10833 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10834 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10835 (x86_linux_dr_get): Likewise.
10836 (x86_linux_dr_set): Likewise.
10837 (update_debug_registers_callback): Likewise.
10838 (x86_linux_dr_set_addr): Likewise.
10839 (x86_linux_dr_get_addr): Likewise.
10840 (x86_linux_dr_set_control): Likewise.
10841 (x86_linux_dr_get_control): Likewise.
10842 (x86_linux_dr_get_status): Likewise.
10843 (x86_linux_update_debug_registers): Likewise.
10844
2b95d440
GB
108452015-03-24 Gary Benson <gbenson@redhat.com>
10846
10847 * linux-x86-low.c (x86_linux_update_debug_registers):
10848 New function, factored out from...
10849 (x86_linux_prepare_to_resume): ...this.
10850
14b0bc68
GB
108512015-03-24 Gary Benson <gbenson@redhat.com>
10852
10853 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10854 (x86_linux_dr_set): Likewise.
10855 (update_debug_registers_callback): Likewise.
10856 (x86_linux_dr_set_addr): Likewise.
10857 (x86_linux_dr_get_addr): Likewise.
10858 (x86_linux_dr_set_control): Likewise.
10859 (x86_linux_dr_get_control): Likewise.
10860 (x86_linux_dr_get_status): Likewise.
10861 (x86_linux_prepare_to_resume): Likewise.
10862
5dfe6ca8
GB
108632015-03-24 Gary Benson <gbenson@redhat.com>
10864
10865 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10866 Use perror_with_name. Pass string through gettext.
10867 (x86_linux_dr_set): Likewise.
10868
d33472ad
GB
108692015-03-24 Gary Benson <gbenson@redhat.com>
10870
10871 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10872 (x86_linux_dr_set_addr): ...this.
10873 (x86_dr_low_get_addr): Rename to...
10874 (x86_linux_dr_get_addr): ...this.
10875 (x86_dr_low_set_control): Rename to...
10876 (x86_linux_dr_set_control): ...this.
10877 (x86_dr_low_get_control): Rename to...
10878 (x86_linux_dr_get_control): ...this.
10879 (x86_dr_low_get_status): Rename to...
10880 (x86_linux_dr_get_status): ...this.
10881 (x86_dr_low): Update with new function names.
10882
4b134ca1
GB
108832015-03-24 Gary Benson <gbenson@redhat.com>
10884
10885 * Makefile.in (x86-linux.o): New rule.
10886 * configure.srv: Add x86-linux.o to relevant targets.
10887 * linux-low.c (lwp_set_arch_private_info): New function.
10888 (lwp_arch_private_info): Likewise.
10889 * linux-x86-low.c: Include nat/x86-linux.h.
10890 (arch_lwp_info): Removed structure.
10891 (update_debug_registers_callback):
10892 Use lwp_set_debug_registers_changed.
10893 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10894 and lwp_set_debug_registers_changed.
10895 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10896
34c703da
GB
108972015-03-24 Gary Benson <gbenson@redhat.com>
10898
10899 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10900 * linux-arm-low.c (arm_new_thread): Likewise.
10901 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10902 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10903 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10904 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10905
cff068da
GB
109062015-03-24 Gary Benson <gbenson@redhat.com>
10907
10908 * linux-low.c (ptid_of_lwp): New function.
10909 (lwp_is_stopped): Likewise.
10910 (lwp_stop_reason): Likewise.
10911 * linux-x86-low.c (update_debug_registers_callback):
10912 Use lwp_is_stopped.
10913 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10914 lwp_stop_reason.
10915
b2f7c7e8
GB
109162015-03-24 Gary Benson <gbenson@redhat.com>
10917
10918 * linux-low.h (linux_stop_lwp): Remove declaration.
10919
6d4ee8c6
GB
109202015-03-24 Gary Benson <gbenson@redhat.com>
10921
10922 * linux-low.h: Include nat/linux-nat.h.
10923 * linux-low.c (iterate_over_lwps_args): New structure.
10924 (iterate_over_lwps_filter): New function.
10925 (iterate_over_lwps): Likewise.
10926 * linux-x86-low.c (update_debug_registers_callback):
10927 Update signature to what iterate_over_lwps expects.
10928 Remove PID check that iterate_over_lwps now performs.
10929 (x86_dr_low_set_addr): Use iterate_over_lwps.
10930 (x86_dr_low_set_control): Likewise.
10931
70a0bb6b
GB
109322015-03-24 Gary Benson <gbenson@redhat.com>
10933
10934 * linux-x86-low.c (x86_debug_reg_state): New function.
10935 (x86_linux_prepare_to_resume): Use the above.
10936
7b669087
GB
109372015-03-24 Gary Benson <gbenson@redhat.com>
10938
10939 * linux-low.c (current_lwp_ptid): New function.
10940 * linux-x86-low.c: Include nat/linux-nat.h.
10941 (x86_dr_low_get_addr): Use current_lwp_ptid.
10942 (x86_dr_low_get_control): Likewise.
10943 (x86_dr_low_get_status): Likewise.
10944
eef49a3d
PA
109452015-03-20 Pedro Alves <palves@redhat.com>
10946
10947 * tracepoint.c (cmd_qtstatus): Make "str" const.
10948
b2333d22
PA
109492015-03-20 Pedro Alves <palves@redhat.com>
10950
10951 * server.c (handle_general_set): Make "req_str" const.
10952
23f238d3
PA
109532015-03-19 Pedro Alves <palves@redhat.com>
10954
10955 * linux-low.c (linux_resume_one_lwp): Rename to ...
10956 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
10957 instead call perror_with_name.
10958 (check_ptrace_stopped_lwp_gone): New function.
10959 (linux_resume_one_lwp): Reimplement as wrapper around
10960 linux_resume_one_lwp_throw that swallows errors if the LWP is
10961 gone.
10962
91baf43f
PA
109632015-03-19 Pedro Alves <palves@redhat.com>
10964
10965 * linux-low.c (count_events_callback, select_event_lwp_callback):
10966 No longer check whether the thread has resume_stop as last resume
10967 kind.
10968
8bf3b159
PA
109692015-03-19 Pedro Alves <palves@redhat.com>
10970
10971 * linux-low.c (count_events_callback, select_event_lwp_callback):
10972 Use the lwp's status_pending_p field, not the thread's.
10973
b90fc188
PA
109742015-03-19 Pedro Alves <palves@redhat.com>
10975
10976 * linux-low.c (select_event_lwp_callback): Update comments to
10977 no longer mention SIGTRAP.
10978
464b0089
GB
109792015-03-18 Gary Benson <gbenson@redhat.com>
10980
10981 * server.c (handle_query): Do not report vFile:fstat as supported.
10982
aa9e327f
GB
109832015-03-11 Gary Benson <gbenson@redhat.com>
10984
10985 * hostio.c (sys/types.h): New include.
10986 (sys/stat.h): Likewise.
10987 (common-remote-fileio.h): Likewise.
10988 (handle_fstat): New function.
10989 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 10990
791c0056
GB
109912015-03-11 Gary Benson <gbenson@redhat.com>
10992
10993 * configure.ac (AC_CHECK_MEMBERS): Add checks for
10994 struct stat.st_blocks and struct stat.st_blksize.
10995 * configure: Regenerate.
10996 * config.in: Likewise.
10997 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
10998 (OBS): Add common-remote-fileio.o.
10999 (common-remote-fileio.o): New rule.
11000
9a9df970
PA
110012015-03-09 Pedro Alves <palves@redhat.com>
11002
11003 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11004 'struct sockaddr' pointer in 'accept' call.
11005
9eb1356e
PA
110062015-03-09 Pedro Alves <palves@redhat.com>
11007
11008 Revert:
11009 2015-03-07 Pedro Alves <palves@redhat.com>
11010 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11011 or <winsock2.h> here. Instead include "gdb_socket.h".
11012 (remote_open): Use union gdb_sockaddr_u.
11013 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11014 or <winsock2.h> here. Instead include "gdb_socket.h".
11015 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11016 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11017 or <sys/un.h>.
11018 (init_named_socket, gdb_agent_helper_thread): Use union
11019 gdb_sockaddr_u.
11020
aac331e4
PA
110212015-03-07 Pedro Alves <palves@redhat.com>
11022
11023 * configure.ac (build_warnings): Move
11024 -Wdeclaration-after-statement to the C-specific set.
11025 * configure: Regenerate.
11026
366c75fc
PA
110272015-03-07 Pedro Alves <palves@redhat.com>
11028
11029 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11030 or <winsock2.h> here. Instead include "gdb_socket.h".
11031 (remote_open): Use union gdb_sockaddr_u.
11032 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11033 or <winsock2.h> here. Instead include "gdb_socket.h".
11034 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11035 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11036 or <sys/un.h>.
11037 (init_named_socket, gdb_agent_helper_thread): Use union
11038 gdb_sockaddr_u.
11039
492d29ea
PA
110402015-03-07 Pedro Alves <palves@redhat.com>
11041
11042 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11043 instead.
11044
60a191ed
YQ
110452015-03-06 Yao Qi <yao.qi@linaro.org>
11046
11047 * linux-aarch64-low.c (aarch64_insert_point): Use
11048 show_debug_regs as a boolean.
11049 (aarch64_remove_point): Likewise.
11050
f5771b1d
PA
110512015-03-05 Pedro Alves <palves@redhat.com>
11052
11053 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11054 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11055 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11056 * nto-low.c (nto_target_ops): Likewise.
11057 * spu-low.c (spu_target_ops): Likewise.
11058 * win32-low.c (win32_target_ops): Likewise.
11059
3e572f71
PA
110602015-03-04 Pedro Alves <palves@redhat.com>
11061
72f4393d 11062 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
11063 Decide whether a breakpoint triggered based on the SIGTRAP's
11064 siginfo.si_code.
72f4393d
L
11065 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11066 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
11067 (linux_low_filter_event): Check for breakpoints before checking
11068 watchpoints.
11069 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11070 siginfo.si_code.
72f4393d
L
11071 (linux_stopped_by_sw_breakpoint)
11072 (linux_supports_stopped_by_sw_breakpoint)
11073 (linux_stopped_by_hw_breakpoint)
11074 (linux_supports_stopped_by_hw_breakpoint): New functions.
11075 (linux_target_ops): Install new target methods.
3e572f71 11076
1ec68e26
PA
110772015-03-04 Pedro Alves <palves@redhat.com>
11078
11079 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11080 * server.c (swbreak_feature, hwbreak_feature): New globals.
11081 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11082 (captured_main): Clear swbreak_feature and hwbreak_feature.
11083 * server.h (swbreak_feature, hwbreak_feature): Declare.
11084 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11085 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11086 supports_stopped_by_hw_breakpoint>: New fields.
11087 (target_supports_stopped_by_sw_breakpoint)
11088 (target_stopped_by_sw_breakpoint)
11089 (target_supports_stopped_by_hw_breakpoint)
11090 (target_stopped_by_hw_breakpoint): Declare.
11091
15c66dd6
PA
110922015-03-04 Pedro Alves <palves@redhat.com>
11093
11094 enum lwp_stop_reason -> enum target_stop_reason
11095 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11096 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11097 (linux_wait_1, stuck_in_jump_pad_callback)
11098 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11099 (linux_stopped_by_watchpoint):
11100 * linux-low.h (enum lwp_stop_reason): Delete.
11101 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11102 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11103
98fc70d6
YQ
111042015-03-04 Yao Qi <yao.qi@linaro.org>
11105
11106 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11107
dd2ac174
GB
111082015-03-03 Gary Benson <gbenson@redhat.com>
11109
11110 * hostio.c (handle_vFile): Fix prefix lengths.
11111
d68e53f4
MM
111122015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11113
11114 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11115 ptr_bits.
11116
bf2d68ab
AA
111172015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11118
11119 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11120 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11121 (clean): Add "rm -f" for above C files.
11122 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11123 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11124 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11125 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11126 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11127 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11128 (init_registers_s390x_vx_linux64)
11129 (init_registers_s390x_tevx_linux64)
11130 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11131 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11132 declarations.
11133 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11134 (s390_store_vxrs_high): New functions.
11135 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11136 NT_S390_VXRS_HIGH.
11137 (s390_arch_setup): Add logic for selecting one of the new target
11138 descriptions. Activate the new vector regsets if applicable.
11139 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11140 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11141 and init_registers_s390x_tevx_linux64.
11142
c966a859
PA
111432015-03-01 Pedro Alves <palves@redhat.com>
11144
11145 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11146 parameter.
11147
4180215b
PA
111482015-02-27 Pedro Alves <palves@redhat.com>
11149
11150 * linux-x86-low.c (u_debugreg_offset): New function.
11151 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11152
749bab01
PA
111532015-02-27 Pedro Alves <palves@redhat.com>
11154
11155 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11156 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11157 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11158 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11159 (ps_lsetfpregs, ps_getpid)
11160 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11161 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11162 (ps_lsetxregs, ps_plog): Declare.
11163
3c14e5a3
PA
111642015-02-27 Pedro Alves <palves@redhat.com>
11165
11166 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11167 IP_AGENT_EXPORT_FUNC.
11168 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11169 IP_AGENT_EXPORT_FUNC.
11170 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11171 (IP_AGENT_EXPORT): Delete.
11172 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11173 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11174 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11175 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11176 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11177 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11178 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11179 (traceframe_read_count, traceframe_write_count)
11180 (traceframes_created, trace_state_variables, get_raw_reg)
11181 (get_trace_state_variable_value, set_trace_state_variable_value)
11182 (ust_loaded, helper_thread_id, cmd_buf): Use
11183 IPA_SYM_EXPORTED_NAME.
11184 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11185 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11186 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11187 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11188 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11189 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11190 EXTERN_C_PUSH/EXTERN_C_POP.
11191 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11192 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11193 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11194 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11195 (traceframe_write_count, traceframe_read_count)
11196 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11197 (about_to_request_buffer_space, get_trace_state_variable_value)
11198 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11199 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11200 EXTERN_C_PUSH/EXTERN_C_POP.
11201 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11202 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11203 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11204 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11205 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11206 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11207 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11208 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11209 Define.
11210 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11211 (IP_AGENT_EXPORT_VAR_DECL): Define.
11212 (tracing): Declare.
11213 (gdb_agent_get_raw_reg): Declare.
11214
fe978cb0
PA
112152015-02-27 Tom Tromey <tromey@redhat.com>
11216 Pedro Alves <palves@redhat.com>
11217
11218 Rename symbols whose names are reserved C++ keywords throughout.
11219
3bc3d82a
PA
112202015-02-27 Pedro Alves <palves@redhat.com>
11221
11222 * Makefile.in (COMPILER): New, get it from autoconf.
11223 (CXX): Get from autoconf instead.
11224 (COMPILE.pre): Use COMPILER.
11225 (CC-LD): Rename to ...
11226 (CC_LD): ... this. Use COMPILER.
11227 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11228 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11229 * acinclude.m4: Include build-with-cxx.m4.
11230 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11231 Disable -Werror by default if building in C++ mode.
11232 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11233 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11234 the C++ compiler. Save/restore CXXFLAGS too.
11235 * configure: Regenerate.
11236
07697489
PA
112372015-02-27 Pedro Alves <palves@redhat.com>
11238
11239 * acinclude.m4: Include libiberty.m4.
11240 * configure.ac: Call libiberty_INIT.
11241 * config.in, configure: Regenerate.
11242
9beb7c4e
PA
112432015-02-26 Pedro Alves <palves@redhat.com>
11244
11245 * linux-low.c (linux_wait_1): When incrementing the PC past a
11246 program breakpoint always use the_low_target.breakpoint_len as
11247 increment, rather than the maximum between that and
11248 the_low_target.decr_pc_after_break.
11249
8090aef2
PA
112502015-02-23 Pedro Alves <palves@redhat.com>
11251
11252 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11253 thread was doing a step-over; always adjust the PC if
11254 we stepped over a permanent breakpoint.
11255 (linux_wait_1): If we stepped over breakpoint that was on top of a
11256 permanent breakpoint, manually advance the PC past it.
11257
bc9540e8
PA
112582015-02-23 Pedro Alves <palves@redhat.com>
11259
11260 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11261 modes.
11262 (x86_fill_gregset, x86_store_gregset): Use it when handling
11263 $orig_eax.
11264
2db9a427
PA
112652015-02-20 Pedro Alves <palves@redhat.com>
11266
11267 * thread-db.c: Include "nat/linux-procfs.h".
11268 (thread_db_init): Skip listing new threads if the kernel supports
11269 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11270
afa8d396
PA
112712015-02-20 Pedro Alves <palves@redhat.com>
11272
11273 * linux-low.c (status_pending_p_callback): Use ptid_match.
11274
c9587f88
AT
112752015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11276
11277 PR breakpoints/16812
11278 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11279 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11280 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11281
b05ec7a5
AT
112822015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11283
11284 PR breakpoints/15956
11285 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11286
d33501a5
MM
112872015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11288
11289 * linux-low.c (linux_low_btrace_conf): Print size.
11290 * server.c (handle_btrace_conf_general_set): New.
11291 (hanle_general_set): Call handle_btrace_conf_general_set.
11292 (handle_query): Report Qbtrace-conf:bts:size as supported.
11293
f4abbc16
MM
112942015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11295
11296 * linux-low.c (linux_low_enable_btrace): Update parameters.
11297 (linux_low_btrace_conf): New.
11298 (linux_target_ops)<to_btrace_conf>: Initialize.
11299 * server.c (current_btrace_conf): New.
11300 (handle_btrace_enable): Rename to ...
11301 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11302 to target_enable_btrace. Update comment. Update users.
11303 (handle_qxfer_btrace_conf): New.
11304 (qxfer_packets): Add btrace-conf entry.
11305 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11306 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11307 (target_ops)<read_btrace_conf>: New.
11308 (target_enable_btrace): Update parameters.
11309 (target_read_btrace_conf): New.
11310
043c3577
MM
113112015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11312
11313 * server.c (handle_btrace_general_set): Remove call to
11314 target_supports_btrace.
11315 (supported_btrace_packets): New.
11316 (handle_query): Call supported_btrace_packets.
11317 * target.h: include btrace-common.h.
11318 (btrace_target_info): Removed.
11319 (supports_btrace, target_supports_btrace): Update parameters.
11320
734b0e4b
MM
113212015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11322
11323 * Makefile.in (SFILES): Add common/btrace-common.c.
11324 (OBS): Add common/btrace-common.o.
11325 (btrace-common.o): Add build rules.
11326 * linux-low: Include btrace-common.h.
11327 (linux_low_read_btrace): Use struct btrace_data. Call
11328 btrace_data_init and btrace_data_fini.
11329
d6c146e9
PA
113302015-02-06 Pedro Alves <palves@redhat.com>
11331
11332 * thread-db.c (find_new_threads_callback): Add debug output.
11333
20ba1ce6
PA
113342015-02-04 Pedro Alves <palves@redhat.com>
11335
11336 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11337 (resume_stopped_resumed_lwps): New function.
11338 (linux_wait_for_event_filtered): Use it.
11339
8cc73a39
SDJ
113402015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11341
11342 * Makefile.in (SFILES): Add linux-personality.c.
11343 (linux-personality.o): New rule.
11344 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11345 list of objects to be built.
11346 * linux-low.c: Include nat/linux-personality.h.
11347 (linux_create_inferior): Remove code to disable address space
11348 randomization (moved to ../nat/linux-personality.c). Create
11349 cleanup to disable address space randomization.
11350
fb23d554
SDJ
113512015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11352
11353 * Makefile.in (posix-strerror.o): New rule.
11354 (mingw-strerror.o): Likewise.
11355 * configure: Regenerated.
11356 * configure.ac: Source file ../common/common.host. Initialize new
11357 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11358
cdf43629
YQ
113592015-01-14 Yao Qi <yao@codesourcery.com>
11360
11361 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11362 (ppc-linux.o): New rule.
11363 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11364 * configure.ac: AC_CHECK_FUNCS(getauxval).
11365 * config.in: Re-generated.
11366 * configure: Re-generated.
11367 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11368 ppc64_64bit_inferior_p
11369
514c5338
YQ
113702015-01-14 Yao Qi <yao@codesourcery.com>
11371
11372 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11373 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11374 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11375 (PT_ORIG_R3, PT_TRAP): Likewise.
11376 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11377 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11378 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11379
3368c1e5
JB
113802015-01-10 Joel Brobecker <brobecker@adacore.com>
11381
11382 * i387-fp.c (i387_cache_to_xsave): In look over
11383 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11384 zmmh_low_space field by use of zmmh_high_space.
11385
582511be
PA
113862015-01-09 Pedro Alves <palves@redhat.com>
11387
11388 * linux-low.c (step_over_bkpt): Move higher up in the file.
11389 (handle_extended_wait): Don't store the stop_pc here.
11390 (get_stop_pc): Adjust comments and rename to ...
11391 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11392 stopped for a software breakpoint or hardware breakpoint.
11393 (thread_still_has_status_pending_p): New function.
11394 (status_pending_p_callback): Use
11395 thread_still_has_status_pending_p. If the event is no longer
11396 interesting, resume the LWP.
11397 (handle_tracepoints): Add assert.
11398 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11399 (wstatus_maybe_breakpoint): New function.
11400 (cancel_breakpoint): Delete function.
11401 (check_stopped_by_watchpoint): New function, factored out from
11402 linux_low_filter_event.
11403 (lp_status_maybe_breakpoint): Delete function.
11404 (linux_low_filter_event): Remove filter_ptid argument.
11405 Leave thread group exits pending here. Store the LWP's stop PC.
11406 Always leave events pending.
11407 (linux_wait_for_event_filtered): Pull all events out of the
11408 kernel, and leave them all pending.
11409 (count_events_callback, select_event_lwp_callback): Consider all
11410 events.
11411 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11412 (select_event_lwp): Only give preference to the stepping LWP in
11413 all-stop mode. Adjust comments.
11414 (ignore_event): New function.
11415 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11416 references to cancel_breakpoints. Adjust to renames. Also give
11417 equal priority to all LWPs that have had events in non-stop mode.
11418 If reporting a software breakpoint event, unadjust the LWP's PC.
11419 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11420 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11421 Adjust.
11422 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11423 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11424 (linux_stopped_by_watchpoint): Adjust.
11425 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11426 * linux-low.h (enum lwp_stop_reason): New.
11427 (struct lwp_info) <stop_pc>: Adjust comment.
11428 <stopped_by_watchpoint>: Delete field.
11429 <stop_reason>: New field.
11430 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11431 * mem-break.c (software_breakpoint_inserted_here)
11432 (hardware_breakpoint_inserted_here): New function.
11433 * mem-break.h (software_breakpoint_inserted_here)
11434 (hardware_breakpoint_inserted_here): Declare.
11435 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11436 (cancel_breakpoints): Delete.
11437 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11438 (upload_fast_traceframes): Remove references to
11439 cancel_breakpoints.
11440
a33e3959
PA
114412015-01-09 Pedro Alves <palves@redhat.com>
11442
11443 * thread-db.c (find_new_threads_callback): Ignore thread if the
11444 kernel thread ID is -1.
11445
8784d563
PA
114462015-01-09 Pedro Alves <palves@redhat.com>
11447
11448 * linux-low.c (linux_attach_fail_reason_string): Move to
11449 nat/linux-ptrace.c, and rename.
11450 (linux_attach_lwp): Update comment.
11451 (attach_proc_task_lwp_callback): New function.
11452 (linux_attach): Adjust to rename and use
11453 linux_proc_attach_tgid_threads.
11454 (linux_attach_fail_reason_string): Delete declaration.
11455
76f2b779
JB
114562015-01-01 Joel Brobecker <brobecker@adacore.com>
11457
11458 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11459 * server.c (gdbserver_version): Likewise.
11460
fafcc06a
SDJ
114612014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11462
11463 * remote-utils.c: Include ctype.h.
11464 (input_interrupt): Explicitly handle the case when the char
11465 received is the NUL byte. Improve the printing of non-ASCII
11466 characters.
11467
beed38b8
JB
114682014-12-16 Joel Brobecker <brobecker@adacore.com>
11469
11470 * linux-low.c (linux_low_filter_event): Update call to
11471 linux_enable_event_reporting following the addition of
11472 a new parameter to that function.
11473
bf330350
CU
114742014-12-16 Catalin Udma <catalin.udma@freescale.com>
11475
11476 PR server/17457
11477 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11478 (AARCH64_FPCR_REGNO): Likewise.
11479 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11480 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11481 (aarch64_store_fpregset): Likewise.
11482
5227d625
JB
114832014-12-15 Joel Brobecker <brobecker@adacore.com>
11484
11485 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11486 Remove FIXME comment about assumption about N.
11487
f93b65a0
JB
114882014-12-13 Joel Brobecker <brobecker@adacore.com>
11489
11490 * configure.ac: If large-file support is disabled in GDBserver,
11491 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11492 * configure: Regenerate.
11493
e5a9158d
AA
114942014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11495
11496 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11497 warning upon ENODATA from ptrace.
11498 * linux-s390-low.c (s390_store_tdb): New.
11499 (s390_regsets): Add regset for NT_S390_TDB.
11500
feea5f36
AA
115012014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11502
11503 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11504 without a fill_function.
11505 * linux-s390-low.c (s390_fill_last_break): Remove.
11506 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11507 (s390_arch_setup): Use regset's size instead of fill_function for
11508 loop end condition.
11509
098dbe61
AA
115102014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11511
11512 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11513 the regset's store function when ptrace returned an error.
11514 * regcache.c (get_thread_regcache): Invalidate register cache
11515 before fetching inferior's registers.
11516
28eef672
AA
115172014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11518
11519 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11520 while-loop as for-loop.
11521 (regsets_store_inferior_registers): Likewise.
11522
bdca27a2
YQ
115232014-11-28 Yao Qi <yao@codesourcery.com>
11524
11525 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11526 * config.in, configure: Re-generate.
11527 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11528 is defined.
11529
9c232dda
YQ
115302014-11-21 Yao Qi <yao@codesourcery.com>
11531
11532 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11533 (AC_CHECK_HEADERS): Remove malloc.h.
11534 * configure: Re-generated.
11535 * config.in: Re-generated.
11536 * server.h: Don't include alloca.h and malloc.h.
11537 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11538 Don't include malloc.h.
11539
43968415
JB
115402014-11-17 Joel Brobecker <brobecker@adacore.com>
11541
11542 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11543 corresponding ERRNO check in same block.
11544
40e91bc7
PA
115452014-11-12 Pedro Alves <palves@redhat.com>
11546
11547 * server.c (cont_thread): Update comment.
11548 (start_inferior, attach_inferior): No longer clear cont_thread.
11549 (handle_v_cont): No longer set cont_thread.
11550 (captured_main): Clear cont_thread each time a GDB connects.
11551
c2c118cf
PA
115522014-11-12 Pedro Alves <palves@redhat.com>
11553
11554 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11555 thread, and don't resume all threads if the Hc thread has exited.
11556
78708b7c
PA
115572014-11-12 Pedro Alves <palves@redhat.com>
11558
11559 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11560 the process group instead of to a specific LWP.
11561
a2abc7de
PA
115622014-10-15 Pedro Alves <palves@redhat.com>
11563
11564 PR server/17487
11565 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11566 parameter.
11567 (arm_set_thread_context): Delete.
11568 (the_low_target): Adjust.
11569 * win32-i386-low.c (debug_registers_changed)
11570 (debug_registers_used): Delete.
11571 (update_debug_registers_callback): New function.
11572 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11573 needing to update their debug registers.
11574 (win32_get_current_dr): New function.
11575 (x86_dr_low_get_addr, x86_dr_low_get_control)
11576 (x86_dr_low_get_status): Fetch the debug register from the thread
11577 record's context.
11578 (i386_initial_stuff): Adjust.
11579 (i386_get_thread_context): Remove current_event parameter. Don't
11580 clear debug_registers_changed nor copy DR values to
11581 debug_reg_state.
11582 (i386_set_thread_context): Delete.
11583 (i386_prepare_to_resume): New function.
11584 (i386_thread_added): Mark the thread as needing to update irs
11585 debug registers.
11586 (the_low_target): Remove i386_set_thread_context and install
11587 i386_prepare_to_resume.
11588 * win32-low.c (win32_get_thread_context): Adjust.
11589 (win32_set_thread_context): Use SetThreadContext
11590 directly.
11591 (win32_prepare_to_resume): New function.
11592 (win32_require_context): New function, factored out from ...
11593 (thread_rec): ... this.
11594 (continue_one_thread): Call win32_prepare_to_resume on each thread
11595 we're about to continue.
11596 (win32_resume): Call win32_prepare_to_resume on the event thread.
11597 * win32-low.h (struct win32_thread_info)
11598 <debug_registers_changed>: New field.
11599 (struct win32_target_ops): Change prototype of set_thread_context,
11600 delete set_thread_context and add prepare_to_resume.
11601 (win32_require_context): New declaration.
11602
a442d071
GB
116032014-10-08 Gary Benson <gbenson@redhat.com>
11604
11605 * server.h: Do not include common-exceptions.h.
11606
6f1947e8
GB
116072014-10-08 Gary Benson <gbenson@redhat.com>
11608
11609 * server.h: Do not include cleanups.h.
11610
63b434a4
JH
116112014-09-30 James Hogan <james.hogan@imgtec.com>
11612
11613 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11614 mips64-dsp-linux.c.
11615
c4d9ceb6
YQ
116162014-09-23 Yao Qi <yao@codesourcery.com>
11617
11618 * linux-low.c (lp_status_maybe_breakpoint): New function.
11619 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11620 (count_events_callback): Likewise.
11621 (select_event_lwp_callback): Likewise.
11622 (cancel_breakpoints_callback): Likewise.
11623
89a5711c
DB
116242014-09-19 Don Breazeal <donb@codesourcery.com>
11625
11626 * linux-low.c (handle_extended_wait): Call
11627 linux_ptrace_get_extended_event.
11628 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11629 linux_is_extended_waitstatus.
11630
bffc0964
JB
116312014-09-16 Joel Brobecker <brobecker@adacore.com>
11632
11633 * Makefile.in (CPPFLAGS): Define.
11634 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11635 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11636
0bfdf32f
GB
116372014-09-16 Gary Benson <gbenson@redhat.com>
11638
11639 * inferiors.h (current_inferior): Renamed as...
11640 (current_thread): New variable. All uses updated.
11641 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11642 (maybe_move_out_of_jump_pad): Likewise.
11643 (cancel_breakpoint): Likewise.
11644 (linux_low_filter_event): Likewise.
11645 (wait_for_sigstop): Likewise.
11646 (linux_resume_one_lwp): Likewise.
11647 (need_step_over_p): Likewise.
11648 (start_step_over): Likewise.
11649 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11650 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11651 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11652 and save_inferior as saved_thread.
11653 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11654 saved_thread.
11655 (regcache_invalidate_thread): Likewise.
11656 * remote-utils.c (prepare_resume_reply): Likewise.
11657 * thread-db.c (thread_db_get_tls_address): Likewise.
11658 (disable_thread_event_reporting): Likewise.
11659 (remove_thread_event_breakpoints): Likewise.
11660 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11661 as saved_thread.
11662 * target.h (set_desired_inferior): Renamed as...
11663 (set_desired_thread): New declaration. All uses updated.
11664 * server.c (myresume): Updated comment to reference thread instead
11665 of inferior.
11666 (handle_serial_event): Likewise.
11667 (handle_target_event): Likewise.
11668
361c8ade
GB
116692014-09-12 Tom Tromey <tromey@redhat.com>
11670 Gary Benson <gbenson@redhat.com>
11671
11672 * regcache.h: Include common-regcache.h.
11673 (regcache_read_pc): Don't declare.
11674 * regcache.c (get_thread_regcache_for_ptid): New function.
11675
bd9269f7
GB
116762014-09-11 Tom Tromey <tromey@redhat.com>
11677 Gary Benson <gbenson@redhat.com>
11678
11679 * symbol.c: New file.
11680 * Makefile.in (SFILES): Add symbol.c.
11681 (OBS): Add symbol.o.
11682
f8c1d06b
GB
116832014-09-11 Gary Benson <gbenson@redhat.com>
11684
11685 * target.c (target_stop_ptid, target_continue_ptid): New
11686 functions.
11687
721ec300
GB
116882014-09-11 Tom Tromey <tromey@redhat.com>
11689 Gary Benson <gbenson@redhat.com>
11690
11691 * target.h: Include target/target.h.
11692 * target.c (target_read_memory, target_read_uint32)
11693 (target_write_memory): New functions.
11694
c5e92cca
GB
116952014-09-11 Gary Benson <gbenson@redhat.com>
11696
11697 * server.h (debug_hw_points): Don't declare.
11698 * server.c (debug_hw_points): Don't define. Replace all uses
11699 with show_debug_regs.
11700 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11701 all uses with show_debug_regs.
11702
2e4bb98a
EBM
117032014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11704
11705 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11706 endianness into account.
11707 (ppc_supply_ptrace_register): Likewise.
11708
ac740bc7
JH
117092014-09-03 James Hogan <james.hogan@imgtec.com>
11710
11711 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11712 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11713
97ea6506
GB
117142014-09-03 Gary Benson <gbenson@redhat.com>
11715
11716 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11717 ALL_DEBUG_ADDRESS_REGISTERS.
11718
df7e5265
GB
117192014-09-02 Gary Benson <gbenson@redhat.com>
11720
11721 * i386-low.h: Renamed as...
11722 * x86-low.h: New file. All type, function and variable name
11723 prefixes changed from "i386_" to "x86_". All references updated.
11724 * i386-low.c: Renamed as...
11725 * x86-low.c: New file. All type, function and variable name
11726 prefixes changed from "i386_" to "x86_". All references updated.
11727
ed859da7
GB
117282014-09-02 Gary Benson <gbenson@redhat.com>
11729
11730 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11731 (x86_linux_new_thread): Likewise.
11732
860789c7
GB
117332014-08-29 Gary Benson <gbenson@redhat.com>
11734
11735 * server.h (setjmp.h): Do not include.
11736 (toplevel): Do not declare.
11737 (common-exceptions.h): Include.
11738 (cleanups.h): Likewise.
11739 * server.c (toplevel): Do not define.
11740 (exit_code): New static global.
11741 (detach_or_kill_for_exit_cleanup): New function.
11742 (main): New function. Original main renamed to...
11743 (captured_main): New function.
11744 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11745
ff55e1b5
GB
117462014-08-29 Gary Benson <gbenson@redhat.com>
11747
11748 * Makefile.in (SFILES): Add common/common-exceptions.c.
11749 (OBS): Add common-exceptions.o.
11750 (common-exceptions.o): New rule.
11751 * utils.c (prepare_to_throw_exception): New function.
11752
e9bcb658
GB
117532014-08-29 Gary Benson <gbenson@redhat.com>
11754
11755 * config.in: Regenerate.
11756 * configure: Likewise.
11757
e3180625
GB
117582014-08-29 Gary Benson <gbenson@redhat.com>
11759
11760 * Makefile.in (SFILES): Add common/cleanups.c.
11761 (OBS): cleanups.o.
11762 (cleanups.o): New rule.
11763
e3d6ba5d
GB
117642014-08-29 Gary Benson <gbenson@redhat.com>
11765
11766 * utils.c (internal_vwarning): New function.
11767
7096e886
GB
117682014-08-28 Gary Benson <gbenson@redhat.com>
11769
11770 * utils.h (fatal): Remove declaration.
11771 * utils.c (fatal): Remove function.
11772
14ce3192
GB
117732014-08-28 Gary Benson <gbenson@redhat.com>
11774
11775 * tracepoint.c (gdb_agent_init): Replace fatal with
11776 perror_with_name.
11777 (initialize_tracepoint): Likewise.
11778
50278d59
GB
117792014-08-28 Gary Benson <gbenson@redhat.com>
11780
11781 * remote-utils.c (remote_prepare): Replace fatal with error.
11782
aa96c426
GB
117832014-08-28 Gary Benson <gbenson@redhat.com>
11784
11785 * linux-low.c (linux_async): Replace fatal with warning.
11786 Tidy up and return.
11787 (linux_start_non_stop): Return -1 if linux_async failed.
11788
f7160e97
GB
117892014-08-28 Gary Benson <gbenson@redhat.com>
11790
11791 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11792 gdb_assert.
11793 (i386_dr_low_get_addr): Remove vague comment.
11794 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11795 gdb_assert.
11796
38e08fca
GB
117972014-08-28 Gary Benson <gbenson@redhat.com>
11798
11799 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11800 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11801 internal_error.
11802 (linux_resume_one_lwp): Likewise.
11803 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11804 gdb_assert.
11805 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11806 with internal_error.
11807 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11808 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11809 (find_register_by_name): Replace fatal with internal_error.
11810 (find_regno): Likewise.
11811 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11812 * thread-db.c (thread_db_create_event): Likewise.
11813 (thread_db_load_search): Likewise.
11814 (try_thread_db_load_1): Likewise.
11815 * tracepoint.c (get_jump_space_head): Replace fatal with
11816 internal_error.
11817 (claim_trampoline_space): Likewise.
11818 (have_fast_tracepoint_trampoline_buffer): Likewise.
11819 (cmd_qtstart): Likewise.
11820 (stop_tracing): Likewise.
11821 (fast_tracepoint_collecting): Likewise.
11822 (target_malloc): Likewise.
11823 (download_tracepoint): Likewise.
11824 (download_trace_state_variables): Replace check with gdb_assert.
11825 (upload_fast_traceframes): Replace fatal with internal_error.
11826
34abf635
GB
118272014-08-19 Tom Tromey <tromey@redhat.com>
11828 Gary Benson <gbenson@redhat.com>
11829
11830 * Makefile.in (SFILES): Add common/common-debug.c.
11831 (OBS): Add common-debug.o.
11832 (common-debug.o): New rule.
11833 * debug.h (debug_printf): Don't declare.
11834 * debug.c (debug_printf): Renamed and rewritten as...
11835 (debug_vprintf): New function.
11836
f6e94d78
GB
118372014-08-19 Gary Benson <gbenson@redhat.com>
11838
11839 * utils.h: Do not include print-utils.h.
11840
9239eeab
GB
118412014-08-19 Tom Tromey <tromey@redhat.com>
11842 Gary Benson <gbenson@redhat.com>
11843
11844 * server.h: Add static assertion.
11845 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11846
ef87c8bb
GB
118472014-08-19 Tom Tromey <tromey@redhat.com>
11848 Gary Benson <gbenson@redhat.com>
11849
11850 * Makefile.in (SFILES): Add common/errors.c.
11851 (OBS): Add errors.o.
11852 (IPA_OBS): Add errors-ipa.o.
11853 (errors.o): New rule.
11854 (errors-ipa.o): Likewise.
11855 * utils.h (perror_with_name, error, warning): Don't declare.
11856 * utils.c (warning): Renamed and rewritten as...
11857 (vwarning): New function.
11858 (error): Renamed and rewritten as...
11859 (verror): New function.
11860 (internal_error): Renamed and rewritten as...
11861 (internal_verror): New function.
11862
bb974a24
GB
118632014-08-07 Gary Benson <gbenson@redhat.com>
11864
11865 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11866 * configure: Regenerate.
11867 * config.in: Likewise.
11868 * server.h: Do not include errno.h.
11869 * event-loop.c: Likewise.
11870 * hostio-errno.c: Likewise.
11871 * linux-low.c: Likewise.
11872 * remote-utils.c: Likewise.
11873 * spu-low.c: Likewise.
11874 * utils.c: Likewise.
11875 * gdbreplay.c: Unconditionally include errno.h.
11876
6d3d12eb
GB
118772014-08-07 Gary Benson <gbenson@redhat.com>
11878
11879 * server.h: Do not include string.h.
11880 * event-loop.c: Likewise.
11881 * linux-low.c: Likewise.
11882 * regcache.c: Likewise.
11883 * remote-utils.c: Likewise.
11884 * spu-low.c: Likewise.
11885 * utils.c: Likewise.
11886
dccbb609
GB
118872014-08-07 Gary Benson <gbenson@redhat.com>
11888
11889 * server.h: Do not include gdb_assert.h.
11890
e76df0d0
GB
118912014-08-07 Gary Benson <gbenson@redhat.com>
11892
11893 * server.h: Do not include common-utils.h.
11894
4cb9c816
GB
118952014-08-07 Gary Benson <gbenson@redhat.com>
11896
11897 * server.h: Do not include ptid.h.
11898 * notif.h: Likewise.
11899
3995eeee
GB
119002014-08-07 Gary Benson <gbenson@redhat.com>
11901
11902 * server.h: Do not include gdb_locale.h.
11903
cb9f1a9b
GB
119042014-08-07 Gary Benson <gbenson@redhat.com>
11905
11906 * server.h: Do not include gdb/signals.h.
11907 * win32-low.c: Likewise.
11908
a5fceff8
GB
119092014-08-07 Gary Benson <gbenson@redhat.com>
11910
11911 * server.h: Do not include pathmax.h.
11912
b9391142
GB
119132014-08-07 Gary Benson <gbenson@redhat.com>
11914
11915 * server.h: Do not include libiberty.h.
11916 * linux-bfin-low.c: Likewise.
11917
0e443c87
GB
119182014-08-07 Gary Benson <gbenson@redhat.com>
11919
11920 * server.h: Do not include ansidecl.h.
11921
8ebb3f56
GB
119222014-08-07 Gary Benson <gbenson@redhat.com>
11923
11924 * linux-x86-low.c: Do not include stddef.h.
11925 * lynx-ppc-low.c: Likewise.
11926 * tracepoint.c: Likewise.
11927
8980bdf6
GB
119282014-08-07 Gary Benson <gbenson@redhat.com>
11929
11930 * server.h: Do not include stdarg.h.
11931 * nto-low.c: Likewise.
11932
d7096f71
GB
119332014-08-07 Gary Benson <gbenson@redhat.com>
11934
11935 * server.h: Do not include stdlib.h.
11936 * inferiors.c: Likewise.
11937 * linux-low.c: Likewise.
11938 * regcache.c: Likewise.
11939 * spu-low.c: Likewise.
11940 * tracepoint.c: Likewise.
11941 * utils.c: Likewise.
11942
d02f550d
GB
119432014-08-07 Gary Benson <gbenson@redhat.com>
11944
11945 * server.h: Do not include stdio.h.
11946 * linux-low.c: Likewise.
11947 * remote-utils.c: Likewise.
11948 * spu-low.c: Likewise.
11949 * utils.c: Likewise.
11950 * wincecompat.c: Likewise.
11951
87f6c4e3
GB
119522014-08-06 Gary Benson <gbenson@redhat.com>
11953
11954 * regcache.c (init_register_cache): Move conditionals inside if.
11955
7089dca4
GB
119562014-08-06 Gary Benson <gbenson@redhat.com>
11957
11958 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
11959
462f517e
GB
119602014-07-31 Gary Benson <gbenson@redhat.com>
11961
11962 * ax.h: Do not include server.h.
11963 * gdbthread.h: Likewise.
11964 * lynx-low.h: Likewise.
11965 * notif.h: Likewise.
11966
976411d6
GB
119672014-07-30 Gary Benson <gbenson@redhat.com>
11968
11969 * server.h: Include common-defs.h.
11970 Do not include config.h or build-gnulib-gdbserver/config.h.
11971
d41f6d8e
GB
119722014-07-30 Gary Benson <gbenson@redhat.com>
11973
11974 * hostio-errno.c: Move server.h to top of includes list.
11975 * inferiors.c: Likewise.
11976 * linux-x86-low.c: Likewise.
11977 * notif.c: Include server.h.
11978
314c6a35
TT
119792014-07-24 Tom Tromey <tromey@redhat.com>
11980 Gary Benson <gbenson@redhat.com>
11981
11982 * server.h (CORE_ADDR): Now unsigned.
11983
69ff6be5
PA
119842014-07-16 Pedro Alves <palves@redhat.com>
11985
11986 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
11987
ce9e3fe7
PA
119882014-07-15 Pedro Alves <palves@redhat.com>
11989
11990 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
11991 copy.
11992
e76126e8
PA
119932014-07-11 Pedro Alves <palves@redhat.com>
11994
11995 * linux-low.c (kill_wait_lwp): New function, based on
11996 kill_one_lwp_callback, but use my_waitpid directly.
11997 (kill_one_lwp_callback, linux_kill): Use it.
11998
8e9db26e
PA
119992014-06-23 Pedro Alves <palves@redhat.com>
12000
12001 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12002 before setting DR0..DR3.
12003
698b3e08
GB
120042014-06-20 Gary Benson <gbenson@redhat.com>
12005
12006 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12007 * configure: Regenerated.
12008 * config.in: Likewise.
12009
125f8a3d
GB
120102014-06-20 Gary Benson <gbenson@redhat.com>
12011
12012 * Makefile.in (SFILES): Update locations for files moved
12013 from common to nat.
12014 (object file files): Reordered.
12015
42995dbd
GB
120162014-06-20 Gary Benson <gbenson@redhat.com>
12017
12018 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12019 (i386_dr_low_set_addr): Likewise.
12020 (i386_dr_low_get_addr): Likewise.
12021 (i386_dr_low_can_set_control): Likewise.
12022 (i386_dr_low_set_control): Likewise.
12023 (i386_dr_low_get_control): Likewise.
12024 (i386_dr_low_get_status): Likewise.
12025 (i386_get_debug_register_length): Likewise.
12026 * linux-x86-low.c (i386_dr_low_set_addr):
12027 Changed signature. Made static.
12028 (i386_dr_low_get_addr): Likewise.
12029 (i386_dr_low_set_control): Likewise.
12030 (i386_dr_low_get_control): Likewise.
12031 (i386_dr_low_get_status): Likewise.
12032 (i386_dr_low): New global variable.
12033 * win32-i386-low.c (i386_dr_low_set_addr):
12034 Changed signature. Made static.
12035 (i386_dr_low_get_addr): Likewise.
12036 (i386_dr_low_set_control): Likewise.
12037 (i386_dr_low_get_control): Likewise.
12038 (i386_dr_low_get_status): Likewise.
12039 (i386_dr_low): New global variable.
12040
e1d2394b
MS
120412014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12042
12043 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12044 * Makefile.in (AR, AR_FLAGS): Define.
12045 * configure: Regenerate.
12046
3a8ee006
GB
120472014-06-19 Gary Benson <gbenson@redhat.com>
12048
12049 * Makefile.in (i386-dregs.o): New rule.
12050 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12051 * i386-low.c (target.h): Remove include.
12052 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12053 (DR_CONTROL_SHIFT): Likewise.
12054 (DR_CONTROL_SIZE): Likewise.
12055 (DR_RW_EXECUTE): Likewise.
12056 (DR_RW_WRITE): Likewise.
12057 (DR_RW_READ): Likewise.
12058 (DR_RW_IORW): Likewise.
12059 (DR_LEN_1): Likewise.
12060 (DR_LEN_2): Likewise.
12061 (DR_LEN_4): Likewise.
12062 (DR_LEN_8): Likewise.
12063 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12064 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12065 (DR_ENABLE_SIZE): Likewise.
12066 (DR_LOCAL_SLOWDOWN): Likewise.
12067 (DR_GLOBAL_SLOWDOWN): Likewise.
12068 (DR_CONTROL_RESERVED): Likewise.
12069 (I386_DR_CONTROL_MASK): Likewise.
12070 (I386_DR_VACANT): Likewise.
12071 (I386_DR_LOCAL_ENABLE): Likewise.
12072 (I386_DR_GLOBAL_ENABLE): Likewise.
12073 (I386_DR_DISABLE): Likewise.
12074 (I386_DR_SET_RW_LEN): Likewise.
12075 (I386_DR_GET_RW_LEN): Likewise.
12076 (I386_DR_WATCH_HIT): Likewise.
12077 (i386_wp_op_t): Likewise.
12078 (i386_show_dr): Likewise.
12079 (i386_length_and_rw_bits): Likewise.
12080 (i386_insert_aligned_watchpoint): Likewise.
12081 (i386_remove_aligned_watchpoint): Likewise.
12082 (i386_handle_nonaligned_watchpoint): Likewise.
12083 i386_update_inferior_debug_regs(): Likewise.
12084 (i386_dr_insert_watchpoint): Likewise.
12085 (i386_dr_remove_watchpoint): Likewise.
12086 (i386_dr_region_ok_for_watchpoint): Likewise.
12087 (i386_dr_stopped_data_address): Likewise.
12088 (i386_dr_stopped_by_watchpoint): Likewise.
12089
8f26655c
GB
120902014-06-19 Gary Benson <gbenson@redhat.com>
12091
12092 * i386-low.c (i386_dr_show): Renamed to
12093 i386_show_dr and made static. All uses updated.
12094 (i386_dr_length_and_rw_bits): Renamed to
12095 i386_length_and_rw_bits and made static.
12096 All uses updated.
12097 (i386_dr_insert_aligned_watchpoint): Renamed to
12098 i386_insert_aligned_watchpoint and made static.
12099 All uses updated.
12100 (i386_dr_remove_aligned_watchpoint): Renamed to
12101 i386_remove_aligned_watchpoint and made static.
12102 All uses updated.
12103 (i386_dr_update_inferior_debug_regs): Renamed to
12104 i386_update_inferior_debug_regs and made static.
12105 All uses updated.
12106
b9228891
GB
121072014-06-18 Gary Benson <gbenson@redhat.com>
12108
5171def3
GB
12109 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12110 (i386_dr_low_can_set_control): Likewise.
12111 (i386_get_debug_register_length): Likewise.
12112 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12113 (i386_dr_low_can_set_control): Likewise.
12114 (i386_get_debug_register_length): Likewise.
12115
121162014-06-17 Gary Benson <gbenson@redhat.com>
12117
b9228891
GB
12118 * i386-low.h (i386-dregs.h): New include.
12119 (DR_FIRSTADDR): Now in i386-dregs.h.
12120 (DR_LASTADDR): Likewise.
12121 (DR_NADDR): Likewise.
12122 (DR_STATUS): Likewise.
12123 (DR_CONTROL): Likewise.
12124 (i386_debug_reg_state): Likewise.
12125 (i386_dr_insert_watchpoint): Likewise.
12126 (i386_dr_remove_watchpoint): Likewise.
12127 (i386_dr_region_ok_for_watchpoint): Likewise.
12128 (i386_dr_stopped_data_address): Likewise.
12129 (i386_dr_stopped_by_watchpoint): Likewise.
12130 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12131
4be83cc2
GB
121322014-06-18 Gary Benson <gbenson@redhat.com>
12133
12134 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12135 i386_dr_insert_watchpoint.
12136 (i386_low_remove_watchpoint): Renamed to
12137 i386_dr_remove_watchpoint.
12138 (i386_low_region_ok_for_watchpoint): Renamed to
12139 i386_dr_region_ok_for_watchpoint.
12140 (i386_low_stopped_data_address): Renamed to
12141 i386_dr_stopped_data_address.
12142 (i386_low_stopped_by_watchpoint): Renamed to
12143 i386_dr_stopped_by_watchpoint.
12144 * i386-low.c (i386_show_dr): Renamed to
12145 i386_dr_show and made nonstatic. All uses updated.
12146 (i386_length_and_rw_bits): Renamed to
12147 i386_dr_length_and_rw_bits and made nonstatic.
12148 All uses updated.
12149 (i386_insert_aligned_watchpoint): Renamed to
12150 i386_dr_insert_aligned_watchpoint and made nonstatic.
12151 All uses updated.
12152 (i386_remove_aligned_watchpoint): Renamed to
12153 i386_dr_remove_aligned_watchpoint and made nonstatic.
12154 All uses updated.
12155 (i386_update_inferior_debug_regs): Renamed to
12156 i386_dr_update_inferior_debug_regs and made nonstatic.
12157 All uses updated.
12158 (i386_low_insert_watchpoint): Renamed to
12159 i386_dr_insert_watchpoint. All uses updated.
12160 (i386_low_remove_watchpoint): Renamed to
12161 i386_dr_remove_watchpoint. All uses updated.
12162 (i386_low_region_ok_for_watchpoint): Renamed to
12163 i386_dr_region_ok_for_watchpoint. All uses updated.
12164 (i386_low_stopped_data_address): Renamed to
12165 i386_dr_stopped_data_address. All uses updated.
12166 (i386_low_stopped_by_watchpoint): Renamed to
12167 i386_dr_stopped_by_watchpoint. All uses updated.
12168
131aa0d4
GB
121692014-06-18 Gary Benson <gbenson@redhat.com>
12170
12171 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12172 (i386_dr_low_can_set_control): Likewise.
12173 (i386_insert_aligned_watchpoint): New check.
12174
d9305f7f
GB
121752014-06-18 Gary Benson <gbenson@redhat.com>
12176
12177 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12178 Renamed to state.
12179
e927c9fc
GB
121802014-06-18 Gary Benson <gbenson@redhat.com>
12181
12182 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12183 instead of fatal and error.
12184 (i386_handle_nonaligned_watchpoint): Likewise.
12185
1b6d4134
GB
121862014-06-18 Gary Benson <gbenson@redhat.com>
12187
12188 * i386-low.c (i386_get_debug_register_length): New macro.
12189 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12190 (i386_show_dr): Use debug_printf instead of fprintf. Use
12191 phex to format values.
12192
6e62758f
GB
121932014-06-18 Gary Benson <gbenson@redhat.com>
12194
12195 * i386-low.h: Comment changes.
12196 * i386-low.c: Likewise.
12197
fc6e2f03
GB
121982014-06-18 Gary Benson <gbenson@redhat.com>
12199
12200 * i386-low.c: Whitespace changes.
12201
f9d1eeed
TT
122022014-06-12 Tom Tromey <tromey@redhat.com>
12203
12204 * utils.c (freeargv): Remove.
12205
0b04e523
TT
122062014-06-12 Tom Tromey <tromey@redhat.com>
12207
12208 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12209 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12210 (parse_debug_format_options): Likewise.
12211 (gdbserver_usage): Likewise.
12212 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12213 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12214 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12215 against libiberty.
12216 ($(LIBGNU)): Depend on libiberty.
12217 (all-lib): Recurse into all subdirs.
12218 (install-only): Invoke "install" target in subdirs.
12219 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12220 targets.
12221 * configure: Rebuild.
12222 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12223 for vasprintf, vsnprintf, or gettimeofday.
12224 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12225 srv_tgtobj.
12226
270c9937
JB
122272014-06-05 Joel Brobecker <brobecker@adacore.com>
12228
12229 * development.sh: Delete.
12230 * Makefile.in (config.status): Adjust dependency on development.sh.
12231 * configure.ac: Adjust development.sh source call.
12232 * configure: Regenerate.
12233
0a261ed8
PA
122342014-06-02 Pedro Alves <palves@redhat.com>
12235
12236 * ax.c (gdb_free_agent_expr): New function.
12237 * ax.h (gdb_free_agent_expr): New declaration.
12238 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12239 list.
12240 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12241 static.
12242 (clear_breakpoint_conditions_and_commands): New function.
12243 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12244 (clear_breakpoint_conditions_and_commands): New declaration.
12245
e9dae05e
RR
122462014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12247
12248 * linux-aarch64-low.c (asm/ptrace.h): Include.
12249
5876f503
JK
122502014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12251
12252 Fix TLS access for -static -pthread.
12253 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12254 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12255 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12256
802e8e6d
PA
122572014-05-20 Pedro Alves <palves@redhat.com>
12258
12259 * linux-aarch64-low.c (aarch64_insert_point)
12260 (aarch64_remove_point): No longer check whether the type is
12261 supported here. Adjust to new interface.
12262 (the_low_target): Install aarch64_supports_z_point_type as
12263 supports_z_point_type method.
12264 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12265 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12266 instead of a Z packet char. Adjust.
12267 (arm_supports_z_point_type): New function.
12268 (arm_insert_point, arm_remove_point): Adjust to new interface.
12269 (the_low_target): Install arm_supports_z_point_type.
12270 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12271 (cris_insert_point, cris_remove_point): Adjust to new interface.
12272 Don't check whether the type is supported here.
12273 (the_low_target): Install cris_supports_z_point_type.
12274 * linux-low.c (linux_supports_z_point_type): New function.
12275 (linux_insert_point, linux_remove_point): Adjust to new interface.
12276 * linux-low.h (struct linux_target_ops) <insert_point,
12277 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12278 raw_breakpoint pointer parameter.
12279 <supports_z_point_type>: New method.
12280 * linux-mips-low.c (mips_supports_z_point_type): New function.
12281 (mips_insert_point, mips_remove_point): Adjust to new interface.
12282 Use mips_supports_z_point_type.
12283 (the_low_target): Install mips_supports_z_point_type.
12284 * linux-ppc-low.c (the_low_target): Install NULL as
12285 supports_z_point_type method.
12286 * linux-s390-low.c (the_low_target): Install NULL as
12287 supports_z_point_type method.
12288 * linux-sparc-low.c (the_low_target): Install NULL as
12289 supports_z_point_type method.
12290 * linux-x86-low.c (x86_supports_z_point_type): New function.
12291 (x86_insert_point): Adjust to new insert_point interface. Use
12292 insert_memory_breakpoint. Adjust to new
12293 i386_low_insert_watchpoint interface.
12294 (x86_remove_point): Adjust to remove_point interface. Use
12295 remove_memory_breakpoint. Adjust to new
12296 i386_low_remove_watchpoint interface.
12297 (the_low_target): Install x86_supports_z_point_type.
12298 * lynx-low.c (lynx_target_ops): Install NULL as
12299 supports_z_point_type callback.
12300 * nto-low.c (nto_supports_z_point_type): New.
12301 (nto_insert_point, nto_remove_point): Adjust to new interface.
12302 (nto_target_ops): Install nto_supports_z_point_type.
12303 * mem-break.c: Adjust intro comment.
12304 (struct raw_breakpoint) <raw_type, size>: New fields.
12305 <inserted>: Update comment.
12306 <shlib_disabled>: Delete field.
12307 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12308 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12309 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12310 (raw_bkpt_type_to_target_hw_bp_type): New function.
12311 (find_enabled_raw_code_breakpoint_at): New function.
12312 (find_raw_breakpoint_at): New type and size parameters. Use them.
12313 (insert_memory_breakpoint): New function, based off
12314 set_raw_breakpoint_at.
12315 (remove_memory_breakpoint): New function.
12316 (set_raw_breakpoint_at): Reimplement.
12317 (set_breakpoint): New, based on set_breakpoint_at.
12318 (set_breakpoint_at): Reimplement.
12319 (delete_raw_breakpoint): Go through the_target->remove_point
12320 instead of assuming memory breakpoints.
12321 (find_gdb_breakpoint_at): Delete.
12322 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12323 (find_gdb_breakpoint): New function.
12324 (set_gdb_breakpoint_at): Delete.
12325 (z_type_supported): New function.
12326 (set_gdb_breakpoint_1): New function, loosely based off
12327 set_gdb_breakpoint_at.
12328 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12329 (delete_gdb_breakpoint_at): Delete.
12330 (delete_gdb_breakpoint_1): New function, loosely based off
12331 delete_gdb_breakpoint_at.
12332 (delete_gdb_breakpoint): New function.
12333 (clear_gdb_breakpoint_conditions): Rename to ...
12334 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12335 breakpoint.
12336 (add_condition_to_breakpoint): Make static.
12337 (add_breakpoint_condition): Take a struct breakpoint pointer
12338 instead of an address. Adjust.
12339 (gdb_condition_true_at_breakpoint): Rename to ...
12340 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12341 z_type parameter.
12342 (gdb_condition_true_at_breakpoint): Reimplement.
12343 (add_breakpoint_commands): Take a struct breakpoint pointer
12344 instead of an address. Adjust.
12345 (gdb_no_commands_at_breakpoint): Rename to ...
12346 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12347 parameter. Return true if no breakpoint was found. Change debug
12348 output.
12349 (gdb_no_commands_at_breakpoint): Reimplement.
12350 (run_breakpoint_commands): Rename to ...
12351 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12352 and change return type to boolean.
12353 (run_breakpoint_commands): New function.
12354 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12355 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12356 breakpoint. Go through the_target->remove_point instead of
12357 assuming memory breakpoint.
12358 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12359 software and hardware breakpoints.
12360 (reinsert_raw_breakpoint): Go through the_target->insert_point
12361 instead of assuming memory breakpoint.
12362 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12363 software and hardware breakpoints.
12364 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12365 Check both software and hardware breakpoints.
12366 (validate_inserted_breakpoint): Assert the breakpoint is a
12367 software breakpoint. Set the inserted flag to -1 instead of
12368 setting shlib_disabled.
12369 (delete_disabled_breakpoints): Adjust.
12370 (validate_breakpoints): Only validate software breakpoints.
12371 Adjust to inserted flag change.
12372 (check_mem_read, check_mem_write): Skip breakpoint types other
12373 than software breakpoints. Adjust to inserted flag change.
12374 * mem-break.h (enum raw_bkpt_type): New enum.
12375 (raw_breakpoint, struct process_info): Forward declare.
12376 (Z_packet_to_target_hw_bp_type): Delete declaration.
12377 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12378 (set_gdb_breakpoint, delete_gdb_breakpoint)
12379 (clear_breakpoint_conditions): New declarations.
12380 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12381 (breakpoint_inserted_here): Update comment.
12382 (add_breakpoint_condition, add_breakpoint_commands): Replace
12383 address parameter with a breakpoint pointer parameter.
12384 (gdb_breakpoint_here): Update comment.
12385 (delete_gdb_breakpoint_at): Delete.
12386 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12387 * server.c (process_point_options): Take a struct breakpoint
12388 pointer instead of an address. Adjust.
12389 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12390 delete_gdb_breakpoint.
12391 * spu-low.c (spu_target_ops): Install NULL as
12392 supports_z_point_type method.
12393 * target.h: Include mem-break.h.
12394 (struct target_ops) <prepare_to_access_memory>: Update comment.
12395 <supports_z_point_type>: New field.
12396 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12397 instead of a char. Also take a raw breakpoint pointer.
12398 * win32-arm-low.c (the_low_target): Install NULL as
12399 supports_z_point_type.
12400 * win32-i386-low.c (i386_supports_z_point_type): New function.
12401 (i386_insert_point, i386_remove_point): Adjust to new interface.
12402 (the_low_target): Install i386_supports_z_point_type.
12403 * win32-low.c (win32_supports_z_point_type): New function.
12404 (win32_insert_point, win32_remove_point): Adjust to new interface.
12405 (win32_target_ops): Install win32_supports_z_point_type.
12406 * win32-low.h (struct win32_target_ops):
12407 <supports_z_point_type>: New method.
12408 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12409 instead of a char. Also take a raw breakpoint pointer.
12410
932539e3
PA
124112014-05-20 Pedro Alves <palves@redhat.com>
12412
12413 * mem-break.h: Include break-common.h.
12414 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12415 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12416 (Z_packet_to_target_hw_bp_type): New declaration.
12417 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12418 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12419 (Z_PACKET_ACCESS_WP): Delete macros.
12420 (Z_packet_to_hw_type): Delete function.
12421 * i386-low.h: Don't include break-common.h here.
12422 (Z_packet_to_hw_type): Delete declaration.
12423 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12424 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12425 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12426 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12427 * linux-aarch64-low.c: Don't include break-common.h here.
12428 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12429 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12430 (Z_packet_to_target_hw_bp_type): Delete function.
12431 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12432 function.
12433 (mips_insert_point, mips_remove_point): Use
12434 Z_packet_to_target_hw_bp_type.
12435
4ff0d3d8
PA
124362014-05-20 Pedro Alves <palves@redhat.com>
12437
12438 * linux-aarch64-low.c: Include break-common.h.
12439 (enum target_point_type): Delete.
12440 (Z_packet_to_point_type): Rename to ...
12441 (Z_packet_to_target_hw_bp_type): ... this, and return a
12442 target_hw_bp_type instead.
12443 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12444 instead of an enum target_point_type.
12445 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12446 breakpoint type.
12447 (aarch64_dr_state_insert_one_point)
12448 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12449 (aarch64_handle_aligned_watchpoint)
12450 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12451 Take an enum target_hw_bp_type instead of an enum
12452 target_point_type.
12453 (aarch64_supports_z_point_type): New function.
12454 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12455 use Z_packet_to_target_hw_bp_type.
12456
786dc519
JB
124572014-05-20 Joel Brobecker <brobecker@adacore.com>
12458
12459 * configure.ac: Only use -Werror by default when DEVELOPMENT
12460 is true.
12461 * configure: Regenerate.
12462
9e0aa64f
JK
124632014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12464
12465 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12466 * linux-x86-low.c (X86_64_USER_REGS): New.
12467 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12468
2b577b92
YQ
124692014-04-28 Yao Qi <yao@codesourcery.com>
12470
12471 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12472 name.
12473
94611da2
PA
124742014-04-25 Pedro Alves <palves@redhat.com>
12475
12476 PR server/16255
12477 * linux-low.c (linux_attach_fail_reason_string): New function.
12478 (linux_attach_lwp): Delete.
12479 (linux_attach_lwp_1): Rename to ...
12480 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12481 argument. Remove "initial" parameter. Return int instead of
12482 void. Don't error or warn here.
12483 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12484 failure to attach to the tgid. Call warning when failing to
12485 attach to an lwp.
12486 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12487 argument. Remove "initial" parameter. Return int instead of
12488 void. Don't error or warn here.
12489 (linux_attach_fail_reason_string): New declaration.
12490 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12491 interface change. Use linux_attach_fail_reason_string.
12492
01f9f808
MS
124932014-04-24 Michael Sturm <michael.sturm@mintel.com>
12494 Walfred Tedeschi <walfred.tedeschi@intel.com>
12495
12496 * Makefile.in: Added rules to handle new files
12497 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12498 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12499 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12500 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12501 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12502 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12503 x32-avx512-linux.o.
12504 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12505 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12506 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12507 i386/x32-avx512.xml.
12508 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12509 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12510 i386/x32-avx512-linux.xml.
12511 * i387-fp.c (num_avx512_k_registers): New constant for number
12512 of K registers.
12513 (num_avx512_zmmh_low_registers): New constant for number of
12514 lower ZMM registers (0-15).
12515 (num_avx512_zmmh_high_registers): New constant for number of
12516 higher ZMM registers (16-31).
12517 (num_avx512_ymmh_registers): New contant for number of higher
12518 YMM registers (ymm16-31 added by avx521 on x86_64).
12519 (num_avx512_xmm_registers): New constant for number of higher
12520 XMM registers (xmm16-31 added by AVX512 on x86_64).
12521 (struct i387_xsave): Add space for AVX512 registers.
12522 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12523 Add code to handle AVX512 registers.
12524 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12525 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12526 prototypei from generated file.
12527 (tdesc_amd64_avx512_linux): Likewise.
12528 (init_registers_x32_avx512_linux): Likewise.
12529 (tdesc_x32_avx512_linux): Likewise.
12530 (init_registers_i386_avx512_linux): Likewise.
12531 (tdesc_i386_avx512_linux): Likewise.
12532 (x86_64_regmap): Add AVX512 registers.
12533 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12534 mask.
12535 (initialize_low_arch): Add code to initialize AVX512 registers.
12536
51aa91f9
PA
125372014-04-23 Pedro Alves <palves@redhat.com>
12538
12539 * mem-break.c (find_gdb_breakpoint_at): Make static.
12540 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12541
a4165e94
PA
125422014-04-23 Pedro Alves <palves@redhat.com>
12543
12544 * i386-low.c: Don't include break-common.h here.
12545 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12546 prototype to take target_hw_bp_type as argument instead of a Z
12547 packet char.
12548 * i386-low.h: Include break-common.h here.
12549 (Z_packet_to_hw_type): Declare.
12550 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12551 prototypes.
12552 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12553 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12554 (x86_remove_point): Convert the packet number to a
12555 target_hw_bp_type before calling i386_low_remove_watchpoint.
12556 * win32-i386-low.c (i386_insert_point): Convert the packet number
12557 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12558 (i386_remove_point): Convert the packet number to a
12559 target_hw_bp_type before calling i386_low_remove_watchpoint.
12560
b8acf843
PA
125612014-04-23 Pedro Alves <palves@redhat.com>
12562
12563 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12564
d708bcd1
PA
125652014-04-10 Pedro Alves <palves@redhat.com>
12566
12567 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12568 Check if the condition or command is NULL before checking if the
12569 breakpoint is known. On success, return true.
12570 * mem-break.h (add_breakpoint_condition): Document return.
12571 (add_breakpoint_commands): Add describing comment.
12572 * server.c (skip_to_semicolon): New function.
12573 (process_point_options): Use it.
12574
2eec7d5b
PA
125752014-04-09 Pedro Alves <palves@redhat.com>
12576
12577 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12578 to lwpid_of.
12579
fa96cb38
PA
125802014-02-27 Pedro Alves <palves@redhat.com>
12581
12582 PR 12702
12583 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12584 macros.
12585 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12586 output.
12587 (last_thread_of_process_p): Take a PID argument instead of a
12588 thread pointer.
12589 (linux_wait_for_lwp): Delete.
12590 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12591 functions.
12592 (linux_low_filter_event): New function, party factored out from
12593 linux_wait_for_event.
12594 (linux_wait_for_event): Rename to ...
12595 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12596 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12597 sigsuspend. Check for zombie leaders.
12598 (linux_wait_for_event): Reimplement as wrapper around
12599 linux_wait_for_event_filtered.
12600 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12601 a normal or signal exit is seen, it's the whole process exiting.
12602 (wait_for_sigstop): No longer a for_each_inferior callback.
12603 Rewrite on top of linux_wait_for_event_filtered.
12604 (stop_all_lwps): Call wait_for_sigstop directly.
12605 * server.c (resume, handle_target_event): Handle
12606 TARGET_WAITKIND_NO_RESUMED.
12607
d763de10
JB
126082014-02-26 Joel Brobecker <brobecker@adacore.com>
12609
12610 * win32-low.c (psapi_get_dll_name,
12611 * win32_CreateToolhelp32Snapshot): Delete.
12612 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12613 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12614 Delete.
12615 (handle_load_dll): Add function description.
12616 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12617
850a0f76
JB
126182014-02-26 Joel Brobecker <brobecker@adacore.com>
12619
12620 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12621 Add comment.
12622 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12623 base address when calling win32_add_one_solib.
12624 (handle_load_dll): Delete local variable load_addr.
12625 Remove 0x1000 offset applied to DLL base address when calling
12626 win32_add_one_solib.
12627 (handle_unload_dll): Add comment.
12628
f25b3fc3
JB
126292014-02-26 Joel Brobecker <brobecker@adacore.com>
12630
12631 * win32-low.c (win32_add_all_dlls): Renames
12632 win32_ensure_ntdll_loaded. Rewrite function documentation.
12633 Adjust implementation to always load all DLLs.
12634 Add 0x1000 offset to DLL base address when calling
12635 win32_add_one_solib.
12636 (child_initialization_done): New static global.
12637 (do_initial_child_stuff): Set child_initialization_done to
12638 zero during child initialization, and 1 after. Replace call
12639 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12640 Add comment.
12641 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12642 (handle_unload_dll): Add function documentation.
12643 (get_child_debug_event): Ignore load and unload DLL events
12644 during child initialization.
12645
d86d4aaf
DE
126462014-02-20 Doug Evans <dje@google.com>
12647
3bc32da3 12648 Remove global all_lwps.
d86d4aaf
DE
12649 * inferiors.h (ptid_of): Move here from linux-low.h.
12650 (pid_of, lwpid_of): Ditto.
12651 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12652 parameter is a struct thread_info * now.
12653 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12654 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12655 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12656 directly.
12657 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12658 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12659 * linux-arm-low.c (update_registers_callback): Update, "entry"
12660 parameter is a struct thread_info * now.
12661 Fetch lwpid from current_inferior directly.
12662 (arm_insert_point): Pass &all_threads to find_inferior instead of
12663 &all_lwps.
12664 (arm_remove_point): Ditto.
12665 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12666 (arm_prepare_to_resume): Fetch pid from thread.
12667 (arm_read_description): Fetch lwpid from current_inferior directly.
12668 * linux-low.c (all_lwps): Delete.
12669 (delete_lwp): Delete call to remove_inferior.
12670 (handle_extended_wait): Fetch lwpid from thread.
12671 (add_lwp): Don't set lwp->entry.id. Remove call to
12672 add_inferior_to_list.
12673 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12674 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12675 (kill_one_lwp_callback): Ditto.
12676 (linux_kill): Don't dereference NULL pointer.
12677 Fetch ptid,lwpid from thread.
12678 (get_detach_signal): Fetch ptid from thread.
12679 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12680 Simplify call to regcache_invalidate_thread.
12681 (delete_lwp_callback): Update, "entry" parameter is a
12682 struct thread_info * now. Fetch pid from thread.
12683 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12684 (status_pending_p_callback): Update, "entry" parameter is a
12685 struct thread_info * now. Fetch ptid from thread.
12686 (find_lwp_pid): Update, "entry" parameter is a
12687 struct thread_info * now.
12688 (linux_wait_for_lwp): Fetch pid from thread.
12689 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12690 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12691 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12692 (dequeue_one_deferred_signal): Ditto.
12693 (cancel_breakpoint): Fetch ptid from current_inferior.
12694 (linux_wait_for_event): Pass &all_threads to find_inferior,
12695 not &all_lwps. Fetch ptid, lwpid from thread.
12696 (count_events_callback): Update, "entry" parameter is a
12697 struct thread_info * now.
12698 (select_singlestep_lwp_callback): Ditto.
12699 (select_event_lwp_callback): Ditto.
12700 (cancel_breakpoints_callback): Ditto.
12701 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12702 not &all_lwps.
12703 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12704 (unsuspend_one_lwp): Update, "entry" parameter is a
12705 struct thread_info * now.
12706 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12707 not &all_lwps.
12708 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12709 Fetch lwpid from thread, not lwp.
12710 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12711 Pass &all_threads to find_inferior, not &all_lwps.
12712 (send_sigstop): Fetch lwpid from thread, not lwp.
12713 (send_sigstop_callback): Update, "entry" parameter is a
12714 struct thread_info * now.
12715 (suspend_and_send_sigstop_callback): Ditto.
12716 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12717 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12718 struct thread_info * now.
12719 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12720 from thread, lwp.
12721 (lwp_running): Update, "entry" parameter is a
12722 struct thread_info * now.
12723 (stop_all_lwps): Fetch ptid from thread.
12724 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12725 (linux_resume_one_lwp): Fetch lwpid from thread.
12726 (linux_set_resume_request): Update, "entry" parameter is a
12727 struct thread_info * now. Fetch pid, lwpid from thread.
12728 (resume_status_pending_p): Update, "entry" parameter is a
12729 struct thread_info * now.
12730 (need_step_over_p): Ditto. Fetch lwpid from thread.
12731 (start_step_over): Fetch lwpid from thread.
12732 (linux_resume_one_thread): Update, "entry" parameter is a
12733 struct thread_info * now. Fetch lwpid from thread.
12734 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12735 (proceed_one_lwp): Update, "entry" parameter is a
12736 struct thread_info * now. Fetch lwpid from thread.
12737 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12738 struct thread_info * now.
12739 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12740 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12741 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12742 directly.
12743 (regsets_store_inferior_registers): Ditto.
12744 (fetch_register, store_register): Ditto.
12745 (linux_read_memory, linux_write_memory): Ditto.
12746 (linux_request_interrupt): Ditto.
12747 (linux_read_auxv): Ditto.
12748 (linux_xfer_siginfo): Ditto.
12749 (linux_qxfer_spu): Ditto.
12750 (linux_qxfer_libraries_svr4): Ditto.
12751 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12752 moved to inferiors.h.
12753 (get_lwp): Delete.
12754 (get_thread_lwp): Update.
12755 (struct lwp_info): Delete member "entry". Simplify comment for
12756 member "thread".
12757 (all_lwps): Delete.
12758 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12759 current_inferior directly.
12760 (update_watch_registers_callback): Update, "entry" parameter is a
12761 struct thread_info * now. Fetch pid from thread.
12762 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12763 (mips_insert_point): Fetch lwpid from current_inferior.
12764 Pass &all_threads to find_inferior, not &all_lwps.
12765 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12766 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12767 directly.
12768 (mips_stopped_data_address): Ditto.
12769 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12770 directly.
12771 * linux-tile-low.c (tile_arch_setup): Ditto.
12772 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12773 (update_debug_registers_callback): Update, "entry" parameter is a
12774 struct thread_info * now. Fetch pid from thread.
12775 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12776 Pass &all_threads to find_inferior, not &all_lwps.
12777 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12778 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12779 Pass &all_threads to find_inferior, not &all_lwps.
12780 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12781 (i386_dr_low_get_status): Ditto.
12782 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12783 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12784 (x86_linux_read_description): Ditto.
12785 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12786
3b8361aa
DE
127872014-02-20 Doug Evans <dje@google.com>
12788
12789 * inferiors.c (get_first_inferior): Fix buglet.
12790
f7667f0d
DE
127912014-02-19 Doug Evans <dje@google.com>
12792
12793 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12794 * inferiors.c (add_thread): Change result type to struct thread_info *.
12795 All callers updated.
12796 (add_lwp): Call add_thread here instead of in callers.
12797 All callers updated.
12798 * linux-low.h (get_lwp_thread): Rewrite.
12799 (struct lwp_info): New member "thread".
12800
b3312d80
DE
128012014-02-19 Doug Evans <dje@google.com>
12802
12803 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12804 All callers updated.
12805
ecc6f45c
DE
128062014-02-19 Doug Evans <dje@google.com>
12807
12808 * inferiors.c (add_thread): Fix whitespace.
12809
649ebbca
DE
128102014-02-19 Doug Evans <dje@google.com>
12811
12812 * dll.c (clear_dlls): Replace accessing list implemention details
12813 with API function.
12814 * gdbthread.h (get_first_thread): Declare.
12815 * inferiors.c (for_each_inferior_with_data): New function.
12816 (get_first_thread): New function.
12817 (find_thread_ptid): Simplify.
12818 (get_first_inferior): New function.
12819 (clear_list): Delete.
12820 (one_inferior_p): New function.
12821 (clear_inferior_list): New function.
12822 (clear_inferiors): Update.
12823 * inferiors.h (for_each_inferior_with_data): Declare.
12824 (clear_inferior_list): Declare.
12825 (one_inferior_p): Declare.
12826 (get_first_inferior): Declare.
12827 * linux-low.c (linux_wait_for_event): Replace accessing list
12828 implemention details with API function.
12829 * server.c (target_running): Ditto.
12830 (accumulate_file_name_length): New function.
12831 (emit_dll_description): New function.
12832 (handle_qxfer_libraries): Replace accessing list implemention
12833 details with API function.
12834 (handle_qxfer_threads_worker): New function.
12835 (handle_qxfer_threads_proper): Replace accessing list implemention
12836 details with API function.
12837 (handle_query): Ditto.
12838 (visit_actioned_threads_callback_ftype): New typedef.
12839 (visit_actioned_threads_data): New struct.
12840 (visit_actioned_threads): Rewrite to be find_inferior callback.
12841 (resume): Call find_inferior.
12842 (handle_status): Replace accessing list implemention
12843 details with API function.
12844 (process_serial_event): Replace accessing list implemention details
12845 with API function.
12846 * target.c (set_desired_inferior): Replace accessing list implemention
12847 details with API function.
12848 * tracepoint.c (same_process_p): New function.
12849 (gdb_agent_about_to_close): Replace accessing list implemention
12850 details with API function.
12851 * win32-low.c (child_delete_thread): Replace accessing list
12852 implemention details with API function.
12853 (match_dll_by_basename): New function.
12854 (dll_is_loaded_by_basename): New function.
12855 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12856 details call to dll_is_loaded_by_basename.
12857
80894984
DE
128582014-02-19 Doug Evans <dje@google.com>
12859
12860 * dll.h (struct dll_info): Add comment.
12861 * gdbthread.h (struct thread_info): Add comment.
12862 (current_ptid): Simplify.
12863 * inferiors.c (add_process): Update.
12864 (remove_process): Update.
12865 * inferiors.h (struct process_info): Rename member "head" to "entry".
12866 * linux-low.c (delete_lwp): Update.
12867 (add_lwp): Update.
12868 (last_thread_of_process_p): Update.
12869 (kill_one_lwp_callback, linux_kill): Update.
12870 (status_pending_p_callback): Update.
12871 (wait_for_sigstop): Update. Simplify read of ptid.
12872 (start_step_over): Update.
12873 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12874 (get_lwp_thread): Update.
12875 (struct lwp_info): Rename member "head" to "entry".
12876 * regcache.h (inferior_list_entry): Delete.
12877 * server.c (kill_inferior_callback): Update.
12878 (detach_or_kill_inferior_callback): Update.
12879 (print_started_pid): Update.
12880 (print_attached_pid): Update.
12881 (process_serial_event): Simplify read of ptid.
12882 * thread-db.c (thread_db_create_event): Update.
12883 (thread_db_get_tls_address): Update.
12884 * win32-low.c (current_inferior_ptid): Simplify.
12885
46917d26
TT
128862014-02-19 Tom Tromey <tromey@redhat.com>
12887
12888 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12889 argument.
12890 (target_supports_btrace): Update.
12891
0759a81e
YQ
128922014-02-14 Yao Qi <yao@codesourcery.com>
12893
12894 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12895 (rsp-low-ipa.o): New target.
12896
a7191e8b
TT
128972014-02-12 Tom Tromey <tromey@redhat.com>
12898
12899 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12900 convert_ascii_to_int.
12901 * regcache.c (registers_to_string): Likewise.
12902 * remote-utils.c (decode_M_packet): Likewise.
12903 * server.c (process_serial_event): Likewise.
12904
ff0e980e
TT
129052014-02-12 Tom Tromey <tromey@redhat.com>
12906
12907 * server.c (handle_query, handle_v_run): Use hex2bin, not
12908 unhexify.
12909 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12910
e9371aff
TT
129112014-02-12 Tom Tromey <tromey@redhat.com>
12912
12913 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12914 convert_int_to_ascii.
12915 * regcache.c (registers_to_string, collect_register_as_string):
12916 Likewise.
12917 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12918 Likewise.
12919 * server.c (process_serial_event): Likewise.
12920 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12921 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
12922
971dc0b8
TT
129232014-02-12 Tom Tromey <tromey@redhat.com>
12924
12925 * remote-utils.c (look_up_one_symbol, monitor_output): Use
12926 bin2hex, not hexify.
12927 * tracepoint.c (cmd_qtstatus): Likewise.
12928
0a822afb
TT
129292014-02-12 Tom Tromey <tromey@redhat.com>
12930
12931 * remote-utils.c (monitor_output): Pass explicit length to
12932 hexify.
12933
9c3d6531
TT
129342014-02-12 Tom Tromey <tromey@redhat.com>
12935
12936 * tracepoint.c: Include rsp-low.h.
12937 * server.c: Include rsp-low.h.
12938 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
12939 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
12940 declare.
12941 * remote-utils.c: Include rsp-low.h.
12942 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
12943 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
12944 (convert_int_to_ascii, convert_ascii_to_int): Move to
12945 common/rsp-low.c.
12946 * regcache.c: Include rsp-low.h.
12947 * ax.c: Include rsp-low.h.
12948 * Makefile.in (SFILES): Add common/rsp-low.c.
12949 (OBS): Add rsp-low.o.
12950 (rsp-low.o): New target.
12951
01fd3ea5
TT
129522014-02-12 Tom Tromey <tromey@redhat.com>
12953
12954 * utils.h (pulongest, plongest, phex_nz): Don't declare.
12955 Include print-utils.h.
12956 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
12957 (plongest, thirty_two, phex_nz): Remove.
12958 * Makefile.in (SFILES): Add common/print-utils.c.
12959 (OBS): Add print-utils.o.
12960 (print-utils-ipa.o): New target.
12961 (print-utils.o): New target.
12962 (IPA_OBJS): Add print-utils-ipa.o.
12963
e99dc820
TT
129642014-02-06 Tom Tromey <tromey@redhat.com>
12965
12966 * Makefile.in (SFILES): Fix indentation.
12967
ee1e2d4f
DE
129682014-02-05 Doug Evans <dje@google.com>
12969
12970 * linux-low.c (linux_wait_for_event): Improve comment.
12971 (linux_wait_1): Keep current_inferior in sync with event_child.
12972
f5a02773
DE
129732014-01-22 Doug Evans <dje@google.com>
12974
12975 * gdbthread.h (gdb_id_to_thread): Delete, unused.
12976
87ce2a04
DE
129772014-01-22 Doug Evans <dje@google.com>
12978
12979 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
12980 * configure: Regenerate.
12981 * config.in: Regenerate.
12982 * Makefile.in (SFILES): Add debug.c.
12983 (OBS): Add debug.o.
12984 * debug.c: New file.
12985 * debug.h: New file.
12986 * linux-aarch64-low.c (*): Update all debugging printfs to use
12987 debug_printf instead of fprintf.
12988 * linux-arm-low.c (*): Ditto.
12989 * linux-cris-low.c (*): Ditto.
12990 * linux-crisv32-low.c (*): Ditto.
12991 * linux-m32r-low.c (*): Ditto.
12992 * linux-sparc-low.c (*): Ditto.
12993 * linux-x86.c (*): Ditto.
12994 * linux-low.c (*): Ditto.
12995 (linux_wait_1): Add calls to debug_enter, debug_exit.
12996 (linux_wait): Remove redundant debugging printf.
12997 (stop_all_lwps): Add calls to debug_enter, debug_exit.
12998 (linux_resume, unstop_all_lwps): Ditto.
12999 * mem-break.c (*): Update all debugging printfs to use
13000 debug_printf instead of fprintf.
13001 * remote-utils.c (*): Ditto.
13002 * thread-db.c (*): Ditto.
13003 * server.c #include <ctype.h>, "gdb_vecs.h".
13004 (debug_threads): Moved to debug.c.
13005 (*): Update all debugging printfs to use debug_printf instead of
13006 fprintf.
13007 (start_inferior): Replace call to fflush with call to debug_flush.
13008 (monitor_show_help): Mention set debug-format.
13009 (parse_debug_format_options): New function.
13010 (handle_monitor_command): Handle "monitor set debug-format".
13011 (gdbserver_usage): Mention --debug-format.
13012 (main): Parse --debug-format.
13013 * server.h (debug_threads): Declaration moved to debug.h.
13014 #include "debug.h".
13015 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13016 trace_debug_1 that uses debug_printf.
13017 (tracepoint_look_up_symbols): Update all debugging printfs to use
13018 debug_printf instead of fprintf.
13019
e671835b
BS
130202014-01-20 Baruch Siach <baruch@tkos.co.il>
13021
13022 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13023 sys/ptrace.h.
13024
b5737fa9
PA
130252014-01-17 Pedro Alves <palves@redhat.com>
13026
ea38d2a9 13027 PR build/16445
c7faa97a
PA
13028 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13029 defined after including gdb_proc_service.h.
b5737fa9 13030
40ed484e
DE
130312014-01-16 Doug Evans <dje@google.com>
13032
13033 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13034 (match_dll): Use it.
13035
969c39fb
MM
130362014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13037
13038 * target.h (target_ops) <read_btrace>: Change parameters and
13039 return type to allow error reporting.
13040 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13041 trace reading errors on.
13042 * linux-low.c (linux_low_read_btrace): Pass trace reading
13043 errors on.
13044 (linux_low_disable_btrace): New.
13045
ab7f45ba
DE
130462014-01-15 Doug Evans <dje@google.com>
13047
13048 * inferiors.c (thread_id_to_gdb_id): Delete.
13049 * inferiors.h (thread_id_to_gdb_id): Delete.
13050
66af0f44
EZ
130512014-01-13 Eli Zaretskii <eliz@gnu.org>
13052
13053 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13054 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13055 versions.
13056
9939e131
PA
130572014-01-08 Pedro Alves <palves@redhat.com>
13058
13059 * server.c (handle_status): Don't discard previous queued stop
13060 replies or thread's pending status here.
13061 (main) <disconnection>: Do it here instead.
13062
b7ea362b
PA
130632014-01-08 Pedro Alves <palves@redhat.com>
13064
13065 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13066 * server.c (visit_actioned_threads, handle_pending_status): New
13067 function.
13068 (handle_v_cont): Factor out parts to ...
13069 (resume): ... this new function. If in all-stop, and a thread
13070 being resumed has a pending status, report it without actually
13071 resuming.
13072 (myresume): Adjust to use the new 'resume' function.
13073 (clear_pending_status_callback, set_pending_status_callback)
13074 (find_status_pending_thread_callback): New functions.
13075 (handle_status): Handle the case of multiple threads having
13076 interesting statuses to report. Report threads' real last signal
13077 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13078 with an interesting thread to report the status for, instead of
13079 always reporting the status of the first thread.
13080
28498c42
JB
130812014-01-01 Joel Brobecker <brobecker@adacore.com>
13082
13083 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13084 * gdbreplay.c (gdbreplay_version): Likewise.
13085
f45c82da
YZ
130862013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13087
13088 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13089 iov.iov_len with the real length in use.
13090
379a5e2d
JB
130912013-12-13 Joel Brobecker <brobecker@adacore.com>
13092
13093 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13094 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13095 for all targets that use win32-low.c.
13096 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13097 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13098
4210d83e
PA
130992013-12-13 Pedro Alves <palves@redhat.com>
13100
13101 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13102 if equal to TARGET_WAITKIND_LOADED.
13103 * win32-low.c (cached_status): New static global.
13104 (win32_wait): Add declaration.
13105 (do_initial_child_stuff): Flush all initial pending debug events
13106 up to the initial breakpoint.
13107 (win32_wait): If CACHED_STATUS was set, return that instead
13108 of doing a real wait. Remove the code resuming the execution
13109 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13110 during the initial phase. Also remove the code changing
13111 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13112 TARGET_WAITKIND_STOPPED.
13113
e7f0d979
YQ
131142013-12-11 Yao Qi <yao@codesourcery.com>
13115
13116 * notif.c (handle_notif_ack): Return 0 if no notification
13117 matches.
13118
ebcf782c
DE
131192013-11-20 Doug Evans <dje@google.com>
13120
13121 * linux-low.c (linux_set_resume_request): Fix comment.
13122
20ad9378
DE
131232013-11-20 Doug Evans <dje@google.com>
13124
13125 * linux-low.c (resume_status_pending_p): Tweak comment.
13126
a196ebeb
WT
131272013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13128
13129 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13130 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13131 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13132 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13133 (srv_amd64_regobj): Add amd64-mpx.o.
13134 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13135 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13136 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13137 * i387-fp.c (num_pl_bnd_register) Added constant.
13138 (num_pl_bnd_cfg_registers) Added constant.
13139 (struct i387_xsave) Added reserved area and MPX fields.
13140 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13141 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13142 function.
13143 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13144 (init_registers_amd64_mpx_linux): Declare new function.
13145 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13146 (x86_64_regmap): Add MPX registers.
13147 (x86_linux_read_description): Add MPX case.
13148 (initialize_low_arch): Initialize MPX targets.
13149
0080a2f6
TT
131502013-11-18 Tom Tromey <tromey@redhat.com>
13151
13152 * configure: Rebuild.
13153 * configure.ac: Don't check for stdlib.h.
13154 * gdbreplay.c: Unconditionally include stdlib.h.
13155
2978b111
TT
131562013-11-18 Tom Tromey <tromey@redhat.com>
13157
13158 * config.in: Rebuild.
13159 * configure: Rebuild.
13160 * configure.ac: Don't use AC_HEADER_DIRENT.
13161
a3d08894
TT
131622013-11-18 Tom Tromey <tromey@redhat.com>
13163
13164 * server.h: Don't check HAVE_STRING_H.
13165 * gdbreplay.c: Don't check HAVE_STRING_H.
13166 * configure: Rebuild.
13167
0a5dd17d
TT
131682013-11-18 Tom Tromey <tromey@redhat.com>
13169
13170 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13171 LIBGNU.
13172
1bd2f0ba
TT
131732013-11-08 Tom Tromey <tromey@redhat.com>
13174
13175 * configure, config.in: Rebuild.
13176 * configure.ac: Remove unused configury.
13177
3266f10b
TT
131782013-11-08 Tom Tromey <tromey@redhat.com>
13179
13180 * acinclude.m4: Include common.m4, codeset.m4.
13181 * configure, config.in: Rebuild.
13182 * configure.ac: Use GDB_AC_COMMON.
13183
6682d959
AA
131842013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13185
13186 * linux-s390-low.c (HWCAP_S390_TE): New define.
13187 (s390_arch_setup): Consider the TE field in the HWCAP for
13188 determining 'have_regset_tdb'.
13189
fd0a4d76
SDJ
131902013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13191
13192 PR gdb/16014
13193 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13194 call to sizeof.
13195
1a3d890b
PA
131962013-10-02 Pedro Alves <palves@redhat.com>
13197
13198 * server.c (process_serial_event): Don't output "GDBserver
13199 exiting" if GDB is connected through stdio.
13200 * target.c (mywait): Likewise, be silent if GDB is connected
13201 through stdio.
13202
97ad4581
JB
132032013-10-01 Joel Brobecker <brobecker@adacore.com>
13204
13205 * lynx-low.c (lynx_add_threads_after_attach): New function.
13206 (lynx_attach): Remove call to add_thread. Add call to
13207 lynx_add_threads_after_attach instead.
13208
5b4e221c
MF
132092013-09-28 Mike Frysinger <vapier@gentoo.org>
13210
13211 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13212 * config.in, configure: Regenerated.
13213
ee47b2f8
YQ
132142013-09-18 Yao Qi <yao@codesourcery.com>
13215
13216 PR server/15959
13217 * server.c (start_inferior): Clear 'resume_info'.
13218
d6707650 132192013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13220
d6707650
JW
13221 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13222 for each register.
13223
9243dd0e 132242013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13225
9243dd0e
JW
13226 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13227 linux-tile-low.o to srv_tgtobj.
13228
c623a6ef
WN
132292013-09-16 Will Newton <will.newton@linaro.org>
13230
13231 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13232 out regs.
13233
fb71d39e
PA
132342013-09-06 Pedro Alves <palves@redhat.com>
13235
13236 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13237 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13238 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13239 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13240 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13241 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13242
8e7e9910
PA
132432013-09-06 Pedro Alves <palves@redhat.com>
13244
13245 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13246 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13247
7c3a12ca
PA
132482013-09-06 Pedro Alves <palves@redhat.com>
13249
13250 * linux-amd64-ipa.c: Include tracepoint.h.
13251 * linux-i386-ipa.c: Include tracepoint.h.
13252
8eb3d7b6
RW
132532013-09-06 Ricard Wanderlof <ricardw@axis.com>
13254
13255 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13256 (ps_get_thread_area): New function.
13257
eddddb9d
RW
132582013-09-06 Ricard Wanderlof <ricardw@axis.com>
13259
13260 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13261 (initialize_low_arch): Call init_registers_crisv32 rather than
13262 init_register_crisv32.
13263
533b0600
PA
132642013-09-05 Pedro Alves <palves@redhat.com>
13265
13266 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13267 to ...
13268 * hostio.h: ... this new file.
13269 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13270 win32-low.c: Include hostio.h.
13271
0ce3d3b5
PA
132722013-09-05 Pedro Alves <palves@redhat.com>
13273
13274 * server.h (gdb_client_data, handler_func, callback_handler_func)
13275 (delete_file_handler, add_file_handler, append_callback_event)
13276 (delete_callback_event, start_event_loop, initialize_event_loop):
13277 Move to event-loop.h and include it.
13278 * event-loop.h: New file.
13279
799cdc37
PA
132802013-09-05 Pedro Alves <palves@redhat.com>
13281
13282 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13283 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13284 (loaded_dll, unloaded_dll): Move to ...
13285 * dll.h: ... this new file.
13286 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13287
6a6bbd9d
PA
132882013-09-05 Pedro Alves <palves@redhat.com>
13289
13290 * server.h (current_process, get_thread_process, all_processes)
13291 (add_inferior_to_list, for_each_inferior, current_inferior)
13292 (remove_inferior, add_process, remove_process, find_process_pid)
13293 (have_started_inferiors_p, have_attached_inferiors_p)
13294 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13295 (clear_inferiors, find_inferior, find_inferior_id)
13296 (inferior_target_data, set_inferior_target_data)
13297 (inferior_regcache_data, set_inferior_regcache_data): Move to
13298 inferiors.h, and include it.
13299 * inferiors.h: New file.
13300
f699aaba
PA
133012013-09-05 Pedro Alves <palves@redhat.com>
13302
13303 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13304 Move ...
72f4393d 13305 * ax.h: ... here.
f699aaba 13306
c144c7a0
PA
133072013-09-05 Pedro Alves <palves@redhat.com>
13308
13309 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13310 tracepoint.h.
13311 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13312 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13313 (handle_tracepoint_general_set, handle_tracepoint_query)
13314 (tracepoint_finished_step, tracepoint_was_hit)
13315 (release_while_stepping_state_list, current_traceframe)
13316 (in_readonly_region, traceframe_read_mem)
13317 (fetch_traceframe_registers, traceframe_read_sdata)
13318 (traceframe_read_info, struct fast_tpoint_collect_status)
13319 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13320 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13321 (supply_fast_tracepoint_registers)
13322 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13323 (ipa_tdesc, claim_trampoline_space)
13324 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13325 (agent_mem_read, agent_get_trace_state_variable_value)
13326 (agent_set_trace_state_variable_value, agent_tsv_read)
13327 (agent_mem_read_string, get_raw_reg_func_addr)
13328 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13329 * tracepoint.h: ... this new file.
13330
ff42e6ab
PA
133312013-09-05 Pedro Alves <palves@redhat.com>
13332
13333 * server.h (perror_with_name, error, fatal, warning, paddress)
13334 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13335 include it.
13336 * utils.h: New file.
13337
541af0f4
PA
133382013-09-05 Pedro Alves <palves@redhat.com>
13339
13340 * server.h (remote_debug, noack_mode, transport_is_reliable)
13341 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13342 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13343 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13344 (write_enn, initialize_async_io, enable_async_io)
13345 (disable_async_io, check_remote_input_interrupt_request)
13346 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13347 (dead_thread_notify, prepare_resume_reply)
13348 (decode_address_to_semicolon, decode_address, decode_m_packet)
13349 (decode_M_packet, decode_X_packet, decode_xfer_write)
13350 (decode_search_memory_packet, unhexify, hexify)
13351 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13352 (look_up_one_symbol, relocate_instruction)
13353 (monitor_output): Move to remote-utils.h, and include it.
13354 * remote-utils.h: New file.
13355
eebdf26b
PA
133562013-09-05 Pedro Alves <palves@redhat.com>
13357
13358 * server.h (_): Delete.
13359
3aafd2ff
PA
133602013-09-02 Pedro Alves <palves@redhat.com>
13361
13362 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13363 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13364 allocated.
13365 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13366
cee83bcb
PM
133672013-09-02 Pierre Muller <muller@sourceware.org>
13368
13369 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13370 or WriteProcessMemory complete successfully and handle
13371 ERROR_PARTIAL_COPY error.
13372
9a13b2fa
PA
133732013-09-02 Pedro Alves <palves@redhat.com>
13374
13375 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13376 error instead of EIO.
13377
602e3198
JK
133782013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13379
13380 PR server/15604
13381 * linux-low.c: Include filestuff.h.
13382 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13383 * lynx-low.c: Include filestuff.h.
13384 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13385 * server.c: Include filestuff.h.
13386 (main): Call notice_open_fds.
13387 * spu-low.c: Include filestuff.h.
13388 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13389
96d7229d
LM
133902013-08-22 Luis Machado <lgustavo@codesourcery.com>
13391
13392 * Makefile.in: Explain why ../target and ../nat are not
13393 listed as include file search paths.
13394 (linux-waitpid.o): New object file rule.
13395 * configure.srv (srv_native_linux_obj): New variable.
13396 Replace all occurrences of linux native object files with
13397 $srv_native_linux_obj.
13398 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13399 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13400 (linux_enable_event_reporting): Remove declaration.
13401 (my_waitpid): Moved to common/linux-waitpid.c.
13402 (linux_wait_for_event): Pass ptid when calling
13403 linux_enable_event_reporting.
13404 (linux_supports_tracefork_flag): Remove.
13405 (linux_enable_event_reporting): Likewise.
13406 (linux_tracefork_grandchild): Remove.
13407 (STACK_SIZE): Moved to common/linux-ptrace.c.
13408 (linux_tracefork_child): Remove.
13409 (linux_test_for_tracefork): Remove.
13410 (linux_look_up_symbols): Call linux_supports_traceclone.
13411 (initialize_low): Remove call to linux_test_for_tracefork.
13412 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13413 common/linux-ptrace.h.
13414 (PTRACE_TYPE_ARG4): Likewise.
13415 Include linux-ptrace.h.
13416
32940073
PA
134172013-08-21 Pedro Alves <palves@redhat.com>
13418
13419 * config.in: Renegerate.
13420
33b60d58 134212013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 13422
33b60d58
LM
13423 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13424 (SFILES): Remove $(srcdir)/common/target-common.c and
13425 add $(srcdir)/target/waitstatus.c.
13426 (OBS): Remove target-common.o and add waitstatus.o.
13427 (server_h): Remove $(srcdir)/../common/target-common.h and
13428 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13429 and $(srcdir)/../target/waitstatus.h.
13430 (target-common.o): Remove.
13431 (waitstatus.o): New target object file.
13432 * target.h: Do not include target-common.h and
13433 include target/resume.h, target/wait.h and
13434 target/waitstatus.h.
13435
b8e1b30e
LM
134362013-08-13 Luis Machado <lgustavo@codesourcery.com>
13437
13438 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13439 to PTRACE_TYPE_ARG3.
13440 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13441 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13442 PTRACE_TYPE_ARG4.
13443 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13444 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13445
7a60ad40
YQ
134462013-07-27 Jie Zhang <jie@codesourcery.com>
13447 Daniel Jacobowitz <dan@codesourcery.com>
13448 Yao Qi <yao@codesourcery.com>
13449
13450 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13451 (mips-linux-watch.o): New rule.
13452 (mips_linux_watch_h): New variable.
13453 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13454 srv_tgtobj.
13455 * linux-mips-low.c: Include mips-linux-watch.h.
13456 (struct arch_process_info, struct arch_lwp_info): New.
13457 (update_watch_registers_callback): New function.
13458 (mips_linux_new_process, mips_linux_new_thread) New functions.
13459 (mips_linux_prepare_to_resume, mips_insert_point): New
13460 functions.
13461 (mips_remove_point, mips_stopped_by_watchpoint): New
13462 functions.
13463 (rsp_bp_type_to_target_hw_bp_type): New function.
13464 (mips_stopped_data_address): New function.
13465 (the_low_target): Add watchpoint support functions.
13466
de6f69ad
YQ
134672013-07-27 Yao Qi <yao@codesourcery.com>
13468
13469 * i386-low.c: Include break-common.h.
13470 (enum target_hw_bp_type): Remove.
13471
3360c0bf
LM
134722013-07-24 Luis Machado <lgustavo@codesourcery.com>
13473
13474 * Makefile.in (SFILES): /common/target-common.c.
13475 (OBS): Add target-common.o.
13476 (server_h): Add $(srcdir)/../common/target-common.h.
13477 (target-common.o): New target.
13478 * server.c (queue_stop_reply_callback): Free
13479 status string after use.
13480 * target.c (target_waitstatus_to_string): Remove.
13481 * target.h: Include target-common.h.
13482 (resume_kind): Likewise.
13483 (target_waitkind): Likewise.
13484 (target_waitstatus): Likewise.
13485 (TARGET_WNOHANG): Likewise.
13486
bd885420
YQ
134872013-07-04 Yao Qi <yao@codesourcery.com>
13488
13489 * Makefile.in (host_alias): Use @host_noncanonical@.
13490 (target_alias): Use @target_noncanonical@.
13491 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13492 ACX_NONCANONICAL_HOST.
13493 * configure: Regenerated.
13494
13495 Revert:
13496 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13497
13498 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13499 * configure: Rebuild.
13500 * Makefile.in (version_host, version_target): Get from configure.
13501 (version.c): Use $(version_host) and $(version_target).
13502
17ef446e
PA
135032013-07-03 Pedro Alves <palves@redhat.com>
13504
13505 * Makefile.in (config.status): Depend on development.sh.
13506 * acinclude.m4: Include libmcheck.m4.
13507 * configure: Regenerate.
13508
7a9a7487
MG
135092013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13510
13511 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13512 attribute inside the parentheses.
13513 (winapi_DebugSetProcessKillOnExit): Ditto.
13514 (winapi_DebugBreakProcess): Ditto.
13515 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 13516
49b64de6
MG
135172013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13518
13519 * notif.h (notif_event): Add a dummy member to avoid compiler
13520 errors.
13521
d5749ee7
PA
135222013-07-01 Pedro Alves <palves@redhat.com>
13523
13524 * hostio.c (HOSTIO_PATH_MAX): Define.
13525 (require_filename, handle_open, handle_unlink, handle_readlink):
13526 Use it.
13527
d8d2a3ee
PA
135282013-07-01 Pedro Alves <palves@redhat.com>
13529
13530 * server.h: Include "pathmax.h".
13531 * linux-low.c: Don't include sys/param.h.
13532 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13533 MAXPATHLEN.
13534 * win32-low.c: Don't include sys/param.h.
13535 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13536
bc7dea8d
PA
135372013-07-01 Pedro Alves <palves@redhat.com>
13538
13539 * event-loop.c: Don't check HAVE_UNISTD_H before including
13540 <unistd.h>.
13541 * gdbreplay.c: Likewise.
13542 * remote-utils.c: Likewise.
13543 * server.c: Likewise.
13544 * configure.ac: Don't check for unistd.h.
13545 * configure: Regenerate.
13546
d6c2da54
TT
135472013-06-28 Tom Tromey <tromey@redhat.com>
13548
13549 * Makefile.in (version.c): Use version.in, not
13550 common/version.in.
13551
257b6bec
MG
135522013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13553
13554 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13555 * configure: Rebuild.
13556 * Makefile.in (version_host, version_target): Get from configure.
13557 (version.c): Use $(version_host) and $(version_target).
13558
86ebe149
DK
135592013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13560
13561 Fix trace-status to output user name without trailing colon.
13562 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13563
f30aa5af
DK
135642013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13565
13566 Fix trace-status to output proper start-time and stop-time.
13567 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13568 output start time and stop time in hex as gdb expects.
13569
28a93511
YQ
135702013-06-26 Pedro Alves <pedro@codesourcery.com>
13571
13572 * tracepoint.c (build_traceframe_info_xml): Output trace state
13573 variables present in the trace buffer.
13574
01208463
TT
135752013-06-24 Tom Tromey <tromey@redhat.com>
13576
13577 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13578 create-version.sh.
13579 (version.o): Remove.
13580 * gdbreplay.c: Include version.h.
13581 (version, host_name): Don't declare.
13582 * server.h: Include version.h.
13583 (version, host_name): Don't declare.
13584
760256f9
PA
135852013-06-12 Pedro Alves <palves@redhat.com>
13586
13587 * linux-x86-low.c (linux_is_elf64): Delete global.
13588 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13589 with local linux_pid_exe_is_elf_64_file use.
13590
030031ee
PA
135912013-06-11 Pedro Alves <palves@redhat.com>
13592
13593 * linux-low.c (regset_disabled, disable_regset): New functions.
13594 (regsets_fetch_inferior_registers)
13595 (regsets_store_inferior_registers): Use them.
13596 (initialize_regsets_info); Don't allocate the disabled_regsets
13597 array here.
13598 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13599 comment.
13600
5da6eb0a
PA
136012013-06-11 Pedro Alves <palves@redhat.com>
13602
13603 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13604 xmalloc.
13605
7e5aaa09
PA
136062013-06-11 Pedro Alves <palves@redhat.com>
13607
13608 * linux-x86-low.c (initialize_low_arch): Call
13609 init_registers_x32_avx_linux.
13610
d878444c
JK
136112013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13612
13613 Fix compatibility with Android Bionic.
13614 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13615 it is not empty.
13616
3aee8918
PA
136172013-06-07 Pedro Alves <palves@redhat.com>
13618
5f2b57b5 13619 PR server/14823
3aee8918
PA
13620 * Makefile.in (OBS): Add tdesc.o.
13621 (IPA_OBJS): Add tdesc-ipa.o.
13622 (tdesc-ipa.o): New rule.
13623 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13624 interface.
13625 * linux-low.c (new_inferior): Delete.
13626 (disabled_regsets, num_regsets): Delete.
13627 (linux_add_process): Adjust to set the new per-process
13628 new_inferior flag.
13629 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13630 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13631 was a stop. When calling arch_setup, switch the current inferior
13632 to the thread that got an event.
13633 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13634 (regsets_fetch_inferior_registers)
13635 (regsets_store_inferior_registers): New regsets_info parameter.
13636 Adjust to use it.
13637 (linux_register_in_regsets): New regs_info parameter. Adjust to
13638 use it.
13639 (register_addr, fetch_register, store_register): New usrregs_info
13640 parameter. Adjust to use it.
13641 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13642 parameter regs_info. Adjust to use it.
13643 (linux_fetch_registers): Get the current inferior's regs_info, and
13644 adjust to use it.
13645 (linux_store_registers): Ditto.
13646 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13647 (initialize_low): Don't initialize the target_regsets here. Call
13648 initialize_low_arch.
13649 * linux-low.h (target_regsets): Delete declaration.
13650 (struct regsets_info): New.
13651 (struct usrregs_info): New.
13652 (struct regs_info): New.
13653 (struct process_info_private) <new_inferior>: New field.
13654 (struct linux_target_ops): Delete the num_regs, regmap, and
13655 regset_bitmap fields. New field regs_info.
13656 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13657 * i387-fp.c (num_xmm_registers): Delete.
13658 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13659 calls to new interface.
13660 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13661 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13662 Infer the number of xmm registers from the regcache's target
13663 description.
13664 * i387-fp.h (num_xmm_registers): Delete.
13665 * inferiors.c (add_thread): Don't install the thread's regcache
13666 here.
13667 * proc-service.c (gregset_info): Fetch the current inferior's
13668 regs_info. Adjust to use it.
13669 * regcache.c: Include tdesc.h.
13670 (register_bytes, reg_defs, num_registers)
13671 (gdbserver_expedite_regs): Delete.
13672 (get_thread_regcache): If the thread doesn't have a regcache yet,
13673 create one, instead of aborting gdbserver.
13674 (regcache_invalidate_one): Rename to ...
13675 (regcache_invalidate_thread): ... this.
13676 (regcache_invalidate_one): New.
13677 (regcache_invalidate): Only invalidate registers of the current
13678 process.
13679 (init_register_cache): Add target_desc parameter, and use it.
13680 (new_register_cache): Ditto. Assert the target description has a
13681 non zero registers_size.
13682 (regcache_cpy): Add assertions. Adjust.
13683 (realloc_register_cache, set_register_cache): Delete.
13684 (registers_to_string, registers_from_string): Adjust.
13685 (find_register_by_name, find_regno, find_register_by_number)
13686 (register_cache_size): Add target_desc parameter, and use it.
13687 (free_register_cache_thread, free_register_cache_thread_one)
13688 (regcache_release, register_cache_size): New.
13689 (register_size): Add target_desc parameter, and use it.
13690 (register_data, supply_register, supply_register_zeroed)
13691 (supply_regblock, supply_register_by_name, collect_register)
13692 (collect_register_as_string, collect_register_by_name): Adjust.
13693 * regcache.h (struct target_desc): Forward declare.
13694 (struct regcache) <tdesc>: New field.
13695 (init_register_cache, new_register_cache): Add target_desc
13696 parameter.
13697 (regcache_invalidate_thread): Declare.
13698 (regcache_invalidate_one): Delete declaration.
13699 (regcache_release): Declare.
13700 (find_register_by_number, register_cache_size, register_size)
13701 (find_regno): Add target_desc parameter.
13702 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13703 declarations.
13704 * remote-utils.c: Include tdesc.h.
13705 (outreg, prepare_resume_reply): Adjust.
13706 * server.c: Include tdesc.h.
13707 (gdbserver_xmltarget): Delete declaration.
13708 (get_features_xml, process_serial_event): Adjust.
13709 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13710 declare.
13711 (struct process_info) <tdesc>: New field.
13712 (ipa_tdesc): Declare.
13713 * tdesc.c: New file.
13714 * tdesc.h: New file.
13715 * tracepoint.c: Include tdesc.h.
13716 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13717 (get_context_regcache): Adjust to pass ipa_tdesc down.
13718 (do_action_at_tracepoint): Adjust to get the register cache size
13719 from the context regcache's description.
13720 (traceframe_walk_blocks): Adjust to get the register cache size
13721 from the current trace frame's description.
13722 (traceframe_get_pc): Adjust to get current trace frame's
13723 description and pass it down.
13724 (gdb_collect): Adjust to get the register cache size from the
13725 IPA's description.
13726 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13727 (gdbserver_xmltarget): Delete.
13728 (initialize_low_tracepoint): Set the ipa's target description.
13729 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13730 (initialize_low_tracepoint): Set the ipa's target description.
13731 * linux-x86-low.c: Include tdesc.h.
13732 [__x86_64__] (is_64bit_tdesc): New.
13733 (ps_get_thread_area, x86_get_thread_area): Use it.
13734 (i386_cannot_store_register): Rename to ...
13735 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13736 (i386_cannot_fetch_register): Rename to ...
13737 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13738 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13739 to new interface.
13740 (target_regsets): Rename to ...
13741 (x86_regsets): ... this.
13742 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13743 interface.
13744 (x86_siginfo_fixup): Use is_64bit_tdesc.
13745 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13746 (tdesc_x32_avx_linux, tdesc_x32_linux)
13747 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13748 Declare.
13749 (x86_linux_update_xmltarget): Delete.
13750 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13751 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13752 (AMD64_LINUX_USER64_CS): New.
13753 (x86_linux_read_description): New, based on
13754 x86_linux_update_xmltarget.
13755 (same_process_callback): New.
13756 (x86_arch_setup_process_callback): New.
13757 (x86_linux_update_xmltarget): New.
13758 (x86_regsets_info): New.
13759 (amd64_linux_regs_info): New.
13760 (i386_linux_usrregs_info): New.
13761 (i386_linux_regs_info): New.
13762 (x86_linux_regs_info): New.
13763 (x86_arch_setup): Reimplement.
13764 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13765 (x86_emit_ops): Ditto.
13766 (the_low_target): Adjust. Install x86_linux_regs_info,
13767 x86_cannot_fetch_register, and x86_cannot_store_register.
13768 (initialize_low_arch): New.
13769 * linux-ia64-low.c (tdesc_ia64): Declare.
13770 (ia64_fetch_register): Adjust.
13771 (ia64_usrregs_info, regs_info): New globals.
13772 (ia64_regs_info): New function.
13773 (the_low_target): Adjust.
13774 (initialize_low_arch): New function.
13775 * linux-sparc-low.c (tdesc_sparc64): Declare.
13776 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13777 Adjust.
13778 (sparc_arch_setup): New function.
13779 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13780 (the_low_target): Adjust.
13781 (initialize_low_arch): New function.
13782 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13783 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13784 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13785 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13786 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13787 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13788 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13789 (tdesc_powerpc_isa205_vsx64l): Declare.
13790 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13791 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13792 (ppc_set_pc, ppc_get_hwcap): Adjust.
13793 (ppc_usrregs_info): Forward declare.
13794 (!__powerpc64__) ppc_regmap_adjusted: New global.
13795 (ppc_arch_setup): Adjust to the current process'es target
13796 description.
13797 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13798 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13799 (ppc_store_evrregset): Adjust.
13800 (target_regsets): Rename to ...
13801 (ppc_regsets): ... this, and make static.
13802 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13803 (ppc_regs_info): New function.
13804 (the_low_target): Adjust.
13805 (initialize_low_arch): New function.
13806 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13807 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13808 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13809 (tdesc_s390x_linux64v2): Declare.
13810 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13811 (s390_fill_gregset, s390_store_last_break): Adjust.
13812 (target_regsets): Rename to ...
13813 (s390_regsets): ... this, and make static.
13814 (s390_get_pc, s390_set_pc): Adjust.
13815 (s390_get_hwcap): New target_desc parameter, and use it.
13816 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13817 (s390_arch_setup): Adjust to set the current process'es target
13818 description. Don't adjust the regmap.
13819 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13820 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13821 (regs_info_3264): New globals.
13822 (s390_regs_info): New function.
13823 (the_low_target): Adjust.
13824 (initialize_low_arch): New function.
13825 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13826 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13827 [__mips64] (init_registers_mips_linux)
13828 (init_registers_mips_dsp_linux): Delete defines.
13829 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13830 (have_dsp): New global.
13831 (mips_read_description): New, based on mips_arch_setup.
13832 (mips_arch_setup): Reimplement.
13833 (get_usrregs_info): New function.
13834 (mips_cannot_fetch_register, mips_cannot_store_register)
13835 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13836 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13837 (target_regsets): Rename to ...
13838 (mips_regsets): ... this, and make static.
13839 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13840 (dsp_regs_info, regs_info): New globals.
13841 (mips_regs_info): New function.
13842 (the_low_target): Adjust.
13843 (initialize_low_arch): New function.
13844 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13845 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13846 Declare.
13847 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13848 (arm_read_description): New, with bits factored from
13849 arm_arch_setup.
13850 (arm_arch_setup): Reimplement.
13851 (target_regsets): Rename to ...
13852 (arm_regsets): ... this, and make static.
13853 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13854 (arm_regs_info): New function.
13855 (the_low_target): Adjust.
13856 (initialize_low_arch): New function.
13857 * linux-m68k-low.c (tdesc_m68k): Declare.
13858 (target_regsets): Rename to ...
13859 (m68k_regsets): ... this, and make static.
13860 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13861 (m68k_regs_info): New function.
13862 (m68k_arch_setup): New function.
13863 (the_low_target): Adjust.
13864 (initialize_low_arch): New function.
13865 * linux-sh-low.c (tdesc_sharch): Declare.
13866 (target_regsets): Rename to ...
13867 (sh_regsets): ... this, and make static.
13868 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13869 (sh_regs_info, sh_arch_setup): New functions.
13870 (the_low_target): Adjust.
13871 (initialize_low_arch): New function.
13872 * linux-bfin-low.c (tdesc_bfin): Declare.
13873 (bfin_arch_setup): New function.
13874 (bfin_usrregs_info, regs_info): New globals.
13875 (bfin_regs_info): New function.
13876 (the_low_target): Adjust.
13877 (initialize_low_arch): New function.
13878 * linux-cris-low.c (tdesc_cris): Declare.
13879 (cris_arch_setup): New function.
13880 (cris_usrregs_info, regs_info): New globals.
13881 (cris_regs_info): New function.
13882 (the_low_target): Adjust.
13883 (initialize_low_arch): New function.
13884 * linux-cris-low.c (tdesc_crisv32): Declare.
13885 (cris_arch_setup): New function.
13886 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13887 (cris_regs_info): New function.
13888 (the_low_target): Adjust.
13889 (initialize_low_arch): New function.
13890 * linux-m32r-low.c (tdesc_m32r): Declare.
13891 (m32r_arch_setup): New function.
13892 (m32r_usrregs_info, regs_info): New globals.
13893 (m32r_regs_info): Adjust.
13894 (initialize_low_arch): New function.
13895 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13896 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13897 (tic6x_usrregs_info): Forward declare.
13898 (tic6x_read_description): New function, based on ...
13899 (tic6x_arch_setup): ... this. Reimplement.
13900 (target_regsets): Rename to ...
13901 (tic6x_regsets): ... this, and make static.
13902 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13903 (tic6x_regs_info): New function.
13904 (the_low_target): Adjust.
13905 (initialize_low_arch): New function.
13906 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13907 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13908 (target_regsets): Rename to ...
13909 (xtensa_regsets): ... this, and make static.
13910 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13911 globals.
13912 (xtensa_arch_setup, xtensa_regs_info): New functions.
13913 (the_low_target): Adjust.
13914 (initialize_low_arch): New function.
13915 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13916 (nios2_arch_setup): Set the current process'es tdesc.
13917 (target_regsets): Rename to ...
13918 (nios2_regsets): ... this.
13919 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13920 (nios2_regs_info): New function.
13921 (the_low_target): Adjust.
13922 (initialize_low_arch): New function.
a261b8f5
PA
13923 * linux-aarch64-low.c (tdesc_aarch64): Declare.
13924 (aarch64_arch_setup): Set the current process'es tdesc.
13925 (target_regsets): Rename to ...
13926 (aarch64_regsets): ... this.
13927 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
13928 (aarch64_regs_info): New function.
13929 (the_low_target): Adjust.
13930 (initialize_low_arch): New function.
3aee8918
PA
13931 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
13932 globals.
13933 (target_regsets): Rename to ...
13934 (tile_regsets): ... this.
13935 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
13936 (tile_regs_info): New function.
13937 (tile_arch_setup): Set the current process'es tdesc.
13938 (the_low_target): Adjust.
13939 (initialize_low_arch): New function.
13940 * spu-low.c (tdesc_spu): Declare.
13941 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
13942 * win32-arm-low.c (tdesc_arm): Declare.
13943 (arm_arch_setup): New function.
13944 (the_low_target): Install arm_arch_setup instead of
13945 init_registers_arm.
13946 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
13947 (init_windows_x86): Rename to ...
13948 (i386_arch_setup): ... this. Set `win32_tdesc'.
13949 (the_low_target): Adjust.
13950 * win32-low.c (win32_tdesc): New global.
13951 (child_add_thread): Don't create the thread cache here.
13952 (do_initial_child_stuff): Set the new process'es tdesc.
13953 * win32-low.h (struct target_desc): Forward declare.
13954 (win32_tdesc): Declare.
13955 * lynx-i386-low.c (tdesc_i386): Declare global.
13956 (lynx_i386_arch_setup): Set `lynx_tdesc'.
13957 * lynx-low.c (lynx_tdesc): New global.
13958 (lynx_add_process): Set the new process'es tdesc.
13959 * lynx-low.h (struct target_desc): Forward declare.
13960 (lynx_tdesc): Declare global.
13961 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
13962 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
13963 * nto-low.c (nto_tdesc): New global.
13964 (do_attach): Set the new process'es tdesc.
13965 * nto-low.h (struct target_desc): Forward declare.
13966 (nto_tdesc): Declare.
13967 * nto-x86-low.c (tdesc_i386): Declare.
13968 (nto_x86_arch_setup): Set `nto_tdesc'.
13969
b1fbec62
GB
139702013-06-04 Gary Benson <gbenson@redhat.com>
13971
13972 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
13973 to qSupported response when appropriate.
13974 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
13975 with nonzero-length annex.
13976 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
13977 arguments supplied in annex.
13978
d1ec4ce7
DE
139792013-05-31 Doug Evans <dje@google.com>
13980
ac44adcb 13981 PR server/15594
d1ec4ce7
DE
13982 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
13983 64 bits in 64-cross-32 environment.
13984
9b25f2d3
PA
139852013-05-28 Pedro Alves <palves@redhat.com>
13986
13987 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
13988 (aarch64-without-fpu.c): Delete rule.
13989 * configure.srv (aarch64*-*-linux*): Remove references to
13990 aarch64-without-fpu.o and aarch64-without-fpu.xml.
13991 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
13992 declaration.
13993
6740dc9c
PA
139942013-05-24 Pedro Alves <palves@redhat.com>
13995
13996 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
13997 instead of strchr/decode_address. Error if the range isn't split
13998 with a ','. Don't assume there's be a ':' in the action.
13999
c2d6af84
PA
140002013-05-23 Yao Qi <yao@codesourcery.com>
14001 Pedro Alves <palves@redhat.com>
14002
14003 * linux-low.c (lwp_in_step_range): New function.
14004 (linux_wait_1): If the thread was range stepping and stopped
14005 outside the stepping range, report the stop to GDB. Otherwise,
14006 continue stepping. Add range stepping debug output.
14007 (linux_set_resume_request): Copy the step range from the resume
14008 request to the lwp.
14009 (linux_supports_range_stepping): New.
14010 (linux_target_ops) <supports_range_stepping>: Set to
14011 linux_supports_range_stepping.
14012 * linux-low.h (struct linux_target_ops)
14013 <supports_range_stepping>: New field.
14014 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14015 * linux-x86-low.c (x86_supports_range_stepping): New.
14016 (the_low_target) <supports_range_stepping>: Set to
14017 x86_supports_range_stepping.
14018 * server.c (handle_v_cont): Handle 'r' action.
14019 (handle_v_requests): Append ";r" if the target supports range
14020 stepping.
14021 * target.h (struct thread_resume) <step_range_start,
14022 step_range_end>: New fields.
14023 (struct target_ops) <supports_range_stepping>:
14024 New field.
14025 (target_supports_range_stepping): New macro.
14026
58794e1a
JB
140272013-05-17 Joel Brobecker <brobecker@adacore.com>
14028
14029 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14030 confusion in comment.
14031
d631c5a7
JB
140322013-05-17 Joel Brobecker <brobecker@adacore.com>
14033
14034 * lynx-low.c (struct process_info_private): New type.
14035 (lynx_add_process): New function.
14036 (lynx_create_inferior, lynx_attach): Replace calls to
14037 add_process by calls to lynx_add_process.
14038 (lynx_resume): If PTID is null, then try using
14039 current_process()->private->last_wait_event_ptid.
14040 Add comments.
14041 (lynx_clear_inferiors): Delete. The contents of that function
14042 has been inlined in lynx_mourn;
14043 (lynx_wait_1): Save the ptid in the process's private data.
14044 (lynx_mourn): Free the process' private data. Replace call
14045 to lynx_clear_inferiors by call to clear_inferiors.
14046
96f7a20f
YQ
140472013-05-17 Yao Qi <yao@codesourcery.com>
14048
14049 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14050 the right place.
14051
db0dfaa0
LM
140522013-05-16 Luis Machado <lgustavo@codesourcery.com>
14053
14054 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14055 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14056 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14057 PT_TEXT_END_ADDR guards. Update comments.
14058 (linux_target_op) <read_offsets>: Conditionally define to
14059 linux_read_offsets if the target is UCLIBC and if it defines
14060 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14061
68f5f838
SL
140622013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14063 Andrew Jenner <andrew@codesourcery.com>
14064
14065 * Makefile.in (SFILES): Add linux-nios2-low.c.
14066 (clean): Add action to delete nios2-linux.c.
14067 (nios2-linux.c): New rule.
14068 * configure.srv: Add nios2*-*-linux*.
14069 * linux-nios2-low.c: New.
14070
1ebff1fd
HAQ
140712013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14072
14073 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14074
f6150862
HZ
140752013-04-25 Hui Zhu <hui@codesourcery.com>
14076
14077 PR gdb/15186
f6150862
HZ
14078 * ax.c (ax_printf): Add fflush.
14079
614c279d
TT
140802013-04-22 Tom Tromey <tromey@redhat.com>
14081
14082 * Makefile.in (SFILES): Add filestuff.c.
14083 (OBS): Add filestuff.o.
14084 (filestuff.o): New target.
14085 * config.in, configure: Rebuild.
14086 * configure.ac: Check for fdwalk, pipe2.
14087
7d4e5717
PA
140882013-04-17 Pedro Alves <palves@redhat.com>
14089
14090 * configure.ac (USE_THREAD_DB): Delete variable.
14091 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14092 Don't AC_SUBST USE_THREAD_DB.
14093 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14094 * config.in, configure: Regenerate.
14095
d5c93e41
PA
140962013-04-16 Pedro Alves <palves@redhat.com>
14097
14098 * linux-low.h (struct lwp_info) <thread_known>: Move under
14099 the USE_THREAD_DB #ifdef.
14100
04f5fe89
PA
141012013-04-16 Pedro Alves <palves@redhat.com>
14102
14103 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14104 (linux-low.o): Delete rule.
14105 * linux-low.h: Always include "gdb_thread_db.h" instead of
14106 conditionally including thread_db.h.
14107 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14108 HAVE_THREAD_DB_H.
14109
480b27bf
JK
141102013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14111
14112 * Makefile.in (install-only): Fix make install regression.
14113
43662968
JK
141142013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14115
14116 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14117 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14118 installation.
14119 * gdbserver.1: Remove.
14120
3e74e146
PA
141212013-03-22 Pedro Alves <palves@redhat.com>
14122
14123 * linux-low.c (handle_extended_wait): Don't call
14124 linux_enable_event_reporting.
14125
a8347a2a
TT
141262013-03-15 Tony Theodore <tonyt@logyst.com>
14127
14128 PR build/9098:
14129 * Makefile.in (SHELL): Use @SHELL@.
14130
eeb56fa7
SDJ
141312013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14132
14133 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14134 compiler warning.
14135
4fa7e2ff
JB
141362013-03-13 Joel Brobecker <brobecker@adacore.com>
14137
14138 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14139 Remove extraneous NULL element.
14140
8ddb1965
YQ
141412013-03-13 Yao Qi <yao@codesourcery.com>
14142
14143 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14144 'V' block in trace frame.
14145
9accd112
MM
141462013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14147
14148 * target.h (struct target_ops): Add btrace ops.
14149 (target_supports_btrace): New macro.
14150 (target_enable_btrace): New macro.
14151 (target_disable_btrace): New macro.
14152 (target_read_btrace): New macro.
14153 * gdbthread.h (struct thread_info): Add btrace field.
14154 * server.c: Include btrace-common.h.
14155 (handle_btrace_general_set): New function.
14156 (handle_btrace_enable): New function.
14157 (handle_btrace_disable): New function.
14158 (handle_general_set): Call handle_btrace_general_set.
14159 (handle_qxfer_btrace): New function.
14160 (struct qxfer qxfer_packets[]): Add btrace entry.
14161 * inferiors.c (remove_thread): Disable btrace.
14162 * linux-low: Include linux-btrace.h.
14163 (linux_low_enable_btrace): New function.
14164 (linux_low_read_btrace): New function.
14165 (linux_target_ops): Add btrace ops.
14166 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14167 Add srv_linux_btrace=yes.
14168 (x86_64-*-linux*): Add linux-btrace.o.
14169 Add srv_linux_btrace=yes.
14170 * configure.ac: Define HAVE_LINUX_BTRACE.
14171 * config.in: Regenerated.
14172 * configure: Regenerated.
14173
5cc22e4c
MM
141742013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14175
14176 * server.c (handle_qxfer): Preserve error message if -3 is
14177 returned.
14178 (qxfer): Document the -3 return value.
14179
7c97f91e
MM
141802013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14181
14182 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14183 (linux_btrace_h): New variable.
14184 (linux-btrace.o): New rule.
14185
be9a119c 141862013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
14187 Hafiz Abid Qadeer <abidh@codesourcery.com>
14188
14189 * tracepoint.c (trace_buffer_size): New global.
14190 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14191 (init_trace_buffer): Change to one-argument function. Allocate
14192 trace buffer memory.
14193 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14194 handle QTBuffer:size packet.
14195 (cmd_bigqtbuffer_size): New function.
14196 (initialize_tracepoint): Call init_trace_buffer with
14197 DEFAULT_TRACE_BUFFER_SIZE.
14198 * server.c (handle_query): Add QTBuffer:size in the
14199 supported packets.
14200
e64f7499
YQ
142012013-03-07 Yao Qi <yao@codesourcery.com>
14202
14203 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14204 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14205 of -1.
14206 (cmd_qtsp): Adjust condition. Do post increment.
14207 Set cur_action and cur_step_action back to 0.
14208
f0ae6fc3
PA
142092013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14210
14211 PR server/15236
14212 * linux-low.c (linux_write_memory): Return early success if LEN is
14213 zero.
14214
b5b0b0af
CV
142152013-03-05 Corinna Vinschen <vinschen@redhat.de>
14216
334ad4a8 14217 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 14218
589bc927
TT
142192013-02-28 Tom Tromey <tromey@redhat.com>
14220
14221 * configure.ac: Invoke AC_SYS_LARGEFILE.
14222 * configure, config.in: Rebuild.
14223
dfe07582
CV
142242013-02-28 Corinna Vinschen <vinschen@redhat.com>
14225
14226 * win32-low.c: Throughout, fix format strings and casts of
14227 printf-like functions to avoid type related warnings on all
14228 platforms.
14229 (get_child_debug_event): Print dwDebugEventCode as hex since
14230 that's how it's usually documented.
14231
736cd585
YQ
142322013-02-28 Yao Qi <yao@codesourcery.com>
14233
14234 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14235 pulongest.
14236
e1f58301
JW
142372013-02-27 Jiong Wang <jiwang@tilera.com>
14238
14239 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14240 (reg-tilegx32.c): New rule.
14241 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14242 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14243 different register info initializer according to elf class.
14244 (init_registers_tilgx32): New function. The tilegx32 register info
14245 initializer.
14246 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14247 (tile_store_gregset): Likewise.
14248
d171ca78
YQ
142492013-02-27 Yao Qi <yao@codesourcery.com>
14250
14251 * server.c (process_point_options): Print debug message when
14252 debug_threads is true.
14253
282bbdf3
YQ
142542013-02-26 Yao Qi <yao@codesourcery.com>
14255
14256 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14257
aca22551
PA
142582013-02-19 Pedro Alves <palves@redhat.com>
14259 Kai Tietz <ktietz@redhat.com>
14260
14261 PR gdb/15161
14262
14263 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14264 instead of strtoul to extract address from packet.
14265 (process_serial_event) <'z'>: Likewise.
14266
4f3cee1c
YQ
142672013-02-18 Yao Qi <yao@codesourcery.com>
14268
14269 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14270
8e1d55a3
PA
142712013-02-14 Pedro Alves <palves@redhat.com>
14272
14273 Plug memory leak.
14274
14275 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14276 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14277
458820da
PA
142782013-02-14 Pedro Alves <palves@redhat.com>
14279
14280 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14281
baea0dae
PA
142822013-02-14 Pedro Alves <palves@redhat.com>
14283
14284 * tracepoint.c (save_string): Delete.
14285 (add_tracepoint_action): Use savestring instead of save_string.
14286
0b1afbb3
PA
142872013-02-12 Pedro Alves <palves@redhat.com>
14288
14289 * linux-xtensa-low.c: Ditto.
14290 * xtensa-xtregs.c: Ditto.
14291
8a4ac37e
PA
142922013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14293
14294 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14295 thread_db.
14296
148de6bb
MS
142972013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14298
14299 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14300 aarch64_num_wp_regs and aarch64_num_bp_regs to
14301 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14302
55fac6e0
MS
143032013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14304
14305 * linux-aarch64-low.c (ps_get_thread_area): Replace
14306 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14307
176eb98c
MS
143082013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14309 Marcus Shawcroft <marcus.shawcroft@arm.com>
14310 Nigel Stephens <nigel.stephens@arm.com>
14311 Yufeng Zhang <yufeng.zhang@arm.com>
14312
14313 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14314 (aarch64.c, aarch64-without-fpu.c): New targets.
14315 * configure.srv (aarch64*-*-linux*): New.
14316 * linux-aarch64-low.c: New file.
14317
56f7af9c
MS
143182013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14319
43aaf8b6 14320 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
14321 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14322 (dequeue_one_deferred_signal, linux_resume_one_thread)
14323 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14324 (linux_tracefork_grandchild, linux_test_for_tracefork)
14325 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14326 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14327 where the argument is 0.
14328
60f662b0
YQ
143292013-01-25 Yao Qi <yao@codesourcery.com>
14330
14331 * event-loop.c: Include "queue.h".
14332 (gdb_event_p): New typedef.
14333 (struct gdb_event) <next_event>: Remove.
14334 (event_queue): Change to QUEUE(gdb_event_p).
14335 (async_queue_event): Remove.
14336 (gdb_event_xfree): New.
14337 (initialize_event_loop): New.
14338 (process_event): Use API from QUEUE.
14339 (wait_for_event): Likewise.
14340 * server.c (main): Call initialize_event_loop.
14341 * server.h (initialize_event_loop): Declare.
14342
5ae4861a
YQ
143432013-01-18 Yao Qi <yao@codesourcery.com>
14344
14345 * ax.h (struct eval_agent_expr_context): New.
14346 (gdb_eval_agent_expr): Update declaration.
14347 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14348 TFRAME. Add new argument CTX.
14349 * server.h (struct eval_agent_expr_context): Declare.
14350 (agent_mem_read, agent_tsv_read): Update declaration.
14351 (agent_mem_read_string): Likewise.
14352 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14353 (add_traceframe_block): Add new argument TPOINT.
14354 Increase TPOINT->traceframe_usage.
14355 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14356 eval_tracepoint_agent_expr.
14357 (condition_true_at_tracepoint): Likewise.
14358 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14359 (agent_mem_read_string, agent_tsv_read): Likewise.
14360
85e00e85
YQ
143612013-01-16 Yao Qi <yao@codesourcery.com>
14362
14363 * linux-low.c (linux_resume_one_lwp): Don't check
14364 'lwp->bp_reinsert != 0'.
14365
4039cf45
JB
143662013-01-07 Joel Brobecker <brobecker@adacore.com>
14367 Pedro Alves <palves@redhat.com>
14368
14369 * lynx-low.c (ptrace_request_to_str): Define a temporary
14370 macro and use it to simplify this function's implementation.
14371
9044dee2
JB
143722013-01-07 Joel Brobecker <brobecker@adacore.com>
14373
14374 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14375 sets errno.
14376
e6352c8f
JB
143772013-01-07 Joel Brobecker <brobecker@adacore.com>
14378
14379 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14380
50681a27
JB
143812013-01-07 Joel Brobecker <brobecker@adacore.com>
14382
14383 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14384
3f6e77ef
JB
143852013-01-07 Joel Brobecker <brobecker@adacore.com>
14386
14387 * lynx-low.c (lynx_resume): Use the resume_info parameter
14388 to determine the ptid for the lynx_ptrace call, unless
14389 it is equal to minus_one_ptid, in which case we use the
14390 ptid of the current_inferior.
14391 (lynx_wait_1): After having received a thread create/exit
14392 event, resume the inferior's execution using the signaling
14393 thread's ptid, rather than the old ptid.
14394
7fda33ae
JB
143952013-01-07 Joel Brobecker <brobecker@adacore.com>
14396
14397 * lynx-low.c (lynx_resume): Delete variable ret.
14398
b9786c74
JB
143992013-01-01 Joel Brobecker <brobecker@adacore.com>
14400
14401 * gdbreplay.c (gdbreplay_version): Update copyright year.
14402 * server.c (gdbserver_version): Likewise.
14403
8b93d60f
JB
144042012-12-17 Joel Brobecker <brobecker@adacore.com>
14405
14406 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14407 new thread.
14408
037335a7
JB
144092012-12-17 Joel Brobecker <brobecker@adacore.com>
14410
14411 * lynx-low.c (ptrace_request_to_str): Add handling for
14412 PTRACE_GETTRACESIG.
14413
52d4cbd8
JB
144142012-12-17 Joel Brobecker <brobecker@adacore.com>
14415
14416 * lynx-low.c (lynx_attach): Delete variable new_process.
14417
ab8f6ca9
JB
144182012-12-17 Joel Brobecker <brobecker@adacore.com>
14419
14420 * lynx-low.c (lynx_create_inferior): Delete variable
14421 new_process.
14422
78cbc024
JB
144232012-12-17 Joel Brobecker <brobecker@adacore.com>
14424
14425 * lynx-low.c (ptrace_request_to_str): Do not handle
14426 PTRACE_GETTHREADLIST if this macro does not exist.
14427
14a00470
YQ
144282012-12-15 Yao Qi <yao@codesourcery.com>
14429
14430 * Makefile.in (OBS): Add notif.o.
14431 * notif.c, notif.h: New.
14432 * server.c: Include "notif.h".
14433 (struct vstop_notif) <next>: Remove.
14434 <base>: New field.
14435 (queue_stop_reply): Update.
14436 (push_event, send_next_stop_reply): Remove.
14437 (discard_queued_stop_replies): Update.
14438 (notif_stop): New variable.
14439 (handle_v_stopped): Remove.
14440 (handle_v_requests): Don't call handle_v_stopped. Call
14441 handle_ack_notif instead.
14442 (queue_stop_reply_callback): Call notif_event_enque instead
14443 of queue_stop_reply.
14444 (handle_status): Don't call send_next_stop_reply, call
14445 notif_write_event instead.
14446 (kill_inferior_callback): Likewise.
14447 (detach_or_kill_inferior_callback): Likewise.
14448 (main): Call initialize_notif.
14449 (process_serial_event): Call QUEUE_is_empty.
14450 (handle_target_event): Call notif_push instead of push event.
14451 * server.h (push_event): Remove declaration.
14452
61c125b9
TT
144532012-12-10 Tom Tromey <tromey@redhat.com>
14454
14455 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14456 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14457 macros.
14458 (.c.o): Rewrite.
14459 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14460 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14461 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14462 (amd64-linux-ipa.o, ax.o): Rewrite.
14463 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14464 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14465 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14466 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14467 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14468 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14469 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14470 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14471 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14472 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14473 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14474 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14475 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14476 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14477 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14478 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14479 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14480 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14481 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14482 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14483 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14484 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14485 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14486 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14487 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14488 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14489 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14490 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14491 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14492 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14493 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14494 (reg-tilegx.o): Remove.
14495 (all_object_files): New macro.
14496 Include .deps files.
14497 * aclocal.m4, configure: Rebuild.
14498 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14499 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14500 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14501
e90e9ad9
TT
145022012-12-05 Tom Tromey <tromey@redhat.com>
14503
14504 PR gdb/14917:
14505 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14506
02d403bf 145072012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
14508
14509 * configure.ac: Check for linux/perf_event.h.
14510 * config.in: Regenerated.
14511 * configure: Regenerated.
14512
0270a750
PA
145132012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14514
14515 * hostio.c (handle_readlink): Decrease buffer size
14516 parameter passed to readlink by one byte.
14517
8c29b58e
YQ
145182012-11-26 Yao Qi <yao@codesourcery.com>
14519
14520 * configure.ac (build_warnings): Append '-Wempty-body'.
14521 * configure: Regenerated.
14522 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14523 body.
14524
8bdce1ff
PM
145252012-11-15 Pierre Muller <muller@sourceware.org>
14526
14527 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14528 * config.in: Regenerate.
14529 * configure: Regenerate.
14530 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14531 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14532 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14533 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14534 header.
14535 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14536 instead of <sys/wait.h> header.
14537 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14538
02d403bf 145392012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
14540
14541 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14542 (various make rules): Remove -DGDBSERVER
14543
fbd5db48
YQ
145442012-11-09 Yao Qi <yao@codesourcery.com>
14545
14546 * spu-low.c (current_ptid): Move it to ..
14547 * gdbthread.h: ... here. New.
14548 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14549 * server.c (myresume, process_serial_event): Likewise.
14550 * thread-db.c (thread_db_find_new_threads): Likewise.
14551 * tracepoint.c (run_inferior_command): Likewise.
14552
b3dc46ff
AB
145532012-10-01 Andrew Burgess <aburgess@broadcom.com>
14554
14555 * server.c (handle_search_memory_1): Include access length in
14556 warning message.
14557
07c04788
HPN
145582012-09-05 Michael Brandt <michael.brandt@axis.com>
14559
14560 * linux-crisv32-low.c: Fix compile errors.
14561
918d227b
YQ
145622012-09-04 Yao Qi <yao@codesourcery.com>
14563
14564 * tracepoint.c (cmd_qtsv): Adjust debug message.
14565 Don't check CUR_TPOINT.
14566
18c1b81a
YQ
145672012-08-28 Yao Qi <yao@codesourcery.com>
14568
14569 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14570 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14571 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14572 Remove declarations of xmalloc, xreallloc, xstrdup and
14573 freeargv.
14574 * Makefile.in (libiberty_h): New.
14575 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14576 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14577
dc82f37b
YQ
145782012-08-23 Yao Qi <yao@codesourcery.com>
14579
14580 * server.h: Remove declaration of 'xsnprintf'.
14581
406b1477
KS
145822012-08-22 Keith Seitz <keiths@redhat.com>
14583
14584 * server.h: Include build-gnulib-gbserver/config.h.
14585 * gdbreplay.c: Likewise.
14586
e6712ff1
DE
145872012-08-08 Doug Evans <dje@google.com>
14588
14589 * Makefile.in (SFILES): Add gdb_vecs.c.
14590 (OBS): Add gdb_vecs.o.
14591 (gdb_vecs_h, host_defs_h): New variables.
14592 (thread-db.o): Add $(gdb_vecs_h) dependency.
14593 (gdb_vecs.o): New rule.
14594 * thread-db.c: #include "gdb_vecs.h".
14595 (thread_db_load_search): Use a vector to iterate over path elements.
14596 Handle text appearing after "$pdir".
14597
14598 * configure.ac: Add check for strstr.
14599 * config.in: Regenerate.
14600 * configure: Regenerate.
14601
7c3270ae
UW
146022012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14603
14604 * hostio.c (handle_pread): If pread fails, fall back to attempting
14605 lseek/read.
14606 (handle_pwrite): Likewise for pwrite.
14607
b62e2b27
UW
146082012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14609
14610 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14611 between unsupported TYPE and unimplementable ADDR/LEN combination.
14612 (arm_insert_point): Act on new return value.
14613
78a99e91
PA
146142012-07-31 Pedro Alves <palves@redhat.com>
14615
14616 * server.c (process_point_options): Only skip tokens if we find
14617 one that is unrecognized. Don't treat 'X' specially while
14618 skipping unrecognized tokens.
14619
fcf303ab
UW
146202012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14621
14622 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14623 to 4-byte-align HW breakpoint addresses for Thumb.
14624
7255706c
YQ
146252012-07-27 Yao Qi <yao@codesourcery.com>
14626
14627 PR remote/14161.
14628
14629 * server.h: Declare gdb_agent_about_to_close.
14630 * target.c (kill_inferior): Include "agent.h".
14631 New. Send command 'kill'.
14632 * target.h (kill_inferior): Removed macro.
14633 * tracepoint.c (gdb_agent_about_to_close): New.
14634 (gdb_agent_helper_thread): Handle command 'close'.
14635 Wait endlessly until the inferior stops.
14636 Install gdb_agent_remove_socket to atexit hook.
14637 (agent_socket_name): New static variable.
14638 (gdb_agent_socket_init): Replace local variable 'name' with
14639 'agent_socket_name'.
14640 (gdb_agent_remove_socket): New.
14641
5a3f286f
YQ
146422012-07-27 Yao Qi <yao@codesourcery.com>
14643
14644 * server.c (process_point_options): Stop at 'X' when parsing.
14645
961bd387
ME
146462012-07-19 Michael Eager <eager@eagercon.com>
14647
a261b8f5 14648 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
14649 to hw_execute.
14650 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14651 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14652 hardware breakpoint.
14653
aa7c7447
JK
146542012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14655
14656 * gdbserver/linux-low.c (initialize_low): Call
14657 linux_ptrace_init_warnings.
14658
7f216e7c
DE
146592012-07-02 Doug Evans <dje@google.com>
14660
14661 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14662 pointer to int.
14663
d3ce09f5
SS
146642012-07-02 Stan Shebs <stan@codesourcery.com>
14665
14666 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14667 (ax.o): Add it to build rule.
14668 (ax-ipa.o): Ditto.
14669 (OBS): Add format.o.
14670 (IPA_OBS): Add format.o.
14671 * server.c (handle_query): Claim support for breakpoint commands.
14672 (process_point_options): Add command case.
14673 (process_serial_event): Leave running if there are printfs in
14674 effect.
14675 * mem-break.h (any_persistent_commands): Declare.
14676 (add_breakpoint_commands): Declare.
14677 (gdb_no_commands_at_breakpoint): Declare.
14678 (run_breakpoint_commands): Declare.
14679 * mem-break.c (struct point_command_list): New struct.
14680 (struct breakpoint): New field command_list.
14681 (any_persistent_commands): New function.
14682 (add_commands_to_breakpoint): New function.
14683 (add_breakpoint_commands): New function.
14684 (gdb_no_commands_at_breakpoint): New function.
14685 (run_breakpoint_commands): New function.
14686 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14687 locally.
14688 * ax.c: Include format.h.
14689 (ax_printf): New function.
14690 (gdb_eval_agent_expr): Add printf opcode.
14691
2f8f6aed
YQ
146922012-06-13 Yao Qi <yao@codesourcery.com>
14693
14694 * server.c (start_inferior): Remove duplicated writes to fields
14695 'last_resume_kind' and 'last_status' of 'current_inferior'.
14696
0c9070b3
YQ
146972012-06-12 Yao Qi <yao@codesourcery.com>
14698 Pedro Alves <palves@redhat.com>
14699
14700 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14701 comment.
14702 * server.c (handle_v_cont): Extend comment.
14703
c52daf70
YQ
147042012-06-11 Yao Qi <yao@codesourcery.com>
14705
14706 * linux-low.c (linux_attach): Add 'static'.
14707
d38bbb0a
YQ
147082012-06-06 Yao Qi <yao@codesourcery.com>
14709
14710 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14711
89dc0afd
JK
147122012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14713
14714 Fix gcc -flto compilation warning.
14715 * server.c (main): Make variable multi_mode and attach volatile.
14716
75f62ce7
TJB
147172012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14718
14719 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14720 if the platform doesn't know about it.
14721
65f479b6
PA
147222012-05-30 Jeff Kenton <jkenton@tilera.com>
14723
14724 * Makefile.in (SFILES): Add linux-tile-low.c.
14725 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14726 * configure.srv: Handle tilegx-*-linux*.
14727 * linux-tile-low.c: New file.
14728
0c5bf5a9
JK
147292012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14730
14731 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14732
a493e3e2
PA
147332012-05-24 Pedro Alves <palves@redhat.com>
14734
14735 PR gdb/7205
14736
43aaf8b6 14737 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 14738
2ea28649
PA
147392012-05-24 Pedro Alves <palves@redhat.com>
14740
14741 PR gdb/7205
14742
14743 Replace target_signal with gdb_signal throughout.
14744
8d409d16
MR
147452012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14746
14747 * linux-low.c (linux_store_registers): Avoid the copying sequence
14748 when no data has been retrieved by ptrace.
14749
23512c01
MGD
147502012-05-22 Will Deacon <will.deacon@arm.com>
14751
14752 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14753 Include asm/ptrace.h.
14754 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14755 already defined.
14756
4934b29e
MR
147572012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14758
14759 * linux-low.c (linux_store_registers): Don't re-retrieve data
14760 with ptrace that has already been obtained from /proc. Always
14761 copy any data retrieved with ptrace to the buffer supplied.
14762
bde24c0a
PA
147632012-05-11 Yao Qi <yao@codesourcery.com>
14764 Pedro Alves <palves@redhat.com>
14765
14766 * linux-low.c (enum stopping_threads_kind): New.
14767 (stopping_threads): Change type to `enum stopping_threads_kind'.
14768 (handle_extended_wait): If stopping and suspending threads, leave
14769 the new_lwp suspended too.
14770 (linux_wait_for_event): Adjust.
14771 (stop_all_lwps): Set `stopping_threads' to
14772 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14773 whether we're suspending threads or just stopping them. Assert no
14774 recursion happens.
14775
623b6bdf
YQ
147762012-04-29 Yao Qi <yao@codesourcery.com>
14777
14778 * server.h: Move some code to ...
14779 * gdbthread.h: ... here. New.
14780 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14781 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14782 (nto-low.o, win32-low.o): Likewise.
14783 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14784 * regcache.c, remote-utils.c, server.c: Likewise.
14785 * target.c, tracepoint.c, win32-low.c: Likewise.
14786
f15f9948
TJB
147872012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14788
14789 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14790 (PTRACE_ARG4_TYPE): Likewise.
14791 (PTRACE_XFER_TYPE): Likewise.
14792 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14793 ptrace to PTRACE_ARG3_TYPE.
14794 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14795 (PTRACE_ARG4_TYPE): Likewise.
14796 (PTRACE_XFER_TYPE): Likewise.
14797 (linux_detach_one_lwp): Cast fourth argument of
14798 ptrace to long then PTRACE_ARG4_TYPE.
14799 (regsets_fetch_inferior_registers): Cast third argument of
14800 ptrace to long then PTRACE_ARG3_TYPE.
14801 (regsets_store_inferior_registers): Likewise.
14802
38ea300a
PA
148032012-04-20 Pedro Alves <palves@redhat.com>
14804
14805 * configure: Regenerate.
14806
c971b7fa
PA
148072012-04-19 Pedro Alves <palves@redhat.com>
14808
43aaf8b6 14809 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 14810 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
14811 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14812 (all, install-only, uninstall, clean-info, all-lib, clean): No
14813 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14814 (maintainer-clean realclean distclean): Use subdir_do.
14815 (subdir_do): New.
14816 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 14817 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
14818 * acinclude.m4: Include acx_configure_dir.m4.
14819 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14820 calls. Call AC_PROG_RANLIB. Configure gnulib using
14821 ACX_CONFIGURE_DIR.
14822 (GNULIB): New.
14823 (GNULIB_STDINT_H): Adjust.
14824 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14825 * gdbreplay.c: Include build-gnulib/config.h.
14826 * server.h: Likewise.
14827 * aclocal.m4: Regenerate.
14828 * config.in: Regenerate.
14829 * configure: Regenerate.
c971b7fa 14830
809277f8
PA
148312012-04-19 Pedro Alves <palves@redhat.com>
14832
14833 * Makefile.in (LIBGNU, INCGNU): Adjust.
14834 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14835 (all, install-only, uninstall, clean-info, all-lib, clean)
14836 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14837 * configure.ac: Adjust AC_OUTPUT output.
14838 * aclocal.m4: Regenerate.
14839 * configure: Regenerate.
14840
fd9bb8b8
PA
148412012-04-19 Pedro Alves <palves@redhat.com>
14842
14843 * Makefile.in (generated_files): New.
14844 (server_h): Remove the explicit dependency on config.h, and depend
14845 on $generated_files.
14846
1c298c66
PA
148472012-04-19 Pedro Alves <palves@redhat.com>
14848
14849 * Makefile.in (INCGNU): Add -Ignulib.
14850
57c4b50b
PA
148512012-04-19 Pedro Alves <palves@redhat.com>
14852
14853 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14854 (INCGNU): ... this, and spell out -I here.
14855 (GNULIB_LIB): Rename to ...
14856 (LIBGNU): ... this.
14857 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14858
1030e047
PA
148592012-04-19 Pedro Alves <palves@redhat.com>
14860
14861 * config.in: Regenerate.
14862
447d4319
PA
148632012-04-19 Pedro Alves <palves@redhat.com>
14864
14865 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14866 * server.h (memmem): Remove declaration.
14867 * config.in: Regenerate.
14868 * configure: Regenerate.
14869
aad9eab9
YQ
148702012-04-19 Yao Qi <yao@codesourcery.com>
14871
14872 * Makefile.in (SFILES): Add common/vec.c.
14873 (OBS): Add vec.o.
14874 (vec.o): New rule.
14875
3e10640f
YQ
148762012-04-19 Yao Qi <yao@codesourcery.com>
14877
14878 * remote-utils.c (prepare_resume_reply): Replace with macro
14879 target_core_of_thread.
14880 * server.c (handle_qxfer_threads_proper): Likewise.
14881 * target.h (traget_core_of_thread): New macro.
14882
71622373
PA
148832012-04-18 Pedro Alves <palves@redhat.com>
14884
14885 * aclocal.m4: Regenerate.
14886 * configure: Regenerate.
14887
80d26939
YQ
148882012-04-16 Yao Qi <yao@codesourcery.com>
14889
14890 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14891 duplicated on address.
14892
42476b70
YQ
148932012-04-16 Yao Qi <yao@codesourcery.com>
14894
14895 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14896 (struct tracepoint_action_ops) <send>: New field.
14897 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14898 (agent_expr_send, x_tracepoint_action_send): New.
14899 (l_tracepoint_action_send): New.
14900 (cmd_qtdp): Download and install tracepoint
14901 according to `use_agent'.
14902 (run_inferior_command): Add one more parameter `len'.
14903 Update callers.
14904 (tracepoint_send_agent): New.
14905 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14906
7bc83639
YQ
149072012-04-16 Yao Qi <yao@codesourcery.com>
14908
14909 * tracepoint.c (download_tracepoints): Moved to ...
14910 (cmd_qtstart): ... here.
14911
5f18041e
YQ
149122012-04-14 Yao Qi <yao@codesourcery.com>
14913
14914 * tracepoint.c: Include inttypes.h.
14915 (struct collect_memory_action): Use sized types.
14916 (struct tracepoint): Likewise.
14917 (cmd_qtdp, stop_tracing): Update print specifiers.
14918 (cmd_qtp, response_tracepoint): Likewise.
14919 (collect_data_at_tracepoint): Likewise.
14920 (collect_data_at_step): Likewise.
14921
55a8c076
YQ
149222012-04-14 Yao Qi <yao@codesourcery.com>
14923
14924 Import gnulib module inttypes.
14925 * aclocal.m4, config.in, configure: Regenerated.
14926
dc750257
YQ
149272012-04-14 Yao Qi <yao@codesourcery.com>
14928
14929 * Makefile.in (maintainer-clean, realclean, distclean): Remove
14930 Makefile and config.status at last.
14931
0ab5faf9
YQ
149322012-04-13 Yao Qi <yao@codesourcery.com>
14933
14934 * tracepoint.c: Include stdint.h unconditionally.
14935
18f5fd81
TJB
149362012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14937
14938 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
14939 on BFD_HAVE_SYS_PROCFS_TYPE.
14940 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
14941 * configure: Regenerate.
14942 * config.in: Likewise.
14943
4d47af5c
L
149442012-04-13 H.J. Lu <hongjiu.lu@intel.com>
14945
14946 * Makefile.in (clean): Also remove x32.c x32-linux.c
14947 x32-avx.c x32-avx-linux.c.
14948 (x32.o): New target.
14949 (x32.c): Likewise.
14950 (x32-linux.o): Likewise.
14951 (x32-linux.c): Likewise.
14952 (x32-avx.o): Likewise.
14953 (x32-avx.c): Likewise.
14954 (x32-avx-linux.o): Likewise.
14955 (x32-avx-linux.c): Likewise.
14956
14957 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
14958 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
14959 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
14960 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
14961 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
14962 i386/x32-avx-linux.xml.
14963
14964 * linux-x86-low.c (init_registers_x32_linux): New prototype.
14965 (init_registers_x32_avx_linux): Likwise.
14966 (x86_linux_update_xmltarget): Call init_registers_x32_linux
14967 or init_registers_x32_avx_linux if linux_is_elf64 is false.
14968
ecedbe58
PA
149692012-04-13 Pedro Alves <palves@redhat.com>
14970
14971 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
14972 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
14973 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
14974 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
14975 the sub-make.
14976
c92b5177
L
149772012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14978
14979 * linux-x86-low.c (compat_x32_clock_t): New.
14980 (compat_x32_siginfo_t): Likewise.
14981 (compat_x32_siginfo_from_siginfo): Likewise.
14982 (siginfo_from_compat_x32_siginfo): Likewise.
14983 (linux_is_elf64): Likewise.
14984 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
14985 and siginfo_from_compat_x32_siginfo for x32.
14986 (x86_arch_setup): Set linux_is_elf64.
14987
214d508e
L
149882012-04-12 H.J. Lu <hongjiu.lu@intel.com>
14989
14990 PR gdb/13969
14991 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
14992 e_machine field.
14993 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
14994 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
14995 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
14996 compatible with process.
14997
c9a1864a
YQ
149982012-04-12 Yao Qi <yao@codesourcery.com>
14999
15000 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15001 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15002 (install-only, install-info, clean): Handle sub dir gnulib.
15003 (all-lib, am--refresh): New targets.
15004 (memmem.o): Remove target.
15005 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15006 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15007 (AC_REPLACE_FUNCS): Remove memmem.
15008 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15009 (AC_OUTPUT): Generate Makefile in gnulib/.
15010 * aclocal.m4, config.in, configure: Regenerated.
15011
367ba2c2
MR
150122012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15013
15014 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15015
9d236627
PA
150162012-04-05 Pedro Alves <palves@redhat.com>
15017
15018 -Werror=strict-aliasing
15019
15020 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15021 pointer.
15022
111217b3
PA
150232012-04-04 Pedro Alves <palves@redhat.com>
15024
15025 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15026 (sparc_store_gregset_from_stack, sparc_store_gregset)
15027 (sparc_breakpoint_at): Fix formatting.
15028
8365dcf5
TJB
150292012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15030
15031 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15032 are available.
15033 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15034 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15035 * config.in: Regenerate.
15036 * configure: Likewise.
15037
689cc2ae
PA
150382012-03-29 Pedro Alves <palves@redhat.com>
15039
15040 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15041 Correct ptrace arguments.
15042
c14dfd32
PA
150432012-03-28 Pedro Alves <palves@redhat.com>
15044
15045 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15046 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15047 (IA64_FR1_REGNUM): New defines.
15048 (ia64_fetch_register): New.
15049 (the_low_target): Install it.
15050 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15051 field.
15052 * linux-low.c (linux_fetch_registers): Try the
15053 the_low_target.fetch_register hook first.
15054
15055 * linux-arm-low.c (the_low_target): Adjust.
15056 * linux-bfin-low.c (the_low_target): Adjust.
15057 * linux-cris-low.c (the_low_target): Adjust.
15058 * linux-crisv32-low.c (the_low_target): Adjust.
15059 * linux-m32r-low.c (the_low_target): Adjust.
15060 * linux-m68k-low.c (the_low_target): Adjust.
15061 * linux-mips-low.c (the_low_target): Adjust.
15062 * linux-ppc-low.c (the_low_target): Adjust.
15063 * linux-s390-low.c (the_low_target): Adjust.
15064 * linux-sh-low.c (the_low_target): Adjust.
15065 * linux-sparc-low.c (the_low_target): Adjust.
15066 * linux-tic6x-low.c (the_low_target): Adjust.
15067 * linux-x86-low.c (the_low_target): Adjust.
15068 * linux-xtensa-low.c (the_low_target): Adjust.
15069
63c88e13
PA
150702012-03-26 Pedro Alves <palves@redhat.com>
15071
15072 * server.c (handle_qxfer_libraries): Don't bail early if
15073 the_target->qxfer_libraries_svr4 is not NULL.
15074
fb723180
PA
150752012-03-26 Pedro Alves <palves@redhat.com>
15076
15077 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15078
0afae3cf
PA
150792012-03-23 Pedro Alves <palves@redhat.com>
15080
15081 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15082 "library-list-svr4" element's start tag when the the DSO list is
15083 empty.
15084
485f1ee4
PA
150852012-03-23 Pedro Alves <palves@redhat.com>
15086
15087 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15088 a variable whose type size is the same as the inferior's pointer
15089 size.
15090
a5362b9a
TS
150912012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15092
15093 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15094 struct siginfo.
15095 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15096 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15097 * linux-low.h: Include <signal.h>.
15098 (struct siginfo): Remove forward declaration.
15099 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15100 struct siginfo.
15101
d226c142
MF
151022012-03-21 Mike Frysinger <vapier@gentoo.org>
15103
15104 * .gitignore: Ignore more files.
15105
122f36ef
PA
151062012-03-19 Pedro Alves <palves@redhat.com>
15107 Jan Kratochvil <jan.kratochvil@redhat.com>
15108
15109 * server.c (cont_thread, general_thread): Add describing comments.
15110 (start_inferior): Clear `cont_thread'.
15111 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15112 of a process.
15113
fc3e5175
YQ
151142012-03-15 Yao Qi <yao@codesourcery.com>
15115
15116 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15117 handling to ...
15118 (cmd_qtdp): ... here.
15119
8d0d92cd
YQ
151202012-03-15 Yao Qi <yao@codesourcery.com>
15121
15122 * tracepoint.c (struct tracepoint_action_ops): New.
15123 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15124 (m_tracepoint_action_download): New.
15125 (r_tracepoint_action_download): New.
15126 (x_tracepoint_action_download): New.
15127 (l_tracepoint_action_download): New.
15128 (add_tracepoint_action): Install `action->ops' according type.
15129 (download_tracepoint_1): Move code `download' function pointer
15130 of various tracepoint_action_ops.
15131
87b0bb13
JK
151322012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15133
15134 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15135 linux_ptrace_attach_warnings.
15136
5f572dec
JK
151372012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15138
15139 * Makefile.in (linux-ptrace.o): New.
15140 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15141 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15142 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15143 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15144 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15145 of these targets.
15146 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15147
f4647387
YQ
151482012-03-08 Yao Qi <yao@codesourcery.com>
15149 Pedro Alves <palves@redhat.com>
15150
15151 Fix PR server/13392.
15152 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15153 offset of JMP insn.
15154 * tracepoint.c (remove_tracepoint): New.
15155 (cmd_qtdp): Call remove_tracepoint when failed to install.
15156
9b224c5e
PA
151572012-03-07 Pedro Alves <palves@redhat.com>
15158
15159 * linux-low.c (get_detach_signal): New.
15160 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15161 Pass on pending signals to PTRACE_DETACH. Check the result of the
15162 ptrace call.
15163 * server.c (program_signals, program_signals_p): New.
15164 (handle_general_set): Handle QProgramSignals.
15165 * server.h (program_signals, program_signals_p): Declare.
15166
e237a7e2
JK
151672012-03-05 Pedro Alves <palves@redhat.com>
15168 Jan Kratochvil <jan.kratochvil@redhat.com>
15169
15170 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15171 New comment why.
15172
5808517f
YQ
151732012-03-03 Yao Qi <yao@codesourcery.com>
15174
15175 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15176 agent_look_up_symbols.
15177
58b4daa5
YQ
151782012-03-03 Yao Qi <yao@codesourcery.com>
15179
15180 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15181 (linux-x86-low.o): Likewise.
15182 * server.h: Remove in_process_agent_loaded.
15183 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15184 common/agent.c.
15185 Update callers.
15186
8ffcbaaf
YQ
151872012-03-03 Yao Qi <yao@codesourcery.com>
15188
15189 * tracepoint.c (gdb_agent_capability): New global.
15190 (in_process_agent_loaded_ust): Renamed to
15191 `in_process_agent_supports_ust'.
15192 Update callers.
15193 (in_process_agent_supports_ust): Call agent_capability_check.
15194 (clear_installed_tracepoints): Assert that agent supports
15195 agent.
15196
d1feda86
YQ
151972012-03-03 Yao Qi <yao@codesourcery.com>
15198
15199 * linux-low.c (linux_supports_agent): New.
15200 (linux_target_ops): Initialize field `supports_agent' with
15201 linux_supports_agent.
15202 * target.h (struct target_ops) <supports_agent>: New.
15203 (target_supports_agent): New macro.
15204 * server.c (handle_general_set): Handle packet 'QAgent'.
15205 (handle_query): Send `QAgent+'.
15206 * Makefile.in (server.o): Depends on agent.h.
15207
2fa291ac
YQ
152082012-03-03 Yao Qi <yao@codesourcery.com>
15209
15210 * Makefile.in (OBS): Add agent.o.
15211 Add new rule for agent.o.
15212 Track dependence of tracepoint.c on agent.h.
15213 * tracepoint.c (run_inferior_command_1):
15214 (run_inferior_command): Call agent_run_command.
15215 (gdb_ust_connect_sync_socket): Deleted. Move it to
15216 common/agent.c.
15217 (resume_thread, stop_thread): Likewise.
15218 (gdb_ust_socket_init): Renamed to ...
15219 (gdb_agent_socket_init): ... New.
15220 (gdb_ust_thread): Renamed to ...
15221 (gdb_agent_helper_thread): ... New.
15222 (gdb_ust_init): Move some code to ...
15223 (gdb_agent_init): ... here. New.
15224 [HAVE_UST]: Call gdb_ust_init.
15225 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15226 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15227 * config.in, configure: Regenerated.
15228
05044653
PA
152292012-03-02 Pedro Alves <palves@redhat.com>
15230
15231 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15232 * linux-low.c (struct simple_pid_list): New.
15233 (stopped_pids): New a struct simple_pid_list pointer.
15234 (add_to_pid_list, pull_pid_from_list): New.
15235 (handle_extended_wait): Don't assume the first signal new children
15236 report is SIGSTOP. Adjust call to pull_pid_from_list.
15237 (linux_wait_for_lwp): Adjust.
15238
8d00225b
YQ
152392012-03-02 Yao Qi <yao@codesourcery.com>
15240
15241 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15242 debug log.
15243
19560ba5
YQ
152442012-03-02 Yao Qi <yao@codesourcery.com>
15245
15246 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15247 `stop_pc' and `tpoint'. Update caller.
15248
1faeff08
MR
152492012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15250
15251 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15252 * linux-low.c (use_linux_regsets): New macro.
15253 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15254 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15255 (linux_register_in_regsets): New function.
15256 (usr_fetch_inferior_registers): Skip registers covered by
15257 regsets.
15258 (usr_store_inferior_registers): Likewise.
15259 (usr_fetch_inferior_registers): New macro.
15260 (usr_store_inferior_registers): Likewise.
15261 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15262 (linux_store_registers): Likewise.
15263 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15264 prototype.
15265 (init_registers_mips64_dsp_linux): Likewise.
15266 (init_registers_mips_linux): New macro.
15267 (init_registers_mips_dsp_linux): Likewise.
15268 (mips_dsp_num_regs): Likewise.
15269 (DSP_BASE, DSP_CONTROL): New fallback macros.
15270 (mips_base_regs): New macro.
15271 (mips_regmap): Use it. Fix the size.
15272 (mips_dsp_regmap): New variable.
15273 (mips_dsp_regset_bitmap): Likewise.
15274 (mips_arch_setup): New function.
15275 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15276 than mips_regmap.
15277 (mips_cannot_store_register): Likewise.
15278 (the_low_target): Update .arch_setup, .num_regs and .regmap
15279 initializers. Add .regset_bitmap initializer.
15280 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15281 initializer.
15282 * linux-bfin-low.c (the_low_target): Likewise.
15283 * linux-cris-low.c (the_low_target): Likewise.
15284 * linux-crisv32-low.c (the_low_target): Likewise.
15285 * linux-ia64-low.c (the_low_target): Likewise.
15286 * linux-m32r-low.c (the_low_target): Likewise.
15287 * linux-m68k-low.c (the_low_target): Likewise.
15288 * linux-ppc-low.c (the_low_target): Likewise.
15289 * linux-s390-low.c (the_low_target): Likewise.
15290 * linux-sh-low.c (the_low_target): Likewise.
15291 * linux-sparc-low.c (the_low_target): Likewise.
15292 * linux-tic6x-low.c (the_low_target): Likewise.
15293 * linux-x86-low.c (the_low_target): Likewise.
15294 * linux-xtensa-low.c (the_low_target): Likewise.
15295 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15296 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15297 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15298 srv_xmlfiles.
15299 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15300 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15301
c03e6ccc
YQ
153022012-02-29 Yao Qi <yao@codesourcery.com>
15303 Pedro Alves <palves@redhat.com>
15304
15305 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15306 `step_over_finished' is true.
15307
644cebc9
PA
153082012-02-27 Pedro Alves <palves@redhat.com>
15309
15310 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15311 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15312
c14d7ab2
PA
153132012-02-27 Pedro Alves <palves@redhat.com>
15314
15315 PR server/9684
15316 * linux-low.c (pid_is_stopped): New.
15317 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15318
412c89dd
LM
153192012-02-25 Luis Machado <lgustavo@codesourcery.com>
15320
15321 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15322 of conditions.
15323
b745defe
MR
153242012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15325
15326 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15327
9f3a5c85
LM
153282012-02-24 Luis Machado <lgustavo@codesourcery>
15329
15330 * server.c (handle_query): Advertise support for target-side
15331 breakpoint condition evaluation.
15332 (process_point_options): New function.
15333 (process_serial_event): When inserting a breakpoint, check for
15334 a target-side condition that should be evaluated.
15335
15336 * mem-break.c: Include regcache.h and ax.h.
15337 (point_cond_list_t): New data structure.
15338 (breakpoint) <cond_list>: New field.
15339 (find_gdb_breakpoint_at): Make non-static.
15340 (delete_gdb_breakpoint_at): Clear any target-side
15341 conditions.
15342 (clear_gdb_breakpoint_conditions): New function.
15343 (add_condition_to_breakpoint): Likewise.
15344 (add_breakpoint_condition): Likewise.
15345 (gdb_condition_true_at_breakpoint): Likewise.
15346 (gdb_breakpoint_here): Return result directly instead
15347 of going through a local variable.
15348
15349 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15350 (clear_gdb_breakpoint_conditions): Likewise.
15351 (add_breakpoint_condition): Likewise.
15352 (gdb_condition_true_at_breakpoint): Likewise.
15353
15354 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15355 (need_step_over_p): Take target-side breakpoint condition into
15356 consideration.
15357
5e1dc496
LM
153582012-02-24 Luis Machado <lgustavo@codesourcery>
15359
15360 * server.h: Include tracepoint.h.
15361 (agent_mem_read, agent_get_trace_state_variable_value,
15362 agent_set_trace_state_variable_value,
15363 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15364 get_set_tsv_func_addr): New prototypes.
15365
15366 * ax.h: New include file.
15367 * ax.c: New source file.
15368
15369 * tracepoint.c: Include ax.h.
15370 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15371 agent_expr, eval_result_type): Move to ax.h.
15372 (parse_agent_expr): Rename to ...
15373 (gdb_parse_agent_expr): ... this, make it non-static and move
15374 to ax.h.
15375 (unparse_agent_expr) Rename to ...
15376 (gdb_unparse_agent_expr): ... this, make it non-static and move
15377 to ax.h.
15378 (eval_agent_expr): Rename to ...
15379 (eval_tracepoint_agent_expr): ... this.
15380 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15381 forward declarations.
15382 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15383 (agent_get_trace_state_variable_value): New function.
15384 (agent_set_trace_state_variable_value): New function.
15385 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15386 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15387 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15388 (condition_true_at_tracepoint): Likewise.
15389 (parse_agent_expr): Rename to ...
15390 (gdb_parse_agent_expr): ... this and move to ax.c.
15391 (unparse_agent_expr): Rename to ...
15392 (gdb_unparse_agent_expr): ... this and move to ax.c.
15393 (gdb_agent_op_name): Move to ax.c.
15394 (eval_agent_expr): Rename to ...
15395 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15396 and move to ax.c.
15397 (eval_tracepoint_agent_expr): New function.
15398 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 15399 non-static.
5e1dc496
LM
15400 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15401 ax.c.
15402 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15403 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15404 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15405 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15406 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15407 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15408 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15409 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15410 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15411 (compile_bytecodes): Remove forward declaration.
15412 (is_goto_target): Move to ax.c.
15413 (compile_bytecodes): Move to ax.c and call
15414 agent_get_trace_state_variable_value (...) and
15415 agent_set_trace_state_variable_value (...).
15416
15417 * Makefile.in: Update ax.c and IPA dependencies.
15418
277e4e52
PA
154192012-02-24 Pedro Alves <palves@redhat.com>
15420
15421 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15422 (cmd_bigqtbuffer_circular): ... this. Only handle
15423 'QTBuffer:circular:'.
15424 (handle_tracepoint_general_set): Adjust.
15425
bf4c19f7
YQ
154262012-02-16 Yao Qi <yao@codesourcery.com>
15427
15428 * inferiors.c: Move code to ...
15429 * dll.c: .... here. New.
15430 * server.h: Declare clear_dlls.
15431 * Makefile.in (SFILES): Add dll.c.
15432 (OBS): Add dll.o
15433 (dll.o): New rule.
15434
d73f2619
YQ
154352012-02-11 Yao Qi <yao@codesourcery.com>
15436
15437 * server.c: (handle_monitor_command): Add a new parameter
15438 `own_buf'.
15439 (handle_query): Update caller.
15440
f8255c2a
JB
154412012-02-09 Joel Brobecker <brobecker@adacore.com>
15442
15443 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15444 * configure, config.in: Regenerate.
15445 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15446 is not defined.
15447
da84f473
PA
154482012-02-02 Pedro Alves <palves@redhat.com>
15449
15450 Try SIGKILL first, then PTRACE_KILL.
15451 * linux-low.c (linux_kill_one_lwp): New.
15452 (linux_kill_one_lwp): Rename to ...
15453 (kill_one_lwp_callback): ... this. Use the new
15454 linux_kill_one_lwp.
15455
e886a173
PA
154562012-02-02 Pedro Alves <palves@redhat.com>
15457
15458 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15459 inferior.
15460
be07f1a2
PA
154612012-01-27 Pedro Alves <palves@redhat.com>
15462
15463 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15464 (elf_64_file_p): Make static.
15465 (linux_pid_exe_is_elf_64_file): New.
15466 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15467 Delete declarations.
15468 (linux_pid_exe_is_elf_64_file): Declare.
15469 * linux-x86-low.c (x86_arch_setup): Use
15470 linux_pid_exe_is_elf_64_file.
15471
d8301ad1
JK
154722012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15473
15474 * linux-low.c (linux_wait_for_event_1): Rename to ...
15475 (linux_wait_for_event): ... here and merge it with former
15476 linux_wait_for_event - new variable wait_ptid, use it.
15477 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15478
01b17894
PA
154792012-01-23 Pedro Alves <palves@redhat.com>
15480
15481 * server.c (main): Avoid yet another case of infinite loop while
15482 detaching/killing after a longjmp.
15483
e825046f
JK
154842012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15485
15486 Code cleanup.
15487 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15488
b9e7b9c3
UW
154892012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15490
15491 * hostio.c (handle_readlink): New function.
15492 (handle_vFile): Call it to handle "vFile:readlink" packets.
15493
901f9912
UW
154942012-01-20 Pedro Alves <palves@redhat.com>
15495 Ulrich Weigand <ulrich.weigand@linaro.org>
15496
15497 * server.c (handle_v_requests): Only support vAttach and vRun to
15498 start multiple processes when in extended protocol mode.
15499
fc1ab1a0
PA
155002012-01-17 Pedro Alves <palves@redhat.com>
15501
15502 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15503 memalign plus mprotect to allocate the scratch buffer.
15504
7d5d4e98
PA
155052012-01-13 Pedro Alves <palves@redhat.com>
15506
15507 * server.c (attach_inferior): Clear `cont_thread'.
15508
f128d5e9
PA
155092012-01-13 Pedro Alves <palves@redhat.com>
15510
15511 * server.c (main): Avoid infinite loop while detaching/killing
15512 after a longjmp.
15513
06db92f0
DE
155142012-01-09 Doug Evans <dje@google.com>
15515
15516 * server.c (start_inferior): Set last_ptid in --wrapper case.
15517
32d92999
YQ
155182012-01-06 Yao Qi <yao@codesourcery.com>
15519
15520 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15521 defined.
15522 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15523
5e0a92a9
YQ
155242012-01-04 Yao Qi <yao@codesourcery.com>
15525
15526 * tracepoint.c (cmd_qtdp): Print debug message
15527 for static tracepoint.
15528
ae639e8c
YQ
155292012-01-04 Yao Qi <yao@codesourcery.com>
15530
15531 * tracepoint.c (trace_vdebug): Differentiate debug message
15532 between gdbserver and IPA.
15533
f72429c5
YQ
155342012-01-03 Yao Qi <yao@codesourcery.com>
15535
15536 * tracepoint.c (tracepoint_was_hit): Don't collect for
15537 static tracepoint.
15538
12c3e59c
JB
155392012-01-02 Joel Brobecker <brobecker@adacore.com>
15540
15541 * terminal.h: Reformat copyright header.
15542
67827812
JB
155432012-01-02 Joel Brobecker <brobecker@adacore.com>
15544
15545 * server.c (gdbserver_version): Update copyright year.
15546 * gdbreplay.c (gdbreplay_version): Likewise.
15547
3e52c33d
JK
155482011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15549
15550 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15551
15552 Revert:
15553 2011-12-18 Hui Zhu <teawater@gmail.com>
15554 * linux-low.c (linux_create_inferior): Save return value to ret.
15555
66f1260e
HZ
155562011-12-18 Hui Zhu <teawater@gmail.com>
15557
15558 * linux-low.c (linux_create_inferior): Save return value to ret.
15559
e77616d7
DE
155602011-12-16 Doug Evans <dje@google.com>
15561
e7b06c57
DE
15562 * linux-low.c (linux_create_inferior): If stdio connection,
15563 redirect stdin from /dev/null, stdout to stderr.
15564 * remote-utils.c (remote_is_stdio): New static global.
15565 (remote_connection_is_stdio): New function.
15566 (remote_prepare): Handle stdio connection.
15567 (remote_open): Ditto.
15568 (remote_close): Don't close stdin for stdio connections.
15569 (read_prim,write_prim): New functions. Replace all calls to
15570 read/write to these.
15571 * server.c (main): Watch for "-" argument. Move call to
15572 remote_prepare before start_inferior.
15573 * server.h (STDIO_CONNECTION_NAME): New macro.
15574 (remote_connection_is_stdio): Declare.
15575
e77616d7
DE
15576 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15577 in debugging output.
15578
82067193
YQ
155792011-12-15 Yao Qi <yao@codesourcery.com>
15580
15581 * tracepoint.c: Include sys/syscall.h.
15582 (gdb_ust_thread): Remove preprocessor conditional.
15583
82bfbe7e
PA
155842011-12-14 Pedro Alves <pedro@codesourcery.com>
15585
15586 * linux-low.c (linux_detach_one_lwp): Call
15587 the_low_target.prepare_to_resume before detaching.
15588
712c6575
YQ
155892011-12-14 Yao Qi <yao@codesourcery.com>
15590
15591 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15592 of write.
15593
d54d1edf
YQ
155942011-12-14 Yao Qi <yao@codesourcery.com>
15595
15596 * i386-low.c (i386_low_stopped_data_address): Initialize local
15597 variable `control'.
15598
6210a125
PA
155992011-12-13 Pedro Alves <pedro@codesourcery.com>
15600
15601 PR remote/13492
15602
15603 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15604 DR_CONTROL unless necessary. Extend comments.
15605 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15606 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15607
2ece8244
YQ
156082011-12-13 Yao Qi <yao@codesourcery.com>
15609
15610 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15611 macros.
15612 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15613
784867a5
JK
156142011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15615
15616 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15617 Print new debug message for such case.
15618
6bf36717
JK
156192011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15620
15621 Fix overlapping memcpy.
15622 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15623 the read_inferior_memory transfer.
15624 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15625 write_inferior_memory transfer.
15626 (set_fast_tracepoint_jump): New variable buf. Use it for the
15627 read_inferior_memory and write_inferior_memory transfers.
15628 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15629 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15630 Use it for the write_inferior_memory transfer.
15631 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15632 buffers.
15633
50275556
MR
156342011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15635
15636 * linux-low.c (fetch_register, store_register): Make code
15637 consistent, fix formatting.
15638
7325beb4
MR
156392011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15640
15641 * linux-low.c (usr_store_inferior_registers): Factor out code
15642 to handle individual registers into...
15643 (store_register): ... this new function.
15644
c642a434
UW
156452011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15646
15647 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15648 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15649 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15650 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15651 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15652 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15653 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15654 (srv_xmlfiles): Add new XML files.
15655
15656 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15657 and <sys/uio.h>.
15658 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15659 (init_registers_s390_linux32v1): Add prototype.
15660 (init_registers_s390_linux32v2): Likewise.
15661 (init_registers_s390_linux64v1): Likewise.
15662 (init_registers_s390_linux64v2): Likewise.
15663 (init_registers_s390x_linux64v1): Likewise.
15664 (init_registers_s390x_linux64v2): Likewise.
15665 (s390_num_regs): Increment to 52.
15666 (s390_regmap): Add orig_r2 register.
15667 (s390_num_regs_3264): Increment to 68.
15668 (s390_regmap_3264): Add orig_r2 register.
15669 (s390_collect_ptrace_register): Handle orig_r2 register.
15670 (s390_supply_ptrace_register): Likewise.
15671 (s390_fill_last_break): New function.
15672 (s390_store_last_break): Likewise.
15673 (s390_fill_system_call): New function.
15674 (s390_store_system_call): Likewise.
15675 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15676 register sets.
15677 (s390_check_regset): New function.
15678 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15679 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15680 Update target_regsets for available register sets.
15681
2268b414
JK
156822011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15683 Jan Kratochvil <jan.kratochvil@redhat.com>
15684
15685 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15686 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15687 New.
15688 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15689 * linux-low.h (struct process_info_private): New member r_debug.
15690 * server.c (handle_qxfer_libraries): Call
15691 the_target->qxfer_libraries_svr4.
15692 (handle_qxfer_libraries_svr4): New function.
15693 (qxfer_packets): New entry "libraries-svr4".
15694 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15695 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15696 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15697 PACKET_qXfer_libraries_svr4.
15698
d6db1fab
UW
156992011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15700
15701 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15702 PSW address/mask between 8-byte and 16-byte formats.
15703 (s390_supply_ptrace_register): Likewise.
15704 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15705 basic addressing mode bit.
15706
242f5f1c
SS
157072011-11-24 Stan Shebs <stan@codesourcery.com>
15708
15709 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15710
f196051f
SS
157112011-11-17 Stan Shebs <stan@codesourcery.com>
15712
15713 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15714 (tracing_start_time): New global.
15715 (tracing_stop_time): New global.
15716 (tracing_user_name): New global.
15717 (tracing_notes): New global.
15718 (tracing_stop_note): New global.
15719 (cmd_qtstart): Set traceframe_usage, start_time.
15720 (stop_tracing): Set stop_time.
15721 (cmd_qtstatus): Report additional status.
15722 (cmd_qtp): New function.
15723 (handle_tracepoint_query): Call it.
15724 (cmd_qtnotes): New function.
15725 (handle_tracepoint_general_set): Call it.
15726 (get_timestamp): Rename from tsv_get_timestamp.
15727
405f8e94
SS
157282011-11-14 Stan Shebs <stan@codesourcery.com>
15729 Kwok Cheung Yeung <kcy@codesourcery.com>
15730
15731 * linux-x86-low.c (small_jump_insn): New.
15732 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15733 trampoline and error message, build a trampoline and issue a small
15734 jump instruction to it.
15735 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15736 trampoline and error message.
15737 (x86_get_min_fast_tracepoint_insn_len): New.
15738 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15739 * linux-low.h (struct linux_target_ops): Add arguments to
15740 install_fast_tracepoint_jump_pad operation, add new operation.
15741 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15742 arguments.
15743 (linux_get_min_fast_tracepoint_insn_len): New function.
15744 (linux_target_op): Add new operation.
15745 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15746 (gdb_trampoline_buffer_end): Ditto.
15747 (gdb_trampoline_buffer_error): Ditto.
15748 (struct ipa_sym_addresses): Add fields for new IPA variables.
15749 (symbol_list): Add entries for new IPA variables.
15750 (struct tracepoint): Add fields to hold the address range of the
15751 trampoline used by the tracepoint.
15752 (trampoline_buffer_head): New static variable.
15753 (trampoline_buffer_tail): Ditto.
15754 (claim_trampoline_space): New function.
15755 (have_fast_tracepoint_trampoline_buffer): New function.
15756 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15757 structure.
15758 (install_fast_tracepoint): Ditto, also add error buffer argument.
15759 (cmd_qtminftpilen): New function.
15760 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15761 (fast_tracepoint_from_trampoline_address): New function.
15762 (fast_tracepoint_collecting): Handle trampoline as part of jump
15763 pad space.
15764 (set_trampoline_buffer_space): New function.
15765 (initialize_tracepoint): Initialize new IPA variables.
15766 * target.h (struct target_ops): Add arguments to
15767 install_fast_tracepoint_jump_pad operation, add new
15768 get_min_fast_tracepoint_insn_len operation.
15769 (target_get_min_fast_tracepoint_insn_len): New.
15770 (install_fast_tracepoint_jump_pad): Add arguments.
15771 * server.h (IPA_BUFSIZ): Define.
15772 * linux-i386-ipa.c: Include extra header files.
15773 (initialize_fast_tracepoint_trampoline_buffer): New function.
15774 (initialize_low_tracepoint): Call it.
15775 * server.h (set_trampoline_buffer_space): Declare.
15776 (claim_trampoline_space): Ditto.
15777 (have_fast_tracepoint_trampoline_buffer): Ditto.
15778
1e4d1764
YQ
157792011-11-14 Yao Qi <yao@codesourcery.com>
15780
15781 * server.c (handle_query): Handle InstallInTrace for qSupported.
15782 * tracepoint.c (add_tracepoint): Sort list.
15783 (install_tracepoint, download_tracepoint): New.
15784 (cmd_qtdp): Call them to install and download tracepoints.
15785 (sort_tracepoints): Removed.
15786 (cmd_qtstart): Update.
15787
5c73ff4e
YQ
157882011-11-14 Yao Qi <yao@codesourcery.com>
15789
15790 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15791 * mem-break.h: Declare.
15792 * tracepoint.c (cmd_qtstart): Move some code to ...
15793 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15794 New.
15795 (download_tracepoints): Move some code to ...
15796 (download_tracepoint_1): ... here. New.
15797
86a30030
YQ
157982011-11-08 Yao Qi <yao@codesourcery.com>
15799
15800 * remote-utils.c (relocate_instruction): A comment fix.
15801
8d26e50c
JB
158022011-11-07 Joel Brobecker <brobecker@adacore.com>
15803
15804 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15805 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15806 dr_status_mirror and dr_control_mirror from debug_reg_state.
15807 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15808 (i386_initial_stuff): Remove use of deleted globals.
15809 (i386_get_thread_context, i386_set_thread_context,
15810 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15811 from debug_reg_state.
15812
a59306a3
YQ
158132011-11-05 Yao Qi <yao@codesourcery.com>
15814
15815 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15816 address as TPOINT's.
15817
3065dfb6
SS
158182011-11-02 Stan Shebs <stan@codesourcery.com>
15819
15820 * tracepoint.c (agent_mem_read_string): New function.
15821 (eval_agent_expr): Call it for tracenz.
15822 * server.c (handle_query): Report support for tracenz.
15823
fd0d8c7c
YQ
158242011-11-02 Yao Qi <yao@codesourcery.com>
15825
15826 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15827
609086b1
YQ
158282011-11-02 Yao Qi <yao@codesourcery.com>
15829
15830 * target.h: Fix a typo in comment.
15831
b9fd1791
PA
158322011-10-31 Pedro Alves <pedro@codesourcery.com>
15833
15834 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15835 clobber the breakpoints' shadows with fast tracepoint jumps.
15836 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15837 * target.c (write_inferior_memory): Also pass MYADDR down to
15838 check_mem_write.
15839
03583c20
UW
158402011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15841
15842 * configure.ac: Check support for personality routine.
15843 * configure: Regenerate.
15844 * config.in: Likewise.
15845 * linux-low.c: Include <sys/personality.h>.
15846 Define ADDR_NO_RANDOMIZE if necessary.
15847 (linux_create_inferior): Disable address space randomization when
15848 forking inferior, if requested.
15849 (linux_supports_disable_randomization): New function.
15850 (linux_target_ops): Install it.
15851 * server.h (disable_randomization): Declare.
15852 * server.c (disable_randomization): New global variable.
15853 (handle_general_set): Handle QDisableRandomization.
15854 (handle_query): Likewise for qSupported.
15855 (main): Support --disable-randomization and --no-disable-randomization
15856 command line arguments.
15857 * target.h (struct target_ops): Add supports_disable_randomization.
15858 (target_supports_disable_randomization): New macro.
15859
723b724b
MF
158602011-09-29 Mike Frysinger <vapier@gentoo.org>
15861
15862 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15863 ifdef check.
15864 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15865 [!PT_GETDSBT] (target_loadmap): New definition.
15866 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15867 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15868 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15869 and PT_GETDSBT to LINUX_LOADMAP.
15870 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15871 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15872
55329a5c 158732011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
15874
15875 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15876 (arm_linux_hwbp_cap): New static variable.
15877 (arm_linux_get_hwbp_cap): Replace by ...
15878 (arm_linux_init_hwbp_cap): ... this new function.
15879 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15880 (arm_linux_get_hw_watchpoint_count): Likewise.
15881 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15882 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15883 (arm_prepare_to_resume): Use perror_with_name instead of error.
15884
55329a5c 158852011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
15886
15887 * linux-arm-low.c: Include <signal.h>.
15888 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15889 (struct arm_linux_hwbp_cap): New data type.
15890 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15891 (struct arm_linux_hw_breakpoint): New data type.
15892 (MAX_BPTS, MAX_WPTS): Define.
15893 (struct arch_process_info, struct arch_lwp_info): New data types.
15894 (arm_linux_get_hwbp_cap): New function.
15895 (arm_linux_get_hw_breakpoint_count): Likewise.
15896 (arm_linux_get_hw_watchpoint_count): Likewise.
15897 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15898 (arm_hwbp_control_initialize): Likewise.
15899 (arm_hwbp_control_is_enabled): Likewise.
15900 (arm_hwbp_control_is_initialized): Likewise.
15901 (arm_hwbp_control_disable): Likewise.
15902 (arm_linux_hw_breakpoint_equal): Likewise.
15903 (arm_linux_hw_point_initialize): Likewise.
15904 (struct update_registers_data): New data structure.
15905 (update_registers_callback: New function.
15906 (arm_insert_point): Likewise.
15907 (arm_remove_point): Likewise.
15908 (arm_stopped_by_watchpoint): Likewise.
15909 (arm_stopped_data_address): Likewise.
15910 (arm_new_process): Likewise.
15911 (arm_new_thread): Likewise.
15912 (arm_prepare_to_resume): Likewise.
15913 (the_low_target): Register arm_insert_point, arm_remove_point,
15914 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15915 arm_new_thread, and arm_prepare_to_resume.
15916
6b9801d4
SS
159172011-09-15 Stan Shebs <stan@codesourcery.com>
15918
15919 * server.h (struct emit_ops): Add compare-goto fields.
15920 * tracepoint.c (gdb_agent_op_sizes): New table.
15921 (emit_eq_goto): New function.
15922 (emit_ne_goto): New function.
15923 (emit_lt_goto): New function.
15924 (emit_le_goto): New function.
15925 (emit_gt_goto): New function.
15926 (emit_ge_goto): New function.
15927 (is_goto_target): New function.
15928 (compile_bytecodes): Recognize special cases of compare-goto
15929 combinations and call specialized emitters for them.
15930 * linux-x86-low.c (amd64_emit_eq_goto): New function.
15931 (amd64_emit_ne_goto): New function.
15932 (amd64_emit_lt_goto): New function.
15933 (amd64_emit_le_goto): New function.
15934 (amd64_emit_gt_goto): New function.
15935 (amd64_emit_ge_goto): New function.
15936 (amd64_emit_ops): Add the new functions.
15937 (i386_emit_eq_goto): New function.
15938 (i386_emit_ne_goto): New function.
15939 (i386_emit_lt_goto): New function.
15940 (i386_emit_le_goto): New function.
15941 (i386_emit_gt_goto): New function.
15942 (i386_emit_ge_goto): New function.
15943 (i386_emit_ops): Add the new functions.
15944
bf15cbda
SS
159452011-09-08 Stan Shebs <stan@codesourcery.com>
15946
15947 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
15948 (i386_emit_epilogue): Restore %ebx.
15949
943ca1dd
JZ
159502011-08-31 Jie Zhang <jzhang918@gmail.com>
15951
15952 * server.c (step_thread): Remove definition.
15953 (process_serial_event): Don't handle Hs.
15954 * server.h (step_thread): Remove declaration.
15955 * target.c (set_desired_inferior): Remove use of step_thread.
15956
e3deef73
LM
159572011-08-24 Luis Machado <lgustavo@codesourcery.com>
15958
15959 * linux-low.c: Include linux-procfs.h.
15960 (linux_attach_lwp_1): Update comments.
15961 (linux_attach): Scan for existing threads when attaching to a
15962 process that is the tgid.
15963 * Makefile.in: Update dependencies.
15964
13da1c97
LM
159652011-08-24 Luis Machado <lgustavo@codesourcery.com>
15966
15967 * configure.srv: Add linux-procfs.o dependencies.
15968
881127c9
YQ
159692011-08-14 Yao Qi <yao@codesourcery.com>
15970
15971 * target.h (struct target_ops): Fix indent.
15972 * win32-low.c (win32_target_ops): Fix comment.
15973
58dbd541
YQ
159742011-08-14 Andrew Jenner <andrew@codesourcery.com>
15975 Yao Qi <yao@codesourcery.com>
15976
15977 * Makefile.in (clean): Remove tic6x-*.c files.
15978 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
15979 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
15980 (tic6x-c64xp-linux.c): Likewise.
15981 * configure.srv: Add support for tic6x-*-uclinux.
15982 * linux-tic6x-low.c: New.
15983 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
15984
78d85199
YQ
159852011-08-14 Andrew Stubbs <ams@codesourcery.com>
15986 Yao Qi <yao@codesourcery.com>
15987
15988 * target.h (struct target_ops): Add read_loadmap.
15989 * linux-low.c (struct target_loadseg): New type.
15990 (struct target_loadmap): New type.
15991 (linux_read_loadmap): New function.
15992 (linux_target_ops): Add linux_read_loadmap.
15993 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
15994 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
15995 to NULL.
78d85199 15996
a959a88d
EZ
159972011-08-05 Eli Zaretskii <eliz@gnu.org>
15998
15999 * win32-low.c: Include <stdint.h>.
16000
1ced966e
PA
160012011-07-22 Pedro Alves <pedro@codesourcery.com>
16002
16003 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16004 to the inferior here.
16005 (i386_remove_aligned_watchpoint): Ditto.
16006 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16007 fit part of the watchpoint in the debug registers.
16008 (i386_update_inferior_debug_regs): New.
16009 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16010 registers, and only update the inferior on success.
16011 (i386_low_remove_watchpoint): Ditto.
16012
d26e3629
KY
160132011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16014
16015 * linux-low.c (compare_ints, unique, list_threads, show_process,
16016 linux_core_of_thread): Delete.
16017 (linux_target_ops): Change linux_core_of_thread to
16018 linux_common_core_of_thread.
16019 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16020 * utils.c (malloc_failure): Change type of argument.
16021 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16022 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16023 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16024 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16025 (IPA_OBJS): Add common-utils-ipa.o.
16026 (ptid_h, linux_osdata_h): New macros.
16027 (server_h): Add common/common-utils.h, common/xml-utils.h,
16028 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16029 common/ptid.h.
16030 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16031 ptid.o, buffer.o): New rules.
16032 (linux-low.o): Add common/linux-osdata.h as a dependency.
16033 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16034 * configure.ac: Add AC_HEADER_DIRENT check.
16035 * config.in: Regenerate.
16036 * configure: Regenerate.
16037 * remote-utils.c (xml_escape_text): Delete.
16038 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16039 buffer_xml_printf): Move to common/buffer.c.
16040 * server.c (main): Remove call to initialize_inferiors.
16041 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16042 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16043 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16044 internal_error, gdb_assert, gdb_assert_fail): Delete.
16045 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16046 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16047 common/buffer.h.
16048 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16049 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16050 initialize_inferiors): Delete.
16051
2275a1a7
PA
160522011-07-20 Pedro Alves <pedro@codesourcery.com>
16053
16054 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16055 symbol error.
16056
0a5b1e09
PA
160572011-05-31 Pedro Alves <pedro@codesourcery.com>
16058
16059 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16060 assertion.
16061 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16062
6938fd34
YQ
160632011-05-26 Yao Qi <yao@codesourcery.com>
16064
16065 * Makefile.in (thread-db.o): Track dependence to
16066 common/gdb_thread_db.h.
16067 * thread-db.c: include gdb_thread_db.h from right place.
16068
b481f9e0
TT
160692011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16070
16071 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16072 __FILE__ and __LINE__ to internal_error.
16073
98a5dd13
DE
160742011-05-13 Doug Evans <dje@google.com>
16075
16076 * thread-db.c (try_thread_db_load_from_sdir): New function.
16077 (try_thread_db_load_from_dir): New function.
16078 (thread_db_load_search): Handle $sdir, ignore $pdir.
16079 Remove trying of system directories if search of
16080 libthread-db-search-path fails, that is now done via $sdir.
16081
d248b706
KY
160822011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16083
16084 * server.c (handle_query): Add EnableDisableTracepoints to the list
16085 of supported features.
43aaf8b6 16086 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 16087 tracepoints.
43aaf8b6
PA
16088 (cmd_qtenable_disable): New.
16089 (cmd_qtstart): Install tracepoints even if disabled.
16090 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16091 receiving a QTEnable or QTDisable packet.
16092 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16093 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16094 tracepoints.
16095 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 16096
84e578fb
DE
160972011-05-10 Doug Evans <dje@google.com>
16098
16099 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16100
71f55dd8
DE
161012011-05-04 Doug Evans <dje@google.com>
16102
16103 * linux-low.c (linux_join): Skip process lookup.
16104 * spu-low.c (spu_join): Ditto.
16105 * server.c (join_inferiors_callback): Delete.
16106 (process_serial_event): For 'D' packet (detach) call join_inferior
16107 directly.
16108
4d393d60
JM
161092011-05-04 Joseph Myers <joseph@codesourcery.com>
16110
16111 * README: Don't mention xscale*-*-linux*.
16112 * configure.srv (xscale*-*-linux*): Don't handle target.
16113
b00ad6ff
NF
161142011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16115
16116 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16117 casting pointers.
16118 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16119 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16120 (i386_emit_void_call_2): Likewise.
16121
af96c192
YQ
161222011-04-26 Yao Qi <yao@codesourcery.com>
16123
43aaf8b6
PA
16124 * linux-low.c: Move common macros to linux-ptrace.h.
16125 Include linux-ptrace.h.
af96c192
YQ
16126 * Makefile.in (linux_ptrace_h): New.
16127 (linux-low.o): Depends on linux-ptrace.h.
16128
03f2bd59
JK
161292011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16130
16131 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16132 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16133 (remote_prepare): New function with most of the TCP code from ...
16134 (remote_open): ... here. Detect PORT here unconditionally. Move also
16135 setting transport_is_reliable.
16136 * server.c (run_once): New variable.
16137 (gdbserver_usage): Document it.
16138 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16139 the first run if RUN_ONCE.
16140 * server.h (run_once, remote_prepare): New declarations.
16141
7a9dd1b2
TT
161422011-04-19 Tom Tromey <tromey@redhat.com>
16143
16144 * win32-low.c (handle_load_dll): Remove duplicate "the".
16145
81239425
PM
161462011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16147
16148 Remove support for old Cygwin 1.5 versions.
16149 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16150 function to avoid warning.
16151 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16152 warning.
16153
9e0627f1
PM
161542011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16155
16156 * gdbserver/server.h (Macro _): Define it if not available.
16157
588eebee
MS
161582011-03-14 Michael Snyder <msnyder@vmware.com>
16159
348af9f7 16160 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 16161
43f70d4c
JB
161622011-03-10 Joel Brobecker <brobecker@adacore.com>
16163
16164 * Makefile.in (maintainer-clean realclean distclean): Remove
16165 "make ... subdir_do" command.
16166
348af9f7
MS
161672011-03-10 Michael Snyder <msnyder@vmware.com>
16168
16169 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16170
16171 * server.c (handle_v_run): Free alloced buffer on early return.
16172
e637a4f5
YQ
161732011-03-09 Yao Qi <yao@codesourcery.com>
16174
16175 Revert:
16176 2011-03-04 Yao Qi <yao@codesourcery.com>
16177
16178 * Makefile.in: Remove GNU make feature --directory.
16179
16180 2011-03-05 Yao Qi <yao@codesourcery.com>
16181
16182 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16183 (subdir_do): New make target. Copied from gdb/Makefile.
16184 (maintainer-clean, realclean, distclean, clean): Call corresponding
16185 make targets in common/Makefile.
16186
16187 2011-02-11 Yao Qi <yao@codesourcery.com>
16188
16189 * configure.ac: Call AC_PROG_RANLIB.
16190 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16191 * configure: Regenerate.
16192
e6edda56
JK
161932011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16194
16195 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16196
e5141119
JB
161972011-03-06 Yao Qi <yao@codesourcery.com>
16198
16199 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16200
64794aa4
JB
162012011-03-05 Yao Qi <yao@codesourcery.com>
16202
16203 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16204 (subdir_do): New make target. Copied from gdb/Makefile.
16205 (maintainer-clean, realclean, distclean, clean): Call corresponding
16206 make targets in common/Makefile.
16207
7a762829
YQ
162082011-03-04 Yao Qi <yao@codesourcery.com>
16209
16210 * Makefile.in: Remove GNU make feature --directory.
16211
348af9f7
MS
162122011-03-04 Michael Snyder <msnyder@vmware.com>
16213
16214 * server.c (queue_stop_reply): Call xmalloc not malloc.
16215
162162011-03-02 Michael Snyder <msnyder@vmware.com>
16217
16218 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16219
9f72fee2
MS
162202011-02-28 Michael Snyder <msnyder@vmware.com>
16221
588eebee
MS
16222 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16223 (cmd_qtframe): Ditto.
16224 (cmd_qtbuffer): Ditto.
16225 (cmd_bigqtbuffer): Ditto.
16226
9f72fee2
MS
16227 * utils.c (decimal2str): Initialize 'width' to nine, then
16228 don't mess with it.
16229
8040bd49
UW
162302011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16231
16232 * hostio.c (require_data): Free *data, not data.
16233
7e52cbd0
JK
162342011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16235
16236 * hostio.c (require_data): Use free, not xfree.
16237
9130f83e
MS
162382011-02-27 Michael Snyder <msnyder@vmware.com>
16239
4b812f4e
MS
16240 * server.c (handle_query): Discard unused value.
16241
9130f83e
MS
16242 * hostio.c (require_data): Free malloc memory before returning
16243 error.
16244
69d37113
MS
162452011-02-26 Michael Snyder <msnyder@vmware.com>
16246
16247 * linux-low.c (list_threads): Call closedir for dirent.
16248
35f5825a
MS
162492011-02-27 Michael Snyder <msnyder@vmware.com>
16250
2a589cef
MS
16251 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16252 a case statement falls through.
16253
0adea5f7
MS
16254 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16255
35f5825a
MS
16256 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16257 in comparison.
16258
238f1c74
MS
162592011-02-26 Michael Snyder <msnyder@vmware.com>
16260
16261 * utils.c (decimal2str): Eliminate dead code and dead param.
16262 (pulongest): Drop dead param from call to decimal2str.
16263 (plongest): Ditto.
16264
633ff500
JB
162652011-02-24 Joel Brobecker <brobecker@adacore.com>
16266
16267 Revert the following patch (not approved yet):
16268 2011-02-21 Hui Zhu <teawater@gmail.com>
16269 * tracepoint.c (tp_printf): New function.
16270 (eval_agent_expr): Handle gdb_agent_op_printf.
16271
f9c6ff72
HZ
162722011-02-21 Hui Zhu <teawater@gmail.com>
16273
16274 * tracepoint.c (tp_printf): New function.
16275 (eval_agent_expr): Handle gdb_agent_op_printf.
16276
94d5e490
TT
162772011-02-18 Tom Tromey <tromey@redhat.com>
16278
16279 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16280 (tracepoint.o): Likewise.
16281 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16282 (gdb_agent_op_names): Likewise.
16283
c7f96d2b
TT
162842011-02-18 Tom Tromey <tromey@redhat.com>
16285
16286 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16287 gdb_agent_op_rot>: New constants.
16288 (gdb_agent_op_names): Add pick and roll.
16289 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16290 cases.
16291
0feedb2c
JK
162922011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16293
16294 * aclocal.m4: Regenerated with aclocal-1.11.1.
16295
b3b9301e
PA
162962011-02-14 Pedro Alves <pedro@codesourcery.com>
16297
16298 * server.c (handle_qxfer_traceframe_info): New.
16299 (qxfer_packets): Register "traceframe-info".
16300 (handle_query): Report support for qXfer:traceframe-info:read+.
16301 * tracepoint.c (match_blocktype): New.
16302 (traceframe_find_block_type): Rename to ...
16303 (traceframe_walk_blocks): ... this. Add callback filter argument,
16304 and use it.
16305 (traceframe_find_block_type): New, reimplemented on top of
16306 traceframe_walk_blocks.
16307 (build_traceframe_info_xml): New.
16308 (traceframe_read_info): New.
16309 * server.h (traceframe_read_info): Declare.
16310
4f3e6fb7
YQ
163112011-02-11 Yao Qi <yao@codesourcery.com>
16312
16313 * configure.ac: Call AC_PROG_RANLIB.
16314 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16315 * configure: Regenerate.
16316
764880b7
PA
163172011-02-07 Pedro Alves <pedro@codesourcery.com>
16318
16319 * server.c (gdb_read_memory): Change return semantics to allow
16320 partial transfers.
16321 (handle_search_memory_1): Adjust.
16322 (process_serial_event) <'m' packet>: Handle partial transfers.
16323 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16324
1c79eb8a
PA
163252011-01-28 Pedro Alves <pedro@codesourcery.com>
16326
16327 * regcache.c (init_register_cache): Initialize
16328 regcache->register_status.
16329 (free_register_cache): Release regcache->register_status.
16330 (regcache_cpy): Copy register_status.
16331 (registers_to_string): Print 'x's for unavailable registers.
16332 (supply_register): Mark the register's status valid or
16333 unavailable, depending on whether a buffer was passed in or not.
16334 (supply_register_zeroed): New.
16335 (supply_regblock): Mark the registers' status valid or
16336 unavailable, depending on whether a buffer was passed in or not.
16337 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16338 (struct regcache): New `register_status' field.
16339 (supply_register_zeroed): Declare.
16340 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16341 supply_register_zeroed, rather than passing a NULL buffer to
16342 supply_register.
16343 * tracepoint.c (fetch_traceframe_registers): Update comment.
16344
85724a0e
PA
163452011-01-28 Pedro Alves <pedro@codesourcery.com>
16346
16347 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16348 buffer explicit.
16349
d08aafef
PA
163502011-01-25 Pedro Alves <pedro@codesourcery.com>
16351
16352 * server.h (decode_xfer_write): Change prototype.
16353 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16354 and don't extract the annex here.
16355 * server.c (decode_xfer_read): Remove `annex' parameter,
16356 and don't extract the annex here.
16357 (decode_xfer): New.
16358 (struct qxfer): New.
16359 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16360 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16361 (handle_qxfer_statictrace): New functions, abstracted out from
16362 handle_query, and made to use the struct qxfer interface.
16363 (handle_threads_qxfer_proper): Rename to ...
16364 (handle_qxfer_threads_proper): ... this.
16365 (handle_threads_qxfer): Rename to ...
16366 (handle_qxfer_threads): ... this. Adjust.
16367 (qxfer_packets): New array.
16368 (handle_qxfer): New function.
16369 (handle_query): Use handle_qxfer.
16370
493e2a69
MS
163712011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16372
16373 * gdbreplay.c: Shorten lines of >= 80 columns.
16374 * linux-low.c: Ditto.
16375 * linux-ppc-low.c: Ditto.
16376 * linux-s390-low.c: Ditto.
16377 * linux-sparc-low.c: Ditto.
16378 * linux-x86-low.c: Ditto.
16379 * linux-xtensa-low.c: Ditto.
16380 * mem-break.c: Ditto.
16381 * nto-low.c: Ditto.
16382 * regcache.h: Ditto.
16383 * remote-utils.c: Ditto.
16384 * server.c: Ditto.
16385 * server.h: Ditto.
16386 * thread-db.c: Ditto.
16387 * tracepoint.c: Ditto.
16388 * utils.c: Ditto.
16389 * win32-low.h: Ditto.
16390
44944448
JB
163912011-01-05 Joel Brobecker <brobecker@adacore.com>
16392
16393 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16394 update.
16395
71ce852c
JB
163962011-01-01 Joel Brobecker <brobecker@adacore.com>
16397
16398 * server.c (gdbserver_version): Update copyright year in version
16399 output.
16400 * gdbreplay.c (gdbreplay_version): Ditto.
16401
eb826dc6
MF
164022010-12-29 Jie Zhang <jie.zhang@analog.com>
16403
16404 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16405 * linux-bfin-low.c: New file.
16406 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16407 PT_DATA_ADDR for BFIN targets.
16408 * Makefile.in (SFILES): Add linux-bfin-low.c.
16409 (clean): Remove reg-bfin.c.
16410 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16411 * README: Mention supported Blackfin targets.
16412
39ab222a
MF
164132010-12-23 Mike Frysinger <vapier@gentoo.org>
16414
16415 * .gitignore: New file.
16416
a1f2ce7d
MF
164172010-11-16 Mike Frysinger <vapier@gentoo.org>
16418
16419 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16420
f474844c
JZ
164212010-10-22 Jie Zhang <jie@codesourcery.com>
16422
16423 * Makefile.in: Add FLAGS_TO_PASS variable.
16424 (install): Remove dependency of install-only and recursively
16425 invoke make for install-only.
16426
f1048712
DE
164272010-10-04 Doug Evans <dje@google.com>
16428
16429 * Makefile.in (uninstall): Use $(DESTDIR).
16430
b53a1623
PA
164312010-09-24 Pedro Alves <pedro@codesourcery.com>
16432
e6ee044d
PA
16433 PR gdb/11842
16434
b53a1623
PA
16435 * linux-x86-low.c (compat_siginfo_from_siginfo)
16436 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16437 si_code is < 0. Check for si_code == SI_TIMER before checking for
16438 si_code < 0.
16439
fa1bd1e4
JB
164402010-09-13 Joel Brobecker <brobecker@adacore.com>
16441
16442 * lynx-i386-low.c: New file.
16443 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16444
47fac8f8
JB
164452010-09-13 Joel Brobecker <brobecker@adacore.com>
16446
16447 * lynx-low.c (ptrace_request_to_str): Remove handling for
16448 request values that have been removed in LynxOS 5.x.
16449
1adfc54d
JB
164502010-09-13 Joel Brobecker <brobecker@adacore.com>
16451
16452 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16453 <ptrace.h>
16454
c2a66c29
NS
164552010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16456
16457 * configure.ac: Add --enable-inprocess-agent option.
16458 * configure: Rebuilt.
16459
32fcada3
YQ
164602010-09-06 Yao Qi <yao@codesourcery.com>
16461
16462 * linux-low.c (linux_kill): Remove unused variable.
16463 (linux_stabilize_threads): Likewise.
16464 * server.c (start_inferior): Likewise.
16465 (queue_stop_reply_callback): Likewise.
16466 * tracepoint.c (do_action_at_tracepoint): Likewise.
16467
0cccb683
YQ
164682010-09-06 Yao Qi <yao@codesourcery.com>
16469
16470 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16471 on return.
16472
423ec54c
JK
164732010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16474
16475 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16476
12ac6819
PA
164772010-09-06 Pedro Alves <pedro@codesourcery.com>
16478
16479 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16480 "$(IPA_DEPFILES)".
16481
8ed54b31
JB
164822010-09-01 Joel Brobecker <brobecker@adacore.com>
16483
16484 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16485 gdbserver/lynx-ppc-low.c: New files.
16486 * Makefile.in (lynx_low_h): New variable.
16487 (lynx-low.o, lynx-ppc-low.o): New rules.
16488 * configure.ac: On LynxOS, link with -lnetinet.
16489 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16490 * configure: regenerate.
16491
bb0116a4
JB
164922010-09-01 Joel Brobecker <brobecker@adacore.com>
16493
16494 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16495 * configure.ac: Add check for vasprintf and vsnprintf.
16496 * configure, config.in: Regenerate.
16497 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16498
a778ab81 164992010-09-01 Joel Brobecker <brobecker@adacore.com>
16500
16501 * gdbreplay.c: Move include of alloca.h up, next to include of
16502 malloc.h.
16503 * server.h: Add include of malloc.h.
16504 * mem-break.c: Remove include of malloc.h.
16505 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16506
8b034a19 165072010-09-01 Joel Brobecker <brobecker@adacore.com>
16508
16509 * Makefile.in (memmem.o): Build with -Wno-error.
16510
165112010-09-01 Joel Brobecker <brobecker@adacore.com>
16512
16513 * utils.c (xsnprintf): Make non-static.
16514 * server.h: Add xsnprintf declaration.
16515 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16516 replace calls to snprintf by calls to xsnprintf throughout.
16517
165182010-09-01 Joel Brobecker <brobecker@adacore.com>
16519
16520 * configure.ac: Add configure check for alloca.
16521 * configure, config.in: Regenerate.
16522 * server.h: Include alloca.h if it exists.
16523 * gdbreplay.c: Include alloca.h if it exists.
16524
1a981360
PA
165252010-08-28 Pedro Alves <pedro@codesourcery.com>
16526
16527 * linux-low.c (__SIGRTMIN): Define if not already defined.
16528 (linux_create_inferior): Check for __ANDROID__ rather than
16529 __SIGRTMIN.
16530 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16531 are already deferred.
16532 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16533 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16534 stopped and already has a pending signal to report.
16535 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16536 a pending signal to report or is moving out of a jump pad.
16537 (linux_init_signals): Check for __ANDROID__ rather than
16538 __SIGRTMIN.
16539
b4d51a55
PA
165402010-08-28 Pedro Alves <pedro@codesourcery.com>
16541
16542 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16543 debug_threads check. Avoid a linear search when not doing debug
16544 output.
16545
ec48365d
PA
165462010-08-27 Pedro Alves <pedro@codesourcery.com>
16547
16548 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16549 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16550 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16551 (process_event): Change local fd's type to gdb_fildes_t.
16552 (create_file_handler): Adjust prototype.
16553 (delete_file_handler): Adjust prototype.
16554 (handle_file_event): Adjust prototype. Use pfildes.
16555 (create_file_event): Adjsut prototype.
16556 * remote-utils.c (remote_desc, listen_desc): Change type to
16557 gdb_fildes_t.
16558 * server.h: New gdb_fildes_t typedef.
16559 [USE_WIN32API]: Include winsock2.h.
16560 (delete_file_handler, add_file_handler): Adjust prototypes.
16561 (pfildes): Declare.
16562 * utils.c (pfildes): New.
16563
854d88f0
PA
165642010-08-27 Pedro Alves <pedro@codesourcery.com>
16565
16566 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16567 * configure: Regenerate.
16568
0146f85b
PA
165692010-08-27 Pedro Alves <pedro@codesourcery.com>
16570
16571 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16572 (linux_done_accessing_memory): ... this.
16573 (linux_target_ops): Adjust.
16574 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16575 * nto-low.c (nto_target_ops): Adjust comment.
16576 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16577 * spu-low.c (spu_target_ops): Adjust comment.
16578 * target.h (target_ops): Rename unprepare_to_access_memory field
16579 to done_accessing_memory.
16580 (unprepare_to_access_memory): Rename to ...
16581 (done_accessing_memory): ... this.
16582
90d74c30
PA
165832010-08-26 Pedro Alves <pedro@codesourcery.com>
16584
16585 * linux-low.c (linux_prepare_to_access_memory): New.
16586 (linux_unprepare_to_access_memory): New.
16587 (linux_target_ops): Install them.
16588 * server.c (read_memory): Rename to ...
16589 (gdb_read_memory): ... this. Use
16590 prepare_to_access_memory/prepare_to_access_memory.
16591 (write_memory): Rename to ...
16592 (gdb_write_memory): ... this. Use
16593 prepare_to_access_memory/prepare_to_access_memory.
16594 (handle_search_memory_1): Adjust.
16595 (process_serial_event): Adjust.
16596 * target.h (struct target_ops): New fields
16597 prepare_to_access_memory and unprepare_to_access_memory.
16598 (prepare_to_access_memory, unprepare_to_access_memory): New.
16599 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16600 prepare_to_access_memory/prepare_to_access_memory.
16601 * nto-low.c (nto_target_ops): Adjust.
16602 * spu-low.c (spu_target_ops): Adjust.
16603 * win32-low.c (win32_target_ops): Adjust.
16604
fd467969
PA
166052010-08-26 Pedro Alves <pedro@codesourcery.com>
16606
16607 * Makefile.in (WARN_CFLAGS): Get it from configure.
16608 (WERROR_CFLAGS): New.
16609 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16610 * configure.ac: Introduce --enable-werror, which adds -Werror to
16611 the compiler command line. Enabled by default. Disable with
16612 --disable-werror. Add -Wdeclaration-after-statement
16613 Wpointer-arith and -Wformat-nonliteral to warning flags.
16614 * configure: Regenerate.
16615
331e2f5f
PA
166162010-08-26 Pedro Alves <pedro@codesourcery.com>
16617
16618 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16619
e581f2b4
PA
166202010-08-26 Pedro Alves <pedro@codesourcery.com>
16621
16622 * gdbreplay.c (remote_error): New.
16623 (gdbchar): New.
16624 (expect): Use gdbchar. Check for error reading from GDB.
16625 Clarify sync error output.
16626 (play): Check for errors writing to GDB.
16627 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16628 * remote-utils.c (getpkt): Check for errors writing to the remote
16629 descriptor.
16630
3c11dd79
PA
166312010-08-25 Pedro Alves <pedro@codesourcery.com>
16632
16633 * linux-low.c (linux_wait_1): Move non-debugging code out of
16634 `debug_threads' control.
16635
d20a8ad9
PA
166362010-08-25 Pedro Alves <pedro@codesourcery.com>
16637
16638 * linux-low.c (linux_wait_1): Don't set last_status here.
16639 * server.c (push_event, queue_stop_reply_callback): Assert we're
16640 not pushing a TARGET_WAITKIND_IGNORE event.
16641 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16642 (myresume, handle_target_event): Set the thread's last_resume_kind
16643 and last_status from the target returned status.
16644
964e4306
PA
166452010-08-25 Pedro Alves <pedro@codesourcery.com>
16646
16647 PR threads/10729
16648
16649 * linux-x86-low.c (update_debug_registers_callback): New.
16650 (i386_dr_low_set_addr): Use it.
16651 (i386_dr_low_get_addr): New.
16652 (i386_dr_low_set_control): Use update_debug_registers_callback.
16653 (i386_dr_low_get_control): New.
16654 (i386_dr_low_get_status): Adjust.
16655 * linux-low.c (linux_stop_lwp): New.
16656 * linux-low.h (linux_stop_lwp): Declare.
16657
16658 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16659 argument instead of a i386_debug_reg_state.
16660 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16661 a i386_debug_reg_state.
16662 (i386_insert_aligned_watchpoint): Adjust.
16663 (i386_remove_aligned_watchpoint): Adjust.
16664 (i386_low_stopped_data_address): Read the debug registers from the
16665 inferior instead of from the mirrors.
16666 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16667 (i386_dr_low_get_addr): Declare.
16668 (i386_dr_low_get_control): Declare.
16669 (i386_dr_low_get_status): Change prototype.
16670
16671 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16672 (i386_dr_low_get_addr): New.
16673 (i386_dr_low_get_control): New.
16674 (i386_dr_low_get_status): Adjust prototype. Return
16675 dr_status_mirror.
16676 (i386_initial_stuff): Clear dr_status_mirror and
16677 dr_control_mirror.
16678 (i386_get_thread_context): Adjust.
16679 (i386_set_thread_context): Adjust.
16680 (i386_thread_added): Adjust.
16681
5f21a75b
PA
166822010-08-24 Pedro Alves <pedro@codesourcery.com>
16683
16684 * linux-low.h (linux_thread_area): Delete declaration.
16685
3e4c1235
TS
166862010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16687
16688 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16689 after its termination.
16690
1971b033
PA
166912010-08-09 Pedro Alves <pedro@codesourcery.com>
16692
16693 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16694 (gdb_wants_all_stopped): Delete.
16695 (linux_wait_1): Don't call them.
16696 * server.c (handle_v_cont): Tag all threads as want-stopped.
16697 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16698 stopped as "client-wants-stopped".
16699
310444ac
PA
167002010-07-31 Pedro Alves <pedro@codesourcery.com>
16701
16702 * Makefile.in (signals_h): New.
16703 (server_h): Depend on it.
16704 (server.o): Don't depend on $(signals_def).
16705 (signals.o): Depend on $(signals_def).
16706
a19cae16
JK
167072010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16708
16709 * Makefile.in (signals_def): New.
16710 (server_h): Append include/gdb/signals.h and signals_def.
16711 (server.o): Append signals_def.
16712
30d50328
JK
167132010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16714
16715 * server.c (handle_target_event): Use target_signal_to_host for
16716 resume_info.sig initialization.
16717 * target.h (struct thread_resume) <sig>: New comment.
16718
5c3216e2
OS
167192010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16720
c6f46ca0
OS
16721 * server.c (handle_query): strcpy() the returned string from paddress()
16722 instead of sprintf().
5c3216e2
OS
16723 * utils.c (paddress): Return phex_nz().
16724
6bd31874
JB
167252010-07-07 Joel Brobecker <brobecker@adacore.com>
16726
16727 * server.c (handle_v_cont): Call mourn_inferior if process
16728 just exited.
16729 (myresume): Likewise.
16730
0fb4aa4b
PA
167312010-07-01 Pedro Alves <pedro@codesourcery.com>
16732
16733 Static tracepoints, and integration with UST.
16734
16735 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16736 * mem-break.c (uninsert_all_breakpoints)
16737 (reinsert_all_breakpoints): New.
16738 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16739 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16740 (gdb_agent_ust_loaded, helper_thread_id)
16741 (gdb_agent_helper_thread_id): New macros.
16742 (struct ipa_sym_addresses): Add addr_ust_loaded,
16743 addr_helper_thread_id, addr_cmd_buf.
16744 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16745 (in_process_agent_loaded_ust): New.
16746 (write_e_ust_not_loaded): New.
16747 (maybe_write_ipa_ust_not_loaded): New.
16748 (struct collect_static_trace_data_action): New.
16749 (enum tracepoint_type) <static_tracepoint>: New.
16750 (struct tracepoint) <handle>: Mention static tracepoints.
16751 (struct static_tracepoint_ctx): New.
16752 (CMD_BUF_SIZE): New.
16753 (add_tracepoint_action): Handle static tracepoint actions.
16754 (unprobe_marker_at): New.
16755 (clear_installed_tracepoints): Handle static tracepoints.
16756 (cmd_qtdp): Handle static tracepoints.
16757 (probe_marker_at): New.
16758 (cmd_qtstart): Handle static tracepoints.
16759 (response_tracepoint): Handle static tracepoints.
16760 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16761 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16762 (get_context_regcache): Handle static tracepoints.
16763 (do_action_at_tracepoint): Handle static tracepoint actions.
16764 (traceframe_find_block_type): Handle static trace data blocks.
16765 (traceframe_read_sdata): New.
16766 (download_tracepoints): Download static tracepoint actions.
16767 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16768 (GDB_PROBE_NAME): New.
16769 (ust_ops): New.
16770 (GET_UST_SYM): New.
16771 (USTF): New.
16772 (dlsym_ust): New.
16773 (ust_marker_to_static_tracepoint): New.
16774 (gdb_probe): New.
16775 (collect_ust_data_at_tracepoint): New.
16776 (gdb_ust_probe): New.
16777 (UNIX_PATH_MAX, SOCK_DIR): New.
16778 (gdb_ust_connect_sync_socket): New.
16779 (resume_thread, stop_thread): New.
16780 (run_inferior_command): New.
16781 (init_named_socket): New.
16782 (gdb_ust_socket_init): New.
16783 (cstr_to_hexstr): New.
16784 (next_st): New.
16785 (first_marker, next_marker): New.
16786 (response_ust_marker): New.
16787 (cmd_qtfstm, cmd_qtsstm): New.
16788 (unprobe_marker_at, probe_marker_at): New.
16789 (cmd_qtstmat, gdb_ust_thread): New.
16790 (gdb_ust_init): New.
16791 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16792 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16793 (ST_REGENTRY): New.
16794 (x86_64_st_collect_regmap): New.
16795 (X86_64_NUM_ST_COLLECT_GREGS): New.
16796 (AMD64_RIP_REGNUM): New.
16797 (supply_static_tracepoint_registers): New.
16798 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16799 (ST_REGENTRY): New.
16800 (i386_st_collect_regmap): New.
16801 (i386_NUM_ST_COLLECT_GREGS): New.
16802 (supply_static_tracepoint_registers): New.
16803 * server.c (handle_query): Handle qXfer:statictrace:read.
16804 <qSupported>: Report support for StaticTracepoints, and
16805 qXfer:statictrace:read features.
16806 * server.h (traceframe_read_sdata)
16807 (supply_static_tracepoint_registers): Declare.
16808 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16809 (unpack_varlen_hex): Include in IPA build.
16810 * Makefile.in (ustlibs, ustinc): New.
16811 (IPA_OBJS): Add remote-utils-ipa.o.
16812 ($(IPA_LIB)): Link -ldl and -lpthread.
16813 (UST_CFLAGS): New.
16814 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16815 * config.in, configure: Regenerate.
16816
9e4344e5
PA
168172010-06-20 Ian Lance Taylor <iant@google.com>
16818 Pedro Alves <pedro@codesourcery.com>
16819
16820 * linux-x86-low.c (always_true): Delete.
16821 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16822 trying to fool the compiler with always_true.
16823
c6beb2cb
PA
168242010-06-20 Pedro Alves <pedro@codesourcery.com>
16825
16826 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16827 conditions in gdbserver.
16828
d2ed6730
UW
168292010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16830
16831 * spu-low.c (spu_read_memory): Wrap around local store limit.
16832 (spu_write_memory): Likewise.
16833
4e29fb54
PA
168342010-06-15 Pedro Alves <pedro@codesourcery.com>
16835
16836 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16837 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16838 LONGEST uses.
16839 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16840 uses.
16841 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16842 uses with LONGEST uses.
16843
6a271cae
PA
168442010-06-14 Stan Shebs <stan@codesourcery.com>
16845 Pedro Alves <pedro@codesourcery.com>
16846
16847 Bytecode compiler.
16848
16849 * linux-x86-low.c: Include limits.h.
16850 (add_insns): New.
16851 (always_true): New.
16852 (EMIT_ASM): New.
16853 (EMIT_ASM32): New.
16854 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16855 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16856 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16857 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16858 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16859 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16860 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16861 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16862 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16863 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16864 (amd64_emit_void_call_2): New.
16865 (amd64_emit_ops): New.
16866 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16867 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16868 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16869 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16870 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16871 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16872 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16873 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16874 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16875 (i386_emit_stack_adjust, i386_emit_int_call_1)
16876 (i386_emit_void_call_2): New.
16877 (i386_emit_ops): New.
16878 (x86_emit_ops): New.
16879 (the_low_target): Install x86_emit_ops.
16880 * server.h (struct emit_ops): New.
16881 (get_raw_reg_func_addr): Declare.
16882 (current_insn_ptr, emit_error): Declare.
16883 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16884 (set_trace_state_variable_value): New defines.
16885 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16886 addr_get_trace_state_variable_value and
16887 addr_set_trace_state_variable_value.
16888 (symbol_list): New fields for get_raw_reg,
16889 get_trace_state_variable_value and set_trace_state_variable_value.
16890 (condfn): New typedef.
16891 (struct tracepoint): New field `compiled_cond'.
16892 (do_action_at_tracepoint): Clear compiled_cond.
16893 (get_trace_state_variable_value, set_trace_state_variable_value):
16894 Export in the IPA.
16895 (condition_true_at_tracepoint): If there's a compiled condition,
16896 run that.
16897 (current_insn_ptr, emit_error): New globals.
16898 (struct bytecode_address): New.
16899 (get_raw_reg_func_addr): New.
16900 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16901 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16902 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16903 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16904 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16905 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16906 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16907 (compile_tracepoint_condition, compile_bytecodes): New.
16908 * target.h (emit_ops): Forward declare.
16909 (struct target_ops): New field emit_ops.
16910 (target_emit_ops): New.
16911 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16912 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16913 * linux-low.c (linux_emit_ops): New.
16914 (linux_target_ops): Install it.
16915 * linux-low.h (struct linux_target_ops): New field emit_ops.
16916
92b72907
UW
169172010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16918
16919 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16920 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16921
fa593d66
PA
169222010-06-01 Pedro Alves <pedro@codesourcery.com>
16923 Stan Shebs <stan@codesourcery.com>
16924
16925 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
16926 (all): Depend on $(extra_libraries).
16927 (install-only): Install the IPA.
16928 (IPA_OBJS, IPA_LIB): New.
16929 (clean): Remove the IPA lib.
16930 (IPAGENT_CFLAGS): New.
16931 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
16932 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
16933 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
16934 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
16935 * configure.ac: Check for atomic builtins support in the compiler.
16936 (IPA_DEPFILES, extra_libraries): Define.
16937 * configure.srv (ipa_obj): Add description.
16938 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
16939 (i[34567]86-*-linux*): Set ipa_obj.
16940 (x86_64-*-linux*): Set ipa_obj.
16941 * linux-low.c (stabilizing_threads): New.
16942 (supports_fast_tracepoints): New.
16943 (linux_detach): Stabilize threads before detaching.
16944 (handle_tracepoints): Handle internal tracing breakpoints. Assert
16945 the lwp is either not stabilizing, or is moving out of a jump pad.
16946 (linux_fast_tracepoint_collecting): New.
16947 (maybe_move_out_of_jump_pad): New.
16948 (enqueue_one_deferred_signal): New.
16949 (dequeue_one_deferred_signal): New.
16950 (linux_wait_for_event_1): If moving out of a jump pad, defer
16951 pending signals to later.
16952 (linux_stabilize_threads): New.
16953 (linux_wait_1): Check if threads need moving out of jump pads, and
16954 do it if so.
16955 (stuck_in_jump_pad_callback): New.
16956 (move_out_of_jump_pad_callback): New.
16957 (lwp_running): New.
16958 (linux_resume_one_lwp): Handle moving out of jump pads.
16959 (linux_set_resume_request): Dequeue deferred signals.
16960 (need_step_over_p): Also step over fast tracepoint jumps.
16961 (start_step_over): Also uninsert fast tracepoint jumps.
16962 (finish_step_over): Also reinsert fast tracepoint jumps.
16963 (linux_install_fast_tracepoint_jump): New.
16964 (linux_target_ops): Install linux_stabilize_threads and
16965 linux_install_fast_tracepoint_jump_pad.
16966 * linux-low.h (linux_target_ops) <get_thread_area,
16967 install_fast_tracepoint_jump_pad>: New fields.
16968 (struct lwp_info) <collecting_fast_tracepoint,
16969 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
16970 (linux_get_thread_area): Declare.
16971 * linux-x86-low.c (jump_insn): New.
16972 (x86_get_thread_area): New.
16973 (append_insns): New.
16974 (push_opcode): New.
16975 (amd64_install_fast_tracepoint_jump_pad): New.
16976 (i386_install_fast_tracepoint_jump_pad): New.
16977 (x86_install_fast_tracepoint_jump_pad): New.
16978 (the_low_target): Install x86_get_thread_area and
16979 x86_install_fast_tracepoint_jump_pad.
16980 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
16981 (struct fast_tracepoint_jump): New.
16982 (fast_tracepoint_jump_insn): New.
16983 (fast_tracepoint_jump_shadow): New.
16984 (find_fast_tracepoint_jump_at): New.
16985 (fast_tracepoint_jump_here): New.
16986 (delete_fast_tracepoint_jump): New.
16987 (set_fast_tracepoint_jump): New.
16988 (uninsert_fast_tracepoint_jumps_at): New.
16989 (reinsert_fast_tracepoint_jumps_at): New.
16990 (set_breakpoint_at): Use write_inferior_memory.
16991 (uninsert_raw_breakpoint): Use write_inferior_memory.
16992 (check_mem_read): Mask out fast tracepoint jumps.
16993 (check_mem_write): Mask out fast tracepoint jumps.
16994 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
16995 (set_fast_tracepoint_jump): Declare.
16996 (delete_fast_tracepoint_jump)
16997 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
16998 (reinsert_fast_tracepoint_jumps_at): Declare.
16999 * regcache.c: Don't compile many functions when building the
17000 in-process agent library.
17001 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17002 the register buffer in the heap.
17003 (free_register_cache): If the register buffer isn't owned by the
17004 regcache, don't free it.
17005 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17006 pre-existing register caches.
17007 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17008 type.
17009 (convert_ascii_to_int): : Constify `from' parameter type.
17010 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17011 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17012 the needed buffer in-place.
17013 (relocate_instruction): New.
17014 * server.c (handle_query) <qSymbols>: If the target supports
17015 tracepoints, give it a chance of looking up symbols. Report
17016 support for fast tracepoints.
17017 (handle_status): Stabilize threads.
17018 (process_serial_event): Adjust.
17019 * server.h (struct fast_tracepoint_jump): Forward declare.
17020 (struct process_info) <fast_tracepoint_jumps>: New field.
17021 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17022 (decode_X_packet, decode_M_packet): Adjust.
17023 (relocate_instruction): Declare.
17024 (in_process_agent_loaded): Declare.
17025 (tracepoint_look_up_symbols): Declare.
17026 (struct fast_tpoint_collect_status): Declare.
17027 (fast_tracepoint_collecting): Declare.
17028 (force_unlock_trace_buffer): Declare.
17029 (handle_tracepoint_bkpts): Declare.
17030 (initialize_low_tracepoint)
17031 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17032 * target.h (struct target_ops) <stabilize_threads,
17033 install_fast_tracepoint_jump_pad>: New fields.
17034 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17035 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17036 [HAVE_STDINT_H]: Include stdint.h.
17037 (trace_debug_1): Rename to ...
17038 (trace_vdebug): ... this.
17039 (trace_debug): Rename to ...
17040 (trace_debug_1): ... this. Add `level' parameter.
17041 (trace_debug): New.
17042 (ATTR_USED, ATTR_NOINLINE): New.
17043 (IP_AGENT_EXPORT): New.
17044 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17045 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17046 (about_to_request_buffer_space, trace_buffer_is_full)
17047 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17048 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17049 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17050 (traceframe_write_count, traceframes_created)
17051 (trace_state_variables)
17052 New renaming defines.
17053 (struct ipa_sym_addresses): New.
17054 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17055 (symbol_list): New.
17056 (ipa_sym_addrs): New.
17057 (all_tracepoint_symbols_looked_up): New.
17058 (in_process_agent_loaded): New.
17059 (write_e_ipa_not_loaded): New.
17060 (maybe_write_ipa_not_loaded): New.
17061 (tracepoint_look_up_symbols): New.
17062 (debug_threads) [IN_PROCESS_AGENT]: New.
17063 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17064 (UNKNOWN_SIDE_EFFECTS): New.
17065 (stop_tracing): New.
17066 (flush_trace_buffer): New.
17067 (stop_tracing_bkpt): New.
17068 (flush_trace_buffer_bkpt): New.
17069 (read_inferior_integer): New.
17070 (read_inferior_uinteger): New.
17071 (read_inferior_data_pointer): New.
17072 (write_inferior_data_pointer): New.
17073 (write_inferior_integer): New.
17074 (write_inferior_uinteger): New.
17075 (struct collect_static_trace_data_action): Delete.
17076 (enum tracepoint_type): New.
17077 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
17078 <actions_str, step_actions, step_actions_str>: Only include in
17079 GDBserver.
fa593d66
PA
17080 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17081 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17082 (tracepoints): Use IP_AGENT_EXPORT.
17083 (last_tracepoint): Don't include in the IPA.
17084 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17085 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17086 (alloced_trace_state_variables): New.
17087 (trace_state_variables): Use IP_AGENT_EXPORT.
17088 (traceframe_t): Delete unused variable.
17089 (circular_trace_buffer): Don't include in the IPA.
17090 (trace_buffer_start): Delete.
17091 (struct trace_buffer_control): New.
17092 (trace_buffer_free): Delete.
17093 (struct ipa_trace_buffer_control): New.
17094 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17095 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17096 New.
17097 (trace_buffer_ctrl): New.
17098 (TRACE_BUFFER_CTRL_CURR): New.
17099 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17100 Reimplement as macros.
17101 (trace_buffer_wrap): Delete.
17102 (traceframe_write_count, traceframe_read_count)
17103 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17104 (struct tracepoint_hit_ctx) <type>: New field.
17105 (struct fast_tracepoint_ctx): New.
17106 (memory_barrier): New.
17107 (cmpxchg): New.
17108 (record_tracepoint_error): Update atomically in the IPA.
17109 (clear_inferior_trace_buffer): New.
17110 (about_to_request_buffer_space): New.
17111 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17112 updating the same buffer.
17113 (add_tracepoint): Default the tracepoint's type to trap
17114 tracepoint, and orig_size to -1.
17115 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17116 internal variables.
17117 (create_trace_state_variable): New parameter `gdb'. Handle it.
17118 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17119 (cmd_qtdp): Handle fast tracepoints.
17120 (cmd_qtdv): Adjust.
17121 (max_jump_pad_size): New.
17122 (gdb_jump_pad_head): New.
17123 (get_jump_space_head): New.
17124 (claim_jump_space): New.
17125 (sort_tracepoints): New.
17126 (MAX_JUMP_SIZE): New.
17127 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17128 IPA.
17129 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17130 support. Upload fast traceframes, and delete internal IPA
17131 breakpoints.
17132 (stop_tracing_handler): New.
17133 (flush_trace_buffer_handler): New.
17134 (cmd_qtstop): Upload fast tracepoints.
17135 (response_tracepoint): Handle fast tracepoints.
17136 (tracepoint_finished_step): Upload fast traceframes. Set the
17137 tracepoint hit context's tracepoint type.
17138 (handle_tracepoint_bkpts): New.
17139 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17140 type. Add comment about fast tracepoints.
17141 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17142 non-existing action_str field.
17143 (get_context_regcache): Handle fast tracepoints.
17144 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17145 to the regcache.
17146 (fast_tracepoint_from_jump_pad_address): New.
17147 (fast_tracepoint_from_ipa_tpoint_address): New.
17148 (collecting_t): New.
17149 (force_unlock_trace_buffer): New.
17150 (fast_tracepoint_collecting): New.
17151 (collecting): New.
17152 (gdb_collect): New.
17153 (write_inferior_data_ptr): New.
17154 (target_tp_heap): New.
17155 (target_malloc): New.
17156 (download_agent_expr): New.
17157 (UALIGN): New.
17158 (download_tracepoints): New.
17159 (download_trace_state_variables): New.
17160 (upload_fast_traceframes): New.
17161 (IPA_FIRST_TRACEFRAME): New.
17162 (IPA_NEXT_TRACEFRAME_1): New.
17163 (IPA_NEXT_TRACEFRAME): New.
17164 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17165 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17166 (gdb_jump_pad_buffer_end): New.
17167 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17168 (initialize_tracepoint): Adjust.
17169 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17170 buffer. Initialize the low module.
17171 * utils.c (PREFIX, TOOLNAME): New.
17172 (malloc_failure): Use PREFIX.
17173 (error): In the IPA, an error causes an exit.
17174 (fatal, warning): Use PREFIX.
17175 (internal_error): Use TOOLNAME.
17176 (NUMCELLS): Increase to 10.
17177 * configure, config.in: Regenerate.
17178
d149dd1d
PA
171792010-06-01 Pedro Alves <pedro@codesourcery.com>
17180
17181 * server.c (handle_query) <qSupported>: Do two passes over the
17182 qSupported string to avoid nesting strtok.
17183
f6528abd
JK
171842010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17185
17186 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17187 (CDEPS): New.
17188 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17189 -Wl,--dynamic-list.
17190 * configure: Regenerate.
17191 * proc-service.list: New.
17192
ca2a87a0
JK
171932010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17194
17195 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17196 New comment.
17197
363a6e9f
OS
171982010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17199
17200 * gdbreplay.c (remote_open): Check error return from socket() call by
17201 its equality to -1 not by it being negative.
17202 * remote-utils.c (remote_open): Likewise.
17203
d23b6cb1
PA
172042010-05-23 Pedro Alves <pedro@codesourcery.com>
17205
17206 * config.h: Regenerate.
17207
28d3cf85
MK
172082010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17209
17210 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17211 doesn't provide PTRACE_GET_THREAD_AREA.
17212
fea36a59
MK
172132010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17214
17215 * linux-m68k-low.c: Include <asm/ptrace.h>
17216 (ps_get_thread_area): Implement.
17217
24b066ba
DE
172182010-05-03 Doug Evans <dje@google.com>
17219
17220 * event-loop.c (struct callback_event): New struct.
17221 (callback_list): New global.
17222 (append_callback_event, delete_callback_event): New functions.
17223 (process_callback): New function.
17224 (start_event_loop): Call it.
17225 * remote-utils.c (NOT_SCHEDULED): Define.
17226 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17227 moved out of readchar.
17228 (readchar): Rewrite. Call reschedule before returning.
17229 (reset_readchar): New function.
17230 (remote_close): Call it.
17231 (process_remaining, reschedule): New functions.
17232 * server.h (callback_handler_func): New typedef.
17233 (append_callback_event, delete_callback_event): Declare.
17234
9836d6ea
PA
172352010-05-03 Pedro Alves <pedro@codesourcery.com>
17236
17237 * proc-service.c (ps_pglobal_lookup): Use
17238 thread_db_look_up_one_symbol.
17239 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17240 parameter. Use it instead of all_symbols_looked_up.
17241 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17242 field.
17243 (all_symbols_looked_up): Don't declare.
17244 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17245 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17246 field.
17247 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17248 Set all_symbols_looked_up here.
17249 (thread_db_look_up_one_symbol): New.
17250 (thread_db_get_tls_address): Adjust.
17251 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17252 thread_db object on the heap, and tentatively set it in the
17253 process structure.
17254 (thread_db_init): Don't set all_symbols_looked_up here.
17255 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17256
7984d532
PA
172572010-05-03 Pedro Alves <pedro@codesourcery.com>
17258
17259 * linux-low.c (linux_kill, linux_detach): Adjust.
17260 (status_pending_p_callback): Remove redundant statement. Check
17261 for !TARGET_WAITIKIND_IGNORE, instead of
17262 TARGET_WAITKIND_STOPPED.
17263 (handle_tracepoints): Make sure LWP is locked. Adjust.
17264 (linux_wait_for_event_1): Adjust.
17265 (linux_cancel_breakpoints): New.
17266 (unsuspend_one_lwp): New.
17267 (unsuspend_all_lwps): New.
17268 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17269 (send_sigstop_callback): Change return type to int, add new
17270 `except' parameter and handle it.
17271 (suspend_and_send_sigstop_callback): New.
17272 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17273 pass them down. If SUSPEND, also increment the lwp's suspend
17274 count.
17275 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17276 (need_step_over_p): Don't consider suspended LWPs.
17277 (start_step_over): Adjust.
17278 (proceed_one_lwp): Change return type to int, add new `except'
17279 parameter and handle it.
17280 (unsuspend_and_proceed_one_lwp): New.
17281 (proceed_all_lwps): Use find_inferior instead of
17282 for_each_inferior.
17283 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17284 also decrement the suspend count of LWPs. Pass `except' down,
17285 instead of hacking its suspend count.
17286 (linux_pause_all): Add `freeze' parameter. Adjust.
17287 (linux_unpause_all): New.
17288 (linux_target_ops): Install linux_unpause_all.
17289 * server.c (handle_status): Adjust.
17290 * target.h (struct target_ops): New fields `unpause_all' and
17291 `cancel_breakpoints'. Add new parameter to `pause_all'.
17292 (pause_all): Add new `freeze' parameter.
17293 (unpause_all): New.
17294 (cancel_breakpoints): New.
17295 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17296 cancel breakpoints.
17297 (cmd_qtstart): Pause threads.
17298 (stop_tracing): Pause threads, and cancel breakpoints.
17299 * win32-low.c (win32_target_ops): Adjust.
17300
e471f25b
PA
173012010-05-03 Pedro Alves <pedro@codesourcery.com>
17302
17303 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17304 the inferior right away from here...
17305 (linux_wait_1): ... to here, and adjust to check the thread's
17306 last_resume_kind instead of the lwp's step or stop_expected flags.
17307
1915ef4f
PA
173082010-05-02 Pedro Alves <pedro@codesourcery.com>
17309
17310 * README: Use consistent `GDB' and `GDBserver' spellings.
17311
f9e39928
PA
173122010-05-02 Pedro Alves <pedro@codesourcery.com>
17313
17314 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17315 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17316 (linux_detach_one_lwp): Assume the lwp is stopped.
17317 (any_thread_of): Delete.
17318 (linux_detach): Stop all lwps here. Don't blindly delete all
17319 breakpoints.
17320 (delete_lwp_callback): New.
17321 (linux_mourn): Delete all lwps of the process that is gone.
17322 (linux_wait_1): Don't delete the last lwp of the process here.
17323 * mem-break.h (mark_breakpoints_out): Declare.
17324 * mem-break.c (mark_breakpoints_out): New.
17325 (free_all_breakpoints): Use it.
17326 * server.c (handle_target_event): If the process is gone, mark
17327 breakpoints out.
17328 * thread-db.c (struct thread_db) <create_bp>: New field.
17329 (thread_db_enable_reporting): Fix prototype. Store a thread event
17330 breakpoint reference in the thread_db struct.
17331 (thread_db_load_search): Clear the thread_db object.
17332 (try_thread_db_load_1): Ditto.
17333 (switch_to_process): New.
17334 (disable_thread_event_reporting): Use it.
17335 (remove_thread_event_breakpoints): New.
17336 (thread_db_detach, thread_db_mourn): Use it.
17337
1e7fc18c
PA
173382010-05-01 Pedro Alves <pedro@codesourcery.com>
17339
17340 * linux-low.c (linux_enable_event_reporting): New.
17341 (linux_wait_for_event_1, handle_extended_wait): Use it.
17342
02fc4de7
PA
173432010-04-30 Pedro Alves <pedro@codesourcery.com>
17344
17345 * linux-low.c (linux_kill_one_lwp, linux_kill)
17346 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17347 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17348 SIGSTOP even if the LWP is stopped.
17349 (send_sigstop_callback): New.
17350 (stop_all_lwps): Use send_sigstop_callback instead.
17351 (linux_resume_one_thread): Adjust.
17352 (proceed_one_lwp): Still proceed an LWP that the client has
17353 requested to stop, if we haven't reported it as stopped yet. Make
17354 sure that LWPs the client want stopped, have a pending SIGSTOP.
17355
bc3b5632
DE
173562010-04-26 Doug Evans <dje@google.com>
17357
ae1ada35
DE
17358 * server.c (handle_general_set): Make static.
17359
bc3b5632
DE
17360 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17361 Print received char after testing for error/eof instead of before.
17362 (input_interrupt): Tweak comment.
17363
65730243
DE
173642010-04-23 Doug Evans <dje@google.com>
17365
17366 * server.c (start_inferior): Print inferior argv if --debug.
17367
a8ae7dc0
AR
173682010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17369
17370 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17371 * nto-x86-low.c: Include server.h
17372
1c07cc19
PM
173732010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17374
17375 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17376 be consistent with other sources of this directory.
17377 (init_registers_amd64): Correct name of source file of this function
17378 in the comment.
17379
e0a61e09
PM
173802010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17381
17382 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17383 64-bit executables.
17384
54709339
PM
173852010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17386
17387 * win32-i386-low.c: Add 64-bit support.
17388 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17389 (init_registers_amd64): Declare.
17390 (mappings): Add 64-bit version of array.
17391 (init_windows_x86): New function.
17392 (the_low_target): Change init_arch field to init_windows_x86.
17393
e8f0053d
PM
173942010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17395
17396 * win32-low.c: Adapt to support also 64-bit architecture.
17397 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17398 (get_image_name): Use SIZE_T type for local variable `done'.
17399 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17400 (toolhelp_get_dll_name): Idem.
17401 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17402 Use uintptr_t typecast to avoid warning.
17403 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17404 (handle_exception): Use phex_nz to avoid warning.
17405 (win32_wait): Remove unused local variable `process'.
17406
c481e77e
PM
174072010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17408
17409 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17410 `amd64-avx.o'.
17411
12ea4b69
PM
174122010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17413
17414 * configure.ac: Use `ws2_32' library for srv_mingw.
17415 * configure: Regenerate.
17416 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17417 * remote-utils.c: Likewise.
17418
f6d1620c
L
174192010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17420
17421 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17422 if __x86_64__ is defined.
17423
8e642873
PM
174242010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17425
17426 * configure: Regenerate.
17427
711e434b
PM
174282010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17429
17430 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17431 * target.h (target_ops): New get_tib_address field.
17432 * win32-low.h (win32_thread_info): Add thread_local_base field.
17433 * win32-low.c (child_add_thread): Add tlb argument.
17434 Set thread_local_base field to TLB.
17435 (get_child_debug_event): Adapt to child_add_thread change.
17436 (win32_get_tib_address): New function.
17437 (win32_target_ops): Set get_tib_address field to
17438 win32_get_tib_address.
17439 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17440
505106cd
PA
174412010-04-12 Pedro Alves <pedro@codesourcery.com>
17442
505106cd
PA
17443 * linux-low.c (linux_mourn): Also remove the process.
17444 * server.c (handle_target_event): Don't remove the process here.
17445 * nto-low.c (nto_mourn): New.
17446 (nto_target_ops): Install it.
17447 * spu-low.c (spu_mourn): New.
17448 (spu_target_ops): Install it.
17449 * win32-low.c (win32_mourn): New.
17450 (win32_target_ops): Install it.
17451
e8470a06
PA
174522010-04-12 Pedro Alves <pedro@codesourcery.com>
17453
17454 * server.h (buffer_xml_printf): Remove redundant `;'.
17455
45ba0d02
PA
174562010-04-12 Pedro Alves <pedro@codesourcery.com>
17457
17458 * regcache.c (set_register_cache): Invalidate regcaches before
17459 changing the register cache layout.
17460 (regcache_invalidate_one): Allow a NULL regcache.
17461 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17462 regcaches before changing the register cache layout or the target
17463 regsets.
17464
59e04013
L
174652010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17466
17467 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17468 variable warning on Linux/x86-64.
17469
8336d594
PA
174702010-04-11 Pedro Alves <pedro@codesourcery.com>
17471
17472 GDBserver disconnected tracing support.
17473
17474 * linux-low.c (linux_remove_process): Delete.
17475 (add_lwp): Don't set last_resume_kind here.
17476 (linux_kill): Use `mourn'.
17477 (linux_detach): Use `thread_db_detach', and `mourn'.
17478 (linux_mourn): New.
17479 (linux_attach_lwp_1): Adjust comment.
17480 (linux_attach): last_resume_kind moved the thread_info; adjust.
17481 (status_pending_p_callback): Adjust.
17482 (linux_wait_for_event_1): Adjust.
17483 (count_events_callback, select_singlestep_lwp_callback)
17484 (select_event_lwp_callback, cancel_breakpoints_callback)
17485 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17486 (proceed_one_lwp): Adjust.
17487 (linux_async): Add debug output.
17488 (linux_thread_stopped): New.
17489 (linux_pause_all): New.
17490 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17491 linux_pause_all.
17492 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17493 (thread_db_free): Delete declaration.
17494 (thread_db_detach, thread_db_mourn): Declare.
17495 * thread-db.c (thread_db_init): Use thread_db_mourn.
17496 (thread_db_free): Delete, split in two.
17497 (disable_thread_event_reporting): New.
17498 (thread_db_detach): New.
17499 (thread_db_mourn): New.
17500
17501 * server.h (struct thread_info) <last_resume_kind>: New field.
17502 <attached>: Add comment.
17503 <gdb_detached>: New field.
17504 (handler_func): Change return type to int.
17505 (handle_serial_event, handle_target_event): Ditto.
17506 (gdb_connected): Declare.
17507 (tracing): Delete.
17508 (disconnected_tracing): Declare.
17509 (stop_tracing): Declare.
17510
17511 * server.c (handle_query) <qSupported>: Report support for
17512 disconnected tracing.
17513 (queue_stop_reply_callback): Account for running threads.
17514 (gdb_wants_thread_stopped): New.
17515 (gdb_wants_all_threads_stopped): New.
17516 (gdb_reattached_process): New.
17517 (handle_status): Clear the `gdb_detached' flag of all processes.
17518 In all-stop, stop all threads.
17519 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17520 (process_serial_event): If the remote connection breaks, or if an
17521 exit was forced with "monitor exit", force an event loop exit.
17522 Handle disconnected tracing on detach.
17523 (handle_serial_event): Adjust.
17524 (handle_target_event): If GDB isn't connected, forward events back
17525 to the inferior, unless the last process exited, in which case,
17526 exit gdbserver. Adjust interface.
17527
17528 * remote-utils.c (remote_open): Don't block in accept. Instead
17529 register an event loop source on the listen socket file
17530 descriptor. Refactor bits into ...
17531 (listen_desc): ... this new global.
17532 (gdb_connected): ... this new function.
17533 (enable_async_notification): ... this new function.
17534 (handle_accept_event): ... this new function.
17535 (remote_close): Clear remote_desc.
17536
17537 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17538
17539 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17540 New fields.
17541 (mourn_inferior): Define.
17542 (target_process_qsupported): Avoid the dangling else problem.
17543 (thread_stopped): Define.
17544 (pause_all): Define.
17545 (target_waitstatus_to_string): Declare.
17546 * target.c (target_waitstatus_to_string): New.
17547
17548 * tracepoint.c (tracing): Make extern.
17549 (disconnected_tracing): New.
17550 (stop_tracing): Make extern. Handle tracing stops due to GDB
17551 disconnecting.
17552 (cmd_qtdisconnected): New.
17553 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17554 (handle_tracepoint_general_set): Handle QTDisconnected.
17555
17556 * event-loop.c (event_handler_func): Change return type to int.
17557 (process_event): Bail out if the event handler wants the event
17558 loop to stop.
17559 (handle_file_event): Ditto.
17560 (start_event_loop): Bail out if the event handler wants the event
17561 loop to stop.
17562
17563 * nto-low.c (nto_target_ops): Adjust.
17564 * spu-low.c (spu_wait): Don't remove the process here.
17565 (spu_target_ops): Adjust.
17566 * win32-low.c (win32_wait): Don't remove the process here.
17567 (win32_target_ops): Adjust.
17568
5d267c4c
PA
175692010-04-11 Pedro Alves <pedro@codesourcery.com>
17570
17571 * regcache.c (realloc_register_cache): Invalidate inferior's
17572 regcache before recreating it.
17573
623ccd72
PA
175742010-04-09 Pedro Alves <pedro@codesourcery.com>
17575
17576 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17577
219f2f23
PA
175782010-04-09 Stan Shebs <stan@codesourcery.com>
17579 Pedro Alves <pedro@codesourcery.com>
17580
17581 * server.h (LONGEST): New.
17582 (struct thread_info) <while_stepping>: New field.
17583 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17584 Declare.
17585 (initialize_tracepoint, handle_tracepoint_general_set)
17586 (handle_tracepoint_query, tracepoint_finished_step)
17587 (tracepoint_was_hit, release_while_stepping_state_list):
17588 (current_traceframe): Declare.
17589 * server.c (handle_general_set): Handle tracepoint packets.
17590 (read_memory): New.
17591 (write_memory): New.
17592 (handle_search_memory_1): Use read_memory.
17593 (handle_query): Report support for conditional tracepoints, trace
17594 state variables, and tracepoint sources. Handle tracepoint
17595 queries.
17596 (main): Initialize the tracepoints module.
17597 (process_serial_event): Handle traceframe reads/writes.
17598
17599 * linux-low.c (handle_tracepoints): New.
17600 (linux_wait_1): Call it.
17601 (linux_resume_one_lwp): Handle while-stepping.
17602 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17603 (linux_target_ops): Install them.
17604 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17605 New field.
17606 * linux-x86-low.c (x86_supports_tracepoints): New.
17607 (the_low_target). Install it.
17608
17609 * mem-break.h (delete_breakpoint): Declare.
17610 * mem-break.c (delete_breakpoint): Make external.
17611
17612 * target.h (struct target_ops): Add `supports_tracepoints',
17613 `read_pc', and `write_pc' fields.
17614 (target_supports_tracepoints): Define.
17615 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17616 (phex_nz): New.
17617
17618 * regcache.h (struct regcache) <registers_owned>: New field.
17619 (init_register_cache, regcache_cpy): Declare.
17620 (regcache_read_pc, regcache_write_pc): Declare.
17621 (register_cache_size): Declare.
17622 (supply_regblock): Declare.
17623 * regcache.c (init_register_cache): New.
17624 (new_register_cache): Use it.
17625 (regcache_cpy): New.
17626 (register_cache_size): New.
17627 (supply_regblock): New.
17628 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 17629
219f2f23
PA
17630 * tracepoint.c: New.
17631
17632 * Makefile.in (OBS): Add tracepoint.o.
17633 (tracepoint.o): New rule.
17634
3a13a53b
L
176352010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17636
17637 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17638 (i386-mmx.o): New.
17639 (i386-mmx.c): Likewise.
17640 (i386-mmx-linux.o): Likewise.
17641 (i386-mmx-linux.c): Likewise.
17642
17643 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17644 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17645 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17646 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17647
17648 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17649 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17650 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17651
1570b33e
L
176522010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17653
17654 * Makefile.in (clean): Updated.
17655 (i386-avx.o): New.
17656 (i386-avx.c): Likewise.
17657 (i386-avx-linux.o): Likewise.
17658 (i386-avx-linux.c): Likewise.
17659 (amd64-avx.o): Likewise.
17660 (amd64-avx.c): Likewise.
17661 (amd64-avx-linux.o): Likewise.
17662 (amd64-avx-linux.c): Likewise.
17663
17664 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17665 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17666 (srv_amd64_regobj): Add amd64-avx.o.
17667 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17668 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17669 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17670 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17671 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17672 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17673 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17674
17675 * i387-fp.c: Include "i386-xstate.h".
17676 (i387_xsave): New.
17677 (i387_cache_to_xsave): Likewise.
17678 (i387_xsave_to_cache): Likewise.
17679 (x86_xcr0): Likewise.
17680
17681 * i387-fp.h (i387_cache_to_xsave): Likewise.
17682 (i387_xsave_to_cache): Likewise.
17683 (x86_xcr0): Likewise.
17684
17685 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17686 * linux-crisv32-low.c (target_regsets): Likewise.
17687 * linux-m68k-low.c (target_regsets): Likewise.
17688 * linux-mips-low.c (target_regsets): Likewise.
17689 * linux-ppc-low.c (target_regsets): Likewise.
17690 * linux-s390-low.c (target_regsets): Likewise.
17691 * linux-sh-low.c (target_regsets): Likewise.
17692 * linux-sparc-low.c (target_regsets): Likewise.
17693 * linux-xtensa-low.c (target_regsets): Likewise.
17694
17695 * linux-low.c: Include <sys/uio.h>.
17696 (regsets_fetch_inferior_registers): Support nt_type.
17697 (regsets_store_inferior_registers): Likewise.
17698 (linux_process_qsupported): New.
17699 (linux_target_ops): Add linux_process_qsupported.
17700
17701 * linux-low.h (regset_info): Add nt_type.
17702 (linux_target_ops): Add process_qsupported.
17703
17704 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17705 and <sys/uio.h>.
17706 (init_registers_i386_avx_linux): New.
17707 (init_registers_amd64_avx_linux): Likewise.
17708 (xmltarget_i386_linux_no_xml): Likewise.
17709 (xmltarget_amd64_linux_no_xml): Likewise.
17710 (PTRACE_GETREGSET): Likewise.
17711 (PTRACE_SETREGSET): Likewise.
17712 (x86_fill_xstateregset): Likewise.
17713 (x86_store_xstateregset): Likewise.
17714 (use_xml): Likewise.
17715 (x86_linux_update_xmltarget): Likewise.
17716 (x86_linux_process_qsupported): Likewise.
17717 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17718 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17719 init_registers_i386_linux here. Call
17720 x86_linux_update_xmltarget.
17721 (the_low_target): Add x86_linux_process_qsupported.
17722
17723 * server.c (handle_query): Call target_process_qsupported.
17724
17725 * target.h (target_ops): Add process_qsupported.
17726 (target_process_qsupported): New.
17727
fc7238bb
PA
177282010-04-03 Pedro Alves <pedro@codesourcery.com>
17729
17730 * inferiors.c (add_thread): Set last_status kind to
17731 TARGET_WAITKIND_IGNORE.
17732 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17733 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17734 (linux_wait_1): Move `thread' local definition to block that uses
17735 it. Don't NULL initialize `event_child'.
17736 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17737 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17738 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17739
bdabb078
PA
177402010-04-01 Pedro Alves <pedro@codesourcery.com>
17741
17742 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17743 an extended waitstatus, or by a watchpoint.
17744 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17745 thread was stepping or has been stopped by a watchpoint.
17746
d3bbe7a0
PA
177472010-04-01 Pedro Alves <pedro@codesourcery.com>
17748
17749 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17750 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17751 of another, then delete the previous, and validate all
17752 breakpoints.
17753 (validate_inserted_breakpoint): New.
17754 (delete_disabled_breakpoints): New.
17755 (validate_breakpoints): New.
17756 (check_mem_read): Validate breakpoints before trusting their
17757 shadow. Delete disabled breakpoints.
17758 (check_mem_write): Validate breakpoints before trusting they
17759 should be inserted. Delete disabled breakpoints.
17760 * mem-break.h (validate_breakpoints):
17761 * server.c (handle_query): Validate breakpoints when we see a
17762 qSymbol query.
17763
8b07ae33
PA
177642010-04-01 Pedro Alves <pedro@codesourcery.com>
17765
17766 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17767 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17768 if we could tell there's a GDB breakpoint at stop_pc.
17769 (need_step_over_p): Don't do a step over if we find a GDB
17770 breakpoint at the resume PC.
17771
17772 * mem-break.c (struct raw_breakpoint): New.
17773 (enum bkpt_type): New type `gdb_breakpoint'.
17774 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17775 fields. New field `raw'.
17776 (find_raw_breakpoint_at): New.
17777 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17778 breakpoint instead.
17779 (set_breakpoint_at): Adjust.
17780 (delete_raw_breakpoint): New.
17781 (release_breakpoint): New.
17782 (delete_breakpoint): Rename to...
17783 (delete_breakpoint_1): ... this. Add proc parameter. Use
17784 release_breakpoint. Return ENOENT.
17785 (delete_breakpoint): Reimplement.
17786 (find_breakpoint_at): Delete.
17787 (find_gdb_breakpoint_at): New.
17788 (delete_breakpoint_at): Delete.
17789 (set_gdb_breakpoint_at): New.
17790 (delete_gdb_breakpoint_at): New.
17791 (gdb_breakpoint_here): New.
17792 (set_reinsert_breakpoint): Use release_breakpoint.
17793 (uninsert_breakpoint): Rename to ...
17794 (uninsert_raw_breakpoint): ... this.
17795 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17796 (reinsert_raw_breakpoint): Change parameter type to
17797 raw_breakpoint.
17798 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17799 instead.
17800 (check_breakpoints): Adjust. Use release_breakpoint.
17801 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17802 (breakpoint_inserted_here): Ditto.
17803 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17804 Don't trust the breakpoint's shadow if it is not inserted.
17805 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17806 (delete_all_breakpoints): Adjust.
17807 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17808 use delete_breakpoint_1.
17809
17810 * mem-break.h (breakpoints_supported): Delete declaration.
17811 (set_gdb_breakpoint_at): Declare.
17812 (gdb_breakpoint_here): Declare.
17813 (delete_breakpoint_at): Delete.
17814 (delete_gdb_breakpoint_at): Declare.
17815
17816 * server.h (struct raw_breakpoint): Forward declare.
17817 (struct process_info): New field `raw_breakpoints'.
17818
17819 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17820 breakpoints.
17821
6bf5e0ba
PA
178222010-03-24 Pedro Alves <pedro@codesourcery.com>
17823
17824 * linux-low.c (status_pending_p_callback): Fix comment.
17825 (linux_wait_for_event_1): Move most of the internal breakpoint
17826 handling from here...
17827 (linux_wait_1): ... to here.
17828 (count_events_callback): New.
17829 (select_singlestep_lwp_callback): New.
17830 (select_event_lwp_callback): New.
17831 (cancel_breakpoints_callback): New.
17832 (select_event_lwp): New.
17833 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17834 priority to all LWPs that have had events that should be reported
17835 to the client. Cancel breakpoints when about to reporting the
17836 event to the client, not while stopping lwps. No longer cancel
17837 finished single-steps here.
17838 (cancel_finished_single_step): Delete.
17839 (cancel_finished_single_steps): Delete.
17840
414a389f
PA
178412010-03-24 Pedro Alves <pedro@codesourcery.com>
17842
17843 * mem-break.c (enum bkpt_type): New.
17844 (struct breakpoint): New field `type'.
17845 (set_breakpoint_at): Change return type to struct breakpoint
17846 pointer. Set type to `other_breakpoint' by default.
17847 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17848 in the breakpoint list.
17849 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17850 (reinsert_breakpoint): Rename to ...
17851 (reinsert_raw_breakpoint): ... this.
17852 (reinsert_breakpoints_at): Adjust.
17853 * mem-break.h (struct breakpoint): Declare.
17854 (set_breakpoint_at): Change return type to struct breakpoint
17855 pointer.
17856
2280c721
PA
178572010-03-24 Pedro Alves <pedro@codesourcery.com>
17858
17859 * server.c (handle_query): Assign, not compare.
17860
d50171e4
PA
178612010-03-24 Pedro Alves <pedro@codesourcery.com>
17862
17863 Teach linux gdbserver to step-over-breakpoints.
17864
17865 * linux-low.c (can_hardware_single_step): New.
17866 (supports_breakpoints): New.
17867 (handle_extended_wait): If stopping threads, read the stop pc of
17868 the new cloned LWP.
17869 (get_pc): New.
17870 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17871 low target doesn't support retrieving the PC.
17872 (add_lwp): Set last_resume_kind to resume_continue.
17873 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17874 (linux_attach): Don't clear stop_expected. Set the lwp's
17875 last_resume_kind to resume_stop.
17876 (linux_detach_one_lwp): Don't check for removed breakpoints.
17877 (check_removed_breakpoint): Delete.
17878 (status_pending_p): Rename to ...
17879 (status_pending_p_callback): ... this. Don't check for removed
17880 breakpoints. Don't consider threads that are stopped from GDB's
17881 perspective.
17882 (linux_wait_for_lwp): Always read the stop_pc here.
17883 (cancel_breakpoint): New.
17884 (step_over_bkpt): New global.
17885 (linux_wait_for_event_1): Implement stepping over breakpoints.
17886 (gdb_wants_lwp_stopped): New.
17887 (gdb_wants_all_stopped): New.
17888 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17889 single-step traps here. Store the thread's last reported target
17890 wait status.
17891 (send_sigstop): Don't clear stop_expected. Always set it,
17892 instead.
17893 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17894 (cancel_finished_single_step): New.
17895 (cancel_finished_single_steps): New.
17896 (wait_for_sigstop): Don't cancel finished single-step traps here.
17897 (linux_resume_one_lwp): Don't check for removed breakpoints.
17898 Don't set `step' on non-hardware step archs.
17899 (linux_set_resume_request): Ignore resume_stop requests if already
17900 stopping or stopped. Set the lwp's last_resume_kind.
17901 (resume_status_pending_p): Don't check for removed breakpoints.
17902 (need_step_over_p): New.
17903 (start_step_over): New.
17904 (finish_step_over): New.
17905 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17906 requests. Clear the thread's last reported target waitstatus.
17907 Don't use the `suspended' flag. Don't consider pending breakpoints.
17908 (linux_resume): Start a step-over if necessary.
17909 (proceed_one_lwp): New.
17910 (proceed_all_lwps): New.
17911 (unstop_all_lwps): New.
17912 * linux-low.h (struct lwp_info): Rewrite comment for the
17913 `suspended' flag. Add the `stop_pc' field. Delete the
17914 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17915 Add `'last_resume_kind' and `need_step_over' fields.
17916 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17917 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17918 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17919 (set_raw_breakpoint_at): New.
17920 (set_breakpoint_at): Rewrite to use it.
17921 (reinsert_breakpoint_handler): Delete.
17922 (set_reinsert_breakpoint): New.
17923 (reinsert_breakpoint_by_bp): Delete.
17924 (delete_reinsert_breakpoints): New.
17925 (uninsert_breakpoint): Rewrite.
17926 (uninsert_breakpoints_at): New.
17927 (reinsert_breakpoint): Rewrite.
17928 (reinsert_breakpoints_at): New.
17929 (check_breakpoints): Rewrite.
17930 (breakpoint_here): New.
17931 (breakpoint_inserted_here): New.
17932 (check_mem_read): Adjust.
17933 * mem-break.h (breakpoints_supported, breakpoint_here)
17934 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
17935 (reinsert_breakpoint_by_bp): Delete declaration.
17936 (delete_reinsert_breakpoints): Declare.
17937 (reinsert_breakpoint): Delete declaration.
17938 (reinsert_breakpoints_at): Declare.
17939 (uninsert_breakpoint): Delete declaration.
17940 (uninsert_breakpoints_at): Declare.
17941 (check_breakpoints): Adjust prototype.
17942 * server.h: Adjust include order.
17943 (struct thread_info): Declare here. Add a `last_status' field.
17944
30ba68cb
MS
179452010-03-23 Michael Snyder <msnyder@vmware.com>
17946
17947 * server.c (crc32): New function.
17948 (handle_query): Add handling for 'qCRC:' request.
17949
b9a881c2
PA
179502010-03-23 Pedro Alves <pedro@codesourcery.com>
17951
17952 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
17953 lwp had been stopped by a watchpoint.
17954
e92d13d5
PA
179552010-03-16 Pedro Alves <pedro@codesourcery.com>
17956
17957 * server.h (internal_error): Declare.
17958 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
17959 * utils.c (internal_error): New function.
17960
64daa791
AS
179612010-03-15 Andreas Schwab <schwab@redhat.com>
17962
17963 * configure.srv: Fix typo setting srv_regobj.
17964
f52cd8cd
PA
179652010-03-15 Pedro Alves <pedro@codesourcery.com>
17966
17967 * linux-low.c (fetch_register): Avoid passing a non string literal
17968 format to `error'.
17969 (usr_store_inferior_registers): Ditto.
17970
93ae6fdc
PA
179712010-03-14 Pedro Alves <pedro@codesourcery.com>
17972
17973 * linux-low.c (linux_write_memory): Bail out early if peeking
17974 memory failed.
17975
c3adc08c
PA
179762010-03-14 Pedro Alves <pedro@codesourcery.com>
17977
17978 * linux-low.h (struct lwp_info): New fields
17979 `stopped_by_watchpoint' and `stopped_data_address'.
17980 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
17981 here, and cache them in the lwp object.
17982 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
17983 directly.
17984 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
17985 field.
17986 (linux_stopped_by_watchpoint): Rewrite.
17987 (linux_stopped_data_address): Rewrite.
17988
bce522a2
PA
179892010-03-06 Simo Melenius <simo.melenius@iki.fi>
17990
17991 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
17992 switching the current inferior, not before.
17993
90884b2b
L
179942010-03-01 H.J. Lu <hongjiu.lu@intel.com>
17995
17996 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
17997 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
17998 i386-linux.c and amd64-linux.c.
17999 (reg-i386.o): Removed.
18000 (reg-i386.c): Likewise.
18001 (reg-i386-linux.o): Likewise.
18002 (reg-i386-linux.c): Likewise.
18003 (reg-x86-64.o): Likewise.
18004 (reg-x86-64.c): Likewise.
18005 (reg-x86-64-linux.o): Likewise.
18006 (reg-x86-64-linux.c): Likewise.
18007 (i386.o): New.
18008 (i386.c): Likewise.
18009 (i386-linux.o): Likewise.
18010 (i386-linux.c): Likewise.
18011 (amd64.o): Likewise.
18012 (amd64.c): Likewise.
18013 (amd64-linux.o): Likewise.
18014 (amd64-linux.c): Likewise.
18015
18016 * configure.srv (srv_i386_regobj): New.
18017 (srv_i386_linux_regobj): Likewise.
18018 (srv_amd64_regobj): Likewise.
18019 (srv_amd64_linux_regobj): Likewise.
18020 (srv_i386_32bit_xmlfiles): Likewise.
18021 (srv_i386_64bit_xmlfiles): Likewise.
18022 (srv_i386_xmlfiles): Likewise.
18023 (srv_amd64_xmlfiles): Likewise.
18024 (srv_i386_linux_xmlfiles): Likewise.
18025 (srv_amd64_linux_xmlfiles): Likewise.
18026 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18027 srv_xmlfiles to $srv_i386_xmlfiles.
18028 (i[34567]86-*-mingw32ce*): Likewise.
18029 (i[34567]86-*-mingw*): Likewise.
18030 (i[34567]86-*-nto*): Likewise.
18031 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18032 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18033 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18034 (x86_64-*-linux*): Likewise.
18035
18036 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18037 (init_registers_amd64_linux): New.
18038 (x86_arch_setup): Replace init_registers_x86_64_linux with
18039 init_registers_amd64_linux.
18040
193f13e6
MK
180412010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18042
18043 * configure.ac: Check for libdl. If it is not available link against
18044 static libthread_db.
18045 * configure: Regenerate.
18046
85d721b8
PA
180472010-02-22 Pedro Alves <pedro@codesourcery.com>
18048
18049 PR9605
18050
18051 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18052 handing a read watchpoint.
18053 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18054
6076632b
DE
180552010-02-12 Doug Evans <dje@google.com>
18056
18057 * linux-low.c (linux_supports_tracefork_flag): Document.
18058 (linux_look_up_symbols): Add comment.
18059
3327ccf7
L
180602010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18061
18062 * regcache.c (supply_register): Clear regcache if buf is NULL.
18063
0718675c 180642010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 18065 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
18066
18067 * inferiors.c (find_inferior): Add function documentation.
18068 (unloaded_dll): Handle the case where the unloaded dll has not
18069 been previously registered in the dll list.
18070
177321bd
DJ
180712010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18072
18073 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18074 (thumb2_breakpoint): New.
18075 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18076
2b009048
DJ
180772010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18078
18079 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18080 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18081 breakpoints.
18082
3be029c7
PA
180832010-01-21 Pedro Alves <pedro@codesourcery.com>
18084
18085 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18086
18f5de3b
JK
180872010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18088
18089 * linux-s390-low.c (s390_collect_ptrace_register)
18090 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18091
3743bb4f
DE
180922010-01-21 Doug Evans <dje@google.com>
18093
14ce3065
DE
18094 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18095 (PTRACE_ARG4_TYPE): New macro.
18096 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18097 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18098 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18099 (usr_store_inferior_registers): Ditto.
18100 (linux_read_memory, linux_write_memory): Ditto.
18101 (linux_test_for_tracefork): Ditto.
18102
3743bb4f
DE
18103 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18104 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18105
8b315be5
PA
181062010-01-21 Pedro Alves <pedro@codesourcery.com>
18107
18108 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18109 target.
18110
85492558
PA
181112010-01-21 Pedro Alves <pedro@codesourcery.com>
18112
18113 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18114 prototype to take a regcache. Adjust.
18115
442ea881
PA
181162010-01-20 Pedro Alves <pedro@codesourcery.com>
18117
18118 * regcache.h (struct thread_info): Forward declare.
18119 (struct regcache): New.
18120 (new_register_cache): Adjust prototype.
18121 (get_thread_regcache): Declare.
18122 (free_register_cache): Adjust prototype.
18123 (registers_to_string, registers_from_string): Ditto.
18124 (supply_register, supply_register_by_name, collect_register)
18125 (collect_register_as_string, collect_register_by_name): Ditto.
18126 * regcache.c (struct inferior_regcache_data): Delete.
18127 (get_regcache): Rename to ...
18128 (get_thread_regcache): ... this. Adjust. Switch inferior before
18129 fetching registers.
18130 (regcache_invalidate_one): Adjust.
18131 (regcache_invalidate): Fix prototype.
18132 (new_register_cache): Return the new register cache.
18133 (free_register_cache): Change prototype.
18134 (realloc_register_cache): Adjust.
18135 (registers_to_string): Change prototype to take a regcache. Adjust.
18136 (registers_from_string): Ditto.
18137 (register_data): Ditto.
18138 (supply_register): Ditto.
18139 (supply_register_by_name): Ditto.
18140 (collect_register): Ditto.
18141 (collect_register_as_string): Ditto.
18142 (collect_register_by_name): Ditto.
18143 * server.c (process_serial_event): Adjust.
18144 * linux-low.h (regset_fill_func, regset_store_func): Change
18145 prototype.
18146 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18147 Change prototype.
18148 * linux-low.c (get_stop_pc): Adjust.
18149 (check_removed_breakpoint): Adjust.
18150 (linux_wait_for_event): Adjust.
18151 (linux_resume_one_lwp): Adjust.
18152 (fetch_register): Add regcache parameter. Adjust.
18153 (usr_store_inferior_registers): Ditto.
18154 (regsets_fetch_inferior_registers): Ditto.
18155 (regsets_store_inferior_registers): Ditto.
18156 (linux_fetch_registers, linux_store_registers): Ditto.
18157 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18158 regcache. Adjust.
43aaf8b6
PA
18159 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18160 Ditto.
442ea881
PA
18161 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18162 prototype to take a regcache.
18163 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18164 * remote-utils.c (convert_ascii_to_int, outreg)
18165 (prepare_resume_reply): Change prototype to take a regcache.
18166 Adjust.
18167 * target.h (struct target_ops) <fetch_registers, store_registers>:
18168 Change prototype to take a regcache.
18169 (fetch_inferior_registers, store_inferior_registers): Change
18170 prototype to take a regcache. Adjust.
18171 * proc-service.c (ps_lgetregs): Adjust.
18172 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18173 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18174 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18175 take a regcache. Adjust.
18176 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18177 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18178 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18179 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18180 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18181 (cris_cannot_fetch_register):
18182 (cris_breakpoint_at): Change prototype to take a regcache.
18183 Adjust.
18184 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18185 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18186 to take a regcache. Adjust.
18187 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18188 Adjust.
18189 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18190 take a regcache. Adjust.
18191 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18192 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18193 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18194 * linux-mips-low.c (mips_get_pc):
18195 (mips_set_pc): Change prototype to take a regcache. Adjust.
18196 (mips_reinsert_addr): Adjust.
18197 (mips_collect_register): Change prototype to take a regcache.
18198 Adjust.
18199 (mips_supply_register):
18200 (mips_collect_register_32bit, mips_supply_register_32bit)
18201 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18202 (mips_store_fpregset): Ditto.
43aaf8b6
PA
18203 * linux-ppc-low.c (ppc_supply_ptrace_register)
18204 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
18205 (parse_spufs_run): Adjust.
18206 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18207 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18208 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18209 take a regcache. Adjust.
18210 * linux-s390-low.c (s390_collect_ptrace_register)
18211 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18212 (s390_set_pc): Change prototype to take a regcache. Adjust.
18213 (s390_arch_setup): Adjust.
18214 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18215 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18216 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18217 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18218 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18219 regcache. Adjust.
18220 (sparc_breakpoint_at): Adjust.
18221 * linux-xtensa-low.c (xtensa_fill_gregset):
18222 (xtensa_store_gregset):
18223 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18224 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18225 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18226 prototype to take a regcache. Adjust.
18227 * win32-arm-low.c (arm_fetch_inferior_register)
18228 (arm_store_inferior_register): Change prototype to take a
18229 regcache. Adjust.
18230 * win32-i386-low.c (i386_fetch_inferior_register)
18231 (i386_store_inferior_register): Change prototype to take a
18232 regcache. Adjust.
18233 * win32-low.c (child_fetch_inferior_registers)
18234 (child_store_inferior_registers): Change prototype to take a
18235 regcache. Adjust.
18236 (win32_wait): Adjust.
18237 (win32_fetch_inferior_registers): Change prototype to take a
18238 regcache. Adjust.
18239 (win32_store_inferior_registers): Adjust.
18240 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18241 store_inferior_register>: Change prototype to take a regcache.
18242
60c3d7b0
DE
182432010-01-20 Doug Evans <dje@google.com>
18244
18245 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18246 #ifdef.
18247 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 18248 (W_STOPCODE): Provide definition if missing.
60c3d7b0 18249
dc146f7c
VP
182502010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18251
18252 * linux-low.c (linux_core_of_thread): New.
18253 (compare_ints, show_process, list_threads): New.
18254 (linux_qxfer_osdata): Report threads and cores.
18255 (linux_target_op): Register linux_core_of_thread.
18256 * remote-utils.c (prepare_resume_reply): Report the core.
18257 (buffer_xml_printf): Support %d specifier.
18258 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18259 New.
18260 (handle_query): Handle qXfer:threads. Announce availability
18261 thereof.
18262 * target.h (struct target_ops): New field core_of_thread.
18263
7803799a
UW
182642010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18265
18266 * Makefile.in (clean): Remove new generated files.
18267 (reg-s390.o, reg-s390.c): Remove rules.
18268 (reg-s390x.o, reg-s390x.c): Likewise.
18269 (s390-linux32.o, s390-linux32.c): Add rules.
18270 (s390-linux64.o, s390-linux64.c): Likewise.
18271 (s390x-linux64.o, s390x-linux64.c): Likewise.
18272 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18273 * linux-s390-low.c: Include <elf.h>.
18274 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18275 (init_registers_s390): Remove prototype.
18276 (init_registers_s390x): Likewise.
18277 (init_registers_s390_linux32): Add prototype.
18278 (init_registers_s390_linux64): Likewise.
18279 (init_registers_s390x_linux64): Likewise.
18280 (s390_num_regs_3264): New define.
18281 (s390_regmap_3264): New global variable.
18282 (s390_cannot_fetch_register): Remove obsolete check.
18283 (s390_cannot_store_register): Likewise.
18284 (s390_collect_ptrace_register): Handle upper/lower register halves.
18285 (s390_supply_ptrace_register): Likewise.
18286 (s390_fill_gregset): Update to register number changes.
18287 (s390_get_hwcap): New routine.
18288 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18289 Install appropriate regmap and register set.
18290
6e7ffa39
JB
182912010-01-01 Joel Brobecker <brobecker@adacore.com>
18292
18293 * server.c (gdbserver_version): Update copyright year to 2010.
18294 * gdbreplay.c (gdbreplay_version): Likewise.
18295
957f3f49
DE
182962009-12-28 Doug Evans <dje@google.com>
18297
18298 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18299 elf/external.h. Include <elf.h> instead but only if necessary.
18300
ca5c370d
PA
183012009-12-28 Pedro Alves <pedro@codesourcery.com>
18302
18303 * linux-low.c (linux_remove_process): Remove `detaching'
18304 parameter. Don't release/detach from thread_db here.
18305 (linux_kill): Release/detach from thread_db here, ...
18306 (linux_detach): ... and here, before actually detaching.
18307 (linux_wait_1): ... and here, when a process exits.
18308 * thread-db.c (any_thread_of): New.
18309 (thread_db_free): Switch the current inferior to a thread of the
18310 passed in process.
18311
4ee62156
DE
183122009-12-21 Doug Evans <dje@google.com>
18313
d90e6a88
DE
18314 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18315
c5f62d5f
DE
18316 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18317 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18318 warning ifndef __NR_tkill. Move setting of errno there too.
18319 Delete unnecessary resetting of errno after syscall.
18320 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18321
10e86dd7
DE
18322 * configure.ac: Check for dladdr.
18323 * config.in: Regenerate.
18324 * configure: Regenerate.
18325 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18326 (try_thread_db_load): Update.
18327
4ee62156
DE
18328 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18329
00f515da
DE
183302009-12-18 Doug Evans <dje@google.com>
18331
e9464885
DE
18332 * event-loop.c: Include unistd.h if it exists.
18333
07d4f67e
DE
18334 * linux-low.c (my_waitpid): Move definition away from being in
18335 between linux_tracefork_child/linux_test_for_tracefork.
18336
00f515da
DE
18337 * gdb_proc_service.h (psaddr_t): Fix type.
18338 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18339 signature to match glibc.
18340
1de1badb
DE
183412009-12-16 Doug Evans <dje@google.com>
18342
18343 * linux-low.c (linux_read_memory): Fix argument to read.
18344
aeeb81d1
PA
183452009-11-26 Pedro Alves <pedro@codesourcery.com>
18346
18347 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18348 events, don't leave current_inferior pointing at null.
18349
10357975
PA
183502009-11-26 Pedro Alves <pedro@codesourcery.com>
18351
18352 * win32-low.c (LOG): Delete.
18353 (OUTMSG): Output to stderr.
18354 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18355 on compile time LOG macro.
18356 (win32_wait): Fix debug output.
18357
cf6e3471
PA
183582009-11-26 Pedro Alves <pedro@codesourcery.com>
18359
18360 * win32-low.c (win32_add_one_solib): If the dll name is
18361 "ntdll.dll", prepend the system directory to the dll path.
18362
0c85e18e
MK
183632009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18364
18365 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18366
9ac544ce 183672009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 18368 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
18369
18370 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18371 * configure.ac: Check for __mcoldfire__ and set
18372 gdb_cv_m68k_is_coldfire.
18373 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18374 reg-cf.o and reg-m68k.o.
18375 * configure: Regenerated.
18376
fd7dd3e6
PA
183772009-11-16 Pedro Alves <pedro@codesourcery.com>
18378
18379 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18380 Pass it to thread_db_free.
18381 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18382 proper `detaching' argument to linux_remove_process.
18383 * linux-low.h (thread_db_free): Add `detaching' parameter.
18384 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18385 to thread_db_free.
18386 (thread_db_free): Add `detaching' parameter. Only
18387 call td_ta_clear_event if detaching from process.
18388
75aa492e
MK
183892009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18390
18391 * thread-db.c (thread_db_free): Fix typo.
18392
21e1bee4
PP
183932009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18394
18395 PR gdb/10838
18396 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18397
8838b45e
NS
183982009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18399
18400 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18401 with an i686 compiler.
18402 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18403 needed.
18404 * configure: Rebuilt.
18405
8a35fb51
SL
184062009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18407
18408 PR gdb/10783
18409
18410 * server.c (handle_search_memory_1): Correct read_addr initialization
18411 in loop for searching subsequent chunks.
18412
96f15937
PP
184132009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18414
18415 * configure.ac: New --with-libthread-db option.
18416 * thread-db.c: Allow direct dependence on libthread_db.
18417 (thread_db_free): Adjust.
18418 * config.in: Regenerate.
18419 * configure: Likewise.
889bf7c5 18420
5f7d1694
PP
184212009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18422
18423 PR gdb/10757
18424 * thread-db.c (attach_thread): New function.
18425 (maybe_attach_thread): Return success/failure.
18426 (find_new_threads_callback): Adjust.
889bf7c5
PA
18427 (thread_db_find_new_threads): Loop until no new threads.
18428
88e3b899
PA
184292009-10-13 Pedro Alves <pedro@codesourcery.com>
18430
18431 * proc-service.c (ps_lgetregs): Formatting.
18432
cdbfd419
PP
184332009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18434
18435 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18436 * configure.ac: Adjust.
18437 * linux-low.h (struct process_info_private): Move members to struct
18438 thread_db.
18439 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18440 * linux-low.c (linux_remove_process): Adjust.
18441 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18442 * server.c (handle_query): Move code ...
18443 (handle_monitor_command): ... here. New function.
18444 * target.h (struct target_ops): New member.
18445 * thread-db.c (struct thread_db): New.
18446 (libthread_db_search_path): New variable.
18447 (thread_db_create_event, thread_db_enable_reporting)
18448 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18449 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18450 (try_thread_db_load_1, dladdr_to_soname): New functions.
18451 (try_thread_db_load, thread_db_load_search): New functions.
18452 (thread_db_init): Search for libthread_db.
18453 (thread_db_free): New function.
18454 (thread_db_handle_monitor_command): Likewise.
18455 * config.in: Regenerate.
18456 * configure: Regenerate.
889bf7c5 18457
4168d2d6
UW
184582009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18459
18460 * spu-low.c (spu_kill): Wait for inferior to terminate.
18461 Call clear_inferiors.
18462 (spu_detach): Call clear_inferiors.
18463
81ecdfbb
RW
184642009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18465
18466 * aclocal.m4: Regenerate.
18467 * config.in: Likewise.
18468 * configure: Likewise.
18469
0b9ff2c0
UW
184702009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18471
18472 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18473 (parse_spufs_run): New function.
18474 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18475 (ppc_breakpoint_at): Handle SPU breakpoints.
18476
efcbbd14
UW
184772009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18478
18479 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18480 (SPUFS_MAGIC): Define.
18481 (spu_enumerate_spu_ids): New function.
18482 (linux_qxfer_spu): New function.
18483 (linux_target_ops): Install linux_qxfer_spu.
18484
f4d9bade
UW
184852009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18486
18487 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18488 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18489 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18490 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18491 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18492 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18493 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18494 (init_registers_powerpc_cell32l): Add prototype.
18495 (init_registers_powerpc_cell64l): Likewise.
18496 (ppc_arch_setup): Detect Cell/B.E. architecture.
18497
96e946ca
RW
184982009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18499
18500 * Makefile.in (datarootdir): New variable.
18501
58d6951d
DJ
185022009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18503
18504 * linux-low.c (linux_write_memory): Update debugging output.
18505 * Makefile.in (clean): Add new descriptions.
18506 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18507 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18508 * configure.srv: Add new files for arm*-*-linux*.
18509 * linux-arm-low.c: Add new declarations.
18510 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18511 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18512 (HWCAP_VFPv3D16): New.
18513 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18514 instead of __IWMMXT__.
18515 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18516 (arm_arch_setup): New.
18517 (target_regsets): Remove #ifdef. Add VFP regset.
18518 (the_low_target): Use arm_arch_setup.
18519
12b42a12
DJ
185202009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18521
18522 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18523 the main thread again.
18524
ac8c974e
AR
185252009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18526
18527 Adding Neutrino gdbserver.
18528 * configure: Regenerated.
18529 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18530 * configure.srv (i[34567]86-*-nto*): New target.
18531 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18532 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18533 (nto_comctrl) [__QNX__]: New function.
18534 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18535
4424e0c3 185362009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
18537
18538 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18539 srv_tgtobj.
18540
912cf4ba
PA
185412009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18542 Pedro Alves <pedro@codesourcery.com>
18543
18544 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18545 don't support CONTEXT_EXTENDED_REGISTERS.
18546 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18547 (the_low_target): Install them.
18548 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18549 failing with ERROR_PIPE_NOT_CONNECTED.
18550
aa5ca48f
DE
185512009-06-30 Doug Evans <dje@google.com>
18552 Pierre Muller <muller@ics.u-strasbg.fr>
18553
18554 Add h/w watchpoint support to x86-linux, win32-i386.
18555 * Makefile.in (SFILES): Add i386-low.c
18556 (i386_low_h): Define.
18557 (i386-low.o): Add dependencies.
18558 (linux-x86-low.o): Add i386-low.h dependency.
18559 (win32-i386-low.o): Ditto.
18560 * i386-low.c: New file.
18561 * i386-low.h: New file.
18562 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18563 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18564 * linux-low.c (linux_add_process): Initialize arch_private.
18565 (linux_remove_process): Free arch_private.
18566 (add_lwp): Initialize arch_private.
18567 (delete_lwp): Free arch_private.
18568 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18569 provided.
18570 * linux-low.h (process_info_private): New member arch_private.
18571 (lwp_info): New member arch_private.
18572 (linux_target_ops): New members new_process, new_thread,
18573 prepare_to_resume.
18574 (ptid_of): New macro.
18575 * linux-x86-low.c: Include stddef.h, i386-low.h.
18576 (arch_process_info): New struct.
18577 (arch_lwp_info): New struct.
18578 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18579 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18580 (i386_dr_low_get_status): New function.
18581 (x86_insert_point, x86_remove_point): New functions.
18582 (x86_stopped_by_watchpoint): New function.
18583 (x86_stopped_data_address): New function.
18584 (x86_linux_new_process, x86_linux_new_thread): New functions.
18585 (x86_linux_prepare_to_resume): New function.
18586 (the_low_target): Add entries for insert_point, remove_point,
18587 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18588 prepare_to_resume.
18589 * server.c (debug_hw_points): New global.
18590 (monitor_show_help): Document set debug-hw-points.
18591 (handle_query): Process "set debug-hw-points".
18592 * server.h (debug_hw_points): Declare.
18593 (paddress): Declare.
18594 * utils.c (NUMCELLS, CELLSIZE): New macros.
18595 (get_sell, xsnprintf, paddress): New functions.
18596 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18597 remove_point, stopped_by_watchpoint, stopped_data_address.
18598 * win32-i386-low.c: Include i386-low.h.
18599 (debug_reg_state): Replaces dr.
18600 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18601 (i386_dr_low_get_status): New function.
18602 (i386_insert_point, i386_remove_point): New functions.
18603 (i386_stopped_by_watchpoint): New function.
18604 (i386_stopped_data_address): New function.
18605 (i386_initial_stuff): Update.
18606 (get_thread_context,set_thread_context,i386_thread_added): Update.
18607 (the_low_target): Add entries for insert_point,
18608 remove_point, stopped_by_watchpoint, stopped_data_address.
18609 * win32-low.c (win32_insert_watchpoint): New function.
18610 (win32_remove_watchpoint): New function.
18611 (win32_stopped_by_watchpoint): New function.
18612 (win32_stopped_data_address): New function.
18613 (win32_target_ops): Add entries for insert_watchpoint,
18614 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18615 * win32-low.h (win32_target_ops): New members insert_point,
18616 remove_point, stopped_by_watchpoint, stopped_data_address.
18617
d993e290
PA
186182009-06-25 Pedro Alves <pedro@codesourcery.com>
18619
18620 * server.c (process_serial_event): Re-return unsupported, not
18621 error, if the type isn't recognized. Re-allow supporting only
18622 insert or remove packets. Also call require_running for
18623 breakpoints. Add missing break statement to default case. Tidy.
18624 * target.h (struct target_ops): Rename insert_watchpoint to
18625 insert_point, and remove_watchpoint to remove_point.
18626
18627 * linux-low.h (struct linux_target_ops): Likewise.
18628 * linux-low.c (linux_insert_watchpoint): Rename to ...
18629 (linux_insert_point): ... this. Adjust.
18630 (linux_remove_watchpoint): Rename to ...
18631 (linux_remove_point): ... this. Adjust.
18632 (linux_target_ops): Adjust.
18633 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18634 (cris_insert_point): ... this.
18635 (cris_remove_watchpoint): Rename to ...
18636 (cris_remove_point): ... this.
18637 (the_low_target): Adjust.
18638
0f54c268
PM
186392009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18640
18641 * server.c (handle_v_kill): Pass signal_pid to
18642 kill_inferior if multi_process is zero.
18643
c6314022
AR
186442009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18645
18646 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18647 * target.h (target_ops): Comment for *_watchpoint to make it clear
18648 the functions can get types '0' and '1'.
18649
4463ce24
AR
186502009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18651
18652 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18653 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18654 * regcache.c (get_regcache): Likewise.
18655 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18656 * win32-low.c (child_fetch_inferior_registers): Remove check for
18657 regno 0.
18658
cf8fd78b
PA
186592009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18660 Pedro Alves <pedro@codesourcery.com>
18661
18662 * target.h (struct target_ops) <supports_multi_process>: New
18663 callback.
18664 (target_supports_multi_process): New.
18665 * server.c (handle_query): Even if GDB reports support, only
18666 enable multi-process if the target also supports it. Report
18667 multi-process support only if the target backend supports it.
18668 * linux-low.c (linux_supports_multi_process): New function.
18669 (linux_target_ops): Install it as target_supports_multi_process
18670 callback.
18671
47c0c975
DE
186722009-05-24 Doug Evans <dje@google.com>
18673
e09875d4
DE
18674 Global renaming of find_thread_pid to find_thread_ptid.
18675 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18676 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18677 All callers updated.
18678
e27d73f6
DE
18679 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18680 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18681 directly.
18682
47c0c975
DE
18683 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18684 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18685 (linux_resume_one_lwp): Ditto.
18686
2acc282a
DE
186872009-05-23 Doug Evans <dje@google.com>
18688
18689 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18690 from struct inferior_list_entry * to struct lwp_info *.
18691 All callers updated.
18692
9f1036c1
DE
186932009-05-13 Doug Evans <dje@google.com>
18694
18695 * linux-x86-low.c: Don't include assert.h.
18696 (x86_siginfo_fixup): Use fatal, not assert.
18697 (x86_arch_setup): Fix comment.
18698
d0722149
DE
186992009-05-12 Doug Evans <dje@google.com>
18700
18701 Biarch support for i386/amd64 gdbserver.
18702 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18703 Add linux-x86-low.c.
18704 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18705 (linux-x86-low.o): Add.
18706 * linux-x86-64-low.c: Delete.
18707 * linux-i386-low.c: Delete.
18708 * linux-x86-low.c: New file.
18709 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18710 linux-x86-low.o.
18711 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18712 linux-x86-low.o.
18713 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18714 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18715 (linux_child_pid_to_exec_file): New function.
18716 (elf_64_header_p, elf_64_file_p): New functions.
18717 (siginfo_fixup): New function.
18718 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18719 give target a chance to convert layout.
18720 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18721 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18722
fdeb2a12
DE
187232009-05-07 Doug Evans <dje@google.com>
18724
18725 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18726 (regsets_store_inferior_registers): Ditto.
18727
a6dbe5df
PA
187282009-05-06 Pedro Alves <pedro@codesourcery.com>
18729
18730 PR server/10048
18731
18732 * linux-low.c (must_set_ptrace_flags): Delete.
18733 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18734 of the global.
18735 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18736 `lwp->must_set_ptrace_flags' instead.
ba42693b 18737 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
18738 (linux_wait_1): ... not here.
18739
5091eb23
DE
187402009-04-30 Doug Evans <dje@google.com>
18741
9f767825
DE
18742 * inferiors.c (started_inferior_callback): New function.
18743 (attached_inferior_callback): New function.
18744 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18745 * server.c (print_started_pid, print_attached_pid): New functions.
18746 (detach_or_kill_for_exit): New function.
18747 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18748 * server.h (have_started_inferiors_p): Declare.
18749 (have_attached_inferiors_p): Declare.
18750
5091eb23
DE
18751 * inferiors.c (remove_process): Fix memory leak, free process.
18752 * linux-low.c (linux_remove_process): New function.
18753 (linux_kill): Call it instead of remove_process.
18754 (linux_detach, linux_wait_1): Ditto.
18755
155c8968
PA
187562009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18757
18758 * configure.srv: Add x86 Windows CE target.
18759
7fe519cb
UW
187602009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18761
18762 * inferiors.c (get_thread_process): Make global.
18763 * server.h (get_thread_process): Add prototype.
18764 * thread-db.c (find_one_thread): Use get_thread_process
18765 instead of current_process.
18766 (thread_db_get_tls_address): Do not crash if called when
18767 thread layer is not yet initialized.
18768
5472f405
UW
187692009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18770
18771 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18772 * spu-low.c (current_tid): Rename to ...
18773 (current_ptid): ... this.
18774 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18775 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18776 ptid_get_lwp (current_ptid) instead of current_tid.
18777 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18778 instead of current_tid. Use find_process_pid to verify pid
18779 argument is valid. Pass proper argument to remove_process.
18780 (spu_thread_alive): Compare current_ptid instead of current_tid.
18781 (spu_resume): Likewise.
18782
55ac2b99
PA
187832009-04-02 Pedro Alves <pedro@codesourcery.com>
18784
18785 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18786 variable.
18787
95954743
PA
187882009-04-01 Pedro Alves <pedro@codesourcery.com>
18789
18790 Implement the multiprocess extensions, and add linux multiprocess
18791 support.
18792
18793 * server.h (ULONGEST): Declare.
18794 (struct ptid, ptid_t): New.
18795 (minus_one_ptid, null_ptid): Declare.
18796 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18797 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18798 (struct inferior_list_entry): Change `id' type from unsigned from
18799 to ptid_t.
18800 (struct sym_cache, struct breakpoint, struct
18801 process_info_private): Forward declare.
18802 (struct process_info): Declare.
18803 (current_process): Declare.
18804 (all_processes): Declare.
18805 (initialize_inferiors): Declare.
18806 (add_thread): Adjust to use ptid_t.
18807 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18808 (add_process, remove_process, find_thread_pid): Declare.
18809 (find_inferior_id): Adjust to use ptid_t.
18810 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18811 (multi_process): Declare.
18812 (push_event): Adjust to use ptid_t.
18813 (read_ptid, write_ptid): Declare.
18814 (prepare_resume_reply): Adjust to use ptid_t.
18815 (clear_symbol_cache): Declare.
18816 * inferiors.c (all_processes): New.
18817 (null_ptid, minus_one_ptid): New.
18818 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18819 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18820 (add_thread): Change unsigned long to ptid. Remove gdb_id
18821 parameter. Adjust.
18822 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18823 (gdb_id_to_thread): Rename to ...
18824 (find_thread_pid): ... this. Change unsigned long to ptid.
18825 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18826 (loaded_dll, pull_pid_from_list): Adjust.
18827 (add_process, remove_process, find_process_pid)
18828 (get_thread_process, current_process, initialize_inferiors): New.
18829 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18830 (struct target_waitstatus) <related_pid>: Ditto.
18831 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18832 return type to int.
18833 (struct target_ops) <join>: Add `pid' argument.
18834 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18835 (struct target_ops) <wait>: Add `ptid' field. Change return type
18836 to ptid.
18837 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18838 (mywait): Add `ptid' argument. Change return type to ptid_t.
18839 (target_pid_to_str): Declare.
18840 * target.c (set_desired_inferior): Adjust to use ptids.
18841 (mywait): Add new `ptid' argument. Adjust.
18842 (target_pid_to_str): New.
18843 * mem-break.h (free_all_breakpoints): Declare.
18844 * mem-break.c (breakpoints): Delelete.
18845 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18846 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18847 to use per-process breakpoint list.
18848 (free_all_breakpoints): New.
18849 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18850 (symbol_cache, all_symbols_looked_up): Delete.
18851 (hexchars): New.
18852 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18853 read_ptid): New.
18854 (prepare_resume_reply): Change ptid argument's type from unsigned
18855 long to ptid_t. Adjust. Implement W;process and X;process.
18856 (free_sym_cache, clear_symbol_cache): New.
18857 (look_up_one_symbol): Adjust to per-process symbol cache. *
18858 * server.c (cont_thread, general_thread, step_thread): Change type
18859 to ptid_t.
18860 (attached): Delete.
18861 (multi_process): New.
18862 (last_ptid): Change type to ptid_t.
18863 (struct vstop_notif) <ptid>: Change type to ptid_t.
18864 (queue_stop_reply, push_event): Change `ptid' argument's type to
18865 ptid_t.
18866 (discard_queued_stop_replies): Add `pid' argument.
18867 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18868 changes. Don't reference the `attached' global.
18869 (attach_inferior): Adjust to mywait interface changes.
18870 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18871 features. Handle and report "multiprocess+". Handle
18872 "qAttached:PID".
18873 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18874 changes.
18875 (handle_v_kill): New.
18876 (handle_v_stopped): Adjust to use target_pid_to_str.
18877 (handle_v_requests): Allow multiple attaches and runs when
18878 multiprocess extensions are in effect. Handle "vKill".
18879 (myresume): Adjust to use ptids.
18880 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18881 (handle_status): Adjust to discard_queued_stop_replies interface
18882 change.
18883 (first_thread_of, kill_inferior_callback)
18884 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18885 (main): Call initialize_inferiors. Adjust to use ptids, killing
18886 and detaching from all inferiors. Handle multiprocess packet
18887 variants.
18888 * linux-low.h: Include gdb_proc_service.h.
18889 (struct process_info_private): New.
18890 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18891 <lwpid_of>: Use ptid_get_lwp.
18892 (get_lwp_thread): Adjust.
18893 (struct lwp_info): Add `dead' member.
18894 (find_lwp_pid): Declare.
18895 * linux-low.c (thread_db_active): Delete.
18896 (new_inferior): Adjust comment.
18897 (inferior_pid): Delete.
18898 (linux_add_process): New.
18899 (handle_extended_wait): Adjust.
18900 (add_lwp): Change unsigned long to ptid.
18901 (linux_create_inferior): Add process to processes table. Adjust
18902 to use ptids. Don't set new_inferior here.
18903 (linux_attach_lwp): Rename to ...
18904 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18905 it. Adjust to use ptids.
18906 (linux_attach_lwp): New.
18907 (linux_attach): Add process to processes table. Don't set
18908 new_inferior here.
18909 (struct counter): New.
18910 (second_thread_of_pid_p, last_thread_of_process_p): New.
18911 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18912 multiple processes.
18913 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18914 processes. Remove process from process table.
18915 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18916 to multiple processes.
18917 (any_thread_of): New.
18918 (linux_detach): Add `pid' argument, and handle it. Remove process
18919 from processes table.
18920 (linux_join): Add `pid' argument. Handle it.
18921 (linux_thread_alive): Change unsighed long argument to ptid_t.
18922 Consider dead lwps as not being alive.
18923 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
18924 threads we're not interested in.
18925 (same_lwp, find_lwp_pid): New.
18926 (linux_wait_for_lwp): Change `pid' argument's type from int to
18927 ptid_t. Adjust.
18928 (linux_wait_for_event): Rename to ...
18929 (linux_wait_for_event_1): ... this. Change `pid' argument's type
18930 from int to ptid_t. Adjust.
18931 (linux_wait_for_event): New.
18932 (linux_wait_1): Add `ptid' argument. Change return type to
18933 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
18934 that exit from the process table.
18935 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
18936 Adjust.
18937 (mark_lwp_dead): New.
18938 (wait_for_sigstop): Adjust to use ptids. If a process exits while
18939 stopping all threads, mark its main lwp as dead.
18940 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
18941 ptids.
18942 (fetch_register, usr_store_inferior_registers)
18943 (regsets_fetch_inferior_registers)
18944 (regsets_store_inferior_registers, linux_read_memory)
18945 (linux_write_memory): Inline `inferior_pid'.
18946 (linux_look_up_symbols): Adjust to use per-process
18947 `thread_db_active'.
18948 (linux_request_interrupt): Adjust to use ptids.
18949 (linux_read_auxv): Inline `inferior_pid'.
18950 (initialize_low): Don't reference thread_db_active.
18951 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
18952 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
18953 (ps_getpid): Return the pid of the current inferior.
18954 * thread-db.c (proc_handle, thread_agent): Delete.
18955 (thread_db_create_event, thread_db_enable_reporting): Adjust to
18956 per-process data.
18957 (find_one_thread): Change argument type to ptid_t. Adjust to
18958 per-process data.
18959 (maybe_attach_thread): Adjust to per-process data and ptids.
18960 (thread_db_find_new_threads): Ditto.
18961 (thread_db_init): Ditto.
18962 * spu-low.c (spu_create_inferior, spu_attach): Add process to
18963 processes table. Adjust to use ptids.
18964 (spu_kill, spu_detach): Adjust interface. Remove process from
18965 processes table.
18966 (spu_join, spu_thread_alive): Adjust interface.
18967 (spu_wait): Adjust interface. Remove process from processes
18968 table. Adjust to use ptids.
18969 * win32-low.c (current_inferior_tid): Delete.
18970 (current_inferior_ptid): New.
18971 (debug_event_ptid): New.
18972 (thread_rec): Take a ptid. Adjust.
18973 (child_add_thread): Add `pid' argument. Adjust to use ptids.
18974 (child_delete_thread): Ditto.
18975 (do_initial_child_stuff): Add `attached' argument. Add process to
18976 processes table.
18977 (child_fetch_inferior_registers, child_store_inferior_registers):
18978 Adjust.
18979 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
18980 (win32_attach): Pass 1 to do_initial_child_stuff.
18981 (win32_kill): Adjust interface. Remove process from processes
18982 table.
18983 (win32_detach): Ditto.
18984 (win32_join): Adjust interface.
18985 (win32_thread_alive): Take a ptid.
18986 (win32_resume): Adjust to use ptids.
18987 (get_child_debug_event): Ditto.
18988 (win32_wait): Adjust interface. Remove exiting process from
18989 processes table.
18990
bd99dc85
PA
189912009-04-01 Pedro Alves <pedro@codesourcery.com>
18992
18993 Non-stop mode support.
18994
18995 * server.h (non_stop): Declare.
18996 (gdb_client_data, handler_func): Declare.
18997 (delete_file_handler, add_file_handler, start_event_loop):
18998 Declare.
18999 (handle_serial_event, handle_target_event, push_event)
19000 (putpkt_notif): Declare.
19001 * target.h (enum resume_kind): New.
19002 (struct thread_resume): Replace `step' field by `kind' field.
19003 (TARGET_WNOHANG): Define.
19004 (struct target_ops) <wait>: Add `options' argument.
19005 <supports_non_stop, async, start_non_stop>: New fields.
19006 (target_supports_non_stop, target_async): New.
19007 (start_non_stop): Declare.
19008 (mywait): Add `options' argument.
19009 * target.c (mywait): Add `options' argument. Print child exit
19010 notifications here.
19011 (start_non_stop): New.
19012 * server.c (non_stop, own_buf, mem_buf): New globals.
19013 (struct vstop_notif): New.
19014 (notif_queue): New global.
19015 (queue_stop_reply, push_event, discard_queued_stop_replies)
19016 (send_next_stop_reply): New.
19017 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19018 interface changes.
19019 (attach_inferior): In non-stop mode, don't wait for the target
19020 here.
19021 (handle_general_set): Handle QNonStop.
19022 (handle_query): When handling qC, return the current general
19023 thread, instead of the first thread of the list.
19024 (handle_query): If the backend supports non-stop mode, include
19025 QNonStop+ in the qSupported query response.
19026 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19027 and non-stop mode.
19028 (handle_v_attach, handle_v_run): Handle non-stop mode.
19029 (handle_v_stopped): New.
19030 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19031 (myresume): Adjust to use resume_kind. Handle non-stop.
19032 (queue_stop_reply_callback): New.
19033 (handle_status): Handle non-stop mode.
19034 (main): Clear non_stop flag on reconnection. Use the event-loop.
19035 Refactor serial protocol handling from here ...
19036 (process_serial_event): ... to this new function. When GDB
19037 selects any thread, select one here. In non-stop mode, wait until
19038 GDB acks all pending events before exiting.
19039 (handle_serial_event, handle_target_event): New.
19040 * remote-utils.c (remote_open): Install remote_desc in the event
19041 loop.
19042 (remote_close): Remove remote_desc from the event loop.
19043 (putpkt_binary): Rename to...
19044 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19045 (putpkt_binary): New as wrapper around putpkt_binary_1.
19046 (putpkt_notif): New.
19047 (prepare_resume_reply): In non-stop mode, don't change the
19048 general_thread.
19049 * event-loop.c: New.
19050 * Makefile.in (OBJ): Add event-loop.o.
19051 (event-loop.o): New rule.
19052
19053 * linux-low.h (pid_of): Moved here.
19054 (lwpid_of): New.
19055 (get_lwp_thread): Use lwpid_of.
19056 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19057 * linux-low.c (pid_of): Delete.
19058 (inferior_pid): Use lwpid_of.
19059 (linux_event_pipe): New.
19060 (target_is_async_p): New.
19061 (delete_lwp): New.
19062 (handle_extended_wait): Use lwpid_of.
19063 (add_lwp): Don't set lwpid field.
19064 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19065 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19066 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19067 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19068 first. Adjust to linux_wait_for_event interface changes. Use
19069 lwpid_of.
19070 (linux_detach): Don't delete the main lwp here.
19071 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19072 (status_pending_p): Don't consider explicitly suspended lwps.
19073 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19074 pointer. Add OPTIONS argument. Change return type to int. Use
19075 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19076 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19077 pointer. Add status pointer argument. Return a pid instead of a
19078 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19079 changes. In non-stop mode, don't switch to a random thread.
19080 (linux_wait): Rename to...
19081 (linux_wait_1): ... this. Add target_options argument, and handle
19082 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19083 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19084 clean exit and signal exit code. Don't stop all threads in
19085 non-stop mode. In all-stop mode, only stop all threads when
19086 reporting a stop to GDB. Handle explicit thread stop requests.
19087 (async_file_flush, async_file_mark): New.
19088 (linux_wait): New.
19089 (send_sigstop): Use lwpid_of.
19090 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19091 interface changes. In non-stop mode, don't switch to a random
19092 thread.
19093 (linux_resume_one_lwp): Use lwpid_of.
19094 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19095 (linux_resume_one_thread): ... this. Handle resume_stop. In
19096 non-stop mode, don't look for pending flag in all threads.
19097 (resume_status_pending_p): Don't consider explicitly suspended
19098 threads.
19099 (my_waitpid): Reimplement. Emulate __WALL.
19100 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19101 Use lwpid_of.
19102 (sigchld_handler, linux_supports_non_stop, linux_async)
19103 (linux_start_non_stop): New.
19104 (linux_target_ops): Register linux_supports_non_stop, linux_async
19105 and linux_start_non_stop.
19106 (initialize_low): Install SIGCHLD handler.
19107 * thread-db.c (thread_db_create_event, find_one_thread)
19108 (thread_db_get_tls_address): Use lwpid_of.
19109 * win32-low.c (win32_detach): Adjust to use resume_kind.
19110 (win32_wait): Add `options' argument.
19111 * spu-low.c (spu_resume): Adjust to use resume_kind.
19112 (spu_wait): Add `options' argument.
19113
5b1c542e
PA
191142009-04-01 Pedro Alves <pedro@codesourcery.com>
19115
19116 Decouple target code from remote protocol.
19117
19118 * target.h (enum target_waitkind): New.
19119 (struct target_waitstatus): New.
19120 (struct target_ops) <wait>: Return an unsigned long. Take a
19121 target_waitstatus pointer instead of a char pointer.
19122 (mywait): Likewise.
19123 * target.c (mywait): Change prototype to return an unsigned long.
19124 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19125 * server.h (thread_from_wait, old_thread_from_wait): Delete
19126 declarations.
19127 (prepare_resume_reply): Change prototype to take a
19128 target_waitstatus.
19129 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19130 (last_status, last_ptid): New.
19131 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19132 pid instead of a signal.
19133 (attach_inferior): Remove "status" and "signal" parameters.
19134 Adjust.
19135 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19136 not as an address.
19137 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19138 (handle_v_requests, myresume): Remove "status" and "signal"
19139 parameters. Adjust.
19140 (handle_status): New.
19141 (main): Delete local `status'. Adjust.
19142 * remote-utils.c: Include target.h.
19143 (prepare_resume_reply): Change prototype to take a
19144 target_waitstatus. Adjust.
19145
19146 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19147 interface.
19148 * spu-low.c (spu_wait): Adjust.
19149 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19150 Delete.
19151 (win32_wait): Adjust.
19152
2bd7c093
PA
191532009-04-01 Pedro Alves <pedro@codesourcery.com>
19154
19155 * target.h (struct thread_resume): Delete leave_stopped member.
19156 (struct target_ops): Add a `n' argument to the `resume' callback.
19157 * server.c (start_inferior): Adjust.
19158 (handle_v_cont, myresume): Adjust.
19159 * linux-low.c (check_removed_breakpoint): Adjust to resume
19160 interface change, and to removed leave_stopped field.
19161 (resume_ptr): Delete.
19162 (struct thread_resume_array): New.
19163 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19164 resume interface change.
19165 (linux_continue_one_thread, linux_queue_one_thread)
19166 (resume_status_pending_p): Check if the resume field is NULL
19167 instead of checking the leave_stopped member.
19168 (linux_resume): Adjust to the target resume interface change.
19169 * spu-low.c (spu_resume): Adjust to the target resume interface
19170 change.
19171 * win32-low.c (win32_detach, win32_resume): Ditto.
19172
c35fafde
PA
191732009-04-01 Pedro Alves <pedro@codesourcery.com>
19174
19175 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19176 flag.
19177 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19178 pending.
19179 (linux_continue_one_thread): Only preserve the stepping flag if
19180 there's a pending breakpoint.
19181
0a59d50b
PA
191822009-03-31 Pedro Alves <pedro@codesourcery.com>
19183
19184 * server.c (main): After the inferior having exited, call
19185 remote_close before exiting gdbserver.
19186
f04c6d38
TJB
191872009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19188
19189 Fix size of FPSCR in Power 7 processors.
19190 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19191 (PPC_FEATURE_HAS_DFP): New #define.
19192 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19193 size of the FPSCR.
19194
78e5cee6
PA
191952009-03-23 Pedro Alves <pedro@codesourcery.com>
19196
19197 * server.c (handle_query) Whitespace and formatting.
19198
1b3f6016
PA
191992009-03-22 Pedro Alves <pedro@codesourcery.com>
19200
19201 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19202 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19203 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19204 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19205 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19206 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19207 Makefile.in, configure.ac: Fix whitespace throughout.
19208 * configure: Regenerate.
19209
a07b2135
PA
192102009-03-22 Pedro Alves <pedro@codesourcery.com>
19211
19212 * inferiors.c (find_inferior): Make it safe for the callback
19213 function to delete the currently iterated inferior.
19214
67cc2626
PA
192152009-03-22 Pedro Alves <pedro@codesourcery.com>
19216
19217 * Makefile.in (linuw_low_h): Move higher.
19218 (thread-db.o): Depend on $(linux_low_h).
19219
54a0b537
PA
192202009-03-17 Pedro Alves <pedro@codesourcery.com>
19221
19222 Rename "process" to "lwp" throughout.
19223
19224 * linux-low.c (all_processes): Rename to...
19225 (all_lwps): ... this.
19226 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19227 (add_process): Rename to ...
19228 (add_lwp): ... this. Adjust.
19229 (linux_create_inferior): Adjust.
19230 (linux_attach_lwp): Adjust.
19231 (linux_attach): Adjust.
19232 (linux_kill_one_process): Rename to ...
19233 (linux_kill_one_lwp): ... this. Adjust.
19234 (linux_kill): Adjust.
19235 (linux_detach_one_process): Rename to ...
19236 (linux_detach_one_lwp): ... this. Adjust.
19237 (linux_detach): Adjust.
19238 (check_removed_breakpoint): Adjust.
19239 (status_pending_p): Adjust.
19240 (linux_wait_for_process): Rename to ...
19241 (linux_wait_for_lwp): ... this. Adjust.
19242 (linux_wait_for_event): Adjust.
19243 (send_sigstop): Adjust.
19244 (wait_for_sigstop): Adjust.
19245 (stop_all_processes): Rename to ...
19246 (stop_all_lwps): ... this.
19247 (linux_resume_one_process): Rename to ...
19248 (linux_resume_one_lwp): ... this. Adjust.
19249 (linux_set_resume_request, linux_continue_one_thread)
19250 (linux_queue_one_thread, resume_status_pending_p)
19251 (usr_store_inferior_registers, regsets_store_inferior_registers)
19252 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19253 Adjust.
19254 * linux-low.h (get_process): Rename to ...
19255 (get_lwp): ... this. Adjust.
19256 (get_thread_process): Rename to ...
19257 (get_thread_lwp): ... this. Adjust.
19258 (get_process_thread): Rename to ...
19259 (get_lwp_thread): ... this. Adjust.
19260 (struct process_info): Rename to ...
19261 (struct lwp_info): ... this.
19262 (all_processes): Rename to ...
19263 (all_lwps): ... this.
19264 * proc-service.c (ps_lgetregs): Adjust.
19265 * thread-db.c (thread_db_create_event, find_one_thread)
19266 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19267
0b16c5cf
PA
192682009-03-14 Pedro Alves <pedro@codesourcery.com>
19269
19270 * server.c (handle_query): Handle "qAttached".
19271
32de4b9d
NS
192722009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19273
19274 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19275 GPLv3, update license URL.
19276
2aecd87f
DE
192772009-03-01 Doug Evans <dje@google.com>
19278
93efd302 19279 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
19280 (server_h): Add gdb_signals.h.
19281 (signals.o): Update.
19282 * server.h (target_signal_from_host,target_signal_to_host_p)
19283 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19284
86b1f9c5
PM
192852009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19286
19287 * remote-utils.c (getpkt): Also generate remote-debug
19288 information if noack_mode is set.
19289
4aa995e1
PA
192902009-02-06 Pedro Alves <pedro@codesourcery.com>
19291
19292 * server.c (handle_query): Report qXfer:siginfo:read and
19293 qXfer:siginfo:write as supported and handle them.
19294 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19295 * linux-low.c (linux_xfer_siginfo): New.
19296 (linux_target_ops): Set it.
19297
62709adf
PA
192982009-01-26 Pedro Alves <pedro@codesourcery.com>
19299
19300 * server.c (gdbserver_usage): Mention --remote-debug.
19301 (main): Accept '--remote-debug' switch.
19302
aef93bd7
DE
193032009-01-18 Doug Evans <dje@google.com>
19304
19305 * regcache.c (new_register_cache): No need to check result of xcalloc.
19306 * server.c (handle_search_memory): Back out calls to xmalloc,
19307 result is checked and error is returned to user upon failure.
19308 (handle_query): Ditto. Add more checks for result of malloc.
19309 (handle_v_cont): Check result of malloc, report error back to
19310 user upon failure.
19311 (handle_v_run): Ditto. Call freeargv.
19312 * server.h (freeargv): Declare.
19313 * utils.c (freeargv): New fn.
19314
54363045
DE
193152009-01-15 Doug Evans <dje@google.com>
19316
f626972c
DE
19317 * gdbreplay.c (perror_with_name): Make arg const char *.
19318 * server.h (target_signal_to_name): Make return type const char *.
0842e787 19319 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 19320 * utils.c (perror_with_name): Make arg const char *.
54363045 19321
18aae699
PA
193222009-01-14 Pedro Alves <pedro@codesourcery.com>
19323
19324 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19325 when handling a EXIT_PROCESS_DEBUG_EVENT.
19326
ff703abe
JB
193272009-01-06 Joel Brobecker <brobecker@adacore.com>
19328
19329 * gdbreplay.c (gdbreplay_version): Update copyright year.
19330 * server.c (gdbserver_version): Likewise.
19331
f21cc1a2 193322009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
19333
19334 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 19335 (handle_extended_wait): Improve comment.
0e21c1ec 19336
bca929d3
DE
193372008-12-13 Doug Evans <dje@google.com>
19338
19339 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19340 * server.h (ATTR_MALLOC): New macro.
19341 (xmalloc,xcalloc,xstrdup): Declare.
19342 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19343 * inferiors.c: Ditto.
19344 * linux-low.c: Ditto.
19345 * mem-break.c: Ditto.
19346 * regcache.c: Ditto.
19347 * remote-utils.c: Ditto.
19348 * server.c: Ditto.
19349 * target.c: Ditto.
19350 * win32-low.c: Ditto.
19351
97438e3f
DE
193522008-12-12 Doug Evans <dje@google.com>
19353
896c7fbb
DE
19354 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19355 in debugging printf.
19356
97438e3f
DE
19357 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19358
e3b886f8
DE
193592008-12-09 Doug Evans <dje@google.com>
19360
19361 * linux-low.h (struct process_info): Delete member tid, unused.
19362 * thread-db.c (find_one_thread): Update.
19363 (maybe_attach_thread): Update.
19364
07e059b5
VP
193652008-12-02 Pedro Alves <pedro@codesourcery.com>
19366
889bf7c5
PA
19367 * target.h (struct target_ops): Add qxfer_osdata member.
19368 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19369 and dirent.h.
19370 (linux_qxfer_osdata): New functions.
19371 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19372 callback.
19373 * server.c (handle_query): Handle "qXfer:osdata:read:".
19374 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19375 (buffer_xml_printf): New functions.
19376 * server.h (struct buffer): New.
19377 (buffer_grow_str, buffer_grow_str0): New macros.
19378 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19379 (buffer_xml_printf): Declare.
07e059b5 19380
4cab47ab
DE
193812008-11-24 Doug Evans <dje@google.com>
19382
19383 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19384
f142445f
DJ
193852008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19386
19387 * server.c (handle_v_run): Always use the supplied argument list.
19388
d0107bb6 193892008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 19390
d0107bb6
BW
19391 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19392 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 19393
2c4ad781
TJB
193942008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19395
19396 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19397 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19398 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19399 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19400 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19401 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19402 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19403 XML target descriptions.
19404 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19405 when inferior is running on an ISA 2.05 or later processor. Add
19406 special case to return offset for full 64-bit slot of FPSCR when
19407 in 32-bits.
19408
dfb64f85
DJ
194092008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19410
19411 * Makefile.in (SFILES, clean): Added sparc64 files.
19412 (reg-sparc64.o, reg-sparc64.c): New.
19413 * configure.srv (sparc*-*-linux*): New configuration.
19414 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19415 syscall arguments for SPARC.
19416 (regsets_store_inferior_registers): Likewise.
19417 * linux-sparc-low.c: New file.
19418
66b6e1dd
DE
194192008-10-21 Doug Evans <dje@google.com>
19420
19421 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19422 (READLINE_DIR,READLINE_DEP): Delete.
19423 (INTERNAL_CFLAGS): Update.
19424 (LINTFLAGS): Update.
19425
9b710a42
PA
194262008-10-10 Pedro Alves <pedro@codesourcery.com>
19427
19428 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19429 whole argv from the last run, not just argv[0].
19430
5822d809
PA
194312008-09-08 Pedro Alves <pedro@codesourcery.com>
19432
19433 * regcache.c (new_register_cache): Return NULL if the register
19434 cache size isn't known yet.
19435 (free_register_cache): Avoid dereferencing a NULL regcache.
19436
74aac56f
DJ
194372008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19438
19439 * configure.srv: Merge MIPS and MIPS64.
19440
400b20f5
MR
194412008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19442
19443 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19444
677c5bb1
LM
194452008-08-18 Luis Machado <luisgpm@br.ibm.com>
19446
19447 * Makefile.in: Add required vsx dependencies.
19448
19449 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19450 Declare init_registers_powerpc_vsx32l.
19451 Declare init_registers_powerpc_vsx64l.
19452 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19453 (ppc_arch_setup): Check for VSX in hwcap.
19454 (ppc_fill_vsxregset): New function.
19455 (ppc_store_vsxregset): New function.
19456 Add new VSX entry in regset_info target_regsets.
19457
19458 * configure.srv: Add new VSX dependencies.
19459
a6f3e723
SL
194602008-08-12 Pedro Alves <pedro@codesourcery.com>
19461
19462 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19463 (remote_open): Set or clear transport_is_reliable.
19464 (putpkt_binary): Don't expect acks in noack mode.
19465 (getpkt): Don't send ack/nac in noack mode.
19466 * server.c (handle_general_set): Handle QStartNoAckMode.
19467 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19468 qSupported.
19469 (main): Reset noack_mode on every connection.
19470 * server.h (noack_mode): Declare.
19471
a417dc56
RW
194722008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19473
19474 * Makefile.in (GDBREPLAY_OBS): New variable.
19475 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19476
3221518c
UW
194772008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19478 Daniel Jacobowitz <dan@codesourcery.com>
19479
19480 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19481 (usr_store_inferior_registers): Likewise.
19482 (regsets_store_inferior_registers): Likewise.
19483
ec56be1b
PA
194842008-07-31 Rolf Jansen <rj@surtec.com>
19485 Pedro Alves <pedro@codesourcery.com>
19486
19487 * configure.ac: Check for memmem declaration.
19488 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19489 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19490 (disable_packet_qfThreadInfo): Unconditionally compile.
19491 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19492 * configure, config.in: Regenerate.
19493
2fe5e3ff
DE
194942008-07-28 Doug Kwan <dougkwan@google.com>
19495
19496 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19497 (linux_write_memory): Remove declaration of errno.
19498
836acd6d
UW
194992008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19500
19501 * linux-low.c (handle_extended_wait): Do not use "status"
19502 variable uninitialized.
19503
aeba519e
PA
195042008-07-07 Pedro Alves <pedro@codesourcery.com>
19505
19506 * server.c (handle_v_attach): Inhibit reporting dll changes.
19507
db42f210
PA
195082008-06-27 Pedro Alves <pedro@codesourcery.com>
19509
19510 * remote-utils.c (prepare_resume_reply): If requested, don't
19511 output "thread:TID" in the T stop reply.
19512
19513 * server.c (disable_packet_vCont, disable_packet_Tthread)
19514 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19515 (handle_query): If requested, disable support for qC, qfThreadInfo
19516 and qsThreadInfo.
19517 (handle_v_requests): If requested, disable support for vCont.
19518 (gdbserver_show_disableable): New.
19519 (main): Handle --disable-packet and --disable-packet=LIST.
19520
19521 * server.h (disable_packet_vCont, disable_packet_Tthread)
19522 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19523
8e4c5421
CD
195242008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19525
19526 * server.c (gdbserver_usage): Mention --version.
19527
6e23a804
DJ
195282008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19529
19530 * Makefile.in (gdbreplay.o): New rule.
19531
90aa6a40
JM
195322008-06-06 Joseph Myers <joseph@codesourcery.com>
19533
19534 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19535 message, not gdbserver.
19536
c16158bc 195372008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
19538 Nathan Sidwell <nathan@codesourcery.com>
19539 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
19540
19541 * acinclude.m4: Include ../../config/acx.m4.
19542 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19543 * configure, config.in: Regenerate.
19544 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19545 * server.c (gdbserver_version): Print PKGVERSION.
19546 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19547 (main): Adjust gdbserver_usage calls.
19548 * gdbreplay.c (version, host_name): Add declarations.
19549 (gdbreplay_version, gdbreplay_usage): New.
19550 (main): Accept --version and --help options.
19551
aeb75bf5
DJ
195522008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19553
19554 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19555 (arm_breakpoint_at): Handle Thumb.
19556 (the_low_target): Add comment.
19557
76b233dd
UW
195582008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19559
19560 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19561
08388c79
DE
195622008-05-09 Doug Evans <dje@google.com>
19563
a3c83fae
DE
19564 * server.h (decode_search_memory_packet): Declare.
19565 * remote-utils.c (decode_search_memory_packet): New fn.
19566 * server.c (handle_search_memory_1): New fn.
08388c79
DE
19567 (handle_search_memory): New fn.
19568 (handle_query): Process qSearch:memory packets.
19569
bb9c3d36
UW
195702008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19571
19572 * regcache.c (registers_length): Remove.
19573 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19574 full register packet.
19575 * regcache.h (registers_length): Remove prototype.
19576 * server.h (PBUFSIZ): Define to 16384.
19577
7284e1be
UW
195782008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19579
19580 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19581 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19582 powerpc-64l.o, and powerpc-altivec64l.o.
19583 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19584 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19585 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19586 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19587 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19588 to srv_xmlfiles.
19589
19590 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19591 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19592 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19593 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19594 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19595 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19596 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19597 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19598 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19599 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19600 (clean): Update.
19601
19602 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19603 (init_registers_powerpc_32l): ... this new prototype.
19604 (init_registers_powerpc_32): Remove, replace by ...
19605 (init_registers_powerpc_altivec32l): ... this new prototype.
19606 (init_registers_powerpc_e500): Remove, replace by ...
19607 (init_registers_powerpc_e500l): ... this new prototype.
19608 (init_registers_ppc64): Remove, replace by ...
19609 (init_registers_powerpc_64l): ... this new prototype.
19610 (init_registers_powerpc_64): Remove, replace by ...
19611 (init_registers_powerpc_altivec64l): ... this new prototype.
19612 (ppc_num_regs): Set to 73.
19613 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19614 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19615 (ppc_cannot_store_register): Handle orig_r3 and trap.
19616 (ppc_arch_setup): Update init_registers_... calls.
19617 (ppc_fill_gregset): Handle orig_r3 and trap.
19618
19619 * inferiors.c (clear_inferiors): Reset current_inferior.
19620
fdc59709
PB
196212008-04-23 Paolo Bonzini <bonzini@gnu.org>
19622
889bf7c5
PA
19623 * acinclude.m4: Add override.m4.
19624 * configure: Regenerate.
fdc59709 19625
c9b2f845
UW
196262008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19627
19628 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19629 initial call to init_register_ppc64.
19630
550512b8
UW
196312008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19632
43aaf8b6
PA
19633 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19634 single powerpc*-*-linux* case.
550512b8
UW
19635 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19636
b6430ec3
UW
196372008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19638
19639 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 19640 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
19641 from reg_xmlfiles.
19642 * linux-ppc-low.c: Include <elf.h>.
19643 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19644 (ppc_hwcap): New global variable.
19645 (ppc_regmap): Remove __SPE__ #ifdef sections.
19646 (ppc_regmap_e500): New global variable.
19647 (ppc_cannot_store_register): Update __SPE__ special case.
19648 (ppc_get_hwcap): New function.
19649 (ppc_arch_setup): Use it to determine whether inferior supports
19650 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19651 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19652 Do not access registers if target does not support AltiVec.
19653 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19654 Do not access registers if target does not support SPE.
19655 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19656
52fa2412
UW
196572008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19658
19659 * linux-low.c (disabled_regsets, num_regsets): New.
19660 (use_regsets_p): Delete.
19661 (linux_wait_for_process): Clear disabled_regsets.
19662 (regsets_fetch_inferior_registers): Check and set it.
19663 (regsets_store_inferior_registers): Likewise.
19664 (linux_fetch_registers, linux_store_registers): Do not use
19665 use_regsets_p.
19666 (initialize_low): Allocate disabled_regsets.
19667
e28b3332
DJ
196682008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19669
19670 * Makefile.in (LIBOBJS): New.
19671 (OBS): Use LIBOBJS.
19672 (memmem.o): New rule.
19673 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19674 * configure: Regenerated.
19675
4536995d
UW
196762008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19677
19678 * server.c (handle_query): Never return "unsupported" for
19679 qXfer:features:read queries.
19680
221c031f
UW
196812008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19682
19683 * server.c (get_features_xml): Fix inverted condition.
19684 (handle_query): Always support qXfer:feature:read.
19685
ccd213ac
DJ
196862008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19687
19688 * server.c (wrapper_argv): New.
19689 (start_inferior): Handle wrapper_argv. If set, expect an extra
19690 trap.
19691 (gdbserver_usage): Document --wrapper.
19692 (main): Parse --wrapper.
19693
6fe305f7
UW
196942008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19695
19696 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19697 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19698 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19699 (ppc_set_pc): Likewise.
19700 (ppc_arch_setup): New function.
19701 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19702 of collect_register.
889bf7c5 19703 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 19704
5b0a002e
UW
197052008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19706
19707 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19708 instead of linux-ppc64-low.o.
19709 * linux-ppc64-low.c: Remove file.
19710 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19711 (linux-ppc64-low.o): Remove rule.
19712
19713 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19714 (init_registers_powerpc_64): Likewise.
19715 (ppc_regmap): Conditionally define depending on __powerpc64__.
19716 (ppc_cannot_store_register): Do not special-case "fpscr" when
19717 compiled on __powerpc64__.
19718 (ppc_collect_ptrace_register): New function.
19719 (ppc_supply_ptrace_register): New function.
19720 (ppc_breakpoint): Change type to "unsigned int".
19721 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19722 (the_low_target): Conditionally provide initializers for the
889bf7c5 19723 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
19724 collect_ptrace_register and supply_ptrace_register members.
19725
9b4b61c8
UW
197262008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19727
19728 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19729 * server.c (gdbserver_xmltarget): Define.
19730 (get_features_xml): Use it to replace "target.xml" and arch_string.
19731
19732 * configure.srv: Remove srv_xmltarget. Add XML files that were
19733 mentioned there to srv_xmlfiles instead. Remove conditional tests
19734 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19735 srv_xmlfiles and srv_regobj to include all possible choices.
19736 * configure.ac (srv_xmltarget): Remove.
19737 (srv_xmlfiles): Do not add "target.xml".
19738 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19739 checks for supplementary target information.
19740 * configure: Regenerate.
19741 * Makefile.in (XML_TARGET): Remove.
19742 (target.xml): Remove rule.
19743 (clean): Do not clean up target.xml.
19744 (.PRECIOUS): Do not mention target.xml.
19745
19746 * target.h (struct target_ops): Remove arch_string member.
19747 * linux-low.c (linux_arch_string): Remove.
19748 (linux_target_ops): Remove arch_string initializer.
19749 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19750 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19751 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19752 * spu-low.c (spu_arch_string): Remove.
19753 (spu_target_ops): Remove arch_string initializer.
19754 * win32-low.c (win32_arch_string): Remove.
19755 (win32_target_ops): Remove arch_string initializer.
19756 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19757 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19758 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19759
ee1a7ae4
UW
197602008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19761
19762 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19763 by collect_ptrace_register and supply_ptrace_register hooks.
19764 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19765 instead of checking for the_low_target.left_pad_xfer.
19766 (usr_store_inferior_registers): Use collect_ptrace_register callback
19767 instead of checking for the_low_target.left_pad_xfer.
19768
19769 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19770 (s390_supply_ptrace_register): Likewise.
19771 (s390_fill_gregset): Call s390_collect_ptrace_register.
19772 (the_low_target): Update.
19773
19774 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19775 (ppc_supply_ptrace_register): Likewise.
19776 (the_low_target): Update.
19777
19778 * linux-i386-low.c (the_low_target): Update.
19779 * linux-x86-64-low.c (the_low_target): Update.
19780
d61ddec4
UW
197812008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19782
19783 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19784 reg-s390.o and reg-s390x.o.
19785
19786 * linux-low.c (new_inferior): New global variable.
19787 (linux_create_inferior, linux_attach): Set it.
19788 (linux_wait_for_process): Call the_low_target.arch_setup after the
19789 target has stopped for the first time.
19790 (initialize_low): Do not call the_low_target.arch_setup.
19791
19792 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19793 (s390_set_pc): Likewise.
19794 (s390_arch_setup): New function.
19795 (the_low_target): Use s390_arch_setup as arch_setup routine.
19796
19797 * regcache.c (realloc_register_cache): New function.
19798 (set_register_cache): Call it for each existing regcache.
19799
d05b4ac3
UW
198002008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19801
19802 * server.h (init_registers): Remove prototype.
19803
19804 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19805 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19806 instead of init_registers ().
19807 * linux-arm-low.c (init_registers_arm): Add prototype.
19808 (init_registers_arm_with_iwmmxt): Likewise.
19809 (the_low_target): Add initializer for arch_setup field.
19810 * linux-cris-low.c (init_registers_cris): Add prototype.
19811 (the_low_target): Add initializer for arch_setup field.
19812 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19813 (the_low_target): Add initializer for arch_setup field.
19814 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19815 (the_low_target): Add initializer for arch_setup field.
19816 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19817 (the_low_target): Add initializer for arch_setup field.
19818 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19819 (the_low_target): Add initializer for arch_setup field.
19820 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19821 (the_low_target): Add initializer for arch_setup field.
19822 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19823 (init_registers_mips64_linux): Likewise.
19824 (the_low_target): Add initializer for arch_setup field.
19825 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19826 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19827 (the_low_target): Add initializer for arch_setup field.
19828 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19829 (init_registers_powerpc_64): Likewise.
19830 (the_low_target): Add initializer for arch_setup field.
19831 * linux-s390-low.c (init_registers_s390): Add prototype.
19832 (init_registers_s390x): Likewise.
19833 (the_low_target): Add initializer for arch_setup field.
19834 * linux-sh-low.c (init_registers_sh): Add prototype.
19835 (the_low_target): Add initializer for arch_setup field.
19836 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19837 (the_low_target): Add initializer for arch_setup field.
19838 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19839 (the_low_target): Add initializer for arch_setup field.
19840
19841 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19842 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19843 instead of init_registers ().
19844 * win32-arm-low.c (init_registers_arm): Add prototype.
19845 (the_low_target): Add initializer for arch_setup field.
19846 * win32-i386-low.c (init_registers_i386): Add prototype.
19847 (the_low_target): Add initializer for arch_setup field.
19848
19849 * spu-low.c (init_registers_spu): Add prototype.
19850 (initialize_low): Call initialie_registers_spu () instead of
19851 initialize_registers ().
19852
fd96d250
PA
198532008-02-19 Pedro Alves <pedro@codesourcery.com>
19854
19855 * server.c (handle_v_requests): When handling the vRun and vAttach
19856 packets, if already debugging a process, don't kill it. Return an
19857 error instead.
19858
d41b6bb4
DJ
198592008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19860
19861 * server.c (handle_query): Correct length check.
19862
5ac588cf
PA
198632008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19864
19865 * win32-low.c (do_initial_child_stuff): Add process handle
19866 parameter. Set current_process_handle and current_process_id from the
19867 parameters. Clear globals.
19868 (win32_create_inferior): Don't set current_process_handle and
19869 current_process_id here. Instead pass them on the call to
19870 do_initial_child_stuff.
19871 (win32_attach): Likewise.
19872 (win32_clear_inferiors): New.
19873 (win32_kill): Don't close the current process handle or the
19874 current thread handle here. Instead call win32_clear_inferiors.
19875 (win32_detach): Don't open a new handle to the process. Call
19876 win32_clear_inferiors.
19877 (win32_join): Don't rely on current_process_handle; open a new
19878 handle using the process id.
19879 (win32_wait): Call win32_clear_inferiors when the inferior process
19880 has exited.
19881
ecd7ecbc
DJ
198822008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19883
19884 * server.c (monitor_show_help): Add "exit".
19885
1525d545
MG
198862008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19887
ecd7ecbc 19888 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
19889 (clean): Add reg-xtensa.c.
19890 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
19891 * configure.srv (xtensa*-*-linux*) New target.
19892 * linux-xtensa-low.c: New.
19893 * xtensa-xtregs.c: New.
1525d545 19894
59a016f0
PA
198952008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19896
19897 * hostio.c: Don't include errno.h.
19898 (errno_to_fileio_errno): Move to hostio-errno.
19899 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19900 error number outputting to the target->hostio_last_error callback.
19901 (hostio_packet_error): Use FILEIO_EINVAL directly.
19902 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19903 calls to hostio_error.
19904 * hostio-errno.c: New.
19905 * server.h (hostio_last_error_from_errno): Declare.
19906 * target.h (target_ops): Add hostio_last_error member.
19907 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19908 as hostio_last_error handler.
889bf7c5 19909 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
19910 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19911 (wince_hostio_last_error): New functions.
19912 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19913 as hostio_last_error handler.
19914 (win32_target_ops) [!_WIN32_WCE]: Register
19915 hostio_last_error_from_errno as hostio_last_error handler.
19916 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19917 (hostio-errno.o): New rule.
19918 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19919 * configure.srv (srv_hostio_err_objs): New variable. Default to
19920 hostio-errno.o.
19921 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19922 * configure: Regenerate.
19923
2d717e4f
DJ
199242008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19925
19926 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
19927 (linux_kill, linux_detach): Clean up the process list.
19928 * remote-utils.c (remote_open): Improve port number parsing.
19929 (putpkt_binary, input_interrupt): Only send interrupts if the target
19930 is running.
19931 * server.c (extended_protocol): Make static.
19932 (attached): Define earlier.
19933 (exit_requested, response_needed, program_argv): New variables.
19934 (target_running): New.
19935 (start_inferior): Clear attached here.
19936 (attach_inferior): Set attached here.
19937 (require_running): Define.
19938 (handle_query): Use require_running and target_running. Implement
19939 "monitor exit".
19940 (handle_v_attach, handle_v_run): New.
19941 (handle_v_requests): Use require_running. Handle vAttach and vRun.
19942 (gdbserver_usage): Update.
19943 (main): Redo argument parsing. Handle --debug and --multi. Handle
19944 --attach along with other options or after the port. Save
19945 program_argv. Support no initial program. Resynchronize
19946 communication with GDB after an error. Handle "monitor exit".
19947 Use require_running and target_running. Always allow the extended
19948 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
19949 restart in extended mode.
19950 * README: Refer to the GDB manual. Update --attach usage.
19951
7407e2de
AS
199522007-12-20 Andreas Schwab <schwab@suse.de>
19953
19954 * linux-low.c (STACK_SIZE): Define.
19955 (linux_tracefork_child): Use it. Use __clone2 on ia64.
19956 (linux_test_for_tracefork): Likewise.
19957
b65d95c5
DJ
199582007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
19959
19960 * linux-low.c (linux_wait_for_event): Update messages. Do not
19961 reinsert auto-delete breakpoints.
19962 * mem-break.c (struct breakpoint): Change return type of handler to
19963 int.
19964 (set_breakpoint_at): Update handler type.
19965 (reinsert_breakpoint_handler): Return 1 instead of calling
19966 delete_breakpoint.
19967 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
19968 setting a new one.
19969 (check_breakpoints): Delete auto-delete breakpoints and return 2.
19970 * mem-break.h (set_breakpoint_at): Update handler type.
19971 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
19972 * win32-low.c (auto_delete_breakpoint): New.
19973 (get_child_debug_event): Use it.
19974
4e799345
DJ
199752007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
19976
19977 * configure.ac: Check for pread and pwrite.
19978 * hostio.c (handle_pread): Fall back to lseek and read.
19979 (handle_pwrite): Fall back to lseek and write.
19980 * config.in, configure: Regenerated.
19981
27524b67
DJ
199822007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
19983
19984 * server.c (myresume): Add own_buf argument.
19985 (main): Update calls.
19986
a20d5e98
DJ
199872007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
19988
19989 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
19990 * remote-utils.c (remote_open): Do not call disable_async_io.
19991 (block_async_io): Delete.
19992 (unblock_async_io): Make static.
19993 (initialize_async_io): New.
19994 * server.c (handle_v_cont): Handle async I/O here.
19995 (myresume): Likewise. Move other common resume tasks here...
19996 (main): ... from here. Call initialize_async_io. Disable async
19997 I/O before the main loop.
19998 * server.h (initialize_async_io): Declare.
19999 (block_async_io, unblock_async_io): Delete prototypes.
20000 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20001
b79d787e
DJ
200022007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20003
20004 * remote-utils.c (readchar): Allow binary data in received messages.
20005
d97903b2
PA
200062007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20007
20008 * win32-low.c (attaching): New global.
20009 (win32_create_inferior): Clear the `attaching' global.
20010 (win32_attach): Set the `attaching' global.
20011 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20012 attaching. Only set a breakpoint at the entry point if not
20013 attaching.
20014
311de423
PA
200152007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20016
20017 * server.c (main): Don't report dll events on the initial
20018 connection on attaches.
20019
6c2d16d2
PA
200202007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20021
20022 * server.c (main): Relax numerical bases supported for the pid of
20023 the --attach command line argument.
20024
5ca906e6
PA
200252007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20026
20027 * win32-low.c (win32_attach): Call OpenProcess before
20028 DebugActiveProcess, not after. Add last error output to error
20029 call.
20030
9c6c8194
PA
200312007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20032
20033 * win32-low.c (win32_get_thread_context)
20034 (win32_set_thread_context): New functions.
20035 (thread_rec): Use win32_get_thread_context.
20036 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20037 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20038 field.
20039
4d5d1aaa
PA
200402007-12-03 Leo Zayas
20041 Pedro Alves <pedro_alves@portugalmail.pt>
20042
20043 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20044 global variables.
20045 (child_add_thread): Minor cleanup.
20046 (child_continue): Resume artificially suspended threads before
20047 calling ContinueDebugEvent.
20048 (suspend_one_thread): New.
20049 (fake_breakpoint_event): New.
20050 (get_child_debug_event): Change return type to int. Check here if
20051 gdb sent an interrupt request. If a soft interrupt was requested,
20052 fake a breakpoint event. Return 0 if there is no event to handle,
20053 and 1 otherwise.
20054 (win32_wait): Don't check here if gdb sent an interrupt request.
20055 Ensure there is a valid event to handle.
20056 (win32_request_interrupt): Add soft interruption method as last
20057 resort.
20058
c436e841
PA
200592007-12-03 Leo Zayas
20060 Pedro Alves <pedro_alves@portugalmail.pt>
20061
20062 * win32-low.h (win32_thread_info): Add descriptions to the
20063 structure members. Replace `suspend_count' counter by a
20064 `suspended' flag.
20065 * win32-low.c (thread_rec): Update condition of when to get the
20066 context from the inferior. Rely on ContextFlags being set if it
20067 has already been retrieved. Only suspend the inferior thread if
20068 we haven't already. Warn if that fails.
20069 (continue_one_thread): s/suspend_count/suspended/. Only call
20070 ResumeThread once. Warn if that fails.
20071
e7b5fa67
PA
200722007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20073
20074 * win32-low.c (win32_wait): Don't read from the inferior when it
20075 has already exited.
20076
a385171d
PA
200772007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20078
20079 * Makefile.in (win32_low_h): New variable.
20080 (win32-low.o): Add dependency on $(win32_low_h).
20081 (win32-arm-low.o, win32-i386-low.o): New rules.
20082
f80c84b3
DJ
200832007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20084
20085 * hostio.c: Correct copyright year.
20086
a6b151f1
DJ
200872007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20088
20089 * Makefile.in (OBS): Add hostio.o.
20090 (hostio.o): New rule.
20091 * server.h (handle_vFile): Declare.
20092 * hostio.c: New file.
20093 * server.c (handle_v_requests): Take packet_len and new_packet_len
20094 for binary packets. Call handle_vFile.
20095 (main): Update call to handle_v_requests.
20096
f9387fc3
DJ
200972007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20098
20099 * linux-low.c: Include <sched.h>.
20100
51c2684e
DJ
201012007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20102
20103 * linux-low.c (linux_tracefork_grandchild): New.
20104 (linux_tracefork_child): Use clone.
20105 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20106
75f83163
JB
201072007-10-31 Joel Brobecker <brobecker@adacore.com>
20108
20109 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20110
da5898ce
DJ
201112007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20112
20113 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20114
24a09b5f
DJ
201152007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20116
20117 * inferiors.c (change_inferior_id): Delete.
20118 (add_pid_to_list, pull_pid_from_list): New.
20119 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20120 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20121 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20122 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20123 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20124 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20125 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20126 (using_threads): Always set to 1.
20127 (handle_extended_wait): New.
20128 (add_process): Do not set TID.
20129 (linux_create_inferior): Set must_set_ptrace_flags.
20130 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20131 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20132 (linux_thread_alive): Rename TID argument to LWPID.
20133 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20134 (linux_wait_for_event): Do not use TID or check using_threads. Update
20135 call to dead_thread_notify. Call handle_extended_wait.
20136 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20137 (send_sigstop): Delete sigstop_sent.
20138 (wait_for_sigstop): Avoid TID.
20139 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20140 (linux_test_for_tracefork): New.
20141 (linux_lookup_signals): Use thread_db_active and
20142 linux_supports_tracefork_flag.
20143 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20144 * linux-low.h (get_process_thread): Avoid TID.
20145 (struct process_ifo): Move thread_known and tid to the end. Remove
20146 sigstop_sent.
20147 (linux_attach_lwp, thread_db_init): Update prototypes.
20148 * server.h (change_inferior_id): Delete prototype.
20149 (add_pid_to_list, pull_pid_from_list): New prototypes.
20150 * thread-db.c (thread_db_use_events): New.
20151 (find_first_thread): Rename to...
20152 (find_one_thread): ...this. Update callers and messages. Do not
20153 call fatal. Check thread_db_use_events. Do not call
20154 change_inferior_id or new_thread_notify.
20155 (maybe_attach_thread): Update. Do not call new_thread_notify.
20156 (thread_db_init): Set thread_db_use_events. Check use_events.
20157 * utils.c (fatal, warning): Correct message prefix.
20158
30ed0a8f
DJ
201592007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20160
20161 * Makefile.in (clean): Remove new files.
20162 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20163 (powerpc-64.o, powerpc-64.c): New rules.
20164 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20165 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20166 with SPE.
20167 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20168 SPE targets.
20169 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20170 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20171 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20172 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20173 (target_regsets): Add AltiVec and SPE register sets.
20174 * configure.ac: Check for AltiVec and SPE.
20175 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20176 (ppc_fill_vrregset, ppc_store_vrregset): New.
20177 (target_regsets): Add AltiVec register set.
20178 * configure: Regenerated.
20179
fd462a61
DJ
201802007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20181
20182 * linux-low.c (O_LARGEFILE): Define.
20183 (linux_read_memory): Use /proc/PID/mem.
20184 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20185 * configure, config.in: Regenerated.
20186
69f223ed
DJ
201872007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20188
20189 * linux-low.c (linux_wait_for_event): Do not pass signals while
20190 single-stepping.
20191
aec18585
PA
201922007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20193
20194 * win32-low.c (create_process): New.
20195 (win32_create_inferior): Use create_process instead of
20196 CreateProcess. If create_process failed retry appending an ".exe"
20197 suffix. Store the GetLastError result immediatelly after
20198 create_process calls and use it on the call to error.
20199
34d86ddd
PA
202002007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20201
20202 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20203
5a0e3bd0
JB
202042007-08-23 Joel Brobecker <brobecker@adacore.com>
20205
20206 * configure.ac: Switch license to GPLv3.
20207
f88c79e6
MS
202082007-08-01 Michael Snyder <msnyder@access-company.com>
20209
20210 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20211
6b3d9b83
PA
202122007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20213
20214 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20215 typedef.
20216 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20217 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20218 CloseToolhelp32Snapshot.
20219 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20220 CloseToolhelp32Snapshot.
20221
c588c53c
MS
202222007-07-27 Michael Snyder <michael.snyder@access-company.com>
20223
20224 * server.c (main): Check for inferior exit before main loop.
20225
aa0403d9
PA
202262007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20227
20228 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20229 instead of on tmp_desc.
20230
255e7678
DJ
202312007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20232 Daniel Jacobowitz <dan@codesourcery.com>
20233
20234 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20235 (add_thread): Minor cleanups.
20236 (clear_inferiors): Move lower in the file. Clear the DLL
20237 list.
20238 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20239 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20240 (xml_escape_text): New.
20241 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20242 for qSupported.
20243 (handle_v_cont): Report errors.
20244 (gdbserver_version): Update.
20245 (main): Correct size of own_buf. Do not report initial DLL events.
20246 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20247 (unloaded_dll, xml_escape_text): New.
20248 * win32-low.c (enum target_waitkind): Update comments.
20249 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20250 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20251 (win32_EnumProcessModules, win32_GetModuleInformation)
20252 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20253 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20254 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20255 (win32_Module32First, win32_Module32Next, load_toolhelp)
20256 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20257 (get_child_debug_event): Handle DLL events.
20258 (win32_wait): Likewise.
20259
0d37add9
DJ
202602007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20261
20262 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20263 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20264
45e2715e
PA
202652007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20266
20267 * win32-low.c (handle_output_debug_string): Ignore event if not
20268 waiting.
20269
c5674cf1
PA
202702007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20271
20272 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20273
2bbe3cc1
DJ
202742007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20275
20276 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20277
ae13219e
DJ
202782007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20279
20280 * inferiors.c (change_inferior_id): Add comment.
20281 * linux-low.c (check_removed_breakpoint): Add an early
20282 prototype. Improve debug output.
20283 (linux_attach): Doc update.
20284 (linux_detach_one_process, linux_detach): Clean up before releasing
20285 each process.
20286 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20287 * linux-low.h (struct process_info): Doc improvement.
20288 * mem-break.c (delete_all_breakpoints): New.
20289 * mem-break.h (delete_all_breakpoints): New prototype.
20290 * thread-db.c (find_first_thread): New.
20291 (thread_db_create_event): Call it instead of
20292 thread_db_find_new_threads. Clean up unused variables.
20293 (maybe_attach_thread): Remove first thread handling.
20294 (thread_db_find_new_threads): Use find_first_thread.
20295 (thread_db_get_tls_address): Likewise.
20296
4105de34
DJ
202972007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20298
20299 * thread-db.c (thread_db_find_new_threads): Add prototype.
20300 (thread_db_create_event): Check for the main thread before adding
20301 a new thread.
20302 (maybe_attach_thread): Only enable event reporting if TID == 0.
20303 (thread_db_get_tls_address): Check for new threads.
20304
2b876972
DJ
203052007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20306
20307 * linux-low.c (linux_create_inferior): Try execv before execvp.
20308 * spu-low.c (spu_create_inferior): Likewise.
20309
7a245884
DJ
203102007-06-13 Mike Frysinger <vapier@gentoo.org>
20311
20312 * linux-low.c (linux_create_inferior): Change execv to execvp.
20313 * spu-low.c (spu_create_inferior): Likewies.
20314
117ce543
DJ
203152007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20316
20317 * Makefile.in (clean): Clean new files instead of deleted ones.
20318 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20319 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20320 rules.
20321 * configure.srv: Specify XML files and new regformats for MIPS and
20322 MIPS64 GNU/Linux.
20323 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20324 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20325 an entry for the restart register.
20326 (mips_cannot_fetch_register, mips_cannot_store_register)
20327 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20328 register names to match the XML descriptions.
20329 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20330 restart register instead of $0.
20331
0e7f50da
UW
203322007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20333 Markus Deuling <deuling@de.ibm.com>
20334
20335 * remote-utils.c (decode_xfer_write): New function.
20336 * server.h (decode_xfer_write): Add prototype.
20337 * server.c (handle_query): Add PACKET_LEN argument. Support
20338 qXfer:spu:read and qXfer:spu:write packets.
20339 (main): Pass packet_len to handle_query.
20340 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20341 * target.h (target_ops): Add qxfer_spu.
20342
374c1d38
UW
203432007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20344
20345 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20346 accessing non-seekable spufs files.
20347
bb63802a
UW
203482007-05-16 Markus Deuling <deuling@de.ibm.com>
20349
889bf7c5 20350 * server.c (handle_query): Add reply for qC packet.
bb63802a 20351
7390519e
PA
203522007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20353 Leo Zayas <lerele@champenstudios@com>
20354
20355 * server.h (check_remote_input_interrupt_request): New function.
20356 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20357 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20358 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20359 (check_remote_input_interrupt_request): New function.
20360 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 20361 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
20362 winapi_GenerateConsoleCtrlEvent): New typedefs.
20363 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20364 to 250 ms.
20365 (win32_wait): Check for remote interrupt request
20366 with check_remote_input_interrupt_request.
20367 (win32_request_interrupt): New function.
20368 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20369
34b34921
PA
203702007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20371
20372 * win32-low.c (debug_registers_changed,
20373 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20374 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20375 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20376 (thread_rec): Get context using the low target.
20377 (child_add_thread): Call thread_added on the low target,
20378 which does the same thing.
20379 (regptr): Delete.
20380 (do_initial_child_stuff): Remove debug registers references.
20381 Set context using the low target. Resume threads after
20382 setting the contexts.
20383 (child_continue): Remove dead variable. Remove debug
20384 registers references.
20385 (child_fetch_inferior_registers): Go through the low target.
20386 (do_child_store_inferior_registers): Remove.
20387 (child_store_inferior_registers): Go through the low target.
20388 (win32_resume): Remove debug registers references.
20389 Set context using the low target.
20390 (handle_exception): Change return type to void. Don't record
20391 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20392 first chance exception.
889bf7c5 20393 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
20394 goto loop. Always return after waiting for debug event.
20395 (win32_wait): Convert to switch statement. Handle spurious
20396 events.
20397
20398 * win32-i386-low.c (debug_registers_changed,
20399 debug_registers_used): New.
20400 (initial_stuff): Rename to ...
20401 (i386_initial_stuff): ... this. Clear debug registers
20402 state variables.
20403 (store_debug_registers): Delete.
20404 (i386_get_thread_context): New.
20405 (load_debug_registers): Delete.
20406 (i386_set_thread_context): New.
20407 (i386_thread_added): New.
20408 (single_step): Rename to ...
20409 (i386_single_step): ... this.
20410 (do_fetch_inferior_registers): Rename to ...
20411 (i386_fetch_inferior_register): ... this.
20412 (i386_store_inferior_register): New.
20413 (the_low_target): Adapt to new interface.
20414
20415 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20416 (arm_get_thread_context): New.
20417 (arm_set_thread_context): New.
20418 (regptr): New.
20419 (do_fetch_inferior_registers): Rename to ...
20420 (arm_fetch_inferior_register): ... this.
20421 (arm_store_inferior_register): New.
20422 (arm_wince_breakpoint): Reimplement as unsigned long.
20423 (arm_wince_breakpoint_len): Define.
20424 (the_low_target): Adapt to new interface.
20425
20426 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20427 load_debug_registers. Add get_thread_context, set_thread_context,
20428 thread_added and store_inferior_register. Rename
20429 fetch_inferior_registers to fetch_inferior_register.
20430 (regptr): Remove declaration.
20431
dd6953e1
PA
204322007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20433
20434 * linux-low.c (linux_detach): Change return type to int. Return 0.
20435 * spu-low.c (spu_detach): Likewise.
20436
444d6139
PA
204372007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20438
20439 * target.h (target_ops): Change return type of detach to int.
20440 Add join.
20441 (join_inferior): New.
20442 * server.c (main): Don't skip detach support on mingw32.
20443 If the inferior doesn't support detaching return error.
20444 Call join_inferior instead of using waitpid.
20445 * linux-low.c (linux_join): New.
20446 (linux_target_op): Add linux_join.
20447 * spu-low.c (spu_join): New.
20448 (spu_target_ops): Add spu_join.
20449 * win32-low.c (win32_detach): Adapt to new interface.
20450 Reopen current_process_handle before detaching. Issue a child
20451 resume before detaching.
20452 (win32_join): New.
20453 (win32_target_op): Add win32_join.
20454
1d5315fe
PA
204552007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20456
20457 * win32-low.c (win32-attach): Fix return value.
20458 * target.h (target_ops): Describe ATTACH return values.
20459
bf914831
PA
204602007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20461
20462 * win32-low.c (GETPROCADDRESS): Define.
20463 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20464 (winapi_DebugSetProcessKillOnExit): Likewise.
20465 (win32_create_inferior): Force usage of ansi CreateProcessA.
20466 (win32_attach): Use GETPROCADDRESS.
20467 (win32_detach): Likewise.
20468
f72f3e60
PA
204692007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20470
20471 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20472
ed50f18f
PA
204732007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20474
20475 * win32-low.c: Commit leftover changes from 2007-03-29.
20476
0c2ead7e
DJ
204772007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20478
20479 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20480 fields short instead of int. Add explicit padding.
20481 (i387_cache_to_fsave): Remove unnecessary casts.
20482 (i387_fsave_to_cache): Doc fix.
20483 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20484
73725ff3
DJ
204852007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20486
20487 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20488 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20489
d99f33d8
PA
204902007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20491
20492 * configure.srv (arm*-*-mingw32ce*): Move near the other
20493 arm targets.
20494
68070c10
PA
204952007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20496
2482afc6 20497 * configure.ac: Add errno checking.
68070c10
PA
20498 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20499 sys/file.h and malloc.h.
20500 (AC_CHECK_DECLS): Add perror.
20501 (srv_mingwce): Handle.
2482afc6 20502 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
20503 win32-i386-low.o to srv_tgtobj.
20504 (i[34567]86-*-mingw*): Likewise.
20505 (arm*-*-mingw32ce*): Add case.
20506 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20507 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20508 [__MINGW32CE__] (strerror): New function.
20509 [__MINGW32CE__] (errno): Define to GetLastError.
20510 [__MINGW32CE__] (COUNTOF): New macro.
20511 (remote_open): Remove extra close call.
20512 * mem-break.c (delete_breakpoint_at): New function.
20513 * mem-break.h (delete_breakpoint_at): Declare.
20514 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20515 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20516 [USE_WIN32API] (read, write): Add char* casts.
20517 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20518 * server.h: Include wincecompat.h on Windows CE.
20519 [HAVE_ERRNO_H]: Check.
20520 (perror): Declare if not declared.
20521 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20522 (perror_with_name): Remove errno declaration.
20523 * wincecompat.h: New.
20524 * wincecompat.c: New.
20525 * win32-low.h: New.
20526 * win32-arm-low.c: New.
20527 * win32-i386-low.c: New.
20528 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20529 (OUTMSG2): Make it safe.
20530 (_T): New macro.
20531 (COUNTOF): New macro.
20532 (NUM_REGS): Get it from the low target.
20533 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20534 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20535 (thread_rec): Let low target handle debug registers.
20536 (child_add_thread): Likewise.
20537 (child_init_thread_list): Likewise.
20538 (continue_one_thread): Likewise.
20539 (regptr): New.
20540 (do_child_fetch_inferior_registers): Move to ...
20541 * win32-i386-low.c: ... here, and rename to ...
20542 (do_fetch_inferior_registers): ... this.
889bf7c5 20543 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
20544 Go through the low target.
20545 (do_child_store_inferior_registers): Use regptr.
20546 (strwinerror): New function.
20547 (win32_create_inferior): Handle Windows CE.
20548 Use strwinerror instead of strerror on Windows error
20549 codes. Add program to the error output.
20550 Don't close the main thread handle on Windows CE.
20551 (win32_attach): Use coredll.dll on Windows CE.
20552 (win32_kill): Close current process and current
20553 thread handles.
20554 (win32_detach): Use coredll.dll on Windows CE.
20555 (win32_resume): Let low target handle debug registers, and
20556 step request.
20557 (handle_exception): Add/Remove initial breakpoint. Avoid
20558 non-existant WSTOPSIG on Windows CE.
20559 (win32_read_inferior_memory): Cast to remove warning.
20560 (win32_arch_string): Go through the low target.
20561 (initialize_low): Call set_breakpoint_data with the low
20562 target's breakpoint.
20563 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20564 FOP_REGNUM, mappings): Move to ...
20565 * win32-i386-low.c: ... here.
20566 * win32-low.c (win32_thread_info): Move to ...
20567 * win32-low.h: ... here.
20568 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20569 win32-arm-low.c and wincecompat.c.
20570 (all:): Add $EXEEXT.
20571 (install-only:): Likewise.
20572 (gdbserver:): Likewise.
20573 (gdbreplay:): Likewise.
20574 * config.in: Regenerate.
20575 * configure: Regenerate.
20576
41093d81
PA
205772007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20578
20579 * win32-low.c: Rename typedef thread_info to
20580 win32_thread_info throughout.
20581
544afa54
PA
205822007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20583
20584 * win32-i386-low.c: Rename to ...
20585 * win32-low.c: ... this.
20586 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20587 * Makefile.in: Likewise.
20588
bce7165d
PA
205892007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20590
20591 * remote-utils.c (monitor_output): Constify msg parameter.
20592 * server.h (monitor_output): Likewise.
20593 * win32-i386-low.c (handle_output_debug_string): New.
20594 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20595 handle_output_debug_string.
20596 (get_child_debug_event): Likewise.
20597
506c7aa0
DJ
205982007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20599
20600 * server.c (main): Correct strtoul check.
20601
42c81e2a
DJ
206022007-03-27 Jon Ringle <jon@ringle.org>
20603
20604 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20605
9453113a
DJ
206062007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20607
20608 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20609
64a69107
DJ
206102007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20611
20612 * terminal.h: Check HAVE_SGTTY_H.
20613
206142007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
20615
20616 * remote-utils.c (remote_open): Print out the assigned port number.
20617
c74d0ad8
DJ
206182007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20619
20620 * remote-utils.c (monitor_output): New function.
20621 * server.c (debug_threads): Define here.
20622 (monitor_show_help): New function.
20623 (handle_query): Handle qRcmd.
20624 (main): Do not handle 'd' packet.
20625 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20626 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20627 of debug_threads.
20628
de7c3b4a
PA
206292007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20630
20631 * Makefile.in (EXEEXT): New.
20632 (clean): Use $(EXEEXT).
20633
ef57601b
PA
206342007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20635
20636 * target.h (target_ops): Rename send_signal to request_interrupt,
20637 and remove enum target_signal parameter.
20638 * linux-low.c (linux_request_interrupt): Rename from
20639 linux_send_signal, and always send SIGINT.
20640 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20641 and always send SIGINT.
20642 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20643 of send_signal.
20644 (input_interrupt): Likewise.
20645
820f2bda
PA
206462007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20647
20648 * server.c (get_features_xml): Check if target implemented
20649 arch_string.
20650 * win32-i386-low.c (win32_arch_string): New.
20651 (win32_target_ops): Add win32_arch_string as arch_string member.
20652
ab39bf24
UW
206532007-02-22 Markus Deuling <deuling@de.ibm.com>
20654
20655 * spu-low.c (spu_arch_string): New.
20656 (spu_target_ops): Add spu_arch_string.
20657
61ff6e04
DJ
206582007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20659
20660 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20661 * configure.ac: Do not check for terminal.h.
20662 * configure, config.in: Regenerated.
20663
fb1e4ffc
DJ
206642007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20665
20666 * Makefile.in (OBS): Add $(XML_BUILTIN).
20667 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20668 (clean): Update.
20669 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20670 (arm-with-iwmmxt.c): New.
20671 * config.in, configure: Regenerate.
20672 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20673 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20674 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20675 (arm*-*-linux*): Add iWMMXt and regset support.
20676 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20677 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20678 (arm_store_wmmxregset, target_regsets): New.
20679 * server.c (get_features_xml): Take annex argument. Check builtin
20680 XML documents.
20681 (handle_query): Handle multiple annexes.
20682
0f48aa01
DJ
206832007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20684
20685 * remote-utils.c [USE_WIN32API] (read, write): Define.
20686 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20687 write.
20688
23181151
DJ
206892007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20690
20691 * linux-i386-low.c (the_low_target): Set arch_string.
20692 * linux-x86-64-low.c (the_low_target): Likewise.
20693 * linux-low.c (linux_arch_string): New.
20694 (linux_target_ops): Add it.
20695 * linux-low.h (struct linux_target_ops): Add arch_string.
20696 * server.c (write_qxfer_response): Use const void * for DATA.
20697 (get_features_xml): New.
20698 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20699 * target.h (struct target_ops): Add arch_string method.
20700
9d606399
DJ
207012007-01-03 Denis Pilat <denis.pilat@st.com>
20702 Daniel Jacobowitz <dan@codesourcery.com>
20703
20704 * linux-low.c (linux_kill): Handle being called with no threads.
20705 * win32-i386-low.c (win32_kill): Likewise.
20706 (get_child_debug_event): Clear current_process_handle.
20707
207082006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
20709 Daniel Jacobowitz <dan@codesourcery.com>
20710
20711 * remote-utils.c (remote_open): Check the type of specified
20712 serial port devices before opening them.
20713 * server.c (main): Kill the inferior if an error occurs during
20714 the first remote_open.
20715
a5e13d24
DJ
207162006-12-05 Markus Deuling <deuling@de.ibm.com>
20717
20718 * README: Update supported targets.
20719
186947f7
DJ
207202006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20721
20722 * Makefile.in (clean): Remove reg-mips64.c.
20723 (reg-mips64.c, reg-mips64.o): New rules.
20724 * configure.srv: Handle mips64. Include regset support for mips.
20725 * linux-mips-low.c (union mips_register): New.
20726 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20727 (mips_breakpoint, mips_breakpoint_at): Use int.
20728 (mips_collect_register, mips_supply_register)
20729 (mips_collect_register_32bit, mips_supply_register_32bit)
20730 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20731 (mips_store_fpregset, target_regsets): New.
20732 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20733
a13e2c95
UW
207342006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20735
20736 * configure.srv: Add target "spu*-*-*".
20737 * Makefile.in (clean): Remove reg-spu.c.
20738 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20739 * spu-low.c: New file.
20740
cb7283db
DJ
207412006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20742
20743 * configure.ac: Correct td_thr_tls_get_addr test.
20744 * configure: Regenerated.
20745
89be2091
DJ
207462006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20747
20748 * linux-low.c (linux_wait_for_event): Reformat. Use the
20749 pass_signals array.
20750 * remote-utils.c (decode_address_to_semicolon): New.
20751 * server.c (pass_signals, handle_general_set): New.
20752 (handle_query): Mention QPassSignals for qSupported.
20753 (main): Call handle_general_set.
20754 * server.h (pass_signals, decode_address_to_semicolon): New.
20755
000ef4f0
DJ
207562006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20757
20758 * server.c (handle_query): Correct error handling for read_auxv.
20759
b7149293
UW
207602005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20761
20762 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20763 and srv_linux_thread_db to yes.
20764 * linux-s390-low.c (s390_fill_gregset): New function.
20765 (target_regsets): Define data structure.
20766
dae5f5cf
DJ
207672006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20768
20769 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20770 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20771 * config.in, configure: Regenerated.
20772 * inferiors.c (gdb_id_to_thread): New function.
20773 (gdb_id_to_thread_id): Use it.
20774 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20775 * linux-low.h (struct process_info): Add th member.
20776 (thread_db_get_tls_address): New prototype.
20777 * remote-utils.c (decode_address): Make non-static.
20778 * server.c (handle_query): Handle qGetTLSAddr.
20779 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20780 * target.h (struct target_ops): Add get_tls_address.
20781 * thread-db.c (maybe_attach_thread): Save the thread handle.
20782 (thread_db_get_tls_address): New.
20783
32ca6d61
DJ
207842006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20785
20786 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20787 (linux_resume_one_process): Take a siginfo_t *. Update all
20788 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20789 (struct pending_signals): Add a siginfo_t.
20790 (linux_wait_for_process): Always set last_status.
20791 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20792 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20793 * linux-low.h (struct process_info): Add last_status.
20794
5ffff7c1
DJ
207952006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20796
20797 * remote-utils.c (try_rle): New function.
20798 (putpkt_binary): Use it.
20799
8695c747
DJ
208002006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20801
20802 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20803 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20804 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20805 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20806 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20807 point registers.
20808
290fadea
RS
208092006-08-08 Richard Sandiford <richard@codesourcery.com>
20810
20811 * server.c (terminal_fd): New variable.
20812 (old_foreground_pgrp): Likewise.
20813 (restore_old_foreground_pgrp): New function.
20814 (start_inferior): Record the terminal file descriptor in terminal_fd
20815 and its original foreground group in old_foreground_pgrp. Register
20816 restore_old_foreground_pgrp with atexit().
20817
9f2e1e63
DJ
208182006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20819
20820 * server.c (handle_query): Correct qPart to qXfer.
20821
b80864fb
DJ
208222006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20823
20824 * configure.ac: Check for more headers which are missing on
20825 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20826 * configure.srv: Add Cygwin and mingw32.
20827 * remote-utils.c: Don't include headers unconditionally which
20828 are missing on mingw32. Include <winsock.h> for mingw32.
20829 (remote_open): Adjust for mingw32 support. Flush
20830 standard error after writing to it.
20831 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20832 (unblock_async_io, enable_async_io, disable_async_io)
20833 (readchar, getpkt): Update for Winsock support.
20834 (prepare_resume_reply): Expect a protocol signal number.
20835 * server.c: Disable <sys/wait.h> on mingw32.
20836 (start_inferior): Adjust for mingw32 support. Flush
20837 standard error after writing to it.
20838 (attach_inferior): Likewise. Use protocol signal
20839 numbers.
20840 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20841 and names.
20842 * win32-i386-low.c: New file.
20843 * Makefile.in (XM_CLIBS): Set.
20844 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20845 (win32-i386-low.o): New dependency rule.
20846 * linux-low.c (linux_wait): Use target signal numbers.
20847 * target.h (struct target_ops): Doc fix.
20848 * server.h (target_signal_to_name): New prototype.
20849 * gdbreplay.c: Don't include headers unconditionally which
20850 are missing on mingw32. Include <winsock.h> for mingw32.
20851 (remote_close, remote_open): Adjust for Winsock support.
20852 * configure, config.in: Regenerated.
20853
0876f84a
DJ
208542006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20855
20856 * server.c (decode_xfer_read, write_qxfer_response): New.
20857 (handle_query): Take a packet length argument. Handle
20858 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20859 the qSupported response.
20860 (main): Update call to handle_query.
20861
01f9e8fa
DJ
208622006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20863
20864 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20865 (putpkt_binary): Renamed from putpkt and adjusted for binary
20866 data.
20867 (putpkt): New wrapper for putpkt_binary.
20868 (readchar): Don't mask off the high bit.
20869 (decode_X_packet): New function.
20870 * server.c (main): Call putpkt_binary if a handler sets the packet
20871 length. Save the length of the incoming packet. Handle 'X'.
20872 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20873
be2a5f71
DJ
208742006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20875
20876 * server.c (handle_query): Handle qSupported.
20877
ea025f5f
DJ
208782006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20879
20880 * remote-utils.c (all_symbols_looked_up): New variable.
20881 (look_up_one_symbol): Check it.
20882 * server.h (look_up_one_symbol): New declaration.
20883 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20884
9308fc88
DJ
208852006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20886
20887 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 20888 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
20889 (PTRACE_GET_THREAD_AREA): Define.
20890 (ps_get_thread_area): New function.
20891
52fb6437
NS
208922006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20893
20894 * configure.srv (m68k*-*-uclinux*): New target.
20895 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20896 (linux_resume_one_process): Remove extraneous cast.
20897 (linux_read_offsets): New.
20898 (linux_target_op): Add linux_read_offsets on mmuless systems.
20899 * server.c (handle_query): Add qOffsets logic.
20900 * target.h (struct target_ops): Add read_offsets.
20901
21b0f40c
DJ
209022006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20903
20904 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20905 (PTRACE_GET_THREAD_AREA): Define.
20906 (ps_get_thread_area): New function.
20907 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20908 (linux-x86-64-low.o): Update.
20909
0050a760
DJ
209102006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20911
20912 * configure.ac: Remove checks for prfpregset_t.
20913 * gdb_proc_service.h: New file.
20914 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20915 new "gdb_proc_service.h".
20916 * proc-service.c: Likewise.
20917 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20918 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20919 * Makefile.in (gdb_proc_service_h): Updated.
20920 * configure, config.in: Regenerated.
20921
b92a518e
DJ
209222006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
20923
20924 * remote-utils.c (prepare_resume_reply): Move declaration
20925 of gdb_id_from_wait to the top of the block.
20926
545587ee
DJ
209272006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
20928
20929 * linux-low.c (regsets_store_inferior_registers): Read the regset
20930 from the target before filling it.
20931
9db87ebd
DJ
209322006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20933
20934 * server.c (attach_inferior): Return SIGTRAP for a successful
20935 attach.
20936
dd24457d
DJ
209372006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
20938
20939 * Makefile.in (OBS): Add version.o.
20940 (STAGESTUFF): Delete.
20941 (version.o): Add dependencies.
20942 (version.c): Replace rule.
20943 (clean): Remove version.c.
20944 * server.c (gdbserver_version): New.
20945 (gdbserver_usage): Use printf.
20946 (main): Handle --version and --help.
20947 * server.h (version, host_name): Add declarations.
20948
6f0f660e
EZ
209492005-12-23 Eli Zaretskii <eliz@gnu.org>
20950
889bf7c5
PA
20951 * linux-arm-low.c:
20952 * linux-arm-low.c:
20953 * inferiors.c:
20954 * i387-fp.h:
20955 * i387-fp.c:
20956 * gdbreplay.c:
20957 * regcache.c:
20958 * proc-service.c:
20959 * mem-break.h:
20960 * mem-break.c:
20961 * linux-x86-64-low.c:
20962 * linux-sh-low.c:
20963 * linux-s390-low.c:
20964 * linux-ppc64-low.c:
20965 * linux-ppc-low.c:
20966 * linux-mips-low.c:
20967 * linux-m68k-low.c:
20968 * linux-m32r-low.c:
20969 * linux-low.h:
20970 * linux-low.c:
20971 * linux-ia64-low.c:
20972 * linux-i386-low.c:
20973 * linux-crisv32-low.c:
20974 * thread-db.c:
20975 * terminal.h:
20976 * target.h:
20977 * target.c:
20978 * server.h:
20979 * server.c:
20980 * remote-utils.c:
20981 * regcache.h:
20982 * utils.c:
20983 * Makefile.in:
20984 * configure.ac:
6f0f660e
EZ
20985 * gdbserver.1: Add (C) after Copyright. Update the FSF
20986 address.
20987
9d1fb177
DJ
209882005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
20989
20990 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
20991 (arm_breakpoint_at): Recognize both breakpoints.
20992 (the_low_target): Use the correct breakpoint instruction.
20993
011a70c2
DJ
209942005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
20995
20996 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
20997 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
20998 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
20999 (the_low_target): Update.
21000
7fb85e41
AS
210012005-10-25 Andreas Schwab <schwab@suse.de>
21002
21003 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21004
21005 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21006 (ia64_num_regs): Reduce to 462.
21007
3db0444b
DJ
210082005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21009
21010 * acinclude.m4: Correct quoting.
21011 * aclocal.m4: Regenerated.
21012
21013 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21014 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21015 (thread_db_init): Call thread_db_err_str.
21016 * configure.ac: Check for TD_VERSION.
21017 * config.in, configure: Regenerated.
21018
bee0189a
DJ
210192005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21020
21021 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21022
e9d25b98
DJ
210232005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21024
21025 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21026 is not available. Define HAVE_PTRACE_GETREGS if it is.
21027 * config.in, configure: Regenerated.
21028 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21029 * linux-i386-low.c, linux-m68k-low.c: Update to use
21030 HAVE_PTRACE_GETREGS.
21031 * linux-low.c (regsets_fetch_inferior_registers)
21032 (regsets_store_inferior_registers): Only return 0 if we processed
21033 GENERAL_REGS.
21034 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21035 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21036
a06660f7
DJ
210372005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21038
21039 * inferiors.c (struct thread_info): Add gdb_id.
21040 (add_thread): Add gdb_id argument.
21041 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21042 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21043 calls to add_thread.
21044 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21045 * server.c (handle_query): Use thread_to_gdb_id.
21046 (handle_v_cont, main): Use gdb_id_to_thread_id.
21047 * server.h (add_thread): Update prototype.
21048 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21049 prototypes.
21050
5a1f5858
DJ
210512005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21052
21053 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21054 left-padded registers.
21055 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21056 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21057
e122f1f5
SE
210582005-07-01 Steve Ellcey <sje@cup.hp.com>
21059
21060 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21061 * configure: Regenerate.
21062 * config.in: Regenerate.
21063 * server.h (NEED_DECLARATION_STRERROR):
21064 Replace with !HAVE_DECL_STRERROR.
21065
d592fa2f
DJ
210662005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21067
21068 * linux-low.c (linux_wait, linux_send_signal): Don't test
21069 an unsigned long variable for > 0 if it could be MAX_ULONG.
21070 * server.c (myresume): Likewise.
21071 * target.c (set_desired_inferior): Likewise.
21072
ccbd4912
MK
210732005-06-13 Mark Kettenis <kettenis@gnu.org>
21074
21075 * configure.ac: Simplify and improve check for socklen_t.
21076 * configure, config.in: Regenerate.
21077
f450004a
DJ
210782005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21079
21080 * acconfig.h: Remove.
21081 * configure.ac: Add a test for socklen_t. Use three-argument
21082 AC_DEFINE throughout.
21083 * config.in: Regenerated using autoheader 2.59.
21084 * configure: Regenerated.
21085
21086 * gdbreplay.c (socklen_t): Provide a default.
21087 (remote_open): Use socklen_t.
21088 * remote-utils.c (socklen_t): Provide a default.
21089 (remote_open): Use socklen_t.
21090 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21091 unsigned char.
21092
21093 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21094 char for buffers.
21095 * linux-low.c (linux_read_memory, linux_write_memory)
21096 (linux_read_auxv): Likewise.
21097 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21098 (check_mem_write): Likewise.
21099 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21100 Likewise.
21101 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21102 (registers_from_string, register_data): Likewise.
21103 * server.c (handle_query, main): Likewise.
21104 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21105 (decode_M_packet): Likewise.
21106 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21107 * target.h (struct target_ops): Update read_memory, write_memory,
21108 and read_auxv.
21109 (read_inferior_memory, write_inferior_memory): Update.
21110 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21111 to unsigned char *.
21112 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21113 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21114 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21115 linux-s390-low.c, linux-sh-low.c: Update for changes in
21116 read_inferior_memory and the_low_target->breakpoint.
21117
eee84df1
DJ
211182005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21119
21120 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21121 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21122 * configure.srv: Add powerpc64-*-linux*.
21123 * linux-ppc64-low.c: New file.
21124
45b134e5
OF
211252005-05-23 Orjan Friberg <orjanf@axis.com>
21126
21127 * linux-cris-low.c: New file with support for CRIS.
21128 * linux-crisv32-low.c: Ditto for CRISv32.
21129 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21130 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 21131 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
21132 reg-crisv32.o, and reg-crisv32.c to make rules.
21133 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21134 recognized targets.
21135
48d93c75
UW
211362005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21137
21138 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21139 of sizeof (PTRACE_XFER_TYPE).
21140 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21141
e013ee27
OF
211422005-05-12 Orjan Friberg <orjanf@axis.com>
21143
889bf7c5 21144 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
21145 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21146 pointers for hardware watchpoint support.
21147 * linux-low.h (struct linux_target_ops): Ditto.
21148 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21149 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21150 to linux_target_ops.
21151 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21152 reply packet.
21153 * server.c (main): Recognize 'Z' and 'z' packets.
21154
b0ded00b
UW
211552005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21156
21157 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21158 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21159 (the_low_target): Add new members.
21160
8643e2ad
DJ
211612005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21162
21163 * proc-service.c (ps_lgetregs): Search all_processes instead of
21164 all_threads.
21165
fc620387
DJ
211662005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21167
21168 * server.c (start_inferior): Change return type to int.
21169 (attach_inferior): Change sigptr to int *.
21170 (handle_v_cont, handle_v_requests): Change signal to int *.
21171 (main): Change signal to int.
21172
211732005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
21174
21175 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21176 * configure.srv: Add m32r*-*-linux*.
21177 * linux-m32r-low.c: New file.
21178
e0e76420
DJ
211792005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21180
21181 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21182
a1928bad
DJ
211832005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21184
21185 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21186 Take unsigned long arguments for PIDs.
21187 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21188 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21189 (wait_for_sigstop, linux_resume_one_process)
21190 (regsets_fetch_inferior_registers, linux_send_signal)
21191 (linux_read_auxv): Likewise. Update the types of variables holding
21192 PIDs. Update format string specifiers.
21193 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21194 * remote-utils.c (prepare_resume_reply): Likewise.
21195 * server.c (cont_thread, general_thread, step_thread)
21196 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21197 unsigned long.
21198 (handle_query): Update format specifiers.
21199 (handle_v_cont, main): Use strtoul for thread IDs.
21200 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21201 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21202 (general_thread, step_thread, thread_from_wait)
21203 (old_thread_from_wait): Update.
21204 * target.h (struct thread_resume): Use unsigned long for THREAD.
21205 (struct target_ops): Use unsigned long for arguments to attach and
21206 thread_alive.
21207
dcdb98d2
DJ
212082005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21209
21210 * acinclude.m4: Include bfd/bfd.m4 directly.
21211 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21212 <agriffis@toolchain.org>.
21213 * aclocal.m4, configure: Regenerated.
21214
bec39cab
AC
212152005-01-07 Andrew Cagney <cagney@gnu.org>
21216
21217 * configure.ac: Rename configure.in, require autoconf 2.59.
21218 * configure: Re-generate.
21219
434c4c77
DJ
212202004-12-08 Daniel Jacobowitz <dan@debian.org>
21221
21222 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21223 LIBS when finished.
21224 * aclocal.m4: Regenerated.
21225 * configure: Regenerated.
21226
db1d3e1b
AS
212272004-11-21 Andreas Schwab <schwab@suse.de>
21228
21229 * linux-m68k-low.c (m68k_num_gregs): Define.
21230 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21231 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21232 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21233 (m68k_breakpoint_at): New. Add to the_low_target.
21234
21235 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21236 srv_linux_thread_db to yes.
21237
43360365
JB
212382004-10-20 Joel Brobecker <brobecker@gnat.com>
21239
21240 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21241 (ARCH_SET_FS): Likewise.
21242 (ARCH_GET_FS): Likewise.
21243 (ARCH_GET_GS): Likewise.
21244
fd500816
DJ
212452004-10-16 Daniel Jacobowitz <dan@debian.org>
21246
21247 * linux-i386-low.c (ps_get_thread_area): New.
21248 * linux-x86-64-low.c (ps_get_thread_area): New.
21249 * linux-low.c: Include <sys/syscall.h>.
21250 (linux_kill_one_process): Don't kill the first thread here.
21251 (linux_kill): Kill the first thread here.
21252 (kill_lwp): New function.
21253 (send_sigstop, linux_send_signal): Use it.
21254 * proc-service.c: Clean up #ifdefs.
21255 (fpregset_info): Delete.
21256 (ps_lgetregs): Update and enable implementation.
21257 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21258 implementations.
21259 * remote-utils.c (struct sym_cache, symbol_cache): New.
21260 (input_interrupt): Print a clearer message.
21261 (async_io_enabled): New variable.
21262 (enable_async_io, disable_async_io): Use it. Update comments.
21263 (look_up_one_symbol): Use the symbol cache.
21264 * thread-db.c (thread_db_look_up_symbols): New function.
21265 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21266
f6de3c42
DJ
212672004-10-16 Daniel Jacobowitz <dan@debian.org>
21268
21269 * configure.in: Test for -rdynamic.
21270 * configure: Regenerated.
21271 * Makefile (INTERNAL_LDFLAGS): New.
21272 (gdbserver, gdbreplay): Use it.
21273
2c0fc042
AC
212742004-09-02 Andrew Cagney <cagney@gnu.org>
21275
21276 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21277
075b3282
DJ
212782004-03-23 Daniel Jacobowitz <drow@mvista.com>
21279
21280 * linux-low.c (linux_wait): Clear all_processes list also.
21281
fa6a77dc
DJ
212822004-03-12 Daniel Jacobowitz <drow@mvista.com>
21283
21284 * linux-low.c: Include <errno.h>. Remove extern declaration of
21285 errno.
21286
6d782a97
DJ
212872004-03-12 Daniel Jacobowitz <drow@mvista.com>
21288
21289 * gdbreplay.c, server.h, utils.c: Update copyright years.
21290
3a7fb99b
DJ
212912004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21292
21293 * server.c (main): Print child status or termination signal from
21294 variable 'signal', not 'sig'.
21295
c3e735a6
DJ
212962004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21297
21298 * linux-low.c (linux_read_memory): Change return type to
21299 int. Check for and return error from ptrace().
21300 * target.c (read_inferior_memory): Change return type to int. Pass
21301 back return status from the_target->read_memory().
21302 * target.h (struct target_ops): Adapt *read_memory() prototype.
21303 Update comment.
21304 (read_inferior_memory): Adapt prototype.
21305 * server.c (main): Return an error packet if
21306 read_inferior_memory() returns an error.
21307
a59d1c82
DJ
213082004-03-04 Daniel Jacobowitz <drow@mvista.com>
21309
21310 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21311 Unify with other clean targets.
21312
dc3f8883
DJ
213132004-02-29 Daniel Jacobowitz <drow@mvista.com>
21314
21315 * server.c (handle_v_cont): Call set_desired_inferior.
21316
89a208da
DJ
213172004-02-29 Daniel Jacobowitz <drow@mvista.com>
21318
21319 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21320
62ea82f5
DJ
213212004-02-29 Daniel Jacobowitz <drow@mvista.com>
21322
21323 * linux-low.c (linux_wait): Unblock async I/O.
21324 (linux_resume): Block and enable async I/O.
21325 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21326 * server.h (block_async_io, unblock_async_io): Add prototypes.
21327
6910d122
DJ
213282004-02-29 Daniel Jacobowitz <drow@mvista.com>
21329
21330 * remote-utils.c (remote_open): Print a status notice after
21331 opening a TCP port.
21332 * server.c (attach_inferior): Print a status notice after
21333 attaching.
21334
213352004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
21336
21337 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21338
c89dc5d4
DJ
213392004-02-26 Daniel Jacobowitz <drow@mvista.com>
21340
21341 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21342 error packet.
21343 * server.c, target.h: Update copyright years.
21344
4b8dad4a
RM
213452004-02-25 Roland McGrath <roland@redhat.com>
21346
21347 * target.h (struct target_ops): New member `read_auxv'.
21348 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21349 * linux-low.c (linux_read_auxv): New function.
21350 (linux_target_ops): Initialize `read_auxv' member to that.
21351
d7446758
JB
213522004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21353
21354 Committed by Jim Blandy <jimb@redhat.com>.
21355
21356 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 21357 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
21358 instead of GPR_SIZE to distiguish s390 and s390x targets.
21359
5544ad89
DJ
213602004-01-31 Daniel Jacobowitz <drow@mvista.com>
21361
21362 * linux-low.c: Update copyright year.
21363 (check_removed_breakpoint): Clear pending_is_breakpoint.
21364 (linux_set_resume_request, linux_queue_one_thread)
21365 (resume_status_pending_p): New functions.
21366 (linux_continue_one_thread): Use process->resume.
21367 (linux_resume): Only resume threads if there are no pending events.
21368 * linux-low.h (struct process_info): Add resume request
21369 pointer.
21370
2a68b70e
DJ
213712004-01-30 Daniel Jacobowitz <drow@mvista.com>
21372
21373 * regcache.c (new_register_cache): Clear the allocated register
21374 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21375
64386c31
DJ
213762003-10-13 Daniel Jacobowitz <drow@mvista.com>
21377
21378 * linux-low.c (linux_resume): Take a struct thread_resume *
21379 argument.
21380 (linux_wait): Update call.
21381 (resume_ptr): New static variable.
21382 (linux_continue_one_thread): Renamed from
21383 linux_continue_one_process. Use resume_ptr.
21384 (linux_resume): Use linux_continue_one_thread.
21385 * server.c (handle_v_cont, handle_v_requests): New functions.
21386 (myresume): New function.
21387 (main): Handle 'v' case.
21388 * target.h (struct thread_resume): New type.
21389 (struct target_ops): Change argument of "resume" to struct
21390 thread_resume *.
21391 (myresume): Delete macro.
21392
c938e9b0
L
213932003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21394
21395 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21396 (uninstall): Support DESTDIR.
21397
7f313d07
BC
21398Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21399
21400 * configure.srv: Add xscale*linux copy of arm*linux entry.
21401
3b2fc2ea
DJ
214022003-07-24 Daniel Jacobowitz <drow@mvista.com>
21403
21404 * linux-arm-low.c (arm_reinsert_addr): New function.
21405 (the_low_target): Add arm_reinsert_addr.
21406
1c0a559e
MK
214072003-07-08 Mark Kettenis <kettenis@gnu.org>
21408
21409 * mem-break.c: Remove whitespace at end of file.
21410
43d5792c
DJ
214112003-06-28 Daniel Jacobowitz <drow@mvista.com>
21412
21413 * configure.in: Check whether we need to prototype strerror.
21414 * server.h: Optionally prototype strerror.
21415 * gdbreplay.c (perror_with_name): Use strerror.
21416 * linux-low.c (linux_attach_lwp): Use strerror.
21417 * utils.c (perror_with_name): Use strerror.
21418 * config.in, configure: Regenerated.
21419
c8a86edf
DJ
214202003-06-28 Daniel Jacobowitz <drow@mvista.com>
21421
21422 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21423 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21424
73d37363
DJ
214252003-06-20 Daniel Jacobowitz <drow@mvista.com>
21426
21427 * Makefile.in (SFILES): Update.
21428 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21429 low-sun3.c: Remove files.
21430
6ad8ae5c
DJ
214312003-06-17 Daniel Jacobowitz <drow@mvista.com>
21432
21433 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21434 (linux_detach_one_process, linux_detach): New functions.
21435 (linux_target_ops): Add linux_detach.
21436 * server.c (main): Handle 'D' packet.
21437 * target.h (struct target_ops): Add "detach" member.
21438 (detach_inferior): Define.
21439
1581182a
MK
214402003-06-13 Mark Kettenis <kettenis@gnu.org>
21441
21442 From Kelley Cook <kelleycook@wideopenwest.com>:
21443 * configure.srv: Accept i[34567]86 variants.
21444
e5379b03
DJ
214452003-06-05 Daniel Jacobowitz <drow@mvista.com>
21446
21447 * linux-low.c (linux_wait_for_event): Correct comment typos.
21448 (linux_resume_one_process): Call check_removed_breakpoint.
21449 (linux_send_signal): New function.
21450 (linux_target_ops): Add linux_send_signal.
21451 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21452 of kill.
21453 * target.h (struct target_ops): Add send_signal.
21454
2ff29de4
JB
214552003-05-29 Jim Blandy <jimb@redhat.com>
21456
21457 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21458 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21459 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21460 away part of the register's value.
21461
254787d4
DJ
214622003-03-26 Daniel Jacobowitz <drow@mvista.com>
21463
21464 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21465 (linux_wait_for_event, linux_init_signals): Likewise.
21466
94e10508
DJ
214672003-03-17 Daniel Jacobowitz <drow@mvista.com>
21468
21469 * configure.in: Check for stdlib.h.
21470 * configure: Regenerated.
21471 * config.in: Regenerated.
21472
4c0711e0
DJ
214732003-01-04 Andreas Schwab <schwab@suse.de>
21474
21475 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21476
ef66e766
AC
214772003-01-02 Andrew Cagney <ac131313@redhat.com>
21478
21479 * Makefile.in: Remove obsolete code.
21480
a1358604
DJ
214812002-11-20 Daniel Jacobowitz <drow@mvista.com>
21482
21483 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21484 defined(PT_FPR0_HI).
21485
23ce3b1c
DJ
214862002-11-17 Stuart Hughes <seh@zee2.com>
21487
21488 * linux-arm-low.c (arm_num_regs): Increase.
21489 (arm_regmap): Include status register.
21490
214912002-11-17 Daniel Jacobowitz <drow@mvista.com>
21492
21493 * linux-low.c (register_addr): Remove incorrect -1 check.
21494
a9fa9f7d
DJ
214952002-08-29 Daniel Jacobowitz <drow@mvista.com>
21496
21497 * linux-low.c (linux_create_inferior): Call setpgid. Return
21498 the new PID.
21499 (unstopped_p, linux_signal_pid): Remove.
21500 (linux_target_ops): Remove linux_signal_pid.
21501 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21502 global instead of target method.
21503 * target.h (struct target_ops): Remove signal_pid. Update comment
21504 for create_inferior.
21505 * server.c (signal_pid): New variable.
21506 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 21507 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
21508 (attach_inferior): Set signal_pid.
21509
17574093
DJ
215102002-08-23 Daniel Jacobowitz <drow@mvista.com>
21511
21512 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21513
215142002-08-20 Jim Blandy <jimb@redhat.com>
21515
21516 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21517 default for this.
21518
215192002-08-01 Andrew Cagney <cagney@redhat.com>
21520
21521 * Makefile.in: Make chill references obsolete.
21522
215232002-07-24 Kevin Buettner <kevinb@redhat.com>
21524
21525 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21526 * configure: Regenerate.
21527 * config.in: Regenerate.
21528
215292002-07-09 David O'Brien <obrien@FreeBSD.org>
21530
21531 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21532 (perror_with_name, remote_close, remote_open, expect, play): Static.
21533
215342002-07-04 Michal Ludvig <mludvig@suse.cz>
21535
4b8dad4a 21536 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
21537 byte offsets instead of an array of indexes.
21538 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21539
215402002-06-13 Daniel Jacobowitz <drow@mvista.com>
21541
21542 * regcache.c: Add comment.
21543
215442002-06-11 Daniel Jacobowitz <drow@mvista.com>
21545
21546 * thread-db.c: New file.
21547 * proc-service.c: New file.
21548 * acinclude.m4: New file.
21549 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21550 proc-service.o, and thread-db.o.
21551 (linux-low.o): Add USE_THREAD_DB.
21552 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21553 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21554 * aclocal.m4: Regenerated.
21555 * config.in: Regenerated.
21556 * configure: Regenerated.
21557 * configure.in: Check for proc_service.h, sys/procfs.h,
21558 thread_db.h, and linux/elf.h headrs.
21559 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21560 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21561 Check for -lthread_db and thread support.
21562 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21563 PowerPC, and SuperH.
21564 * i387-fp.c: Constify arguments.
21565 * i387-fp.h: Likewise.
21566 * inferiors.c: (struct thread_info): Renamed from
21567 `struct inferior_info'. Remove PID member. Use generic inferior
21568 list header. All uses updated.
21569 (inferiors, signal_pid): Removed.
21570 (all_threads): New variable.
21571 (get_thread): Define.
21572 (add_inferior_to_list): New function.
21573 (for_each_inferior): New function.
21574 (change_inferior_id): New function.
21575 (add_inferior): Removed.
21576 (remove_inferior): New function.
21577 (add_thread): New function.
21578 (free_one_thread): New function.
21579 (remove_thread): New function.
21580 (clear_inferiors): Use for_each_inferior and free_one_thread.
21581 (find_inferior): New function.
21582 (find_inferior_id): New function.
21583 (inferior_target_data): Update argument type.
21584 (set_inferior_target_data): Likewise.
21585 (inferior_regcache_data): Likewise.
21586 (set_inferior_regcache_data): Likewise.
21587 * linux-low.c (linux_bp_reinsert): Remove.
21588 (all_processes, stopping_threads, using_thrads)
21589 (struct pending_signals, debug_threads, pid_of): New.
21590 (inferior_pid): Replace with macro.
21591 (struct inferior_linux_data): Remove.
21592 (get_stop_pc, add_process): New functions.
21593 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21594 Use add_process and add_thread.
21595 (linux_attach_lwp): New function, based on old linux_attach. Use
21596 add_process and add_thread. Set stop_expected for new threads.
21597 (linux_attach): New function.
21598 (linux_kill_one_process): New function.
21599 (linux_kill): Kill all LWPs.
21600 (linux_thread_alive): Use find_inferior_id.
21601 (check_removed_breakpoints, status_pending_p): New functions.
21602 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21603 Update. Use WNOHANG. Wait for cloned processes also. Update process
21604 struct for the found process.
21605 (linux_wait_for_event): New function.
21606 (linux_wait): Use it. Support LWPs.
21607 (send_sigstop, wait_for_sigstop, stop_all_processes)
21608 (linux_resume_one_process, linux_continue_one_process): New functions.
21609 (linux_resume): Support LWPs.
21610 (REGISTER_RAW_SIZE): Remove.
21611 (fetch_register): Use register_size instead. Call supply_register.
21612 (usr_store_inferior_registers): Likewise. Call collect_register.
21613 Fix recursive case.
21614 (regsets_fetch_inferior_registers): Improve error message.
21615 (regsets_store_inferior_registers): Add debugging.
21616 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21617 (unstopped_p, linux_signal_pid): New functions.
21618 (linux_target_ops): Add linux_signal_pid.
21619 (linux_init_signals): New function.
21620 (initialize_low): Call it. Initialize using_threads.
21621 * regcache.c (inferior_regcache_data): Add valid
21622 flag.
21623 (get_regcache): Fetch registers lazily. Add fetch argument
21624 and update all callers.
21625 (regcache_invalidate_one, regcache_invalidate): New
21626 functions.
21627 (new_register_cache): Renamed from create_register_cache.
21628 Return the new regcache.
21629 (free_register_cache): Change argument to a void *.
21630 (registers_to_string, registers_from_string): Call get_regcache
21631 with fetch flag set.
21632 (register_data): Make static. Pass fetch flag to get_regcache.
21633 (supply_register): Call get_regcache with fetch flag clear.
21634 (collect_register): Call get_regcache with fetch flag set.
21635 (collect_register_as_string): New function.
21636 * regcache.h: Update.
21637 * remote-utils.c (putpkt): Flush after debug output and use
21638 stderr.
21639 Handle input interrupts while waiting for an ACK.
21640 (input_interrupt): Use signal_pid method.
21641 (getpkt): Flush after debug output and use stderr.
21642 (outreg): Use collect_register_as_string.
21643 (new_thread_notify, dead_thread_notify): New functions.
21644 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21645 and general_thread.
21646 (look_up_one_symbol): Flush after debug output.
21647 * server.c (step_thread, server_waiting): New variables.
21648 (start_inferior): Don't use signal_pid. Update call to mywait.
21649 (attach_inferior): Update call to mywait.
21650 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21651 (main): Don't fetch/store registers explicitly. Use
21652 set_desired_inferior. Support proposed ``Hs'' packet. Update
21653 calls to mywait.
21654 * server.h: Update.
21655 (struct inferior_list, struct_inferior_list_entry): New.
21656 * target.c (set_desired_inferior): New.
21657 (write_inferior_memory): Constify.
21658 (mywait): New function.
21659 * target.h: Update.
21660 (struct target_ops): New signal_pid method.
21661 (mywait): Removed macro, added prototype.
21662
21663 * linux-low.h (regset_func): Removed.
21664 (regset_fill_func, regset_store_func): New.
21665 (enum regset_type): New.
21666 (struct regset_info): Add type field. Use new operation types.
21667 (struct linux_target_ops): stop_pc renamed to get_pc.
21668 Add decr_pc_after_break and breakpoint_at.
21669 (get_process, get_thread_proess, get_process_thread)
21670 (strut process_info, all_processes, linux_attach_lwp)
21671 (thread_db_init): New.
21672
21673 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21674 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21675 (the_low_target): Add new members.
21676 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21677 (i386_store_fpxregset): Constify.
21678 (target_regsets): Add new kind identifier.
21679 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21680 (i386_set_pc): Add debugging.
21681 (i386_breakpoint_at): New function.
21682 (the_low_target): Add new members.
21683 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21684 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21685 (mips_breakpoint_at): New.
21686 (the_low_target): Add new members.
21687 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21688 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21689 (the_low_target): Add new members.
21690 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21691 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21692 (the_low_target): Add new members.
21693 * linux-x86-64-low.c (target_regsets): Add new kind
21694 identifier.
21695
216962002-05-15 Daniel Jacobowitz <drow@mvista.com>
21697
21698 From Martin Pool <mbp@samba.org>:
21699 * server.c (gdbserver_usage): New function.
21700 (main): Call it.
21701
217022002-05-14 Daniel Jacobowitz <drow@mvista.com>
21703
21704 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21705 stop_at -> stop_pc.
21706
217072002-05-04 Andrew Cagney <ac131313@redhat.com>
21708
21709 * Makefile.in: Remove obsolete code.
21710
217112002-04-24 Michal Ludvig <mludvig@suse.cz>
21712
21713 * linux-low.c (regsets_fetch_inferior_registers),
21714 (regsets_store_inferior_registers): Removed cast to int from
21715 ptrace() calls.
21716 * regcache.h: Added declaration of struct inferior_info.
21717
217182002-04-20 Daniel Jacobowitz <drow@mvista.com>
21719
21720 * inferiors.c (struct inferior_info): Add regcache_data.
21721 (add_inferior): Call create_register_cache.
21722 (clear_inferiors): Call free_register_cache.
21723 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21724 * regcache.c (struct inferior_regcache_data): New.
21725 (registers): Remove.
21726 (get_regcache): New function.
21727 (create_register_cache, free_register_cache): New functions.
21728 (set_register_cache): Don't initialize the register cache here.
21729 (registers_to_string, registers_from_string, register_data): Call
21730 get_regcache.
21731 * regcache.h: Add prototypes.
21732 * server.h: Likewise.
21733
217342002-04-20 Daniel Jacobowitz <drow@mvista.com>
21735
21736 * mem-break.c: New file.
21737 * mem-break.h: New file.
21738 * Makefile.in: Add mem-break.o rule; update server.h
21739 dependencies.
21740 * inferiors.c (struct inferior_info): Add target_data
21741 member.
21742 (clear_inferiors): Free target_data member if set.
21743 (inferior_target_data, set_inferior_target_data): New functions.
21744 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21745 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21746 * linux-low.c (linux_bp_reinsert): New variable.
21747 (struct inferior_linux_data): New.
21748 (linux_create_inferior): Use set_inferior_target_data.
21749 (linux_attach): Likewise. Call add_inferior.
21750 (linux_wait_for_one_inferior): New function.
21751 (linux_wait): Call it.
21752 (linux_write_memory): Add const.
21753 (initialize_low): Call set_breakpoint_data.
21754 * linux-low.h (struct linux_target_ops): Add breakpoint
21755 handling members.
21756 * server.c (attach_inferior): Remove extra add_inferior
21757 call.
21758 * server.h: Include mem-break.h. Update inferior.c
21759 prototypes.
21760 * target.c (read_inferior_memory)
21761 (write_inferior_memory): New functions.
21762 * target.h (read_inferior_memory)
21763 (write_inferior_memory): Change macros to prototypes.
21764 (struct target_ops): Update comments. Add const to write_memory
21765 definition.
21766
217672002-04-11 Daniel Jacobowitz <drow@mvista.com>
21768
21769 * linux-low.c (usr_store_inferior_registers): Support
21770 registers which are allowed to fail to store.
21771 * linux-low.h (linux_target_ops): Likewise.
21772 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21773 (ppc_cannot_store_register): FPSCR may not be storable.
21774
217752002-04-09 Daniel Jacobowitz <drow@mvista.com>
21776
21777 * server.h: Include <string.h> if HAVE_STRING_H.
21778 * ChangeLog: Correct paths in last ChangeLog entry.
21779
217802002-04-09 Daniel Jacobowitz <drow@mvista.com>
21781
21782 * linux-low.h: Remove obsolete prototypes.
21783 (struct linux_target_ops): New.
21784 (extern the_low_target): New.
21785 * linux-low.c (num_regs, regmap): Remove declarations.
21786 (register_addr): Use the_low_target explicitly.
21787 (fetch_register): Likewise.
21788 (usr_fetch_inferior_registers): Likewise.
21789 (usr_store_inferior_registers): Likewise.
21790 * linux-arm-low.c (num_regs): Remove.
21791 (arm_num_regs): Define.
21792 (arm_regmap): Renamed from regmap, made static.
21793 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21794 made static.
21795 (arm_cannot_store_register): Renamed from cannot_store_register,
21796 made static.
21797 (the_low_target): New.
21798 * linux-i386-low.c (num_regs): Remove.
21799 (i386_num_regs): Define.
21800 (i386_regmap): Renamed from regmap, made static.
21801 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21802 made static.
21803 (i386_cannot_store_register): Renamed from cannot_store_register,
21804 made static.
21805 (the_low_target): New.
21806 * linux-ia64-low.c (num_regs): Remove.
21807 (ia64_num_regs): Define.
21808 (ia64_regmap): Renamed from regmap, made static.
21809 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21810 made static.
21811 (ia64_cannot_store_register): Renamed from cannot_store_register,
21812 made static.
21813 (the_low_target): New.
21814 * linux-m68k-low.c (num_regs): Remove.
21815 (m68k_num_regs): Define.
21816 (m68k_regmap): Renamed from regmap, made static.
21817 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21818 made static.
21819 (m68k_cannot_store_register): Renamed from cannot_store_register,
21820 made static.
21821 (the_low_target): New.
21822 * linux-mips-low.c (num_regs): Remove.
21823 (mips_num_regs): Define.
21824 (mips_regmap): Renamed from regmap, made static.
21825 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21826 made static.
21827 (mips_cannot_store_register): Renamed from cannot_store_register,
21828 made static.
21829 (the_low_target): New.
21830 * linux-ppc-low.c (num_regs): Remove.
21831 (ppc_num_regs): Define.
21832 (ppc_regmap): Renamed from regmap, made static.
21833 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21834 made static.
21835 (ppc_cannot_store_register): Renamed from cannot_store_register,
21836 made static.
21837 (the_low_target): New.
21838 * linux-s390-low.c (num_regs): Remove.
21839 (s390_num_regs): Define.
21840 (s390_regmap): Renamed from regmap, made static.
21841 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21842 made static.
21843 (s390_cannot_store_register): Renamed from cannot_store_register,
21844 made static.
21845 (the_low_target): New.
21846 * linux-sh-low.c (num_regs): Remove.
21847 (sh_num_regs): Define.
21848 (sh_regmap): Renamed from regmap, made static.
21849 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21850 made static.
21851 (sh_cannot_store_register): Renamed from cannot_store_register,
21852 made static.
21853 (the_low_target): New.
21854 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21855 (the_low_target): New.
21856
218572002-04-09 Daniel Jacobowitz <drow@mvista.com>
21858
21859 * Makefile.in: Add stamp-h target.
21860 * configure.in: Create stamp-h.
21861 * configure: Regenerated.
21862
218632002-04-09 Daniel Jacobowitz <drow@mvista.com>
21864
21865 * inferiors.c: New file.
21866 * target.c: New file.
21867 * target.h: New file.
21868 * Makefile.in: Add target.o and inferiors.o. Update
21869 dependencies.
21870 * linux-low.c (inferior_pid): New static variable,
21871 moved from server.c.
21872 (linux_create_inferior): Renamed from create_inferior.
21873 Call add_inferior. Return 0 on success instead of a PID.
21874 (linux_attach): Renamed from myattach.
21875 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21876 (linux_thread_alive): Renamed from mythread_alive.
21877 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21878 child dies.
21879 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21880 (regsets_store_inferior_registers): Correct error message.
21881 Add missing ``return 0''.
21882 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21883 (linux_store_registers): Renamed from store_inferior_registers.
21884 (linux_read_memory): Renamed from read_inferior_memory.
21885 (linux_write_memory): Renamed from write_inferior_memory.
21886 (linux_target_ops): New structure.
21887 (initialize_low): Call set_target_ops ().
21888 * remote-utils.c (unhexify): New function.
21889 (hexify): New function.
21890 (input_interrupt): Send signals to ``signal_pid''.
21891 * server.c (inferior_pid): Remove.
21892 (start_inferior): Update create_inferior call.
21893 (attach_inferior): Call add_inferior.
21894 (handle_query): New function.
21895 (main): Call handle_query for `q' packets.
21896 * server.h: Include "target.h". Remove obsolete prototypes.
21897 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21898
218992002-04-09 Daniel Jacobowitz <drow@mvista.com>
21900
21901 * Makefile.in: Add WARN_CFLAGS. Update configury
21902 dependencies.
21903 * configure.in: Check for <string.h>
21904 * configure: Regenerate.
21905 * config.in: Regenerate.
21906 * gdbreplay.c: Include needed system headers.
21907 (remote_open): Remove strchr prototype.
21908 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21909 * regcache.c (supply_register): Change buf argument to const void *.
21910 (supply_register_by_name): Likewise.
21911 (collect_register): Change buf argument to void *.
21912 (collect_register_by_name): Likewise.
21913 * regcache.h: Add missing prototypes.
21914 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21915 * server.c (handle_query): New function.
21916 (attached): New static variable, moved out of main.
21917 (main): Quiet longjmp clobber warnings.
21918 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21919 * utils.c (error): Remove NORETURN.
21920 (fatal): Likewise.