1 2016-04-21 Pedro Alves <palves@redhat.com>
3 * linux-s390-low.c (s390_collect_ptrace_register)
4 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
6 (s390_check_regset): Use void * instead of gdb_byte *.
8 2016-04-20 Pedro Alves <palves@redhat.com>
10 * configure: Renegerate.
12 2016-04-20 Yao Qi <yao.qi@linaro.org>
14 * linux-aarch32-low.c: Include "arch/arm-linux.h".
15 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
17 (arm_store_gregset): Likewise.
19 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
21 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
22 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
23 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
24 (amd64-avx-mpx-linux.c): New rules.
25 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
26 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
27 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
28 (srv_amd64_regobj): Add amd64-avx-mpx.o.
29 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
30 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
31 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
32 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
33 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
34 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
35 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
36 * linux-x86-low.c (x86_linux_read_description): Add case for
37 X86_XSTATE_AVX_MPX_MASK.
38 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
39 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
40 init_registers_i386_avx_mpx_linux.
41 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
42 (initialize_low_tracepoint): Call
43 init_registers_i386_avx_mpx_linux.
44 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
45 (initialize_low_tracepoint): Call
46 init_registers_amd64_avx_mpx_linux.
47 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
48 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
49 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
52 2016-04-18 Pedro Alves <palves@redhat.com>
54 * configure: Regenerate.
56 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
58 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
59 (aarch64_emit_sub): Likewise.
61 2016-04-12 Pedro Alves <palves@redhat.com>
63 * utils.c (prepare_to_throw_exception): Delete.
65 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
67 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
69 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
71 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
73 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
75 * linux-aarch64-ipa.c: Add <elf.h> include.
76 * linux-ppc-ipa.c: Add <elf.h> include.
77 * linux-s390-ipa.c: Add <elf.h> include.
79 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
81 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
82 (get_raw_reg_ptr): Likewise.
83 (get_trace_state_variable_value_ptr): Likewise.
84 (set_trace_state_variable_value_ptr): Likewise.
85 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
88 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
89 Marcin Kościelnicki <koriakin@0x04.net>
92 * linux-ppc-low.c (emit_insns): New function.
93 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
94 (ppc_emit_prologue): New function.
95 (ppc_emit_epilogue): New function.
96 (ppc_emit_add): New function.
97 (ppc_emit_sub): New function.
98 (ppc_emit_mul): New function.
99 (ppc_emit_lsh): New function.
100 (ppc_emit_rsh_signed): New function.
101 (ppc_emit_rsh_unsigned): New function.
102 (ppc_emit_ext): New function.
103 (ppc_emit_zero_ext): New function.
104 (ppc_emit_log_not): New function.
105 (ppc_emit_bit_and): New function.
106 (ppc_emit_bit_or): New function.
107 (ppc_emit_bit_xor): New function.
108 (ppc_emit_bit_not): New function.
109 (ppc_emit_equal): New function.
110 (ppc_emit_less_signed): New function.
111 (ppc_emit_less_unsigned): New function.
112 (ppc_emit_ref): New function.
113 (ppc_emit_const): New function.
114 (ppc_emit_reg): New function.
115 (ppc_emit_pop): New function.
116 (ppc_emit_stack_flush): New function.
117 (ppc_emit_swap): New function.
118 (ppc_emit_stack_adjust): New function.
119 (ppc_emit_call): New function.
120 (ppc_emit_int_call_1): New function.
121 (ppc_emit_void_call_2): New function.
122 (ppc_emit_if_goto): New function.
123 (ppc_emit_goto): New function.
124 (ppc_emit_eq_goto): New function.
125 (ppc_emit_ne_goto): New function.
126 (ppc_emit_lt_goto): New function.
127 (ppc_emit_le_goto): New function.
128 (ppc_emit_gt_goto): New function.
129 (ppc_emit_ge_goto): New function.
130 (ppc_write_goto_address): New function.
131 (ppc_emit_ops_impl): New static variable.
132 (ppc64v1_emit_prologue): New function.
133 (ppc64v2_emit_prologue): New function.
134 (ppc64_emit_epilogue): New function.
135 (ppc64_emit_add): New function.
136 (ppc64_emit_sub): New function.
137 (ppc64_emit_mul): New function.
138 (ppc64_emit_lsh): New function.
139 (ppc64_emit_rsh_signed): New function.
140 (ppc64_emit_rsh_unsigned): New function.
141 (ppc64_emit_ext): New function.
142 (ppc64_emit_zero_ext): New function.
143 (ppc64_emit_log_not): New function.
144 (ppc64_emit_bit_and): New function.
145 (ppc64_emit_bit_or): New function.
146 (ppc64_emit_bit_xor): New function.
147 (ppc64_emit_bit_not): New function.
148 (ppc64_emit_equal): New function.
149 (ppc64_emit_less_signed): New function.
150 (ppc64_emit_less_unsigned): New function.
151 (ppc64_emit_ref): New function.
152 (ppc64_emit_const): New function.
153 (ppc64v1_emit_reg): New function.
154 (ppc64v2_emit_reg): New function.
155 (ppc64_emit_pop): New function.
156 (ppc64_emit_stack_flush): New function.
157 (ppc64_emit_swap): New function.
158 (ppc64v1_emit_call): New function.
159 (ppc64v2_emit_call): New function.
160 (ppc64v1_emit_int_call_1): New function.
161 (ppc64v2_emit_int_call_1): New function.
162 (ppc64v1_emit_void_call_2): New function.
163 (ppc64v2_emit_void_call_2): New function.
164 (ppc64_emit_if_goto): New function.
165 (ppc64_emit_eq_goto): New function.
166 (ppc64_emit_ne_goto): New function.
167 (ppc64_emit_lt_goto): New function.
168 (ppc64_emit_le_goto): New function.
169 (ppc64_emit_gt_goto): New function.
170 (ppc64_emit_ge_goto): New function.
171 (ppc64v1_emit_ops_impl): New static variable.
172 (ppc64v2_emit_ops_impl): New static variable.
173 (ppc_emit_ops): New function.
174 (linux_low_target): Wire in ppc_emit_ops.
176 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
177 Marcin Kościelnicki <koriakin@0x04.net>
180 * Makefile.in: Add powerpc-*-ipa.o
181 * configure.srv: Add ipa_obj for powerpc*-linux.
182 * linux-ppc-ipa.c: New file.
183 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
185 (PPC_FIELD): New macro.
186 (PPC_SEXT): New macro.
187 (PPC_OP6): New macro.
191 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
192 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
193 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
194 (ppc_get_thread_area): New function.
195 (is_elfv2_inferior): New function.
196 (gen_ds_form): New function.
197 (GEN_STD): New macro.
198 (GEN_STDU): New macro.
200 (GEN_LDU): New macro.
201 (gen_d_form): New function.
202 (GEN_ADDI): New macro.
203 (GEN_ADDIS): New macro.
205 (GEN_LIS): New macro.
206 (GEN_ORI): New macro.
207 (GEN_ORIS): New macro.
208 (GEN_LWZ): New macro.
209 (GEN_STW): New macro.
210 (GEN_STWU): New macro.
211 (gen_xfx_form): New function.
212 (GEN_MFSPR): New macro.
213 (GEN_MTSPR): New macro.
214 (GEN_MFCR): New macro.
215 (GEN_MTCR): New macro.
216 (GEN_SYNC): New macro.
217 (GEN_LWSYNC): New macro.
218 (gen_x_form): New function.
221 (GEN_LWARX): New macro.
222 (GEN_STWCX): New macro.
223 (GEN_CMPW): New macro.
224 (gen_md_form): New function.
225 (GEN_RLDICL): New macro.
226 (GEN_RLDICR): New macro.
227 (gen_i_form): New function.
230 (gen_b_form): New function.
231 (GEN_BNE): New macro.
232 (GEN_LOAD): New macro.
233 (GEN_STORE): New macro.
234 (gen_limm): New function.
235 (gen_atomic_xchg): New function.
236 (gen_call): New function.
237 (ppc_relocate_instruction): New function.
238 (ppc_install_fast_tracepoint_jump_pad): New function.
239 (ppc_get_min_fast_tracepoint_insn_len): New function.
240 (ppc_get_ipa_tdesc_idx): New function.
241 (the_low_target): Wire in the new functions.
242 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
244 * linux-ppc-tdesc.h: New file.
246 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
248 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
249 (alloc_jump_pad_buffer): New function.
250 * linux-amd64-ipa.c: Add <sys/mman.h> include.
251 (alloc_jump_pad_buffer): New function.
252 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
253 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
254 (alloc_jump_pad_buffer): New function.
255 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
256 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
257 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
258 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
260 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
262 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
263 * linux-amd64-ipa.c: Likewise.
264 * linux-i386-ipa.c: Likewise.
265 * linux-s390-ipa.c: Likewise.
266 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
267 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
268 set_trace_state_variable_value_ptr.
269 (struct ipa_sym_addresses): Likewise.
270 (symbol_list): Likewise.
271 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
272 accessing gdb_collect directly.
273 (gdb_collect_ptr_type): New typedef.
274 (get_raw_reg_ptr_type): New typedef.
275 (get_trace_state_variable_value_ptr_type): New typedef.
276 (set_trace_state_variable_value_ptr_type): New typedef.
277 (gdb_collect_ptr): New global.
278 (get_raw_reg_ptr): New global.
279 (get_trace_state_variable_value_ptr): New global.
280 (set_trace_state_variable_value_ptr): New global.
281 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
282 accessing get_raw_reg directly.
283 (get_get_tsv_func_addr): Likewise for
284 get_trace_state_variable_value_ptr.
285 (get_set_tsv_func_addr): Likewise for
286 set_trace_state_variable_value_ptr.
287 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
289 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
291 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
293 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
295 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
297 (relocate_instruction): Remove own_buf.
298 * server.c (own_buf): Make global.
299 (handle_v_requests): Make global.
300 * server.h (own_buf): New declaration.
301 (handle_v_requests): New prototype.
303 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
306 * linux-s390-low.c (add_insns): New function.
307 (s390_emit_prologue): New function.
308 (s390_emit_epilogue): New function.
309 (s390_emit_add): New function.
310 (s390_emit_sub): New function.
311 (s390_emit_mul): New function.
312 (s390_emit_lsh): New function.
313 (s390_emit_rsh_signed): New function.
314 (s390_emit_rsh_unsigned): New function.
315 (s390_emit_ext): New function.
316 (s390_emit_log_not): New function.
317 (s390_emit_bit_and): New function.
318 (s390_emit_bit_or): New function.
319 (s390_emit_bit_xor): New function.
320 (s390_emit_bit_not): New function.
321 (s390_emit_equal): New function.
322 (s390_emit_less_signed): New function.
323 (s390_emit_less_unsigned): New function.
324 (s390_emit_ref): New function.
325 (s390_emit_if_goto): New function.
326 (s390_emit_goto): New function.
327 (s390_write_goto_address): New function.
328 (s390_emit_litpool): New function.
329 (s390_emit_const): New function.
330 (s390_emit_call): New function.
331 (s390_emit_reg): New function.
332 (s390_emit_pop): New function.
333 (s390_emit_stack_flush): New function.
334 (s390_emit_zero_ext): New function.
335 (s390_emit_swap): New function.
336 (s390_emit_stack_adjust): New function.
337 (s390_emit_set_r2): New function.
338 (s390_emit_int_call_1): New function.
339 (s390_emit_void_call_2): New function.
340 (s390_emit_eq_goto): New function.
341 (s390_emit_ne_goto): New function.
342 (s390_emit_lt_goto): New function.
343 (s390_emit_le_goto): New function.
344 (s390_emit_gt_goto): New function.
345 (s390_emit_ge_goto): New function.
346 (s390x_emit_prologue): New function.
347 (s390x_emit_epilogue): New function.
348 (s390x_emit_add): New function.
349 (s390x_emit_sub): New function.
350 (s390x_emit_mul): New function.
351 (s390x_emit_lsh): New function.
352 (s390x_emit_rsh_signed): New function.
353 (s390x_emit_rsh_unsigned): New function.
354 (s390x_emit_ext): New function.
355 (s390x_emit_log_not): New function.
356 (s390x_emit_bit_and): New function.
357 (s390x_emit_bit_or): New function.
358 (s390x_emit_bit_xor): New function.
359 (s390x_emit_bit_not): New function.
360 (s390x_emit_equal): New function.
361 (s390x_emit_less_signed): New function.
362 (s390x_emit_less_unsigned): New function.
363 (s390x_emit_ref): New function.
364 (s390x_emit_if_goto): New function.
365 (s390x_emit_const): New function.
366 (s390x_emit_call): New function.
367 (s390x_emit_reg): New function.
368 (s390x_emit_pop): New function.
369 (s390x_emit_stack_flush): New function.
370 (s390x_emit_zero_ext): New function.
371 (s390x_emit_swap): New function.
372 (s390x_emit_stack_adjust): New function.
373 (s390x_emit_int_call_1): New function.
374 (s390x_emit_void_call_2): New function.
375 (s390x_emit_eq_goto): New function.
376 (s390x_emit_ne_goto): New function.
377 (s390x_emit_lt_goto): New function.
378 (s390x_emit_le_goto): New function.
379 (s390x_emit_gt_goto): New function.
380 (s390x_emit_ge_goto): New function.
381 (s390_emit_ops): New function.
382 (struct linux_target_ops): Fill in emit_ops hook.
384 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
387 * Makefile.in: Add s390 IPA files.
388 * configure.srv: Build IPA for s390.
389 * linux-s390-ipa.c: New file.
390 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
391 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
392 (tdesc_s390_linux32): Likewise.
393 (init_registers_s390_linux32v1): Likewise.
394 (tdesc_s390_linux32v1): Likewise.
395 (init_registers_s390_linux32v2): Likewise.
396 (tdesc_s390_linux32v2): Likewise.
397 (init_registers_s390_linux64): Likewise.
398 (tdesc_s390_linux64): Likewise.
399 (init_registers_s390_linux64v1): Likewise.
400 (tdesc_s390_linux64v1): Likewise.
401 (init_registers_s390_linux64v2): Likewise.
402 (tdesc_s390_linux64v2): Likewise.
403 (init_registers_s390_te_linux64): Likewise.
404 (tdesc_s390_te_linux64): Likewise.
405 (init_registers_s390_vx_linux64): Likewise.
406 (tdesc_s390_vx_linux64): Likewise.
407 (init_registers_s390_tevx_linux64): Likewise.
408 (tdesc_s390_tevx_linux64): Likewise.
409 (init_registers_s390x_linux64): Likewise.
410 (tdesc_s390x_linux64): Likewise.
411 (init_registers_s390x_linux64v1): Likewise.
412 (tdesc_s390x_linux64v1): Likewise.
413 (init_registers_s390x_linux64v2): Likewise.
414 (tdesc_s390x_linux64v2): Likewise.
415 (init_registers_s390x_te_linux64): Likewise.
416 (tdesc_s390x_te_linux64): Likewise.
417 (init_registers_s390x_vx_linux64): Likewise.
418 (tdesc_s390x_vx_linux64): Likewise.
419 (init_registers_s390x_tevx_linux64): Likewise.
420 (tdesc_s390x_tevx_linux64): Likewise.
421 (have_hwcap_s390_vx): New static variable.
422 (s390_arch_setup): Fill have_hwcap_s390_vx.
423 (s390_get_thread_area): New function.
424 (s390_ft_entry_gpr_esa): New const.
425 (s390_ft_entry_gpr_zarch): New const.
426 (s390_ft_entry_misc): New const.
427 (s390_ft_entry_fr): New const.
428 (s390_ft_entry_vr): New const.
429 (s390_ft_main_31): New const.
430 (s390_ft_main_64): New const.
431 (s390_ft_exit_fr): New const.
432 (s390_ft_exit_vr): New const.
433 (s390_ft_exit_misc): New const.
434 (s390_ft_exit_gpr_esa): New const.
435 (s390_ft_exit_gpr_zarch): New const.
436 (append_insns): New function.
437 (s390_relocate_instruction): New function.
438 (s390_install_fast_tracepoint_jump_pad): New function.
439 (s390_get_min_fast_tracepoint_insn_len): New function.
440 (s390_get_ipa_tdesc_idx): New function.
441 (struct linux_target_ops): Wire in the above functions.
442 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
443 * linux-s390-tdesc.h: New file.
445 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
447 * linux-s390-low.c (s390_supports_tracepoints): New function.
448 (struct linux_target_ops): Fill supports_tracepoints hook.
450 2016-03-18 Yao Qi <yao.qi@linaro.org>
452 * linux-low.c (lwp_signal_can_be_delivered): New function.
453 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
455 2016-03-18 Yao Qi <yao.qi@linaro.org>
457 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
458 0 if signal is enqueued. Remove 'signal' from one debugging
459 message. Move one debugging message to some lines below.
460 Remove code setting 'signal' to 0.
462 2016-03-18 Yao Qi <yao.qi@linaro.org>
464 * linux-low.c (linux_low_filter_event): Remove redundant
465 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
467 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
469 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
470 (struct linux_target_ops): Wire in the above.
472 2016-03-03 Yao Qi <yao.qi@linaro.org>
474 * linux-low.c: Update comments to start_step_over.
476 2016-03-03 Yao Qi <yao.qi@linaro.org>
479 * linux-low.c (handle_extended_wait): Set child suspended
480 if event_lwp->bp_reinsert isn't zero.
482 2016-03-02 Yao Qi <yao.qi@linaro.org>
484 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
485 enqueue_pending_signal.
487 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
489 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
492 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
494 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
495 (s390_regmap_3264) [!__s390x__]: New global.
496 (s390_collect_ptrace_register): Skip map entries containing -1.
497 (s390_supply_ptrace_register): Ditto.
498 (s390_fill_gprs_high): New function.
499 (s390_store_gprs_high): New function.
500 (s390_regsets): Add NT_S390_HIGH_GPRS.
501 (s390_get_hwcap): Enable on 31-bit.
502 (have_hwcap_s390_high_gprs): Enable on 31-bit.
503 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
504 Detect NT_S390_HIGH_GPRS.
505 (s390_usrregs_info_3264): Enable on 31-bit.
506 (s390_regs_info): Enable regs_info_3264 on 31-bit.
507 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
509 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
512 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
513 * configure.srv: Ditto.
514 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
515 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
516 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
517 (init_registers_amd64_linux): Remove prototype.
518 (tdesc_amd64_linux): Remove declaration.
519 (get_ipa_tdesc): New function.
520 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
521 initialize remaining tdescs.
522 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
523 (init_registers_i386_linux): Remove prototype.
524 (tdesc_i386_linux): Remove declaration.
525 (get_ipa_tdesc): New function.
526 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
527 initialize remaining tdescs.
528 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
529 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
530 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
531 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
532 (x86_get_ipa_tdesc_idx): New function.
533 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
534 * linux-x86-tdesc.h: New file.
535 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
536 (target_get_ipa_tdesc_idx): New macro.
537 * tracepoint.c (ipa_tdesc_idx): New macro.
538 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
539 (symbol_list): Add ipa_tdesc_idx.
540 (cmd_qtstart): Write ipa_tdesc_idx in the target.
542 (ipa_tdesc_idx): New variable.
543 (get_context_regcache): Use get_ipa_tdesc.
544 (gdb_collect): Ditto.
546 * tracepoint.h (get_ipa_tdesc): New prototype.
549 2016-02-24 Pedro Alves <palves@redhat.com>
551 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
552 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
553 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
554 Factor out common code between the USE_SIGTRAP_SIGINFO and
555 !USE_SIGTRAP_SIGINFO blocks.
556 (linux_low_filter_event): Call save_stop_reason instead of
557 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
559 (linux_wait_1): Update comments.
561 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
563 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
564 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
565 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
566 ppc_insert_point, ppc_remove_point.
568 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
570 * linux-s390-low.c (s390_supports_z_point_type): New function.
571 (struct linux_target_ops): Wire s390_supports_z_point_type in.
573 2016-02-16 Yao Qi <yao.qi@linaro.org>
575 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
576 PC. Get pc from regcache_read_pc.
578 2016-02-12 Yao Qi <yao.qi@linaro.org>
580 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
581 or linux_get_pc_32bit.
582 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
584 2016-02-12 Yao Qi <yao.qi@linaro.org>
586 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
587 arm_linux_get_next_pcs_fixup.
589 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
591 * tracepoint.c (x_tracepoint_action_download): Change
592 write_inferior_data_ptr to write_inferior_data_pointer.
593 (cmd_qtstart): Likewise.
594 (write_inferior_data_ptr): Remove.
595 (download_agent_expr): Change write_inferior_data_ptr to
596 write_inferior_data_pointer.
597 (download_tracepoint_1): Likewise.
598 (download_tracepoint): Likewise.
599 (download_trace_state_variables): Likewise.
601 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
602 Marcin Kościelnicki <koriakin@0x04.net>
604 * tracepoint.c (struct tracepoint_action_ops): Remove.
605 (struct tracepoint_action): Remove ops.
606 (m_tracepoint_action_download, r_tracepoint_action_download)
607 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
608 size and offset accordingly.
609 (m_tracepoint_action_ops, r_tracepoint_action_ops)
610 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
611 (tracepoint_action_send, tracepoint_action_download): New functions.
612 Helpers for trace action handlers.
613 (add_tracepoint_action): Remove setup actions ops.
614 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
616 2016-02-10 Yao Qi <yao.qi@linaro.org>
618 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
620 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
622 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
624 * configure: Regenerate.
626 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
628 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
629 void * to gdb_byte *.
630 * linux-low.c (siginfo_fixup): Likewise.
631 (linux_xfer_siginfo): Likewise.
632 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
634 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
636 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
638 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
640 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
642 * linux-x86-low.c [__x86_64__]: Include
643 "nat/amd64-linux-siginfo.h".
644 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
645 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
646 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
647 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
648 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
649 (cpt_si_fd, si_timerid, si_overrun): Move from
650 nat/amd64-linux-siginfo.c.
651 * Makefile.in (amd64-linux-siginfo.o:): New rule.
653 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
655 * server.c (skip_to_semicolon): Remove.
656 (process_point_options): Use strchrnul instead of
659 2016-01-26 Yao Qi <yao.qi@linaro.org>
661 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
662 * linux-low.c (install_software_single_step_breakpoints): Don't
663 call regcache_read_pc.
664 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
667 2016-01-26 Yao Qi <yao.qi@linaro.org>
669 * linux-low.c (install_software_single_step_breakpoints): Call
670 regcache_read_pc instead of get_pc.
672 2016-01-26 Yao Qi <yao.qi@linaro.org>
674 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
675 (unblock_async_io): Rename to ...
676 (block_unblock_async_io): ... it. New function.
677 (enable_async_io): Don't install SIGIO handler. Unblock it
679 (disable_async_io): Don't ignore SIGIO. Block it instead.
680 (initialize_async_io): Install SIGIO handler. Don't call
683 2016-01-26 Yao Qi <yao.qi@linaro.org>
685 * remote-utils.c (getpkt): If the buffer isn't empty, and the
686 first character is '\003', call *the_target->request_interrupt.
688 2016-01-25 Yao Qi <yao.qi@linaro.org>
690 * remote-utils.c (new_thread_notify): Remove.
691 (dead_thread_notify): Likewise.
692 * remote-utils.h (new_thread_notify): Remove declaration.
693 (dead_thread_notify): Likewise.
695 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
697 * gdb.trace/pending.exp: Fix expected message on continue.
699 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
701 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
702 it works properly on big-endian machines where sizeof (CORE_ADDR)
705 2016-01-21 Pedro Alves <palves@redhat.com>
707 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
708 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
709 * configure: Regenerate.
711 2016-01-21 Yao Qi <yao.qi@linaro.org>
713 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
714 is_thumb and set it according to CPSR saved on the stack.
715 (get_next_pcs_syscall_next_pc): Pass is_thumb to
716 arm_sigreturn_next_pc.
718 2016-01-18 Yao Qi <yao.qi@linaro.org>
720 * linux-low.c (linux_set_pc_64bit): New function.
721 (linux_get_pc_64bit): New function.
722 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
724 * linux-sparc-low.c (debug_threads): Remove declaration.
725 (sparc_get_pc): Remove.
726 (the_low_target): Use linux_get_pc_64bit instead of
728 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
729 (the_low_target): Use linux_get_pc_64bit and
732 2016-01-18 Yao Qi <yao.qi@linaro.org>
734 * linux-arm-low.c (debug_threads): Remove declaration.
735 (arm_get_pc, arm_set_pc): Remove.
736 (the_low_target): Use linux_get_pc_32bit and
738 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
739 (the_low_target): Use linux_get_pc_32bit and
741 * linux-cris-low.c (debug_threads): Remove declaration.
742 (cris_get_pc, cris_set_pc,): Remove.
743 (the_low_target): Use linux_get_pc_32bit and
745 * linux-crisv32-low.c (debug_threads): Remove declaration.
746 (cris_get_pc, cris_set_pc): Remove.
747 (the_low_target): Use linux_get_pc_32bit and
749 * linux-low.c: Include inttypes.h.
750 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
751 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
752 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
753 (the_low_target): Use linux_get_pc_32bit and
755 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
756 (the_low_target): Use linux_get_pc_32bit and
758 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
759 (the_low_target): Use linux_get_pc_32bit and
761 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
762 (the_low_target): Use linux_get_pc_32bit and
764 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
765 (the_low_target): Use linux_get_pc_32bit and
768 2016-01-18 Gary Benson <gbenson@redhat.com>
770 * configure.ac (AC_FUNC_FORK): New check.
771 * config.in: Regenerate.
772 * configure: Likewise.
774 2016-01-14 Yao Qi <yao.qi@linaro.org>
776 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
777 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
778 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
779 arm_get_next_pcs_ctor.
781 2016-01-12 Josh Stone <jistone@redhat.com>
782 Philippe Waroquiers <philippe.waroquiers@skynet.be>
784 * inferiors.h: Include "gdb_vecs.h".
785 (struct process_info): Add syscalls_to_catch.
786 * inferiors.c (remove_process): Free syscalls_to_catch.
787 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
788 syscall_return stops.
789 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
790 * server.c (handle_general_set): Handle QCatchSyscalls.
791 (handle_query): Report support for QCatchSyscalls.
792 * target.h (struct target_ops): Add supports_catch_syscall.
793 (target_supports_catch_syscall): New macro.
794 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
795 (struct lwp_info): Add syscall_state.
796 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
797 Maintain syscall_state and syscalls_to_catch across exec.
798 (get_syscall_trapinfo): New function, proxy to the_low_target.
799 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
800 (linux_low_filter_event): Toggle syscall_state entry/return for
801 syscall traps, and set it ignored for all others.
802 (gdb_catching_syscalls_p): New function.
803 (gdb_catch_this_syscall_p): New function.
804 (linux_wait_1): Handle SYSCALL_SIGTRAP.
805 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
806 (linux_supports_catch_syscall): New function.
807 (linux_target_ops): Install it.
808 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
809 (the_low_target): Install it.
811 2016-01-12 Mike Frysinger <vapier@gentoo.org>
813 * acinclude.m4: Include new ../warning.m4 file.
814 * configure: Regenerated.
815 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
817 2016-01-12 Mike Frysinger <vapier@gentoo.org>
819 * ax.c (is_goto_target): Mark static.
820 * linux-low.c (register_addr): Likewise.
821 (linux_fetch_registers, linux_store_registers): Likewise.
822 * mem-break.c (any_persistent_commands): Fix old prototype.
823 (add_commands_to_breakpoint): Mark static.
824 * regcache.c (find_register_by_name): Delete unused func.
825 * remote-utils.c (hex_or_minus_one): Mark static.
826 * server.c (monitor_show_help): Mark static.
827 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
828 handle_v_requests): Likewise.
830 2016-01-12 Pedro Alves <palves@redhat.com>
832 Remove use of the registered trademark symbol throughout.
834 2016-01-08 Yao Qi <yao.qi@linaro.org>
836 * remote-utils.c (getpkt): If c is '\003', call target hook
839 2016-01-06 Yao Qi <yao.qi@linaro.org>
841 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
843 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
844 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
845 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
846 (thumb2_breakpoint): Declare.
847 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
849 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
850 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
851 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
853 2016-01-01 Joel Brobecker <brobecker@adacore.com>
855 * gdbreplay.c (gdbreplay_version): Change copyright year in
857 * server.c (gdbserver_version): Likewise.
859 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
861 * server.c (crc32_table): Delete.
862 (crc32): Use libiberty's xcrc32 function.
864 2015-12-22 Joel Brobecker <brobecker@adacore.com>
866 * lynx-low.c (lynx_delete_thread_callback): New function.
867 (lynx_mourn): Properly delete our process and all of its
868 threads. Remove call to clear_inferiors.
870 2015-12-22 Joel Brobecker <brobecker@adacore.com>
872 * target.c (thread_search_callback): Add check that
873 the thread_stopped target callback is not NULL before
876 2015-12-21 Yao Qi <yao.qi@linaro.org>
878 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
881 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
883 * server.c (handle_query): Call target_supports_software_single_step.
885 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
887 * linux-low.c (single_step): New function.
888 (linux_resume_one_lwp_throw): Call single_step.
889 (start_step_over): Likewise.
891 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
893 * Makefile.in (SFILES): Append arch/arm-linux.c,
894 arch/arm-get-next-pcs.c.
895 (arm-linux.o): New rule.
896 (arm-get-next-pcs.o): New rule.
897 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
899 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
900 to linux-aarch32-low.c.
901 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
902 (arm_breakpoint_len, thumb_breakpoint): Likewise.
903 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
904 (thumb2_breakpoint_len): Likewise.
905 (arm_is_thumb_mode): Make non-static.
906 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
907 from linux-aarch32-low.c.
908 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
909 (arm_breakpoint_len, thumb_breakpoint): Likewise.
910 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
911 (thumb2_breakpoint_len): Likewise.
912 (arm_is_thumb_mode): New declaration.
913 * linux-arm-low.c: Include arch/arm-linux.h
914 aarch/arm-get-next-pcs.h, sys/syscall.h.
915 (get_next_pcs_ops): New struct.
916 (get_next_pcs_addr_bits_remove): New function.
917 (get_next_pcs_is_thumb): New function.
918 (get_next_pcs_read_memory_unsigned_integer): Likewise.
919 (arm_sigreturn_next_pc): Likewise.
920 (get_next_pcs_syscall_next_pc): Likewise.
921 (arm_gdbserver_get_next_pcs): Likewise.
922 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
924 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
925 * server.h: Include gdb_vecs.h.
927 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
929 * Makefile.in (SFILES): Append common/common-regcache.c.
930 (OBS): Append common-regcache.o.
931 (common-regcache.o): New rule.
932 * regcache.c (init_register_cache): Initialize cache to
934 (regcache_raw_read_unsigned): New function.
935 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
936 register_status enum.
938 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
940 * linux-aarch64-low.c (the_low_targets): Rename
941 breakpoint_reinsert_addr to get_next_pcs.
942 * linux-arm-low.c (the_low_targets): Likewise.
943 * linux-bfin-low.c (the_low_targets): Likewise.
944 * linux-cris-low.c (the_low_targets): Likewise.
945 * linux-crisv32-low.c (the_low_targets): Likewise.
946 * linux-low.c (can_software_single_step): Likewise.
947 (install_software_single_step_breakpoints): New function.
948 (start_step_over): Use install_software_single_step_breakpoints.
949 * linux-low.h: New CORE_ADDR vector.
950 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
952 * linux-mips-low.c (the_low_targets): Likewise.
953 * linux-nios2-low.c (the_low_targets): Likewise.
954 * linux-sparc-low.c (the_low_targets): Likewise.
956 2015-12-17 Pedro Alves <palves@redhat.com>
958 * linux-low.c (linux_kill_one_lwp): Remove references to
960 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
962 (linux_init_signals): Delete.
963 (initialize_low): Adjust.
964 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
966 2015-12-16 Pedro Alves <palves@redhat.com>
968 * configure.ac (compiler warning flags): When testing a
969 -Wno-foo option, check whether -Wfoo works instead.
970 * configure: Regenerate.
972 2015-12-11 Don Breazeal <donb@codesourcery.com>
974 * server.c (process_serial_event): Don't exit from gdbserver
975 in remote mode if there are still active inferiors.
977 2015-12-11 Yao Qi <yao.qi@linaro.org>
979 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
980 arm_breakpoint_at if the process is 32-bit.
982 2015-12-11 Yao Qi <yao.qi@linaro.org>
984 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
987 2015-12-07 Yao Qi <yao.qi@linaro.org>
989 * configure.srv: Append arm.o to srv_tgtobj for
990 aarch64*-*-linux* target.
991 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
992 from linux-arm-low.c.
993 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
994 (arm_breakpoint_len, thumb_breakpoint): Likewise.
995 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
996 (thumb2_breakpoint_len): Likewise.
997 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
998 (arm_breakpoint_kinds): Likewise.
999 (arm_breakpoint_kind_from_pc): Likewise.
1000 (arm_sw_breakpoint_from_kind): Likewise.
1001 (arm_breakpoint_kind_from_current_state): Likewise.
1002 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
1003 (arm_sw_breakpoint_from_kind): Declare.
1004 (arm_breakpoint_kind_from_current_state): Declare.
1005 (arm_breakpoint_at): Declare.
1006 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
1007 arm_sw_breakpoint_from_kind if process is 32-bit.
1008 (aarch64_breakpoint_kind_from_pc): New function.
1009 (aarch64_breakpoint_kind_from_current_state): New function.
1010 (the_low_target): Initialize fields breakpoint_kind_from_pc
1011 and breakpoint_kind_from_current_state.
1012 * linux-arm-low.c (arm_breakpoint_kinds): Move to
1013 linux-aarch32-low.c.
1014 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
1015 (arm_breakpoint, arm_breakpoint_len): Likewise.
1016 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
1017 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
1018 (arm_is_thumb_mode): Likewise.
1019 (arm_breakpoint_at): Likewise.
1020 (arm_breakpoint_kind_from_pc): Likewise.
1021 (arm_sw_breakpoint_from_kind): Likewise.
1022 (arm_breakpoint_kind_from_current_state): Likewise.
1025 2015-08-04 Yao Qi <yao.qi@linaro.org>
1027 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
1028 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
1029 * server.c (extended_protocol): Remove "static".
1030 * server.h (extended_protocol): Declare it.
1032 2015-12-04 Josh Stone <jistone@redhat.com>
1034 * target.h (struct target_ops) <arch_setup>: Rename to ...
1035 (struct target_ops) <post_create_inferior>: ... this.
1036 (target_arch_setup): Rename to ...
1037 (target_post_create_inferior): ... this, calling post_create_inferior.
1038 * server.c (start_inferior): Update target_arch_setup calls to
1039 target_post_create_inferior.
1040 * linux-low.c (linux_low_ptrace_options): Forward declare.
1041 (linux_arch_setup): Update its comment for general use.
1042 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
1043 (struct linux_target_ops): Use linux_post_create_inferior.
1044 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
1045 to post_create_inferior.
1046 * nto-low.c (struct nto_target_ops): Likewise.
1047 * spu-low.c (struct spu_target_ops): Likewise.
1048 * win32-low.c (struct win32_target_ops): Likewise.
1050 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
1052 * linux-arm-low.c: Remove duplicate arch/arm.h include.
1054 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
1056 * linux-arm-low.c (arm_reinsert_addr): Remove function.
1057 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
1058 * linux-cris-low.c (cris_reinsert_addr> Remove function.
1059 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
1060 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
1061 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
1062 * linux-mips-low.c (mips_reinsert_addr): Remove function.
1063 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
1064 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
1065 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
1066 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
1067 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
1069 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
1071 * linux-low.c (linux_look_up_symbols): Don't call
1072 linux_supports_traceclone.
1073 * linux-low.h (thread_db_init): Remove use_events argument.
1074 * thread-db.c (thread_db_use_event): Remove global variable.
1075 (struct thread_db) <td_thr_event_enable_p>: Remove field.
1076 (struct thread_db) <td_create_bp>: Remove field.
1077 (thread_db_create_event): Remove function.
1078 (thread_db_enable_reporting): Likewise.
1079 (find_one_thread): Don't check for thread_db_use_events.
1080 (attach_thread): Likewise.
1081 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
1082 (try_thread_db_load_1): Don't check for thread_db_use_events.
1083 (thread_db_init): Remove use_events argument and thread events
1085 (remove_thread_event_breakpoints): Remove function.
1086 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
1088 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
1090 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
1092 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1093 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
1094 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1095 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
1096 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
1098 * linux-crisv32-low.c (cris_supports_hardware_single_step):
1100 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1101 * linux-low.c (can_hardware_single_step): Use
1102 supports_hardware_single_step.
1103 (can_software_single_step): New function.
1104 (start_step_over): Call can_software_single_step.
1105 (linux_supports_hardware_single_step): New function.
1106 (struct target_ops) <supports_software_single_step>: Initialize.
1107 * linux-low.h (struct linux_target_ops)
1108 <supports_hardware_single_step>: Initialize.
1109 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
1110 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1111 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
1112 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
1113 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
1114 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1115 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
1116 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1117 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
1118 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
1120 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
1121 (struct linux_target_ops) <tile_supports_hardware_single_step>:
1123 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
1124 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1125 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
1127 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1128 * target.h (struct target_ops): <supports_software_single_step>:
1130 (target_supports_software_single_step): New macro.
1132 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
1134 * linux-low.c (linux_wait_1): Fix pc advance condition.
1135 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
1136 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
1138 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
1140 * linux-arm-low.c (arm_is_thumb_mode): New function.
1141 (arm_breakpoint_at): Use arm_is_thumb_mode.
1142 (arm_breakpoint_kind_from_current_state): New function.
1143 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
1145 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
1146 (linux_breakpoint_kind_from_current_state): New function.
1147 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
1148 * linux-low.h (struct linux_target_ops)
1149 <breakpoint_kind_from_current_state>: New field.
1150 * target.h (struct target_ops): Likewise.
1151 (target_breakpoint_kind_from_current_state): New macro.
1153 2015-11-30 Pedro Alves <palves@redhat.com>
1155 * linux-low.c (linux_resume): Wake up the event loop before
1158 2015-11-30 Pedro Alves <palves@redhat.com>
1160 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
1162 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
1164 * target.c (struct thread_search): New structure.
1165 (thread_search_callback): New function.
1166 (prev_general_thread): New global.
1167 (prepare_to_access_memory, done_accessing_memory): New functions.
1168 * target.h (prepare_to_access_memory, done_accessing_memory):
1169 Replace macros with function declarations.
1171 2015-11-30 Pedro Alves <palves@redhat.com>
1174 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
1175 report TARGET_WAITKIND_NO_RESUMED.
1176 * remote-utils.c (prepare_resume_reply): Handle
1177 TARGET_WAITKIND_NO_RESUMED.
1178 * server.c (report_no_resumed): New global.
1179 (handle_query) <qSupported>: Handle "no-resumed+". Report
1180 "no-resumed+" support.
1181 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
1182 return error if the client doesn't support no-resumed events.
1183 (push_stop_notification): New function.
1184 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
1185 events if the client supports them.
1187 2015-11-30 Pedro Alves <palves@redhat.com>
1189 * linux-low.c (thread_still_has_status_pending_p): Don't check
1191 (lwp_resumed): New function.
1192 (status_pending_p_callback): Return early if the LWP is not
1193 supposed to be resumed.
1195 2015-11-30 Pedro Alves <palves@redhat.com>
1197 * linux-low.c (handle_extended_wait): Assert that the LWP's
1198 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
1199 thread create events, leave the new child's status pending.
1200 (linux_low_filter_event): If GDB wants to hear about thread exit
1201 events, leave the LWP marked dead and don't delete it.
1202 (linux_wait_for_event_filtered): Don't check for thread exit.
1203 (filter_exit_event): New function.
1204 (linux_wait_1): Use it, when returning an exit event.
1205 (linux_resume_one_lwp_throw): Assert that the LWP's
1206 waitstatus is TARGET_WAITKIND_IGNORE.
1207 * remote-utils.c (prepare_resume_reply): Handle
1208 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
1209 * server.c (report_thread_events): New global.
1210 (handle_general_set): Handle QThreadEvents.
1211 (handle_query) <qSupported>: Handle and report QThreadEvents+;
1212 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
1213 TARGET_WAITKIND_THREAD_EXITED.
1214 * server.h (report_thread_events): Declare.
1216 2015-11-30 Pedro Alves <palves@redhat.com>
1218 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
1219 the thread's last_resume_kind was resume_stop.
1221 2015-11-30 Pedro Alves <palves@redhat.com>
1223 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
1226 2015-11-30 Pedro Alves <palves@redhat.com>
1228 * server.c (handle_v_requests): Handle vCtrlC.
1230 2015-11-30 Pedro Alves <palves@redhat.com>
1232 * gdbthread.h (find_any_thread_of_pid): Declare.
1233 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
1235 * server.c (handle_query): If current_thread is NULL, look for
1236 another thread of the selected process.
1238 2015-11-26 Daniel Colascione <dancol@dancol.org>
1239 Simon Marchi <simon.marchi@ericsson.com>
1241 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
1242 * server.c (handle_qxfer_threads_worker): Refactor to include thread
1244 * target.h (struct target_ops) <thread_name>: New field.
1245 (target_thread_name): New macro.
1247 2015-11-23 Joel Brobecker <brobecker@adacore.com>
1249 * regcache.h (regcache_invalidate_pid): Add declaration.
1250 * regcache.c (regcache_invalidate_pid): New function, extracted
1251 from regcache_invalidate.
1252 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
1253 Add trivial documentation comment.
1254 * lynx-low.c: Use regcache_invalidate_pid instead of
1255 regcache_invalidate.
1257 2015-11-23 Joel Brobecker <brobecker@adacore.com>
1259 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
1260 and Elf64_auxv_t if the target is Android.
1262 2015-11-22 Doug Evans <xdje42@gmail.com>
1264 * target.h: #include <sys/types.h>.
1266 2015-11-19 Pedro Alves <palves@redhat.com>
1268 * linux-low.c (linux_process_qsupported): Change prototype.
1270 * linux-low.h (struct linux_target_ops) <process_qsupported>:
1272 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
1273 and adjust to loop over all features.
1274 * server.c (handle_query) <qSupported>: Adjust to call
1275 target_process_qsupported once, passing it a vector of unprocessed
1277 * target.h (struct target_ops) <process_qsupported>: Change
1279 (target_process_qsupported): Adjust.
1281 2015-11-19 Pedro Alves <palves@redhat.com>
1283 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
1285 * configure: Regenerate.
1287 2015-11-19 Pedro Alves <palves@redhat.com>
1289 * configure: Regenerate.
1291 2015-11-19 Yao Qi <yao.qi@linaro.org>
1293 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
1296 2015-11-19 Yao Qi <yao.qi@linaro.org>
1298 * linux-aarch64-low.c (enum aarch64_operand_type): New.
1299 (struct aarch64_operand): Move enum out.
1301 2015-11-19 Yao Qi <yao.qi@linaro.org>
1303 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
1304 struct user_fpsimd_state *.
1305 (aarch64_store_fpregset): Likewise.
1307 2015-11-19 Yao Qi <yao.qi@linaro.org>
1309 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
1310 struct user_pt_regs *.
1311 (aarch64_store_gregset): Likewise.
1313 2015-11-18 Pedro Alves <palves@redhat.com>
1315 * Makefile.in (all_object_files): Add $IPA_OBJS.
1317 2015-11-17 Pedro Alves <palves@redhat.com>
1319 * win32-low.c (win32_resume): Use gdb_signal_from_host,
1320 GDB_SIGNAL_0 and gdb_signal_to_string.
1322 2015-11-17 Pedro Alves <palves@redhat.com>
1324 * win32-low.c (handle_output_debug_string): Remove parameter.
1325 (win32_kill): Remove our_status local and adjust call to
1326 handle_output_debug_string.
1327 (get_child_debug_event): Adjust call to
1328 handle_output_debug_string.
1330 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1332 * linux-mips-low.c (mips_fill_gregset): Add cast.
1333 (mips_store_gregset): Likewise.
1334 (mips_fill_fpregset): Likewise.
1335 (mips_store_fpregset): Likewise.
1337 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1339 * linux-mips-low.c (mips_add_watchpoint): Rename private to
1342 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1344 * linux-mips-low.c (mips_linux_new_thread): Change type of
1345 watch_type to enum target_hw_bp_type.
1347 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1349 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
1350 Change return type to arm_hwbp_type.
1352 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1354 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
1355 (arm_store_gregset): Likewise.
1356 * linux-arm-low.c (arm_get_hwcap): Likewise.
1357 (arm_read_description): Likewise.
1359 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1361 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
1363 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1365 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
1366 (ppc_fill_vsxregset): Likewise.
1367 (ppc_store_vsxregset): Likewise.
1368 (ppc_fill_vrregset): Likewise.
1369 (ppc_store_vrregset): Likewise.
1370 (ppc_fill_evrregset): Likewise.
1371 (ppc_store_evrregset): Likewise.
1373 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
1375 * linux-ppc-low.c (ppc_usrregs_info): Remove
1376 forward-declaration.
1377 (ppc_arch_setup): Move lower in file.
1379 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
1381 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
1382 (ps_pdwrite): Likewise.
1384 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
1386 * linux-arm-low.c (arm_new_thread): Move pointer dereference
1387 to after assert checks.
1389 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
1391 * proc-service.c (ps_pdread): Add/adjust casts.
1392 (ps_pdwrite): Add/adjust casts.
1394 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
1396 * server.c (handle_search_memory_1): Cast return value of
1399 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
1401 * server.c (write_qxfer_response): Change type of data to
1404 2015-10-29 Pedro Alves <palves@redhat.com>
1406 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
1408 2015-10-29 Pedro Alves <palves@redhat.com>
1410 * tracepoint.c (clear_installed_tracepoints): Add casts.
1412 2015-10-29 Pedro Alves <palves@redhat.com>
1414 * server.c (handle_v_cont, process_serial_event): Add enum
1415 gdb_signal casts to signal parsing code.
1417 2015-10-29 Pedro Alves <palves@redhat.com>
1419 * linux-low.h (NULL_REGSET): Define.
1420 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
1421 * linux-arm-low.c (arm_regsets): Likewise.
1422 * linux-crisv32-low.c (cris_regsets): Likewise.
1423 * linux-m68k-low.c (m68k_regsets): Likewise.
1424 * linux-mips-low.c (mips_regsets): Likewise.
1425 * linux-nios2-low.c (nios2_regsets): Likewise.
1426 * linux-ppc-low.c (ppc_regsets): Likewise.
1427 * linux-s390-low.c (s390_regsets): Likewise.
1428 * linux-sh-low.c (sh_regsets): Likewise.
1429 * linux-sparc-low.c (sparc_regsets): Likewise.
1430 * linux-tic6x-low.c (tic6x_regsets): Likewise.
1431 * linux-tile-low.c (tile_regsets): Likewise.
1432 * linux-x86-low.c (x86_regsets): Likewise.
1433 * linux-xtensa-low.c (xtensa_regsets): Likewise.
1435 2015-10-29 Pedro Alves <palves@redhat.com>
1437 * linux-low.h (NULL_REGSET): Define.
1438 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
1439 * linux-arm-low.c (arm_regsets): Likewise.
1440 * linux-crisv32-low.c (cris_regsets): Likewise.
1441 * linux-m68k-low.c (m68k_regsets): Likewise.
1442 * linux-mips-low.c (mips_regsets): Likewise.
1443 * linux-nios2-low.c (nios2_regsets): Likewise.
1444 * linux-ppc-low.c (ppc_regsets): Likewise.
1445 * linux-s390-low.c (s390_regsets): Likewise.
1446 * linux-sh-low.c (sh_regsets): Likewise.
1447 * linux-sparc-low.c (sparc_regsets): Likewise.
1448 * linux-tic6x-low.c (tic6x_regsets): Likewise.
1449 * linux-tile-low.c (tile_regsets): Likewise.
1450 * linux-x86-low.c (x86_regsets): Likewise.
1451 * linux-xtensa-low.c (xtensa_regsets): Likewise.
1453 2015-10-26 Doug Evans <dje@google.com>
1455 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
1457 2015-10-26 Doug Evans <dje@google.com>
1459 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
1461 2015-10-26 Doug Evans <dje@google.com>
1463 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
1465 (attach_thread, find_new_threads_callback): Ditto.
1467 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
1469 * mem-break.h (set_breakpoint_data): Remove.
1471 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
1473 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
1474 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
1475 (initialize_low): Remove set_breakpoint_data call.
1476 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
1477 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
1478 (initialize_low): Remove set_breakpoint_data call.
1479 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
1480 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
1481 (initialize_low): Remove set_breakpoint_data call.
1483 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
1485 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
1486 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
1487 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
1488 * target.h (target_breakpoint_kind_from_pc): New macro.
1490 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
1492 * linux-low.c (default_breakpoint_kind_from_pc): New function.
1493 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
1494 the default breakpoint kind.
1496 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
1498 * linux-arm-low.c (arm_supports_z_point_type): Add software
1501 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
1503 * linux-arm-low.c: Refactor breakpoint definitions.
1504 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
1505 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
1507 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
1509 * Makefile.in: Add arm.c/o.
1510 * configure.srv: Likewise.
1511 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
1512 (arm_breakpoint_kind_from_pc): New function.
1513 (arm_sw_breakpoint_from_kind): Return proper kind.
1514 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
1516 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
1518 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
1520 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
1521 (struct raw_breakpoint) <size>: Remove.
1522 (struct raw_breakpoint) <kind>: Add.
1523 (bp_size): New function.
1524 (bp_opcode): Likewise.
1525 (find_raw_breakpoint_at): Adjust for kind.
1526 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
1527 (remove_memory_breakpoint): Adjust for kind call bp_size.
1528 (set_raw_breakpoint_at): Adjust for kind.
1529 (set_breakpoint): Likewise.
1530 (set_breakpoint_at): Call breakpoint_kind_from_pc.
1531 (delete_raw_breakpoint): Adjust for kind.
1532 (delete_breakpoint): Likewise.
1533 (find_gdb_breakpoint): Likewise.
1534 (set_gdb_breakpoint_1): Likewise.
1535 (set_gdb_breakpoint): Likewise.
1536 (delete_gdb_breakpoint_1): Likewise.
1537 (delete_gdb_breakpoint): Likewise.
1538 (uninsert_raw_breakpoint): Likewise.
1539 (reinsert_raw_breakpoint): Likewise.
1540 (set_breakpoint_data): Remove.
1541 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
1542 (check_mem_read): Adjust for kind call bp_size.
1543 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
1544 (clone_one_breakpoint): Adjust for kind.
1545 * mem-break.h (set_gdb_breakpoint): Likewise.
1546 (delete_gdb_breakpoint): Likewise.
1547 * server.c (process_serial_event): Likewise.
1549 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
1551 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
1552 (struct linux_target_ops) <breakpoint>: Remove.
1553 (struct linux_target_ops) <breakpoint_len>: Remove.
1554 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1555 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1556 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
1557 (arm_sw_breakpoint_from_kind): New function.
1558 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
1559 (struct linux_target_ops) <breakpoint>: Remove.
1560 (struct linux_target_ops) <breakpoint_len>: Remove.
1561 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1562 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1563 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
1564 (struct linux_target_ops) <breakpoint>: Remove.
1565 (struct linux_target_ops) <breakpoint_len>: Remove.
1566 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1567 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1568 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
1569 (struct linux_target_ops) <breakpoint>: Remove.
1570 (struct linux_target_ops) <breakpoint_len>: Remove.
1571 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1572 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1573 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
1574 and sw_breakpoint_from_kind to increment the pc.
1575 (linux_breakpoint_kind_from_pc): New function.
1576 (linux_sw_breakpoint_from_kind): New function.
1577 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
1578 (initialize_low): Call breakpoint_kind_from_pc and
1579 sw_breakpoint_from_kind to replace breakpoint_data/len.
1580 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
1582 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
1583 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
1584 (struct linux_target_ops) <breakpoint>: Remove.
1585 (struct linux_target_ops) <breakpoint_len>: Remove.
1586 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1587 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1588 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
1589 (struct linux_target_ops) <breakpoint>: Remove.
1590 (struct linux_target_ops) <breakpoint_len>: Remove.
1591 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1592 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1593 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
1594 (struct linux_target_ops) <breakpoint>: Remove.
1595 (struct linux_target_ops) <breakpoint_len>: Remove.
1596 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1597 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1598 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
1599 (struct linux_target_ops) <breakpoint>: Remove.
1600 (struct linux_target_ops) <breakpoint_len>: Remove.
1601 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1602 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1603 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
1604 (struct linux_target_ops) <breakpoint>: Remove.
1605 (struct linux_target_ops) <breakpoint_len>: Remove.
1606 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1607 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1608 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
1609 (struct linux_target_ops) <breakpoint>: Remove.
1610 (struct linux_target_ops) <breakpoint_len>: Remove.
1611 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1612 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1613 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
1614 (struct linux_target_ops) <breakpoint>: Remove.
1615 (struct linux_target_ops) <breakpoint_len>: Remove.
1616 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1617 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1618 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
1619 (struct linux_target_ops) <breakpoint>: Remove.
1620 (struct linux_target_ops) <breakpoint_len>: Remove.
1621 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1622 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1623 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
1624 (struct linux_target_ops) <breakpoint>: Remove.
1625 (struct linux_target_ops) <breakpoint_len>: Remove.
1626 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1627 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1628 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
1629 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
1630 (struct linux_target_ops) <breakpoint>: Remove.
1631 (struct linux_target_ops) <breakpoint_len>: Remove.
1632 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1633 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1634 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
1635 (struct linux_target_ops) <breakpoint>: Remove.
1636 (struct linux_target_ops) <breakpoint_len>: Remove.
1637 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
1638 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
1640 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
1642 * linux-cris-low.c (cris_get_pc): Remove void arg.
1644 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
1646 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
1649 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
1651 * inferiors.c (thread_pid_matches_callback): New function.
1652 (find_thread_process): New function.
1653 (remove_thread): Reset current_thread.
1654 (remove_process): Assert threads have been removed first.
1656 2015-10-15 Yao Qi <yao.qi@linaro.org>
1658 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
1660 (aarch64_remove_point): Likewise.
1661 * regcache.c (regcache_register_size): New function.
1663 2015-10-12 Yao Qi <yao.qi@linaro.org>
1665 * linux-aarch64-low.c: Update all callers as emit_load_store
1666 is renamed to aarch64_emit_load_store.
1668 2015-10-12 Yao Qi <yao.qi@linaro.org>
1670 * linux-aarch64-low.c: Update all callers of function renaming
1671 from emit_insn to aarch64_emit_insn.
1673 2015-10-12 Yao Qi <yao.qi@linaro.org>
1675 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
1676 arch/aarch64-insn.h.
1677 (struct aarch64_memory_operand): Likewise.
1679 (emit_insn): Move to arch/aarch64-insn.c.
1680 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
1681 (emit_load_store): Move to arch/aarch64-insn.c.
1682 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
1683 (can_encode_int32): Remove.
1685 2015-10-12 Yao Qi <yao.qi@linaro.org>
1687 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
1688 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
1689 (aarch64_relocate_instruction): Likewise.
1690 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
1691 (struct aarch64_insn_visitor): Likewise.
1693 2015-10-12 Yao Qi <yao.qi@linaro.org>
1695 * linux-aarch64-low.c (struct aarch64_insn_data): New.
1696 (struct aarch64_insn_visitor): New.
1697 (struct aarch64_insn_relocation_data): New.
1698 (aarch64_ftrace_insn_reloc_b): New function.
1699 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
1700 (aarch64_ftrace_insn_reloc_cb): Likewise.
1701 (aarch64_ftrace_insn_reloc_tb): Likewise.
1702 (aarch64_ftrace_insn_reloc_adr): Likewise.
1703 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
1704 (aarch64_ftrace_insn_reloc_others): Likewise.
1706 (aarch64_relocate_instruction): Use visitor.
1708 2015-10-12 Yao Qi <yao.qi@linaro.org>
1710 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
1711 int. Add argument buf.
1712 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
1713 aarch64_relocate_instruction.
1715 2015-10-12 Yao Qi <yao.qi@linaro.org>
1717 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
1718 argument insn. Remove local variable insn. Don't call
1720 (aarch64_install_fast_tracepoint_jump_pad): Call
1723 2015-09-30 Yao Qi <yao.qi@linaro.org>
1725 * linux-aarch64-low.c (emit_movk): Shorten a long line.
1726 (emit_load_store_pair): Likewise.
1728 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
1730 * dll.c (match_dll): Add cast(s).
1731 (unloaded_dll): Likewise.
1732 * linux-low.c (second_thread_of_pid_p): Likewise.
1733 (delete_lwp_callback): Likewise.
1734 (count_events_callback): Likewise.
1735 (select_event_lwp_callback): Likewise.
1736 (linux_set_resume_request): Likewise.
1737 * server.c (accumulate_file_name_length): Likewise.
1738 (emit_dll_description): Likewise.
1739 (handle_qxfer_threads_worker): Likewise.
1740 (visit_actioned_threads): Likewise.
1741 * thread-db.c (any_thread_of): Likewise.
1742 * tracepoint.c (same_process_p): Likewise.
1743 (match_blocktype): Likewise.
1744 (build_traceframe_info_xml): Likewise.
1746 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
1748 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
1750 (gdb_unparse_agent_expr): Likewise.
1751 * hostio.c (require_data): Likewise.
1752 (handle_pread): Likewise.
1753 * linux-low.c (disable_regset): Likewise.
1754 (fetch_register): Likewise.
1755 (store_register): Likewise.
1756 (get_dynamic): Likewise.
1757 (linux_qxfer_libraries_svr4): Likewise.
1758 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
1759 (set_fast_tracepoint_jump): Likewise.
1760 (uninsert_fast_tracepoint_jumps_at): Likewise.
1761 (reinsert_fast_tracepoint_jumps_at): Likewise.
1762 (validate_inserted_breakpoint): Likewise.
1763 (clone_agent_expr): Likewise.
1764 * regcache.c (init_register_cache): Likewise.
1765 * remote-utils.c (putpkt_binary_1): Likewise.
1766 (decode_M_packet): Likewise.
1767 (decode_X_packet): Likewise.
1768 (look_up_one_symbol): Likewise.
1769 (relocate_instruction): Likewise.
1770 (monitor_output): Likewise.
1771 * server.c (handle_search_memory): Likewise.
1772 (handle_qxfer_exec_file): Likewise.
1773 (handle_qxfer_libraries): Likewise.
1774 (handle_qxfer): Likewise.
1775 (handle_query): Likewise.
1776 (handle_v_cont): Likewise.
1777 (handle_v_run): Likewise.
1778 (captured_main): Likewise.
1779 * target.c (write_inferior_memory): Likewise.
1780 * thread-db.c (try_thread_db_load_from_dir): Likewise.
1781 * tracepoint.c (init_trace_buffer): Likewise.
1782 (add_tracepoint_action): Likewise.
1783 (add_traceframe): Likewise.
1784 (add_traceframe_block): Likewise.
1785 (cmd_qtdpsrc): Likewise.
1786 (cmd_qtdv): Likewise.
1787 (cmd_qtstatus): Likewise.
1788 (response_source): Likewise.
1789 (response_tsv): Likewise.
1790 (cmd_qtnotes): Likewise.
1791 (gdb_collect): Likewise.
1792 (initialize_tracepoint): Likewise.
1794 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
1796 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
1797 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
1798 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
1800 (enum aarch64_condition_codes): New enum.
1801 (w0): New static global.
1804 (struct aarch64_memory_operand) <type>: New
1805 MEMORY_OPERAND_POSTINDEX type.
1806 (postindex_memory_operand): New helper function.
1807 (emit_ret): New function.
1808 (emit_load_store_pair): New function, factored out of emit_stp
1809 with support for MEMORY_OPERAND_POSTINDEX.
1810 (emit_stp): Rewrite using emit_load_store_pair.
1811 (emit_ldp): New function.
1812 (emit_load_store): Likewise.
1813 (emit_ldr): Mention post-index instruction in comment.
1814 (emit_ldrh): New function.
1815 (emit_ldrb): New function.
1816 (emit_ldrsw): Mention post-index instruction in comment.
1817 (emit_str): Likewise.
1818 (emit_subs): New function.
1819 (emit_cmp): Likewise.
1820 (emit_and): Likewise.
1821 (emit_orr): Likewise.
1822 (emit_orn): Likewise.
1823 (emit_eor): Likewise.
1824 (emit_mvn): Likewise.
1825 (emit_lslv): Likewise.
1826 (emit_lsrv): Likewise.
1827 (emit_asrv): Likewise.
1828 (emit_mul): Likewise.
1829 (emit_sbfm): Likewise.
1830 (emit_sbfx): Likewise.
1831 (emit_ubfm): Likewise.
1832 (emit_ubfx): Likewise.
1833 (emit_csinc): Likewise.
1834 (emit_cset): Likewise.
1835 (emit_nop): Likewise.
1836 (emit_ops_insns): New helper function.
1837 (emit_pop): Likewise.
1838 (emit_push): Likewise.
1839 (aarch64_emit_prologue): New function.
1840 (aarch64_emit_epilogue): Likewise.
1841 (aarch64_emit_add): Likewise.
1842 (aarch64_emit_sub): Likewise.
1843 (aarch64_emit_mul): Likewise.
1844 (aarch64_emit_lsh): Likewise.
1845 (aarch64_emit_rsh_signed): Likewise.
1846 (aarch64_emit_rsh_unsigned): Likewise.
1847 (aarch64_emit_ext): Likewise.
1848 (aarch64_emit_log_not): Likewise.
1849 (aarch64_emit_bit_and): Likewise.
1850 (aarch64_emit_bit_or): Likewise.
1851 (aarch64_emit_bit_xor): Likewise.
1852 (aarch64_emit_bit_not): Likewise.
1853 (aarch64_emit_equal): Likewise.
1854 (aarch64_emit_less_signed): Likewise.
1855 (aarch64_emit_less_unsigned): Likewise.
1856 (aarch64_emit_ref): Likewise.
1857 (aarch64_emit_if_goto): Likewise.
1858 (aarch64_emit_goto): Likewise.
1859 (aarch64_write_goto_address): Likewise.
1860 (aarch64_emit_const): Likewise.
1861 (aarch64_emit_call): Likewise.
1862 (aarch64_emit_reg): Likewise.
1863 (aarch64_emit_pop): Likewise.
1864 (aarch64_emit_stack_flush): Likewise.
1865 (aarch64_emit_zero_ext): Likewise.
1866 (aarch64_emit_swap): Likewise.
1867 (aarch64_emit_stack_adjust): Likewise.
1868 (aarch64_emit_int_call_1): Likewise.
1869 (aarch64_emit_void_call_2): Likewise.
1870 (aarch64_emit_eq_goto): Likewise.
1871 (aarch64_emit_ne_goto): Likewise.
1872 (aarch64_emit_lt_goto): Likewise.
1873 (aarch64_emit_le_goto): Likewise.
1874 (aarch64_emit_gt_goto): Likewise.
1875 (aarch64_emit_ge_got): Likewise.
1876 (aarch64_emit_ops_impl): New static global variable.
1877 (aarch64_emit_ops): New target function, return
1878 &aarch64_emit_ops_impl.
1879 (struct linux_target_ops): Install it.
1881 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
1883 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
1884 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
1886 * linux-aarch64-ipa.c: New file.
1887 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
1889 (aarch64_get_thread_area): New target method.
1890 (extract_signed_bitfield): New helper function.
1891 (aarch64_decode_ldr_literal): New function.
1892 (enum aarch64_opcodes): New enum.
1893 (struct aarch64_register): New struct.
1894 (struct aarch64_operand): New struct.
1895 (x0): New static global.
1904 (aarch64_register): New helper function.
1905 (register_operand): Likewise.
1906 (immediate_operand): Likewise.
1907 (struct aarch64_memory_operand): New struct.
1908 (offset_memory_operand): New helper function.
1909 (preindex_memory_operand): Likewise.
1910 (enum aarch64_system_control_registers): New enum.
1911 (ENCODE): New macro.
1912 (emit_insn): New helper function.
1913 (emit_b): New function.
1914 (emit_bcond): Likewise.
1915 (emit_cb): Likewise.
1916 (emit_tb): Likewise.
1917 (emit_blr): Likewise.
1918 (emit_stp): Likewise.
1919 (emit_ldp_q_offset): Likewise.
1920 (emit_stp_q_offset): Likewise.
1921 (emit_load_store): Likewise.
1922 (emit_ldr): Likewise.
1923 (emit_ldrsw): Likewise.
1924 (emit_str): Likewise.
1925 (emit_ldaxr): Likewise.
1926 (emit_stxr): Likewise.
1927 (emit_stlr): Likewise.
1928 (emit_data_processing_reg): Likewise.
1929 (emit_data_processing): Likewise.
1930 (emit_add): Likewise.
1931 (emit_sub): Likewise.
1932 (emit_mov): Likewise.
1933 (emit_movk): Likewise.
1934 (emit_mov_addr): Likewise.
1935 (emit_mrs): Likewise.
1936 (emit_msr): Likewise.
1937 (emit_sevl): Likewise.
1938 (emit_wfe): Likewise.
1939 (append_insns): Likewise.
1940 (can_encode_int32_in): New helper function.
1941 (aarch64_relocate_instruction): New function.
1942 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
1943 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
1944 (struct linux_target_ops): Install aarch64_get_thread_area,
1945 aarch64_install_fast_tracepoint_jump_pad and
1946 aarch64_get_min_fast_tracepoint_insn_len.
1948 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
1950 * Makefile.in (aarch64-insn.o): New rule.
1951 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
1953 2015-09-21 Yao Qi <yao.qi@linaro.org>
1955 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
1957 2015-09-21 Yao Qi <yao.qi@linaro.org>
1959 * tracepoint.c (max_jump_pad_size): Remove.
1961 2015-09-18 Yao Qi <yao.qi@linaro.org>
1963 * linux-aarch64-low.c: Don't include sys/uio.h.
1964 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
1966 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
1968 * tracepoint.c (eval_result_type): Change prototype.
1969 (condition_true_at_tracepoint): Fix argument to compiled_cond.
1971 2015-09-15 Pedro Alves <palves@redhat.com>
1973 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
1974 Check whether to report exec events instead of checking whether
1975 multiprocess is enabled.
1977 2015-09-15 Pedro Alves <palves@redhat.com>
1980 * remote-utils.c (prepare_resume_reply): Merge
1981 TARGET_WAITKIND_VFORK_DONE switch case with the
1982 TARGET_WAITKIND_FORKED case.
1984 2015-09-15 Yao Qi <yao.qi@linaro.org>
1986 * server.c (handle_query): Check string comparison using
1987 "else if" instead of "if".
1989 2015-09-15 Yao Qi <yao.qi@linaro.org>
1991 * server.c (vCont_supported): New global variable.
1992 (handle_query): Set vCont_supported to 1 if "vContSupported+"
1993 matches. Append ";vContSupported+" to own_buf.
1994 (handle_v_requests): Append ";s;S" to own_buf if target supports
1995 hardware single step or vCont_supported is false.
1996 (capture_main): Set vCont_supported to zero.
1998 2015-09-15 Yao Qi <yao.qi@linaro.org>
2000 * linux-low.c (linux_supports_conditional_breakpoints): Rename
2002 (linux_supports_hardware_single_step): ... New function.
2003 (linux_target_ops): Update.
2004 * lynx-low.c (lynx_target_ops): Set field
2005 supports_hardware_single_step to target_can_do_hardware_single_step.
2006 * nto-low.c (nto_target_ops): Likewise.
2007 * spu-low.c (spu_target_ops): Likewise.
2008 * win32-low.c (win32_target_ops): Likewise.
2009 * target.c (target_can_do_hardware_single_step): New function.
2010 * target.h (struct target_ops) <supports_conditional_breakpoints>:
2011 Remove. <supports_hardware_single_step>: New field.
2012 (target_supports_conditional_breakpoints): Remove.
2013 (target_supports_hardware_single_step): New macro.
2014 (target_can_do_hardware_single_step): Declare.
2015 * server.c (handle_query): Use target_supports_hardware_single_step
2016 instead of target_supports_conditional_breakpoints.
2018 2015-09-15 Yao Qi <yao.qi@linaro.org>
2020 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
2022 (struct linux_target_ops the_low_target): Install
2023 aarch64_linux_siginfo_fixup.
2025 2015-09-11 Don Breazeal <donb@codesourcery.com>
2026 Luis Machado <lgustavo@codesourcery.com>
2028 * linux-low.c (linux_mourn): Static declaration.
2029 (linux_arch_setup): Move in front of
2030 handle_extended_wait.
2031 (linux_arch_setup_thread): New function.
2032 (handle_extended_wait): Handle exec events. Call
2033 linux_arch_setup_thread. Make event_lwp argument a
2034 pointer-to-a-pointer.
2035 (check_zombie_leaders): Do not check stopped threads.
2036 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
2037 (linux_low_filter_event): Add lwp and thread for exec'ing
2038 non-leader thread if leader thread has been deleted.
2039 Refactor code into linux_arch_setup_thread and call it.
2040 Pass child lwp pointer by reference to handle_extended_wait.
2041 (linux_wait_for_event_filtered): Update comment.
2042 (linux_wait_1): Prevent clobbering exec event status.
2043 (linux_supports_exec_events): New function.
2044 (linux_target_ops) <supports_exec_events>: Initialize new member.
2045 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
2047 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
2048 * server.c (report_exec_events): New global variable.
2049 (handle_query): Handle qSupported query for exec-events feature.
2050 (captured_main): Initialize report_exec_events.
2051 * server.h (report_exec_events): Declare new global variable.
2052 * target.h (struct target_ops) <supports_exec_events>: New
2054 (target_supports_exec_events): New macro.
2055 * win32-low.c (win32_target_ops) <supports_exec_events>:
2056 Initialize new member.
2058 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
2060 * linux-low.c (linux_low_enable_btrace): Remove.
2061 (linux_target_ops): Replace linux_low_enable_btrace with
2062 linux_enable_btrace.
2064 2015-09-03 Yao Qi <yao.qi@linaro.org>
2066 * linux-aarch64-low.c (aarch64_insert_point): Call
2067 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
2070 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
2072 * linux-low.c (check_stopped_by_breakpoint): Use
2073 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
2075 2015-08-27 Pedro Alves <palves@redhat.com>
2077 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
2079 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
2081 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
2082 the XNEW-family equivalent.
2083 (compile_bytecodes): Likewise.
2084 * dll.c (loaded_dll): Likewise.
2085 * event-loop.c (append_callback_event): Likewise.
2086 (create_file_handler): Likewise.
2087 (create_file_event): Likewise.
2088 * hostio.c (handle_open): Likewise.
2089 * inferiors.c (add_thread): Likewise.
2090 (add_process): Likewise.
2091 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
2092 * linux-arm-low.c (arm_new_process): Likewise.
2093 (arm_new_thread): Likewise.
2094 * linux-low.c (add_to_pid_list): Likewise.
2095 (linux_add_process): Likewise.
2096 (handle_extended_wait): Likewise.
2097 (add_lwp): Likewise.
2098 (enqueue_one_deferred_signal): Likewise.
2099 (enqueue_pending_signal): Likewise.
2100 (linux_resume_one_lwp_throw): Likewise.
2101 (linux_resume_one_thread): Likewise.
2102 (linux_read_memory): Likewise.
2103 (linux_write_memory): Likewise.
2104 * linux-mips-low.c (mips_linux_new_process): Likewise.
2105 (mips_linux_new_thread): Likewise.
2106 (mips_add_watchpoint): Likewise.
2107 * linux-x86-low.c (initialize_low_arch): Likewise.
2108 * lynx-low.c (lynx_add_process): Likewise.
2109 * mem-break.c (set_raw_breakpoint_at): Likewise.
2110 (set_breakpoint): Likewise.
2111 (add_condition_to_breakpoint): Likewise.
2112 (add_commands_to_breakpoint): Likewise.
2113 (clone_agent_expr): Likewise.
2114 (clone_one_breakpoint): Likewise.
2115 * regcache.c (new_register_cache): Likewise.
2116 * remote-utils.c (look_up_one_symbol): Likewise.
2117 * server.c (queue_stop_reply): Likewise.
2118 (start_inferior): Likewise.
2119 (queue_stop_reply_callback): Likewise.
2120 (handle_target_event): Likewise.
2121 * spu-low.c (fetch_ppc_memory): Likewise.
2122 (store_ppc_memory): Likewise.
2123 * target.c (set_target_ops): Likewise.
2124 * thread-db.c (thread_db_load_search): Likewise.
2125 (try_thread_db_load_1): Likewise.
2126 * tracepoint.c (add_tracepoint): Likewise.
2127 (add_tracepoint_action): Likewise.
2128 (create_trace_state_variable): Likewise.
2129 (cmd_qtdpsrc): Likewise.
2130 (cmd_qtro): Likewise.
2131 (add_while_stepping_state): Likewise.
2132 * win32-low.c (child_add_thread): Likewise.
2133 (get_image_name): Likewise.
2135 2015-08-25 Yao Qi <yao.qi@linaro.org>
2137 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
2139 2015-08-25 Yao Qi <yao.qi@linaro.org>
2141 * Makefile.in (aarch64-linux.o): New rule.
2142 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
2144 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
2145 (aarch64_init_debug_reg_state): Make it extern.
2146 (aarch64_linux_prepare_to_resume): Remove.
2148 2015-08-25 Yao Qi <yao.qi@linaro.org>
2150 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
2151 lwp_arch_private_info and ptid_of_lwp.
2153 2015-08-25 Yao Qi <yao.qi@linaro.org>
2155 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
2156 Find proc_info by find_process_pid. All callers updated.
2158 2015-08-25 Yao Qi <yao.qi@linaro.org>
2160 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
2162 (debug_reg_change_callback): Remove.
2163 (aarch64_notify_debug_reg_change): Remove.
2165 2015-08-25 Yao Qi <yao.qi@linaro.org>
2167 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
2168 Call current_lwp_ptid.
2170 2015-08-25 Yao Qi <yao.qi@linaro.org>
2172 * linux-aarch64-low.c (debug_reg_change_callback): Use
2175 2015-08-25 Yao Qi <yao.qi@linaro.org>
2177 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
2179 2015-08-25 Yao Qi <yao.qi@linaro.org>
2181 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
2183 2015-08-25 Yao Qi <yao.qi@linaro.org>
2185 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
2188 2015-08-25 Yao Qi <yao.qi@linaro.org>
2190 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
2192 (debug_reg_change_callback): Remove argument entry and add argument
2193 lwp. Remove local variable thread. Don't print thread id in the
2194 debugging output. Don't check whether pid of thread equals to pid.
2195 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
2196 iterate_over_lwps instead find_inferior.
2198 2015-08-24 Pedro Alves <palves@redhat.com>
2200 * inferiors.c (get_first_process): New function.
2201 * inferiors.h (get_first_process): New declaration.
2202 * remote-utils.c (read_ptid): Default to the first process in the
2203 list, instead of to the current thread's process.
2205 2015-08-24 Pedro Alves <palves@redhat.com>
2207 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
2208 * event-loop.c: Likewise.
2209 * remote-utils.c: Likewise.
2210 * tracepoint.c: Likewise.
2212 2015-08-24 Pedro Alves <palves@redhat.com>
2214 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
2217 2015-08-21 Pedro Alves <palves@redhat.com>
2219 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
2220 instead of literal 1.
2222 2015-08-21 Pedro Alves <palves@redhat.com>
2224 * tdesc.c (default_description): Explicitly zero-initialize.
2226 2015-08-21 Pedro Alves <palves@redhat.com>
2229 * inferiors.c (remove_thread): Discard any pending stop reply for
2231 * server.c (remove_all_on_match_pid): Rename to ...
2232 (remove_all_on_match_ptid): ... this. Work with a filter ptid
2234 (discard_queued_stop_replies): Change parameter to a ptid. Now
2236 (handle_v_kill, kill_inferior_callback, captured_main)
2237 (process_serial_event): Adjust.
2238 * server.h (discard_queued_stop_replies): Declare.
2240 2015-08-21 Pedro Alves <palves@redhat.com>
2242 * linux-low.c (wait_for_sigstop): Always switch to no thread
2243 selected if the previously current thread dies.
2244 * lynx-low.c (lynx_request_interrupt): Use the first thread's
2245 process instead of the current thread's.
2246 * remote-utils.c (input_interrupt): Don't check if there's no
2248 * server.c (gdb_read_memory, gdb_write_memory): If setting the
2249 current thread to the general thread fails, error out.
2250 (handle_qxfer_auxv, handle_qxfer_libraries)
2251 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
2252 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
2253 (handle_query): Check if there's a thread selected instead of
2254 checking whether there's any thread in the thread list.
2255 (handle_qxfer_threads, handle_qxfer_btrace)
2256 (handle_qxfer_btrace_conf): Don't error out early if there's no
2257 thread in the thread list.
2258 (handle_v_cont, myresume): Don't set the current thread to the
2260 (process_serial_event) <Hg handling>: Also set thread_id if the
2261 previous general thread is still alive.
2262 (process_serial_event) <g/G handling>: If setting the current
2263 thread to the general thread fails, error out.
2264 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
2265 thread's lwp instead of the current thread's.
2266 * target.c (set_desired_thread): If the desired thread was not
2267 found, leave the current thread pointing to NULL. Return an int
2268 (boolean) indicating success.
2269 * target.h (set_desired_thread): Change return type to int.
2271 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
2273 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
2274 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
2276 (ps_get_thread_area): New function.
2278 2015-08-19 Gary Benson <gbenson@redhat.com>
2280 * hostio.c (handle_pread): Do not attempt to read more data
2281 than hostio_reply_with_data can fit in a packet.
2283 2015-08-18 Joel Brobecker <brobecker@adacore.com>
2285 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
2287 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
2289 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
2291 2015-08-06 Pedro Alves <palves@redhat.com>
2293 * tracepoint.c (expr_eval_result): Now an int.
2295 2015-08-06 Pedro Alves <palves@redhat.com>
2297 * gdbthread.h (struct regcache): Forward declare.
2298 (struct thread_info) <regcache_data>: Now a struct regcache
2300 * inferiors.c (inferior_regcache_data)
2301 (set_inferior_regcache_data): Now work with struct regcache
2303 * inferiors.h (struct regcache): Forward declare.
2304 (inferior_regcache_data, set_inferior_regcache_data): Now work
2305 with struct regcache pointers.
2306 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
2307 (free_register_cache_thread): Remove struct regcache pointer
2310 2015-08-06 Pedro Alves <palves@redhat.com>
2312 * server.c (captured_main): On error, print the exception message
2313 to stderr, and if run_once is set, throw a quit.
2315 2015-08-06 Pedro Alves <palves@redhat.com>
2317 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
2320 2015-08-06 Pedro Alves <palves@redhat.com>
2322 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
2323 reading beyond the passed in buffer length.
2325 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
2327 * tracepoint.c (symbol_list) <required>: Remove.
2329 2015-08-06 Pedro Alves <palves@redhat.com>
2331 * linux-low.c (handle_extended_wait): Set the fork child's suspend
2332 count if stopping and suspending threads.
2333 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
2334 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
2335 (linux_detach): Complete an ongoing step-over.
2336 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
2338 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
2339 (linux_wait_1): If passing a signal to the inferior after
2340 finishing a step-over, unsuspend and re-resume all lwps. If we
2341 see a single-step event but the thread should be continuing, don't
2342 pass the trap to gdb.
2343 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
2344 internal_error instead of gdb_assert.
2345 (enqueue_pending_signal): New function.
2346 (check_ptrace_stopped_lwp_gone): Add debug output.
2347 (start_step_over): Use internal_error instead of gdb_assert.
2348 (complete_ongoing_step_over): New function.
2349 (linux_resume_one_thread): Don't resume a suspended thread.
2350 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
2353 2015-08-06 Pedro Alves <palves@redhat.com>
2355 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
2356 (linux_thread_alive): Use lwp_is_marked_dead.
2357 (extended_event_reported): Delete.
2358 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
2359 instead of extended_event_reported.
2360 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
2362 (lwp_is_marked_dead): New function.
2363 (lwp_running): Use lwp_is_marked_dead.
2364 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
2367 2015-08-06 Pedro Alves <palves@redhat.com>
2369 * linux-low.c (linux_wait_1): Move fork event output out of the
2370 !report_to_gdb check. Pass event_child->waitstatus to
2371 target_waitstatus_to_string instead of ourstatus.
2373 2015-08-04 Yao Qi <yao.qi@linaro.org>
2375 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
2376 if current_thread is 32 bit.
2378 2015-08-04 Yao Qi <yao.qi@linaro.org>
2380 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
2381 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
2382 * server.c (extended_protocol): Remove "static".
2383 * server.h (extended_protocol): Declare it.
2385 2015-08-04 Yao Qi <yao.qi@linaro.org>
2387 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
2388 both aarch64 and aarch32.
2389 (aarch64_set_pc): Likewise.
2391 2015-08-04 Yao Qi <yao.qi@linaro.org>
2393 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
2394 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
2395 arm-with-neon.xml to srv_xmlfiles.
2396 * linux-aarch64-low.c: Include linux-aarch32-low.h.
2397 (is_64bit_tdesc): New function.
2398 (aarch64_linux_read_description): New function.
2399 (aarch64_arch_setup): Call aarch64_linux_read_description.
2400 (regs_info): Rename to regs_info_aarch64.
2401 (aarch64_regs_info): Return right regs_info.
2402 (initialize_low_arch): Call initialize_low_arch_aarch32.
2404 2015-08-04 Yao Qi <yao.qi@linaro.org>
2406 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
2407 * linux-aarch32-low.c: New file.
2408 * linux-aarch32-low.h: New file.
2409 * linux-arm-low.c (arm_fill_gregset): Move it to
2410 linux-aarch32-low.c.
2411 (arm_store_gregset): Likewise.
2412 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
2413 (arm_store_vfpregset): Call arm_store_vfpregset_num.
2414 (arm_arch_setup): Check if PTRACE_GETREGSET works.
2415 (regs_info): Rename to regs_info_arm.
2416 (arm_regs_info): Return regs_info_aarch32 if
2417 have_ptrace_getregset is 1 and target description is
2418 arm_with_neon or arm_with_vfpv3.
2419 (initialize_low_arch): Don't call init_registers_arm_with_neon.
2420 Call initialize_low_arch_aarch32 instead.
2422 2015-08-04 Yao Qi <yao.qi@linaro.org>
2424 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
2425 * linux-low.c: ... here.
2426 * linux-low.h (have_ptrace_getregset): Declare it.
2428 2015-08-04 Pedro Alves <palves@redhat.com>
2430 * thread-db.c (struct thread_db): Use new typedefs.
2431 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
2433 (disable_thread_event_reporting): Cast result of dlsym to
2434 destination function pointer type.
2435 (thread_db_mourn): Use td_ta_delete_ftype.
2437 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
2439 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
2441 (CDX_BREAKPOINT): Define for R2.
2442 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
2443 (the_low_target): Add comments.
2445 2015-07-30 Yao Qi <yao.qi@linaro.org>
2447 * linux-arm-low.c (arm_hwcap): Remove it.
2448 (arm_read_description): New local variable arm_hwcap. Don't
2449 set arm_hwcap to zero.
2451 2015-07-30 Yao Qi <yao.qi@linaro.org>
2453 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
2454 Use regcache->tdesc instead.
2455 (arm_store_wmmxregset): Likewise.
2456 (arm_fill_vfpregset): Likewise.
2457 (arm_store_vfpregset): Likewise.
2459 2015-07-30 Yao Qi <yao.qi@linaro.org>
2461 * linux-arm-low.c: Include arch/arm.h.
2462 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
2463 (arm_store_gregset): Likewise.
2465 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
2467 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
2468 ptrace's 4th parameter.
2470 2015-07-27 Yao Qi <yao.qi@linaro.org>
2472 * configure.srv (case aarch64*-*-linux*): Don't set
2475 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
2477 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
2479 * linux-arm-low.c: Likewise.
2480 * linux-cris-low.c: Likewise.
2481 * linux-crisv32-low.c: Likewise.
2482 * linux-low.c: Likewise.
2483 * linux-m68k-low.c: Likewise.
2484 * linux-mips-low.c: Likewise.
2485 * linux-nios2-low.c: Likewise.
2486 * linux-s390-low.c: Likewise.
2487 * linux-sparc-low.c: Likewise.
2488 * linux-tic6x-low.c: Likewise.
2489 * linux-tile-low.c: Likewise.
2490 * linux-x86-low.c: Likewise.
2492 2015-07-24 Pedro Alves <palves@redhat.com>
2494 * config.in: Regenerate.
2495 * configure: Regenerate.
2497 2015-07-24 Pedro Alves <palves@redhat.com>
2499 * acinclude.m4: Include ../ptrace.m4.
2500 * configure.ac: Call GDB_AC_PTRACE.
2501 * config.in, configure: Regenerate.
2503 2015-07-24 Yao Qi <yao.qi@linaro.org>
2505 * linux-low.c (linux_create_inferior): Remove setting to
2506 proc->priv->new_inferior.
2507 (linux_attach): Likewise.
2508 (linux_low_filter_event): Likewise.
2509 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
2511 2015-07-24 Yao Qi <yao.qi@linaro.org>
2513 * linux-low.c (linux_arch_setup): New function.
2514 (linux_low_filter_event): If proc->tdesc is NULL and
2515 proc->attached is true, call the_low_target.arch_setup.
2516 Otherwise, keep status pending, and return.
2517 (linux_resume_one_lwp_throw): Don't call get_pc if
2518 thread->while_stepping isn't NULL. Don't call
2519 get_thread_regcache if proc->tdesc is NULL.
2520 (need_step_over_p): Return 0 if proc->tdesc is NULL.
2521 (linux_target_ops): Install arch_setup.
2522 * server.c (start_inferior): Call the_target->arch_setup.
2523 * target.h (struct target_ops) <arch_setup>: New field.
2524 (target_arch_setup): New marco.
2525 * lynx-low.c (lynx_target_ops): Update.
2526 * nto-low.c (nto_target_ops): Update.
2527 * spu-low.c (spu_target_ops): Update.
2528 * win32-low.c (win32_target_ops): Update.
2530 2015-07-24 Yao Qi <yao.qi@linaro.org>
2532 * linux-low.c (linux_add_process): Don't set
2533 proc->priv->new_inferior.
2534 (linux_create_inferior): Set proc->priv->new_inferior to 1.
2535 (linux_attach): Likewise.
2537 2015-07-24 Yao Qi <yao.qi@linaro.org>
2539 * server.c (start_inferior): Code refactor.
2541 2015-07-24 Yao Qi <yao.qi@linaro.org>
2543 * server.c (process_serial_event): Set general_thread.
2545 2015-07-21 Yao Qi <yao.qi@linaro.org>
2547 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
2548 aarch64_linux_get_debug_reg_capacity.
2550 2015-07-17 Yao Qi <yao.qi@linaro.org>
2552 * Makefile.in (aarch64-linux-hw-point.o): New rule.
2553 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
2554 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
2555 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
2556 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
2557 (AARCH64_HWP_ALIGNMENT): Likewise.
2558 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
2559 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
2560 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
2561 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
2562 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
2563 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
2564 (struct aarch64_debug_reg_state): Likewise.
2565 (struct arch_lwp_info): Likewise.
2566 (aarch64_align_watchpoint): Likewise.
2567 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
2568 (aarch64_watchpoint_length): Likewise.
2569 (aarch64_point_encode_ctrl_reg): Likewise
2570 (aarch64_point_is_aligned): Likewise.
2571 (aarch64_align_watchpoint): Likewise.
2572 (aarch64_linux_set_debug_regs):
2573 (aarch64_dr_state_insert_one_point): Likewise.
2574 (aarch64_dr_state_remove_one_point): Likewise.
2575 (aarch64_handle_breakpoint): Likewise.
2576 (aarch64_handle_aligned_watchpoint): Likewise.
2577 (aarch64_handle_unaligned_watchpoint): Likewise.
2578 (aarch64_handle_watchpoint): Likewise.
2580 2015-07-17 Yao Qi <yao.qi@linaro.org>
2582 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
2583 and don't aarch64_get_debug_reg_state. All callers update.
2584 (aarch64_handle_aligned_watchpoint): Likewise.
2585 (aarch64_handle_unaligned_watchpoint): Likewise.
2586 (aarch64_handle_watchpoint): Likewise.
2587 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
2588 (aarch64_remove_point): Likewise.
2590 2015-07-17 Yao Qi <yao.qi@linaro.org>
2592 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
2594 (aarch64_handle_unaligned_watchpoint): Likewise.
2596 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
2598 Revert the previous 3 commits:
2599 Move gdb_regex* to common/
2600 Move linux_find_memory_regions_full & co.
2601 gdbserver build-id attribute generator
2603 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
2604 Jan Kratochvil <jan.kratochvil@redhat.com>
2606 gdbserver build-id attribute generator.
2607 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
2608 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
2609 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
2611 (get_dynamic): Use find_pdhr to traverse program headers.
2612 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
2613 (compare_mapping_entry_range, struct find_memory_region_callback_data)
2614 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
2615 (get_hex_build_id): New.
2616 (linux_qxfer_libraries_svr4): Add optional build-id attribute
2617 to reply XML document.
2619 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
2620 Jan Kratochvil <jan.kratochvil@redhat.com>
2622 * target.c: Include target/target-utils.h and fcntl.h.
2623 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
2624 (target_fileio_read_stralloc): New functions.
2626 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
2628 * Makefile.in (OBS): Add gdb_regex.o.
2630 * config.in: Rebuilt.
2631 * configure: Rebuilt.
2633 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
2634 Jan Kratochvil <jan.kratochvil@redhat.com>
2636 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
2637 * Makefile.in (OBS): Add target-utils.o.
2638 (linux-maps.o, target-utils.o): New.
2639 * configure.srv (srv_linux_obj): Add linux-maps.o.
2641 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
2643 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
2645 (the_low_target): Install it.
2647 2015-07-14 Pedro Alves <palves@redhat.com>
2649 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
2650 Instead, ignore ECHILD, and throw an error for other errnos.
2652 2015-07-10 Pedro Alves <palves@redhat.com>
2654 * event-loop.c (struct callback_event) <data>: Change type to
2655 gdb_client_data instance instead of gdb_client_data pointer.
2656 (append_callback_event): Adjust.
2658 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
2660 * linux-aarch64-low.c: Add comments for each linux_target_ops
2661 method. Remove comments already covered in target_ops and
2662 linux_target_ops definitions.
2663 (the_low_target): Add comments for each unimplemented method.
2665 2015-07-09 Yao Qi <yao.qi@linaro.org>
2667 * linux-aarch64-low.c (aarch64_regmap): Remove.
2668 (aarch64_usrregs_info): Remove.
2669 (regs_info): Set field usrregs to NULL.
2671 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
2673 * linux-low.c: Include "rsp-low.h"
2674 (linux_low_encode_pt_config, linux_low_encode_raw): New.
2675 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
2676 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
2677 (handle_btrace_enable_pt): New.
2678 (handle_btrace_general_set): Support "pt".
2679 (handle_btrace_conf_general_set): Support "pt:size".
2681 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
2683 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
2686 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
2688 * linux-aarch64-low.c: Remove comment about endianness.
2689 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
2690 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
2693 2015-06-24 Gary Benson <gbenson@redhat.com>
2695 * linux-i386-ipa.c (stdint.h): Do not include.
2696 * lynx-i386-low.c (stdint.h): Likewise.
2697 * lynx-ppc-low.c (stdint.h): Likewise.
2698 * mem-break.c (stdint.h): Likewise.
2699 * thread-db.c (stdint.h): Likewise.
2700 * tracepoint.c (stdint.h): Likewise.
2701 * win32-low.c (stdint.h): Likewise.
2703 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
2705 * server.c (write_qxfer_response): Update call to
2706 remote_escape_output.
2708 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
2709 Jan Kratochvil <jan.kratochvil@redhat.com>
2711 Merge multiple hex conversions.
2712 * gdbreplay.c (tohex): Rename to 'fromhex'.
2713 (logchar): Use fromhex.
2715 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
2717 * server.c (handle_qxfer_libraries): Set `version' attribute for
2720 2015-06-10 Gary Benson <gbenson@redhat.com>
2722 * target.h (struct target_ops) <multifs_open>: New field.
2723 <multifs_unlink>: Likewise.
2724 <multifs_readlink>: Likewise.
2725 * linux-low.c (nat/linux-namespaces.h): New include.
2726 (linux_target_ops): Initialize the_target->multifs_open,
2727 the_target->multifs_unlink and the_target->multifs_readlink.
2728 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
2729 * hostio.c (hostio_fs_pid): New static variable.
2730 (hostio_handle_new_gdb_connection): New function.
2731 (handle_setfs): Likewise.
2732 (handle_open): Use the_target->multifs_open as appropriate.
2733 (handle_unlink): Use the_target->multifs_unlink as appropriate.
2734 (handle_readlink): Use the_target->multifs_readlink as
2736 (handle_vFile): Handle vFile:setfs packets.
2737 * server.c (handle_query): Call hostio_handle_new_gdb_connection
2738 after target_handle_new_gdb_connection.
2740 2015-06-10 Gary Benson <gbenson@redhat.com>
2742 * configure.ac (AC_CHECK_FUNCS): Add setns.
2743 * config.in: Regenerate.
2744 * configure: Likewise.
2745 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
2746 (linux-namespaces.o): New rule.
2747 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
2749 2015-06-09 Gary Benson <gbenson@redhat.com>
2751 * hostio.c (handle_open): Process mode argument with
2752 fileio_to_host_mode.
2754 2015-06-01 Yao Qi <yao.qi@linaro.org>
2756 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
2757 * linux-x86-low.c: Likewise.
2759 2015-05-28 Don Breazeal <donb@codesourcery.com>
2761 * linux-low.c (handle_extended_wait): Initialize
2762 thread_info.last_resume_kind for new fork children.
2764 2015-05-15 Pedro Alves <palves@redhat.com>
2766 * target.h (target_handle_new_gdb_connection): Rewrite using if
2767 wrapped in do/while.
2769 2015-05-14 Joel Brobecker <brobecker@adacore.com>
2771 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
2772 * configure, config.in: Regenerate.
2773 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
2776 2015-05-12 Don Breazeal <donb@codesourcery.com>
2778 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
2779 PTRACE_EVENT_VFORK_DONE.
2780 (linux_low_ptrace_options, extended_event_reported): Add vfork
2782 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
2783 and "vforkdone" for RSP 'T' Stop Reply Packet.
2784 * server.h (report_vfork_events): Declare
2787 2015-05-12 Don Breazeal <donb@codesourcery.com>
2789 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
2790 (the_low_target) <new_fork>: Initialize new member.
2791 * linux-arm-low.c (arm_new_fork): New function.
2792 (the_low_target) <new_fork>: Initialize new member.
2793 * linux-low.c (handle_extended_wait): Call new target function
2795 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
2796 * linux-mips-low.c (mips_add_watchpoint): New function
2797 extracted from mips_insert_point.
2798 (the_low_target) <new_fork>: Initialize new member.
2799 (mips_linux_new_fork): New function.
2800 (mips_insert_point): Call mips_add_watchpoint.
2801 * linux-x86-low.c (x86_linux_new_fork): New function.
2802 (the_low_target) <new_fork>: Initialize new member.
2804 2015-05-12 Don Breazeal <donb@codesourcery.com>
2806 * linux-low.c (handle_extended_wait): Implement return value,
2807 rename argument 'event_child' to 'event_lwp', handle
2808 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
2809 (linux_low_ptrace_options): New function.
2810 (linux_low_filter_event): Call linux_low_ptrace_options,
2811 use different argument fo linux_enable_event_reporting,
2812 use return value from handle_extended_wait.
2813 (extended_event_reported): New function.
2814 (linux_wait_1): Call extended_event_reported and set
2815 status to report fork events.
2816 (linux_write_memory): Add pid to debug message.
2817 (reset_lwp_ptrace_options_callback): New function.
2818 (linux_handle_new_gdb_connection): New function.
2819 (linux_target_ops): Initialize new structure member.
2820 * linux-low.h (struct lwp_info) <waitstatus>: New member.
2821 * lynx-low.c: Initialize new structure member.
2822 * remote-utils.c (prepare_resume_reply): Implement stop reason
2823 "fork" for "T" stop message.
2824 * server.c (handle_query): Call handle_new_gdb_connection.
2825 * server.h (report_fork_events): Declare global flag.
2826 * target.h (struct target_ops) <handle_new_gdb_connection>:
2828 (target_handle_new_gdb_connection): New macro.
2829 * win32-low.c: Initialize new structure member.
2831 2015-05-12 Don Breazeal <donb@codesourcery.com>
2833 * mem-break.c (APPEND_TO_LIST): Define macro.
2834 (clone_agent_expr): New function.
2835 (clone_one_breakpoint): New function.
2836 (clone_all_breakpoints): New function.
2837 * mem-break.h: Declare new functions.
2839 2015-05-12 Don Breazeal <donb@codesourcery.com>
2841 * linux-low.c (linux_supports_fork_events): New function.
2842 (linux_supports_vfork_events): New function.
2843 (linux_target_ops): Initialize new structure members.
2844 (initialize_low): Call linux_check_ptrace_features.
2845 * lynx-low.c (lynx_target_ops): Initialize new structure
2847 * server.c (report_fork_events, report_vfork_events):
2849 (handle_query): Add new features to qSupported packet and
2851 (captured_main): Initialize new global variables.
2852 * target.h (struct target_ops) <supports_fork_events>:
2854 <supports_vfork_events>: New member.
2855 (target_supports_fork_events): New macro.
2856 (target_supports_vfork_events): New macro.
2857 * win32-low.c (win32_target_ops): Initialize new structure
2860 2015-05-12 Gary Benson <gbenson@redhat.com>
2862 * server.c (handle_qxfer_exec_file): Use current process
2865 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
2867 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
2868 Remove HAVE_PTRACE_GETREGS conditionals.
2869 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
2870 instead of PTRACE_GETREGS and PTRACE_SETREGS.
2872 2015-05-08 Yao Qi <yao.qi@linaro.org>
2874 * linux-low.c (linux_supports_conditional_breakpoints): New
2876 (linux_target_ops): Install new target method.
2877 * lynx-low.c (lynx_target_ops): Install NULL hook for
2878 supports_conditional_breakpoints.
2879 * nto-low.c (nto_target_ops): Likewise.
2880 * spu-low.c (spu_target_ops): Likewise.
2881 * win32-low.c (win32_target_ops): Likewise.
2882 * server.c (handle_query): Check
2883 target_supports_conditional_breakpoints.
2884 * target.h (struct target_ops) <supports_conditional_breakpoints>:
2886 (target_supports_conditional_breakpoints): New macro.
2888 2015-05-06 Pedro Alves <palves@redhat.com>
2891 * server.c (start_inferior): If the process exits, mourn it.
2893 2015-04-21 Gary Benson <gbenson@redhat.com>
2895 * hostio.c (fileio_open_flags_to_host): Factored out to
2896 fileio_to_host_openflags in common/fileio.c. Single use
2899 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
2901 * linux-xtensa-low.c (xtensa_fill_gregset)
2902 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
2905 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
2907 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
2908 (regs_info): Replace usrregs pointer with NULL.
2910 2015-04-17 Gary Benson <gbenson@redhat.com>
2912 * target.h (struct target_ops) <pid_to_exec_file>: New field.
2913 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
2914 * server.c (handle_qxfer_exec_file): New function.
2915 (qxfer_packets): Add exec-file entry.
2916 (handle_query): Report qXfer:exec-file:read as supported packet.
2918 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
2920 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
2922 2015-04-09 Gary Benson <gbenson@redhat.com>
2924 * hostio-errno.c (errno_to_fileio_error): Remove function.
2925 Update caller to use remote_fileio_to_fio_error.
2927 2015-04-09 Yao Qi <yao.qi@linaro.org>
2929 * linux-low.c (linux_insert_point): Call
2930 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
2931 (linux_remove_point): Call remove_memory_breakpoint if type is
2933 * linux-x86-low.c (x86_insert_point): Don't call
2934 insert_memory_breakpoint.
2935 (x86_remove_point): Don't call remove_memory_breakpoint.
2937 2015-04-01 Pedro Alves <palves@redhat.com>
2938 Cleber Rosa <crosa@redhat.com>
2940 * server.c (gdbserver_usage): Reorganize and extend the usage
2943 2015-03-24 Pedro Alves <palves@redhat.com>
2945 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
2946 output. Also dump TRAP_TRACE.
2947 (linux_low_filter_event): In debug output, distinguish a
2948 resume_stop SIGSTOP from a delayed SIGSTOP.
2950 2015-03-24 Gary Benson <gbenson@redhat.com>
2952 * linux-x86-low.c (x86_linux_new_thread): Moved to
2954 (x86_linux_prepare_to_resume): Likewise.
2956 2015-03-24 Gary Benson <gbenson@redhat.com>
2958 * Makefile.in (x86-linux-dregs.o): New rule.
2959 * configure.srv: Add x86-linux-dregs.o to relevant targets.
2960 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
2961 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
2962 (x86_linux_dr_get): Likewise.
2963 (x86_linux_dr_set): Likewise.
2964 (update_debug_registers_callback): Likewise.
2965 (x86_linux_dr_set_addr): Likewise.
2966 (x86_linux_dr_get_addr): Likewise.
2967 (x86_linux_dr_set_control): Likewise.
2968 (x86_linux_dr_get_control): Likewise.
2969 (x86_linux_dr_get_status): Likewise.
2970 (x86_linux_update_debug_registers): Likewise.
2972 2015-03-24 Gary Benson <gbenson@redhat.com>
2974 * linux-x86-low.c (x86_linux_update_debug_registers):
2975 New function, factored out from...
2976 (x86_linux_prepare_to_resume): ...this.
2978 2015-03-24 Gary Benson <gbenson@redhat.com>
2980 * linux-x86-low.c (x86_linux_dr_get): Update comments.
2981 (x86_linux_dr_set): Likewise.
2982 (update_debug_registers_callback): Likewise.
2983 (x86_linux_dr_set_addr): Likewise.
2984 (x86_linux_dr_get_addr): Likewise.
2985 (x86_linux_dr_set_control): Likewise.
2986 (x86_linux_dr_get_control): Likewise.
2987 (x86_linux_dr_get_status): Likewise.
2988 (x86_linux_prepare_to_resume): Likewise.
2990 2015-03-24 Gary Benson <gbenson@redhat.com>
2992 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
2993 Use perror_with_name. Pass string through gettext.
2994 (x86_linux_dr_set): Likewise.
2996 2015-03-24 Gary Benson <gbenson@redhat.com>
2998 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
2999 (x86_linux_dr_set_addr): ...this.
3000 (x86_dr_low_get_addr): Rename to...
3001 (x86_linux_dr_get_addr): ...this.
3002 (x86_dr_low_set_control): Rename to...
3003 (x86_linux_dr_set_control): ...this.
3004 (x86_dr_low_get_control): Rename to...
3005 (x86_linux_dr_get_control): ...this.
3006 (x86_dr_low_get_status): Rename to...
3007 (x86_linux_dr_get_status): ...this.
3008 (x86_dr_low): Update with new function names.
3010 2015-03-24 Gary Benson <gbenson@redhat.com>
3012 * Makefile.in (x86-linux.o): New rule.
3013 * configure.srv: Add x86-linux.o to relevant targets.
3014 * linux-low.c (lwp_set_arch_private_info): New function.
3015 (lwp_arch_private_info): Likewise.
3016 * linux-x86-low.c: Include nat/x86-linux.h.
3017 (arch_lwp_info): Removed structure.
3018 (update_debug_registers_callback):
3019 Use lwp_set_debug_registers_changed.
3020 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
3021 and lwp_set_debug_registers_changed.
3022 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
3024 2015-03-24 Gary Benson <gbenson@redhat.com>
3026 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
3027 * linux-arm-low.c (arm_new_thread): Likewise.
3028 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
3029 * linux-mips-low.c (mips_linux_new_thread): Likewise.
3030 * linux-x86-low.c (x86_linux_new_thread): Likewise.
3031 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
3033 2015-03-24 Gary Benson <gbenson@redhat.com>
3035 * linux-low.c (ptid_of_lwp): New function.
3036 (lwp_is_stopped): Likewise.
3037 (lwp_stop_reason): Likewise.
3038 * linux-x86-low.c (update_debug_registers_callback):
3040 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
3043 2015-03-24 Gary Benson <gbenson@redhat.com>
3045 * linux-low.h (linux_stop_lwp): Remove declaration.
3047 2015-03-24 Gary Benson <gbenson@redhat.com>
3049 * linux-low.h: Include nat/linux-nat.h.
3050 * linux-low.c (iterate_over_lwps_args): New structure.
3051 (iterate_over_lwps_filter): New function.
3052 (iterate_over_lwps): Likewise.
3053 * linux-x86-low.c (update_debug_registers_callback):
3054 Update signature to what iterate_over_lwps expects.
3055 Remove PID check that iterate_over_lwps now performs.
3056 (x86_dr_low_set_addr): Use iterate_over_lwps.
3057 (x86_dr_low_set_control): Likewise.
3059 2015-03-24 Gary Benson <gbenson@redhat.com>
3061 * linux-x86-low.c (x86_debug_reg_state): New function.
3062 (x86_linux_prepare_to_resume): Use the above.
3064 2015-03-24 Gary Benson <gbenson@redhat.com>
3066 * linux-low.c (current_lwp_ptid): New function.
3067 * linux-x86-low.c: Include nat/linux-nat.h.
3068 (x86_dr_low_get_addr): Use current_lwp_ptid.
3069 (x86_dr_low_get_control): Likewise.
3070 (x86_dr_low_get_status): Likewise.
3072 2015-03-20 Pedro Alves <palves@redhat.com>
3074 * tracepoint.c (cmd_qtstatus): Make "str" const.
3076 2015-03-20 Pedro Alves <palves@redhat.com>
3078 * server.c (handle_general_set): Make "req_str" const.
3080 2015-03-19 Pedro Alves <palves@redhat.com>
3082 * linux-low.c (linux_resume_one_lwp): Rename to ...
3083 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
3084 instead call perror_with_name.
3085 (check_ptrace_stopped_lwp_gone): New function.
3086 (linux_resume_one_lwp): Reimplement as wrapper around
3087 linux_resume_one_lwp_throw that swallows errors if the LWP is
3090 2015-03-19 Pedro Alves <palves@redhat.com>
3092 * linux-low.c (count_events_callback, select_event_lwp_callback):
3093 No longer check whether the thread has resume_stop as last resume
3096 2015-03-19 Pedro Alves <palves@redhat.com>
3098 * linux-low.c (count_events_callback, select_event_lwp_callback):
3099 Use the lwp's status_pending_p field, not the thread's.
3101 2015-03-19 Pedro Alves <palves@redhat.com>
3103 * linux-low.c (select_event_lwp_callback): Update comments to
3104 no longer mention SIGTRAP.
3106 2015-03-18 Gary Benson <gbenson@redhat.com>
3108 * server.c (handle_query): Do not report vFile:fstat as supported.
3110 2015-03-11 Gary Benson <gbenson@redhat.com>
3112 * hostio.c (sys/types.h): New include.
3113 (sys/stat.h): Likewise.
3114 (common-remote-fileio.h): Likewise.
3115 (handle_fstat): New function.
3116 (handle_vFile): Handle vFile:fstat packets.
3118 2015-03-11 Gary Benson <gbenson@redhat.com>
3120 * configure.ac (AC_CHECK_MEMBERS): Add checks for
3121 struct stat.st_blocks and struct stat.st_blksize.
3122 * configure: Regenerate.
3123 * config.in: Likewise.
3124 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
3125 (OBS): Add common-remote-fileio.o.
3126 (common-remote-fileio.o): New rule.
3128 2015-03-09 Pedro Alves <palves@redhat.com>
3130 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
3131 'struct sockaddr' pointer in 'accept' call.
3133 2015-03-09 Pedro Alves <palves@redhat.com>
3136 2015-03-07 Pedro Alves <palves@redhat.com>
3137 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
3138 or <winsock2.h> here. Instead include "gdb_socket.h".
3139 (remote_open): Use union gdb_sockaddr_u.
3140 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
3141 or <winsock2.h> here. Instead include "gdb_socket.h".
3142 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
3143 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
3145 (init_named_socket, gdb_agent_helper_thread): Use union
3148 2015-03-07 Pedro Alves <palves@redhat.com>
3150 * configure.ac (build_warnings): Move
3151 -Wdeclaration-after-statement to the C-specific set.
3152 * configure: Regenerate.
3154 2015-03-07 Pedro Alves <palves@redhat.com>
3156 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
3157 or <winsock2.h> here. Instead include "gdb_socket.h".
3158 (remote_open): Use union gdb_sockaddr_u.
3159 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
3160 or <winsock2.h> here. Instead include "gdb_socket.h".
3161 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
3162 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
3164 (init_named_socket, gdb_agent_helper_thread): Use union
3167 2015-03-07 Pedro Alves <palves@redhat.com>
3169 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
3172 2015-03-06 Yao Qi <yao.qi@linaro.org>
3174 * linux-aarch64-low.c (aarch64_insert_point): Use
3175 show_debug_regs as a boolean.
3176 (aarch64_remove_point): Likewise.
3178 2015-03-05 Pedro Alves <palves@redhat.com>
3180 * lynx-low.c (lynx_target_ops): Install NULL hooks for
3181 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
3182 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
3183 * nto-low.c (nto_target_ops): Likewise.
3184 * spu-low.c (spu_target_ops): Likewise.
3185 * win32-low.c (win32_target_ops): Likewise.
3187 2015-03-04 Pedro Alves <palves@redhat.com>
3189 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3190 Decide whether a breakpoint triggered based on the SIGTRAP's
3192 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
3193 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3194 (linux_low_filter_event): Check for breakpoints before checking
3196 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
3198 (linux_stopped_by_sw_breakpoint)
3199 (linux_supports_stopped_by_sw_breakpoint)
3200 (linux_stopped_by_hw_breakpoint)
3201 (linux_supports_stopped_by_hw_breakpoint): New functions.
3202 (linux_target_ops): Install new target methods.
3204 2015-03-04 Pedro Alves <palves@redhat.com>
3206 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
3207 * server.c (swbreak_feature, hwbreak_feature): New globals.
3208 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
3209 (captured_main): Clear swbreak_feature and hwbreak_feature.
3210 * server.h (swbreak_feature, hwbreak_feature): Declare.
3211 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
3212 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
3213 supports_stopped_by_hw_breakpoint>: New fields.
3214 (target_supports_stopped_by_sw_breakpoint)
3215 (target_stopped_by_sw_breakpoint)
3216 (target_supports_stopped_by_hw_breakpoint)
3217 (target_stopped_by_hw_breakpoint): Declare.
3219 2015-03-04 Pedro Alves <palves@redhat.com>
3221 enum lwp_stop_reason -> enum target_stop_reason
3222 * linux-low.c (check_stopped_by_breakpoint): Adjust.
3223 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
3224 (linux_wait_1, stuck_in_jump_pad_callback)
3225 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
3226 (linux_stopped_by_watchpoint):
3227 * linux-low.h (enum lwp_stop_reason): Delete.
3228 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
3229 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
3231 2015-03-04 Yao Qi <yao.qi@linaro.org>
3233 * Makefile.in (SFILES): Add linux-aarch64-low.c.
3235 2015-03-03 Gary Benson <gbenson@redhat.com>
3237 * hostio.c (handle_vFile): Fix prefix lengths.
3239 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
3241 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
3244 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
3246 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
3247 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
3248 (clean): Add "rm -f" for above C files.
3249 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
3250 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
3251 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
3252 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
3253 * linux-s390-low.c (HWCAP_S390_VX): New macro.
3254 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
3255 (init_registers_s390x_vx_linux64)
3256 (init_registers_s390x_tevx_linux64)
3257 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
3258 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
3260 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
3261 (s390_store_vxrs_high): New functions.
3262 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
3264 (s390_arch_setup): Add logic for selecting one of the new target
3265 descriptions. Activate the new vector regsets if applicable.
3266 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
3267 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
3268 and init_registers_s390x_tevx_linux64.
3270 2015-03-01 Pedro Alves <palves@redhat.com>
3272 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
3275 2015-02-27 Pedro Alves <palves@redhat.com>
3277 * linux-x86-low.c (u_debugreg_offset): New function.
3278 (x86_linux_dr_get, x86_linux_dr_set): Use it.
3280 2015-02-27 Pedro Alves <palves@redhat.com>
3282 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
3283 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
3284 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
3285 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
3286 (ps_lsetfpregs, ps_getpid)
3287 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
3288 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
3289 (ps_lsetxregs, ps_plog): Declare.
3291 2015-02-27 Pedro Alves <palves@redhat.com>
3293 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
3294 IP_AGENT_EXPORT_FUNC.
3295 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
3296 IP_AGENT_EXPORT_FUNC.
3297 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
3298 (IP_AGENT_EXPORT): Delete.
3299 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
3300 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
3301 (gdb_trampoline_buffer_error, collecting, gdb_collect)
3302 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
3303 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
3304 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
3305 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
3306 (traceframe_read_count, traceframe_write_count)
3307 (traceframes_created, trace_state_variables, get_raw_reg)
3308 (get_trace_state_variable_value, set_trace_state_variable_value)
3309 (ust_loaded, helper_thread_id, cmd_buf): Use
3310 IPA_SYM_EXPORTED_NAME.
3311 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
3312 (tracepoints) Use IP_AGENT_EXPORT_VAR.
3313 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
3314 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
3315 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
3316 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
3317 EXTERN_C_PUSH/EXTERN_C_POP.
3318 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
3319 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
3320 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
3321 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
3322 (traceframe_write_count, traceframe_read_count)
3323 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
3324 (about_to_request_buffer_space, get_trace_state_variable_value)
3325 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
3326 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
3327 EXTERN_C_PUSH/EXTERN_C_POP.
3328 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
3329 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
3330 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
3331 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
3332 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
3333 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
3334 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
3335 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
3337 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
3338 (IP_AGENT_EXPORT_VAR_DECL): Define.
3340 (gdb_agent_get_raw_reg): Declare.
3342 2015-02-27 Tom Tromey <tromey@redhat.com>
3343 Pedro Alves <palves@redhat.com>
3345 Rename symbols whose names are reserved C++ keywords throughout.
3347 2015-02-27 Pedro Alves <palves@redhat.com>
3349 * Makefile.in (COMPILER): New, get it from autoconf.
3350 (CXX): Get from autoconf instead.
3351 (COMPILE.pre): Use COMPILER.
3352 (CC-LD): Rename to ...
3353 (CC_LD): ... this. Use COMPILER.
3354 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
3355 (CXX_FOR_TARGET): Default to g++ instead of gcc.
3356 * acinclude.m4: Include build-with-cxx.m4.
3357 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
3358 Disable -Werror by default if building in C++ mode.
3359 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
3360 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
3361 the C++ compiler. Save/restore CXXFLAGS too.
3362 * configure: Regenerate.
3364 2015-02-27 Pedro Alves <palves@redhat.com>
3366 * acinclude.m4: Include libiberty.m4.
3367 * configure.ac: Call libiberty_INIT.
3368 * config.in, configure: Regenerate.
3370 2015-02-26 Pedro Alves <palves@redhat.com>
3372 * linux-low.c (linux_wait_1): When incrementing the PC past a
3373 program breakpoint always use the_low_target.breakpoint_len as
3374 increment, rather than the maximum between that and
3375 the_low_target.decr_pc_after_break.
3377 2015-02-23 Pedro Alves <palves@redhat.com>
3379 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
3380 thread was doing a step-over; always adjust the PC if
3381 we stepped over a permanent breakpoint.
3382 (linux_wait_1): If we stepped over breakpoint that was on top of a
3383 permanent breakpoint, manually advance the PC past it.
3385 2015-02-23 Pedro Alves <palves@redhat.com>
3387 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
3389 (x86_fill_gregset, x86_store_gregset): Use it when handling
3392 2015-02-20 Pedro Alves <palves@redhat.com>
3394 * thread-db.c: Include "nat/linux-procfs.h".
3395 (thread_db_init): Skip listing new threads if the kernel supports
3396 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
3398 2015-02-20 Pedro Alves <palves@redhat.com>
3400 * linux-low.c (status_pending_p_callback): Use ptid_match.
3402 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
3404 PR breakpoints/16812
3405 * linux-low.c (wstatus_maybe_breakpoint): Remove.
3406 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
3407 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
3409 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
3411 PR breakpoints/15956
3412 * tracepoint.c (cmd_qtinit): Add check for current_thread.
3414 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
3416 * linux-low.c (linux_low_btrace_conf): Print size.
3417 * server.c (handle_btrace_conf_general_set): New.
3418 (hanle_general_set): Call handle_btrace_conf_general_set.
3419 (handle_query): Report Qbtrace-conf:bts:size as supported.
3421 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
3423 * linux-low.c (linux_low_enable_btrace): Update parameters.
3424 (linux_low_btrace_conf): New.
3425 (linux_target_ops)<to_btrace_conf>: Initialize.
3426 * server.c (current_btrace_conf): New.
3427 (handle_btrace_enable): Rename to ...
3428 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
3429 to target_enable_btrace. Update comment. Update users.
3430 (handle_qxfer_btrace_conf): New.
3431 (qxfer_packets): Add btrace-conf entry.
3432 (handle_query): Report qXfer:btrace-conf:read as supported packet.
3433 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
3434 (target_ops)<read_btrace_conf>: New.
3435 (target_enable_btrace): Update parameters.
3436 (target_read_btrace_conf): New.
3438 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
3440 * server.c (handle_btrace_general_set): Remove call to
3441 target_supports_btrace.
3442 (supported_btrace_packets): New.
3443 (handle_query): Call supported_btrace_packets.
3444 * target.h: include btrace-common.h.
3445 (btrace_target_info): Removed.
3446 (supports_btrace, target_supports_btrace): Update parameters.
3448 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
3450 * Makefile.in (SFILES): Add common/btrace-common.c.
3451 (OBS): Add common/btrace-common.o.
3452 (btrace-common.o): Add build rules.
3453 * linux-low: Include btrace-common.h.
3454 (linux_low_read_btrace): Use struct btrace_data. Call
3455 btrace_data_init and btrace_data_fini.
3457 2015-02-06 Pedro Alves <palves@redhat.com>
3459 * thread-db.c (find_new_threads_callback): Add debug output.
3461 2015-02-04 Pedro Alves <palves@redhat.com>
3463 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
3464 (resume_stopped_resumed_lwps): New function.
3465 (linux_wait_for_event_filtered): Use it.
3467 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
3469 * Makefile.in (SFILES): Add linux-personality.c.
3470 (linux-personality.o): New rule.
3471 * configure.srv (srv_linux_obj): Add linux-personality.o to the
3472 list of objects to be built.
3473 * linux-low.c: Include nat/linux-personality.h.
3474 (linux_create_inferior): Remove code to disable address space
3475 randomization (moved to ../nat/linux-personality.c). Create
3476 cleanup to disable address space randomization.
3478 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
3480 * Makefile.in (posix-strerror.o): New rule.
3481 (mingw-strerror.o): Likewise.
3482 * configure: Regenerated.
3483 * configure.ac: Source file ../common/common.host. Initialize new
3484 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
3486 2015-01-14 Yao Qi <yao@codesourcery.com>
3488 * Makefile.in (SFILES): Add nat/ppc-linux.c.
3489 (ppc-linux.o): New rule.
3490 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
3491 * configure.ac: AC_CHECK_FUNCS(getauxval).
3492 * config.in: Re-generated.
3493 * configure: Re-generated.
3494 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
3495 ppc64_64bit_inferior_p
3497 2015-01-14 Yao Qi <yao@codesourcery.com>
3499 * linux-ppc-low.c: Include "nat/ppc-linux.h".
3500 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
3501 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
3502 (PT_ORIG_R3, PT_TRAP): Likewise.
3503 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
3504 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
3505 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
3507 2015-01-10 Joel Brobecker <brobecker@adacore.com>
3509 * i387-fp.c (i387_cache_to_xsave): In look over
3510 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
3511 zmmh_low_space field by use of zmmh_high_space.
3513 2015-01-09 Pedro Alves <palves@redhat.com>
3515 * linux-low.c (step_over_bkpt): Move higher up in the file.
3516 (handle_extended_wait): Don't store the stop_pc here.
3517 (get_stop_pc): Adjust comments and rename to ...
3518 (check_stopped_by_breakpoint): ... this. Record whether the LWP
3519 stopped for a software breakpoint or hardware breakpoint.
3520 (thread_still_has_status_pending_p): New function.
3521 (status_pending_p_callback): Use
3522 thread_still_has_status_pending_p. If the event is no longer
3523 interesting, resume the LWP.
3524 (handle_tracepoints): Add assert.
3525 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
3526 (wstatus_maybe_breakpoint): New function.
3527 (cancel_breakpoint): Delete function.
3528 (check_stopped_by_watchpoint): New function, factored out from
3529 linux_low_filter_event.
3530 (lp_status_maybe_breakpoint): Delete function.
3531 (linux_low_filter_event): Remove filter_ptid argument.
3532 Leave thread group exits pending here. Store the LWP's stop PC.
3533 Always leave events pending.
3534 (linux_wait_for_event_filtered): Pull all events out of the
3535 kernel, and leave them all pending.
3536 (count_events_callback, select_event_lwp_callback): Consider all
3538 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
3539 (select_event_lwp): Only give preference to the stepping LWP in
3540 all-stop mode. Adjust comments.
3541 (ignore_event): New function.
3542 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
3543 references to cancel_breakpoints. Adjust to renames. Also give
3544 equal priority to all LWPs that have had events in non-stop mode.
3545 If reporting a software breakpoint event, unadjust the LWP's PC.
3546 (linux_wait): If linux_wait_1 returned an ignored event, retry.
3547 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
3549 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
3550 (resume_status_pending_p): Use thread_still_has_status_pending_p.
3551 (linux_stopped_by_watchpoint): Adjust.
3552 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
3553 * linux-low.h (enum lwp_stop_reason): New.
3554 (struct lwp_info) <stop_pc>: Adjust comment.
3555 <stopped_by_watchpoint>: Delete field.
3556 <stop_reason>: New field.
3557 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
3558 * mem-break.c (software_breakpoint_inserted_here)
3559 (hardware_breakpoint_inserted_here): New function.
3560 * mem-break.h (software_breakpoint_inserted_here)
3561 (hardware_breakpoint_inserted_here): Declare.
3562 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
3563 (cancel_breakpoints): Delete.
3564 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
3565 (upload_fast_traceframes): Remove references to
3568 2015-01-09 Pedro Alves <palves@redhat.com>
3570 * thread-db.c (find_new_threads_callback): Ignore thread if the
3571 kernel thread ID is -1.
3573 2015-01-09 Pedro Alves <palves@redhat.com>
3575 * linux-low.c (linux_attach_fail_reason_string): Move to
3576 nat/linux-ptrace.c, and rename.
3577 (linux_attach_lwp): Update comment.
3578 (attach_proc_task_lwp_callback): New function.
3579 (linux_attach): Adjust to rename and use
3580 linux_proc_attach_tgid_threads.
3581 (linux_attach_fail_reason_string): Delete declaration.
3583 2015-01-01 Joel Brobecker <brobecker@adacore.com>
3585 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
3586 * server.c (gdbserver_version): Likewise.
3588 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
3590 * remote-utils.c: Include ctype.h.
3591 (input_interrupt): Explicitly handle the case when the char
3592 received is the NUL byte. Improve the printing of non-ASCII
3595 2014-12-16 Joel Brobecker <brobecker@adacore.com>
3597 * linux-low.c (linux_low_filter_event): Update call to
3598 linux_enable_event_reporting following the addition of
3599 a new parameter to that function.
3601 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
3604 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
3605 (AARCH64_FPCR_REGNO): Likewise.
3606 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
3607 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
3608 (aarch64_store_fpregset): Likewise.
3610 2014-12-15 Joel Brobecker <brobecker@adacore.com>
3612 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
3613 Remove FIXME comment about assumption about N.
3615 2014-12-13 Joel Brobecker <brobecker@adacore.com>
3617 * configure.ac: If large-file support is disabled in GDBserver,
3618 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
3619 * configure: Regenerate.
3621 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
3623 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
3624 warning upon ENODATA from ptrace.
3625 * linux-s390-low.c (s390_store_tdb): New.
3626 (s390_regsets): Add regset for NT_S390_TDB.
3628 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
3630 * linux-low.c (regsets_store_inferior_registers): Skip regsets
3631 without a fill_function.
3632 * linux-s390-low.c (s390_fill_last_break): Remove.
3633 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
3634 (s390_arch_setup): Use regset's size instead of fill_function for
3637 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
3639 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
3640 the regset's store function when ptrace returned an error.
3641 * regcache.c (get_thread_regcache): Invalidate register cache
3642 before fetching inferior's registers.
3644 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
3646 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
3647 while-loop as for-loop.
3648 (regsets_store_inferior_registers): Likewise.
3650 2014-11-28 Yao Qi <yao@codesourcery.com>
3652 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
3653 * config.in, configure: Re-generate.
3654 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
3657 2014-11-21 Yao Qi <yao@codesourcery.com>
3659 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
3660 (AC_CHECK_HEADERS): Remove malloc.h.
3661 * configure: Re-generated.
3662 * config.in: Re-generated.
3663 * server.h: Don't include alloca.h and malloc.h.
3664 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
3665 Don't include malloc.h.
3667 2014-11-17 Joel Brobecker <brobecker@adacore.com>
3669 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
3670 corresponding ERRNO check in same block.
3672 2014-11-12 Pedro Alves <palves@redhat.com>
3674 * server.c (cont_thread): Update comment.
3675 (start_inferior, attach_inferior): No longer clear cont_thread.
3676 (handle_v_cont): No longer set cont_thread.
3677 (captured_main): Clear cont_thread each time a GDB connects.
3679 2014-11-12 Pedro Alves <palves@redhat.com>
3681 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
3682 thread, and don't resume all threads if the Hc thread has exited.
3684 2014-11-12 Pedro Alves <palves@redhat.com>
3686 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
3687 the process group instead of to a specific LWP.
3689 2014-10-15 Pedro Alves <palves@redhat.com>
3692 * win32-arm-low.c (arm_set_thread_context): Remove current_event
3694 (arm_set_thread_context): Delete.
3695 (the_low_target): Adjust.
3696 * win32-i386-low.c (debug_registers_changed)
3697 (debug_registers_used): Delete.
3698 (update_debug_registers_callback): New function.
3699 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
3700 needing to update their debug registers.
3701 (win32_get_current_dr): New function.
3702 (x86_dr_low_get_addr, x86_dr_low_get_control)
3703 (x86_dr_low_get_status): Fetch the debug register from the thread
3705 (i386_initial_stuff): Adjust.
3706 (i386_get_thread_context): Remove current_event parameter. Don't
3707 clear debug_registers_changed nor copy DR values to
3709 (i386_set_thread_context): Delete.
3710 (i386_prepare_to_resume): New function.
3711 (i386_thread_added): Mark the thread as needing to update irs
3713 (the_low_target): Remove i386_set_thread_context and install
3714 i386_prepare_to_resume.
3715 * win32-low.c (win32_get_thread_context): Adjust.
3716 (win32_set_thread_context): Use SetThreadContext
3718 (win32_prepare_to_resume): New function.
3719 (win32_require_context): New function, factored out from ...
3720 (thread_rec): ... this.
3721 (continue_one_thread): Call win32_prepare_to_resume on each thread
3722 we're about to continue.
3723 (win32_resume): Call win32_prepare_to_resume on the event thread.
3724 * win32-low.h (struct win32_thread_info)
3725 <debug_registers_changed>: New field.
3726 (struct win32_target_ops): Change prototype of set_thread_context,
3727 delete set_thread_context and add prepare_to_resume.
3728 (win32_require_context): New declaration.
3730 2014-10-08 Gary Benson <gbenson@redhat.com>
3732 * server.h: Do not include common-exceptions.h.
3734 2014-10-08 Gary Benson <gbenson@redhat.com>
3736 * server.h: Do not include cleanups.h.
3738 2014-09-30 James Hogan <james.hogan@imgtec.com>
3740 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
3743 2014-09-23 Yao Qi <yao@codesourcery.com>
3745 * linux-low.c (lp_status_maybe_breakpoint): New function.
3746 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
3747 (count_events_callback): Likewise.
3748 (select_event_lwp_callback): Likewise.
3749 (cancel_breakpoints_callback): Likewise.
3751 2014-09-19 Don Breazeal <donb@codesourcery.com>
3753 * linux-low.c (handle_extended_wait): Call
3754 linux_ptrace_get_extended_event.
3755 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
3756 linux_is_extended_waitstatus.
3758 2014-09-16 Joel Brobecker <brobecker@adacore.com>
3760 * Makefile.in (CPPFLAGS): Define.
3761 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
3762 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
3764 2014-09-16 Gary Benson <gbenson@redhat.com>
3766 * inferiors.h (current_inferior): Renamed as...
3767 (current_thread): New variable. All uses updated.
3768 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
3769 (maybe_move_out_of_jump_pad): Likewise.
3770 (cancel_breakpoint): Likewise.
3771 (linux_low_filter_event): Likewise.
3772 (wait_for_sigstop): Likewise.
3773 (linux_resume_one_lwp): Likewise.
3774 (need_step_over_p): Likewise.
3775 (start_step_over): Likewise.
3776 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
3777 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
3778 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
3779 and save_inferior as saved_thread.
3780 * regcache.c (get_thread_regcache): Renamed saved_inferior as
3782 (regcache_invalidate_thread): Likewise.
3783 * remote-utils.c (prepare_resume_reply): Likewise.
3784 * thread-db.c (thread_db_get_tls_address): Likewise.
3785 (disable_thread_event_reporting): Likewise.
3786 (remove_thread_event_breakpoints): Likewise.
3787 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
3789 * target.h (set_desired_inferior): Renamed as...
3790 (set_desired_thread): New declaration. All uses updated.
3791 * server.c (myresume): Updated comment to reference thread instead
3793 (handle_serial_event): Likewise.
3794 (handle_target_event): Likewise.
3796 2014-09-12 Tom Tromey <tromey@redhat.com>
3797 Gary Benson <gbenson@redhat.com>
3799 * regcache.h: Include common-regcache.h.
3800 (regcache_read_pc): Don't declare.
3801 * regcache.c (get_thread_regcache_for_ptid): New function.
3803 2014-09-11 Tom Tromey <tromey@redhat.com>
3804 Gary Benson <gbenson@redhat.com>
3806 * symbol.c: New file.
3807 * Makefile.in (SFILES): Add symbol.c.
3808 (OBS): Add symbol.o.
3810 2014-09-11 Gary Benson <gbenson@redhat.com>
3812 * target.c (target_stop_ptid, target_continue_ptid): New
3815 2014-09-11 Tom Tromey <tromey@redhat.com>
3816 Gary Benson <gbenson@redhat.com>
3818 * target.h: Include target/target.h.
3819 * target.c (target_read_memory, target_read_uint32)
3820 (target_write_memory): New functions.
3822 2014-09-11 Gary Benson <gbenson@redhat.com>
3824 * server.h (debug_hw_points): Don't declare.
3825 * server.c (debug_hw_points): Don't define. Replace all uses
3826 with show_debug_regs.
3827 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
3828 all uses with show_debug_regs.
3830 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
3832 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
3833 endianness into account.
3834 (ppc_supply_ptrace_register): Likewise.
3836 2014-09-03 James Hogan <james.hogan@imgtec.com>
3838 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
3839 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
3841 2014-09-03 Gary Benson <gbenson@redhat.com>
3843 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
3844 ALL_DEBUG_ADDRESS_REGISTERS.
3846 2014-09-02 Gary Benson <gbenson@redhat.com>
3848 * i386-low.h: Renamed as...
3849 * x86-low.h: New file. All type, function and variable name
3850 prefixes changed from "i386_" to "x86_". All references updated.
3851 * i386-low.c: Renamed as...
3852 * x86-low.c: New file. All type, function and variable name
3853 prefixes changed from "i386_" to "x86_". All references updated.
3855 2014-09-02 Gary Benson <gbenson@redhat.com>
3857 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
3858 (x86_linux_new_thread): Likewise.
3860 2014-08-29 Gary Benson <gbenson@redhat.com>
3862 * server.h (setjmp.h): Do not include.
3863 (toplevel): Do not declare.
3864 (common-exceptions.h): Include.
3865 (cleanups.h): Likewise.
3866 * server.c (toplevel): Do not define.
3867 (exit_code): New static global.
3868 (detach_or_kill_for_exit_cleanup): New function.
3869 (main): New function. Original main renamed to...
3870 (captured_main): New function.
3871 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
3873 2014-08-29 Gary Benson <gbenson@redhat.com>
3875 * Makefile.in (SFILES): Add common/common-exceptions.c.
3876 (OBS): Add common-exceptions.o.
3877 (common-exceptions.o): New rule.
3878 * utils.c (prepare_to_throw_exception): New function.
3880 2014-08-29 Gary Benson <gbenson@redhat.com>
3882 * config.in: Regenerate.
3883 * configure: Likewise.
3885 2014-08-29 Gary Benson <gbenson@redhat.com>
3887 * Makefile.in (SFILES): Add common/cleanups.c.
3889 (cleanups.o): New rule.
3891 2014-08-29 Gary Benson <gbenson@redhat.com>
3893 * utils.c (internal_vwarning): New function.
3895 2014-08-28 Gary Benson <gbenson@redhat.com>
3897 * utils.h (fatal): Remove declaration.
3898 * utils.c (fatal): Remove function.
3900 2014-08-28 Gary Benson <gbenson@redhat.com>
3902 * tracepoint.c (gdb_agent_init): Replace fatal with
3904 (initialize_tracepoint): Likewise.
3906 2014-08-28 Gary Benson <gbenson@redhat.com>
3908 * remote-utils.c (remote_prepare): Replace fatal with error.
3910 2014-08-28 Gary Benson <gbenson@redhat.com>
3912 * linux-low.c (linux_async): Replace fatal with warning.
3914 (linux_start_non_stop): Return -1 if linux_async failed.
3916 2014-08-28 Gary Benson <gbenson@redhat.com>
3918 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
3920 (i386_dr_low_get_addr): Remove vague comment.
3921 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
3924 2014-08-28 Gary Benson <gbenson@redhat.com>
3926 * inferiors.c (get_thread_process): Replace check with gdb_assert.
3927 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
3929 (linux_resume_one_lwp): Likewise.
3930 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
3932 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
3933 with internal_error.
3934 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
3935 (init_register_cache): Replace fatal with gdb_assert_not_reached.
3936 (find_register_by_name): Replace fatal with internal_error.
3937 (find_regno): Likewise.
3938 * tdesc.c (init_target_desc): Replace check with gdb_assert.
3939 * thread-db.c (thread_db_create_event): Likewise.
3940 (thread_db_load_search): Likewise.
3941 (try_thread_db_load_1): Likewise.
3942 * tracepoint.c (get_jump_space_head): Replace fatal with
3944 (claim_trampoline_space): Likewise.
3945 (have_fast_tracepoint_trampoline_buffer): Likewise.
3946 (cmd_qtstart): Likewise.
3947 (stop_tracing): Likewise.
3948 (fast_tracepoint_collecting): Likewise.
3949 (target_malloc): Likewise.
3950 (download_tracepoint): Likewise.
3951 (download_trace_state_variables): Replace check with gdb_assert.
3952 (upload_fast_traceframes): Replace fatal with internal_error.
3954 2014-08-19 Tom Tromey <tromey@redhat.com>
3955 Gary Benson <gbenson@redhat.com>
3957 * Makefile.in (SFILES): Add common/common-debug.c.
3958 (OBS): Add common-debug.o.
3959 (common-debug.o): New rule.
3960 * debug.h (debug_printf): Don't declare.
3961 * debug.c (debug_printf): Renamed and rewritten as...
3962 (debug_vprintf): New function.
3964 2014-08-19 Gary Benson <gbenson@redhat.com>
3966 * utils.h: Do not include print-utils.h.
3968 2014-08-19 Tom Tromey <tromey@redhat.com>
3969 Gary Benson <gbenson@redhat.com>
3971 * server.h: Add static assertion.
3972 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
3974 2014-08-19 Tom Tromey <tromey@redhat.com>
3975 Gary Benson <gbenson@redhat.com>
3977 * Makefile.in (SFILES): Add common/errors.c.
3978 (OBS): Add errors.o.
3979 (IPA_OBS): Add errors-ipa.o.
3980 (errors.o): New rule.
3981 (errors-ipa.o): Likewise.
3982 * utils.h (perror_with_name, error, warning): Don't declare.
3983 * utils.c (warning): Renamed and rewritten as...
3984 (vwarning): New function.
3985 (error): Renamed and rewritten as...
3986 (verror): New function.
3987 (internal_error): Renamed and rewritten as...
3988 (internal_verror): New function.
3990 2014-08-07 Gary Benson <gbenson@redhat.com>
3992 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
3993 * configure: Regenerate.
3994 * config.in: Likewise.
3995 * server.h: Do not include errno.h.
3996 * event-loop.c: Likewise.
3997 * hostio-errno.c: Likewise.
3998 * linux-low.c: Likewise.
3999 * remote-utils.c: Likewise.
4000 * spu-low.c: Likewise.
4001 * utils.c: Likewise.
4002 * gdbreplay.c: Unconditionally include errno.h.
4004 2014-08-07 Gary Benson <gbenson@redhat.com>
4006 * server.h: Do not include string.h.
4007 * event-loop.c: Likewise.
4008 * linux-low.c: Likewise.
4009 * regcache.c: Likewise.
4010 * remote-utils.c: Likewise.
4011 * spu-low.c: Likewise.
4012 * utils.c: Likewise.
4014 2014-08-07 Gary Benson <gbenson@redhat.com>
4016 * server.h: Do not include gdb_assert.h.
4018 2014-08-07 Gary Benson <gbenson@redhat.com>
4020 * server.h: Do not include common-utils.h.
4022 2014-08-07 Gary Benson <gbenson@redhat.com>
4024 * server.h: Do not include ptid.h.
4025 * notif.h: Likewise.
4027 2014-08-07 Gary Benson <gbenson@redhat.com>
4029 * server.h: Do not include gdb_locale.h.
4031 2014-08-07 Gary Benson <gbenson@redhat.com>
4033 * server.h: Do not include gdb/signals.h.
4034 * win32-low.c: Likewise.
4036 2014-08-07 Gary Benson <gbenson@redhat.com>
4038 * server.h: Do not include pathmax.h.
4040 2014-08-07 Gary Benson <gbenson@redhat.com>
4042 * server.h: Do not include libiberty.h.
4043 * linux-bfin-low.c: Likewise.
4045 2014-08-07 Gary Benson <gbenson@redhat.com>
4047 * server.h: Do not include ansidecl.h.
4049 2014-08-07 Gary Benson <gbenson@redhat.com>
4051 * linux-x86-low.c: Do not include stddef.h.
4052 * lynx-ppc-low.c: Likewise.
4053 * tracepoint.c: Likewise.
4055 2014-08-07 Gary Benson <gbenson@redhat.com>
4057 * server.h: Do not include stdarg.h.
4058 * nto-low.c: Likewise.
4060 2014-08-07 Gary Benson <gbenson@redhat.com>
4062 * server.h: Do not include stdlib.h.
4063 * inferiors.c: Likewise.
4064 * linux-low.c: Likewise.
4065 * regcache.c: Likewise.
4066 * spu-low.c: Likewise.
4067 * tracepoint.c: Likewise.
4068 * utils.c: Likewise.
4070 2014-08-07 Gary Benson <gbenson@redhat.com>
4072 * server.h: Do not include stdio.h.
4073 * linux-low.c: Likewise.
4074 * remote-utils.c: Likewise.
4075 * spu-low.c: Likewise.
4076 * utils.c: Likewise.
4077 * wincecompat.c: Likewise.
4079 2014-08-06 Gary Benson <gbenson@redhat.com>
4081 * regcache.c (init_register_cache): Move conditionals inside if.
4083 2014-08-06 Gary Benson <gbenson@redhat.com>
4085 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
4087 2014-07-31 Gary Benson <gbenson@redhat.com>
4089 * ax.h: Do not include server.h.
4090 * gdbthread.h: Likewise.
4091 * lynx-low.h: Likewise.
4092 * notif.h: Likewise.
4094 2014-07-30 Gary Benson <gbenson@redhat.com>
4096 * server.h: Include common-defs.h.
4097 Do not include config.h or build-gnulib-gdbserver/config.h.
4099 2014-07-30 Gary Benson <gbenson@redhat.com>
4101 * hostio-errno.c: Move server.h to top of includes list.
4102 * inferiors.c: Likewise.
4103 * linux-x86-low.c: Likewise.
4104 * notif.c: Include server.h.
4106 2014-07-24 Tom Tromey <tromey@redhat.com>
4107 Gary Benson <gbenson@redhat.com>
4109 * server.h (CORE_ADDR): Now unsigned.
4111 2014-07-16 Pedro Alves <palves@redhat.com>
4113 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
4115 2014-07-15 Pedro Alves <palves@redhat.com>
4117 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
4120 2014-07-11 Pedro Alves <palves@redhat.com>
4122 * linux-low.c (kill_wait_lwp): New function, based on
4123 kill_one_lwp_callback, but use my_waitpid directly.
4124 (kill_one_lwp_callback, linux_kill): Use it.
4126 2014-06-23 Pedro Alves <palves@redhat.com>
4128 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
4129 before setting DR0..DR3.
4131 2014-06-20 Gary Benson <gbenson@redhat.com>
4133 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
4134 * configure: Regenerated.
4135 * config.in: Likewise.
4137 2014-06-20 Gary Benson <gbenson@redhat.com>
4139 * Makefile.in (SFILES): Update locations for files moved
4141 (object file files): Reordered.
4143 2014-06-20 Gary Benson <gbenson@redhat.com>
4145 * i386-low.h (i386_dr_low_can_set_addr): Removed.
4146 (i386_dr_low_set_addr): Likewise.
4147 (i386_dr_low_get_addr): Likewise.
4148 (i386_dr_low_can_set_control): Likewise.
4149 (i386_dr_low_set_control): Likewise.
4150 (i386_dr_low_get_control): Likewise.
4151 (i386_dr_low_get_status): Likewise.
4152 (i386_get_debug_register_length): Likewise.
4153 * linux-x86-low.c (i386_dr_low_set_addr):
4154 Changed signature. Made static.
4155 (i386_dr_low_get_addr): Likewise.
4156 (i386_dr_low_set_control): Likewise.
4157 (i386_dr_low_get_control): Likewise.
4158 (i386_dr_low_get_status): Likewise.
4159 (i386_dr_low): New global variable.
4160 * win32-i386-low.c (i386_dr_low_set_addr):
4161 Changed signature. Made static.
4162 (i386_dr_low_get_addr): Likewise.
4163 (i386_dr_low_set_control): Likewise.
4164 (i386_dr_low_get_control): Likewise.
4165 (i386_dr_low_get_status): Likewise.
4166 (i386_dr_low): New global variable.
4168 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
4170 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
4171 * Makefile.in (AR, AR_FLAGS): Define.
4172 * configure: Regenerate.
4174 2014-06-19 Gary Benson <gbenson@redhat.com>
4176 * Makefile.in (i386-dregs.o): New rule.
4177 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
4178 * i386-low.c (target.h): Remove include.
4179 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
4180 (DR_CONTROL_SHIFT): Likewise.
4181 (DR_CONTROL_SIZE): Likewise.
4182 (DR_RW_EXECUTE): Likewise.
4183 (DR_RW_WRITE): Likewise.
4184 (DR_RW_READ): Likewise.
4185 (DR_RW_IORW): Likewise.
4186 (DR_LEN_1): Likewise.
4187 (DR_LEN_2): Likewise.
4188 (DR_LEN_4): Likewise.
4189 (DR_LEN_8): Likewise.
4190 (DR_LOCAL_ENABLE_SHIFT): Likewise.
4191 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
4192 (DR_ENABLE_SIZE): Likewise.
4193 (DR_LOCAL_SLOWDOWN): Likewise.
4194 (DR_GLOBAL_SLOWDOWN): Likewise.
4195 (DR_CONTROL_RESERVED): Likewise.
4196 (I386_DR_CONTROL_MASK): Likewise.
4197 (I386_DR_VACANT): Likewise.
4198 (I386_DR_LOCAL_ENABLE): Likewise.
4199 (I386_DR_GLOBAL_ENABLE): Likewise.
4200 (I386_DR_DISABLE): Likewise.
4201 (I386_DR_SET_RW_LEN): Likewise.
4202 (I386_DR_GET_RW_LEN): Likewise.
4203 (I386_DR_WATCH_HIT): Likewise.
4204 (i386_wp_op_t): Likewise.
4205 (i386_show_dr): Likewise.
4206 (i386_length_and_rw_bits): Likewise.
4207 (i386_insert_aligned_watchpoint): Likewise.
4208 (i386_remove_aligned_watchpoint): Likewise.
4209 (i386_handle_nonaligned_watchpoint): Likewise.
4210 i386_update_inferior_debug_regs(): Likewise.
4211 (i386_dr_insert_watchpoint): Likewise.
4212 (i386_dr_remove_watchpoint): Likewise.
4213 (i386_dr_region_ok_for_watchpoint): Likewise.
4214 (i386_dr_stopped_data_address): Likewise.
4215 (i386_dr_stopped_by_watchpoint): Likewise.
4217 2014-06-19 Gary Benson <gbenson@redhat.com>
4219 * i386-low.c (i386_dr_show): Renamed to
4220 i386_show_dr and made static. All uses updated.
4221 (i386_dr_length_and_rw_bits): Renamed to
4222 i386_length_and_rw_bits and made static.
4224 (i386_dr_insert_aligned_watchpoint): Renamed to
4225 i386_insert_aligned_watchpoint and made static.
4227 (i386_dr_remove_aligned_watchpoint): Renamed to
4228 i386_remove_aligned_watchpoint and made static.
4230 (i386_dr_update_inferior_debug_regs): Renamed to
4231 i386_update_inferior_debug_regs and made static.
4234 2014-06-18 Gary Benson <gbenson@redhat.com>
4236 * i386-low.h (i386_dr_low_can_set_addr): New macro.
4237 (i386_dr_low_can_set_control): Likewise.
4238 (i386_get_debug_register_length): Likewise.
4239 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
4240 (i386_dr_low_can_set_control): Likewise.
4241 (i386_get_debug_register_length): Likewise.
4243 2014-06-17 Gary Benson <gbenson@redhat.com>
4245 * i386-low.h (i386-dregs.h): New include.
4246 (DR_FIRSTADDR): Now in i386-dregs.h.
4247 (DR_LASTADDR): Likewise.
4248 (DR_NADDR): Likewise.
4249 (DR_STATUS): Likewise.
4250 (DR_CONTROL): Likewise.
4251 (i386_debug_reg_state): Likewise.
4252 (i386_dr_insert_watchpoint): Likewise.
4253 (i386_dr_remove_watchpoint): Likewise.
4254 (i386_dr_region_ok_for_watchpoint): Likewise.
4255 (i386_dr_stopped_data_address): Likewise.
4256 (i386_dr_stopped_by_watchpoint): Likewise.
4257 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
4259 2014-06-18 Gary Benson <gbenson@redhat.com>
4261 * i386-low.h (i386_low_insert_watchpoint): Renamed to
4262 i386_dr_insert_watchpoint.
4263 (i386_low_remove_watchpoint): Renamed to
4264 i386_dr_remove_watchpoint.
4265 (i386_low_region_ok_for_watchpoint): Renamed to
4266 i386_dr_region_ok_for_watchpoint.
4267 (i386_low_stopped_data_address): Renamed to
4268 i386_dr_stopped_data_address.
4269 (i386_low_stopped_by_watchpoint): Renamed to
4270 i386_dr_stopped_by_watchpoint.
4271 * i386-low.c (i386_show_dr): Renamed to
4272 i386_dr_show and made nonstatic. All uses updated.
4273 (i386_length_and_rw_bits): Renamed to
4274 i386_dr_length_and_rw_bits and made nonstatic.
4276 (i386_insert_aligned_watchpoint): Renamed to
4277 i386_dr_insert_aligned_watchpoint and made nonstatic.
4279 (i386_remove_aligned_watchpoint): Renamed to
4280 i386_dr_remove_aligned_watchpoint and made nonstatic.
4282 (i386_update_inferior_debug_regs): Renamed to
4283 i386_dr_update_inferior_debug_regs and made nonstatic.
4285 (i386_low_insert_watchpoint): Renamed to
4286 i386_dr_insert_watchpoint. All uses updated.
4287 (i386_low_remove_watchpoint): Renamed to
4288 i386_dr_remove_watchpoint. All uses updated.
4289 (i386_low_region_ok_for_watchpoint): Renamed to
4290 i386_dr_region_ok_for_watchpoint. All uses updated.
4291 (i386_low_stopped_data_address): Renamed to
4292 i386_dr_stopped_data_address. All uses updated.
4293 (i386_low_stopped_by_watchpoint): Renamed to
4294 i386_dr_stopped_by_watchpoint. All uses updated.
4296 2014-06-18 Gary Benson <gbenson@redhat.com>
4298 * i386-low.c (i386_dr_low_can_set_addr): New macro.
4299 (i386_dr_low_can_set_control): Likewise.
4300 (i386_insert_aligned_watchpoint): New check.
4302 2014-06-18 Gary Benson <gbenson@redhat.com>
4304 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
4307 2014-06-18 Gary Benson <gbenson@redhat.com>
4309 * i386-low.c (i386_length_and_rw_bits): Use internal_error
4310 instead of fatal and error.
4311 (i386_handle_nonaligned_watchpoint): Likewise.
4313 2014-06-18 Gary Benson <gbenson@redhat.com>
4315 * i386-low.c (i386_get_debug_register_length): New macro.
4316 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
4317 (i386_show_dr): Use debug_printf instead of fprintf. Use
4318 phex to format values.
4320 2014-06-18 Gary Benson <gbenson@redhat.com>
4322 * i386-low.h: Comment changes.
4323 * i386-low.c: Likewise.
4325 2014-06-18 Gary Benson <gbenson@redhat.com>
4327 * i386-low.c: Whitespace changes.
4329 2014-06-12 Tom Tromey <tromey@redhat.com>
4331 * utils.c (freeargv): Remove.
4333 2014-06-12 Tom Tromey <tromey@redhat.com>
4335 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
4336 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
4337 (parse_debug_format_options): Likewise.
4338 (gdbserver_usage): Likewise.
4339 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
4340 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
4341 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
4343 ($(LIBGNU)): Depend on libiberty.
4344 (all-lib): Recurse into all subdirs.
4345 (install-only): Invoke "install" target in subdirs.
4346 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
4348 * configure: Rebuild.
4349 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
4350 for vasprintf, vsnprintf, or gettimeofday.
4351 * configure.srv: Don't add safe-ctype.o or lbasename.o to
4354 2014-06-05 Joel Brobecker <brobecker@adacore.com>
4356 * development.sh: Delete.
4357 * Makefile.in (config.status): Adjust dependency on development.sh.
4358 * configure.ac: Adjust development.sh source call.
4359 * configure: Regenerate.
4361 2014-06-02 Pedro Alves <palves@redhat.com>
4363 * ax.c (gdb_free_agent_expr): New function.
4364 * ax.h (gdb_free_agent_expr): New declaration.
4365 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
4367 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
4369 (clear_breakpoint_conditions_and_commands): New function.
4370 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
4371 (clear_breakpoint_conditions_and_commands): New declaration.
4373 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
4375 * linux-aarch64-low.c (asm/ptrace.h): Include.
4377 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
4379 Fix TLS access for -static -pthread.
4380 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
4381 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
4382 (thread_db_load_search, try_thread_db_load_1): Initialize it.
4384 2014-05-20 Pedro Alves <palves@redhat.com>
4386 * linux-aarch64-low.c (aarch64_insert_point)
4387 (aarch64_remove_point): No longer check whether the type is
4388 supported here. Adjust to new interface.
4389 (the_low_target): Install aarch64_supports_z_point_type as
4390 supports_z_point_type method.
4391 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
4392 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
4393 instead of a Z packet char. Adjust.
4394 (arm_supports_z_point_type): New function.
4395 (arm_insert_point, arm_remove_point): Adjust to new interface.
4396 (the_low_target): Install arm_supports_z_point_type.
4397 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
4398 (cris_insert_point, cris_remove_point): Adjust to new interface.
4399 Don't check whether the type is supported here.
4400 (the_low_target): Install cris_supports_z_point_type.
4401 * linux-low.c (linux_supports_z_point_type): New function.
4402 (linux_insert_point, linux_remove_point): Adjust to new interface.
4403 * linux-low.h (struct linux_target_ops) <insert_point,
4404 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
4405 raw_breakpoint pointer parameter.
4406 <supports_z_point_type>: New method.
4407 * linux-mips-low.c (mips_supports_z_point_type): New function.
4408 (mips_insert_point, mips_remove_point): Adjust to new interface.
4409 Use mips_supports_z_point_type.
4410 (the_low_target): Install mips_supports_z_point_type.
4411 * linux-ppc-low.c (the_low_target): Install NULL as
4412 supports_z_point_type method.
4413 * linux-s390-low.c (the_low_target): Install NULL as
4414 supports_z_point_type method.
4415 * linux-sparc-low.c (the_low_target): Install NULL as
4416 supports_z_point_type method.
4417 * linux-x86-low.c (x86_supports_z_point_type): New function.
4418 (x86_insert_point): Adjust to new insert_point interface. Use
4419 insert_memory_breakpoint. Adjust to new
4420 i386_low_insert_watchpoint interface.
4421 (x86_remove_point): Adjust to remove_point interface. Use
4422 remove_memory_breakpoint. Adjust to new
4423 i386_low_remove_watchpoint interface.
4424 (the_low_target): Install x86_supports_z_point_type.
4425 * lynx-low.c (lynx_target_ops): Install NULL as
4426 supports_z_point_type callback.
4427 * nto-low.c (nto_supports_z_point_type): New.
4428 (nto_insert_point, nto_remove_point): Adjust to new interface.
4429 (nto_target_ops): Install nto_supports_z_point_type.
4430 * mem-break.c: Adjust intro comment.
4431 (struct raw_breakpoint) <raw_type, size>: New fields.
4432 <inserted>: Update comment.
4433 <shlib_disabled>: Delete field.
4434 (enum bkpt_type) <gdb_breakpoint>: Delete value.
4435 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
4436 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
4437 (raw_bkpt_type_to_target_hw_bp_type): New function.
4438 (find_enabled_raw_code_breakpoint_at): New function.
4439 (find_raw_breakpoint_at): New type and size parameters. Use them.
4440 (insert_memory_breakpoint): New function, based off
4441 set_raw_breakpoint_at.
4442 (remove_memory_breakpoint): New function.
4443 (set_raw_breakpoint_at): Reimplement.
4444 (set_breakpoint): New, based on set_breakpoint_at.
4445 (set_breakpoint_at): Reimplement.
4446 (delete_raw_breakpoint): Go through the_target->remove_point
4447 instead of assuming memory breakpoints.
4448 (find_gdb_breakpoint_at): Delete.
4449 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
4450 (find_gdb_breakpoint): New function.
4451 (set_gdb_breakpoint_at): Delete.
4452 (z_type_supported): New function.
4453 (set_gdb_breakpoint_1): New function, loosely based off
4454 set_gdb_breakpoint_at.
4455 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
4456 (delete_gdb_breakpoint_at): Delete.
4457 (delete_gdb_breakpoint_1): New function, loosely based off
4458 delete_gdb_breakpoint_at.
4459 (delete_gdb_breakpoint): New function.
4460 (clear_gdb_breakpoint_conditions): Rename to ...
4461 (clear_breakpoint_conditions): ... this. Don't handle a NULL
4463 (add_condition_to_breakpoint): Make static.
4464 (add_breakpoint_condition): Take a struct breakpoint pointer
4465 instead of an address. Adjust.
4466 (gdb_condition_true_at_breakpoint): Rename to ...
4467 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
4469 (gdb_condition_true_at_breakpoint): Reimplement.
4470 (add_breakpoint_commands): Take a struct breakpoint pointer
4471 instead of an address. Adjust.
4472 (gdb_no_commands_at_breakpoint): Rename to ...
4473 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
4474 parameter. Return true if no breakpoint was found. Change debug
4476 (gdb_no_commands_at_breakpoint): Reimplement.
4477 (run_breakpoint_commands): Rename to ...
4478 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
4479 and change return type to boolean.
4480 (run_breakpoint_commands): New function.
4481 (gdb_breakpoint_here): Also check for Z1 breakpoints.
4482 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
4483 breakpoint. Go through the_target->remove_point instead of
4484 assuming memory breakpoint.
4485 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
4486 software and hardware breakpoints.
4487 (reinsert_raw_breakpoint): Go through the_target->insert_point
4488 instead of assuming memory breakpoint.
4489 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
4490 software and hardware breakpoints.
4491 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
4492 Check both software and hardware breakpoints.
4493 (validate_inserted_breakpoint): Assert the breakpoint is a
4494 software breakpoint. Set the inserted flag to -1 instead of
4495 setting shlib_disabled.
4496 (delete_disabled_breakpoints): Adjust.
4497 (validate_breakpoints): Only validate software breakpoints.
4498 Adjust to inserted flag change.
4499 (check_mem_read, check_mem_write): Skip breakpoint types other
4500 than software breakpoints. Adjust to inserted flag change.
4501 * mem-break.h (enum raw_bkpt_type): New enum.
4502 (raw_breakpoint, struct process_info): Forward declare.
4503 (Z_packet_to_target_hw_bp_type): Delete declaration.
4504 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
4505 (set_gdb_breakpoint, delete_gdb_breakpoint)
4506 (clear_breakpoint_conditions): New declarations.
4507 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
4508 (breakpoint_inserted_here): Update comment.
4509 (add_breakpoint_condition, add_breakpoint_commands): Replace
4510 address parameter with a breakpoint pointer parameter.
4511 (gdb_breakpoint_here): Update comment.
4512 (delete_gdb_breakpoint_at): Delete.
4513 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
4514 * server.c (process_point_options): Take a struct breakpoint
4515 pointer instead of an address. Adjust.
4516 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
4517 delete_gdb_breakpoint.
4518 * spu-low.c (spu_target_ops): Install NULL as
4519 supports_z_point_type method.
4520 * target.h: Include mem-break.h.
4521 (struct target_ops) <prepare_to_access_memory>: Update comment.
4522 <supports_z_point_type>: New field.
4523 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
4524 instead of a char. Also take a raw breakpoint pointer.
4525 * win32-arm-low.c (the_low_target): Install NULL as
4526 supports_z_point_type.
4527 * win32-i386-low.c (i386_supports_z_point_type): New function.
4528 (i386_insert_point, i386_remove_point): Adjust to new interface.
4529 (the_low_target): Install i386_supports_z_point_type.
4530 * win32-low.c (win32_supports_z_point_type): New function.
4531 (win32_insert_point, win32_remove_point): Adjust to new interface.
4532 (win32_target_ops): Install win32_supports_z_point_type.
4533 * win32-low.h (struct win32_target_ops):
4534 <supports_z_point_type>: New method.
4535 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
4536 instead of a char. Also take a raw breakpoint pointer.
4538 2014-05-20 Pedro Alves <palves@redhat.com>
4540 * mem-break.h: Include break-common.h.
4541 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
4542 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
4543 (Z_packet_to_target_hw_bp_type): New declaration.
4544 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
4545 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
4546 (Z_PACKET_ACCESS_WP): Delete macros.
4547 (Z_packet_to_hw_type): Delete function.
4548 * i386-low.h: Don't include break-common.h here.
4549 (Z_packet_to_hw_type): Delete declaration.
4550 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
4551 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
4552 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
4553 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
4554 * linux-aarch64-low.c: Don't include break-common.h here.
4555 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
4556 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
4557 (Z_packet_to_target_hw_bp_type): Delete function.
4558 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
4560 (mips_insert_point, mips_remove_point): Use
4561 Z_packet_to_target_hw_bp_type.
4563 2014-05-20 Pedro Alves <palves@redhat.com>
4565 * linux-aarch64-low.c: Include break-common.h.
4566 (enum target_point_type): Delete.
4567 (Z_packet_to_point_type): Rename to ...
4568 (Z_packet_to_target_hw_bp_type): ... this, and return a
4569 target_hw_bp_type instead.
4570 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
4571 instead of an enum target_point_type.
4572 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
4574 (aarch64_dr_state_insert_one_point)
4575 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
4576 (aarch64_handle_aligned_watchpoint)
4577 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
4578 Take an enum target_hw_bp_type instead of an enum
4580 (aarch64_supports_z_point_type): New function.
4581 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
4582 use Z_packet_to_target_hw_bp_type.
4584 2014-05-20 Joel Brobecker <brobecker@adacore.com>
4586 * configure.ac: Only use -Werror by default when DEVELOPMENT
4588 * configure: Regenerate.
4590 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
4592 Fix gdbserver qGetTLSAddr for x86_64 -m32.
4593 * linux-x86-low.c (X86_64_USER_REGS): New.
4594 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
4596 2014-04-28 Yao Qi <yao@codesourcery.com>
4598 * Makefile.in (i386-avx512.c): Fix the typo of generated file
4601 2014-04-25 Pedro Alves <palves@redhat.com>
4604 * linux-low.c (linux_attach_fail_reason_string): New function.
4605 (linux_attach_lwp): Delete.
4606 (linux_attach_lwp_1): Rename to ...
4607 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
4608 argument. Remove "initial" parameter. Return int instead of
4609 void. Don't error or warn here.
4610 (linux_attach): Adjust to call linux_attach_lwp. Call error on
4611 failure to attach to the tgid. Call warning when failing to
4613 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
4614 argument. Remove "initial" parameter. Return int instead of
4615 void. Don't error or warn here.
4616 (linux_attach_fail_reason_string): New declaration.
4617 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
4618 interface change. Use linux_attach_fail_reason_string.
4620 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
4621 Walfred Tedeschi <walfred.tedeschi@intel.com>
4623 * Makefile.in: Added rules to handle new files
4624 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
4625 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
4626 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
4627 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
4628 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
4629 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
4631 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
4632 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
4633 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
4634 i386/x32-avx512.xml.
4635 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
4636 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
4637 i386/x32-avx512-linux.xml.
4638 * i387-fp.c (num_avx512_k_registers): New constant for number
4640 (num_avx512_zmmh_low_registers): New constant for number of
4641 lower ZMM registers (0-15).
4642 (num_avx512_zmmh_high_registers): New constant for number of
4643 higher ZMM registers (16-31).
4644 (num_avx512_ymmh_registers): New contant for number of higher
4645 YMM registers (ymm16-31 added by avx521 on x86_64).
4646 (num_avx512_xmm_registers): New constant for number of higher
4647 XMM registers (xmm16-31 added by AVX512 on x86_64).
4648 (struct i387_xsave): Add space for AVX512 registers.
4649 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
4650 Add code to handle AVX512 registers.
4651 (i387_xsave_to_cache): Add code to handle AVX512 registers.
4652 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
4653 prototypei from generated file.
4654 (tdesc_amd64_avx512_linux): Likewise.
4655 (init_registers_x32_avx512_linux): Likewise.
4656 (tdesc_x32_avx512_linux): Likewise.
4657 (init_registers_i386_avx512_linux): Likewise.
4658 (tdesc_i386_avx512_linux): Likewise.
4659 (x86_64_regmap): Add AVX512 registers.
4660 (x86_linux_read_description): Add code to handle AVX512 XSTATE
4662 (initialize_low_arch): Add code to initialize AVX512 registers.
4664 2014-04-23 Pedro Alves <palves@redhat.com>
4666 * mem-break.c (find_gdb_breakpoint_at): Make static.
4667 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
4669 2014-04-23 Pedro Alves <palves@redhat.com>
4671 * i386-low.c: Don't include break-common.h here.
4672 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
4673 prototype to take target_hw_bp_type as argument instead of a Z
4675 * i386-low.h: Include break-common.h here.
4676 (Z_packet_to_hw_type): Declare.
4677 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
4679 * linux-x86-low.c (x86_insert_point): Convert the packet number to
4680 a target_hw_bp_type before calling i386_low_insert_watchpoint.
4681 (x86_remove_point): Convert the packet number to a
4682 target_hw_bp_type before calling i386_low_remove_watchpoint.
4683 * win32-i386-low.c (i386_insert_point): Convert the packet number
4684 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
4685 (i386_remove_point): Convert the packet number to a
4686 target_hw_bp_type before calling i386_low_remove_watchpoint.
4688 2014-04-23 Pedro Alves <palves@redhat.com>
4690 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
4692 2014-04-10 Pedro Alves <palves@redhat.com>
4694 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4695 Check if the condition or command is NULL before checking if the
4696 breakpoint is known. On success, return true.
4697 * mem-break.h (add_breakpoint_condition): Document return.
4698 (add_breakpoint_commands): Add describing comment.
4699 * server.c (skip_to_semicolon): New function.
4700 (process_point_options): Use it.
4702 2014-04-09 Pedro Alves <palves@redhat.com>
4704 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
4707 2014-02-27 Pedro Alves <palves@redhat.com>
4710 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
4712 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
4714 (last_thread_of_process_p): Take a PID argument instead of a
4716 (linux_wait_for_lwp): Delete.
4717 (num_lwps, check_zombie_leaders, not_stopped_callback): New
4719 (linux_low_filter_event): New function, party factored out from
4720 linux_wait_for_event.
4721 (linux_wait_for_event): Rename to ...
4722 (linux_wait_for_event_filtered): ... this. Add new filter ptid
4723 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
4724 sigsuspend. Check for zombie leaders.
4725 (linux_wait_for_event): Reimplement as wrapper around
4726 linux_wait_for_event_filtered.
4727 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
4728 a normal or signal exit is seen, it's the whole process exiting.
4729 (wait_for_sigstop): No longer a for_each_inferior callback.
4730 Rewrite on top of linux_wait_for_event_filtered.
4731 (stop_all_lwps): Call wait_for_sigstop directly.
4732 * server.c (resume, handle_target_event): Handle
4733 TARGET_WAITKIND_NO_RESUMED.
4735 2014-02-26 Joel Brobecker <brobecker@adacore.com>
4737 * win32-low.c (psapi_get_dll_name,
4738 * win32_CreateToolhelp32Snapshot): Delete.
4739 (win32_CreateToolhelp32Snapshot, win32_Module32First)
4740 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
4742 (handle_load_dll): Add function description.
4743 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
4745 2014-02-26 Joel Brobecker <brobecker@adacore.com>
4747 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
4749 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
4750 base address when calling win32_add_one_solib.
4751 (handle_load_dll): Delete local variable load_addr.
4752 Remove 0x1000 offset applied to DLL base address when calling
4753 win32_add_one_solib.
4754 (handle_unload_dll): Add comment.
4756 2014-02-26 Joel Brobecker <brobecker@adacore.com>
4758 * win32-low.c (win32_add_all_dlls): Renames
4759 win32_ensure_ntdll_loaded. Rewrite function documentation.
4760 Adjust implementation to always load all DLLs.
4761 Add 0x1000 offset to DLL base address when calling
4762 win32_add_one_solib.
4763 (child_initialization_done): New static global.
4764 (do_initial_child_stuff): Set child_initialization_done to
4765 zero during child initialization, and 1 after. Replace call
4766 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
4768 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
4769 (handle_unload_dll): Add function documentation.
4770 (get_child_debug_event): Ignore load and unload DLL events
4771 during child initialization.
4773 2014-02-20 Doug Evans <dje@google.com>
4775 Remove global all_lwps.
4776 * inferiors.h (ptid_of): Move here from linux-low.h.
4777 (pid_of, lwpid_of): Ditto.
4778 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
4779 parameter is a struct thread_info * now.
4780 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
4781 directly. Pass &all_threads to find_inferior instead of &all_lwps.
4782 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
4784 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
4785 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
4786 * linux-arm-low.c (update_registers_callback): Update, "entry"
4787 parameter is a struct thread_info * now.
4788 Fetch lwpid from current_inferior directly.
4789 (arm_insert_point): Pass &all_threads to find_inferior instead of
4791 (arm_remove_point): Ditto.
4792 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
4793 (arm_prepare_to_resume): Fetch pid from thread.
4794 (arm_read_description): Fetch lwpid from current_inferior directly.
4795 * linux-low.c (all_lwps): Delete.
4796 (delete_lwp): Delete call to remove_inferior.
4797 (handle_extended_wait): Fetch lwpid from thread.
4798 (add_lwp): Don't set lwp->entry.id. Remove call to
4799 add_inferior_to_list.
4800 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
4801 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
4802 (kill_one_lwp_callback): Ditto.
4803 (linux_kill): Don't dereference NULL pointer.
4804 Fetch ptid,lwpid from thread.
4805 (get_detach_signal): Fetch ptid from thread.
4806 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
4807 Simplify call to regcache_invalidate_thread.
4808 (delete_lwp_callback): Update, "entry" parameter is a
4809 struct thread_info * now. Fetch pid from thread.
4810 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
4811 (status_pending_p_callback): Update, "entry" parameter is a
4812 struct thread_info * now. Fetch ptid from thread.
4813 (find_lwp_pid): Update, "entry" parameter is a
4814 struct thread_info * now.
4815 (linux_wait_for_lwp): Fetch pid from thread.
4816 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
4817 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
4818 (enqueue_one_deferred_signal): Fetch lwpid from thread.
4819 (dequeue_one_deferred_signal): Ditto.
4820 (cancel_breakpoint): Fetch ptid from current_inferior.
4821 (linux_wait_for_event): Pass &all_threads to find_inferior,
4822 not &all_lwps. Fetch ptid, lwpid from thread.
4823 (count_events_callback): Update, "entry" parameter is a
4824 struct thread_info * now.
4825 (select_singlestep_lwp_callback): Ditto.
4826 (select_event_lwp_callback): Ditto.
4827 (cancel_breakpoints_callback): Ditto.
4828 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
4830 (select_event_lwp): Ditto. Fetch ptid from event_thread.
4831 (unsuspend_one_lwp): Update, "entry" parameter is a
4832 struct thread_info * now.
4833 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
4835 (linux_stabilize_threads): Ditto. And for for_each_inferior.
4836 Fetch lwpid from thread, not lwp.
4837 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
4838 Pass &all_threads to find_inferior, not &all_lwps.
4839 (send_sigstop): Fetch lwpid from thread, not lwp.
4840 (send_sigstop_callback): Update, "entry" parameter is a
4841 struct thread_info * now.
4842 (suspend_and_send_sigstop_callback): Ditto.
4843 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
4844 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
4845 struct thread_info * now.
4846 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
4848 (lwp_running): Update, "entry" parameter is a
4849 struct thread_info * now.
4850 (stop_all_lwps): Fetch ptid from thread.
4851 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
4852 (linux_resume_one_lwp): Fetch lwpid from thread.
4853 (linux_set_resume_request): Update, "entry" parameter is a
4854 struct thread_info * now. Fetch pid, lwpid from thread.
4855 (resume_status_pending_p): Update, "entry" parameter is a
4856 struct thread_info * now.
4857 (need_step_over_p): Ditto. Fetch lwpid from thread.
4858 (start_step_over): Fetch lwpid from thread.
4859 (linux_resume_one_thread): Update, "entry" parameter is a
4860 struct thread_info * now. Fetch lwpid from thread.
4861 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
4862 (proceed_one_lwp): Update, "entry" parameter is a
4863 struct thread_info * now. Fetch lwpid from thread.
4864 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
4865 struct thread_info * now.
4866 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
4867 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
4868 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
4870 (regsets_store_inferior_registers): Ditto.
4871 (fetch_register, store_register): Ditto.
4872 (linux_read_memory, linux_write_memory): Ditto.
4873 (linux_request_interrupt): Ditto.
4874 (linux_read_auxv): Ditto.
4875 (linux_xfer_siginfo): Ditto.
4876 (linux_qxfer_spu): Ditto.
4877 (linux_qxfer_libraries_svr4): Ditto.
4878 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
4879 moved to inferiors.h.
4881 (get_thread_lwp): Update.
4882 (struct lwp_info): Delete member "entry". Simplify comment for
4885 * linux-mips-low.c (mips_read_description): Fetch lwpid from
4886 current_inferior directly.
4887 (update_watch_registers_callback): Update, "entry" parameter is a
4888 struct thread_info * now. Fetch pid from thread.
4889 (mips_linux_prepare_to_resume): Fetch ptid from thread.
4890 (mips_insert_point): Fetch lwpid from current_inferior.
4891 Pass &all_threads to find_inferior, not &all_lwps.
4892 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
4893 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
4895 (mips_stopped_data_address): Ditto.
4896 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
4898 * linux-tile-low.c (tile_arch_setup): Ditto.
4899 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
4900 (update_debug_registers_callback): Update, "entry" parameter is a
4901 struct thread_info * now. Fetch pid from thread.
4902 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
4903 Pass &all_threads to find_inferior, not &all_lwps.
4904 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
4905 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
4906 Pass &all_threads to find_inferior, not &all_lwps.
4907 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
4908 (i386_dr_low_get_status): Ditto.
4909 (x86_linux_prepare_to_resume): Fetch ptid from thread.
4910 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
4911 (x86_linux_read_description): Ditto.
4912 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
4914 2014-02-20 Doug Evans <dje@google.com>
4916 * inferiors.c (get_first_inferior): Fix buglet.
4918 2014-02-19 Doug Evans <dje@google.com>
4920 * gdbthread.h (add_thread): Change result type to struct thread_info *.
4921 * inferiors.c (add_thread): Change result type to struct thread_info *.
4922 All callers updated.
4923 (add_lwp): Call add_thread here instead of in callers.
4924 All callers updated.
4925 * linux-low.h (get_lwp_thread): Rewrite.
4926 (struct lwp_info): New member "thread".
4928 2014-02-19 Doug Evans <dje@google.com>
4930 * linux-low.c (add_lwp): Change result to struct lwp_info *.
4931 All callers updated.
4933 2014-02-19 Doug Evans <dje@google.com>
4935 * inferiors.c (add_thread): Fix whitespace.
4937 2014-02-19 Doug Evans <dje@google.com>
4939 * dll.c (clear_dlls): Replace accessing list implemention details
4941 * gdbthread.h (get_first_thread): Declare.
4942 * inferiors.c (for_each_inferior_with_data): New function.
4943 (get_first_thread): New function.
4944 (find_thread_ptid): Simplify.
4945 (get_first_inferior): New function.
4946 (clear_list): Delete.
4947 (one_inferior_p): New function.
4948 (clear_inferior_list): New function.
4949 (clear_inferiors): Update.
4950 * inferiors.h (for_each_inferior_with_data): Declare.
4951 (clear_inferior_list): Declare.
4952 (one_inferior_p): Declare.
4953 (get_first_inferior): Declare.
4954 * linux-low.c (linux_wait_for_event): Replace accessing list
4955 implemention details with API function.
4956 * server.c (target_running): Ditto.
4957 (accumulate_file_name_length): New function.
4958 (emit_dll_description): New function.
4959 (handle_qxfer_libraries): Replace accessing list implemention
4960 details with API function.
4961 (handle_qxfer_threads_worker): New function.
4962 (handle_qxfer_threads_proper): Replace accessing list implemention
4963 details with API function.
4964 (handle_query): Ditto.
4965 (visit_actioned_threads_callback_ftype): New typedef.
4966 (visit_actioned_threads_data): New struct.
4967 (visit_actioned_threads): Rewrite to be find_inferior callback.
4968 (resume): Call find_inferior.
4969 (handle_status): Replace accessing list implemention
4970 details with API function.
4971 (process_serial_event): Replace accessing list implemention details
4973 * target.c (set_desired_inferior): Replace accessing list implemention
4974 details with API function.
4975 * tracepoint.c (same_process_p): New function.
4976 (gdb_agent_about_to_close): Replace accessing list implemention
4977 details with API function.
4978 * win32-low.c (child_delete_thread): Replace accessing list
4979 implemention details with API function.
4980 (match_dll_by_basename): New function.
4981 (dll_is_loaded_by_basename): New function.
4982 (win32_ensure_ntdll_loaded): Replace accessing list implemention
4983 details call to dll_is_loaded_by_basename.
4985 2014-02-19 Doug Evans <dje@google.com>
4987 * dll.h (struct dll_info): Add comment.
4988 * gdbthread.h (struct thread_info): Add comment.
4989 (current_ptid): Simplify.
4990 * inferiors.c (add_process): Update.
4991 (remove_process): Update.
4992 * inferiors.h (struct process_info): Rename member "head" to "entry".
4993 * linux-low.c (delete_lwp): Update.
4995 (last_thread_of_process_p): Update.
4996 (kill_one_lwp_callback, linux_kill): Update.
4997 (status_pending_p_callback): Update.
4998 (wait_for_sigstop): Update. Simplify read of ptid.
4999 (start_step_over): Update.
5000 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
5001 (get_lwp_thread): Update.
5002 (struct lwp_info): Rename member "head" to "entry".
5003 * regcache.h (inferior_list_entry): Delete.
5004 * server.c (kill_inferior_callback): Update.
5005 (detach_or_kill_inferior_callback): Update.
5006 (print_started_pid): Update.
5007 (print_attached_pid): Update.
5008 (process_serial_event): Simplify read of ptid.
5009 * thread-db.c (thread_db_create_event): Update.
5010 (thread_db_get_tls_address): Update.
5011 * win32-low.c (current_inferior_ptid): Simplify.
5013 2014-02-19 Tom Tromey <tromey@redhat.com>
5015 * target.h (struct target_ops) <supports_btrace>: Add target_ops
5017 (target_supports_btrace): Update.
5019 2014-02-14 Yao Qi <yao@codesourcery.com>
5021 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
5022 (rsp-low-ipa.o): New target.
5024 2014-02-12 Tom Tromey <tromey@redhat.com>
5026 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
5027 convert_ascii_to_int.
5028 * regcache.c (registers_to_string): Likewise.
5029 * remote-utils.c (decode_M_packet): Likewise.
5030 * server.c (process_serial_event): Likewise.
5032 2014-02-12 Tom Tromey <tromey@redhat.com>
5034 * server.c (handle_query, handle_v_run): Use hex2bin, not
5036 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
5038 2014-02-12 Tom Tromey <tromey@redhat.com>
5040 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
5041 convert_int_to_ascii.
5042 * regcache.c (registers_to_string, collect_register_as_string):
5044 * remote-utils.c (look_up_one_symbol, relocate_instruction):
5046 * server.c (process_serial_event): Likewise.
5047 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
5048 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
5050 2014-02-12 Tom Tromey <tromey@redhat.com>
5052 * remote-utils.c (look_up_one_symbol, monitor_output): Use
5053 bin2hex, not hexify.
5054 * tracepoint.c (cmd_qtstatus): Likewise.
5056 2014-02-12 Tom Tromey <tromey@redhat.com>
5058 * remote-utils.c (monitor_output): Pass explicit length to
5061 2014-02-12 Tom Tromey <tromey@redhat.com>
5063 * tracepoint.c: Include rsp-low.h.
5064 * server.c: Include rsp-low.h.
5065 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
5066 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
5068 * remote-utils.c: Include rsp-low.h.
5069 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
5070 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
5071 (convert_int_to_ascii, convert_ascii_to_int): Move to
5073 * regcache.c: Include rsp-low.h.
5074 * ax.c: Include rsp-low.h.
5075 * Makefile.in (SFILES): Add common/rsp-low.c.
5076 (OBS): Add rsp-low.o.
5077 (rsp-low.o): New target.
5079 2014-02-12 Tom Tromey <tromey@redhat.com>
5081 * utils.h (pulongest, plongest, phex_nz): Don't declare.
5082 Include print-utils.h.
5083 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
5084 (plongest, thirty_two, phex_nz): Remove.
5085 * Makefile.in (SFILES): Add common/print-utils.c.
5086 (OBS): Add print-utils.o.
5087 (print-utils-ipa.o): New target.
5088 (print-utils.o): New target.
5089 (IPA_OBJS): Add print-utils-ipa.o.
5091 2014-02-06 Tom Tromey <tromey@redhat.com>
5093 * Makefile.in (SFILES): Fix indentation.
5095 2014-02-05 Doug Evans <dje@google.com>
5097 * linux-low.c (linux_wait_for_event): Improve comment.
5098 (linux_wait_1): Keep current_inferior in sync with event_child.
5100 2014-01-22 Doug Evans <dje@google.com>
5102 * gdbthread.h (gdb_id_to_thread): Delete, unused.
5104 2014-01-22 Doug Evans <dje@google.com>
5106 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
5107 * configure: Regenerate.
5108 * config.in: Regenerate.
5109 * Makefile.in (SFILES): Add debug.c.
5111 * debug.c: New file.
5112 * debug.h: New file.
5113 * linux-aarch64-low.c (*): Update all debugging printfs to use
5114 debug_printf instead of fprintf.
5115 * linux-arm-low.c (*): Ditto.
5116 * linux-cris-low.c (*): Ditto.
5117 * linux-crisv32-low.c (*): Ditto.
5118 * linux-m32r-low.c (*): Ditto.
5119 * linux-sparc-low.c (*): Ditto.
5120 * linux-x86.c (*): Ditto.
5121 * linux-low.c (*): Ditto.
5122 (linux_wait_1): Add calls to debug_enter, debug_exit.
5123 (linux_wait): Remove redundant debugging printf.
5124 (stop_all_lwps): Add calls to debug_enter, debug_exit.
5125 (linux_resume, unstop_all_lwps): Ditto.
5126 * mem-break.c (*): Update all debugging printfs to use
5127 debug_printf instead of fprintf.
5128 * remote-utils.c (*): Ditto.
5129 * thread-db.c (*): Ditto.
5130 * server.c #include <ctype.h>, "gdb_vecs.h".
5131 (debug_threads): Moved to debug.c.
5132 (*): Update all debugging printfs to use debug_printf instead of
5134 (start_inferior): Replace call to fflush with call to debug_flush.
5135 (monitor_show_help): Mention set debug-format.
5136 (parse_debug_format_options): New function.
5137 (handle_monitor_command): Handle "monitor set debug-format".
5138 (gdbserver_usage): Mention --debug-format.
5139 (main): Parse --debug-format.
5140 * server.h (debug_threads): Declaration moved to debug.h.
5142 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
5143 trace_debug_1 that uses debug_printf.
5144 (tracepoint_look_up_symbols): Update all debugging printfs to use
5145 debug_printf instead of fprintf.
5147 2014-01-20 Baruch Siach <baruch@tkos.co.il>
5149 * linux-xtensa-low.c: Include asm/ptrace.h instead of
5152 2014-01-17 Pedro Alves <palves@redhat.com>
5155 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
5156 defined after including gdb_proc_service.h.
5158 2014-01-16 Doug Evans <dje@google.com>
5160 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
5161 (match_dll): Use it.
5163 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
5165 * target.h (target_ops) <read_btrace>: Change parameters and
5166 return type to allow error reporting.
5167 * server.c (handle_qxfer_btrace): Support delta reads. Pass
5168 trace reading errors on.
5169 * linux-low.c (linux_low_read_btrace): Pass trace reading
5171 (linux_low_disable_btrace): New.
5173 2014-01-15 Doug Evans <dje@google.com>
5175 * inferiors.c (thread_id_to_gdb_id): Delete.
5176 * inferiors.h (thread_id_to_gdb_id): Delete.
5178 2014-01-13 Eli Zaretskii <eliz@gnu.org>
5180 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
5181 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
5184 2014-01-08 Pedro Alves <palves@redhat.com>
5186 * server.c (handle_status): Don't discard previous queued stop
5187 replies or thread's pending status here.
5188 (main) <disconnection>: Do it here instead.
5190 2014-01-08 Pedro Alves <palves@redhat.com>
5192 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
5193 * server.c (visit_actioned_threads, handle_pending_status): New
5195 (handle_v_cont): Factor out parts to ...
5196 (resume): ... this new function. If in all-stop, and a thread
5197 being resumed has a pending status, report it without actually
5199 (myresume): Adjust to use the new 'resume' function.
5200 (clear_pending_status_callback, set_pending_status_callback)
5201 (find_status_pending_thread_callback): New functions.
5202 (handle_status): Handle the case of multiple threads having
5203 interesting statuses to report. Report threads' real last signal
5204 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
5205 with an interesting thread to report the status for, instead of
5206 always reporting the status of the first thread.
5208 2014-01-01 Joel Brobecker <brobecker@adacore.com>
5210 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
5211 * gdbreplay.c (gdbreplay_version): Likewise.
5213 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
5215 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
5216 iov.iov_len with the real length in use.
5218 2013-12-13 Joel Brobecker <brobecker@adacore.com>
5220 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
5221 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
5222 for all targets that use win32-low.c.
5223 * win32-low.c (win32_ensure_ntdll_loaded): New function.
5224 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
5226 2013-12-13 Pedro Alves <palves@redhat.com>
5228 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
5229 if equal to TARGET_WAITKIND_LOADED.
5230 * win32-low.c (cached_status): New static global.
5231 (win32_wait): Add declaration.
5232 (do_initial_child_stuff): Flush all initial pending debug events
5233 up to the initial breakpoint.
5234 (win32_wait): If CACHED_STATUS was set, return that instead
5235 of doing a real wait. Remove the code resuming the execution
5236 of the inferior after receiving a TARGET_WAITKIND_LOADED event
5237 during the initial phase. Also remove the code changing
5238 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
5239 TARGET_WAITKIND_STOPPED.
5241 2013-12-11 Yao Qi <yao@codesourcery.com>
5243 * notif.c (handle_notif_ack): Return 0 if no notification
5246 2013-11-20 Doug Evans <dje@google.com>
5248 * linux-low.c (linux_set_resume_request): Fix comment.
5250 2013-11-20 Doug Evans <dje@google.com>
5252 * linux-low.c (resume_status_pending_p): Tweak comment.
5254 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
5256 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
5257 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
5258 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
5259 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
5260 (srv_amd64_regobj): Add amd64-mpx.o.
5261 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
5262 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
5263 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
5264 * i387-fp.c (num_pl_bnd_register) Added constant.
5265 (num_pl_bnd_cfg_registers) Added constant.
5266 (struct i387_xsave) Added reserved area and MPX fields.
5267 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
5268 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
5270 (tdesc_i386_mpx_linux): Add MPX amd64 target.
5271 (init_registers_amd64_mpx_linux): Declare new function.
5272 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
5273 (x86_64_regmap): Add MPX registers.
5274 (x86_linux_read_description): Add MPX case.
5275 (initialize_low_arch): Initialize MPX targets.
5277 2013-11-18 Tom Tromey <tromey@redhat.com>
5279 * configure: Rebuild.
5280 * configure.ac: Don't check for stdlib.h.
5281 * gdbreplay.c: Unconditionally include stdlib.h.
5283 2013-11-18 Tom Tromey <tromey@redhat.com>
5285 * config.in: Rebuild.
5286 * configure: Rebuild.
5287 * configure.ac: Don't use AC_HEADER_DIRENT.
5289 2013-11-18 Tom Tromey <tromey@redhat.com>
5291 * server.h: Don't check HAVE_STRING_H.
5292 * gdbreplay.c: Don't check HAVE_STRING_H.
5293 * configure: Rebuild.
5295 2013-11-18 Tom Tromey <tromey@redhat.com>
5297 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
5300 2013-11-08 Tom Tromey <tromey@redhat.com>
5302 * configure, config.in: Rebuild.
5303 * configure.ac: Remove unused configury.
5305 2013-11-08 Tom Tromey <tromey@redhat.com>
5307 * acinclude.m4: Include common.m4, codeset.m4.
5308 * configure, config.in: Rebuild.
5309 * configure.ac: Use GDB_AC_COMMON.
5311 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
5313 * linux-s390-low.c (HWCAP_S390_TE): New define.
5314 (s390_arch_setup): Consider the TE field in the HWCAP for
5315 determining 'have_regset_tdb'.
5317 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
5320 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
5323 2013-10-02 Pedro Alves <palves@redhat.com>
5325 * server.c (process_serial_event): Don't output "GDBserver
5326 exiting" if GDB is connected through stdio.
5327 * target.c (mywait): Likewise, be silent if GDB is connected
5330 2013-10-01 Joel Brobecker <brobecker@adacore.com>
5332 * lynx-low.c (lynx_add_threads_after_attach): New function.
5333 (lynx_attach): Remove call to add_thread. Add call to
5334 lynx_add_threads_after_attach instead.
5336 2013-09-28 Mike Frysinger <vapier@gentoo.org>
5338 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
5339 * config.in, configure: Regenerated.
5341 2013-09-18 Yao Qi <yao@codesourcery.com>
5344 * server.c (start_inferior): Clear 'resume_info'.
5346 2013-09-16 Jiong Wang <jiwang@tilera.com>
5348 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
5351 2013-09-16 Jiong Wang <jiwang@tilera.com>
5353 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
5354 linux-tile-low.o to srv_tgtobj.
5356 2013-09-16 Will Newton <will.newton@linaro.org>
5358 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
5361 2013-09-06 Pedro Alves <palves@redhat.com>
5363 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
5364 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
5365 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
5366 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
5367 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
5368 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
5370 2013-09-06 Pedro Alves <palves@redhat.com>
5372 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
5373 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
5375 2013-09-06 Pedro Alves <palves@redhat.com>
5377 * linux-amd64-ipa.c: Include tracepoint.h.
5378 * linux-i386-ipa.c: Include tracepoint.h.
5380 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
5382 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
5383 (ps_get_thread_area): New function.
5385 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
5387 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
5388 (initialize_low_arch): Call init_registers_crisv32 rather than
5389 init_register_crisv32.
5391 2013-09-05 Pedro Alves <palves@redhat.com>
5393 * server.h (handle_vFile, hostio_last_error_from_errno): Move
5395 * hostio.h: ... this new file.
5396 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
5397 win32-low.c: Include hostio.h.
5399 2013-09-05 Pedro Alves <palves@redhat.com>
5401 * server.h (gdb_client_data, handler_func, callback_handler_func)
5402 (delete_file_handler, add_file_handler, append_callback_event)
5403 (delete_callback_event, start_event_loop, initialize_event_loop):
5404 Move to event-loop.h and include it.
5405 * event-loop.h: New file.
5407 2013-09-05 Pedro Alves <palves@redhat.com>
5409 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
5410 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
5411 (loaded_dll, unloaded_dll): Move to ...
5412 * dll.h: ... this new file.
5413 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
5415 2013-09-05 Pedro Alves <palves@redhat.com>
5417 * server.h (current_process, get_thread_process, all_processes)
5418 (add_inferior_to_list, for_each_inferior, current_inferior)
5419 (remove_inferior, add_process, remove_process, find_process_pid)
5420 (have_started_inferiors_p, have_attached_inferiors_p)
5421 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
5422 (clear_inferiors, find_inferior, find_inferior_id)
5423 (inferior_target_data, set_inferior_target_data)
5424 (inferior_regcache_data, set_inferior_regcache_data): Move to
5425 inferiors.h, and include it.
5426 * inferiors.h: New file.
5428 2013-09-05 Pedro Alves <palves@redhat.com>
5430 * server.h (struct emit_ops, current_insn_ptr, emit_error):
5434 2013-09-05 Pedro Alves <palves@redhat.com>
5436 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
5438 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
5439 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
5440 (handle_tracepoint_general_set, handle_tracepoint_query)
5441 (tracepoint_finished_step, tracepoint_was_hit)
5442 (release_while_stepping_state_list, current_traceframe)
5443 (in_readonly_region, traceframe_read_mem)
5444 (fetch_traceframe_registers, traceframe_read_sdata)
5445 (traceframe_read_info, struct fast_tpoint_collect_status)
5446 (fast_tracepoint_collecting, force_unlock_trace_buffer)
5447 (handle_tracepoit_bkpts, initialize_low_tracepoint)
5448 (supply_fast_tracepoint_registers)
5449 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
5450 (ipa_tdesc, claim_trampoline_space)
5451 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
5452 (agent_mem_read, agent_get_trace_state_variable_value)
5453 (agent_set_trace_state_variable_value, agent_tsv_read)
5454 (agent_mem_read_string, get_raw_reg_func_addr)
5455 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
5456 * tracepoint.h: ... this new file.
5458 2013-09-05 Pedro Alves <palves@redhat.com>
5460 * server.h (perror_with_name, error, fatal, warning, paddress)
5461 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
5463 * utils.h: New file.
5465 2013-09-05 Pedro Alves <palves@redhat.com>
5467 * server.h (remote_debug, noack_mode, transport_is_reliable)
5468 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
5469 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
5470 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
5471 (write_enn, initialize_async_io, enable_async_io)
5472 (disable_async_io, check_remote_input_interrupt_request)
5473 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
5474 (dead_thread_notify, prepare_resume_reply)
5475 (decode_address_to_semicolon, decode_address, decode_m_packet)
5476 (decode_M_packet, decode_X_packet, decode_xfer_write)
5477 (decode_search_memory_packet, unhexify, hexify)
5478 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
5479 (look_up_one_symbol, relocate_instruction)
5480 (monitor_output): Move to remote-utils.h, and include it.
5481 * remote-utils.h: New file.
5483 2013-09-05 Pedro Alves <palves@redhat.com>
5485 * server.h (_): Delete.
5487 2013-09-02 Pedro Alves <palves@redhat.com>
5489 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
5490 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
5492 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
5494 2013-09-02 Pierre Muller <muller@sourceware.org>
5496 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
5497 or WriteProcessMemory complete successfully and handle
5498 ERROR_PARTIAL_COPY error.
5500 2013-09-02 Pedro Alves <palves@redhat.com>
5502 * server.c (gdb_read_memory): Return -1 on traceframe memory read
5503 error instead of EIO.
5505 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5508 * linux-low.c: Include filestuff.h.
5509 (linux_create_inferior) <pid == 0>: Call close_most_fds.
5510 * lynx-low.c: Include filestuff.h.
5511 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
5512 * server.c: Include filestuff.h.
5513 (main): Call notice_open_fds.
5514 * spu-low.c: Include filestuff.h.
5515 (spu_create_inferior) <pid == 0>: Call close_most_fds.
5517 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
5519 * Makefile.in: Explain why ../target and ../nat are not
5520 listed as include file search paths.
5521 (linux-waitpid.o): New object file rule.
5522 * configure.srv (srv_native_linux_obj): New variable.
5523 Replace all occurrences of linux native object files with
5524 $srv_native_linux_obj.
5525 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
5526 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
5527 (linux_enable_event_reporting): Remove declaration.
5528 (my_waitpid): Moved to common/linux-waitpid.c.
5529 (linux_wait_for_event): Pass ptid when calling
5530 linux_enable_event_reporting.
5531 (linux_supports_tracefork_flag): Remove.
5532 (linux_enable_event_reporting): Likewise.
5533 (linux_tracefork_grandchild): Remove.
5534 (STACK_SIZE): Moved to common/linux-ptrace.c.
5535 (linux_tracefork_child): Remove.
5536 (linux_test_for_tracefork): Remove.
5537 (linux_look_up_symbols): Call linux_supports_traceclone.
5538 (initialize_low): Remove call to linux_test_for_tracefork.
5539 * linux-low.h (PTRACE_TYPE_ARG3): Move to
5540 common/linux-ptrace.h.
5541 (PTRACE_TYPE_ARG4): Likewise.
5542 Include linux-ptrace.h.
5544 2013-08-21 Pedro Alves <palves@redhat.com>
5546 * config.in: Renegerate.
5548 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
5550 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
5551 (SFILES): Remove $(srcdir)/common/target-common.c and
5552 add $(srcdir)/target/waitstatus.c.
5553 (OBS): Remove target-common.o and add waitstatus.o.
5554 (server_h): Remove $(srcdir)/../common/target-common.h and
5555 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
5556 and $(srcdir)/../target/waitstatus.h.
5557 (target-common.o): Remove.
5558 (waitstatus.o): New target object file.
5559 * target.h: Do not include target-common.h and
5560 include target/resume.h, target/wait.h and
5561 target/waitstatus.h.
5563 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
5565 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
5566 to PTRACE_TYPE_ARG3.
5567 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
5568 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
5570 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
5571 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
5573 2013-07-27 Jie Zhang <jie@codesourcery.com>
5574 Daniel Jacobowitz <dan@codesourcery.com>
5575 Yao Qi <yao@codesourcery.com>
5577 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
5578 (mips-linux-watch.o): New rule.
5579 (mips_linux_watch_h): New variable.
5580 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
5582 * linux-mips-low.c: Include mips-linux-watch.h.
5583 (struct arch_process_info, struct arch_lwp_info): New.
5584 (update_watch_registers_callback): New function.
5585 (mips_linux_new_process, mips_linux_new_thread) New functions.
5586 (mips_linux_prepare_to_resume, mips_insert_point): New
5588 (mips_remove_point, mips_stopped_by_watchpoint): New
5590 (rsp_bp_type_to_target_hw_bp_type): New function.
5591 (mips_stopped_data_address): New function.
5592 (the_low_target): Add watchpoint support functions.
5594 2013-07-27 Yao Qi <yao@codesourcery.com>
5596 * i386-low.c: Include break-common.h.
5597 (enum target_hw_bp_type): Remove.
5599 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
5601 * Makefile.in (SFILES): /common/target-common.c.
5602 (OBS): Add target-common.o.
5603 (server_h): Add $(srcdir)/../common/target-common.h.
5604 (target-common.o): New target.
5605 * server.c (queue_stop_reply_callback): Free
5606 status string after use.
5607 * target.c (target_waitstatus_to_string): Remove.
5608 * target.h: Include target-common.h.
5609 (resume_kind): Likewise.
5610 (target_waitkind): Likewise.
5611 (target_waitstatus): Likewise.
5612 (TARGET_WNOHANG): Likewise.
5614 2013-07-04 Yao Qi <yao@codesourcery.com>
5616 * Makefile.in (host_alias): Use @host_noncanonical@.
5617 (target_alias): Use @target_noncanonical@.
5618 * configure.ac: Use ACX_NONCANONICAL_TARGET and
5619 ACX_NONCANONICAL_HOST.
5620 * configure: Regenerated.
5623 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
5625 * configure.ac (version_host, version_target): Set and AC_SUBST them.
5626 * configure: Rebuild.
5627 * Makefile.in (version_host, version_target): Get from configure.
5628 (version.c): Use $(version_host) and $(version_target).
5630 2013-07-03 Pedro Alves <palves@redhat.com>
5632 * Makefile.in (config.status): Depend on development.sh.
5633 * acinclude.m4: Include libmcheck.m4.
5634 * configure: Regenerate.
5636 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
5638 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
5639 attribute inside the parentheses.
5640 (winapi_DebugSetProcessKillOnExit): Ditto.
5641 (winapi_DebugBreakProcess): Ditto.
5642 (winapi_GenerateConsoleCtrlEvent): Ditto.
5644 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
5646 * notif.h (notif_event): Add a dummy member to avoid compiler
5649 2013-07-01 Pedro Alves <palves@redhat.com>
5651 * hostio.c (HOSTIO_PATH_MAX): Define.
5652 (require_filename, handle_open, handle_unlink, handle_readlink):
5655 2013-07-01 Pedro Alves <palves@redhat.com>
5657 * server.h: Include "pathmax.h".
5658 * linux-low.c: Don't include sys/param.h.
5659 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
5661 * win32-low.c: Don't include sys/param.h.
5662 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
5664 2013-07-01 Pedro Alves <palves@redhat.com>
5666 * event-loop.c: Don't check HAVE_UNISTD_H before including
5668 * gdbreplay.c: Likewise.
5669 * remote-utils.c: Likewise.
5670 * server.c: Likewise.
5671 * configure.ac: Don't check for unistd.h.
5672 * configure: Regenerate.
5674 2013-06-28 Tom Tromey <tromey@redhat.com>
5676 * Makefile.in (version.c): Use version.in, not
5679 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
5681 * configure.ac (version_host, version_target): Set and AC_SUBST them.
5682 * configure: Rebuild.
5683 * Makefile.in (version_host, version_target): Get from configure.
5684 (version.c): Use $(version_host) and $(version_target).
5686 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
5688 Fix trace-status to output user name without trailing colon.
5689 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
5691 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
5693 Fix trace-status to output proper start-time and stop-time.
5694 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
5695 output start time and stop time in hex as gdb expects.
5697 2013-06-26 Pedro Alves <pedro@codesourcery.com>
5699 * tracepoint.c (build_traceframe_info_xml): Output trace state
5700 variables present in the trace buffer.
5702 2013-06-24 Tom Tromey <tromey@redhat.com>
5704 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
5706 (version.o): Remove.
5707 * gdbreplay.c: Include version.h.
5708 (version, host_name): Don't declare.
5709 * server.h: Include version.h.
5710 (version, host_name): Don't declare.
5712 2013-06-12 Pedro Alves <palves@redhat.com>
5714 * linux-x86-low.c (linux_is_elf64): Delete global.
5715 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
5716 with local linux_pid_exe_is_elf_64_file use.
5718 2013-06-11 Pedro Alves <palves@redhat.com>
5720 * linux-low.c (regset_disabled, disable_regset): New functions.
5721 (regsets_fetch_inferior_registers)
5722 (regsets_store_inferior_registers): Use them.
5723 (initialize_regsets_info); Don't allocate the disabled_regsets
5725 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
5728 2013-06-11 Pedro Alves <palves@redhat.com>
5730 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
5733 2013-06-11 Pedro Alves <palves@redhat.com>
5735 * linux-x86-low.c (initialize_low_arch): Call
5736 init_registers_x32_avx_linux.
5738 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
5740 Fix compatibility with Android Bionic.
5741 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
5744 2013-06-07 Pedro Alves <palves@redhat.com>
5747 * Makefile.in (OBS): Add tdesc.o.
5748 (IPA_OBJS): Add tdesc-ipa.o.
5749 (tdesc-ipa.o): New rule.
5750 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
5752 * linux-low.c (new_inferior): Delete.
5753 (disabled_regsets, num_regsets): Delete.
5754 (linux_add_process): Adjust to set the new per-process
5756 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
5757 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
5758 was a stop. When calling arch_setup, switch the current inferior
5759 to the thread that got an event.
5760 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
5761 (regsets_fetch_inferior_registers)
5762 (regsets_store_inferior_registers): New regsets_info parameter.
5764 (linux_register_in_regsets): New regs_info parameter. Adjust to
5766 (register_addr, fetch_register, store_register): New usrregs_info
5767 parameter. Adjust to use it.
5768 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
5769 parameter regs_info. Adjust to use it.
5770 (linux_fetch_registers): Get the current inferior's regs_info, and
5772 (linux_store_registers): Ditto.
5773 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
5774 (initialize_low): Don't initialize the target_regsets here. Call
5775 initialize_low_arch.
5776 * linux-low.h (target_regsets): Delete declaration.
5777 (struct regsets_info): New.
5778 (struct usrregs_info): New.
5779 (struct regs_info): New.
5780 (struct process_info_private) <new_inferior>: New field.
5781 (struct linux_target_ops): Delete the num_regs, regmap, and
5782 regset_bitmap fields. New field regs_info.
5783 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
5784 * i387-fp.c (num_xmm_registers): Delete.
5785 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
5786 calls to new interface.
5787 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
5788 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
5789 Infer the number of xmm registers from the regcache's target
5791 * i387-fp.h (num_xmm_registers): Delete.
5792 * inferiors.c (add_thread): Don't install the thread's regcache
5794 * proc-service.c (gregset_info): Fetch the current inferior's
5795 regs_info. Adjust to use it.
5796 * regcache.c: Include tdesc.h.
5797 (register_bytes, reg_defs, num_registers)
5798 (gdbserver_expedite_regs): Delete.
5799 (get_thread_regcache): If the thread doesn't have a regcache yet,
5800 create one, instead of aborting gdbserver.
5801 (regcache_invalidate_one): Rename to ...
5802 (regcache_invalidate_thread): ... this.
5803 (regcache_invalidate_one): New.
5804 (regcache_invalidate): Only invalidate registers of the current
5806 (init_register_cache): Add target_desc parameter, and use it.
5807 (new_register_cache): Ditto. Assert the target description has a
5808 non zero registers_size.
5809 (regcache_cpy): Add assertions. Adjust.
5810 (realloc_register_cache, set_register_cache): Delete.
5811 (registers_to_string, registers_from_string): Adjust.
5812 (find_register_by_name, find_regno, find_register_by_number)
5813 (register_cache_size): Add target_desc parameter, and use it.
5814 (free_register_cache_thread, free_register_cache_thread_one)
5815 (regcache_release, register_cache_size): New.
5816 (register_size): Add target_desc parameter, and use it.
5817 (register_data, supply_register, supply_register_zeroed)
5818 (supply_regblock, supply_register_by_name, collect_register)
5819 (collect_register_as_string, collect_register_by_name): Adjust.
5820 * regcache.h (struct target_desc): Forward declare.
5821 (struct regcache) <tdesc>: New field.
5822 (init_register_cache, new_register_cache): Add target_desc
5824 (regcache_invalidate_thread): Declare.
5825 (regcache_invalidate_one): Delete declaration.
5826 (regcache_release): Declare.
5827 (find_register_by_number, register_cache_size, register_size)
5828 (find_regno): Add target_desc parameter.
5829 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
5831 * remote-utils.c: Include tdesc.h.
5832 (outreg, prepare_resume_reply): Adjust.
5833 * server.c: Include tdesc.h.
5834 (gdbserver_xmltarget): Delete declaration.
5835 (get_features_xml, process_serial_event): Adjust.
5836 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
5838 (struct process_info) <tdesc>: New field.
5839 (ipa_tdesc): Declare.
5840 * tdesc.c: New file.
5841 * tdesc.h: New file.
5842 * tracepoint.c: Include tdesc.h.
5843 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
5844 (get_context_regcache): Adjust to pass ipa_tdesc down.
5845 (do_action_at_tracepoint): Adjust to get the register cache size
5846 from the context regcache's description.
5847 (traceframe_walk_blocks): Adjust to get the register cache size
5848 from the current trace frame's description.
5849 (traceframe_get_pc): Adjust to get current trace frame's
5850 description and pass it down.
5851 (gdb_collect): Adjust to get the register cache size from the
5853 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
5854 (gdbserver_xmltarget): Delete.
5855 (initialize_low_tracepoint): Set the ipa's target description.
5856 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
5857 (initialize_low_tracepoint): Set the ipa's target description.
5858 * linux-x86-low.c: Include tdesc.h.
5859 [__x86_64__] (is_64bit_tdesc): New.
5860 (ps_get_thread_area, x86_get_thread_area): Use it.
5861 (i386_cannot_store_register): Rename to ...
5862 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
5863 (i386_cannot_fetch_register): Rename to ...
5864 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
5865 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
5867 (target_regsets): Rename to ...
5868 (x86_regsets): ... this.
5869 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
5871 (x86_siginfo_fixup): Use is_64bit_tdesc.
5872 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
5873 (tdesc_x32_avx_linux, tdesc_x32_linux)
5874 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
5876 (x86_linux_update_xmltarget): Delete.
5877 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
5878 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
5879 (AMD64_LINUX_USER64_CS): New.
5880 (x86_linux_read_description): New, based on
5881 x86_linux_update_xmltarget.
5882 (same_process_callback): New.
5883 (x86_arch_setup_process_callback): New.
5884 (x86_linux_update_xmltarget): New.
5885 (x86_regsets_info): New.
5886 (amd64_linux_regs_info): New.
5887 (i386_linux_usrregs_info): New.
5888 (i386_linux_regs_info): New.
5889 (x86_linux_regs_info): New.
5890 (x86_arch_setup): Reimplement.
5891 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
5892 (x86_emit_ops): Ditto.
5893 (the_low_target): Adjust. Install x86_linux_regs_info,
5894 x86_cannot_fetch_register, and x86_cannot_store_register.
5895 (initialize_low_arch): New.
5896 * linux-ia64-low.c (tdesc_ia64): Declare.
5897 (ia64_fetch_register): Adjust.
5898 (ia64_usrregs_info, regs_info): New globals.
5899 (ia64_regs_info): New function.
5900 (the_low_target): Adjust.
5901 (initialize_low_arch): New function.
5902 * linux-sparc-low.c (tdesc_sparc64): Declare.
5903 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
5905 (sparc_arch_setup): New function.
5906 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
5907 (the_low_target): Adjust.
5908 (initialize_low_arch): New function.
5909 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
5910 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
5911 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
5912 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
5913 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
5914 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
5915 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
5916 (tdesc_powerpc_isa205_vsx64l): Declare.
5917 (ppc_cannot_store_register, ppc_collect_ptrace_register)
5918 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
5919 (ppc_set_pc, ppc_get_hwcap): Adjust.
5920 (ppc_usrregs_info): Forward declare.
5921 (!__powerpc64__) ppc_regmap_adjusted: New global.
5922 (ppc_arch_setup): Adjust to the current process'es target
5924 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
5925 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
5926 (ppc_store_evrregset): Adjust.
5927 (target_regsets): Rename to ...
5928 (ppc_regsets): ... this, and make static.
5929 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
5930 (ppc_regs_info): New function.
5931 (the_low_target): Adjust.
5932 (initialize_low_arch): New function.
5933 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
5934 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
5935 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
5936 (tdesc_s390x_linux64v2): Declare.
5937 (s390_collect_ptrace_register, s390_supply_ptrace_register)
5938 (s390_fill_gregset, s390_store_last_break): Adjust.
5939 (target_regsets): Rename to ...
5940 (s390_regsets): ... this, and make static.
5941 (s390_get_pc, s390_set_pc): Adjust.
5942 (s390_get_hwcap): New target_desc parameter, and use it.
5943 [__s390x__] (have_hwcap_s390_high_gprs): New global.
5944 (s390_arch_setup): Adjust to set the current process'es target
5945 description. Don't adjust the regmap.
5946 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
5947 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
5948 (regs_info_3264): New globals.
5949 (s390_regs_info): New function.
5950 (the_low_target): Adjust.
5951 (initialize_low_arch): New function.
5952 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
5953 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
5954 [__mips64] (init_registers_mips_linux)
5955 (init_registers_mips_dsp_linux): Delete defines.
5956 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
5957 (have_dsp): New global.
5958 (mips_read_description): New, based on mips_arch_setup.
5959 (mips_arch_setup): Reimplement.
5960 (get_usrregs_info): New function.
5961 (mips_cannot_fetch_register, mips_cannot_store_register)
5962 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
5963 (mips_fill_fpregset, mips_store_fpregset): Adjust.
5964 (target_regsets): Rename to ...
5965 (mips_regsets): ... this, and make static.
5966 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
5967 (dsp_regs_info, regs_info): New globals.
5968 (mips_regs_info): New function.
5969 (the_low_target): Adjust.
5970 (initialize_low_arch): New function.
5971 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
5972 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
5974 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
5975 (arm_read_description): New, with bits factored from
5977 (arm_arch_setup): Reimplement.
5978 (target_regsets): Rename to ...
5979 (arm_regsets): ... this, and make static.
5980 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
5981 (arm_regs_info): New function.
5982 (the_low_target): Adjust.
5983 (initialize_low_arch): New function.
5984 * linux-m68k-low.c (tdesc_m68k): Declare.
5985 (target_regsets): Rename to ...
5986 (m68k_regsets): ... this, and make static.
5987 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
5988 (m68k_regs_info): New function.
5989 (m68k_arch_setup): New function.
5990 (the_low_target): Adjust.
5991 (initialize_low_arch): New function.
5992 * linux-sh-low.c (tdesc_sharch): Declare.
5993 (target_regsets): Rename to ...
5994 (sh_regsets): ... this, and make static.
5995 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
5996 (sh_regs_info, sh_arch_setup): New functions.
5997 (the_low_target): Adjust.
5998 (initialize_low_arch): New function.
5999 * linux-bfin-low.c (tdesc_bfin): Declare.
6000 (bfin_arch_setup): New function.
6001 (bfin_usrregs_info, regs_info): New globals.
6002 (bfin_regs_info): New function.
6003 (the_low_target): Adjust.
6004 (initialize_low_arch): New function.
6005 * linux-cris-low.c (tdesc_cris): Declare.
6006 (cris_arch_setup): New function.
6007 (cris_usrregs_info, regs_info): New globals.
6008 (cris_regs_info): New function.
6009 (the_low_target): Adjust.
6010 (initialize_low_arch): New function.
6011 * linux-cris-low.c (tdesc_crisv32): Declare.
6012 (cris_arch_setup): New function.
6013 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
6014 (cris_regs_info): New function.
6015 (the_low_target): Adjust.
6016 (initialize_low_arch): New function.
6017 * linux-m32r-low.c (tdesc_m32r): Declare.
6018 (m32r_arch_setup): New function.
6019 (m32r_usrregs_info, regs_info): New globals.
6020 (m32r_regs_info): Adjust.
6021 (initialize_low_arch): New function.
6022 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
6023 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
6024 (tic6x_usrregs_info): Forward declare.
6025 (tic6x_read_description): New function, based on ...
6026 (tic6x_arch_setup): ... this. Reimplement.
6027 (target_regsets): Rename to ...
6028 (tic6x_regsets): ... this, and make static.
6029 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
6030 (tic6x_regs_info): New function.
6031 (the_low_target): Adjust.
6032 (initialize_low_arch): New function.
6033 * linux-xtensa-low.c (tdesc_xtensa): Declare.
6034 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
6035 (target_regsets): Rename to ...
6036 (xtensa_regsets): ... this, and make static.
6037 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
6039 (xtensa_arch_setup, xtensa_regs_info): New functions.
6040 (the_low_target): Adjust.
6041 (initialize_low_arch): New function.
6042 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
6043 (nios2_arch_setup): Set the current process'es tdesc.
6044 (target_regsets): Rename to ...
6045 (nios2_regsets): ... this.
6046 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
6047 (nios2_regs_info): New function.
6048 (the_low_target): Adjust.
6049 (initialize_low_arch): New function.
6050 * linux-aarch64-low.c (tdesc_aarch64): Declare.
6051 (aarch64_arch_setup): Set the current process'es tdesc.
6052 (target_regsets): Rename to ...
6053 (aarch64_regsets): ... this.
6054 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
6055 (aarch64_regs_info): New function.
6056 (the_low_target): Adjust.
6057 (initialize_low_arch): New function.
6058 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
6060 (target_regsets): Rename to ...
6061 (tile_regsets): ... this.
6062 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
6063 (tile_regs_info): New function.
6064 (tile_arch_setup): Set the current process'es tdesc.
6065 (the_low_target): Adjust.
6066 (initialize_low_arch): New function.
6067 * spu-low.c (tdesc_spu): Declare.
6068 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
6069 * win32-arm-low.c (tdesc_arm): Declare.
6070 (arm_arch_setup): New function.
6071 (the_low_target): Install arm_arch_setup instead of
6073 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
6074 (init_windows_x86): Rename to ...
6075 (i386_arch_setup): ... this. Set `win32_tdesc'.
6076 (the_low_target): Adjust.
6077 * win32-low.c (win32_tdesc): New global.
6078 (child_add_thread): Don't create the thread cache here.
6079 (do_initial_child_stuff): Set the new process'es tdesc.
6080 * win32-low.h (struct target_desc): Forward declare.
6081 (win32_tdesc): Declare.
6082 * lynx-i386-low.c (tdesc_i386): Declare global.
6083 (lynx_i386_arch_setup): Set `lynx_tdesc'.
6084 * lynx-low.c (lynx_tdesc): New global.
6085 (lynx_add_process): Set the new process'es tdesc.
6086 * lynx-low.h (struct target_desc): Forward declare.
6087 (lynx_tdesc): Declare global.
6088 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
6089 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
6090 * nto-low.c (nto_tdesc): New global.
6091 (do_attach): Set the new process'es tdesc.
6092 * nto-low.h (struct target_desc): Forward declare.
6093 (nto_tdesc): Declare.
6094 * nto-x86-low.c (tdesc_i386): Declare.
6095 (nto_x86_arch_setup): Set `nto_tdesc'.
6097 2013-06-04 Gary Benson <gbenson@redhat.com>
6099 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
6100 to qSupported response when appropriate.
6101 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
6102 with nonzero-length annex.
6103 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
6104 arguments supplied in annex.
6106 2013-05-31 Doug Evans <dje@google.com>
6109 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
6110 64 bits in 64-cross-32 environment.
6112 2013-05-28 Pedro Alves <palves@redhat.com>
6114 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
6115 (aarch64-without-fpu.c): Delete rule.
6116 * configure.srv (aarch64*-*-linux*): Remove references to
6117 aarch64-without-fpu.o and aarch64-without-fpu.xml.
6118 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
6121 2013-05-24 Pedro Alves <palves@redhat.com>
6123 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
6124 instead of strchr/decode_address. Error if the range isn't split
6125 with a ','. Don't assume there's be a ':' in the action.
6127 2013-05-23 Yao Qi <yao@codesourcery.com>
6128 Pedro Alves <palves@redhat.com>
6130 * linux-low.c (lwp_in_step_range): New function.
6131 (linux_wait_1): If the thread was range stepping and stopped
6132 outside the stepping range, report the stop to GDB. Otherwise,
6133 continue stepping. Add range stepping debug output.
6134 (linux_set_resume_request): Copy the step range from the resume
6136 (linux_supports_range_stepping): New.
6137 (linux_target_ops) <supports_range_stepping>: Set to
6138 linux_supports_range_stepping.
6139 * linux-low.h (struct linux_target_ops)
6140 <supports_range_stepping>: New field.
6141 (struct lwp_info) <step_range_start, step_range_end>: New fields.
6142 * linux-x86-low.c (x86_supports_range_stepping): New.
6143 (the_low_target) <supports_range_stepping>: Set to
6144 x86_supports_range_stepping.
6145 * server.c (handle_v_cont): Handle 'r' action.
6146 (handle_v_requests): Append ";r" if the target supports range
6148 * target.h (struct thread_resume) <step_range_start,
6149 step_range_end>: New fields.
6150 (struct target_ops) <supports_range_stepping>:
6152 (target_supports_range_stepping): New macro.
6154 2013-05-17 Joel Brobecker <brobecker@adacore.com>
6156 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
6157 confusion in comment.
6159 2013-05-17 Joel Brobecker <brobecker@adacore.com>
6161 * lynx-low.c (struct process_info_private): New type.
6162 (lynx_add_process): New function.
6163 (lynx_create_inferior, lynx_attach): Replace calls to
6164 add_process by calls to lynx_add_process.
6165 (lynx_resume): If PTID is null, then try using
6166 current_process()->private->last_wait_event_ptid.
6168 (lynx_clear_inferiors): Delete. The contents of that function
6169 has been inlined in lynx_mourn;
6170 (lynx_wait_1): Save the ptid in the process's private data.
6171 (lynx_mourn): Free the process' private data. Replace call
6172 to lynx_clear_inferiors by call to clear_inferiors.
6174 2013-05-17 Yao Qi <yao@codesourcery.com>
6176 * i386-low.c (i386_length_and_rw_bits): Move the comment to
6179 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
6181 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
6182 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
6183 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
6184 PT_TEXT_END_ADDR guards. Update comments.
6185 (linux_target_op) <read_offsets>: Conditionally define to
6186 linux_read_offsets if the target is UCLIBC and if it defines
6187 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
6189 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
6190 Andrew Jenner <andrew@codesourcery.com>
6192 * Makefile.in (SFILES): Add linux-nios2-low.c.
6193 (clean): Add action to delete nios2-linux.c.
6194 (nios2-linux.c): New rule.
6195 * configure.srv: Add nios2*-*-linux*.
6196 * linux-nios2-low.c: New.
6198 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
6200 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
6202 2013-04-25 Hui Zhu <hui@codesourcery.com>
6205 * ax.c (ax_printf): Add fflush.
6207 2013-04-22 Tom Tromey <tromey@redhat.com>
6209 * Makefile.in (SFILES): Add filestuff.c.
6210 (OBS): Add filestuff.o.
6211 (filestuff.o): New target.
6212 * config.in, configure: Rebuild.
6213 * configure.ac: Check for fdwalk, pipe2.
6215 2013-04-17 Pedro Alves <palves@redhat.com>
6217 * configure.ac (USE_THREAD_DB): Delete variable.
6218 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
6219 Don't AC_SUBST USE_THREAD_DB.
6220 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
6221 * config.in, configure: Regenerate.
6223 2013-04-16 Pedro Alves <palves@redhat.com>
6225 * linux-low.h (struct lwp_info) <thread_known>: Move under
6226 the USE_THREAD_DB #ifdef.
6228 2013-04-16 Pedro Alves <palves@redhat.com>
6230 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
6231 (linux-low.o): Delete rule.
6232 * linux-low.h: Always include "gdb_thread_db.h" instead of
6233 conditionally including thread_db.h.
6234 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
6237 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
6239 * Makefile.in (install-only): Fix make install regression.
6241 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
6243 Convert man pages to texinfo, new gdbinit.5 texinfo page.
6244 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
6246 * gdbserver.1: Remove.
6248 2013-03-22 Pedro Alves <palves@redhat.com>
6250 * linux-low.c (handle_extended_wait): Don't call
6251 linux_enable_event_reporting.
6253 2013-03-15 Tony Theodore <tonyt@logyst.com>
6256 * Makefile.in (SHELL): Use @SHELL@.
6258 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
6260 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
6263 2013-03-13 Joel Brobecker <brobecker@adacore.com>
6265 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
6266 Remove extraneous NULL element.
6268 2013-03-13 Yao Qi <yao@codesourcery.com>
6270 * tracepoint.c (traceframe_read_tsv): Look for the last matched
6271 'V' block in trace frame.
6273 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
6275 * target.h (struct target_ops): Add btrace ops.
6276 (target_supports_btrace): New macro.
6277 (target_enable_btrace): New macro.
6278 (target_disable_btrace): New macro.
6279 (target_read_btrace): New macro.
6280 * gdbthread.h (struct thread_info): Add btrace field.
6281 * server.c: Include btrace-common.h.
6282 (handle_btrace_general_set): New function.
6283 (handle_btrace_enable): New function.
6284 (handle_btrace_disable): New function.
6285 (handle_general_set): Call handle_btrace_general_set.
6286 (handle_qxfer_btrace): New function.
6287 (struct qxfer qxfer_packets[]): Add btrace entry.
6288 * inferiors.c (remove_thread): Disable btrace.
6289 * linux-low: Include linux-btrace.h.
6290 (linux_low_enable_btrace): New function.
6291 (linux_low_read_btrace): New function.
6292 (linux_target_ops): Add btrace ops.
6293 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
6294 Add srv_linux_btrace=yes.
6295 (x86_64-*-linux*): Add linux-btrace.o.
6296 Add srv_linux_btrace=yes.
6297 * configure.ac: Define HAVE_LINUX_BTRACE.
6298 * config.in: Regenerated.
6299 * configure: Regenerated.
6301 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
6303 * server.c (handle_qxfer): Preserve error message if -3 is
6305 (qxfer): Document the -3 return value.
6307 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
6309 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
6310 (linux_btrace_h): New variable.
6311 (linux-btrace.o): New rule.
6313 2013-03-08 Stan Shebs <stan@codesourcery.com>
6314 Hafiz Abid Qadeer <abidh@codesourcery.com>
6316 * tracepoint.c (trace_buffer_size): New global.
6317 (DEFAULT_TRACE_BUFFER_SIZE): New define.
6318 (init_trace_buffer): Change to one-argument function. Allocate
6319 trace buffer memory.
6320 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
6321 handle QTBuffer:size packet.
6322 (cmd_bigqtbuffer_size): New function.
6323 (initialize_tracepoint): Call init_trace_buffer with
6324 DEFAULT_TRACE_BUFFER_SIZE.
6325 * server.c (handle_query): Add QTBuffer:size in the
6328 2013-03-07 Yao Qi <yao@codesourcery.com>
6330 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
6331 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
6333 (cmd_qtsp): Adjust condition. Do post increment.
6334 Set cur_action and cur_step_action back to 0.
6336 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
6339 * linux-low.c (linux_write_memory): Return early success if LEN is
6342 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
6344 * configure.srv: Add x86_64-*-cygwin* as target.
6346 2013-02-28 Tom Tromey <tromey@redhat.com>
6348 * configure.ac: Invoke AC_SYS_LARGEFILE.
6349 * configure, config.in: Rebuild.
6351 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
6353 * win32-low.c: Throughout, fix format strings and casts of
6354 printf-like functions to avoid type related warnings on all
6356 (get_child_debug_event): Print dwDebugEventCode as hex since
6357 that's how it's usually documented.
6359 2013-02-28 Yao Qi <yao@codesourcery.com>
6361 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
6364 2013-02-27 Jiong Wang <jiwang@tilera.com>
6366 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
6367 (reg-tilegx32.c): New rule.
6368 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
6369 * linux-tile-low.c (tile_arch_setup): New function. Invoke
6370 different register info initializer according to elf class.
6371 (init_registers_tilgx32): New function. The tilegx32 register info
6373 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
6374 (tile_store_gregset): Likewise.
6376 2013-02-27 Yao Qi <yao@codesourcery.com>
6378 * server.c (process_point_options): Print debug message when
6379 debug_threads is true.
6381 2013-02-26 Yao Qi <yao@codesourcery.com>
6383 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
6385 2013-02-19 Pedro Alves <palves@redhat.com>
6386 Kai Tietz <ktietz@redhat.com>
6390 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
6391 instead of strtoul to extract address from packet.
6392 (process_serial_event) <'z'>: Likewise.
6394 2013-02-18 Yao Qi <yao@codesourcery.com>
6396 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
6398 2013-02-14 Pedro Alves <palves@redhat.com>
6402 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
6403 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
6405 2013-02-14 Pedro Alves <palves@redhat.com>
6407 * tracepoint.c (cmd_qtdpsrc): Use savestring.
6409 2013-02-14 Pedro Alves <palves@redhat.com>
6411 * tracepoint.c (save_string): Delete.
6412 (add_tracepoint_action): Use savestring instead of save_string.
6414 2013-02-12 Pedro Alves <palves@redhat.com>
6416 * linux-xtensa-low.c: Ditto.
6417 * xtensa-xtregs.c: Ditto.
6419 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
6421 * thread-db.c (thread_db_get_tls_address): NULL pointer check
6424 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
6426 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
6427 aarch64_num_wp_regs and aarch64_num_bp_regs to
6428 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
6430 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
6432 * linux-aarch64-low.c (ps_get_thread_area): Replace
6433 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
6435 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
6436 Marcus Shawcroft <marcus.shawcroft@arm.com>
6437 Nigel Stephens <nigel.stephens@arm.com>
6438 Yufeng Zhang <yufeng.zhang@arm.com>
6440 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
6441 (aarch64.c, aarch64-without-fpu.c): New targets.
6442 * configure.srv (aarch64*-*-linux*): New.
6443 * linux-aarch64-low.c: New file.
6445 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
6447 * linux-low.c (handle_extended_wait, linux_create_inferior)
6448 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
6449 (dequeue_one_deferred_signal, linux_resume_one_thread)
6450 (fetch_register, linux_write_memory, linux_enable_event_reporting)
6451 (linux_tracefork_grandchild, linux_test_for_tracefork)
6452 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
6453 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
6454 where the argument is 0.
6456 2013-01-25 Yao Qi <yao@codesourcery.com>
6458 * event-loop.c: Include "queue.h".
6459 (gdb_event_p): New typedef.
6460 (struct gdb_event) <next_event>: Remove.
6461 (event_queue): Change to QUEUE(gdb_event_p).
6462 (async_queue_event): Remove.
6463 (gdb_event_xfree): New.
6464 (initialize_event_loop): New.
6465 (process_event): Use API from QUEUE.
6466 (wait_for_event): Likewise.
6467 * server.c (main): Call initialize_event_loop.
6468 * server.h (initialize_event_loop): Declare.
6470 2013-01-18 Yao Qi <yao@codesourcery.com>
6472 * ax.h (struct eval_agent_expr_context): New.
6473 (gdb_eval_agent_expr): Update declaration.
6474 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
6475 TFRAME. Add new argument CTX.
6476 * server.h (struct eval_agent_expr_context): Declare.
6477 (agent_mem_read, agent_tsv_read): Update declaration.
6478 (agent_mem_read_string): Likewise.
6479 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
6480 (add_traceframe_block): Add new argument TPOINT.
6481 Increase TPOINT->traceframe_usage.
6482 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
6483 eval_tracepoint_agent_expr.
6484 (condition_true_at_tracepoint): Likewise.
6485 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
6486 (agent_mem_read_string, agent_tsv_read): Likewise.
6488 2013-01-16 Yao Qi <yao@codesourcery.com>
6490 * linux-low.c (linux_resume_one_lwp): Don't check
6491 'lwp->bp_reinsert != 0'.
6493 2013-01-07 Joel Brobecker <brobecker@adacore.com>
6494 Pedro Alves <palves@redhat.com>
6496 * lynx-low.c (ptrace_request_to_str): Define a temporary
6497 macro and use it to simplify this function's implementation.
6499 2013-01-07 Joel Brobecker <brobecker@adacore.com>
6501 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
6504 2013-01-07 Joel Brobecker <brobecker@adacore.com>
6506 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
6508 2013-01-07 Joel Brobecker <brobecker@adacore.com>
6510 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
6512 2013-01-07 Joel Brobecker <brobecker@adacore.com>
6514 * lynx-low.c (lynx_resume): Use the resume_info parameter
6515 to determine the ptid for the lynx_ptrace call, unless
6516 it is equal to minus_one_ptid, in which case we use the
6517 ptid of the current_inferior.
6518 (lynx_wait_1): After having received a thread create/exit
6519 event, resume the inferior's execution using the signaling
6520 thread's ptid, rather than the old ptid.
6522 2013-01-07 Joel Brobecker <brobecker@adacore.com>
6524 * lynx-low.c (lynx_resume): Delete variable ret.
6526 2013-01-01 Joel Brobecker <brobecker@adacore.com>
6528 * gdbreplay.c (gdbreplay_version): Update copyright year.
6529 * server.c (gdbserver_version): Likewise.
6531 2012-12-17 Joel Brobecker <brobecker@adacore.com>
6533 * lynx-low.c (lynx_wait_1): Add debug trace before adding
6536 2012-12-17 Joel Brobecker <brobecker@adacore.com>
6538 * lynx-low.c (ptrace_request_to_str): Add handling for
6541 2012-12-17 Joel Brobecker <brobecker@adacore.com>
6543 * lynx-low.c (lynx_attach): Delete variable new_process.
6545 2012-12-17 Joel Brobecker <brobecker@adacore.com>
6547 * lynx-low.c (lynx_create_inferior): Delete variable
6550 2012-12-17 Joel Brobecker <brobecker@adacore.com>
6552 * lynx-low.c (ptrace_request_to_str): Do not handle
6553 PTRACE_GETTHREADLIST if this macro does not exist.
6555 2012-12-15 Yao Qi <yao@codesourcery.com>
6557 * Makefile.in (OBS): Add notif.o.
6558 * notif.c, notif.h: New.
6559 * server.c: Include "notif.h".
6560 (struct vstop_notif) <next>: Remove.
6562 (queue_stop_reply): Update.
6563 (push_event, send_next_stop_reply): Remove.
6564 (discard_queued_stop_replies): Update.
6565 (notif_stop): New variable.
6566 (handle_v_stopped): Remove.
6567 (handle_v_requests): Don't call handle_v_stopped. Call
6568 handle_ack_notif instead.
6569 (queue_stop_reply_callback): Call notif_event_enque instead
6570 of queue_stop_reply.
6571 (handle_status): Don't call send_next_stop_reply, call
6572 notif_write_event instead.
6573 (kill_inferior_callback): Likewise.
6574 (detach_or_kill_inferior_callback): Likewise.
6575 (main): Call initialize_notif.
6576 (process_serial_event): Call QUEUE_is_empty.
6577 (handle_target_event): Call notif_push instead of push event.
6578 * server.h (push_event): Remove declaration.
6580 2012-12-10 Tom Tromey <tromey@redhat.com>
6582 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
6583 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
6586 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
6587 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
6588 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
6589 (amd64-linux-ipa.o, ax.o): Rewrite.
6590 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
6591 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
6592 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
6593 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
6594 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
6595 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
6596 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
6597 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
6598 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
6599 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
6600 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
6601 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
6602 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
6603 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
6604 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
6605 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
6606 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
6607 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
6608 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
6609 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
6610 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
6611 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
6612 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
6613 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
6614 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
6615 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
6616 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
6617 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
6618 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
6619 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
6620 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
6621 (reg-tilegx.o): Remove.
6622 (all_object_files): New macro.
6623 Include .deps files.
6624 * aclocal.m4, configure: Rebuild.
6625 * acinclude.m4: Include depstand.m4, lead-dot.m4.
6626 * configure.ac: Invoke ZW_CREATE_DEPDIR,
6627 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
6629 2012-12-05 Tom Tromey <tromey@redhat.com>
6632 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
6634 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
6636 * configure.ac: Check for linux/perf_event.h.
6637 * config.in: Regenerated.
6638 * configure: Regenerated.
6640 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
6642 * hostio.c (handle_readlink): Decrease buffer size
6643 parameter passed to readlink by one byte.
6645 2012-11-26 Yao Qi <yao@codesourcery.com>
6647 * configure.ac (build_warnings): Append '-Wempty-body'.
6648 * configure: Regenerated.
6649 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
6652 2012-11-15 Pierre Muller <muller@sourceware.org>
6654 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
6655 * config.in: Regenerate.
6656 * configure: Regenerate.
6657 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
6658 Use "gdb_wait.h" header instead of <sys/wait.h> header.
6659 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
6660 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
6662 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
6663 instead of <sys/wait.h> header.
6664 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
6666 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
6668 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
6669 (various make rules): Remove -DGDBSERVER
6671 2012-11-09 Yao Qi <yao@codesourcery.com>
6673 * spu-low.c (current_ptid): Move it to ..
6674 * gdbthread.h: ... here. New.
6675 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
6676 * server.c (myresume, process_serial_event): Likewise.
6677 * thread-db.c (thread_db_find_new_threads): Likewise.
6678 * tracepoint.c (run_inferior_command): Likewise.
6680 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
6682 * server.c (handle_search_memory_1): Include access length in
6685 2012-09-05 Michael Brandt <michael.brandt@axis.com>
6687 * linux-crisv32-low.c: Fix compile errors.
6689 2012-09-04 Yao Qi <yao@codesourcery.com>
6691 * tracepoint.c (cmd_qtsv): Adjust debug message.
6692 Don't check CUR_TPOINT.
6694 2012-08-28 Yao Qi <yao@codesourcery.com>
6696 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
6697 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
6698 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
6699 Remove declarations of xmalloc, xreallloc, xstrdup and
6701 * Makefile.in (libiberty_h): New.
6702 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
6703 (linux-bfin-low.o): Append dependency 'libiberty.h'.
6705 2012-08-23 Yao Qi <yao@codesourcery.com>
6707 * server.h: Remove declaration of 'xsnprintf'.
6709 2012-08-22 Keith Seitz <keiths@redhat.com>
6711 * server.h: Include build-gnulib-gbserver/config.h.
6712 * gdbreplay.c: Likewise.
6714 2012-08-08 Doug Evans <dje@google.com>
6716 * Makefile.in (SFILES): Add gdb_vecs.c.
6717 (OBS): Add gdb_vecs.o.
6718 (gdb_vecs_h, host_defs_h): New variables.
6719 (thread-db.o): Add $(gdb_vecs_h) dependency.
6720 (gdb_vecs.o): New rule.
6721 * thread-db.c: #include "gdb_vecs.h".
6722 (thread_db_load_search): Use a vector to iterate over path elements.
6723 Handle text appearing after "$pdir".
6725 * configure.ac: Add check for strstr.
6726 * config.in: Regenerate.
6727 * configure: Regenerate.
6729 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
6731 * hostio.c (handle_pread): If pread fails, fall back to attempting
6733 (handle_pwrite): Likewise for pwrite.
6735 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
6737 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
6738 between unsupported TYPE and unimplementable ADDR/LEN combination.
6739 (arm_insert_point): Act on new return value.
6741 2012-07-31 Pedro Alves <palves@redhat.com>
6743 * server.c (process_point_options): Only skip tokens if we find
6744 one that is unrecognized. Don't treat 'X' specially while
6745 skipping unrecognized tokens.
6747 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
6749 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
6750 to 4-byte-align HW breakpoint addresses for Thumb.
6752 2012-07-27 Yao Qi <yao@codesourcery.com>
6756 * server.h: Declare gdb_agent_about_to_close.
6757 * target.c (kill_inferior): Include "agent.h".
6758 New. Send command 'kill'.
6759 * target.h (kill_inferior): Removed macro.
6760 * tracepoint.c (gdb_agent_about_to_close): New.
6761 (gdb_agent_helper_thread): Handle command 'close'.
6762 Wait endlessly until the inferior stops.
6763 Install gdb_agent_remove_socket to atexit hook.
6764 (agent_socket_name): New static variable.
6765 (gdb_agent_socket_init): Replace local variable 'name' with
6766 'agent_socket_name'.
6767 (gdb_agent_remove_socket): New.
6769 2012-07-27 Yao Qi <yao@codesourcery.com>
6771 * server.c (process_point_options): Stop at 'X' when parsing.
6773 2012-07-19 Michael Eager <eager@eagercon.com>
6775 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
6777 * linux-x86-low.c (x86_insert_point, x86_remove_point):
6778 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
6779 hardware breakpoint.
6781 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
6783 * gdbserver/linux-low.c (initialize_low): Call
6784 linux_ptrace_init_warnings.
6786 2012-07-02 Doug Evans <dje@google.com>
6788 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
6791 2012-07-02 Stan Shebs <stan@codesourcery.com>
6793 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
6794 (ax.o): Add it to build rule.
6796 (OBS): Add format.o.
6797 (IPA_OBS): Add format.o.
6798 * server.c (handle_query): Claim support for breakpoint commands.
6799 (process_point_options): Add command case.
6800 (process_serial_event): Leave running if there are printfs in
6802 * mem-break.h (any_persistent_commands): Declare.
6803 (add_breakpoint_commands): Declare.
6804 (gdb_no_commands_at_breakpoint): Declare.
6805 (run_breakpoint_commands): Declare.
6806 * mem-break.c (struct point_command_list): New struct.
6807 (struct breakpoint): New field command_list.
6808 (any_persistent_commands): New function.
6809 (add_commands_to_breakpoint): New function.
6810 (add_breakpoint_commands): New function.
6811 (gdb_no_commands_at_breakpoint): New function.
6812 (run_breakpoint_commands): New function.
6813 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
6815 * ax.c: Include format.h.
6816 (ax_printf): New function.
6817 (gdb_eval_agent_expr): Add printf opcode.
6819 2012-06-13 Yao Qi <yao@codesourcery.com>
6821 * server.c (start_inferior): Remove duplicated writes to fields
6822 'last_resume_kind' and 'last_status' of 'current_inferior'.
6824 2012-06-12 Yao Qi <yao@codesourcery.com>
6825 Pedro Alves <palves@redhat.com>
6827 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
6829 * server.c (handle_v_cont): Extend comment.
6831 2012-06-11 Yao Qi <yao@codesourcery.com>
6833 * linux-low.c (linux_attach): Add 'static'.
6835 2012-06-06 Yao Qi <yao@codesourcery.com>
6837 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
6839 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
6841 Fix gcc -flto compilation warning.
6842 * server.c (main): Make variable multi_mode and attach volatile.
6844 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
6846 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
6847 if the platform doesn't know about it.
6849 2012-05-30 Jeff Kenton <jkenton@tilera.com>
6851 * Makefile.in (SFILES): Add linux-tile-low.c.
6852 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
6853 * configure.srv: Handle tilegx-*-linux*.
6854 * linux-tile-low.c: New file.
6856 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
6858 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
6860 2012-05-24 Pedro Alves <palves@redhat.com>
6864 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
6866 2012-05-24 Pedro Alves <palves@redhat.com>
6870 Replace target_signal with gdb_signal throughout.
6872 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
6874 * linux-low.c (linux_store_registers): Avoid the copying sequence
6875 when no data has been retrieved by ptrace.
6877 2012-05-22 Will Deacon <will.deacon@arm.com>
6879 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
6880 Include asm/ptrace.h.
6881 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
6884 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
6886 * linux-low.c (linux_store_registers): Don't re-retrieve data
6887 with ptrace that has already been obtained from /proc. Always
6888 copy any data retrieved with ptrace to the buffer supplied.
6890 2012-05-11 Yao Qi <yao@codesourcery.com>
6891 Pedro Alves <palves@redhat.com>
6893 * linux-low.c (enum stopping_threads_kind): New.
6894 (stopping_threads): Change type to `enum stopping_threads_kind'.
6895 (handle_extended_wait): If stopping and suspending threads, leave
6896 the new_lwp suspended too.
6897 (linux_wait_for_event): Adjust.
6898 (stop_all_lwps): Set `stopping_threads' to
6899 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
6900 whether we're suspending threads or just stopping them. Assert no
6903 2012-04-29 Yao Qi <yao@codesourcery.com>
6905 * server.h: Move some code to ...
6906 * gdbthread.h: ... here. New.
6907 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
6908 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
6909 (nto-low.o, win32-low.o): Likewise.
6910 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
6911 * regcache.c, remote-utils.c, server.c: Likewise.
6912 * target.c, tracepoint.c, win32-low.c: Likewise.
6914 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
6916 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
6917 (PTRACE_ARG4_TYPE): Likewise.
6918 (PTRACE_XFER_TYPE): Likewise.
6919 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
6920 ptrace to PTRACE_ARG3_TYPE.
6921 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
6922 (PTRACE_ARG4_TYPE): Likewise.
6923 (PTRACE_XFER_TYPE): Likewise.
6924 (linux_detach_one_lwp): Cast fourth argument of
6925 ptrace to long then PTRACE_ARG4_TYPE.
6926 (regsets_fetch_inferior_registers): Cast third argument of
6927 ptrace to long then PTRACE_ARG3_TYPE.
6928 (regsets_store_inferior_registers): Likewise.
6930 2012-04-20 Pedro Alves <palves@redhat.com>
6932 * configure: Regenerate.
6934 2012-04-19 Pedro Alves <palves@redhat.com>
6936 * Makefile.in (GNULIB_BUILDDIR): New.
6937 (LIBGNU, INCGNU, GNULIB_H): Adjust.
6938 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
6939 (all, install-only, uninstall, clean-info, all-lib, clean): No
6940 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
6941 (maintainer-clean realclean distclean): Use subdir_do.
6943 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
6944 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
6945 * acinclude.m4: Include acx_configure_dir.m4.
6946 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
6947 calls. Call AC_PROG_RANLIB. Configure gnulib using
6950 (GNULIB_STDINT_H): Adjust.
6951 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
6952 * gdbreplay.c: Include build-gnulib/config.h.
6953 * server.h: Likewise.
6954 * aclocal.m4: Regenerate.
6955 * config.in: Regenerate.
6956 * configure: Regenerate.
6958 2012-04-19 Pedro Alves <palves@redhat.com>
6960 * Makefile.in (LIBGNU, INCGNU): Adjust.
6961 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
6962 (all, install-only, uninstall, clean-info, all-lib, clean)
6963 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
6964 * configure.ac: Adjust AC_OUTPUT output.
6965 * aclocal.m4: Regenerate.
6966 * configure: Regenerate.
6968 2012-04-19 Pedro Alves <palves@redhat.com>
6970 * Makefile.in (generated_files): New.
6971 (server_h): Remove the explicit dependency on config.h, and depend
6972 on $generated_files.
6974 2012-04-19 Pedro Alves <palves@redhat.com>
6976 * Makefile.in (INCGNU): Add -Ignulib.
6978 2012-04-19 Pedro Alves <palves@redhat.com>
6980 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
6981 (INCGNU): ... this, and spell out -I here.
6982 (GNULIB_LIB): Rename to ...
6984 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
6986 2012-04-19 Pedro Alves <palves@redhat.com>
6988 * config.in: Regenerate.
6990 2012-04-19 Pedro Alves <palves@redhat.com>
6992 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
6993 * server.h (memmem): Remove declaration.
6994 * config.in: Regenerate.
6995 * configure: Regenerate.
6997 2012-04-19 Yao Qi <yao@codesourcery.com>
6999 * Makefile.in (SFILES): Add common/vec.c.
7003 2012-04-19 Yao Qi <yao@codesourcery.com>
7005 * remote-utils.c (prepare_resume_reply): Replace with macro
7006 target_core_of_thread.
7007 * server.c (handle_qxfer_threads_proper): Likewise.
7008 * target.h (traget_core_of_thread): New macro.
7010 2012-04-18 Pedro Alves <palves@redhat.com>
7012 * aclocal.m4: Regenerate.
7013 * configure: Regenerate.
7015 2012-04-16 Yao Qi <yao@codesourcery.com>
7017 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
7018 duplicated on address.
7020 2012-04-16 Yao Qi <yao@codesourcery.com>
7022 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
7023 (struct tracepoint_action_ops) <send>: New field.
7024 (m_tracepoint_action_send, r_tracepoint_action_send): New.
7025 (agent_expr_send, x_tracepoint_action_send): New.
7026 (l_tracepoint_action_send): New.
7027 (cmd_qtdp): Download and install tracepoint
7028 according to `use_agent'.
7029 (run_inferior_command): Add one more parameter `len'.
7031 (tracepoint_send_agent): New.
7032 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
7034 2012-04-16 Yao Qi <yao@codesourcery.com>
7036 * tracepoint.c (download_tracepoints): Moved to ...
7037 (cmd_qtstart): ... here.
7039 2012-04-14 Yao Qi <yao@codesourcery.com>
7041 * tracepoint.c: Include inttypes.h.
7042 (struct collect_memory_action): Use sized types.
7043 (struct tracepoint): Likewise.
7044 (cmd_qtdp, stop_tracing): Update print specifiers.
7045 (cmd_qtp, response_tracepoint): Likewise.
7046 (collect_data_at_tracepoint): Likewise.
7047 (collect_data_at_step): Likewise.
7049 2012-04-14 Yao Qi <yao@codesourcery.com>
7051 Import gnulib module inttypes.
7052 * aclocal.m4, config.in, configure: Regenerated.
7054 2012-04-14 Yao Qi <yao@codesourcery.com>
7056 * Makefile.in (maintainer-clean, realclean, distclean): Remove
7057 Makefile and config.status at last.
7059 2012-04-13 Yao Qi <yao@codesourcery.com>
7061 * tracepoint.c: Include stdint.h unconditionally.
7063 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
7065 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
7066 on BFD_HAVE_SYS_PROCFS_TYPE.
7067 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
7068 * configure: Regenerate.
7069 * config.in: Likewise.
7071 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
7073 * Makefile.in (clean): Also remove x32.c x32-linux.c
7074 x32-avx.c x32-avx-linux.c.
7075 (x32.o): New target.
7077 (x32-linux.o): Likewise.
7078 (x32-linux.c): Likewise.
7079 (x32-avx.o): Likewise.
7080 (x32-avx.c): Likewise.
7081 (x32-avx-linux.o): Likewise.
7082 (x32-avx-linux.c): Likewise.
7084 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
7085 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
7086 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
7087 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
7088 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
7089 i386/x32-avx-linux.xml.
7091 * linux-x86-low.c (init_registers_x32_linux): New prototype.
7092 (init_registers_x32_avx_linux): Likwise.
7093 (x86_linux_update_xmltarget): Call init_registers_x32_linux
7094 or init_registers_x32_avx_linux if linux_is_elf64 is false.
7096 2012-04-13 Pedro Alves <palves@redhat.com>
7098 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
7099 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
7100 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
7101 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
7104 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
7106 * linux-x86-low.c (compat_x32_clock_t): New.
7107 (compat_x32_siginfo_t): Likewise.
7108 (compat_x32_siginfo_from_siginfo): Likewise.
7109 (siginfo_from_compat_x32_siginfo): Likewise.
7110 (linux_is_elf64): Likewise.
7111 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
7112 and siginfo_from_compat_x32_siginfo for x32.
7113 (x86_arch_setup): Set linux_is_elf64.
7115 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
7118 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
7120 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
7121 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
7122 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
7123 compatible with process.
7125 2012-04-12 Yao Qi <yao@codesourcery.com>
7127 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
7128 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
7129 (install-only, install-info, clean): Handle sub dir gnulib.
7130 (all-lib, am--refresh): New targets.
7131 (memmem.o): Remove target.
7132 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
7133 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
7134 (AC_REPLACE_FUNCS): Remove memmem.
7135 Invoke gl_INIT and AM_INIT_AUTOMAKE.
7136 (AC_OUTPUT): Generate Makefile in gnulib/.
7137 * aclocal.m4, config.in, configure: Regenerated.
7139 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
7141 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
7143 2012-04-05 Pedro Alves <palves@redhat.com>
7145 -Werror=strict-aliasing
7147 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
7150 2012-04-04 Pedro Alves <palves@redhat.com>
7152 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
7153 (sparc_store_gregset_from_stack, sparc_store_gregset)
7154 (sparc_breakpoint_at): Fix formatting.
7156 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
7158 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
7160 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
7161 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
7162 * config.in: Regenerate.
7163 * configure: Likewise.
7165 2012-03-29 Pedro Alves <palves@redhat.com>
7167 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
7168 Correct ptrace arguments.
7170 2012-03-28 Pedro Alves <palves@redhat.com>
7172 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
7173 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
7174 (IA64_FR1_REGNUM): New defines.
7175 (ia64_fetch_register): New.
7176 (the_low_target): Install it.
7177 * linux-low.h (struct linux_target_ops) <fetch_register>: New
7179 * linux-low.c (linux_fetch_registers): Try the
7180 the_low_target.fetch_register hook first.
7182 * linux-arm-low.c (the_low_target): Adjust.
7183 * linux-bfin-low.c (the_low_target): Adjust.
7184 * linux-cris-low.c (the_low_target): Adjust.
7185 * linux-crisv32-low.c (the_low_target): Adjust.
7186 * linux-m32r-low.c (the_low_target): Adjust.
7187 * linux-m68k-low.c (the_low_target): Adjust.
7188 * linux-mips-low.c (the_low_target): Adjust.
7189 * linux-ppc-low.c (the_low_target): Adjust.
7190 * linux-s390-low.c (the_low_target): Adjust.
7191 * linux-sh-low.c (the_low_target): Adjust.
7192 * linux-sparc-low.c (the_low_target): Adjust.
7193 * linux-tic6x-low.c (the_low_target): Adjust.
7194 * linux-x86-low.c (the_low_target): Adjust.
7195 * linux-xtensa-low.c (the_low_target): Adjust.
7197 2012-03-26 Pedro Alves <palves@redhat.com>
7199 * server.c (handle_qxfer_libraries): Don't bail early if
7200 the_target->qxfer_libraries_svr4 is not NULL.
7202 2012-03-26 Pedro Alves <palves@redhat.com>
7204 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
7206 2012-03-23 Pedro Alves <palves@redhat.com>
7208 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
7209 "library-list-svr4" element's start tag when the the DSO list is
7212 2012-03-23 Pedro Alves <palves@redhat.com>
7214 * linux-low.c (read_one_ptr): Read the inferior's pointer through
7215 a variable whose type size is the same as the inferior's pointer
7218 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
7220 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
7222 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
7223 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
7224 * linux-low.h: Include <signal.h>.
7225 (struct siginfo): Remove forward declaration.
7226 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
7229 2012-03-21 Mike Frysinger <vapier@gentoo.org>
7231 * .gitignore: Ignore more files.
7233 2012-03-19 Pedro Alves <palves@redhat.com>
7234 Jan Kratochvil <jan.kratochvil@redhat.com>
7236 * server.c (cont_thread, general_thread): Add describing comments.
7237 (start_inferior): Clear `cont_thread'.
7238 (handle_v_cont): Don't set `cont_thread' if resuming all threads
7241 2012-03-15 Yao Qi <yao@codesourcery.com>
7243 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
7245 (cmd_qtdp): ... here.
7247 2012-03-15 Yao Qi <yao@codesourcery.com>
7249 * tracepoint.c (struct tracepoint_action_ops): New.
7250 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
7251 (m_tracepoint_action_download): New.
7252 (r_tracepoint_action_download): New.
7253 (x_tracepoint_action_download): New.
7254 (l_tracepoint_action_download): New.
7255 (add_tracepoint_action): Install `action->ops' according type.
7256 (download_tracepoint_1): Move code `download' function pointer
7257 of various tracepoint_action_ops.
7259 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
7261 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
7262 linux_ptrace_attach_warnings.
7264 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
7266 * Makefile.in (linux-ptrace.o): New.
7267 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
7268 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
7269 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
7270 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
7271 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
7273 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
7275 2012-03-08 Yao Qi <yao@codesourcery.com>
7276 Pedro Alves <palves@redhat.com>
7278 Fix PR server/13392.
7279 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
7281 * tracepoint.c (remove_tracepoint): New.
7282 (cmd_qtdp): Call remove_tracepoint when failed to install.
7284 2012-03-07 Pedro Alves <palves@redhat.com>
7286 * linux-low.c (get_detach_signal): New.
7287 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
7288 Pass on pending signals to PTRACE_DETACH. Check the result of the
7290 * server.c (program_signals, program_signals_p): New.
7291 (handle_general_set): Handle QProgramSignals.
7292 * server.h (program_signals, program_signals_p): Declare.
7294 2012-03-05 Pedro Alves <palves@redhat.com>
7295 Jan Kratochvil <jan.kratochvil@redhat.com>
7297 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
7300 2012-03-03 Yao Qi <yao@codesourcery.com>
7302 * tracepoint.c (tracepoint_look_up_symbols): Update call to
7303 agent_look_up_symbols.
7305 2012-03-03 Yao Qi <yao@codesourcery.com>
7307 * Makefile.in (linux-low.o): Keep dependence on agent.h.
7308 (linux-x86-low.o): Likewise.
7309 * server.h: Remove in_process_agent_loaded.
7310 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
7314 2012-03-03 Yao Qi <yao@codesourcery.com>
7316 * tracepoint.c (gdb_agent_capability): New global.
7317 (in_process_agent_loaded_ust): Renamed to
7318 `in_process_agent_supports_ust'.
7320 (in_process_agent_supports_ust): Call agent_capability_check.
7321 (clear_installed_tracepoints): Assert that agent supports
7324 2012-03-03 Yao Qi <yao@codesourcery.com>
7326 * linux-low.c (linux_supports_agent): New.
7327 (linux_target_ops): Initialize field `supports_agent' with
7328 linux_supports_agent.
7329 * target.h (struct target_ops) <supports_agent>: New.
7330 (target_supports_agent): New macro.
7331 * server.c (handle_general_set): Handle packet 'QAgent'.
7332 (handle_query): Send `QAgent+'.
7333 * Makefile.in (server.o): Depends on agent.h.
7335 2012-03-03 Yao Qi <yao@codesourcery.com>
7337 * Makefile.in (OBS): Add agent.o.
7338 Add new rule for agent.o.
7339 Track dependence of tracepoint.c on agent.h.
7340 * tracepoint.c (run_inferior_command_1):
7341 (run_inferior_command): Call agent_run_command.
7342 (gdb_ust_connect_sync_socket): Deleted. Move it to
7344 (resume_thread, stop_thread): Likewise.
7345 (gdb_ust_socket_init): Renamed to ...
7346 (gdb_agent_socket_init): ... New.
7347 (gdb_ust_thread): Renamed to ...
7348 (gdb_agent_helper_thread): ... New.
7349 (gdb_ust_init): Move some code to ...
7350 (gdb_agent_init): ... here. New.
7351 [HAVE_UST]: Call gdb_ust_init.
7352 (initialize_tracepoint_ftlib): Call gdb_agent_init.
7353 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
7354 * config.in, configure: Regenerated.
7356 2012-03-02 Pedro Alves <palves@redhat.com>
7358 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
7359 * linux-low.c (struct simple_pid_list): New.
7360 (stopped_pids): New a struct simple_pid_list pointer.
7361 (add_to_pid_list, pull_pid_from_list): New.
7362 (handle_extended_wait): Don't assume the first signal new children
7363 report is SIGSTOP. Adjust call to pull_pid_from_list.
7364 (linux_wait_for_lwp): Adjust.
7366 2012-03-02 Yao Qi <yao@codesourcery.com>
7368 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
7371 2012-03-02 Yao Qi <yao@codesourcery.com>
7373 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
7374 `stop_pc' and `tpoint'. Update caller.
7376 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
7378 * linux-low.h (linux_target_ops): Add regset_bitmap member.
7379 * linux-low.c (use_linux_regsets): New macro.
7380 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
7381 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
7382 (linux_register_in_regsets): New function.
7383 (usr_fetch_inferior_registers): Skip registers covered by
7385 (usr_store_inferior_registers): Likewise.
7386 (usr_fetch_inferior_registers): New macro.
7387 (usr_store_inferior_registers): Likewise.
7388 (linux_fetch_registers): Handle mixed regset/non-regset targets.
7389 (linux_store_registers): Likewise.
7390 * linux-mips-low.c (init_registers_mips_dsp_linux): New
7392 (init_registers_mips64_dsp_linux): Likewise.
7393 (init_registers_mips_linux): New macro.
7394 (init_registers_mips_dsp_linux): Likewise.
7395 (mips_dsp_num_regs): Likewise.
7396 (DSP_BASE, DSP_CONTROL): New fallback macros.
7397 (mips_base_regs): New macro.
7398 (mips_regmap): Use it. Fix the size.
7399 (mips_dsp_regmap): New variable.
7400 (mips_dsp_regset_bitmap): Likewise.
7401 (mips_arch_setup): New function.
7402 (mips_cannot_fetch_register): Use the_low_target.regmap rather
7404 (mips_cannot_store_register): Likewise.
7405 (the_low_target): Update .arch_setup, .num_regs and .regmap
7406 initializers. Add .regset_bitmap initializer.
7407 * linux-arm-low.c (the_low_target): Add .regset_bitmap
7409 * linux-bfin-low.c (the_low_target): Likewise.
7410 * linux-cris-low.c (the_low_target): Likewise.
7411 * linux-crisv32-low.c (the_low_target): Likewise.
7412 * linux-ia64-low.c (the_low_target): Likewise.
7413 * linux-m32r-low.c (the_low_target): Likewise.
7414 * linux-m68k-low.c (the_low_target): Likewise.
7415 * linux-ppc-low.c (the_low_target): Likewise.
7416 * linux-s390-low.c (the_low_target): Likewise.
7417 * linux-sh-low.c (the_low_target): Likewise.
7418 * linux-sparc-low.c (the_low_target): Likewise.
7419 * linux-tic6x-low.c (the_low_target): Likewise.
7420 * linux-x86-low.c (the_low_target): Likewise.
7421 * linux-xtensa-low.c (the_low_target): Likewise.
7422 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
7423 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
7424 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
7426 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
7427 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
7429 2012-02-29 Yao Qi <yao@codesourcery.com>
7430 Pedro Alves <palves@redhat.com>
7432 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
7433 `step_over_finished' is true.
7435 2012-02-27 Pedro Alves <palves@redhat.com>
7437 * linux-low.c (pid_is_stopped): Delete, moved to common/.
7438 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
7440 2012-02-27 Pedro Alves <palves@redhat.com>
7443 * linux-low.c (pid_is_stopped): New.
7444 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
7446 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
7448 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
7451 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
7453 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
7455 2012-02-24 Luis Machado <lgustavo@codesourcery>
7457 * server.c (handle_query): Advertise support for target-side
7458 breakpoint condition evaluation.
7459 (process_point_options): New function.
7460 (process_serial_event): When inserting a breakpoint, check for
7461 a target-side condition that should be evaluated.
7463 * mem-break.c: Include regcache.h and ax.h.
7464 (point_cond_list_t): New data structure.
7465 (breakpoint) <cond_list>: New field.
7466 (find_gdb_breakpoint_at): Make non-static.
7467 (delete_gdb_breakpoint_at): Clear any target-side
7469 (clear_gdb_breakpoint_conditions): New function.
7470 (add_condition_to_breakpoint): Likewise.
7471 (add_breakpoint_condition): Likewise.
7472 (gdb_condition_true_at_breakpoint): Likewise.
7473 (gdb_breakpoint_here): Return result directly instead
7474 of going through a local variable.
7476 * mem-break.h (find_gdb_breakpoint_at): New prototype.
7477 (clear_gdb_breakpoint_conditions): Likewise.
7478 (add_breakpoint_condition): Likewise.
7479 (gdb_condition_true_at_breakpoint): Likewise.
7481 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
7482 (need_step_over_p): Take target-side breakpoint condition into
7485 2012-02-24 Luis Machado <lgustavo@codesourcery>
7487 * server.h: Include tracepoint.h.
7488 (agent_mem_read, agent_get_trace_state_variable_value,
7489 agent_set_trace_state_variable_value,
7490 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
7491 get_set_tsv_func_addr): New prototypes.
7493 * ax.h: New include file.
7494 * ax.c: New source file.
7496 * tracepoint.c: Include ax.h.
7497 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
7498 agent_expr, eval_result_type): Move to ax.h.
7499 (parse_agent_expr): Rename to ...
7500 (gdb_parse_agent_expr): ... this, make it non-static and move
7502 (unparse_agent_expr) Rename to ...
7503 (gdb_unparse_agent_expr): ... this, make it non-static and move
7505 (eval_agent_expr): Rename to ...
7506 (eval_tracepoint_agent_expr): ... this.
7507 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
7508 forward declarations.
7509 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
7510 (agent_get_trace_state_variable_value): New function.
7511 (agent_set_trace_state_variable_value): New function.
7512 (cmd_qtdp): Call gdb_parse_agent_expr (...).
7513 (response_tracepoint): Call gdb_unparse_agent_expr (...).
7514 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
7515 (condition_true_at_tracepoint): Likewise.
7516 (parse_agent_expr): Rename to ...
7517 (gdb_parse_agent_expr): ... this and move to ax.c.
7518 (unparse_agent_expr): Rename to ...
7519 (gdb_unparse_agent_expr): ... this and move to ax.c.
7520 (gdb_agent_op_name): Move to ax.c.
7521 (eval_agent_expr): Rename to ...
7522 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
7524 (eval_tracepoint_agent_expr): New function.
7525 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
7527 (current_insn_ptr, emit_error, struct bytecode_address): Move to
7529 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
7530 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
7531 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
7532 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
7533 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
7534 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
7535 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
7536 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
7537 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
7538 (compile_bytecodes): Remove forward declaration.
7539 (is_goto_target): Move to ax.c.
7540 (compile_bytecodes): Move to ax.c and call
7541 agent_get_trace_state_variable_value (...) and
7542 agent_set_trace_state_variable_value (...).
7544 * Makefile.in: Update ax.c and IPA dependencies.
7546 2012-02-24 Pedro Alves <palves@redhat.com>
7548 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
7549 (cmd_bigqtbuffer_circular): ... this. Only handle
7550 'QTBuffer:circular:'.
7551 (handle_tracepoint_general_set): Adjust.
7553 2012-02-16 Yao Qi <yao@codesourcery.com>
7555 * inferiors.c: Move code to ...
7556 * dll.c: .... here. New.
7557 * server.h: Declare clear_dlls.
7558 * Makefile.in (SFILES): Add dll.c.
7562 2012-02-11 Yao Qi <yao@codesourcery.com>
7564 * server.c: (handle_monitor_command): Add a new parameter
7566 (handle_query): Update caller.
7568 2012-02-09 Joel Brobecker <brobecker@adacore.com>
7570 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
7571 * configure, config.in: Regenerate.
7572 * hostio.c: Provide an alternate implementation if HAVE_READLINK
7575 2012-02-02 Pedro Alves <palves@redhat.com>
7577 Try SIGKILL first, then PTRACE_KILL.
7578 * linux-low.c (linux_kill_one_lwp): New.
7579 (linux_kill_one_lwp): Rename to ...
7580 (kill_one_lwp_callback): ... this. Use the new
7583 2012-02-02 Pedro Alves <palves@redhat.com>
7585 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
7588 2012-01-27 Pedro Alves <palves@redhat.com>
7590 * linux-low.c (linux_child_pid_to_exec_file): Delete.
7591 (elf_64_file_p): Make static.
7592 (linux_pid_exe_is_elf_64_file): New.
7593 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
7594 Delete declarations.
7595 (linux_pid_exe_is_elf_64_file): Declare.
7596 * linux-x86-low.c (x86_arch_setup): Use
7597 linux_pid_exe_is_elf_64_file.
7599 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
7601 * linux-low.c (linux_wait_for_event_1): Rename to ...
7602 (linux_wait_for_event): ... here and merge it with former
7603 linux_wait_for_event - new variable wait_ptid, use it.
7604 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
7606 2012-01-23 Pedro Alves <palves@redhat.com>
7608 * server.c (main): Avoid yet another case of infinite loop while
7609 detaching/killing after a longjmp.
7611 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
7614 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
7616 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
7618 * hostio.c (handle_readlink): New function.
7619 (handle_vFile): Call it to handle "vFile:readlink" packets.
7621 2012-01-20 Pedro Alves <palves@redhat.com>
7622 Ulrich Weigand <ulrich.weigand@linaro.org>
7624 * server.c (handle_v_requests): Only support vAttach and vRun to
7625 start multiple processes when in extended protocol mode.
7627 2012-01-17 Pedro Alves <palves@redhat.com>
7629 * tracepoint.c (initialize_tracepoint): Use mmap instead of
7630 memalign plus mprotect to allocate the scratch buffer.
7632 2012-01-13 Pedro Alves <palves@redhat.com>
7634 * server.c (attach_inferior): Clear `cont_thread'.
7636 2012-01-13 Pedro Alves <palves@redhat.com>
7638 * server.c (main): Avoid infinite loop while detaching/killing
7641 2012-01-09 Doug Evans <dje@google.com>
7643 * server.c (start_inferior): Set last_ptid in --wrapper case.
7645 2012-01-06 Yao Qi <yao@codesourcery.com>
7647 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
7649 [IN_PROCESS_AGENT] (debug_agent): New global variable.
7651 2012-01-04 Yao Qi <yao@codesourcery.com>
7653 * tracepoint.c (cmd_qtdp): Print debug message
7654 for static tracepoint.
7656 2012-01-04 Yao Qi <yao@codesourcery.com>
7658 * tracepoint.c (trace_vdebug): Differentiate debug message
7659 between gdbserver and IPA.
7661 2012-01-03 Yao Qi <yao@codesourcery.com>
7663 * tracepoint.c (tracepoint_was_hit): Don't collect for
7666 2012-01-02 Joel Brobecker <brobecker@adacore.com>
7668 * terminal.h: Reformat copyright header.
7670 2012-01-02 Joel Brobecker <brobecker@adacore.com>
7672 * server.c (gdbserver_version): Update copyright year.
7673 * gdbreplay.c (gdbreplay_version): Likewise.
7675 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
7677 * linux-low.c (linux_create_inferior): Put empty if clause for write.
7680 2011-12-18 Hui Zhu <teawater@gmail.com>
7681 * linux-low.c (linux_create_inferior): Save return value to ret.
7683 2011-12-18 Hui Zhu <teawater@gmail.com>
7685 * linux-low.c (linux_create_inferior): Save return value to ret.
7687 2011-12-16 Doug Evans <dje@google.com>
7689 * linux-low.c (linux_create_inferior): If stdio connection,
7690 redirect stdin from /dev/null, stdout to stderr.
7691 * remote-utils.c (remote_is_stdio): New static global.
7692 (remote_connection_is_stdio): New function.
7693 (remote_prepare): Handle stdio connection.
7694 (remote_open): Ditto.
7695 (remote_close): Don't close stdin for stdio connections.
7696 (read_prim,write_prim): New functions. Replace all calls to
7697 read/write to these.
7698 * server.c (main): Watch for "-" argument. Move call to
7699 remote_prepare before start_inferior.
7700 * server.h (STDIO_CONNECTION_NAME): New macro.
7701 (remote_connection_is_stdio): Declare.
7703 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
7704 in debugging output.
7706 2011-12-15 Yao Qi <yao@codesourcery.com>
7708 * tracepoint.c: Include sys/syscall.h.
7709 (gdb_ust_thread): Remove preprocessor conditional.
7711 2011-12-14 Pedro Alves <pedro@codesourcery.com>
7713 * linux-low.c (linux_detach_one_lwp): Call
7714 the_low_target.prepare_to_resume before detaching.
7716 2011-12-14 Yao Qi <yao@codesourcery.com>
7718 * tracepoint.c (gdb_ust_thread): Don't ignore return value
7721 2011-12-14 Yao Qi <yao@codesourcery.com>
7723 * i386-low.c (i386_low_stopped_data_address): Initialize local
7726 2011-12-13 Pedro Alves <pedro@codesourcery.com>
7730 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
7731 DR_CONTROL unless necessary. Extend comments.
7732 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
7733 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
7735 2011-12-13 Yao Qi <yao@codesourcery.com>
7737 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
7739 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
7741 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
7743 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
7744 Print new debug message for such case.
7746 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7748 Fix overlapping memcpy.
7749 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
7750 the read_inferior_memory transfer.
7751 (delete_fast_tracepoint_jump): New variable buf. Use it for the
7752 write_inferior_memory transfer.
7753 (set_fast_tracepoint_jump): New variable buf. Use it for the
7754 read_inferior_memory and write_inferior_memory transfers.
7755 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
7756 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
7757 Use it for the write_inferior_memory transfer.
7758 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
7761 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
7763 * linux-low.c (fetch_register, store_register): Make code
7764 consistent, fix formatting.
7766 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
7768 * linux-low.c (usr_store_inferior_registers): Factor out code
7769 to handle individual registers into...
7770 (store_register): ... this new function.
7772 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
7774 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
7775 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
7776 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
7777 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
7778 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
7779 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
7780 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
7781 (srv_xmlfiles): Add new XML files.
7783 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
7785 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
7786 (init_registers_s390_linux32v1): Add prototype.
7787 (init_registers_s390_linux32v2): Likewise.
7788 (init_registers_s390_linux64v1): Likewise.
7789 (init_registers_s390_linux64v2): Likewise.
7790 (init_registers_s390x_linux64v1): Likewise.
7791 (init_registers_s390x_linux64v2): Likewise.
7792 (s390_num_regs): Increment to 52.
7793 (s390_regmap): Add orig_r2 register.
7794 (s390_num_regs_3264): Increment to 68.
7795 (s390_regmap_3264): Add orig_r2 register.
7796 (s390_collect_ptrace_register): Handle orig_r2 register.
7797 (s390_supply_ptrace_register): Likewise.
7798 (s390_fill_last_break): New function.
7799 (s390_store_last_break): Likewise.
7800 (s390_fill_system_call): New function.
7801 (s390_store_system_call): Likewise.
7802 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
7804 (s390_check_regset): New function.
7805 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
7806 NT_S390_SYSTEM_CALL regsets and use appropriate description.
7807 Update target_regsets for available register sets.
7809 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
7810 Jan Kratochvil <jan.kratochvil@redhat.com>
7812 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
7813 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
7815 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
7816 * linux-low.h (struct process_info_private): New member r_debug.
7817 * server.c (handle_qxfer_libraries): Call
7818 the_target->qxfer_libraries_svr4.
7819 (handle_qxfer_libraries_svr4): New function.
7820 (qxfer_packets): New entry "libraries-svr4".
7821 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
7822 * target.h (struct target_ops): New member qxfer_libraries_svr4.
7823 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
7824 PACKET_qXfer_libraries_svr4.
7826 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
7828 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
7829 PSW address/mask between 8-byte and 16-byte formats.
7830 (s390_supply_ptrace_register): Likewise.
7831 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
7832 basic addressing mode bit.
7834 2011-11-24 Stan Shebs <stan@codesourcery.com>
7836 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
7838 2011-11-17 Stan Shebs <stan@codesourcery.com>
7840 * tracepoint.c (struct tracepoint): New field traceframe_usage.
7841 (tracing_start_time): New global.
7842 (tracing_stop_time): New global.
7843 (tracing_user_name): New global.
7844 (tracing_notes): New global.
7845 (tracing_stop_note): New global.
7846 (cmd_qtstart): Set traceframe_usage, start_time.
7847 (stop_tracing): Set stop_time.
7848 (cmd_qtstatus): Report additional status.
7849 (cmd_qtp): New function.
7850 (handle_tracepoint_query): Call it.
7851 (cmd_qtnotes): New function.
7852 (handle_tracepoint_general_set): Call it.
7853 (get_timestamp): Rename from tsv_get_timestamp.
7855 2011-11-14 Stan Shebs <stan@codesourcery.com>
7856 Kwok Cheung Yeung <kcy@codesourcery.com>
7858 * linux-x86-low.c (small_jump_insn): New.
7859 (i386_install_fast_tracepoint_jump_pad): Add arguments for
7860 trampoline and error message, build a trampoline and issue a small
7861 jump instruction to it.
7862 (x86_install_fast_tracepoint_jump_pad): Add arguments for
7863 trampoline and error message.
7864 (x86_get_min_fast_tracepoint_insn_len): New.
7865 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
7866 * linux-low.h (struct linux_target_ops): Add arguments to
7867 install_fast_tracepoint_jump_pad operation, add new operation.
7868 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
7870 (linux_get_min_fast_tracepoint_insn_len): New function.
7871 (linux_target_op): Add new operation.
7872 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
7873 (gdb_trampoline_buffer_end): Ditto.
7874 (gdb_trampoline_buffer_error): Ditto.
7875 (struct ipa_sym_addresses): Add fields for new IPA variables.
7876 (symbol_list): Add entries for new IPA variables.
7877 (struct tracepoint): Add fields to hold the address range of the
7878 trampoline used by the tracepoint.
7879 (trampoline_buffer_head): New static variable.
7880 (trampoline_buffer_tail): Ditto.
7881 (claim_trampoline_space): New function.
7882 (have_fast_tracepoint_trampoline_buffer): New function.
7883 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
7885 (install_fast_tracepoint): Ditto, also add error buffer argument.
7886 (cmd_qtminftpilen): New function.
7887 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
7888 (fast_tracepoint_from_trampoline_address): New function.
7889 (fast_tracepoint_collecting): Handle trampoline as part of jump
7891 (set_trampoline_buffer_space): New function.
7892 (initialize_tracepoint): Initialize new IPA variables.
7893 * target.h (struct target_ops): Add arguments to
7894 install_fast_tracepoint_jump_pad operation, add new
7895 get_min_fast_tracepoint_insn_len operation.
7896 (target_get_min_fast_tracepoint_insn_len): New.
7897 (install_fast_tracepoint_jump_pad): Add arguments.
7898 * server.h (IPA_BUFSIZ): Define.
7899 * linux-i386-ipa.c: Include extra header files.
7900 (initialize_fast_tracepoint_trampoline_buffer): New function.
7901 (initialize_low_tracepoint): Call it.
7902 * server.h (set_trampoline_buffer_space): Declare.
7903 (claim_trampoline_space): Ditto.
7904 (have_fast_tracepoint_trampoline_buffer): Ditto.
7906 2011-11-14 Yao Qi <yao@codesourcery.com>
7908 * server.c (handle_query): Handle InstallInTrace for qSupported.
7909 * tracepoint.c (add_tracepoint): Sort list.
7910 (install_tracepoint, download_tracepoint): New.
7911 (cmd_qtdp): Call them to install and download tracepoints.
7912 (sort_tracepoints): Removed.
7913 (cmd_qtstart): Update.
7915 2011-11-14 Yao Qi <yao@codesourcery.com>
7917 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
7918 * mem-break.h: Declare.
7919 * tracepoint.c (cmd_qtstart): Move some code to ...
7920 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
7922 (download_tracepoints): Move some code to ...
7923 (download_tracepoint_1): ... here. New.
7925 2011-11-08 Yao Qi <yao@codesourcery.com>
7927 * remote-utils.c (relocate_instruction): A comment fix.
7929 2011-11-07 Joel Brobecker <brobecker@adacore.com>
7931 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
7932 (i386_dr_low_get_control, i386_dr_low_get_status): Use
7933 dr_status_mirror and dr_control_mirror from debug_reg_state.
7934 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
7935 (i386_initial_stuff): Remove use of deleted globals.
7936 (i386_get_thread_context, i386_set_thread_context,
7937 i386_thread_added): Use dr_status_mirror and dr_control_mirror
7938 from debug_reg_state.
7940 2011-11-05 Yao Qi <yao@codesourcery.com>
7942 * tracepoint.c (gdb_collect): Loop over tracepoints of same
7943 address as TPOINT's.
7945 2011-11-02 Stan Shebs <stan@codesourcery.com>
7947 * tracepoint.c (agent_mem_read_string): New function.
7948 (eval_agent_expr): Call it for tracenz.
7949 * server.c (handle_query): Report support for tracenz.
7951 2011-11-02 Yao Qi <yao@codesourcery.com>
7953 * tracepoint.c (cmd_qtstart): Remove unused local variables.
7955 2011-11-02 Yao Qi <yao@codesourcery.com>
7957 * target.h: Fix a typo in comment.
7959 2011-10-31 Pedro Alves <pedro@codesourcery.com>
7961 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
7962 clobber the breakpoints' shadows with fast tracepoint jumps.
7963 * mem-break.h (check_mem_write): Add `myaddr' parameter.
7964 * target.c (write_inferior_memory): Also pass MYADDR down to
7967 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
7969 * configure.ac: Check support for personality routine.
7970 * configure: Regenerate.
7971 * config.in: Likewise.
7972 * linux-low.c: Include <sys/personality.h>.
7973 Define ADDR_NO_RANDOMIZE if necessary.
7974 (linux_create_inferior): Disable address space randomization when
7975 forking inferior, if requested.
7976 (linux_supports_disable_randomization): New function.
7977 (linux_target_ops): Install it.
7978 * server.h (disable_randomization): Declare.
7979 * server.c (disable_randomization): New global variable.
7980 (handle_general_set): Handle QDisableRandomization.
7981 (handle_query): Likewise for qSupported.
7982 (main): Support --disable-randomization and --no-disable-randomization
7983 command line arguments.
7984 * target.h (struct target_ops): Add supports_disable_randomization.
7985 (target_supports_disable_randomization): New macro.
7987 2011-09-29 Mike Frysinger <vapier@gentoo.org>
7989 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
7991 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
7992 [!PT_GETDSBT] (target_loadmap): New definition.
7993 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
7994 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
7995 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
7996 and PT_GETDSBT to LINUX_LOADMAP.
7997 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
7998 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
8000 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
8002 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
8003 (arm_linux_hwbp_cap): New static variable.
8004 (arm_linux_get_hwbp_cap): Replace by ...
8005 (arm_linux_init_hwbp_cap): ... this new function.
8006 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
8007 (arm_linux_get_hw_watchpoint_count): Likewise.
8008 (arm_linux_get_hw_watchpoint_max_length): Likewise.
8009 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
8010 (arm_prepare_to_resume): Use perror_with_name instead of error.
8012 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
8014 * linux-arm-low.c: Include <signal.h>.
8015 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
8016 (struct arm_linux_hwbp_cap): New data type.
8017 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
8018 (struct arm_linux_hw_breakpoint): New data type.
8019 (MAX_BPTS, MAX_WPTS): Define.
8020 (struct arch_process_info, struct arch_lwp_info): New data types.
8021 (arm_linux_get_hwbp_cap): New function.
8022 (arm_linux_get_hw_breakpoint_count): Likewise.
8023 (arm_linux_get_hw_watchpoint_count): Likewise.
8024 (arm_linux_get_hw_watchpoint_max_length): Likewise.
8025 (arm_hwbp_control_initialize): Likewise.
8026 (arm_hwbp_control_is_enabled): Likewise.
8027 (arm_hwbp_control_is_initialized): Likewise.
8028 (arm_hwbp_control_disable): Likewise.
8029 (arm_linux_hw_breakpoint_equal): Likewise.
8030 (arm_linux_hw_point_initialize): Likewise.
8031 (struct update_registers_data): New data structure.
8032 (update_registers_callback: New function.
8033 (arm_insert_point): Likewise.
8034 (arm_remove_point): Likewise.
8035 (arm_stopped_by_watchpoint): Likewise.
8036 (arm_stopped_data_address): Likewise.
8037 (arm_new_process): Likewise.
8038 (arm_new_thread): Likewise.
8039 (arm_prepare_to_resume): Likewise.
8040 (the_low_target): Register arm_insert_point, arm_remove_point,
8041 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
8042 arm_new_thread, and arm_prepare_to_resume.
8044 2011-09-15 Stan Shebs <stan@codesourcery.com>
8046 * server.h (struct emit_ops): Add compare-goto fields.
8047 * tracepoint.c (gdb_agent_op_sizes): New table.
8048 (emit_eq_goto): New function.
8049 (emit_ne_goto): New function.
8050 (emit_lt_goto): New function.
8051 (emit_le_goto): New function.
8052 (emit_gt_goto): New function.
8053 (emit_ge_goto): New function.
8054 (is_goto_target): New function.
8055 (compile_bytecodes): Recognize special cases of compare-goto
8056 combinations and call specialized emitters for them.
8057 * linux-x86-low.c (amd64_emit_eq_goto): New function.
8058 (amd64_emit_ne_goto): New function.
8059 (amd64_emit_lt_goto): New function.
8060 (amd64_emit_le_goto): New function.
8061 (amd64_emit_gt_goto): New function.
8062 (amd64_emit_ge_goto): New function.
8063 (amd64_emit_ops): Add the new functions.
8064 (i386_emit_eq_goto): New function.
8065 (i386_emit_ne_goto): New function.
8066 (i386_emit_lt_goto): New function.
8067 (i386_emit_le_goto): New function.
8068 (i386_emit_gt_goto): New function.
8069 (i386_emit_ge_goto): New function.
8070 (i386_emit_ops): Add the new functions.
8072 2011-09-08 Stan Shebs <stan@codesourcery.com>
8074 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
8075 (i386_emit_epilogue): Restore %ebx.
8077 2011-08-31 Jie Zhang <jzhang918@gmail.com>
8079 * server.c (step_thread): Remove definition.
8080 (process_serial_event): Don't handle Hs.
8081 * server.h (step_thread): Remove declaration.
8082 * target.c (set_desired_inferior): Remove use of step_thread.
8084 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
8086 * linux-low.c: Include linux-procfs.h.
8087 (linux_attach_lwp_1): Update comments.
8088 (linux_attach): Scan for existing threads when attaching to a
8089 process that is the tgid.
8090 * Makefile.in: Update dependencies.
8092 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
8094 * configure.srv: Add linux-procfs.o dependencies.
8096 2011-08-14 Yao Qi <yao@codesourcery.com>
8098 * target.h (struct target_ops): Fix indent.
8099 * win32-low.c (win32_target_ops): Fix comment.
8101 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
8102 Yao Qi <yao@codesourcery.com>
8104 * Makefile.in (clean): Remove tic6x-*.c files.
8105 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
8106 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
8107 (tic6x-c64xp-linux.c): Likewise.
8108 * configure.srv: Add support for tic6x-*-uclinux.
8109 * linux-tic6x-low.c: New.
8110 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
8112 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
8113 Yao Qi <yao@codesourcery.com>
8115 * target.h (struct target_ops): Add read_loadmap.
8116 * linux-low.c (struct target_loadseg): New type.
8117 (struct target_loadmap): New type.
8118 (linux_read_loadmap): New function.
8119 (linux_target_ops): Add linux_read_loadmap.
8120 * server.c (handle_query): Support qXfer:fdpic:read packet.
8121 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
8124 2011-08-05 Eli Zaretskii <eliz@gnu.org>
8126 * win32-low.c: Include <stdint.h>.
8128 2011-07-22 Pedro Alves <pedro@codesourcery.com>
8130 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
8131 to the inferior here.
8132 (i386_remove_aligned_watchpoint): Ditto.
8133 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
8134 fit part of the watchpoint in the debug registers.
8135 (i386_update_inferior_debug_regs): New.
8136 (i386_low_insert_watchpoint): Work on a local mirror of the debug
8137 registers, and only update the inferior on success.
8138 (i386_low_remove_watchpoint): Ditto.
8140 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
8142 * linux-low.c (compare_ints, unique, list_threads, show_process,
8143 linux_core_of_thread): Delete.
8144 (linux_target_ops): Change linux_core_of_thread to
8145 linux_common_core_of_thread.
8146 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
8147 * utils.c (malloc_failure): Change type of argument.
8148 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
8149 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
8150 common/linux-osdata.c, common/ptid.c and common/buffer.c.
8151 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
8152 (IPA_OBJS): Add common-utils-ipa.o.
8153 (ptid_h, linux_osdata_h): New macros.
8154 (server_h): Add common/common-utils.h, common/xml-utils.h,
8155 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
8157 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
8158 ptid.o, buffer.o): New rules.
8159 (linux-low.o): Add common/linux-osdata.h as a dependency.
8160 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
8161 * configure.ac: Add AC_HEADER_DIRENT check.
8162 * config.in: Regenerate.
8163 * configure: Regenerate.
8164 * remote-utils.c (xml_escape_text): Delete.
8165 (buffer_grow, buffer_free, buffer_init, buffer_finish,
8166 buffer_xml_printf): Move to common/buffer.c.
8167 * server.c (main): Remove call to initialize_inferiors.
8168 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
8169 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
8170 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
8171 internal_error, gdb_assert, gdb_assert_fail): Delete.
8172 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
8173 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
8175 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
8176 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
8177 initialize_inferiors): Delete.
8179 2011-07-20 Pedro Alves <pedro@codesourcery.com>
8181 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
8184 2011-05-31 Pedro Alves <pedro@codesourcery.com>
8186 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
8188 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
8190 2011-05-26 Yao Qi <yao@codesourcery.com>
8192 * Makefile.in (thread-db.o): Track dependence to
8193 common/gdb_thread_db.h.
8194 * thread-db.c: include gdb_thread_db.h from right place.
8196 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
8198 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
8199 __FILE__ and __LINE__ to internal_error.
8201 2011-05-13 Doug Evans <dje@google.com>
8203 * thread-db.c (try_thread_db_load_from_sdir): New function.
8204 (try_thread_db_load_from_dir): New function.
8205 (thread_db_load_search): Handle $sdir, ignore $pdir.
8206 Remove trying of system directories if search of
8207 libthread-db-search-path fails, that is now done via $sdir.
8209 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
8211 * server.c (handle_query): Add EnableDisableTracepoints to the list
8212 of supported features.
8213 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
8215 (cmd_qtenable_disable): New.
8216 (cmd_qtstart): Install tracepoints even if disabled.
8217 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
8218 receiving a QTEnable or QTDisable packet.
8219 (gdb_collect): Skip data collection if fast tracepoint is disabled.
8220 (ust_marker_to_static_tracepoint): Do not ignore disabled static
8222 (gdb_probe): Skip data collection if static tracepoint is disabled.
8224 2011-05-10 Doug Evans <dje@google.com>
8226 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
8228 2011-05-04 Doug Evans <dje@google.com>
8230 * linux-low.c (linux_join): Skip process lookup.
8231 * spu-low.c (spu_join): Ditto.
8232 * server.c (join_inferiors_callback): Delete.
8233 (process_serial_event): For 'D' packet (detach) call join_inferior
8236 2011-05-04 Joseph Myers <joseph@codesourcery.com>
8238 * README: Don't mention xscale*-*-linux*.
8239 * configure.srv (xscale*-*-linux*): Don't handle target.
8241 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
8243 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
8245 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
8246 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
8247 (i386_emit_void_call_2): Likewise.
8249 2011-04-26 Yao Qi <yao@codesourcery.com>
8251 * linux-low.c: Move common macros to linux-ptrace.h.
8252 Include linux-ptrace.h.
8253 * Makefile.in (linux_ptrace_h): New.
8254 (linux-low.o): Depends on linux-ptrace.h.
8256 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8258 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
8259 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
8260 (remote_prepare): New function with most of the TCP code from ...
8261 (remote_open): ... here. Detect PORT here unconditionally. Move also
8262 setting transport_is_reliable.
8263 * server.c (run_once): New variable.
8264 (gdbserver_usage): Document it.
8265 (main): Set run_once for `--once'. Call remote_prepare. Exit after
8266 the first run if RUN_ONCE.
8267 * server.h (run_once, remote_prepare): New declarations.
8269 2011-04-19 Tom Tromey <tromey@redhat.com>
8271 * win32-low.c (handle_load_dll): Remove duplicate "the".
8273 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
8275 Remove support for old Cygwin 1.5 versions.
8276 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
8277 function to avoid warning.
8278 (win32_add_one_solib): Use cygwin_conv_path function to avoid
8281 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
8283 * gdbserver/server.h (Macro _): Define it if not available.
8285 2011-03-14 Michael Snyder <msnyder@vmware.com>
8287 * hostio.c (handle_close): Remove unnecessary null test.
8289 2011-03-10 Joel Brobecker <brobecker@adacore.com>
8291 * Makefile.in (maintainer-clean realclean distclean): Remove
8292 "make ... subdir_do" command.
8294 2011-03-10 Michael Snyder <msnyder@vmware.com>
8296 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
8298 * server.c (handle_v_run): Free alloced buffer on early return.
8300 2011-03-09 Yao Qi <yao@codesourcery.com>
8303 2011-03-04 Yao Qi <yao@codesourcery.com>
8305 * Makefile.in: Remove GNU make feature --directory.
8307 2011-03-05 Yao Qi <yao@codesourcery.com>
8309 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
8310 (subdir_do): New make target. Copied from gdb/Makefile.
8311 (maintainer-clean, realclean, distclean, clean): Call corresponding
8312 make targets in common/Makefile.
8314 2011-02-11 Yao Qi <yao@codesourcery.com>
8316 * configure.ac: Call AC_PROG_RANLIB.
8317 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
8318 * configure: Regenerate.
8320 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
8322 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
8324 2011-03-06 Yao Qi <yao@codesourcery.com>
8326 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
8328 2011-03-05 Yao Qi <yao@codesourcery.com>
8330 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
8331 (subdir_do): New make target. Copied from gdb/Makefile.
8332 (maintainer-clean, realclean, distclean, clean): Call corresponding
8333 make targets in common/Makefile.
8335 2011-03-04 Yao Qi <yao@codesourcery.com>
8337 * Makefile.in: Remove GNU make feature --directory.
8339 2011-03-04 Michael Snyder <msnyder@vmware.com>
8341 * server.c (queue_stop_reply): Call xmalloc not malloc.
8343 2011-03-02 Michael Snyder <msnyder@vmware.com>
8345 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
8347 2011-02-28 Michael Snyder <msnyder@vmware.com>
8349 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
8350 (cmd_qtframe): Ditto.
8351 (cmd_qtbuffer): Ditto.
8352 (cmd_bigqtbuffer): Ditto.
8354 * utils.c (decimal2str): Initialize 'width' to nine, then
8357 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
8359 * hostio.c (require_data): Free *data, not data.
8361 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8363 * hostio.c (require_data): Use free, not xfree.
8365 2011-02-27 Michael Snyder <msnyder@vmware.com>
8367 * server.c (handle_query): Discard unused value.
8369 * hostio.c (require_data): Free malloc memory before returning
8372 2011-02-26 Michael Snyder <msnyder@vmware.com>
8374 * linux-low.c (list_threads): Call closedir for dirent.
8376 2011-02-27 Michael Snyder <msnyder@vmware.com>
8378 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
8379 a case statement falls through.
8381 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
8383 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
8386 2011-02-26 Michael Snyder <msnyder@vmware.com>
8388 * utils.c (decimal2str): Eliminate dead code and dead param.
8389 (pulongest): Drop dead param from call to decimal2str.
8392 2011-02-24 Joel Brobecker <brobecker@adacore.com>
8394 Revert the following patch (not approved yet):
8395 2011-02-21 Hui Zhu <teawater@gmail.com>
8396 * tracepoint.c (tp_printf): New function.
8397 (eval_agent_expr): Handle gdb_agent_op_printf.
8399 2011-02-21 Hui Zhu <teawater@gmail.com>
8401 * tracepoint.c (tp_printf): New function.
8402 (eval_agent_expr): Handle gdb_agent_op_printf.
8404 2011-02-18 Tom Tromey <tromey@redhat.com>
8406 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
8407 (tracepoint.o): Likewise.
8408 * tracepoint.c (enum gdb_agent_op): Use ax.def.
8409 (gdb_agent_op_names): Likewise.
8411 2011-02-18 Tom Tromey <tromey@redhat.com>
8413 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
8414 gdb_agent_op_rot>: New constants.
8415 (gdb_agent_op_names): Add pick and roll.
8416 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
8419 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8421 * aclocal.m4: Regenerated with aclocal-1.11.1.
8423 2011-02-14 Pedro Alves <pedro@codesourcery.com>
8425 * server.c (handle_qxfer_traceframe_info): New.
8426 (qxfer_packets): Register "traceframe-info".
8427 (handle_query): Report support for qXfer:traceframe-info:read+.
8428 * tracepoint.c (match_blocktype): New.
8429 (traceframe_find_block_type): Rename to ...
8430 (traceframe_walk_blocks): ... this. Add callback filter argument,
8432 (traceframe_find_block_type): New, reimplemented on top of
8433 traceframe_walk_blocks.
8434 (build_traceframe_info_xml): New.
8435 (traceframe_read_info): New.
8436 * server.h (traceframe_read_info): Declare.
8438 2011-02-11 Yao Qi <yao@codesourcery.com>
8440 * configure.ac: Call AC_PROG_RANLIB.
8441 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
8442 * configure: Regenerate.
8444 2011-02-07 Pedro Alves <pedro@codesourcery.com>
8446 * server.c (gdb_read_memory): Change return semantics to allow
8448 (handle_search_memory_1): Adjust.
8449 (process_serial_event) <'m' packet>: Handle partial transfers.
8450 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
8452 2011-01-28 Pedro Alves <pedro@codesourcery.com>
8454 * regcache.c (init_register_cache): Initialize
8455 regcache->register_status.
8456 (free_register_cache): Release regcache->register_status.
8457 (regcache_cpy): Copy register_status.
8458 (registers_to_string): Print 'x's for unavailable registers.
8459 (supply_register): Mark the register's status valid or
8460 unavailable, depending on whether a buffer was passed in or not.
8461 (supply_register_zeroed): New.
8462 (supply_regblock): Mark the registers' status valid or
8463 unavailable, depending on whether a buffer was passed in or not.
8464 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
8465 (struct regcache): New `register_status' field.
8466 (supply_register_zeroed): Declare.
8467 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
8468 supply_register_zeroed, rather than passing a NULL buffer to
8470 * tracepoint.c (fetch_traceframe_registers): Update comment.
8472 2011-01-28 Pedro Alves <pedro@codesourcery.com>
8474 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
8477 2011-01-25 Pedro Alves <pedro@codesourcery.com>
8479 * server.h (decode_xfer_write): Change prototype.
8480 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
8481 and don't extract the annex here.
8482 * server.c (decode_xfer_read): Remove `annex' parameter,
8483 and don't extract the annex here.
8485 (struct qxfer): New.
8486 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
8487 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
8488 (handle_qxfer_statictrace): New functions, abstracted out from
8489 handle_query, and made to use the struct qxfer interface.
8490 (handle_threads_qxfer_proper): Rename to ...
8491 (handle_qxfer_threads_proper): ... this.
8492 (handle_threads_qxfer): Rename to ...
8493 (handle_qxfer_threads): ... this. Adjust.
8494 (qxfer_packets): New array.
8495 (handle_qxfer): New function.
8496 (handle_query): Use handle_qxfer.
8498 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
8500 * gdbreplay.c: Shorten lines of >= 80 columns.
8501 * linux-low.c: Ditto.
8502 * linux-ppc-low.c: Ditto.
8503 * linux-s390-low.c: Ditto.
8504 * linux-sparc-low.c: Ditto.
8505 * linux-x86-low.c: Ditto.
8506 * linux-xtensa-low.c: Ditto.
8507 * mem-break.c: Ditto.
8509 * regcache.h: Ditto.
8510 * remote-utils.c: Ditto.
8513 * thread-db.c: Ditto.
8514 * tracepoint.c: Ditto.
8516 * win32-low.h: Ditto.
8518 2011-01-05 Joel Brobecker <brobecker@adacore.com>
8520 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
8523 2011-01-01 Joel Brobecker <brobecker@adacore.com>
8525 * server.c (gdbserver_version): Update copyright year in version
8527 * gdbreplay.c (gdbreplay_version): Ditto.
8529 2010-12-29 Jie Zhang <jie.zhang@analog.com>
8531 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
8532 * linux-bfin-low.c: New file.
8533 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
8534 PT_DATA_ADDR for BFIN targets.
8535 * Makefile.in (SFILES): Add linux-bfin-low.c.
8536 (clean): Remove reg-bfin.c.
8537 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
8538 * README: Mention supported Blackfin targets.
8540 2010-12-23 Mike Frysinger <vapier@gentoo.org>
8542 * .gitignore: New file.
8544 2010-11-16 Mike Frysinger <vapier@gentoo.org>
8546 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
8548 2010-10-22 Jie Zhang <jie@codesourcery.com>
8550 * Makefile.in: Add FLAGS_TO_PASS variable.
8551 (install): Remove dependency of install-only and recursively
8552 invoke make for install-only.
8554 2010-10-04 Doug Evans <dje@google.com>
8556 * Makefile.in (uninstall): Use $(DESTDIR).
8558 2010-09-24 Pedro Alves <pedro@codesourcery.com>
8562 * linux-x86-low.c (compat_siginfo_from_siginfo)
8563 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
8564 si_code is < 0. Check for si_code == SI_TIMER before checking for
8567 2010-09-13 Joel Brobecker <brobecker@adacore.com>
8569 * lynx-i386-low.c: New file.
8570 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
8572 2010-09-13 Joel Brobecker <brobecker@adacore.com>
8574 * lynx-low.c (ptrace_request_to_str): Remove handling for
8575 request values that have been removed in LynxOS 5.x.
8577 2010-09-13 Joel Brobecker <brobecker@adacore.com>
8579 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
8582 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
8584 * configure.ac: Add --enable-inprocess-agent option.
8585 * configure: Rebuilt.
8587 2010-09-06 Yao Qi <yao@codesourcery.com>
8589 * linux-low.c (linux_kill): Remove unused variable.
8590 (linux_stabilize_threads): Likewise.
8591 * server.c (start_inferior): Likewise.
8592 (queue_stop_reply_callback): Likewise.
8593 * tracepoint.c (do_action_at_tracepoint): Likewise.
8595 2010-09-06 Yao Qi <yao@codesourcery.com>
8597 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
8600 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8602 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
8604 2010-09-06 Pedro Alves <pedro@codesourcery.com>
8606 * Makefile.in (install-only): Replace $IPA_DEPFILES with
8609 2010-09-01 Joel Brobecker <brobecker@adacore.com>
8611 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
8612 gdbserver/lynx-ppc-low.c: New files.
8613 * Makefile.in (lynx_low_h): New variable.
8614 (lynx-low.o, lynx-ppc-low.o): New rules.
8615 * configure.ac: On LynxOS, link with -lnetinet.
8616 * configure.srv: Add handling of powerpc-*-lynxos* targets.
8617 * configure: regenerate.
8619 2010-09-01 Joel Brobecker <brobecker@adacore.com>
8621 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
8622 * configure.ac: Add check for vasprintf and vsnprintf.
8623 * configure, config.in: Regenerate.
8624 * server.h (vasprintf, vsnprintf): Add conditional declarations.
8626 2010-09-01 Joel Brobecker <brobecker@adacore.com>
8628 * gdbreplay.c: Move include of alloca.h up, next to include of
8630 * server.h: Add include of malloc.h.
8631 * mem-break.c: Remove include of malloc.h.
8632 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
8634 2010-09-01 Joel Brobecker <brobecker@adacore.com>
8636 * Makefile.in (memmem.o): Build with -Wno-error.
8638 2010-09-01 Joel Brobecker <brobecker@adacore.com>
8640 * utils.c (xsnprintf): Make non-static.
8641 * server.h: Add xsnprintf declaration.
8642 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
8643 replace calls to snprintf by calls to xsnprintf throughout.
8645 2010-09-01 Joel Brobecker <brobecker@adacore.com>
8647 * configure.ac: Add configure check for alloca.
8648 * configure, config.in: Regenerate.
8649 * server.h: Include alloca.h if it exists.
8650 * gdbreplay.c: Include alloca.h if it exists.
8652 2010-08-28 Pedro Alves <pedro@codesourcery.com>
8654 * linux-low.c (__SIGRTMIN): Define if not already defined.
8655 (linux_create_inferior): Check for __ANDROID__ rather than
8657 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
8658 are already deferred.
8659 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
8660 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
8661 stopped and already has a pending signal to report.
8662 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
8663 a pending signal to report or is moving out of a jump pad.
8664 (linux_init_signals): Check for __ANDROID__ rather than
8667 2010-08-28 Pedro Alves <pedro@codesourcery.com>
8669 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
8670 debug_threads check. Avoid a linear search when not doing debug
8673 2010-08-27 Pedro Alves <pedro@codesourcery.com>
8675 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
8676 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
8677 (struct file_handler) <fd>: Change type to gdb_fildes_t.
8678 (process_event): Change local fd's type to gdb_fildes_t.
8679 (create_file_handler): Adjust prototype.
8680 (delete_file_handler): Adjust prototype.
8681 (handle_file_event): Adjust prototype. Use pfildes.
8682 (create_file_event): Adjsut prototype.
8683 * remote-utils.c (remote_desc, listen_desc): Change type to
8685 * server.h: New gdb_fildes_t typedef.
8686 [USE_WIN32API]: Include winsock2.h.
8687 (delete_file_handler, add_file_handler): Adjust prototypes.
8689 * utils.c (pfildes): New.
8691 2010-08-27 Pedro Alves <pedro@codesourcery.com>
8693 * configure.ac (build_warnings): Add -Wno-char-subscripts.
8694 * configure: Regenerate.
8696 2010-08-27 Pedro Alves <pedro@codesourcery.com>
8698 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
8699 (linux_done_accessing_memory): ... this.
8700 (linux_target_ops): Adjust.
8701 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
8702 * nto-low.c (nto_target_ops): Adjust comment.
8703 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
8704 * spu-low.c (spu_target_ops): Adjust comment.
8705 * target.h (target_ops): Rename unprepare_to_access_memory field
8706 to done_accessing_memory.
8707 (unprepare_to_access_memory): Rename to ...
8708 (done_accessing_memory): ... this.
8710 2010-08-26 Pedro Alves <pedro@codesourcery.com>
8712 * linux-low.c (linux_prepare_to_access_memory): New.
8713 (linux_unprepare_to_access_memory): New.
8714 (linux_target_ops): Install them.
8715 * server.c (read_memory): Rename to ...
8716 (gdb_read_memory): ... this. Use
8717 prepare_to_access_memory/prepare_to_access_memory.
8718 (write_memory): Rename to ...
8719 (gdb_write_memory): ... this. Use
8720 prepare_to_access_memory/prepare_to_access_memory.
8721 (handle_search_memory_1): Adjust.
8722 (process_serial_event): Adjust.
8723 * target.h (struct target_ops): New fields
8724 prepare_to_access_memory and unprepare_to_access_memory.
8725 (prepare_to_access_memory, unprepare_to_access_memory): New.
8726 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
8727 prepare_to_access_memory/prepare_to_access_memory.
8728 * nto-low.c (nto_target_ops): Adjust.
8729 * spu-low.c (spu_target_ops): Adjust.
8730 * win32-low.c (win32_target_ops): Adjust.
8732 2010-08-26 Pedro Alves <pedro@codesourcery.com>
8734 * Makefile.in (WARN_CFLAGS): Get it from configure.
8735 (WERROR_CFLAGS): New.
8736 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
8737 * configure.ac: Introduce --enable-werror, which adds -Werror to
8738 the compiler command line. Enabled by default. Disable with
8739 --disable-werror. Add -Wdeclaration-after-statement
8740 Wpointer-arith and -Wformat-nonliteral to warning flags.
8741 * configure: Regenerate.
8743 2010-08-26 Pedro Alves <pedro@codesourcery.com>
8745 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
8747 2010-08-26 Pedro Alves <pedro@codesourcery.com>
8749 * gdbreplay.c (remote_error): New.
8751 (expect): Use gdbchar. Check for error reading from GDB.
8752 Clarify sync error output.
8753 (play): Check for errors writing to GDB.
8754 * linux-low.c (sigchld_handler): Really ignore `write' errors.
8755 * remote-utils.c (getpkt): Check for errors writing to the remote
8758 2010-08-25 Pedro Alves <pedro@codesourcery.com>
8760 * linux-low.c (linux_wait_1): Move non-debugging code out of
8761 `debug_threads' control.
8763 2010-08-25 Pedro Alves <pedro@codesourcery.com>
8765 * linux-low.c (linux_wait_1): Don't set last_status here.
8766 * server.c (push_event, queue_stop_reply_callback): Assert we're
8767 not pushing a TARGET_WAITKIND_IGNORE event.
8768 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
8769 (myresume, handle_target_event): Set the thread's last_resume_kind
8770 and last_status from the target returned status.
8772 2010-08-25 Pedro Alves <pedro@codesourcery.com>
8776 * linux-x86-low.c (update_debug_registers_callback): New.
8777 (i386_dr_low_set_addr): Use it.
8778 (i386_dr_low_get_addr): New.
8779 (i386_dr_low_set_control): Use update_debug_registers_callback.
8780 (i386_dr_low_get_control): New.
8781 (i386_dr_low_get_status): Adjust.
8782 * linux-low.c (linux_stop_lwp): New.
8783 * linux-low.h (linux_stop_lwp): Declare.
8785 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
8786 argument instead of a i386_debug_reg_state.
8787 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
8788 a i386_debug_reg_state.
8789 (i386_insert_aligned_watchpoint): Adjust.
8790 (i386_remove_aligned_watchpoint): Adjust.
8791 (i386_low_stopped_data_address): Read the debug registers from the
8792 inferior instead of from the mirrors.
8793 * i386-low.h (struct i386_debug_reg_state): Extend comment.
8794 (i386_dr_low_get_addr): Declare.
8795 (i386_dr_low_get_control): Declare.
8796 (i386_dr_low_get_status): Change prototype.
8798 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
8799 (i386_dr_low_get_addr): New.
8800 (i386_dr_low_get_control): New.
8801 (i386_dr_low_get_status): Adjust prototype. Return
8803 (i386_initial_stuff): Clear dr_status_mirror and
8805 (i386_get_thread_context): Adjust.
8806 (i386_set_thread_context): Adjust.
8807 (i386_thread_added): Adjust.
8809 2010-08-24 Pedro Alves <pedro@codesourcery.com>
8811 * linux-low.h (linux_thread_area): Delete declaration.
8813 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
8815 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
8816 after its termination.
8818 2010-08-09 Pedro Alves <pedro@codesourcery.com>
8820 * linux-low.c (gdb_wants_lwp_stopped): Delete.
8821 (gdb_wants_all_stopped): Delete.
8822 (linux_wait_1): Don't call them.
8823 * server.c (handle_v_cont): Tag all threads as want-stopped.
8824 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
8825 stopped as "client-wants-stopped".
8827 2010-07-31 Pedro Alves <pedro@codesourcery.com>
8829 * Makefile.in (signals_h): New.
8830 (server_h): Depend on it.
8831 (server.o): Don't depend on $(signals_def).
8832 (signals.o): Depend on $(signals_def).
8834 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
8836 * Makefile.in (signals_def): New.
8837 (server_h): Append include/gdb/signals.h and signals_def.
8838 (server.o): Append signals_def.
8840 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
8842 * server.c (handle_target_event): Use target_signal_to_host for
8843 resume_info.sig initialization.
8844 * target.h (struct thread_resume) <sig>: New comment.
8846 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
8848 * server.c (handle_query): strcpy() the returned string from paddress()
8849 instead of sprintf().
8850 * utils.c (paddress): Return phex_nz().
8852 2010-07-07 Joel Brobecker <brobecker@adacore.com>
8854 * server.c (handle_v_cont): Call mourn_inferior if process
8856 (myresume): Likewise.
8858 2010-07-01 Pedro Alves <pedro@codesourcery.com>
8860 Static tracepoints, and integration with UST.
8862 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
8863 * mem-break.c (uninsert_all_breakpoints)
8864 (reinsert_all_breakpoints): New.
8865 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
8866 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
8867 (gdb_agent_ust_loaded, helper_thread_id)
8868 (gdb_agent_helper_thread_id): New macros.
8869 (struct ipa_sym_addresses): Add addr_ust_loaded,
8870 addr_helper_thread_id, addr_cmd_buf.
8871 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
8872 (in_process_agent_loaded_ust): New.
8873 (write_e_ust_not_loaded): New.
8874 (maybe_write_ipa_ust_not_loaded): New.
8875 (struct collect_static_trace_data_action): New.
8876 (enum tracepoint_type) <static_tracepoint>: New.
8877 (struct tracepoint) <handle>: Mention static tracepoints.
8878 (struct static_tracepoint_ctx): New.
8879 (CMD_BUF_SIZE): New.
8880 (add_tracepoint_action): Handle static tracepoint actions.
8881 (unprobe_marker_at): New.
8882 (clear_installed_tracepoints): Handle static tracepoints.
8883 (cmd_qtdp): Handle static tracepoints.
8884 (probe_marker_at): New.
8885 (cmd_qtstart): Handle static tracepoints.
8886 (response_tracepoint): Handle static tracepoints.
8887 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
8888 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
8889 (get_context_regcache): Handle static tracepoints.
8890 (do_action_at_tracepoint): Handle static tracepoint actions.
8891 (traceframe_find_block_type): Handle static trace data blocks.
8892 (traceframe_read_sdata): New.
8893 (download_tracepoints): Download static tracepoint actions.
8894 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
8895 (GDB_PROBE_NAME): New.
8900 (ust_marker_to_static_tracepoint): New.
8902 (collect_ust_data_at_tracepoint): New.
8903 (gdb_ust_probe): New.
8904 (UNIX_PATH_MAX, SOCK_DIR): New.
8905 (gdb_ust_connect_sync_socket): New.
8906 (resume_thread, stop_thread): New.
8907 (run_inferior_command): New.
8908 (init_named_socket): New.
8909 (gdb_ust_socket_init): New.
8910 (cstr_to_hexstr): New.
8912 (first_marker, next_marker): New.
8913 (response_ust_marker): New.
8914 (cmd_qtfstm, cmd_qtsstm): New.
8915 (unprobe_marker_at, probe_marker_at): New.
8916 (cmd_qtstmat, gdb_ust_thread): New.
8917 (gdb_ust_init): New.
8918 (initialize_tracepoint_ftlib): Call gdb_ust_init.
8919 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
8921 (x86_64_st_collect_regmap): New.
8922 (X86_64_NUM_ST_COLLECT_GREGS): New.
8923 (AMD64_RIP_REGNUM): New.
8924 (supply_static_tracepoint_registers): New.
8925 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
8927 (i386_st_collect_regmap): New.
8928 (i386_NUM_ST_COLLECT_GREGS): New.
8929 (supply_static_tracepoint_registers): New.
8930 * server.c (handle_query): Handle qXfer:statictrace:read.
8931 <qSupported>: Report support for StaticTracepoints, and
8932 qXfer:statictrace:read features.
8933 * server.h (traceframe_read_sdata)
8934 (supply_static_tracepoint_registers): Declare.
8935 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
8936 (unpack_varlen_hex): Include in IPA build.
8937 * Makefile.in (ustlibs, ustinc): New.
8938 (IPA_OBJS): Add remote-utils-ipa.o.
8939 ($(IPA_LIB)): Link -ldl and -lpthread.
8941 (IPAGENT_CFLAGS): Add UST_CFLAGS.
8942 * config.in, configure: Regenerate.
8944 2010-06-20 Ian Lance Taylor <iant@google.com>
8945 Pedro Alves <pedro@codesourcery.com>
8947 * linux-x86-low.c (always_true): Delete.
8948 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
8949 trying to fool the compiler with always_true.
8951 2010-06-20 Pedro Alves <pedro@codesourcery.com>
8953 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
8954 conditions in gdbserver.
8956 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
8958 * spu-low.c (spu_read_memory): Wrap around local store limit.
8959 (spu_write_memory): Likewise.
8961 2010-06-15 Pedro Alves <pedro@codesourcery.com>
8963 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
8964 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
8966 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
8968 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
8969 uses with LONGEST uses.
8971 2010-06-14 Stan Shebs <stan@codesourcery.com>
8972 Pedro Alves <pedro@codesourcery.com>
8976 * linux-x86-low.c: Include limits.h.
8981 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
8982 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
8983 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
8984 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
8985 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
8986 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
8987 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
8988 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
8989 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
8990 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
8991 (amd64_emit_void_call_2): New.
8992 (amd64_emit_ops): New.
8993 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
8994 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
8995 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
8996 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
8997 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
8998 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
8999 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
9000 (i386_emit_call, i386_emit_reg, i386_emit_pop)
9001 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
9002 (i386_emit_stack_adjust, i386_emit_int_call_1)
9003 (i386_emit_void_call_2): New.
9004 (i386_emit_ops): New.
9005 (x86_emit_ops): New.
9006 (the_low_target): Install x86_emit_ops.
9007 * server.h (struct emit_ops): New.
9008 (get_raw_reg_func_addr): Declare.
9009 (current_insn_ptr, emit_error): Declare.
9010 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
9011 (set_trace_state_variable_value): New defines.
9012 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
9013 addr_get_trace_state_variable_value and
9014 addr_set_trace_state_variable_value.
9015 (symbol_list): New fields for get_raw_reg,
9016 get_trace_state_variable_value and set_trace_state_variable_value.
9017 (condfn): New typedef.
9018 (struct tracepoint): New field `compiled_cond'.
9019 (do_action_at_tracepoint): Clear compiled_cond.
9020 (get_trace_state_variable_value, set_trace_state_variable_value):
9022 (condition_true_at_tracepoint): If there's a compiled condition,
9024 (current_insn_ptr, emit_error): New globals.
9025 (struct bytecode_address): New.
9026 (get_raw_reg_func_addr): New.
9027 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
9028 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
9029 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
9030 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
9031 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
9032 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
9033 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
9034 (compile_tracepoint_condition, compile_bytecodes): New.
9035 * target.h (emit_ops): Forward declare.
9036 (struct target_ops): New field emit_ops.
9037 (target_emit_ops): New.
9038 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
9039 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
9040 * linux-low.c (linux_emit_ops): New.
9041 (linux_target_ops): Install it.
9042 * linux-low.h (struct linux_target_ops): New field emit_ops.
9044 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
9046 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
9047 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
9049 2010-06-01 Pedro Alves <pedro@codesourcery.com>
9050 Stan Shebs <stan@codesourcery.com>
9052 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
9053 (all): Depend on $(extra_libraries).
9054 (install-only): Install the IPA.
9055 (IPA_OBJS, IPA_LIB): New.
9056 (clean): Remove the IPA lib.
9057 (IPAGENT_CFLAGS): New.
9058 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
9059 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
9060 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
9061 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
9062 * configure.ac: Check for atomic builtins support in the compiler.
9063 (IPA_DEPFILES, extra_libraries): Define.
9064 * configure.srv (ipa_obj): Add description.
9065 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
9066 (i[34567]86-*-linux*): Set ipa_obj.
9067 (x86_64-*-linux*): Set ipa_obj.
9068 * linux-low.c (stabilizing_threads): New.
9069 (supports_fast_tracepoints): New.
9070 (linux_detach): Stabilize threads before detaching.
9071 (handle_tracepoints): Handle internal tracing breakpoints. Assert
9072 the lwp is either not stabilizing, or is moving out of a jump pad.
9073 (linux_fast_tracepoint_collecting): New.
9074 (maybe_move_out_of_jump_pad): New.
9075 (enqueue_one_deferred_signal): New.
9076 (dequeue_one_deferred_signal): New.
9077 (linux_wait_for_event_1): If moving out of a jump pad, defer
9078 pending signals to later.
9079 (linux_stabilize_threads): New.
9080 (linux_wait_1): Check if threads need moving out of jump pads, and
9082 (stuck_in_jump_pad_callback): New.
9083 (move_out_of_jump_pad_callback): New.
9085 (linux_resume_one_lwp): Handle moving out of jump pads.
9086 (linux_set_resume_request): Dequeue deferred signals.
9087 (need_step_over_p): Also step over fast tracepoint jumps.
9088 (start_step_over): Also uninsert fast tracepoint jumps.
9089 (finish_step_over): Also reinsert fast tracepoint jumps.
9090 (linux_install_fast_tracepoint_jump): New.
9091 (linux_target_ops): Install linux_stabilize_threads and
9092 linux_install_fast_tracepoint_jump_pad.
9093 * linux-low.h (linux_target_ops) <get_thread_area,
9094 install_fast_tracepoint_jump_pad>: New fields.
9095 (struct lwp_info) <collecting_fast_tracepoint,
9096 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
9097 (linux_get_thread_area): Declare.
9098 * linux-x86-low.c (jump_insn): New.
9099 (x86_get_thread_area): New.
9100 (append_insns): New.
9102 (amd64_install_fast_tracepoint_jump_pad): New.
9103 (i386_install_fast_tracepoint_jump_pad): New.
9104 (x86_install_fast_tracepoint_jump_pad): New.
9105 (the_low_target): Install x86_get_thread_area and
9106 x86_install_fast_tracepoint_jump_pad.
9107 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
9108 (struct fast_tracepoint_jump): New.
9109 (fast_tracepoint_jump_insn): New.
9110 (fast_tracepoint_jump_shadow): New.
9111 (find_fast_tracepoint_jump_at): New.
9112 (fast_tracepoint_jump_here): New.
9113 (delete_fast_tracepoint_jump): New.
9114 (set_fast_tracepoint_jump): New.
9115 (uninsert_fast_tracepoint_jumps_at): New.
9116 (reinsert_fast_tracepoint_jumps_at): New.
9117 (set_breakpoint_at): Use write_inferior_memory.
9118 (uninsert_raw_breakpoint): Use write_inferior_memory.
9119 (check_mem_read): Mask out fast tracepoint jumps.
9120 (check_mem_write): Mask out fast tracepoint jumps.
9121 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
9122 (set_fast_tracepoint_jump): Declare.
9123 (delete_fast_tracepoint_jump)
9124 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
9125 (reinsert_fast_tracepoint_jumps_at): Declare.
9126 * regcache.c: Don't compile many functions when building the
9127 in-process agent library.
9128 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
9129 the register buffer in the heap.
9130 (free_register_cache): If the register buffer isn't owned by the
9131 regcache, don't free it.
9132 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
9133 pre-existing register caches.
9134 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
9136 (convert_ascii_to_int): : Constify `from' parameter type.
9137 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
9138 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
9139 the needed buffer in-place.
9140 (relocate_instruction): New.
9141 * server.c (handle_query) <qSymbols>: If the target supports
9142 tracepoints, give it a chance of looking up symbols. Report
9143 support for fast tracepoints.
9144 (handle_status): Stabilize threads.
9145 (process_serial_event): Adjust.
9146 * server.h (struct fast_tracepoint_jump): Forward declare.
9147 (struct process_info) <fast_tracepoint_jumps>: New field.
9148 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
9149 (decode_X_packet, decode_M_packet): Adjust.
9150 (relocate_instruction): Declare.
9151 (in_process_agent_loaded): Declare.
9152 (tracepoint_look_up_symbols): Declare.
9153 (struct fast_tpoint_collect_status): Declare.
9154 (fast_tracepoint_collecting): Declare.
9155 (force_unlock_trace_buffer): Declare.
9156 (handle_tracepoint_bkpts): Declare.
9157 (initialize_low_tracepoint)
9158 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
9159 * target.h (struct target_ops) <stabilize_threads,
9160 install_fast_tracepoint_jump_pad>: New fields.
9161 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
9162 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
9163 [HAVE_STDINT_H]: Include stdint.h.
9164 (trace_debug_1): Rename to ...
9165 (trace_vdebug): ... this.
9166 (trace_debug): Rename to ...
9167 (trace_debug_1): ... this. Add `level' parameter.
9169 (ATTR_USED, ATTR_NOINLINE): New.
9170 (IP_AGENT_EXPORT): New.
9171 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9172 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
9173 (about_to_request_buffer_space, trace_buffer_is_full)
9174 (stopping_tracepoint, expr_eval_result, error_tracepoint)
9175 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
9176 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
9177 (traceframe_write_count, traceframes_created)
9178 (trace_state_variables)
9179 New renaming defines.
9180 (struct ipa_sym_addresses): New.
9181 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
9183 (ipa_sym_addrs): New.
9184 (all_tracepoint_symbols_looked_up): New.
9185 (in_process_agent_loaded): New.
9186 (write_e_ipa_not_loaded): New.
9187 (maybe_write_ipa_not_loaded): New.
9188 (tracepoint_look_up_symbols): New.
9189 (debug_threads) [IN_PROCESS_AGENT]: New.
9190 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
9191 (UNKNOWN_SIDE_EFFECTS): New.
9192 (stop_tracing): New.
9193 (flush_trace_buffer): New.
9194 (stop_tracing_bkpt): New.
9195 (flush_trace_buffer_bkpt): New.
9196 (read_inferior_integer): New.
9197 (read_inferior_uinteger): New.
9198 (read_inferior_data_pointer): New.
9199 (write_inferior_data_pointer): New.
9200 (write_inferior_integer): New.
9201 (write_inferior_uinteger): New.
9202 (struct collect_static_trace_data_action): Delete.
9203 (enum tracepoint_type): New.
9204 (struct tracepoint) <type>: New field `type'.
9205 <actions_str, step_actions, step_actions_str>: Only include in
9207 <orig_size, obj_addr_on_target, adjusted_insn_addr>
9208 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
9209 (tracepoints): Use IP_AGENT_EXPORT.
9210 (last_tracepoint): Don't include in the IPA.
9211 (stopping_tracepoint): Use IP_AGENT_EXPORT.
9212 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
9213 (alloced_trace_state_variables): New.
9214 (trace_state_variables): Use IP_AGENT_EXPORT.
9215 (traceframe_t): Delete unused variable.
9216 (circular_trace_buffer): Don't include in the IPA.
9217 (trace_buffer_start): Delete.
9218 (struct trace_buffer_control): New.
9219 (trace_buffer_free): Delete.
9220 (struct ipa_trace_buffer_control): New.
9221 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
9222 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
9224 (trace_buffer_ctrl): New.
9225 (TRACE_BUFFER_CTRL_CURR): New.
9226 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
9227 Reimplement as macros.
9228 (trace_buffer_wrap): Delete.
9229 (traceframe_write_count, traceframe_read_count)
9230 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
9231 (struct tracepoint_hit_ctx) <type>: New field.
9232 (struct fast_tracepoint_ctx): New.
9233 (memory_barrier): New.
9235 (record_tracepoint_error): Update atomically in the IPA.
9236 (clear_inferior_trace_buffer): New.
9237 (about_to_request_buffer_space): New.
9238 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
9239 updating the same buffer.
9240 (add_tracepoint): Default the tracepoint's type to trap
9241 tracepoint, and orig_size to -1.
9242 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
9244 (create_trace_state_variable): New parameter `gdb'. Handle it.
9245 (clear_installed_tracepoints): Clear fast tracepoint jumps.
9246 (cmd_qtdp): Handle fast tracepoints.
9248 (max_jump_pad_size): New.
9249 (gdb_jump_pad_head): New.
9250 (get_jump_space_head): New.
9251 (claim_jump_space): New.
9252 (sort_tracepoints): New.
9253 (MAX_JUMP_SIZE): New.
9254 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
9256 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
9257 support. Upload fast traceframes, and delete internal IPA
9259 (stop_tracing_handler): New.
9260 (flush_trace_buffer_handler): New.
9261 (cmd_qtstop): Upload fast tracepoints.
9262 (response_tracepoint): Handle fast tracepoints.
9263 (tracepoint_finished_step): Upload fast traceframes. Set the
9264 tracepoint hit context's tracepoint type.
9265 (handle_tracepoint_bkpts): New.
9266 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
9267 type. Add comment about fast tracepoints.
9268 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
9269 non-existing action_str field.
9270 (get_context_regcache): Handle fast tracepoints.
9271 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
9273 (fast_tracepoint_from_jump_pad_address): New.
9274 (fast_tracepoint_from_ipa_tpoint_address): New.
9275 (collecting_t): New.
9276 (force_unlock_trace_buffer): New.
9277 (fast_tracepoint_collecting): New.
9280 (write_inferior_data_ptr): New.
9281 (target_tp_heap): New.
9282 (target_malloc): New.
9283 (download_agent_expr): New.
9285 (download_tracepoints): New.
9286 (download_trace_state_variables): New.
9287 (upload_fast_traceframes): New.
9288 (IPA_FIRST_TRACEFRAME): New.
9289 (IPA_NEXT_TRACEFRAME_1): New.
9290 (IPA_NEXT_TRACEFRAME): New.
9291 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
9292 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
9293 (gdb_jump_pad_buffer_end): New.
9294 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
9295 (initialize_tracepoint): Adjust.
9296 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
9297 buffer. Initialize the low module.
9298 * utils.c (PREFIX, TOOLNAME): New.
9299 (malloc_failure): Use PREFIX.
9300 (error): In the IPA, an error causes an exit.
9301 (fatal, warning): Use PREFIX.
9302 (internal_error): Use TOOLNAME.
9303 (NUMCELLS): Increase to 10.
9304 * configure, config.in: Regenerate.
9306 2010-06-01 Pedro Alves <pedro@codesourcery.com>
9308 * server.c (handle_query) <qSupported>: Do two passes over the
9309 qSupported string to avoid nesting strtok.
9311 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9313 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
9315 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
9317 * configure: Regenerate.
9318 * proc-service.list: New.
9320 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9322 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
9325 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
9327 * gdbreplay.c (remote_open): Check error return from socket() call by
9328 its equality to -1 not by it being negative.
9329 * remote-utils.c (remote_open): Likewise.
9331 2010-05-23 Pedro Alves <pedro@codesourcery.com>
9333 * config.h: Regenerate.
9335 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
9337 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
9338 doesn't provide PTRACE_GET_THREAD_AREA.
9340 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
9342 * linux-m68k-low.c: Include <asm/ptrace.h>
9343 (ps_get_thread_area): Implement.
9345 2010-05-03 Doug Evans <dje@google.com>
9347 * event-loop.c (struct callback_event): New struct.
9348 (callback_list): New global.
9349 (append_callback_event, delete_callback_event): New functions.
9350 (process_callback): New function.
9351 (start_event_loop): Call it.
9352 * remote-utils.c (NOT_SCHEDULED): Define.
9353 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
9354 moved out of readchar.
9355 (readchar): Rewrite. Call reschedule before returning.
9356 (reset_readchar): New function.
9357 (remote_close): Call it.
9358 (process_remaining, reschedule): New functions.
9359 * server.h (callback_handler_func): New typedef.
9360 (append_callback_event, delete_callback_event): Declare.
9362 2010-05-03 Pedro Alves <pedro@codesourcery.com>
9364 * proc-service.c (ps_pglobal_lookup): Use
9365 thread_db_look_up_one_symbol.
9366 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
9367 parameter. Use it instead of all_symbols_looked_up.
9368 * server.h (struct process_info) <all_symbols_looked_up>: Delete
9370 (all_symbols_looked_up): Don't declare.
9371 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
9372 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
9374 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
9375 Set all_symbols_looked_up here.
9376 (thread_db_look_up_one_symbol): New.
9377 (thread_db_get_tls_address): Adjust.
9378 (thread_db_load_search, try_thread_db_load_1): Always allocate the
9379 thread_db object on the heap, and tentatively set it in the
9381 (thread_db_init): Don't set all_symbols_looked_up here.
9382 * linux-low.h (thread_db_look_up_one_symbol): Declare.
9384 2010-05-03 Pedro Alves <pedro@codesourcery.com>
9386 * linux-low.c (linux_kill, linux_detach): Adjust.
9387 (status_pending_p_callback): Remove redundant statement. Check
9388 for !TARGET_WAITIKIND_IGNORE, instead of
9389 TARGET_WAITKIND_STOPPED.
9390 (handle_tracepoints): Make sure LWP is locked. Adjust.
9391 (linux_wait_for_event_1): Adjust.
9392 (linux_cancel_breakpoints): New.
9393 (unsuspend_one_lwp): New.
9394 (unsuspend_all_lwps): New.
9395 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
9396 (send_sigstop_callback): Change return type to int, add new
9397 `except' parameter and handle it.
9398 (suspend_and_send_sigstop_callback): New.
9399 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
9400 pass them down. If SUSPEND, also increment the lwp's suspend
9402 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
9403 (need_step_over_p): Don't consider suspended LWPs.
9404 (start_step_over): Adjust.
9405 (proceed_one_lwp): Change return type to int, add new `except'
9406 parameter and handle it.
9407 (unsuspend_and_proceed_one_lwp): New.
9408 (proceed_all_lwps): Use find_inferior instead of
9410 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
9411 also decrement the suspend count of LWPs. Pass `except' down,
9412 instead of hacking its suspend count.
9413 (linux_pause_all): Add `freeze' parameter. Adjust.
9414 (linux_unpause_all): New.
9415 (linux_target_ops): Install linux_unpause_all.
9416 * server.c (handle_status): Adjust.
9417 * target.h (struct target_ops): New fields `unpause_all' and
9418 `cancel_breakpoints'. Add new parameter to `pause_all'.
9419 (pause_all): Add new `freeze' parameter.
9421 (cancel_breakpoints): New.
9422 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
9424 (cmd_qtstart): Pause threads.
9425 (stop_tracing): Pause threads, and cancel breakpoints.
9426 * win32-low.c (win32_target_ops): Adjust.
9428 2010-05-03 Pedro Alves <pedro@codesourcery.com>
9430 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
9431 the inferior right away from here...
9432 (linux_wait_1): ... to here, and adjust to check the thread's
9433 last_resume_kind instead of the lwp's step or stop_expected flags.
9435 2010-05-02 Pedro Alves <pedro@codesourcery.com>
9437 * README: Use consistent `GDB' and `GDBserver' spellings.
9439 2010-05-02 Pedro Alves <pedro@codesourcery.com>
9441 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
9442 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
9443 (linux_detach_one_lwp): Assume the lwp is stopped.
9444 (any_thread_of): Delete.
9445 (linux_detach): Stop all lwps here. Don't blindly delete all
9447 (delete_lwp_callback): New.
9448 (linux_mourn): Delete all lwps of the process that is gone.
9449 (linux_wait_1): Don't delete the last lwp of the process here.
9450 * mem-break.h (mark_breakpoints_out): Declare.
9451 * mem-break.c (mark_breakpoints_out): New.
9452 (free_all_breakpoints): Use it.
9453 * server.c (handle_target_event): If the process is gone, mark
9455 * thread-db.c (struct thread_db) <create_bp>: New field.
9456 (thread_db_enable_reporting): Fix prototype. Store a thread event
9457 breakpoint reference in the thread_db struct.
9458 (thread_db_load_search): Clear the thread_db object.
9459 (try_thread_db_load_1): Ditto.
9460 (switch_to_process): New.
9461 (disable_thread_event_reporting): Use it.
9462 (remove_thread_event_breakpoints): New.
9463 (thread_db_detach, thread_db_mourn): Use it.
9465 2010-05-01 Pedro Alves <pedro@codesourcery.com>
9467 * linux-low.c (linux_enable_event_reporting): New.
9468 (linux_wait_for_event_1, handle_extended_wait): Use it.
9470 2010-04-30 Pedro Alves <pedro@codesourcery.com>
9472 * linux-low.c (linux_kill_one_lwp, linux_kill)
9473 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
9474 (send_sigstop): Take an lwp_info as parameter instead. Queue a
9475 SIGSTOP even if the LWP is stopped.
9476 (send_sigstop_callback): New.
9477 (stop_all_lwps): Use send_sigstop_callback instead.
9478 (linux_resume_one_thread): Adjust.
9479 (proceed_one_lwp): Still proceed an LWP that the client has
9480 requested to stop, if we haven't reported it as stopped yet. Make
9481 sure that LWPs the client want stopped, have a pending SIGSTOP.
9483 2010-04-26 Doug Evans <dje@google.com>
9485 * server.c (handle_general_set): Make static.
9487 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
9488 Print received char after testing for error/eof instead of before.
9489 (input_interrupt): Tweak comment.
9491 2010-04-23 Doug Evans <dje@google.com>
9493 * server.c (start_inferior): Print inferior argv if --debug.
9495 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
9497 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
9498 * nto-x86-low.c: Include server.h
9500 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
9502 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
9503 be consistent with other sources of this directory.
9504 (init_registers_amd64): Correct name of source file of this function
9507 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
9509 * configure.srv (x86_64-*-mingw*): New configuration for Windows
9512 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
9514 * win32-i386-low.c: Add 64-bit support.
9515 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
9516 (init_registers_amd64): Declare.
9517 (mappings): Add 64-bit version of array.
9518 (init_windows_x86): New function.
9519 (the_low_target): Change init_arch field to init_windows_x86.
9521 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
9523 * win32-low.c: Adapt to support also 64-bit architecture.
9524 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
9525 (get_image_name): Use SIZE_T type for local variable `done'.
9526 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
9527 (toolhelp_get_dll_name): Idem.
9528 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
9529 Use uintptr_t typecast to avoid warning.
9530 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
9531 (handle_exception): Use phex_nz to avoid warning.
9532 (win32_wait): Remove unused local variable `process'.
9534 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
9536 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
9539 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
9541 * configure.ac: Use `ws2_32' library for srv_mingw.
9542 * configure: Regenerate.
9543 * gdbreplay.c: Include winsock2.h instead of winsock.h.
9544 * remote-utils.c: Likewise.
9546 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
9548 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
9549 if __x86_64__ is defined.
9551 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
9553 * configure: Regenerate.
9555 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
9557 * server.c (handle_query): Handle 'qGetTIBAddr' query.
9558 * target.h (target_ops): New get_tib_address field.
9559 * win32-low.h (win32_thread_info): Add thread_local_base field.
9560 * win32-low.c (child_add_thread): Add tlb argument.
9561 Set thread_local_base field to TLB.
9562 (get_child_debug_event): Adapt to child_add_thread change.
9563 (win32_get_tib_address): New function.
9564 (win32_target_ops): Set get_tib_address field to
9565 win32_get_tib_address.
9566 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
9568 2010-04-12 Pedro Alves <pedro@codesourcery.com>
9570 * linux-low.c (linux_mourn): Also remove the process.
9571 * server.c (handle_target_event): Don't remove the process here.
9572 * nto-low.c (nto_mourn): New.
9573 (nto_target_ops): Install it.
9574 * spu-low.c (spu_mourn): New.
9575 (spu_target_ops): Install it.
9576 * win32-low.c (win32_mourn): New.
9577 (win32_target_ops): Install it.
9579 2010-04-12 Pedro Alves <pedro@codesourcery.com>
9581 * server.h (buffer_xml_printf): Remove redundant `;'.
9583 2010-04-12 Pedro Alves <pedro@codesourcery.com>
9585 * regcache.c (set_register_cache): Invalidate regcaches before
9586 changing the register cache layout.
9587 (regcache_invalidate_one): Allow a NULL regcache.
9588 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
9589 regcaches before changing the register cache layout or the target
9592 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
9594 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
9595 variable warning on Linux/x86-64.
9597 2010-04-11 Pedro Alves <pedro@codesourcery.com>
9599 GDBserver disconnected tracing support.
9601 * linux-low.c (linux_remove_process): Delete.
9602 (add_lwp): Don't set last_resume_kind here.
9603 (linux_kill): Use `mourn'.
9604 (linux_detach): Use `thread_db_detach', and `mourn'.
9606 (linux_attach_lwp_1): Adjust comment.
9607 (linux_attach): last_resume_kind moved the thread_info; adjust.
9608 (status_pending_p_callback): Adjust.
9609 (linux_wait_for_event_1): Adjust.
9610 (count_events_callback, select_singlestep_lwp_callback)
9611 (select_event_lwp_callback, cancel_breakpoints_callback)
9612 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
9613 (proceed_one_lwp): Adjust.
9614 (linux_async): Add debug output.
9615 (linux_thread_stopped): New.
9616 (linux_pause_all): New.
9617 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
9619 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
9620 (thread_db_free): Delete declaration.
9621 (thread_db_detach, thread_db_mourn): Declare.
9622 * thread-db.c (thread_db_init): Use thread_db_mourn.
9623 (thread_db_free): Delete, split in two.
9624 (disable_thread_event_reporting): New.
9625 (thread_db_detach): New.
9626 (thread_db_mourn): New.
9628 * server.h (struct thread_info) <last_resume_kind>: New field.
9629 <attached>: Add comment.
9630 <gdb_detached>: New field.
9631 (handler_func): Change return type to int.
9632 (handle_serial_event, handle_target_event): Ditto.
9633 (gdb_connected): Declare.
9635 (disconnected_tracing): Declare.
9636 (stop_tracing): Declare.
9638 * server.c (handle_query) <qSupported>: Report support for
9639 disconnected tracing.
9640 (queue_stop_reply_callback): Account for running threads.
9641 (gdb_wants_thread_stopped): New.
9642 (gdb_wants_all_threads_stopped): New.
9643 (gdb_reattached_process): New.
9644 (handle_status): Clear the `gdb_detached' flag of all processes.
9645 In all-stop, stop all threads.
9646 (main): Be sure to leave tfind mode. Handle disconnected tracing.
9647 (process_serial_event): If the remote connection breaks, or if an
9648 exit was forced with "monitor exit", force an event loop exit.
9649 Handle disconnected tracing on detach.
9650 (handle_serial_event): Adjust.
9651 (handle_target_event): If GDB isn't connected, forward events back
9652 to the inferior, unless the last process exited, in which case,
9653 exit gdbserver. Adjust interface.
9655 * remote-utils.c (remote_open): Don't block in accept. Instead
9656 register an event loop source on the listen socket file
9657 descriptor. Refactor bits into ...
9658 (listen_desc): ... this new global.
9659 (gdb_connected): ... this new function.
9660 (enable_async_notification): ... this new function.
9661 (handle_accept_event): ... this new function.
9662 (remote_close): Clear remote_desc.
9664 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
9666 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
9668 (mourn_inferior): Define.
9669 (target_process_qsupported): Avoid the dangling else problem.
9670 (thread_stopped): Define.
9671 (pause_all): Define.
9672 (target_waitstatus_to_string): Declare.
9673 * target.c (target_waitstatus_to_string): New.
9675 * tracepoint.c (tracing): Make extern.
9676 (disconnected_tracing): New.
9677 (stop_tracing): Make extern. Handle tracing stops due to GDB
9679 (cmd_qtdisconnected): New.
9680 (cmd_qtstatus): Report disconnected tracing status in trace reply.
9681 (handle_tracepoint_general_set): Handle QTDisconnected.
9683 * event-loop.c (event_handler_func): Change return type to int.
9684 (process_event): Bail out if the event handler wants the event
9686 (handle_file_event): Ditto.
9687 (start_event_loop): Bail out if the event handler wants the event
9690 * nto-low.c (nto_target_ops): Adjust.
9691 * spu-low.c (spu_wait): Don't remove the process here.
9692 (spu_target_ops): Adjust.
9693 * win32-low.c (win32_wait): Don't remove the process here.
9694 (win32_target_ops): Adjust.
9696 2010-04-11 Pedro Alves <pedro@codesourcery.com>
9698 * regcache.c (realloc_register_cache): Invalidate inferior's
9699 regcache before recreating it.
9701 2010-04-09 Pedro Alves <pedro@codesourcery.com>
9703 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
9705 2010-04-09 Stan Shebs <stan@codesourcery.com>
9706 Pedro Alves <pedro@codesourcery.com>
9708 * server.h (LONGEST): New.
9709 (struct thread_info) <while_stepping>: New field.
9710 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
9712 (initialize_tracepoint, handle_tracepoint_general_set)
9713 (handle_tracepoint_query, tracepoint_finished_step)
9714 (tracepoint_was_hit, release_while_stepping_state_list):
9715 (current_traceframe): Declare.
9716 * server.c (handle_general_set): Handle tracepoint packets.
9718 (write_memory): New.
9719 (handle_search_memory_1): Use read_memory.
9720 (handle_query): Report support for conditional tracepoints, trace
9721 state variables, and tracepoint sources. Handle tracepoint
9723 (main): Initialize the tracepoints module.
9724 (process_serial_event): Handle traceframe reads/writes.
9726 * linux-low.c (handle_tracepoints): New.
9727 (linux_wait_1): Call it.
9728 (linux_resume_one_lwp): Handle while-stepping.
9729 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
9730 (linux_target_ops): Install them.
9731 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
9733 * linux-x86-low.c (x86_supports_tracepoints): New.
9734 (the_low_target). Install it.
9736 * mem-break.h (delete_breakpoint): Declare.
9737 * mem-break.c (delete_breakpoint): Make external.
9739 * target.h (struct target_ops): Add `supports_tracepoints',
9740 `read_pc', and `write_pc' fields.
9741 (target_supports_tracepoints): Define.
9742 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
9745 * regcache.h (struct regcache) <registers_owned>: New field.
9746 (init_register_cache, regcache_cpy): Declare.
9747 (regcache_read_pc, regcache_write_pc): Declare.
9748 (register_cache_size): Declare.
9749 (supply_regblock): Declare.
9750 * regcache.c (init_register_cache): New.
9751 (new_register_cache): Use it.
9752 (regcache_cpy): New.
9753 (register_cache_size): New.
9754 (supply_regblock): New.
9755 (regcache_read_pc, regcache_write_pc): New.
9757 * tracepoint.c: New.
9759 * Makefile.in (OBS): Add tracepoint.o.
9760 (tracepoint.o): New rule.
9762 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
9764 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
9766 (i386-mmx.c): Likewise.
9767 (i386-mmx-linux.o): Likewise.
9768 (i386-mmx-linux.c): Likewise.
9770 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
9771 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
9772 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
9773 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
9775 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
9776 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
9777 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
9779 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
9781 * Makefile.in (clean): Updated.
9783 (i386-avx.c): Likewise.
9784 (i386-avx-linux.o): Likewise.
9785 (i386-avx-linux.c): Likewise.
9786 (amd64-avx.o): Likewise.
9787 (amd64-avx.c): Likewise.
9788 (amd64-avx-linux.o): Likewise.
9789 (amd64-avx-linux.c): Likewise.
9791 * configure.srv (srv_i386_regobj): Add i386-avx.o.
9792 (srv_i386_linux_regobj): Add i386-avx-linux.o.
9793 (srv_amd64_regobj): Add amd64-avx.o.
9794 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
9795 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
9796 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
9797 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
9798 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
9799 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
9800 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
9802 * i387-fp.c: Include "i386-xstate.h".
9804 (i387_cache_to_xsave): Likewise.
9805 (i387_xsave_to_cache): Likewise.
9806 (x86_xcr0): Likewise.
9808 * i387-fp.h (i387_cache_to_xsave): Likewise.
9809 (i387_xsave_to_cache): Likewise.
9810 (x86_xcr0): Likewise.
9812 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
9813 * linux-crisv32-low.c (target_regsets): Likewise.
9814 * linux-m68k-low.c (target_regsets): Likewise.
9815 * linux-mips-low.c (target_regsets): Likewise.
9816 * linux-ppc-low.c (target_regsets): Likewise.
9817 * linux-s390-low.c (target_regsets): Likewise.
9818 * linux-sh-low.c (target_regsets): Likewise.
9819 * linux-sparc-low.c (target_regsets): Likewise.
9820 * linux-xtensa-low.c (target_regsets): Likewise.
9822 * linux-low.c: Include <sys/uio.h>.
9823 (regsets_fetch_inferior_registers): Support nt_type.
9824 (regsets_store_inferior_registers): Likewise.
9825 (linux_process_qsupported): New.
9826 (linux_target_ops): Add linux_process_qsupported.
9828 * linux-low.h (regset_info): Add nt_type.
9829 (linux_target_ops): Add process_qsupported.
9831 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
9833 (init_registers_i386_avx_linux): New.
9834 (init_registers_amd64_avx_linux): Likewise.
9835 (xmltarget_i386_linux_no_xml): Likewise.
9836 (xmltarget_amd64_linux_no_xml): Likewise.
9837 (PTRACE_GETREGSET): Likewise.
9838 (PTRACE_SETREGSET): Likewise.
9839 (x86_fill_xstateregset): Likewise.
9840 (x86_store_xstateregset): Likewise.
9841 (use_xml): Likewise.
9842 (x86_linux_update_xmltarget): Likewise.
9843 (x86_linux_process_qsupported): Likewise.
9844 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
9845 (x86_arch_setup): Don't call init_registers_amd64_linux nor
9846 init_registers_i386_linux here. Call
9847 x86_linux_update_xmltarget.
9848 (the_low_target): Add x86_linux_process_qsupported.
9850 * server.c (handle_query): Call target_process_qsupported.
9852 * target.h (target_ops): Add process_qsupported.
9853 (target_process_qsupported): New.
9855 2010-04-03 Pedro Alves <pedro@codesourcery.com>
9857 * inferiors.c (add_thread): Set last_status kind to
9858 TARGET_WAITKIND_IGNORE.
9859 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
9860 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
9861 (linux_wait_1): Move `thread' local definition to block that uses
9862 it. Don't NULL initialize `event_child'.
9863 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
9864 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
9865 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
9867 2010-04-01 Pedro Alves <pedro@codesourcery.com>
9869 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
9870 an extended waitstatus, or by a watchpoint.
9871 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
9872 thread was stepping or has been stopped by a watchpoint.
9874 2010-04-01 Pedro Alves <pedro@codesourcery.com>
9876 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
9877 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
9878 of another, then delete the previous, and validate all
9880 (validate_inserted_breakpoint): New.
9881 (delete_disabled_breakpoints): New.
9882 (validate_breakpoints): New.
9883 (check_mem_read): Validate breakpoints before trusting their
9884 shadow. Delete disabled breakpoints.
9885 (check_mem_write): Validate breakpoints before trusting they
9886 should be inserted. Delete disabled breakpoints.
9887 * mem-break.h (validate_breakpoints):
9888 * server.c (handle_query): Validate breakpoints when we see a
9891 2010-04-01 Pedro Alves <pedro@codesourcery.com>
9893 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
9894 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
9895 if we could tell there's a GDB breakpoint at stop_pc.
9896 (need_step_over_p): Don't do a step over if we find a GDB
9897 breakpoint at the resume PC.
9899 * mem-break.c (struct raw_breakpoint): New.
9900 (enum bkpt_type): New type `gdb_breakpoint'.
9901 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
9902 fields. New field `raw'.
9903 (find_raw_breakpoint_at): New.
9904 (set_raw_breakpoint_at): Handle refcounting. Create a raw
9906 (set_breakpoint_at): Adjust.
9907 (delete_raw_breakpoint): New.
9908 (release_breakpoint): New.
9909 (delete_breakpoint): Rename to...
9910 (delete_breakpoint_1): ... this. Add proc parameter. Use
9911 release_breakpoint. Return ENOENT.
9912 (delete_breakpoint): Reimplement.
9913 (find_breakpoint_at): Delete.
9914 (find_gdb_breakpoint_at): New.
9915 (delete_breakpoint_at): Delete.
9916 (set_gdb_breakpoint_at): New.
9917 (delete_gdb_breakpoint_at): New.
9918 (gdb_breakpoint_here): New.
9919 (set_reinsert_breakpoint): Use release_breakpoint.
9920 (uninsert_breakpoint): Rename to ...
9921 (uninsert_raw_breakpoint): ... this.
9922 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
9923 (reinsert_raw_breakpoint): Change parameter type to
9925 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
9927 (check_breakpoints): Adjust. Use release_breakpoint.
9928 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
9929 (breakpoint_inserted_here): Ditto.
9930 (check_mem_read): Adjust to iterate over raw breakpoints instead.
9931 Don't trust the breakpoint's shadow if it is not inserted.
9932 (check_mem_write): Adjust to iterate over raw breakpoints instead.
9933 (delete_all_breakpoints): Adjust.
9934 (free_all_breakpoints): Mark all breakpoints as uninserted, and
9935 use delete_breakpoint_1.
9937 * mem-break.h (breakpoints_supported): Delete declaration.
9938 (set_gdb_breakpoint_at): Declare.
9939 (gdb_breakpoint_here): Declare.
9940 (delete_breakpoint_at): Delete.
9941 (delete_gdb_breakpoint_at): Declare.
9943 * server.h (struct raw_breakpoint): Forward declare.
9944 (struct process_info): New field `raw_breakpoints'.
9946 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
9949 2010-03-24 Pedro Alves <pedro@codesourcery.com>
9951 * linux-low.c (status_pending_p_callback): Fix comment.
9952 (linux_wait_for_event_1): Move most of the internal breakpoint
9953 handling from here...
9954 (linux_wait_1): ... to here.
9955 (count_events_callback): New.
9956 (select_singlestep_lwp_callback): New.
9957 (select_event_lwp_callback): New.
9958 (cancel_breakpoints_callback): New.
9959 (select_event_lwp): New.
9960 (linux_wait_1): Simplify internal breakpoint handling. Give equal
9961 priority to all LWPs that have had events that should be reported
9962 to the client. Cancel breakpoints when about to reporting the
9963 event to the client, not while stopping lwps. No longer cancel
9964 finished single-steps here.
9965 (cancel_finished_single_step): Delete.
9966 (cancel_finished_single_steps): Delete.
9968 2010-03-24 Pedro Alves <pedro@codesourcery.com>
9970 * mem-break.c (enum bkpt_type): New.
9971 (struct breakpoint): New field `type'.
9972 (set_breakpoint_at): Change return type to struct breakpoint
9973 pointer. Set type to `other_breakpoint' by default.
9974 (delete_breakpoint): Rewrite, supporting more than one breakpoint
9975 in the breakpoint list.
9976 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
9977 (reinsert_breakpoint): Rename to ...
9978 (reinsert_raw_breakpoint): ... this.
9979 (reinsert_breakpoints_at): Adjust.
9980 * mem-break.h (struct breakpoint): Declare.
9981 (set_breakpoint_at): Change return type to struct breakpoint
9984 2010-03-24 Pedro Alves <pedro@codesourcery.com>
9986 * server.c (handle_query): Assign, not compare.
9988 2010-03-24 Pedro Alves <pedro@codesourcery.com>
9990 Teach linux gdbserver to step-over-breakpoints.
9992 * linux-low.c (can_hardware_single_step): New.
9993 (supports_breakpoints): New.
9994 (handle_extended_wait): If stopping threads, read the stop pc of
9997 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
9998 low target doesn't support retrieving the PC.
9999 (add_lwp): Set last_resume_kind to resume_continue.
10000 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
10001 (linux_attach): Don't clear stop_expected. Set the lwp's
10002 last_resume_kind to resume_stop.
10003 (linux_detach_one_lwp): Don't check for removed breakpoints.
10004 (check_removed_breakpoint): Delete.
10005 (status_pending_p): Rename to ...
10006 (status_pending_p_callback): ... this. Don't check for removed
10007 breakpoints. Don't consider threads that are stopped from GDB's
10009 (linux_wait_for_lwp): Always read the stop_pc here.
10010 (cancel_breakpoint): New.
10011 (step_over_bkpt): New global.
10012 (linux_wait_for_event_1): Implement stepping over breakpoints.
10013 (gdb_wants_lwp_stopped): New.
10014 (gdb_wants_all_stopped): New.
10015 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
10016 single-step traps here. Store the thread's last reported target
10018 (send_sigstop): Don't clear stop_expected. Always set it,
10020 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
10021 (cancel_finished_single_step): New.
10022 (cancel_finished_single_steps): New.
10023 (wait_for_sigstop): Don't cancel finished single-step traps here.
10024 (linux_resume_one_lwp): Don't check for removed breakpoints.
10025 Don't set `step' on non-hardware step archs.
10026 (linux_set_resume_request): Ignore resume_stop requests if already
10027 stopping or stopped. Set the lwp's last_resume_kind.
10028 (resume_status_pending_p): Don't check for removed breakpoints.
10029 (need_step_over_p): New.
10030 (start_step_over): New.
10031 (finish_step_over): New.
10032 (linux_resume_one_thread): Always queue a sigstop for resume_stop
10033 requests. Clear the thread's last reported target waitstatus.
10034 Don't use the `suspended' flag. Don't consider pending breakpoints.
10035 (linux_resume): Start a step-over if necessary.
10036 (proceed_one_lwp): New.
10037 (proceed_all_lwps): New.
10038 (unstop_all_lwps): New.
10039 * linux-low.h (struct lwp_info): Rewrite comment for the
10040 `suspended' flag. Add the `stop_pc' field. Delete the
10041 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
10042 Add `'last_resume_kind' and `need_step_over' fields.
10043 * inferiors.c (struct thread_info): Delete, moved elsewhere.
10044 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
10045 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
10046 (set_raw_breakpoint_at): New.
10047 (set_breakpoint_at): Rewrite to use it.
10048 (reinsert_breakpoint_handler): Delete.
10049 (set_reinsert_breakpoint): New.
10050 (reinsert_breakpoint_by_bp): Delete.
10051 (delete_reinsert_breakpoints): New.
10052 (uninsert_breakpoint): Rewrite.
10053 (uninsert_breakpoints_at): New.
10054 (reinsert_breakpoint): Rewrite.
10055 (reinsert_breakpoints_at): New.
10056 (check_breakpoints): Rewrite.
10057 (breakpoint_here): New.
10058 (breakpoint_inserted_here): New.
10059 (check_mem_read): Adjust.
10060 * mem-break.h (breakpoints_supported, breakpoint_here)
10061 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
10062 (reinsert_breakpoint_by_bp): Delete declaration.
10063 (delete_reinsert_breakpoints): Declare.
10064 (reinsert_breakpoint): Delete declaration.
10065 (reinsert_breakpoints_at): Declare.
10066 (uninsert_breakpoint): Delete declaration.
10067 (uninsert_breakpoints_at): Declare.
10068 (check_breakpoints): Adjust prototype.
10069 * server.h: Adjust include order.
10070 (struct thread_info): Declare here. Add a `last_status' field.
10072 2010-03-23 Michael Snyder <msnyder@vmware.com>
10074 * server.c (crc32): New function.
10075 (handle_query): Add handling for 'qCRC:' request.
10077 2010-03-23 Pedro Alves <pedro@codesourcery.com>
10079 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
10080 lwp had been stopped by a watchpoint.
10082 2010-03-16 Pedro Alves <pedro@codesourcery.com>
10084 * server.h (internal_error): Declare.
10085 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
10086 * utils.c (internal_error): New function.
10088 2010-03-15 Andreas Schwab <schwab@redhat.com>
10090 * configure.srv: Fix typo setting srv_regobj.
10092 2010-03-15 Pedro Alves <pedro@codesourcery.com>
10094 * linux-low.c (fetch_register): Avoid passing a non string literal
10096 (usr_store_inferior_registers): Ditto.
10098 2010-03-14 Pedro Alves <pedro@codesourcery.com>
10100 * linux-low.c (linux_write_memory): Bail out early if peeking
10103 2010-03-14 Pedro Alves <pedro@codesourcery.com>
10105 * linux-low.h (struct lwp_info): New fields
10106 `stopped_by_watchpoint' and `stopped_data_address'.
10107 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
10108 here, and cache them in the lwp object.
10109 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
10111 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
10113 (linux_stopped_by_watchpoint): Rewrite.
10114 (linux_stopped_data_address): Rewrite.
10116 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
10118 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
10119 switching the current inferior, not before.
10121 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
10123 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
10124 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
10125 i386-linux.c and amd64-linux.c.
10126 (reg-i386.o): Removed.
10127 (reg-i386.c): Likewise.
10128 (reg-i386-linux.o): Likewise.
10129 (reg-i386-linux.c): Likewise.
10130 (reg-x86-64.o): Likewise.
10131 (reg-x86-64.c): Likewise.
10132 (reg-x86-64-linux.o): Likewise.
10133 (reg-x86-64-linux.c): Likewise.
10135 (i386.c): Likewise.
10136 (i386-linux.o): Likewise.
10137 (i386-linux.c): Likewise.
10138 (amd64.o): Likewise.
10139 (amd64.c): Likewise.
10140 (amd64-linux.o): Likewise.
10141 (amd64-linux.c): Likewise.
10143 * configure.srv (srv_i386_regobj): New.
10144 (srv_i386_linux_regobj): Likewise.
10145 (srv_amd64_regobj): Likewise.
10146 (srv_amd64_linux_regobj): Likewise.
10147 (srv_i386_32bit_xmlfiles): Likewise.
10148 (srv_i386_64bit_xmlfiles): Likewise.
10149 (srv_i386_xmlfiles): Likewise.
10150 (srv_amd64_xmlfiles): Likewise.
10151 (srv_i386_linux_xmlfiles): Likewise.
10152 (srv_amd64_linux_xmlfiles): Likewise.
10153 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
10154 srv_xmlfiles to $srv_i386_xmlfiles.
10155 (i[34567]86-*-mingw32ce*): Likewise.
10156 (i[34567]86-*-mingw*): Likewise.
10157 (i[34567]86-*-nto*): Likewise.
10158 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
10159 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
10160 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
10161 (x86_64-*-linux*): Likewise.
10163 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
10164 (init_registers_amd64_linux): New.
10165 (x86_arch_setup): Replace init_registers_x86_64_linux with
10166 init_registers_amd64_linux.
10168 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
10170 * configure.ac: Check for libdl. If it is not available link against
10171 static libthread_db.
10172 * configure: Regenerate.
10174 2010-02-22 Pedro Alves <pedro@codesourcery.com>
10178 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
10179 handing a read watchpoint.
10180 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
10182 2010-02-12 Doug Evans <dje@google.com>
10184 * linux-low.c (linux_supports_tracefork_flag): Document.
10185 (linux_look_up_symbols): Add comment.
10187 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
10189 * regcache.c (supply_register): Clear regcache if buf is NULL.
10191 2010-02-02 Nicolas Roche <roche@sourceware.org>
10192 Joel Brobecker <brobecker@adacore.com>
10194 * inferiors.c (find_inferior): Add function documentation.
10195 (unloaded_dll): Handle the case where the unloaded dll has not
10196 been previously registered in the dll list.
10198 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
10200 * linux-arm-low.c (thumb_breakpoint_len): Delete.
10201 (thumb2_breakpoint): New.
10202 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
10204 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
10206 * linux-low.c (get_stop_pc): Check for SIGTRAP.
10207 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
10210 2010-01-21 Pedro Alves <pedro@codesourcery.com>
10212 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
10214 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10216 * linux-s390-low.c (s390_collect_ptrace_register)
10217 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
10219 2010-01-21 Doug Evans <dje@google.com>
10221 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
10222 (PTRACE_ARG4_TYPE): New macro.
10223 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
10224 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
10225 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
10226 (usr_store_inferior_registers): Ditto.
10227 (linux_read_memory, linux_write_memory): Ditto.
10228 (linux_test_for_tracefork): Ditto.
10230 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
10231 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
10233 2010-01-21 Pedro Alves <pedro@codesourcery.com>
10235 * proc-service.c (ps_lgetregs): Don't refetch registers from the
10238 2010-01-21 Pedro Alves <pedro@codesourcery.com>
10240 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
10241 prototype to take a regcache. Adjust.
10243 2010-01-20 Pedro Alves <pedro@codesourcery.com>
10245 * regcache.h (struct thread_info): Forward declare.
10246 (struct regcache): New.
10247 (new_register_cache): Adjust prototype.
10248 (get_thread_regcache): Declare.
10249 (free_register_cache): Adjust prototype.
10250 (registers_to_string, registers_from_string): Ditto.
10251 (supply_register, supply_register_by_name, collect_register)
10252 (collect_register_as_string, collect_register_by_name): Ditto.
10253 * regcache.c (struct inferior_regcache_data): Delete.
10254 (get_regcache): Rename to ...
10255 (get_thread_regcache): ... this. Adjust. Switch inferior before
10256 fetching registers.
10257 (regcache_invalidate_one): Adjust.
10258 (regcache_invalidate): Fix prototype.
10259 (new_register_cache): Return the new register cache.
10260 (free_register_cache): Change prototype.
10261 (realloc_register_cache): Adjust.
10262 (registers_to_string): Change prototype to take a regcache. Adjust.
10263 (registers_from_string): Ditto.
10264 (register_data): Ditto.
10265 (supply_register): Ditto.
10266 (supply_register_by_name): Ditto.
10267 (collect_register): Ditto.
10268 (collect_register_as_string): Ditto.
10269 (collect_register_by_name): Ditto.
10270 * server.c (process_serial_event): Adjust.
10271 * linux-low.h (regset_fill_func, regset_store_func): Change
10273 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
10275 * linux-low.c (get_stop_pc): Adjust.
10276 (check_removed_breakpoint): Adjust.
10277 (linux_wait_for_event): Adjust.
10278 (linux_resume_one_lwp): Adjust.
10279 (fetch_register): Add regcache parameter. Adjust.
10280 (usr_store_inferior_registers): Ditto.
10281 (regsets_fetch_inferior_registers): Ditto.
10282 (regsets_store_inferior_registers): Ditto.
10283 (linux_fetch_registers, linux_store_registers): Ditto.
10284 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
10286 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
10288 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
10289 prototype to take a regcache.
10290 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
10291 * remote-utils.c (convert_ascii_to_int, outreg)
10292 (prepare_resume_reply): Change prototype to take a regcache.
10294 * target.h (struct target_ops) <fetch_registers, store_registers>:
10295 Change prototype to take a regcache.
10296 (fetch_inferior_registers, store_inferior_registers): Change
10297 prototype to take a regcache. Adjust.
10298 * proc-service.c (ps_lgetregs): Adjust.
10299 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
10300 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
10301 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
10302 take a regcache. Adjust.
10303 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
10304 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
10305 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
10306 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
10307 * linux-cris-low.c (cris_get_pc, cris_set_pc)
10308 (cris_cannot_fetch_register):
10309 (cris_breakpoint_at): Change prototype to take a regcache.
10311 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
10312 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
10313 to take a regcache. Adjust.
10314 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
10316 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
10317 take a regcache. Adjust.
10318 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
10319 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
10320 (m68k_set_pc): Change prototype to take a regcache. Adjust.
10321 * linux-mips-low.c (mips_get_pc):
10322 (mips_set_pc): Change prototype to take a regcache. Adjust.
10323 (mips_reinsert_addr): Adjust.
10324 (mips_collect_register): Change prototype to take a regcache.
10326 (mips_supply_register):
10327 (mips_collect_register_32bit, mips_supply_register_32bit)
10328 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
10329 (mips_store_fpregset): Ditto.
10330 * linux-ppc-low.c (ppc_supply_ptrace_register)
10331 (ppc_supply_ptrace_register): Ditto.
10332 (parse_spufs_run): Adjust.
10333 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
10334 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
10335 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
10336 take a regcache. Adjust.
10337 * linux-s390-low.c (s390_collect_ptrace_register)
10338 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
10339 (s390_set_pc): Change prototype to take a regcache. Adjust.
10340 (s390_arch_setup): Adjust.
10341 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
10342 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
10343 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10344 (sparc_fill_gregset, sparc_store_gregset_from_stack)
10345 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
10347 (sparc_breakpoint_at): Adjust.
10348 * linux-xtensa-low.c (xtensa_fill_gregset):
10349 (xtensa_store_gregset):
10350 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
10351 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
10352 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
10353 prototype to take a regcache. Adjust.
10354 * win32-arm-low.c (arm_fetch_inferior_register)
10355 (arm_store_inferior_register): Change prototype to take a
10357 * win32-i386-low.c (i386_fetch_inferior_register)
10358 (i386_store_inferior_register): Change prototype to take a
10360 * win32-low.c (child_fetch_inferior_registers)
10361 (child_store_inferior_registers): Change prototype to take a
10363 (win32_wait): Adjust.
10364 (win32_fetch_inferior_registers): Change prototype to take a
10366 (win32_store_inferior_registers): Adjust.
10367 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
10368 store_inferior_register>: Change prototype to take a regcache.
10370 2010-01-20 Doug Evans <dje@google.com>
10372 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
10374 (linux_wait_for_event1, linux_init_signals): Ditto.
10375 (W_STOPCODE): Provide definition if missing.
10377 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
10379 * linux-low.c (linux_core_of_thread): New.
10380 (compare_ints, show_process, list_threads): New.
10381 (linux_qxfer_osdata): Report threads and cores.
10382 (linux_target_op): Register linux_core_of_thread.
10383 * remote-utils.c (prepare_resume_reply): Report the core.
10384 (buffer_xml_printf): Support %d specifier.
10385 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
10387 (handle_query): Handle qXfer:threads. Announce availability
10389 * target.h (struct target_ops): New field core_of_thread.
10391 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
10393 * Makefile.in (clean): Remove new generated files.
10394 (reg-s390.o, reg-s390.c): Remove rules.
10395 (reg-s390x.o, reg-s390x.c): Likewise.
10396 (s390-linux32.o, s390-linux32.c): Add rules.
10397 (s390-linux64.o, s390-linux64.c): Likewise.
10398 (s390x-linux64.o, s390x-linux64.c): Likewise.
10399 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
10400 * linux-s390-low.c: Include <elf.h>.
10401 (HWCAP_S390_HIGH_GPRS): Define if undefined.
10402 (init_registers_s390): Remove prototype.
10403 (init_registers_s390x): Likewise.
10404 (init_registers_s390_linux32): Add prototype.
10405 (init_registers_s390_linux64): Likewise.
10406 (init_registers_s390x_linux64): Likewise.
10407 (s390_num_regs_3264): New define.
10408 (s390_regmap_3264): New global variable.
10409 (s390_cannot_fetch_register): Remove obsolete check.
10410 (s390_cannot_store_register): Likewise.
10411 (s390_collect_ptrace_register): Handle upper/lower register halves.
10412 (s390_supply_ptrace_register): Likewise.
10413 (s390_fill_gregset): Update to register number changes.
10414 (s390_get_hwcap): New routine.
10415 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
10416 Install appropriate regmap and register set.
10418 2010-01-01 Joel Brobecker <brobecker@adacore.com>
10420 * server.c (gdbserver_version): Update copyright year to 2010.
10421 * gdbreplay.c (gdbreplay_version): Likewise.
10423 2009-12-28 Doug Evans <dje@google.com>
10425 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
10426 elf/external.h. Include <elf.h> instead but only if necessary.
10428 2009-12-28 Pedro Alves <pedro@codesourcery.com>
10430 * linux-low.c (linux_remove_process): Remove `detaching'
10431 parameter. Don't release/detach from thread_db here.
10432 (linux_kill): Release/detach from thread_db here, ...
10433 (linux_detach): ... and here, before actually detaching.
10434 (linux_wait_1): ... and here, when a process exits.
10435 * thread-db.c (any_thread_of): New.
10436 (thread_db_free): Switch the current inferior to a thread of the
10439 2009-12-21 Doug Evans <dje@google.com>
10441 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
10443 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
10444 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
10445 warning ifndef __NR_tkill. Move setting of errno there too.
10446 Delete unnecessary resetting of errno after syscall.
10447 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
10449 * configure.ac: Check for dladdr.
10450 * config.in: Regenerate.
10451 * configure: Regenerate.
10452 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
10453 (try_thread_db_load): Update.
10455 * linux-low.c (my_waitpid): Delete unnecessary prototype.
10457 2009-12-18 Doug Evans <dje@google.com>
10459 * event-loop.c: Include unistd.h if it exists.
10461 * linux-low.c (my_waitpid): Move definition away from being in
10462 between linux_tracefork_child/linux_test_for_tracefork.
10464 * gdb_proc_service.h (psaddr_t): Fix type.
10465 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
10466 signature to match glibc.
10468 2009-12-16 Doug Evans <dje@google.com>
10470 * linux-low.c (linux_read_memory): Fix argument to read.
10472 2009-11-26 Pedro Alves <pedro@codesourcery.com>
10474 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
10475 events, don't leave current_inferior pointing at null.
10477 2009-11-26 Pedro Alves <pedro@codesourcery.com>
10479 * win32-low.c (LOG): Delete.
10480 (OUTMSG): Output to stderr.
10481 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
10482 on compile time LOG macro.
10483 (win32_wait): Fix debug output.
10485 2009-11-26 Pedro Alves <pedro@codesourcery.com>
10487 * win32-low.c (win32_add_one_solib): If the dll name is
10488 "ntdll.dll", prepend the system directory to the dll path.
10490 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
10492 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
10494 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
10495 Vladimir Prus <vladimir@codesourcery.com>
10497 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
10498 * configure.ac: Check for __mcoldfire__ and set
10499 gdb_cv_m68k_is_coldfire.
10500 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
10501 reg-cf.o and reg-m68k.o.
10502 * configure: Regenerated.
10504 2009-11-16 Pedro Alves <pedro@codesourcery.com>
10506 * linux-low.c (linux_remove_process): Add `detaching' parameter.
10507 Pass it to thread_db_free.
10508 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
10509 proper `detaching' argument to linux_remove_process.
10510 * linux-low.h (thread_db_free): Add `detaching' parameter.
10511 * thread-db.c (thread_db_init): Pass false as `detaching' argument
10513 (thread_db_free): Add `detaching' parameter. Only
10514 call td_ta_clear_event if detaching from process.
10516 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
10518 * thread-db.c (thread_db_free): Fix typo.
10520 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
10523 * thread-db.c (thread_db_free): Call td_ta_clear_event.
10525 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
10527 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
10528 with an i686 compiler.
10529 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
10531 * configure: Rebuilt.
10533 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
10537 * server.c (handle_search_memory_1): Correct read_addr initialization
10538 in loop for searching subsequent chunks.
10540 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
10542 * configure.ac: New --with-libthread-db option.
10543 * thread-db.c: Allow direct dependence on libthread_db.
10544 (thread_db_free): Adjust.
10545 * config.in: Regenerate.
10546 * configure: Likewise.
10548 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
10551 * thread-db.c (attach_thread): New function.
10552 (maybe_attach_thread): Return success/failure.
10553 (find_new_threads_callback): Adjust.
10554 (thread_db_find_new_threads): Loop until no new threads.
10556 2009-10-13 Pedro Alves <pedro@codesourcery.com>
10558 * proc-service.c (ps_lgetregs): Formatting.
10560 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
10562 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
10563 * configure.ac: Adjust.
10564 * linux-low.h (struct process_info_private): Move members to struct
10566 (thread_db_free, thread_db_handle_monitor_command): New prototype.
10567 * linux-low.c (linux_remove_process): Adjust.
10568 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
10569 * server.c (handle_query): Move code ...
10570 (handle_monitor_command): ... here. New function.
10571 * target.h (struct target_ops): New member.
10572 * thread-db.c (struct thread_db): New.
10573 (libthread_db_search_path): New variable.
10574 (thread_db_create_event, thread_db_enable_reporting)
10575 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
10576 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
10577 (try_thread_db_load_1, dladdr_to_soname): New functions.
10578 (try_thread_db_load, thread_db_load_search): New functions.
10579 (thread_db_init): Search for libthread_db.
10580 (thread_db_free): New function.
10581 (thread_db_handle_monitor_command): Likewise.
10582 * config.in: Regenerate.
10583 * configure: Regenerate.
10585 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
10587 * spu-low.c (spu_kill): Wait for inferior to terminate.
10588 Call clear_inferiors.
10589 (spu_detach): Call clear_inferiors.
10591 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
10593 * aclocal.m4: Regenerate.
10594 * config.in: Likewise.
10595 * configure: Likewise.
10597 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
10599 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
10600 (parse_spufs_run): New function.
10601 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
10602 (ppc_breakpoint_at): Handle SPU breakpoints.
10604 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
10606 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
10607 (SPUFS_MAGIC): Define.
10608 (spu_enumerate_spu_ids): New function.
10609 (linux_qxfer_spu): New function.
10610 (linux_target_ops): Install linux_qxfer_spu.
10612 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
10614 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
10615 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
10616 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
10617 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
10618 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
10619 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
10620 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
10621 (init_registers_powerpc_cell32l): Add prototype.
10622 (init_registers_powerpc_cell64l): Likewise.
10623 (ppc_arch_setup): Detect Cell/B.E. architecture.
10625 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
10627 * Makefile.in (datarootdir): New variable.
10629 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
10631 * linux-low.c (linux_write_memory): Update debugging output.
10632 * Makefile.in (clean): Add new descriptions.
10633 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
10634 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
10635 * configure.srv: Add new files for arm*-*-linux*.
10636 * linux-arm-low.c: Add new declarations.
10637 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
10638 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
10639 (HWCAP_VFPv3D16): New.
10640 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
10641 instead of __IWMMXT__.
10642 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
10643 (arm_arch_setup): New.
10644 (target_regsets): Remove #ifdef. Add VFP regset.
10645 (the_low_target): Use arm_arch_setup.
10647 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
10649 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
10650 the main thread again.
10652 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
10654 Adding Neutrino gdbserver.
10655 * configure: Regenerated.
10656 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
10657 * configure.srv (i[34567]86-*-nto*): New target.
10658 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
10659 * remote-utils.c [__QNX__]: Include sys/iomgr.h
10660 (nto_comctrl) [__QNX__]: New function.
10661 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
10663 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
10665 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
10668 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
10669 Pedro Alves <pedro@codesourcery.com>
10671 * win32-i386-low.c (i386_get_thread_context): Handle systems that
10672 don't support CONTEXT_EXTENDED_REGISTERS.
10673 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
10674 (the_low_target): Install them.
10675 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
10676 failing with ERROR_PIPE_NOT_CONNECTED.
10678 2009-06-30 Doug Evans <dje@google.com>
10679 Pierre Muller <muller@ics.u-strasbg.fr>
10681 Add h/w watchpoint support to x86-linux, win32-i386.
10682 * Makefile.in (SFILES): Add i386-low.c
10683 (i386_low_h): Define.
10684 (i386-low.o): Add dependencies.
10685 (linux-x86-low.o): Add i386-low.h dependency.
10686 (win32-i386-low.o): Ditto.
10687 * i386-low.c: New file.
10688 * i386-low.h: New file.
10689 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
10690 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
10691 * linux-low.c (linux_add_process): Initialize arch_private.
10692 (linux_remove_process): Free arch_private.
10693 (add_lwp): Initialize arch_private.
10694 (delete_lwp): Free arch_private.
10695 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
10697 * linux-low.h (process_info_private): New member arch_private.
10698 (lwp_info): New member arch_private.
10699 (linux_target_ops): New members new_process, new_thread,
10701 (ptid_of): New macro.
10702 * linux-x86-low.c: Include stddef.h, i386-low.h.
10703 (arch_process_info): New struct.
10704 (arch_lwp_info): New struct.
10705 (x86_linux_dr_get, x86_linux_dr_set): New functions.
10706 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
10707 (i386_dr_low_get_status): New function.
10708 (x86_insert_point, x86_remove_point): New functions.
10709 (x86_stopped_by_watchpoint): New function.
10710 (x86_stopped_data_address): New function.
10711 (x86_linux_new_process, x86_linux_new_thread): New functions.
10712 (x86_linux_prepare_to_resume): New function.
10713 (the_low_target): Add entries for insert_point, remove_point,
10714 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
10716 * server.c (debug_hw_points): New global.
10717 (monitor_show_help): Document set debug-hw-points.
10718 (handle_query): Process "set debug-hw-points".
10719 * server.h (debug_hw_points): Declare.
10720 (paddress): Declare.
10721 * utils.c (NUMCELLS, CELLSIZE): New macros.
10722 (get_sell, xsnprintf, paddress): New functions.
10723 * win32-arm-low.c (the_low_target): Add entries for insert_point,
10724 remove_point, stopped_by_watchpoint, stopped_data_address.
10725 * win32-i386-low.c: Include i386-low.h.
10726 (debug_reg_state): Replaces dr.
10727 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
10728 (i386_dr_low_get_status): New function.
10729 (i386_insert_point, i386_remove_point): New functions.
10730 (i386_stopped_by_watchpoint): New function.
10731 (i386_stopped_data_address): New function.
10732 (i386_initial_stuff): Update.
10733 (get_thread_context,set_thread_context,i386_thread_added): Update.
10734 (the_low_target): Add entries for insert_point,
10735 remove_point, stopped_by_watchpoint, stopped_data_address.
10736 * win32-low.c (win32_insert_watchpoint): New function.
10737 (win32_remove_watchpoint): New function.
10738 (win32_stopped_by_watchpoint): New function.
10739 (win32_stopped_data_address): New function.
10740 (win32_target_ops): Add entries for insert_watchpoint,
10741 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
10742 * win32-low.h (win32_target_ops): New members insert_point,
10743 remove_point, stopped_by_watchpoint, stopped_data_address.
10745 2009-06-25 Pedro Alves <pedro@codesourcery.com>
10747 * server.c (process_serial_event): Re-return unsupported, not
10748 error, if the type isn't recognized. Re-allow supporting only
10749 insert or remove packets. Also call require_running for
10750 breakpoints. Add missing break statement to default case. Tidy.
10751 * target.h (struct target_ops): Rename insert_watchpoint to
10752 insert_point, and remove_watchpoint to remove_point.
10754 * linux-low.h (struct linux_target_ops): Likewise.
10755 * linux-low.c (linux_insert_watchpoint): Rename to ...
10756 (linux_insert_point): ... this. Adjust.
10757 (linux_remove_watchpoint): Rename to ...
10758 (linux_remove_point): ... this. Adjust.
10759 (linux_target_ops): Adjust.
10760 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
10761 (cris_insert_point): ... this.
10762 (cris_remove_watchpoint): Rename to ...
10763 (cris_remove_point): ... this.
10764 (the_low_target): Adjust.
10766 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
10768 * server.c (handle_v_kill): Pass signal_pid to
10769 kill_inferior if multi_process is zero.
10771 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
10773 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
10774 * target.h (target_ops): Comment for *_watchpoint to make it clear
10775 the functions can get types '0' and '1'.
10777 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
10779 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
10780 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
10781 * regcache.c (get_regcache): Likewise.
10782 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
10783 * win32-low.c (child_fetch_inferior_registers): Remove check for
10786 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
10787 Pedro Alves <pedro@codesourcery.com>
10789 * target.h (struct target_ops) <supports_multi_process>: New
10791 (target_supports_multi_process): New.
10792 * server.c (handle_query): Even if GDB reports support, only
10793 enable multi-process if the target also supports it. Report
10794 multi-process support only if the target backend supports it.
10795 * linux-low.c (linux_supports_multi_process): New function.
10796 (linux_target_ops): Install it as target_supports_multi_process
10799 2009-05-24 Doug Evans <dje@google.com>
10801 Global renaming of find_thread_pid to find_thread_ptid.
10802 * server.h (find_thread_ptid): Renamed from find_thread_pid.
10803 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
10804 All callers updated.
10806 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
10807 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
10810 * linux-low.c (get_stop_pc): Print pc if debug_threads.
10811 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
10812 (linux_resume_one_lwp): Ditto.
10814 2009-05-23 Doug Evans <dje@google.com>
10816 * linux-low.c (linux_resume_one_lwp): Change type of first arg
10817 from struct inferior_list_entry * to struct lwp_info *.
10818 All callers updated.
10820 2009-05-13 Doug Evans <dje@google.com>
10822 * linux-x86-low.c: Don't include assert.h.
10823 (x86_siginfo_fixup): Use fatal, not assert.
10824 (x86_arch_setup): Fix comment.
10826 2009-05-12 Doug Evans <dje@google.com>
10828 Biarch support for i386/amd64 gdbserver.
10829 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
10830 Add linux-x86-low.c.
10831 (linux-i386-low.o, linux-x86-64-low.o): Delete.
10832 (linux-x86-low.o): Add.
10833 * linux-x86-64-low.c: Delete.
10834 * linux-i386-low.c: Delete.
10835 * linux-x86-low.c: New file.
10836 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
10838 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
10840 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
10841 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
10842 (linux_child_pid_to_exec_file): New function.
10843 (elf_64_header_p, elf_64_file_p): New functions.
10844 (siginfo_fixup): New function.
10845 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
10846 give target a chance to convert layout.
10847 * linux-low.h (linux_target_ops): New member siginfo_fixup.
10848 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
10850 2009-05-07 Doug Evans <dje@google.com>
10852 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
10853 (regsets_store_inferior_registers): Ditto.
10855 2009-05-06 Pedro Alves <pedro@codesourcery.com>
10859 * linux-low.c (must_set_ptrace_flags): Delete.
10860 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
10862 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
10863 `lwp->must_set_ptrace_flags' instead.
10864 (linux_wait_for_event_1): Set ptrace options here.
10865 (linux_wait_1): ... not here.
10867 2009-04-30 Doug Evans <dje@google.com>
10869 * inferiors.c (started_inferior_callback): New function.
10870 (attached_inferior_callback): New function.
10871 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
10872 * server.c (print_started_pid, print_attached_pid): New functions.
10873 (detach_or_kill_for_exit): New function.
10874 (main): Call it instead of for_each_inferior (kill_inferior_callback).
10875 * server.h (have_started_inferiors_p): Declare.
10876 (have_attached_inferiors_p): Declare.
10878 * inferiors.c (remove_process): Fix memory leak, free process.
10879 * linux-low.c (linux_remove_process): New function.
10880 (linux_kill): Call it instead of remove_process.
10881 (linux_detach, linux_wait_1): Ditto.
10883 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
10885 * configure.srv: Add x86 Windows CE target.
10887 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
10889 * inferiors.c (get_thread_process): Make global.
10890 * server.h (get_thread_process): Add prototype.
10891 * thread-db.c (find_one_thread): Use get_thread_process
10892 instead of current_process.
10893 (thread_db_get_tls_address): Do not crash if called when
10894 thread layer is not yet initialized.
10896 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
10898 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
10899 * spu-low.c (current_tid): Rename to ...
10900 (current_ptid): ... this.
10901 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
10902 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
10903 ptid_get_lwp (current_ptid) instead of current_tid.
10904 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
10905 instead of current_tid. Use find_process_pid to verify pid
10906 argument is valid. Pass proper argument to remove_process.
10907 (spu_thread_alive): Compare current_ptid instead of current_tid.
10908 (spu_resume): Likewise.
10910 2009-04-02 Pedro Alves <pedro@codesourcery.com>
10912 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
10915 2009-04-01 Pedro Alves <pedro@codesourcery.com>
10917 Implement the multiprocess extensions, and add linux multiprocess
10920 * server.h (ULONGEST): Declare.
10921 (struct ptid, ptid_t): New.
10922 (minus_one_ptid, null_ptid): Declare.
10923 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
10924 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
10925 (struct inferior_list_entry): Change `id' type from unsigned from
10927 (struct sym_cache, struct breakpoint, struct
10928 process_info_private): Forward declare.
10929 (struct process_info): Declare.
10930 (current_process): Declare.
10931 (all_processes): Declare.
10932 (initialize_inferiors): Declare.
10933 (add_thread): Adjust to use ptid_t.
10934 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
10935 (add_process, remove_process, find_thread_pid): Declare.
10936 (find_inferior_id): Adjust to use ptid_t.
10937 (cont_thread, general_thread, step_thread): Change type to ptid_t.
10938 (multi_process): Declare.
10939 (push_event): Adjust to use ptid_t.
10940 (read_ptid, write_ptid): Declare.
10941 (prepare_resume_reply): Adjust to use ptid_t.
10942 (clear_symbol_cache): Declare.
10943 * inferiors.c (all_processes): New.
10944 (null_ptid, minus_one_ptid): New.
10945 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
10946 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
10947 (add_thread): Change unsigned long to ptid. Remove gdb_id
10949 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
10950 (gdb_id_to_thread): Rename to ...
10951 (find_thread_pid): ... this. Change unsigned long to ptid.
10952 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
10953 (loaded_dll, pull_pid_from_list): Adjust.
10954 (add_process, remove_process, find_process_pid)
10955 (get_thread_process, current_process, initialize_inferiors): New.
10956 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
10957 (struct target_waitstatus) <related_pid>: Ditto.
10958 (struct target_ops) <kill, detach>: Add `pid' argument. Change
10959 return type to int.
10960 (struct target_ops) <join>: Add `pid' argument.
10961 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
10962 (struct target_ops) <wait>: Add `ptid' field. Change return type
10964 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
10965 (mywait): Add `ptid' argument. Change return type to ptid_t.
10966 (target_pid_to_str): Declare.
10967 * target.c (set_desired_inferior): Adjust to use ptids.
10968 (mywait): Add new `ptid' argument. Adjust.
10969 (target_pid_to_str): New.
10970 * mem-break.h (free_all_breakpoints): Declare.
10971 * mem-break.c (breakpoints): Delelete.
10972 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
10973 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
10974 to use per-process breakpoint list.
10975 (free_all_breakpoints): New.
10976 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
10977 (symbol_cache, all_symbols_looked_up): Delete.
10979 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
10981 (prepare_resume_reply): Change ptid argument's type from unsigned
10982 long to ptid_t. Adjust. Implement W;process and X;process.
10983 (free_sym_cache, clear_symbol_cache): New.
10984 (look_up_one_symbol): Adjust to per-process symbol cache. *
10985 * server.c (cont_thread, general_thread, step_thread): Change type
10987 (attached): Delete.
10988 (multi_process): New.
10989 (last_ptid): Change type to ptid_t.
10990 (struct vstop_notif) <ptid>: Change type to ptid_t.
10991 (queue_stop_reply, push_event): Change `ptid' argument's type to
10993 (discard_queued_stop_replies): Add `pid' argument.
10994 (start_inferior): Adjust to use ptids. Adjust to mywait interface
10995 changes. Don't reference the `attached' global.
10996 (attach_inferior): Adjust to mywait interface changes.
10997 (handle_query): Adjust to use ptids. Parse GDB's qSupported
10998 features. Handle and report "multiprocess+". Handle
11000 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
11002 (handle_v_kill): New.
11003 (handle_v_stopped): Adjust to use target_pid_to_str.
11004 (handle_v_requests): Allow multiple attaches and runs when
11005 multiprocess extensions are in effect. Handle "vKill".
11006 (myresume): Adjust to use ptids.
11007 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
11008 (handle_status): Adjust to discard_queued_stop_replies interface
11010 (first_thread_of, kill_inferior_callback)
11011 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
11012 (main): Call initialize_inferiors. Adjust to use ptids, killing
11013 and detaching from all inferiors. Handle multiprocess packet
11015 * linux-low.h: Include gdb_proc_service.h.
11016 (struct process_info_private): New.
11017 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
11018 <lwpid_of>: Use ptid_get_lwp.
11019 (get_lwp_thread): Adjust.
11020 (struct lwp_info): Add `dead' member.
11021 (find_lwp_pid): Declare.
11022 * linux-low.c (thread_db_active): Delete.
11023 (new_inferior): Adjust comment.
11024 (inferior_pid): Delete.
11025 (linux_add_process): New.
11026 (handle_extended_wait): Adjust.
11027 (add_lwp): Change unsigned long to ptid.
11028 (linux_create_inferior): Add process to processes table. Adjust
11029 to use ptids. Don't set new_inferior here.
11030 (linux_attach_lwp): Rename to ...
11031 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
11032 it. Adjust to use ptids.
11033 (linux_attach_lwp): New.
11034 (linux_attach): Add process to processes table. Don't set
11036 (struct counter): New.
11037 (second_thread_of_pid_p, last_thread_of_process_p): New.
11038 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
11039 multiple processes.
11040 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
11041 processes. Remove process from process table.
11042 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
11043 to multiple processes.
11044 (any_thread_of): New.
11045 (linux_detach): Add `pid' argument, and handle it. Remove process
11046 from processes table.
11047 (linux_join): Add `pid' argument. Handle it.
11048 (linux_thread_alive): Change unsighed long argument to ptid_t.
11049 Consider dead lwps as not being alive.
11050 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
11051 threads we're not interested in.
11052 (same_lwp, find_lwp_pid): New.
11053 (linux_wait_for_lwp): Change `pid' argument's type from int to
11055 (linux_wait_for_event): Rename to ...
11056 (linux_wait_for_event_1): ... this. Change `pid' argument's type
11057 from int to ptid_t. Adjust.
11058 (linux_wait_for_event): New.
11059 (linux_wait_1): Add `ptid' argument. Change return type to
11060 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
11061 that exit from the process table.
11062 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
11064 (mark_lwp_dead): New.
11065 (wait_for_sigstop): Adjust to use ptids. If a process exits while
11066 stopping all threads, mark its main lwp as dead.
11067 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
11069 (fetch_register, usr_store_inferior_registers)
11070 (regsets_fetch_inferior_registers)
11071 (regsets_store_inferior_registers, linux_read_memory)
11072 (linux_write_memory): Inline `inferior_pid'.
11073 (linux_look_up_symbols): Adjust to use per-process
11074 `thread_db_active'.
11075 (linux_request_interrupt): Adjust to use ptids.
11076 (linux_read_auxv): Inline `inferior_pid'.
11077 (initialize_low): Don't reference thread_db_active.
11078 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
11079 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
11080 (ps_getpid): Return the pid of the current inferior.
11081 * thread-db.c (proc_handle, thread_agent): Delete.
11082 (thread_db_create_event, thread_db_enable_reporting): Adjust to
11084 (find_one_thread): Change argument type to ptid_t. Adjust to
11086 (maybe_attach_thread): Adjust to per-process data and ptids.
11087 (thread_db_find_new_threads): Ditto.
11088 (thread_db_init): Ditto.
11089 * spu-low.c (spu_create_inferior, spu_attach): Add process to
11090 processes table. Adjust to use ptids.
11091 (spu_kill, spu_detach): Adjust interface. Remove process from
11093 (spu_join, spu_thread_alive): Adjust interface.
11094 (spu_wait): Adjust interface. Remove process from processes
11095 table. Adjust to use ptids.
11096 * win32-low.c (current_inferior_tid): Delete.
11097 (current_inferior_ptid): New.
11098 (debug_event_ptid): New.
11099 (thread_rec): Take a ptid. Adjust.
11100 (child_add_thread): Add `pid' argument. Adjust to use ptids.
11101 (child_delete_thread): Ditto.
11102 (do_initial_child_stuff): Add `attached' argument. Add process to
11104 (child_fetch_inferior_registers, child_store_inferior_registers):
11106 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
11107 (win32_attach): Pass 1 to do_initial_child_stuff.
11108 (win32_kill): Adjust interface. Remove process from processes
11110 (win32_detach): Ditto.
11111 (win32_join): Adjust interface.
11112 (win32_thread_alive): Take a ptid.
11113 (win32_resume): Adjust to use ptids.
11114 (get_child_debug_event): Ditto.
11115 (win32_wait): Adjust interface. Remove exiting process from
11118 2009-04-01 Pedro Alves <pedro@codesourcery.com>
11120 Non-stop mode support.
11122 * server.h (non_stop): Declare.
11123 (gdb_client_data, handler_func): Declare.
11124 (delete_file_handler, add_file_handler, start_event_loop):
11126 (handle_serial_event, handle_target_event, push_event)
11127 (putpkt_notif): Declare.
11128 * target.h (enum resume_kind): New.
11129 (struct thread_resume): Replace `step' field by `kind' field.
11130 (TARGET_WNOHANG): Define.
11131 (struct target_ops) <wait>: Add `options' argument.
11132 <supports_non_stop, async, start_non_stop>: New fields.
11133 (target_supports_non_stop, target_async): New.
11134 (start_non_stop): Declare.
11135 (mywait): Add `options' argument.
11136 * target.c (mywait): Add `options' argument. Print child exit
11137 notifications here.
11138 (start_non_stop): New.
11139 * server.c (non_stop, own_buf, mem_buf): New globals.
11140 (struct vstop_notif): New.
11141 (notif_queue): New global.
11142 (queue_stop_reply, push_event, discard_queued_stop_replies)
11143 (send_next_stop_reply): New.
11144 (start_inferior): Adjust to use resume_kind. Adjust to mywait
11146 (attach_inferior): In non-stop mode, don't wait for the target
11148 (handle_general_set): Handle QNonStop.
11149 (handle_query): When handling qC, return the current general
11150 thread, instead of the first thread of the list.
11151 (handle_query): If the backend supports non-stop mode, include
11152 QNonStop+ in the qSupported query response.
11153 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
11155 (handle_v_attach, handle_v_run): Handle non-stop mode.
11156 (handle_v_stopped): New.
11157 (handle_v_requests): Report support for vCont;t. Handle vStopped.
11158 (myresume): Adjust to use resume_kind. Handle non-stop.
11159 (queue_stop_reply_callback): New.
11160 (handle_status): Handle non-stop mode.
11161 (main): Clear non_stop flag on reconnection. Use the event-loop.
11162 Refactor serial protocol handling from here ...
11163 (process_serial_event): ... to this new function. When GDB
11164 selects any thread, select one here. In non-stop mode, wait until
11165 GDB acks all pending events before exiting.
11166 (handle_serial_event, handle_target_event): New.
11167 * remote-utils.c (remote_open): Install remote_desc in the event
11169 (remote_close): Remove remote_desc from the event loop.
11170 (putpkt_binary): Rename to...
11171 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
11172 (putpkt_binary): New as wrapper around putpkt_binary_1.
11173 (putpkt_notif): New.
11174 (prepare_resume_reply): In non-stop mode, don't change the
11176 * event-loop.c: New.
11177 * Makefile.in (OBJ): Add event-loop.o.
11178 (event-loop.o): New rule.
11180 * linux-low.h (pid_of): Moved here.
11182 (get_lwp_thread): Use lwpid_of.
11183 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
11184 * linux-low.c (pid_of): Delete.
11185 (inferior_pid): Use lwpid_of.
11186 (linux_event_pipe): New.
11187 (target_is_async_p): New.
11189 (handle_extended_wait): Use lwpid_of.
11190 (add_lwp): Don't set lwpid field.
11191 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
11192 (linux_kill_one_lwp): If killing a running lwp, stop it first.
11193 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
11194 (linux_detach_one_lwp): If detaching from a running lwp, stop it
11195 first. Adjust to linux_wait_for_event interface changes. Use
11197 (linux_detach): Don't delete the main lwp here.
11198 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
11199 (status_pending_p): Don't consider explicitly suspended lwps.
11200 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
11201 pointer. Add OPTIONS argument. Change return type to int. Use
11202 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
11203 (linux_wait_for_event): Take an integer pid instead of a lwp_info
11204 pointer. Add status pointer argument. Return a pid instead of a
11205 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
11206 changes. In non-stop mode, don't switch to a random thread.
11207 (linux_wait): Rename to...
11208 (linux_wait_1): ... this. Add target_options argument, and handle
11209 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
11210 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
11211 clean exit and signal exit code. Don't stop all threads in
11212 non-stop mode. In all-stop mode, only stop all threads when
11213 reporting a stop to GDB. Handle explicit thread stop requests.
11214 (async_file_flush, async_file_mark): New.
11216 (send_sigstop): Use lwpid_of.
11217 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
11218 interface changes. In non-stop mode, don't switch to a random
11220 (linux_resume_one_lwp): Use lwpid_of.
11221 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
11222 (linux_resume_one_thread): ... this. Handle resume_stop. In
11223 non-stop mode, don't look for pending flag in all threads.
11224 (resume_status_pending_p): Don't consider explicitly suspended
11226 (my_waitpid): Reimplement. Emulate __WALL.
11227 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
11229 (sigchld_handler, linux_supports_non_stop, linux_async)
11230 (linux_start_non_stop): New.
11231 (linux_target_ops): Register linux_supports_non_stop, linux_async
11232 and linux_start_non_stop.
11233 (initialize_low): Install SIGCHLD handler.
11234 * thread-db.c (thread_db_create_event, find_one_thread)
11235 (thread_db_get_tls_address): Use lwpid_of.
11236 * win32-low.c (win32_detach): Adjust to use resume_kind.
11237 (win32_wait): Add `options' argument.
11238 * spu-low.c (spu_resume): Adjust to use resume_kind.
11239 (spu_wait): Add `options' argument.
11241 2009-04-01 Pedro Alves <pedro@codesourcery.com>
11243 Decouple target code from remote protocol.
11245 * target.h (enum target_waitkind): New.
11246 (struct target_waitstatus): New.
11247 (struct target_ops) <wait>: Return an unsigned long. Take a
11248 target_waitstatus pointer instead of a char pointer.
11249 (mywait): Likewise.
11250 * target.c (mywait): Change prototype to return an unsigned long.
11251 Take a target_waitstatus pointer instead of a char pointer. Adjust.
11252 * server.h (thread_from_wait, old_thread_from_wait): Delete
11254 (prepare_resume_reply): Change prototype to take a
11256 * server.c (thread_from_wait, old_thread_from_wait): Delete.
11257 (last_status, last_ptid): New.
11258 (start_inferior): Remove "statusptr" argument. Adjust. Return a
11259 pid instead of a signal.
11260 (attach_inferior): Remove "status" and "signal" parameters.
11262 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
11264 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
11265 (handle_v_requests, myresume): Remove "status" and "signal"
11266 parameters. Adjust.
11267 (handle_status): New.
11268 (main): Delete local `status'. Adjust.
11269 * remote-utils.c: Include target.h.
11270 (prepare_resume_reply): Change prototype to take a
11271 target_waitstatus. Adjust.
11273 * linux-low.c (linux_wait): Adjust to new target_ops->wait
11275 * spu-low.c (spu_wait): Adjust.
11276 * win32-low.c (enum target_waitkind, struct target_waitstatus):
11278 (win32_wait): Adjust.
11280 2009-04-01 Pedro Alves <pedro@codesourcery.com>
11282 * target.h (struct thread_resume): Delete leave_stopped member.
11283 (struct target_ops): Add a `n' argument to the `resume' callback.
11284 * server.c (start_inferior): Adjust.
11285 (handle_v_cont, myresume): Adjust.
11286 * linux-low.c (check_removed_breakpoint): Adjust to resume
11287 interface change, and to removed leave_stopped field.
11288 (resume_ptr): Delete.
11289 (struct thread_resume_array): New.
11290 (linux_set_resume_request): Add new `arg' parameter. Adjust to
11291 resume interface change.
11292 (linux_continue_one_thread, linux_queue_one_thread)
11293 (resume_status_pending_p): Check if the resume field is NULL
11294 instead of checking the leave_stopped member.
11295 (linux_resume): Adjust to the target resume interface change.
11296 * spu-low.c (spu_resume): Adjust to the target resume interface
11298 * win32-low.c (win32_detach, win32_resume): Ditto.
11300 2009-04-01 Pedro Alves <pedro@codesourcery.com>
11302 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
11304 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
11306 (linux_continue_one_thread): Only preserve the stepping flag if
11307 there's a pending breakpoint.
11309 2009-03-31 Pedro Alves <pedro@codesourcery.com>
11311 * server.c (main): After the inferior having exited, call
11312 remote_close before exiting gdbserver.
11314 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
11316 Fix size of FPSCR in Power 7 processors.
11317 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
11318 (PPC_FEATURE_HAS_DFP): New #define.
11319 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
11322 2009-03-23 Pedro Alves <pedro@codesourcery.com>
11324 * server.c (handle_query) Whitespace and formatting.
11326 2009-03-22 Pedro Alves <pedro@codesourcery.com>
11328 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
11329 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
11330 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
11331 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
11332 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
11333 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
11334 Makefile.in, configure.ac: Fix whitespace throughout.
11335 * configure: Regenerate.
11337 2009-03-22 Pedro Alves <pedro@codesourcery.com>
11339 * inferiors.c (find_inferior): Make it safe for the callback
11340 function to delete the currently iterated inferior.
11342 2009-03-22 Pedro Alves <pedro@codesourcery.com>
11344 * Makefile.in (linuw_low_h): Move higher.
11345 (thread-db.o): Depend on $(linux_low_h).
11347 2009-03-17 Pedro Alves <pedro@codesourcery.com>
11349 Rename "process" to "lwp" throughout.
11351 * linux-low.c (all_processes): Rename to...
11352 (all_lwps): ... this.
11353 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
11354 (add_process): Rename to ...
11355 (add_lwp): ... this. Adjust.
11356 (linux_create_inferior): Adjust.
11357 (linux_attach_lwp): Adjust.
11358 (linux_attach): Adjust.
11359 (linux_kill_one_process): Rename to ...
11360 (linux_kill_one_lwp): ... this. Adjust.
11361 (linux_kill): Adjust.
11362 (linux_detach_one_process): Rename to ...
11363 (linux_detach_one_lwp): ... this. Adjust.
11364 (linux_detach): Adjust.
11365 (check_removed_breakpoint): Adjust.
11366 (status_pending_p): Adjust.
11367 (linux_wait_for_process): Rename to ...
11368 (linux_wait_for_lwp): ... this. Adjust.
11369 (linux_wait_for_event): Adjust.
11370 (send_sigstop): Adjust.
11371 (wait_for_sigstop): Adjust.
11372 (stop_all_processes): Rename to ...
11373 (stop_all_lwps): ... this.
11374 (linux_resume_one_process): Rename to ...
11375 (linux_resume_one_lwp): ... this. Adjust.
11376 (linux_set_resume_request, linux_continue_one_thread)
11377 (linux_queue_one_thread, resume_status_pending_p)
11378 (usr_store_inferior_registers, regsets_store_inferior_registers)
11379 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
11381 * linux-low.h (get_process): Rename to ...
11382 (get_lwp): ... this. Adjust.
11383 (get_thread_process): Rename to ...
11384 (get_thread_lwp): ... this. Adjust.
11385 (get_process_thread): Rename to ...
11386 (get_lwp_thread): ... this. Adjust.
11387 (struct process_info): Rename to ...
11388 (struct lwp_info): ... this.
11389 (all_processes): Rename to ...
11390 (all_lwps): ... this.
11391 * proc-service.c (ps_lgetregs): Adjust.
11392 * thread-db.c (thread_db_create_event, find_one_thread)
11393 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
11395 2009-03-14 Pedro Alves <pedro@codesourcery.com>
11397 * server.c (handle_query): Handle "qAttached".
11399 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
11401 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
11402 GPLv3, update license URL.
11404 2009-03-01 Doug Evans <dje@google.com>
11406 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
11407 (server_h): Add gdb_signals.h.
11408 (signals.o): Update.
11409 * server.h (target_signal_from_host,target_signal_to_host_p)
11410 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
11412 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
11414 * remote-utils.c (getpkt): Also generate remote-debug
11415 information if noack_mode is set.
11417 2009-02-06 Pedro Alves <pedro@codesourcery.com>
11419 * server.c (handle_query): Report qXfer:siginfo:read and
11420 qXfer:siginfo:write as supported and handle them.
11421 * target.h (struct target_ops) <qxfer_siginfo>: New field.
11422 * linux-low.c (linux_xfer_siginfo): New.
11423 (linux_target_ops): Set it.
11425 2009-01-26 Pedro Alves <pedro@codesourcery.com>
11427 * server.c (gdbserver_usage): Mention --remote-debug.
11428 (main): Accept '--remote-debug' switch.
11430 2009-01-18 Doug Evans <dje@google.com>
11432 * regcache.c (new_register_cache): No need to check result of xcalloc.
11433 * server.c (handle_search_memory): Back out calls to xmalloc,
11434 result is checked and error is returned to user upon failure.
11435 (handle_query): Ditto. Add more checks for result of malloc.
11436 (handle_v_cont): Check result of malloc, report error back to
11438 (handle_v_run): Ditto. Call freeargv.
11439 * server.h (freeargv): Declare.
11440 * utils.c (freeargv): New fn.
11442 2009-01-15 Doug Evans <dje@google.com>
11444 * gdbreplay.c (perror_with_name): Make arg const char *.
11445 * server.h (target_signal_to_name): Make return type const char *.
11446 * thread-db.c (thread_db_err_str): Make return type const char *.
11447 * utils.c (perror_with_name): Make arg const char *.
11449 2009-01-14 Pedro Alves <pedro@codesourcery.com>
11451 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
11452 when handling a EXIT_PROCESS_DEBUG_EVENT.
11454 2009-01-06 Joel Brobecker <brobecker@adacore.com>
11456 * gdbreplay.c (gdbreplay_version): Update copyright year.
11457 * server.c (gdbserver_version): Likewise.
11459 2009-01-05 Doug Evans <dje@google.com>
11461 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
11462 (handle_extended_wait): Improve comment.
11464 2008-12-13 Doug Evans <dje@google.com>
11466 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
11467 * server.h (ATTR_MALLOC): New macro.
11468 (xmalloc,xcalloc,xstrdup): Declare.
11469 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
11470 * inferiors.c: Ditto.
11471 * linux-low.c: Ditto.
11472 * mem-break.c: Ditto.
11473 * regcache.c: Ditto.
11474 * remote-utils.c: Ditto.
11477 * win32-low.c: Ditto.
11479 2008-12-12 Doug Evans <dje@google.com>
11481 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
11482 in debugging printf.
11484 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
11486 2008-12-09 Doug Evans <dje@google.com>
11488 * linux-low.h (struct process_info): Delete member tid, unused.
11489 * thread-db.c (find_one_thread): Update.
11490 (maybe_attach_thread): Update.
11492 2008-12-02 Pedro Alves <pedro@codesourcery.com>
11494 * target.h (struct target_ops): Add qxfer_osdata member.
11495 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
11497 (linux_qxfer_osdata): New functions.
11498 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
11500 * server.c (handle_query): Handle "qXfer:osdata:read:".
11501 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
11502 (buffer_xml_printf): New functions.
11503 * server.h (struct buffer): New.
11504 (buffer_grow_str, buffer_grow_str0): New macros.
11505 (buffer_grow, buffer_free, buffer_init, buffer_finish)
11506 (buffer_xml_printf): Declare.
11508 2008-11-24 Doug Evans <dje@google.com>
11510 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
11512 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
11514 * server.c (handle_v_run): Always use the supplied argument list.
11516 2008-11-19 Bob Wilson <bob.wilson@acm.org>
11518 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
11519 (xtensa_regmap_table): Add entry for scompare1.
11521 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
11523 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
11524 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
11525 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
11526 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
11527 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
11528 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
11529 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
11530 XML target descriptions.
11531 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
11532 when inferior is running on an ISA 2.05 or later processor. Add
11533 special case to return offset for full 64-bit slot of FPSCR when
11536 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
11538 * Makefile.in (SFILES, clean): Added sparc64 files.
11539 (reg-sparc64.o, reg-sparc64.c): New.
11540 * configure.srv (sparc*-*-linux*): New configuration.
11541 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
11542 syscall arguments for SPARC.
11543 (regsets_store_inferior_registers): Likewise.
11544 * linux-sparc-low.c: New file.
11546 2008-10-21 Doug Evans <dje@google.com>
11548 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
11549 (READLINE_DIR,READLINE_DEP): Delete.
11550 (INTERNAL_CFLAGS): Update.
11551 (LINTFLAGS): Update.
11553 2008-10-10 Pedro Alves <pedro@codesourcery.com>
11555 * server.c (handle_v_run): If GDB didn't specify an argv, use the
11556 whole argv from the last run, not just argv[0].
11558 2008-09-08 Pedro Alves <pedro@codesourcery.com>
11560 * regcache.c (new_register_cache): Return NULL if the register
11561 cache size isn't known yet.
11562 (free_register_cache): Avoid dereferencing a NULL regcache.
11564 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
11566 * configure.srv: Merge MIPS and MIPS64.
11568 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
11570 * Makefile.in (uninstall): Apply $(EXEEXT) too.
11572 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
11574 * Makefile.in: Add required vsx dependencies.
11576 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
11577 Declare init_registers_powerpc_vsx32l.
11578 Declare init_registers_powerpc_vsx64l.
11579 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
11580 (ppc_arch_setup): Check for VSX in hwcap.
11581 (ppc_fill_vsxregset): New function.
11582 (ppc_store_vsxregset): New function.
11583 Add new VSX entry in regset_info target_regsets.
11585 * configure.srv: Add new VSX dependencies.
11587 2008-08-12 Pedro Alves <pedro@codesourcery.com>
11589 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
11590 (remote_open): Set or clear transport_is_reliable.
11591 (putpkt_binary): Don't expect acks in noack mode.
11592 (getpkt): Don't send ack/nac in noack mode.
11593 * server.c (handle_general_set): Handle QStartNoAckMode.
11594 (handle_query): If connected by tcp pass QStartNoAckMode+ in
11596 (main): Reset noack_mode on every connection.
11597 * server.h (noack_mode): Declare.
11599 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11601 * Makefile.in (GDBREPLAY_OBS): New variable.
11602 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
11604 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
11605 Daniel Jacobowitz <dan@codesourcery.com>
11607 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
11608 (usr_store_inferior_registers): Likewise.
11609 (regsets_store_inferior_registers): Likewise.
11611 2008-07-31 Rolf Jansen <rj@surtec.com>
11612 Pedro Alves <pedro@codesourcery.com>
11614 * configure.ac: Check for memmem declaration.
11615 * server.c [HAVE_MALLOC_H]: Include malloc.h.
11616 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
11617 (disable_packet_qfThreadInfo): Unconditionally compile.
11618 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
11619 * configure, config.in: Regenerate.
11621 2008-07-28 Doug Kwan <dougkwan@google.com>
11623 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
11624 (linux_write_memory): Remove declaration of errno.
11626 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
11628 * linux-low.c (handle_extended_wait): Do not use "status"
11629 variable uninitialized.
11631 2008-07-07 Pedro Alves <pedro@codesourcery.com>
11633 * server.c (handle_v_attach): Inhibit reporting dll changes.
11635 2008-06-27 Pedro Alves <pedro@codesourcery.com>
11637 * remote-utils.c (prepare_resume_reply): If requested, don't
11638 output "thread:TID" in the T stop reply.
11640 * server.c (disable_packet_vCont, disable_packet_Tthread)
11641 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
11642 (handle_query): If requested, disable support for qC, qfThreadInfo
11644 (handle_v_requests): If requested, disable support for vCont.
11645 (gdbserver_show_disableable): New.
11646 (main): Handle --disable-packet and --disable-packet=LIST.
11648 * server.h (disable_packet_vCont, disable_packet_Tthread)
11649 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
11651 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
11653 * server.c (gdbserver_usage): Mention --version.
11655 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
11657 * Makefile.in (gdbreplay.o): New rule.
11659 2008-06-06 Joseph Myers <joseph@codesourcery.com>
11661 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
11662 message, not gdbserver.
11664 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
11665 Nathan Sidwell <nathan@codesourcery.com>
11666 Joseph Myers <joseph@codesourcery.com>
11668 * acinclude.m4: Include ../../config/acx.m4.
11669 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
11670 * configure, config.in: Regenerate.
11671 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
11672 * server.c (gdbserver_version): Print PKGVERSION.
11673 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
11674 (main): Adjust gdbserver_usage calls.
11675 * gdbreplay.c (version, host_name): Add declarations.
11676 (gdbreplay_version, gdbreplay_usage): New.
11677 (main): Accept --version and --help options.
11679 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
11681 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
11682 (arm_breakpoint_at): Handle Thumb.
11683 (the_low_target): Add comment.
11685 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
11687 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
11689 2008-05-09 Doug Evans <dje@google.com>
11691 * server.h (decode_search_memory_packet): Declare.
11692 * remote-utils.c (decode_search_memory_packet): New fn.
11693 * server.c (handle_search_memory_1): New fn.
11694 (handle_search_memory): New fn.
11695 (handle_query): Process qSearch:memory packets.
11697 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
11699 * regcache.c (registers_length): Remove.
11700 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
11701 full register packet.
11702 * regcache.h (registers_length): Remove prototype.
11703 * server.h (PBUFSIZ): Define to 16384.
11705 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
11707 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
11708 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
11709 powerpc-64l.o, and powerpc-altivec64l.o.
11710 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
11711 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
11712 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
11713 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
11714 rs6000/power-linux.xml, and rs6000/power64-linux.xml
11717 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
11718 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
11719 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
11720 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
11721 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
11722 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
11723 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
11724 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
11725 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
11726 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
11729 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
11730 (init_registers_powerpc_32l): ... this new prototype.
11731 (init_registers_powerpc_32): Remove, replace by ...
11732 (init_registers_powerpc_altivec32l): ... this new prototype.
11733 (init_registers_powerpc_e500): Remove, replace by ...
11734 (init_registers_powerpc_e500l): ... this new prototype.
11735 (init_registers_ppc64): Remove, replace by ...
11736 (init_registers_powerpc_64l): ... this new prototype.
11737 (init_registers_powerpc_64): Remove, replace by ...
11738 (init_registers_powerpc_altivec64l): ... this new prototype.
11739 (ppc_num_regs): Set to 73.
11740 (PT_ORIG_R3, PT_TRAP): Define if necessary.
11741 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
11742 (ppc_cannot_store_register): Handle orig_r3 and trap.
11743 (ppc_arch_setup): Update init_registers_... calls.
11744 (ppc_fill_gregset): Handle orig_r3 and trap.
11746 * inferiors.c (clear_inferiors): Reset current_inferior.
11748 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
11750 * acinclude.m4: Add override.m4.
11751 * configure: Regenerate.
11753 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
11755 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
11756 initial call to init_register_ppc64.
11758 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
11760 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
11761 single powerpc*-*-linux* case.
11762 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
11764 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
11766 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
11767 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
11769 * linux-ppc-low.c: Include <elf.h>.
11770 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
11771 (ppc_hwcap): New global variable.
11772 (ppc_regmap): Remove __SPE__ #ifdef sections.
11773 (ppc_regmap_e500): New global variable.
11774 (ppc_cannot_store_register): Update __SPE__ special case.
11775 (ppc_get_hwcap): New function.
11776 (ppc_arch_setup): Use it to determine whether inferior supports
11777 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
11778 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
11779 Do not access registers if target does not support AltiVec.
11780 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
11781 Do not access registers if target does not support SPE.
11782 (target_regsets): Unconditionally include AltiVec and SPE regsets.
11784 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
11786 * linux-low.c (disabled_regsets, num_regsets): New.
11787 (use_regsets_p): Delete.
11788 (linux_wait_for_process): Clear disabled_regsets.
11789 (regsets_fetch_inferior_registers): Check and set it.
11790 (regsets_store_inferior_registers): Likewise.
11791 (linux_fetch_registers, linux_store_registers): Do not use
11793 (initialize_low): Allocate disabled_regsets.
11795 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
11797 * Makefile.in (LIBOBJS): New.
11798 (OBS): Use LIBOBJS.
11799 (memmem.o): New rule.
11800 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
11801 * configure: Regenerated.
11803 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
11805 * server.c (handle_query): Never return "unsupported" for
11806 qXfer:features:read queries.
11808 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
11810 * server.c (get_features_xml): Fix inverted condition.
11811 (handle_query): Always support qXfer:feature:read.
11813 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
11815 * server.c (wrapper_argv): New.
11816 (start_inferior): Handle wrapper_argv. If set, expect an extra
11818 (gdbserver_usage): Document --wrapper.
11819 (main): Parse --wrapper.
11821 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11823 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
11824 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
11825 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
11826 (ppc_set_pc): Likewise.
11827 (ppc_arch_setup): New function.
11828 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
11829 of collect_register.
11830 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
11832 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11834 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
11835 instead of linux-ppc64-low.o.
11836 * linux-ppc64-low.c: Remove file.
11837 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
11838 (linux-ppc64-low.o): Remove rule.
11840 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
11841 (init_registers_powerpc_64): Likewise.
11842 (ppc_regmap): Conditionally define depending on __powerpc64__.
11843 (ppc_cannot_store_register): Do not special-case "fpscr" when
11844 compiled on __powerpc64__.
11845 (ppc_collect_ptrace_register): New function.
11846 (ppc_supply_ptrace_register): New function.
11847 (ppc_breakpoint): Change type to "unsigned int".
11848 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
11849 (the_low_target): Conditionally provide initializers for the
11850 arch_setup member depending on __powerpc64__. Install
11851 collect_ptrace_register and supply_ptrace_register members.
11853 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11855 * regcache.h (gdbserver_xmltarget): Add extern declaration.
11856 * server.c (gdbserver_xmltarget): Define.
11857 (get_features_xml): Use it to replace "target.xml" and arch_string.
11859 * configure.srv: Remove srv_xmltarget. Add XML files that were
11860 mentioned there to srv_xmlfiles instead. Remove conditional tests
11861 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
11862 srv_xmlfiles and srv_regobj to include all possible choices.
11863 * configure.ac (srv_xmltarget): Remove.
11864 (srv_xmlfiles): Do not add "target.xml".
11865 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
11866 checks for supplementary target information.
11867 * configure: Regenerate.
11868 * Makefile.in (XML_TARGET): Remove.
11869 (target.xml): Remove rule.
11870 (clean): Do not clean up target.xml.
11871 (.PRECIOUS): Do not mention target.xml.
11873 * target.h (struct target_ops): Remove arch_string member.
11874 * linux-low.c (linux_arch_string): Remove.
11875 (linux_target_ops): Remove arch_string initializer.
11876 * linux-low.h (struct linux_target_ops): Remove arch_string member.
11877 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
11878 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
11879 * spu-low.c (spu_arch_string): Remove.
11880 (spu_target_ops): Remove arch_string initializer.
11881 * win32-low.c (win32_arch_string): Remove.
11882 (win32_target_ops): Remove arch_string initializer.
11883 * win32-low.h (struct win32_target_ops): Remove arch_string member.
11884 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
11885 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
11887 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
11889 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
11890 by collect_ptrace_register and supply_ptrace_register hooks.
11891 * linux-low.c (fetch_register): Use supply_ptrace_register callback
11892 instead of checking for the_low_target.left_pad_xfer.
11893 (usr_store_inferior_registers): Use collect_ptrace_register callback
11894 instead of checking for the_low_target.left_pad_xfer.
11896 * linux-s390-low.c (s390_collect_ptrace_register): New function.
11897 (s390_supply_ptrace_register): Likewise.
11898 (s390_fill_gregset): Call s390_collect_ptrace_register.
11899 (the_low_target): Update.
11901 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
11902 (ppc_supply_ptrace_register): Likewise.
11903 (the_low_target): Update.
11905 * linux-i386-low.c (the_low_target): Update.
11906 * linux-x86-64-low.c (the_low_target): Update.
11908 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
11910 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
11911 reg-s390.o and reg-s390x.o.
11913 * linux-low.c (new_inferior): New global variable.
11914 (linux_create_inferior, linux_attach): Set it.
11915 (linux_wait_for_process): Call the_low_target.arch_setup after the
11916 target has stopped for the first time.
11917 (initialize_low): Do not call the_low_target.arch_setup.
11919 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
11920 (s390_set_pc): Likewise.
11921 (s390_arch_setup): New function.
11922 (the_low_target): Use s390_arch_setup as arch_setup routine.
11924 * regcache.c (realloc_register_cache): New function.
11925 (set_register_cache): Call it for each existing regcache.
11927 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
11929 * server.h (init_registers): Remove prototype.
11931 * linux-low.h (struct linux_target_ops): Add arch_setup field.
11932 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
11933 instead of init_registers ().
11934 * linux-arm-low.c (init_registers_arm): Add prototype.
11935 (init_registers_arm_with_iwmmxt): Likewise.
11936 (the_low_target): Add initializer for arch_setup field.
11937 * linux-cris-low.c (init_registers_cris): Add prototype.
11938 (the_low_target): Add initializer for arch_setup field.
11939 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
11940 (the_low_target): Add initializer for arch_setup field.
11941 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
11942 (the_low_target): Add initializer for arch_setup field.
11943 * linux-ia64-low.c (init_registers_ia64): Add prototype.
11944 (the_low_target): Add initializer for arch_setup field.
11945 * linux-m32r-low.c (init_registers_m32r): Add prototype.
11946 (the_low_target): Add initializer for arch_setup field.
11947 * linux-m68k-low.c (init_registers_m68k): Add prototype.
11948 (the_low_target): Add initializer for arch_setup field.
11949 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
11950 (init_registers_mips64_linux): Likewise.
11951 (the_low_target): Add initializer for arch_setup field.
11952 * linux-ppc-low.c (init_registers_ppc): Add prototype.
11953 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
11954 (the_low_target): Add initializer for arch_setup field.
11955 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
11956 (init_registers_powerpc_64): Likewise.
11957 (the_low_target): Add initializer for arch_setup field.
11958 * linux-s390-low.c (init_registers_s390): Add prototype.
11959 (init_registers_s390x): Likewise.
11960 (the_low_target): Add initializer for arch_setup field.
11961 * linux-sh-low.c (init_registers_sh): Add prototype.
11962 (the_low_target): Add initializer for arch_setup field.
11963 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
11964 (the_low_target): Add initializer for arch_setup field.
11965 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
11966 (the_low_target): Add initializer for arch_setup field.
11968 * win32-low.h (struct win32_target_ops): Add arch_setup field.
11969 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
11970 instead of init_registers ().
11971 * win32-arm-low.c (init_registers_arm): Add prototype.
11972 (the_low_target): Add initializer for arch_setup field.
11973 * win32-i386-low.c (init_registers_i386): Add prototype.
11974 (the_low_target): Add initializer for arch_setup field.
11976 * spu-low.c (init_registers_spu): Add prototype.
11977 (initialize_low): Call initialie_registers_spu () instead of
11978 initialize_registers ().
11980 2008-02-19 Pedro Alves <pedro@codesourcery.com>
11982 * server.c (handle_v_requests): When handling the vRun and vAttach
11983 packets, if already debugging a process, don't kill it. Return an
11986 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
11988 * server.c (handle_query): Correct length check.
11990 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
11992 * win32-low.c (do_initial_child_stuff): Add process handle
11993 parameter. Set current_process_handle and current_process_id from the
11994 parameters. Clear globals.
11995 (win32_create_inferior): Don't set current_process_handle and
11996 current_process_id here. Instead pass them on the call to
11997 do_initial_child_stuff.
11998 (win32_attach): Likewise.
11999 (win32_clear_inferiors): New.
12000 (win32_kill): Don't close the current process handle or the
12001 current thread handle here. Instead call win32_clear_inferiors.
12002 (win32_detach): Don't open a new handle to the process. Call
12003 win32_clear_inferiors.
12004 (win32_join): Don't rely on current_process_handle; open a new
12005 handle using the process id.
12006 (win32_wait): Call win32_clear_inferiors when the inferior process
12009 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
12011 * server.c (monitor_show_help): Add "exit".
12013 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
12015 * Makefile.in (SFILES): Add linux-xtensa-low.c.
12016 (clean): Add reg-xtensa.c.
12017 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
12018 * configure.srv (xtensa*-*-linux*) New target.
12019 * linux-xtensa-low.c: New.
12020 * xtensa-xtregs.c: New.
12022 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
12024 * hostio.c: Don't include errno.h.
12025 (errno_to_fileio_errno): Move to hostio-errno.
12026 * hostio.c: (hostio_error): Remove the error parameter. Defer the
12027 error number outputting to the target->hostio_last_error callback.
12028 (hostio_packet_error): Use FILEIO_EINVAL directly.
12029 (handle_open, handle_pread, hostio_error, handle_unlink): Update
12030 calls to hostio_error.
12031 * hostio-errno.c: New.
12032 * server.h (hostio_last_error_from_errno): Declare.
12033 * target.h (target_ops): Add hostio_last_error member.
12034 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
12035 as hostio_last_error handler.
12036 * spu-low.c (spu_target_ops): Likewise.
12037 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
12038 (wince_hostio_last_error): New functions.
12039 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
12040 as hostio_last_error handler.
12041 (win32_target_ops) [!_WIN32_WCE]: Register
12042 hostio_last_error_from_errno as hostio_last_error handler.
12043 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
12044 (hostio-errno.o): New rule.
12045 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
12046 * configure.srv (srv_hostio_err_objs): New variable. Default to
12048 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
12049 * configure: Regenerate.
12051 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
12053 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
12054 (linux_kill, linux_detach): Clean up the process list.
12055 * remote-utils.c (remote_open): Improve port number parsing.
12056 (putpkt_binary, input_interrupt): Only send interrupts if the target
12058 * server.c (extended_protocol): Make static.
12059 (attached): Define earlier.
12060 (exit_requested, response_needed, program_argv): New variables.
12061 (target_running): New.
12062 (start_inferior): Clear attached here.
12063 (attach_inferior): Set attached here.
12064 (require_running): Define.
12065 (handle_query): Use require_running and target_running. Implement
12067 (handle_v_attach, handle_v_run): New.
12068 (handle_v_requests): Use require_running. Handle vAttach and vRun.
12069 (gdbserver_usage): Update.
12070 (main): Redo argument parsing. Handle --debug and --multi. Handle
12071 --attach along with other options or after the port. Save
12072 program_argv. Support no initial program. Resynchronize
12073 communication with GDB after an error. Handle "monitor exit".
12074 Use require_running and target_running. Always allow the extended
12075 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
12076 restart in extended mode.
12077 * README: Refer to the GDB manual. Update --attach usage.
12079 2007-12-20 Andreas Schwab <schwab@suse.de>
12081 * linux-low.c (STACK_SIZE): Define.
12082 (linux_tracefork_child): Use it. Use __clone2 on ia64.
12083 (linux_test_for_tracefork): Likewise.
12085 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
12087 * linux-low.c (linux_wait_for_event): Update messages. Do not
12088 reinsert auto-delete breakpoints.
12089 * mem-break.c (struct breakpoint): Change return type of handler to
12091 (set_breakpoint_at): Update handler type.
12092 (reinsert_breakpoint_handler): Return 1 instead of calling
12094 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
12096 (check_breakpoints): Delete auto-delete breakpoints and return 2.
12097 * mem-break.h (set_breakpoint_at): Update handler type.
12098 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
12099 * win32-low.c (auto_delete_breakpoint): New.
12100 (get_child_debug_event): Use it.
12102 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
12104 * configure.ac: Check for pread and pwrite.
12105 * hostio.c (handle_pread): Fall back to lseek and read.
12106 (handle_pwrite): Fall back to lseek and write.
12107 * config.in, configure: Regenerated.
12109 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
12111 * server.c (myresume): Add own_buf argument.
12112 (main): Update calls.
12114 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
12116 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
12117 * remote-utils.c (remote_open): Do not call disable_async_io.
12118 (block_async_io): Delete.
12119 (unblock_async_io): Make static.
12120 (initialize_async_io): New.
12121 * server.c (handle_v_cont): Handle async I/O here.
12122 (myresume): Likewise. Move other common resume tasks here...
12123 (main): ... from here. Call initialize_async_io. Disable async
12124 I/O before the main loop.
12125 * server.h (initialize_async_io): Declare.
12126 (block_async_io, unblock_async_io): Delete prototypes.
12127 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
12129 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
12131 * remote-utils.c (readchar): Allow binary data in received messages.
12133 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
12135 * win32-low.c (attaching): New global.
12136 (win32_create_inferior): Clear the `attaching' global.
12137 (win32_attach): Set the `attaching' global.
12138 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
12139 attaching. Only set a breakpoint at the entry point if not
12142 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
12144 * server.c (main): Don't report dll events on the initial
12145 connection on attaches.
12147 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
12149 * server.c (main): Relax numerical bases supported for the pid of
12150 the --attach command line argument.
12152 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
12154 * win32-low.c (win32_attach): Call OpenProcess before
12155 DebugActiveProcess, not after. Add last error output to error
12158 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
12160 * win32-low.c (win32_get_thread_context)
12161 (win32_set_thread_context): New functions.
12162 (thread_rec): Use win32_get_thread_context.
12163 (continue_one_thread, win32_resume): Use win32_set_thread_context.
12164 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
12167 2007-12-03 Leo Zayas
12168 Pedro Alves <pedro_alves@portugalmail.pt>
12170 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
12172 (child_add_thread): Minor cleanup.
12173 (child_continue): Resume artificially suspended threads before
12174 calling ContinueDebugEvent.
12175 (suspend_one_thread): New.
12176 (fake_breakpoint_event): New.
12177 (get_child_debug_event): Change return type to int. Check here if
12178 gdb sent an interrupt request. If a soft interrupt was requested,
12179 fake a breakpoint event. Return 0 if there is no event to handle,
12181 (win32_wait): Don't check here if gdb sent an interrupt request.
12182 Ensure there is a valid event to handle.
12183 (win32_request_interrupt): Add soft interruption method as last
12186 2007-12-03 Leo Zayas
12187 Pedro Alves <pedro_alves@portugalmail.pt>
12189 * win32-low.h (win32_thread_info): Add descriptions to the
12190 structure members. Replace `suspend_count' counter by a
12192 * win32-low.c (thread_rec): Update condition of when to get the
12193 context from the inferior. Rely on ContextFlags being set if it
12194 has already been retrieved. Only suspend the inferior thread if
12195 we haven't already. Warn if that fails.
12196 (continue_one_thread): s/suspend_count/suspended/. Only call
12197 ResumeThread once. Warn if that fails.
12199 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
12201 * win32-low.c (win32_wait): Don't read from the inferior when it
12202 has already exited.
12204 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
12206 * Makefile.in (win32_low_h): New variable.
12207 (win32-low.o): Add dependency on $(win32_low_h).
12208 (win32-arm-low.o, win32-i386-low.o): New rules.
12210 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
12212 * hostio.c: Correct copyright year.
12214 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
12216 * Makefile.in (OBS): Add hostio.o.
12217 (hostio.o): New rule.
12218 * server.h (handle_vFile): Declare.
12219 * hostio.c: New file.
12220 * server.c (handle_v_requests): Take packet_len and new_packet_len
12221 for binary packets. Call handle_vFile.
12222 (main): Update call to handle_v_requests.
12224 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
12226 * linux-low.c: Include <sched.h>.
12228 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
12230 * linux-low.c (linux_tracefork_grandchild): New.
12231 (linux_tracefork_child): Use clone.
12232 (linux_test_for_tracefork): Use clone; allocate and free a stack.
12234 2007-10-31 Joel Brobecker <brobecker@adacore.com>
12236 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
12238 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
12240 * linux-low.c (handle_extended_wait): Handle unexpected signals.
12242 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
12244 * inferiors.c (change_inferior_id): Delete.
12245 (add_pid_to_list, pull_pid_from_list): New.
12246 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
12247 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
12248 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
12249 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
12250 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
12251 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
12252 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
12253 (using_threads): Always set to 1.
12254 (handle_extended_wait): New.
12255 (add_process): Do not set TID.
12256 (linux_create_inferior): Set must_set_ptrace_flags.
12257 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
12258 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
12259 (linux_thread_alive): Rename TID argument to LWPID.
12260 (linux_wait_for_process): Handle unknown processes. Do not use TID.
12261 (linux_wait_for_event): Do not use TID or check using_threads. Update
12262 call to dead_thread_notify. Call handle_extended_wait.
12263 (linux_create_inferior): Use PTRACE_SETOPTIONS.
12264 (send_sigstop): Delete sigstop_sent.
12265 (wait_for_sigstop): Avoid TID.
12266 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
12267 (linux_test_for_tracefork): New.
12268 (linux_lookup_signals): Use thread_db_active and
12269 linux_supports_tracefork_flag.
12270 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
12271 * linux-low.h (get_process_thread): Avoid TID.
12272 (struct process_ifo): Move thread_known and tid to the end. Remove
12274 (linux_attach_lwp, thread_db_init): Update prototypes.
12275 * server.h (change_inferior_id): Delete prototype.
12276 (add_pid_to_list, pull_pid_from_list): New prototypes.
12277 * thread-db.c (thread_db_use_events): New.
12278 (find_first_thread): Rename to...
12279 (find_one_thread): ...this. Update callers and messages. Do not
12280 call fatal. Check thread_db_use_events. Do not call
12281 change_inferior_id or new_thread_notify.
12282 (maybe_attach_thread): Update. Do not call new_thread_notify.
12283 (thread_db_init): Set thread_db_use_events. Check use_events.
12284 * utils.c (fatal, warning): Correct message prefix.
12286 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
12288 * Makefile.in (clean): Remove new files.
12289 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
12290 (powerpc-64.o, powerpc-64.c): New rules.
12291 * configure.srv: Use alternate register sets for powerpc64-*-linux*
12292 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
12294 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
12296 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
12297 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
12298 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
12299 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
12300 (target_regsets): Add AltiVec and SPE register sets.
12301 * configure.ac: Check for AltiVec and SPE.
12302 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
12303 (ppc_fill_vrregset, ppc_store_vrregset): New.
12304 (target_regsets): Add AltiVec register set.
12305 * configure: Regenerated.
12307 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
12309 * linux-low.c (O_LARGEFILE): Define.
12310 (linux_read_memory): Use /proc/PID/mem.
12311 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
12312 * configure, config.in: Regenerated.
12314 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
12316 * linux-low.c (linux_wait_for_event): Do not pass signals while
12319 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
12321 * win32-low.c (create_process): New.
12322 (win32_create_inferior): Use create_process instead of
12323 CreateProcess. If create_process failed retry appending an ".exe"
12324 suffix. Store the GetLastError result immediatelly after
12325 create_process calls and use it on the call to error.
12327 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
12329 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
12331 2007-08-23 Joel Brobecker <brobecker@adacore.com>
12333 * configure.ac: Switch license to GPLv3.
12335 2007-08-01 Michael Snyder <msnyder@access-company.com>
12337 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
12339 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
12341 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
12343 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
12344 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
12345 CloseToolhelp32Snapshot.
12346 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
12347 CloseToolhelp32Snapshot.
12349 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
12351 * server.c (main): Check for inferior exit before main loop.
12353 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
12355 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
12356 instead of on tmp_desc.
12358 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
12359 Daniel Jacobowitz <dan@codesourcery.com>
12361 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
12362 (add_thread): Minor cleanups.
12363 (clear_inferiors): Move lower in the file. Clear the DLL
12365 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
12366 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
12367 (xml_escape_text): New.
12368 * server.c (handle_query): Handle qXfer:libraries:read. Report it
12370 (handle_v_cont): Report errors.
12371 (gdbserver_version): Update.
12372 (main): Correct size of own_buf. Do not report initial DLL events.
12373 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
12374 (unloaded_dll, xml_escape_text): New.
12375 * win32-low.c (enum target_waitkind): Update comments.
12376 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
12377 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
12378 (win32_EnumProcessModules, win32_GetModuleInformation)
12379 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
12380 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
12381 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
12382 (win32_Module32First, win32_Module32Next, load_toolhelp)
12383 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
12384 (get_child_debug_event): Handle DLL events.
12385 (win32_wait): Likewise.
12387 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
12389 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
12390 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
12392 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
12394 * win32-low.c (handle_output_debug_string): Ignore event if not
12397 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
12399 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
12401 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
12403 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
12405 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
12407 * inferiors.c (change_inferior_id): Add comment.
12408 * linux-low.c (check_removed_breakpoint): Add an early
12409 prototype. Improve debug output.
12410 (linux_attach): Doc update.
12411 (linux_detach_one_process, linux_detach): Clean up before releasing
12413 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
12414 * linux-low.h (struct process_info): Doc improvement.
12415 * mem-break.c (delete_all_breakpoints): New.
12416 * mem-break.h (delete_all_breakpoints): New prototype.
12417 * thread-db.c (find_first_thread): New.
12418 (thread_db_create_event): Call it instead of
12419 thread_db_find_new_threads. Clean up unused variables.
12420 (maybe_attach_thread): Remove first thread handling.
12421 (thread_db_find_new_threads): Use find_first_thread.
12422 (thread_db_get_tls_address): Likewise.
12424 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
12426 * thread-db.c (thread_db_find_new_threads): Add prototype.
12427 (thread_db_create_event): Check for the main thread before adding
12429 (maybe_attach_thread): Only enable event reporting if TID == 0.
12430 (thread_db_get_tls_address): Check for new threads.
12432 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
12434 * linux-low.c (linux_create_inferior): Try execv before execvp.
12435 * spu-low.c (spu_create_inferior): Likewise.
12437 2007-06-13 Mike Frysinger <vapier@gentoo.org>
12439 * linux-low.c (linux_create_inferior): Change execv to execvp.
12440 * spu-low.c (spu_create_inferior): Likewies.
12442 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
12444 * Makefile.in (clean): Clean new files instead of deleted ones.
12445 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
12446 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
12448 * configure.srv: Specify XML files and new regformats for MIPS and
12450 * linux-mips-low.c (mips_num_regs): Set to only used registers.
12451 (mips_regmap): Do not fetch $0. Remove unused registers. Add
12452 an entry for the restart register.
12453 (mips_cannot_fetch_register, mips_cannot_store_register)
12454 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
12455 register names to match the XML descriptions.
12456 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
12457 restart register instead of $0.
12459 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
12460 Markus Deuling <deuling@de.ibm.com>
12462 * remote-utils.c (decode_xfer_write): New function.
12463 * server.h (decode_xfer_write): Add prototype.
12464 * server.c (handle_query): Add PACKET_LEN argument. Support
12465 qXfer:spu:read and qXfer:spu:write packets.
12466 (main): Pass packet_len to handle_query.
12467 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
12468 * target.h (target_ops): Add qxfer_spu.
12470 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
12472 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
12473 accessing non-seekable spufs files.
12475 2007-05-16 Markus Deuling <deuling@de.ibm.com>
12477 * server.c (handle_query): Add reply for qC packet.
12479 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12480 Leo Zayas <lerele@champenstudios@com>
12482 * server.h (check_remote_input_interrupt_request): New function.
12483 * remote_utils.c (INVALID_DESCRIPTOR): New define.
12484 (remote_desc): Initialize with INVALID_DESCRIPTOR.
12485 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
12486 (check_remote_input_interrupt_request): New function.
12487 * server.h (check_remote_input_interrupt_request): Declare.
12488 * win32-low.c (winapi_DebugBreakProcess,
12489 winapi_GenerateConsoleCtrlEvent): New typedefs.
12490 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
12492 (win32_wait): Check for remote interrupt request
12493 with check_remote_input_interrupt_request.
12494 (win32_request_interrupt): New function.
12495 (win32_target_op): Set request_interrupt to win32_request_interrupt.
12497 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12499 * win32-low.c (debug_registers_changed,
12500 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
12501 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
12502 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
12503 (thread_rec): Get context using the low target.
12504 (child_add_thread): Call thread_added on the low target,
12505 which does the same thing.
12507 (do_initial_child_stuff): Remove debug registers references.
12508 Set context using the low target. Resume threads after
12509 setting the contexts.
12510 (child_continue): Remove dead variable. Remove debug
12511 registers references.
12512 (child_fetch_inferior_registers): Go through the low target.
12513 (do_child_store_inferior_registers): Remove.
12514 (child_store_inferior_registers): Go through the low target.
12515 (win32_resume): Remove debug registers references.
12516 Set context using the low target.
12517 (handle_exception): Change return type to void. Don't record
12518 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
12519 first chance exception.
12520 (get_child_debug_event): Change return type to void. Remove
12521 goto loop. Always return after waiting for debug event.
12522 (win32_wait): Convert to switch statement. Handle spurious
12525 * win32-i386-low.c (debug_registers_changed,
12526 debug_registers_used): New.
12527 (initial_stuff): Rename to ...
12528 (i386_initial_stuff): ... this. Clear debug registers
12530 (store_debug_registers): Delete.
12531 (i386_get_thread_context): New.
12532 (load_debug_registers): Delete.
12533 (i386_set_thread_context): New.
12534 (i386_thread_added): New.
12535 (single_step): Rename to ...
12536 (i386_single_step): ... this.
12537 (do_fetch_inferior_registers): Rename to ...
12538 (i386_fetch_inferior_register): ... this.
12539 (i386_store_inferior_register): New.
12540 (the_low_target): Adapt to new interface.
12542 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
12543 (arm_get_thread_context): New.
12544 (arm_set_thread_context): New.
12546 (do_fetch_inferior_registers): Rename to ...
12547 (arm_fetch_inferior_register): ... this.
12548 (arm_store_inferior_register): New.
12549 (arm_wince_breakpoint): Reimplement as unsigned long.
12550 (arm_wince_breakpoint_len): Define.
12551 (the_low_target): Adapt to new interface.
12553 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
12554 load_debug_registers. Add get_thread_context, set_thread_context,
12555 thread_added and store_inferior_register. Rename
12556 fetch_inferior_registers to fetch_inferior_register.
12557 (regptr): Remove declaration.
12559 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12561 * linux-low.c (linux_detach): Change return type to int. Return 0.
12562 * spu-low.c (spu_detach): Likewise.
12564 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12566 * target.h (target_ops): Change return type of detach to int.
12568 (join_inferior): New.
12569 * server.c (main): Don't skip detach support on mingw32.
12570 If the inferior doesn't support detaching return error.
12571 Call join_inferior instead of using waitpid.
12572 * linux-low.c (linux_join): New.
12573 (linux_target_op): Add linux_join.
12574 * spu-low.c (spu_join): New.
12575 (spu_target_ops): Add spu_join.
12576 * win32-low.c (win32_detach): Adapt to new interface.
12577 Reopen current_process_handle before detaching. Issue a child
12578 resume before detaching.
12580 (win32_target_op): Add win32_join.
12582 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12584 * win32-low.c (win32-attach): Fix return value.
12585 * target.h (target_ops): Describe ATTACH return values.
12587 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12589 * win32-low.c (GETPROCADDRESS): Define.
12590 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
12591 (winapi_DebugSetProcessKillOnExit): Likewise.
12592 (win32_create_inferior): Force usage of ansi CreateProcessA.
12593 (win32_attach): Use GETPROCADDRESS.
12594 (win32_detach): Likewise.
12596 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
12598 * win32-low.c (win32_wait): Don't use WSTOPSIG.
12600 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
12602 * win32-low.c: Commit leftover changes from 2007-03-29.
12604 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
12606 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
12607 fields short instead of int. Add explicit padding.
12608 (i387_cache_to_fsave): Remove unnecessary casts.
12609 (i387_fsave_to_cache): Doc fix.
12610 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
12612 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
12614 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
12615 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
12617 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
12619 * configure.srv (arm*-*-mingw32ce*): Move near the other
12622 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
12624 * configure.ac: Add errno checking.
12625 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
12626 sys/file.h and malloc.h.
12627 (AC_CHECK_DECLS): Add perror.
12628 (srv_mingwce): Handle.
12629 * configure.srv (i[34567]86-*-cygwin*): Add
12630 win32-i386-low.o to srv_tgtobj.
12631 (i[34567]86-*-mingw*): Likewise.
12632 (arm*-*-mingw32ce*): Add case.
12633 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
12634 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
12635 [__MINGW32CE__] (strerror): New function.
12636 [__MINGW32CE__] (errno): Define to GetLastError.
12637 [__MINGW32CE__] (COUNTOF): New macro.
12638 (remote_open): Remove extra close call.
12639 * mem-break.c (delete_breakpoint_at): New function.
12640 * mem-break.h (delete_breakpoint_at): Declare.
12641 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
12642 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
12643 [USE_WIN32API] (read, write): Add char* casts.
12644 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
12645 * server.h: Include wincecompat.h on Windows CE.
12646 [HAVE_ERRNO_H]: Check.
12647 (perror): Declare if not declared.
12648 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
12649 (perror_with_name): Remove errno declaration.
12650 * wincecompat.h: New.
12651 * wincecompat.c: New.
12652 * win32-low.h: New.
12653 * win32-arm-low.c: New.
12654 * win32-i386-low.c: New.
12655 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
12656 (OUTMSG2): Make it safe.
12658 (COUNTOF): New macro.
12659 (NUM_REGS): Get it from the low target.
12660 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
12661 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
12662 (thread_rec): Let low target handle debug registers.
12663 (child_add_thread): Likewise.
12664 (child_init_thread_list): Likewise.
12665 (continue_one_thread): Likewise.
12667 (do_child_fetch_inferior_registers): Move to ...
12668 * win32-i386-low.c: ... here, and rename to ...
12669 (do_fetch_inferior_registers): ... this.
12670 * win32-low.c (child_fetch_inferior_registers):
12671 Go through the low target.
12672 (do_child_store_inferior_registers): Use regptr.
12673 (strwinerror): New function.
12674 (win32_create_inferior): Handle Windows CE.
12675 Use strwinerror instead of strerror on Windows error
12676 codes. Add program to the error output.
12677 Don't close the main thread handle on Windows CE.
12678 (win32_attach): Use coredll.dll on Windows CE.
12679 (win32_kill): Close current process and current
12681 (win32_detach): Use coredll.dll on Windows CE.
12682 (win32_resume): Let low target handle debug registers, and
12684 (handle_exception): Add/Remove initial breakpoint. Avoid
12685 non-existant WSTOPSIG on Windows CE.
12686 (win32_read_inferior_memory): Cast to remove warning.
12687 (win32_arch_string): Go through the low target.
12688 (initialize_low): Call set_breakpoint_data with the low
12689 target's breakpoint.
12690 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
12691 FOP_REGNUM, mappings): Move to ...
12692 * win32-i386-low.c: ... here.
12693 * win32-low.c (win32_thread_info): Move to ...
12694 * win32-low.h: ... here.
12695 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
12696 win32-arm-low.c and wincecompat.c.
12697 (all:): Add $EXEEXT.
12698 (install-only:): Likewise.
12699 (gdbserver:): Likewise.
12700 (gdbreplay:): Likewise.
12701 * config.in: Regenerate.
12702 * configure: Regenerate.
12704 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
12706 * win32-low.c: Rename typedef thread_info to
12707 win32_thread_info throughout.
12709 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
12711 * win32-i386-low.c: Rename to ...
12712 * win32-low.c: ... this.
12713 * configure.srv: Replace win32-i386-low.o with win32-low.o.
12714 * Makefile.in: Likewise.
12716 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
12718 * remote-utils.c (monitor_output): Constify msg parameter.
12719 * server.h (monitor_output): Likewise.
12720 * win32-i386-low.c (handle_output_debug_string): New.
12721 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
12722 handle_output_debug_string.
12723 (get_child_debug_event): Likewise.
12725 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
12727 * server.c (main): Correct strtoul check.
12729 2007-03-27 Jon Ringle <jon@ringle.org>
12731 * linux-low.c: Check __ARCH_HAS_MMU__ also.
12733 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
12735 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
12737 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
12739 * terminal.h: Check HAVE_SGTTY_H.
12741 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
12743 * remote-utils.c (remote_open): Print out the assigned port number.
12745 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
12747 * remote-utils.c (monitor_output): New function.
12748 * server.c (debug_threads): Define here.
12749 (monitor_show_help): New function.
12750 (handle_query): Handle qRcmd.
12751 (main): Do not handle 'd' packet.
12752 * server.h (debug_threads, remote_debug, monitor_output): Declare.
12753 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
12756 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
12758 * Makefile.in (EXEEXT): New.
12759 (clean): Use $(EXEEXT).
12761 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
12763 * target.h (target_ops): Rename send_signal to request_interrupt,
12764 and remove enum target_signal parameter.
12765 * linux-low.c (linux_request_interrupt): Rename from
12766 linux_send_signal, and always send SIGINT.
12767 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
12768 and always send SIGINT.
12769 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
12771 (input_interrupt): Likewise.
12773 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
12775 * server.c (get_features_xml): Check if target implemented
12777 * win32-i386-low.c (win32_arch_string): New.
12778 (win32_target_ops): Add win32_arch_string as arch_string member.
12780 2007-02-22 Markus Deuling <deuling@de.ibm.com>
12782 * spu-low.c (spu_arch_string): New.
12783 (spu_target_ops): Add spu_arch_string.
12785 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
12787 * remote-utils.c: Remove HAVE_TERMINAL_H check.
12788 * configure.ac: Do not check for terminal.h.
12789 * configure, config.in: Regenerated.
12791 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
12793 * Makefile.in (OBS): Add $(XML_BUILTIN).
12794 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
12796 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
12797 (arm-with-iwmmxt.c): New.
12798 * config.in, configure: Regenerate.
12799 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
12800 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
12801 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
12802 (arm*-*-linux*): Add iWMMXt and regset support.
12803 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
12804 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
12805 (arm_store_wmmxregset, target_regsets): New.
12806 * server.c (get_features_xml): Take annex argument. Check builtin
12808 (handle_query): Handle multiple annexes.
12810 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
12812 * remote-utils.c [USE_WIN32API] (read, write): Define.
12813 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
12816 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
12818 * linux-i386-low.c (the_low_target): Set arch_string.
12819 * linux-x86-64-low.c (the_low_target): Likewise.
12820 * linux-low.c (linux_arch_string): New.
12821 (linux_target_ops): Add it.
12822 * linux-low.h (struct linux_target_ops): Add arch_string.
12823 * server.c (write_qxfer_response): Use const void * for DATA.
12824 (get_features_xml): New.
12825 (handle_query): Handle qXfer:features:read. Report it for qSupported.
12826 * target.h (struct target_ops): Add arch_string method.
12828 2007-01-03 Denis Pilat <denis.pilat@st.com>
12829 Daniel Jacobowitz <dan@codesourcery.com>
12831 * linux-low.c (linux_kill): Handle being called with no threads.
12832 * win32-i386-low.c (win32_kill): Likewise.
12833 (get_child_debug_event): Clear current_process_handle.
12835 2006-12-30 Denis PILAT <denis.pilat@st.com>
12836 Daniel Jacobowitz <dan@codesourcery.com>
12838 * remote-utils.c (remote_open): Check the type of specified
12839 serial port devices before opening them.
12840 * server.c (main): Kill the inferior if an error occurs during
12841 the first remote_open.
12843 2006-12-05 Markus Deuling <deuling@de.ibm.com>
12845 * README: Update supported targets.
12847 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
12849 * Makefile.in (clean): Remove reg-mips64.c.
12850 (reg-mips64.c, reg-mips64.o): New rules.
12851 * configure.srv: Handle mips64. Include regset support for mips.
12852 * linux-mips-low.c (union mips_register): New.
12853 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
12854 (mips_breakpoint, mips_breakpoint_at): Use int.
12855 (mips_collect_register, mips_supply_register)
12856 (mips_collect_register_32bit, mips_supply_register_32bit)
12857 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
12858 (mips_store_fpregset, target_regsets): New.
12859 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
12861 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
12863 * configure.srv: Add target "spu*-*-*".
12864 * Makefile.in (clean): Remove reg-spu.c.
12865 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
12866 * spu-low.c: New file.
12868 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
12870 * configure.ac: Correct td_thr_tls_get_addr test.
12871 * configure: Regenerated.
12873 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
12875 * linux-low.c (linux_wait_for_event): Reformat. Use the
12876 pass_signals array.
12877 * remote-utils.c (decode_address_to_semicolon): New.
12878 * server.c (pass_signals, handle_general_set): New.
12879 (handle_query): Mention QPassSignals for qSupported.
12880 (main): Call handle_general_set.
12881 * server.h (pass_signals, decode_address_to_semicolon): New.
12883 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
12885 * server.c (handle_query): Correct error handling for read_auxv.
12887 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
12889 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
12890 and srv_linux_thread_db to yes.
12891 * linux-s390-low.c (s390_fill_gregset): New function.
12892 (target_regsets): Define data structure.
12894 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
12896 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
12897 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
12898 * config.in, configure: Regenerated.
12899 * inferiors.c (gdb_id_to_thread): New function.
12900 (gdb_id_to_thread_id): Use it.
12901 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
12902 * linux-low.h (struct process_info): Add th member.
12903 (thread_db_get_tls_address): New prototype.
12904 * remote-utils.c (decode_address): Make non-static.
12905 * server.c (handle_query): Handle qGetTLSAddr.
12906 * server.h (gdb_id_to_thread, decode_address): New prototypes.
12907 * target.h (struct target_ops): Add get_tls_address.
12908 * thread-db.c (maybe_attach_thread): Save the thread handle.
12909 (thread_db_get_tls_address): New.
12911 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
12913 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
12914 (linux_resume_one_process): Take a siginfo_t *. Update all
12915 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
12916 (struct pending_signals): Add a siginfo_t.
12917 (linux_wait_for_process): Always set last_status.
12918 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
12919 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
12920 * linux-low.h (struct process_info): Add last_status.
12922 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
12924 * remote-utils.c (try_rle): New function.
12925 (putpkt_binary): Use it.
12927 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
12929 * Makefile.in (clean): Clean reg-x86-64-linux.c.
12930 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
12931 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
12932 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
12933 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
12936 2006-08-08 Richard Sandiford <richard@codesourcery.com>
12938 * server.c (terminal_fd): New variable.
12939 (old_foreground_pgrp): Likewise.
12940 (restore_old_foreground_pgrp): New function.
12941 (start_inferior): Record the terminal file descriptor in terminal_fd
12942 and its original foreground group in old_foreground_pgrp. Register
12943 restore_old_foreground_pgrp with atexit().
12945 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
12947 * server.c (handle_query): Correct qPart to qXfer.
12949 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
12951 * configure.ac: Check for more headers which are missing on
12952 Windows. Automatically supply -lwsock32 and USE_WIN32API.
12953 * configure.srv: Add Cygwin and mingw32.
12954 * remote-utils.c: Don't include headers unconditionally which
12955 are missing on mingw32. Include <winsock.h> for mingw32.
12956 (remote_open): Adjust for mingw32 support. Flush
12957 standard error after writing to it.
12958 (remote_close, putpkt_binary, input_interrupt, block_async_io)
12959 (unblock_async_io, enable_async_io, disable_async_io)
12960 (readchar, getpkt): Update for Winsock support.
12961 (prepare_resume_reply): Expect a protocol signal number.
12962 * server.c: Disable <sys/wait.h> on mingw32.
12963 (start_inferior): Adjust for mingw32 support. Flush
12964 standard error after writing to it.
12965 (attach_inferior): Likewise. Use protocol signal
12967 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
12969 * win32-i386-low.c: New file.
12970 * Makefile.in (XM_CLIBS): Set.
12971 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
12972 (win32-i386-low.o): New dependency rule.
12973 * linux-low.c (linux_wait): Use target signal numbers.
12974 * target.h (struct target_ops): Doc fix.
12975 * server.h (target_signal_to_name): New prototype.
12976 * gdbreplay.c: Don't include headers unconditionally which
12977 are missing on mingw32. Include <winsock.h> for mingw32.
12978 (remote_close, remote_open): Adjust for Winsock support.
12979 * configure, config.in: Regenerated.
12981 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
12983 * server.c (decode_xfer_read, write_qxfer_response): New.
12984 (handle_query): Take a packet length argument. Handle
12985 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
12986 the qSupported response.
12987 (main): Update call to handle_query.
12989 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
12991 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
12992 (putpkt_binary): Renamed from putpkt and adjusted for binary
12994 (putpkt): New wrapper for putpkt_binary.
12995 (readchar): Don't mask off the high bit.
12996 (decode_X_packet): New function.
12997 * server.c (main): Call putpkt_binary if a handler sets the packet
12998 length. Save the length of the incoming packet. Handle 'X'.
12999 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
13001 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
13003 * server.c (handle_query): Handle qSupported.
13005 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
13007 * remote-utils.c (all_symbols_looked_up): New variable.
13008 (look_up_one_symbol): Check it.
13009 * server.h (look_up_one_symbol): New declaration.
13010 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
13012 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
13014 * Makefile.in (linux-arm-low.o): Update dependencies.
13015 * linux-arm-low.c: Include "gdb_proc_service.h".
13016 (PTRACE_GET_THREAD_AREA): Define.
13017 (ps_get_thread_area): New function.
13019 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
13021 * configure.srv (m68k*-*-uclinux*): New target.
13022 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
13023 (linux_resume_one_process): Remove extraneous cast.
13024 (linux_read_offsets): New.
13025 (linux_target_op): Add linux_read_offsets on mmuless systems.
13026 * server.c (handle_query): Add qOffsets logic.
13027 * target.h (struct target_ops): Add read_offsets.
13029 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
13031 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
13032 (PTRACE_GET_THREAD_AREA): Define.
13033 (ps_get_thread_area): New function.
13034 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
13035 (linux-x86-64-low.o): Update.
13037 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
13039 * configure.ac: Remove checks for prfpregset_t.
13040 * gdb_proc_service.h: New file.
13041 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
13042 new "gdb_proc_service.h".
13043 * proc-service.c: Likewise.
13044 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
13045 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
13046 * Makefile.in (gdb_proc_service_h): Updated.
13047 * configure, config.in: Regenerated.
13049 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
13051 * remote-utils.c (prepare_resume_reply): Move declaration
13052 of gdb_id_from_wait to the top of the block.
13054 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
13056 * linux-low.c (regsets_store_inferior_registers): Read the regset
13057 from the target before filling it.
13059 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
13061 * server.c (attach_inferior): Return SIGTRAP for a successful
13064 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13066 * Makefile.in (OBS): Add version.o.
13067 (STAGESTUFF): Delete.
13068 (version.o): Add dependencies.
13069 (version.c): Replace rule.
13070 (clean): Remove version.c.
13071 * server.c (gdbserver_version): New.
13072 (gdbserver_usage): Use printf.
13073 (main): Handle --version and --help.
13074 * server.h (version, host_name): Add declarations.
13076 2005-12-23 Eli Zaretskii <eliz@gnu.org>
13088 * linux-x86-64-low.c:
13090 * linux-s390-low.c:
13091 * linux-ppc64-low.c:
13093 * linux-mips-low.c:
13094 * linux-m68k-low.c:
13095 * linux-m32r-low.c:
13098 * linux-ia64-low.c:
13099 * linux-i386-low.c:
13100 * linux-crisv32-low.c:
13112 * gdbserver.1: Add (C) after Copyright. Update the FSF
13115 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
13117 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
13118 (arm_breakpoint_at): Recognize both breakpoints.
13119 (the_low_target): Use the correct breakpoint instruction.
13121 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
13123 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
13124 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
13125 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
13126 (the_low_target): Update.
13128 2005-10-25 Andreas Schwab <schwab@suse.de>
13130 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
13132 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
13133 (ia64_num_regs): Reduce to 462.
13135 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
13137 * acinclude.m4: Correct quoting.
13138 * aclocal.m4: Regenerated.
13140 Suggested by SZOKOVACS Robert <szo@ies.hu>:
13141 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
13142 (thread_db_init): Call thread_db_err_str.
13143 * configure.ac: Check for TD_VERSION.
13144 * config.in, configure: Regenerated.
13146 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
13148 * server.h (error, fatal, warning): Add ATTR_FORMAT.
13150 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
13152 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
13153 is not available. Define HAVE_PTRACE_GETREGS if it is.
13154 * config.in, configure: Regenerated.
13155 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
13156 * linux-i386-low.c, linux-m68k-low.c: Update to use
13157 HAVE_PTRACE_GETREGS.
13158 * linux-low.c (regsets_fetch_inferior_registers)
13159 (regsets_store_inferior_registers): Only return 0 if we processed
13161 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
13162 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
13164 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
13166 * inferiors.c (struct thread_info): Add gdb_id.
13167 (add_thread): Add gdb_id argument.
13168 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
13169 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
13170 calls to add_thread.
13171 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
13172 * server.c (handle_query): Use thread_to_gdb_id.
13173 (handle_v_cont, main): Use gdb_id_to_thread_id.
13174 * server.h (add_thread): Update prototype.
13175 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
13178 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
13180 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
13181 left-padded registers.
13182 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
13183 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
13185 2005-07-01 Steve Ellcey <sje@cup.hp.com>
13187 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
13188 * configure: Regenerate.
13189 * config.in: Regenerate.
13190 * server.h (NEED_DECLARATION_STRERROR):
13191 Replace with !HAVE_DECL_STRERROR.
13193 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
13195 * linux-low.c (linux_wait, linux_send_signal): Don't test
13196 an unsigned long variable for > 0 if it could be MAX_ULONG.
13197 * server.c (myresume): Likewise.
13198 * target.c (set_desired_inferior): Likewise.
13200 2005-06-13 Mark Kettenis <kettenis@gnu.org>
13202 * configure.ac: Simplify and improve check for socklen_t.
13203 * configure, config.in: Regenerate.
13205 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
13207 * acconfig.h: Remove.
13208 * configure.ac: Add a test for socklen_t. Use three-argument
13209 AC_DEFINE throughout.
13210 * config.in: Regenerated using autoheader 2.59.
13211 * configure: Regenerated.
13213 * gdbreplay.c (socklen_t): Provide a default.
13214 (remote_open): Use socklen_t.
13215 * remote-utils.c (socklen_t): Provide a default.
13216 (remote_open): Use socklen_t.
13217 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
13220 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
13222 * linux-low.c (linux_read_memory, linux_write_memory)
13223 (linux_read_auxv): Likewise.
13224 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
13225 (check_mem_write): Likewise.
13226 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
13228 * regcache.c (struct inferior_rgcache_data, registers_to_string)
13229 (registers_from_string, register_data): Likewise.
13230 * server.c (handle_query, main): Likewise.
13231 * server.h (convert_ascii_to_int, convert_int_to_ascii)
13232 (decode_M_packet): Likewise.
13233 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
13234 * target.h (struct target_ops): Update read_memory, write_memory,
13236 (read_inferior_memory, write_inferior_memory): Update.
13237 * linux-low.h (struct linux_target_ops): Change type of breakpoint
13238 to unsigned char *.
13239 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
13240 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
13241 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
13242 linux-s390-low.c, linux-sh-low.c: Update for changes in
13243 read_inferior_memory and the_low_target->breakpoint.
13245 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
13247 * Makefile.in (SFILES): Add linux-ppc64-low.c.
13248 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
13249 * configure.srv: Add powerpc64-*-linux*.
13250 * linux-ppc64-low.c: New file.
13252 2005-05-23 Orjan Friberg <orjanf@axis.com>
13254 * linux-cris-low.c: New file with support for CRIS.
13255 * linux-crisv32-low.c: Ditto for CRISv32.
13256 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
13257 (clean): Add reg-cris.c and reg-crisv32.c.
13258 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
13259 reg-crisv32.o, and reg-crisv32.c to make rules.
13260 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
13261 recognized targets.
13263 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
13265 * linux-low.c (fetch_register): Ensure buffer size is a multiple
13266 of sizeof (PTRACE_XFER_TYPE).
13267 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
13269 2005-05-12 Orjan Friberg <orjanf@axis.com>
13271 * target.h (struct target_ops): Add insert_watchpoint,
13272 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
13273 pointers for hardware watchpoint support.
13274 * linux-low.h (struct linux_target_ops): Ditto.
13275 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
13276 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
13277 to linux_target_ops.
13278 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
13280 * server.c (main): Recognize 'Z' and 'z' packets.
13282 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
13284 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
13285 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
13286 (the_low_target): Add new members.
13288 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
13290 * proc-service.c (ps_lgetregs): Search all_processes instead of
13293 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
13295 * server.c (start_inferior): Change return type to int.
13296 (attach_inferior): Change sigptr to int *.
13297 (handle_v_cont, handle_v_requests): Change signal to int *.
13298 (main): Change signal to int.
13300 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
13302 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
13303 * configure.srv: Add m32r*-*-linux*.
13304 * linux-m32r-low.c: New file.
13306 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
13308 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
13310 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
13312 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
13313 Take unsigned long arguments for PIDs.
13314 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
13315 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
13316 (wait_for_sigstop, linux_resume_one_process)
13317 (regsets_fetch_inferior_registers, linux_send_signal)
13318 (linux_read_auxv): Likewise. Update the types of variables holding
13319 PIDs. Update format string specifiers.
13320 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
13321 * remote-utils.c (prepare_resume_reply): Likewise.
13322 * server.c (cont_thread, general_thread, step_thread)
13323 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
13325 (handle_query): Update format specifiers.
13326 (handle_v_cont, main): Use strtoul for thread IDs.
13327 * server.h (struct inferior_list_entry): Use unsigned long for ID.
13328 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
13329 (general_thread, step_thread, thread_from_wait)
13330 (old_thread_from_wait): Update.
13331 * target.h (struct thread_resume): Use unsigned long for THREAD.
13332 (struct target_ops): Use unsigned long for arguments to attach and
13335 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
13337 * acinclude.m4: Include bfd/bfd.m4 directly.
13338 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
13339 <agriffis@toolchain.org>.
13340 * aclocal.m4, configure: Regenerated.
13342 2005-01-07 Andrew Cagney <cagney@gnu.org>
13344 * configure.ac: Rename configure.in, require autoconf 2.59.
13345 * configure: Re-generate.
13347 2004-12-08 Daniel Jacobowitz <dan@debian.org>
13349 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
13350 LIBS when finished.
13351 * aclocal.m4: Regenerated.
13352 * configure: Regenerated.
13354 2004-11-21 Andreas Schwab <schwab@suse.de>
13356 * linux-m68k-low.c (m68k_num_gregs): Define.
13357 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
13358 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
13359 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
13360 (m68k_breakpoint_at): New. Add to the_low_target.
13362 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
13363 srv_linux_thread_db to yes.
13365 2004-10-20 Joel Brobecker <brobecker@gnat.com>
13367 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
13368 (ARCH_SET_FS): Likewise.
13369 (ARCH_GET_FS): Likewise.
13370 (ARCH_GET_GS): Likewise.
13372 2004-10-16 Daniel Jacobowitz <dan@debian.org>
13374 * linux-i386-low.c (ps_get_thread_area): New.
13375 * linux-x86-64-low.c (ps_get_thread_area): New.
13376 * linux-low.c: Include <sys/syscall.h>.
13377 (linux_kill_one_process): Don't kill the first thread here.
13378 (linux_kill): Kill the first thread here.
13379 (kill_lwp): New function.
13380 (send_sigstop, linux_send_signal): Use it.
13381 * proc-service.c: Clean up #ifdefs.
13382 (fpregset_info): Delete.
13383 (ps_lgetregs): Update and enable implementation.
13384 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
13386 * remote-utils.c (struct sym_cache, symbol_cache): New.
13387 (input_interrupt): Print a clearer message.
13388 (async_io_enabled): New variable.
13389 (enable_async_io, disable_async_io): Use it. Update comments.
13390 (look_up_one_symbol): Use the symbol cache.
13391 * thread-db.c (thread_db_look_up_symbols): New function.
13392 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
13394 2004-10-16 Daniel Jacobowitz <dan@debian.org>
13396 * configure.in: Test for -rdynamic.
13397 * configure: Regenerated.
13398 * Makefile (INTERNAL_LDFLAGS): New.
13399 (gdbserver, gdbreplay): Use it.
13401 2004-09-02 Andrew Cagney <cagney@gnu.org>
13403 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
13405 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
13407 * linux-low.c (linux_wait): Clear all_processes list also.
13409 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
13411 * linux-low.c: Include <errno.h>. Remove extern declaration of
13414 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
13416 * gdbreplay.c, server.h, utils.c: Update copyright years.
13418 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
13420 * server.c (main): Print child status or termination signal from
13421 variable 'signal', not 'sig'.
13423 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
13425 * linux-low.c (linux_read_memory): Change return type to
13426 int. Check for and return error from ptrace().
13427 * target.c (read_inferior_memory): Change return type to int. Pass
13428 back return status from the_target->read_memory().
13429 * target.h (struct target_ops): Adapt *read_memory() prototype.
13431 (read_inferior_memory): Adapt prototype.
13432 * server.c (main): Return an error packet if
13433 read_inferior_memory() returns an error.
13435 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
13437 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
13438 Unify with other clean targets.
13440 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
13442 * server.c (handle_v_cont): Call set_desired_inferior.
13444 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
13446 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
13448 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
13450 * linux-low.c (linux_wait): Unblock async I/O.
13451 (linux_resume): Block and enable async I/O.
13452 * remote-utils.c (block_async_io, unblock_async_io): New functions.
13453 * server.h (block_async_io, unblock_async_io): Add prototypes.
13455 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
13457 * remote-utils.c (remote_open): Print a status notice after
13458 opening a TCP port.
13459 * server.c (attach_inferior): Print a status notice after
13462 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
13464 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
13466 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
13468 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
13470 * server.c, target.h: Update copyright years.
13472 2004-02-25 Roland McGrath <roland@redhat.com>
13474 * target.h (struct target_ops): New member `read_auxv'.
13475 * server.c (handle_query): Handle qPart:auxv:read: query using that.
13476 * linux-low.c (linux_read_auxv): New function.
13477 (linux_target_ops): Initialize `read_auxv' member to that.
13479 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
13481 Committed by Jim Blandy <jimb@redhat.com>.
13483 * linux-s390-low.c (s390_num_regs): Update.
13484 (s390_regmap): Remove control registers. Use __s390x__ predefine
13485 instead of GPR_SIZE to distiguish s390 and s390x targets.
13487 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
13489 * linux-low.c: Update copyright year.
13490 (check_removed_breakpoint): Clear pending_is_breakpoint.
13491 (linux_set_resume_request, linux_queue_one_thread)
13492 (resume_status_pending_p): New functions.
13493 (linux_continue_one_thread): Use process->resume.
13494 (linux_resume): Only resume threads if there are no pending events.
13495 * linux-low.h (struct process_info): Add resume request
13498 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
13500 * regcache.c (new_register_cache): Clear the allocated register
13501 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
13503 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
13505 * linux-low.c (linux_resume): Take a struct thread_resume *
13507 (linux_wait): Update call.
13508 (resume_ptr): New static variable.
13509 (linux_continue_one_thread): Renamed from
13510 linux_continue_one_process. Use resume_ptr.
13511 (linux_resume): Use linux_continue_one_thread.
13512 * server.c (handle_v_cont, handle_v_requests): New functions.
13513 (myresume): New function.
13514 (main): Handle 'v' case.
13515 * target.h (struct thread_resume): New type.
13516 (struct target_ops): Change argument of "resume" to struct
13518 (myresume): Delete macro.
13520 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
13522 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
13523 (uninstall): Support DESTDIR.
13525 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
13527 * configure.srv: Add xscale*linux copy of arm*linux entry.
13529 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
13531 * linux-arm-low.c (arm_reinsert_addr): New function.
13532 (the_low_target): Add arm_reinsert_addr.
13534 2003-07-08 Mark Kettenis <kettenis@gnu.org>
13536 * mem-break.c: Remove whitespace at end of file.
13538 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
13540 * configure.in: Check whether we need to prototype strerror.
13541 * server.h: Optionally prototype strerror.
13542 * gdbreplay.c (perror_with_name): Use strerror.
13543 * linux-low.c (linux_attach_lwp): Use strerror.
13544 * utils.c (perror_with_name): Use strerror.
13545 * config.in, configure: Regenerated.
13547 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
13549 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
13550 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
13552 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
13554 * Makefile.in (SFILES): Update.
13555 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
13556 low-sun3.c: Remove files.
13558 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
13560 * linux-low.c: Move comment to linux_thread_alive where it belonged.
13561 (linux_detach_one_process, linux_detach): New functions.
13562 (linux_target_ops): Add linux_detach.
13563 * server.c (main): Handle 'D' packet.
13564 * target.h (struct target_ops): Add "detach" member.
13565 (detach_inferior): Define.
13567 2003-06-13 Mark Kettenis <kettenis@gnu.org>
13569 From Kelley Cook <kelleycook@wideopenwest.com>:
13570 * configure.srv: Accept i[34567]86 variants.
13572 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
13574 * linux-low.c (linux_wait_for_event): Correct comment typos.
13575 (linux_resume_one_process): Call check_removed_breakpoint.
13576 (linux_send_signal): New function.
13577 (linux_target_ops): Add linux_send_signal.
13578 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
13580 * target.h (struct target_ops): Add send_signal.
13582 2003-05-29 Jim Blandy <jimb@redhat.com>
13584 * linux-low.c (usr_store_inferior_registers): Transfer buf in
13585 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
13586 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
13587 away part of the register's value.
13589 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
13591 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
13592 (linux_wait_for_event, linux_init_signals): Likewise.
13594 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
13596 * configure.in: Check for stdlib.h.
13597 * configure: Regenerated.
13598 * config.in: Regenerated.
13600 2003-01-04 Andreas Schwab <schwab@suse.de>
13602 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
13604 2003-01-02 Andrew Cagney <ac131313@redhat.com>
13606 * Makefile.in: Remove obsolete code.
13608 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
13610 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
13611 defined(PT_FPR0_HI).
13613 2002-11-17 Stuart Hughes <seh@zee2.com>
13615 * linux-arm-low.c (arm_num_regs): Increase.
13616 (arm_regmap): Include status register.
13618 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
13620 * linux-low.c (register_addr): Remove incorrect -1 check.
13622 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
13624 * linux-low.c (linux_create_inferior): Call setpgid. Return
13626 (unstopped_p, linux_signal_pid): Remove.
13627 (linux_target_ops): Remove linux_signal_pid.
13628 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
13629 global instead of target method.
13630 * target.h (struct target_ops): Remove signal_pid. Update comment
13631 for create_inferior.
13632 * server.c (signal_pid): New variable.
13633 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
13634 gdbserver. Set the child to be the foreground process group.
13635 (attach_inferior): Set signal_pid.
13637 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
13639 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
13641 2002-08-20 Jim Blandy <jimb@redhat.com>
13643 * Makefile.in (LDFLAGS): Allow the configure script to establish a
13646 2002-08-01 Andrew Cagney <cagney@redhat.com>
13648 * Makefile.in: Make chill references obsolete.
13650 2002-07-24 Kevin Buettner <kevinb@redhat.com>
13652 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
13653 * configure: Regenerate.
13654 * config.in: Regenerate.
13656 2002-07-09 David O'Brien <obrien@FreeBSD.org>
13658 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
13659 (perror_with_name, remote_close, remote_open, expect, play): Static.
13661 2002-07-04 Michal Ludvig <mludvig@suse.cz>
13663 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
13664 byte offsets instead of an array of indexes.
13665 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
13667 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
13669 * regcache.c: Add comment.
13671 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
13673 * thread-db.c: New file.
13674 * proc-service.c: New file.
13675 * acinclude.m4: New file.
13676 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
13677 proc-service.o, and thread-db.o.
13678 (linux-low.o): Add USE_THREAD_DB.
13679 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
13680 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
13681 * aclocal.m4: Regenerated.
13682 * config.in: Regenerated.
13683 * configure: Regenerated.
13684 * configure.in: Check for proc_service.h, sys/procfs.h,
13685 thread_db.h, and linux/elf.h headrs.
13686 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
13687 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
13688 Check for -lthread_db and thread support.
13689 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
13690 PowerPC, and SuperH.
13691 * i387-fp.c: Constify arguments.
13692 * i387-fp.h: Likewise.
13693 * inferiors.c: (struct thread_info): Renamed from
13694 `struct inferior_info'. Remove PID member. Use generic inferior
13695 list header. All uses updated.
13696 (inferiors, signal_pid): Removed.
13697 (all_threads): New variable.
13698 (get_thread): Define.
13699 (add_inferior_to_list): New function.
13700 (for_each_inferior): New function.
13701 (change_inferior_id): New function.
13702 (add_inferior): Removed.
13703 (remove_inferior): New function.
13704 (add_thread): New function.
13705 (free_one_thread): New function.
13706 (remove_thread): New function.
13707 (clear_inferiors): Use for_each_inferior and free_one_thread.
13708 (find_inferior): New function.
13709 (find_inferior_id): New function.
13710 (inferior_target_data): Update argument type.
13711 (set_inferior_target_data): Likewise.
13712 (inferior_regcache_data): Likewise.
13713 (set_inferior_regcache_data): Likewise.
13714 * linux-low.c (linux_bp_reinsert): Remove.
13715 (all_processes, stopping_threads, using_thrads)
13716 (struct pending_signals, debug_threads, pid_of): New.
13717 (inferior_pid): Replace with macro.
13718 (struct inferior_linux_data): Remove.
13719 (get_stop_pc, add_process): New functions.
13720 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
13721 Use add_process and add_thread.
13722 (linux_attach_lwp): New function, based on old linux_attach. Use
13723 add_process and add_thread. Set stop_expected for new threads.
13724 (linux_attach): New function.
13725 (linux_kill_one_process): New function.
13726 (linux_kill): Kill all LWPs.
13727 (linux_thread_alive): Use find_inferior_id.
13728 (check_removed_breakpoints, status_pending_p): New functions.
13729 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
13730 Update. Use WNOHANG. Wait for cloned processes also. Update process
13731 struct for the found process.
13732 (linux_wait_for_event): New function.
13733 (linux_wait): Use it. Support LWPs.
13734 (send_sigstop, wait_for_sigstop, stop_all_processes)
13735 (linux_resume_one_process, linux_continue_one_process): New functions.
13736 (linux_resume): Support LWPs.
13737 (REGISTER_RAW_SIZE): Remove.
13738 (fetch_register): Use register_size instead. Call supply_register.
13739 (usr_store_inferior_registers): Likewise. Call collect_register.
13740 Fix recursive case.
13741 (regsets_fetch_inferior_registers): Improve error message.
13742 (regsets_store_inferior_registers): Add debugging.
13743 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
13744 (unstopped_p, linux_signal_pid): New functions.
13745 (linux_target_ops): Add linux_signal_pid.
13746 (linux_init_signals): New function.
13747 (initialize_low): Call it. Initialize using_threads.
13748 * regcache.c (inferior_regcache_data): Add valid
13750 (get_regcache): Fetch registers lazily. Add fetch argument
13751 and update all callers.
13752 (regcache_invalidate_one, regcache_invalidate): New
13754 (new_register_cache): Renamed from create_register_cache.
13755 Return the new regcache.
13756 (free_register_cache): Change argument to a void *.
13757 (registers_to_string, registers_from_string): Call get_regcache
13758 with fetch flag set.
13759 (register_data): Make static. Pass fetch flag to get_regcache.
13760 (supply_register): Call get_regcache with fetch flag clear.
13761 (collect_register): Call get_regcache with fetch flag set.
13762 (collect_register_as_string): New function.
13763 * regcache.h: Update.
13764 * remote-utils.c (putpkt): Flush after debug output and use
13766 Handle input interrupts while waiting for an ACK.
13767 (input_interrupt): Use signal_pid method.
13768 (getpkt): Flush after debug output and use stderr.
13769 (outreg): Use collect_register_as_string.
13770 (new_thread_notify, dead_thread_notify): New functions.
13771 (prepare_resume_reply): Check using_threads. Set thread_from_wait
13772 and general_thread.
13773 (look_up_one_symbol): Flush after debug output.
13774 * server.c (step_thread, server_waiting): New variables.
13775 (start_inferior): Don't use signal_pid. Update call to mywait.
13776 (attach_inferior): Update call to mywait.
13777 (handle_query): Handle qfThreadInfo and qsThreadInfo.
13778 (main): Don't fetch/store registers explicitly. Use
13779 set_desired_inferior. Support proposed ``Hs'' packet. Update
13781 * server.h: Update.
13782 (struct inferior_list, struct_inferior_list_entry): New.
13783 * target.c (set_desired_inferior): New.
13784 (write_inferior_memory): Constify.
13785 (mywait): New function.
13786 * target.h: Update.
13787 (struct target_ops): New signal_pid method.
13788 (mywait): Removed macro, added prototype.
13790 * linux-low.h (regset_func): Removed.
13791 (regset_fill_func, regset_store_func): New.
13792 (enum regset_type): New.
13793 (struct regset_info): Add type field. Use new operation types.
13794 (struct linux_target_ops): stop_pc renamed to get_pc.
13795 Add decr_pc_after_break and breakpoint_at.
13796 (get_process, get_thread_proess, get_process_thread)
13797 (strut process_info, all_processes, linux_attach_lwp)
13798 (thread_db_init): New.
13800 * linux-arm-low.c (arm_get_pc, arm_set_pc,
13801 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
13802 (the_low_target): Add new members.
13803 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
13804 (i386_store_fpxregset): Constify.
13805 (target_regsets): Add new kind identifier.
13806 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
13807 (i386_set_pc): Add debugging.
13808 (i386_breakpoint_at): New function.
13809 (the_low_target): Add new members.
13810 * linux-mips-low.c (mips_get_pc, mips_set_pc)
13811 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
13812 (mips_breakpoint_at): New.
13813 (the_low_target): Add new members.
13814 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
13815 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
13816 (the_low_target): Add new members.
13817 * linux-sh-low.c (sh_get_pc, sh_set_pc)
13818 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
13819 (the_low_target): Add new members.
13820 * linux-x86-64-low.c (target_regsets): Add new kind
13823 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
13825 From Martin Pool <mbp@samba.org>:
13826 * server.c (gdbserver_usage): New function.
13829 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
13831 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
13832 stop_at -> stop_pc.
13834 2002-05-04 Andrew Cagney <ac131313@redhat.com>
13836 * Makefile.in: Remove obsolete code.
13838 2002-04-24 Michal Ludvig <mludvig@suse.cz>
13840 * linux-low.c (regsets_fetch_inferior_registers),
13841 (regsets_store_inferior_registers): Removed cast to int from
13843 * regcache.h: Added declaration of struct inferior_info.
13845 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
13847 * inferiors.c (struct inferior_info): Add regcache_data.
13848 (add_inferior): Call create_register_cache.
13849 (clear_inferiors): Call free_register_cache.
13850 (inferior_regcache_data, set_inferior_regcache_data): New functions.
13851 * regcache.c (struct inferior_regcache_data): New.
13852 (registers): Remove.
13853 (get_regcache): New function.
13854 (create_register_cache, free_register_cache): New functions.
13855 (set_register_cache): Don't initialize the register cache here.
13856 (registers_to_string, registers_from_string, register_data): Call
13858 * regcache.h: Add prototypes.
13859 * server.h: Likewise.
13861 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
13863 * mem-break.c: New file.
13864 * mem-break.h: New file.
13865 * Makefile.in: Add mem-break.o rule; update server.h
13867 * inferiors.c (struct inferior_info): Add target_data
13869 (clear_inferiors): Free target_data member if set.
13870 (inferior_target_data, set_inferior_target_data): New functions.
13871 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
13872 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
13873 * linux-low.c (linux_bp_reinsert): New variable.
13874 (struct inferior_linux_data): New.
13875 (linux_create_inferior): Use set_inferior_target_data.
13876 (linux_attach): Likewise. Call add_inferior.
13877 (linux_wait_for_one_inferior): New function.
13878 (linux_wait): Call it.
13879 (linux_write_memory): Add const.
13880 (initialize_low): Call set_breakpoint_data.
13881 * linux-low.h (struct linux_target_ops): Add breakpoint
13883 * server.c (attach_inferior): Remove extra add_inferior
13885 * server.h: Include mem-break.h. Update inferior.c
13887 * target.c (read_inferior_memory)
13888 (write_inferior_memory): New functions.
13889 * target.h (read_inferior_memory)
13890 (write_inferior_memory): Change macros to prototypes.
13891 (struct target_ops): Update comments. Add const to write_memory
13894 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
13896 * linux-low.c (usr_store_inferior_registers): Support
13897 registers which are allowed to fail to store.
13898 * linux-low.h (linux_target_ops): Likewise.
13899 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
13900 (ppc_cannot_store_register): FPSCR may not be storable.
13902 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
13904 * server.h: Include <string.h> if HAVE_STRING_H.
13905 * ChangeLog: Correct paths in last ChangeLog entry.
13907 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
13909 * linux-low.h: Remove obsolete prototypes.
13910 (struct linux_target_ops): New.
13911 (extern the_low_target): New.
13912 * linux-low.c (num_regs, regmap): Remove declarations.
13913 (register_addr): Use the_low_target explicitly.
13914 (fetch_register): Likewise.
13915 (usr_fetch_inferior_registers): Likewise.
13916 (usr_store_inferior_registers): Likewise.
13917 * linux-arm-low.c (num_regs): Remove.
13918 (arm_num_regs): Define.
13919 (arm_regmap): Renamed from regmap, made static.
13920 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
13922 (arm_cannot_store_register): Renamed from cannot_store_register,
13924 (the_low_target): New.
13925 * linux-i386-low.c (num_regs): Remove.
13926 (i386_num_regs): Define.
13927 (i386_regmap): Renamed from regmap, made static.
13928 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
13930 (i386_cannot_store_register): Renamed from cannot_store_register,
13932 (the_low_target): New.
13933 * linux-ia64-low.c (num_regs): Remove.
13934 (ia64_num_regs): Define.
13935 (ia64_regmap): Renamed from regmap, made static.
13936 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
13938 (ia64_cannot_store_register): Renamed from cannot_store_register,
13940 (the_low_target): New.
13941 * linux-m68k-low.c (num_regs): Remove.
13942 (m68k_num_regs): Define.
13943 (m68k_regmap): Renamed from regmap, made static.
13944 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
13946 (m68k_cannot_store_register): Renamed from cannot_store_register,
13948 (the_low_target): New.
13949 * linux-mips-low.c (num_regs): Remove.
13950 (mips_num_regs): Define.
13951 (mips_regmap): Renamed from regmap, made static.
13952 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
13954 (mips_cannot_store_register): Renamed from cannot_store_register,
13956 (the_low_target): New.
13957 * linux-ppc-low.c (num_regs): Remove.
13958 (ppc_num_regs): Define.
13959 (ppc_regmap): Renamed from regmap, made static.
13960 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
13962 (ppc_cannot_store_register): Renamed from cannot_store_register,
13964 (the_low_target): New.
13965 * linux-s390-low.c (num_regs): Remove.
13966 (s390_num_regs): Define.
13967 (s390_regmap): Renamed from regmap, made static.
13968 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
13970 (s390_cannot_store_register): Renamed from cannot_store_register,
13972 (the_low_target): New.
13973 * linux-sh-low.c (num_regs): Remove.
13974 (sh_num_regs): Define.
13975 (sh_regmap): Renamed from regmap, made static.
13976 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
13978 (sh_cannot_store_register): Renamed from cannot_store_register,
13980 (the_low_target): New.
13981 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
13982 (the_low_target): New.
13984 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
13986 * Makefile.in: Add stamp-h target.
13987 * configure.in: Create stamp-h.
13988 * configure: Regenerated.
13990 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
13992 * inferiors.c: New file.
13993 * target.c: New file.
13994 * target.h: New file.
13995 * Makefile.in: Add target.o and inferiors.o. Update
13997 * linux-low.c (inferior_pid): New static variable,
13998 moved from server.c.
13999 (linux_create_inferior): Renamed from create_inferior.
14000 Call add_inferior. Return 0 on success instead of a PID.
14001 (linux_attach): Renamed from myattach.
14002 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
14003 (linux_thread_alive): Renamed from mythread_alive.
14004 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
14006 (linux_resume): Renamed from myresume. Add missing ``return 0''.
14007 (regsets_store_inferior_registers): Correct error message.
14008 Add missing ``return 0''.
14009 (linux_fetch_registers): Renamed from fetch_inferior_registers.
14010 (linux_store_registers): Renamed from store_inferior_registers.
14011 (linux_read_memory): Renamed from read_inferior_memory.
14012 (linux_write_memory): Renamed from write_inferior_memory.
14013 (linux_target_ops): New structure.
14014 (initialize_low): Call set_target_ops ().
14015 * remote-utils.c (unhexify): New function.
14016 (hexify): New function.
14017 (input_interrupt): Send signals to ``signal_pid''.
14018 * server.c (inferior_pid): Remove.
14019 (start_inferior): Update create_inferior call.
14020 (attach_inferior): Call add_inferior.
14021 (handle_query): New function.
14022 (main): Call handle_query for `q' packets.
14023 * server.h: Include "target.h". Remove obsolete prototypes.
14024 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
14026 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
14028 * Makefile.in: Add WARN_CFLAGS. Update configury
14030 * configure.in: Check for <string.h>
14031 * configure: Regenerate.
14032 * config.in: Regenerate.
14033 * gdbreplay.c: Include needed system headers.
14034 (remote_open): Remove strchr prototype.
14035 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
14036 * regcache.c (supply_register): Change buf argument to const void *.
14037 (supply_register_by_name): Likewise.
14038 (collect_register): Change buf argument to void *.
14039 (collect_register_by_name): Likewise.
14040 * regcache.h: Add missing prototypes.
14041 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
14042 * server.c (handle_query): New function.
14043 (attached): New static variable, moved out of main.
14044 (main): Quiet longjmp clobber warnings.
14045 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
14046 * utils.c (error): Remove NORETURN.