remote: one struct remote_state per struct remote_target
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
CommitLineData
1d75a658
PFC
12018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2
3 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
4 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5 mode. Call collect_register_by_name with vscr using
6 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
7 (ppc_store_vrregset): Add and set vscr_offset variable as in
8 ppc_fill_vrregset. Call supply_register_by_name with vscr using
9 vscr_offset.
10
d078308a
PFC
112018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12
13 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
14 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
15 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
16
7273b5fc
PFC
172018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
18
19 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
20 (ppc_store_vsxregset): Likewise.
21 (ppc_fill_vrregset): Likewise.
22 (ppc_store_vrregset): Likewise.
23 (ppc_fill_evrregset): Likewise.
24 (ppc_store_evrregset): Likewise.
25 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
26 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
27 needed.
28
2e077f5e
PFC
292018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
30
31 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
32 wordsize of the inferior. Call ppc_linux_target_wordsize.
33
bd64614e
PFC
342018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
35
36 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
37 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
38 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
39 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
40 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
41 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
42 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
43 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
44 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
45 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
46 (tdesc_powerpc_e500l): Remove.
47 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
48 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
49 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
50 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
51 linux-ppc-tdesc.h.
52 (ppc_arch_setup): Remove target description matching code. Fill a
53 ppc_linux_features struct and call ppc_linux_match_description
54 with it.
55
75d74cca
MR
562018-05-22 Maciej W. Rozycki <macro@mips.com>
57
58 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
59 width of the requested register exceeds the width of the
60 `ptrace' data type.
61 (mips_cannot_store_register): Likewise.
62
e4439e43
MR
632018-05-21 Maciej W. Rozycki <macro@mips.com>
64
65 * linux-mips-low.c (mips_fetch_register): New function. Update
66 preceding comment.
67 (mips_store_gregset): Supply 0 rather than $restart for $zero.
68 (the_low_target): Wire `mips_fetch_register'.
69
55271bf9
JB
702018-05-10 Joel Brobecker <brobecker@adacore.com>
71
72 * lynx-i386-low.c (LYNXOS_178): New macro.
73 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
74 the layout on LynxOS-178.
75 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
76 handle floating point registers that are not supported by
77 LynxOS-178.
78
1a34f210
TT
792018-05-10 Tom Tromey <tom@tromey.com>
80
81 * configure: Rebuild.
82
190852c8
JB
832018-05-10 Joel Brobecker <brobecker@adacore.com>
84
85 PR server/23158:
86 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
87 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
88 Use it to set the expedite_regs field in the given tdesc.
89 * x86-tdesc.h: New file.
90 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
91 Adjust following the addition of the new expedite_regs parameter
92 to init_target_desc.
93 * linux-tic6x-low.c (tic6x_read_description): Likewise.
94 * linux-x86-tdesc.c: #include "x86-tdesc.h".
95 (i386_linux_read_description, amd64_linux_read_description):
96 Adjust following the addition of the new expedite_regs parameter
97 to init_target_desc.
98 * lynx-i386-low.c: #include "x86-tdesc.h".
99 (lynx_i386_arch_setup): Adjust following the addition of the new
100 expedite_regs parameter to init_target_desc.
101 * nto-x86-low.c: #include "x86-tdesc.h".
102 (nto_x86_arch_setup): Adjust following the addition of the new
103 expedite_regs parameter to init_target_desc.
104 * win32-i386-low.c: #include "x86-tdesc.h".
105 (i386_arch_setup): Adjust following the addition of the new
106 expedite_regs parameter to init_target_desc.
107
7dbac825
JB
1082018-05-10 Joel Brobecker <brobecker@adacore.com>
109
110 PR server/23158:
111 * win32-low.c (win32_create_inferior): Add call to my_wait
112 setting last_status global.
113
906994d9
JB
1142018-05-10 Joel Brobecker <brobecker@adacore.com>
115
116 PR server/23158:
117 * win32-low.c (create_process): Only call gdb_tilde_expand if
118 inferior_cwd is not NULL.
119
8ee22052
AB
1202018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
121
122 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
123 registers to the cache if their values have changed.
124 (i387_xsave_to_cache): Provide default values for x87 control
125 registers when these features are available, but disabled.
126 * regcache.c (supply_register_by_name_zeroed): New function.
127 * regcache.h (supply_register_by_name_zeroed): Declare new
128 function.
129
aff689d3
TT
1302018-05-07 Tom Tromey <tom@tromey.com>
131
132 * configure: Rebuild.
133
85e26832
TT
1342018-05-04 Tom Tromey <tom@tromey.com>
135
136 * configure: Rebuild.
137
a3b60e45
JK
1382018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
139 Pedro Alves <palves@redhat.com>
140
141 * linux-aarch64-low.c (aarch64_stopped_data_address):
142 Likewise.
143
632e107b
TT
1442018-04-27 Tom Tromey <tom@tromey.com>
145
146 * configure: Rebuild.
147
458412c3
TT
1482018-04-23 Tom Tromey <tom@tromey.com>
149
150 * configure: Rebuild.
151
f31c089e
SM
1522018-04-19 Simon Marchi <simon.marchi@ericsson.com>
153
154 * Makefile.in (depcomp): Add "..".
155 (all_deps_files): New and use it.
156
b319b098
AH
1572018-04-18 Alan Hayward <alan.hayward@arm.com>
158
159 * configure.srv (aarch64*-*-linux*): Don't include xml.
160 (i[34567]86-*-cygwin*): Likewise.
161 (i[34567]86-*-linux*): Likewise.
162 (i[34567]86-*-lynxos*): Likewise.
163 (i[34567]86-*-mingw32ce*): Likewise.
164 (i[34567]86-*-mingw*): Likewise.
165 (i[34567]86-*-nto*): Likewise.
166 (tic6x-*-uclinux): Likewise.
167 (x86_64-*-linux*): Likewise.
168 (x86_64-*-mingw*): Likewise.
169 (x86_64-*-cygwin*): Likewise.
170
3b74854b
AH
1712018-04-18 Alan Hayward <alan.hayward@arm.com>
172
173 * tdesc.c: Remove xml parameter.
174
e98577a9
AH
1752018-04-18 Alan Hayward <alan.hayward@arm.com>
176
177 * server.c (get_features_xml): Remove cast.
178 * tdesc.c (void target_desc::accept): Fill in function.
179 (tdesc_get_features_xml): Remove old xml creation.
180 (print_xml_feature::visit_pre): Add xml vistor.
181 * tdesc.h (struct target_desc): Make xmltarget mutable.
182 (tdesc_get_features_xml): Remove declaration.
183
d278f585
AH
1842018-04-18 Alan Hayward <alan.hayward@arm.com>
185
186 * tdesc.c (tdesc_architecture_name): Add new function.
187 (tdesc_osabi_name): Likewise.
188 (tdesc_get_features_xml): Use new functions.
189
eee8a18d
AH
1902018-04-18 Alan Hayward <alan.hayward@arm.com>
191
192 * tdesc.c (tdesc_create_flags): Remove.
193 (tdesc_add_flag): Likewise.
194 (tdesc_named_type): Likewise.
195 (tdesc_create_union): Likewise.
196 (tdesc_create_struct): Likewise.
197 (tdesc_create_vector): Likewise.
198 (tdesc_add_bitfield): Likewise.
199 (tdesc_add_field): Likewise.
200 (tdesc_set_struct_size): Likewise.
201
82ec9bc7
AH
2022018-04-18 Alan Hayward <alan.hayward@arm.com>
203
204 * tdesc.c (~target_desc): Remove implictly deleted items.
205 (init_target_desc): Iterate all features.
206 (tdesc_get_features_xml): Use vector.
207 (tdesc_create_feature): Create feature.
208 * tdesc.h (tdesc_feature) Remove
209 (target_desc): Add features.
210
ea3e7d71
AH
2112018-04-18 Alan Hayward <alan.hayward@arm.com>
212
213 * Makefile.in: Add common/tdesc.c
214 * tdesc.c (init_target_desc): init all reg_defs from register
215 vector.
216 (tdesc_create_reg): Create tdesc_reg.
217 * tdesc.h (tdesc_feature): Add register vector.
218
17d08cd4
SM
2192018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
220
221 * tdesc.h (struct target_desc) <features>: Change type to
222 std::vector<std::string>.
223 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
224 changes.
225 (tdesc_get_features_xml): Likewise.
226 (tdesc_create_feature): Likewise.
227
5cd3e386
AH
2282018-03-26 Alan Hayward <alan.hayward@arm.com>
229
230 * regcache.c (find_register_by_number): Return a ref.
231 (find_regno): Use references.
232 (register_size): Likewise.
233 (register_data): Likewise.
234 * tdesc.c (target_desc::~target_desc): Remove free calls.
235 (target_desc::operator==): Use std::vector compare.
236 (init_target_desc): Use reference.
237 (tdesc_create_reg): Use reg constructors.
238 * tdesc.h (struct target_desc): Replace pointer with object.
239
dff7492c
AH
2402018-03-23 Alan Hayward <alan.hayward@arm.com>
241
242 * regcache.c (find_register_by_number): Make static.
243 (find_regno): Use find_register_by_number
244 * regcache.h (struct reg): Remove declaration.
245
d80e5242
AH
2462018-03-23 Alan Hayward <alan.hayward@arm.com>
247
248 * tdesc.c (target_desc::~target_desc): Move to here.
249 (target_desc::operator==): Likewise.
250 * tdesc.h (target_desc::~target_desc): Move from here.
251 (target_desc::operator==): Likewise.
252
f69c5afb
AA
2532018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
254
255 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
256
ce29f843
AA
2572018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
258
259 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
260 S390_TDESC_GS.
261 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
262 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
263 and init_registers_s390_gs_linux64.
264
c49bd90b
AA
2652018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
266
267 * linux-s390-low.c (s390_fill_gs): Remove function.
268 (s390_fill_gsbc): Remove function.
269 (s390_regsets): Set fill functions for the guarded storage regsets
270 to NULL.
271
7edb9bd3
AA
2722018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
273
274 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
275 the word size. Add comment.
276 (s390_get_wordsize): New function.
277 (s390_arch_setup): No longer select a temporary tdesc to fetch the
278 pswm with it. Instead, use s390_get_wordsize to determine the
279 word size first and derive the correct tdesc from that directly.
280
39be3c7e
SM
2812018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
282
283 * Makefile.in: Include silent-rules.mk.
284 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
285 (COMPILE): Add ECHO_CXX.
286 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
287 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
288 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
289 (version-generated.c): Add ECHO_GEN.
290 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
291 (IPAGENT_COMPILE): Add ECHO_CXX.
292 (%-generated.c): Add ECHO_REGDAT.
293
3ae9ce5d
TT
2942018-03-14 Tom Tromey <tom@tromey.com>
295
296 PR cli/14977:
297 * ax.c (ax_printf): Special case for NULL.
298
e6a58aa8
SM
2992018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
300
301 * linux-low.c (linux_qxfer_libraries_svr4): Use
302 xml_escape_text_append.
303
f6e8a41e
SM
3042018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
305
306 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
307
b9671caf
SM
3082018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
309
310 * server.c (handle_general_set): Remove unnecessary xstrdup.
311
e80aaf61
SM
3122018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
313
314 * server.c (parse_debug_format_options): Adjust to
315 delim_string_to_char_ptr_vec changes.
316 * thread-db.c (thread_db_load_search): Adjust to
317 dirnames_to_char_ptr_vec changes.
318
b1223e78
MM
3192018-03-01 Markus Metzger <markus.t.metzger@intel.com>
320
321 * target.h (target_enable_btrace, target_disable_btrace)
322 (target_read_btrace, target_read_btrace_conf): Turn macro into
323 inline function. Throw error if target method is not defined.
324 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
325 check for btrace target method. Be prepared to handle exceptions
326 from btrace target methods.
327
81561546
SDJ
3282018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
329
330 * server.c (captured_main): Change order of error message printed
331 when the current working directory cannot be found.
332
25e3c82c
SDJ
3332018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
334
335 * server.c: Include "filenames.h" and "pathstuff.h".
336 (program_name): Delete variable.
337 (program_path): New anonymous class.
338 (get_exec_wrapper): Use "program_path" instead of
339 "program_name".
340 (handle_v_run): Likewise.
341 (captured_main): Likewise.
342 (process_serial_event): Likewise.
343
b4987c95
SDJ
3442018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
345
346 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
347 (OBJS): Add "pathstuff.o".
348 * server.c (current_directory): New global variable.
349 (captured_main): Initialize "current_directory".
350
f46cd62a
AH
3512018-02-26 Alan Hayward <alan.hayward@arm.com>
352
353 * tdesc.c: Use common/tdesc.h.
354 * tdesc.h: Likewise.
355
a543c5ca
AH
3562018-02-20 Alan Hayward <alan.hayward@arm.com>
357 Simon Marchi <simon.marchi@ericsson.com>
358
359 * Makefile.in: Switch order of make rules.
360
b5884fa7
AH
3612018-02-19 Alan Hayward <alan.hayward@arm.com>
362
363 * Makefile.in: Add common directory in build.
364 * configure.ac: Add common reference.
365 * configure: Regenerate.
366
de6242d3
MM
3672018-02-09 Markus Metzger <markus.t.metzger@intel.com>
368
369 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
370 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
371 * spu-low.c (spu_target_ops): Likewise.
372 * win32-low.c (win32_target_ops): Likewise.
373 * server.c (supported_btrace_packets): Report packets unconditionally.
374 * target.h (target_ops) <supports_btrace>: Remove.
375 (target_supports_btrace): Remove.
376
9ee23a85
MM
3772018-02-09 Markus Metzger <markus.t.metzger@intel.com>
378
379 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
380 (handle_btrace_disable): Change return type to void. Use exceptions
381 to report errors.
382 (handle_btrace_general_set): Catch exception and copy message to
383 return message.
384
8ce47547
TT
3852018-02-08 Tom Tromey <tom@tromey.com>
386
387 * linux-low.c (install_software_single_step_breakpoints): Use
388 make_scoped_restore.
389 * inferiors.c (make_cleanup_restore_current_thread): Remove.
390 (do_restore_current_thread_cleanup): Remove.
391 * gdbthread.h (make_cleanup_restore_current_thread): Don't
392 declare.
393
45dd3607
TT
3942018-02-08 Tom Tromey <tom@tromey.com>
395
396 * mem-break.c (set_raw_breakpoint_at): Use
397 gdb::unique_xmalloc_ptr.
398
e671cd59
PA
3992018-01-30 Pedro Alves <palves@redhat.com>
400
401 PR gdb/13211
402 * target.c (target_terminal::terminal_state): Rename to ...
403 (target_terminal::m_terminal_state): ... this.
404
a0aad537
JC
4052018-01-19 James Clarke <jrtc27@jrtc27.com>
406
407 * linux-low.c (handle_extended_wait): Surround call to
408 thread_db_notice_clone with #ifdef USE_THREAD_DB.
409
4d9b86e1
SM
4102018-01-17 Simon Marchi <simon.marchi@ericsson.com>
411
412 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
413 linux_ptrace_attach_fail_reason_string now returning an
414 std::string.
415 (linux_attach): Likewise.
416 * thread-db.c (attach_thread): Likewise.
417
f517c180
EA
4182018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
419
420 PR gdb/21559
421 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
422 checking for fs_base/gs_base fields in struct user_regs_struct.
423 * configure: Regenerate.
424
9a70f35c
YQ
4252018-01-16 Yao Qi <yao.qi@linaro.org>
426
427 PR gdb/18749
428 * linux-low.c (fetch_register): Call supply_register instead of
429 error.
430
605fd3c6
YQ
4312018-01-08 Yao Qi <yao.qi@linaro.org>
432 Simon Marchi <simon.marchi@ericsson.com>
433
434 * Makefile.in (OBS): Remove selftest.o.
435 * configure.ac: Set srv_selftest_objs if $development is true.
436 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
437 * configure: Re-generated.
438 * server.c (captured_main): Wrap variable selftest_filter with
439 GDB_SELF_TEST.
440
2cc05030
SM
4412018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
442
443 * server.c (parse_debug_format_options): Return std::string.
444 (handle_monitor_command, captured_main): Adjust.
445
e379cee6
PA
4462018-01-05 Pedro Alves <palves@redhat.com>
447
448 PR gdb/18653
449 * server.c (captured_main): Pass quiet=false to
450 save_original_signals_state.
451
82e1e79a
JB
4522018-01-01 Joel Brobecker <brobecker@adacore.com>
453
454 * gdbreplay.c (gdbreplay_version): Update copyright year in
455 version message.
456 * server.c (gdbserver_version): Likewise.
457
8e481c3b
TT
4582017-12-08 Tom Tromey <tom@tromey.com>
459
460 * ax.c (ax_printf): Update.
461
a8806230
YQ
4622017-12-07 Yao Qi <yao.qi@linaro.org>
463
464 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
465 aarch64_linux_read_description.
466 * linux-amd64-ipa.c (idx2mask): New array.
467 (get_ipa_tdesc): Move idx2mask out.
468 (initialize_low_tracepoint): Initialize target descriptions.
469 * linux-i386-ipa.c (idx2mask): New array.
470 (get_ipa_tdesc): Move idx2mask out.
471 (initialize_low_tracepoint): Initialize target descriptions.
472
d4a0e8b5
SM
4732017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
474
475 * tdesc.c (struct tdesc_type): Change return type.
476 (tdesc_add_flag): Change parameter type.
477 (tdesc_add_bitfield): Likewise.
478 (tdesc_add_field): Likewise.
479 (tdesc_set_struct_size): Likewise.
480
798a7429
SM
4812017-12-05 Simon Marchi <simon.marchi@ericsson.com>
482
483 * regcache.c (registers_to_string): Remove unused variable.
484
c0e15c9b
SM
4852017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
486
487 * inferiors.c (for_each_inferior_with_data): Remove.
488 * inferiors.h (for_each_inferior_with_data): Remove.
489 * server.c (handle_qxfer_threads_worker): Change parameter type.
490 (handle_qxfer_threads_proper): Use for_each_thread.
491
f0045347
SM
4922017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
493
494 * inferiors.c (for_each_inferior): Remove.
495 (clear_inferiors): Use for_each_thread.
496 * inferiors.h (for_each_inferior): Remove.
497 * linux-low.c (linux_wait_for_event_filtered): Use
498 for_each_thread.
499 (linux_stabilize_threads): Likewise.
500 * regcache.c (regcache_release): Likewise.
501 * server.c (gdb_wants_all_threads_stopped): Likewise.
502 (clear_pending_status_callback): Remove.
503 (handle_status): Use for_each_thread.
504 (captured_main): Likewise.
505 * win32-low.c (child_init_thread_list): Likewise.
506 (win32_clear_inferiors): Likewise.
507 (fake_breakpoint_event): Likewise.
508
9521758b
SM
5092017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
510
511 * inferiors.h (find_inferior): Remove.
512 * inferiors.c (find_inferior): Remove.
513
8f86d7aa
SM
5142017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
515
516 * linux-low.c (resume_status_pending_p): Update comment.
517 (need_step_over_p): Update comment.
518
e2b44075
SM
5192017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
520
521 * linux-low.c (proceed_one_lwp): Return void, change parameter
522 type.
523 (unsuspend_and_proceed_one_lwp): Likewise.
524 (proceed_all_lwps): Use for_each_thread.
525 (unstop_all_lwps): Likewise.
526
c80825ff
SM
5272017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
528
529 * linux-low.c (linux_resume_one_thread): Return void, take
530 parameter directly.
531 (linux_resume): Use for_each_thread.
532
df3e4dbe
SM
5332017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
534
535 * linux-low.c (send_sigstop_callback): Return void, change
536 parameter type. Rename to...
537 (send_sigstop): ... this.
538 (suspend_and_send_sigstop_callback): Return void, change parameter
539 type. Rename to...
540 (suspend_and_send_sigstop): ... this.
541 (stop_all_lwps): Use for_each_thread.
542
5a6b0a41
SM
5432017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
544
545 * linux-low.c (lwp_running): Return bool, remove unused
546 argument.
547 (linux_stabilize_threads): Use find_thread.
548
39a64da5
SM
5492017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
550
551 * linux-low.c (select_singlestep_lwp_callback): Remove.
552 (count_events_callback): Remove.
553 (select_event_lwp_callback): Remove.
554 (select_event_lwp): Use find_thread/for_each_thread.
555
a1385b7b
SM
5562017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
557
558 * linux-low.c (not_stopped_callback): Return bool, take filter
559 argument directly.
560 (linux_wait_for_event_filtered): Use find_thread.
561 (linux_wait_1): Likewise.
562
454296a2
SM
5632017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
564
565 * linux-low.c (same_lwp): Remove.
566 (find_lwp_pid): Use find_thread.
567
6b2a85da
SM
5682017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
569
570 * linux-low.c (delete_lwp_callback): Remove.
571 (linux_mourn): Use for_each_thread.
572
798a38e8
SM
5732017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
574
575 * linux-low.c (linux_detach_lwp_callback): Return void, remove
576 args parameter, don't check for pid.
577 (linux_detach): Use for_each_thread.
578
e4eb0dec
SM
5792017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
580
581 * linux-low.c (struct counter): Remove.
582 (second_thread_of_pid_p): Remove.
583 (last_thread_of_process_p): Use find_thread.
584
83e1b6c1
SM
5852017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
586
587 * inferiors.c (find_inferior_in_random): Remove.
588 * inferiors.h (find_inferior_in_random): Remove.
589 * linux-low.c (status_pending_p_callback): Return bool, accept
590 parameter ptid directly.
591 (linux_wait_for_event_filtered): Use find_thread_in_random.
592 (linux_wait_1): Likewise.
593
8dc7b443
SM
5942017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
595
596 * inferiors.c (find_inferior_id): Remove.
597 (find_thread_ptid): Move implemention from find_inferior_id to
598 here.
599 * inferiors.h (find_inferior_id): Remove.
600 * server.c (handle_status): Use find_thread_ptid.
601 (process_serial_event): Likewise.
602 * thread-db.c (find_one_thread): Likewise.
603 (thread_db_thread_handle): Likewise.
604 * win32-low.c (thread_rec): Likewise.
605 (child_delete_thread): Likewise.
606 (win32_thread_alive): Likewise.
607 (get_child_debug_event): Likewise.
608
da25033c
SM
6092017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
610
611 * linux-mips-low.c (update_watch_registers_callback): Return
612 void, remove pid_p parameter, don't check for pid.
613 (mips_insert_point, mips_remove_point): Use for_each_thread.
614
c91bb56b
SM
6152017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
616
617 * lynx.low (lynx_delete_thread_callback): Remove.
618 (lynx_mourn): Use for_each_thread.
619
634a3254
SM
6202017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
621
622 * regcache.c (regcache_invalidate_one): Remove.
623 (regcache_invalidate_pid): use for_each_thread.
624
41272101
TT
6252017-11-26 Tom Tromey <tom@tromey.com>
626
627 * linux-low.c (linux_create_inferior): Update.
628
f5291a6f
UW
6292017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
630
631 * spu-low.c (spu_create_inferior): Fix typo in argument name.
632
6654d750
AH
6332017-11-24 Alan Hayward <alan.hayward@arm.com>
634
635 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
636 * linux-aarch64-low.c (initialize_low_arch): Call init func.
637 * linux-aarch64-tdesc-selftest.c: New file.
638 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
639
6402017-11-24 Alan Hayward <alan.hayward@arm.com>
641
642 * configure.srv: Add new file.
643 * linux-aarch64-low.c (initialize_low_arch): Call init func.
644 * linux-aarch64-tdesc-selftest.c: New file.
645 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
646
49bdb7ee
AH
6472017-11-24 Alan Hayward <alan.hayward@arm.com>
648
649 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
650 * linux-aarch64-low.c (initialize_low_arch): Remove init.
651 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
652
d6d7ce56
AH
6532017-11-24 Alan Hayward <alan.hayward@arm.com>
654
655 * configure.srv: Add new files.
656 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
657 aarch64_linux_read_description.
658 * linux-aarch64-low.c (aarch64_linux_read_description):
659 Merge with aarch64_arch_setup.
660 (aarch64_arch_setup): Call aarch64_linux_read_description.
661 * linux-aarch64-tdesc.c: New file.
662 * linux-aarch64-tdesc.h: New file.
663
506fe5f4
YQ
6642017-11-24 Yao Qi <yao.qi@linaro.org>
665
666 * configure.srv: Set $srv_regobj for tic6x-linux.
667 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
668 (tic6x_read_description): Move some code to tic6x_arch_setup.
669 (tic6x_tdesc_test): New function.
670 (initialize_low_arch): Call selftests::register_test.
671
29f9a567
YQ
6722017-11-22 Yao Qi <yao.qi@linaro.org>
673
674 * remote-utils.c (prepare_resume_reply): Use memcpy.
675
578290ec
SM
6762017-11-19 Simon Marchi <simon.marchi@ericsson.com>
677
678 * linux-low.c (kill_one_lwp_callback): Return void, take
679 argument directly, don't filter on pid.
680 (linux_kill): Use for_each_thread.
681
eca55aec
SM
6822017-11-19 Simon Marchi <simon.marchi@ericsson.com>
683
684 * linux-low.c (need_step_over_p): Return bool, remove dummy
685 argument.
686 (linux_resume, proceed_all_lwps): Use find_thread.
687
25c28b4d
SM
6882017-11-19 Simon Marchi <simon.marchi@ericsson.com>
689
690 * linux-low.c (resume_status_pending_p): Return bool, remove
691 flag_p argument.
692 (linux_resume): Use find_thread.
693
5fdda392
SM
6942017-11-19 Simon Marchi <simon.marchi@ericsson.com>
695
696 * linux-low.c (struct thread_resume_array): Remove.
697 (linux_set_resume_request): Return void, take arguments
698 directly.
699 (linux_resume): Use for_each_thread.
700
fcb056a5
SM
7012017-11-19 Simon Marchi <simon.marchi@ericsson.com>
702
703 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
704 return bool, remove data argument.
705 (linux_stabilize_threads): Use find_thread.
706
139720c5
SM
7072017-11-19 Simon Marchi <simon.marchi@ericsson.com>
708
709 * linux-low.c (unsuspend_one_lwp): Remove.
710 (unsuspend_all_lwps): Use for_each_thread, inline code from
711 unsuspend_one_lwp.
712
6d1e5673
SM
7132017-11-19 Simon Marchi <simon.marchi@ericsson.com>
714
715 * gdbthread.h (find_thread): Add overload with ptid_t filter.
716 * linux-low.c (struct iterate_over_lwps_args): Remove.
717 (iterate_over_lwps_filter): Remove.
718 (iterate_over_lwps): Use find_thread.
719
bbf550d5
SM
7202017-11-19 Simon Marchi <simon.marchi@ericsson.com>
721
722 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
723 (linux_handle_new_gdb_connection): Use for_each_thread, inline
724 code from reset_lwp_ptrace_options_callback.
725
00192f77
SM
7262017-11-19 Simon Marchi <simon.marchi@ericsson.com>
727
728 * linux-arm-low.c (struct update_registers_data): Remove.
729 (update_registers_callback): Return void, take arguments
730 directly, don't check thread's pid.
731 (arm_insert_point, arm_remove_point): Use for_each_thread.
732
2bee2b6c
SM
7332017-11-19 Simon Marchi <simon.marchi@ericsson.com>
734
735 * win32-low.c (continue_one_thread): Return void, take argument
736 directly.
737 (child_continue): Use for_each_thread.
738
0b360f19
SM
7392017-11-19 Simon Marchi <simon.marchi@ericsson.com>
740
741 * win32-i386-low.c (update_debug_registers_callback): Rename
742 to ...
743 (update_debug_registers): ... this, return void, remove pid_p arg.
744 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
745
f27866ba
SM
7462017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
747
748 * inferiors.h (struct process_info): Add constructor, initialize
749 fields..
750 <syscalls_to_catch>: Change type to std::vector<int>.
751 * inferiors.c (add_process): Allocate process_info with new.
752 (remove_process): Free process_info with delete.
753 * linux-low.c (handle_extended_wait): Adjust.
754 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
755 * server.c (handle_general_set): Adjust.
756
e849ea89
PA
7572017-11-16 Pedro Alves <palves@redhat.com>
758
759 * remote-utils.c (remote_close): Block SIGIO signals instead of
760 uninstalling the SIGIO handler.
761
1d0aa65c
AH
7622017-11-16 Alan Hayward <alan.hayward@arm.com>
763
764 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
765
3491a34c
YQ
7662017-11-16 Yao Qi <yao.qi@linaro.org>
767
768 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
769 (tic6x_store_gregset): Likewise.
770 (tic6x_usrregs_info): Move it up.
771
a602f924
AH
7722017-11-15 Alan Hayward <alan.hayward@arm.com>
773
774 * Makefile.in: Update arch rules.
775 * configure.srv: Explicitly mark arch/ files.
776
5616b6c3
AS
7772017-11-13 Andreas Schwab <schwab@suse.de>
778
779 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
780 function.
781 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
782
d1928160
PA
7832017-11-06 Pedro Alves <palves@redhat.com>
784
785 * config.in, configure: Regenerate.
786
bac608e7
SM
7872017-10-27 Simon Marchi <simon.marchi@ericsson.com>
788
789 * target.c (struct thread_search): Remove.
790 (thread_search_callback): Remove.
791 (prepare_to_access_memory): Use for_each_thread instead of
792 find_inferior. Inline code from thread_search_callback.
793
eaddb425
SM
7942017-10-27 Simon Marchi <simon.marchi@ericsson.com>
795
796 * server.c (struct visit_actioned_threads_data): Remove.
797 (visit_actioned_threads): Change prototype to take arguments
798 directly.
799 (resume): Use find_thread instead of find_inferior.
800
99078d34
SM
8012017-10-27 Simon Marchi <simon.marchi@ericsson.com>
802
803 * server.c (queue_stop_reply_callback): Change prototype, return
804 void.
805 (find_status_pending_thread_callback): Remove.
806 (handle_status): Replace find_inferior with find_thread and
807 for_each_thread.
808
cc628f3d
AH
8092017-10-25 Alan Hayward <alan.hayward@arm.com>
810
811 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
812 with REGNO.
813 (aarch64_store_gregset): Likewise.
814 (aarch64_fill_fpregset): Likewise.
815 (aarch64_store_fpregset): Likewise.
816
4d3bb80e
SM
8172017-10-21 Simon Marchi <simon.marchi@ericsson.com>
818
819 * gdbthread.h (find_thread, for_each_thread): New functions.
820 * inferiors.c (thread_of_pid): Remove.
821 (find_any_thread_of_pid): Use find_thread.
822 * linux-low.c (num_lwps): Use for_each_thread.
823
7a7cdfa0
YQ
8242017-10-17 Yao Qi <yao.qi@linaro.org>
825
826 * Makefile.in: Remove one rule.
827 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
828
e675d170
YQ
8292017-10-17 Yao Qi <yao.qi@linaro.org>
830
831 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
832 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
833
7eb4e0f9
YQ
8342017-10-17 Yao Qi <yao.qi@linaro.org>
835
836 * configure.srv: Rename arm.o with arch/arm.o.
837
60d6cfc9
YQ
8382017-10-17 Yao Qi <yao.qi@linaro.org>
839
840 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
841 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
842 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
843 (arch-i386.o, arch-amd64.o): Remove rules.
844 (arch/%.o): New rule.
845 Update POSTCOMPILE and COMPILE.pre.
846 * configure.ac: Invoke AC_CONFIG_COMMANDS.
847 * configure: Re-generated.
848 * configure.srv: Replace arch-i386.o with arch/i386.o.
849 Replace arch-amd64.o with arch/amd64.o.
850
5bfda255
YQ
8512017-10-16 Yao Qi <yao.qi@linaro.org>
852
853 * configure: Regenerated.
854
9c80ecd6
SM
8552017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
856
857 * inferiors.h: (struct inferior_list): Remove.
858 (struct inferior_list_entry); Remove.
859 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
860 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
861 get_first_inferior): Remove.
862 (for_each_inferior, for_each_inferior_with_data, find_inferior,
863 find_inferior_id, find_inferior_in_random): Change signature.
864 * inferiors.c (all_threads): Change type to
865 std::list<thread_info *>.
866 (get_thread): Remove macro.
867 (find_inferior, find_inferior_id): Change signature, implement
868 using find_thread.
869 (find_inferior_in_random): Change signature, implement using
870 find_thread_in_random.
871 (for_each_inferior, for_each_inferior_with_data): Change
872 signature, implement using for_each_thread.
873 (add_inferior_to_list, remove_inferior): Remove.
874 (add_thread, get_first_thread, thread_of_pid,
875 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
876 (get_first_inferior, one_inferior_p, clear_inferior_list):
877 Remove.
878 (clear_inferiors, get_thread_process): Update.
879 * gdbthread.h: Include <list>.
880 (struct thread_info) <entry>: Remove field.
881 <id>: New field.
882 (all_threads): Change type to std::list<thread_info *>.
883 (get_first_inferior): Add doc.
884 (find_thread, for_each_thread, find_thread_in_random): New
885 functions.
886 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
887 * linux-arm-low.c (update_registers_callback): Update.
888 * linux-low.c (second_thread_of_pid_p): Update.
889 (kill_one_lwp_callback, linux_detach_lwp_callback,
890 delete_lwp_callback, status_pending_p_callback, same_lwp,
891 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
892 iterate_over_lwps, not_stopped_callback,
893 resume_stopped_resumed_lwps, count_events_callback,
894 select_singlestep_lwp_callback, select_event_lwp_callback,
895 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
896 suspend_and_send_sigstop_callback, wait_for_sigstop,
897 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
898 lwp_running, linux_set_resume_request, resume_status_pending_p,
899 need_step_over_p, start_step_over, linux_resume_one_thread,
900 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
901 reset_lwp_ptrace_options_callback): Update.
902 * linux-mips-low.c (update_watch_registers_callback): Update.
903 * regcache.c (regcache_invalidate_one, regcache_invalidate):
904 Update.
905 (free_register_cache_thread_one): Remove.
906 (regcache_release): Update.
907 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
908 handle_qxfer_threads_worker): Update.
909 (handle_query): Update, use list iterator.
910 (visit_actioned_threads, handle_pending_status,
911 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
912 clear_pending_status_callback, set_pending_status_callback,
913 find_status_pending_thread_callback, handle_status,
914 process_serial_event): Update.
915 * target.c (thread_search_callback): Update.
916 * thread-db.c (thread_db_get_tls_address): Update.
917 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
918 Update.
919 * win32-i386-low.c (update_debug_registers_callback): Update.
920 * win32-low.c (delete_thread_info, child_delete_thread,
921 continue_one_thread, suspend_one_thread,
922 get_child_debug_event): Adjust.
923
9179355e
SM
9242017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
925
926 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
927 * inferiors.h: Include <list>.
928 (struct process_info) <entry>: Remove field.
929 <pid>: New field.
930 (pid_of): Change macro to function.
931 (ptid_of, lwpid_of): Remove macro.
932 (all_processes): Change type to std::list<process_info *>.
933 (ALL_PROCESSES): Remove macro.
934 (for_each_process, find_process): New function.
935 * inferiors.c (all_processes): Change type to
936 std::list<process_info *>.
937 (find_thread_process): Adjust.
938 (add_process): Likewise.
939 (remove_process): Likewise.
940 (find_process_pid): Likewise.
941 (get_first_process): Likewise.
942 (started_inferior_callback): Remove.
943 (have_started_inferiors_p): Adjust.
944 (attached_inferior_callback): Remove.
945 (have_attached_inferiors_p): Adjust.
946 * linux-low.c (check_zombie_leaders): Likewise.
947 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
948 (x86_linux_update_xmltarget): Adjust.
949 * server.c (handle_query): Likewise.
950 (gdb_reattached_process): Remove.
951 (handle_status): Adjust.
952 (kill_inferior_callback): Likewise.
953 (detach_or_kill_inferior): Remove.
954 (print_started_pid): Likewise.
955 (print_attached_pid): Likewise.
956 (detach_or_kill_for_exit): Update.
957 (process_serial_event): Likewise.
958 * linux-arm-low.c (arm_new_fork): Likewise.
959
c9cb8905
SM
9602017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
961
962 * dll.h: Include <list>.
963 (struct dll_info): Add constructor.
964 <entry>: Remove field.
965 (all_dlls): Change type to std::list<dll_info>.
966 * dll.c: Include <algorithm>.
967 (get_dll): Remove macro.
968 (all_dlls): Change type to std::list<dll_info *>.
969 (free_one_dll): Remove.
970 (match_dll): Likewise.
971 (loaded_dll): Adjust.
972 (unloaded_dll): Adjust to all_dlls type change, use
973 std::find_if. Inline code from match_dll.
974 (clear_dlls): Adjust to all_dlls type change.
975 * server.c (emit_dll_description): Remove.
976 (handle_qxfer_libraries): Adjust to all_dlls type change,
977 integrate emit_dll_description's functionality.
978
04ec7890
SM
9792017-10-12 Simon Marchi <simon.marchi@ericsson.com>
980
981 * linux-low.h (struct linux_target_ops) <delete_process>: New
982 field.
983 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
984 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
985 (struct linux_target_ops): Add delete_process callback.
986 * linux-arm-low.c (arm_delete_process): New.
987 (struct linux_target_ops): Add delete_process callback.
988 * linux-bfin-low.c (struct linux_target_ops): Likewise.
989 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
990 * linux-m32r-low.c (struct linux_target_ops): Likewise.
991 * linux-mips-low.c (mips_linux_delete_process): New.
992 (struct linux_target_ops): Add delete_process callback.
993 * linux-ppc-low.c (struct linux_target_ops): Likewise.
994 * linux-s390-low.c (struct linux_target_ops): Likewise.
995 * linux-sh-low.c (struct linux_target_ops): Likewise.
996 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
997 * linux-tile-low.c (struct linux_target_ops): Likewise.
998 * linux-x86-low.c (x86_linux_delete_process): New.
999 (struct linux_target_ops): Add delete_process callback.
1000 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
1001
466eecee
SM
10022017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1003
1004 * linux-aarch64-low.c (the_low_target): Add thread delete
1005 callback.
1006 * linux-arm-low.c (arm_delete_thread): New function.
1007 (the_low_target): Add thread delete callback.
1008 * linux-bfin-low.c (the_low_target): Likewise.
1009 * linux-crisv32-low.c (the_low_target): Likewise.
1010 * linux-low.c (delete_lwp): Invoke delete_thread callback if
1011 set.
1012 * linux-low.h (struct linux_target_ops) <delete_thread>: New
1013 field.
1014 * linux-m32r-low.c (the_low_target): Add thread delete callback.
1015 * linux-mips-low.c (mips_linux_delete_thread): New function.
1016 (the_low_target): Add thread delete callback.
1017 * linux-ppc-low.c (the_low_target): Likewise.
1018 * linux-s390-low.c (the_low_target): Likewise.
1019 * linux-sh-low.c (the_low_target): Likewise.
1020 * linux-tic6x-low.c (the_low_target): Likewise.
1021 * linux-tile-low.c (the_low_target): Likewise.
1022 * linux-x86-low.c (the_low_target): Likewise.
1023 * linux-xtensa-low.c (the_low_target): Likewise.
1024
b79f7801
YZ
10252017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
1026
1027 * win32-low.c: Include "common-inferior.h".
1028
bc3b087d
SDJ
10292017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1030
1031 * inferiors.c (set_inferior_cwd): New function.
1032 * server.c (handle_general_set): Handle QSetWorkingDir packet.
1033 (handle_query): Inform that QSetWorkingDir is supported.
1034 * win32-low.c (create_process): Pass the inferior's cwd to
1035 CreateProcess.
1036
d092c5a2
SDJ
10372017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1038
1039 * inferiors.c (current_inferior_cwd): New global variable.
1040 (get_inferior_cwd): New function.
1041 * inferiors.h (struct process_info) <cwd>: New field.
1042
7da0a886
SDJ
10432017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1044
1045 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
1046 (OBS): Add gdb_tilde_expand.o.
1047
289a6840
SM
10482017-10-02 Simon Marchi <simon.marchi@ericsson.com>
1049
1050 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
1051 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1052
256642e8
PA
10532017-09-29 Pedro Alves <palves@redhat.com>
1054
1055 * ax.c (gdb_parse_agent_expr): Constify.
1056 * ax.h (gdb_parse_agent_expr): Constify.
1057 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
1058 Constify.
1059 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
1060 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
1061 * remote-utils.h (read_ptid): Constify.
1062 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
1063 (process_point_options, process_serial_event): Constify.
1064 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
1065 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
1066 (cmd_qtbuffer): Constify.
1067
5b9ca4d4
PA
10682017-09-29 Pedro Alves <palves@redhat.com>
1069
1070 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
1071 fails.
1072
94c207e0
PA
10732017-09-29 Pedro Alves <palves@redhat.com>
1074
1075 * linux-low.c (handle_extended_wait): Pass parent thread instead
1076 of process to thread_db_notice_clone.
1077 * linux-low.h (thread_db_notice_clone): Replace parent process
1078 parameter with parent thread parameter.
1079 * thread-db.c (find_one_thread): Add comment.
1080 (thread_db_notice_clone): Replace parent process parameter with
1081 parent thread parameter. Temporarily switch to the parent thread.
1082
75352e28
SDJ
10832017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
1084
1085 * gdbthread.h: Include "common-gdbthread.h".
1086 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
1087 "if" when validating the ptid.
1088 * remote-utils.c: Include "gdbthread.h".
1089 (prepare_resume_reply): Use "switch_to_thread".
1090 * target.c (done_accessing_memory): Likewise.
1091
ad339634
AA
10922017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1093
1094 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
1095 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
1096 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
1097 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
1098 s390x-gs-linux64-ipa.o to ipa_obj.
1099 * linux-s390-low.c (HWCAP_S390_GS): New define.
1100 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
1101 New functions.
1102 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
1103 (s390_arch_setup): Check for guarded-storage support and choose
1104 appropriate tdesc.
1105 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
1106 init_registers_s390x_gs_linux64.
1107 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
1108 enum value.
1109 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
1110 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
1111
cc4d742f
SM
11122017-09-22 Simon Marchi <simon.marchi@ericsson.com>
1113
1114 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
1115
f6327dcb
KB
11162017-09-21 Kevin Buettner <kevinb@redhat.com>
1117
1118 * linux-low.h (struct lwp_info): Add new field, thread_handle.
1119 (thread_db_thread_handle): Declare.
1120 * linux-low.c (linux_target_ops): Initialize thread_handle.
1121 * server.c (handle_qxfer_threads_worker): Add support for
1122 "handle" attribute.
1123 * target.h (struct target_ops): Add new function pointer,
1124 thread_handle.
1125 (target_thread_handle): Define.
1126 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
1127 field in lwp.
1128 (thread_db_thread_handle): New function.
1129
86299109
KB
11302017-09-21 Kevin Buettner <kevinb@redhat.com>
1131
1132 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
1133 * linux-low.h (thread_db_notice_clone): Declare.
1134 * thread-db.c (thread_db_notice_clone): New function.
1135
f557a88a
PA
11362017-09-21 Pedro Alves <palves@redhat.com>
1137
1138 * server.c (gdb_read_memory, handle_status, process_serial_event)
1139 (handle_serial_event, handle_target_event): Adjust to
1140 set_desired_thread prototype change.
1141 * target.c (set_desired_thread): Remove 'use_general' parameter
1142 and adjust.
1143 * target.h (set_desired_thread): Remove 'use_general' parameter.
1144
223ffa71
TT
11452017-09-20 Tom Tromey <tom@tromey.com>
1146
1147 * target.c (target_terminal::terminal_state): Define.
1148 (target_terminal::init): Rename from target_terminal_init.
1149 (target_terminal::inferior): Rename from
1150 target_terminal_inferior.
1151 (target_terminal::ours): Rename from target_terminal_ours.
1152 (target_terminal::ours_for_output, target_terminal::info): New.
1153
04fd3ba9
SM
11542017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1155
1156 * server.c (accumulate_file_name_length): Remove.
1157 (emit_dll_description): Adjust to std::string change.
1158 (handle_qxfer_libraries): Use std::string to hold document.
1159
5e187554
SM
11602017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1161
1162 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
1163 return type of xml_escape_text.
1164 * server.c (emit_dll_description): Likewise.
1165
1526853e
SM
11662017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1167
1168 * server.c (captured_main): Accept argument for --selftest.
1169 Update run_tests call.
1170 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
1171 when registering selftests.
1172
c4dfafab
SDJ
11732017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
1174
1175 * regcache.c (get_thread_regcache): Update code to use "std::vector"
1176 instead of "VEC" for "target_desc.reg_defs".
1177 (regcache_cpy): Likewise.
1178 (registers_to_string): Likewise.
1179 (registers_from_string): Likewise.
1180 (find_regno): Likewise.
1181 (supply_regblock): Likewise.
1182 (regcache_raw_read_unsigned): Likewise.
1183 * tdesc.c (init_target_desc): Likewise.
1184 (tdesc_create_reg): Likewise.
1185 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
1186 (struct target_desc) <reg_defs>: Convert to "std::vector".
1187 (target_desc): Do not initialize "reg_defs".
1188 (~target_desc): Update code to use "std::vector" instead of "VEC"
1189 for "target_desc.reg_defs".
1190 (operator==): Likewise.
1191
124aceb4
SM
11922017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1193
1194 * inferiors.h (thread_to_gdb_id): Remove.
1195 * inferiors.c (thread_to_gdb_id): Remove.
1196 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
1197 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
1198 lynx_store_registers, lynx_read_memory, lynx_write_memory):
1199 Likewise.
1200 * nto-low.c (nto_fetch_registers, nto_store_registers,
1201 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
1202
96cde54f
SM
12032017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1204
1205 * inferiors.h (gdb_id_to_thread_id): Remove.
1206 * inferiors.c (gdb_id_to_thread_id): Remove.
1207 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
1208 removal. Move pid declaration closer to where it's used.
1209
e8ca139e
SM
12102017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1211
1212 * server.c (handle_detach): New function.
1213 (process_serial_event): Move code out, call handle_detach.
1214
f8a4e119
SM
12152017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1216
1217 * server.c (require_running): Rename to ...
1218 (require_running_or_return): ... this ...
1219 (require_running_or_break): ... and this.
1220 (handle_query, process_serial_event): Adjust.
1221
0eb0a407
SM
12222017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1223
1224 * linux-low.c (linux_set_resume_request): Remove unused
1225 variables.
1226
785922a5
SM
12272017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1228
1229 * server.c (first_thread_of): Remove.
1230 (process_serial_event): Replace usage of first_thread_of with
1231 find_any_thread_of_pid.
1232 * tracepoint.c (same_process_p): Remove.
1233 (gdb_agent_about_to_close): Replace usage of same_process_p with
1234 find_any_thread_of_pid.
1235 * linux-x86-low.c (same_process_callback): Remove.
1236 (x86_arch_setup_process_callback): Replace usage of
1237 same_process_callback with find_any_thread_of_pid.
1238 * thread-db.c (any_thread_of): Remove.
1239 (switch_to_process): Replace usage of any_thread_of with
1240 find_any_thread_of_pid.
1241 * inferiors.c (thread_pid_matches_callback): Remove.
1242 (find_thread_process): Adjust to use find_any_thread_of_pid.
1243
a059f00c
SDJ
12442017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1245
1246 * regcache.c (get_thread_regcache): Guard calls to "memset"
1247 with "!VEC_empty".
1248
cc397f3a
SDJ
12492017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1250
1251 * linux-low.c (handle_extended_wait): Use
1252 "allocate_target_description" instead of "XNEW".
1253 * linux-x86-low.c (initialize_low_arch): Likewise.
1254
22916b07
YQ
12552017-09-05 Yao Qi <yao.qi@linaro.org>
1256
1257 * configure.srv (srv_i386_regobj): Remove.
1258 (srv_amd64_regobj): Remove.
1259 (srv_regobj): Set it to "" for x86 non-linux targets.
1260 * linux-x86-tdesc.c (i386_linux_read_description):
1261 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
1262 (init_registers_i386): Remove the declaration.
1263 (tdesc_i386): Remove the declaration.
1264 (lynx_i386_arch_setup): Call i386_create_target_description.
1265 * nto-x86-low.c: Likewise.
1266 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
1267 [!__x86_64__]: include arch/i386.h.
1268 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
1269
38602d55
YQ
12702017-09-05 Yao Qi <yao.qi@linaro.org>
1271
1272 * configure.srv (srv_amd64_linux_xmlfiles): Remove
1273 i386/amd64-XXX-linux from it.
1274
44b886ff
YQ
12752017-09-05 Yao Qi <yao.qi@linaro.org>
1276
1277 * configure.srv: Empty srv_amd64_linux_regobj if $development is
1278 false.
1279 (ipa_amd64_linux_regobj): Remove.
1280 (ipa_x32_linux_regobj): Remove.
1281
b4570e4b
YQ
12822017-09-05 Yao Qi <yao.qi@linaro.org>
1283
1284 * Makefile.in (arch-amd64.o): New rule.
1285 * configure.srv: Append arch-amd64.o.
1286 * linux-amd64-ipa.c: Include common/x86-xstate.h.
1287 (get_ipa_tdesc): Call amd64_linux_read_description.
1288 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
1289 and init_registers_amd64_XXX.
1290 * linux-x86-low.c (x86_linux_read_description): Call
1291 amd64_linux_read_description.
1292 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
1293 (initialize_low_arch): Don't call init_registers_x32_XXX and
1294 init_registers_amd64_XXX.
1295 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
1296 and tdesc_amd64_XXX.
1297 [__x86_64__] (amd64_tdesc_test): New function.
1298 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
1299 and init_registers_amd64_XXX.
1300 * linux-x86-tdesc.c: Include arch/amd64.h.
1301 (xcr0_to_tdesc_idx): New function.
1302 (i386_linux_read_description): New function.
1303 (amd64_get_ipa_tdesc_idx): New function.
1304 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
1305 (amd64_get_ipa_tdesc): Declare.
1306
d1f28ea2
YQ
13072017-09-05 Yao Qi <yao.qi@linaro.org>
1308
1309 * configure.srv (srv_i386_linux_xmlfiles): Remove
1310 i386/i386-XXX-linux.xml from it.
1311
25a93583
YQ
13122017-09-05 Yao Qi <yao.qi@linaro.org>
1313
1314 * configure.srv: Set srv_i386_linux_regobj empty if $development
1315 is false.
1316 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
1317 initialize_low_tdesc.
1318 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
1319 with #if initialize_low_tdesc.
1320 * linux-x86-tdesc-selftest.c: New file.
1321 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
1322
5f035c07
YQ
13232017-09-05 Yao Qi <yao.qi@linaro.org>
1324
1325 * Makefile.in (arch-i386.o): New rule.
1326 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
1327 (x86_64-*-linux*): Likewise.
1328 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
1329 include arch/i386.h.
1330 (i386_linux_read_description): Remove code and call
1331 i386_create_target_description.
1332 * tdesc.c (allocate_target_description): New function.
1333 * tdesc.h (set_tdesc_architecture): Remove declaration.
1334 (set_tdesc_osabi): Likewise.
1335
0abe8a89
YQ
13362017-09-05 Yao Qi <yao.qi@linaro.org>
1337
1338 * linux-x86-tdesc.c: Don't include <inttypes.h>.
1339 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
1340 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
1341 .xmltarget.
1342 * server.c (get_features_xml): Call tdesc_get_features_xml.
1343 * tdesc.c (set_tdesc_architecture): New function.
1344 (set_tdesc_osabi): New function.
1345 (tdesc_get_features_xml): New function.
1346 (tdesc_create_feature): Add an argument.
1347 * tdesc.h (struct target_desc) <features>: New field.
1348 <arch, osabi>: New field.
1349 (~target_desc): xfree features, arch, and osabi.
1350 (target_desc::oerator==): Don't compare .xmltarget.
1351 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
1352 (set_tdesc_osabi): Likewise.
1353 (tdesc_get_features_xml): Likewise.
1354
0a188386
YQ
13552017-09-05 Yao Qi <yao.qi@linaro.org>
1356
1357 * linux-x86-tdesc.c: Include selftest.h.
1358 (i386_tdesc_test): New function.
1359 (initialize_low_tdesc): Call selftests::register_test.
1360 * tdesc.h: Include regdef.h.
1361 (target_desc): Override operator == and !=.
1362
f49ff000
YQ
13632017-09-05 Yao Qi <yao.qi@linaro.org>
1364
1365 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
1366 (ipa_obj): Likewise.
1367 * linux-i386-ipa.c: Include common/x86-xstate.h
1368 (get_ipa_tdesc): Call i386_linux_read_description.
1369 (initialize_low_tracepoint): Don't call init_registers_XXX
1370 functions, call initialize_low_tdesc instead.
1371 * linux-x86-low.c (x86_linux_read_description): Call
1372 i386_linux_read_description.
1373 (initialize_low_arch): Don't call init_registers_i386_XXX
1374 functions, call initialize_low_tdesc.
1375 * linux-x86-tdesc.c: New file.
1376 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
1377 (i386_get_ipa_tdesc_idx): Declare.
1378 (i386_get_ipa_tdesc): Declare.
1379 (initialize_low_tdesc): Declare.
1380
2b68ef2f
YQ
13812017-09-05 Yao Qi <yao.qi@linaro.org>
1382
1383 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
1384 instead of 0.
1385
f7000548
YQ
13862017-09-05 Yao Qi <yao.qi@linaro.org>
1387
1388 * Makefile.in (IPA_OBJS): Add vec-ipa.o
1389 * regcache.c (get_thread_regcache): Use VEC_length.
1390 (init_register_cache): Likewise.
1391 (regcache_cpy): Likewise.
1392 (registers_to_string): Iterate reg_defs via VEC_iterate.
1393 (find_regno): Likewise.
1394 (find_register_by_number): Use VEC_index.
1395 (register_size): Call find_register_by_number.
1396 (register_data): Call find_register_by_number.
1397 (supply_regblock): Use VEC_length.
1398 (regcache_raw_read_unsigned): Likewise.
1399 * tdesc.c (init_target_desc): Iterate reg_defs via
1400 VEC_iterate.
1401 (default_description): Update initializer.
1402 (copy_target_description): Don't update field num_registers.
1403 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
1404 <num_registers>: Remove.
1405
50a421ac
SM
14062017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1407
1408 * Makefile.in (.SECONDARY): Define target.
1409
23fdd69e
SM
14102017-09-03 Simon Marchi <simon.marchi@ericsson.com>
1411
1412 * linux-low.c (linux_wait_1): Adjust.
1413 * server.c (queue_stop_reply_callback): Adjust.
1414
0a2dde4a
SDJ
14152017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1416
1417 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
1418 QEnvironmentUnset and QEnvironmentReset packets.
1419 (handle_query): Inform remote that QEnvironmentHexEncoded,
1420 QEnvironmentUnset and QEnvironmentReset are supported.
1421
6afd337d
SM
14222017-08-25 Simon Marchi <simon.marchi@ericsson.com>
1423
1424 * inferiors.h (inferior_target_data): Rename to ...
1425 (thread_target_data): ... this.
1426 (inferior_regcache_data): Rename to ...
1427 (thread_regcache_data): ... this.
1428 (set_inferior_regcache_data): Rename to ...
1429 (set_thread_regcache_data): ... this.
1430 * inferiors.c (inferior_target_data): Rename to ...
1431 (thread_target_data): ... this.
1432 (inferior_regcache_data): Rename to ...
1433 (thread_regcache_data): ... this.
1434 (set_inferior_regcache_data): Rename to ...
1435 (set_thread_regcache_data): ... this.
1436 (free_one_thread): Update.
1437 * linux-low.h (get_thread_lwp): Update.
1438 * regcache.c (get_thread_regcache): Update.
1439 (regcache_invalidate_thread): Update.
1440 (free_register_cache_thread): Update.
1441 * win32-i386-low.c (update_debug_registers_callback): Update.
1442 (win32_get_current_dr): Update.
1443 * win32-low.c (thread_rec): Update.
1444 (delete_thread_info): Update.
1445 (continue_one_thread): Update.
1446 (suspend_one_thread): Update.
1447
a160cc46
SM
14482017-08-24 Simon Marchi <simon.marchi@ericsson.com>
1449
1450 * inferiors.c (set_inferior_target_data): Remove.
1451 * inferiors.h (set_inferior_target_data): Remove.
1452
6d580b63
YQ
14532017-08-18 Yao Qi <yao.qi@linaro.org>
1454
1455 * Makefile.in (OBS): Add selftest.o.
1456 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
1457 * configure, config.in: Re-generated.
1458 * server.c: Include common/sefltest.h.
1459 (captured_main): Handle option --selftest.
1460
f5a29eb0
YQ
14612017-08-09 Yao Qi <yao.qi@linaro.org>
1462
1463 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
1464 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
1465 i386-avx-mpx.o and i386-mmx.o.
1466 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
1467 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
1468 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
1469 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
1470 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
1471 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
1472 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
1473 i386/amd64-avx-mpx.xml.
1474
57757c2f
YQ
14752017-08-09 Yao Qi <yao.qi@linaro.org>
1476
1477 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
1478 and x32-avx-avx512.o.
1479 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
1480 i386/x32-avx-avx512.xml.
1481
229d26fc
SM
14822017-07-26 Simon Marchi <simon.marchi@ericsson.com>
1483
1484 * tracepoint.h (enum class fast_tpoint_collect_result): New
1485 enumeration.
1486 (fast_tracepoint_collecting): Change return type to
1487 fast_tpoint_collect_result.
1488 * tracepoint.c (fast_tracepoint_collecting): Likewise.
1489 * linux-low.h: Include tracepoint.h.
1490 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
1491 fast_tpoint_collect_result.
1492 * linux-low.c (handle_tracepoints): Adjust.
1493 (linux_fast_tracepoint_collecting): Change return type to
1494 fast_tpoint_collect_result.
1495 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
1496 linux_wait_1, stuck_in_jump_pad_callback,
1497 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
1498 proceed_one_lwp): Adjust to type change.
1499
2e1e43e1
YQ
15002017-07-10 Yao Qi <yao.qi@linaro.org>
1501
1502 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
1503
adc764e7
YQ
15042017-06-29 Yao Qi <yao.qi@linaro.org>
1505
1506 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
1507 Remove.
1508 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
1509
a206891a
SM
15102017-06-20 Simon Marchi <simon.marchi@ericsson.com>
1511
1512 * Makefile.in (IPA_OBJS): Sort and format one item per line.
1513
9a6c7d9c
SDJ
15142017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
1515
1516 * linux-low.c (linux_create_inferior): Adjust code to access the
1517 environment information via 'gdb_environ' class.
1518 * lynx-low.c (lynx_create_inferior): Likewise.
1519 * server.c (our_environ): Make it an instance of 'gdb_environ'.
1520 (get_environ): Return a pointer to 'our_environ'.
1521 (captured_main): Initialize 'our_environ'.
1522 * server.h (get_environ): Adjust prototype.
1523 * spu-low.c (spu_create_inferior): Adjust code to access the
1524 environment information via 'gdb_environ' class.
1525
ae3e2ccf
SM
15262017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1527
1528 * linux-low.c (linux_read_memory, linux_write_memory): Remove
1529 usage of "register" keyword.
1530
3e019bdc
SM
15312017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1532
1533 * configure: Re-generate.
1534
8465943a
SM
15352017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1536
1537 * configure: Re-generate.
1538
cf0dd6f0
SM
15392017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1540
1541 * Makefile.in (COMPILE.pre): Add "-x c++".
1542
9845682b
SDJ
15432017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
1544
1545 * fork-child.c: Conditionally include <signal.h>.
1546
aefd8b33
SDJ
15472017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1548
1549 * server.c (handle_general_set): Handle new packet
1550 "QStartupWithShell".
1551 (handle_query): Add "QStartupWithShell" to the list of supported
1552 packets.
1553 (gdbserver_usage): Add help text explaining the
1554 new "--startup-with-shell" and "--no-startup-with-shell" CLI
1555 options.
1556 (captured_main): Recognize and act upon the presence of the new
1557 CLI options.
1558
2090129c
SDJ
15592017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1560 Pedro Alves <palves@redhat.com>
1561
1562 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
1563 * configure: Regenerate.
1564 * configure.srv (srv_linux_obj): Add "fork-child.o" and
1565 "fork-inferior.o".
1566 (i[34567]86-*-lynxos*): Likewise.
1567 (spu*-*-*): Likewise.
1568 * fork-child.c: New file.
1569 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
1570 and "environ.h".
1571 (linux_ptrace_fun): New function.
1572 (linux_create_inferior): Adjust function prototype to reflect
1573 change on "target.h". Adjust function code to use
1574 "fork_inferior".
1575 (linux_request_interrupt): Delete "signal_pid".
1576 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
1577 (lynx_ptrace_fun): New function.
1578 (lynx_create_inferior): Adjust function prototype to reflect
1579 change on "target.h". Adjust function code to use
1580 "fork_inferior".
1581 * nto-low.c (nto_create_inferior): Adjust function prototype and
1582 code to reflect change on "target.h". Update comments.
1583 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
1584 "common-terminal.h" and "environ.h".
1585 (terminal_fd): Moved to fork-child.c.
1586 (old_foreground_pgrp): Likewise.
1587 (restore_old_foreground_pgrp): Likewise.
1588 (last_status): Make it global.
1589 (last_ptid): Likewise.
1590 (our_environ): New variable.
1591 (startup_with_shell): Likewise.
1592 (program_name): Likewise.
1593 (program_argv): Rename to...
1594 (program_args): ...this.
1595 (wrapper_argv): New variable.
1596 (start_inferior): Delete function.
1597 (get_exec_wrapper): New function.
1598 (get_exec_file): Likewise.
1599 (get_environ): Likewise.
1600 (prefork_hook): Likewise.
1601 (post_fork_inferior): Likewise.
1602 (postfork_hook): Likewise.
1603 (postfork_child_hook): Likewise.
1604 (handle_v_run): Update code to deal with arguments coming from the
1605 remote host. Update calls from "start_inferior" to
1606 "create_inferior".
1607 (captured_main): Likewise. Initialize environment variable. Call
1608 "have_job_control".
1609 * server.h (post_fork_inferior): New prototype.
1610 (get_environ): Likewise.
1611 (last_status): Declare.
1612 (last_ptid): Likewise.
1613 (signal_pid): Likewise.
1614 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
1615 (spu_ptrace_fun): New function.
1616 (spu_create_inferior): Adjust function prototype to reflect change
1617 on "target.h". Adjust function code to use "fork_inferior".
1618 * target.c (target_terminal_init): New function.
1619 (target_terminal_inferior): Likewise.
1620 (target_terminal_ours): Likewise.
1621 * target.h: Include <vector>.
1622 (struct target_ops) <create_inferior>: Update prototype.
1623 (create_inferior): Update macro.
1624 * utils.c (gdb_flush_out_err): New function.
1625 * win32-low.c (win32_create_inferior): Adjust function prototype
1626 and code to reflect change on "target.h".
1627
043a4934
SDJ
16282017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1629
1630 * inferiors.c (switch_to_thread): New function.
1631
15652511
SDJ
16322017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1633
1634 * Makefile.in (SFILE): Add "common/job-control.c".
1635 (OBS): Add "job-control.o".
1636
21ea5acd
SDJ
16372017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
1638
1639 * Makefile: Remove "@host_makefile_frag@".
1640
e13cb306
PA
16412017-05-05 Pedro Alves <palves@redhat.com>
1642
1643 * configure: Regenerate.
1644
c94fee56
SDJ
16452017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
1646
1647 * configure: Regenerate.
1648
a0ff9e1a
SM
16492017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
1650
1651 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
1652 software_single_step change of return type to
1653 std::vector<CORE_ADDR>.
1654 * linux-low.c (install_software_single_step_breakpoints):
1655 Likewise.
1656 * linux-low.h (install_software_single_step_breakpoints):
1657 Likewise.
1658
be628ab8
SDJ
16592017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
1660
1661 * remote-utils.c: Include "gdb_termios.h" instead of
1662 "terminal.h".
1663 * terminal.h: Delete file.
1664
7c5ded6a
SDJ
16652017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
1666
1667 * server.c: Include <vector>.
1668 <program_argv, wrapper_argv>: Convert to std::vector.
1669 (start_inferior): Rewrite function to use C++.
1670 (handle_v_run): Likewise. Update code that calculates the argv
1671 based on the vRun packet; use C++.
1672 (captured_main): Likewise.
1673
436252de
SM
16742017-04-06 Simon Marchi <simon.marchi@ericsson.com>
1675
1676 * server.c (handle_v_cont): Initialize thread_resume::thread
1677 with null_ptid.
1678
9bf2a700
PA
16792017-04-05 Pedro Alves <palves@redhat.com>
1680
1681 * configure: Regenerate.
1682
a121b7c1
PA
16832017-04-05 Pedro Alves <palves@redhat.com>
1684
1685 * gdbreplay.c (sync_error): Constify.
1686 * linux-x86-low.c (push_opcode): Constify.
1687
21c8a587
PA
16882017-04-05 Pedro Alves <palves@redhat.com>
1689
1690 * win32-low.c (get_child_debug_event)
1691 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
1692 Report TARGET_WAITKIND_SPURIOUS instead.
1693
fb32b4f7
PA
16942017-04-05 Pedro Alves <palves@redhat.com>
1695
1696 * remote-utils.c (remote_prepare, remote_open): Constify.
1697 * remote-utils.h (remote_prepare, remote_open): Constify.
1698 * server.c (captured_main): Constify 'port' handling.
1699
65dd1e59
SM
17002017-04-04 Simon Marchi <simon.marchi@ericsson.com>
1701
1702 * Makefile.in (clean): Clear .deps.
1703
8fa5b777
SM
17042017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
1705
1706 * .gitignore: Remove generated files, replace with wildcard.
1707 * (clean): Replace removal of generated files with wildcard.
1708 (version.c): Replace with...
1709 (version-generated.c): ...this.
1710 (xml-builtin.c): Replace with...
1711 (xml-builtin-generated.c): ...this.
1712 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
1713 (%.c: *regformats*): Replace with...
1714 (%-generated.c: *regformats*): ...this.
1715
a12e714b
MF
17162017-03-27 Max Filippov <jcmvbkbc@gmail.com>
1717
1718 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
1719 (xtensa_fill_gregset): Call collect_register_by_name for
1720 threadptr register.
1721 (xtensa_store_gregset): Call supply_register_by_name for
1722 threadptr register.
1723
1a09b50a
MF
17242017-03-27 Max Filippov <jcmvbkbc@gmail.com>
1725
1726 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
1727 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
1728 (xtensa_store_gregset): Call supply_register for all registers in
1729 a0_regnum..a0_regnum + C0_NREGS range.
1730
1a01e7c6
SM
17312017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1732
1733 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
1734 (ax-ipa.o: ax.c): Remove.
1735 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
1736 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
1737 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
1738 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
1739 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
1740
36bc18a8
SM
17412017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1742
1743 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
1744 (print-utils-ipa.o: ../common/print-utils.c): Remove.
1745 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
1746 (errors-ipa.o: ../common/errors.c): Remove.
1747 (format-ipa.o: ../common/format.c): Remove.
1748 (common-utils-ipa.o: ../common/common-utils.c): Remove.
1749
a8ebe3d5
SM
17502017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1751
1752 * Makefile.in (%-ipa.o: %.c): New rule.
1753 (tracepoint-ipa.o: tracepoint.c): Remove.
1754 (utils-ipa.o: utils.c): Remove.
1755 (remote-utils-ipa.o: remote-utils.c): Remove.
1756 (regcache-ipa.o: regcache.c): Remove.
1757 (i386-linux-ipa.o: i386-linux.c): Remove.
1758 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
1759 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
1760 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
1761 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
1762 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
1763 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
1764 (amd64-linux-ipa.o: amd64-linux.c): Remove.
1765 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
1766 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
1767 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
1768 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
1769 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
1770 (aarch64-ipa.o: aarch64.c): Remove.
1771 (s390-linux32-ipa.o: s390-linux32.c): Remove.
1772 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
1773 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
1774 (s390-linux64-ipa.o: s390-linux64.c): Remove.
1775 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
1776 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
1777 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
1778 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
1779 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
1780 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
1781 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
1782 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
1783 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
1784 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
1785 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
1786 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
1787 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
1788 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
1789 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
1790 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
1791 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
1792 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
1793 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
1794 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
1795 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
1796 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
1797 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
1798 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
1799 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
1800 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
1801 (tdesc-ipa.o: tdesc.c): Remove.
1802 (x32-linux-ipa.o: x32-linux.c): Remove.
1803 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
1804 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
1805
50cfacb7
SM
18062017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1807
1808 * Makefile.in (%.o: ../arch/%.c): New rule.
1809 (arm.o: ../arch/arm.c): Remove.
1810 (arm-linux.o: ../arch/arm-linux.c): Remove.
1811 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
1812 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
1813
c5a22423
SM
18142017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1815
1816 * Makefile.in (%.o: ../nat/%.c): New rule.
1817 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
1818 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
1819 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
1820 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
1821 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
1822 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
1823 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
1824 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
1825 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
1826 (linux-personality.o: ../nat/linux-personality.c): Remove.
1827 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
1828 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
1829 (x86-linux.o: ../nat/x86-linux.c): Remove.
1830 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
1831 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
1832
6bda016b
SM
18332017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1834
1835 * Makefile.in (%.o: ../common/%.c): New rule.
1836 (signals.o: ../common/signals.c): Remove.
1837 (print-utils.o: ../common/print-utils.c): Remove.
1838 (rsp-low.o: ../common/rsp-low.c): Remove.
1839 (common-utils.o: ../common/common-utils.c): Remove.
1840 (posix-strerror.o: ../common/posix-strerror.c): Remove.
1841 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
1842 (vec.o: ../common/vec.c): Remove.
1843 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
1844 (xml-utils.o: ../common/xml-utils.c): Remove.
1845 (ptid.o: ../common/ptid.c): Remove.
1846 (buffer.o: ../common/buffer.c): Remove.
1847 (format.o: ../common/format.c): Remove.
1848 (filestuff.o: ../common/filestuff.c): Remove.
1849 (agent.o: ../common/agent.c): Remove.
1850 (errors.o: ../common/errors.c): Remove.
1851 (environ.o: ../common/environ.c): Remove.
1852 (common-debug.o: ../common/common-debug.c): Remove.
1853 (cleanups.o: ../common/cleanups.c): Remove.
1854 (common-exceptions.o: ../common/common-exceptions.c): Remove.
1855 (fileio.o: ../common/fileio.c): Remove.
1856 (common-regcache.o: ../common/common-regcache.c): Remove.
1857 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
1858 (new-op.o: ../common/new-op.c): Remove.
1859 (btrace-common.o: ../common/btrace-common.c): Remove.
1860
21122961
SM
18612017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1862
1863 * Makefile.in (%.o: ../target/%.c): New rule.
1864 (waitstatus.o: ../target/waitstatus.c): Remove.
1865
c362e621
SM
18662017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1867
1868 * Makefile.in
1869 (%.c: ../regformats/%.dat,
1870 (%.c: ../regformats/arm/%.dat,
1871 (%.c: ../regformats/i386/%.dat,
1872 (%.c: ../regformats/rs6000/%.dat): New rules.
1873 (aarch64.c): Remove.
1874 (reg-arm.c): Remove.
1875 (arm-with-iwmmxt.c): Remove.
1876 (arm-with-vfpv2.c): Remove.
1877 (arm-with-vfpv3.c): Remove.
1878 (arm-with-neon.c): Remove.
1879 (reg-bfin.c): Remove.
1880 (reg-cris.c): Remove.
1881 (reg-crisv32.c): Remove.
1882 (i386.c): Remove.
1883 (i386-linux.c): Remove.
1884 (i386-avx.c): Remove.
1885 (i386-avx-linux.c): Remove.
1886 (i386-avx-avx512.c): Remove.
1887 (i386-avx-avx512-linux.c): Remove.
1888 (i386-mpx.c): Remove.
1889 (i386-mpx-linux.c): Remove.
1890 (i386-avx-mpx-avx512-pku.c): Remove.
1891 (i386-avx-mpx-avx512-pku-linux.c): Remove.
1892 (i386-avx-mpx.c): Remove.
1893 (i386-avx-mpx-linux.c): Remove.
1894 (i386-mmx.c): Remove.
1895 (i386-mmx-linux.c): Remove.
1896 (reg-ia64.c): Remove.
1897 (reg-m32r.c): Remove.
1898 (reg-m68k.c): Remove.
1899 (reg-cf.c): Remove.
1900 (mips-linux.c): Remove.
1901 (mips-dsp-linux.c): Remove.
1902 (mips64-linux.c): Remove.
1903 (mips64-dsp-linux.c): Remove.
1904 (nios2-linux.c): Remove.
1905 (powerpc-32.c): Remove.
1906 (powerpc-32l.c): Remove.
1907 (powerpc-altivec32l.c): Remove.
1908 (powerpc-cell32l.c): Remove.
1909 (powerpc-vsx32l.c): Remove.
1910 (powerpc-isa205-32l.c): Remove.
1911 (powerpc-isa205-altivec32l.c): Remove.
1912 (powerpc-isa205-vsx32l.c): Remove.
1913 (powerpc-e500l.c): Remove.
1914 (powerpc-64l.c): Remove.
1915 (powerpc-altivec64l.c): Remove.
1916 (powerpc-cell64l.c): Remove.
1917 (powerpc-vsx64l.c): Remove.
1918 (powerpc-isa205-64l.c): Remove.
1919 (powerpc-isa205-altivec64l.c): Remove.
1920 (powerpc-isa205-vsx64l.c): Remove.
1921 (s390-linux32.c): Remove.
1922 (s390-linux32v1.c): Remove.
1923 (s390-linux32v2.c): Remove.
1924 (s390-linux64.c): Remove.
1925 (s390-linux64v1.c): Remove.
1926 (s390-linux64v2.c): Remove.
1927 (s390-te-linux64.c): Remove.
1928 (s390-vx-linux64.c): Remove.
1929 (s390-tevx-linux64.c): Remove.
1930 (s390x-linux64.c): Remove.
1931 (s390x-linux64v1.c): Remove.
1932 (s390x-linux64v2.c): Remove.
1933 (s390x-te-linux64.c): Remove.
1934 (s390x-vx-linux64.c): Remove.
1935 (s390x-tevx-linux64.c): Remove.
1936 (tic6x-c64xp-linux.c): Remove.
1937 (tic6x-c64x-linux.c): Remove.
1938 (tic6x-c62x-linux.c): Remove.
1939 (reg-sh.c): Remove.
1940 (reg-sparc64.c): Remove.
1941 (reg-spu.c): Remove.
1942 (amd64.c): Remove.
1943 (amd64-linux.c): Remove.
1944 (amd64-avx.c): Remove.
1945 (amd64-avx-linux.c): Remove.
1946 (amd64-avx-avx512.c): Remove.
1947 (amd64-avx-avx512-linux.c): Remove.
1948 (amd64-mpx.c): Remove.
1949 (amd64-mpx-linux.c): Remove.
1950 (amd64-avx-mpx-avx512-pku.c): Remove.
1951 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
1952 (amd64-avx-mpx.c): Remove.
1953 (amd64-avx-mpx-linux.c): Remove.
1954 (x32.c): Remove.
1955 (x32-linux.c): Remove.
1956 (x32-avx.c): Remove.
1957 (x32-avx-linux.c): Remove.
1958 (x32-avx-avx512.c): Remove.
1959 (x32-avx-avx512-linux.c): Remove.
1960 (reg-xtensa.c): Remove.
1961 (reg-tilegx.c): Remove.
1962 (reg-tilegx32.c): Remove.
1963
1672e0d9
SDJ
19642017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
1965
1966 * Makefile.in (SFILES): Add "common/environ.c".
1967 (OBJS): Add "common/environ.h".
1968
239b6d10
WT
19692017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
1970
1971 * configure.ac: Check if the fs_base and gs_base members of
1972 `struct user_regs_struct' exist.
1973 * config.in: Regenerated.
1974 * configure: Likewise.
1975
694b382c
AT
19762017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
1977
1978 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
1979 target_read_memory.
1980 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
1981 (get_next_pcs_syscall_next_pc): Likewise.
1982
7dc53023
LM
19832016-12-23 Luis Machado <lgustavo@codesourcery.com>
1984
1985 * win32-i386-low.c: Fix incorrect reference to a couple source files.
1986 * nto-x86-low.c: Likewise.
1987
ad02e4fe
SM
19882016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
1989
1990 * Makefile.in: Include disable-implicit-rules.mk.
1991
dcb07cfa
PA
19922016-11-23 Pedro Alves <palves@redhat.com>
1993
1994 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
1995 (debug_vprintf): Use std::chrono::steady_clock instead of
1996 gettimeofday. Use '.' instead of ':'.
1997 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
1998 (get_timestamp): Use std::chrono::steady_clock instead of
1999 gettimeofday.
2000
8629c02c
SM
20012016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2002
2003 * Makefile.in: Fix whitespace formatting.
2004
b593ecca
SM
20052016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2006
2007 * Makefile.in (SFILES, OBS): Flatten list and order
2008 alphabetically.
2009
9986ba08
PA
20102016-11-23 Pedro Alves <palves@redhat.com>
2011
2012 * event-loop.c (handle_file_event): Use warning.
2013 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
2014 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2015 Use warning.
2016
4eefa7bc
PA
20172016-11-23 Pedro Alves <palves@redhat.com>
2018
2019 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
2020 output.
2021 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
2022 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
2023 debug_printf and debug_flush for debug output.
2024 * server.c (handle_general_set): Likewise.
2025 * thread-db.c (try_thread_db_load): Use debug_printf for debug
2026 output.
2027
5443506e
SM
20282016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2029
2030 * Makefile.in (.c.o): Replace rule with ...
2031 (%.o: %.c): ... this one.
2032
3b165252
SM
20332016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2034
2035 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
2036 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
2037 make.
2038 * configure.ac: Remove checks for the make program.
2039 * configure: Re-generate.
2040
0bcda685
PA
20412016-10-28 Pedro Alves <palves@redhat.com>
2042
2043 * Makefile.in (CXX_DIALECT): Get from configure.
2044 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
2045 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
2046 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
2047 * config.in: Regenerate.
2048 * configure: Regenerate.
2049
c3805894
YQ
20502016-10-27 Yao Qi <yao.qi@linaro.org>
2051
2052 * linux-low.c (linux_supports_range_stepping): Return true if
2053 can_software_single_step return true.
2054
89342618
YQ
20552016-10-27 Yao Qi <yao.qi@linaro.org>
2056
2057 * inferiors.c (find_inferior_in_random): New function.
2058 * inferiors.h (find_inferior_in_random): Declare.
2059 * linux-low.c (linux_wait_for_event_filtered): Call
2060 find_inferior_in_random instead of find_inferior.
2061
e3652c84
YQ
20622016-10-27 Yao Qi <yao.qi@linaro.org>
2063
2064 * linux-low.c (linux_wait_1): If single-step breakpoints are
2065 inserted, remove them.
2066
5a04c4cf
PA
20672016-10-26 Pedro Alves <palves@redhat.com>
2068
2069 * linux-low.c (handle_extended_wait): Link parent/child fork
2070 threads.
2071 (linux_wait_1): Unlink them.
2072 (linux_set_resume_request): Ignore resume requests for
2073 already-resumed and unhandled fork child threads.
2074 * linux-low.h (struct lwp_info) <fork_relative>: New field.
2075 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
2076 New functions.
2077 (handle_v_requests) <vCont>: Don't call require_running.
2078 * server.h (in_queued_stop_replies): New declaration.
2079
cb93dc7f
YQ
20802016-10-24 Yao Qi <yao.qi@linaro.org>
2081
2082 PR server/20733
2083 * linux-aarch64-low.c (append_insns): Cast the return value to
2084 'uint32_t *'.
2085
a1078bea
YQ
20862016-10-10 Yao Qi <yao.qi@linaro.org>
2087
2088 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
2089
1fb77080
SDJ
20902016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
2091
2092 * target.c (target_supports_multi_process): New function, moved
2093 from...
2094 * target.h (target_supports_multi_process): ... here. Remove
2095 macro.
2096
39b5a3b9
TT
20972016-10-05 Tom Tromey <tom@tromey.com>
2098
2099 PR remote/20655:
2100 * tracepoint.c (handle_tracepoint_bkpts): Check
2101 ipa_error_tracepoint, not ipa_stopping_tracepoint.
2102
c1d0b70a
YQ
21032016-10-05 Yao Qi <yao.qi@linaro.org>
2104
2105 * configure.srv: Update the path of arm-*.xml files.
2106
0a69eedb
YQ
21072016-10-05 Terry Guo <terry.guo@arm.com>
2108 Yao Qi <yao.qi@linaro.org>
2109
2110 * Makefile.in: Adjust the path of rules.
2111 * configure.srv: Update the path of xml files.
2112 * regformats/arm-with-iwmmxt.dat: Regenerated.
2113 * regformats/arm-with-neon.dat: Likewise.
2114 * regformats/arm-with-vfpv2.dat: Likewise.
2115 * regformats/arm-with-vfpv3.dat Likewise.
2116
17e16485
YQ
21172016-09-30 Yao Qi <yao.qi@linaro.org>
2118
2119 PR gdbserver/20627
2120 * target.c (target_stop_and_wait): Don't call
2121 target_continue_no_signal, use resume_stop instead.
2122
edeeb602
YQ
21232016-09-26 Yao Qi <yao.qi@linaro.org>
2124
2125 * linux-low.c (linux_wait_1): Call debug_exit.
2126
503b1c39
PA
21272016-09-23 Pedro Alves <palves@redhat.com>
2128
2129 * Makefile.in (SFILES): Add common/new-op.c.
2130 (OBS): Add common/new-op.o.
2131 (new-op.o): New rule.
2132
74172ecf
SM
21332016-09-21 Simon Marchi <simon.marchi@ericsson.com>
2134
2135 * .gitinore: Ignore more files.
2136
fc6cda2e
YQ
21372016-09-21 Yao Qi <yao.qi@linaro.org>
2138
2139 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
2140 23.
2141
bc1e6c81
SDJ
21422016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
2143
2144 * server.c (start_inferior): Call target_mourn_inferior instead of
2145 mourn_inferior; pass ptid_t argument to it.
2146 (resume): Likewise.
2147 (handle_target_event): Likewise.
2148 * target.c (target_mourn_inferior): New function.
2149 * target.h (mourn_inferior): Delete macro.
2150
0e00e962
AA
21512016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
2152
2153 * linux-low.c (lwp_is_stepping): New function.
2154
1d8cb77d
CL
21552016-09-06 Carl Love <cel@us.ibm.com>
2156
2157 * server.c (start_inferior): Fixed comment, requested comment change
2158 didn't get updated correctly. Removed reference to ptrace () call as
2159 it is only true on Linux systems.
2160
7313bced
CL
21612016-09-06 Carl Love <cel@us.ibm.com>
2162
2163 * server.c (start_inferior): Do not call
2164 function target_post_create_inferior () if the
2165 inferior process has already exited.
2166
cf6de44d
PA
21672016-09-05 Pedro Alves <palves@redhat.com>
2168
2169 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
2170 (COMPILE.pre, CC_LD): Use CXX directly.
2171 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
2172 * acinclude.m4: Don't include build-with-cxx.m4.
2173 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
2174 * configure: Regenerate.
2175
c1da6748
AT
21762016-09-02 Akash Trehan <akash.trehan123@gmail.com>
2177
2178 PR gdb/19495
2179 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
2180 call writing data to own_buf.
2181
f2b9e3df
SDJ
21822016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2183
2184 * target.c (mywait): Call target_wait instead of
2185 the_target->wait.
2186 (target_wait): New function.
2187
049a8570
SDJ
21882016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2189
2190 * server.c (start_inferior): New variable 'ptid'. Replace calls
2191 to the_target->resume by target_continue{,_no_signal}, depending
2192 on the case.
2193 * target.c (target_stop_and_wait): Call target_continue_no_signal
2194 instead of the_target->resume.
2195 (target_continue): New function.
2196
3aa5cfa0
AT
21972016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
2198
2199 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
2200
754653a7
AZ
22012016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
2202
2203 PR server/20491
2204 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
2205 ps_prochandle.
2206 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
2207 * linux-arm-low.c (ps_get_thread_area): Likewise.
2208 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
2209 * linux-m68k-low.c (ps_get_thread_area): Likewise.
2210 * linux-mips-low.c (ps_get_thread_area): Likewise.
2211 * linux-nios2-low.c (ps_get_thread_area): Likewise.
2212 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
2213 * linux-x86-low.c (ps_get_thread_area): Likewise.
2214 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
2215
ed036b40
PA
22162016-08-19 Pedro Alves <palves@redhat.com>
2217
2218 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
2219
c8ef42ee
PA
22202016-08-19 Pedro Alves <palves@redhat.com>
2221
2222 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
2223 comment. Use memcpy instead of casting through unsigned long.
2224
9c235a72
PA
22252016-08-19 Pedro Alves <palves@redhat.com>
2226
2227 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
2228 allocating around 0x80000000.
2229
201506da
PA
22302016-08-19 Pedro Alves <palves@redhat.com>
2231
2232 PR gdb/20415
2233 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
2234 (x32-avx512-linux-ipa.o): New rules.
2235 * configure.ac (x86_64-*-linux*): New x32 check.
2236 * configure.srv (ipa_x32_linux_regobj): New.
2237 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
2238 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
2239 descriptions.
2240 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
2241 descriptions.
2242 * configure: Regenerate.
2243
f348d89a
PA
22442016-08-09 Pedro Alves <palves@redhat.com>
2245
2246 PR gdb/18653
2247 * Makefile.in (OBS): Add signals-state-save-restore.o.
2248 (signals-state-save-restore.o): New rule.
2249 * config.in: Regenerate.
2250 * configure: Regenerate.
2251 * linux-low.c: Include "signals-state-save-restore.h".
2252 (linux_create_inferior): Call
2253 restore_original_signals_state.
2254 * server.c: Include "dispositions-save-restore.h".
2255 (captured_main): Call save_original_signals_state.
2256
1baf5149
PA
22572016-08-05 Pedro Alves <palves@redhat.com>
2258
2259 * configure: Regenerate.
2260
fcd4a73d
YQ
22612016-08-04 Yao Qi <yao.qi@linaro.org>
2262
2263 * linux-low.c (regsets_fetch_inferior_registers): Check
2264 errno is ESRCH or not.
2265
979659d0
YQ
22662016-08-02 Yao Qi <yao.qi@linaro.org>
2267
2268 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
2269 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
2270 (thread_db_load_search): Update.
2271 (try_thread_db_load_1): Don't look for td_ta_event_addr,
2272 td_ta_set_event and td_ta_event_getmsg.
2273
6598661d
PA
22742016-07-26 Pedro Alves <palves@redhat.com>
2275
2276 PR server/20414
2277 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
2278 of unsigned long for 64-bit registers and use uint32_t instead of
2279 unsigned int for 32-bit registers.
2280
9cf12d57
PA
22812016-07-26 Pedro Alves <palves@redhat.com>
2282
2283 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
2284 to 'ptrace'.
2285
305450ed
TT
22862016-07-21 Tom Tromey <tom@tromey.com>
2287
2288 * configure: Rebuild.
2289
2583da7c
YQ
22902016-07-21 Yao Qi <yao.qi@linaro.org>
2291
2292 * mem-break.c (find_gdb_breakpoint): Cast bp to
2293 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
2294
21536b36
YQ
22952016-07-21 Yao Qi <yao.qi@linaro.org>
2296
2297 * server.c (handle_v_requests): Support s and S actions
2298 if target_supports_software_single_step return true.
2299
8901d193
YQ
23002016-07-21 Yao Qi <yao.qi@linaro.org>
2301
2302 * linux-low.c (resume_stopped_resumed_lwps): If resume request
2303 is resume_step, call maybe_hw_step.
2304 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
2305 and unstop them.
2306 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
2307 breakpoints or not.
2308 (proceed_one_lwp): If resume request is resume_step, install
2309 reinsert breakpoints and call maybe_hw_step.
2310
0e9a339e
YQ
23112016-07-21 Yao Qi <yao.qi@linaro.org>
2312
2313 * linux-low.c (proceed_one_lwp): Declare.
2314 (linux_resume_one_thread): Remove local variable 'step'.
2315 Lift code enqueue signal. Call proceed_one_lwp instead of
2316 linux_resume_one_lwp.
2317
4281b351
YQ
23182016-07-21 Yao Qi <yao.qi@linaro.org>
2319
2320 * linux-low.c (linux_resume_one_thread): Call
2321 enqueue_pending_signal.
2322
984a2c04
YQ
23232016-07-21 Yao Qi <yao.qi@linaro.org>
2324
2325 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
2326 * inferiors.c (do_restore_current_thread_cleanup): New function.
2327 (make_cleanup_restore_current_thread): Likewise.
2328 * linux-low.c (install_software_single_step_breakpoints): Call
2329 make_cleanup_restore_current_thread. Switch current_thread to
2330 thread.
2331
bec903c9
YQ
23322016-07-21 Yao Qi <yao.qi@linaro.org>
2333
2334 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
2335 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
2336 (clone_one_breakpoint): Likewise.
2337 (delete_reinsert_breakpoints): Change parameter to thread.
2338 Callers updated.
2339 (has_reinsert_breakpoints): Likewise.
2340 (uninsert_reinsert_breakpoints): Likewise.
2341 (reinsert_reinsert_breakpoints): Likewise.
2342 * mem-break.h (set_reinsert_breakpoint): Update declaration.
2343 (delete_reinsert_breakpoints): Likewise.
2344 (reinsert_reinsert_breakpoints): Likewise.
2345 (uninsert_reinsert_breakpoints): Likewise.
2346 (has_reinsert_breakpoints): Likewise.
2347
63c40ec7
YQ
23482016-07-21 Yao Qi <yao.qi@linaro.org>
2349
2350 * inferiors.c (get_thread_process): Make parameter const.
2351 * inferiors.h (get_thread_process): Update declaration.
2352 * mem-break.c (clone_all_breakpoints): Remove all parameters.
2353 Add new parameters child_thread and parent_thread. Callers
2354 updated.
2355 * mem-break.h (clone_all_breakpoints): Update declaration.
2356
9aa76cd0
YQ
23572016-07-21 Yao Qi <yao.qi@linaro.org>
2358
2359 * mem-break.c (struct breakpoint) <cond_list>: Remove.
2360 <command_list, handler>: Remove.
2361 (struct gdb_breakpoint): New.
2362 (struct other_breakpoint): New.
2363 (struct reinsert_breakpoint): New.
2364 (is_gdb_breakpoint): New function.
2365 (any_persistent_commands): Update command_list if
2366 is_gdb_breakpoint returns true.
2367 (set_breakpoint): Create breakpoints according to their types.
2368 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
2369 (set_gdb_breakpoint_1): Likewise.
2370 (set_gdb_breakpoint): Likewise.
2371 (clear_breakpoint_conditions): Change parameter type to
2372 'struct gdb_breakpoint *'.
2373 (clear_breakpoint_commands): Likewise.
2374 (clear_breakpoint_conditions_and_commands): Likewise.
2375 (add_condition_to_breakpoint): Likewise.
2376 (add_breakpoint_condition): Likewise.
2377 (add_commands_to_breakpoint): Likewise.
2378 (check_breakpoints): Check other_breakpoint.
2379 (clone_one_breakpoint): Clone breakpopint according to its type.
2380 * mem-break.h (struct gdb_breakpoint): Declare.
2381 (set_gdb_breakpoint): Update declaration.
2382 (clear_breakpoint_conditions_and_commands): Likewise.
2383 (add_breakpoint_condition): Likewise.
2384 (add_breakpoint_commands): Likewise.
2385 * server.c (process_point_options): Change parameter type to
2386 'struct gdb_breakpoint *'.
2387
811f8301
YQ
23882016-07-21 Yao Qi <yao.qi@linaro.org>
2389
2390 * mem-break.c (set_breakpoint_at): Rename it to ...
2391 (set_breakpoint_type_at): ... it.
2392 (set_breakpoint_at): Call set_breakpoint_type_at.
2393 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
2394 * mem-break.h (set_breakpoint_at): Update comments.
2395
b1c51e36
CLT
23962016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
2397
2398 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
2399 to buf parameter.
2400 (nios2_store_gregset): Likewise.
2401
ced2dffb
PA
24022016-07-01 Pedro Alves <palves@redhat.com>
2403 Antoine Tremblay <antoine.tremblay@ericsson.com>
2404
2405 * linux-low.c: Change interface to take the target lwp_info
2406 pointer directly and return void. Handle detaching from a zombie
2407 thread.
2408 (linux_detach_lwp_callback): New function.
2409 (linux_detach): Detach from the leader thread after detaching from
2410 the clone threads.
2411
2ac09a5b
YQ
24122016-06-28 Yao Qi <yao.qi@linaro.org>
2413
2414 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
2415 for variable new_offset.
2416 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
2417 (aarch64_ftrace_insn_reloc_cb): Likewise.
2418 (aarch64_ftrace_insn_reloc_tb): Likewise.
2419 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
2420 PRIx64 instead of PRIx32.
2421
79e7fd4f
YQ
24222016-06-28 Yao Qi <yao.qi@linaro.org>
2423
2424 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
2425 (the_low_target): Install arm_get_syscall_trapinfo.
2426
061fc021
YQ
24272016-06-28 Yao Qi <yao.qi@linaro.org>
2428
2429 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
2430 function.
2431 (the_low_target): Install aarch64_get_syscall_trapinfo.
2432
4cc32bec
YQ
24332016-06-28 Yao Qi <yao.qi@linaro.org>
2434
2435 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
2436 Callers updated.
2437 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
2438 Remove parameter sysno.
2439 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
2440 sysret.
2441
782c1122
AA
24422016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2443
2444 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
2445 (s390_emit_ne_goto): Likewise.
2446 (s390_emit_lt_goto): Likewise.
2447 (s390_emit_le_goto): Likewise.
2448 (s390_emit_gt_goto): Likewise.
2449 (s390_emit_ge_goto): Likewise.
2450 (s390x_emit_eq_goto): Likewise.
2451 (s390x_emit_ne_goto): Likewise.
2452 (s390x_emit_lt_goto): Likewise.
2453 (s390x_emit_le_goto): Likewise.
2454 (s390x_emit_gt_goto): Likewise.
2455 (s390x_emit_ge_goto): Likewise.
2456 (s390_emit_ops_impl): Mark variable static.
2457 (s390x_emit_ops): Likewise.
2458
2e7b624b
YQ
24592016-06-17 Yao Qi <yao.qi@linaro.org>
2460
2461 * linux-low.c (handle_extended_wait): Call
2462 uninsert_reinsert_breakpoints for the parent process. Remove
2463 reinsert breakpoints from the child process. Reinsert them to
2464 the parent process when vfork is done.
2465 * mem-break.c (uninsert_reinsert_breakpoints): New function.
2466 (reinsert_reinsert_breakpoints): New function.
2467 * mem-break.h (uninsert_reinsert_breakpoints): Declare
2468 (reinsert_reinsert_breakpoints): Declare.
2469
8a81c5d7
YQ
24702016-06-17 Yao Qi <yao.qi@linaro.org>
2471
2472 * linux-low.c (handle_extended_wait): If the parent is doing
2473 step-over, remove the reinsert breakpoints from the forked child.
2474
f50bf8e5
YQ
24752016-06-17 Yao Qi <yao.qi@linaro.org>
2476
2477 * linux-low.c (unsuspend_all_lwps): Declare.
2478 (linux_low_filter_event): If thread exited, call finish_step_over.
2479 If step-over is finished, unsuspend other threads.
2480
8376a3cb
YQ
24812016-06-17 Yao Qi <yao.qi@linaro.org>
2482
2483 * linux-low.c (linux_resume_one_lwp_throw): Assert
2484 has_reinsert_breakpoints returns false.
2485 * mem-break.c (delete_disabled_breakpoints): Assert
2486 bp type isn't reinsert_breakpoint.
2487
f79b145d
YQ
24882016-06-17 Yao Qi <yao.qi@linaro.org>
2489
2490 * linux-low.c (maybe_hw_step): New function.
2491 (linux_resume_one_lwp_throw): Call maybe_hw_step.
2492 (finish_step_over): Switch current_thread to lwp temporarily,
2493 and assert has_reinsert_breakpoints returns true.
2494 (proceed_one_lwp): Call maybe_hw_step.
2495 * mem-break.c (has_reinsert_breakpoints): New function.
2496 * mem-break.h (has_reinsert_breakpoints): Declare.
2497
0ae534d2
JT
24982016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
2499
2500 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
2501
fcdad592
YQ
25022016-05-17 Yao Qi <yao.qi@linaro.org>
2503
2504 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
2505 instead of find_inferior.
2506
9e784964
YQ
25072016-05-05 Yao Qi <yao.qi@linaro.org>
2508
2509 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
2510 Initialize res to zero.
2511
cf2ebb6e
YQ
25122016-05-05 Yao Qi <yao.qi@linaro.org>
2513
2514 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
2515 to uint32_t.
2516
c1aebf87
UW
25172016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
2518
2519 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
2520 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
2521 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
2522
35fd2deb 25232016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 2524 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
2525
2526 * tracepoint.c (write_inferior_int8): New function.
2527 (cmd_qtenable_disable): Write enable flag using
2528 write_inferior_int8.
2529
484b3c32
YQ
25302016-04-25 Yao Qi <yao.qi@linaro.org>
2531
2532 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
2533 (need_step_over_p): Return zero if the LWP has pending signals
2534 can be delivered on software single step target.
2535
85ba7d86
YQ
25362016-04-25 Yao Qi <yao.qi@linaro.org>
2537
2538 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
2539 return instead of error.
2540
3539aa13
YQ
25412016-04-22 Yao Qi <yao.qi@linaro.org>
2542
2543 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
2544 to 23.
2545
5b061e98
YQ
25462016-04-22 Yao Qi <yao.qi@linaro.org>
2547
2548 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
2549 signal when stepping over breakpoint with software single
2550 step.
2551
3451269c
PA
25522016-04-21 Pedro Alves <palves@redhat.com>
2553
2554 * linux-s390-low.c (s390_collect_ptrace_register)
2555 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
2556 add casts.
2557 (s390_check_regset): Use void * instead of gdb_byte *.
2558
a2358508
PA
25592016-04-20 Pedro Alves <palves@redhat.com>
2560
2561 * configure: Renegerate.
2562
6885166d
YQ
25632016-04-20 Yao Qi <yao.qi@linaro.org>
2564
2565 * linux-aarch32-low.c: Include "arch/arm-linux.h".
2566 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
2567 number 16.
2568 (arm_store_gregset): Likewise.
2569
2b863f51
WT
25702016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
2571
2572 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
2573 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
2574 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
2575 (amd64-avx-mpx-linux.c): New rules.
2576 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
2577 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
2578 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
2579 (srv_amd64_regobj): Add amd64-avx-mpx.o.
2580 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
2581 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
2582 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
2583 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
2584 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
2585 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
2586 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
2587 * linux-x86-low.c (x86_linux_read_description): Add case for
2588 X86_XSTATE_AVX_MPX_MASK.
2589 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
2590 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
2591 init_registers_i386_avx_mpx_linux.
2592 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
2593 (initialize_low_tracepoint): Call
2594 init_registers_i386_avx_mpx_linux.
2595 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
2596 (initialize_low_tracepoint): Call
2597 init_registers_amd64_avx_mpx_linux.
2598 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
2599 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
2600 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
2601 declarations.
2602
9b30624b
PA
26032016-04-18 Pedro Alves <palves@redhat.com>
2604
2605 * configure: Regenerate.
2606
45e3745e
AT
26072016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
2608
2609 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
2610 (aarch64_emit_sub): Likewise.
2611
2afc13ff
PA
26122016-04-12 Pedro Alves <palves@redhat.com>
2613
2614 * utils.c (prepare_to_throw_exception): Delete.
2615
6e774b13
SM
26162016-04-05 Simon Marchi <simon.marchi@ericsson.com>
2617
2618 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
2619
4dca19f8
MK
26202016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
2621
2622 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
2623
d0a9981f
MK
26242016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
2625
2626 * linux-aarch64-ipa.c: Add <elf.h> include.
2627 * linux-ppc-ipa.c: Add <elf.h> include.
2628 * linux-s390-ipa.c: Add <elf.h> include.
2629
252db07e
MK
26302016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
2631
2632 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
2633 (get_raw_reg_ptr): Likewise.
2634 (get_trace_state_variable_value_ptr): Likewise.
2635 (set_trace_state_variable_value_ptr): Likewise.
2636 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
2637 char *.
2638
14e2b6d9
MK
26392016-03-31 Wei-cheng Wang <cole945@gmail.com>
2640 Marcin Kościelnicki <koriakin@0x04.net>
2641
2642 PR/17221
2643 * linux-ppc-low.c (emit_insns): New function.
2644 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
2645 (ppc_emit_prologue): New function.
2646 (ppc_emit_epilogue): New function.
2647 (ppc_emit_add): New function.
2648 (ppc_emit_sub): New function.
2649 (ppc_emit_mul): New function.
2650 (ppc_emit_lsh): New function.
2651 (ppc_emit_rsh_signed): New function.
2652 (ppc_emit_rsh_unsigned): New function.
2653 (ppc_emit_ext): New function.
2654 (ppc_emit_zero_ext): New function.
2655 (ppc_emit_log_not): New function.
2656 (ppc_emit_bit_and): New function.
2657 (ppc_emit_bit_or): New function.
2658 (ppc_emit_bit_xor): New function.
2659 (ppc_emit_bit_not): New function.
2660 (ppc_emit_equal): New function.
2661 (ppc_emit_less_signed): New function.
2662 (ppc_emit_less_unsigned): New function.
2663 (ppc_emit_ref): New function.
2664 (ppc_emit_const): New function.
2665 (ppc_emit_reg): New function.
2666 (ppc_emit_pop): New function.
2667 (ppc_emit_stack_flush): New function.
2668 (ppc_emit_swap): New function.
2669 (ppc_emit_stack_adjust): New function.
2670 (ppc_emit_call): New function.
2671 (ppc_emit_int_call_1): New function.
2672 (ppc_emit_void_call_2): New function.
2673 (ppc_emit_if_goto): New function.
2674 (ppc_emit_goto): New function.
2675 (ppc_emit_eq_goto): New function.
2676 (ppc_emit_ne_goto): New function.
2677 (ppc_emit_lt_goto): New function.
2678 (ppc_emit_le_goto): New function.
2679 (ppc_emit_gt_goto): New function.
2680 (ppc_emit_ge_goto): New function.
2681 (ppc_write_goto_address): New function.
2682 (ppc_emit_ops_impl): New static variable.
2683 (ppc64v1_emit_prologue): New function.
2684 (ppc64v2_emit_prologue): New function.
2685 (ppc64_emit_epilogue): New function.
2686 (ppc64_emit_add): New function.
2687 (ppc64_emit_sub): New function.
2688 (ppc64_emit_mul): New function.
2689 (ppc64_emit_lsh): New function.
2690 (ppc64_emit_rsh_signed): New function.
2691 (ppc64_emit_rsh_unsigned): New function.
2692 (ppc64_emit_ext): New function.
2693 (ppc64_emit_zero_ext): New function.
2694 (ppc64_emit_log_not): New function.
2695 (ppc64_emit_bit_and): New function.
2696 (ppc64_emit_bit_or): New function.
2697 (ppc64_emit_bit_xor): New function.
2698 (ppc64_emit_bit_not): New function.
2699 (ppc64_emit_equal): New function.
2700 (ppc64_emit_less_signed): New function.
2701 (ppc64_emit_less_unsigned): New function.
2702 (ppc64_emit_ref): New function.
2703 (ppc64_emit_const): New function.
2704 (ppc64v1_emit_reg): New function.
2705 (ppc64v2_emit_reg): New function.
2706 (ppc64_emit_pop): New function.
2707 (ppc64_emit_stack_flush): New function.
2708 (ppc64_emit_swap): New function.
2709 (ppc64v1_emit_call): New function.
2710 (ppc64v2_emit_call): New function.
2711 (ppc64v1_emit_int_call_1): New function.
2712 (ppc64v2_emit_int_call_1): New function.
2713 (ppc64v1_emit_void_call_2): New function.
2714 (ppc64v2_emit_void_call_2): New function.
2715 (ppc64_emit_if_goto): New function.
2716 (ppc64_emit_eq_goto): New function.
2717 (ppc64_emit_ne_goto): New function.
2718 (ppc64_emit_lt_goto): New function.
2719 (ppc64_emit_le_goto): New function.
2720 (ppc64_emit_gt_goto): New function.
2721 (ppc64_emit_ge_goto): New function.
2722 (ppc64v1_emit_ops_impl): New static variable.
2723 (ppc64v2_emit_ops_impl): New static variable.
2724 (ppc_emit_ops): New function.
2725 (linux_low_target): Wire in ppc_emit_ops.
2726
a2174ba4
MK
27272016-03-31 Wei-cheng Wang <cole945@gmail.com>
2728 Marcin Kościelnicki <koriakin@0x04.net>
2729
2730 PR/17221
2731 * Makefile.in: Add powerpc-*-ipa.o
2732 * configure.srv: Add ipa_obj for powerpc*-linux.
2733 * linux-ppc-ipa.c: New file.
2734 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
2735 includes.
2736 (PPC_FIELD): New macro.
2737 (PPC_SEXT): New macro.
2738 (PPC_OP6): New macro.
2739 (PPC_BO): New macro.
2740 (PPC_LI): New macro.
2741 (PPC_BD): New macro.
2742 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
2743 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
2744 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
2745 (ppc_get_thread_area): New function.
2746 (is_elfv2_inferior): New function.
2747 (gen_ds_form): New function.
2748 (GEN_STD): New macro.
2749 (GEN_STDU): New macro.
2750 (GEN_LD): New macro.
2751 (GEN_LDU): New macro.
2752 (gen_d_form): New function.
2753 (GEN_ADDI): New macro.
2754 (GEN_ADDIS): New macro.
2755 (GEN_LI): New macro.
2756 (GEN_LIS): New macro.
2757 (GEN_ORI): New macro.
2758 (GEN_ORIS): New macro.
2759 (GEN_LWZ): New macro.
2760 (GEN_STW): New macro.
2761 (GEN_STWU): New macro.
2762 (gen_xfx_form): New function.
2763 (GEN_MFSPR): New macro.
2764 (GEN_MTSPR): New macro.
2765 (GEN_MFCR): New macro.
2766 (GEN_MTCR): New macro.
2767 (GEN_SYNC): New macro.
2768 (GEN_LWSYNC): New macro.
2769 (gen_x_form): New function.
2770 (GEN_OR): New macro.
2771 (GEN_MR): New macro.
2772 (GEN_LWARX): New macro.
2773 (GEN_STWCX): New macro.
2774 (GEN_CMPW): New macro.
2775 (gen_md_form): New function.
2776 (GEN_RLDICL): New macro.
2777 (GEN_RLDICR): New macro.
2778 (gen_i_form): New function.
2779 (GEN_B): New macro.
2780 (GEN_BL): New macro.
2781 (gen_b_form): New function.
2782 (GEN_BNE): New macro.
2783 (GEN_LOAD): New macro.
2784 (GEN_STORE): New macro.
2785 (gen_limm): New function.
2786 (gen_atomic_xchg): New function.
2787 (gen_call): New function.
2788 (ppc_relocate_instruction): New function.
2789 (ppc_install_fast_tracepoint_jump_pad): New function.
2790 (ppc_get_min_fast_tracepoint_insn_len): New function.
2791 (ppc_get_ipa_tdesc_idx): New function.
2792 (the_low_target): Wire in the new functions.
2793 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
2794 tdescs.
2795 * linux-ppc-tdesc.h: New file.
2796
a13c4696
MK
27972016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
2798
2799 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
2800 (alloc_jump_pad_buffer): New function.
2801 * linux-amd64-ipa.c: Add <sys/mman.h> include.
2802 (alloc_jump_pad_buffer): New function.
2803 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
2804 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
2805 (alloc_jump_pad_buffer): New function.
2806 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
2807 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
2808 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
2809 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
2810
1cda1512
MK
28112016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
2812
2813 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
2814 * linux-amd64-ipa.c: Likewise.
2815 * linux-i386-ipa.c: Likewise.
2816 * linux-s390-ipa.c: Likewise.
2817 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
2818 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
2819 set_trace_state_variable_value_ptr.
2820 (struct ipa_sym_addresses): Likewise.
2821 (symbol_list): Likewise.
2822 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
2823 accessing gdb_collect directly.
2824 (gdb_collect_ptr_type): New typedef.
2825 (get_raw_reg_ptr_type): New typedef.
2826 (get_trace_state_variable_value_ptr_type): New typedef.
2827 (set_trace_state_variable_value_ptr_type): New typedef.
2828 (gdb_collect_ptr): New global.
2829 (get_raw_reg_ptr): New global.
2830 (get_trace_state_variable_value_ptr): New global.
2831 (set_trace_state_variable_value_ptr): New global.
2832 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
2833 accessing get_raw_reg directly.
2834 (get_get_tsv_func_addr): Likewise for
2835 get_trace_state_variable_value_ptr.
2836 (get_set_tsv_func_addr): Likewise for
2837 set_trace_state_variable_value_ptr.
2838 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
2839
72fb5488
SM
28402016-03-30 Simon Marchi <simon.marchi@ericsson.com>
2841
2842 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
2843
28170b88
MK
28442016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
2845
2846 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
2847 packets.
2848 (relocate_instruction): Remove own_buf.
2849 * server.c (own_buf): Make global.
2850 (handle_v_requests): Make global.
2851 * server.h (own_buf): New declaration.
2852 (handle_v_requests): New prototype.
2853
f39e8743
MK
28542016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
2855
2856 PR 18377
2857 * linux-s390-low.c (add_insns): New function.
2858 (s390_emit_prologue): New function.
2859 (s390_emit_epilogue): New function.
2860 (s390_emit_add): New function.
2861 (s390_emit_sub): New function.
2862 (s390_emit_mul): New function.
2863 (s390_emit_lsh): New function.
2864 (s390_emit_rsh_signed): New function.
2865 (s390_emit_rsh_unsigned): New function.
2866 (s390_emit_ext): New function.
2867 (s390_emit_log_not): New function.
2868 (s390_emit_bit_and): New function.
2869 (s390_emit_bit_or): New function.
2870 (s390_emit_bit_xor): New function.
2871 (s390_emit_bit_not): New function.
2872 (s390_emit_equal): New function.
2873 (s390_emit_less_signed): New function.
2874 (s390_emit_less_unsigned): New function.
2875 (s390_emit_ref): New function.
2876 (s390_emit_if_goto): New function.
2877 (s390_emit_goto): New function.
2878 (s390_write_goto_address): New function.
2879 (s390_emit_litpool): New function.
2880 (s390_emit_const): New function.
2881 (s390_emit_call): New function.
2882 (s390_emit_reg): New function.
2883 (s390_emit_pop): New function.
2884 (s390_emit_stack_flush): New function.
2885 (s390_emit_zero_ext): New function.
2886 (s390_emit_swap): New function.
2887 (s390_emit_stack_adjust): New function.
2888 (s390_emit_set_r2): New function.
2889 (s390_emit_int_call_1): New function.
2890 (s390_emit_void_call_2): New function.
2891 (s390_emit_eq_goto): New function.
2892 (s390_emit_ne_goto): New function.
2893 (s390_emit_lt_goto): New function.
2894 (s390_emit_le_goto): New function.
2895 (s390_emit_gt_goto): New function.
2896 (s390_emit_ge_goto): New function.
2897 (s390x_emit_prologue): New function.
2898 (s390x_emit_epilogue): New function.
2899 (s390x_emit_add): New function.
2900 (s390x_emit_sub): New function.
2901 (s390x_emit_mul): New function.
2902 (s390x_emit_lsh): New function.
2903 (s390x_emit_rsh_signed): New function.
2904 (s390x_emit_rsh_unsigned): New function.
2905 (s390x_emit_ext): New function.
2906 (s390x_emit_log_not): New function.
2907 (s390x_emit_bit_and): New function.
2908 (s390x_emit_bit_or): New function.
2909 (s390x_emit_bit_xor): New function.
2910 (s390x_emit_bit_not): New function.
2911 (s390x_emit_equal): New function.
2912 (s390x_emit_less_signed): New function.
2913 (s390x_emit_less_unsigned): New function.
2914 (s390x_emit_ref): New function.
2915 (s390x_emit_if_goto): New function.
2916 (s390x_emit_const): New function.
2917 (s390x_emit_call): New function.
2918 (s390x_emit_reg): New function.
2919 (s390x_emit_pop): New function.
2920 (s390x_emit_stack_flush): New function.
2921 (s390x_emit_zero_ext): New function.
2922 (s390x_emit_swap): New function.
2923 (s390x_emit_stack_adjust): New function.
2924 (s390x_emit_int_call_1): New function.
2925 (s390x_emit_void_call_2): New function.
2926 (s390x_emit_eq_goto): New function.
2927 (s390x_emit_ne_goto): New function.
2928 (s390x_emit_lt_goto): New function.
2929 (s390x_emit_le_goto): New function.
2930 (s390x_emit_gt_goto): New function.
2931 (s390x_emit_ge_goto): New function.
2932 (s390_emit_ops): New function.
2933 (struct linux_target_ops): Fill in emit_ops hook.
2934
abd9baf9
MK
29352016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
2936
2937 PR 18377
2938 * Makefile.in: Add s390 IPA files.
2939 * configure.srv: Build IPA for s390.
2940 * linux-s390-ipa.c: New file.
2941 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
2942 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
2943 (tdesc_s390_linux32): Likewise.
2944 (init_registers_s390_linux32v1): Likewise.
2945 (tdesc_s390_linux32v1): Likewise.
2946 (init_registers_s390_linux32v2): Likewise.
2947 (tdesc_s390_linux32v2): Likewise.
2948 (init_registers_s390_linux64): Likewise.
2949 (tdesc_s390_linux64): Likewise.
2950 (init_registers_s390_linux64v1): Likewise.
2951 (tdesc_s390_linux64v1): Likewise.
2952 (init_registers_s390_linux64v2): Likewise.
2953 (tdesc_s390_linux64v2): Likewise.
2954 (init_registers_s390_te_linux64): Likewise.
2955 (tdesc_s390_te_linux64): Likewise.
2956 (init_registers_s390_vx_linux64): Likewise.
2957 (tdesc_s390_vx_linux64): Likewise.
2958 (init_registers_s390_tevx_linux64): Likewise.
2959 (tdesc_s390_tevx_linux64): Likewise.
2960 (init_registers_s390x_linux64): Likewise.
2961 (tdesc_s390x_linux64): Likewise.
2962 (init_registers_s390x_linux64v1): Likewise.
2963 (tdesc_s390x_linux64v1): Likewise.
2964 (init_registers_s390x_linux64v2): Likewise.
2965 (tdesc_s390x_linux64v2): Likewise.
2966 (init_registers_s390x_te_linux64): Likewise.
2967 (tdesc_s390x_te_linux64): Likewise.
2968 (init_registers_s390x_vx_linux64): Likewise.
2969 (tdesc_s390x_vx_linux64): Likewise.
2970 (init_registers_s390x_tevx_linux64): Likewise.
2971 (tdesc_s390x_tevx_linux64): Likewise.
2972 (have_hwcap_s390_vx): New static variable.
2973 (s390_arch_setup): Fill have_hwcap_s390_vx.
2974 (s390_get_thread_area): New function.
2975 (s390_ft_entry_gpr_esa): New const.
2976 (s390_ft_entry_gpr_zarch): New const.
2977 (s390_ft_entry_misc): New const.
2978 (s390_ft_entry_fr): New const.
2979 (s390_ft_entry_vr): New const.
2980 (s390_ft_main_31): New const.
2981 (s390_ft_main_64): New const.
2982 (s390_ft_exit_fr): New const.
2983 (s390_ft_exit_vr): New const.
2984 (s390_ft_exit_misc): New const.
2985 (s390_ft_exit_gpr_esa): New const.
2986 (s390_ft_exit_gpr_zarch): New const.
2987 (append_insns): New function.
2988 (s390_relocate_instruction): New function.
2989 (s390_install_fast_tracepoint_jump_pad): New function.
2990 (s390_get_min_fast_tracepoint_insn_len): New function.
2991 (s390_get_ipa_tdesc_idx): New function.
2992 (struct linux_target_ops): Wire in the above functions.
2993 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
2994 * linux-s390-tdesc.h: New file.
2995
a4105d04
MK
29962016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
2997
2998 * linux-s390-low.c (s390_supports_tracepoints): New function.
2999 (struct linux_target_ops): Fill supports_tracepoints hook.
3000
35ac8b3e
YQ
30012016-03-18 Yao Qi <yao.qi@linaro.org>
3002
3003 * linux-low.c (lwp_signal_can_be_delivered): New function.
3004 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
3005
94610ec4
YQ
30062016-03-18 Yao Qi <yao.qi@linaro.org>
3007
3008 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
3009 0 if signal is enqueued. Remove 'signal' from one debugging
3010 message. Move one debugging message to some lines below.
3011 Remove code setting 'signal' to 0.
3012
80aea927
YQ
30132016-03-18 Yao Qi <yao.qi@linaro.org>
3014
3015 * linux-low.c (linux_low_filter_event): Remove redundant
3016 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
3017
b04fd3be
MK
30182016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
3019
3020 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
3021 (struct linux_target_ops): Wire in the above.
3022
c40c8d4b
YQ
30232016-03-03 Yao Qi <yao.qi@linaro.org>
3024
3025 * linux-low.c: Update comments to start_step_over.
3026
0f8288ae
YQ
30272016-03-03 Yao Qi <yao.qi@linaro.org>
3028
3029 PR server/19736
3030 * linux-low.c (handle_extended_wait): Set child suspended
3031 if event_lwp->bp_reinsert isn't zero.
3032
fdbd04a8
YQ
30332016-03-02 Yao Qi <yao.qi@linaro.org>
3034
3035 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
3036 enqueue_pending_signal.
3037
6896a8fa
MK
30382016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
3039
3040 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
3041 is actually loaded.
3042
ab503087
MK
30432016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3044
3045 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
3046 (s390_regmap_3264) [!__s390x__]: New global.
3047 (s390_collect_ptrace_register): Skip map entries containing -1.
3048 (s390_supply_ptrace_register): Ditto.
3049 (s390_fill_gprs_high): New function.
3050 (s390_store_gprs_high): New function.
3051 (s390_regsets): Add NT_S390_HIGH_GPRS.
3052 (s390_get_hwcap): Enable on 31-bit.
3053 (have_hwcap_s390_high_gprs): Enable on 31-bit.
3054 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
3055 Detect NT_S390_HIGH_GPRS.
3056 (s390_usrregs_info_3264): Enable on 31-bit.
3057 (s390_regs_info): Enable regs_info_3264 on 31-bit.
3058 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
3059
ae91f625
MK
30602016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3061
3062 PR gdb/13808
3063 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
3064 * configure.srv: Ditto.
3065 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
3066 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
3067 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
3068 (init_registers_amd64_linux): Remove prototype.
3069 (tdesc_amd64_linux): Remove declaration.
3070 (get_ipa_tdesc): New function.
3071 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3072 initialize remaining tdescs.
3073 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
3074 (init_registers_i386_linux): Remove prototype.
3075 (tdesc_i386_linux): Remove declaration.
3076 (get_ipa_tdesc): New function.
3077 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3078 initialize remaining tdescs.
3079 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
3080 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
3081 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
3082 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
3083 (x86_get_ipa_tdesc_idx): New function.
3084 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
3085 * linux-x86-tdesc.h: New file.
3086 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
3087 (target_get_ipa_tdesc_idx): New macro.
3088 * tracepoint.c (ipa_tdesc_idx): New macro.
3089 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
3090 (symbol_list): Add ipa_tdesc_idx.
3091 (cmd_qtstart): Write ipa_tdesc_idx in the target.
3092 (ipa_tdesc): Remove.
3093 (ipa_tdesc_idx): New variable.
3094 (get_context_regcache): Use get_ipa_tdesc.
3095 (gdb_collect): Ditto.
3096 (gdb_probe): Ditto.
3097 * tracepoint.h (get_ipa_tdesc): New prototype.
3098 (ipa_tdesc): Remove.
3099
e7ad2f14
PA
31002016-02-24 Pedro Alves <palves@redhat.com>
3101
3102 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
3103 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
3104 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
3105 Factor out common code between the USE_SIGTRAP_SIGINFO and
3106 !USE_SIGTRAP_SIGINFO blocks.
3107 (linux_low_filter_event): Call save_stop_reason instead of
3108 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
3109 Update comments.
3110 (linux_wait_1): Update comments.
3111
657f9cde
WW
31122016-02-24 Wei-cheng Wang <cole945@gmail.com>
3113
3114 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
3115 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
3116 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
3117 ppc_insert_point, ppc_remove_point.
3118
b00b61e1
MK
31192016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
3120
3121 * linux-s390-low.c (s390_supports_z_point_type): New function.
3122 (struct linux_target_ops): Wire s390_supports_z_point_type in.
3123
553cb527
YQ
31242016-02-16 Yao Qi <yao.qi@linaro.org>
3125
3126 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
3127 PC. Get pc from regcache_read_pc.
3128
a5652c21
YQ
31292016-02-12 Yao Qi <yao.qi@linaro.org>
3130
3131 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
3132 or linux_get_pc_32bit.
3133 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
3134
ed443b61
YQ
31352016-02-12 Yao Qi <yao.qi@linaro.org>
3136
3137 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
3138 arm_linux_get_next_pcs_fixup.
3139
020ecd38
MK
31402016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
3141
3142 * tracepoint.c (x_tracepoint_action_download): Change
3143 write_inferior_data_ptr to write_inferior_data_pointer.
3144 (cmd_qtstart): Likewise.
3145 (write_inferior_data_ptr): Remove.
3146 (download_agent_expr): Change write_inferior_data_ptr to
3147 write_inferior_data_pointer.
3148 (download_tracepoint_1): Likewise.
3149 (download_tracepoint): Likewise.
3150 (download_trace_state_variables): Likewise.
3151
7cae9051
WW
31522016-02-11 Wei-cheng Wang <cole945@gmail.com>
3153 Marcin Kościelnicki <koriakin@0x04.net>
3154
3155 * tracepoint.c (struct tracepoint_action_ops): Remove.
3156 (struct tracepoint_action): Remove ops.
3157 (m_tracepoint_action_download, r_tracepoint_action_download)
3158 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
3159 size and offset accordingly.
3160 (m_tracepoint_action_ops, r_tracepoint_action_ops)
3161 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
3162 (tracepoint_action_send, tracepoint_action_download): New functions.
3163 Helpers for trace action handlers.
3164 (add_tracepoint_action): Remove setup actions ops.
3165 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
3166
9f6a71b4
YQ
31672016-02-10 Yao Qi <yao.qi@linaro.org>
3168
3169 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
3170
1e94266c
SM
31712016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3172
3173 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
3174 to AC_OUTPUT.
3175 * configure: Regenerate.
3176
8adce034
SM
31772016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3178
3179 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
3180 void * to gdb_byte *.
3181 * linux-low.c (siginfo_fixup): Likewise.
3182 (linux_xfer_siginfo): Likewise.
3183 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
3184 Likewise.
3185 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
3186
93813b37
WT
31872016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
3188
3189 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
3190 to srv_tgtobj.
3191 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
3192 to srv_tgtobj.
3193 * linux-x86-low.c [__x86_64__]: Include
3194 "nat/amd64-linux-siginfo.h".
3195 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
3196 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
3197 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
3198 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
3199 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
3200 (cpt_si_fd, si_timerid, si_overrun): Move from
3201 nat/amd64-linux-siginfo.c.
3202 * Makefile.in (amd64-linux-siginfo.o:): New rule.
3203
8424cc97
SM
32042016-01-28 Simon Marchi <simon.marchi@ericsson.com>
3205
3206 * server.c (skip_to_semicolon): Remove.
3207 (process_point_options): Use strchrnul instead of
3208 skip_to_semicolon.
3209
4d18591b
YQ
32102016-01-26 Yao Qi <yao.qi@linaro.org>
3211
3212 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
3213 * linux-low.c (install_software_single_step_breakpoints): Don't
3214 call regcache_read_pc.
3215 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
3216 argument pc.
3217
d8020970
YQ
32182016-01-26 Yao Qi <yao.qi@linaro.org>
3219
3220 * linux-low.c (install_software_single_step_breakpoints): Call
3221 regcache_read_pc instead of get_pc.
3222
8b207339
YQ
32232016-01-26 Yao Qi <yao.qi@linaro.org>
3224
3225 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
3226 (unblock_async_io): Rename to ...
3227 (block_unblock_async_io): ... it. New function.
3228 (enable_async_io): Don't install SIGIO handler. Unblock it
3229 instead.
3230 (disable_async_io): Don't ignore SIGIO. Block it instead.
3231 (initialize_async_io): Install SIGIO handler. Don't call
3232 unblock_async_io.
3233
18879fef
YQ
32342016-01-26 Yao Qi <yao.qi@linaro.org>
3235
3236 * remote-utils.c (getpkt): If the buffer isn't empty, and the
3237 first character is '\003', call *the_target->request_interrupt.
3238
a0f8e08a
YQ
32392016-01-25 Yao Qi <yao.qi@linaro.org>
3240
3241 * remote-utils.c (new_thread_notify): Remove.
3242 (dead_thread_notify): Likewise.
3243 * remote-utils.h (new_thread_notify): Remove declaration.
3244 (dead_thread_notify): Likewise.
3245
cc5fd9ab
MK
32462016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
3247
3248 * gdb.trace/pending.exp: Fix expected message on continue.
3249
99e8eb11
MK
32502016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
3251
3252 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
3253 it works properly on big-endian machines where sizeof (CORE_ADDR)
3254 != sizeof (void *).
3255
a994041d
PA
32562016-01-21 Pedro Alves <palves@redhat.com>
3257
3258 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
3259 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
3260 * configure: Regenerate.
3261
f7a6a40d
YQ
32622016-01-21 Yao Qi <yao.qi@linaro.org>
3263
3264 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
3265 is_thumb and set it according to CPSR saved on the stack.
3266 (get_next_pcs_syscall_next_pc): Pass is_thumb to
3267 arm_sigreturn_next_pc.
3268
6f69e520
YQ
32692016-01-18 Yao Qi <yao.qi@linaro.org>
3270
3271 * linux-low.c (linux_set_pc_64bit): New function.
3272 (linux_get_pc_64bit): New function.
3273 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
3274 Declare.
3275 * linux-sparc-low.c (debug_threads): Remove declaration.
3276 (sparc_get_pc): Remove.
3277 (the_low_target): Use linux_get_pc_64bit instead of
3278 sparc_get_pc.
3279 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
3280 (the_low_target): Use linux_get_pc_64bit and
3281 linux_set_pc_64bit.
3282
276d4552
YQ
32832016-01-18 Yao Qi <yao.qi@linaro.org>
3284
3285 * linux-arm-low.c (debug_threads): Remove declaration.
3286 (arm_get_pc, arm_set_pc): Remove.
3287 (the_low_target): Use linux_get_pc_32bit and
3288 linux_set_pc_32bit.
3289 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
3290 (the_low_target): Use linux_get_pc_32bit and
3291 linux_set_pc_32bit.
3292 * linux-cris-low.c (debug_threads): Remove declaration.
3293 (cris_get_pc, cris_set_pc,): Remove.
3294 (the_low_target): Use linux_get_pc_32bit and
3295 linux_set_pc_32bit.
3296 * linux-crisv32-low.c (debug_threads): Remove declaration.
3297 (cris_get_pc, cris_set_pc): Remove.
3298 (the_low_target): Use linux_get_pc_32bit and
3299 linux_set_pc_32bit.
3300 * linux-low.c: Include inttypes.h.
3301 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
3302 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
3303 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
3304 (the_low_target): Use linux_get_pc_32bit and
3305 linux_set_pc_32bit.
3306 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
3307 (the_low_target): Use linux_get_pc_32bit and
3308 linux_set_pc_32bit.
3309 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
3310 (the_low_target): Use linux_get_pc_32bit and
3311 linux_set_pc_32bit.
3312 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
3313 (the_low_target): Use linux_get_pc_32bit and
3314 linux_set_pc_32bit.
3315 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
3316 (the_low_target): Use linux_get_pc_32bit and
3317 linux_set_pc_32bit.
3318
eb0edac8
GB
33192016-01-18 Gary Benson <gbenson@redhat.com>
3320
3321 * configure.ac (AC_FUNC_FORK): New check.
3322 * config.in: Regenerate.
3323 * configure: Likewise.
3324
1b451dda
YQ
33252016-01-14 Yao Qi <yao.qi@linaro.org>
3326
3327 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
3328 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
3329 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
3330 arm_get_next_pcs_ctor.
3331
82075af2
JS
33322016-01-12 Josh Stone <jistone@redhat.com>
3333 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3334
3335 * inferiors.h: Include "gdb_vecs.h".
3336 (struct process_info): Add syscalls_to_catch.
3337 * inferiors.c (remove_process): Free syscalls_to_catch.
3338 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
3339 syscall_return stops.
3340 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
3341 * server.c (handle_general_set): Handle QCatchSyscalls.
3342 (handle_query): Report support for QCatchSyscalls.
3343 * target.h (struct target_ops): Add supports_catch_syscall.
3344 (target_supports_catch_syscall): New macro.
3345 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
3346 (struct lwp_info): Add syscall_state.
3347 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
3348 Maintain syscall_state and syscalls_to_catch across exec.
3349 (get_syscall_trapinfo): New function, proxy to the_low_target.
3350 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
3351 (linux_low_filter_event): Toggle syscall_state entry/return for
3352 syscall traps, and set it ignored for all others.
3353 (gdb_catching_syscalls_p): New function.
3354 (gdb_catch_this_syscall_p): New function.
3355 (linux_wait_1): Handle SYSCALL_SIGTRAP.
3356 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
3357 (linux_supports_catch_syscall): New function.
3358 (linux_target_ops): Install it.
3359 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
3360 (the_low_target): Install it.
3361
8f13a3ce
MF
33622016-01-12 Mike Frysinger <vapier@gentoo.org>
3363
3364 * acinclude.m4: Include new ../warning.m4 file.
3365 * configure: Regenerated.
3366 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
3367
5b3da067
MF
33682016-01-12 Mike Frysinger <vapier@gentoo.org>
3369
3370 * ax.c (is_goto_target): Mark static.
3371 * linux-low.c (register_addr): Likewise.
3372 (linux_fetch_registers, linux_store_registers): Likewise.
3373 * mem-break.c (any_persistent_commands): Fix old prototype.
3374 (add_commands_to_breakpoint): Mark static.
3375 * regcache.c (find_register_by_name): Delete unused func.
3376 * remote-utils.c (hex_or_minus_one): Mark static.
3377 * server.c (monitor_show_help): Mark static.
3378 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
3379 handle_v_requests): Likewise.
3380
bc504a31
PA
33812016-01-12 Pedro Alves <palves@redhat.com>
3382
3383 Remove use of the registered trademark symbol throughout.
3384
5a0dd67a
YQ
33852016-01-08 Yao Qi <yao.qi@linaro.org>
3386
3387 * remote-utils.c (getpkt): If c is '\003', call target hook
3388 request_interrupt.
3389
b2ca446f
YQ
33902016-01-06 Yao Qi <yao.qi@linaro.org>
3391
3392 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
3393 linux-aarch32-low.c.
3394 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3395 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
3396 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
3397 (thumb2_breakpoint): Declare.
3398 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
3399 linux-aarch32-low.h.
3400 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3401 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
3402 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
3403
edd88788
JB
34042016-01-01 Joel Brobecker <brobecker@adacore.com>
3405
3406 * gdbreplay.c (gdbreplay_version): Change copyright year in
3407 version message.
3408 * server.c (gdbserver_version): Likewise.
3409
65da7f14
PP
34102015-12-28 Patrick Palka <patrick@parcs.ath.cx>
3411
3412 * server.c (crc32_table): Delete.
3413 (crc32): Use libiberty's xcrc32 function.
3414
4abd5ed2
JB
34152015-12-22 Joel Brobecker <brobecker@adacore.com>
3416
3417 * lynx-low.c (lynx_delete_thread_callback): New function.
3418 (lynx_mourn): Properly delete our process and all of its
3419 threads. Remove call to clear_inferiors.
3420
0e50fe5c
JB
34212015-12-22 Joel Brobecker <brobecker@adacore.com>
3422
3423 * target.c (thread_search_callback): Add check that
3424 the thread_stopped target callback is not NULL before
3425 calling it.
3426
35adc03f
YQ
34272015-12-21 Yao Qi <yao.qi@linaro.org>
3428
3429 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
3430 arm breakpoint.
3431
bd2b2909
AT
34322015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3433
3434 * server.c (handle_query): Call target_supports_software_single_step.
3435
7fe5e27e
AT
34362015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3437
3438 * linux-low.c (single_step): New function.
3439 (linux_resume_one_lwp_throw): Call single_step.
3440 (start_step_over): Likewise.
3441
d9311bfa
AT
34422015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3443
3444 * Makefile.in (SFILES): Append arch/arm-linux.c,
3445 arch/arm-get-next-pcs.c.
3446 (arm-linux.o): New rule.
3447 (arm-get-next-pcs.o): New rule.
3448 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
3449 arm-linux.o.
3450 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
3451 to linux-aarch32-low.c.
3452 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3453 (arm_breakpoint_len, thumb_breakpoint): Likewise.
3454 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
3455 (thumb2_breakpoint_len): Likewise.
3456 (arm_is_thumb_mode): Make non-static.
3457 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
3458 from linux-aarch32-low.c.
3459 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3460 (arm_breakpoint_len, thumb_breakpoint): Likewise.
3461 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
3462 (thumb2_breakpoint_len): Likewise.
3463 (arm_is_thumb_mode): New declaration.
3464 * linux-arm-low.c: Include arch/arm-linux.h
3465 aarch/arm-get-next-pcs.h, sys/syscall.h.
3466 (get_next_pcs_ops): New struct.
3467 (get_next_pcs_addr_bits_remove): New function.
3468 (get_next_pcs_is_thumb): New function.
3469 (get_next_pcs_read_memory_unsigned_integer): Likewise.
3470 (arm_sigreturn_next_pc): Likewise.
3471 (get_next_pcs_syscall_next_pc): Likewise.
3472 (arm_gdbserver_get_next_pcs): Likewise.
3473 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
3474 Initialize.
3475 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
3476 * server.h: Include gdb_vecs.h.
3477
68ce2059
AT
34782015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3479
3480 * Makefile.in (SFILES): Append common/common-regcache.c.
3481 (OBS): Append common-regcache.o.
3482 (common-regcache.o): New rule.
3483 * regcache.c (init_register_cache): Initialize cache to
3484 REG_UNAVAILABLE.
3485 (regcache_raw_read_unsigned): New function.
3486 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
3487 register_status enum.
3488
fa5308bd
AT
34892015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3490
3491 * linux-aarch64-low.c (the_low_targets): Rename
3492 breakpoint_reinsert_addr to get_next_pcs.
3493 * linux-arm-low.c (the_low_targets): Likewise.
3494 * linux-bfin-low.c (the_low_targets): Likewise.
3495 * linux-cris-low.c (the_low_targets): Likewise.
3496 * linux-crisv32-low.c (the_low_targets): Likewise.
3497 * linux-low.c (can_software_single_step): Likewise.
3498 (install_software_single_step_breakpoints): New function.
3499 (start_step_over): Use install_software_single_step_breakpoints.
3500 * linux-low.h: New CORE_ADDR vector.
3501 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
3502 get_next_pcs.
3503 * linux-mips-low.c (the_low_targets): Likewise.
3504 * linux-nios2-low.c (the_low_targets): Likewise.
3505 * linux-sparc-low.c (the_low_targets): Likewise.
3506
4a6ed09b
PA
35072015-12-17 Pedro Alves <palves@redhat.com>
3508
3509 * linux-low.c (linux_kill_one_lwp): Remove references to
3510 LinuxThreads.
3511 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
3512 to 'kill'.
3513 (linux_init_signals): Delete.
3514 (initialize_low): Adjust.
3515 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
3516
7544db95
PA
35172015-12-16 Pedro Alves <palves@redhat.com>
3518
3519 * configure.ac (compiler warning flags): When testing a
3520 -Wno-foo option, check whether -Wfoo works instead.
3521 * configure: Regenerate.
3522
8020350c
DB
35232015-12-11 Don Breazeal <donb@codesourcery.com>
3524
3525 * server.c (process_serial_event): Don't exit from gdbserver
3526 in remote mode if there are still active inferiors.
3527
db91f502
YQ
35282015-12-11 Yao Qi <yao.qi@linaro.org>
3529
3530 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
3531 arm_breakpoint_at if the process is 32-bit.
3532
b37a6290
YQ
35332015-12-11 Yao Qi <yao.qi@linaro.org>
3534
3535 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
3536 arm breakpoint.
3537
17b1509a
YQ
35382015-12-07 Yao Qi <yao.qi@linaro.org>
3539
3540 * configure.srv: Append arm.o to srv_tgtobj for
3541 aarch64*-*-linux* target.
3542 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
3543 from linux-arm-low.c.
3544 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3545 (arm_breakpoint_len, thumb_breakpoint): Likewise.
3546 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
3547 (thumb2_breakpoint_len): Likewise.
3548 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
3549 (arm_breakpoint_kinds): Likewise.
3550 (arm_breakpoint_kind_from_pc): Likewise.
3551 (arm_sw_breakpoint_from_kind): Likewise.
3552 (arm_breakpoint_kind_from_current_state): Likewise.
3553 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
3554 (arm_sw_breakpoint_from_kind): Declare.
3555 (arm_breakpoint_kind_from_current_state): Declare.
3556 (arm_breakpoint_at): Declare.
3557 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
3558 arm_sw_breakpoint_from_kind if process is 32-bit.
3559 (aarch64_breakpoint_kind_from_pc): New function.
3560 (aarch64_breakpoint_kind_from_current_state): New function.
3561 (the_low_target): Initialize fields breakpoint_kind_from_pc
3562 and breakpoint_kind_from_current_state.
3563 * linux-arm-low.c (arm_breakpoint_kinds): Move to
3564 linux-aarch32-low.c.
3565 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
3566 (arm_breakpoint, arm_breakpoint_len): Likewise.
3567 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
3568 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
3569 (arm_is_thumb_mode): Likewise.
3570 (arm_breakpoint_at): Likewise.
3571 (arm_breakpoint_kind_from_pc): Likewise.
3572 (arm_sw_breakpoint_from_kind): Likewise.
3573 (arm_breakpoint_kind_from_current_state): Likewise.
3574
3575 Revert:
3576 2015-08-04 Yao Qi <yao.qi@linaro.org>
3577
3578 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
3579 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
3580 * server.c (extended_protocol): Remove "static".
3581 * server.h (extended_protocol): Declare it.
3582
ece66d65
JS
35832015-12-04 Josh Stone <jistone@redhat.com>
3584
3585 * target.h (struct target_ops) <arch_setup>: Rename to ...
3586 (struct target_ops) <post_create_inferior>: ... this.
3587 (target_arch_setup): Rename to ...
3588 (target_post_create_inferior): ... this, calling post_create_inferior.
3589 * server.c (start_inferior): Update target_arch_setup calls to
3590 target_post_create_inferior.
3591 * linux-low.c (linux_low_ptrace_options): Forward declare.
3592 (linux_arch_setup): Update its comment for general use.
3593 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
3594 (struct linux_target_ops): Use linux_post_create_inferior.
3595 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
3596 to post_create_inferior.
3597 * nto-low.c (struct nto_target_ops): Likewise.
3598 * spu-low.c (struct spu_target_ops): Likewise.
3599 * win32-low.c (struct win32_target_ops): Likewise.
3600
e58c48b4
AT
36012015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
3602
3603 * linux-arm-low.c: Remove duplicate arch/arm.h include.
3604
fbec8956
AT
36052015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3606
3607 * linux-arm-low.c (arm_reinsert_addr): Remove function.
3608 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
3609 * linux-cris-low.c (cris_reinsert_addr> Remove function.
3610 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3611 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
3612 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3613 * linux-mips-low.c (mips_reinsert_addr): Remove function.
3614 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3615 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
3616 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3617 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
3618 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3619
9b4c5f87
AT
36202015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3621
3622 * linux-low.c (linux_look_up_symbols): Don't call
3623 linux_supports_traceclone.
3624 * linux-low.h (thread_db_init): Remove use_events argument.
3625 * thread-db.c (thread_db_use_event): Remove global variable.
3626 (struct thread_db) <td_thr_event_enable_p>: Remove field.
3627 (struct thread_db) <td_create_bp>: Remove field.
3628 (thread_db_create_event): Remove function.
3629 (thread_db_enable_reporting): Likewise.
3630 (find_one_thread): Don't check for thread_db_use_events.
3631 (attach_thread): Likewise.
3632 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
3633 (try_thread_db_load_1): Don't check for thread_db_use_events.
3634 (thread_db_init): Remove use_events argument and thread events
3635 handling.
3636 (remove_thread_event_breakpoints): Remove function.
3637 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
3638
7d00775e
AT
36392015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3640
3641 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
3642 New function.
3643 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3644 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
3645 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3646 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
3647 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
3648 Initialize.
3649 * linux-crisv32-low.c (cris_supports_hardware_single_step):
3650 New function.
3651 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3652 * linux-low.c (can_hardware_single_step): Use
3653 supports_hardware_single_step.
3654 (can_software_single_step): New function.
3655 (start_step_over): Call can_software_single_step.
3656 (linux_supports_hardware_single_step): New function.
3657 (struct target_ops) <supports_software_single_step>: Initialize.
3658 * linux-low.h (struct linux_target_ops)
3659 <supports_hardware_single_step>: Initialize.
3660 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
3661 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3662 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
3663 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
3664 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
3665 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3666 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
3667 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3668 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
3669 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
3670 Initialize.
3671 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
3672 (struct linux_target_ops) <tile_supports_hardware_single_step>:
3673 Initialize.
3674 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
3675 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3676 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
3677 New function.
3678 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3679 * target.h (struct target_ops): <supports_software_single_step>:
3680 New field.
3681 (target_supports_software_single_step): New macro.
3682
2d97cd35
AT
36832015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3684
3685 * linux-low.c (linux_wait_1): Fix pc advance condition.
3686 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
3687 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
3688
769ef81f
AT
36892015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3690
3691 * linux-arm-low.c (arm_is_thumb_mode): New function.
3692 (arm_breakpoint_at): Use arm_is_thumb_mode.
3693 (arm_breakpoint_kind_from_current_state): New function.
3694 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
3695 Initialize.
3696 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
3697 (linux_breakpoint_kind_from_current_state): New function.
3698 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
3699 * linux-low.h (struct linux_target_ops)
3700 <breakpoint_kind_from_current_state>: New field.
3701 * target.h (struct target_ops): Likewise.
3702 (target_breakpoint_kind_from_current_state): New macro.
3703
1bebeeca
PA
37042015-11-30 Pedro Alves <palves@redhat.com>
3705
3706 * linux-low.c (linux_resume): Wake up the event loop before
3707 returning.
3708
a67a9fae
PA
37092015-11-30 Pedro Alves <palves@redhat.com>
3710
3711 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
3712 check.
3713 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
3714 to -1.
3715 * target.c (struct thread_search): New structure.
3716 (thread_search_callback): New function.
3717 (prev_general_thread): New global.
3718 (prepare_to_access_memory, done_accessing_memory): New functions.
3719 * target.h (prepare_to_access_memory, done_accessing_memory):
3720 Replace macros with function declarations.
3721
f2faf941
PA
37222015-11-30 Pedro Alves <palves@redhat.com>
3723
3724 PR 14618
3725 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
3726 report TARGET_WAITKIND_NO_RESUMED.
3727 * remote-utils.c (prepare_resume_reply): Handle
3728 TARGET_WAITKIND_NO_RESUMED.
3729 * server.c (report_no_resumed): New global.
3730 (handle_query) <qSupported>: Handle "no-resumed+". Report
3731 "no-resumed+" support.
3732 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
3733 return error if the client doesn't support no-resumed events.
3734 (push_stop_notification): New function.
3735 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
3736 events if the client supports them.
3737
a681f9c9
PA
37382015-11-30 Pedro Alves <palves@redhat.com>
3739
3740 * linux-low.c (thread_still_has_status_pending_p): Don't check
3741 vCont;t here.
3742 (lwp_resumed): New function.
3743 (status_pending_p_callback): Return early if the LWP is not
3744 supposed to be resumed.
3745
65706a29
PA
37462015-11-30 Pedro Alves <palves@redhat.com>
3747
3748 * linux-low.c (handle_extended_wait): Assert that the LWP's
3749 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
3750 thread create events, leave the new child's status pending.
3751 (linux_low_filter_event): If GDB wants to hear about thread exit
3752 events, leave the LWP marked dead and don't delete it.
3753 (linux_wait_for_event_filtered): Don't check for thread exit.
3754 (filter_exit_event): New function.
3755 (linux_wait_1): Use it, when returning an exit event.
3756 (linux_resume_one_lwp_throw): Assert that the LWP's
3757 waitstatus is TARGET_WAITKIND_IGNORE.
3758 * remote-utils.c (prepare_resume_reply): Handle
3759 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
3760 * server.c (report_thread_events): New global.
3761 (handle_general_set): Handle QThreadEvents.
3762 (handle_query) <qSupported>: Handle and report QThreadEvents+;
3763 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
3764 TARGET_WAITKIND_THREAD_EXITED.
3765 * server.h (report_thread_events): Declare.
3766
56cf4bed
PA
37672015-11-30 Pedro Alves <palves@redhat.com>
3768
3769 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
3770 the thread's last_resume_kind was resume_stop.
3771
500c1d85
PA
37722015-11-30 Pedro Alves <palves@redhat.com>
3773
3774 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
3775 before returning.
3776
de979965
PA
37772015-11-30 Pedro Alves <palves@redhat.com>
3778
3779 * server.c (handle_v_requests): Handle vCtrlC.
3780
34c65914
PA
37812015-11-30 Pedro Alves <palves@redhat.com>
3782
3783 * gdbthread.h (find_any_thread_of_pid): Declare.
3784 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
3785 functions.
3786 * server.c (handle_query): If current_thread is NULL, look for
3787 another thread of the selected process.
3788
79efa585 37892015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 3790 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
3791
3792 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
3793 * server.c (handle_qxfer_threads_worker): Refactor to include thread
3794 name in reply.
3795 * target.h (struct target_ops) <thread_name>: New field.
3796 (target_thread_name): New macro.
3797
80d82c19
JB
37982015-11-23 Joel Brobecker <brobecker@adacore.com>
3799
3800 * regcache.h (regcache_invalidate_pid): Add declaration.
3801 * regcache.c (regcache_invalidate_pid): New function, extracted
3802 from regcache_invalidate.
3803 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
3804 Add trivial documentation comment.
3805 * lynx-low.c: Use regcache_invalidate_pid instead of
3806 regcache_invalidate.
3807
64da5dd5
JB
38082015-11-23 Joel Brobecker <brobecker@adacore.com>
3809
3810 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
3811 and Elf64_auxv_t if the target is Android.
3812
37ce4055
DE
38132015-11-22 Doug Evans <xdje42@gmail.com>
3814
3815 * target.h: #include <sys/types.h>.
3816
06e03fff
PA
38172015-11-19 Pedro Alves <palves@redhat.com>
3818
3819 * linux-low.c (linux_process_qsupported): Change prototype.
3820 Adjust.
3821 * linux-low.h (struct linux_target_ops) <process_qsupported>:
3822 Change prototype.
3823 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
3824 and adjust to loop over all features.
3825 * server.c (handle_query) <qSupported>: Adjust to call
3826 target_process_qsupported once, passing it a vector of unprocessed
3827 features.
3828 * target.h (struct target_ops) <process_qsupported>: Change
3829 prototype.
3830 (target_process_qsupported): Adjust.
3831
9a084706
PA
38322015-11-19 Pedro Alves <palves@redhat.com>
3833
3834 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
3835 mode.
3836 * configure: Regenerate.
3837
dad44a1f
PA
38382015-11-19 Pedro Alves <palves@redhat.com>
3839
3840 * configure: Regenerate.
3841
231c0592
YQ
38422015-11-19 Yao Qi <yao.qi@linaro.org>
3843
3844 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
3845 type to uint32_t.
3846
6c1c9a8b
YQ
38472015-11-19 Yao Qi <yao.qi@linaro.org>
3848
3849 * linux-aarch64-low.c (enum aarch64_operand_type): New.
3850 (struct aarch64_operand): Move enum out.
3851
9caa3311
YQ
38522015-11-19 Yao Qi <yao.qi@linaro.org>
3853
3854 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
3855 struct user_fpsimd_state *.
3856 (aarch64_store_fpregset): Likewise.
3857
6a69a054
YQ
38582015-11-19 Yao Qi <yao.qi@linaro.org>
3859
3860 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
3861 struct user_pt_regs *.
3862 (aarch64_store_gregset): Likewise.
3863
1798301e
PA
38642015-11-18 Pedro Alves <palves@redhat.com>
3865
3866 * Makefile.in (all_object_files): Add $IPA_OBJS.
3867
ce7715e2
PA
38682015-11-17 Pedro Alves <palves@redhat.com>
3869
3870 * win32-low.c (win32_resume): Use gdb_signal_from_host,
3871 GDB_SIGNAL_0 and gdb_signal_to_string.
3872
c0879059
PA
38732015-11-17 Pedro Alves <palves@redhat.com>
3874
3875 * win32-low.c (handle_output_debug_string): Remove parameter.
3876 (win32_kill): Remove our_status local and adjust call to
3877 handle_output_debug_string.
3878 (get_child_debug_event): Adjust call to
3879 handle_output_debug_string.
3880
1996e237
SM
38812015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3882
3883 * linux-mips-low.c (mips_fill_gregset): Add cast.
3884 (mips_store_gregset): Likewise.
3885 (mips_fill_fpregset): Likewise.
3886 (mips_store_fpregset): Likewise.
3887
cbec665b
SM
38882015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3889
3890 * linux-mips-low.c (mips_add_watchpoint): Rename private to
3891 priv.
3892
eb3e3c67
SM
38932015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3894
3895 * linux-mips-low.c (mips_linux_new_thread): Change type of
3896 watch_type to enum target_hw_bp_type.
3897
171de4b8
SM
38982015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3899
3900 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
3901 Change return type to arm_hwbp_type.
3902
04248ead
SM
39032015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3904
3905 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
3906 (arm_store_gregset): Likewise.
3907 * linux-arm-low.c (arm_get_hwcap): Likewise.
3908 (arm_read_description): Likewise.
3909
04b3479c
SM
39102015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3911
3912 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
3913
2bc84e8a
SM
39142015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3915
3916 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
3917 (ppc_fill_vsxregset): Likewise.
3918 (ppc_store_vsxregset): Likewise.
3919 (ppc_fill_vrregset): Likewise.
3920 (ppc_store_vrregset): Likewise.
3921 (ppc_fill_evrregset): Likewise.
3922 (ppc_store_evrregset): Likewise.
3923
e6c5bb05
SM
39242015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3925
3926 * linux-ppc-low.c (ppc_usrregs_info): Remove
3927 forward-declaration.
3928 (ppc_arch_setup): Move lower in file.
3929
7ea45d72
SM
39302015-10-30 Simon Marchi <simon.marchi@ericsson.com>
3931
3932 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
3933 (ps_pdwrite): Likewise.
3934
69291610
HW
39352015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
3936
3937 * linux-arm-low.c (arm_new_thread): Move pointer dereference
3938 to after assert checks.
3939
b42945fd
SM
39402015-10-29 Simon Marchi <simon.marchi@ericsson.com>
3941
3942 * proc-service.c (ps_pdread): Add/adjust casts.
3943 (ps_pdwrite): Add/adjust casts.
3944
d6f85c84
SM
39452015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
3946
3947 * server.c (handle_search_memory_1): Cast return value of
3948 memmem.
3949
f98cd059
SM
39502015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
3951
3952 * server.c (write_qxfer_response): Change type of data to
3953 gdb_byte *.
3954
d2412fa5
PA
39552015-10-29 Pedro Alves <palves@redhat.com>
3956
3957 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
3958
c17414a2
PA
39592015-10-29 Pedro Alves <palves@redhat.com>
3960
3961 * tracepoint.c (clear_installed_tracepoints): Add casts.
3962
e053fbc4
PA
39632015-10-29 Pedro Alves <palves@redhat.com>
3964
3965 * server.c (handle_v_cont, process_serial_event): Add enum
3966 gdb_signal casts to signal parsing code.
3967
add67df8
PA
39682015-10-29 Pedro Alves <palves@redhat.com>
3969
3970 * linux-low.h (NULL_REGSET): Define.
3971 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
3972 * linux-arm-low.c (arm_regsets): Likewise.
3973 * linux-crisv32-low.c (cris_regsets): Likewise.
3974 * linux-m68k-low.c (m68k_regsets): Likewise.
3975 * linux-mips-low.c (mips_regsets): Likewise.
3976 * linux-nios2-low.c (nios2_regsets): Likewise.
3977 * linux-ppc-low.c (ppc_regsets): Likewise.
3978 * linux-s390-low.c (s390_regsets): Likewise.
3979 * linux-sh-low.c (sh_regsets): Likewise.
3980 * linux-sparc-low.c (sparc_regsets): Likewise.
3981 * linux-tic6x-low.c (tic6x_regsets): Likewise.
3982 * linux-tile-low.c (tile_regsets): Likewise.
3983 * linux-x86-low.c (x86_regsets): Likewise.
3984 * linux-xtensa-low.c (xtensa_regsets): Likewise.
3985
50bc912a
PA
39862015-10-29 Pedro Alves <palves@redhat.com>
3987
3988 * linux-low.h (NULL_REGSET): Define.
3989 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
3990 * linux-arm-low.c (arm_regsets): Likewise.
3991 * linux-crisv32-low.c (cris_regsets): Likewise.
3992 * linux-m68k-low.c (m68k_regsets): Likewise.
3993 * linux-mips-low.c (mips_regsets): Likewise.
3994 * linux-nios2-low.c (nios2_regsets): Likewise.
3995 * linux-ppc-low.c (ppc_regsets): Likewise.
3996 * linux-s390-low.c (s390_regsets): Likewise.
3997 * linux-sh-low.c (sh_regsets): Likewise.
3998 * linux-sparc-low.c (sparc_regsets): Likewise.
3999 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4000 * linux-tile-low.c (tile_regsets): Likewise.
4001 * linux-x86-low.c (x86_regsets): Likewise.
4002 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4003
682b2546
DE
40042015-10-26 Doug Evans <dje@google.com>
4005
4006 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
4007
963843d4
DE
40082015-10-26 Doug Evans <dje@google.com>
4009
4010 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
4011
d41401ac
DE
40122015-10-26 Doug Evans <dje@google.com>
4013
4014 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
4015 for debug_printf.
4016 (attach_thread, find_new_threads_callback): Ditto.
4017
3db28855
AT
40182015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4019
4020 * mem-break.h (set_breakpoint_data): Remove.
4021
fb78e89c
AT
40222015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4023
4024 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
4025 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4026 (initialize_low): Remove set_breakpoint_data call.
4027 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
4028 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
4029 (initialize_low): Remove set_breakpoint_data call.
4030 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
4031 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4032 (initialize_low): Remove set_breakpoint_data call.
4033
2e6ee069
AT
40342015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4035
4036 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
4037 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
4038 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
4039 * target.h (target_breakpoint_kind_from_pc): New macro.
4040
1652a986
AT
40412015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
4042
4043 * linux-low.c (default_breakpoint_kind_from_pc): New function.
4044 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
4045 the default breakpoint kind.
4046
abeead09
AT
40472015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4048
4049 * linux-arm-low.c (arm_supports_z_point_type): Add software
4050 breakpoint support.
4051
b0b4b501
AT
40522015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4053
4054 * linux-arm-low.c: Refactor breakpoint definitions.
4055 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
4056 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
4057
8689682c
AT
40582015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4059
4060 * Makefile.in: Add arm.c/o.
4061 * configure.srv: Likewise.
4062 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
4063 (arm_breakpoint_kind_from_pc): New function.
4064 (arm_sw_breakpoint_from_kind): Return proper kind.
4065 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
4066
27165294
AT
40672015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4068
4069 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
4070 removal.
4071 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
4072 (struct raw_breakpoint) <size>: Remove.
4073 (struct raw_breakpoint) <kind>: Add.
4074 (bp_size): New function.
4075 (bp_opcode): Likewise.
4076 (find_raw_breakpoint_at): Adjust for kind.
4077 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
4078 (remove_memory_breakpoint): Adjust for kind call bp_size.
4079 (set_raw_breakpoint_at): Adjust for kind.
4080 (set_breakpoint): Likewise.
4081 (set_breakpoint_at): Call breakpoint_kind_from_pc.
4082 (delete_raw_breakpoint): Adjust for kind.
4083 (delete_breakpoint): Likewise.
4084 (find_gdb_breakpoint): Likewise.
4085 (set_gdb_breakpoint_1): Likewise.
4086 (set_gdb_breakpoint): Likewise.
4087 (delete_gdb_breakpoint_1): Likewise.
4088 (delete_gdb_breakpoint): Likewise.
4089 (uninsert_raw_breakpoint): Likewise.
4090 (reinsert_raw_breakpoint): Likewise.
4091 (set_breakpoint_data): Remove.
4092 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
4093 (check_mem_read): Adjust for kind call bp_size.
4094 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
4095 (clone_one_breakpoint): Adjust for kind.
4096 * mem-break.h (set_gdb_breakpoint): Likewise.
4097 (delete_gdb_breakpoint): Likewise.
4098 * server.c (process_serial_event): Likewise.
4099
dd373349
AT
41002015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4101
4102 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
4103 (struct linux_target_ops) <breakpoint>: Remove.
4104 (struct linux_target_ops) <breakpoint_len>: Remove.
4105 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4106 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4107 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
4108 (arm_sw_breakpoint_from_kind): New function.
4109 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
4110 (struct linux_target_ops) <breakpoint>: Remove.
4111 (struct linux_target_ops) <breakpoint_len>: Remove.
4112 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4113 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4114 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
4115 (struct linux_target_ops) <breakpoint>: Remove.
4116 (struct linux_target_ops) <breakpoint_len>: Remove.
4117 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4118 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4119 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
4120 (struct linux_target_ops) <breakpoint>: Remove.
4121 (struct linux_target_ops) <breakpoint_len>: Remove.
4122 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4123 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4124 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
4125 and sw_breakpoint_from_kind to increment the pc.
4126 (linux_breakpoint_kind_from_pc): New function.
4127 (linux_sw_breakpoint_from_kind): New function.
4128 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
4129 (initialize_low): Call breakpoint_kind_from_pc and
4130 sw_breakpoint_from_kind to replace breakpoint_data/len.
4131 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
4132 New field.
4133 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
4134 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
4135 (struct linux_target_ops) <breakpoint>: Remove.
4136 (struct linux_target_ops) <breakpoint_len>: Remove.
4137 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4138 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4139 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
4140 (struct linux_target_ops) <breakpoint>: Remove.
4141 (struct linux_target_ops) <breakpoint_len>: Remove.
4142 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4143 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4144 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
4145 (struct linux_target_ops) <breakpoint>: Remove.
4146 (struct linux_target_ops) <breakpoint_len>: Remove.
4147 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4148 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4149 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
4150 (struct linux_target_ops) <breakpoint>: Remove.
4151 (struct linux_target_ops) <breakpoint_len>: Remove.
4152 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4153 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4154 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
4155 (struct linux_target_ops) <breakpoint>: Remove.
4156 (struct linux_target_ops) <breakpoint_len>: Remove.
4157 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4158 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4159 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
4160 (struct linux_target_ops) <breakpoint>: Remove.
4161 (struct linux_target_ops) <breakpoint_len>: Remove.
4162 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4163 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4164 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
4165 (struct linux_target_ops) <breakpoint>: Remove.
4166 (struct linux_target_ops) <breakpoint_len>: Remove.
4167 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4168 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4169 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
4170 (struct linux_target_ops) <breakpoint>: Remove.
4171 (struct linux_target_ops) <breakpoint_len>: Remove.
4172 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4173 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4174 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
4175 (struct linux_target_ops) <breakpoint>: Remove.
4176 (struct linux_target_ops) <breakpoint_len>: Remove.
4177 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4178 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4179 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
4180 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
4181 (struct linux_target_ops) <breakpoint>: Remove.
4182 (struct linux_target_ops) <breakpoint_len>: Remove.
4183 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4184 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4185 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
4186 (struct linux_target_ops) <breakpoint>: Remove.
4187 (struct linux_target_ops) <breakpoint_len>: Remove.
4188 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4189 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4190
4cd98a19
AT
41912015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4192
4193 * linux-cris-low.c (cris_get_pc): Remove void arg.
4194
774ee6d2
AR
41952015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4196
4197 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
4198 variable name.
4199
833dcd29
AR
42002015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4201
4202 * inferiors.c (thread_pid_matches_callback): New function.
4203 (find_thread_process): New function.
4204 (remove_thread): Reset current_thread.
4205 (remove_process): Assert threads have been removed first.
4206
8d689ee5
YQ
42072015-10-15 Yao Qi <yao.qi@linaro.org>
4208
4209 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
4210 if it is 3.
4211 (aarch64_remove_point): Likewise.
4212 * regcache.c (regcache_register_size): New function.
4213
1c2e1515
YQ
42142015-10-12 Yao Qi <yao.qi@linaro.org>
4215
4216 * linux-aarch64-low.c: Update all callers as emit_load_store
4217 is renamed to aarch64_emit_load_store.
4218
e1c587c3
YQ
42192015-10-12 Yao Qi <yao.qi@linaro.org>
4220
4221 * linux-aarch64-low.c: Update all callers of function renaming
4222 from emit_insn to aarch64_emit_insn.
4223
b6542f81
YQ
42242015-10-12 Yao Qi <yao.qi@linaro.org>
4225
4226 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
4227 arch/aarch64-insn.h.
4228 (struct aarch64_memory_operand): Likewise.
4229 (ENCODE): Likewise.
4230 (emit_insn): Move to arch/aarch64-insn.c.
4231 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
4232 (emit_load_store): Move to arch/aarch64-insn.c.
4233 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
4234 (can_encode_int32): Remove.
4235
246994ce
YQ
42362015-10-12 Yao Qi <yao.qi@linaro.org>
4237
4238 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
4239 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
4240 (aarch64_relocate_instruction): Likewise.
4241 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
4242 (struct aarch64_insn_visitor): Likewise.
4243
0badd99f
YQ
42442015-10-12 Yao Qi <yao.qi@linaro.org>
4245
4246 * linux-aarch64-low.c (struct aarch64_insn_data): New.
4247 (struct aarch64_insn_visitor): New.
4248 (struct aarch64_insn_relocation_data): New.
4249 (aarch64_ftrace_insn_reloc_b): New function.
4250 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4251 (aarch64_ftrace_insn_reloc_cb): Likewise.
4252 (aarch64_ftrace_insn_reloc_tb): Likewise.
4253 (aarch64_ftrace_insn_reloc_adr): Likewise.
4254 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
4255 (aarch64_ftrace_insn_reloc_others): Likewise.
4256 (visitor): New.
4257 (aarch64_relocate_instruction): Use visitor.
4258
dfaffe9d
YQ
42592015-10-12 Yao Qi <yao.qi@linaro.org>
4260
4261 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
4262 int. Add argument buf.
4263 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
4264 aarch64_relocate_instruction.
4265
70b439f0
YQ
42662015-10-12 Yao Qi <yao.qi@linaro.org>
4267
4268 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
4269 argument insn. Remove local variable insn. Don't call
4270 target_read_uint32.
4271 (aarch64_install_fast_tracepoint_jump_pad): Call
4272 target_read_uint32.
4273
7781c06f
YQ
42742015-09-30 Yao Qi <yao.qi@linaro.org>
4275
4276 * linux-aarch64-low.c (emit_movk): Shorten a long line.
4277 (emit_load_store_pair): Likewise.
4278
9a3c8263
SM
42792015-09-25 Simon Marchi <simon.marchi@ericsson.com>
4280
4281 * dll.c (match_dll): Add cast(s).
4282 (unloaded_dll): Likewise.
4283 * linux-low.c (second_thread_of_pid_p): Likewise.
4284 (delete_lwp_callback): Likewise.
4285 (count_events_callback): Likewise.
4286 (select_event_lwp_callback): Likewise.
4287 (linux_set_resume_request): Likewise.
4288 * server.c (accumulate_file_name_length): Likewise.
4289 (emit_dll_description): Likewise.
4290 (handle_qxfer_threads_worker): Likewise.
4291 (visit_actioned_threads): Likewise.
4292 * thread-db.c (any_thread_of): Likewise.
4293 * tracepoint.c (same_process_p): Likewise.
4294 (match_blocktype): Likewise.
4295 (build_traceframe_info_xml): Likewise.
4296
224c3ddb
SM
42972015-09-25 Simon Marchi <simon.marchi@ericsson.com>
4298
4299 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
4300 assignment.
4301 (gdb_unparse_agent_expr): Likewise.
4302 * hostio.c (require_data): Likewise.
4303 (handle_pread): Likewise.
4304 * linux-low.c (disable_regset): Likewise.
4305 (fetch_register): Likewise.
4306 (store_register): Likewise.
4307 (get_dynamic): Likewise.
4308 (linux_qxfer_libraries_svr4): Likewise.
4309 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
4310 (set_fast_tracepoint_jump): Likewise.
4311 (uninsert_fast_tracepoint_jumps_at): Likewise.
4312 (reinsert_fast_tracepoint_jumps_at): Likewise.
4313 (validate_inserted_breakpoint): Likewise.
4314 (clone_agent_expr): Likewise.
4315 * regcache.c (init_register_cache): Likewise.
4316 * remote-utils.c (putpkt_binary_1): Likewise.
4317 (decode_M_packet): Likewise.
4318 (decode_X_packet): Likewise.
4319 (look_up_one_symbol): Likewise.
4320 (relocate_instruction): Likewise.
4321 (monitor_output): Likewise.
4322 * server.c (handle_search_memory): Likewise.
4323 (handle_qxfer_exec_file): Likewise.
4324 (handle_qxfer_libraries): Likewise.
4325 (handle_qxfer): Likewise.
4326 (handle_query): Likewise.
4327 (handle_v_cont): Likewise.
4328 (handle_v_run): Likewise.
4329 (captured_main): Likewise.
4330 * target.c (write_inferior_memory): Likewise.
4331 * thread-db.c (try_thread_db_load_from_dir): Likewise.
4332 * tracepoint.c (init_trace_buffer): Likewise.
4333 (add_tracepoint_action): Likewise.
4334 (add_traceframe): Likewise.
4335 (add_traceframe_block): Likewise.
4336 (cmd_qtdpsrc): Likewise.
4337 (cmd_qtdv): Likewise.
4338 (cmd_qtstatus): Likewise.
4339 (response_source): Likewise.
4340 (response_tsv): Likewise.
4341 (cmd_qtnotes): Likewise.
4342 (gdb_collect): Likewise.
4343 (initialize_tracepoint): Likewise.
4344
afbe19f8
PL
43452015-09-21 Pierre Langlois <pierre.langlois@arm.com>
4346
4347 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
4348 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
4349 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
4350 <NOP>: New.
4351 (enum aarch64_condition_codes): New enum.
4352 (w0): New static global.
4353 (fp): Likewise.
4354 (lr): Likewise.
4355 (struct aarch64_memory_operand) <type>: New
4356 MEMORY_OPERAND_POSTINDEX type.
4357 (postindex_memory_operand): New helper function.
4358 (emit_ret): New function.
4359 (emit_load_store_pair): New function, factored out of emit_stp
4360 with support for MEMORY_OPERAND_POSTINDEX.
4361 (emit_stp): Rewrite using emit_load_store_pair.
4362 (emit_ldp): New function.
4363 (emit_load_store): Likewise.
4364 (emit_ldr): Mention post-index instruction in comment.
4365 (emit_ldrh): New function.
4366 (emit_ldrb): New function.
4367 (emit_ldrsw): Mention post-index instruction in comment.
4368 (emit_str): Likewise.
4369 (emit_subs): New function.
4370 (emit_cmp): Likewise.
4371 (emit_and): Likewise.
4372 (emit_orr): Likewise.
4373 (emit_orn): Likewise.
4374 (emit_eor): Likewise.
4375 (emit_mvn): Likewise.
4376 (emit_lslv): Likewise.
4377 (emit_lsrv): Likewise.
4378 (emit_asrv): Likewise.
4379 (emit_mul): Likewise.
4380 (emit_sbfm): Likewise.
4381 (emit_sbfx): Likewise.
4382 (emit_ubfm): Likewise.
4383 (emit_ubfx): Likewise.
4384 (emit_csinc): Likewise.
4385 (emit_cset): Likewise.
4386 (emit_nop): Likewise.
4387 (emit_ops_insns): New helper function.
4388 (emit_pop): Likewise.
4389 (emit_push): Likewise.
4390 (aarch64_emit_prologue): New function.
4391 (aarch64_emit_epilogue): Likewise.
4392 (aarch64_emit_add): Likewise.
4393 (aarch64_emit_sub): Likewise.
4394 (aarch64_emit_mul): Likewise.
4395 (aarch64_emit_lsh): Likewise.
4396 (aarch64_emit_rsh_signed): Likewise.
4397 (aarch64_emit_rsh_unsigned): Likewise.
4398 (aarch64_emit_ext): Likewise.
4399 (aarch64_emit_log_not): Likewise.
4400 (aarch64_emit_bit_and): Likewise.
4401 (aarch64_emit_bit_or): Likewise.
4402 (aarch64_emit_bit_xor): Likewise.
4403 (aarch64_emit_bit_not): Likewise.
4404 (aarch64_emit_equal): Likewise.
4405 (aarch64_emit_less_signed): Likewise.
4406 (aarch64_emit_less_unsigned): Likewise.
4407 (aarch64_emit_ref): Likewise.
4408 (aarch64_emit_if_goto): Likewise.
4409 (aarch64_emit_goto): Likewise.
4410 (aarch64_write_goto_address): Likewise.
4411 (aarch64_emit_const): Likewise.
4412 (aarch64_emit_call): Likewise.
4413 (aarch64_emit_reg): Likewise.
4414 (aarch64_emit_pop): Likewise.
4415 (aarch64_emit_stack_flush): Likewise.
4416 (aarch64_emit_zero_ext): Likewise.
4417 (aarch64_emit_swap): Likewise.
4418 (aarch64_emit_stack_adjust): Likewise.
4419 (aarch64_emit_int_call_1): Likewise.
4420 (aarch64_emit_void_call_2): Likewise.
4421 (aarch64_emit_eq_goto): Likewise.
4422 (aarch64_emit_ne_goto): Likewise.
4423 (aarch64_emit_lt_goto): Likewise.
4424 (aarch64_emit_le_goto): Likewise.
4425 (aarch64_emit_gt_goto): Likewise.
4426 (aarch64_emit_ge_got): Likewise.
4427 (aarch64_emit_ops_impl): New static global variable.
4428 (aarch64_emit_ops): New target function, return
4429 &aarch64_emit_ops_impl.
4430 (struct linux_target_ops): Install it.
4431
bb903df0
PL
44322015-09-21 Pierre Langlois <pierre.langlois@arm.com>
4433
4434 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
4435 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
4436 aarch64-ipa.o.
4437 * linux-aarch64-ipa.c: New file.
4438 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
4439 and endian.h.
4440 (aarch64_get_thread_area): New target method.
4441 (extract_signed_bitfield): New helper function.
4442 (aarch64_decode_ldr_literal): New function.
4443 (enum aarch64_opcodes): New enum.
4444 (struct aarch64_register): New struct.
4445 (struct aarch64_operand): New struct.
4446 (x0): New static global.
4447 (x1): Likewise.
4448 (x2): Likewise.
4449 (x3): Likewise.
4450 (x4): Likewise.
4451 (w2): Likewise.
4452 (ip0): Likewise.
4453 (sp): Likewise.
4454 (xzr): Likewise.
4455 (aarch64_register): New helper function.
4456 (register_operand): Likewise.
4457 (immediate_operand): Likewise.
4458 (struct aarch64_memory_operand): New struct.
4459 (offset_memory_operand): New helper function.
4460 (preindex_memory_operand): Likewise.
4461 (enum aarch64_system_control_registers): New enum.
4462 (ENCODE): New macro.
4463 (emit_insn): New helper function.
4464 (emit_b): New function.
4465 (emit_bcond): Likewise.
4466 (emit_cb): Likewise.
4467 (emit_tb): Likewise.
4468 (emit_blr): Likewise.
4469 (emit_stp): Likewise.
4470 (emit_ldp_q_offset): Likewise.
4471 (emit_stp_q_offset): Likewise.
4472 (emit_load_store): Likewise.
4473 (emit_ldr): Likewise.
4474 (emit_ldrsw): Likewise.
4475 (emit_str): Likewise.
4476 (emit_ldaxr): Likewise.
4477 (emit_stxr): Likewise.
4478 (emit_stlr): Likewise.
4479 (emit_data_processing_reg): Likewise.
4480 (emit_data_processing): Likewise.
4481 (emit_add): Likewise.
4482 (emit_sub): Likewise.
4483 (emit_mov): Likewise.
4484 (emit_movk): Likewise.
4485 (emit_mov_addr): Likewise.
4486 (emit_mrs): Likewise.
4487 (emit_msr): Likewise.
4488 (emit_sevl): Likewise.
4489 (emit_wfe): Likewise.
4490 (append_insns): Likewise.
4491 (can_encode_int32_in): New helper function.
4492 (aarch64_relocate_instruction): New function.
4493 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
4494 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
4495 (struct linux_target_ops): Install aarch64_get_thread_area,
4496 aarch64_install_fast_tracepoint_jump_pad and
4497 aarch64_get_min_fast_tracepoint_insn_len.
4498
787749ea
PL
44992015-09-21 Pierre Langlois <pierre.langlois@arm.com>
4500
4501 * Makefile.in (aarch64-insn.o): New rule.
4502 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
4503
9812b2e6
YQ
45042015-09-21 Yao Qi <yao.qi@linaro.org>
4505
4506 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
4507
18fe412b
YQ
45082015-09-21 Yao Qi <yao.qi@linaro.org>
4509
4510 * tracepoint.c (max_jump_pad_size): Remove.
4511
a0cc84cd
YQ
45122015-09-18 Yao Qi <yao.qi@linaro.org>
4513
4514 * linux-aarch64-low.c: Don't include sys/uio.h.
4515 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
4516
d78908cf
WW
45172015-09-16 Wei-cheng Wang <cole945@gmail.com>
4518
4519 * tracepoint.c (eval_result_type): Change prototype.
4520 (condition_true_at_tracepoint): Fix argument to compiled_cond.
4521
d57e0d50
PA
45222015-09-15 Pedro Alves <palves@redhat.com>
4523
4524 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
4525 Check whether to report exec events instead of checking whether
4526 multiprocess is enabled.
4527
5a676acc
PA
45282015-09-15 Pedro Alves <palves@redhat.com>
4529
4530 PR remote/18965
4531 * remote-utils.c (prepare_resume_reply): Merge
4532 TARGET_WAITKIND_VFORK_DONE switch case with the
4533 TARGET_WAITKIND_FORKED case.
4534
7c5d0fad
YQ
45352015-09-15 Yao Qi <yao.qi@linaro.org>
4536
4537 * server.c (handle_query): Check string comparison using
4538 "else if" instead of "if".
4539
750ce8d1
YQ
45402015-09-15 Yao Qi <yao.qi@linaro.org>
4541
4542 * server.c (vCont_supported): New global variable.
4543 (handle_query): Set vCont_supported to 1 if "vContSupported+"
4544 matches. Append ";vContSupported+" to own_buf.
4545 (handle_v_requests): Append ";s;S" to own_buf if target supports
4546 hardware single step or vCont_supported is false.
4547 (capture_main): Set vCont_supported to zero.
4548
70b90b91
YQ
45492015-09-15 Yao Qi <yao.qi@linaro.org>
4550
4551 * linux-low.c (linux_supports_conditional_breakpoints): Rename
4552 it to ...
4553 (linux_supports_hardware_single_step): ... New function.
4554 (linux_target_ops): Update.
4555 * lynx-low.c (lynx_target_ops): Set field
4556 supports_hardware_single_step to target_can_do_hardware_single_step.
4557 * nto-low.c (nto_target_ops): Likewise.
4558 * spu-low.c (spu_target_ops): Likewise.
4559 * win32-low.c (win32_target_ops): Likewise.
4560 * target.c (target_can_do_hardware_single_step): New function.
4561 * target.h (struct target_ops) <supports_conditional_breakpoints>:
4562 Remove. <supports_hardware_single_step>: New field.
4563 (target_supports_conditional_breakpoints): Remove.
4564 (target_supports_hardware_single_step): New macro.
4565 (target_can_do_hardware_single_step): Declare.
4566 * server.c (handle_query): Use target_supports_hardware_single_step
4567 instead of target_supports_conditional_breakpoints.
4568
ade90bde
YQ
45692015-09-15 Yao Qi <yao.qi@linaro.org>
4570
4571 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
4572 function.
4573 (struct linux_target_ops the_low_target): Install
4574 aarch64_linux_siginfo_fixup.
4575
94585166
DB
45762015-09-11 Don Breazeal <donb@codesourcery.com>
4577 Luis Machado <lgustavo@codesourcery.com>
4578
4579 * linux-low.c (linux_mourn): Static declaration.
4580 (linux_arch_setup): Move in front of
4581 handle_extended_wait.
4582 (linux_arch_setup_thread): New function.
4583 (handle_extended_wait): Handle exec events. Call
4584 linux_arch_setup_thread. Make event_lwp argument a
4585 pointer-to-a-pointer.
4586 (check_zombie_leaders): Do not check stopped threads.
4587 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
4588 (linux_low_filter_event): Add lwp and thread for exec'ing
4589 non-leader thread if leader thread has been deleted.
4590 Refactor code into linux_arch_setup_thread and call it.
4591 Pass child lwp pointer by reference to handle_extended_wait.
4592 (linux_wait_for_event_filtered): Update comment.
4593 (linux_wait_1): Prevent clobbering exec event status.
4594 (linux_supports_exec_events): New function.
4595 (linux_target_ops) <supports_exec_events>: Initialize new member.
4596 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
4597 new member.
4598 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
4599 * server.c (report_exec_events): New global variable.
4600 (handle_query): Handle qSupported query for exec-events feature.
4601 (captured_main): Initialize report_exec_events.
4602 * server.h (report_exec_events): Declare new global variable.
4603 * target.h (struct target_ops) <supports_exec_events>: New
4604 member.
4605 (target_supports_exec_events): New macro.
4606 * win32-low.c (win32_target_ops) <supports_exec_events>:
4607 Initialize new member.
4608
0568462b
MM
46092015-09-09 Markus Metzger <markus.t.metzger@intel.com>
4610
4611 * linux-low.c (linux_low_enable_btrace): Remove.
4612 (linux_target_ops): Replace linux_low_enable_btrace with
4613 linux_enable_btrace.
4614
39edd165
YQ
46152015-09-03 Yao Qi <yao.qi@linaro.org>
4616
4617 * linux-aarch64-low.c (aarch64_insert_point): Call
4618 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
4619 returns true.
4620
1db33b5a
UW
46212015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
4622
4623 * linux-low.c (check_stopped_by_breakpoint): Use
4624 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
4625
ab290430
PA
46262015-08-27 Pedro Alves <palves@redhat.com>
4627
4628 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
4629
8d749320
SM
46302015-08-26 Simon Marchi <simon.marchi@ericsson.com>
4631
6711b7f8
SM
4632 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
4633 the XNEW-family equivalent.
8d749320
SM
4634 (compile_bytecodes): Likewise.
4635 * dll.c (loaded_dll): Likewise.
4636 * event-loop.c (append_callback_event): Likewise.
4637 (create_file_handler): Likewise.
4638 (create_file_event): Likewise.
4639 * hostio.c (handle_open): Likewise.
4640 * inferiors.c (add_thread): Likewise.
4641 (add_process): Likewise.
4642 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
4643 * linux-arm-low.c (arm_new_process): Likewise.
4644 (arm_new_thread): Likewise.
4645 * linux-low.c (add_to_pid_list): Likewise.
4646 (linux_add_process): Likewise.
4647 (handle_extended_wait): Likewise.
4648 (add_lwp): Likewise.
4649 (enqueue_one_deferred_signal): Likewise.
4650 (enqueue_pending_signal): Likewise.
4651 (linux_resume_one_lwp_throw): Likewise.
4652 (linux_resume_one_thread): Likewise.
4653 (linux_read_memory): Likewise.
4654 (linux_write_memory): Likewise.
4655 * linux-mips-low.c (mips_linux_new_process): Likewise.
4656 (mips_linux_new_thread): Likewise.
4657 (mips_add_watchpoint): Likewise.
4658 * linux-x86-low.c (initialize_low_arch): Likewise.
4659 * lynx-low.c (lynx_add_process): Likewise.
4660 * mem-break.c (set_raw_breakpoint_at): Likewise.
4661 (set_breakpoint): Likewise.
4662 (add_condition_to_breakpoint): Likewise.
4663 (add_commands_to_breakpoint): Likewise.
4664 (clone_agent_expr): Likewise.
4665 (clone_one_breakpoint): Likewise.
4666 * regcache.c (new_register_cache): Likewise.
4667 * remote-utils.c (look_up_one_symbol): Likewise.
4668 * server.c (queue_stop_reply): Likewise.
4669 (start_inferior): Likewise.
4670 (queue_stop_reply_callback): Likewise.
4671 (handle_target_event): Likewise.
4672 * spu-low.c (fetch_ppc_memory): Likewise.
4673 (store_ppc_memory): Likewise.
4674 * target.c (set_target_ops): Likewise.
4675 * thread-db.c (thread_db_load_search): Likewise.
4676 (try_thread_db_load_1): Likewise.
4677 * tracepoint.c (add_tracepoint): Likewise.
4678 (add_tracepoint_action): Likewise.
4679 (create_trace_state_variable): Likewise.
4680 (cmd_qtdpsrc): Likewise.
4681 (cmd_qtro): Likewise.
4682 (add_while_stepping_state): Likewise.
4683 * win32-low.c (child_add_thread): Likewise.
4684 (get_image_name): Likewise.
4685
ed8b7b42
YQ
46862015-08-25 Yao Qi <yao.qi@linaro.org>
4687
4688 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
4689
db3cb7cb
YQ
46902015-08-25 Yao Qi <yao.qi@linaro.org>
4691
4692 * Makefile.in (aarch64-linux.o): New rule.
4693 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
4694 srv_tgtobj.
4695 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
4696 (aarch64_init_debug_reg_state): Make it extern.
4697 (aarch64_linux_prepare_to_resume): Remove.
4698
f6011a1c
YQ
46992015-08-25 Yao Qi <yao.qi@linaro.org>
4700
4701 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
4702 lwp_arch_private_info and ptid_of_lwp.
4703
88e2cf7e
YQ
47042015-08-25 Yao Qi <yao.qi@linaro.org>
4705
4706 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
4707 Find proc_info by find_process_pid. All callers updated.
4708
5e35436e
YQ
47092015-08-25 Yao Qi <yao.qi@linaro.org>
4710
4711 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
4712 Remove.
4713 (debug_reg_change_callback): Remove.
4714 (aarch64_notify_debug_reg_change): Remove.
4715
4a8a7965
YQ
47162015-08-25 Yao Qi <yao.qi@linaro.org>
4717
4718 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
4719 Call current_lwp_ptid.
4720
32a271ee
YQ
47212015-08-25 Yao Qi <yao.qi@linaro.org>
4722
4723 * linux-aarch64-low.c (debug_reg_change_callback): Use
4724 debug_printf.
4725
0d51c8d7
YQ
47262015-08-25 Yao Qi <yao.qi@linaro.org>
4727
4728 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
4729
31a43dd5
YQ
47302015-08-25 Yao Qi <yao.qi@linaro.org>
4731
4732 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
4733
8ee52567
YQ
47342015-08-25 Yao Qi <yao.qi@linaro.org>
4735
4736 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
4737 the code.
4738
ff3f0f45
YQ
47392015-08-25 Yao Qi <yao.qi@linaro.org>
4740
4741 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
4742 Remove.
4743 (debug_reg_change_callback): Remove argument entry and add argument
4744 lwp. Remove local variable thread. Don't print thread id in the
4745 debugging output. Don't check whether pid of thread equals to pid.
4746 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
4747 iterate_over_lwps instead find_inferior.
4748
3d40fbb5
PA
47492015-08-24 Pedro Alves <palves@redhat.com>
4750
4751 * inferiors.c (get_first_process): New function.
4752 * inferiors.h (get_first_process): New declaration.
4753 * remote-utils.c (read_ptid): Default to the first process in the
4754 list, instead of to the current thread's process.
4755
438e1e42
PA
47562015-08-24 Pedro Alves <palves@redhat.com>
4757
4758 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
4759 * event-loop.c: Likewise.
4760 * remote-utils.c: Likewise.
4761 * tracepoint.c: Likewise.
4762
a8c6d4fc
PA
47632015-08-24 Pedro Alves <palves@redhat.com>
4764
4765 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
4766 ptid_get_lwp.
4767
99b0bb12
PA
47682015-08-21 Pedro Alves <palves@redhat.com>
4769
4770 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
4771 instead of literal 1.
4772
f8904751
PA
47732015-08-21 Pedro Alves <palves@redhat.com>
4774
4775 * tdesc.c (default_description): Explicitly zero-initialize.
4776
465a859e
PA
47772015-08-21 Pedro Alves <palves@redhat.com>
4778
4779 PR gdb/18749
4780 * inferiors.c (remove_thread): Discard any pending stop reply for
4781 this thread.
4782 * server.c (remove_all_on_match_pid): Rename to ...
4783 (remove_all_on_match_ptid): ... this. Work with a filter ptid
4784 instead of a pid.
4785 (discard_queued_stop_replies): Change parameter to a ptid. Now
4786 extern.
4787 (handle_v_kill, kill_inferior_callback, captured_main)
4788 (process_serial_event): Adjust.
4789 * server.h (discard_queued_stop_replies): Declare.
4790
f0db101d
PA
47912015-08-21 Pedro Alves <palves@redhat.com>
4792
4793 * linux-low.c (wait_for_sigstop): Always switch to no thread
4794 selected if the previously current thread dies.
4795 * lynx-low.c (lynx_request_interrupt): Use the first thread's
4796 process instead of the current thread's.
4797 * remote-utils.c (input_interrupt): Don't check if there's no
4798 current thread.
4799 * server.c (gdb_read_memory, gdb_write_memory): If setting the
4800 current thread to the general thread fails, error out.
4801 (handle_qxfer_auxv, handle_qxfer_libraries)
4802 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
4803 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
4804 (handle_query): Check if there's a thread selected instead of
4805 checking whether there's any thread in the thread list.
4806 (handle_qxfer_threads, handle_qxfer_btrace)
4807 (handle_qxfer_btrace_conf): Don't error out early if there's no
4808 thread in the thread list.
4809 (handle_v_cont, myresume): Don't set the current thread to the
4810 continue thread.
4811 (process_serial_event) <Hg handling>: Also set thread_id if the
4812 previous general thread is still alive.
4813 (process_serial_event) <g/G handling>: If setting the current
4814 thread to the general thread fails, error out.
4815 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
4816 thread's lwp instead of the current thread's.
4817 * target.c (set_desired_thread): If the desired thread was not
4818 found, leave the current thread pointing to NULL. Return an int
4819 (boolean) indicating success.
4820 * target.h (set_desired_thread): Change return type to int.
4821
40045d91
MF
48222015-08-20 Max Filippov <jcmvbkbc@gmail.com>
4823
4824 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
4825 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
4826 #includes.
4827 (ps_get_thread_area): New function.
4828
45face3b
GB
48292015-08-19 Gary Benson <gbenson@redhat.com>
4830
4831 * hostio.c (handle_pread): Do not attempt to read more data
4832 than hostio_reply_with_data can fit in a packet.
4833
16d5f642
JB
48342015-08-18 Joel Brobecker <brobecker@adacore.com>
4835
4836 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
4837
a738da3a
MF
48382015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
4839
4840 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
4841
33ebda9d
PA
48422015-08-06 Pedro Alves <palves@redhat.com>
4843
4844 * tracepoint.c (expr_eval_result): Now an int.
4845
a44892be
PA
48462015-08-06 Pedro Alves <palves@redhat.com>
4847
4848 * gdbthread.h (struct regcache): Forward declare.
4849 (struct thread_info) <regcache_data>: Now a struct regcache
4850 pointer.
4851 * inferiors.c (inferior_regcache_data)
4852 (set_inferior_regcache_data): Now work with struct regcache
4853 pointers.
4854 * inferiors.h (struct regcache): Forward declare.
4855 (inferior_regcache_data, set_inferior_regcache_data): Now work
4856 with struct regcache pointers.
4857 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
4858 (free_register_cache_thread): Remove struct regcache pointer
4859 casts.
4860
608a1e46
PA
48612015-08-06 Pedro Alves <palves@redhat.com>
4862
4863 * server.c (captured_main): On error, print the exception message
4864 to stderr, and if run_once is set, throw a quit.
4865
f0ce0d3a
PA
48662015-08-06 Pedro Alves <palves@redhat.com>
4867
4868 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
4869 the current thread.
4870
bf47e248
PA
48712015-08-06 Pedro Alves <palves@redhat.com>
4872
4873 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
4874 reading beyond the passed in buffer length.
4875
b6b9ffcc
PL
48762015-08-06 Pierre Langlois <pierre.langlois@arm.com>
4877
4878 * tracepoint.c (symbol_list) <required>: Remove.
4879
863d01bd
PA
48802015-08-06 Pedro Alves <palves@redhat.com>
4881
4882 * linux-low.c (handle_extended_wait): Set the fork child's suspend
4883 count if stopping and suspending threads.
4884 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
4885 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
4886 (linux_detach): Complete an ongoing step-over.
4887 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
4888 throughout.
4889 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
4890 (linux_wait_1): If passing a signal to the inferior after
4891 finishing a step-over, unsuspend and re-resume all lwps. If we
4892 see a single-step event but the thread should be continuing, don't
4893 pass the trap to gdb.
4894 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
4895 internal_error instead of gdb_assert.
4896 (enqueue_pending_signal): New function.
4897 (check_ptrace_stopped_lwp_gone): Add debug output.
4898 (start_step_over): Use internal_error instead of gdb_assert.
4899 (complete_ongoing_step_over): New function.
4900 (linux_resume_one_thread): Don't resume a suspended thread.
4901 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
4902 it stepping.
4903
00db26fa
PA
49042015-08-06 Pedro Alves <palves@redhat.com>
4905
4906 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
4907 (linux_thread_alive): Use lwp_is_marked_dead.
4908 (extended_event_reported): Delete.
4909 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
4910 instead of extended_event_reported.
4911 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
4912 as well.
4913 (lwp_is_marked_dead): New function.
4914 (lwp_running): Use lwp_is_marked_dead.
4915 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
4916 comment.
4917
ad071a30
PA
49182015-08-06 Pedro Alves <palves@redhat.com>
4919
4920 * linux-low.c (linux_wait_1): Move fork event output out of the
4921 !report_to_gdb check. Pass event_child->waitstatus to
4922 target_waitstatus_to_string instead of ourstatus.
4923
524b57e6
YQ
49242015-08-04 Yao Qi <yao.qi@linaro.org>
4925
4926 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
4927 if current_thread is 32 bit.
4928
6085d6f6
YQ
49292015-08-04 Yao Qi <yao.qi@linaro.org>
4930
4931 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4932 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4933 * server.c (extended_protocol): Remove "static".
4934 * server.h (extended_protocol): Declare it.
4935
8a7e4587
YQ
49362015-08-04 Yao Qi <yao.qi@linaro.org>
4937
4938 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
4939 both aarch64 and aarch32.
4940 (aarch64_set_pc): Likewise.
4941
3b53ae99
YQ
49422015-08-04 Yao Qi <yao.qi@linaro.org>
4943
4944 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
4945 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
4946 arm-with-neon.xml to srv_xmlfiles.
4947 * linux-aarch64-low.c: Include linux-aarch32-low.h.
4948 (is_64bit_tdesc): New function.
4949 (aarch64_linux_read_description): New function.
4950 (aarch64_arch_setup): Call aarch64_linux_read_description.
4951 (regs_info): Rename to regs_info_aarch64.
4952 (aarch64_regs_info): Return right regs_info.
4953 (initialize_low_arch): Call initialize_low_arch_aarch32.
4954
bd9e6534
YQ
49552015-08-04 Yao Qi <yao.qi@linaro.org>
4956
4957 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
4958 * linux-aarch32-low.c: New file.
4959 * linux-aarch32-low.h: New file.
4960 * linux-arm-low.c (arm_fill_gregset): Move it to
4961 linux-aarch32-low.c.
4962 (arm_store_gregset): Likewise.
4963 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
4964 (arm_store_vfpregset): Call arm_store_vfpregset_num.
4965 (arm_arch_setup): Check if PTRACE_GETREGSET works.
4966 (regs_info): Rename to regs_info_arm.
4967 (arm_regs_info): Return regs_info_aarch32 if
4968 have_ptrace_getregset is 1 and target description is
4969 arm_with_neon or arm_with_vfpv3.
4970 (initialize_low_arch): Don't call init_registers_arm_with_neon.
4971 Call initialize_low_arch_aarch32 instead.
4972
ded48a5e
YQ
49732015-08-04 Yao Qi <yao.qi@linaro.org>
4974
4975 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
4976 * linux-low.c: ... here.
4977 * linux-low.h (have_ptrace_getregset): Declare it.
4978
96e9210f
PA
49792015-08-04 Pedro Alves <palves@redhat.com>
4980
4981 * thread-db.c (struct thread_db): Use new typedefs.
4982 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
4983 CHK calls.
4984 (disable_thread_event_reporting): Cast result of dlsym to
4985 destination function pointer type.
4986 (thread_db_mourn): Use td_ta_delete_ftype.
4987
af60a1ef
SL
49882015-08-03 Sandra Loosemore <sandra@codesourcery.com>
4989
4990 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
4991 arch variant.
4992 (CDX_BREAKPOINT): Define for R2.
4993 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
4994 (the_low_target): Add comments.
4995
e8b41681
YQ
49962015-07-30 Yao Qi <yao.qi@linaro.org>
4997
4998 * linux-arm-low.c (arm_hwcap): Remove it.
4999 (arm_read_description): New local variable arm_hwcap. Don't
5000 set arm_hwcap to zero.
5001
89abb039
YQ
50022015-07-30 Yao Qi <yao.qi@linaro.org>
5003
5004 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
5005 Use regcache->tdesc instead.
5006 (arm_store_wmmxregset): Likewise.
5007 (arm_fill_vfpregset): Likewise.
5008 (arm_store_vfpregset): Likewise.
5009
deca266c
YQ
50102015-07-30 Yao Qi <yao.qi@linaro.org>
5011
5012 * linux-arm-low.c: Include arch/arm.h.
5013 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
5014 (arm_store_gregset): Likewise.
5015
aa58a496
SM
50162015-07-29 Simon Marchi <simon.marchi@ericsson.com>
5017
5018 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
5019 ptrace's 4th parameter.
5020
50904b25
YQ
50212015-07-27 Yao Qi <yao.qi@linaro.org>
5022
5023 * configure.srv (case aarch64*-*-linux*): Don't set
5024 srv_linux_usrregs.
5025
5826e159
PA
50262015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
5027
5028 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
5029 sys/ptrace.h.
5030 * linux-arm-low.c: Likewise.
5031 * linux-cris-low.c: Likewise.
5032 * linux-crisv32-low.c: Likewise.
5033 * linux-low.c: Likewise.
5034 * linux-m68k-low.c: Likewise.
5035 * linux-mips-low.c: Likewise.
5036 * linux-nios2-low.c: Likewise.
5037 * linux-s390-low.c: Likewise.
5038 * linux-sparc-low.c: Likewise.
5039 * linux-tic6x-low.c: Likewise.
5040 * linux-tile-low.c: Likewise.
5041 * linux-x86-low.c: Likewise.
5042
54019719
PA
50432015-07-24 Pedro Alves <palves@redhat.com>
5044
5045 * config.in: Regenerate.
5046 * configure: Regenerate.
5047
eb7aa561
PA
50482015-07-24 Pedro Alves <palves@redhat.com>
5049
5050 * acinclude.m4: Include ../ptrace.m4.
5051 * configure.ac: Call GDB_AC_PTRACE.
5052 * config.in, configure: Regenerate.
5053
55d7b841
YQ
50542015-07-24 Yao Qi <yao.qi@linaro.org>
5055
5056 * linux-low.c (linux_create_inferior): Remove setting to
5057 proc->priv->new_inferior.
5058 (linux_attach): Likewise.
5059 (linux_low_filter_event): Likewise.
5060 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
5061
c06cbd92
YQ
50622015-07-24 Yao Qi <yao.qi@linaro.org>
5063
5064 * linux-low.c (linux_arch_setup): New function.
5065 (linux_low_filter_event): If proc->tdesc is NULL and
5066 proc->attached is true, call the_low_target.arch_setup.
5067 Otherwise, keep status pending, and return.
5068 (linux_resume_one_lwp_throw): Don't call get_pc if
5069 thread->while_stepping isn't NULL. Don't call
5070 get_thread_regcache if proc->tdesc is NULL.
5071 (need_step_over_p): Return 0 if proc->tdesc is NULL.
5072 (linux_target_ops): Install arch_setup.
5073 * server.c (start_inferior): Call the_target->arch_setup.
5074 * target.h (struct target_ops) <arch_setup>: New field.
5075 (target_arch_setup): New marco.
5076 * lynx-low.c (lynx_target_ops): Update.
5077 * nto-low.c (nto_target_ops): Update.
5078 * spu-low.c (spu_target_ops): Update.
5079 * win32-low.c (win32_target_ops): Update.
5080
5ae3ebba
YQ
50812015-07-24 Yao Qi <yao.qi@linaro.org>
5082
5083 * linux-low.c (linux_add_process): Don't set
5084 proc->priv->new_inferior.
5085 (linux_create_inferior): Set proc->priv->new_inferior to 1.
5086 (linux_attach): Likewise.
5087
eb97750b
YQ
50882015-07-24 Yao Qi <yao.qi@linaro.org>
5089
5090 * server.c (start_inferior): Code refactor.
5091
51aee833
YQ
50922015-07-24 Yao Qi <yao.qi@linaro.org>
5093
5094 * server.c (process_serial_event): Set general_thread.
5095
af1b22f3
YQ
50962015-07-21 Yao Qi <yao.qi@linaro.org>
5097
5098 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
5099 aarch64_linux_get_debug_reg_capacity.
5100
554717a3
YQ
51012015-07-17 Yao Qi <yao.qi@linaro.org>
5102
5103 * Makefile.in (aarch64-linux-hw-point.o): New rule.
5104 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
5105 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
5106 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
5107 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
5108 (AARCH64_HWP_ALIGNMENT): Likewise.
5109 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
5110 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
5111 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
5112 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
5113 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
5114 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
5115 (struct aarch64_debug_reg_state): Likewise.
5116 (struct arch_lwp_info): Likewise.
5117 (aarch64_align_watchpoint): Likewise.
5118 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
5119 (aarch64_watchpoint_length): Likewise.
5120 (aarch64_point_encode_ctrl_reg): Likewise
5121 (aarch64_point_is_aligned): Likewise.
5122 (aarch64_align_watchpoint): Likewise.
5123 (aarch64_linux_set_debug_regs):
5124 (aarch64_dr_state_insert_one_point): Likewise.
5125 (aarch64_dr_state_remove_one_point): Likewise.
5126 (aarch64_handle_breakpoint): Likewise.
5127 (aarch64_handle_aligned_watchpoint): Likewise.
5128 (aarch64_handle_unaligned_watchpoint): Likewise.
5129 (aarch64_handle_watchpoint): Likewise.
5130
c67ca4de
YQ
51312015-07-17 Yao Qi <yao.qi@linaro.org>
5132
5133 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
5134 and don't aarch64_get_debug_reg_state. All callers update.
5135 (aarch64_handle_aligned_watchpoint): Likewise.
5136 (aarch64_handle_unaligned_watchpoint): Likewise.
5137 (aarch64_handle_watchpoint): Likewise.
5138 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
5139 (aarch64_remove_point): Likewise.
5140
25abf979
YQ
51412015-07-17 Yao Qi <yao.qi@linaro.org>
5142
5143 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
5144 debug_printf.
5145 (aarch64_handle_unaligned_watchpoint): Likewise.
5146
db1ff28b
JK
51472015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5148
5149 Revert the previous 3 commits:
5150 Move gdb_regex* to common/
5151 Move linux_find_memory_regions_full & co.
5152 gdbserver build-id attribute generator
5153
700ca40f
JK
51542015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5155 Jan Kratochvil <jan.kratochvil@redhat.com>
5156
5157 gdbserver build-id attribute generator.
5158 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
5159 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
5160 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
5161 (find_phdr): New.
5162 (get_dynamic): Use find_pdhr to traverse program headers.
5163 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
5164 (compare_mapping_entry_range, struct find_memory_region_callback_data)
5165 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
5166 (get_hex_build_id): New.
5167 (linux_qxfer_libraries_svr4): Add optional build-id attribute
5168 to reply XML document.
5169
9904185c
JK
51702015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5171 Jan Kratochvil <jan.kratochvil@redhat.com>
5172
5173 * target.c: Include target/target-utils.h and fcntl.h.
5174 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
5175 (target_fileio_read_stralloc): New functions.
5176
6e5b4429
JK
51772015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5178
5179 * Makefile.in (OBS): Add gdb_regex.o.
5180 (gdb_regex.o): New.
5181 * config.in: Rebuilt.
5182 * configure: Rebuilt.
5183
ddc98fbf
JK
51842015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5185 Jan Kratochvil <jan.kratochvil@redhat.com>
5186
5187 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
5188 * Makefile.in (OBS): Add target-utils.o.
5189 (linux-maps.o, target-utils.o): New.
5190 * configure.srv (srv_linux_obj): Add linux-maps.o.
5191
e57bb7a0
PL
51922015-07-15 Pierre Langlois <pierre.langlois@arm.com>
5193
5194 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
5195 function, return 1.
5196 (the_low_target): Install it.
5197
586b02a9
PA
51982015-07-14 Pedro Alves <palves@redhat.com>
5199
5200 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
5201 Instead, ignore ECHILD, and throw an error for other errnos.
5202
58c1b36c
PA
52032015-07-10 Pedro Alves <palves@redhat.com>
5204
5205 * event-loop.c (struct callback_event) <data>: Change type to
5206 gdb_client_data instance instead of gdb_client_data pointer.
5207 (append_callback_event): Adjust.
5208
421530db
PL
52092015-07-10 Pierre Langlois <pierre.langlois@arm.com>
5210
5211 * linux-aarch64-low.c: Add comments for each linux_target_ops
5212 method. Remove comments already covered in target_ops and
5213 linux_target_ops definitions.
5214 (the_low_target): Add comments for each unimplemented method.
5215
c2d65f38
YQ
52162015-07-09 Yao Qi <yao.qi@linaro.org>
5217
5218 * linux-aarch64-low.c (aarch64_regmap): Remove.
5219 (aarch64_usrregs_info): Remove.
5220 (regs_info): Set field usrregs to NULL.
5221
b20a6524
MM
52222015-07-02 Markus Metzger <markus.t.metzger@intel.com>
5223
5224 * linux-low.c: Include "rsp-low.h"
5225 (linux_low_encode_pt_config, linux_low_encode_raw): New.
5226 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
5227 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
5228 (handle_btrace_enable_pt): New.
5229 (handle_btrace_general_set): Support "pt".
5230 (handle_btrace_conf_general_set): Support "pt:size".
5231
96c97461
PL
52322015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5233
5234 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
5235 Z_PACKET_SW_BP.
5236
37d66942
PL
52372015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5238
5239 * linux-aarch64-low.c: Remove comment about endianness.
5240 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
5241 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
5242 memcmp.
5243
dc06243f
GB
52442015-06-24 Gary Benson <gbenson@redhat.com>
5245
5246 * linux-i386-ipa.c (stdint.h): Do not include.
5247 * lynx-i386-low.c (stdint.h): Likewise.
5248 * lynx-ppc-low.c (stdint.h): Likewise.
5249 * mem-break.c (stdint.h): Likewise.
5250 * thread-db.c (stdint.h): Likewise.
5251 * tracepoint.c (stdint.h): Likewise.
5252 * win32-low.c (stdint.h): Likewise.
5253
124e13d9
SM
52542015-06-18 Simon Marchi <simon.marchi@ericsson.com>
5255
5256 * server.c (write_qxfer_response): Update call to
5257 remote_escape_output.
5258
909c2cda
JK
52592015-06-15 Aleksandar Ristovski <aristovski@qnx.com
5260 Jan Kratochvil <jan.kratochvil@redhat.com>
5261
5262 Merge multiple hex conversions.
5263 * gdbreplay.c (tohex): Rename to 'fromhex'.
5264 (logchar): Use fromhex.
5265
24c05f46
JK
52662015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
5267
5268 * server.c (handle_qxfer_libraries): Set `version' attribute for
5269 <library-list>.
5270
14d2069a
GB
52712015-06-10 Gary Benson <gbenson@redhat.com>
5272
5273 * target.h (struct target_ops) <multifs_open>: New field.
5274 <multifs_unlink>: Likewise.
5275 <multifs_readlink>: Likewise.
5276 * linux-low.c (nat/linux-namespaces.h): New include.
5277 (linux_target_ops): Initialize the_target->multifs_open,
5278 the_target->multifs_unlink and the_target->multifs_readlink.
5279 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
5280 * hostio.c (hostio_fs_pid): New static variable.
5281 (hostio_handle_new_gdb_connection): New function.
5282 (handle_setfs): Likewise.
5283 (handle_open): Use the_target->multifs_open as appropriate.
5284 (handle_unlink): Use the_target->multifs_unlink as appropriate.
5285 (handle_readlink): Use the_target->multifs_readlink as
5286 appropriate.
5287 (handle_vFile): Handle vFile:setfs packets.
5288 * server.c (handle_query): Call hostio_handle_new_gdb_connection
5289 after target_handle_new_gdb_connection.
5290
4b8b5e72
GB
52912015-06-10 Gary Benson <gbenson@redhat.com>
5292
5293 * configure.ac (AC_CHECK_FUNCS): Add setns.
5294 * config.in: Regenerate.
5295 * configure: Likewise.
5296 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
5297 (linux-namespaces.o): New rule.
5298 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
5299
3ac2e371
GB
53002015-06-09 Gary Benson <gbenson@redhat.com>
5301
5302 * hostio.c (handle_open): Process mode argument with
5303 fileio_to_host_mode.
5304
ca9b78ce
YQ
53052015-06-01 Yao Qi <yao.qi@linaro.org>
5306
5307 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
5308 * linux-x86-low.c: Likewise.
5309
bfacd19d
DB
53102015-05-28 Don Breazeal <donb@codesourcery.com>
5311
5312 * linux-low.c (handle_extended_wait): Initialize
5313 thread_info.last_resume_kind for new fork children.
5314
452003ef
PA
53152015-05-15 Pedro Alves <palves@redhat.com>
5316
5317 * target.h (target_handle_new_gdb_connection): Rewrite using if
5318 wrapped in do/while.
5319
1041a03c
JB
53202015-05-14 Joel Brobecker <brobecker@adacore.com>
5321
5322 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
5323 * configure, config.in: Regenerate.
5324 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
5325 Declare typedef.
5326
c269dbdb
DB
53272015-05-12 Don Breazeal <donb@codesourcery.com>
5328
5329 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
5330 PTRACE_EVENT_VFORK_DONE.
5331 (linux_low_ptrace_options, extended_event_reported): Add vfork
5332 events.
5333 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
5334 and "vforkdone" for RSP 'T' Stop Reply Packet.
5335 * server.h (report_vfork_events): Declare
5336 global variable.
5337
3a8a0396
DB
53382015-05-12 Don Breazeal <donb@codesourcery.com>
5339
5340 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
5341 (the_low_target) <new_fork>: Initialize new member.
5342 * linux-arm-low.c (arm_new_fork): New function.
5343 (the_low_target) <new_fork>: Initialize new member.
5344 * linux-low.c (handle_extended_wait): Call new target function
5345 new_fork.
5346 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
5347 * linux-mips-low.c (mips_add_watchpoint): New function
5348 extracted from mips_insert_point.
5349 (the_low_target) <new_fork>: Initialize new member.
5350 (mips_linux_new_fork): New function.
5351 (mips_insert_point): Call mips_add_watchpoint.
5352 * linux-x86-low.c (x86_linux_new_fork): New function.
5353 (the_low_target) <new_fork>: Initialize new member.
5354
de0d863e
DB
53552015-05-12 Don Breazeal <donb@codesourcery.com>
5356
5357 * linux-low.c (handle_extended_wait): Implement return value,
5358 rename argument 'event_child' to 'event_lwp', handle
5359 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
5360 (linux_low_ptrace_options): New function.
5361 (linux_low_filter_event): Call linux_low_ptrace_options,
5362 use different argument fo linux_enable_event_reporting,
5363 use return value from handle_extended_wait.
5364 (extended_event_reported): New function.
5365 (linux_wait_1): Call extended_event_reported and set
5366 status to report fork events.
5367 (linux_write_memory): Add pid to debug message.
5368 (reset_lwp_ptrace_options_callback): New function.
5369 (linux_handle_new_gdb_connection): New function.
5370 (linux_target_ops): Initialize new structure member.
5371 * linux-low.h (struct lwp_info) <waitstatus>: New member.
5372 * lynx-low.c: Initialize new structure member.
5373 * remote-utils.c (prepare_resume_reply): Implement stop reason
5374 "fork" for "T" stop message.
5375 * server.c (handle_query): Call handle_new_gdb_connection.
5376 * server.h (report_fork_events): Declare global flag.
5377 * target.h (struct target_ops) <handle_new_gdb_connection>:
5378 New member.
5379 (target_handle_new_gdb_connection): New macro.
5380 * win32-low.c: Initialize new structure member.
5381
ddcbc397
DB
53822015-05-12 Don Breazeal <donb@codesourcery.com>
5383
5384 * mem-break.c (APPEND_TO_LIST): Define macro.
5385 (clone_agent_expr): New function.
5386 (clone_one_breakpoint): New function.
5387 (clone_all_breakpoints): New function.
5388 * mem-break.h: Declare new functions.
5389
89245bc0
DB
53902015-05-12 Don Breazeal <donb@codesourcery.com>
5391
5392 * linux-low.c (linux_supports_fork_events): New function.
5393 (linux_supports_vfork_events): New function.
5394 (linux_target_ops): Initialize new structure members.
5395 (initialize_low): Call linux_check_ptrace_features.
5396 * lynx-low.c (lynx_target_ops): Initialize new structure
5397 members.
5398 * server.c (report_fork_events, report_vfork_events):
5399 New global flags.
5400 (handle_query): Add new features to qSupported packet and
5401 response.
5402 (captured_main): Initialize new global variables.
5403 * target.h (struct target_ops) <supports_fork_events>:
5404 New member.
5405 <supports_vfork_events>: New member.
5406 (target_supports_fork_events): New macro.
5407 (target_supports_vfork_events): New macro.
5408 * win32-low.c (win32_target_ops): Initialize new structure
5409 members.
5410
835205d0
GB
54112015-05-12 Gary Benson <gbenson@redhat.com>
5412
5413 * server.c (handle_qxfer_exec_file): Use current process
5414 if annex is empty.
5415
21e94bd9
SL
54162015-05-08 Sandra Loosemore <sandra@codesourcery.com>
5417
5418 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
5419 Remove HAVE_PTRACE_GETREGS conditionals.
5420 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
5421 instead of PTRACE_GETREGS and PTRACE_SETREGS.
5422
45614f15
YQ
54232015-05-08 Yao Qi <yao.qi@linaro.org>
5424
5425 * linux-low.c (linux_supports_conditional_breakpoints): New
5426 function.
5427 (linux_target_ops): Install new target method.
5428 * lynx-low.c (lynx_target_ops): Install NULL hook for
5429 supports_conditional_breakpoints.
5430 * nto-low.c (nto_target_ops): Likewise.
5431 * spu-low.c (spu_target_ops): Likewise.
5432 * win32-low.c (win32_target_ops): Likewise.
5433 * server.c (handle_query): Check
5434 target_supports_conditional_breakpoints.
5435 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5436 New field.
5437 (target_supports_conditional_breakpoints): New macro.
5438
80ad801e
PA
54392015-05-06 Pedro Alves <palves@redhat.com>
5440
5441 PR server/18081
5442 * server.c (start_inferior): If the process exits, mourn it.
5443
819843c7
GB
54442015-04-21 Gary Benson <gbenson@redhat.com>
5445
5446 * hostio.c (fileio_open_flags_to_host): Factored out to
5447 fileio_to_host_openflags in common/fileio.c. Single use
5448 updated.
5449
a2d5a9d7
MF
54502015-04-17 Max Filippov <jcmvbkbc@gmail.com>
5451
5452 * linux-xtensa-low.c (xtensa_fill_gregset)
5453 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
5454 XCHAL_HAVE_LOOP.
5455
deb44829
MF
54562015-04-17 Max Filippov <jcmvbkbc@gmail.com>
5457
5458 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
5459 (regs_info): Replace usrregs pointer with NULL.
5460
e57f1de3
GB
54612015-04-17 Gary Benson <gbenson@redhat.com>
5462
5463 * target.h (struct target_ops) <pid_to_exec_file>: New field.
5464 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
5465 * server.c (handle_qxfer_exec_file): New function.
5466 (qxfer_packets): Add exec-file entry.
5467 (handle_query): Report qXfer:exec-file:read as supported packet.
5468
62828379
RN
54692015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
5470
5471 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
5472
b88bb450
GB
54732015-04-09 Gary Benson <gbenson@redhat.com>
5474
5475 * hostio-errno.c (errno_to_fileio_error): Remove function.
5476 Update caller to use remote_fileio_to_fio_error.
5477
c8f4bfdd
YQ
54782015-04-09 Yao Qi <yao.qi@linaro.org>
5479
5480 * linux-low.c (linux_insert_point): Call
5481 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
5482 (linux_remove_point): Call remove_memory_breakpoint if type is
5483 raw_bkpt_type_sw.
5484 * linux-x86-low.c (x86_insert_point): Don't call
5485 insert_memory_breakpoint.
5486 (x86_remove_point): Don't call remove_memory_breakpoint.
5487
41f98f02
PA
54882015-04-01 Pedro Alves <palves@redhat.com>
5489 Cleber Rosa <crosa@redhat.com>
5490
5491 * server.c (gdbserver_usage): Reorganize and extend the usage
5492 message.
5493
2bf6fb9d
PA
54942015-03-24 Pedro Alves <palves@redhat.com>
5495
5496 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
5497 output. Also dump TRAP_TRACE.
5498 (linux_low_filter_event): In debug output, distinguish a
5499 resume_stop SIGSTOP from a delayed SIGSTOP.
5500
369f6daa
GB
55012015-03-24 Gary Benson <gbenson@redhat.com>
5502
5503 * linux-x86-low.c (x86_linux_new_thread): Moved to
5504 nat/x86-linux.c.
5505 (x86_linux_prepare_to_resume): Likewise.
5506
8e5d4070
GB
55072015-03-24 Gary Benson <gbenson@redhat.com>
5508
5509 * Makefile.in (x86-linux-dregs.o): New rule.
5510 * configure.srv: Add x86-linux-dregs.o to relevant targets.
5511 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
5512 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
5513 (x86_linux_dr_get): Likewise.
5514 (x86_linux_dr_set): Likewise.
5515 (update_debug_registers_callback): Likewise.
5516 (x86_linux_dr_set_addr): Likewise.
5517 (x86_linux_dr_get_addr): Likewise.
5518 (x86_linux_dr_set_control): Likewise.
5519 (x86_linux_dr_get_control): Likewise.
5520 (x86_linux_dr_get_status): Likewise.
5521 (x86_linux_update_debug_registers): Likewise.
5522
2b95d440
GB
55232015-03-24 Gary Benson <gbenson@redhat.com>
5524
5525 * linux-x86-low.c (x86_linux_update_debug_registers):
5526 New function, factored out from...
5527 (x86_linux_prepare_to_resume): ...this.
5528
14b0bc68
GB
55292015-03-24 Gary Benson <gbenson@redhat.com>
5530
5531 * linux-x86-low.c (x86_linux_dr_get): Update comments.
5532 (x86_linux_dr_set): Likewise.
5533 (update_debug_registers_callback): Likewise.
5534 (x86_linux_dr_set_addr): Likewise.
5535 (x86_linux_dr_get_addr): Likewise.
5536 (x86_linux_dr_set_control): Likewise.
5537 (x86_linux_dr_get_control): Likewise.
5538 (x86_linux_dr_get_status): Likewise.
5539 (x86_linux_prepare_to_resume): Likewise.
5540
5dfe6ca8
GB
55412015-03-24 Gary Benson <gbenson@redhat.com>
5542
5543 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
5544 Use perror_with_name. Pass string through gettext.
5545 (x86_linux_dr_set): Likewise.
5546
d33472ad
GB
55472015-03-24 Gary Benson <gbenson@redhat.com>
5548
5549 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
5550 (x86_linux_dr_set_addr): ...this.
5551 (x86_dr_low_get_addr): Rename to...
5552 (x86_linux_dr_get_addr): ...this.
5553 (x86_dr_low_set_control): Rename to...
5554 (x86_linux_dr_set_control): ...this.
5555 (x86_dr_low_get_control): Rename to...
5556 (x86_linux_dr_get_control): ...this.
5557 (x86_dr_low_get_status): Rename to...
5558 (x86_linux_dr_get_status): ...this.
5559 (x86_dr_low): Update with new function names.
5560
4b134ca1
GB
55612015-03-24 Gary Benson <gbenson@redhat.com>
5562
5563 * Makefile.in (x86-linux.o): New rule.
5564 * configure.srv: Add x86-linux.o to relevant targets.
5565 * linux-low.c (lwp_set_arch_private_info): New function.
5566 (lwp_arch_private_info): Likewise.
5567 * linux-x86-low.c: Include nat/x86-linux.h.
5568 (arch_lwp_info): Removed structure.
5569 (update_debug_registers_callback):
5570 Use lwp_set_debug_registers_changed.
5571 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
5572 and lwp_set_debug_registers_changed.
5573 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
5574
34c703da
GB
55752015-03-24 Gary Benson <gbenson@redhat.com>
5576
5577 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
5578 * linux-arm-low.c (arm_new_thread): Likewise.
5579 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
5580 * linux-mips-low.c (mips_linux_new_thread): Likewise.
5581 * linux-x86-low.c (x86_linux_new_thread): Likewise.
5582 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
5583
cff068da
GB
55842015-03-24 Gary Benson <gbenson@redhat.com>
5585
5586 * linux-low.c (ptid_of_lwp): New function.
5587 (lwp_is_stopped): Likewise.
5588 (lwp_stop_reason): Likewise.
5589 * linux-x86-low.c (update_debug_registers_callback):
5590 Use lwp_is_stopped.
5591 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
5592 lwp_stop_reason.
5593
b2f7c7e8
GB
55942015-03-24 Gary Benson <gbenson@redhat.com>
5595
5596 * linux-low.h (linux_stop_lwp): Remove declaration.
5597
6d4ee8c6
GB
55982015-03-24 Gary Benson <gbenson@redhat.com>
5599
5600 * linux-low.h: Include nat/linux-nat.h.
5601 * linux-low.c (iterate_over_lwps_args): New structure.
5602 (iterate_over_lwps_filter): New function.
5603 (iterate_over_lwps): Likewise.
5604 * linux-x86-low.c (update_debug_registers_callback):
5605 Update signature to what iterate_over_lwps expects.
5606 Remove PID check that iterate_over_lwps now performs.
5607 (x86_dr_low_set_addr): Use iterate_over_lwps.
5608 (x86_dr_low_set_control): Likewise.
5609
70a0bb6b
GB
56102015-03-24 Gary Benson <gbenson@redhat.com>
5611
5612 * linux-x86-low.c (x86_debug_reg_state): New function.
5613 (x86_linux_prepare_to_resume): Use the above.
5614
7b669087
GB
56152015-03-24 Gary Benson <gbenson@redhat.com>
5616
5617 * linux-low.c (current_lwp_ptid): New function.
5618 * linux-x86-low.c: Include nat/linux-nat.h.
5619 (x86_dr_low_get_addr): Use current_lwp_ptid.
5620 (x86_dr_low_get_control): Likewise.
5621 (x86_dr_low_get_status): Likewise.
5622
eef49a3d
PA
56232015-03-20 Pedro Alves <palves@redhat.com>
5624
5625 * tracepoint.c (cmd_qtstatus): Make "str" const.
5626
b2333d22
PA
56272015-03-20 Pedro Alves <palves@redhat.com>
5628
5629 * server.c (handle_general_set): Make "req_str" const.
5630
23f238d3
PA
56312015-03-19 Pedro Alves <palves@redhat.com>
5632
5633 * linux-low.c (linux_resume_one_lwp): Rename to ...
5634 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
5635 instead call perror_with_name.
5636 (check_ptrace_stopped_lwp_gone): New function.
5637 (linux_resume_one_lwp): Reimplement as wrapper around
5638 linux_resume_one_lwp_throw that swallows errors if the LWP is
5639 gone.
5640
91baf43f
PA
56412015-03-19 Pedro Alves <palves@redhat.com>
5642
5643 * linux-low.c (count_events_callback, select_event_lwp_callback):
5644 No longer check whether the thread has resume_stop as last resume
5645 kind.
5646
8bf3b159
PA
56472015-03-19 Pedro Alves <palves@redhat.com>
5648
5649 * linux-low.c (count_events_callback, select_event_lwp_callback):
5650 Use the lwp's status_pending_p field, not the thread's.
5651
b90fc188
PA
56522015-03-19 Pedro Alves <palves@redhat.com>
5653
5654 * linux-low.c (select_event_lwp_callback): Update comments to
5655 no longer mention SIGTRAP.
5656
464b0089
GB
56572015-03-18 Gary Benson <gbenson@redhat.com>
5658
5659 * server.c (handle_query): Do not report vFile:fstat as supported.
5660
aa9e327f
GB
56612015-03-11 Gary Benson <gbenson@redhat.com>
5662
5663 * hostio.c (sys/types.h): New include.
5664 (sys/stat.h): Likewise.
5665 (common-remote-fileio.h): Likewise.
5666 (handle_fstat): New function.
5667 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 5668
791c0056
GB
56692015-03-11 Gary Benson <gbenson@redhat.com>
5670
5671 * configure.ac (AC_CHECK_MEMBERS): Add checks for
5672 struct stat.st_blocks and struct stat.st_blksize.
5673 * configure: Regenerate.
5674 * config.in: Likewise.
5675 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
5676 (OBS): Add common-remote-fileio.o.
5677 (common-remote-fileio.o): New rule.
5678
9a9df970
PA
56792015-03-09 Pedro Alves <palves@redhat.com>
5680
5681 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
5682 'struct sockaddr' pointer in 'accept' call.
5683
9eb1356e
PA
56842015-03-09 Pedro Alves <palves@redhat.com>
5685
5686 Revert:
5687 2015-03-07 Pedro Alves <palves@redhat.com>
5688 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
5689 or <winsock2.h> here. Instead include "gdb_socket.h".
5690 (remote_open): Use union gdb_sockaddr_u.
5691 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
5692 or <winsock2.h> here. Instead include "gdb_socket.h".
5693 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
5694 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
5695 or <sys/un.h>.
5696 (init_named_socket, gdb_agent_helper_thread): Use union
5697 gdb_sockaddr_u.
5698
aac331e4
PA
56992015-03-07 Pedro Alves <palves@redhat.com>
5700
5701 * configure.ac (build_warnings): Move
5702 -Wdeclaration-after-statement to the C-specific set.
5703 * configure: Regenerate.
5704
366c75fc
PA
57052015-03-07 Pedro Alves <palves@redhat.com>
5706
5707 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
5708 or <winsock2.h> here. Instead include "gdb_socket.h".
5709 (remote_open): Use union gdb_sockaddr_u.
5710 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
5711 or <winsock2.h> here. Instead include "gdb_socket.h".
5712 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
5713 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
5714 or <sys/un.h>.
5715 (init_named_socket, gdb_agent_helper_thread): Use union
5716 gdb_sockaddr_u.
5717
492d29ea
PA
57182015-03-07 Pedro Alves <palves@redhat.com>
5719
5720 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
5721 instead.
5722
60a191ed
YQ
57232015-03-06 Yao Qi <yao.qi@linaro.org>
5724
5725 * linux-aarch64-low.c (aarch64_insert_point): Use
5726 show_debug_regs as a boolean.
5727 (aarch64_remove_point): Likewise.
5728
f5771b1d
PA
57292015-03-05 Pedro Alves <palves@redhat.com>
5730
5731 * lynx-low.c (lynx_target_ops): Install NULL hooks for
5732 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5733 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
5734 * nto-low.c (nto_target_ops): Likewise.
5735 * spu-low.c (spu_target_ops): Likewise.
5736 * win32-low.c (win32_target_ops): Likewise.
5737
3e572f71
PA
57382015-03-04 Pedro Alves <palves@redhat.com>
5739
72f4393d 5740 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
5741 Decide whether a breakpoint triggered based on the SIGTRAP's
5742 siginfo.si_code.
72f4393d
L
5743 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
5744 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
5745 (linux_low_filter_event): Check for breakpoints before checking
5746 watchpoints.
5747 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
5748 siginfo.si_code.
72f4393d
L
5749 (linux_stopped_by_sw_breakpoint)
5750 (linux_supports_stopped_by_sw_breakpoint)
5751 (linux_stopped_by_hw_breakpoint)
5752 (linux_supports_stopped_by_hw_breakpoint): New functions.
5753 (linux_target_ops): Install new target methods.
3e572f71 5754
1ec68e26
PA
57552015-03-04 Pedro Alves <palves@redhat.com>
5756
5757 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
5758 * server.c (swbreak_feature, hwbreak_feature): New globals.
5759 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
5760 (captured_main): Clear swbreak_feature and hwbreak_feature.
5761 * server.h (swbreak_feature, hwbreak_feature): Declare.
5762 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
5763 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
5764 supports_stopped_by_hw_breakpoint>: New fields.
5765 (target_supports_stopped_by_sw_breakpoint)
5766 (target_stopped_by_sw_breakpoint)
5767 (target_supports_stopped_by_hw_breakpoint)
5768 (target_stopped_by_hw_breakpoint): Declare.
5769
15c66dd6
PA
57702015-03-04 Pedro Alves <palves@redhat.com>
5771
5772 enum lwp_stop_reason -> enum target_stop_reason
5773 * linux-low.c (check_stopped_by_breakpoint): Adjust.
5774 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
5775 (linux_wait_1, stuck_in_jump_pad_callback)
5776 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
5777 (linux_stopped_by_watchpoint):
5778 * linux-low.h (enum lwp_stop_reason): Delete.
5779 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
5780 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
5781
98fc70d6
YQ
57822015-03-04 Yao Qi <yao.qi@linaro.org>
5783
5784 * Makefile.in (SFILES): Add linux-aarch64-low.c.
5785
dd2ac174
GB
57862015-03-03 Gary Benson <gbenson@redhat.com>
5787
5788 * hostio.c (handle_vFile): Fix prefix lengths.
5789
d68e53f4
MM
57902015-03-03 Markus Metzger <markus.t.metzger@intel.com>
5791
5792 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
5793 ptr_bits.
5794
bf2d68ab
AA
57952015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
5796
5797 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
5798 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
5799 (clean): Add "rm -f" for above C files.
5800 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
5801 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
5802 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
5803 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
5804 * linux-s390-low.c (HWCAP_S390_VX): New macro.
5805 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
5806 (init_registers_s390x_vx_linux64)
5807 (init_registers_s390x_tevx_linux64)
5808 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
5809 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
5810 declarations.
5811 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
5812 (s390_store_vxrs_high): New functions.
5813 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
5814 NT_S390_VXRS_HIGH.
5815 (s390_arch_setup): Add logic for selecting one of the new target
5816 descriptions. Activate the new vector regsets if applicable.
5817 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
5818 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
5819 and init_registers_s390x_tevx_linux64.
5820
c966a859
PA
58212015-03-01 Pedro Alves <palves@redhat.com>
5822
5823 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
5824 parameter.
5825
4180215b
PA
58262015-02-27 Pedro Alves <palves@redhat.com>
5827
5828 * linux-x86-low.c (u_debugreg_offset): New function.
5829 (x86_linux_dr_get, x86_linux_dr_set): Use it.
5830
749bab01
PA
58312015-02-27 Pedro Alves <palves@redhat.com>
5832
5833 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
5834 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
5835 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
5836 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
5837 (ps_lsetfpregs, ps_getpid)
5838 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
5839 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
5840 (ps_lsetxregs, ps_plog): Declare.
5841
3c14e5a3
PA
58422015-02-27 Pedro Alves <palves@redhat.com>
5843
5844 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
5845 IP_AGENT_EXPORT_FUNC.
5846 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
5847 IP_AGENT_EXPORT_FUNC.
5848 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
5849 (IP_AGENT_EXPORT): Delete.
5850 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
5851 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
5852 (gdb_trampoline_buffer_error, collecting, gdb_collect)
5853 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
5854 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
5855 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
5856 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
5857 (traceframe_read_count, traceframe_write_count)
5858 (traceframes_created, trace_state_variables, get_raw_reg)
5859 (get_trace_state_variable_value, set_trace_state_variable_value)
5860 (ust_loaded, helper_thread_id, cmd_buf): Use
5861 IPA_SYM_EXPORTED_NAME.
5862 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
5863 (tracepoints) Use IP_AGENT_EXPORT_VAR.
5864 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
5865 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
5866 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
5867 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
5868 EXTERN_C_PUSH/EXTERN_C_POP.
5869 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
5870 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
5871 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
5872 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
5873 (traceframe_write_count, traceframe_read_count)
5874 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
5875 (about_to_request_buffer_space, get_trace_state_variable_value)
5876 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
5877 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
5878 EXTERN_C_PUSH/EXTERN_C_POP.
5879 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
5880 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
5881 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
5882 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
5883 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
5884 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
5885 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
5886 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
5887 Define.
5888 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
5889 (IP_AGENT_EXPORT_VAR_DECL): Define.
5890 (tracing): Declare.
5891 (gdb_agent_get_raw_reg): Declare.
5892
fe978cb0
PA
58932015-02-27 Tom Tromey <tromey@redhat.com>
5894 Pedro Alves <palves@redhat.com>
5895
5896 Rename symbols whose names are reserved C++ keywords throughout.
5897
3bc3d82a
PA
58982015-02-27 Pedro Alves <palves@redhat.com>
5899
5900 * Makefile.in (COMPILER): New, get it from autoconf.
5901 (CXX): Get from autoconf instead.
5902 (COMPILE.pre): Use COMPILER.
5903 (CC-LD): Rename to ...
5904 (CC_LD): ... this. Use COMPILER.
5905 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
5906 (CXX_FOR_TARGET): Default to g++ instead of gcc.
5907 * acinclude.m4: Include build-with-cxx.m4.
5908 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
5909 Disable -Werror by default if building in C++ mode.
5910 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
5911 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
5912 the C++ compiler. Save/restore CXXFLAGS too.
5913 * configure: Regenerate.
5914
07697489
PA
59152015-02-27 Pedro Alves <palves@redhat.com>
5916
5917 * acinclude.m4: Include libiberty.m4.
5918 * configure.ac: Call libiberty_INIT.
5919 * config.in, configure: Regenerate.
5920
9beb7c4e
PA
59212015-02-26 Pedro Alves <palves@redhat.com>
5922
5923 * linux-low.c (linux_wait_1): When incrementing the PC past a
5924 program breakpoint always use the_low_target.breakpoint_len as
5925 increment, rather than the maximum between that and
5926 the_low_target.decr_pc_after_break.
5927
8090aef2
PA
59282015-02-23 Pedro Alves <palves@redhat.com>
5929
5930 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
5931 thread was doing a step-over; always adjust the PC if
5932 we stepped over a permanent breakpoint.
5933 (linux_wait_1): If we stepped over breakpoint that was on top of a
5934 permanent breakpoint, manually advance the PC past it.
5935
bc9540e8
PA
59362015-02-23 Pedro Alves <palves@redhat.com>
5937
5938 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
5939 modes.
5940 (x86_fill_gregset, x86_store_gregset): Use it when handling
5941 $orig_eax.
5942
2db9a427
PA
59432015-02-20 Pedro Alves <palves@redhat.com>
5944
5945 * thread-db.c: Include "nat/linux-procfs.h".
5946 (thread_db_init): Skip listing new threads if the kernel supports
5947 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
5948
afa8d396
PA
59492015-02-20 Pedro Alves <palves@redhat.com>
5950
5951 * linux-low.c (status_pending_p_callback): Use ptid_match.
5952
c9587f88
AT
59532015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
5954
5955 PR breakpoints/16812
5956 * linux-low.c (wstatus_maybe_breakpoint): Remove.
5957 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
5958 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
5959
b05ec7a5
AT
59602015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
5961
5962 PR breakpoints/15956
5963 * tracepoint.c (cmd_qtinit): Add check for current_thread.
5964
d33501a5
MM
59652015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5966
5967 * linux-low.c (linux_low_btrace_conf): Print size.
5968 * server.c (handle_btrace_conf_general_set): New.
5969 (hanle_general_set): Call handle_btrace_conf_general_set.
5970 (handle_query): Report Qbtrace-conf:bts:size as supported.
5971
f4abbc16
MM
59722015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5973
5974 * linux-low.c (linux_low_enable_btrace): Update parameters.
5975 (linux_low_btrace_conf): New.
5976 (linux_target_ops)<to_btrace_conf>: Initialize.
5977 * server.c (current_btrace_conf): New.
5978 (handle_btrace_enable): Rename to ...
5979 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
5980 to target_enable_btrace. Update comment. Update users.
5981 (handle_qxfer_btrace_conf): New.
5982 (qxfer_packets): Add btrace-conf entry.
5983 (handle_query): Report qXfer:btrace-conf:read as supported packet.
5984 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
5985 (target_ops)<read_btrace_conf>: New.
5986 (target_enable_btrace): Update parameters.
5987 (target_read_btrace_conf): New.
5988
043c3577
MM
59892015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5990
5991 * server.c (handle_btrace_general_set): Remove call to
5992 target_supports_btrace.
5993 (supported_btrace_packets): New.
5994 (handle_query): Call supported_btrace_packets.
5995 * target.h: include btrace-common.h.
5996 (btrace_target_info): Removed.
5997 (supports_btrace, target_supports_btrace): Update parameters.
5998
734b0e4b
MM
59992015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6000
6001 * Makefile.in (SFILES): Add common/btrace-common.c.
6002 (OBS): Add common/btrace-common.o.
6003 (btrace-common.o): Add build rules.
6004 * linux-low: Include btrace-common.h.
6005 (linux_low_read_btrace): Use struct btrace_data. Call
6006 btrace_data_init and btrace_data_fini.
6007
d6c146e9
PA
60082015-02-06 Pedro Alves <palves@redhat.com>
6009
6010 * thread-db.c (find_new_threads_callback): Add debug output.
6011
20ba1ce6
PA
60122015-02-04 Pedro Alves <palves@redhat.com>
6013
6014 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
6015 (resume_stopped_resumed_lwps): New function.
6016 (linux_wait_for_event_filtered): Use it.
6017
8cc73a39
SDJ
60182015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6019
6020 * Makefile.in (SFILES): Add linux-personality.c.
6021 (linux-personality.o): New rule.
6022 * configure.srv (srv_linux_obj): Add linux-personality.o to the
6023 list of objects to be built.
6024 * linux-low.c: Include nat/linux-personality.h.
6025 (linux_create_inferior): Remove code to disable address space
6026 randomization (moved to ../nat/linux-personality.c). Create
6027 cleanup to disable address space randomization.
6028
fb23d554
SDJ
60292015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6030
6031 * Makefile.in (posix-strerror.o): New rule.
6032 (mingw-strerror.o): Likewise.
6033 * configure: Regenerated.
6034 * configure.ac: Source file ../common/common.host. Initialize new
6035 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
6036
cdf43629
YQ
60372015-01-14 Yao Qi <yao@codesourcery.com>
6038
6039 * Makefile.in (SFILES): Add nat/ppc-linux.c.
6040 (ppc-linux.o): New rule.
6041 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
6042 * configure.ac: AC_CHECK_FUNCS(getauxval).
6043 * config.in: Re-generated.
6044 * configure: Re-generated.
6045 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
6046 ppc64_64bit_inferior_p
6047
514c5338
YQ
60482015-01-14 Yao Qi <yao@codesourcery.com>
6049
6050 * linux-ppc-low.c: Include "nat/ppc-linux.h".
6051 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
6052 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
6053 (PT_ORIG_R3, PT_TRAP): Likewise.
6054 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
6055 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
6056 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
6057
3368c1e5
JB
60582015-01-10 Joel Brobecker <brobecker@adacore.com>
6059
6060 * i387-fp.c (i387_cache_to_xsave): In look over
6061 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
6062 zmmh_low_space field by use of zmmh_high_space.
6063
582511be
PA
60642015-01-09 Pedro Alves <palves@redhat.com>
6065
6066 * linux-low.c (step_over_bkpt): Move higher up in the file.
6067 (handle_extended_wait): Don't store the stop_pc here.
6068 (get_stop_pc): Adjust comments and rename to ...
6069 (check_stopped_by_breakpoint): ... this. Record whether the LWP
6070 stopped for a software breakpoint or hardware breakpoint.
6071 (thread_still_has_status_pending_p): New function.
6072 (status_pending_p_callback): Use
6073 thread_still_has_status_pending_p. If the event is no longer
6074 interesting, resume the LWP.
6075 (handle_tracepoints): Add assert.
6076 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
6077 (wstatus_maybe_breakpoint): New function.
6078 (cancel_breakpoint): Delete function.
6079 (check_stopped_by_watchpoint): New function, factored out from
6080 linux_low_filter_event.
6081 (lp_status_maybe_breakpoint): Delete function.
6082 (linux_low_filter_event): Remove filter_ptid argument.
6083 Leave thread group exits pending here. Store the LWP's stop PC.
6084 Always leave events pending.
6085 (linux_wait_for_event_filtered): Pull all events out of the
6086 kernel, and leave them all pending.
6087 (count_events_callback, select_event_lwp_callback): Consider all
6088 events.
6089 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
6090 (select_event_lwp): Only give preference to the stepping LWP in
6091 all-stop mode. Adjust comments.
6092 (ignore_event): New function.
6093 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
6094 references to cancel_breakpoints. Adjust to renames. Also give
6095 equal priority to all LWPs that have had events in non-stop mode.
6096 If reporting a software breakpoint event, unadjust the LWP's PC.
6097 (linux_wait): If linux_wait_1 returned an ignored event, retry.
6098 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
6099 Adjust.
6100 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
6101 (resume_status_pending_p): Use thread_still_has_status_pending_p.
6102 (linux_stopped_by_watchpoint): Adjust.
6103 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
6104 * linux-low.h (enum lwp_stop_reason): New.
6105 (struct lwp_info) <stop_pc>: Adjust comment.
6106 <stopped_by_watchpoint>: Delete field.
6107 <stop_reason>: New field.
6108 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6109 * mem-break.c (software_breakpoint_inserted_here)
6110 (hardware_breakpoint_inserted_here): New function.
6111 * mem-break.h (software_breakpoint_inserted_here)
6112 (hardware_breakpoint_inserted_here): Declare.
6113 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
6114 (cancel_breakpoints): Delete.
6115 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
6116 (upload_fast_traceframes): Remove references to
6117 cancel_breakpoints.
6118
a33e3959
PA
61192015-01-09 Pedro Alves <palves@redhat.com>
6120
6121 * thread-db.c (find_new_threads_callback): Ignore thread if the
6122 kernel thread ID is -1.
6123
8784d563
PA
61242015-01-09 Pedro Alves <palves@redhat.com>
6125
6126 * linux-low.c (linux_attach_fail_reason_string): Move to
6127 nat/linux-ptrace.c, and rename.
6128 (linux_attach_lwp): Update comment.
6129 (attach_proc_task_lwp_callback): New function.
6130 (linux_attach): Adjust to rename and use
6131 linux_proc_attach_tgid_threads.
6132 (linux_attach_fail_reason_string): Delete declaration.
6133
76f2b779
JB
61342015-01-01 Joel Brobecker <brobecker@adacore.com>
6135
6136 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
6137 * server.c (gdbserver_version): Likewise.
6138
fafcc06a
SDJ
61392014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
6140
6141 * remote-utils.c: Include ctype.h.
6142 (input_interrupt): Explicitly handle the case when the char
6143 received is the NUL byte. Improve the printing of non-ASCII
6144 characters.
6145
beed38b8
JB
61462014-12-16 Joel Brobecker <brobecker@adacore.com>
6147
6148 * linux-low.c (linux_low_filter_event): Update call to
6149 linux_enable_event_reporting following the addition of
6150 a new parameter to that function.
6151
bf330350
CU
61522014-12-16 Catalin Udma <catalin.udma@freescale.com>
6153
6154 PR server/17457
6155 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
6156 (AARCH64_FPCR_REGNO): Likewise.
6157 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
6158 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
6159 (aarch64_store_fpregset): Likewise.
6160
5227d625
JB
61612014-12-15 Joel Brobecker <brobecker@adacore.com>
6162
6163 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
6164 Remove FIXME comment about assumption about N.
6165
f93b65a0
JB
61662014-12-13 Joel Brobecker <brobecker@adacore.com>
6167
6168 * configure.ac: If large-file support is disabled in GDBserver,
6169 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
6170 * configure: Regenerate.
6171
e5a9158d
AA
61722014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6173
6174 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
6175 warning upon ENODATA from ptrace.
6176 * linux-s390-low.c (s390_store_tdb): New.
6177 (s390_regsets): Add regset for NT_S390_TDB.
6178
feea5f36
AA
61792014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6180
6181 * linux-low.c (regsets_store_inferior_registers): Skip regsets
6182 without a fill_function.
6183 * linux-s390-low.c (s390_fill_last_break): Remove.
6184 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
6185 (s390_arch_setup): Use regset's size instead of fill_function for
6186 loop end condition.
6187
098dbe61
AA
61882014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6189
6190 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
6191 the regset's store function when ptrace returned an error.
6192 * regcache.c (get_thread_regcache): Invalidate register cache
6193 before fetching inferior's registers.
6194
28eef672
AA
61952014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6196
6197 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
6198 while-loop as for-loop.
6199 (regsets_store_inferior_registers): Likewise.
6200
bdca27a2
YQ
62012014-11-28 Yao Qi <yao@codesourcery.com>
6202
6203 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
6204 * config.in, configure: Re-generate.
6205 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
6206 is defined.
6207
9c232dda
YQ
62082014-11-21 Yao Qi <yao@codesourcery.com>
6209
6210 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
6211 (AC_CHECK_HEADERS): Remove malloc.h.
6212 * configure: Re-generated.
6213 * config.in: Re-generated.
6214 * server.h: Don't include alloca.h and malloc.h.
6215 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
6216 Don't include malloc.h.
6217
43968415
JB
62182014-11-17 Joel Brobecker <brobecker@adacore.com>
6219
6220 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
6221 corresponding ERRNO check in same block.
6222
40e91bc7
PA
62232014-11-12 Pedro Alves <palves@redhat.com>
6224
6225 * server.c (cont_thread): Update comment.
6226 (start_inferior, attach_inferior): No longer clear cont_thread.
6227 (handle_v_cont): No longer set cont_thread.
6228 (captured_main): Clear cont_thread each time a GDB connects.
6229
c2c118cf
PA
62302014-11-12 Pedro Alves <palves@redhat.com>
6231
6232 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
6233 thread, and don't resume all threads if the Hc thread has exited.
6234
78708b7c
PA
62352014-11-12 Pedro Alves <palves@redhat.com>
6236
6237 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
6238 the process group instead of to a specific LWP.
6239
a2abc7de
PA
62402014-10-15 Pedro Alves <palves@redhat.com>
6241
6242 PR server/17487
6243 * win32-arm-low.c (arm_set_thread_context): Remove current_event
6244 parameter.
6245 (arm_set_thread_context): Delete.
6246 (the_low_target): Adjust.
6247 * win32-i386-low.c (debug_registers_changed)
6248 (debug_registers_used): Delete.
6249 (update_debug_registers_callback): New function.
6250 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
6251 needing to update their debug registers.
6252 (win32_get_current_dr): New function.
6253 (x86_dr_low_get_addr, x86_dr_low_get_control)
6254 (x86_dr_low_get_status): Fetch the debug register from the thread
6255 record's context.
6256 (i386_initial_stuff): Adjust.
6257 (i386_get_thread_context): Remove current_event parameter. Don't
6258 clear debug_registers_changed nor copy DR values to
6259 debug_reg_state.
6260 (i386_set_thread_context): Delete.
6261 (i386_prepare_to_resume): New function.
6262 (i386_thread_added): Mark the thread as needing to update irs
6263 debug registers.
6264 (the_low_target): Remove i386_set_thread_context and install
6265 i386_prepare_to_resume.
6266 * win32-low.c (win32_get_thread_context): Adjust.
6267 (win32_set_thread_context): Use SetThreadContext
6268 directly.
6269 (win32_prepare_to_resume): New function.
6270 (win32_require_context): New function, factored out from ...
6271 (thread_rec): ... this.
6272 (continue_one_thread): Call win32_prepare_to_resume on each thread
6273 we're about to continue.
6274 (win32_resume): Call win32_prepare_to_resume on the event thread.
6275 * win32-low.h (struct win32_thread_info)
6276 <debug_registers_changed>: New field.
6277 (struct win32_target_ops): Change prototype of set_thread_context,
6278 delete set_thread_context and add prepare_to_resume.
6279 (win32_require_context): New declaration.
6280
a442d071
GB
62812014-10-08 Gary Benson <gbenson@redhat.com>
6282
6283 * server.h: Do not include common-exceptions.h.
6284
6f1947e8
GB
62852014-10-08 Gary Benson <gbenson@redhat.com>
6286
6287 * server.h: Do not include cleanups.h.
6288
63b434a4
JH
62892014-09-30 James Hogan <james.hogan@imgtec.com>
6290
6291 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
6292 mips64-dsp-linux.c.
6293
c4d9ceb6
YQ
62942014-09-23 Yao Qi <yao@codesourcery.com>
6295
6296 * linux-low.c (lp_status_maybe_breakpoint): New function.
6297 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
6298 (count_events_callback): Likewise.
6299 (select_event_lwp_callback): Likewise.
6300 (cancel_breakpoints_callback): Likewise.
6301
89a5711c
DB
63022014-09-19 Don Breazeal <donb@codesourcery.com>
6303
6304 * linux-low.c (handle_extended_wait): Call
6305 linux_ptrace_get_extended_event.
6306 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
6307 linux_is_extended_waitstatus.
6308
bffc0964
JB
63092014-09-16 Joel Brobecker <brobecker@adacore.com>
6310
6311 * Makefile.in (CPPFLAGS): Define.
6312 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
6313 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
6314
0bfdf32f
GB
63152014-09-16 Gary Benson <gbenson@redhat.com>
6316
6317 * inferiors.h (current_inferior): Renamed as...
6318 (current_thread): New variable. All uses updated.
6319 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
6320 (maybe_move_out_of_jump_pad): Likewise.
6321 (cancel_breakpoint): Likewise.
6322 (linux_low_filter_event): Likewise.
6323 (wait_for_sigstop): Likewise.
6324 (linux_resume_one_lwp): Likewise.
6325 (need_step_over_p): Likewise.
6326 (start_step_over): Likewise.
6327 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
6328 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
6329 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
6330 and save_inferior as saved_thread.
6331 * regcache.c (get_thread_regcache): Renamed saved_inferior as
6332 saved_thread.
6333 (regcache_invalidate_thread): Likewise.
6334 * remote-utils.c (prepare_resume_reply): Likewise.
6335 * thread-db.c (thread_db_get_tls_address): Likewise.
6336 (disable_thread_event_reporting): Likewise.
6337 (remove_thread_event_breakpoints): Likewise.
6338 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
6339 as saved_thread.
6340 * target.h (set_desired_inferior): Renamed as...
6341 (set_desired_thread): New declaration. All uses updated.
6342 * server.c (myresume): Updated comment to reference thread instead
6343 of inferior.
6344 (handle_serial_event): Likewise.
6345 (handle_target_event): Likewise.
6346
361c8ade
GB
63472014-09-12 Tom Tromey <tromey@redhat.com>
6348 Gary Benson <gbenson@redhat.com>
6349
6350 * regcache.h: Include common-regcache.h.
6351 (regcache_read_pc): Don't declare.
6352 * regcache.c (get_thread_regcache_for_ptid): New function.
6353
bd9269f7
GB
63542014-09-11 Tom Tromey <tromey@redhat.com>
6355 Gary Benson <gbenson@redhat.com>
6356
6357 * symbol.c: New file.
6358 * Makefile.in (SFILES): Add symbol.c.
6359 (OBS): Add symbol.o.
6360
f8c1d06b
GB
63612014-09-11 Gary Benson <gbenson@redhat.com>
6362
6363 * target.c (target_stop_ptid, target_continue_ptid): New
6364 functions.
6365
721ec300
GB
63662014-09-11 Tom Tromey <tromey@redhat.com>
6367 Gary Benson <gbenson@redhat.com>
6368
6369 * target.h: Include target/target.h.
6370 * target.c (target_read_memory, target_read_uint32)
6371 (target_write_memory): New functions.
6372
c5e92cca
GB
63732014-09-11 Gary Benson <gbenson@redhat.com>
6374
6375 * server.h (debug_hw_points): Don't declare.
6376 * server.c (debug_hw_points): Don't define. Replace all uses
6377 with show_debug_regs.
6378 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
6379 all uses with show_debug_regs.
6380
2e4bb98a
EBM
63812014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
6382
6383 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
6384 endianness into account.
6385 (ppc_supply_ptrace_register): Likewise.
6386
ac740bc7
JH
63872014-09-03 James Hogan <james.hogan@imgtec.com>
6388
6389 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
6390 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
6391
97ea6506
GB
63922014-09-03 Gary Benson <gbenson@redhat.com>
6393
6394 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
6395 ALL_DEBUG_ADDRESS_REGISTERS.
6396
df7e5265
GB
63972014-09-02 Gary Benson <gbenson@redhat.com>
6398
6399 * i386-low.h: Renamed as...
6400 * x86-low.h: New file. All type, function and variable name
6401 prefixes changed from "i386_" to "x86_". All references updated.
6402 * i386-low.c: Renamed as...
6403 * x86-low.c: New file. All type, function and variable name
6404 prefixes changed from "i386_" to "x86_". All references updated.
6405
ed859da7
GB
64062014-09-02 Gary Benson <gbenson@redhat.com>
6407
6408 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
6409 (x86_linux_new_thread): Likewise.
6410
860789c7
GB
64112014-08-29 Gary Benson <gbenson@redhat.com>
6412
6413 * server.h (setjmp.h): Do not include.
6414 (toplevel): Do not declare.
6415 (common-exceptions.h): Include.
6416 (cleanups.h): Likewise.
6417 * server.c (toplevel): Do not define.
6418 (exit_code): New static global.
6419 (detach_or_kill_for_exit_cleanup): New function.
6420 (main): New function. Original main renamed to...
6421 (captured_main): New function.
6422 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
6423
ff55e1b5
GB
64242014-08-29 Gary Benson <gbenson@redhat.com>
6425
6426 * Makefile.in (SFILES): Add common/common-exceptions.c.
6427 (OBS): Add common-exceptions.o.
6428 (common-exceptions.o): New rule.
6429 * utils.c (prepare_to_throw_exception): New function.
6430
e9bcb658
GB
64312014-08-29 Gary Benson <gbenson@redhat.com>
6432
6433 * config.in: Regenerate.
6434 * configure: Likewise.
6435
e3180625
GB
64362014-08-29 Gary Benson <gbenson@redhat.com>
6437
6438 * Makefile.in (SFILES): Add common/cleanups.c.
6439 (OBS): cleanups.o.
6440 (cleanups.o): New rule.
6441
e3d6ba5d
GB
64422014-08-29 Gary Benson <gbenson@redhat.com>
6443
6444 * utils.c (internal_vwarning): New function.
6445
7096e886
GB
64462014-08-28 Gary Benson <gbenson@redhat.com>
6447
6448 * utils.h (fatal): Remove declaration.
6449 * utils.c (fatal): Remove function.
6450
14ce3192
GB
64512014-08-28 Gary Benson <gbenson@redhat.com>
6452
6453 * tracepoint.c (gdb_agent_init): Replace fatal with
6454 perror_with_name.
6455 (initialize_tracepoint): Likewise.
6456
50278d59
GB
64572014-08-28 Gary Benson <gbenson@redhat.com>
6458
6459 * remote-utils.c (remote_prepare): Replace fatal with error.
6460
aa96c426
GB
64612014-08-28 Gary Benson <gbenson@redhat.com>
6462
6463 * linux-low.c (linux_async): Replace fatal with warning.
6464 Tidy up and return.
6465 (linux_start_non_stop): Return -1 if linux_async failed.
6466
f7160e97
GB
64672014-08-28 Gary Benson <gbenson@redhat.com>
6468
6469 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
6470 gdb_assert.
6471 (i386_dr_low_get_addr): Remove vague comment.
6472 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
6473 gdb_assert.
6474
38e08fca
GB
64752014-08-28 Gary Benson <gbenson@redhat.com>
6476
6477 * inferiors.c (get_thread_process): Replace check with gdb_assert.
6478 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
6479 internal_error.
6480 (linux_resume_one_lwp): Likewise.
6481 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
6482 gdb_assert.
6483 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
6484 with internal_error.
6485 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
6486 (init_register_cache): Replace fatal with gdb_assert_not_reached.
6487 (find_register_by_name): Replace fatal with internal_error.
6488 (find_regno): Likewise.
6489 * tdesc.c (init_target_desc): Replace check with gdb_assert.
6490 * thread-db.c (thread_db_create_event): Likewise.
6491 (thread_db_load_search): Likewise.
6492 (try_thread_db_load_1): Likewise.
6493 * tracepoint.c (get_jump_space_head): Replace fatal with
6494 internal_error.
6495 (claim_trampoline_space): Likewise.
6496 (have_fast_tracepoint_trampoline_buffer): Likewise.
6497 (cmd_qtstart): Likewise.
6498 (stop_tracing): Likewise.
6499 (fast_tracepoint_collecting): Likewise.
6500 (target_malloc): Likewise.
6501 (download_tracepoint): Likewise.
6502 (download_trace_state_variables): Replace check with gdb_assert.
6503 (upload_fast_traceframes): Replace fatal with internal_error.
6504
34abf635
GB
65052014-08-19 Tom Tromey <tromey@redhat.com>
6506 Gary Benson <gbenson@redhat.com>
6507
6508 * Makefile.in (SFILES): Add common/common-debug.c.
6509 (OBS): Add common-debug.o.
6510 (common-debug.o): New rule.
6511 * debug.h (debug_printf): Don't declare.
6512 * debug.c (debug_printf): Renamed and rewritten as...
6513 (debug_vprintf): New function.
6514
f6e94d78
GB
65152014-08-19 Gary Benson <gbenson@redhat.com>
6516
6517 * utils.h: Do not include print-utils.h.
6518
9239eeab
GB
65192014-08-19 Tom Tromey <tromey@redhat.com>
6520 Gary Benson <gbenson@redhat.com>
6521
6522 * server.h: Add static assertion.
6523 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
6524
ef87c8bb
GB
65252014-08-19 Tom Tromey <tromey@redhat.com>
6526 Gary Benson <gbenson@redhat.com>
6527
6528 * Makefile.in (SFILES): Add common/errors.c.
6529 (OBS): Add errors.o.
6530 (IPA_OBS): Add errors-ipa.o.
6531 (errors.o): New rule.
6532 (errors-ipa.o): Likewise.
6533 * utils.h (perror_with_name, error, warning): Don't declare.
6534 * utils.c (warning): Renamed and rewritten as...
6535 (vwarning): New function.
6536 (error): Renamed and rewritten as...
6537 (verror): New function.
6538 (internal_error): Renamed and rewritten as...
6539 (internal_verror): New function.
6540
bb974a24
GB
65412014-08-07 Gary Benson <gbenson@redhat.com>
6542
6543 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
6544 * configure: Regenerate.
6545 * config.in: Likewise.
6546 * server.h: Do not include errno.h.
6547 * event-loop.c: Likewise.
6548 * hostio-errno.c: Likewise.
6549 * linux-low.c: Likewise.
6550 * remote-utils.c: Likewise.
6551 * spu-low.c: Likewise.
6552 * utils.c: Likewise.
6553 * gdbreplay.c: Unconditionally include errno.h.
6554
6d3d12eb
GB
65552014-08-07 Gary Benson <gbenson@redhat.com>
6556
6557 * server.h: Do not include string.h.
6558 * event-loop.c: Likewise.
6559 * linux-low.c: Likewise.
6560 * regcache.c: Likewise.
6561 * remote-utils.c: Likewise.
6562 * spu-low.c: Likewise.
6563 * utils.c: Likewise.
6564
dccbb609
GB
65652014-08-07 Gary Benson <gbenson@redhat.com>
6566
6567 * server.h: Do not include gdb_assert.h.
6568
e76df0d0
GB
65692014-08-07 Gary Benson <gbenson@redhat.com>
6570
6571 * server.h: Do not include common-utils.h.
6572
4cb9c816
GB
65732014-08-07 Gary Benson <gbenson@redhat.com>
6574
6575 * server.h: Do not include ptid.h.
6576 * notif.h: Likewise.
6577
3995eeee
GB
65782014-08-07 Gary Benson <gbenson@redhat.com>
6579
6580 * server.h: Do not include gdb_locale.h.
6581
cb9f1a9b
GB
65822014-08-07 Gary Benson <gbenson@redhat.com>
6583
6584 * server.h: Do not include gdb/signals.h.
6585 * win32-low.c: Likewise.
6586
a5fceff8
GB
65872014-08-07 Gary Benson <gbenson@redhat.com>
6588
6589 * server.h: Do not include pathmax.h.
6590
b9391142
GB
65912014-08-07 Gary Benson <gbenson@redhat.com>
6592
6593 * server.h: Do not include libiberty.h.
6594 * linux-bfin-low.c: Likewise.
6595
0e443c87
GB
65962014-08-07 Gary Benson <gbenson@redhat.com>
6597
6598 * server.h: Do not include ansidecl.h.
6599
8ebb3f56
GB
66002014-08-07 Gary Benson <gbenson@redhat.com>
6601
6602 * linux-x86-low.c: Do not include stddef.h.
6603 * lynx-ppc-low.c: Likewise.
6604 * tracepoint.c: Likewise.
6605
8980bdf6
GB
66062014-08-07 Gary Benson <gbenson@redhat.com>
6607
6608 * server.h: Do not include stdarg.h.
6609 * nto-low.c: Likewise.
6610
d7096f71
GB
66112014-08-07 Gary Benson <gbenson@redhat.com>
6612
6613 * server.h: Do not include stdlib.h.
6614 * inferiors.c: Likewise.
6615 * linux-low.c: Likewise.
6616 * regcache.c: Likewise.
6617 * spu-low.c: Likewise.
6618 * tracepoint.c: Likewise.
6619 * utils.c: Likewise.
6620
d02f550d
GB
66212014-08-07 Gary Benson <gbenson@redhat.com>
6622
6623 * server.h: Do not include stdio.h.
6624 * linux-low.c: Likewise.
6625 * remote-utils.c: Likewise.
6626 * spu-low.c: Likewise.
6627 * utils.c: Likewise.
6628 * wincecompat.c: Likewise.
6629
87f6c4e3
GB
66302014-08-06 Gary Benson <gbenson@redhat.com>
6631
6632 * regcache.c (init_register_cache): Move conditionals inside if.
6633
7089dca4
GB
66342014-08-06 Gary Benson <gbenson@redhat.com>
6635
6636 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
6637
462f517e
GB
66382014-07-31 Gary Benson <gbenson@redhat.com>
6639
6640 * ax.h: Do not include server.h.
6641 * gdbthread.h: Likewise.
6642 * lynx-low.h: Likewise.
6643 * notif.h: Likewise.
6644
976411d6
GB
66452014-07-30 Gary Benson <gbenson@redhat.com>
6646
6647 * server.h: Include common-defs.h.
6648 Do not include config.h or build-gnulib-gdbserver/config.h.
6649
d41f6d8e
GB
66502014-07-30 Gary Benson <gbenson@redhat.com>
6651
6652 * hostio-errno.c: Move server.h to top of includes list.
6653 * inferiors.c: Likewise.
6654 * linux-x86-low.c: Likewise.
6655 * notif.c: Include server.h.
6656
314c6a35
TT
66572014-07-24 Tom Tromey <tromey@redhat.com>
6658 Gary Benson <gbenson@redhat.com>
6659
6660 * server.h (CORE_ADDR): Now unsigned.
6661
69ff6be5
PA
66622014-07-16 Pedro Alves <palves@redhat.com>
6663
6664 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
6665
ce9e3fe7
PA
66662014-07-15 Pedro Alves <palves@redhat.com>
6667
6668 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
6669 copy.
6670
e76126e8
PA
66712014-07-11 Pedro Alves <palves@redhat.com>
6672
6673 * linux-low.c (kill_wait_lwp): New function, based on
6674 kill_one_lwp_callback, but use my_waitpid directly.
6675 (kill_one_lwp_callback, linux_kill): Use it.
6676
8e9db26e
PA
66772014-06-23 Pedro Alves <palves@redhat.com>
6678
6679 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
6680 before setting DR0..DR3.
6681
698b3e08
GB
66822014-06-20 Gary Benson <gbenson@redhat.com>
6683
6684 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
6685 * configure: Regenerated.
6686 * config.in: Likewise.
6687
125f8a3d
GB
66882014-06-20 Gary Benson <gbenson@redhat.com>
6689
6690 * Makefile.in (SFILES): Update locations for files moved
6691 from common to nat.
6692 (object file files): Reordered.
6693
42995dbd
GB
66942014-06-20 Gary Benson <gbenson@redhat.com>
6695
6696 * i386-low.h (i386_dr_low_can_set_addr): Removed.
6697 (i386_dr_low_set_addr): Likewise.
6698 (i386_dr_low_get_addr): Likewise.
6699 (i386_dr_low_can_set_control): Likewise.
6700 (i386_dr_low_set_control): Likewise.
6701 (i386_dr_low_get_control): Likewise.
6702 (i386_dr_low_get_status): Likewise.
6703 (i386_get_debug_register_length): Likewise.
6704 * linux-x86-low.c (i386_dr_low_set_addr):
6705 Changed signature. Made static.
6706 (i386_dr_low_get_addr): Likewise.
6707 (i386_dr_low_set_control): Likewise.
6708 (i386_dr_low_get_control): Likewise.
6709 (i386_dr_low_get_status): Likewise.
6710 (i386_dr_low): New global variable.
6711 * win32-i386-low.c (i386_dr_low_set_addr):
6712 Changed signature. Made static.
6713 (i386_dr_low_get_addr): Likewise.
6714 (i386_dr_low_set_control): Likewise.
6715 (i386_dr_low_get_control): Likewise.
6716 (i386_dr_low_get_status): Likewise.
6717 (i386_dr_low): New global variable.
6718
e1d2394b
MS
67192014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
6720
6721 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
6722 * Makefile.in (AR, AR_FLAGS): Define.
6723 * configure: Regenerate.
6724
3a8ee006
GB
67252014-06-19 Gary Benson <gbenson@redhat.com>
6726
6727 * Makefile.in (i386-dregs.o): New rule.
6728 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
6729 * i386-low.c (target.h): Remove include.
6730 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
6731 (DR_CONTROL_SHIFT): Likewise.
6732 (DR_CONTROL_SIZE): Likewise.
6733 (DR_RW_EXECUTE): Likewise.
6734 (DR_RW_WRITE): Likewise.
6735 (DR_RW_READ): Likewise.
6736 (DR_RW_IORW): Likewise.
6737 (DR_LEN_1): Likewise.
6738 (DR_LEN_2): Likewise.
6739 (DR_LEN_4): Likewise.
6740 (DR_LEN_8): Likewise.
6741 (DR_LOCAL_ENABLE_SHIFT): Likewise.
6742 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
6743 (DR_ENABLE_SIZE): Likewise.
6744 (DR_LOCAL_SLOWDOWN): Likewise.
6745 (DR_GLOBAL_SLOWDOWN): Likewise.
6746 (DR_CONTROL_RESERVED): Likewise.
6747 (I386_DR_CONTROL_MASK): Likewise.
6748 (I386_DR_VACANT): Likewise.
6749 (I386_DR_LOCAL_ENABLE): Likewise.
6750 (I386_DR_GLOBAL_ENABLE): Likewise.
6751 (I386_DR_DISABLE): Likewise.
6752 (I386_DR_SET_RW_LEN): Likewise.
6753 (I386_DR_GET_RW_LEN): Likewise.
6754 (I386_DR_WATCH_HIT): Likewise.
6755 (i386_wp_op_t): Likewise.
6756 (i386_show_dr): Likewise.
6757 (i386_length_and_rw_bits): Likewise.
6758 (i386_insert_aligned_watchpoint): Likewise.
6759 (i386_remove_aligned_watchpoint): Likewise.
6760 (i386_handle_nonaligned_watchpoint): Likewise.
6761 i386_update_inferior_debug_regs(): Likewise.
6762 (i386_dr_insert_watchpoint): Likewise.
6763 (i386_dr_remove_watchpoint): Likewise.
6764 (i386_dr_region_ok_for_watchpoint): Likewise.
6765 (i386_dr_stopped_data_address): Likewise.
6766 (i386_dr_stopped_by_watchpoint): Likewise.
6767
8f26655c
GB
67682014-06-19 Gary Benson <gbenson@redhat.com>
6769
6770 * i386-low.c (i386_dr_show): Renamed to
6771 i386_show_dr and made static. All uses updated.
6772 (i386_dr_length_and_rw_bits): Renamed to
6773 i386_length_and_rw_bits and made static.
6774 All uses updated.
6775 (i386_dr_insert_aligned_watchpoint): Renamed to
6776 i386_insert_aligned_watchpoint and made static.
6777 All uses updated.
6778 (i386_dr_remove_aligned_watchpoint): Renamed to
6779 i386_remove_aligned_watchpoint and made static.
6780 All uses updated.
6781 (i386_dr_update_inferior_debug_regs): Renamed to
6782 i386_update_inferior_debug_regs and made static.
6783 All uses updated.
6784
b9228891
GB
67852014-06-18 Gary Benson <gbenson@redhat.com>
6786
5171def3
GB
6787 * i386-low.h (i386_dr_low_can_set_addr): New macro.
6788 (i386_dr_low_can_set_control): Likewise.
6789 (i386_get_debug_register_length): Likewise.
6790 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
6791 (i386_dr_low_can_set_control): Likewise.
6792 (i386_get_debug_register_length): Likewise.
6793
67942014-06-17 Gary Benson <gbenson@redhat.com>
6795
b9228891
GB
6796 * i386-low.h (i386-dregs.h): New include.
6797 (DR_FIRSTADDR): Now in i386-dregs.h.
6798 (DR_LASTADDR): Likewise.
6799 (DR_NADDR): Likewise.
6800 (DR_STATUS): Likewise.
6801 (DR_CONTROL): Likewise.
6802 (i386_debug_reg_state): Likewise.
6803 (i386_dr_insert_watchpoint): Likewise.
6804 (i386_dr_remove_watchpoint): Likewise.
6805 (i386_dr_region_ok_for_watchpoint): Likewise.
6806 (i386_dr_stopped_data_address): Likewise.
6807 (i386_dr_stopped_by_watchpoint): Likewise.
6808 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
6809
4be83cc2
GB
68102014-06-18 Gary Benson <gbenson@redhat.com>
6811
6812 * i386-low.h (i386_low_insert_watchpoint): Renamed to
6813 i386_dr_insert_watchpoint.
6814 (i386_low_remove_watchpoint): Renamed to
6815 i386_dr_remove_watchpoint.
6816 (i386_low_region_ok_for_watchpoint): Renamed to
6817 i386_dr_region_ok_for_watchpoint.
6818 (i386_low_stopped_data_address): Renamed to
6819 i386_dr_stopped_data_address.
6820 (i386_low_stopped_by_watchpoint): Renamed to
6821 i386_dr_stopped_by_watchpoint.
6822 * i386-low.c (i386_show_dr): Renamed to
6823 i386_dr_show and made nonstatic. All uses updated.
6824 (i386_length_and_rw_bits): Renamed to
6825 i386_dr_length_and_rw_bits and made nonstatic.
6826 All uses updated.
6827 (i386_insert_aligned_watchpoint): Renamed to
6828 i386_dr_insert_aligned_watchpoint and made nonstatic.
6829 All uses updated.
6830 (i386_remove_aligned_watchpoint): Renamed to
6831 i386_dr_remove_aligned_watchpoint and made nonstatic.
6832 All uses updated.
6833 (i386_update_inferior_debug_regs): Renamed to
6834 i386_dr_update_inferior_debug_regs and made nonstatic.
6835 All uses updated.
6836 (i386_low_insert_watchpoint): Renamed to
6837 i386_dr_insert_watchpoint. All uses updated.
6838 (i386_low_remove_watchpoint): Renamed to
6839 i386_dr_remove_watchpoint. All uses updated.
6840 (i386_low_region_ok_for_watchpoint): Renamed to
6841 i386_dr_region_ok_for_watchpoint. All uses updated.
6842 (i386_low_stopped_data_address): Renamed to
6843 i386_dr_stopped_data_address. All uses updated.
6844 (i386_low_stopped_by_watchpoint): Renamed to
6845 i386_dr_stopped_by_watchpoint. All uses updated.
6846
131aa0d4
GB
68472014-06-18 Gary Benson <gbenson@redhat.com>
6848
6849 * i386-low.c (i386_dr_low_can_set_addr): New macro.
6850 (i386_dr_low_can_set_control): Likewise.
6851 (i386_insert_aligned_watchpoint): New check.
6852
d9305f7f
GB
68532014-06-18 Gary Benson <gbenson@redhat.com>
6854
6855 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
6856 Renamed to state.
6857
e927c9fc
GB
68582014-06-18 Gary Benson <gbenson@redhat.com>
6859
6860 * i386-low.c (i386_length_and_rw_bits): Use internal_error
6861 instead of fatal and error.
6862 (i386_handle_nonaligned_watchpoint): Likewise.
6863
1b6d4134
GB
68642014-06-18 Gary Benson <gbenson@redhat.com>
6865
6866 * i386-low.c (i386_get_debug_register_length): New macro.
6867 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
6868 (i386_show_dr): Use debug_printf instead of fprintf. Use
6869 phex to format values.
6870
6e62758f
GB
68712014-06-18 Gary Benson <gbenson@redhat.com>
6872
6873 * i386-low.h: Comment changes.
6874 * i386-low.c: Likewise.
6875
fc6e2f03
GB
68762014-06-18 Gary Benson <gbenson@redhat.com>
6877
6878 * i386-low.c: Whitespace changes.
6879
f9d1eeed
TT
68802014-06-12 Tom Tromey <tromey@redhat.com>
6881
6882 * utils.c (freeargv): Remove.
6883
0b04e523
TT
68842014-06-12 Tom Tromey <tromey@redhat.com>
6885
6886 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
6887 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
6888 (parse_debug_format_options): Likewise.
6889 (gdbserver_usage): Likewise.
6890 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
6891 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
6892 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
6893 against libiberty.
6894 ($(LIBGNU)): Depend on libiberty.
6895 (all-lib): Recurse into all subdirs.
6896 (install-only): Invoke "install" target in subdirs.
6897 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
6898 targets.
6899 * configure: Rebuild.
6900 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
6901 for vasprintf, vsnprintf, or gettimeofday.
6902 * configure.srv: Don't add safe-ctype.o or lbasename.o to
6903 srv_tgtobj.
6904
270c9937
JB
69052014-06-05 Joel Brobecker <brobecker@adacore.com>
6906
6907 * development.sh: Delete.
6908 * Makefile.in (config.status): Adjust dependency on development.sh.
6909 * configure.ac: Adjust development.sh source call.
6910 * configure: Regenerate.
6911
0a261ed8
PA
69122014-06-02 Pedro Alves <palves@redhat.com>
6913
6914 * ax.c (gdb_free_agent_expr): New function.
6915 * ax.h (gdb_free_agent_expr): New declaration.
6916 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
6917 list.
6918 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
6919 static.
6920 (clear_breakpoint_conditions_and_commands): New function.
6921 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
6922 (clear_breakpoint_conditions_and_commands): New declaration.
6923
e9dae05e
RR
69242014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
6925
6926 * linux-aarch64-low.c (asm/ptrace.h): Include.
6927
5876f503
JK
69282014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
6929
6930 Fix TLS access for -static -pthread.
6931 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
6932 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
6933 (thread_db_load_search, try_thread_db_load_1): Initialize it.
6934
802e8e6d
PA
69352014-05-20 Pedro Alves <palves@redhat.com>
6936
6937 * linux-aarch64-low.c (aarch64_insert_point)
6938 (aarch64_remove_point): No longer check whether the type is
6939 supported here. Adjust to new interface.
6940 (the_low_target): Install aarch64_supports_z_point_type as
6941 supports_z_point_type method.
6942 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
6943 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
6944 instead of a Z packet char. Adjust.
6945 (arm_supports_z_point_type): New function.
6946 (arm_insert_point, arm_remove_point): Adjust to new interface.
6947 (the_low_target): Install arm_supports_z_point_type.
6948 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
6949 (cris_insert_point, cris_remove_point): Adjust to new interface.
6950 Don't check whether the type is supported here.
6951 (the_low_target): Install cris_supports_z_point_type.
6952 * linux-low.c (linux_supports_z_point_type): New function.
6953 (linux_insert_point, linux_remove_point): Adjust to new interface.
6954 * linux-low.h (struct linux_target_ops) <insert_point,
6955 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
6956 raw_breakpoint pointer parameter.
6957 <supports_z_point_type>: New method.
6958 * linux-mips-low.c (mips_supports_z_point_type): New function.
6959 (mips_insert_point, mips_remove_point): Adjust to new interface.
6960 Use mips_supports_z_point_type.
6961 (the_low_target): Install mips_supports_z_point_type.
6962 * linux-ppc-low.c (the_low_target): Install NULL as
6963 supports_z_point_type method.
6964 * linux-s390-low.c (the_low_target): Install NULL as
6965 supports_z_point_type method.
6966 * linux-sparc-low.c (the_low_target): Install NULL as
6967 supports_z_point_type method.
6968 * linux-x86-low.c (x86_supports_z_point_type): New function.
6969 (x86_insert_point): Adjust to new insert_point interface. Use
6970 insert_memory_breakpoint. Adjust to new
6971 i386_low_insert_watchpoint interface.
6972 (x86_remove_point): Adjust to remove_point interface. Use
6973 remove_memory_breakpoint. Adjust to new
6974 i386_low_remove_watchpoint interface.
6975 (the_low_target): Install x86_supports_z_point_type.
6976 * lynx-low.c (lynx_target_ops): Install NULL as
6977 supports_z_point_type callback.
6978 * nto-low.c (nto_supports_z_point_type): New.
6979 (nto_insert_point, nto_remove_point): Adjust to new interface.
6980 (nto_target_ops): Install nto_supports_z_point_type.
6981 * mem-break.c: Adjust intro comment.
6982 (struct raw_breakpoint) <raw_type, size>: New fields.
6983 <inserted>: Update comment.
6984 <shlib_disabled>: Delete field.
6985 (enum bkpt_type) <gdb_breakpoint>: Delete value.
6986 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
6987 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
6988 (raw_bkpt_type_to_target_hw_bp_type): New function.
6989 (find_enabled_raw_code_breakpoint_at): New function.
6990 (find_raw_breakpoint_at): New type and size parameters. Use them.
6991 (insert_memory_breakpoint): New function, based off
6992 set_raw_breakpoint_at.
6993 (remove_memory_breakpoint): New function.
6994 (set_raw_breakpoint_at): Reimplement.
6995 (set_breakpoint): New, based on set_breakpoint_at.
6996 (set_breakpoint_at): Reimplement.
6997 (delete_raw_breakpoint): Go through the_target->remove_point
6998 instead of assuming memory breakpoints.
6999 (find_gdb_breakpoint_at): Delete.
7000 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
7001 (find_gdb_breakpoint): New function.
7002 (set_gdb_breakpoint_at): Delete.
7003 (z_type_supported): New function.
7004 (set_gdb_breakpoint_1): New function, loosely based off
7005 set_gdb_breakpoint_at.
7006 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
7007 (delete_gdb_breakpoint_at): Delete.
7008 (delete_gdb_breakpoint_1): New function, loosely based off
7009 delete_gdb_breakpoint_at.
7010 (delete_gdb_breakpoint): New function.
7011 (clear_gdb_breakpoint_conditions): Rename to ...
7012 (clear_breakpoint_conditions): ... this. Don't handle a NULL
7013 breakpoint.
7014 (add_condition_to_breakpoint): Make static.
7015 (add_breakpoint_condition): Take a struct breakpoint pointer
7016 instead of an address. Adjust.
7017 (gdb_condition_true_at_breakpoint): Rename to ...
7018 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
7019 z_type parameter.
7020 (gdb_condition_true_at_breakpoint): Reimplement.
7021 (add_breakpoint_commands): Take a struct breakpoint pointer
7022 instead of an address. Adjust.
7023 (gdb_no_commands_at_breakpoint): Rename to ...
7024 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
7025 parameter. Return true if no breakpoint was found. Change debug
7026 output.
7027 (gdb_no_commands_at_breakpoint): Reimplement.
7028 (run_breakpoint_commands): Rename to ...
7029 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
7030 and change return type to boolean.
7031 (run_breakpoint_commands): New function.
7032 (gdb_breakpoint_here): Also check for Z1 breakpoints.
7033 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
7034 breakpoint. Go through the_target->remove_point instead of
7035 assuming memory breakpoint.
7036 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
7037 software and hardware breakpoints.
7038 (reinsert_raw_breakpoint): Go through the_target->insert_point
7039 instead of assuming memory breakpoint.
7040 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
7041 software and hardware breakpoints.
7042 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
7043 Check both software and hardware breakpoints.
7044 (validate_inserted_breakpoint): Assert the breakpoint is a
7045 software breakpoint. Set the inserted flag to -1 instead of
7046 setting shlib_disabled.
7047 (delete_disabled_breakpoints): Adjust.
7048 (validate_breakpoints): Only validate software breakpoints.
7049 Adjust to inserted flag change.
7050 (check_mem_read, check_mem_write): Skip breakpoint types other
7051 than software breakpoints. Adjust to inserted flag change.
7052 * mem-break.h (enum raw_bkpt_type): New enum.
7053 (raw_breakpoint, struct process_info): Forward declare.
7054 (Z_packet_to_target_hw_bp_type): Delete declaration.
7055 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
7056 (set_gdb_breakpoint, delete_gdb_breakpoint)
7057 (clear_breakpoint_conditions): New declarations.
7058 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
7059 (breakpoint_inserted_here): Update comment.
7060 (add_breakpoint_condition, add_breakpoint_commands): Replace
7061 address parameter with a breakpoint pointer parameter.
7062 (gdb_breakpoint_here): Update comment.
7063 (delete_gdb_breakpoint_at): Delete.
7064 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
7065 * server.c (process_point_options): Take a struct breakpoint
7066 pointer instead of an address. Adjust.
7067 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
7068 delete_gdb_breakpoint.
7069 * spu-low.c (spu_target_ops): Install NULL as
7070 supports_z_point_type method.
7071 * target.h: Include mem-break.h.
7072 (struct target_ops) <prepare_to_access_memory>: Update comment.
7073 <supports_z_point_type>: New field.
7074 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7075 instead of a char. Also take a raw breakpoint pointer.
7076 * win32-arm-low.c (the_low_target): Install NULL as
7077 supports_z_point_type.
7078 * win32-i386-low.c (i386_supports_z_point_type): New function.
7079 (i386_insert_point, i386_remove_point): Adjust to new interface.
7080 (the_low_target): Install i386_supports_z_point_type.
7081 * win32-low.c (win32_supports_z_point_type): New function.
7082 (win32_insert_point, win32_remove_point): Adjust to new interface.
7083 (win32_target_ops): Install win32_supports_z_point_type.
7084 * win32-low.h (struct win32_target_ops):
7085 <supports_z_point_type>: New method.
7086 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7087 instead of a char. Also take a raw breakpoint pointer.
7088
932539e3
PA
70892014-05-20 Pedro Alves <palves@redhat.com>
7090
7091 * mem-break.h: Include break-common.h.
7092 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7093 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
7094 (Z_packet_to_target_hw_bp_type): New declaration.
7095 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
7096 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
7097 (Z_PACKET_ACCESS_WP): Delete macros.
7098 (Z_packet_to_hw_type): Delete function.
7099 * i386-low.h: Don't include break-common.h here.
7100 (Z_packet_to_hw_type): Delete declaration.
7101 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
7102 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7103 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
7104 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7105 * linux-aarch64-low.c: Don't include break-common.h here.
7106 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7107 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
7108 (Z_packet_to_target_hw_bp_type): Delete function.
7109 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
7110 function.
7111 (mips_insert_point, mips_remove_point): Use
7112 Z_packet_to_target_hw_bp_type.
7113
4ff0d3d8
PA
71142014-05-20 Pedro Alves <palves@redhat.com>
7115
7116 * linux-aarch64-low.c: Include break-common.h.
7117 (enum target_point_type): Delete.
7118 (Z_packet_to_point_type): Rename to ...
7119 (Z_packet_to_target_hw_bp_type): ... this, and return a
7120 target_hw_bp_type instead.
7121 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
7122 instead of an enum target_point_type.
7123 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
7124 breakpoint type.
7125 (aarch64_dr_state_insert_one_point)
7126 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
7127 (aarch64_handle_aligned_watchpoint)
7128 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
7129 Take an enum target_hw_bp_type instead of an enum
7130 target_point_type.
7131 (aarch64_supports_z_point_type): New function.
7132 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
7133 use Z_packet_to_target_hw_bp_type.
7134
786dc519
JB
71352014-05-20 Joel Brobecker <brobecker@adacore.com>
7136
7137 * configure.ac: Only use -Werror by default when DEVELOPMENT
7138 is true.
7139 * configure: Regenerate.
7140
9e0aa64f
JK
71412014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
7142
7143 Fix gdbserver qGetTLSAddr for x86_64 -m32.
7144 * linux-x86-low.c (X86_64_USER_REGS): New.
7145 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
7146
2b577b92
YQ
71472014-04-28 Yao Qi <yao@codesourcery.com>
7148
7149 * Makefile.in (i386-avx512.c): Fix the typo of generated file
7150 name.
7151
94611da2
PA
71522014-04-25 Pedro Alves <palves@redhat.com>
7153
7154 PR server/16255
7155 * linux-low.c (linux_attach_fail_reason_string): New function.
7156 (linux_attach_lwp): Delete.
7157 (linux_attach_lwp_1): Rename to ...
7158 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
7159 argument. Remove "initial" parameter. Return int instead of
7160 void. Don't error or warn here.
7161 (linux_attach): Adjust to call linux_attach_lwp. Call error on
7162 failure to attach to the tgid. Call warning when failing to
7163 attach to an lwp.
7164 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
7165 argument. Remove "initial" parameter. Return int instead of
7166 void. Don't error or warn here.
7167 (linux_attach_fail_reason_string): New declaration.
7168 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
7169 interface change. Use linux_attach_fail_reason_string.
7170
01f9f808
MS
71712014-04-24 Michael Sturm <michael.sturm@mintel.com>
7172 Walfred Tedeschi <walfred.tedeschi@intel.com>
7173
7174 * Makefile.in: Added rules to handle new files
7175 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
7176 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
7177 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
7178 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
7179 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
7180 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
7181 x32-avx512-linux.o.
7182 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
7183 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
7184 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
7185 i386/x32-avx512.xml.
7186 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
7187 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
7188 i386/x32-avx512-linux.xml.
7189 * i387-fp.c (num_avx512_k_registers): New constant for number
7190 of K registers.
7191 (num_avx512_zmmh_low_registers): New constant for number of
7192 lower ZMM registers (0-15).
7193 (num_avx512_zmmh_high_registers): New constant for number of
7194 higher ZMM registers (16-31).
7195 (num_avx512_ymmh_registers): New contant for number of higher
7196 YMM registers (ymm16-31 added by avx521 on x86_64).
7197 (num_avx512_xmm_registers): New constant for number of higher
7198 XMM registers (xmm16-31 added by AVX512 on x86_64).
7199 (struct i387_xsave): Add space for AVX512 registers.
7200 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
7201 Add code to handle AVX512 registers.
7202 (i387_xsave_to_cache): Add code to handle AVX512 registers.
7203 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
7204 prototypei from generated file.
7205 (tdesc_amd64_avx512_linux): Likewise.
7206 (init_registers_x32_avx512_linux): Likewise.
7207 (tdesc_x32_avx512_linux): Likewise.
7208 (init_registers_i386_avx512_linux): Likewise.
7209 (tdesc_i386_avx512_linux): Likewise.
7210 (x86_64_regmap): Add AVX512 registers.
7211 (x86_linux_read_description): Add code to handle AVX512 XSTATE
7212 mask.
7213 (initialize_low_arch): Add code to initialize AVX512 registers.
7214
51aa91f9
PA
72152014-04-23 Pedro Alves <palves@redhat.com>
7216
7217 * mem-break.c (find_gdb_breakpoint_at): Make static.
7218 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
7219
a4165e94
PA
72202014-04-23 Pedro Alves <palves@redhat.com>
7221
7222 * i386-low.c: Don't include break-common.h here.
7223 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7224 prototype to take target_hw_bp_type as argument instead of a Z
7225 packet char.
7226 * i386-low.h: Include break-common.h here.
7227 (Z_packet_to_hw_type): Declare.
7228 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7229 prototypes.
7230 * linux-x86-low.c (x86_insert_point): Convert the packet number to
7231 a target_hw_bp_type before calling i386_low_insert_watchpoint.
7232 (x86_remove_point): Convert the packet number to a
7233 target_hw_bp_type before calling i386_low_remove_watchpoint.
7234 * win32-i386-low.c (i386_insert_point): Convert the packet number
7235 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
7236 (i386_remove_point): Convert the packet number to a
7237 target_hw_bp_type before calling i386_low_remove_watchpoint.
7238
b8acf843
PA
72392014-04-23 Pedro Alves <palves@redhat.com>
7240
7241 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
7242
d708bcd1
PA
72432014-04-10 Pedro Alves <palves@redhat.com>
7244
7245 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7246 Check if the condition or command is NULL before checking if the
7247 breakpoint is known. On success, return true.
7248 * mem-break.h (add_breakpoint_condition): Document return.
7249 (add_breakpoint_commands): Add describing comment.
7250 * server.c (skip_to_semicolon): New function.
7251 (process_point_options): Use it.
7252
2eec7d5b
PA
72532014-04-09 Pedro Alves <palves@redhat.com>
7254
7255 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
7256 to lwpid_of.
7257
fa96cb38
PA
72582014-02-27 Pedro Alves <palves@redhat.com>
7259
7260 PR 12702
7261 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
7262 macros.
7263 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
7264 output.
7265 (last_thread_of_process_p): Take a PID argument instead of a
7266 thread pointer.
7267 (linux_wait_for_lwp): Delete.
7268 (num_lwps, check_zombie_leaders, not_stopped_callback): New
7269 functions.
7270 (linux_low_filter_event): New function, party factored out from
7271 linux_wait_for_event.
7272 (linux_wait_for_event): Rename to ...
7273 (linux_wait_for_event_filtered): ... this. Add new filter ptid
7274 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
7275 sigsuspend. Check for zombie leaders.
7276 (linux_wait_for_event): Reimplement as wrapper around
7277 linux_wait_for_event_filtered.
7278 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
7279 a normal or signal exit is seen, it's the whole process exiting.
7280 (wait_for_sigstop): No longer a for_each_inferior callback.
7281 Rewrite on top of linux_wait_for_event_filtered.
7282 (stop_all_lwps): Call wait_for_sigstop directly.
7283 * server.c (resume, handle_target_event): Handle
7284 TARGET_WAITKIND_NO_RESUMED.
7285
d763de10
JB
72862014-02-26 Joel Brobecker <brobecker@adacore.com>
7287
7288 * win32-low.c (psapi_get_dll_name,
7289 * win32_CreateToolhelp32Snapshot): Delete.
7290 (win32_CreateToolhelp32Snapshot, win32_Module32First)
7291 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
7292 Delete.
7293 (handle_load_dll): Add function description.
7294 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
7295
850a0f76
JB
72962014-02-26 Joel Brobecker <brobecker@adacore.com>
7297
7298 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
7299 Add comment.
7300 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
7301 base address when calling win32_add_one_solib.
7302 (handle_load_dll): Delete local variable load_addr.
7303 Remove 0x1000 offset applied to DLL base address when calling
7304 win32_add_one_solib.
7305 (handle_unload_dll): Add comment.
7306
f25b3fc3
JB
73072014-02-26 Joel Brobecker <brobecker@adacore.com>
7308
7309 * win32-low.c (win32_add_all_dlls): Renames
7310 win32_ensure_ntdll_loaded. Rewrite function documentation.
7311 Adjust implementation to always load all DLLs.
7312 Add 0x1000 offset to DLL base address when calling
7313 win32_add_one_solib.
7314 (child_initialization_done): New static global.
7315 (do_initial_child_stuff): Set child_initialization_done to
7316 zero during child initialization, and 1 after. Replace call
7317 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
7318 Add comment.
7319 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
7320 (handle_unload_dll): Add function documentation.
7321 (get_child_debug_event): Ignore load and unload DLL events
7322 during child initialization.
7323
d86d4aaf
DE
73242014-02-20 Doug Evans <dje@google.com>
7325
3bc32da3 7326 Remove global all_lwps.
d86d4aaf
DE
7327 * inferiors.h (ptid_of): Move here from linux-low.h.
7328 (pid_of, lwpid_of): Ditto.
7329 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
7330 parameter is a struct thread_info * now.
7331 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
7332 directly. Pass &all_threads to find_inferior instead of &all_lwps.
7333 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
7334 directly.
7335 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
7336 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
7337 * linux-arm-low.c (update_registers_callback): Update, "entry"
7338 parameter is a struct thread_info * now.
7339 Fetch lwpid from current_inferior directly.
7340 (arm_insert_point): Pass &all_threads to find_inferior instead of
7341 &all_lwps.
7342 (arm_remove_point): Ditto.
7343 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
7344 (arm_prepare_to_resume): Fetch pid from thread.
7345 (arm_read_description): Fetch lwpid from current_inferior directly.
7346 * linux-low.c (all_lwps): Delete.
7347 (delete_lwp): Delete call to remove_inferior.
7348 (handle_extended_wait): Fetch lwpid from thread.
7349 (add_lwp): Don't set lwp->entry.id. Remove call to
7350 add_inferior_to_list.
7351 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
7352 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
7353 (kill_one_lwp_callback): Ditto.
7354 (linux_kill): Don't dereference NULL pointer.
7355 Fetch ptid,lwpid from thread.
7356 (get_detach_signal): Fetch ptid from thread.
7357 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
7358 Simplify call to regcache_invalidate_thread.
7359 (delete_lwp_callback): Update, "entry" parameter is a
7360 struct thread_info * now. Fetch pid from thread.
7361 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
7362 (status_pending_p_callback): Update, "entry" parameter is a
7363 struct thread_info * now. Fetch ptid from thread.
7364 (find_lwp_pid): Update, "entry" parameter is a
7365 struct thread_info * now.
7366 (linux_wait_for_lwp): Fetch pid from thread.
7367 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
7368 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
7369 (enqueue_one_deferred_signal): Fetch lwpid from thread.
7370 (dequeue_one_deferred_signal): Ditto.
7371 (cancel_breakpoint): Fetch ptid from current_inferior.
7372 (linux_wait_for_event): Pass &all_threads to find_inferior,
7373 not &all_lwps. Fetch ptid, lwpid from thread.
7374 (count_events_callback): Update, "entry" parameter is a
7375 struct thread_info * now.
7376 (select_singlestep_lwp_callback): Ditto.
7377 (select_event_lwp_callback): Ditto.
7378 (cancel_breakpoints_callback): Ditto.
7379 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
7380 not &all_lwps.
7381 (select_event_lwp): Ditto. Fetch ptid from event_thread.
7382 (unsuspend_one_lwp): Update, "entry" parameter is a
7383 struct thread_info * now.
7384 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
7385 not &all_lwps.
7386 (linux_stabilize_threads): Ditto. And for for_each_inferior.
7387 Fetch lwpid from thread, not lwp.
7388 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
7389 Pass &all_threads to find_inferior, not &all_lwps.
7390 (send_sigstop): Fetch lwpid from thread, not lwp.
7391 (send_sigstop_callback): Update, "entry" parameter is a
7392 struct thread_info * now.
7393 (suspend_and_send_sigstop_callback): Ditto.
7394 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
7395 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
7396 struct thread_info * now.
7397 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
7398 from thread, lwp.
7399 (lwp_running): Update, "entry" parameter is a
7400 struct thread_info * now.
7401 (stop_all_lwps): Fetch ptid from thread.
7402 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
7403 (linux_resume_one_lwp): Fetch lwpid from thread.
7404 (linux_set_resume_request): Update, "entry" parameter is a
7405 struct thread_info * now. Fetch pid, lwpid from thread.
7406 (resume_status_pending_p): Update, "entry" parameter is a
7407 struct thread_info * now.
7408 (need_step_over_p): Ditto. Fetch lwpid from thread.
7409 (start_step_over): Fetch lwpid from thread.
7410 (linux_resume_one_thread): Update, "entry" parameter is a
7411 struct thread_info * now. Fetch lwpid from thread.
7412 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
7413 (proceed_one_lwp): Update, "entry" parameter is a
7414 struct thread_info * now. Fetch lwpid from thread.
7415 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
7416 struct thread_info * now.
7417 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
7418 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
7419 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
7420 directly.
7421 (regsets_store_inferior_registers): Ditto.
7422 (fetch_register, store_register): Ditto.
7423 (linux_read_memory, linux_write_memory): Ditto.
7424 (linux_request_interrupt): Ditto.
7425 (linux_read_auxv): Ditto.
7426 (linux_xfer_siginfo): Ditto.
7427 (linux_qxfer_spu): Ditto.
7428 (linux_qxfer_libraries_svr4): Ditto.
7429 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
7430 moved to inferiors.h.
7431 (get_lwp): Delete.
7432 (get_thread_lwp): Update.
7433 (struct lwp_info): Delete member "entry". Simplify comment for
7434 member "thread".
7435 (all_lwps): Delete.
7436 * linux-mips-low.c (mips_read_description): Fetch lwpid from
7437 current_inferior directly.
7438 (update_watch_registers_callback): Update, "entry" parameter is a
7439 struct thread_info * now. Fetch pid from thread.
7440 (mips_linux_prepare_to_resume): Fetch ptid from thread.
7441 (mips_insert_point): Fetch lwpid from current_inferior.
7442 Pass &all_threads to find_inferior, not &all_lwps.
7443 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
7444 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
7445 directly.
7446 (mips_stopped_data_address): Ditto.
7447 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
7448 directly.
7449 * linux-tile-low.c (tile_arch_setup): Ditto.
7450 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
7451 (update_debug_registers_callback): Update, "entry" parameter is a
7452 struct thread_info * now. Fetch pid from thread.
7453 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
7454 Pass &all_threads to find_inferior, not &all_lwps.
7455 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
7456 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
7457 Pass &all_threads to find_inferior, not &all_lwps.
7458 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
7459 (i386_dr_low_get_status): Ditto.
7460 (x86_linux_prepare_to_resume): Fetch ptid from thread.
7461 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
7462 (x86_linux_read_description): Ditto.
7463 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
7464
3b8361aa
DE
74652014-02-20 Doug Evans <dje@google.com>
7466
7467 * inferiors.c (get_first_inferior): Fix buglet.
7468
f7667f0d
DE
74692014-02-19 Doug Evans <dje@google.com>
7470
7471 * gdbthread.h (add_thread): Change result type to struct thread_info *.
7472 * inferiors.c (add_thread): Change result type to struct thread_info *.
7473 All callers updated.
7474 (add_lwp): Call add_thread here instead of in callers.
7475 All callers updated.
7476 * linux-low.h (get_lwp_thread): Rewrite.
7477 (struct lwp_info): New member "thread".
7478
b3312d80
DE
74792014-02-19 Doug Evans <dje@google.com>
7480
7481 * linux-low.c (add_lwp): Change result to struct lwp_info *.
7482 All callers updated.
7483
ecc6f45c
DE
74842014-02-19 Doug Evans <dje@google.com>
7485
7486 * inferiors.c (add_thread): Fix whitespace.
7487
649ebbca
DE
74882014-02-19 Doug Evans <dje@google.com>
7489
7490 * dll.c (clear_dlls): Replace accessing list implemention details
7491 with API function.
7492 * gdbthread.h (get_first_thread): Declare.
7493 * inferiors.c (for_each_inferior_with_data): New function.
7494 (get_first_thread): New function.
7495 (find_thread_ptid): Simplify.
7496 (get_first_inferior): New function.
7497 (clear_list): Delete.
7498 (one_inferior_p): New function.
7499 (clear_inferior_list): New function.
7500 (clear_inferiors): Update.
7501 * inferiors.h (for_each_inferior_with_data): Declare.
7502 (clear_inferior_list): Declare.
7503 (one_inferior_p): Declare.
7504 (get_first_inferior): Declare.
7505 * linux-low.c (linux_wait_for_event): Replace accessing list
7506 implemention details with API function.
7507 * server.c (target_running): Ditto.
7508 (accumulate_file_name_length): New function.
7509 (emit_dll_description): New function.
7510 (handle_qxfer_libraries): Replace accessing list implemention
7511 details with API function.
7512 (handle_qxfer_threads_worker): New function.
7513 (handle_qxfer_threads_proper): Replace accessing list implemention
7514 details with API function.
7515 (handle_query): Ditto.
7516 (visit_actioned_threads_callback_ftype): New typedef.
7517 (visit_actioned_threads_data): New struct.
7518 (visit_actioned_threads): Rewrite to be find_inferior callback.
7519 (resume): Call find_inferior.
7520 (handle_status): Replace accessing list implemention
7521 details with API function.
7522 (process_serial_event): Replace accessing list implemention details
7523 with API function.
7524 * target.c (set_desired_inferior): Replace accessing list implemention
7525 details with API function.
7526 * tracepoint.c (same_process_p): New function.
7527 (gdb_agent_about_to_close): Replace accessing list implemention
7528 details with API function.
7529 * win32-low.c (child_delete_thread): Replace accessing list
7530 implemention details with API function.
7531 (match_dll_by_basename): New function.
7532 (dll_is_loaded_by_basename): New function.
7533 (win32_ensure_ntdll_loaded): Replace accessing list implemention
7534 details call to dll_is_loaded_by_basename.
7535
80894984
DE
75362014-02-19 Doug Evans <dje@google.com>
7537
7538 * dll.h (struct dll_info): Add comment.
7539 * gdbthread.h (struct thread_info): Add comment.
7540 (current_ptid): Simplify.
7541 * inferiors.c (add_process): Update.
7542 (remove_process): Update.
7543 * inferiors.h (struct process_info): Rename member "head" to "entry".
7544 * linux-low.c (delete_lwp): Update.
7545 (add_lwp): Update.
7546 (last_thread_of_process_p): Update.
7547 (kill_one_lwp_callback, linux_kill): Update.
7548 (status_pending_p_callback): Update.
7549 (wait_for_sigstop): Update. Simplify read of ptid.
7550 (start_step_over): Update.
7551 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
7552 (get_lwp_thread): Update.
7553 (struct lwp_info): Rename member "head" to "entry".
7554 * regcache.h (inferior_list_entry): Delete.
7555 * server.c (kill_inferior_callback): Update.
7556 (detach_or_kill_inferior_callback): Update.
7557 (print_started_pid): Update.
7558 (print_attached_pid): Update.
7559 (process_serial_event): Simplify read of ptid.
7560 * thread-db.c (thread_db_create_event): Update.
7561 (thread_db_get_tls_address): Update.
7562 * win32-low.c (current_inferior_ptid): Simplify.
7563
46917d26
TT
75642014-02-19 Tom Tromey <tromey@redhat.com>
7565
7566 * target.h (struct target_ops) <supports_btrace>: Add target_ops
7567 argument.
7568 (target_supports_btrace): Update.
7569
0759a81e
YQ
75702014-02-14 Yao Qi <yao@codesourcery.com>
7571
7572 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
7573 (rsp-low-ipa.o): New target.
7574
a7191e8b
TT
75752014-02-12 Tom Tromey <tromey@redhat.com>
7576
7577 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
7578 convert_ascii_to_int.
7579 * regcache.c (registers_to_string): Likewise.
7580 * remote-utils.c (decode_M_packet): Likewise.
7581 * server.c (process_serial_event): Likewise.
7582
ff0e980e
TT
75832014-02-12 Tom Tromey <tromey@redhat.com>
7584
7585 * server.c (handle_query, handle_v_run): Use hex2bin, not
7586 unhexify.
7587 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
7588
e9371aff
TT
75892014-02-12 Tom Tromey <tromey@redhat.com>
7590
7591 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
7592 convert_int_to_ascii.
7593 * regcache.c (registers_to_string, collect_register_as_string):
7594 Likewise.
7595 * remote-utils.c (look_up_one_symbol, relocate_instruction):
7596 Likewise.
7597 * server.c (process_serial_event): Likewise.
7598 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
7599 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
7600
971dc0b8
TT
76012014-02-12 Tom Tromey <tromey@redhat.com>
7602
7603 * remote-utils.c (look_up_one_symbol, monitor_output): Use
7604 bin2hex, not hexify.
7605 * tracepoint.c (cmd_qtstatus): Likewise.
7606
0a822afb
TT
76072014-02-12 Tom Tromey <tromey@redhat.com>
7608
7609 * remote-utils.c (monitor_output): Pass explicit length to
7610 hexify.
7611
9c3d6531
TT
76122014-02-12 Tom Tromey <tromey@redhat.com>
7613
7614 * tracepoint.c: Include rsp-low.h.
7615 * server.c: Include rsp-low.h.
7616 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
7617 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
7618 declare.
7619 * remote-utils.c: Include rsp-low.h.
7620 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
7621 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
7622 (convert_int_to_ascii, convert_ascii_to_int): Move to
7623 common/rsp-low.c.
7624 * regcache.c: Include rsp-low.h.
7625 * ax.c: Include rsp-low.h.
7626 * Makefile.in (SFILES): Add common/rsp-low.c.
7627 (OBS): Add rsp-low.o.
7628 (rsp-low.o): New target.
7629
01fd3ea5
TT
76302014-02-12 Tom Tromey <tromey@redhat.com>
7631
7632 * utils.h (pulongest, plongest, phex_nz): Don't declare.
7633 Include print-utils.h.
7634 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
7635 (plongest, thirty_two, phex_nz): Remove.
7636 * Makefile.in (SFILES): Add common/print-utils.c.
7637 (OBS): Add print-utils.o.
7638 (print-utils-ipa.o): New target.
7639 (print-utils.o): New target.
7640 (IPA_OBJS): Add print-utils-ipa.o.
7641
e99dc820
TT
76422014-02-06 Tom Tromey <tromey@redhat.com>
7643
7644 * Makefile.in (SFILES): Fix indentation.
7645
ee1e2d4f
DE
76462014-02-05 Doug Evans <dje@google.com>
7647
7648 * linux-low.c (linux_wait_for_event): Improve comment.
7649 (linux_wait_1): Keep current_inferior in sync with event_child.
7650
f5a02773
DE
76512014-01-22 Doug Evans <dje@google.com>
7652
7653 * gdbthread.h (gdb_id_to_thread): Delete, unused.
7654
87ce2a04
DE
76552014-01-22 Doug Evans <dje@google.com>
7656
7657 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
7658 * configure: Regenerate.
7659 * config.in: Regenerate.
7660 * Makefile.in (SFILES): Add debug.c.
7661 (OBS): Add debug.o.
7662 * debug.c: New file.
7663 * debug.h: New file.
7664 * linux-aarch64-low.c (*): Update all debugging printfs to use
7665 debug_printf instead of fprintf.
7666 * linux-arm-low.c (*): Ditto.
7667 * linux-cris-low.c (*): Ditto.
7668 * linux-crisv32-low.c (*): Ditto.
7669 * linux-m32r-low.c (*): Ditto.
7670 * linux-sparc-low.c (*): Ditto.
7671 * linux-x86.c (*): Ditto.
7672 * linux-low.c (*): Ditto.
7673 (linux_wait_1): Add calls to debug_enter, debug_exit.
7674 (linux_wait): Remove redundant debugging printf.
7675 (stop_all_lwps): Add calls to debug_enter, debug_exit.
7676 (linux_resume, unstop_all_lwps): Ditto.
7677 * mem-break.c (*): Update all debugging printfs to use
7678 debug_printf instead of fprintf.
7679 * remote-utils.c (*): Ditto.
7680 * thread-db.c (*): Ditto.
7681 * server.c #include <ctype.h>, "gdb_vecs.h".
7682 (debug_threads): Moved to debug.c.
7683 (*): Update all debugging printfs to use debug_printf instead of
7684 fprintf.
7685 (start_inferior): Replace call to fflush with call to debug_flush.
7686 (monitor_show_help): Mention set debug-format.
7687 (parse_debug_format_options): New function.
7688 (handle_monitor_command): Handle "monitor set debug-format".
7689 (gdbserver_usage): Mention --debug-format.
7690 (main): Parse --debug-format.
7691 * server.h (debug_threads): Declaration moved to debug.h.
7692 #include "debug.h".
7693 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
7694 trace_debug_1 that uses debug_printf.
7695 (tracepoint_look_up_symbols): Update all debugging printfs to use
7696 debug_printf instead of fprintf.
7697
e671835b
BS
76982014-01-20 Baruch Siach <baruch@tkos.co.il>
7699
7700 * linux-xtensa-low.c: Include asm/ptrace.h instead of
7701 sys/ptrace.h.
7702
b5737fa9
PA
77032014-01-17 Pedro Alves <palves@redhat.com>
7704
ea38d2a9 7705 PR build/16445
c7faa97a
PA
7706 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
7707 defined after including gdb_proc_service.h.
b5737fa9 7708
40ed484e
DE
77092014-01-16 Doug Evans <dje@google.com>
7710
7711 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
7712 (match_dll): Use it.
7713
969c39fb
MM
77142014-01-16 Markus Metzger <markus.t.metzger@intel.com>
7715
7716 * target.h (target_ops) <read_btrace>: Change parameters and
7717 return type to allow error reporting.
7718 * server.c (handle_qxfer_btrace): Support delta reads. Pass
7719 trace reading errors on.
7720 * linux-low.c (linux_low_read_btrace): Pass trace reading
7721 errors on.
7722 (linux_low_disable_btrace): New.
7723
ab7f45ba
DE
77242014-01-15 Doug Evans <dje@google.com>
7725
7726 * inferiors.c (thread_id_to_gdb_id): Delete.
7727 * inferiors.h (thread_id_to_gdb_id): Delete.
7728
66af0f44
EZ
77292014-01-13 Eli Zaretskii <eliz@gnu.org>
7730
7731 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
7732 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
7733 versions.
7734
9939e131
PA
77352014-01-08 Pedro Alves <palves@redhat.com>
7736
7737 * server.c (handle_status): Don't discard previous queued stop
7738 replies or thread's pending status here.
7739 (main) <disconnection>: Do it here instead.
7740
b7ea362b
PA
77412014-01-08 Pedro Alves <palves@redhat.com>
7742
7743 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
7744 * server.c (visit_actioned_threads, handle_pending_status): New
7745 function.
7746 (handle_v_cont): Factor out parts to ...
7747 (resume): ... this new function. If in all-stop, and a thread
7748 being resumed has a pending status, report it without actually
7749 resuming.
7750 (myresume): Adjust to use the new 'resume' function.
7751 (clear_pending_status_callback, set_pending_status_callback)
7752 (find_status_pending_thread_callback): New functions.
7753 (handle_status): Handle the case of multiple threads having
7754 interesting statuses to report. Report threads' real last signal
7755 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
7756 with an interesting thread to report the status for, instead of
7757 always reporting the status of the first thread.
7758
28498c42
JB
77592014-01-01 Joel Brobecker <brobecker@adacore.com>
7760
7761 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
7762 * gdbreplay.c (gdbreplay_version): Likewise.
7763
f45c82da
YZ
77642013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
7765
7766 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
7767 iov.iov_len with the real length in use.
7768
379a5e2d
JB
77692013-12-13 Joel Brobecker <brobecker@adacore.com>
7770
7771 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
7772 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
7773 for all targets that use win32-low.c.
7774 * win32-low.c (win32_ensure_ntdll_loaded): New function.
7775 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
7776
4210d83e
PA
77772013-12-13 Pedro Alves <palves@redhat.com>
7778
7779 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
7780 if equal to TARGET_WAITKIND_LOADED.
7781 * win32-low.c (cached_status): New static global.
7782 (win32_wait): Add declaration.
7783 (do_initial_child_stuff): Flush all initial pending debug events
7784 up to the initial breakpoint.
7785 (win32_wait): If CACHED_STATUS was set, return that instead
7786 of doing a real wait. Remove the code resuming the execution
7787 of the inferior after receiving a TARGET_WAITKIND_LOADED event
7788 during the initial phase. Also remove the code changing
7789 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
7790 TARGET_WAITKIND_STOPPED.
7791
e7f0d979
YQ
77922013-12-11 Yao Qi <yao@codesourcery.com>
7793
7794 * notif.c (handle_notif_ack): Return 0 if no notification
7795 matches.
7796
ebcf782c
DE
77972013-11-20 Doug Evans <dje@google.com>
7798
7799 * linux-low.c (linux_set_resume_request): Fix comment.
7800
20ad9378
DE
78012013-11-20 Doug Evans <dje@google.com>
7802
7803 * linux-low.c (resume_status_pending_p): Tweak comment.
7804
a196ebeb
WT
78052013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7806
7807 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
7808 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
7809 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
7810 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
7811 (srv_amd64_regobj): Add amd64-mpx.o.
7812 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
7813 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
7814 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
7815 * i387-fp.c (num_pl_bnd_register) Added constant.
7816 (num_pl_bnd_cfg_registers) Added constant.
7817 (struct i387_xsave) Added reserved area and MPX fields.
7818 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
7819 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
7820 function.
7821 (tdesc_i386_mpx_linux): Add MPX amd64 target.
7822 (init_registers_amd64_mpx_linux): Declare new function.
7823 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
7824 (x86_64_regmap): Add MPX registers.
7825 (x86_linux_read_description): Add MPX case.
7826 (initialize_low_arch): Initialize MPX targets.
7827
0080a2f6
TT
78282013-11-18 Tom Tromey <tromey@redhat.com>
7829
7830 * configure: Rebuild.
7831 * configure.ac: Don't check for stdlib.h.
7832 * gdbreplay.c: Unconditionally include stdlib.h.
7833
2978b111
TT
78342013-11-18 Tom Tromey <tromey@redhat.com>
7835
7836 * config.in: Rebuild.
7837 * configure: Rebuild.
7838 * configure.ac: Don't use AC_HEADER_DIRENT.
7839
a3d08894
TT
78402013-11-18 Tom Tromey <tromey@redhat.com>
7841
7842 * server.h: Don't check HAVE_STRING_H.
7843 * gdbreplay.c: Don't check HAVE_STRING_H.
7844 * configure: Rebuild.
7845
0a5dd17d
TT
78462013-11-18 Tom Tromey <tromey@redhat.com>
7847
7848 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
7849 LIBGNU.
7850
1bd2f0ba
TT
78512013-11-08 Tom Tromey <tromey@redhat.com>
7852
7853 * configure, config.in: Rebuild.
7854 * configure.ac: Remove unused configury.
7855
3266f10b
TT
78562013-11-08 Tom Tromey <tromey@redhat.com>
7857
7858 * acinclude.m4: Include common.m4, codeset.m4.
7859 * configure, config.in: Rebuild.
7860 * configure.ac: Use GDB_AC_COMMON.
7861
6682d959
AA
78622013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
7863
7864 * linux-s390-low.c (HWCAP_S390_TE): New define.
7865 (s390_arch_setup): Consider the TE field in the HWCAP for
7866 determining 'have_regset_tdb'.
7867
fd0a4d76
SDJ
78682013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
7869
7870 PR gdb/16014
7871 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
7872 call to sizeof.
7873
1a3d890b
PA
78742013-10-02 Pedro Alves <palves@redhat.com>
7875
7876 * server.c (process_serial_event): Don't output "GDBserver
7877 exiting" if GDB is connected through stdio.
7878 * target.c (mywait): Likewise, be silent if GDB is connected
7879 through stdio.
7880
97ad4581
JB
78812013-10-01 Joel Brobecker <brobecker@adacore.com>
7882
7883 * lynx-low.c (lynx_add_threads_after_attach): New function.
7884 (lynx_attach): Remove call to add_thread. Add call to
7885 lynx_add_threads_after_attach instead.
7886
5b4e221c
MF
78872013-09-28 Mike Frysinger <vapier@gentoo.org>
7888
7889 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
7890 * config.in, configure: Regenerated.
7891
ee47b2f8
YQ
78922013-09-18 Yao Qi <yao@codesourcery.com>
7893
7894 PR server/15959
7895 * server.c (start_inferior): Clear 'resume_info'.
7896
d6707650 78972013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 7898
d6707650
JW
7899 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
7900 for each register.
7901
9243dd0e 79022013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 7903
9243dd0e
JW
7904 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
7905 linux-tile-low.o to srv_tgtobj.
7906
c623a6ef
WN
79072013-09-16 Will Newton <will.newton@linaro.org>
7908
7909 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
7910 out regs.
7911
fb71d39e
PA
79122013-09-06 Pedro Alves <palves@redhat.com>
7913
7914 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
7915 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
7916 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
7917 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
7918 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
7919 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
7920
8e7e9910
PA
79212013-09-06 Pedro Alves <palves@redhat.com>
7922
7923 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
7924 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
7925
7c3a12ca
PA
79262013-09-06 Pedro Alves <palves@redhat.com>
7927
7928 * linux-amd64-ipa.c: Include tracepoint.h.
7929 * linux-i386-ipa.c: Include tracepoint.h.
7930
8eb3d7b6
RW
79312013-09-06 Ricard Wanderlof <ricardw@axis.com>
7932
7933 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
7934 (ps_get_thread_area): New function.
7935
eddddb9d
RW
79362013-09-06 Ricard Wanderlof <ricardw@axis.com>
7937
7938 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
7939 (initialize_low_arch): Call init_registers_crisv32 rather than
7940 init_register_crisv32.
7941
533b0600
PA
79422013-09-05 Pedro Alves <palves@redhat.com>
7943
7944 * server.h (handle_vFile, hostio_last_error_from_errno): Move
7945 to ...
7946 * hostio.h: ... this new file.
7947 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
7948 win32-low.c: Include hostio.h.
7949
0ce3d3b5
PA
79502013-09-05 Pedro Alves <palves@redhat.com>
7951
7952 * server.h (gdb_client_data, handler_func, callback_handler_func)
7953 (delete_file_handler, add_file_handler, append_callback_event)
7954 (delete_callback_event, start_event_loop, initialize_event_loop):
7955 Move to event-loop.h and include it.
7956 * event-loop.h: New file.
7957
799cdc37
PA
79582013-09-05 Pedro Alves <palves@redhat.com>
7959
7960 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
7961 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
7962 (loaded_dll, unloaded_dll): Move to ...
7963 * dll.h: ... this new file.
7964 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
7965
6a6bbd9d
PA
79662013-09-05 Pedro Alves <palves@redhat.com>
7967
7968 * server.h (current_process, get_thread_process, all_processes)
7969 (add_inferior_to_list, for_each_inferior, current_inferior)
7970 (remove_inferior, add_process, remove_process, find_process_pid)
7971 (have_started_inferiors_p, have_attached_inferiors_p)
7972 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
7973 (clear_inferiors, find_inferior, find_inferior_id)
7974 (inferior_target_data, set_inferior_target_data)
7975 (inferior_regcache_data, set_inferior_regcache_data): Move to
7976 inferiors.h, and include it.
7977 * inferiors.h: New file.
7978
f699aaba
PA
79792013-09-05 Pedro Alves <palves@redhat.com>
7980
7981 * server.h (struct emit_ops, current_insn_ptr, emit_error):
7982 Move ...
72f4393d 7983 * ax.h: ... here.
f699aaba 7984
c144c7a0
PA
79852013-09-05 Pedro Alves <palves@redhat.com>
7986
7987 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
7988 tracepoint.h.
7989 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
7990 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
7991 (handle_tracepoint_general_set, handle_tracepoint_query)
7992 (tracepoint_finished_step, tracepoint_was_hit)
7993 (release_while_stepping_state_list, current_traceframe)
7994 (in_readonly_region, traceframe_read_mem)
7995 (fetch_traceframe_registers, traceframe_read_sdata)
7996 (traceframe_read_info, struct fast_tpoint_collect_status)
7997 (fast_tracepoint_collecting, force_unlock_trace_buffer)
7998 (handle_tracepoit_bkpts, initialize_low_tracepoint)
7999 (supply_fast_tracepoint_registers)
8000 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
8001 (ipa_tdesc, claim_trampoline_space)
8002 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
8003 (agent_mem_read, agent_get_trace_state_variable_value)
8004 (agent_set_trace_state_variable_value, agent_tsv_read)
8005 (agent_mem_read_string, get_raw_reg_func_addr)
8006 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
8007 * tracepoint.h: ... this new file.
8008
ff42e6ab
PA
80092013-09-05 Pedro Alves <palves@redhat.com>
8010
8011 * server.h (perror_with_name, error, fatal, warning, paddress)
8012 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
8013 include it.
8014 * utils.h: New file.
8015
541af0f4
PA
80162013-09-05 Pedro Alves <palves@redhat.com>
8017
8018 * server.h (remote_debug, noack_mode, transport_is_reliable)
8019 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
8020 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
8021 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
8022 (write_enn, initialize_async_io, enable_async_io)
8023 (disable_async_io, check_remote_input_interrupt_request)
8024 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
8025 (dead_thread_notify, prepare_resume_reply)
8026 (decode_address_to_semicolon, decode_address, decode_m_packet)
8027 (decode_M_packet, decode_X_packet, decode_xfer_write)
8028 (decode_search_memory_packet, unhexify, hexify)
8029 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
8030 (look_up_one_symbol, relocate_instruction)
8031 (monitor_output): Move to remote-utils.h, and include it.
8032 * remote-utils.h: New file.
8033
eebdf26b
PA
80342013-09-05 Pedro Alves <palves@redhat.com>
8035
8036 * server.h (_): Delete.
8037
3aafd2ff
PA
80382013-09-02 Pedro Alves <palves@redhat.com>
8039
8040 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
8041 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
8042 allocated.
8043 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
8044
cee83bcb
PM
80452013-09-02 Pierre Muller <muller@sourceware.org>
8046
8047 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
8048 or WriteProcessMemory complete successfully and handle
8049 ERROR_PARTIAL_COPY error.
8050
9a13b2fa
PA
80512013-09-02 Pedro Alves <palves@redhat.com>
8052
8053 * server.c (gdb_read_memory): Return -1 on traceframe memory read
8054 error instead of EIO.
8055
602e3198
JK
80562013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8057
8058 PR server/15604
8059 * linux-low.c: Include filestuff.h.
8060 (linux_create_inferior) <pid == 0>: Call close_most_fds.
8061 * lynx-low.c: Include filestuff.h.
8062 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
8063 * server.c: Include filestuff.h.
8064 (main): Call notice_open_fds.
8065 * spu-low.c: Include filestuff.h.
8066 (spu_create_inferior) <pid == 0>: Call close_most_fds.
8067
96d7229d
LM
80682013-08-22 Luis Machado <lgustavo@codesourcery.com>
8069
8070 * Makefile.in: Explain why ../target and ../nat are not
8071 listed as include file search paths.
8072 (linux-waitpid.o): New object file rule.
8073 * configure.srv (srv_native_linux_obj): New variable.
8074 Replace all occurrences of linux native object files with
8075 $srv_native_linux_obj.
8076 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
8077 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
8078 (linux_enable_event_reporting): Remove declaration.
8079 (my_waitpid): Moved to common/linux-waitpid.c.
8080 (linux_wait_for_event): Pass ptid when calling
8081 linux_enable_event_reporting.
8082 (linux_supports_tracefork_flag): Remove.
8083 (linux_enable_event_reporting): Likewise.
8084 (linux_tracefork_grandchild): Remove.
8085 (STACK_SIZE): Moved to common/linux-ptrace.c.
8086 (linux_tracefork_child): Remove.
8087 (linux_test_for_tracefork): Remove.
8088 (linux_look_up_symbols): Call linux_supports_traceclone.
8089 (initialize_low): Remove call to linux_test_for_tracefork.
8090 * linux-low.h (PTRACE_TYPE_ARG3): Move to
8091 common/linux-ptrace.h.
8092 (PTRACE_TYPE_ARG4): Likewise.
8093 Include linux-ptrace.h.
8094
32940073
PA
80952013-08-21 Pedro Alves <palves@redhat.com>
8096
8097 * config.in: Renegerate.
8098
33b60d58 80992013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 8100
33b60d58
LM
8101 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
8102 (SFILES): Remove $(srcdir)/common/target-common.c and
8103 add $(srcdir)/target/waitstatus.c.
8104 (OBS): Remove target-common.o and add waitstatus.o.
8105 (server_h): Remove $(srcdir)/../common/target-common.h and
8106 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
8107 and $(srcdir)/../target/waitstatus.h.
8108 (target-common.o): Remove.
8109 (waitstatus.o): New target object file.
8110 * target.h: Do not include target-common.h and
8111 include target/resume.h, target/wait.h and
8112 target/waitstatus.h.
8113
b8e1b30e
LM
81142013-08-13 Luis Machado <lgustavo@codesourcery.com>
8115
8116 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8117 to PTRACE_TYPE_ARG3.
8118 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8119 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
8120 PTRACE_TYPE_ARG4.
8121 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
8122 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
8123
7a60ad40
YQ
81242013-07-27 Jie Zhang <jie@codesourcery.com>
8125 Daniel Jacobowitz <dan@codesourcery.com>
8126 Yao Qi <yao@codesourcery.com>
8127
8128 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
8129 (mips-linux-watch.o): New rule.
8130 (mips_linux_watch_h): New variable.
8131 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
8132 srv_tgtobj.
8133 * linux-mips-low.c: Include mips-linux-watch.h.
8134 (struct arch_process_info, struct arch_lwp_info): New.
8135 (update_watch_registers_callback): New function.
8136 (mips_linux_new_process, mips_linux_new_thread) New functions.
8137 (mips_linux_prepare_to_resume, mips_insert_point): New
8138 functions.
8139 (mips_remove_point, mips_stopped_by_watchpoint): New
8140 functions.
8141 (rsp_bp_type_to_target_hw_bp_type): New function.
8142 (mips_stopped_data_address): New function.
8143 (the_low_target): Add watchpoint support functions.
8144
de6f69ad
YQ
81452013-07-27 Yao Qi <yao@codesourcery.com>
8146
8147 * i386-low.c: Include break-common.h.
8148 (enum target_hw_bp_type): Remove.
8149
3360c0bf
LM
81502013-07-24 Luis Machado <lgustavo@codesourcery.com>
8151
8152 * Makefile.in (SFILES): /common/target-common.c.
8153 (OBS): Add target-common.o.
8154 (server_h): Add $(srcdir)/../common/target-common.h.
8155 (target-common.o): New target.
8156 * server.c (queue_stop_reply_callback): Free
8157 status string after use.
8158 * target.c (target_waitstatus_to_string): Remove.
8159 * target.h: Include target-common.h.
8160 (resume_kind): Likewise.
8161 (target_waitkind): Likewise.
8162 (target_waitstatus): Likewise.
8163 (TARGET_WNOHANG): Likewise.
8164
bd885420
YQ
81652013-07-04 Yao Qi <yao@codesourcery.com>
8166
8167 * Makefile.in (host_alias): Use @host_noncanonical@.
8168 (target_alias): Use @target_noncanonical@.
8169 * configure.ac: Use ACX_NONCANONICAL_TARGET and
8170 ACX_NONCANONICAL_HOST.
8171 * configure: Regenerated.
8172
8173 Revert:
8174 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8175
8176 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8177 * configure: Rebuild.
8178 * Makefile.in (version_host, version_target): Get from configure.
8179 (version.c): Use $(version_host) and $(version_target).
8180
17ef446e
PA
81812013-07-03 Pedro Alves <palves@redhat.com>
8182
8183 * Makefile.in (config.status): Depend on development.sh.
8184 * acinclude.m4: Include libmcheck.m4.
8185 * configure: Regenerate.
8186
7a9a7487
MG
81872013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8188
8189 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
8190 attribute inside the parentheses.
8191 (winapi_DebugSetProcessKillOnExit): Ditto.
8192 (winapi_DebugBreakProcess): Ditto.
8193 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 8194
49b64de6
MG
81952013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8196
8197 * notif.h (notif_event): Add a dummy member to avoid compiler
8198 errors.
8199
d5749ee7
PA
82002013-07-01 Pedro Alves <palves@redhat.com>
8201
8202 * hostio.c (HOSTIO_PATH_MAX): Define.
8203 (require_filename, handle_open, handle_unlink, handle_readlink):
8204 Use it.
8205
d8d2a3ee
PA
82062013-07-01 Pedro Alves <palves@redhat.com>
8207
8208 * server.h: Include "pathmax.h".
8209 * linux-low.c: Don't include sys/param.h.
8210 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
8211 MAXPATHLEN.
8212 * win32-low.c: Don't include sys/param.h.
8213 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
8214
bc7dea8d
PA
82152013-07-01 Pedro Alves <palves@redhat.com>
8216
8217 * event-loop.c: Don't check HAVE_UNISTD_H before including
8218 <unistd.h>.
8219 * gdbreplay.c: Likewise.
8220 * remote-utils.c: Likewise.
8221 * server.c: Likewise.
8222 * configure.ac: Don't check for unistd.h.
8223 * configure: Regenerate.
8224
d6c2da54
TT
82252013-06-28 Tom Tromey <tromey@redhat.com>
8226
8227 * Makefile.in (version.c): Use version.in, not
8228 common/version.in.
8229
257b6bec
MG
82302013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8231
8232 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8233 * configure: Rebuild.
8234 * Makefile.in (version_host, version_target): Get from configure.
8235 (version.c): Use $(version_host) and $(version_target).
8236
86ebe149
DK
82372013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8238
8239 Fix trace-status to output user name without trailing colon.
8240 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
8241
f30aa5af
DK
82422013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8243
8244 Fix trace-status to output proper start-time and stop-time.
8245 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
8246 output start time and stop time in hex as gdb expects.
8247
28a93511
YQ
82482013-06-26 Pedro Alves <pedro@codesourcery.com>
8249
8250 * tracepoint.c (build_traceframe_info_xml): Output trace state
8251 variables present in the trace buffer.
8252
01208463
TT
82532013-06-24 Tom Tromey <tromey@redhat.com>
8254
8255 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
8256 create-version.sh.
8257 (version.o): Remove.
8258 * gdbreplay.c: Include version.h.
8259 (version, host_name): Don't declare.
8260 * server.h: Include version.h.
8261 (version, host_name): Don't declare.
8262
760256f9
PA
82632013-06-12 Pedro Alves <palves@redhat.com>
8264
8265 * linux-x86-low.c (linux_is_elf64): Delete global.
8266 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
8267 with local linux_pid_exe_is_elf_64_file use.
8268
030031ee
PA
82692013-06-11 Pedro Alves <palves@redhat.com>
8270
8271 * linux-low.c (regset_disabled, disable_regset): New functions.
8272 (regsets_fetch_inferior_registers)
8273 (regsets_store_inferior_registers): Use them.
8274 (initialize_regsets_info); Don't allocate the disabled_regsets
8275 array here.
8276 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
8277 comment.
8278
5da6eb0a
PA
82792013-06-11 Pedro Alves <palves@redhat.com>
8280
8281 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
8282 xmalloc.
8283
7e5aaa09
PA
82842013-06-11 Pedro Alves <palves@redhat.com>
8285
8286 * linux-x86-low.c (initialize_low_arch): Call
8287 init_registers_x32_avx_linux.
8288
d878444c
JK
82892013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
8290
8291 Fix compatibility with Android Bionic.
8292 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
8293 it is not empty.
8294
3aee8918
PA
82952013-06-07 Pedro Alves <palves@redhat.com>
8296
5f2b57b5 8297 PR server/14823
3aee8918
PA
8298 * Makefile.in (OBS): Add tdesc.o.
8299 (IPA_OBJS): Add tdesc-ipa.o.
8300 (tdesc-ipa.o): New rule.
8301 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
8302 interface.
8303 * linux-low.c (new_inferior): Delete.
8304 (disabled_regsets, num_regsets): Delete.
8305 (linux_add_process): Adjust to set the new per-process
8306 new_inferior flag.
8307 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
8308 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
8309 was a stop. When calling arch_setup, switch the current inferior
8310 to the thread that got an event.
8311 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
8312 (regsets_fetch_inferior_registers)
8313 (regsets_store_inferior_registers): New regsets_info parameter.
8314 Adjust to use it.
8315 (linux_register_in_regsets): New regs_info parameter. Adjust to
8316 use it.
8317 (register_addr, fetch_register, store_register): New usrregs_info
8318 parameter. Adjust to use it.
8319 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
8320 parameter regs_info. Adjust to use it.
8321 (linux_fetch_registers): Get the current inferior's regs_info, and
8322 adjust to use it.
8323 (linux_store_registers): Ditto.
8324 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
8325 (initialize_low): Don't initialize the target_regsets here. Call
8326 initialize_low_arch.
8327 * linux-low.h (target_regsets): Delete declaration.
8328 (struct regsets_info): New.
8329 (struct usrregs_info): New.
8330 (struct regs_info): New.
8331 (struct process_info_private) <new_inferior>: New field.
8332 (struct linux_target_ops): Delete the num_regs, regmap, and
8333 regset_bitmap fields. New field regs_info.
8334 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
8335 * i387-fp.c (num_xmm_registers): Delete.
8336 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
8337 calls to new interface.
8338 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
8339 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
8340 Infer the number of xmm registers from the regcache's target
8341 description.
8342 * i387-fp.h (num_xmm_registers): Delete.
8343 * inferiors.c (add_thread): Don't install the thread's regcache
8344 here.
8345 * proc-service.c (gregset_info): Fetch the current inferior's
8346 regs_info. Adjust to use it.
8347 * regcache.c: Include tdesc.h.
8348 (register_bytes, reg_defs, num_registers)
8349 (gdbserver_expedite_regs): Delete.
8350 (get_thread_regcache): If the thread doesn't have a regcache yet,
8351 create one, instead of aborting gdbserver.
8352 (regcache_invalidate_one): Rename to ...
8353 (regcache_invalidate_thread): ... this.
8354 (regcache_invalidate_one): New.
8355 (regcache_invalidate): Only invalidate registers of the current
8356 process.
8357 (init_register_cache): Add target_desc parameter, and use it.
8358 (new_register_cache): Ditto. Assert the target description has a
8359 non zero registers_size.
8360 (regcache_cpy): Add assertions. Adjust.
8361 (realloc_register_cache, set_register_cache): Delete.
8362 (registers_to_string, registers_from_string): Adjust.
8363 (find_register_by_name, find_regno, find_register_by_number)
8364 (register_cache_size): Add target_desc parameter, and use it.
8365 (free_register_cache_thread, free_register_cache_thread_one)
8366 (regcache_release, register_cache_size): New.
8367 (register_size): Add target_desc parameter, and use it.
8368 (register_data, supply_register, supply_register_zeroed)
8369 (supply_regblock, supply_register_by_name, collect_register)
8370 (collect_register_as_string, collect_register_by_name): Adjust.
8371 * regcache.h (struct target_desc): Forward declare.
8372 (struct regcache) <tdesc>: New field.
8373 (init_register_cache, new_register_cache): Add target_desc
8374 parameter.
8375 (regcache_invalidate_thread): Declare.
8376 (regcache_invalidate_one): Delete declaration.
8377 (regcache_release): Declare.
8378 (find_register_by_number, register_cache_size, register_size)
8379 (find_regno): Add target_desc parameter.
8380 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
8381 declarations.
8382 * remote-utils.c: Include tdesc.h.
8383 (outreg, prepare_resume_reply): Adjust.
8384 * server.c: Include tdesc.h.
8385 (gdbserver_xmltarget): Delete declaration.
8386 (get_features_xml, process_serial_event): Adjust.
8387 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
8388 declare.
8389 (struct process_info) <tdesc>: New field.
8390 (ipa_tdesc): Declare.
8391 * tdesc.c: New file.
8392 * tdesc.h: New file.
8393 * tracepoint.c: Include tdesc.h.
8394 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
8395 (get_context_regcache): Adjust to pass ipa_tdesc down.
8396 (do_action_at_tracepoint): Adjust to get the register cache size
8397 from the context regcache's description.
8398 (traceframe_walk_blocks): Adjust to get the register cache size
8399 from the current trace frame's description.
8400 (traceframe_get_pc): Adjust to get current trace frame's
8401 description and pass it down.
8402 (gdb_collect): Adjust to get the register cache size from the
8403 IPA's description.
8404 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
8405 (gdbserver_xmltarget): Delete.
8406 (initialize_low_tracepoint): Set the ipa's target description.
8407 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
8408 (initialize_low_tracepoint): Set the ipa's target description.
8409 * linux-x86-low.c: Include tdesc.h.
8410 [__x86_64__] (is_64bit_tdesc): New.
8411 (ps_get_thread_area, x86_get_thread_area): Use it.
8412 (i386_cannot_store_register): Rename to ...
8413 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
8414 (i386_cannot_fetch_register): Rename to ...
8415 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
8416 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
8417 to new interface.
8418 (target_regsets): Rename to ...
8419 (x86_regsets): ... this.
8420 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
8421 interface.
8422 (x86_siginfo_fixup): Use is_64bit_tdesc.
8423 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
8424 (tdesc_x32_avx_linux, tdesc_x32_linux)
8425 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
8426 Declare.
8427 (x86_linux_update_xmltarget): Delete.
8428 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
8429 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
8430 (AMD64_LINUX_USER64_CS): New.
8431 (x86_linux_read_description): New, based on
8432 x86_linux_update_xmltarget.
8433 (same_process_callback): New.
8434 (x86_arch_setup_process_callback): New.
8435 (x86_linux_update_xmltarget): New.
8436 (x86_regsets_info): New.
8437 (amd64_linux_regs_info): New.
8438 (i386_linux_usrregs_info): New.
8439 (i386_linux_regs_info): New.
8440 (x86_linux_regs_info): New.
8441 (x86_arch_setup): Reimplement.
8442 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
8443 (x86_emit_ops): Ditto.
8444 (the_low_target): Adjust. Install x86_linux_regs_info,
8445 x86_cannot_fetch_register, and x86_cannot_store_register.
8446 (initialize_low_arch): New.
8447 * linux-ia64-low.c (tdesc_ia64): Declare.
8448 (ia64_fetch_register): Adjust.
8449 (ia64_usrregs_info, regs_info): New globals.
8450 (ia64_regs_info): New function.
8451 (the_low_target): Adjust.
8452 (initialize_low_arch): New function.
8453 * linux-sparc-low.c (tdesc_sparc64): Declare.
8454 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
8455 Adjust.
8456 (sparc_arch_setup): New function.
8457 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
8458 (the_low_target): Adjust.
8459 (initialize_low_arch): New function.
8460 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
8461 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
8462 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
8463 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
8464 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
8465 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
8466 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
8467 (tdesc_powerpc_isa205_vsx64l): Declare.
8468 (ppc_cannot_store_register, ppc_collect_ptrace_register)
8469 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
8470 (ppc_set_pc, ppc_get_hwcap): Adjust.
8471 (ppc_usrregs_info): Forward declare.
8472 (!__powerpc64__) ppc_regmap_adjusted: New global.
8473 (ppc_arch_setup): Adjust to the current process'es target
8474 description.
8475 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
8476 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
8477 (ppc_store_evrregset): Adjust.
8478 (target_regsets): Rename to ...
8479 (ppc_regsets): ... this, and make static.
8480 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
8481 (ppc_regs_info): New function.
8482 (the_low_target): Adjust.
8483 (initialize_low_arch): New function.
8484 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
8485 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
8486 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
8487 (tdesc_s390x_linux64v2): Declare.
8488 (s390_collect_ptrace_register, s390_supply_ptrace_register)
8489 (s390_fill_gregset, s390_store_last_break): Adjust.
8490 (target_regsets): Rename to ...
8491 (s390_regsets): ... this, and make static.
8492 (s390_get_pc, s390_set_pc): Adjust.
8493 (s390_get_hwcap): New target_desc parameter, and use it.
8494 [__s390x__] (have_hwcap_s390_high_gprs): New global.
8495 (s390_arch_setup): Adjust to set the current process'es target
8496 description. Don't adjust the regmap.
8497 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
8498 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
8499 (regs_info_3264): New globals.
8500 (s390_regs_info): New function.
8501 (the_low_target): Adjust.
8502 (initialize_low_arch): New function.
8503 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
8504 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
8505 [__mips64] (init_registers_mips_linux)
8506 (init_registers_mips_dsp_linux): Delete defines.
8507 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
8508 (have_dsp): New global.
8509 (mips_read_description): New, based on mips_arch_setup.
8510 (mips_arch_setup): Reimplement.
8511 (get_usrregs_info): New function.
8512 (mips_cannot_fetch_register, mips_cannot_store_register)
8513 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
8514 (mips_fill_fpregset, mips_store_fpregset): Adjust.
8515 (target_regsets): Rename to ...
8516 (mips_regsets): ... this, and make static.
8517 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
8518 (dsp_regs_info, regs_info): New globals.
8519 (mips_regs_info): New function.
8520 (the_low_target): Adjust.
8521 (initialize_low_arch): New function.
8522 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
8523 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
8524 Declare.
8525 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
8526 (arm_read_description): New, with bits factored from
8527 arm_arch_setup.
8528 (arm_arch_setup): Reimplement.
8529 (target_regsets): Rename to ...
8530 (arm_regsets): ... this, and make static.
8531 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
8532 (arm_regs_info): New function.
8533 (the_low_target): Adjust.
8534 (initialize_low_arch): New function.
8535 * linux-m68k-low.c (tdesc_m68k): Declare.
8536 (target_regsets): Rename to ...
8537 (m68k_regsets): ... this, and make static.
8538 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
8539 (m68k_regs_info): New function.
8540 (m68k_arch_setup): New function.
8541 (the_low_target): Adjust.
8542 (initialize_low_arch): New function.
8543 * linux-sh-low.c (tdesc_sharch): Declare.
8544 (target_regsets): Rename to ...
8545 (sh_regsets): ... this, and make static.
8546 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
8547 (sh_regs_info, sh_arch_setup): New functions.
8548 (the_low_target): Adjust.
8549 (initialize_low_arch): New function.
8550 * linux-bfin-low.c (tdesc_bfin): Declare.
8551 (bfin_arch_setup): New function.
8552 (bfin_usrregs_info, regs_info): New globals.
8553 (bfin_regs_info): New function.
8554 (the_low_target): Adjust.
8555 (initialize_low_arch): New function.
8556 * linux-cris-low.c (tdesc_cris): Declare.
8557 (cris_arch_setup): New function.
8558 (cris_usrregs_info, regs_info): New globals.
8559 (cris_regs_info): New function.
8560 (the_low_target): Adjust.
8561 (initialize_low_arch): New function.
8562 * linux-cris-low.c (tdesc_crisv32): Declare.
8563 (cris_arch_setup): New function.
8564 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
8565 (cris_regs_info): New function.
8566 (the_low_target): Adjust.
8567 (initialize_low_arch): New function.
8568 * linux-m32r-low.c (tdesc_m32r): Declare.
8569 (m32r_arch_setup): New function.
8570 (m32r_usrregs_info, regs_info): New globals.
8571 (m32r_regs_info): Adjust.
8572 (initialize_low_arch): New function.
8573 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
8574 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
8575 (tic6x_usrregs_info): Forward declare.
8576 (tic6x_read_description): New function, based on ...
8577 (tic6x_arch_setup): ... this. Reimplement.
8578 (target_regsets): Rename to ...
8579 (tic6x_regsets): ... this, and make static.
8580 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
8581 (tic6x_regs_info): New function.
8582 (the_low_target): Adjust.
8583 (initialize_low_arch): New function.
8584 * linux-xtensa-low.c (tdesc_xtensa): Declare.
8585 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
8586 (target_regsets): Rename to ...
8587 (xtensa_regsets): ... this, and make static.
8588 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
8589 globals.
8590 (xtensa_arch_setup, xtensa_regs_info): New functions.
8591 (the_low_target): Adjust.
8592 (initialize_low_arch): New function.
8593 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
8594 (nios2_arch_setup): Set the current process'es tdesc.
8595 (target_regsets): Rename to ...
8596 (nios2_regsets): ... this.
8597 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
8598 (nios2_regs_info): New function.
8599 (the_low_target): Adjust.
8600 (initialize_low_arch): New function.
a261b8f5
PA
8601 * linux-aarch64-low.c (tdesc_aarch64): Declare.
8602 (aarch64_arch_setup): Set the current process'es tdesc.
8603 (target_regsets): Rename to ...
8604 (aarch64_regsets): ... this.
8605 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
8606 (aarch64_regs_info): New function.
8607 (the_low_target): Adjust.
8608 (initialize_low_arch): New function.
3aee8918
PA
8609 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
8610 globals.
8611 (target_regsets): Rename to ...
8612 (tile_regsets): ... this.
8613 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
8614 (tile_regs_info): New function.
8615 (tile_arch_setup): Set the current process'es tdesc.
8616 (the_low_target): Adjust.
8617 (initialize_low_arch): New function.
8618 * spu-low.c (tdesc_spu): Declare.
8619 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
8620 * win32-arm-low.c (tdesc_arm): Declare.
8621 (arm_arch_setup): New function.
8622 (the_low_target): Install arm_arch_setup instead of
8623 init_registers_arm.
8624 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
8625 (init_windows_x86): Rename to ...
8626 (i386_arch_setup): ... this. Set `win32_tdesc'.
8627 (the_low_target): Adjust.
8628 * win32-low.c (win32_tdesc): New global.
8629 (child_add_thread): Don't create the thread cache here.
8630 (do_initial_child_stuff): Set the new process'es tdesc.
8631 * win32-low.h (struct target_desc): Forward declare.
8632 (win32_tdesc): Declare.
8633 * lynx-i386-low.c (tdesc_i386): Declare global.
8634 (lynx_i386_arch_setup): Set `lynx_tdesc'.
8635 * lynx-low.c (lynx_tdesc): New global.
8636 (lynx_add_process): Set the new process'es tdesc.
8637 * lynx-low.h (struct target_desc): Forward declare.
8638 (lynx_tdesc): Declare global.
8639 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
8640 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
8641 * nto-low.c (nto_tdesc): New global.
8642 (do_attach): Set the new process'es tdesc.
8643 * nto-low.h (struct target_desc): Forward declare.
8644 (nto_tdesc): Declare.
8645 * nto-x86-low.c (tdesc_i386): Declare.
8646 (nto_x86_arch_setup): Set `nto_tdesc'.
8647
b1fbec62
GB
86482013-06-04 Gary Benson <gbenson@redhat.com>
8649
8650 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
8651 to qSupported response when appropriate.
8652 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
8653 with nonzero-length annex.
8654 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
8655 arguments supplied in annex.
8656
d1ec4ce7
DE
86572013-05-31 Doug Evans <dje@google.com>
8658
ac44adcb 8659 PR server/15594
d1ec4ce7
DE
8660 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
8661 64 bits in 64-cross-32 environment.
8662
9b25f2d3
PA
86632013-05-28 Pedro Alves <palves@redhat.com>
8664
8665 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
8666 (aarch64-without-fpu.c): Delete rule.
8667 * configure.srv (aarch64*-*-linux*): Remove references to
8668 aarch64-without-fpu.o and aarch64-without-fpu.xml.
8669 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
8670 declaration.
8671
6740dc9c
PA
86722013-05-24 Pedro Alves <palves@redhat.com>
8673
8674 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
8675 instead of strchr/decode_address. Error if the range isn't split
8676 with a ','. Don't assume there's be a ':' in the action.
8677
c2d6af84
PA
86782013-05-23 Yao Qi <yao@codesourcery.com>
8679 Pedro Alves <palves@redhat.com>
8680
8681 * linux-low.c (lwp_in_step_range): New function.
8682 (linux_wait_1): If the thread was range stepping and stopped
8683 outside the stepping range, report the stop to GDB. Otherwise,
8684 continue stepping. Add range stepping debug output.
8685 (linux_set_resume_request): Copy the step range from the resume
8686 request to the lwp.
8687 (linux_supports_range_stepping): New.
8688 (linux_target_ops) <supports_range_stepping>: Set to
8689 linux_supports_range_stepping.
8690 * linux-low.h (struct linux_target_ops)
8691 <supports_range_stepping>: New field.
8692 (struct lwp_info) <step_range_start, step_range_end>: New fields.
8693 * linux-x86-low.c (x86_supports_range_stepping): New.
8694 (the_low_target) <supports_range_stepping>: Set to
8695 x86_supports_range_stepping.
8696 * server.c (handle_v_cont): Handle 'r' action.
8697 (handle_v_requests): Append ";r" if the target supports range
8698 stepping.
8699 * target.h (struct thread_resume) <step_range_start,
8700 step_range_end>: New fields.
8701 (struct target_ops) <supports_range_stepping>:
8702 New field.
8703 (target_supports_range_stepping): New macro.
8704
58794e1a
JB
87052013-05-17 Joel Brobecker <brobecker@adacore.com>
8706
8707 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
8708 confusion in comment.
8709
d631c5a7
JB
87102013-05-17 Joel Brobecker <brobecker@adacore.com>
8711
8712 * lynx-low.c (struct process_info_private): New type.
8713 (lynx_add_process): New function.
8714 (lynx_create_inferior, lynx_attach): Replace calls to
8715 add_process by calls to lynx_add_process.
8716 (lynx_resume): If PTID is null, then try using
8717 current_process()->private->last_wait_event_ptid.
8718 Add comments.
8719 (lynx_clear_inferiors): Delete. The contents of that function
8720 has been inlined in lynx_mourn;
8721 (lynx_wait_1): Save the ptid in the process's private data.
8722 (lynx_mourn): Free the process' private data. Replace call
8723 to lynx_clear_inferiors by call to clear_inferiors.
8724
96f7a20f
YQ
87252013-05-17 Yao Qi <yao@codesourcery.com>
8726
8727 * i386-low.c (i386_length_and_rw_bits): Move the comment to
8728 the right place.
8729
db0dfaa0
LM
87302013-05-16 Luis Machado <lgustavo@codesourcery.com>
8731
8732 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
8733 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
8734 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
8735 PT_TEXT_END_ADDR guards. Update comments.
8736 (linux_target_op) <read_offsets>: Conditionally define to
8737 linux_read_offsets if the target is UCLIBC and if it defines
8738 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
8739
68f5f838
SL
87402013-05-06 Sandra Loosemore <sandra@codesourcery.com>
8741 Andrew Jenner <andrew@codesourcery.com>
8742
8743 * Makefile.in (SFILES): Add linux-nios2-low.c.
8744 (clean): Add action to delete nios2-linux.c.
8745 (nios2-linux.c): New rule.
8746 * configure.srv: Add nios2*-*-linux*.
8747 * linux-nios2-low.c: New.
8748
1ebff1fd
HAQ
87492013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
8750
8751 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
8752
f6150862
HZ
87532013-04-25 Hui Zhu <hui@codesourcery.com>
8754
8755 PR gdb/15186
f6150862
HZ
8756 * ax.c (ax_printf): Add fflush.
8757
614c279d
TT
87582013-04-22 Tom Tromey <tromey@redhat.com>
8759
8760 * Makefile.in (SFILES): Add filestuff.c.
8761 (OBS): Add filestuff.o.
8762 (filestuff.o): New target.
8763 * config.in, configure: Rebuild.
8764 * configure.ac: Check for fdwalk, pipe2.
8765
7d4e5717
PA
87662013-04-17 Pedro Alves <palves@redhat.com>
8767
8768 * configure.ac (USE_THREAD_DB): Delete variable.
8769 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
8770 Don't AC_SUBST USE_THREAD_DB.
8771 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
8772 * config.in, configure: Regenerate.
8773
d5c93e41
PA
87742013-04-16 Pedro Alves <palves@redhat.com>
8775
8776 * linux-low.h (struct lwp_info) <thread_known>: Move under
8777 the USE_THREAD_DB #ifdef.
8778
04f5fe89
PA
87792013-04-16 Pedro Alves <palves@redhat.com>
8780
8781 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
8782 (linux-low.o): Delete rule.
8783 * linux-low.h: Always include "gdb_thread_db.h" instead of
8784 conditionally including thread_db.h.
8785 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
8786 HAVE_THREAD_DB_H.
8787
480b27bf
JK
87882013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
8789
8790 * Makefile.in (install-only): Fix make install regression.
8791
43662968
JK
87922013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
8793
8794 Convert man pages to texinfo, new gdbinit.5 texinfo page.
8795 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
8796 installation.
8797 * gdbserver.1: Remove.
8798
3e74e146
PA
87992013-03-22 Pedro Alves <palves@redhat.com>
8800
8801 * linux-low.c (handle_extended_wait): Don't call
8802 linux_enable_event_reporting.
8803
a8347a2a
TT
88042013-03-15 Tony Theodore <tonyt@logyst.com>
8805
8806 PR build/9098:
8807 * Makefile.in (SHELL): Use @SHELL@.
8808
eeb56fa7
SDJ
88092013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
8810
8811 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
8812 compiler warning.
8813
4fa7e2ff
JB
88142013-03-13 Joel Brobecker <brobecker@adacore.com>
8815
8816 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
8817 Remove extraneous NULL element.
8818
8ddb1965
YQ
88192013-03-13 Yao Qi <yao@codesourcery.com>
8820
8821 * tracepoint.c (traceframe_read_tsv): Look for the last matched
8822 'V' block in trace frame.
8823
9accd112
MM
88242013-03-11 Markus Metzger <markus.t.metzger@intel.com>
8825
8826 * target.h (struct target_ops): Add btrace ops.
8827 (target_supports_btrace): New macro.
8828 (target_enable_btrace): New macro.
8829 (target_disable_btrace): New macro.
8830 (target_read_btrace): New macro.
8831 * gdbthread.h (struct thread_info): Add btrace field.
8832 * server.c: Include btrace-common.h.
8833 (handle_btrace_general_set): New function.
8834 (handle_btrace_enable): New function.
8835 (handle_btrace_disable): New function.
8836 (handle_general_set): Call handle_btrace_general_set.
8837 (handle_qxfer_btrace): New function.
8838 (struct qxfer qxfer_packets[]): Add btrace entry.
8839 * inferiors.c (remove_thread): Disable btrace.
8840 * linux-low: Include linux-btrace.h.
8841 (linux_low_enable_btrace): New function.
8842 (linux_low_read_btrace): New function.
8843 (linux_target_ops): Add btrace ops.
8844 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
8845 Add srv_linux_btrace=yes.
8846 (x86_64-*-linux*): Add linux-btrace.o.
8847 Add srv_linux_btrace=yes.
8848 * configure.ac: Define HAVE_LINUX_BTRACE.
8849 * config.in: Regenerated.
8850 * configure: Regenerated.
8851
5cc22e4c
MM
88522013-03-11 Markus Metzger <markus.t.metzger@intel.com>
8853
8854 * server.c (handle_qxfer): Preserve error message if -3 is
8855 returned.
8856 (qxfer): Document the -3 return value.
8857
7c97f91e
MM
88582013-03-11 Markus Metzger <markus.t.metzger@intel.com>
8859
8860 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
8861 (linux_btrace_h): New variable.
8862 (linux-btrace.o): New rule.
8863
be9a119c 88642013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
8865 Hafiz Abid Qadeer <abidh@codesourcery.com>
8866
8867 * tracepoint.c (trace_buffer_size): New global.
8868 (DEFAULT_TRACE_BUFFER_SIZE): New define.
8869 (init_trace_buffer): Change to one-argument function. Allocate
8870 trace buffer memory.
8871 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
8872 handle QTBuffer:size packet.
8873 (cmd_bigqtbuffer_size): New function.
8874 (initialize_tracepoint): Call init_trace_buffer with
8875 DEFAULT_TRACE_BUFFER_SIZE.
8876 * server.c (handle_query): Add QTBuffer:size in the
8877 supported packets.
8878
e64f7499
YQ
88792013-03-07 Yao Qi <yao@codesourcery.com>
8880
8881 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
8882 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
8883 of -1.
8884 (cmd_qtsp): Adjust condition. Do post increment.
8885 Set cur_action and cur_step_action back to 0.
8886
f0ae6fc3
PA
88872013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
8888
8889 PR server/15236
8890 * linux-low.c (linux_write_memory): Return early success if LEN is
8891 zero.
8892
b5b0b0af
CV
88932013-03-05 Corinna Vinschen <vinschen@redhat.de>
8894
334ad4a8 8895 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 8896
589bc927
TT
88972013-02-28 Tom Tromey <tromey@redhat.com>
8898
8899 * configure.ac: Invoke AC_SYS_LARGEFILE.
8900 * configure, config.in: Rebuild.
8901
dfe07582
CV
89022013-02-28 Corinna Vinschen <vinschen@redhat.com>
8903
8904 * win32-low.c: Throughout, fix format strings and casts of
8905 printf-like functions to avoid type related warnings on all
8906 platforms.
8907 (get_child_debug_event): Print dwDebugEventCode as hex since
8908 that's how it's usually documented.
8909
736cd585
YQ
89102013-02-28 Yao Qi <yao@codesourcery.com>
8911
8912 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
8913 pulongest.
8914
e1f58301
JW
89152013-02-27 Jiong Wang <jiwang@tilera.com>
8916
8917 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
8918 (reg-tilegx32.c): New rule.
8919 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
8920 * linux-tile-low.c (tile_arch_setup): New function. Invoke
8921 different register info initializer according to elf class.
8922 (init_registers_tilgx32): New function. The tilegx32 register info
8923 initializer.
8924 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
8925 (tile_store_gregset): Likewise.
8926
d171ca78
YQ
89272013-02-27 Yao Qi <yao@codesourcery.com>
8928
8929 * server.c (process_point_options): Print debug message when
8930 debug_threads is true.
8931
282bbdf3
YQ
89322013-02-26 Yao Qi <yao@codesourcery.com>
8933
8934 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
8935
aca22551
PA
89362013-02-19 Pedro Alves <palves@redhat.com>
8937 Kai Tietz <ktietz@redhat.com>
8938
8939 PR gdb/15161
8940
8941 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
8942 instead of strtoul to extract address from packet.
8943 (process_serial_event) <'z'>: Likewise.
8944
4f3cee1c
YQ
89452013-02-18 Yao Qi <yao@codesourcery.com>
8946
8947 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
8948
8e1d55a3
PA
89492013-02-14 Pedro Alves <palves@redhat.com>
8950
8951 Plug memory leak.
8952
8953 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
8954 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
8955
458820da
PA
89562013-02-14 Pedro Alves <palves@redhat.com>
8957
8958 * tracepoint.c (cmd_qtdpsrc): Use savestring.
8959
baea0dae
PA
89602013-02-14 Pedro Alves <palves@redhat.com>
8961
8962 * tracepoint.c (save_string): Delete.
8963 (add_tracepoint_action): Use savestring instead of save_string.
8964
0b1afbb3
PA
89652013-02-12 Pedro Alves <palves@redhat.com>
8966
8967 * linux-xtensa-low.c: Ditto.
8968 * xtensa-xtregs.c: Ditto.
8969
8a4ac37e
PA
89702013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
8971
8972 * thread-db.c (thread_db_get_tls_address): NULL pointer check
8973 thread_db.
8974
148de6bb
MS
89752013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
8976
8977 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
8978 aarch64_num_wp_regs and aarch64_num_bp_regs to
8979 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
8980
55fac6e0
MS
89812013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
8982
8983 * linux-aarch64-low.c (ps_get_thread_area): Replace
8984 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
8985
176eb98c
MS
89862013-02-04 Jim MacArthur <jim.macarthur@arm.com>
8987 Marcus Shawcroft <marcus.shawcroft@arm.com>
8988 Nigel Stephens <nigel.stephens@arm.com>
8989 Yufeng Zhang <yufeng.zhang@arm.com>
8990
8991 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
8992 (aarch64.c, aarch64-without-fpu.c): New targets.
8993 * configure.srv (aarch64*-*-linux*): New.
8994 * linux-aarch64-low.c: New file.
8995
56f7af9c
MS
89962013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
8997
43aaf8b6 8998 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
8999 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
9000 (dequeue_one_deferred_signal, linux_resume_one_thread)
9001 (fetch_register, linux_write_memory, linux_enable_event_reporting)
9002 (linux_tracefork_grandchild, linux_test_for_tracefork)
9003 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
9004 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
9005 where the argument is 0.
9006
60f662b0
YQ
90072013-01-25 Yao Qi <yao@codesourcery.com>
9008
9009 * event-loop.c: Include "queue.h".
9010 (gdb_event_p): New typedef.
9011 (struct gdb_event) <next_event>: Remove.
9012 (event_queue): Change to QUEUE(gdb_event_p).
9013 (async_queue_event): Remove.
9014 (gdb_event_xfree): New.
9015 (initialize_event_loop): New.
9016 (process_event): Use API from QUEUE.
9017 (wait_for_event): Likewise.
9018 * server.c (main): Call initialize_event_loop.
9019 * server.h (initialize_event_loop): Declare.
9020
5ae4861a
YQ
90212013-01-18 Yao Qi <yao@codesourcery.com>
9022
9023 * ax.h (struct eval_agent_expr_context): New.
9024 (gdb_eval_agent_expr): Update declaration.
9025 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
9026 TFRAME. Add new argument CTX.
9027 * server.h (struct eval_agent_expr_context): Declare.
9028 (agent_mem_read, agent_tsv_read): Update declaration.
9029 (agent_mem_read_string): Likewise.
9030 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
9031 (add_traceframe_block): Add new argument TPOINT.
9032 Increase TPOINT->traceframe_usage.
9033 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
9034 eval_tracepoint_agent_expr.
9035 (condition_true_at_tracepoint): Likewise.
9036 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
9037 (agent_mem_read_string, agent_tsv_read): Likewise.
9038
85e00e85
YQ
90392013-01-16 Yao Qi <yao@codesourcery.com>
9040
9041 * linux-low.c (linux_resume_one_lwp): Don't check
9042 'lwp->bp_reinsert != 0'.
9043
4039cf45
JB
90442013-01-07 Joel Brobecker <brobecker@adacore.com>
9045 Pedro Alves <palves@redhat.com>
9046
9047 * lynx-low.c (ptrace_request_to_str): Define a temporary
9048 macro and use it to simplify this function's implementation.
9049
9044dee2
JB
90502013-01-07 Joel Brobecker <brobecker@adacore.com>
9051
9052 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
9053 sets errno.
9054
e6352c8f
JB
90552013-01-07 Joel Brobecker <brobecker@adacore.com>
9056
9057 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
9058
50681a27
JB
90592013-01-07 Joel Brobecker <brobecker@adacore.com>
9060
9061 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
9062
3f6e77ef
JB
90632013-01-07 Joel Brobecker <brobecker@adacore.com>
9064
9065 * lynx-low.c (lynx_resume): Use the resume_info parameter
9066 to determine the ptid for the lynx_ptrace call, unless
9067 it is equal to minus_one_ptid, in which case we use the
9068 ptid of the current_inferior.
9069 (lynx_wait_1): After having received a thread create/exit
9070 event, resume the inferior's execution using the signaling
9071 thread's ptid, rather than the old ptid.
9072
7fda33ae
JB
90732013-01-07 Joel Brobecker <brobecker@adacore.com>
9074
9075 * lynx-low.c (lynx_resume): Delete variable ret.
9076
b9786c74
JB
90772013-01-01 Joel Brobecker <brobecker@adacore.com>
9078
9079 * gdbreplay.c (gdbreplay_version): Update copyright year.
9080 * server.c (gdbserver_version): Likewise.
9081
8b93d60f
JB
90822012-12-17 Joel Brobecker <brobecker@adacore.com>
9083
9084 * lynx-low.c (lynx_wait_1): Add debug trace before adding
9085 new thread.
9086
037335a7
JB
90872012-12-17 Joel Brobecker <brobecker@adacore.com>
9088
9089 * lynx-low.c (ptrace_request_to_str): Add handling for
9090 PTRACE_GETTRACESIG.
9091
52d4cbd8
JB
90922012-12-17 Joel Brobecker <brobecker@adacore.com>
9093
9094 * lynx-low.c (lynx_attach): Delete variable new_process.
9095
ab8f6ca9
JB
90962012-12-17 Joel Brobecker <brobecker@adacore.com>
9097
9098 * lynx-low.c (lynx_create_inferior): Delete variable
9099 new_process.
9100
78cbc024
JB
91012012-12-17 Joel Brobecker <brobecker@adacore.com>
9102
9103 * lynx-low.c (ptrace_request_to_str): Do not handle
9104 PTRACE_GETTHREADLIST if this macro does not exist.
9105
14a00470
YQ
91062012-12-15 Yao Qi <yao@codesourcery.com>
9107
9108 * Makefile.in (OBS): Add notif.o.
9109 * notif.c, notif.h: New.
9110 * server.c: Include "notif.h".
9111 (struct vstop_notif) <next>: Remove.
9112 <base>: New field.
9113 (queue_stop_reply): Update.
9114 (push_event, send_next_stop_reply): Remove.
9115 (discard_queued_stop_replies): Update.
9116 (notif_stop): New variable.
9117 (handle_v_stopped): Remove.
9118 (handle_v_requests): Don't call handle_v_stopped. Call
9119 handle_ack_notif instead.
9120 (queue_stop_reply_callback): Call notif_event_enque instead
9121 of queue_stop_reply.
9122 (handle_status): Don't call send_next_stop_reply, call
9123 notif_write_event instead.
9124 (kill_inferior_callback): Likewise.
9125 (detach_or_kill_inferior_callback): Likewise.
9126 (main): Call initialize_notif.
9127 (process_serial_event): Call QUEUE_is_empty.
9128 (handle_target_event): Call notif_push instead of push event.
9129 * server.h (push_event): Remove declaration.
9130
61c125b9
TT
91312012-12-10 Tom Tromey <tromey@redhat.com>
9132
9133 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
9134 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
9135 macros.
9136 (.c.o): Rewrite.
9137 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
9138 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
9139 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
9140 (amd64-linux-ipa.o, ax.o): Rewrite.
9141 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
9142 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
9143 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
9144 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
9145 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
9146 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
9147 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
9148 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
9149 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
9150 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
9151 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
9152 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
9153 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
9154 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
9155 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
9156 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
9157 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
9158 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
9159 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
9160 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
9161 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
9162 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
9163 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
9164 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
9165 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
9166 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
9167 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
9168 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
9169 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
9170 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
9171 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
9172 (reg-tilegx.o): Remove.
9173 (all_object_files): New macro.
9174 Include .deps files.
9175 * aclocal.m4, configure: Rebuild.
9176 * acinclude.m4: Include depstand.m4, lead-dot.m4.
9177 * configure.ac: Invoke ZW_CREATE_DEPDIR,
9178 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
9179
e90e9ad9
TT
91802012-12-05 Tom Tromey <tromey@redhat.com>
9181
9182 PR gdb/14917:
9183 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
9184
02d403bf 91852012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
9186
9187 * configure.ac: Check for linux/perf_event.h.
9188 * config.in: Regenerated.
9189 * configure: Regenerated.
9190
0270a750
PA
91912012-11-26 Maxime Villard <rustyBSD@gmx.fr>
9192
9193 * hostio.c (handle_readlink): Decrease buffer size
9194 parameter passed to readlink by one byte.
9195
8c29b58e
YQ
91962012-11-26 Yao Qi <yao@codesourcery.com>
9197
9198 * configure.ac (build_warnings): Append '-Wempty-body'.
9199 * configure: Regenerated.
9200 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
9201 body.
9202
8bdce1ff
PM
92032012-11-15 Pierre Muller <muller@sourceware.org>
9204
9205 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
9206 * config.in: Regenerate.
9207 * configure: Regenerate.
9208 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
9209 Use "gdb_wait.h" header instead of <sys/wait.h> header.
9210 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9211 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
9212 header.
9213 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
9214 instead of <sys/wait.h> header.
9215 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9216
02d403bf 92172012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
9218
9219 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
9220 (various make rules): Remove -DGDBSERVER
9221
fbd5db48
YQ
92222012-11-09 Yao Qi <yao@codesourcery.com>
9223
9224 * spu-low.c (current_ptid): Move it to ..
9225 * gdbthread.h: ... here. New.
9226 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
9227 * server.c (myresume, process_serial_event): Likewise.
9228 * thread-db.c (thread_db_find_new_threads): Likewise.
9229 * tracepoint.c (run_inferior_command): Likewise.
9230
b3dc46ff
AB
92312012-10-01 Andrew Burgess <aburgess@broadcom.com>
9232
9233 * server.c (handle_search_memory_1): Include access length in
9234 warning message.
9235
07c04788
HPN
92362012-09-05 Michael Brandt <michael.brandt@axis.com>
9237
9238 * linux-crisv32-low.c: Fix compile errors.
9239
918d227b
YQ
92402012-09-04 Yao Qi <yao@codesourcery.com>
9241
9242 * tracepoint.c (cmd_qtsv): Adjust debug message.
9243 Don't check CUR_TPOINT.
9244
18c1b81a
YQ
92452012-08-28 Yao Qi <yao@codesourcery.com>
9246
9247 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
9248 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
9249 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
9250 Remove declarations of xmalloc, xreallloc, xstrdup and
9251 freeargv.
9252 * Makefile.in (libiberty_h): New.
9253 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
9254 (linux-bfin-low.o): Append dependency 'libiberty.h'.
9255
dc82f37b
YQ
92562012-08-23 Yao Qi <yao@codesourcery.com>
9257
9258 * server.h: Remove declaration of 'xsnprintf'.
9259
406b1477
KS
92602012-08-22 Keith Seitz <keiths@redhat.com>
9261
9262 * server.h: Include build-gnulib-gbserver/config.h.
9263 * gdbreplay.c: Likewise.
9264
e6712ff1
DE
92652012-08-08 Doug Evans <dje@google.com>
9266
9267 * Makefile.in (SFILES): Add gdb_vecs.c.
9268 (OBS): Add gdb_vecs.o.
9269 (gdb_vecs_h, host_defs_h): New variables.
9270 (thread-db.o): Add $(gdb_vecs_h) dependency.
9271 (gdb_vecs.o): New rule.
9272 * thread-db.c: #include "gdb_vecs.h".
9273 (thread_db_load_search): Use a vector to iterate over path elements.
9274 Handle text appearing after "$pdir".
9275
9276 * configure.ac: Add check for strstr.
9277 * config.in: Regenerate.
9278 * configure: Regenerate.
9279
7c3270ae
UW
92802012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
9281
9282 * hostio.c (handle_pread): If pread fails, fall back to attempting
9283 lseek/read.
9284 (handle_pwrite): Likewise for pwrite.
9285
b62e2b27
UW
92862012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
9287
9288 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
9289 between unsupported TYPE and unimplementable ADDR/LEN combination.
9290 (arm_insert_point): Act on new return value.
9291
78a99e91
PA
92922012-07-31 Pedro Alves <palves@redhat.com>
9293
9294 * server.c (process_point_options): Only skip tokens if we find
9295 one that is unrecognized. Don't treat 'X' specially while
9296 skipping unrecognized tokens.
9297
fcf303ab
UW
92982012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
9299
9300 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
9301 to 4-byte-align HW breakpoint addresses for Thumb.
9302
7255706c
YQ
93032012-07-27 Yao Qi <yao@codesourcery.com>
9304
9305 PR remote/14161.
9306
9307 * server.h: Declare gdb_agent_about_to_close.
9308 * target.c (kill_inferior): Include "agent.h".
9309 New. Send command 'kill'.
9310 * target.h (kill_inferior): Removed macro.
9311 * tracepoint.c (gdb_agent_about_to_close): New.
9312 (gdb_agent_helper_thread): Handle command 'close'.
9313 Wait endlessly until the inferior stops.
9314 Install gdb_agent_remove_socket to atexit hook.
9315 (agent_socket_name): New static variable.
9316 (gdb_agent_socket_init): Replace local variable 'name' with
9317 'agent_socket_name'.
9318 (gdb_agent_remove_socket): New.
9319
5a3f286f
YQ
93202012-07-27 Yao Qi <yao@codesourcery.com>
9321
9322 * server.c (process_point_options): Stop at 'X' when parsing.
9323
961bd387
ME
93242012-07-19 Michael Eager <eager@eagercon.com>
9325
a261b8f5 9326 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
9327 to hw_execute.
9328 * linux-x86-low.c (x86_insert_point, x86_remove_point):
9329 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
9330 hardware breakpoint.
9331
aa7c7447
JK
93322012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9333
9334 * gdbserver/linux-low.c (initialize_low): Call
9335 linux_ptrace_init_warnings.
9336
7f216e7c
DE
93372012-07-02 Doug Evans <dje@google.com>
9338
9339 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
9340 pointer to int.
9341
d3ce09f5
SS
93422012-07-02 Stan Shebs <stan@codesourcery.com>
9343
9344 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
9345 (ax.o): Add it to build rule.
9346 (ax-ipa.o): Ditto.
9347 (OBS): Add format.o.
9348 (IPA_OBS): Add format.o.
9349 * server.c (handle_query): Claim support for breakpoint commands.
9350 (process_point_options): Add command case.
9351 (process_serial_event): Leave running if there are printfs in
9352 effect.
9353 * mem-break.h (any_persistent_commands): Declare.
9354 (add_breakpoint_commands): Declare.
9355 (gdb_no_commands_at_breakpoint): Declare.
9356 (run_breakpoint_commands): Declare.
9357 * mem-break.c (struct point_command_list): New struct.
9358 (struct breakpoint): New field command_list.
9359 (any_persistent_commands): New function.
9360 (add_commands_to_breakpoint): New function.
9361 (add_breakpoint_commands): New function.
9362 (gdb_no_commands_at_breakpoint): New function.
9363 (run_breakpoint_commands): New function.
9364 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
9365 locally.
9366 * ax.c: Include format.h.
9367 (ax_printf): New function.
9368 (gdb_eval_agent_expr): Add printf opcode.
9369
2f8f6aed
YQ
93702012-06-13 Yao Qi <yao@codesourcery.com>
9371
9372 * server.c (start_inferior): Remove duplicated writes to fields
9373 'last_resume_kind' and 'last_status' of 'current_inferior'.
9374
0c9070b3
YQ
93752012-06-12 Yao Qi <yao@codesourcery.com>
9376 Pedro Alves <palves@redhat.com>
9377
9378 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
9379 comment.
9380 * server.c (handle_v_cont): Extend comment.
9381
c52daf70
YQ
93822012-06-11 Yao Qi <yao@codesourcery.com>
9383
9384 * linux-low.c (linux_attach): Add 'static'.
9385
d38bbb0a
YQ
93862012-06-06 Yao Qi <yao@codesourcery.com>
9387
9388 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
9389
89dc0afd
JK
93902012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
9391
9392 Fix gcc -flto compilation warning.
9393 * server.c (main): Make variable multi_mode and attach volatile.
9394
75f62ce7
TJB
93952012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9396
9397 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
9398 if the platform doesn't know about it.
9399
65f479b6
PA
94002012-05-30 Jeff Kenton <jkenton@tilera.com>
9401
9402 * Makefile.in (SFILES): Add linux-tile-low.c.
9403 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
9404 * configure.srv: Handle tilegx-*-linux*.
9405 * linux-tile-low.c: New file.
9406
0c5bf5a9
JK
94072012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9408
9409 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
9410
a493e3e2
PA
94112012-05-24 Pedro Alves <palves@redhat.com>
9412
9413 PR gdb/7205
9414
43aaf8b6 9415 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 9416
2ea28649
PA
94172012-05-24 Pedro Alves <palves@redhat.com>
9418
9419 PR gdb/7205
9420
9421 Replace target_signal with gdb_signal throughout.
9422
8d409d16
MR
94232012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
9424
9425 * linux-low.c (linux_store_registers): Avoid the copying sequence
9426 when no data has been retrieved by ptrace.
9427
23512c01
MGD
94282012-05-22 Will Deacon <will.deacon@arm.com>
9429
9430 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
9431 Include asm/ptrace.h.
9432 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
9433 already defined.
9434
4934b29e
MR
94352012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
9436
9437 * linux-low.c (linux_store_registers): Don't re-retrieve data
9438 with ptrace that has already been obtained from /proc. Always
9439 copy any data retrieved with ptrace to the buffer supplied.
9440
bde24c0a
PA
94412012-05-11 Yao Qi <yao@codesourcery.com>
9442 Pedro Alves <palves@redhat.com>
9443
9444 * linux-low.c (enum stopping_threads_kind): New.
9445 (stopping_threads): Change type to `enum stopping_threads_kind'.
9446 (handle_extended_wait): If stopping and suspending threads, leave
9447 the new_lwp suspended too.
9448 (linux_wait_for_event): Adjust.
9449 (stop_all_lwps): Set `stopping_threads' to
9450 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
9451 whether we're suspending threads or just stopping them. Assert no
9452 recursion happens.
9453
623b6bdf
YQ
94542012-04-29 Yao Qi <yao@codesourcery.com>
9455
9456 * server.h: Move some code to ...
9457 * gdbthread.h: ... here. New.
9458 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
9459 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
9460 (nto-low.o, win32-low.o): Likewise.
9461 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
9462 * regcache.c, remote-utils.c, server.c: Likewise.
9463 * target.c, tracepoint.c, win32-low.c: Likewise.
9464
f15f9948
TJB
94652012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9466
9467 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
9468 (PTRACE_ARG4_TYPE): Likewise.
9469 (PTRACE_XFER_TYPE): Likewise.
9470 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
9471 ptrace to PTRACE_ARG3_TYPE.
9472 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
9473 (PTRACE_ARG4_TYPE): Likewise.
9474 (PTRACE_XFER_TYPE): Likewise.
9475 (linux_detach_one_lwp): Cast fourth argument of
9476 ptrace to long then PTRACE_ARG4_TYPE.
9477 (regsets_fetch_inferior_registers): Cast third argument of
9478 ptrace to long then PTRACE_ARG3_TYPE.
9479 (regsets_store_inferior_registers): Likewise.
9480
38ea300a
PA
94812012-04-20 Pedro Alves <palves@redhat.com>
9482
9483 * configure: Regenerate.
9484
c971b7fa
PA
94852012-04-19 Pedro Alves <palves@redhat.com>
9486
43aaf8b6 9487 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 9488 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
9489 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
9490 (all, install-only, uninstall, clean-info, all-lib, clean): No
9491 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
9492 (maintainer-clean realclean distclean): Use subdir_do.
9493 (subdir_do): New.
9494 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 9495 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
9496 * acinclude.m4: Include acx_configure_dir.m4.
9497 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
9498 calls. Call AC_PROG_RANLIB. Configure gnulib using
9499 ACX_CONFIGURE_DIR.
9500 (GNULIB): New.
9501 (GNULIB_STDINT_H): Adjust.
9502 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
9503 * gdbreplay.c: Include build-gnulib/config.h.
9504 * server.h: Likewise.
9505 * aclocal.m4: Regenerate.
9506 * config.in: Regenerate.
9507 * configure: Regenerate.
c971b7fa 9508
809277f8
PA
95092012-04-19 Pedro Alves <palves@redhat.com>
9510
9511 * Makefile.in (LIBGNU, INCGNU): Adjust.
9512 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
9513 (all, install-only, uninstall, clean-info, all-lib, clean)
9514 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
9515 * configure.ac: Adjust AC_OUTPUT output.
9516 * aclocal.m4: Regenerate.
9517 * configure: Regenerate.
9518
fd9bb8b8
PA
95192012-04-19 Pedro Alves <palves@redhat.com>
9520
9521 * Makefile.in (generated_files): New.
9522 (server_h): Remove the explicit dependency on config.h, and depend
9523 on $generated_files.
9524
1c298c66
PA
95252012-04-19 Pedro Alves <palves@redhat.com>
9526
9527 * Makefile.in (INCGNU): Add -Ignulib.
9528
57c4b50b
PA
95292012-04-19 Pedro Alves <palves@redhat.com>
9530
9531 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
9532 (INCGNU): ... this, and spell out -I here.
9533 (GNULIB_LIB): Rename to ...
9534 (LIBGNU): ... this.
9535 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
9536
1030e047
PA
95372012-04-19 Pedro Alves <palves@redhat.com>
9538
9539 * config.in: Regenerate.
9540
447d4319
PA
95412012-04-19 Pedro Alves <palves@redhat.com>
9542
9543 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
9544 * server.h (memmem): Remove declaration.
9545 * config.in: Regenerate.
9546 * configure: Regenerate.
9547
aad9eab9
YQ
95482012-04-19 Yao Qi <yao@codesourcery.com>
9549
9550 * Makefile.in (SFILES): Add common/vec.c.
9551 (OBS): Add vec.o.
9552 (vec.o): New rule.
9553
3e10640f
YQ
95542012-04-19 Yao Qi <yao@codesourcery.com>
9555
9556 * remote-utils.c (prepare_resume_reply): Replace with macro
9557 target_core_of_thread.
9558 * server.c (handle_qxfer_threads_proper): Likewise.
9559 * target.h (traget_core_of_thread): New macro.
9560
71622373
PA
95612012-04-18 Pedro Alves <palves@redhat.com>
9562
9563 * aclocal.m4: Regenerate.
9564 * configure: Regenerate.
9565
80d26939
YQ
95662012-04-16 Yao Qi <yao@codesourcery.com>
9567
9568 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
9569 duplicated on address.
9570
42476b70
YQ
95712012-04-16 Yao Qi <yao@codesourcery.com>
9572
9573 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
9574 (struct tracepoint_action_ops) <send>: New field.
9575 (m_tracepoint_action_send, r_tracepoint_action_send): New.
9576 (agent_expr_send, x_tracepoint_action_send): New.
9577 (l_tracepoint_action_send): New.
9578 (cmd_qtdp): Download and install tracepoint
9579 according to `use_agent'.
9580 (run_inferior_command): Add one more parameter `len'.
9581 Update callers.
9582 (tracepoint_send_agent): New.
9583 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
9584
7bc83639
YQ
95852012-04-16 Yao Qi <yao@codesourcery.com>
9586
9587 * tracepoint.c (download_tracepoints): Moved to ...
9588 (cmd_qtstart): ... here.
9589
5f18041e
YQ
95902012-04-14 Yao Qi <yao@codesourcery.com>
9591
9592 * tracepoint.c: Include inttypes.h.
9593 (struct collect_memory_action): Use sized types.
9594 (struct tracepoint): Likewise.
9595 (cmd_qtdp, stop_tracing): Update print specifiers.
9596 (cmd_qtp, response_tracepoint): Likewise.
9597 (collect_data_at_tracepoint): Likewise.
9598 (collect_data_at_step): Likewise.
9599
55a8c076
YQ
96002012-04-14 Yao Qi <yao@codesourcery.com>
9601
9602 Import gnulib module inttypes.
9603 * aclocal.m4, config.in, configure: Regenerated.
9604
dc750257
YQ
96052012-04-14 Yao Qi <yao@codesourcery.com>
9606
9607 * Makefile.in (maintainer-clean, realclean, distclean): Remove
9608 Makefile and config.status at last.
9609
0ab5faf9
YQ
96102012-04-13 Yao Qi <yao@codesourcery.com>
9611
9612 * tracepoint.c: Include stdint.h unconditionally.
9613
18f5fd81
TJB
96142012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9615
9616 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
9617 on BFD_HAVE_SYS_PROCFS_TYPE.
9618 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
9619 * configure: Regenerate.
9620 * config.in: Likewise.
9621
4d47af5c
L
96222012-04-13 H.J. Lu <hongjiu.lu@intel.com>
9623
9624 * Makefile.in (clean): Also remove x32.c x32-linux.c
9625 x32-avx.c x32-avx-linux.c.
9626 (x32.o): New target.
9627 (x32.c): Likewise.
9628 (x32-linux.o): Likewise.
9629 (x32-linux.c): Likewise.
9630 (x32-avx.o): Likewise.
9631 (x32-avx.c): Likewise.
9632 (x32-avx-linux.o): Likewise.
9633 (x32-avx-linux.c): Likewise.
9634
9635 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
9636 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
9637 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
9638 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
9639 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
9640 i386/x32-avx-linux.xml.
9641
9642 * linux-x86-low.c (init_registers_x32_linux): New prototype.
9643 (init_registers_x32_avx_linux): Likwise.
9644 (x86_linux_update_xmltarget): Call init_registers_x32_linux
9645 or init_registers_x32_avx_linux if linux_is_elf64 is false.
9646
ecedbe58
PA
96472012-04-13 Pedro Alves <palves@redhat.com>
9648
9649 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
9650 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
9651 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
9652 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
9653 the sub-make.
9654
c92b5177
L
96552012-04-12 H.J. Lu <hongjiu.lu@intel.com>
9656
9657 * linux-x86-low.c (compat_x32_clock_t): New.
9658 (compat_x32_siginfo_t): Likewise.
9659 (compat_x32_siginfo_from_siginfo): Likewise.
9660 (siginfo_from_compat_x32_siginfo): Likewise.
9661 (linux_is_elf64): Likewise.
9662 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
9663 and siginfo_from_compat_x32_siginfo for x32.
9664 (x86_arch_setup): Set linux_is_elf64.
9665
214d508e
L
96662012-04-12 H.J. Lu <hongjiu.lu@intel.com>
9667
9668 PR gdb/13969
9669 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
9670 e_machine field.
9671 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
9672 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
9673 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
9674 compatible with process.
9675
c9a1864a
YQ
96762012-04-12 Yao Qi <yao@codesourcery.com>
9677
9678 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
9679 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
9680 (install-only, install-info, clean): Handle sub dir gnulib.
9681 (all-lib, am--refresh): New targets.
9682 (memmem.o): Remove target.
9683 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
9684 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
9685 (AC_REPLACE_FUNCS): Remove memmem.
9686 Invoke gl_INIT and AM_INIT_AUTOMAKE.
9687 (AC_OUTPUT): Generate Makefile in gnulib/.
9688 * aclocal.m4, config.in, configure: Regenerated.
9689
367ba2c2
MR
96902012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
9691
9692 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
9693
9d236627
PA
96942012-04-05 Pedro Alves <palves@redhat.com>
9695
9696 -Werror=strict-aliasing
9697
9698 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
9699 pointer.
9700
111217b3
PA
97012012-04-04 Pedro Alves <palves@redhat.com>
9702
9703 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
9704 (sparc_store_gregset_from_stack, sparc_store_gregset)
9705 (sparc_breakpoint_at): Fix formatting.
9706
8365dcf5
TJB
97072012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9708
9709 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
9710 are available.
9711 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
9712 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
9713 * config.in: Regenerate.
9714 * configure: Likewise.
9715
689cc2ae
PA
97162012-03-29 Pedro Alves <palves@redhat.com>
9717
9718 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
9719 Correct ptrace arguments.
9720
c14dfd32
PA
97212012-03-28 Pedro Alves <palves@redhat.com>
9722
9723 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
9724 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
9725 (IA64_FR1_REGNUM): New defines.
9726 (ia64_fetch_register): New.
9727 (the_low_target): Install it.
9728 * linux-low.h (struct linux_target_ops) <fetch_register>: New
9729 field.
9730 * linux-low.c (linux_fetch_registers): Try the
9731 the_low_target.fetch_register hook first.
9732
9733 * linux-arm-low.c (the_low_target): Adjust.
9734 * linux-bfin-low.c (the_low_target): Adjust.
9735 * linux-cris-low.c (the_low_target): Adjust.
9736 * linux-crisv32-low.c (the_low_target): Adjust.
9737 * linux-m32r-low.c (the_low_target): Adjust.
9738 * linux-m68k-low.c (the_low_target): Adjust.
9739 * linux-mips-low.c (the_low_target): Adjust.
9740 * linux-ppc-low.c (the_low_target): Adjust.
9741 * linux-s390-low.c (the_low_target): Adjust.
9742 * linux-sh-low.c (the_low_target): Adjust.
9743 * linux-sparc-low.c (the_low_target): Adjust.
9744 * linux-tic6x-low.c (the_low_target): Adjust.
9745 * linux-x86-low.c (the_low_target): Adjust.
9746 * linux-xtensa-low.c (the_low_target): Adjust.
9747
63c88e13
PA
97482012-03-26 Pedro Alves <palves@redhat.com>
9749
9750 * server.c (handle_qxfer_libraries): Don't bail early if
9751 the_target->qxfer_libraries_svr4 is not NULL.
9752
fb723180
PA
97532012-03-26 Pedro Alves <palves@redhat.com>
9754
9755 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
9756
0afae3cf
PA
97572012-03-23 Pedro Alves <palves@redhat.com>
9758
9759 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
9760 "library-list-svr4" element's start tag when the the DSO list is
9761 empty.
9762
485f1ee4
PA
97632012-03-23 Pedro Alves <palves@redhat.com>
9764
9765 * linux-low.c (read_one_ptr): Read the inferior's pointer through
9766 a variable whose type size is the same as the inferior's pointer
9767 size.
9768
a5362b9a
TS
97692012-03-21 Thomas Schwinge <thomas@codesourcery.com>
9770
9771 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
9772 struct siginfo.
9773 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
9774 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
9775 * linux-low.h: Include <signal.h>.
9776 (struct siginfo): Remove forward declaration.
9777 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
9778 struct siginfo.
9779
d226c142
MF
97802012-03-21 Mike Frysinger <vapier@gentoo.org>
9781
9782 * .gitignore: Ignore more files.
9783
122f36ef
PA
97842012-03-19 Pedro Alves <palves@redhat.com>
9785 Jan Kratochvil <jan.kratochvil@redhat.com>
9786
9787 * server.c (cont_thread, general_thread): Add describing comments.
9788 (start_inferior): Clear `cont_thread'.
9789 (handle_v_cont): Don't set `cont_thread' if resuming all threads
9790 of a process.
9791
fc3e5175
YQ
97922012-03-15 Yao Qi <yao@codesourcery.com>
9793
9794 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
9795 handling to ...
9796 (cmd_qtdp): ... here.
9797
8d0d92cd
YQ
97982012-03-15 Yao Qi <yao@codesourcery.com>
9799
9800 * tracepoint.c (struct tracepoint_action_ops): New.
9801 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
9802 (m_tracepoint_action_download): New.
9803 (r_tracepoint_action_download): New.
9804 (x_tracepoint_action_download): New.
9805 (l_tracepoint_action_download): New.
9806 (add_tracepoint_action): Install `action->ops' according type.
9807 (download_tracepoint_1): Move code `download' function pointer
9808 of various tracepoint_action_ops.
9809
87b0bb13
JK
98102012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
9811
9812 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
9813 linux_ptrace_attach_warnings.
9814
5f572dec
JK
98152012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
9816
9817 * Makefile.in (linux-ptrace.o): New.
9818 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
9819 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
9820 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
9821 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
9822 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
9823 of these targets.
9824 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
9825
f4647387
YQ
98262012-03-08 Yao Qi <yao@codesourcery.com>
9827 Pedro Alves <palves@redhat.com>
9828
9829 Fix PR server/13392.
9830 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
9831 offset of JMP insn.
9832 * tracepoint.c (remove_tracepoint): New.
9833 (cmd_qtdp): Call remove_tracepoint when failed to install.
9834
9b224c5e
PA
98352012-03-07 Pedro Alves <palves@redhat.com>
9836
9837 * linux-low.c (get_detach_signal): New.
9838 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
9839 Pass on pending signals to PTRACE_DETACH. Check the result of the
9840 ptrace call.
9841 * server.c (program_signals, program_signals_p): New.
9842 (handle_general_set): Handle QProgramSignals.
9843 * server.h (program_signals, program_signals_p): Declare.
9844
e237a7e2
JK
98452012-03-05 Pedro Alves <palves@redhat.com>
9846 Jan Kratochvil <jan.kratochvil@redhat.com>
9847
9848 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
9849 New comment why.
9850
5808517f
YQ
98512012-03-03 Yao Qi <yao@codesourcery.com>
9852
9853 * tracepoint.c (tracepoint_look_up_symbols): Update call to
9854 agent_look_up_symbols.
9855
58b4daa5
YQ
98562012-03-03 Yao Qi <yao@codesourcery.com>
9857
9858 * Makefile.in (linux-low.o): Keep dependence on agent.h.
9859 (linux-x86-low.o): Likewise.
9860 * server.h: Remove in_process_agent_loaded.
9861 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
9862 common/agent.c.
9863 Update callers.
9864
8ffcbaaf
YQ
98652012-03-03 Yao Qi <yao@codesourcery.com>
9866
9867 * tracepoint.c (gdb_agent_capability): New global.
9868 (in_process_agent_loaded_ust): Renamed to
9869 `in_process_agent_supports_ust'.
9870 Update callers.
9871 (in_process_agent_supports_ust): Call agent_capability_check.
9872 (clear_installed_tracepoints): Assert that agent supports
9873 agent.
9874
d1feda86
YQ
98752012-03-03 Yao Qi <yao@codesourcery.com>
9876
9877 * linux-low.c (linux_supports_agent): New.
9878 (linux_target_ops): Initialize field `supports_agent' with
9879 linux_supports_agent.
9880 * target.h (struct target_ops) <supports_agent>: New.
9881 (target_supports_agent): New macro.
9882 * server.c (handle_general_set): Handle packet 'QAgent'.
9883 (handle_query): Send `QAgent+'.
9884 * Makefile.in (server.o): Depends on agent.h.
9885
2fa291ac
YQ
98862012-03-03 Yao Qi <yao@codesourcery.com>
9887
9888 * Makefile.in (OBS): Add agent.o.
9889 Add new rule for agent.o.
9890 Track dependence of tracepoint.c on agent.h.
9891 * tracepoint.c (run_inferior_command_1):
9892 (run_inferior_command): Call agent_run_command.
9893 (gdb_ust_connect_sync_socket): Deleted. Move it to
9894 common/agent.c.
9895 (resume_thread, stop_thread): Likewise.
9896 (gdb_ust_socket_init): Renamed to ...
9897 (gdb_agent_socket_init): ... New.
9898 (gdb_ust_thread): Renamed to ...
9899 (gdb_agent_helper_thread): ... New.
9900 (gdb_ust_init): Move some code to ...
9901 (gdb_agent_init): ... here. New.
9902 [HAVE_UST]: Call gdb_ust_init.
9903 (initialize_tracepoint_ftlib): Call gdb_agent_init.
9904 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
9905 * config.in, configure: Regenerated.
9906
05044653
PA
99072012-03-02 Pedro Alves <palves@redhat.com>
9908
9909 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
9910 * linux-low.c (struct simple_pid_list): New.
9911 (stopped_pids): New a struct simple_pid_list pointer.
9912 (add_to_pid_list, pull_pid_from_list): New.
9913 (handle_extended_wait): Don't assume the first signal new children
9914 report is SIGSTOP. Adjust call to pull_pid_from_list.
9915 (linux_wait_for_lwp): Adjust.
9916
8d00225b
YQ
99172012-03-02 Yao Qi <yao@codesourcery.com>
9918
9919 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
9920 debug log.
9921
19560ba5
YQ
99222012-03-02 Yao Qi <yao@codesourcery.com>
9923
9924 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
9925 `stop_pc' and `tpoint'. Update caller.
9926
1faeff08
MR
99272012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
9928
9929 * linux-low.h (linux_target_ops): Add regset_bitmap member.
9930 * linux-low.c (use_linux_regsets): New macro.
9931 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
9932 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
9933 (linux_register_in_regsets): New function.
9934 (usr_fetch_inferior_registers): Skip registers covered by
9935 regsets.
9936 (usr_store_inferior_registers): Likewise.
9937 (usr_fetch_inferior_registers): New macro.
9938 (usr_store_inferior_registers): Likewise.
9939 (linux_fetch_registers): Handle mixed regset/non-regset targets.
9940 (linux_store_registers): Likewise.
9941 * linux-mips-low.c (init_registers_mips_dsp_linux): New
9942 prototype.
9943 (init_registers_mips64_dsp_linux): Likewise.
9944 (init_registers_mips_linux): New macro.
9945 (init_registers_mips_dsp_linux): Likewise.
9946 (mips_dsp_num_regs): Likewise.
9947 (DSP_BASE, DSP_CONTROL): New fallback macros.
9948 (mips_base_regs): New macro.
9949 (mips_regmap): Use it. Fix the size.
9950 (mips_dsp_regmap): New variable.
9951 (mips_dsp_regset_bitmap): Likewise.
9952 (mips_arch_setup): New function.
9953 (mips_cannot_fetch_register): Use the_low_target.regmap rather
9954 than mips_regmap.
9955 (mips_cannot_store_register): Likewise.
9956 (the_low_target): Update .arch_setup, .num_regs and .regmap
9957 initializers. Add .regset_bitmap initializer.
9958 * linux-arm-low.c (the_low_target): Add .regset_bitmap
9959 initializer.
9960 * linux-bfin-low.c (the_low_target): Likewise.
9961 * linux-cris-low.c (the_low_target): Likewise.
9962 * linux-crisv32-low.c (the_low_target): Likewise.
9963 * linux-ia64-low.c (the_low_target): Likewise.
9964 * linux-m32r-low.c (the_low_target): Likewise.
9965 * linux-m68k-low.c (the_low_target): Likewise.
9966 * linux-ppc-low.c (the_low_target): Likewise.
9967 * linux-s390-low.c (the_low_target): Likewise.
9968 * linux-sh-low.c (the_low_target): Likewise.
9969 * linux-sparc-low.c (the_low_target): Likewise.
9970 * linux-tic6x-low.c (the_low_target): Likewise.
9971 * linux-x86-low.c (the_low_target): Likewise.
9972 * linux-xtensa-low.c (the_low_target): Likewise.
9973 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
9974 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
9975 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
9976 srv_xmlfiles.
9977 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
9978 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
9979
c03e6ccc
YQ
99802012-02-29 Yao Qi <yao@codesourcery.com>
9981 Pedro Alves <palves@redhat.com>
9982
9983 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
9984 `step_over_finished' is true.
9985
644cebc9
PA
99862012-02-27 Pedro Alves <palves@redhat.com>
9987
9988 * linux-low.c (pid_is_stopped): Delete, moved to common/.
9989 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
9990
c14d7ab2
PA
99912012-02-27 Pedro Alves <palves@redhat.com>
9992
9993 PR server/9684
9994 * linux-low.c (pid_is_stopped): New.
9995 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
9996
412c89dd
LM
99972012-02-25 Luis Machado <lgustavo@codesourcery.com>
9998
9999 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
10000 of conditions.
10001
b745defe
MR
100022012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
10003
10004 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
10005
9f3a5c85
LM
100062012-02-24 Luis Machado <lgustavo@codesourcery>
10007
10008 * server.c (handle_query): Advertise support for target-side
10009 breakpoint condition evaluation.
10010 (process_point_options): New function.
10011 (process_serial_event): When inserting a breakpoint, check for
10012 a target-side condition that should be evaluated.
10013
10014 * mem-break.c: Include regcache.h and ax.h.
10015 (point_cond_list_t): New data structure.
10016 (breakpoint) <cond_list>: New field.
10017 (find_gdb_breakpoint_at): Make non-static.
10018 (delete_gdb_breakpoint_at): Clear any target-side
10019 conditions.
10020 (clear_gdb_breakpoint_conditions): New function.
10021 (add_condition_to_breakpoint): Likewise.
10022 (add_breakpoint_condition): Likewise.
10023 (gdb_condition_true_at_breakpoint): Likewise.
10024 (gdb_breakpoint_here): Return result directly instead
10025 of going through a local variable.
10026
10027 * mem-break.h (find_gdb_breakpoint_at): New prototype.
10028 (clear_gdb_breakpoint_conditions): Likewise.
10029 (add_breakpoint_condition): Likewise.
10030 (gdb_condition_true_at_breakpoint): Likewise.
10031
10032 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
10033 (need_step_over_p): Take target-side breakpoint condition into
10034 consideration.
10035
5e1dc496
LM
100362012-02-24 Luis Machado <lgustavo@codesourcery>
10037
10038 * server.h: Include tracepoint.h.
10039 (agent_mem_read, agent_get_trace_state_variable_value,
10040 agent_set_trace_state_variable_value,
10041 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
10042 get_set_tsv_func_addr): New prototypes.
10043
10044 * ax.h: New include file.
10045 * ax.c: New source file.
10046
10047 * tracepoint.c: Include ax.h.
10048 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
10049 agent_expr, eval_result_type): Move to ax.h.
10050 (parse_agent_expr): Rename to ...
10051 (gdb_parse_agent_expr): ... this, make it non-static and move
10052 to ax.h.
10053 (unparse_agent_expr) Rename to ...
10054 (gdb_unparse_agent_expr): ... this, make it non-static and move
10055 to ax.h.
10056 (eval_agent_expr): Rename to ...
10057 (eval_tracepoint_agent_expr): ... this.
10058 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
10059 forward declarations.
10060 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
10061 (agent_get_trace_state_variable_value): New function.
10062 (agent_set_trace_state_variable_value): New function.
10063 (cmd_qtdp): Call gdb_parse_agent_expr (...).
10064 (response_tracepoint): Call gdb_unparse_agent_expr (...).
10065 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
10066 (condition_true_at_tracepoint): Likewise.
10067 (parse_agent_expr): Rename to ...
10068 (gdb_parse_agent_expr): ... this and move to ax.c.
10069 (unparse_agent_expr): Rename to ...
10070 (gdb_unparse_agent_expr): ... this and move to ax.c.
10071 (gdb_agent_op_name): Move to ax.c.
10072 (eval_agent_expr): Rename to ...
10073 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
10074 and move to ax.c.
10075 (eval_tracepoint_agent_expr): New function.
10076 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 10077 non-static.
5e1dc496
LM
10078 (current_insn_ptr, emit_error, struct bytecode_address): Move to
10079 ax.c.
10080 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
10081 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
10082 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
10083 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
10084 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
10085 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
10086 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
10087 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
10088 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
10089 (compile_bytecodes): Remove forward declaration.
10090 (is_goto_target): Move to ax.c.
10091 (compile_bytecodes): Move to ax.c and call
10092 agent_get_trace_state_variable_value (...) and
10093 agent_set_trace_state_variable_value (...).
10094
10095 * Makefile.in: Update ax.c and IPA dependencies.
10096
277e4e52
PA
100972012-02-24 Pedro Alves <palves@redhat.com>
10098
10099 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
10100 (cmd_bigqtbuffer_circular): ... this. Only handle
10101 'QTBuffer:circular:'.
10102 (handle_tracepoint_general_set): Adjust.
10103
bf4c19f7
YQ
101042012-02-16 Yao Qi <yao@codesourcery.com>
10105
10106 * inferiors.c: Move code to ...
10107 * dll.c: .... here. New.
10108 * server.h: Declare clear_dlls.
10109 * Makefile.in (SFILES): Add dll.c.
10110 (OBS): Add dll.o
10111 (dll.o): New rule.
10112
d73f2619
YQ
101132012-02-11 Yao Qi <yao@codesourcery.com>
10114
10115 * server.c: (handle_monitor_command): Add a new parameter
10116 `own_buf'.
10117 (handle_query): Update caller.
10118
f8255c2a
JB
101192012-02-09 Joel Brobecker <brobecker@adacore.com>
10120
10121 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
10122 * configure, config.in: Regenerate.
10123 * hostio.c: Provide an alternate implementation if HAVE_READLINK
10124 is not defined.
10125
da84f473
PA
101262012-02-02 Pedro Alves <palves@redhat.com>
10127
10128 Try SIGKILL first, then PTRACE_KILL.
10129 * linux-low.c (linux_kill_one_lwp): New.
10130 (linux_kill_one_lwp): Rename to ...
10131 (kill_one_lwp_callback): ... this. Use the new
10132 linux_kill_one_lwp.
10133
e886a173
PA
101342012-02-02 Pedro Alves <palves@redhat.com>
10135
10136 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
10137 inferior.
10138
be07f1a2
PA
101392012-01-27 Pedro Alves <palves@redhat.com>
10140
10141 * linux-low.c (linux_child_pid_to_exec_file): Delete.
10142 (elf_64_file_p): Make static.
10143 (linux_pid_exe_is_elf_64_file): New.
10144 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
10145 Delete declarations.
10146 (linux_pid_exe_is_elf_64_file): Declare.
10147 * linux-x86-low.c (x86_arch_setup): Use
10148 linux_pid_exe_is_elf_64_file.
10149
d8301ad1
JK
101502012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
10151
10152 * linux-low.c (linux_wait_for_event_1): Rename to ...
10153 (linux_wait_for_event): ... here and merge it with former
10154 linux_wait_for_event - new variable wait_ptid, use it.
10155 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
10156
01b17894
PA
101572012-01-23 Pedro Alves <palves@redhat.com>
10158
10159 * server.c (main): Avoid yet another case of infinite loop while
10160 detaching/killing after a longjmp.
10161
e825046f
JK
101622012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10163
10164 Code cleanup.
10165 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
10166
b9e7b9c3
UW
101672012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
10168
10169 * hostio.c (handle_readlink): New function.
10170 (handle_vFile): Call it to handle "vFile:readlink" packets.
10171
901f9912
UW
101722012-01-20 Pedro Alves <palves@redhat.com>
10173 Ulrich Weigand <ulrich.weigand@linaro.org>
10174
10175 * server.c (handle_v_requests): Only support vAttach and vRun to
10176 start multiple processes when in extended protocol mode.
10177
fc1ab1a0
PA
101782012-01-17 Pedro Alves <palves@redhat.com>
10179
10180 * tracepoint.c (initialize_tracepoint): Use mmap instead of
10181 memalign plus mprotect to allocate the scratch buffer.
10182
7d5d4e98
PA
101832012-01-13 Pedro Alves <palves@redhat.com>
10184
10185 * server.c (attach_inferior): Clear `cont_thread'.
10186
f128d5e9
PA
101872012-01-13 Pedro Alves <palves@redhat.com>
10188
10189 * server.c (main): Avoid infinite loop while detaching/killing
10190 after a longjmp.
10191
06db92f0
DE
101922012-01-09 Doug Evans <dje@google.com>
10193
10194 * server.c (start_inferior): Set last_ptid in --wrapper case.
10195
32d92999
YQ
101962012-01-06 Yao Qi <yao@codesourcery.com>
10197
10198 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
10199 defined.
10200 [IN_PROCESS_AGENT] (debug_agent): New global variable.
10201
5e0a92a9
YQ
102022012-01-04 Yao Qi <yao@codesourcery.com>
10203
10204 * tracepoint.c (cmd_qtdp): Print debug message
10205 for static tracepoint.
10206
ae639e8c
YQ
102072012-01-04 Yao Qi <yao@codesourcery.com>
10208
10209 * tracepoint.c (trace_vdebug): Differentiate debug message
10210 between gdbserver and IPA.
10211
f72429c5
YQ
102122012-01-03 Yao Qi <yao@codesourcery.com>
10213
10214 * tracepoint.c (tracepoint_was_hit): Don't collect for
10215 static tracepoint.
10216
12c3e59c
JB
102172012-01-02 Joel Brobecker <brobecker@adacore.com>
10218
10219 * terminal.h: Reformat copyright header.
10220
67827812
JB
102212012-01-02 Joel Brobecker <brobecker@adacore.com>
10222
10223 * server.c (gdbserver_version): Update copyright year.
10224 * gdbreplay.c (gdbreplay_version): Likewise.
10225
3e52c33d
JK
102262011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
10227
10228 * linux-low.c (linux_create_inferior): Put empty if clause for write.
10229
10230 Revert:
10231 2011-12-18 Hui Zhu <teawater@gmail.com>
10232 * linux-low.c (linux_create_inferior): Save return value to ret.
10233
66f1260e
HZ
102342011-12-18 Hui Zhu <teawater@gmail.com>
10235
10236 * linux-low.c (linux_create_inferior): Save return value to ret.
10237
e77616d7
DE
102382011-12-16 Doug Evans <dje@google.com>
10239
e7b06c57
DE
10240 * linux-low.c (linux_create_inferior): If stdio connection,
10241 redirect stdin from /dev/null, stdout to stderr.
10242 * remote-utils.c (remote_is_stdio): New static global.
10243 (remote_connection_is_stdio): New function.
10244 (remote_prepare): Handle stdio connection.
10245 (remote_open): Ditto.
10246 (remote_close): Don't close stdin for stdio connections.
10247 (read_prim,write_prim): New functions. Replace all calls to
10248 read/write to these.
10249 * server.c (main): Watch for "-" argument. Move call to
10250 remote_prepare before start_inferior.
10251 * server.h (STDIO_CONNECTION_NAME): New macro.
10252 (remote_connection_is_stdio): Declare.
10253
e77616d7
DE
10254 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
10255 in debugging output.
10256
82067193
YQ
102572011-12-15 Yao Qi <yao@codesourcery.com>
10258
10259 * tracepoint.c: Include sys/syscall.h.
10260 (gdb_ust_thread): Remove preprocessor conditional.
10261
82bfbe7e
PA
102622011-12-14 Pedro Alves <pedro@codesourcery.com>
10263
10264 * linux-low.c (linux_detach_one_lwp): Call
10265 the_low_target.prepare_to_resume before detaching.
10266
712c6575
YQ
102672011-12-14 Yao Qi <yao@codesourcery.com>
10268
10269 * tracepoint.c (gdb_ust_thread): Don't ignore return value
10270 of write.
10271
d54d1edf
YQ
102722011-12-14 Yao Qi <yao@codesourcery.com>
10273
10274 * i386-low.c (i386_low_stopped_data_address): Initialize local
10275 variable `control'.
10276
6210a125
PA
102772011-12-13 Pedro Alves <pedro@codesourcery.com>
10278
10279 PR remote/13492
10280
10281 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
10282 DR_CONTROL unless necessary. Extend comments.
10283 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
10284 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
10285
2ece8244
YQ
102862011-12-13 Yao Qi <yao@codesourcery.com>
10287
10288 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
10289 macros.
10290 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
10291
784867a5
JK
102922011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
10293
10294 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
10295 Print new debug message for such case.
10296
6bf36717
JK
102972011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
10298
10299 Fix overlapping memcpy.
10300 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
10301 the read_inferior_memory transfer.
10302 (delete_fast_tracepoint_jump): New variable buf. Use it for the
10303 write_inferior_memory transfer.
10304 (set_fast_tracepoint_jump): New variable buf. Use it for the
10305 read_inferior_memory and write_inferior_memory transfers.
10306 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
10307 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
10308 Use it for the write_inferior_memory transfer.
10309 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
10310 buffers.
10311
50275556
MR
103122011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
10313
10314 * linux-low.c (fetch_register, store_register): Make code
10315 consistent, fix formatting.
10316
7325beb4
MR
103172011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
10318
10319 * linux-low.c (usr_store_inferior_registers): Factor out code
10320 to handle individual registers into...
10321 (store_register): ... this new function.
10322
c642a434
UW
103232011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
10324
10325 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
10326 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
10327 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
10328 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
10329 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
10330 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
10331 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
10332 (srv_xmlfiles): Add new XML files.
10333
10334 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
10335 and <sys/uio.h>.
10336 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
10337 (init_registers_s390_linux32v1): Add prototype.
10338 (init_registers_s390_linux32v2): Likewise.
10339 (init_registers_s390_linux64v1): Likewise.
10340 (init_registers_s390_linux64v2): Likewise.
10341 (init_registers_s390x_linux64v1): Likewise.
10342 (init_registers_s390x_linux64v2): Likewise.
10343 (s390_num_regs): Increment to 52.
10344 (s390_regmap): Add orig_r2 register.
10345 (s390_num_regs_3264): Increment to 68.
10346 (s390_regmap_3264): Add orig_r2 register.
10347 (s390_collect_ptrace_register): Handle orig_r2 register.
10348 (s390_supply_ptrace_register): Likewise.
10349 (s390_fill_last_break): New function.
10350 (s390_store_last_break): Likewise.
10351 (s390_fill_system_call): New function.
10352 (s390_store_system_call): Likewise.
10353 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
10354 register sets.
10355 (s390_check_regset): New function.
10356 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
10357 NT_S390_SYSTEM_CALL regsets and use appropriate description.
10358 Update target_regsets for available register sets.
10359
2268b414
JK
103602011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
10361 Jan Kratochvil <jan.kratochvil@redhat.com>
10362
10363 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
10364 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
10365 New.
10366 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
10367 * linux-low.h (struct process_info_private): New member r_debug.
10368 * server.c (handle_qxfer_libraries): Call
10369 the_target->qxfer_libraries_svr4.
10370 (handle_qxfer_libraries_svr4): New function.
10371 (qxfer_packets): New entry "libraries-svr4".
10372 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
10373 * target.h (struct target_ops): New member qxfer_libraries_svr4.
10374 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
10375 PACKET_qXfer_libraries_svr4.
10376
d6db1fab
UW
103772011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
10378
10379 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
10380 PSW address/mask between 8-byte and 16-byte formats.
10381 (s390_supply_ptrace_register): Likewise.
10382 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
10383 basic addressing mode bit.
10384
242f5f1c
SS
103852011-11-24 Stan Shebs <stan@codesourcery.com>
10386
10387 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
10388
f196051f
SS
103892011-11-17 Stan Shebs <stan@codesourcery.com>
10390
10391 * tracepoint.c (struct tracepoint): New field traceframe_usage.
10392 (tracing_start_time): New global.
10393 (tracing_stop_time): New global.
10394 (tracing_user_name): New global.
10395 (tracing_notes): New global.
10396 (tracing_stop_note): New global.
10397 (cmd_qtstart): Set traceframe_usage, start_time.
10398 (stop_tracing): Set stop_time.
10399 (cmd_qtstatus): Report additional status.
10400 (cmd_qtp): New function.
10401 (handle_tracepoint_query): Call it.
10402 (cmd_qtnotes): New function.
10403 (handle_tracepoint_general_set): Call it.
10404 (get_timestamp): Rename from tsv_get_timestamp.
10405
405f8e94
SS
104062011-11-14 Stan Shebs <stan@codesourcery.com>
10407 Kwok Cheung Yeung <kcy@codesourcery.com>
10408
10409 * linux-x86-low.c (small_jump_insn): New.
10410 (i386_install_fast_tracepoint_jump_pad): Add arguments for
10411 trampoline and error message, build a trampoline and issue a small
10412 jump instruction to it.
10413 (x86_install_fast_tracepoint_jump_pad): Add arguments for
10414 trampoline and error message.
10415 (x86_get_min_fast_tracepoint_insn_len): New.
10416 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
10417 * linux-low.h (struct linux_target_ops): Add arguments to
10418 install_fast_tracepoint_jump_pad operation, add new operation.
10419 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
10420 arguments.
10421 (linux_get_min_fast_tracepoint_insn_len): New function.
10422 (linux_target_op): Add new operation.
10423 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
10424 (gdb_trampoline_buffer_end): Ditto.
10425 (gdb_trampoline_buffer_error): Ditto.
10426 (struct ipa_sym_addresses): Add fields for new IPA variables.
10427 (symbol_list): Add entries for new IPA variables.
10428 (struct tracepoint): Add fields to hold the address range of the
10429 trampoline used by the tracepoint.
10430 (trampoline_buffer_head): New static variable.
10431 (trampoline_buffer_tail): Ditto.
10432 (claim_trampoline_space): New function.
10433 (have_fast_tracepoint_trampoline_buffer): New function.
10434 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
10435 structure.
10436 (install_fast_tracepoint): Ditto, also add error buffer argument.
10437 (cmd_qtminftpilen): New function.
10438 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
10439 (fast_tracepoint_from_trampoline_address): New function.
10440 (fast_tracepoint_collecting): Handle trampoline as part of jump
10441 pad space.
10442 (set_trampoline_buffer_space): New function.
10443 (initialize_tracepoint): Initialize new IPA variables.
10444 * target.h (struct target_ops): Add arguments to
10445 install_fast_tracepoint_jump_pad operation, add new
10446 get_min_fast_tracepoint_insn_len operation.
10447 (target_get_min_fast_tracepoint_insn_len): New.
10448 (install_fast_tracepoint_jump_pad): Add arguments.
10449 * server.h (IPA_BUFSIZ): Define.
10450 * linux-i386-ipa.c: Include extra header files.
10451 (initialize_fast_tracepoint_trampoline_buffer): New function.
10452 (initialize_low_tracepoint): Call it.
10453 * server.h (set_trampoline_buffer_space): Declare.
10454 (claim_trampoline_space): Ditto.
10455 (have_fast_tracepoint_trampoline_buffer): Ditto.
10456
1e4d1764
YQ
104572011-11-14 Yao Qi <yao@codesourcery.com>
10458
10459 * server.c (handle_query): Handle InstallInTrace for qSupported.
10460 * tracepoint.c (add_tracepoint): Sort list.
10461 (install_tracepoint, download_tracepoint): New.
10462 (cmd_qtdp): Call them to install and download tracepoints.
10463 (sort_tracepoints): Removed.
10464 (cmd_qtstart): Update.
10465
5c73ff4e
YQ
104662011-11-14 Yao Qi <yao@codesourcery.com>
10467
10468 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
10469 * mem-break.h: Declare.
10470 * tracepoint.c (cmd_qtstart): Move some code to ...
10471 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
10472 New.
10473 (download_tracepoints): Move some code to ...
10474 (download_tracepoint_1): ... here. New.
10475
86a30030
YQ
104762011-11-08 Yao Qi <yao@codesourcery.com>
10477
10478 * remote-utils.c (relocate_instruction): A comment fix.
10479
8d26e50c
JB
104802011-11-07 Joel Brobecker <brobecker@adacore.com>
10481
10482 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
10483 (i386_dr_low_get_control, i386_dr_low_get_status): Use
10484 dr_status_mirror and dr_control_mirror from debug_reg_state.
10485 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
10486 (i386_initial_stuff): Remove use of deleted globals.
10487 (i386_get_thread_context, i386_set_thread_context,
10488 i386_thread_added): Use dr_status_mirror and dr_control_mirror
10489 from debug_reg_state.
10490
a59306a3
YQ
104912011-11-05 Yao Qi <yao@codesourcery.com>
10492
10493 * tracepoint.c (gdb_collect): Loop over tracepoints of same
10494 address as TPOINT's.
10495
3065dfb6
SS
104962011-11-02 Stan Shebs <stan@codesourcery.com>
10497
10498 * tracepoint.c (agent_mem_read_string): New function.
10499 (eval_agent_expr): Call it for tracenz.
10500 * server.c (handle_query): Report support for tracenz.
10501
fd0d8c7c
YQ
105022011-11-02 Yao Qi <yao@codesourcery.com>
10503
10504 * tracepoint.c (cmd_qtstart): Remove unused local variables.
10505
609086b1
YQ
105062011-11-02 Yao Qi <yao@codesourcery.com>
10507
10508 * target.h: Fix a typo in comment.
10509
b9fd1791
PA
105102011-10-31 Pedro Alves <pedro@codesourcery.com>
10511
10512 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
10513 clobber the breakpoints' shadows with fast tracepoint jumps.
10514 * mem-break.h (check_mem_write): Add `myaddr' parameter.
10515 * target.c (write_inferior_memory): Also pass MYADDR down to
10516 check_mem_write.
10517
03583c20
UW
105182011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
10519
10520 * configure.ac: Check support for personality routine.
10521 * configure: Regenerate.
10522 * config.in: Likewise.
10523 * linux-low.c: Include <sys/personality.h>.
10524 Define ADDR_NO_RANDOMIZE if necessary.
10525 (linux_create_inferior): Disable address space randomization when
10526 forking inferior, if requested.
10527 (linux_supports_disable_randomization): New function.
10528 (linux_target_ops): Install it.
10529 * server.h (disable_randomization): Declare.
10530 * server.c (disable_randomization): New global variable.
10531 (handle_general_set): Handle QDisableRandomization.
10532 (handle_query): Likewise for qSupported.
10533 (main): Support --disable-randomization and --no-disable-randomization
10534 command line arguments.
10535 * target.h (struct target_ops): Add supports_disable_randomization.
10536 (target_supports_disable_randomization): New macro.
10537
723b724b
MF
105382011-09-29 Mike Frysinger <vapier@gentoo.org>
10539
10540 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
10541 ifdef check.
10542 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
10543 [!PT_GETDSBT] (target_loadmap): New definition.
10544 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
10545 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
10546 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
10547 and PT_GETDSBT to LINUX_LOADMAP.
10548 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
10549 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
10550
55329a5c 105512011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
10552
10553 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
10554 (arm_linux_hwbp_cap): New static variable.
10555 (arm_linux_get_hwbp_cap): Replace by ...
10556 (arm_linux_init_hwbp_cap): ... this new function.
10557 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
10558 (arm_linux_get_hw_watchpoint_count): Likewise.
10559 (arm_linux_get_hw_watchpoint_max_length): Likewise.
10560 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
10561 (arm_prepare_to_resume): Use perror_with_name instead of error.
10562
55329a5c 105632011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
10564
10565 * linux-arm-low.c: Include <signal.h>.
10566 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
10567 (struct arm_linux_hwbp_cap): New data type.
10568 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
10569 (struct arm_linux_hw_breakpoint): New data type.
10570 (MAX_BPTS, MAX_WPTS): Define.
10571 (struct arch_process_info, struct arch_lwp_info): New data types.
10572 (arm_linux_get_hwbp_cap): New function.
10573 (arm_linux_get_hw_breakpoint_count): Likewise.
10574 (arm_linux_get_hw_watchpoint_count): Likewise.
10575 (arm_linux_get_hw_watchpoint_max_length): Likewise.
10576 (arm_hwbp_control_initialize): Likewise.
10577 (arm_hwbp_control_is_enabled): Likewise.
10578 (arm_hwbp_control_is_initialized): Likewise.
10579 (arm_hwbp_control_disable): Likewise.
10580 (arm_linux_hw_breakpoint_equal): Likewise.
10581 (arm_linux_hw_point_initialize): Likewise.
10582 (struct update_registers_data): New data structure.
10583 (update_registers_callback: New function.
10584 (arm_insert_point): Likewise.
10585 (arm_remove_point): Likewise.
10586 (arm_stopped_by_watchpoint): Likewise.
10587 (arm_stopped_data_address): Likewise.
10588 (arm_new_process): Likewise.
10589 (arm_new_thread): Likewise.
10590 (arm_prepare_to_resume): Likewise.
10591 (the_low_target): Register arm_insert_point, arm_remove_point,
10592 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
10593 arm_new_thread, and arm_prepare_to_resume.
10594
6b9801d4
SS
105952011-09-15 Stan Shebs <stan@codesourcery.com>
10596
10597 * server.h (struct emit_ops): Add compare-goto fields.
10598 * tracepoint.c (gdb_agent_op_sizes): New table.
10599 (emit_eq_goto): New function.
10600 (emit_ne_goto): New function.
10601 (emit_lt_goto): New function.
10602 (emit_le_goto): New function.
10603 (emit_gt_goto): New function.
10604 (emit_ge_goto): New function.
10605 (is_goto_target): New function.
10606 (compile_bytecodes): Recognize special cases of compare-goto
10607 combinations and call specialized emitters for them.
10608 * linux-x86-low.c (amd64_emit_eq_goto): New function.
10609 (amd64_emit_ne_goto): New function.
10610 (amd64_emit_lt_goto): New function.
10611 (amd64_emit_le_goto): New function.
10612 (amd64_emit_gt_goto): New function.
10613 (amd64_emit_ge_goto): New function.
10614 (amd64_emit_ops): Add the new functions.
10615 (i386_emit_eq_goto): New function.
10616 (i386_emit_ne_goto): New function.
10617 (i386_emit_lt_goto): New function.
10618 (i386_emit_le_goto): New function.
10619 (i386_emit_gt_goto): New function.
10620 (i386_emit_ge_goto): New function.
10621 (i386_emit_ops): Add the new functions.
10622
bf15cbda
SS
106232011-09-08 Stan Shebs <stan@codesourcery.com>
10624
10625 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
10626 (i386_emit_epilogue): Restore %ebx.
10627
943ca1dd
JZ
106282011-08-31 Jie Zhang <jzhang918@gmail.com>
10629
10630 * server.c (step_thread): Remove definition.
10631 (process_serial_event): Don't handle Hs.
10632 * server.h (step_thread): Remove declaration.
10633 * target.c (set_desired_inferior): Remove use of step_thread.
10634
e3deef73
LM
106352011-08-24 Luis Machado <lgustavo@codesourcery.com>
10636
10637 * linux-low.c: Include linux-procfs.h.
10638 (linux_attach_lwp_1): Update comments.
10639 (linux_attach): Scan for existing threads when attaching to a
10640 process that is the tgid.
10641 * Makefile.in: Update dependencies.
10642
13da1c97
LM
106432011-08-24 Luis Machado <lgustavo@codesourcery.com>
10644
10645 * configure.srv: Add linux-procfs.o dependencies.
10646
881127c9
YQ
106472011-08-14 Yao Qi <yao@codesourcery.com>
10648
10649 * target.h (struct target_ops): Fix indent.
10650 * win32-low.c (win32_target_ops): Fix comment.
10651
58dbd541
YQ
106522011-08-14 Andrew Jenner <andrew@codesourcery.com>
10653 Yao Qi <yao@codesourcery.com>
10654
10655 * Makefile.in (clean): Remove tic6x-*.c files.
10656 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
10657 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
10658 (tic6x-c64xp-linux.c): Likewise.
10659 * configure.srv: Add support for tic6x-*-uclinux.
10660 * linux-tic6x-low.c: New.
10661 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
10662
78d85199
YQ
106632011-08-14 Andrew Stubbs <ams@codesourcery.com>
10664 Yao Qi <yao@codesourcery.com>
10665
10666 * target.h (struct target_ops): Add read_loadmap.
10667 * linux-low.c (struct target_loadseg): New type.
10668 (struct target_loadmap): New type.
10669 (linux_read_loadmap): New function.
10670 (linux_target_ops): Add linux_read_loadmap.
10671 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
10672 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
10673 to NULL.
78d85199 10674
a959a88d
EZ
106752011-08-05 Eli Zaretskii <eliz@gnu.org>
10676
10677 * win32-low.c: Include <stdint.h>.
10678
1ced966e
PA
106792011-07-22 Pedro Alves <pedro@codesourcery.com>
10680
10681 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
10682 to the inferior here.
10683 (i386_remove_aligned_watchpoint): Ditto.
10684 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
10685 fit part of the watchpoint in the debug registers.
10686 (i386_update_inferior_debug_regs): New.
10687 (i386_low_insert_watchpoint): Work on a local mirror of the debug
10688 registers, and only update the inferior on success.
10689 (i386_low_remove_watchpoint): Ditto.
10690
d26e3629
KY
106912011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
10692
10693 * linux-low.c (compare_ints, unique, list_threads, show_process,
10694 linux_core_of_thread): Delete.
10695 (linux_target_ops): Change linux_core_of_thread to
10696 linux_common_core_of_thread.
10697 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
10698 * utils.c (malloc_failure): Change type of argument.
10699 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
10700 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
10701 common/linux-osdata.c, common/ptid.c and common/buffer.c.
10702 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
10703 (IPA_OBJS): Add common-utils-ipa.o.
10704 (ptid_h, linux_osdata_h): New macros.
10705 (server_h): Add common/common-utils.h, common/xml-utils.h,
10706 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
10707 common/ptid.h.
10708 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
10709 ptid.o, buffer.o): New rules.
10710 (linux-low.o): Add common/linux-osdata.h as a dependency.
10711 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
10712 * configure.ac: Add AC_HEADER_DIRENT check.
10713 * config.in: Regenerate.
10714 * configure: Regenerate.
10715 * remote-utils.c (xml_escape_text): Delete.
10716 (buffer_grow, buffer_free, buffer_init, buffer_finish,
10717 buffer_xml_printf): Move to common/buffer.c.
10718 * server.c (main): Remove call to initialize_inferiors.
10719 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
10720 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
10721 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
10722 internal_error, gdb_assert, gdb_assert_fail): Delete.
10723 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
10724 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
10725 common/buffer.h.
10726 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
10727 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
10728 initialize_inferiors): Delete.
10729
2275a1a7
PA
107302011-07-20 Pedro Alves <pedro@codesourcery.com>
10731
10732 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
10733 symbol error.
10734
0a5b1e09
PA
107352011-05-31 Pedro Alves <pedro@codesourcery.com>
10736
10737 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
10738 assertion.
10739 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
10740
6938fd34
YQ
107412011-05-26 Yao Qi <yao@codesourcery.com>
10742
10743 * Makefile.in (thread-db.o): Track dependence to
10744 common/gdb_thread_db.h.
10745 * thread-db.c: include gdb_thread_db.h from right place.
10746
b481f9e0
TT
107472011-05-16 Adrian Cornish <gnu@bluedreamer.com>
10748
10749 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
10750 __FILE__ and __LINE__ to internal_error.
10751
98a5dd13
DE
107522011-05-13 Doug Evans <dje@google.com>
10753
10754 * thread-db.c (try_thread_db_load_from_sdir): New function.
10755 (try_thread_db_load_from_dir): New function.
10756 (thread_db_load_search): Handle $sdir, ignore $pdir.
10757 Remove trying of system directories if search of
10758 libthread-db-search-path fails, that is now done via $sdir.
10759
d248b706
KY
107602011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
10761
10762 * server.c (handle_query): Add EnableDisableTracepoints to the list
10763 of supported features.
43aaf8b6 10764 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 10765 tracepoints.
43aaf8b6
PA
10766 (cmd_qtenable_disable): New.
10767 (cmd_qtstart): Install tracepoints even if disabled.
10768 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
10769 receiving a QTEnable or QTDisable packet.
10770 (gdb_collect): Skip data collection if fast tracepoint is disabled.
10771 (ust_marker_to_static_tracepoint): Do not ignore disabled static
10772 tracepoints.
10773 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 10774
84e578fb
DE
107752011-05-10 Doug Evans <dje@google.com>
10776
10777 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
10778
71f55dd8
DE
107792011-05-04 Doug Evans <dje@google.com>
10780
10781 * linux-low.c (linux_join): Skip process lookup.
10782 * spu-low.c (spu_join): Ditto.
10783 * server.c (join_inferiors_callback): Delete.
10784 (process_serial_event): For 'D' packet (detach) call join_inferior
10785 directly.
10786
4d393d60
JM
107872011-05-04 Joseph Myers <joseph@codesourcery.com>
10788
10789 * README: Don't mention xscale*-*-linux*.
10790 * configure.srv (xscale*-*-linux*): Don't handle target.
10791
b00ad6ff
NF
107922011-04-27 Nathan Froyd <froydnj@codesourcery.com>
10793
10794 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
10795 casting pointers.
10796 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
10797 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
10798 (i386_emit_void_call_2): Likewise.
10799
af96c192
YQ
108002011-04-26 Yao Qi <yao@codesourcery.com>
10801
43aaf8b6
PA
10802 * linux-low.c: Move common macros to linux-ptrace.h.
10803 Include linux-ptrace.h.
af96c192
YQ
10804 * Makefile.in (linux_ptrace_h): New.
10805 (linux-low.o): Depends on linux-ptrace.h.
10806
03f2bd59
JK
108072011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
10808
10809 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
10810 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
10811 (remote_prepare): New function with most of the TCP code from ...
10812 (remote_open): ... here. Detect PORT here unconditionally. Move also
10813 setting transport_is_reliable.
10814 * server.c (run_once): New variable.
10815 (gdbserver_usage): Document it.
10816 (main): Set run_once for `--once'. Call remote_prepare. Exit after
10817 the first run if RUN_ONCE.
10818 * server.h (run_once, remote_prepare): New declarations.
10819
7a9dd1b2
TT
108202011-04-19 Tom Tromey <tromey@redhat.com>
10821
10822 * win32-low.c (handle_load_dll): Remove duplicate "the".
10823
81239425
PM
108242011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
10825
10826 Remove support for old Cygwin 1.5 versions.
10827 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
10828 function to avoid warning.
10829 (win32_add_one_solib): Use cygwin_conv_path function to avoid
10830 warning.
10831
9e0627f1
PM
108322011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
10833
10834 * gdbserver/server.h (Macro _): Define it if not available.
10835
588eebee
MS
108362011-03-14 Michael Snyder <msnyder@vmware.com>
10837
348af9f7 10838 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 10839
43f70d4c
JB
108402011-03-10 Joel Brobecker <brobecker@adacore.com>
10841
10842 * Makefile.in (maintainer-clean realclean distclean): Remove
10843 "make ... subdir_do" command.
10844
348af9f7
MS
108452011-03-10 Michael Snyder <msnyder@vmware.com>
10846
10847 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
10848
10849 * server.c (handle_v_run): Free alloced buffer on early return.
10850
e637a4f5
YQ
108512011-03-09 Yao Qi <yao@codesourcery.com>
10852
10853 Revert:
10854 2011-03-04 Yao Qi <yao@codesourcery.com>
10855
10856 * Makefile.in: Remove GNU make feature --directory.
10857
10858 2011-03-05 Yao Qi <yao@codesourcery.com>
10859
10860 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
10861 (subdir_do): New make target. Copied from gdb/Makefile.
10862 (maintainer-clean, realclean, distclean, clean): Call corresponding
10863 make targets in common/Makefile.
10864
10865 2011-02-11 Yao Qi <yao@codesourcery.com>
10866
10867 * configure.ac: Call AC_PROG_RANLIB.
10868 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
10869 * configure: Regenerate.
10870
e6edda56
JK
108712011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10872
10873 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
10874
e5141119
JB
108752011-03-06 Yao Qi <yao@codesourcery.com>
10876
10877 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
10878
64794aa4
JB
108792011-03-05 Yao Qi <yao@codesourcery.com>
10880
10881 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
10882 (subdir_do): New make target. Copied from gdb/Makefile.
10883 (maintainer-clean, realclean, distclean, clean): Call corresponding
10884 make targets in common/Makefile.
10885
7a762829
YQ
108862011-03-04 Yao Qi <yao@codesourcery.com>
10887
10888 * Makefile.in: Remove GNU make feature --directory.
10889
348af9f7
MS
108902011-03-04 Michael Snyder <msnyder@vmware.com>
10891
10892 * server.c (queue_stop_reply): Call xmalloc not malloc.
10893
108942011-03-02 Michael Snyder <msnyder@vmware.com>
10895
10896 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
10897
9f72fee2
MS
108982011-02-28 Michael Snyder <msnyder@vmware.com>
10899
588eebee
MS
10900 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
10901 (cmd_qtframe): Ditto.
10902 (cmd_qtbuffer): Ditto.
10903 (cmd_bigqtbuffer): Ditto.
10904
9f72fee2
MS
10905 * utils.c (decimal2str): Initialize 'width' to nine, then
10906 don't mess with it.
10907
8040bd49
UW
109082011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
10909
10910 * hostio.c (require_data): Free *data, not data.
10911
7e52cbd0
JK
109122011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10913
10914 * hostio.c (require_data): Use free, not xfree.
10915
9130f83e
MS
109162011-02-27 Michael Snyder <msnyder@vmware.com>
10917
4b812f4e
MS
10918 * server.c (handle_query): Discard unused value.
10919
9130f83e
MS
10920 * hostio.c (require_data): Free malloc memory before returning
10921 error.
10922
69d37113
MS
109232011-02-26 Michael Snyder <msnyder@vmware.com>
10924
10925 * linux-low.c (list_threads): Call closedir for dirent.
10926
35f5825a
MS
109272011-02-27 Michael Snyder <msnyder@vmware.com>
10928
2a589cef
MS
10929 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
10930 a case statement falls through.
10931
0adea5f7
MS
10932 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
10933
35f5825a
MS
10934 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
10935 in comparison.
10936
238f1c74
MS
109372011-02-26 Michael Snyder <msnyder@vmware.com>
10938
10939 * utils.c (decimal2str): Eliminate dead code and dead param.
10940 (pulongest): Drop dead param from call to decimal2str.
10941 (plongest): Ditto.
10942
633ff500
JB
109432011-02-24 Joel Brobecker <brobecker@adacore.com>
10944
10945 Revert the following patch (not approved yet):
10946 2011-02-21 Hui Zhu <teawater@gmail.com>
10947 * tracepoint.c (tp_printf): New function.
10948 (eval_agent_expr): Handle gdb_agent_op_printf.
10949
f9c6ff72
HZ
109502011-02-21 Hui Zhu <teawater@gmail.com>
10951
10952 * tracepoint.c (tp_printf): New function.
10953 (eval_agent_expr): Handle gdb_agent_op_printf.
10954
94d5e490
TT
109552011-02-18 Tom Tromey <tromey@redhat.com>
10956
10957 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
10958 (tracepoint.o): Likewise.
10959 * tracepoint.c (enum gdb_agent_op): Use ax.def.
10960 (gdb_agent_op_names): Likewise.
10961
c7f96d2b
TT
109622011-02-18 Tom Tromey <tromey@redhat.com>
10963
10964 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
10965 gdb_agent_op_rot>: New constants.
10966 (gdb_agent_op_names): Add pick and roll.
10967 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
10968 cases.
10969
0feedb2c
JK
109702011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10971
10972 * aclocal.m4: Regenerated with aclocal-1.11.1.
10973
b3b9301e
PA
109742011-02-14 Pedro Alves <pedro@codesourcery.com>
10975
10976 * server.c (handle_qxfer_traceframe_info): New.
10977 (qxfer_packets): Register "traceframe-info".
10978 (handle_query): Report support for qXfer:traceframe-info:read+.
10979 * tracepoint.c (match_blocktype): New.
10980 (traceframe_find_block_type): Rename to ...
10981 (traceframe_walk_blocks): ... this. Add callback filter argument,
10982 and use it.
10983 (traceframe_find_block_type): New, reimplemented on top of
10984 traceframe_walk_blocks.
10985 (build_traceframe_info_xml): New.
10986 (traceframe_read_info): New.
10987 * server.h (traceframe_read_info): Declare.
10988
4f3e6fb7
YQ
109892011-02-11 Yao Qi <yao@codesourcery.com>
10990
10991 * configure.ac: Call AC_PROG_RANLIB.
10992 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
10993 * configure: Regenerate.
10994
764880b7
PA
109952011-02-07 Pedro Alves <pedro@codesourcery.com>
10996
10997 * server.c (gdb_read_memory): Change return semantics to allow
10998 partial transfers.
10999 (handle_search_memory_1): Adjust.
11000 (process_serial_event) <'m' packet>: Handle partial transfers.
11001 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
11002
1c79eb8a
PA
110032011-01-28 Pedro Alves <pedro@codesourcery.com>
11004
11005 * regcache.c (init_register_cache): Initialize
11006 regcache->register_status.
11007 (free_register_cache): Release regcache->register_status.
11008 (regcache_cpy): Copy register_status.
11009 (registers_to_string): Print 'x's for unavailable registers.
11010 (supply_register): Mark the register's status valid or
11011 unavailable, depending on whether a buffer was passed in or not.
11012 (supply_register_zeroed): New.
11013 (supply_regblock): Mark the registers' status valid or
11014 unavailable, depending on whether a buffer was passed in or not.
11015 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
11016 (struct regcache): New `register_status' field.
11017 (supply_register_zeroed): Declare.
11018 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
11019 supply_register_zeroed, rather than passing a NULL buffer to
11020 supply_register.
11021 * tracepoint.c (fetch_traceframe_registers): Update comment.
11022
85724a0e
PA
110232011-01-28 Pedro Alves <pedro@codesourcery.com>
11024
11025 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
11026 buffer explicit.
11027
d08aafef
PA
110282011-01-25 Pedro Alves <pedro@codesourcery.com>
11029
11030 * server.h (decode_xfer_write): Change prototype.
11031 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
11032 and don't extract the annex here.
11033 * server.c (decode_xfer_read): Remove `annex' parameter,
11034 and don't extract the annex here.
11035 (decode_xfer): New.
11036 (struct qxfer): New.
11037 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
11038 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
11039 (handle_qxfer_statictrace): New functions, abstracted out from
11040 handle_query, and made to use the struct qxfer interface.
11041 (handle_threads_qxfer_proper): Rename to ...
11042 (handle_qxfer_threads_proper): ... this.
11043 (handle_threads_qxfer): Rename to ...
11044 (handle_qxfer_threads): ... this. Adjust.
11045 (qxfer_packets): New array.
11046 (handle_qxfer): New function.
11047 (handle_query): Use handle_qxfer.
11048
493e2a69
MS
110492011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
11050
11051 * gdbreplay.c: Shorten lines of >= 80 columns.
11052 * linux-low.c: Ditto.
11053 * linux-ppc-low.c: Ditto.
11054 * linux-s390-low.c: Ditto.
11055 * linux-sparc-low.c: Ditto.
11056 * linux-x86-low.c: Ditto.
11057 * linux-xtensa-low.c: Ditto.
11058 * mem-break.c: Ditto.
11059 * nto-low.c: Ditto.
11060 * regcache.h: Ditto.
11061 * remote-utils.c: Ditto.
11062 * server.c: Ditto.
11063 * server.h: Ditto.
11064 * thread-db.c: Ditto.
11065 * tracepoint.c: Ditto.
11066 * utils.c: Ditto.
11067 * win32-low.h: Ditto.
11068
44944448
JB
110692011-01-05 Joel Brobecker <brobecker@adacore.com>
11070
11071 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
11072 update.
11073
71ce852c
JB
110742011-01-01 Joel Brobecker <brobecker@adacore.com>
11075
11076 * server.c (gdbserver_version): Update copyright year in version
11077 output.
11078 * gdbreplay.c (gdbreplay_version): Ditto.
11079
eb826dc6
MF
110802010-12-29 Jie Zhang <jie.zhang@analog.com>
11081
11082 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
11083 * linux-bfin-low.c: New file.
11084 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
11085 PT_DATA_ADDR for BFIN targets.
11086 * Makefile.in (SFILES): Add linux-bfin-low.c.
11087 (clean): Remove reg-bfin.c.
11088 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
11089 * README: Mention supported Blackfin targets.
11090
39ab222a
MF
110912010-12-23 Mike Frysinger <vapier@gentoo.org>
11092
11093 * .gitignore: New file.
11094
a1f2ce7d
MF
110952010-11-16 Mike Frysinger <vapier@gentoo.org>
11096
11097 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
11098
f474844c
JZ
110992010-10-22 Jie Zhang <jie@codesourcery.com>
11100
11101 * Makefile.in: Add FLAGS_TO_PASS variable.
11102 (install): Remove dependency of install-only and recursively
11103 invoke make for install-only.
11104
f1048712
DE
111052010-10-04 Doug Evans <dje@google.com>
11106
11107 * Makefile.in (uninstall): Use $(DESTDIR).
11108
b53a1623
PA
111092010-09-24 Pedro Alves <pedro@codesourcery.com>
11110
e6ee044d
PA
11111 PR gdb/11842
11112
b53a1623
PA
11113 * linux-x86-low.c (compat_siginfo_from_siginfo)
11114 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
11115 si_code is < 0. Check for si_code == SI_TIMER before checking for
11116 si_code < 0.
11117
fa1bd1e4
JB
111182010-09-13 Joel Brobecker <brobecker@adacore.com>
11119
11120 * lynx-i386-low.c: New file.
11121 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
11122
47fac8f8
JB
111232010-09-13 Joel Brobecker <brobecker@adacore.com>
11124
11125 * lynx-low.c (ptrace_request_to_str): Remove handling for
11126 request values that have been removed in LynxOS 5.x.
11127
1adfc54d
JB
111282010-09-13 Joel Brobecker <brobecker@adacore.com>
11129
11130 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
11131 <ptrace.h>
11132
c2a66c29
NS
111332010-09-09 Nathan Sidwell <nathan@codesourcery.com>
11134
11135 * configure.ac: Add --enable-inprocess-agent option.
11136 * configure: Rebuilt.
11137
32fcada3
YQ
111382010-09-06 Yao Qi <yao@codesourcery.com>
11139
11140 * linux-low.c (linux_kill): Remove unused variable.
11141 (linux_stabilize_threads): Likewise.
11142 * server.c (start_inferior): Likewise.
11143 (queue_stop_reply_callback): Likewise.
11144 * tracepoint.c (do_action_at_tracepoint): Likewise.
11145
0cccb683
YQ
111462010-09-06 Yao Qi <yao@codesourcery.com>
11147
11148 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
11149 on return.
11150
423ec54c
JK
111512010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11152
11153 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
11154
12ac6819
PA
111552010-09-06 Pedro Alves <pedro@codesourcery.com>
11156
11157 * Makefile.in (install-only): Replace $IPA_DEPFILES with
11158 "$(IPA_DEPFILES)".
11159
8ed54b31
JB
111602010-09-01 Joel Brobecker <brobecker@adacore.com>
11161
11162 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
11163 gdbserver/lynx-ppc-low.c: New files.
11164 * Makefile.in (lynx_low_h): New variable.
11165 (lynx-low.o, lynx-ppc-low.o): New rules.
11166 * configure.ac: On LynxOS, link with -lnetinet.
11167 * configure.srv: Add handling of powerpc-*-lynxos* targets.
11168 * configure: regenerate.
11169
bb0116a4
JB
111702010-09-01 Joel Brobecker <brobecker@adacore.com>
11171
11172 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
11173 * configure.ac: Add check for vasprintf and vsnprintf.
11174 * configure, config.in: Regenerate.
11175 * server.h (vasprintf, vsnprintf): Add conditional declarations.
11176
a778ab81 111772010-09-01 Joel Brobecker <brobecker@adacore.com>
11178
11179 * gdbreplay.c: Move include of alloca.h up, next to include of
11180 malloc.h.
11181 * server.h: Add include of malloc.h.
11182 * mem-break.c: Remove include of malloc.h.
11183 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
11184
8b034a19 111852010-09-01 Joel Brobecker <brobecker@adacore.com>
11186
11187 * Makefile.in (memmem.o): Build with -Wno-error.
11188
111892010-09-01 Joel Brobecker <brobecker@adacore.com>
11190
11191 * utils.c (xsnprintf): Make non-static.
11192 * server.h: Add xsnprintf declaration.
11193 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
11194 replace calls to snprintf by calls to xsnprintf throughout.
11195
111962010-09-01 Joel Brobecker <brobecker@adacore.com>
11197
11198 * configure.ac: Add configure check for alloca.
11199 * configure, config.in: Regenerate.
11200 * server.h: Include alloca.h if it exists.
11201 * gdbreplay.c: Include alloca.h if it exists.
11202
1a981360
PA
112032010-08-28 Pedro Alves <pedro@codesourcery.com>
11204
11205 * linux-low.c (__SIGRTMIN): Define if not already defined.
11206 (linux_create_inferior): Check for __ANDROID__ rather than
11207 __SIGRTMIN.
11208 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
11209 are already deferred.
11210 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
11211 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
11212 stopped and already has a pending signal to report.
11213 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
11214 a pending signal to report or is moving out of a jump pad.
11215 (linux_init_signals): Check for __ANDROID__ rather than
11216 __SIGRTMIN.
11217
b4d51a55
PA
112182010-08-28 Pedro Alves <pedro@codesourcery.com>
11219
11220 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
11221 debug_threads check. Avoid a linear search when not doing debug
11222 output.
11223
ec48365d
PA
112242010-08-27 Pedro Alves <pedro@codesourcery.com>
11225
11226 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
11227 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
11228 (struct file_handler) <fd>: Change type to gdb_fildes_t.
11229 (process_event): Change local fd's type to gdb_fildes_t.
11230 (create_file_handler): Adjust prototype.
11231 (delete_file_handler): Adjust prototype.
11232 (handle_file_event): Adjust prototype. Use pfildes.
11233 (create_file_event): Adjsut prototype.
11234 * remote-utils.c (remote_desc, listen_desc): Change type to
11235 gdb_fildes_t.
11236 * server.h: New gdb_fildes_t typedef.
11237 [USE_WIN32API]: Include winsock2.h.
11238 (delete_file_handler, add_file_handler): Adjust prototypes.
11239 (pfildes): Declare.
11240 * utils.c (pfildes): New.
11241
854d88f0
PA
112422010-08-27 Pedro Alves <pedro@codesourcery.com>
11243
11244 * configure.ac (build_warnings): Add -Wno-char-subscripts.
11245 * configure: Regenerate.
11246
0146f85b
PA
112472010-08-27 Pedro Alves <pedro@codesourcery.com>
11248
11249 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
11250 (linux_done_accessing_memory): ... this.
11251 (linux_target_ops): Adjust.
11252 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
11253 * nto-low.c (nto_target_ops): Adjust comment.
11254 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
11255 * spu-low.c (spu_target_ops): Adjust comment.
11256 * target.h (target_ops): Rename unprepare_to_access_memory field
11257 to done_accessing_memory.
11258 (unprepare_to_access_memory): Rename to ...
11259 (done_accessing_memory): ... this.
11260
90d74c30
PA
112612010-08-26 Pedro Alves <pedro@codesourcery.com>
11262
11263 * linux-low.c (linux_prepare_to_access_memory): New.
11264 (linux_unprepare_to_access_memory): New.
11265 (linux_target_ops): Install them.
11266 * server.c (read_memory): Rename to ...
11267 (gdb_read_memory): ... this. Use
11268 prepare_to_access_memory/prepare_to_access_memory.
11269 (write_memory): Rename to ...
11270 (gdb_write_memory): ... this. Use
11271 prepare_to_access_memory/prepare_to_access_memory.
11272 (handle_search_memory_1): Adjust.
11273 (process_serial_event): Adjust.
11274 * target.h (struct target_ops): New fields
11275 prepare_to_access_memory and unprepare_to_access_memory.
11276 (prepare_to_access_memory, unprepare_to_access_memory): New.
11277 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
11278 prepare_to_access_memory/prepare_to_access_memory.
11279 * nto-low.c (nto_target_ops): Adjust.
11280 * spu-low.c (spu_target_ops): Adjust.
11281 * win32-low.c (win32_target_ops): Adjust.
11282
fd467969
PA
112832010-08-26 Pedro Alves <pedro@codesourcery.com>
11284
11285 * Makefile.in (WARN_CFLAGS): Get it from configure.
11286 (WERROR_CFLAGS): New.
11287 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
11288 * configure.ac: Introduce --enable-werror, which adds -Werror to
11289 the compiler command line. Enabled by default. Disable with
11290 --disable-werror. Add -Wdeclaration-after-statement
11291 Wpointer-arith and -Wformat-nonliteral to warning flags.
11292 * configure: Regenerate.
11293
331e2f5f
PA
112942010-08-26 Pedro Alves <pedro@codesourcery.com>
11295
11296 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
11297
e581f2b4
PA
112982010-08-26 Pedro Alves <pedro@codesourcery.com>
11299
11300 * gdbreplay.c (remote_error): New.
11301 (gdbchar): New.
11302 (expect): Use gdbchar. Check for error reading from GDB.
11303 Clarify sync error output.
11304 (play): Check for errors writing to GDB.
11305 * linux-low.c (sigchld_handler): Really ignore `write' errors.
11306 * remote-utils.c (getpkt): Check for errors writing to the remote
11307 descriptor.
11308
3c11dd79
PA
113092010-08-25 Pedro Alves <pedro@codesourcery.com>
11310
11311 * linux-low.c (linux_wait_1): Move non-debugging code out of
11312 `debug_threads' control.
11313
d20a8ad9
PA
113142010-08-25 Pedro Alves <pedro@codesourcery.com>
11315
11316 * linux-low.c (linux_wait_1): Don't set last_status here.
11317 * server.c (push_event, queue_stop_reply_callback): Assert we're
11318 not pushing a TARGET_WAITKIND_IGNORE event.
11319 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
11320 (myresume, handle_target_event): Set the thread's last_resume_kind
11321 and last_status from the target returned status.
11322
964e4306
PA
113232010-08-25 Pedro Alves <pedro@codesourcery.com>
11324
11325 PR threads/10729
11326
11327 * linux-x86-low.c (update_debug_registers_callback): New.
11328 (i386_dr_low_set_addr): Use it.
11329 (i386_dr_low_get_addr): New.
11330 (i386_dr_low_set_control): Use update_debug_registers_callback.
11331 (i386_dr_low_get_control): New.
11332 (i386_dr_low_get_status): Adjust.
11333 * linux-low.c (linux_stop_lwp): New.
11334 * linux-low.h (linux_stop_lwp): Declare.
11335
11336 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
11337 argument instead of a i386_debug_reg_state.
11338 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
11339 a i386_debug_reg_state.
11340 (i386_insert_aligned_watchpoint): Adjust.
11341 (i386_remove_aligned_watchpoint): Adjust.
11342 (i386_low_stopped_data_address): Read the debug registers from the
11343 inferior instead of from the mirrors.
11344 * i386-low.h (struct i386_debug_reg_state): Extend comment.
11345 (i386_dr_low_get_addr): Declare.
11346 (i386_dr_low_get_control): Declare.
11347 (i386_dr_low_get_status): Change prototype.
11348
11349 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
11350 (i386_dr_low_get_addr): New.
11351 (i386_dr_low_get_control): New.
11352 (i386_dr_low_get_status): Adjust prototype. Return
11353 dr_status_mirror.
11354 (i386_initial_stuff): Clear dr_status_mirror and
11355 dr_control_mirror.
11356 (i386_get_thread_context): Adjust.
11357 (i386_set_thread_context): Adjust.
11358 (i386_thread_added): Adjust.
11359
5f21a75b
PA
113602010-08-24 Pedro Alves <pedro@codesourcery.com>
11361
11362 * linux-low.h (linux_thread_area): Delete declaration.
11363
3e4c1235
TS
113642010-08-11 Thomas Schwinge <thomas@codesourcery.com>
11365
11366 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
11367 after its termination.
11368
1971b033
PA
113692010-08-09 Pedro Alves <pedro@codesourcery.com>
11370
11371 * linux-low.c (gdb_wants_lwp_stopped): Delete.
11372 (gdb_wants_all_stopped): Delete.
11373 (linux_wait_1): Don't call them.
11374 * server.c (handle_v_cont): Tag all threads as want-stopped.
11375 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
11376 stopped as "client-wants-stopped".
11377
310444ac
PA
113782010-07-31 Pedro Alves <pedro@codesourcery.com>
11379
11380 * Makefile.in (signals_h): New.
11381 (server_h): Depend on it.
11382 (server.o): Don't depend on $(signals_def).
11383 (signals.o): Depend on $(signals_def).
11384
a19cae16
JK
113852010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
11386
11387 * Makefile.in (signals_def): New.
11388 (server_h): Append include/gdb/signals.h and signals_def.
11389 (server.o): Append signals_def.
11390
30d50328
JK
113912010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11392
11393 * server.c (handle_target_event): Use target_signal_to_host for
11394 resume_info.sig initialization.
11395 * target.h (struct thread_resume) <sig>: New comment.
11396
5c3216e2
OS
113972010-07-20 Ozkan Sezer <sezeroz@gmail.com>
11398
c6f46ca0
OS
11399 * server.c (handle_query): strcpy() the returned string from paddress()
11400 instead of sprintf().
5c3216e2
OS
11401 * utils.c (paddress): Return phex_nz().
11402
6bd31874
JB
114032010-07-07 Joel Brobecker <brobecker@adacore.com>
11404
11405 * server.c (handle_v_cont): Call mourn_inferior if process
11406 just exited.
11407 (myresume): Likewise.
11408
0fb4aa4b
PA
114092010-07-01 Pedro Alves <pedro@codesourcery.com>
11410
11411 Static tracepoints, and integration with UST.
11412
11413 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
11414 * mem-break.c (uninsert_all_breakpoints)
11415 (reinsert_all_breakpoints): New.
11416 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
11417 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
11418 (gdb_agent_ust_loaded, helper_thread_id)
11419 (gdb_agent_helper_thread_id): New macros.
11420 (struct ipa_sym_addresses): Add addr_ust_loaded,
11421 addr_helper_thread_id, addr_cmd_buf.
11422 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
11423 (in_process_agent_loaded_ust): New.
11424 (write_e_ust_not_loaded): New.
11425 (maybe_write_ipa_ust_not_loaded): New.
11426 (struct collect_static_trace_data_action): New.
11427 (enum tracepoint_type) <static_tracepoint>: New.
11428 (struct tracepoint) <handle>: Mention static tracepoints.
11429 (struct static_tracepoint_ctx): New.
11430 (CMD_BUF_SIZE): New.
11431 (add_tracepoint_action): Handle static tracepoint actions.
11432 (unprobe_marker_at): New.
11433 (clear_installed_tracepoints): Handle static tracepoints.
11434 (cmd_qtdp): Handle static tracepoints.
11435 (probe_marker_at): New.
11436 (cmd_qtstart): Handle static tracepoints.
11437 (response_tracepoint): Handle static tracepoints.
11438 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
11439 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
11440 (get_context_regcache): Handle static tracepoints.
11441 (do_action_at_tracepoint): Handle static tracepoint actions.
11442 (traceframe_find_block_type): Handle static trace data blocks.
11443 (traceframe_read_sdata): New.
11444 (download_tracepoints): Download static tracepoint actions.
11445 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
11446 (GDB_PROBE_NAME): New.
11447 (ust_ops): New.
11448 (GET_UST_SYM): New.
11449 (USTF): New.
11450 (dlsym_ust): New.
11451 (ust_marker_to_static_tracepoint): New.
11452 (gdb_probe): New.
11453 (collect_ust_data_at_tracepoint): New.
11454 (gdb_ust_probe): New.
11455 (UNIX_PATH_MAX, SOCK_DIR): New.
11456 (gdb_ust_connect_sync_socket): New.
11457 (resume_thread, stop_thread): New.
11458 (run_inferior_command): New.
11459 (init_named_socket): New.
11460 (gdb_ust_socket_init): New.
11461 (cstr_to_hexstr): New.
11462 (next_st): New.
11463 (first_marker, next_marker): New.
11464 (response_ust_marker): New.
11465 (cmd_qtfstm, cmd_qtsstm): New.
11466 (unprobe_marker_at, probe_marker_at): New.
11467 (cmd_qtstmat, gdb_ust_thread): New.
11468 (gdb_ust_init): New.
11469 (initialize_tracepoint_ftlib): Call gdb_ust_init.
11470 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
11471 (ST_REGENTRY): New.
11472 (x86_64_st_collect_regmap): New.
11473 (X86_64_NUM_ST_COLLECT_GREGS): New.
11474 (AMD64_RIP_REGNUM): New.
11475 (supply_static_tracepoint_registers): New.
11476 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
11477 (ST_REGENTRY): New.
11478 (i386_st_collect_regmap): New.
11479 (i386_NUM_ST_COLLECT_GREGS): New.
11480 (supply_static_tracepoint_registers): New.
11481 * server.c (handle_query): Handle qXfer:statictrace:read.
11482 <qSupported>: Report support for StaticTracepoints, and
11483 qXfer:statictrace:read features.
11484 * server.h (traceframe_read_sdata)
11485 (supply_static_tracepoint_registers): Declare.
11486 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
11487 (unpack_varlen_hex): Include in IPA build.
11488 * Makefile.in (ustlibs, ustinc): New.
11489 (IPA_OBJS): Add remote-utils-ipa.o.
11490 ($(IPA_LIB)): Link -ldl and -lpthread.
11491 (UST_CFLAGS): New.
11492 (IPAGENT_CFLAGS): Add UST_CFLAGS.
11493 * config.in, configure: Regenerate.
11494
9e4344e5
PA
114952010-06-20 Ian Lance Taylor <iant@google.com>
11496 Pedro Alves <pedro@codesourcery.com>
11497
11498 * linux-x86-low.c (always_true): Delete.
11499 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
11500 trying to fool the compiler with always_true.
11501
c6beb2cb
PA
115022010-06-20 Pedro Alves <pedro@codesourcery.com>
11503
11504 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
11505 conditions in gdbserver.
11506
d2ed6730
UW
115072010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
11508
11509 * spu-low.c (spu_read_memory): Wrap around local store limit.
11510 (spu_write_memory): Likewise.
11511
4e29fb54
PA
115122010-06-15 Pedro Alves <pedro@codesourcery.com>
11513
11514 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
11515 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
11516 LONGEST uses.
11517 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
11518 uses.
11519 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
11520 uses with LONGEST uses.
11521
6a271cae
PA
115222010-06-14 Stan Shebs <stan@codesourcery.com>
11523 Pedro Alves <pedro@codesourcery.com>
11524
11525 Bytecode compiler.
11526
11527 * linux-x86-low.c: Include limits.h.
11528 (add_insns): New.
11529 (always_true): New.
11530 (EMIT_ASM): New.
11531 (EMIT_ASM32): New.
11532 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
11533 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
11534 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
11535 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
11536 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
11537 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
11538 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
11539 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
11540 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
11541 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
11542 (amd64_emit_void_call_2): New.
11543 (amd64_emit_ops): New.
11544 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
11545 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
11546 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
11547 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
11548 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
11549 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
11550 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
11551 (i386_emit_call, i386_emit_reg, i386_emit_pop)
11552 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
11553 (i386_emit_stack_adjust, i386_emit_int_call_1)
11554 (i386_emit_void_call_2): New.
11555 (i386_emit_ops): New.
11556 (x86_emit_ops): New.
11557 (the_low_target): Install x86_emit_ops.
11558 * server.h (struct emit_ops): New.
11559 (get_raw_reg_func_addr): Declare.
11560 (current_insn_ptr, emit_error): Declare.
11561 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
11562 (set_trace_state_variable_value): New defines.
11563 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
11564 addr_get_trace_state_variable_value and
11565 addr_set_trace_state_variable_value.
11566 (symbol_list): New fields for get_raw_reg,
11567 get_trace_state_variable_value and set_trace_state_variable_value.
11568 (condfn): New typedef.
11569 (struct tracepoint): New field `compiled_cond'.
11570 (do_action_at_tracepoint): Clear compiled_cond.
11571 (get_trace_state_variable_value, set_trace_state_variable_value):
11572 Export in the IPA.
11573 (condition_true_at_tracepoint): If there's a compiled condition,
11574 run that.
11575 (current_insn_ptr, emit_error): New globals.
11576 (struct bytecode_address): New.
11577 (get_raw_reg_func_addr): New.
11578 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
11579 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
11580 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
11581 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
11582 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
11583 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
11584 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
11585 (compile_tracepoint_condition, compile_bytecodes): New.
11586 * target.h (emit_ops): Forward declare.
11587 (struct target_ops): New field emit_ops.
11588 (target_emit_ops): New.
11589 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
11590 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
11591 * linux-low.c (linux_emit_ops): New.
11592 (linux_target_ops): Install it.
11593 * linux-low.h (struct linux_target_ops): New field emit_ops.
11594
92b72907
UW
115952010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
11596
11597 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
11598 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
11599
fa593d66
PA
116002010-06-01 Pedro Alves <pedro@codesourcery.com>
11601 Stan Shebs <stan@codesourcery.com>
11602
11603 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
11604 (all): Depend on $(extra_libraries).
11605 (install-only): Install the IPA.
11606 (IPA_OBJS, IPA_LIB): New.
11607 (clean): Remove the IPA lib.
11608 (IPAGENT_CFLAGS): New.
11609 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
11610 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
11611 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
11612 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
11613 * configure.ac: Check for atomic builtins support in the compiler.
11614 (IPA_DEPFILES, extra_libraries): Define.
11615 * configure.srv (ipa_obj): Add description.
11616 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
11617 (i[34567]86-*-linux*): Set ipa_obj.
11618 (x86_64-*-linux*): Set ipa_obj.
11619 * linux-low.c (stabilizing_threads): New.
11620 (supports_fast_tracepoints): New.
11621 (linux_detach): Stabilize threads before detaching.
11622 (handle_tracepoints): Handle internal tracing breakpoints. Assert
11623 the lwp is either not stabilizing, or is moving out of a jump pad.
11624 (linux_fast_tracepoint_collecting): New.
11625 (maybe_move_out_of_jump_pad): New.
11626 (enqueue_one_deferred_signal): New.
11627 (dequeue_one_deferred_signal): New.
11628 (linux_wait_for_event_1): If moving out of a jump pad, defer
11629 pending signals to later.
11630 (linux_stabilize_threads): New.
11631 (linux_wait_1): Check if threads need moving out of jump pads, and
11632 do it if so.
11633 (stuck_in_jump_pad_callback): New.
11634 (move_out_of_jump_pad_callback): New.
11635 (lwp_running): New.
11636 (linux_resume_one_lwp): Handle moving out of jump pads.
11637 (linux_set_resume_request): Dequeue deferred signals.
11638 (need_step_over_p): Also step over fast tracepoint jumps.
11639 (start_step_over): Also uninsert fast tracepoint jumps.
11640 (finish_step_over): Also reinsert fast tracepoint jumps.
11641 (linux_install_fast_tracepoint_jump): New.
11642 (linux_target_ops): Install linux_stabilize_threads and
11643 linux_install_fast_tracepoint_jump_pad.
11644 * linux-low.h (linux_target_ops) <get_thread_area,
11645 install_fast_tracepoint_jump_pad>: New fields.
11646 (struct lwp_info) <collecting_fast_tracepoint,
11647 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
11648 (linux_get_thread_area): Declare.
11649 * linux-x86-low.c (jump_insn): New.
11650 (x86_get_thread_area): New.
11651 (append_insns): New.
11652 (push_opcode): New.
11653 (amd64_install_fast_tracepoint_jump_pad): New.
11654 (i386_install_fast_tracepoint_jump_pad): New.
11655 (x86_install_fast_tracepoint_jump_pad): New.
11656 (the_low_target): Install x86_get_thread_area and
11657 x86_install_fast_tracepoint_jump_pad.
11658 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
11659 (struct fast_tracepoint_jump): New.
11660 (fast_tracepoint_jump_insn): New.
11661 (fast_tracepoint_jump_shadow): New.
11662 (find_fast_tracepoint_jump_at): New.
11663 (fast_tracepoint_jump_here): New.
11664 (delete_fast_tracepoint_jump): New.
11665 (set_fast_tracepoint_jump): New.
11666 (uninsert_fast_tracepoint_jumps_at): New.
11667 (reinsert_fast_tracepoint_jumps_at): New.
11668 (set_breakpoint_at): Use write_inferior_memory.
11669 (uninsert_raw_breakpoint): Use write_inferior_memory.
11670 (check_mem_read): Mask out fast tracepoint jumps.
11671 (check_mem_write): Mask out fast tracepoint jumps.
11672 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
11673 (set_fast_tracepoint_jump): Declare.
11674 (delete_fast_tracepoint_jump)
11675 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
11676 (reinsert_fast_tracepoint_jumps_at): Declare.
11677 * regcache.c: Don't compile many functions when building the
11678 in-process agent library.
11679 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
11680 the register buffer in the heap.
11681 (free_register_cache): If the register buffer isn't owned by the
11682 regcache, don't free it.
11683 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
11684 pre-existing register caches.
11685 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
11686 type.
11687 (convert_ascii_to_int): : Constify `from' parameter type.
11688 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
11689 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
11690 the needed buffer in-place.
11691 (relocate_instruction): New.
11692 * server.c (handle_query) <qSymbols>: If the target supports
11693 tracepoints, give it a chance of looking up symbols. Report
11694 support for fast tracepoints.
11695 (handle_status): Stabilize threads.
11696 (process_serial_event): Adjust.
11697 * server.h (struct fast_tracepoint_jump): Forward declare.
11698 (struct process_info) <fast_tracepoint_jumps>: New field.
11699 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
11700 (decode_X_packet, decode_M_packet): Adjust.
11701 (relocate_instruction): Declare.
11702 (in_process_agent_loaded): Declare.
11703 (tracepoint_look_up_symbols): Declare.
11704 (struct fast_tpoint_collect_status): Declare.
11705 (fast_tracepoint_collecting): Declare.
11706 (force_unlock_trace_buffer): Declare.
11707 (handle_tracepoint_bkpts): Declare.
11708 (initialize_low_tracepoint)
11709 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
11710 * target.h (struct target_ops) <stabilize_threads,
11711 install_fast_tracepoint_jump_pad>: New fields.
11712 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
11713 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
11714 [HAVE_STDINT_H]: Include stdint.h.
11715 (trace_debug_1): Rename to ...
11716 (trace_vdebug): ... this.
11717 (trace_debug): Rename to ...
11718 (trace_debug_1): ... this. Add `level' parameter.
11719 (trace_debug): New.
11720 (ATTR_USED, ATTR_NOINLINE): New.
11721 (IP_AGENT_EXPORT): New.
11722 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11723 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
11724 (about_to_request_buffer_space, trace_buffer_is_full)
11725 (stopping_tracepoint, expr_eval_result, error_tracepoint)
11726 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
11727 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
11728 (traceframe_write_count, traceframes_created)
11729 (trace_state_variables)
11730 New renaming defines.
11731 (struct ipa_sym_addresses): New.
11732 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
11733 (symbol_list): New.
11734 (ipa_sym_addrs): New.
11735 (all_tracepoint_symbols_looked_up): New.
11736 (in_process_agent_loaded): New.
11737 (write_e_ipa_not_loaded): New.
11738 (maybe_write_ipa_not_loaded): New.
11739 (tracepoint_look_up_symbols): New.
11740 (debug_threads) [IN_PROCESS_AGENT]: New.
11741 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
11742 (UNKNOWN_SIDE_EFFECTS): New.
11743 (stop_tracing): New.
11744 (flush_trace_buffer): New.
11745 (stop_tracing_bkpt): New.
11746 (flush_trace_buffer_bkpt): New.
11747 (read_inferior_integer): New.
11748 (read_inferior_uinteger): New.
11749 (read_inferior_data_pointer): New.
11750 (write_inferior_data_pointer): New.
11751 (write_inferior_integer): New.
11752 (write_inferior_uinteger): New.
11753 (struct collect_static_trace_data_action): Delete.
11754 (enum tracepoint_type): New.
11755 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
11756 <actions_str, step_actions, step_actions_str>: Only include in
11757 GDBserver.
fa593d66
PA
11758 <orig_size, obj_addr_on_target, adjusted_insn_addr>
11759 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
11760 (tracepoints): Use IP_AGENT_EXPORT.
11761 (last_tracepoint): Don't include in the IPA.
11762 (stopping_tracepoint): Use IP_AGENT_EXPORT.
11763 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
11764 (alloced_trace_state_variables): New.
11765 (trace_state_variables): Use IP_AGENT_EXPORT.
11766 (traceframe_t): Delete unused variable.
11767 (circular_trace_buffer): Don't include in the IPA.
11768 (trace_buffer_start): Delete.
11769 (struct trace_buffer_control): New.
11770 (trace_buffer_free): Delete.
11771 (struct ipa_trace_buffer_control): New.
11772 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
11773 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
11774 New.
11775 (trace_buffer_ctrl): New.
11776 (TRACE_BUFFER_CTRL_CURR): New.
11777 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
11778 Reimplement as macros.
11779 (trace_buffer_wrap): Delete.
11780 (traceframe_write_count, traceframe_read_count)
11781 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
11782 (struct tracepoint_hit_ctx) <type>: New field.
11783 (struct fast_tracepoint_ctx): New.
11784 (memory_barrier): New.
11785 (cmpxchg): New.
11786 (record_tracepoint_error): Update atomically in the IPA.
11787 (clear_inferior_trace_buffer): New.
11788 (about_to_request_buffer_space): New.
11789 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
11790 updating the same buffer.
11791 (add_tracepoint): Default the tracepoint's type to trap
11792 tracepoint, and orig_size to -1.
11793 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
11794 internal variables.
11795 (create_trace_state_variable): New parameter `gdb'. Handle it.
11796 (clear_installed_tracepoints): Clear fast tracepoint jumps.
11797 (cmd_qtdp): Handle fast tracepoints.
11798 (cmd_qtdv): Adjust.
11799 (max_jump_pad_size): New.
11800 (gdb_jump_pad_head): New.
11801 (get_jump_space_head): New.
11802 (claim_jump_space): New.
11803 (sort_tracepoints): New.
11804 (MAX_JUMP_SIZE): New.
11805 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
11806 IPA.
11807 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
11808 support. Upload fast traceframes, and delete internal IPA
11809 breakpoints.
11810 (stop_tracing_handler): New.
11811 (flush_trace_buffer_handler): New.
11812 (cmd_qtstop): Upload fast tracepoints.
11813 (response_tracepoint): Handle fast tracepoints.
11814 (tracepoint_finished_step): Upload fast traceframes. Set the
11815 tracepoint hit context's tracepoint type.
11816 (handle_tracepoint_bkpts): New.
11817 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
11818 type. Add comment about fast tracepoints.
11819 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
11820 non-existing action_str field.
11821 (get_context_regcache): Handle fast tracepoints.
11822 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
11823 to the regcache.
11824 (fast_tracepoint_from_jump_pad_address): New.
11825 (fast_tracepoint_from_ipa_tpoint_address): New.
11826 (collecting_t): New.
11827 (force_unlock_trace_buffer): New.
11828 (fast_tracepoint_collecting): New.
11829 (collecting): New.
11830 (gdb_collect): New.
11831 (write_inferior_data_ptr): New.
11832 (target_tp_heap): New.
11833 (target_malloc): New.
11834 (download_agent_expr): New.
11835 (UALIGN): New.
11836 (download_tracepoints): New.
11837 (download_trace_state_variables): New.
11838 (upload_fast_traceframes): New.
11839 (IPA_FIRST_TRACEFRAME): New.
11840 (IPA_NEXT_TRACEFRAME_1): New.
11841 (IPA_NEXT_TRACEFRAME): New.
11842 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
11843 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
11844 (gdb_jump_pad_buffer_end): New.
11845 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
11846 (initialize_tracepoint): Adjust.
11847 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
11848 buffer. Initialize the low module.
11849 * utils.c (PREFIX, TOOLNAME): New.
11850 (malloc_failure): Use PREFIX.
11851 (error): In the IPA, an error causes an exit.
11852 (fatal, warning): Use PREFIX.
11853 (internal_error): Use TOOLNAME.
11854 (NUMCELLS): Increase to 10.
11855 * configure, config.in: Regenerate.
11856
d149dd1d
PA
118572010-06-01 Pedro Alves <pedro@codesourcery.com>
11858
11859 * server.c (handle_query) <qSupported>: Do two passes over the
11860 qSupported string to avoid nesting strtok.
11861
f6528abd
JK
118622010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11863
11864 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
11865 (CDEPS): New.
11866 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
11867 -Wl,--dynamic-list.
11868 * configure: Regenerate.
11869 * proc-service.list: New.
11870
ca2a87a0
JK
118712010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11872
11873 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
11874 New comment.
11875
363a6e9f
OS
118762010-05-26 Ozkan Sezer <sezeroz@gmail.com>
11877
11878 * gdbreplay.c (remote_open): Check error return from socket() call by
11879 its equality to -1 not by it being negative.
11880 * remote-utils.c (remote_open): Likewise.
11881
d23b6cb1
PA
118822010-05-23 Pedro Alves <pedro@codesourcery.com>
11883
11884 * config.h: Regenerate.
11885
28d3cf85
MK
118862010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
11887
11888 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
11889 doesn't provide PTRACE_GET_THREAD_AREA.
11890
fea36a59
MK
118912010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
11892
11893 * linux-m68k-low.c: Include <asm/ptrace.h>
11894 (ps_get_thread_area): Implement.
11895
24b066ba
DE
118962010-05-03 Doug Evans <dje@google.com>
11897
11898 * event-loop.c (struct callback_event): New struct.
11899 (callback_list): New global.
11900 (append_callback_event, delete_callback_event): New functions.
11901 (process_callback): New function.
11902 (start_event_loop): Call it.
11903 * remote-utils.c (NOT_SCHEDULED): Define.
11904 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
11905 moved out of readchar.
11906 (readchar): Rewrite. Call reschedule before returning.
11907 (reset_readchar): New function.
11908 (remote_close): Call it.
11909 (process_remaining, reschedule): New functions.
11910 * server.h (callback_handler_func): New typedef.
11911 (append_callback_event, delete_callback_event): Declare.
11912
9836d6ea
PA
119132010-05-03 Pedro Alves <pedro@codesourcery.com>
11914
11915 * proc-service.c (ps_pglobal_lookup): Use
11916 thread_db_look_up_one_symbol.
11917 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
11918 parameter. Use it instead of all_symbols_looked_up.
11919 * server.h (struct process_info) <all_symbols_looked_up>: Delete
11920 field.
11921 (all_symbols_looked_up): Don't declare.
11922 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
11923 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
11924 field.
11925 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
11926 Set all_symbols_looked_up here.
11927 (thread_db_look_up_one_symbol): New.
11928 (thread_db_get_tls_address): Adjust.
11929 (thread_db_load_search, try_thread_db_load_1): Always allocate the
11930 thread_db object on the heap, and tentatively set it in the
11931 process structure.
11932 (thread_db_init): Don't set all_symbols_looked_up here.
11933 * linux-low.h (thread_db_look_up_one_symbol): Declare.
11934
7984d532
PA
119352010-05-03 Pedro Alves <pedro@codesourcery.com>
11936
11937 * linux-low.c (linux_kill, linux_detach): Adjust.
11938 (status_pending_p_callback): Remove redundant statement. Check
11939 for !TARGET_WAITIKIND_IGNORE, instead of
11940 TARGET_WAITKIND_STOPPED.
11941 (handle_tracepoints): Make sure LWP is locked. Adjust.
11942 (linux_wait_for_event_1): Adjust.
11943 (linux_cancel_breakpoints): New.
11944 (unsuspend_one_lwp): New.
11945 (unsuspend_all_lwps): New.
11946 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
11947 (send_sigstop_callback): Change return type to int, add new
11948 `except' parameter and handle it.
11949 (suspend_and_send_sigstop_callback): New.
11950 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
11951 pass them down. If SUSPEND, also increment the lwp's suspend
11952 count.
11953 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
11954 (need_step_over_p): Don't consider suspended LWPs.
11955 (start_step_over): Adjust.
11956 (proceed_one_lwp): Change return type to int, add new `except'
11957 parameter and handle it.
11958 (unsuspend_and_proceed_one_lwp): New.
11959 (proceed_all_lwps): Use find_inferior instead of
11960 for_each_inferior.
11961 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
11962 also decrement the suspend count of LWPs. Pass `except' down,
11963 instead of hacking its suspend count.
11964 (linux_pause_all): Add `freeze' parameter. Adjust.
11965 (linux_unpause_all): New.
11966 (linux_target_ops): Install linux_unpause_all.
11967 * server.c (handle_status): Adjust.
11968 * target.h (struct target_ops): New fields `unpause_all' and
11969 `cancel_breakpoints'. Add new parameter to `pause_all'.
11970 (pause_all): Add new `freeze' parameter.
11971 (unpause_all): New.
11972 (cancel_breakpoints): New.
11973 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
11974 cancel breakpoints.
11975 (cmd_qtstart): Pause threads.
11976 (stop_tracing): Pause threads, and cancel breakpoints.
11977 * win32-low.c (win32_target_ops): Adjust.
11978
e471f25b
PA
119792010-05-03 Pedro Alves <pedro@codesourcery.com>
11980
11981 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
11982 the inferior right away from here...
11983 (linux_wait_1): ... to here, and adjust to check the thread's
11984 last_resume_kind instead of the lwp's step or stop_expected flags.
11985
1915ef4f
PA
119862010-05-02 Pedro Alves <pedro@codesourcery.com>
11987
11988 * README: Use consistent `GDB' and `GDBserver' spellings.
11989
f9e39928
PA
119902010-05-02 Pedro Alves <pedro@codesourcery.com>
11991
11992 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
11993 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
11994 (linux_detach_one_lwp): Assume the lwp is stopped.
11995 (any_thread_of): Delete.
11996 (linux_detach): Stop all lwps here. Don't blindly delete all
11997 breakpoints.
11998 (delete_lwp_callback): New.
11999 (linux_mourn): Delete all lwps of the process that is gone.
12000 (linux_wait_1): Don't delete the last lwp of the process here.
12001 * mem-break.h (mark_breakpoints_out): Declare.
12002 * mem-break.c (mark_breakpoints_out): New.
12003 (free_all_breakpoints): Use it.
12004 * server.c (handle_target_event): If the process is gone, mark
12005 breakpoints out.
12006 * thread-db.c (struct thread_db) <create_bp>: New field.
12007 (thread_db_enable_reporting): Fix prototype. Store a thread event
12008 breakpoint reference in the thread_db struct.
12009 (thread_db_load_search): Clear the thread_db object.
12010 (try_thread_db_load_1): Ditto.
12011 (switch_to_process): New.
12012 (disable_thread_event_reporting): Use it.
12013 (remove_thread_event_breakpoints): New.
12014 (thread_db_detach, thread_db_mourn): Use it.
12015
1e7fc18c
PA
120162010-05-01 Pedro Alves <pedro@codesourcery.com>
12017
12018 * linux-low.c (linux_enable_event_reporting): New.
12019 (linux_wait_for_event_1, handle_extended_wait): Use it.
12020
02fc4de7
PA
120212010-04-30 Pedro Alves <pedro@codesourcery.com>
12022
12023 * linux-low.c (linux_kill_one_lwp, linux_kill)
12024 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
12025 (send_sigstop): Take an lwp_info as parameter instead. Queue a
12026 SIGSTOP even if the LWP is stopped.
12027 (send_sigstop_callback): New.
12028 (stop_all_lwps): Use send_sigstop_callback instead.
12029 (linux_resume_one_thread): Adjust.
12030 (proceed_one_lwp): Still proceed an LWP that the client has
12031 requested to stop, if we haven't reported it as stopped yet. Make
12032 sure that LWPs the client want stopped, have a pending SIGSTOP.
12033
bc3b5632
DE
120342010-04-26 Doug Evans <dje@google.com>
12035
ae1ada35
DE
12036 * server.c (handle_general_set): Make static.
12037
bc3b5632
DE
12038 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
12039 Print received char after testing for error/eof instead of before.
12040 (input_interrupt): Tweak comment.
12041
65730243
DE
120422010-04-23 Doug Evans <dje@google.com>
12043
12044 * server.c (start_inferior): Print inferior argv if --debug.
12045
a8ae7dc0
AR
120462010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
12047
12048 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
12049 * nto-x86-low.c: Include server.h
12050
1c07cc19
PM
120512010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
12052
12053 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
12054 be consistent with other sources of this directory.
12055 (init_registers_amd64): Correct name of source file of this function
12056 in the comment.
12057
e0a61e09
PM
120582010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12059
12060 * configure.srv (x86_64-*-mingw*): New configuration for Windows
12061 64-bit executables.
12062
54709339
PM
120632010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12064
12065 * win32-i386-low.c: Add 64-bit support.
12066 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
12067 (init_registers_amd64): Declare.
12068 (mappings): Add 64-bit version of array.
12069 (init_windows_x86): New function.
12070 (the_low_target): Change init_arch field to init_windows_x86.
12071
e8f0053d
PM
120722010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12073
12074 * win32-low.c: Adapt to support also 64-bit architecture.
12075 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
12076 (get_image_name): Use SIZE_T type for local variable `done'.
12077 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
12078 (toolhelp_get_dll_name): Idem.
12079 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
12080 Use uintptr_t typecast to avoid warning.
12081 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
12082 (handle_exception): Use phex_nz to avoid warning.
12083 (win32_wait): Remove unused local variable `process'.
12084
c481e77e
PM
120852010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12086
12087 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
12088 `amd64-avx.o'.
12089
12ea4b69
PM
120902010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
12091
12092 * configure.ac: Use `ws2_32' library for srv_mingw.
12093 * configure: Regenerate.
12094 * gdbreplay.c: Include winsock2.h instead of winsock.h.
12095 * remote-utils.c: Likewise.
12096
f6d1620c
L
120972010-04-17 H.J. Lu <hongjiu.lu@intel.com>
12098
12099 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
12100 if __x86_64__ is defined.
12101
8e642873
PM
121022010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12103
12104 * configure: Regenerate.
12105
711e434b
PM
121062010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12107
12108 * server.c (handle_query): Handle 'qGetTIBAddr' query.
12109 * target.h (target_ops): New get_tib_address field.
12110 * win32-low.h (win32_thread_info): Add thread_local_base field.
12111 * win32-low.c (child_add_thread): Add tlb argument.
12112 Set thread_local_base field to TLB.
12113 (get_child_debug_event): Adapt to child_add_thread change.
12114 (win32_get_tib_address): New function.
12115 (win32_target_ops): Set get_tib_address field to
12116 win32_get_tib_address.
12117 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
12118
505106cd
PA
121192010-04-12 Pedro Alves <pedro@codesourcery.com>
12120
505106cd
PA
12121 * linux-low.c (linux_mourn): Also remove the process.
12122 * server.c (handle_target_event): Don't remove the process here.
12123 * nto-low.c (nto_mourn): New.
12124 (nto_target_ops): Install it.
12125 * spu-low.c (spu_mourn): New.
12126 (spu_target_ops): Install it.
12127 * win32-low.c (win32_mourn): New.
12128 (win32_target_ops): Install it.
12129
e8470a06
PA
121302010-04-12 Pedro Alves <pedro@codesourcery.com>
12131
12132 * server.h (buffer_xml_printf): Remove redundant `;'.
12133
45ba0d02
PA
121342010-04-12 Pedro Alves <pedro@codesourcery.com>
12135
12136 * regcache.c (set_register_cache): Invalidate regcaches before
12137 changing the register cache layout.
12138 (regcache_invalidate_one): Allow a NULL regcache.
12139 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
12140 regcaches before changing the register cache layout or the target
12141 regsets.
12142
59e04013
L
121432010-04-12 H.J. Lu <hongjiu.lu@intel.com>
12144
12145 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
12146 variable warning on Linux/x86-64.
12147
8336d594
PA
121482010-04-11 Pedro Alves <pedro@codesourcery.com>
12149
12150 GDBserver disconnected tracing support.
12151
12152 * linux-low.c (linux_remove_process): Delete.
12153 (add_lwp): Don't set last_resume_kind here.
12154 (linux_kill): Use `mourn'.
12155 (linux_detach): Use `thread_db_detach', and `mourn'.
12156 (linux_mourn): New.
12157 (linux_attach_lwp_1): Adjust comment.
12158 (linux_attach): last_resume_kind moved the thread_info; adjust.
12159 (status_pending_p_callback): Adjust.
12160 (linux_wait_for_event_1): Adjust.
12161 (count_events_callback, select_singlestep_lwp_callback)
12162 (select_event_lwp_callback, cancel_breakpoints_callback)
12163 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
12164 (proceed_one_lwp): Adjust.
12165 (linux_async): Add debug output.
12166 (linux_thread_stopped): New.
12167 (linux_pause_all): New.
12168 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
12169 linux_pause_all.
12170 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
12171 (thread_db_free): Delete declaration.
12172 (thread_db_detach, thread_db_mourn): Declare.
12173 * thread-db.c (thread_db_init): Use thread_db_mourn.
12174 (thread_db_free): Delete, split in two.
12175 (disable_thread_event_reporting): New.
12176 (thread_db_detach): New.
12177 (thread_db_mourn): New.
12178
12179 * server.h (struct thread_info) <last_resume_kind>: New field.
12180 <attached>: Add comment.
12181 <gdb_detached>: New field.
12182 (handler_func): Change return type to int.
12183 (handle_serial_event, handle_target_event): Ditto.
12184 (gdb_connected): Declare.
12185 (tracing): Delete.
12186 (disconnected_tracing): Declare.
12187 (stop_tracing): Declare.
12188
12189 * server.c (handle_query) <qSupported>: Report support for
12190 disconnected tracing.
12191 (queue_stop_reply_callback): Account for running threads.
12192 (gdb_wants_thread_stopped): New.
12193 (gdb_wants_all_threads_stopped): New.
12194 (gdb_reattached_process): New.
12195 (handle_status): Clear the `gdb_detached' flag of all processes.
12196 In all-stop, stop all threads.
12197 (main): Be sure to leave tfind mode. Handle disconnected tracing.
12198 (process_serial_event): If the remote connection breaks, or if an
12199 exit was forced with "monitor exit", force an event loop exit.
12200 Handle disconnected tracing on detach.
12201 (handle_serial_event): Adjust.
12202 (handle_target_event): If GDB isn't connected, forward events back
12203 to the inferior, unless the last process exited, in which case,
12204 exit gdbserver. Adjust interface.
12205
12206 * remote-utils.c (remote_open): Don't block in accept. Instead
12207 register an event loop source on the listen socket file
12208 descriptor. Refactor bits into ...
12209 (listen_desc): ... this new global.
12210 (gdb_connected): ... this new function.
12211 (enable_async_notification): ... this new function.
12212 (handle_accept_event): ... this new function.
12213 (remote_close): Clear remote_desc.
12214
12215 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
12216
12217 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
12218 New fields.
12219 (mourn_inferior): Define.
12220 (target_process_qsupported): Avoid the dangling else problem.
12221 (thread_stopped): Define.
12222 (pause_all): Define.
12223 (target_waitstatus_to_string): Declare.
12224 * target.c (target_waitstatus_to_string): New.
12225
12226 * tracepoint.c (tracing): Make extern.
12227 (disconnected_tracing): New.
12228 (stop_tracing): Make extern. Handle tracing stops due to GDB
12229 disconnecting.
12230 (cmd_qtdisconnected): New.
12231 (cmd_qtstatus): Report disconnected tracing status in trace reply.
12232 (handle_tracepoint_general_set): Handle QTDisconnected.
12233
12234 * event-loop.c (event_handler_func): Change return type to int.
12235 (process_event): Bail out if the event handler wants the event
12236 loop to stop.
12237 (handle_file_event): Ditto.
12238 (start_event_loop): Bail out if the event handler wants the event
12239 loop to stop.
12240
12241 * nto-low.c (nto_target_ops): Adjust.
12242 * spu-low.c (spu_wait): Don't remove the process here.
12243 (spu_target_ops): Adjust.
12244 * win32-low.c (win32_wait): Don't remove the process here.
12245 (win32_target_ops): Adjust.
12246
5d267c4c
PA
122472010-04-11 Pedro Alves <pedro@codesourcery.com>
12248
12249 * regcache.c (realloc_register_cache): Invalidate inferior's
12250 regcache before recreating it.
12251
623ccd72
PA
122522010-04-09 Pedro Alves <pedro@codesourcery.com>
12253
12254 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
12255
219f2f23
PA
122562010-04-09 Stan Shebs <stan@codesourcery.com>
12257 Pedro Alves <pedro@codesourcery.com>
12258
12259 * server.h (LONGEST): New.
12260 (struct thread_info) <while_stepping>: New field.
12261 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
12262 Declare.
12263 (initialize_tracepoint, handle_tracepoint_general_set)
12264 (handle_tracepoint_query, tracepoint_finished_step)
12265 (tracepoint_was_hit, release_while_stepping_state_list):
12266 (current_traceframe): Declare.
12267 * server.c (handle_general_set): Handle tracepoint packets.
12268 (read_memory): New.
12269 (write_memory): New.
12270 (handle_search_memory_1): Use read_memory.
12271 (handle_query): Report support for conditional tracepoints, trace
12272 state variables, and tracepoint sources. Handle tracepoint
12273 queries.
12274 (main): Initialize the tracepoints module.
12275 (process_serial_event): Handle traceframe reads/writes.
12276
12277 * linux-low.c (handle_tracepoints): New.
12278 (linux_wait_1): Call it.
12279 (linux_resume_one_lwp): Handle while-stepping.
12280 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
12281 (linux_target_ops): Install them.
12282 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
12283 New field.
12284 * linux-x86-low.c (x86_supports_tracepoints): New.
12285 (the_low_target). Install it.
12286
12287 * mem-break.h (delete_breakpoint): Declare.
12288 * mem-break.c (delete_breakpoint): Make external.
12289
12290 * target.h (struct target_ops): Add `supports_tracepoints',
12291 `read_pc', and `write_pc' fields.
12292 (target_supports_tracepoints): Define.
12293 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
12294 (phex_nz): New.
12295
12296 * regcache.h (struct regcache) <registers_owned>: New field.
12297 (init_register_cache, regcache_cpy): Declare.
12298 (regcache_read_pc, regcache_write_pc): Declare.
12299 (register_cache_size): Declare.
12300 (supply_regblock): Declare.
12301 * regcache.c (init_register_cache): New.
12302 (new_register_cache): Use it.
12303 (regcache_cpy): New.
12304 (register_cache_size): New.
12305 (supply_regblock): New.
12306 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 12307
219f2f23
PA
12308 * tracepoint.c: New.
12309
12310 * Makefile.in (OBS): Add tracepoint.o.
12311 (tracepoint.o): New rule.
12312
3a13a53b
L
123132010-04-08 H.J. Lu <hongjiu.lu@intel.com>
12314
12315 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
12316 (i386-mmx.o): New.
12317 (i386-mmx.c): Likewise.
12318 (i386-mmx-linux.o): Likewise.
12319 (i386-mmx-linux.c): Likewise.
12320
12321 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
12322 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
12323 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
12324 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
12325
12326 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
12327 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
12328 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
12329
1570b33e
L
123302010-04-07 H.J. Lu <hongjiu.lu@intel.com>
12331
12332 * Makefile.in (clean): Updated.
12333 (i386-avx.o): New.
12334 (i386-avx.c): Likewise.
12335 (i386-avx-linux.o): Likewise.
12336 (i386-avx-linux.c): Likewise.
12337 (amd64-avx.o): Likewise.
12338 (amd64-avx.c): Likewise.
12339 (amd64-avx-linux.o): Likewise.
12340 (amd64-avx-linux.c): Likewise.
12341
12342 * configure.srv (srv_i386_regobj): Add i386-avx.o.
12343 (srv_i386_linux_regobj): Add i386-avx-linux.o.
12344 (srv_amd64_regobj): Add amd64-avx.o.
12345 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
12346 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
12347 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
12348 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
12349 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
12350 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
12351 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
12352
12353 * i387-fp.c: Include "i386-xstate.h".
12354 (i387_xsave): New.
12355 (i387_cache_to_xsave): Likewise.
12356 (i387_xsave_to_cache): Likewise.
12357 (x86_xcr0): Likewise.
12358
12359 * i387-fp.h (i387_cache_to_xsave): Likewise.
12360 (i387_xsave_to_cache): Likewise.
12361 (x86_xcr0): Likewise.
12362
12363 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
12364 * linux-crisv32-low.c (target_regsets): Likewise.
12365 * linux-m68k-low.c (target_regsets): Likewise.
12366 * linux-mips-low.c (target_regsets): Likewise.
12367 * linux-ppc-low.c (target_regsets): Likewise.
12368 * linux-s390-low.c (target_regsets): Likewise.
12369 * linux-sh-low.c (target_regsets): Likewise.
12370 * linux-sparc-low.c (target_regsets): Likewise.
12371 * linux-xtensa-low.c (target_regsets): Likewise.
12372
12373 * linux-low.c: Include <sys/uio.h>.
12374 (regsets_fetch_inferior_registers): Support nt_type.
12375 (regsets_store_inferior_registers): Likewise.
12376 (linux_process_qsupported): New.
12377 (linux_target_ops): Add linux_process_qsupported.
12378
12379 * linux-low.h (regset_info): Add nt_type.
12380 (linux_target_ops): Add process_qsupported.
12381
12382 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
12383 and <sys/uio.h>.
12384 (init_registers_i386_avx_linux): New.
12385 (init_registers_amd64_avx_linux): Likewise.
12386 (xmltarget_i386_linux_no_xml): Likewise.
12387 (xmltarget_amd64_linux_no_xml): Likewise.
12388 (PTRACE_GETREGSET): Likewise.
12389 (PTRACE_SETREGSET): Likewise.
12390 (x86_fill_xstateregset): Likewise.
12391 (x86_store_xstateregset): Likewise.
12392 (use_xml): Likewise.
12393 (x86_linux_update_xmltarget): Likewise.
12394 (x86_linux_process_qsupported): Likewise.
12395 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
12396 (x86_arch_setup): Don't call init_registers_amd64_linux nor
12397 init_registers_i386_linux here. Call
12398 x86_linux_update_xmltarget.
12399 (the_low_target): Add x86_linux_process_qsupported.
12400
12401 * server.c (handle_query): Call target_process_qsupported.
12402
12403 * target.h (target_ops): Add process_qsupported.
12404 (target_process_qsupported): New.
12405
fc7238bb
PA
124062010-04-03 Pedro Alves <pedro@codesourcery.com>
12407
12408 * inferiors.c (add_thread): Set last_status kind to
12409 TARGET_WAITKIND_IGNORE.
12410 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
12411 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
12412 (linux_wait_1): Move `thread' local definition to block that uses
12413 it. Don't NULL initialize `event_child'.
12414 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
12415 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
12416 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
12417
bdabb078
PA
124182010-04-01 Pedro Alves <pedro@codesourcery.com>
12419
12420 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
12421 an extended waitstatus, or by a watchpoint.
12422 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
12423 thread was stepping or has been stopped by a watchpoint.
12424
d3bbe7a0
PA
124252010-04-01 Pedro Alves <pedro@codesourcery.com>
12426
12427 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
12428 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
12429 of another, then delete the previous, and validate all
12430 breakpoints.
12431 (validate_inserted_breakpoint): New.
12432 (delete_disabled_breakpoints): New.
12433 (validate_breakpoints): New.
12434 (check_mem_read): Validate breakpoints before trusting their
12435 shadow. Delete disabled breakpoints.
12436 (check_mem_write): Validate breakpoints before trusting they
12437 should be inserted. Delete disabled breakpoints.
12438 * mem-break.h (validate_breakpoints):
12439 * server.c (handle_query): Validate breakpoints when we see a
12440 qSymbol query.
12441
8b07ae33
PA
124422010-04-01 Pedro Alves <pedro@codesourcery.com>
12443
12444 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
12445 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
12446 if we could tell there's a GDB breakpoint at stop_pc.
12447 (need_step_over_p): Don't do a step over if we find a GDB
12448 breakpoint at the resume PC.
12449
12450 * mem-break.c (struct raw_breakpoint): New.
12451 (enum bkpt_type): New type `gdb_breakpoint'.
12452 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
12453 fields. New field `raw'.
12454 (find_raw_breakpoint_at): New.
12455 (set_raw_breakpoint_at): Handle refcounting. Create a raw
12456 breakpoint instead.
12457 (set_breakpoint_at): Adjust.
12458 (delete_raw_breakpoint): New.
12459 (release_breakpoint): New.
12460 (delete_breakpoint): Rename to...
12461 (delete_breakpoint_1): ... this. Add proc parameter. Use
12462 release_breakpoint. Return ENOENT.
12463 (delete_breakpoint): Reimplement.
12464 (find_breakpoint_at): Delete.
12465 (find_gdb_breakpoint_at): New.
12466 (delete_breakpoint_at): Delete.
12467 (set_gdb_breakpoint_at): New.
12468 (delete_gdb_breakpoint_at): New.
12469 (gdb_breakpoint_here): New.
12470 (set_reinsert_breakpoint): Use release_breakpoint.
12471 (uninsert_breakpoint): Rename to ...
12472 (uninsert_raw_breakpoint): ... this.
12473 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
12474 (reinsert_raw_breakpoint): Change parameter type to
12475 raw_breakpoint.
12476 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
12477 instead.
12478 (check_breakpoints): Adjust. Use release_breakpoint.
12479 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
12480 (breakpoint_inserted_here): Ditto.
12481 (check_mem_read): Adjust to iterate over raw breakpoints instead.
12482 Don't trust the breakpoint's shadow if it is not inserted.
12483 (check_mem_write): Adjust to iterate over raw breakpoints instead.
12484 (delete_all_breakpoints): Adjust.
12485 (free_all_breakpoints): Mark all breakpoints as uninserted, and
12486 use delete_breakpoint_1.
12487
12488 * mem-break.h (breakpoints_supported): Delete declaration.
12489 (set_gdb_breakpoint_at): Declare.
12490 (gdb_breakpoint_here): Declare.
12491 (delete_breakpoint_at): Delete.
12492 (delete_gdb_breakpoint_at): Declare.
12493
12494 * server.h (struct raw_breakpoint): Forward declare.
12495 (struct process_info): New field `raw_breakpoints'.
12496
12497 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
12498 breakpoints.
12499
6bf5e0ba
PA
125002010-03-24 Pedro Alves <pedro@codesourcery.com>
12501
12502 * linux-low.c (status_pending_p_callback): Fix comment.
12503 (linux_wait_for_event_1): Move most of the internal breakpoint
12504 handling from here...
12505 (linux_wait_1): ... to here.
12506 (count_events_callback): New.
12507 (select_singlestep_lwp_callback): New.
12508 (select_event_lwp_callback): New.
12509 (cancel_breakpoints_callback): New.
12510 (select_event_lwp): New.
12511 (linux_wait_1): Simplify internal breakpoint handling. Give equal
12512 priority to all LWPs that have had events that should be reported
12513 to the client. Cancel breakpoints when about to reporting the
12514 event to the client, not while stopping lwps. No longer cancel
12515 finished single-steps here.
12516 (cancel_finished_single_step): Delete.
12517 (cancel_finished_single_steps): Delete.
12518
414a389f
PA
125192010-03-24 Pedro Alves <pedro@codesourcery.com>
12520
12521 * mem-break.c (enum bkpt_type): New.
12522 (struct breakpoint): New field `type'.
12523 (set_breakpoint_at): Change return type to struct breakpoint
12524 pointer. Set type to `other_breakpoint' by default.
12525 (delete_breakpoint): Rewrite, supporting more than one breakpoint
12526 in the breakpoint list.
12527 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
12528 (reinsert_breakpoint): Rename to ...
12529 (reinsert_raw_breakpoint): ... this.
12530 (reinsert_breakpoints_at): Adjust.
12531 * mem-break.h (struct breakpoint): Declare.
12532 (set_breakpoint_at): Change return type to struct breakpoint
12533 pointer.
12534
2280c721
PA
125352010-03-24 Pedro Alves <pedro@codesourcery.com>
12536
12537 * server.c (handle_query): Assign, not compare.
12538
d50171e4
PA
125392010-03-24 Pedro Alves <pedro@codesourcery.com>
12540
12541 Teach linux gdbserver to step-over-breakpoints.
12542
12543 * linux-low.c (can_hardware_single_step): New.
12544 (supports_breakpoints): New.
12545 (handle_extended_wait): If stopping threads, read the stop pc of
12546 the new cloned LWP.
12547 (get_pc): New.
12548 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
12549 low target doesn't support retrieving the PC.
12550 (add_lwp): Set last_resume_kind to resume_continue.
12551 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
12552 (linux_attach): Don't clear stop_expected. Set the lwp's
12553 last_resume_kind to resume_stop.
12554 (linux_detach_one_lwp): Don't check for removed breakpoints.
12555 (check_removed_breakpoint): Delete.
12556 (status_pending_p): Rename to ...
12557 (status_pending_p_callback): ... this. Don't check for removed
12558 breakpoints. Don't consider threads that are stopped from GDB's
12559 perspective.
12560 (linux_wait_for_lwp): Always read the stop_pc here.
12561 (cancel_breakpoint): New.
12562 (step_over_bkpt): New global.
12563 (linux_wait_for_event_1): Implement stepping over breakpoints.
12564 (gdb_wants_lwp_stopped): New.
12565 (gdb_wants_all_stopped): New.
12566 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
12567 single-step traps here. Store the thread's last reported target
12568 wait status.
12569 (send_sigstop): Don't clear stop_expected. Always set it,
12570 instead.
12571 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
12572 (cancel_finished_single_step): New.
12573 (cancel_finished_single_steps): New.
12574 (wait_for_sigstop): Don't cancel finished single-step traps here.
12575 (linux_resume_one_lwp): Don't check for removed breakpoints.
12576 Don't set `step' on non-hardware step archs.
12577 (linux_set_resume_request): Ignore resume_stop requests if already
12578 stopping or stopped. Set the lwp's last_resume_kind.
12579 (resume_status_pending_p): Don't check for removed breakpoints.
12580 (need_step_over_p): New.
12581 (start_step_over): New.
12582 (finish_step_over): New.
12583 (linux_resume_one_thread): Always queue a sigstop for resume_stop
12584 requests. Clear the thread's last reported target waitstatus.
12585 Don't use the `suspended' flag. Don't consider pending breakpoints.
12586 (linux_resume): Start a step-over if necessary.
12587 (proceed_one_lwp): New.
12588 (proceed_all_lwps): New.
12589 (unstop_all_lwps): New.
12590 * linux-low.h (struct lwp_info): Rewrite comment for the
12591 `suspended' flag. Add the `stop_pc' field. Delete the
12592 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
12593 Add `'last_resume_kind' and `need_step_over' fields.
12594 * inferiors.c (struct thread_info): Delete, moved elsewhere.
12595 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
12596 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
12597 (set_raw_breakpoint_at): New.
12598 (set_breakpoint_at): Rewrite to use it.
12599 (reinsert_breakpoint_handler): Delete.
12600 (set_reinsert_breakpoint): New.
12601 (reinsert_breakpoint_by_bp): Delete.
12602 (delete_reinsert_breakpoints): New.
12603 (uninsert_breakpoint): Rewrite.
12604 (uninsert_breakpoints_at): New.
12605 (reinsert_breakpoint): Rewrite.
12606 (reinsert_breakpoints_at): New.
12607 (check_breakpoints): Rewrite.
12608 (breakpoint_here): New.
12609 (breakpoint_inserted_here): New.
12610 (check_mem_read): Adjust.
12611 * mem-break.h (breakpoints_supported, breakpoint_here)
12612 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
12613 (reinsert_breakpoint_by_bp): Delete declaration.
12614 (delete_reinsert_breakpoints): Declare.
12615 (reinsert_breakpoint): Delete declaration.
12616 (reinsert_breakpoints_at): Declare.
12617 (uninsert_breakpoint): Delete declaration.
12618 (uninsert_breakpoints_at): Declare.
12619 (check_breakpoints): Adjust prototype.
12620 * server.h: Adjust include order.
12621 (struct thread_info): Declare here. Add a `last_status' field.
12622
30ba68cb
MS
126232010-03-23 Michael Snyder <msnyder@vmware.com>
12624
12625 * server.c (crc32): New function.
12626 (handle_query): Add handling for 'qCRC:' request.
12627
b9a881c2
PA
126282010-03-23 Pedro Alves <pedro@codesourcery.com>
12629
12630 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
12631 lwp had been stopped by a watchpoint.
12632
e92d13d5
PA
126332010-03-16 Pedro Alves <pedro@codesourcery.com>
12634
12635 * server.h (internal_error): Declare.
12636 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
12637 * utils.c (internal_error): New function.
12638
64daa791
AS
126392010-03-15 Andreas Schwab <schwab@redhat.com>
12640
12641 * configure.srv: Fix typo setting srv_regobj.
12642
f52cd8cd
PA
126432010-03-15 Pedro Alves <pedro@codesourcery.com>
12644
12645 * linux-low.c (fetch_register): Avoid passing a non string literal
12646 format to `error'.
12647 (usr_store_inferior_registers): Ditto.
12648
93ae6fdc
PA
126492010-03-14 Pedro Alves <pedro@codesourcery.com>
12650
12651 * linux-low.c (linux_write_memory): Bail out early if peeking
12652 memory failed.
12653
c3adc08c
PA
126542010-03-14 Pedro Alves <pedro@codesourcery.com>
12655
12656 * linux-low.h (struct lwp_info): New fields
12657 `stopped_by_watchpoint' and `stopped_data_address'.
12658 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
12659 here, and cache them in the lwp object.
12660 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
12661 directly.
12662 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
12663 field.
12664 (linux_stopped_by_watchpoint): Rewrite.
12665 (linux_stopped_data_address): Rewrite.
12666
bce522a2
PA
126672010-03-06 Simo Melenius <simo.melenius@iki.fi>
12668
12669 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
12670 switching the current inferior, not before.
12671
90884b2b
L
126722010-03-01 H.J. Lu <hongjiu.lu@intel.com>
12673
12674 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
12675 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
12676 i386-linux.c and amd64-linux.c.
12677 (reg-i386.o): Removed.
12678 (reg-i386.c): Likewise.
12679 (reg-i386-linux.o): Likewise.
12680 (reg-i386-linux.c): Likewise.
12681 (reg-x86-64.o): Likewise.
12682 (reg-x86-64.c): Likewise.
12683 (reg-x86-64-linux.o): Likewise.
12684 (reg-x86-64-linux.c): Likewise.
12685 (i386.o): New.
12686 (i386.c): Likewise.
12687 (i386-linux.o): Likewise.
12688 (i386-linux.c): Likewise.
12689 (amd64.o): Likewise.
12690 (amd64.c): Likewise.
12691 (amd64-linux.o): Likewise.
12692 (amd64-linux.c): Likewise.
12693
12694 * configure.srv (srv_i386_regobj): New.
12695 (srv_i386_linux_regobj): Likewise.
12696 (srv_amd64_regobj): Likewise.
12697 (srv_amd64_linux_regobj): Likewise.
12698 (srv_i386_32bit_xmlfiles): Likewise.
12699 (srv_i386_64bit_xmlfiles): Likewise.
12700 (srv_i386_xmlfiles): Likewise.
12701 (srv_amd64_xmlfiles): Likewise.
12702 (srv_i386_linux_xmlfiles): Likewise.
12703 (srv_amd64_linux_xmlfiles): Likewise.
12704 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
12705 srv_xmlfiles to $srv_i386_xmlfiles.
12706 (i[34567]86-*-mingw32ce*): Likewise.
12707 (i[34567]86-*-mingw*): Likewise.
12708 (i[34567]86-*-nto*): Likewise.
12709 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
12710 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
12711 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
12712 (x86_64-*-linux*): Likewise.
12713
12714 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
12715 (init_registers_amd64_linux): New.
12716 (x86_arch_setup): Replace init_registers_x86_64_linux with
12717 init_registers_amd64_linux.
12718
193f13e6
MK
127192010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
12720
12721 * configure.ac: Check for libdl. If it is not available link against
12722 static libthread_db.
12723 * configure: Regenerate.
12724
85d721b8
PA
127252010-02-22 Pedro Alves <pedro@codesourcery.com>
12726
12727 PR9605
12728
12729 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
12730 handing a read watchpoint.
12731 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
12732
6076632b
DE
127332010-02-12 Doug Evans <dje@google.com>
12734
12735 * linux-low.c (linux_supports_tracefork_flag): Document.
12736 (linux_look_up_symbols): Add comment.
12737
3327ccf7
L
127382010-02-03 H.J. Lu <hongjiu.lu@intel.com>
12739
12740 * regcache.c (supply_register): Clear regcache if buf is NULL.
12741
0718675c 127422010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 12743 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
12744
12745 * inferiors.c (find_inferior): Add function documentation.
12746 (unloaded_dll): Handle the case where the unloaded dll has not
12747 been previously registered in the dll list.
12748
177321bd
DJ
127492010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
12750
12751 * linux-arm-low.c (thumb_breakpoint_len): Delete.
12752 (thumb2_breakpoint): New.
12753 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
12754
2b009048
DJ
127552010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
12756
12757 * linux-low.c (get_stop_pc): Check for SIGTRAP.
12758 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
12759 breakpoints.
12760
3be029c7
PA
127612010-01-21 Pedro Alves <pedro@codesourcery.com>
12762
12763 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
12764
18f5de3b
JK
127652010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12766
12767 * linux-s390-low.c (s390_collect_ptrace_register)
12768 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
12769
3743bb4f
DE
127702010-01-21 Doug Evans <dje@google.com>
12771
14ce3065
DE
12772 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
12773 (PTRACE_ARG4_TYPE): New macro.
12774 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
12775 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
12776 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
12777 (usr_store_inferior_registers): Ditto.
12778 (linux_read_memory, linux_write_memory): Ditto.
12779 (linux_test_for_tracefork): Ditto.
12780
3743bb4f
DE
12781 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
12782 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
12783
8b315be5
PA
127842010-01-21 Pedro Alves <pedro@codesourcery.com>
12785
12786 * proc-service.c (ps_lgetregs): Don't refetch registers from the
12787 target.
12788
85492558
PA
127892010-01-21 Pedro Alves <pedro@codesourcery.com>
12790
12791 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
12792 prototype to take a regcache. Adjust.
12793
442ea881
PA
127942010-01-20 Pedro Alves <pedro@codesourcery.com>
12795
12796 * regcache.h (struct thread_info): Forward declare.
12797 (struct regcache): New.
12798 (new_register_cache): Adjust prototype.
12799 (get_thread_regcache): Declare.
12800 (free_register_cache): Adjust prototype.
12801 (registers_to_string, registers_from_string): Ditto.
12802 (supply_register, supply_register_by_name, collect_register)
12803 (collect_register_as_string, collect_register_by_name): Ditto.
12804 * regcache.c (struct inferior_regcache_data): Delete.
12805 (get_regcache): Rename to ...
12806 (get_thread_regcache): ... this. Adjust. Switch inferior before
12807 fetching registers.
12808 (regcache_invalidate_one): Adjust.
12809 (regcache_invalidate): Fix prototype.
12810 (new_register_cache): Return the new register cache.
12811 (free_register_cache): Change prototype.
12812 (realloc_register_cache): Adjust.
12813 (registers_to_string): Change prototype to take a regcache. Adjust.
12814 (registers_from_string): Ditto.
12815 (register_data): Ditto.
12816 (supply_register): Ditto.
12817 (supply_register_by_name): Ditto.
12818 (collect_register): Ditto.
12819 (collect_register_as_string): Ditto.
12820 (collect_register_by_name): Ditto.
12821 * server.c (process_serial_event): Adjust.
12822 * linux-low.h (regset_fill_func, regset_store_func): Change
12823 prototype.
12824 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
12825 Change prototype.
12826 * linux-low.c (get_stop_pc): Adjust.
12827 (check_removed_breakpoint): Adjust.
12828 (linux_wait_for_event): Adjust.
12829 (linux_resume_one_lwp): Adjust.
12830 (fetch_register): Add regcache parameter. Adjust.
12831 (usr_store_inferior_registers): Ditto.
12832 (regsets_fetch_inferior_registers): Ditto.
12833 (regsets_store_inferior_registers): Ditto.
12834 (linux_fetch_registers, linux_store_registers): Ditto.
12835 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
12836 regcache. Adjust.
43aaf8b6
PA
12837 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
12838 Ditto.
442ea881
PA
12839 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
12840 prototype to take a regcache.
12841 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
12842 * remote-utils.c (convert_ascii_to_int, outreg)
12843 (prepare_resume_reply): Change prototype to take a regcache.
12844 Adjust.
12845 * target.h (struct target_ops) <fetch_registers, store_registers>:
12846 Change prototype to take a regcache.
12847 (fetch_inferior_registers, store_inferior_registers): Change
12848 prototype to take a regcache. Adjust.
12849 * proc-service.c (ps_lgetregs): Adjust.
12850 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
12851 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
12852 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
12853 take a regcache. Adjust.
12854 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
12855 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
12856 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
12857 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
12858 * linux-cris-low.c (cris_get_pc, cris_set_pc)
12859 (cris_cannot_fetch_register):
12860 (cris_breakpoint_at): Change prototype to take a regcache.
12861 Adjust.
12862 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
12863 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
12864 to take a regcache. Adjust.
12865 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
12866 Adjust.
12867 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
12868 take a regcache. Adjust.
12869 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
12870 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
12871 (m68k_set_pc): Change prototype to take a regcache. Adjust.
12872 * linux-mips-low.c (mips_get_pc):
12873 (mips_set_pc): Change prototype to take a regcache. Adjust.
12874 (mips_reinsert_addr): Adjust.
12875 (mips_collect_register): Change prototype to take a regcache.
12876 Adjust.
12877 (mips_supply_register):
12878 (mips_collect_register_32bit, mips_supply_register_32bit)
12879 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
12880 (mips_store_fpregset): Ditto.
43aaf8b6
PA
12881 * linux-ppc-low.c (ppc_supply_ptrace_register)
12882 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
12883 (parse_spufs_run): Adjust.
12884 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
12885 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
12886 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
12887 take a regcache. Adjust.
12888 * linux-s390-low.c (s390_collect_ptrace_register)
12889 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
12890 (s390_set_pc): Change prototype to take a regcache. Adjust.
12891 (s390_arch_setup): Adjust.
12892 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
12893 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
12894 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12895 (sparc_fill_gregset, sparc_store_gregset_from_stack)
12896 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
12897 regcache. Adjust.
12898 (sparc_breakpoint_at): Adjust.
12899 * linux-xtensa-low.c (xtensa_fill_gregset):
12900 (xtensa_store_gregset):
12901 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
12902 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
12903 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
12904 prototype to take a regcache. Adjust.
12905 * win32-arm-low.c (arm_fetch_inferior_register)
12906 (arm_store_inferior_register): Change prototype to take a
12907 regcache. Adjust.
12908 * win32-i386-low.c (i386_fetch_inferior_register)
12909 (i386_store_inferior_register): Change prototype to take a
12910 regcache. Adjust.
12911 * win32-low.c (child_fetch_inferior_registers)
12912 (child_store_inferior_registers): Change prototype to take a
12913 regcache. Adjust.
12914 (win32_wait): Adjust.
12915 (win32_fetch_inferior_registers): Change prototype to take a
12916 regcache. Adjust.
12917 (win32_store_inferior_registers): Adjust.
12918 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
12919 store_inferior_register>: Change prototype to take a regcache.
12920
60c3d7b0
DE
129212010-01-20 Doug Evans <dje@google.com>
12922
12923 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
12924 #ifdef.
12925 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 12926 (W_STOPCODE): Provide definition if missing.
60c3d7b0 12927
dc146f7c
VP
129282010-01-13 Vladimir Prus <vladimir@codesourcery.com>
12929
12930 * linux-low.c (linux_core_of_thread): New.
12931 (compare_ints, show_process, list_threads): New.
12932 (linux_qxfer_osdata): Report threads and cores.
12933 (linux_target_op): Register linux_core_of_thread.
12934 * remote-utils.c (prepare_resume_reply): Report the core.
12935 (buffer_xml_printf): Support %d specifier.
12936 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
12937 New.
12938 (handle_query): Handle qXfer:threads. Announce availability
12939 thereof.
12940 * target.h (struct target_ops): New field core_of_thread.
12941
7803799a
UW
129422010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
12943
12944 * Makefile.in (clean): Remove new generated files.
12945 (reg-s390.o, reg-s390.c): Remove rules.
12946 (reg-s390x.o, reg-s390x.c): Likewise.
12947 (s390-linux32.o, s390-linux32.c): Add rules.
12948 (s390-linux64.o, s390-linux64.c): Likewise.
12949 (s390x-linux64.o, s390x-linux64.c): Likewise.
12950 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
12951 * linux-s390-low.c: Include <elf.h>.
12952 (HWCAP_S390_HIGH_GPRS): Define if undefined.
12953 (init_registers_s390): Remove prototype.
12954 (init_registers_s390x): Likewise.
12955 (init_registers_s390_linux32): Add prototype.
12956 (init_registers_s390_linux64): Likewise.
12957 (init_registers_s390x_linux64): Likewise.
12958 (s390_num_regs_3264): New define.
12959 (s390_regmap_3264): New global variable.
12960 (s390_cannot_fetch_register): Remove obsolete check.
12961 (s390_cannot_store_register): Likewise.
12962 (s390_collect_ptrace_register): Handle upper/lower register halves.
12963 (s390_supply_ptrace_register): Likewise.
12964 (s390_fill_gregset): Update to register number changes.
12965 (s390_get_hwcap): New routine.
12966 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
12967 Install appropriate regmap and register set.
12968
6e7ffa39
JB
129692010-01-01 Joel Brobecker <brobecker@adacore.com>
12970
12971 * server.c (gdbserver_version): Update copyright year to 2010.
12972 * gdbreplay.c (gdbreplay_version): Likewise.
12973
957f3f49
DE
129742009-12-28 Doug Evans <dje@google.com>
12975
12976 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
12977 elf/external.h. Include <elf.h> instead but only if necessary.
12978
ca5c370d
PA
129792009-12-28 Pedro Alves <pedro@codesourcery.com>
12980
12981 * linux-low.c (linux_remove_process): Remove `detaching'
12982 parameter. Don't release/detach from thread_db here.
12983 (linux_kill): Release/detach from thread_db here, ...
12984 (linux_detach): ... and here, before actually detaching.
12985 (linux_wait_1): ... and here, when a process exits.
12986 * thread-db.c (any_thread_of): New.
12987 (thread_db_free): Switch the current inferior to a thread of the
12988 passed in process.
12989
4ee62156
DE
129902009-12-21 Doug Evans <dje@google.com>
12991
d90e6a88
DE
12992 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
12993
c5f62d5f
DE
12994 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
12995 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
12996 warning ifndef __NR_tkill. Move setting of errno there too.
12997 Delete unnecessary resetting of errno after syscall.
12998 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
12999
10e86dd7
DE
13000 * configure.ac: Check for dladdr.
13001 * config.in: Regenerate.
13002 * configure: Regenerate.
13003 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
13004 (try_thread_db_load): Update.
13005
4ee62156
DE
13006 * linux-low.c (my_waitpid): Delete unnecessary prototype.
13007
00f515da
DE
130082009-12-18 Doug Evans <dje@google.com>
13009
e9464885
DE
13010 * event-loop.c: Include unistd.h if it exists.
13011
07d4f67e
DE
13012 * linux-low.c (my_waitpid): Move definition away from being in
13013 between linux_tracefork_child/linux_test_for_tracefork.
13014
00f515da
DE
13015 * gdb_proc_service.h (psaddr_t): Fix type.
13016 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
13017 signature to match glibc.
13018
1de1badb
DE
130192009-12-16 Doug Evans <dje@google.com>
13020
13021 * linux-low.c (linux_read_memory): Fix argument to read.
13022
aeeb81d1
PA
130232009-11-26 Pedro Alves <pedro@codesourcery.com>
13024
13025 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
13026 events, don't leave current_inferior pointing at null.
13027
10357975
PA
130282009-11-26 Pedro Alves <pedro@codesourcery.com>
13029
13030 * win32-low.c (LOG): Delete.
13031 (OUTMSG): Output to stderr.
13032 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
13033 on compile time LOG macro.
13034 (win32_wait): Fix debug output.
13035
cf6e3471
PA
130362009-11-26 Pedro Alves <pedro@codesourcery.com>
13037
13038 * win32-low.c (win32_add_one_solib): If the dll name is
13039 "ntdll.dll", prepend the system directory to the dll path.
13040
0c85e18e
MK
130412009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
13042
13043 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
13044
9ac544ce 130452009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 13046 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
13047
13048 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
13049 * configure.ac: Check for __mcoldfire__ and set
13050 gdb_cv_m68k_is_coldfire.
13051 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
13052 reg-cf.o and reg-m68k.o.
13053 * configure: Regenerated.
13054
fd7dd3e6
PA
130552009-11-16 Pedro Alves <pedro@codesourcery.com>
13056
13057 * linux-low.c (linux_remove_process): Add `detaching' parameter.
13058 Pass it to thread_db_free.
13059 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
13060 proper `detaching' argument to linux_remove_process.
13061 * linux-low.h (thread_db_free): Add `detaching' parameter.
13062 * thread-db.c (thread_db_init): Pass false as `detaching' argument
13063 to thread_db_free.
13064 (thread_db_free): Add `detaching' parameter. Only
13065 call td_ta_clear_event if detaching from process.
13066
75aa492e
MK
130672009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
13068
13069 * thread-db.c (thread_db_free): Fix typo.
13070
21e1bee4
PP
130712009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
13072
13073 PR gdb/10838
13074 * thread-db.c (thread_db_free): Call td_ta_clear_event.
13075
8838b45e
NS
130762009-11-03 Nathan Sidwell <nathan@codesourcery.com>
13077
13078 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
13079 with an i686 compiler.
13080 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
13081 needed.
13082 * configure: Rebuilt.
13083
8a35fb51
SL
130842009-10-29 Sandra Loosemore <sandra@codesourcery.com>
13085
13086 PR gdb/10783
13087
13088 * server.c (handle_search_memory_1): Correct read_addr initialization
13089 in loop for searching subsequent chunks.
13090
96f15937
PP
130912009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
13092
13093 * configure.ac: New --with-libthread-db option.
13094 * thread-db.c: Allow direct dependence on libthread_db.
13095 (thread_db_free): Adjust.
13096 * config.in: Regenerate.
13097 * configure: Likewise.
889bf7c5 13098
5f7d1694
PP
130992009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
13100
13101 PR gdb/10757
13102 * thread-db.c (attach_thread): New function.
13103 (maybe_attach_thread): Return success/failure.
13104 (find_new_threads_callback): Adjust.
889bf7c5
PA
13105 (thread_db_find_new_threads): Loop until no new threads.
13106
88e3b899
PA
131072009-10-13 Pedro Alves <pedro@codesourcery.com>
13108
13109 * proc-service.c (ps_lgetregs): Formatting.
13110
cdbfd419
PP
131112009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
13112
13113 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
13114 * configure.ac: Adjust.
13115 * linux-low.h (struct process_info_private): Move members to struct
13116 thread_db.
13117 (thread_db_free, thread_db_handle_monitor_command): New prototype.
13118 * linux-low.c (linux_remove_process): Adjust.
13119 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
13120 * server.c (handle_query): Move code ...
13121 (handle_monitor_command): ... here. New function.
13122 * target.h (struct target_ops): New member.
13123 * thread-db.c (struct thread_db): New.
13124 (libthread_db_search_path): New variable.
13125 (thread_db_create_event, thread_db_enable_reporting)
13126 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
13127 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
13128 (try_thread_db_load_1, dladdr_to_soname): New functions.
13129 (try_thread_db_load, thread_db_load_search): New functions.
13130 (thread_db_init): Search for libthread_db.
13131 (thread_db_free): New function.
13132 (thread_db_handle_monitor_command): Likewise.
13133 * config.in: Regenerate.
13134 * configure: Regenerate.
889bf7c5 13135
4168d2d6
UW
131362009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
13137
13138 * spu-low.c (spu_kill): Wait for inferior to terminate.
13139 Call clear_inferiors.
13140 (spu_detach): Call clear_inferiors.
13141
81ecdfbb
RW
131422009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13143
13144 * aclocal.m4: Regenerate.
13145 * config.in: Likewise.
13146 * configure: Likewise.
13147
0b9ff2c0
UW
131482009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13149
13150 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
13151 (parse_spufs_run): New function.
13152 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
13153 (ppc_breakpoint_at): Handle SPU breakpoints.
13154
efcbbd14
UW
131552009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13156
13157 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
13158 (SPUFS_MAGIC): Define.
13159 (spu_enumerate_spu_ids): New function.
13160 (linux_qxfer_spu): New function.
13161 (linux_target_ops): Install linux_qxfer_spu.
13162
f4d9bade
UW
131632009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13164
13165 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
13166 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
13167 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
13168 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
13169 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
13170 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
13171 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
13172 (init_registers_powerpc_cell32l): Add prototype.
13173 (init_registers_powerpc_cell64l): Likewise.
13174 (ppc_arch_setup): Detect Cell/B.E. architecture.
13175
96e946ca
RW
131762009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13177
13178 * Makefile.in (datarootdir): New variable.
13179
58d6951d
DJ
131802009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13181
13182 * linux-low.c (linux_write_memory): Update debugging output.
13183 * Makefile.in (clean): Add new descriptions.
13184 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
13185 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
13186 * configure.srv: Add new files for arm*-*-linux*.
13187 * linux-arm-low.c: Add new declarations.
13188 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
13189 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
13190 (HWCAP_VFPv3D16): New.
13191 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
13192 instead of __IWMMXT__.
13193 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
13194 (arm_arch_setup): New.
13195 (target_regsets): Remove #ifdef. Add VFP regset.
13196 (the_low_target): Use arm_arch_setup.
13197
12b42a12
DJ
131982009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13199
13200 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
13201 the main thread again.
13202
ac8c974e
AR
132032009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
13204
13205 Adding Neutrino gdbserver.
13206 * configure: Regenerated.
13207 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
13208 * configure.srv (i[34567]86-*-nto*): New target.
13209 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
13210 * remote-utils.c [__QNX__]: Include sys/iomgr.h
13211 (nto_comctrl) [__QNX__]: New function.
13212 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
13213
4424e0c3 132142009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
13215
13216 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
13217 srv_tgtobj.
13218
912cf4ba
PA
132192009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
13220 Pedro Alves <pedro@codesourcery.com>
13221
13222 * win32-i386-low.c (i386_get_thread_context): Handle systems that
13223 don't support CONTEXT_EXTENDED_REGISTERS.
13224 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
13225 (the_low_target): Install them.
13226 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
13227 failing with ERROR_PIPE_NOT_CONNECTED.
13228
aa5ca48f
DE
132292009-06-30 Doug Evans <dje@google.com>
13230 Pierre Muller <muller@ics.u-strasbg.fr>
13231
13232 Add h/w watchpoint support to x86-linux, win32-i386.
13233 * Makefile.in (SFILES): Add i386-low.c
13234 (i386_low_h): Define.
13235 (i386-low.o): Add dependencies.
13236 (linux-x86-low.o): Add i386-low.h dependency.
13237 (win32-i386-low.o): Ditto.
13238 * i386-low.c: New file.
13239 * i386-low.h: New file.
13240 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
13241 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
13242 * linux-low.c (linux_add_process): Initialize arch_private.
13243 (linux_remove_process): Free arch_private.
13244 (add_lwp): Initialize arch_private.
13245 (delete_lwp): Free arch_private.
13246 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
13247 provided.
13248 * linux-low.h (process_info_private): New member arch_private.
13249 (lwp_info): New member arch_private.
13250 (linux_target_ops): New members new_process, new_thread,
13251 prepare_to_resume.
13252 (ptid_of): New macro.
13253 * linux-x86-low.c: Include stddef.h, i386-low.h.
13254 (arch_process_info): New struct.
13255 (arch_lwp_info): New struct.
13256 (x86_linux_dr_get, x86_linux_dr_set): New functions.
13257 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13258 (i386_dr_low_get_status): New function.
13259 (x86_insert_point, x86_remove_point): New functions.
13260 (x86_stopped_by_watchpoint): New function.
13261 (x86_stopped_data_address): New function.
13262 (x86_linux_new_process, x86_linux_new_thread): New functions.
13263 (x86_linux_prepare_to_resume): New function.
13264 (the_low_target): Add entries for insert_point, remove_point,
13265 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
13266 prepare_to_resume.
13267 * server.c (debug_hw_points): New global.
13268 (monitor_show_help): Document set debug-hw-points.
13269 (handle_query): Process "set debug-hw-points".
13270 * server.h (debug_hw_points): Declare.
13271 (paddress): Declare.
13272 * utils.c (NUMCELLS, CELLSIZE): New macros.
13273 (get_sell, xsnprintf, paddress): New functions.
13274 * win32-arm-low.c (the_low_target): Add entries for insert_point,
13275 remove_point, stopped_by_watchpoint, stopped_data_address.
13276 * win32-i386-low.c: Include i386-low.h.
13277 (debug_reg_state): Replaces dr.
13278 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13279 (i386_dr_low_get_status): New function.
13280 (i386_insert_point, i386_remove_point): New functions.
13281 (i386_stopped_by_watchpoint): New function.
13282 (i386_stopped_data_address): New function.
13283 (i386_initial_stuff): Update.
13284 (get_thread_context,set_thread_context,i386_thread_added): Update.
13285 (the_low_target): Add entries for insert_point,
13286 remove_point, stopped_by_watchpoint, stopped_data_address.
13287 * win32-low.c (win32_insert_watchpoint): New function.
13288 (win32_remove_watchpoint): New function.
13289 (win32_stopped_by_watchpoint): New function.
13290 (win32_stopped_data_address): New function.
13291 (win32_target_ops): Add entries for insert_watchpoint,
13292 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
13293 * win32-low.h (win32_target_ops): New members insert_point,
13294 remove_point, stopped_by_watchpoint, stopped_data_address.
13295
d993e290
PA
132962009-06-25 Pedro Alves <pedro@codesourcery.com>
13297
13298 * server.c (process_serial_event): Re-return unsupported, not
13299 error, if the type isn't recognized. Re-allow supporting only
13300 insert or remove packets. Also call require_running for
13301 breakpoints. Add missing break statement to default case. Tidy.
13302 * target.h (struct target_ops): Rename insert_watchpoint to
13303 insert_point, and remove_watchpoint to remove_point.
13304
13305 * linux-low.h (struct linux_target_ops): Likewise.
13306 * linux-low.c (linux_insert_watchpoint): Rename to ...
13307 (linux_insert_point): ... this. Adjust.
13308 (linux_remove_watchpoint): Rename to ...
13309 (linux_remove_point): ... this. Adjust.
13310 (linux_target_ops): Adjust.
13311 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
13312 (cris_insert_point): ... this.
13313 (cris_remove_watchpoint): Rename to ...
13314 (cris_remove_point): ... this.
13315 (the_low_target): Adjust.
13316
0f54c268
PM
133172009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
13318
13319 * server.c (handle_v_kill): Pass signal_pid to
13320 kill_inferior if multi_process is zero.
13321
c6314022
AR
133222009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
13323
13324 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
13325 * target.h (target_ops): Comment for *_watchpoint to make it clear
13326 the functions can get types '0' and '1'.
13327
4463ce24
AR
133282009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
13329
13330 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
13331 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
13332 * regcache.c (get_regcache): Likewise.
13333 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
13334 * win32-low.c (child_fetch_inferior_registers): Remove check for
13335 regno 0.
13336
cf8fd78b
PA
133372009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
13338 Pedro Alves <pedro@codesourcery.com>
13339
13340 * target.h (struct target_ops) <supports_multi_process>: New
13341 callback.
13342 (target_supports_multi_process): New.
13343 * server.c (handle_query): Even if GDB reports support, only
13344 enable multi-process if the target also supports it. Report
13345 multi-process support only if the target backend supports it.
13346 * linux-low.c (linux_supports_multi_process): New function.
13347 (linux_target_ops): Install it as target_supports_multi_process
13348 callback.
13349
47c0c975
DE
133502009-05-24 Doug Evans <dje@google.com>
13351
e09875d4
DE
13352 Global renaming of find_thread_pid to find_thread_ptid.
13353 * server.h (find_thread_ptid): Renamed from find_thread_pid.
13354 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
13355 All callers updated.
13356
e27d73f6
DE
13357 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
13358 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
13359 directly.
13360
47c0c975
DE
13361 * linux-low.c (get_stop_pc): Print pc if debug_threads.
13362 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
13363 (linux_resume_one_lwp): Ditto.
13364
2acc282a
DE
133652009-05-23 Doug Evans <dje@google.com>
13366
13367 * linux-low.c (linux_resume_one_lwp): Change type of first arg
13368 from struct inferior_list_entry * to struct lwp_info *.
13369 All callers updated.
13370
9f1036c1
DE
133712009-05-13 Doug Evans <dje@google.com>
13372
13373 * linux-x86-low.c: Don't include assert.h.
13374 (x86_siginfo_fixup): Use fatal, not assert.
13375 (x86_arch_setup): Fix comment.
13376
d0722149
DE
133772009-05-12 Doug Evans <dje@google.com>
13378
13379 Biarch support for i386/amd64 gdbserver.
13380 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
13381 Add linux-x86-low.c.
13382 (linux-i386-low.o, linux-x86-64-low.o): Delete.
13383 (linux-x86-low.o): Add.
13384 * linux-x86-64-low.c: Delete.
13385 * linux-i386-low.c: Delete.
13386 * linux-x86-low.c: New file.
13387 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
13388 linux-x86-low.o.
13389 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
13390 linux-x86-low.o.
13391 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
13392 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
13393 (linux_child_pid_to_exec_file): New function.
13394 (elf_64_header_p, elf_64_file_p): New functions.
13395 (siginfo_fixup): New function.
13396 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
13397 give target a chance to convert layout.
13398 * linux-low.h (linux_target_ops): New member siginfo_fixup.
13399 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
13400
fdeb2a12
DE
134012009-05-07 Doug Evans <dje@google.com>
13402
13403 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
13404 (regsets_store_inferior_registers): Ditto.
13405
a6dbe5df
PA
134062009-05-06 Pedro Alves <pedro@codesourcery.com>
13407
13408 PR server/10048
13409
13410 * linux-low.c (must_set_ptrace_flags): Delete.
13411 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
13412 of the global.
13413 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
13414 `lwp->must_set_ptrace_flags' instead.
ba42693b 13415 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
13416 (linux_wait_1): ... not here.
13417
5091eb23
DE
134182009-04-30 Doug Evans <dje@google.com>
13419
9f767825
DE
13420 * inferiors.c (started_inferior_callback): New function.
13421 (attached_inferior_callback): New function.
13422 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
13423 * server.c (print_started_pid, print_attached_pid): New functions.
13424 (detach_or_kill_for_exit): New function.
13425 (main): Call it instead of for_each_inferior (kill_inferior_callback).
13426 * server.h (have_started_inferiors_p): Declare.
13427 (have_attached_inferiors_p): Declare.
13428
5091eb23
DE
13429 * inferiors.c (remove_process): Fix memory leak, free process.
13430 * linux-low.c (linux_remove_process): New function.
13431 (linux_kill): Call it instead of remove_process.
13432 (linux_detach, linux_wait_1): Ditto.
13433
155c8968
PA
134342009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
13435
13436 * configure.srv: Add x86 Windows CE target.
13437
7fe519cb
UW
134382009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
13439
13440 * inferiors.c (get_thread_process): Make global.
13441 * server.h (get_thread_process): Add prototype.
13442 * thread-db.c (find_one_thread): Use get_thread_process
13443 instead of current_process.
13444 (thread_db_get_tls_address): Do not crash if called when
13445 thread layer is not yet initialized.
13446
5472f405
UW
134472009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
13448
13449 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
13450 * spu-low.c (current_tid): Rename to ...
13451 (current_ptid): ... this.
13452 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
13453 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
13454 ptid_get_lwp (current_ptid) instead of current_tid.
13455 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
13456 instead of current_tid. Use find_process_pid to verify pid
13457 argument is valid. Pass proper argument to remove_process.
13458 (spu_thread_alive): Compare current_ptid instead of current_tid.
13459 (spu_resume): Likewise.
13460
55ac2b99
PA
134612009-04-02 Pedro Alves <pedro@codesourcery.com>
13462
13463 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
13464 variable.
13465
95954743
PA
134662009-04-01 Pedro Alves <pedro@codesourcery.com>
13467
13468 Implement the multiprocess extensions, and add linux multiprocess
13469 support.
13470
13471 * server.h (ULONGEST): Declare.
13472 (struct ptid, ptid_t): New.
13473 (minus_one_ptid, null_ptid): Declare.
13474 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
13475 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
13476 (struct inferior_list_entry): Change `id' type from unsigned from
13477 to ptid_t.
13478 (struct sym_cache, struct breakpoint, struct
13479 process_info_private): Forward declare.
13480 (struct process_info): Declare.
13481 (current_process): Declare.
13482 (all_processes): Declare.
13483 (initialize_inferiors): Declare.
13484 (add_thread): Adjust to use ptid_t.
13485 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
13486 (add_process, remove_process, find_thread_pid): Declare.
13487 (find_inferior_id): Adjust to use ptid_t.
13488 (cont_thread, general_thread, step_thread): Change type to ptid_t.
13489 (multi_process): Declare.
13490 (push_event): Adjust to use ptid_t.
13491 (read_ptid, write_ptid): Declare.
13492 (prepare_resume_reply): Adjust to use ptid_t.
13493 (clear_symbol_cache): Declare.
13494 * inferiors.c (all_processes): New.
13495 (null_ptid, minus_one_ptid): New.
13496 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
13497 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
13498 (add_thread): Change unsigned long to ptid. Remove gdb_id
13499 parameter. Adjust.
13500 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
13501 (gdb_id_to_thread): Rename to ...
13502 (find_thread_pid): ... this. Change unsigned long to ptid.
13503 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
13504 (loaded_dll, pull_pid_from_list): Adjust.
13505 (add_process, remove_process, find_process_pid)
13506 (get_thread_process, current_process, initialize_inferiors): New.
13507 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
13508 (struct target_waitstatus) <related_pid>: Ditto.
13509 (struct target_ops) <kill, detach>: Add `pid' argument. Change
13510 return type to int.
13511 (struct target_ops) <join>: Add `pid' argument.
13512 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
13513 (struct target_ops) <wait>: Add `ptid' field. Change return type
13514 to ptid.
13515 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
13516 (mywait): Add `ptid' argument. Change return type to ptid_t.
13517 (target_pid_to_str): Declare.
13518 * target.c (set_desired_inferior): Adjust to use ptids.
13519 (mywait): Add new `ptid' argument. Adjust.
13520 (target_pid_to_str): New.
13521 * mem-break.h (free_all_breakpoints): Declare.
13522 * mem-break.c (breakpoints): Delelete.
13523 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
13524 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
13525 to use per-process breakpoint list.
13526 (free_all_breakpoints): New.
13527 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
13528 (symbol_cache, all_symbols_looked_up): Delete.
13529 (hexchars): New.
13530 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
13531 read_ptid): New.
13532 (prepare_resume_reply): Change ptid argument's type from unsigned
13533 long to ptid_t. Adjust. Implement W;process and X;process.
13534 (free_sym_cache, clear_symbol_cache): New.
13535 (look_up_one_symbol): Adjust to per-process symbol cache. *
13536 * server.c (cont_thread, general_thread, step_thread): Change type
13537 to ptid_t.
13538 (attached): Delete.
13539 (multi_process): New.
13540 (last_ptid): Change type to ptid_t.
13541 (struct vstop_notif) <ptid>: Change type to ptid_t.
13542 (queue_stop_reply, push_event): Change `ptid' argument's type to
13543 ptid_t.
13544 (discard_queued_stop_replies): Add `pid' argument.
13545 (start_inferior): Adjust to use ptids. Adjust to mywait interface
13546 changes. Don't reference the `attached' global.
13547 (attach_inferior): Adjust to mywait interface changes.
13548 (handle_query): Adjust to use ptids. Parse GDB's qSupported
13549 features. Handle and report "multiprocess+". Handle
13550 "qAttached:PID".
13551 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
13552 changes.
13553 (handle_v_kill): New.
13554 (handle_v_stopped): Adjust to use target_pid_to_str.
13555 (handle_v_requests): Allow multiple attaches and runs when
13556 multiprocess extensions are in effect. Handle "vKill".
13557 (myresume): Adjust to use ptids.
13558 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
13559 (handle_status): Adjust to discard_queued_stop_replies interface
13560 change.
13561 (first_thread_of, kill_inferior_callback)
13562 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
13563 (main): Call initialize_inferiors. Adjust to use ptids, killing
13564 and detaching from all inferiors. Handle multiprocess packet
13565 variants.
13566 * linux-low.h: Include gdb_proc_service.h.
13567 (struct process_info_private): New.
13568 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
13569 <lwpid_of>: Use ptid_get_lwp.
13570 (get_lwp_thread): Adjust.
13571 (struct lwp_info): Add `dead' member.
13572 (find_lwp_pid): Declare.
13573 * linux-low.c (thread_db_active): Delete.
13574 (new_inferior): Adjust comment.
13575 (inferior_pid): Delete.
13576 (linux_add_process): New.
13577 (handle_extended_wait): Adjust.
13578 (add_lwp): Change unsigned long to ptid.
13579 (linux_create_inferior): Add process to processes table. Adjust
13580 to use ptids. Don't set new_inferior here.
13581 (linux_attach_lwp): Rename to ...
13582 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
13583 it. Adjust to use ptids.
13584 (linux_attach_lwp): New.
13585 (linux_attach): Add process to processes table. Don't set
13586 new_inferior here.
13587 (struct counter): New.
13588 (second_thread_of_pid_p, last_thread_of_process_p): New.
13589 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
13590 multiple processes.
13591 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
13592 processes. Remove process from process table.
13593 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
13594 to multiple processes.
13595 (any_thread_of): New.
13596 (linux_detach): Add `pid' argument, and handle it. Remove process
13597 from processes table.
13598 (linux_join): Add `pid' argument. Handle it.
13599 (linux_thread_alive): Change unsighed long argument to ptid_t.
13600 Consider dead lwps as not being alive.
13601 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
13602 threads we're not interested in.
13603 (same_lwp, find_lwp_pid): New.
13604 (linux_wait_for_lwp): Change `pid' argument's type from int to
13605 ptid_t. Adjust.
13606 (linux_wait_for_event): Rename to ...
13607 (linux_wait_for_event_1): ... this. Change `pid' argument's type
13608 from int to ptid_t. Adjust.
13609 (linux_wait_for_event): New.
13610 (linux_wait_1): Add `ptid' argument. Change return type to
13611 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
13612 that exit from the process table.
13613 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
13614 Adjust.
13615 (mark_lwp_dead): New.
13616 (wait_for_sigstop): Adjust to use ptids. If a process exits while
13617 stopping all threads, mark its main lwp as dead.
13618 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
13619 ptids.
13620 (fetch_register, usr_store_inferior_registers)
13621 (regsets_fetch_inferior_registers)
13622 (regsets_store_inferior_registers, linux_read_memory)
13623 (linux_write_memory): Inline `inferior_pid'.
13624 (linux_look_up_symbols): Adjust to use per-process
13625 `thread_db_active'.
13626 (linux_request_interrupt): Adjust to use ptids.
13627 (linux_read_auxv): Inline `inferior_pid'.
13628 (initialize_low): Don't reference thread_db_active.
13629 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
13630 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
13631 (ps_getpid): Return the pid of the current inferior.
13632 * thread-db.c (proc_handle, thread_agent): Delete.
13633 (thread_db_create_event, thread_db_enable_reporting): Adjust to
13634 per-process data.
13635 (find_one_thread): Change argument type to ptid_t. Adjust to
13636 per-process data.
13637 (maybe_attach_thread): Adjust to per-process data and ptids.
13638 (thread_db_find_new_threads): Ditto.
13639 (thread_db_init): Ditto.
13640 * spu-low.c (spu_create_inferior, spu_attach): Add process to
13641 processes table. Adjust to use ptids.
13642 (spu_kill, spu_detach): Adjust interface. Remove process from
13643 processes table.
13644 (spu_join, spu_thread_alive): Adjust interface.
13645 (spu_wait): Adjust interface. Remove process from processes
13646 table. Adjust to use ptids.
13647 * win32-low.c (current_inferior_tid): Delete.
13648 (current_inferior_ptid): New.
13649 (debug_event_ptid): New.
13650 (thread_rec): Take a ptid. Adjust.
13651 (child_add_thread): Add `pid' argument. Adjust to use ptids.
13652 (child_delete_thread): Ditto.
13653 (do_initial_child_stuff): Add `attached' argument. Add process to
13654 processes table.
13655 (child_fetch_inferior_registers, child_store_inferior_registers):
13656 Adjust.
13657 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
13658 (win32_attach): Pass 1 to do_initial_child_stuff.
13659 (win32_kill): Adjust interface. Remove process from processes
13660 table.
13661 (win32_detach): Ditto.
13662 (win32_join): Adjust interface.
13663 (win32_thread_alive): Take a ptid.
13664 (win32_resume): Adjust to use ptids.
13665 (get_child_debug_event): Ditto.
13666 (win32_wait): Adjust interface. Remove exiting process from
13667 processes table.
13668
bd99dc85
PA
136692009-04-01 Pedro Alves <pedro@codesourcery.com>
13670
13671 Non-stop mode support.
13672
13673 * server.h (non_stop): Declare.
13674 (gdb_client_data, handler_func): Declare.
13675 (delete_file_handler, add_file_handler, start_event_loop):
13676 Declare.
13677 (handle_serial_event, handle_target_event, push_event)
13678 (putpkt_notif): Declare.
13679 * target.h (enum resume_kind): New.
13680 (struct thread_resume): Replace `step' field by `kind' field.
13681 (TARGET_WNOHANG): Define.
13682 (struct target_ops) <wait>: Add `options' argument.
13683 <supports_non_stop, async, start_non_stop>: New fields.
13684 (target_supports_non_stop, target_async): New.
13685 (start_non_stop): Declare.
13686 (mywait): Add `options' argument.
13687 * target.c (mywait): Add `options' argument. Print child exit
13688 notifications here.
13689 (start_non_stop): New.
13690 * server.c (non_stop, own_buf, mem_buf): New globals.
13691 (struct vstop_notif): New.
13692 (notif_queue): New global.
13693 (queue_stop_reply, push_event, discard_queued_stop_replies)
13694 (send_next_stop_reply): New.
13695 (start_inferior): Adjust to use resume_kind. Adjust to mywait
13696 interface changes.
13697 (attach_inferior): In non-stop mode, don't wait for the target
13698 here.
13699 (handle_general_set): Handle QNonStop.
13700 (handle_query): When handling qC, return the current general
13701 thread, instead of the first thread of the list.
13702 (handle_query): If the backend supports non-stop mode, include
13703 QNonStop+ in the qSupported query response.
13704 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
13705 and non-stop mode.
13706 (handle_v_attach, handle_v_run): Handle non-stop mode.
13707 (handle_v_stopped): New.
13708 (handle_v_requests): Report support for vCont;t. Handle vStopped.
13709 (myresume): Adjust to use resume_kind. Handle non-stop.
13710 (queue_stop_reply_callback): New.
13711 (handle_status): Handle non-stop mode.
13712 (main): Clear non_stop flag on reconnection. Use the event-loop.
13713 Refactor serial protocol handling from here ...
13714 (process_serial_event): ... to this new function. When GDB
13715 selects any thread, select one here. In non-stop mode, wait until
13716 GDB acks all pending events before exiting.
13717 (handle_serial_event, handle_target_event): New.
13718 * remote-utils.c (remote_open): Install remote_desc in the event
13719 loop.
13720 (remote_close): Remove remote_desc from the event loop.
13721 (putpkt_binary): Rename to...
13722 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
13723 (putpkt_binary): New as wrapper around putpkt_binary_1.
13724 (putpkt_notif): New.
13725 (prepare_resume_reply): In non-stop mode, don't change the
13726 general_thread.
13727 * event-loop.c: New.
13728 * Makefile.in (OBJ): Add event-loop.o.
13729 (event-loop.o): New rule.
13730
13731 * linux-low.h (pid_of): Moved here.
13732 (lwpid_of): New.
13733 (get_lwp_thread): Use lwpid_of.
13734 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
13735 * linux-low.c (pid_of): Delete.
13736 (inferior_pid): Use lwpid_of.
13737 (linux_event_pipe): New.
13738 (target_is_async_p): New.
13739 (delete_lwp): New.
13740 (handle_extended_wait): Use lwpid_of.
13741 (add_lwp): Don't set lwpid field.
13742 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
13743 (linux_kill_one_lwp): If killing a running lwp, stop it first.
13744 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
13745 (linux_detach_one_lwp): If detaching from a running lwp, stop it
13746 first. Adjust to linux_wait_for_event interface changes. Use
13747 lwpid_of.
13748 (linux_detach): Don't delete the main lwp here.
13749 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
13750 (status_pending_p): Don't consider explicitly suspended lwps.
13751 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
13752 pointer. Add OPTIONS argument. Change return type to int. Use
13753 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
13754 (linux_wait_for_event): Take an integer pid instead of a lwp_info
13755 pointer. Add status pointer argument. Return a pid instead of a
13756 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
13757 changes. In non-stop mode, don't switch to a random thread.
13758 (linux_wait): Rename to...
13759 (linux_wait_1): ... this. Add target_options argument, and handle
13760 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
13761 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
13762 clean exit and signal exit code. Don't stop all threads in
13763 non-stop mode. In all-stop mode, only stop all threads when
13764 reporting a stop to GDB. Handle explicit thread stop requests.
13765 (async_file_flush, async_file_mark): New.
13766 (linux_wait): New.
13767 (send_sigstop): Use lwpid_of.
13768 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
13769 interface changes. In non-stop mode, don't switch to a random
13770 thread.
13771 (linux_resume_one_lwp): Use lwpid_of.
13772 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
13773 (linux_resume_one_thread): ... this. Handle resume_stop. In
13774 non-stop mode, don't look for pending flag in all threads.
13775 (resume_status_pending_p): Don't consider explicitly suspended
13776 threads.
13777 (my_waitpid): Reimplement. Emulate __WALL.
13778 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
13779 Use lwpid_of.
13780 (sigchld_handler, linux_supports_non_stop, linux_async)
13781 (linux_start_non_stop): New.
13782 (linux_target_ops): Register linux_supports_non_stop, linux_async
13783 and linux_start_non_stop.
13784 (initialize_low): Install SIGCHLD handler.
13785 * thread-db.c (thread_db_create_event, find_one_thread)
13786 (thread_db_get_tls_address): Use lwpid_of.
13787 * win32-low.c (win32_detach): Adjust to use resume_kind.
13788 (win32_wait): Add `options' argument.
13789 * spu-low.c (spu_resume): Adjust to use resume_kind.
13790 (spu_wait): Add `options' argument.
13791
5b1c542e
PA
137922009-04-01 Pedro Alves <pedro@codesourcery.com>
13793
13794 Decouple target code from remote protocol.
13795
13796 * target.h (enum target_waitkind): New.
13797 (struct target_waitstatus): New.
13798 (struct target_ops) <wait>: Return an unsigned long. Take a
13799 target_waitstatus pointer instead of a char pointer.
13800 (mywait): Likewise.
13801 * target.c (mywait): Change prototype to return an unsigned long.
13802 Take a target_waitstatus pointer instead of a char pointer. Adjust.
13803 * server.h (thread_from_wait, old_thread_from_wait): Delete
13804 declarations.
13805 (prepare_resume_reply): Change prototype to take a
13806 target_waitstatus.
13807 * server.c (thread_from_wait, old_thread_from_wait): Delete.
13808 (last_status, last_ptid): New.
13809 (start_inferior): Remove "statusptr" argument. Adjust. Return a
13810 pid instead of a signal.
13811 (attach_inferior): Remove "status" and "signal" parameters.
13812 Adjust.
13813 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
13814 not as an address.
13815 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
13816 (handle_v_requests, myresume): Remove "status" and "signal"
13817 parameters. Adjust.
13818 (handle_status): New.
13819 (main): Delete local `status'. Adjust.
13820 * remote-utils.c: Include target.h.
13821 (prepare_resume_reply): Change prototype to take a
13822 target_waitstatus. Adjust.
13823
13824 * linux-low.c (linux_wait): Adjust to new target_ops->wait
13825 interface.
13826 * spu-low.c (spu_wait): Adjust.
13827 * win32-low.c (enum target_waitkind, struct target_waitstatus):
13828 Delete.
13829 (win32_wait): Adjust.
13830
2bd7c093
PA
138312009-04-01 Pedro Alves <pedro@codesourcery.com>
13832
13833 * target.h (struct thread_resume): Delete leave_stopped member.
13834 (struct target_ops): Add a `n' argument to the `resume' callback.
13835 * server.c (start_inferior): Adjust.
13836 (handle_v_cont, myresume): Adjust.
13837 * linux-low.c (check_removed_breakpoint): Adjust to resume
13838 interface change, and to removed leave_stopped field.
13839 (resume_ptr): Delete.
13840 (struct thread_resume_array): New.
13841 (linux_set_resume_request): Add new `arg' parameter. Adjust to
13842 resume interface change.
13843 (linux_continue_one_thread, linux_queue_one_thread)
13844 (resume_status_pending_p): Check if the resume field is NULL
13845 instead of checking the leave_stopped member.
13846 (linux_resume): Adjust to the target resume interface change.
13847 * spu-low.c (spu_resume): Adjust to the target resume interface
13848 change.
13849 * win32-low.c (win32_detach, win32_resume): Ditto.
13850
c35fafde
PA
138512009-04-01 Pedro Alves <pedro@codesourcery.com>
13852
13853 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
13854 flag.
13855 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
13856 pending.
13857 (linux_continue_one_thread): Only preserve the stepping flag if
13858 there's a pending breakpoint.
13859
0a59d50b
PA
138602009-03-31 Pedro Alves <pedro@codesourcery.com>
13861
13862 * server.c (main): After the inferior having exited, call
13863 remote_close before exiting gdbserver.
13864
f04c6d38
TJB
138652009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
13866
13867 Fix size of FPSCR in Power 7 processors.
13868 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
13869 (PPC_FEATURE_HAS_DFP): New #define.
13870 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
13871 size of the FPSCR.
13872
78e5cee6
PA
138732009-03-23 Pedro Alves <pedro@codesourcery.com>
13874
13875 * server.c (handle_query) Whitespace and formatting.
13876
1b3f6016
PA
138772009-03-22 Pedro Alves <pedro@codesourcery.com>
13878
13879 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
13880 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
13881 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
13882 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
13883 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
13884 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
13885 Makefile.in, configure.ac: Fix whitespace throughout.
13886 * configure: Regenerate.
13887
a07b2135
PA
138882009-03-22 Pedro Alves <pedro@codesourcery.com>
13889
13890 * inferiors.c (find_inferior): Make it safe for the callback
13891 function to delete the currently iterated inferior.
13892
67cc2626
PA
138932009-03-22 Pedro Alves <pedro@codesourcery.com>
13894
13895 * Makefile.in (linuw_low_h): Move higher.
13896 (thread-db.o): Depend on $(linux_low_h).
13897
54a0b537
PA
138982009-03-17 Pedro Alves <pedro@codesourcery.com>
13899
13900 Rename "process" to "lwp" throughout.
13901
13902 * linux-low.c (all_processes): Rename to...
13903 (all_lwps): ... this.
13904 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
13905 (add_process): Rename to ...
13906 (add_lwp): ... this. Adjust.
13907 (linux_create_inferior): Adjust.
13908 (linux_attach_lwp): Adjust.
13909 (linux_attach): Adjust.
13910 (linux_kill_one_process): Rename to ...
13911 (linux_kill_one_lwp): ... this. Adjust.
13912 (linux_kill): Adjust.
13913 (linux_detach_one_process): Rename to ...
13914 (linux_detach_one_lwp): ... this. Adjust.
13915 (linux_detach): Adjust.
13916 (check_removed_breakpoint): Adjust.
13917 (status_pending_p): Adjust.
13918 (linux_wait_for_process): Rename to ...
13919 (linux_wait_for_lwp): ... this. Adjust.
13920 (linux_wait_for_event): Adjust.
13921 (send_sigstop): Adjust.
13922 (wait_for_sigstop): Adjust.
13923 (stop_all_processes): Rename to ...
13924 (stop_all_lwps): ... this.
13925 (linux_resume_one_process): Rename to ...
13926 (linux_resume_one_lwp): ... this. Adjust.
13927 (linux_set_resume_request, linux_continue_one_thread)
13928 (linux_queue_one_thread, resume_status_pending_p)
13929 (usr_store_inferior_registers, regsets_store_inferior_registers)
13930 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
13931 Adjust.
13932 * linux-low.h (get_process): Rename to ...
13933 (get_lwp): ... this. Adjust.
13934 (get_thread_process): Rename to ...
13935 (get_thread_lwp): ... this. Adjust.
13936 (get_process_thread): Rename to ...
13937 (get_lwp_thread): ... this. Adjust.
13938 (struct process_info): Rename to ...
13939 (struct lwp_info): ... this.
13940 (all_processes): Rename to ...
13941 (all_lwps): ... this.
13942 * proc-service.c (ps_lgetregs): Adjust.
13943 * thread-db.c (thread_db_create_event, find_one_thread)
13944 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
13945
0b16c5cf
PA
139462009-03-14 Pedro Alves <pedro@codesourcery.com>
13947
13948 * server.c (handle_query): Handle "qAttached".
13949
32de4b9d
NS
139502009-03-13 Nathan Sidwell <nathan@codesourcery.com>
13951
13952 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
13953 GPLv3, update license URL.
13954
2aecd87f
DE
139552009-03-01 Doug Evans <dje@google.com>
13956
93efd302 13957 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
13958 (server_h): Add gdb_signals.h.
13959 (signals.o): Update.
13960 * server.h (target_signal_from_host,target_signal_to_host_p)
13961 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
13962
86b1f9c5
PM
139632009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
13964
13965 * remote-utils.c (getpkt): Also generate remote-debug
13966 information if noack_mode is set.
13967
4aa995e1
PA
139682009-02-06 Pedro Alves <pedro@codesourcery.com>
13969
13970 * server.c (handle_query): Report qXfer:siginfo:read and
13971 qXfer:siginfo:write as supported and handle them.
13972 * target.h (struct target_ops) <qxfer_siginfo>: New field.
13973 * linux-low.c (linux_xfer_siginfo): New.
13974 (linux_target_ops): Set it.
13975
62709adf
PA
139762009-01-26 Pedro Alves <pedro@codesourcery.com>
13977
13978 * server.c (gdbserver_usage): Mention --remote-debug.
13979 (main): Accept '--remote-debug' switch.
13980
aef93bd7
DE
139812009-01-18 Doug Evans <dje@google.com>
13982
13983 * regcache.c (new_register_cache): No need to check result of xcalloc.
13984 * server.c (handle_search_memory): Back out calls to xmalloc,
13985 result is checked and error is returned to user upon failure.
13986 (handle_query): Ditto. Add more checks for result of malloc.
13987 (handle_v_cont): Check result of malloc, report error back to
13988 user upon failure.
13989 (handle_v_run): Ditto. Call freeargv.
13990 * server.h (freeargv): Declare.
13991 * utils.c (freeargv): New fn.
13992
54363045
DE
139932009-01-15 Doug Evans <dje@google.com>
13994
f626972c
DE
13995 * gdbreplay.c (perror_with_name): Make arg const char *.
13996 * server.h (target_signal_to_name): Make return type const char *.
0842e787 13997 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 13998 * utils.c (perror_with_name): Make arg const char *.
54363045 13999
18aae699
PA
140002009-01-14 Pedro Alves <pedro@codesourcery.com>
14001
14002 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
14003 when handling a EXIT_PROCESS_DEBUG_EVENT.
14004
ff703abe
JB
140052009-01-06 Joel Brobecker <brobecker@adacore.com>
14006
14007 * gdbreplay.c (gdbreplay_version): Update copyright year.
14008 * server.c (gdbserver_version): Likewise.
14009
f21cc1a2 140102009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
14011
14012 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 14013 (handle_extended_wait): Improve comment.
0e21c1ec 14014
bca929d3
DE
140152008-12-13 Doug Evans <dje@google.com>
14016
14017 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
14018 * server.h (ATTR_MALLOC): New macro.
14019 (xmalloc,xcalloc,xstrdup): Declare.
14020 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
14021 * inferiors.c: Ditto.
14022 * linux-low.c: Ditto.
14023 * mem-break.c: Ditto.
14024 * regcache.c: Ditto.
14025 * remote-utils.c: Ditto.
14026 * server.c: Ditto.
14027 * target.c: Ditto.
14028 * win32-low.c: Ditto.
14029
97438e3f
DE
140302008-12-12 Doug Evans <dje@google.com>
14031
896c7fbb
DE
14032 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
14033 in debugging printf.
14034
97438e3f
DE
14035 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
14036
e3b886f8
DE
140372008-12-09 Doug Evans <dje@google.com>
14038
14039 * linux-low.h (struct process_info): Delete member tid, unused.
14040 * thread-db.c (find_one_thread): Update.
14041 (maybe_attach_thread): Update.
14042
07e059b5
VP
140432008-12-02 Pedro Alves <pedro@codesourcery.com>
14044
889bf7c5
PA
14045 * target.h (struct target_ops): Add qxfer_osdata member.
14046 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
14047 and dirent.h.
14048 (linux_qxfer_osdata): New functions.
14049 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
14050 callback.
14051 * server.c (handle_query): Handle "qXfer:osdata:read:".
14052 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
14053 (buffer_xml_printf): New functions.
14054 * server.h (struct buffer): New.
14055 (buffer_grow_str, buffer_grow_str0): New macros.
14056 (buffer_grow, buffer_free, buffer_init, buffer_finish)
14057 (buffer_xml_printf): Declare.
07e059b5 14058
4cab47ab
DE
140592008-11-24 Doug Evans <dje@google.com>
14060
14061 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
14062
f142445f
DJ
140632008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
14064
14065 * server.c (handle_v_run): Always use the supplied argument list.
14066
d0107bb6 140672008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 14068
d0107bb6
BW
14069 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
14070 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 14071
2c4ad781
TJB
140722008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
14073
14074 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
14075 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
14076 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
14077 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
14078 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
14079 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
14080 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
14081 XML target descriptions.
14082 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
14083 when inferior is running on an ISA 2.05 or later processor. Add
14084 special case to return offset for full 64-bit slot of FPSCR when
14085 in 32-bits.
14086
dfb64f85
DJ
140872008-11-14 Daniel Gutson <dgutson@codesourcery.com>
14088
14089 * Makefile.in (SFILES, clean): Added sparc64 files.
14090 (reg-sparc64.o, reg-sparc64.c): New.
14091 * configure.srv (sparc*-*-linux*): New configuration.
14092 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
14093 syscall arguments for SPARC.
14094 (regsets_store_inferior_registers): Likewise.
14095 * linux-sparc-low.c: New file.
14096
66b6e1dd
DE
140972008-10-21 Doug Evans <dje@google.com>
14098
14099 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
14100 (READLINE_DIR,READLINE_DEP): Delete.
14101 (INTERNAL_CFLAGS): Update.
14102 (LINTFLAGS): Update.
14103
9b710a42
PA
141042008-10-10 Pedro Alves <pedro@codesourcery.com>
14105
14106 * server.c (handle_v_run): If GDB didn't specify an argv, use the
14107 whole argv from the last run, not just argv[0].
14108
5822d809
PA
141092008-09-08 Pedro Alves <pedro@codesourcery.com>
14110
14111 * regcache.c (new_register_cache): Return NULL if the register
14112 cache size isn't known yet.
14113 (free_register_cache): Avoid dereferencing a NULL regcache.
14114
74aac56f
DJ
141152008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
14116
14117 * configure.srv: Merge MIPS and MIPS64.
14118
400b20f5
MR
141192008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
14120
14121 * Makefile.in (uninstall): Apply $(EXEEXT) too.
14122
677c5bb1
LM
141232008-08-18 Luis Machado <luisgpm@br.ibm.com>
14124
14125 * Makefile.in: Add required vsx dependencies.
14126
14127 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
14128 Declare init_registers_powerpc_vsx32l.
14129 Declare init_registers_powerpc_vsx64l.
14130 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
14131 (ppc_arch_setup): Check for VSX in hwcap.
14132 (ppc_fill_vsxregset): New function.
14133 (ppc_store_vsxregset): New function.
14134 Add new VSX entry in regset_info target_regsets.
14135
14136 * configure.srv: Add new VSX dependencies.
14137
a6f3e723
SL
141382008-08-12 Pedro Alves <pedro@codesourcery.com>
14139
14140 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
14141 (remote_open): Set or clear transport_is_reliable.
14142 (putpkt_binary): Don't expect acks in noack mode.
14143 (getpkt): Don't send ack/nac in noack mode.
14144 * server.c (handle_general_set): Handle QStartNoAckMode.
14145 (handle_query): If connected by tcp pass QStartNoAckMode+ in
14146 qSupported.
14147 (main): Reset noack_mode on every connection.
14148 * server.h (noack_mode): Declare.
14149
a417dc56
RW
141502008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14151
14152 * Makefile.in (GDBREPLAY_OBS): New variable.
14153 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
14154
3221518c
UW
141552008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
14156 Daniel Jacobowitz <dan@codesourcery.com>
14157
14158 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
14159 (usr_store_inferior_registers): Likewise.
14160 (regsets_store_inferior_registers): Likewise.
14161
ec56be1b
PA
141622008-07-31 Rolf Jansen <rj@surtec.com>
14163 Pedro Alves <pedro@codesourcery.com>
14164
14165 * configure.ac: Check for memmem declaration.
14166 * server.c [HAVE_MALLOC_H]: Include malloc.h.
14167 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
14168 (disable_packet_qfThreadInfo): Unconditionally compile.
14169 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
14170 * configure, config.in: Regenerate.
14171
2fe5e3ff
DE
141722008-07-28 Doug Kwan <dougkwan@google.com>
14173
14174 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
14175 (linux_write_memory): Remove declaration of errno.
14176
836acd6d
UW
141772008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
14178
14179 * linux-low.c (handle_extended_wait): Do not use "status"
14180 variable uninitialized.
14181
aeba519e
PA
141822008-07-07 Pedro Alves <pedro@codesourcery.com>
14183
14184 * server.c (handle_v_attach): Inhibit reporting dll changes.
14185
db42f210
PA
141862008-06-27 Pedro Alves <pedro@codesourcery.com>
14187
14188 * remote-utils.c (prepare_resume_reply): If requested, don't
14189 output "thread:TID" in the T stop reply.
14190
14191 * server.c (disable_packet_vCont, disable_packet_Tthread)
14192 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
14193 (handle_query): If requested, disable support for qC, qfThreadInfo
14194 and qsThreadInfo.
14195 (handle_v_requests): If requested, disable support for vCont.
14196 (gdbserver_show_disableable): New.
14197 (main): Handle --disable-packet and --disable-packet=LIST.
14198
14199 * server.h (disable_packet_vCont, disable_packet_Tthread)
14200 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
14201
8e4c5421
CD
142022008-06-20 Carlos O'Donell <carlos@codesourcery.com>
14203
14204 * server.c (gdbserver_usage): Mention --version.
14205
6e23a804
DJ
142062008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
14207
14208 * Makefile.in (gdbreplay.o): New rule.
14209
90aa6a40
JM
142102008-06-06 Joseph Myers <joseph@codesourcery.com>
14211
14212 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
14213 message, not gdbserver.
14214
c16158bc 142152008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
14216 Nathan Sidwell <nathan@codesourcery.com>
14217 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
14218
14219 * acinclude.m4: Include ../../config/acx.m4.
14220 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
14221 * configure, config.in: Regenerate.
14222 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
14223 * server.c (gdbserver_version): Print PKGVERSION.
14224 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
14225 (main): Adjust gdbserver_usage calls.
14226 * gdbreplay.c (version, host_name): Add declarations.
14227 (gdbreplay_version, gdbreplay_usage): New.
14228 (main): Accept --version and --help options.
14229
aeb75bf5
DJ
142302008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
14231
14232 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
14233 (arm_breakpoint_at): Handle Thumb.
14234 (the_low_target): Add comment.
14235
76b233dd
UW
142362008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
14237
14238 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
14239
08388c79
DE
142402008-05-09 Doug Evans <dje@google.com>
14241
a3c83fae
DE
14242 * server.h (decode_search_memory_packet): Declare.
14243 * remote-utils.c (decode_search_memory_packet): New fn.
14244 * server.c (handle_search_memory_1): New fn.
08388c79
DE
14245 (handle_search_memory): New fn.
14246 (handle_query): Process qSearch:memory packets.
14247
bb9c3d36
UW
142482008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
14249
14250 * regcache.c (registers_length): Remove.
14251 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
14252 full register packet.
14253 * regcache.h (registers_length): Remove prototype.
14254 * server.h (PBUFSIZ): Define to 16384.
14255
7284e1be
UW
142562008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
14257
14258 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
14259 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
14260 powerpc-64l.o, and powerpc-altivec64l.o.
14261 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
14262 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
14263 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
14264 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
14265 rs6000/power-linux.xml, and rs6000/power64-linux.xml
14266 to srv_xmlfiles.
14267
14268 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
14269 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
14270 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
14271 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
14272 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
14273 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
14274 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
14275 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
14276 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
14277 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
14278 (clean): Update.
14279
14280 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
14281 (init_registers_powerpc_32l): ... this new prototype.
14282 (init_registers_powerpc_32): Remove, replace by ...
14283 (init_registers_powerpc_altivec32l): ... this new prototype.
14284 (init_registers_powerpc_e500): Remove, replace by ...
14285 (init_registers_powerpc_e500l): ... this new prototype.
14286 (init_registers_ppc64): Remove, replace by ...
14287 (init_registers_powerpc_64l): ... this new prototype.
14288 (init_registers_powerpc_64): Remove, replace by ...
14289 (init_registers_powerpc_altivec64l): ... this new prototype.
14290 (ppc_num_regs): Set to 73.
14291 (PT_ORIG_R3, PT_TRAP): Define if necessary.
14292 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
14293 (ppc_cannot_store_register): Handle orig_r3 and trap.
14294 (ppc_arch_setup): Update init_registers_... calls.
14295 (ppc_fill_gregset): Handle orig_r3 and trap.
14296
14297 * inferiors.c (clear_inferiors): Reset current_inferior.
14298
fdc59709
PB
142992008-04-23 Paolo Bonzini <bonzini@gnu.org>
14300
889bf7c5
PA
14301 * acinclude.m4: Add override.m4.
14302 * configure: Regenerate.
fdc59709 14303
c9b2f845
UW
143042008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
14305
14306 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
14307 initial call to init_register_ppc64.
14308
550512b8
UW
143092008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
14310
43aaf8b6
PA
14311 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
14312 single powerpc*-*-linux* case.
550512b8
UW
14313 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
14314
b6430ec3
UW
143152008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
14316
14317 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 14318 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
14319 from reg_xmlfiles.
14320 * linux-ppc-low.c: Include <elf.h>.
14321 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
14322 (ppc_hwcap): New global variable.
14323 (ppc_regmap): Remove __SPE__ #ifdef sections.
14324 (ppc_regmap_e500): New global variable.
14325 (ppc_cannot_store_register): Update __SPE__ special case.
14326 (ppc_get_hwcap): New function.
14327 (ppc_arch_setup): Use it to determine whether inferior supports
14328 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
14329 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
14330 Do not access registers if target does not support AltiVec.
14331 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
14332 Do not access registers if target does not support SPE.
14333 (target_regsets): Unconditionally include AltiVec and SPE regsets.
14334
52fa2412
UW
143352008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
14336
14337 * linux-low.c (disabled_regsets, num_regsets): New.
14338 (use_regsets_p): Delete.
14339 (linux_wait_for_process): Clear disabled_regsets.
14340 (regsets_fetch_inferior_registers): Check and set it.
14341 (regsets_store_inferior_registers): Likewise.
14342 (linux_fetch_registers, linux_store_registers): Do not use
14343 use_regsets_p.
14344 (initialize_low): Allocate disabled_regsets.
14345
e28b3332
DJ
143462008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
14347
14348 * Makefile.in (LIBOBJS): New.
14349 (OBS): Use LIBOBJS.
14350 (memmem.o): New rule.
14351 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
14352 * configure: Regenerated.
14353
4536995d
UW
143542008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
14355
14356 * server.c (handle_query): Never return "unsupported" for
14357 qXfer:features:read queries.
14358
221c031f
UW
143592008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
14360
14361 * server.c (get_features_xml): Fix inverted condition.
14362 (handle_query): Always support qXfer:feature:read.
14363
ccd213ac
DJ
143642008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
14365
14366 * server.c (wrapper_argv): New.
14367 (start_inferior): Handle wrapper_argv. If set, expect an extra
14368 trap.
14369 (gdbserver_usage): Document --wrapper.
14370 (main): Parse --wrapper.
14371
6fe305f7
UW
143722008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14373
14374 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
14375 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
14376 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
14377 (ppc_set_pc): Likewise.
14378 (ppc_arch_setup): New function.
14379 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
14380 of collect_register.
889bf7c5 14381 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 14382
5b0a002e
UW
143832008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14384
14385 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
14386 instead of linux-ppc64-low.o.
14387 * linux-ppc64-low.c: Remove file.
14388 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
14389 (linux-ppc64-low.o): Remove rule.
14390
14391 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
14392 (init_registers_powerpc_64): Likewise.
14393 (ppc_regmap): Conditionally define depending on __powerpc64__.
14394 (ppc_cannot_store_register): Do not special-case "fpscr" when
14395 compiled on __powerpc64__.
14396 (ppc_collect_ptrace_register): New function.
14397 (ppc_supply_ptrace_register): New function.
14398 (ppc_breakpoint): Change type to "unsigned int".
14399 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
14400 (the_low_target): Conditionally provide initializers for the
889bf7c5 14401 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
14402 collect_ptrace_register and supply_ptrace_register members.
14403
9b4b61c8
UW
144042008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14405
14406 * regcache.h (gdbserver_xmltarget): Add extern declaration.
14407 * server.c (gdbserver_xmltarget): Define.
14408 (get_features_xml): Use it to replace "target.xml" and arch_string.
14409
14410 * configure.srv: Remove srv_xmltarget. Add XML files that were
14411 mentioned there to srv_xmlfiles instead. Remove conditional tests
14412 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
14413 srv_xmlfiles and srv_regobj to include all possible choices.
14414 * configure.ac (srv_xmltarget): Remove.
14415 (srv_xmlfiles): Do not add "target.xml".
14416 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
14417 checks for supplementary target information.
14418 * configure: Regenerate.
14419 * Makefile.in (XML_TARGET): Remove.
14420 (target.xml): Remove rule.
14421 (clean): Do not clean up target.xml.
14422 (.PRECIOUS): Do not mention target.xml.
14423
14424 * target.h (struct target_ops): Remove arch_string member.
14425 * linux-low.c (linux_arch_string): Remove.
14426 (linux_target_ops): Remove arch_string initializer.
14427 * linux-low.h (struct linux_target_ops): Remove arch_string member.
14428 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
14429 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
14430 * spu-low.c (spu_arch_string): Remove.
14431 (spu_target_ops): Remove arch_string initializer.
14432 * win32-low.c (win32_arch_string): Remove.
14433 (win32_target_ops): Remove arch_string initializer.
14434 * win32-low.h (struct win32_target_ops): Remove arch_string member.
14435 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
14436 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
14437
ee1a7ae4
UW
144382008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
14439
14440 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
14441 by collect_ptrace_register and supply_ptrace_register hooks.
14442 * linux-low.c (fetch_register): Use supply_ptrace_register callback
14443 instead of checking for the_low_target.left_pad_xfer.
14444 (usr_store_inferior_registers): Use collect_ptrace_register callback
14445 instead of checking for the_low_target.left_pad_xfer.
14446
14447 * linux-s390-low.c (s390_collect_ptrace_register): New function.
14448 (s390_supply_ptrace_register): Likewise.
14449 (s390_fill_gregset): Call s390_collect_ptrace_register.
14450 (the_low_target): Update.
14451
14452 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
14453 (ppc_supply_ptrace_register): Likewise.
14454 (the_low_target): Update.
14455
14456 * linux-i386-low.c (the_low_target): Update.
14457 * linux-x86-64-low.c (the_low_target): Update.
14458
d61ddec4
UW
144592008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
14460
14461 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
14462 reg-s390.o and reg-s390x.o.
14463
14464 * linux-low.c (new_inferior): New global variable.
14465 (linux_create_inferior, linux_attach): Set it.
14466 (linux_wait_for_process): Call the_low_target.arch_setup after the
14467 target has stopped for the first time.
14468 (initialize_low): Do not call the_low_target.arch_setup.
14469
14470 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
14471 (s390_set_pc): Likewise.
14472 (s390_arch_setup): New function.
14473 (the_low_target): Use s390_arch_setup as arch_setup routine.
14474
14475 * regcache.c (realloc_register_cache): New function.
14476 (set_register_cache): Call it for each existing regcache.
14477
d05b4ac3
UW
144782008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
14479
14480 * server.h (init_registers): Remove prototype.
14481
14482 * linux-low.h (struct linux_target_ops): Add arch_setup field.
14483 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
14484 instead of init_registers ().
14485 * linux-arm-low.c (init_registers_arm): Add prototype.
14486 (init_registers_arm_with_iwmmxt): Likewise.
14487 (the_low_target): Add initializer for arch_setup field.
14488 * linux-cris-low.c (init_registers_cris): Add prototype.
14489 (the_low_target): Add initializer for arch_setup field.
14490 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
14491 (the_low_target): Add initializer for arch_setup field.
14492 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
14493 (the_low_target): Add initializer for arch_setup field.
14494 * linux-ia64-low.c (init_registers_ia64): Add prototype.
14495 (the_low_target): Add initializer for arch_setup field.
14496 * linux-m32r-low.c (init_registers_m32r): Add prototype.
14497 (the_low_target): Add initializer for arch_setup field.
14498 * linux-m68k-low.c (init_registers_m68k): Add prototype.
14499 (the_low_target): Add initializer for arch_setup field.
14500 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
14501 (init_registers_mips64_linux): Likewise.
14502 (the_low_target): Add initializer for arch_setup field.
14503 * linux-ppc-low.c (init_registers_ppc): Add prototype.
14504 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
14505 (the_low_target): Add initializer for arch_setup field.
14506 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
14507 (init_registers_powerpc_64): Likewise.
14508 (the_low_target): Add initializer for arch_setup field.
14509 * linux-s390-low.c (init_registers_s390): Add prototype.
14510 (init_registers_s390x): Likewise.
14511 (the_low_target): Add initializer for arch_setup field.
14512 * linux-sh-low.c (init_registers_sh): Add prototype.
14513 (the_low_target): Add initializer for arch_setup field.
14514 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
14515 (the_low_target): Add initializer for arch_setup field.
14516 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
14517 (the_low_target): Add initializer for arch_setup field.
14518
14519 * win32-low.h (struct win32_target_ops): Add arch_setup field.
14520 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
14521 instead of init_registers ().
14522 * win32-arm-low.c (init_registers_arm): Add prototype.
14523 (the_low_target): Add initializer for arch_setup field.
14524 * win32-i386-low.c (init_registers_i386): Add prototype.
14525 (the_low_target): Add initializer for arch_setup field.
14526
14527 * spu-low.c (init_registers_spu): Add prototype.
14528 (initialize_low): Call initialie_registers_spu () instead of
14529 initialize_registers ().
14530
fd96d250
PA
145312008-02-19 Pedro Alves <pedro@codesourcery.com>
14532
14533 * server.c (handle_v_requests): When handling the vRun and vAttach
14534 packets, if already debugging a process, don't kill it. Return an
14535 error instead.
14536
d41b6bb4
DJ
145372008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
14538
14539 * server.c (handle_query): Correct length check.
14540
5ac588cf
PA
145412008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
14542
14543 * win32-low.c (do_initial_child_stuff): Add process handle
14544 parameter. Set current_process_handle and current_process_id from the
14545 parameters. Clear globals.
14546 (win32_create_inferior): Don't set current_process_handle and
14547 current_process_id here. Instead pass them on the call to
14548 do_initial_child_stuff.
14549 (win32_attach): Likewise.
14550 (win32_clear_inferiors): New.
14551 (win32_kill): Don't close the current process handle or the
14552 current thread handle here. Instead call win32_clear_inferiors.
14553 (win32_detach): Don't open a new handle to the process. Call
14554 win32_clear_inferiors.
14555 (win32_join): Don't rely on current_process_handle; open a new
14556 handle using the process id.
14557 (win32_wait): Call win32_clear_inferiors when the inferior process
14558 has exited.
14559
ecd7ecbc
DJ
145602008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
14561
14562 * server.c (monitor_show_help): Add "exit".
14563
1525d545
MG
145642008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
14565
ecd7ecbc 14566 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
14567 (clean): Add reg-xtensa.c.
14568 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
14569 * configure.srv (xtensa*-*-linux*) New target.
14570 * linux-xtensa-low.c: New.
14571 * xtensa-xtregs.c: New.
1525d545 14572
59a016f0
PA
145732008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
14574
14575 * hostio.c: Don't include errno.h.
14576 (errno_to_fileio_errno): Move to hostio-errno.
14577 * hostio.c: (hostio_error): Remove the error parameter. Defer the
14578 error number outputting to the target->hostio_last_error callback.
14579 (hostio_packet_error): Use FILEIO_EINVAL directly.
14580 (handle_open, handle_pread, hostio_error, handle_unlink): Update
14581 calls to hostio_error.
14582 * hostio-errno.c: New.
14583 * server.h (hostio_last_error_from_errno): Declare.
14584 * target.h (target_ops): Add hostio_last_error member.
14585 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
14586 as hostio_last_error handler.
889bf7c5 14587 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
14588 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
14589 (wince_hostio_last_error): New functions.
14590 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
14591 as hostio_last_error handler.
14592 (win32_target_ops) [!_WIN32_WCE]: Register
14593 hostio_last_error_from_errno as hostio_last_error handler.
14594 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
14595 (hostio-errno.o): New rule.
14596 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
14597 * configure.srv (srv_hostio_err_objs): New variable. Default to
14598 hostio-errno.o.
14599 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
14600 * configure: Regenerate.
14601
2d717e4f
DJ
146022008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
14603
14604 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
14605 (linux_kill, linux_detach): Clean up the process list.
14606 * remote-utils.c (remote_open): Improve port number parsing.
14607 (putpkt_binary, input_interrupt): Only send interrupts if the target
14608 is running.
14609 * server.c (extended_protocol): Make static.
14610 (attached): Define earlier.
14611 (exit_requested, response_needed, program_argv): New variables.
14612 (target_running): New.
14613 (start_inferior): Clear attached here.
14614 (attach_inferior): Set attached here.
14615 (require_running): Define.
14616 (handle_query): Use require_running and target_running. Implement
14617 "monitor exit".
14618 (handle_v_attach, handle_v_run): New.
14619 (handle_v_requests): Use require_running. Handle vAttach and vRun.
14620 (gdbserver_usage): Update.
14621 (main): Redo argument parsing. Handle --debug and --multi. Handle
14622 --attach along with other options or after the port. Save
14623 program_argv. Support no initial program. Resynchronize
14624 communication with GDB after an error. Handle "monitor exit".
14625 Use require_running and target_running. Always allow the extended
14626 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
14627 restart in extended mode.
14628 * README: Refer to the GDB manual. Update --attach usage.
14629
7407e2de
AS
146302007-12-20 Andreas Schwab <schwab@suse.de>
14631
14632 * linux-low.c (STACK_SIZE): Define.
14633 (linux_tracefork_child): Use it. Use __clone2 on ia64.
14634 (linux_test_for_tracefork): Likewise.
14635
b65d95c5
DJ
146362007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
14637
14638 * linux-low.c (linux_wait_for_event): Update messages. Do not
14639 reinsert auto-delete breakpoints.
14640 * mem-break.c (struct breakpoint): Change return type of handler to
14641 int.
14642 (set_breakpoint_at): Update handler type.
14643 (reinsert_breakpoint_handler): Return 1 instead of calling
14644 delete_breakpoint.
14645 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
14646 setting a new one.
14647 (check_breakpoints): Delete auto-delete breakpoints and return 2.
14648 * mem-break.h (set_breakpoint_at): Update handler type.
14649 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
14650 * win32-low.c (auto_delete_breakpoint): New.
14651 (get_child_debug_event): Use it.
14652
4e799345
DJ
146532007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
14654
14655 * configure.ac: Check for pread and pwrite.
14656 * hostio.c (handle_pread): Fall back to lseek and read.
14657 (handle_pwrite): Fall back to lseek and write.
14658 * config.in, configure: Regenerated.
14659
27524b67
DJ
146602007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
14661
14662 * server.c (myresume): Add own_buf argument.
14663 (main): Update calls.
14664
a20d5e98
DJ
146652007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
14666
14667 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
14668 * remote-utils.c (remote_open): Do not call disable_async_io.
14669 (block_async_io): Delete.
14670 (unblock_async_io): Make static.
14671 (initialize_async_io): New.
14672 * server.c (handle_v_cont): Handle async I/O here.
14673 (myresume): Likewise. Move other common resume tasks here...
14674 (main): ... from here. Call initialize_async_io. Disable async
14675 I/O before the main loop.
14676 * server.h (initialize_async_io): Declare.
14677 (block_async_io, unblock_async_io): Delete prototypes.
14678 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
14679
b79d787e
DJ
146802007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
14681
14682 * remote-utils.c (readchar): Allow binary data in received messages.
14683
d97903b2
PA
146842007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14685
14686 * win32-low.c (attaching): New global.
14687 (win32_create_inferior): Clear the `attaching' global.
14688 (win32_attach): Set the `attaching' global.
14689 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
14690 attaching. Only set a breakpoint at the entry point if not
14691 attaching.
14692
311de423
PA
146932007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14694
14695 * server.c (main): Don't report dll events on the initial
14696 connection on attaches.
14697
6c2d16d2
PA
146982007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14699
14700 * server.c (main): Relax numerical bases supported for the pid of
14701 the --attach command line argument.
14702
5ca906e6
PA
147032007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14704
14705 * win32-low.c (win32_attach): Call OpenProcess before
14706 DebugActiveProcess, not after. Add last error output to error
14707 call.
14708
9c6c8194
PA
147092007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14710
14711 * win32-low.c (win32_get_thread_context)
14712 (win32_set_thread_context): New functions.
14713 (thread_rec): Use win32_get_thread_context.
14714 (continue_one_thread, win32_resume): Use win32_set_thread_context.
14715 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
14716 field.
14717
4d5d1aaa
PA
147182007-12-03 Leo Zayas
14719 Pedro Alves <pedro_alves@portugalmail.pt>
14720
14721 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
14722 global variables.
14723 (child_add_thread): Minor cleanup.
14724 (child_continue): Resume artificially suspended threads before
14725 calling ContinueDebugEvent.
14726 (suspend_one_thread): New.
14727 (fake_breakpoint_event): New.
14728 (get_child_debug_event): Change return type to int. Check here if
14729 gdb sent an interrupt request. If a soft interrupt was requested,
14730 fake a breakpoint event. Return 0 if there is no event to handle,
14731 and 1 otherwise.
14732 (win32_wait): Don't check here if gdb sent an interrupt request.
14733 Ensure there is a valid event to handle.
14734 (win32_request_interrupt): Add soft interruption method as last
14735 resort.
14736
c436e841
PA
147372007-12-03 Leo Zayas
14738 Pedro Alves <pedro_alves@portugalmail.pt>
14739
14740 * win32-low.h (win32_thread_info): Add descriptions to the
14741 structure members. Replace `suspend_count' counter by a
14742 `suspended' flag.
14743 * win32-low.c (thread_rec): Update condition of when to get the
14744 context from the inferior. Rely on ContextFlags being set if it
14745 has already been retrieved. Only suspend the inferior thread if
14746 we haven't already. Warn if that fails.
14747 (continue_one_thread): s/suspend_count/suspended/. Only call
14748 ResumeThread once. Warn if that fails.
14749
e7b5fa67
PA
147502007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
14751
14752 * win32-low.c (win32_wait): Don't read from the inferior when it
14753 has already exited.
14754
a385171d
PA
147552007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
14756
14757 * Makefile.in (win32_low_h): New variable.
14758 (win32-low.o): Add dependency on $(win32_low_h).
14759 (win32-arm-low.o, win32-i386-low.o): New rules.
14760
f80c84b3
DJ
147612007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
14762
14763 * hostio.c: Correct copyright year.
14764
a6b151f1
DJ
147652007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
14766
14767 * Makefile.in (OBS): Add hostio.o.
14768 (hostio.o): New rule.
14769 * server.h (handle_vFile): Declare.
14770 * hostio.c: New file.
14771 * server.c (handle_v_requests): Take packet_len and new_packet_len
14772 for binary packets. Call handle_vFile.
14773 (main): Update call to handle_v_requests.
14774
f9387fc3
DJ
147752007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
14776
14777 * linux-low.c: Include <sched.h>.
14778
51c2684e
DJ
147792007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
14780
14781 * linux-low.c (linux_tracefork_grandchild): New.
14782 (linux_tracefork_child): Use clone.
14783 (linux_test_for_tracefork): Use clone; allocate and free a stack.
14784
75f83163
JB
147852007-10-31 Joel Brobecker <brobecker@adacore.com>
14786
14787 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
14788
da5898ce
DJ
147892007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
14790
14791 * linux-low.c (handle_extended_wait): Handle unexpected signals.
14792
24a09b5f
DJ
147932007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
14794
14795 * inferiors.c (change_inferior_id): Delete.
14796 (add_pid_to_list, pull_pid_from_list): New.
14797 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
14798 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
14799 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
14800 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
14801 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
14802 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
14803 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
14804 (using_threads): Always set to 1.
14805 (handle_extended_wait): New.
14806 (add_process): Do not set TID.
14807 (linux_create_inferior): Set must_set_ptrace_flags.
14808 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
14809 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
14810 (linux_thread_alive): Rename TID argument to LWPID.
14811 (linux_wait_for_process): Handle unknown processes. Do not use TID.
14812 (linux_wait_for_event): Do not use TID or check using_threads. Update
14813 call to dead_thread_notify. Call handle_extended_wait.
14814 (linux_create_inferior): Use PTRACE_SETOPTIONS.
14815 (send_sigstop): Delete sigstop_sent.
14816 (wait_for_sigstop): Avoid TID.
14817 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
14818 (linux_test_for_tracefork): New.
14819 (linux_lookup_signals): Use thread_db_active and
14820 linux_supports_tracefork_flag.
14821 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
14822 * linux-low.h (get_process_thread): Avoid TID.
14823 (struct process_ifo): Move thread_known and tid to the end. Remove
14824 sigstop_sent.
14825 (linux_attach_lwp, thread_db_init): Update prototypes.
14826 * server.h (change_inferior_id): Delete prototype.
14827 (add_pid_to_list, pull_pid_from_list): New prototypes.
14828 * thread-db.c (thread_db_use_events): New.
14829 (find_first_thread): Rename to...
14830 (find_one_thread): ...this. Update callers and messages. Do not
14831 call fatal. Check thread_db_use_events. Do not call
14832 change_inferior_id or new_thread_notify.
14833 (maybe_attach_thread): Update. Do not call new_thread_notify.
14834 (thread_db_init): Set thread_db_use_events. Check use_events.
14835 * utils.c (fatal, warning): Correct message prefix.
14836
30ed0a8f
DJ
148372007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
14838
14839 * Makefile.in (clean): Remove new files.
14840 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
14841 (powerpc-64.o, powerpc-64.c): New rules.
14842 * configure.srv: Use alternate register sets for powerpc64-*-linux*
14843 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
14844 with SPE.
14845 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
14846 SPE targets.
14847 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
14848 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
14849 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
14850 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
14851 (target_regsets): Add AltiVec and SPE register sets.
14852 * configure.ac: Check for AltiVec and SPE.
14853 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
14854 (ppc_fill_vrregset, ppc_store_vrregset): New.
14855 (target_regsets): Add AltiVec register set.
14856 * configure: Regenerated.
14857
fd462a61
DJ
148582007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
14859
14860 * linux-low.c (O_LARGEFILE): Define.
14861 (linux_read_memory): Use /proc/PID/mem.
14862 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
14863 * configure, config.in: Regenerated.
14864
69f223ed
DJ
148652007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
14866
14867 * linux-low.c (linux_wait_for_event): Do not pass signals while
14868 single-stepping.
14869
aec18585
PA
148702007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
14871
14872 * win32-low.c (create_process): New.
14873 (win32_create_inferior): Use create_process instead of
14874 CreateProcess. If create_process failed retry appending an ".exe"
14875 suffix. Store the GetLastError result immediatelly after
14876 create_process calls and use it on the call to error.
14877
34d86ddd
PA
148782007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
14879
14880 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
14881
5a0e3bd0
JB
148822007-08-23 Joel Brobecker <brobecker@adacore.com>
14883
14884 * configure.ac: Switch license to GPLv3.
14885
f88c79e6
MS
148862007-08-01 Michael Snyder <msnyder@access-company.com>
14887
14888 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
14889
6b3d9b83
PA
148902007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
14891
14892 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
14893 typedef.
14894 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
14895 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
14896 CloseToolhelp32Snapshot.
14897 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
14898 CloseToolhelp32Snapshot.
14899
c588c53c
MS
149002007-07-27 Michael Snyder <michael.snyder@access-company.com>
14901
14902 * server.c (main): Check for inferior exit before main loop.
14903
aa0403d9
PA
149042007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
14905
14906 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
14907 instead of on tmp_desc.
14908
255e7678
DJ
149092007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
14910 Daniel Jacobowitz <dan@codesourcery.com>
14911
14912 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
14913 (add_thread): Minor cleanups.
14914 (clear_inferiors): Move lower in the file. Clear the DLL
14915 list.
14916 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
14917 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
14918 (xml_escape_text): New.
14919 * server.c (handle_query): Handle qXfer:libraries:read. Report it
14920 for qSupported.
14921 (handle_v_cont): Report errors.
14922 (gdbserver_version): Update.
14923 (main): Correct size of own_buf. Do not report initial DLL events.
14924 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
14925 (unloaded_dll, xml_escape_text): New.
14926 * win32-low.c (enum target_waitkind): Update comments.
14927 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
14928 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
14929 (win32_EnumProcessModules, win32_GetModuleInformation)
14930 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
14931 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
14932 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
14933 (win32_Module32First, win32_Module32Next, load_toolhelp)
14934 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
14935 (get_child_debug_event): Handle DLL events.
14936 (win32_wait): Likewise.
14937
0d37add9
DJ
149382007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
14939
14940 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
14941 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
14942
45e2715e
PA
149432007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
14944
14945 * win32-low.c (handle_output_debug_string): Ignore event if not
14946 waiting.
14947
c5674cf1
PA
149482007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
14949
14950 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
14951
2bbe3cc1
DJ
149522007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
14953
14954 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
14955
ae13219e
DJ
149562007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
14957
14958 * inferiors.c (change_inferior_id): Add comment.
14959 * linux-low.c (check_removed_breakpoint): Add an early
14960 prototype. Improve debug output.
14961 (linux_attach): Doc update.
14962 (linux_detach_one_process, linux_detach): Clean up before releasing
14963 each process.
14964 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
14965 * linux-low.h (struct process_info): Doc improvement.
14966 * mem-break.c (delete_all_breakpoints): New.
14967 * mem-break.h (delete_all_breakpoints): New prototype.
14968 * thread-db.c (find_first_thread): New.
14969 (thread_db_create_event): Call it instead of
14970 thread_db_find_new_threads. Clean up unused variables.
14971 (maybe_attach_thread): Remove first thread handling.
14972 (thread_db_find_new_threads): Use find_first_thread.
14973 (thread_db_get_tls_address): Likewise.
14974
4105de34
DJ
149752007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
14976
14977 * thread-db.c (thread_db_find_new_threads): Add prototype.
14978 (thread_db_create_event): Check for the main thread before adding
14979 a new thread.
14980 (maybe_attach_thread): Only enable event reporting if TID == 0.
14981 (thread_db_get_tls_address): Check for new threads.
14982
2b876972
DJ
149832007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
14984
14985 * linux-low.c (linux_create_inferior): Try execv before execvp.
14986 * spu-low.c (spu_create_inferior): Likewise.
14987
7a245884
DJ
149882007-06-13 Mike Frysinger <vapier@gentoo.org>
14989
14990 * linux-low.c (linux_create_inferior): Change execv to execvp.
14991 * spu-low.c (spu_create_inferior): Likewies.
14992
117ce543
DJ
149932007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
14994
14995 * Makefile.in (clean): Clean new files instead of deleted ones.
14996 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
14997 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
14998 rules.
14999 * configure.srv: Specify XML files and new regformats for MIPS and
15000 MIPS64 GNU/Linux.
15001 * linux-mips-low.c (mips_num_regs): Set to only used registers.
15002 (mips_regmap): Do not fetch $0. Remove unused registers. Add
15003 an entry for the restart register.
15004 (mips_cannot_fetch_register, mips_cannot_store_register)
15005 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
15006 register names to match the XML descriptions.
15007 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
15008 restart register instead of $0.
15009
0e7f50da
UW
150102007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15011 Markus Deuling <deuling@de.ibm.com>
15012
15013 * remote-utils.c (decode_xfer_write): New function.
15014 * server.h (decode_xfer_write): Add prototype.
15015 * server.c (handle_query): Add PACKET_LEN argument. Support
15016 qXfer:spu:read and qXfer:spu:write packets.
15017 (main): Pass packet_len to handle_query.
15018 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
15019 * target.h (target_ops): Add qxfer_spu.
15020
374c1d38
UW
150212007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15022
15023 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
15024 accessing non-seekable spufs files.
15025
bb63802a
UW
150262007-05-16 Markus Deuling <deuling@de.ibm.com>
15027
889bf7c5 15028 * server.c (handle_query): Add reply for qC packet.
bb63802a 15029
7390519e
PA
150302007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15031 Leo Zayas <lerele@champenstudios@com>
15032
15033 * server.h (check_remote_input_interrupt_request): New function.
15034 * remote_utils.c (INVALID_DESCRIPTOR): New define.
15035 (remote_desc): Initialize with INVALID_DESCRIPTOR.
15036 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
15037 (check_remote_input_interrupt_request): New function.
15038 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 15039 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
15040 winapi_GenerateConsoleCtrlEvent): New typedefs.
15041 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
15042 to 250 ms.
15043 (win32_wait): Check for remote interrupt request
15044 with check_remote_input_interrupt_request.
15045 (win32_request_interrupt): New function.
15046 (win32_target_op): Set request_interrupt to win32_request_interrupt.
15047
34b34921
PA
150482007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15049
15050 * win32-low.c (debug_registers_changed,
15051 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
15052 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
15053 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
15054 (thread_rec): Get context using the low target.
15055 (child_add_thread): Call thread_added on the low target,
15056 which does the same thing.
15057 (regptr): Delete.
15058 (do_initial_child_stuff): Remove debug registers references.
15059 Set context using the low target. Resume threads after
15060 setting the contexts.
15061 (child_continue): Remove dead variable. Remove debug
15062 registers references.
15063 (child_fetch_inferior_registers): Go through the low target.
15064 (do_child_store_inferior_registers): Remove.
15065 (child_store_inferior_registers): Go through the low target.
15066 (win32_resume): Remove debug registers references.
15067 Set context using the low target.
15068 (handle_exception): Change return type to void. Don't record
15069 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
15070 first chance exception.
889bf7c5 15071 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
15072 goto loop. Always return after waiting for debug event.
15073 (win32_wait): Convert to switch statement. Handle spurious
15074 events.
15075
15076 * win32-i386-low.c (debug_registers_changed,
15077 debug_registers_used): New.
15078 (initial_stuff): Rename to ...
15079 (i386_initial_stuff): ... this. Clear debug registers
15080 state variables.
15081 (store_debug_registers): Delete.
15082 (i386_get_thread_context): New.
15083 (load_debug_registers): Delete.
15084 (i386_set_thread_context): New.
15085 (i386_thread_added): New.
15086 (single_step): Rename to ...
15087 (i386_single_step): ... this.
15088 (do_fetch_inferior_registers): Rename to ...
15089 (i386_fetch_inferior_register): ... this.
15090 (i386_store_inferior_register): New.
15091 (the_low_target): Adapt to new interface.
15092
15093 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
15094 (arm_get_thread_context): New.
15095 (arm_set_thread_context): New.
15096 (regptr): New.
15097 (do_fetch_inferior_registers): Rename to ...
15098 (arm_fetch_inferior_register): ... this.
15099 (arm_store_inferior_register): New.
15100 (arm_wince_breakpoint): Reimplement as unsigned long.
15101 (arm_wince_breakpoint_len): Define.
15102 (the_low_target): Adapt to new interface.
15103
15104 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
15105 load_debug_registers. Add get_thread_context, set_thread_context,
15106 thread_added and store_inferior_register. Rename
15107 fetch_inferior_registers to fetch_inferior_register.
15108 (regptr): Remove declaration.
15109
dd6953e1
PA
151102007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15111
15112 * linux-low.c (linux_detach): Change return type to int. Return 0.
15113 * spu-low.c (spu_detach): Likewise.
15114
444d6139
PA
151152007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15116
15117 * target.h (target_ops): Change return type of detach to int.
15118 Add join.
15119 (join_inferior): New.
15120 * server.c (main): Don't skip detach support on mingw32.
15121 If the inferior doesn't support detaching return error.
15122 Call join_inferior instead of using waitpid.
15123 * linux-low.c (linux_join): New.
15124 (linux_target_op): Add linux_join.
15125 * spu-low.c (spu_join): New.
15126 (spu_target_ops): Add spu_join.
15127 * win32-low.c (win32_detach): Adapt to new interface.
15128 Reopen current_process_handle before detaching. Issue a child
15129 resume before detaching.
15130 (win32_join): New.
15131 (win32_target_op): Add win32_join.
15132
1d5315fe
PA
151332007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15134
15135 * win32-low.c (win32-attach): Fix return value.
15136 * target.h (target_ops): Describe ATTACH return values.
15137
bf914831
PA
151382007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15139
15140 * win32-low.c (GETPROCADDRESS): Define.
15141 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
15142 (winapi_DebugSetProcessKillOnExit): Likewise.
15143 (win32_create_inferior): Force usage of ansi CreateProcessA.
15144 (win32_attach): Use GETPROCADDRESS.
15145 (win32_detach): Likewise.
15146
f72f3e60
PA
151472007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15148
15149 * win32-low.c (win32_wait): Don't use WSTOPSIG.
15150
ed50f18f
PA
151512007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
15152
15153 * win32-low.c: Commit leftover changes from 2007-03-29.
15154
0c2ead7e
DJ
151552007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15156
15157 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
15158 fields short instead of int. Add explicit padding.
15159 (i387_cache_to_fsave): Remove unnecessary casts.
15160 (i387_fsave_to_cache): Doc fix.
15161 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
15162
73725ff3
DJ
151632007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15164
15165 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
15166 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
15167
d99f33d8
PA
151682007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15169
15170 * configure.srv (arm*-*-mingw32ce*): Move near the other
15171 arm targets.
15172
68070c10
PA
151732007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15174
2482afc6 15175 * configure.ac: Add errno checking.
68070c10
PA
15176 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
15177 sys/file.h and malloc.h.
15178 (AC_CHECK_DECLS): Add perror.
15179 (srv_mingwce): Handle.
2482afc6 15180 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
15181 win32-i386-low.o to srv_tgtobj.
15182 (i[34567]86-*-mingw*): Likewise.
15183 (arm*-*-mingw32ce*): Add case.
15184 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15185 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
15186 [__MINGW32CE__] (strerror): New function.
15187 [__MINGW32CE__] (errno): Define to GetLastError.
15188 [__MINGW32CE__] (COUNTOF): New macro.
15189 (remote_open): Remove extra close call.
15190 * mem-break.c (delete_breakpoint_at): New function.
15191 * mem-break.h (delete_breakpoint_at): Declare.
15192 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15193 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
15194 [USE_WIN32API] (read, write): Add char* casts.
15195 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
15196 * server.h: Include wincecompat.h on Windows CE.
15197 [HAVE_ERRNO_H]: Check.
15198 (perror): Declare if not declared.
15199 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
15200 (perror_with_name): Remove errno declaration.
15201 * wincecompat.h: New.
15202 * wincecompat.c: New.
15203 * win32-low.h: New.
15204 * win32-arm-low.c: New.
15205 * win32-i386-low.c: New.
15206 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
15207 (OUTMSG2): Make it safe.
15208 (_T): New macro.
15209 (COUNTOF): New macro.
15210 (NUM_REGS): Get it from the low target.
15211 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
15212 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
15213 (thread_rec): Let low target handle debug registers.
15214 (child_add_thread): Likewise.
15215 (child_init_thread_list): Likewise.
15216 (continue_one_thread): Likewise.
15217 (regptr): New.
15218 (do_child_fetch_inferior_registers): Move to ...
15219 * win32-i386-low.c: ... here, and rename to ...
15220 (do_fetch_inferior_registers): ... this.
889bf7c5 15221 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
15222 Go through the low target.
15223 (do_child_store_inferior_registers): Use regptr.
15224 (strwinerror): New function.
15225 (win32_create_inferior): Handle Windows CE.
15226 Use strwinerror instead of strerror on Windows error
15227 codes. Add program to the error output.
15228 Don't close the main thread handle on Windows CE.
15229 (win32_attach): Use coredll.dll on Windows CE.
15230 (win32_kill): Close current process and current
15231 thread handles.
15232 (win32_detach): Use coredll.dll on Windows CE.
15233 (win32_resume): Let low target handle debug registers, and
15234 step request.
15235 (handle_exception): Add/Remove initial breakpoint. Avoid
15236 non-existant WSTOPSIG on Windows CE.
15237 (win32_read_inferior_memory): Cast to remove warning.
15238 (win32_arch_string): Go through the low target.
15239 (initialize_low): Call set_breakpoint_data with the low
15240 target's breakpoint.
15241 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
15242 FOP_REGNUM, mappings): Move to ...
15243 * win32-i386-low.c: ... here.
15244 * win32-low.c (win32_thread_info): Move to ...
15245 * win32-low.h: ... here.
15246 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
15247 win32-arm-low.c and wincecompat.c.
15248 (all:): Add $EXEEXT.
15249 (install-only:): Likewise.
15250 (gdbserver:): Likewise.
15251 (gdbreplay:): Likewise.
15252 * config.in: Regenerate.
15253 * configure: Regenerate.
15254
41093d81
PA
152552007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15256
15257 * win32-low.c: Rename typedef thread_info to
15258 win32_thread_info throughout.
15259
544afa54
PA
152602007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15261
15262 * win32-i386-low.c: Rename to ...
15263 * win32-low.c: ... this.
15264 * configure.srv: Replace win32-i386-low.o with win32-low.o.
15265 * Makefile.in: Likewise.
15266
bce7165d
PA
152672007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
15268
15269 * remote-utils.c (monitor_output): Constify msg parameter.
15270 * server.h (monitor_output): Likewise.
15271 * win32-i386-low.c (handle_output_debug_string): New.
15272 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
15273 handle_output_debug_string.
15274 (get_child_debug_event): Likewise.
15275
506c7aa0
DJ
152762007-03-27 Mat Hostetter <mat@lcs.mit.edu>
15277
15278 * server.c (main): Correct strtoul check.
15279
42c81e2a
DJ
152802007-03-27 Jon Ringle <jon@ringle.org>
15281
15282 * linux-low.c: Check __ARCH_HAS_MMU__ also.
15283
9453113a
DJ
152842007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
15285
15286 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
15287
64a69107
DJ
152882007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
15289
15290 * terminal.h: Check HAVE_SGTTY_H.
15291
152922007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
15293
15294 * remote-utils.c (remote_open): Print out the assigned port number.
15295
c74d0ad8
DJ
152962007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
15297
15298 * remote-utils.c (monitor_output): New function.
15299 * server.c (debug_threads): Define here.
15300 (monitor_show_help): New function.
15301 (handle_query): Handle qRcmd.
15302 (main): Do not handle 'd' packet.
15303 * server.h (debug_threads, remote_debug, monitor_output): Declare.
15304 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
15305 of debug_threads.
15306
de7c3b4a
PA
153072007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
15308
15309 * Makefile.in (EXEEXT): New.
15310 (clean): Use $(EXEEXT).
15311
ef57601b
PA
153122007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
15313
15314 * target.h (target_ops): Rename send_signal to request_interrupt,
15315 and remove enum target_signal parameter.
15316 * linux-low.c (linux_request_interrupt): Rename from
15317 linux_send_signal, and always send SIGINT.
15318 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
15319 and always send SIGINT.
15320 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
15321 of send_signal.
15322 (input_interrupt): Likewise.
15323
820f2bda
PA
153242007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
15325
15326 * server.c (get_features_xml): Check if target implemented
15327 arch_string.
15328 * win32-i386-low.c (win32_arch_string): New.
15329 (win32_target_ops): Add win32_arch_string as arch_string member.
15330
ab39bf24
UW
153312007-02-22 Markus Deuling <deuling@de.ibm.com>
15332
15333 * spu-low.c (spu_arch_string): New.
15334 (spu_target_ops): Add spu_arch_string.
15335
61ff6e04
DJ
153362007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
15337
15338 * remote-utils.c: Remove HAVE_TERMINAL_H check.
15339 * configure.ac: Do not check for terminal.h.
15340 * configure, config.in: Regenerated.
15341
fb1e4ffc
DJ
153422007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
15343
15344 * Makefile.in (OBS): Add $(XML_BUILTIN).
15345 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
15346 (clean): Update.
15347 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
15348 (arm-with-iwmmxt.c): New.
15349 * config.in, configure: Regenerate.
15350 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
15351 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
15352 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
15353 (arm*-*-linux*): Add iWMMXt and regset support.
15354 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
15355 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
15356 (arm_store_wmmxregset, target_regsets): New.
15357 * server.c (get_features_xml): Take annex argument. Check builtin
15358 XML documents.
15359 (handle_query): Handle multiple annexes.
15360
0f48aa01
DJ
153612007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15362
15363 * remote-utils.c [USE_WIN32API] (read, write): Define.
15364 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
15365 write.
15366
23181151
DJ
153672007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
15368
15369 * linux-i386-low.c (the_low_target): Set arch_string.
15370 * linux-x86-64-low.c (the_low_target): Likewise.
15371 * linux-low.c (linux_arch_string): New.
15372 (linux_target_ops): Add it.
15373 * linux-low.h (struct linux_target_ops): Add arch_string.
15374 * server.c (write_qxfer_response): Use const void * for DATA.
15375 (get_features_xml): New.
15376 (handle_query): Handle qXfer:features:read. Report it for qSupported.
15377 * target.h (struct target_ops): Add arch_string method.
15378
9d606399
DJ
153792007-01-03 Denis Pilat <denis.pilat@st.com>
15380 Daniel Jacobowitz <dan@codesourcery.com>
15381
15382 * linux-low.c (linux_kill): Handle being called with no threads.
15383 * win32-i386-low.c (win32_kill): Likewise.
15384 (get_child_debug_event): Clear current_process_handle.
15385
153862006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
15387 Daniel Jacobowitz <dan@codesourcery.com>
15388
15389 * remote-utils.c (remote_open): Check the type of specified
15390 serial port devices before opening them.
15391 * server.c (main): Kill the inferior if an error occurs during
15392 the first remote_open.
15393
a5e13d24
DJ
153942006-12-05 Markus Deuling <deuling@de.ibm.com>
15395
15396 * README: Update supported targets.
15397
186947f7
DJ
153982006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
15399
15400 * Makefile.in (clean): Remove reg-mips64.c.
15401 (reg-mips64.c, reg-mips64.o): New rules.
15402 * configure.srv: Handle mips64. Include regset support for mips.
15403 * linux-mips-low.c (union mips_register): New.
15404 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
15405 (mips_breakpoint, mips_breakpoint_at): Use int.
15406 (mips_collect_register, mips_supply_register)
15407 (mips_collect_register_32bit, mips_supply_register_32bit)
15408 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
15409 (mips_store_fpregset, target_regsets): New.
15410 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
15411
a13e2c95
UW
154122006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
15413
15414 * configure.srv: Add target "spu*-*-*".
15415 * Makefile.in (clean): Remove reg-spu.c.
15416 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
15417 * spu-low.c: New file.
15418
cb7283db
DJ
154192006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
15420
15421 * configure.ac: Correct td_thr_tls_get_addr test.
15422 * configure: Regenerated.
15423
89be2091
DJ
154242006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
15425
15426 * linux-low.c (linux_wait_for_event): Reformat. Use the
15427 pass_signals array.
15428 * remote-utils.c (decode_address_to_semicolon): New.
15429 * server.c (pass_signals, handle_general_set): New.
15430 (handle_query): Mention QPassSignals for qSupported.
15431 (main): Call handle_general_set.
15432 * server.h (pass_signals, decode_address_to_semicolon): New.
15433
000ef4f0
DJ
154342006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
15435
15436 * server.c (handle_query): Correct error handling for read_auxv.
15437
b7149293
UW
154382005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
15439
15440 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
15441 and srv_linux_thread_db to yes.
15442 * linux-s390-low.c (s390_fill_gregset): New function.
15443 (target_regsets): Define data structure.
15444
dae5f5cf
DJ
154452006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
15446
15447 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
15448 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
15449 * config.in, configure: Regenerated.
15450 * inferiors.c (gdb_id_to_thread): New function.
15451 (gdb_id_to_thread_id): Use it.
15452 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
15453 * linux-low.h (struct process_info): Add th member.
15454 (thread_db_get_tls_address): New prototype.
15455 * remote-utils.c (decode_address): Make non-static.
15456 * server.c (handle_query): Handle qGetTLSAddr.
15457 * server.h (gdb_id_to_thread, decode_address): New prototypes.
15458 * target.h (struct target_ops): Add get_tls_address.
15459 * thread-db.c (maybe_attach_thread): Save the thread handle.
15460 (thread_db_get_tls_address): New.
15461
32ca6d61
DJ
154622006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
15463
15464 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
15465 (linux_resume_one_process): Take a siginfo_t *. Update all
15466 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
15467 (struct pending_signals): Add a siginfo_t.
15468 (linux_wait_for_process): Always set last_status.
15469 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
15470 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
15471 * linux-low.h (struct process_info): Add last_status.
15472
5ffff7c1
DJ
154732006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
15474
15475 * remote-utils.c (try_rle): New function.
15476 (putpkt_binary): Use it.
15477
8695c747
DJ
154782006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
15479
15480 * Makefile.in (clean): Clean reg-x86-64-linux.c.
15481 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
15482 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
15483 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
15484 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
15485 point registers.
15486
290fadea
RS
154872006-08-08 Richard Sandiford <richard@codesourcery.com>
15488
15489 * server.c (terminal_fd): New variable.
15490 (old_foreground_pgrp): Likewise.
15491 (restore_old_foreground_pgrp): New function.
15492 (start_inferior): Record the terminal file descriptor in terminal_fd
15493 and its original foreground group in old_foreground_pgrp. Register
15494 restore_old_foreground_pgrp with atexit().
15495
9f2e1e63
DJ
154962006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
15497
15498 * server.c (handle_query): Correct qPart to qXfer.
15499
b80864fb
DJ
155002006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
15501
15502 * configure.ac: Check for more headers which are missing on
15503 Windows. Automatically supply -lwsock32 and USE_WIN32API.
15504 * configure.srv: Add Cygwin and mingw32.
15505 * remote-utils.c: Don't include headers unconditionally which
15506 are missing on mingw32. Include <winsock.h> for mingw32.
15507 (remote_open): Adjust for mingw32 support. Flush
15508 standard error after writing to it.
15509 (remote_close, putpkt_binary, input_interrupt, block_async_io)
15510 (unblock_async_io, enable_async_io, disable_async_io)
15511 (readchar, getpkt): Update for Winsock support.
15512 (prepare_resume_reply): Expect a protocol signal number.
15513 * server.c: Disable <sys/wait.h> on mingw32.
15514 (start_inferior): Adjust for mingw32 support. Flush
15515 standard error after writing to it.
15516 (attach_inferior): Likewise. Use protocol signal
15517 numbers.
15518 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
15519 and names.
15520 * win32-i386-low.c: New file.
15521 * Makefile.in (XM_CLIBS): Set.
15522 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
15523 (win32-i386-low.o): New dependency rule.
15524 * linux-low.c (linux_wait): Use target signal numbers.
15525 * target.h (struct target_ops): Doc fix.
15526 * server.h (target_signal_to_name): New prototype.
15527 * gdbreplay.c: Don't include headers unconditionally which
15528 are missing on mingw32. Include <winsock.h> for mingw32.
15529 (remote_close, remote_open): Adjust for Winsock support.
15530 * configure, config.in: Regenerated.
15531
0876f84a
DJ
155322006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15533
15534 * server.c (decode_xfer_read, write_qxfer_response): New.
15535 (handle_query): Take a packet length argument. Handle
15536 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
15537 the qSupported response.
15538 (main): Update call to handle_query.
15539
01f9e8fa
DJ
155402006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
15541
15542 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
15543 (putpkt_binary): Renamed from putpkt and adjusted for binary
15544 data.
15545 (putpkt): New wrapper for putpkt_binary.
15546 (readchar): Don't mask off the high bit.
15547 (decode_X_packet): New function.
15548 * server.c (main): Call putpkt_binary if a handler sets the packet
15549 length. Save the length of the incoming packet. Handle 'X'.
15550 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
15551
be2a5f71
DJ
155522006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
15553
15554 * server.c (handle_query): Handle qSupported.
15555
ea025f5f
DJ
155562006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
15557
15558 * remote-utils.c (all_symbols_looked_up): New variable.
15559 (look_up_one_symbol): Check it.
15560 * server.h (look_up_one_symbol): New declaration.
15561 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
15562
9308fc88
DJ
155632006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
15564
15565 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 15566 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
15567 (PTRACE_GET_THREAD_AREA): Define.
15568 (ps_get_thread_area): New function.
15569
52fb6437
NS
155702006-05-09 Nathan Sidwell <nathan@codesourcery.com>
15571
15572 * configure.srv (m68k*-*-uclinux*): New target.
15573 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
15574 (linux_resume_one_process): Remove extraneous cast.
15575 (linux_read_offsets): New.
15576 (linux_target_op): Add linux_read_offsets on mmuless systems.
15577 * server.c (handle_query): Add qOffsets logic.
15578 * target.h (struct target_ops): Add read_offsets.
15579
21b0f40c
DJ
155802006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
15581
15582 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
15583 (PTRACE_GET_THREAD_AREA): Define.
15584 (ps_get_thread_area): New function.
15585 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
15586 (linux-x86-64-low.o): Update.
15587
0050a760
DJ
155882006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
15589
15590 * configure.ac: Remove checks for prfpregset_t.
15591 * gdb_proc_service.h: New file.
15592 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
15593 new "gdb_proc_service.h".
15594 * proc-service.c: Likewise.
15595 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
15596 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
15597 * Makefile.in (gdb_proc_service_h): Updated.
15598 * configure, config.in: Regenerated.
15599
b92a518e
DJ
156002006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
15601
15602 * remote-utils.c (prepare_resume_reply): Move declaration
15603 of gdb_id_from_wait to the top of the block.
15604
545587ee
DJ
156052006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
15606
15607 * linux-low.c (regsets_store_inferior_registers): Read the regset
15608 from the target before filling it.
15609
9db87ebd
DJ
156102006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
15611
15612 * server.c (attach_inferior): Return SIGTRAP for a successful
15613 attach.
15614
dd24457d
DJ
156152006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
15616
15617 * Makefile.in (OBS): Add version.o.
15618 (STAGESTUFF): Delete.
15619 (version.o): Add dependencies.
15620 (version.c): Replace rule.
15621 (clean): Remove version.c.
15622 * server.c (gdbserver_version): New.
15623 (gdbserver_usage): Use printf.
15624 (main): Handle --version and --help.
15625 * server.h (version, host_name): Add declarations.
15626
6f0f660e
EZ
156272005-12-23 Eli Zaretskii <eliz@gnu.org>
15628
889bf7c5
PA
15629 * linux-arm-low.c:
15630 * linux-arm-low.c:
15631 * inferiors.c:
15632 * i387-fp.h:
15633 * i387-fp.c:
15634 * gdbreplay.c:
15635 * regcache.c:
15636 * proc-service.c:
15637 * mem-break.h:
15638 * mem-break.c:
15639 * linux-x86-64-low.c:
15640 * linux-sh-low.c:
15641 * linux-s390-low.c:
15642 * linux-ppc64-low.c:
15643 * linux-ppc-low.c:
15644 * linux-mips-low.c:
15645 * linux-m68k-low.c:
15646 * linux-m32r-low.c:
15647 * linux-low.h:
15648 * linux-low.c:
15649 * linux-ia64-low.c:
15650 * linux-i386-low.c:
15651 * linux-crisv32-low.c:
15652 * thread-db.c:
15653 * terminal.h:
15654 * target.h:
15655 * target.c:
15656 * server.h:
15657 * server.c:
15658 * remote-utils.c:
15659 * regcache.h:
15660 * utils.c:
15661 * Makefile.in:
15662 * configure.ac:
6f0f660e
EZ
15663 * gdbserver.1: Add (C) after Copyright. Update the FSF
15664 address.
15665
9d1fb177
DJ
156662005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
15667
15668 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
15669 (arm_breakpoint_at): Recognize both breakpoints.
15670 (the_low_target): Use the correct breakpoint instruction.
15671
011a70c2
DJ
156722005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
15673
15674 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
15675 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
15676 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
15677 (the_low_target): Update.
15678
7fb85e41
AS
156792005-10-25 Andreas Schwab <schwab@suse.de>
15680
15681 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
15682
15683 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
15684 (ia64_num_regs): Reduce to 462.
15685
3db0444b
DJ
156862005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
15687
15688 * acinclude.m4: Correct quoting.
15689 * aclocal.m4: Regenerated.
15690
15691 Suggested by SZOKOVACS Robert <szo@ies.hu>:
15692 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
15693 (thread_db_init): Call thread_db_err_str.
15694 * configure.ac: Check for TD_VERSION.
15695 * config.in, configure: Regenerated.
15696
bee0189a
DJ
156972005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15698
15699 * server.h (error, fatal, warning): Add ATTR_FORMAT.
15700
e9d25b98
DJ
157012005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
15702
15703 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
15704 is not available. Define HAVE_PTRACE_GETREGS if it is.
15705 * config.in, configure: Regenerated.
15706 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
15707 * linux-i386-low.c, linux-m68k-low.c: Update to use
15708 HAVE_PTRACE_GETREGS.
15709 * linux-low.c (regsets_fetch_inferior_registers)
15710 (regsets_store_inferior_registers): Only return 0 if we processed
15711 GENERAL_REGS.
15712 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
15713 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
15714
a06660f7
DJ
157152005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
15716
15717 * inferiors.c (struct thread_info): Add gdb_id.
15718 (add_thread): Add gdb_id argument.
15719 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
15720 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
15721 calls to add_thread.
15722 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
15723 * server.c (handle_query): Use thread_to_gdb_id.
15724 (handle_v_cont, main): Use gdb_id_to_thread_id.
15725 * server.h (add_thread): Update prototype.
15726 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
15727 prototypes.
15728
5a1f5858
DJ
157292005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
15730
15731 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
15732 left-padded registers.
15733 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
15734 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
15735
e122f1f5
SE
157362005-07-01 Steve Ellcey <sje@cup.hp.com>
15737
15738 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
15739 * configure: Regenerate.
15740 * config.in: Regenerate.
15741 * server.h (NEED_DECLARATION_STRERROR):
15742 Replace with !HAVE_DECL_STRERROR.
15743
d592fa2f
DJ
157442005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
15745
15746 * linux-low.c (linux_wait, linux_send_signal): Don't test
15747 an unsigned long variable for > 0 if it could be MAX_ULONG.
15748 * server.c (myresume): Likewise.
15749 * target.c (set_desired_inferior): Likewise.
15750
ccbd4912
MK
157512005-06-13 Mark Kettenis <kettenis@gnu.org>
15752
15753 * configure.ac: Simplify and improve check for socklen_t.
15754 * configure, config.in: Regenerate.
15755
f450004a
DJ
157562005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
15757
15758 * acconfig.h: Remove.
15759 * configure.ac: Add a test for socklen_t. Use three-argument
15760 AC_DEFINE throughout.
15761 * config.in: Regenerated using autoheader 2.59.
15762 * configure: Regenerated.
15763
15764 * gdbreplay.c (socklen_t): Provide a default.
15765 (remote_open): Use socklen_t.
15766 * remote-utils.c (socklen_t): Provide a default.
15767 (remote_open): Use socklen_t.
15768 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
15769 unsigned char.
15770
15771 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
15772 char for buffers.
15773 * linux-low.c (linux_read_memory, linux_write_memory)
15774 (linux_read_auxv): Likewise.
15775 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
15776 (check_mem_write): Likewise.
15777 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
15778 Likewise.
15779 * regcache.c (struct inferior_rgcache_data, registers_to_string)
15780 (registers_from_string, register_data): Likewise.
15781 * server.c (handle_query, main): Likewise.
15782 * server.h (convert_ascii_to_int, convert_int_to_ascii)
15783 (decode_M_packet): Likewise.
15784 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
15785 * target.h (struct target_ops): Update read_memory, write_memory,
15786 and read_auxv.
15787 (read_inferior_memory, write_inferior_memory): Update.
15788 * linux-low.h (struct linux_target_ops): Change type of breakpoint
15789 to unsigned char *.
15790 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
15791 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
15792 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
15793 linux-s390-low.c, linux-sh-low.c: Update for changes in
15794 read_inferior_memory and the_low_target->breakpoint.
15795
eee84df1
DJ
157962005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
15797
15798 * Makefile.in (SFILES): Add linux-ppc64-low.c.
15799 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
15800 * configure.srv: Add powerpc64-*-linux*.
15801 * linux-ppc64-low.c: New file.
15802
45b134e5
OF
158032005-05-23 Orjan Friberg <orjanf@axis.com>
15804
15805 * linux-cris-low.c: New file with support for CRIS.
15806 * linux-crisv32-low.c: Ditto for CRISv32.
15807 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
15808 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 15809 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
15810 reg-crisv32.o, and reg-crisv32.c to make rules.
15811 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
15812 recognized targets.
15813
48d93c75
UW
158142005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
15815
15816 * linux-low.c (fetch_register): Ensure buffer size is a multiple
15817 of sizeof (PTRACE_XFER_TYPE).
15818 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
15819
e013ee27
OF
158202005-05-12 Orjan Friberg <orjanf@axis.com>
15821
889bf7c5 15822 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
15823 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
15824 pointers for hardware watchpoint support.
15825 * linux-low.h (struct linux_target_ops): Ditto.
15826 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
15827 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
15828 to linux_target_ops.
15829 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
15830 reply packet.
15831 * server.c (main): Recognize 'Z' and 'z' packets.
15832
b0ded00b
UW
158332005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
15834
15835 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
15836 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
15837 (the_low_target): Add new members.
15838
8643e2ad
DJ
158392005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
15840
15841 * proc-service.c (ps_lgetregs): Search all_processes instead of
15842 all_threads.
15843
fc620387
DJ
158442005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
15845
15846 * server.c (start_inferior): Change return type to int.
15847 (attach_inferior): Change sigptr to int *.
15848 (handle_v_cont, handle_v_requests): Change signal to int *.
15849 (main): Change signal to int.
15850
158512005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
15852
15853 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
15854 * configure.srv: Add m32r*-*-linux*.
15855 * linux-m32r-low.c: New file.
15856
e0e76420
DJ
158572005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
15858
15859 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
15860
a1928bad
DJ
158612005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
15862
15863 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
15864 Take unsigned long arguments for PIDs.
15865 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
15866 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
15867 (wait_for_sigstop, linux_resume_one_process)
15868 (regsets_fetch_inferior_registers, linux_send_signal)
15869 (linux_read_auxv): Likewise. Update the types of variables holding
15870 PIDs. Update format string specifiers.
15871 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
15872 * remote-utils.c (prepare_resume_reply): Likewise.
15873 * server.c (cont_thread, general_thread, step_thread)
15874 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
15875 unsigned long.
15876 (handle_query): Update format specifiers.
15877 (handle_v_cont, main): Use strtoul for thread IDs.
15878 * server.h (struct inferior_list_entry): Use unsigned long for ID.
15879 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
15880 (general_thread, step_thread, thread_from_wait)
15881 (old_thread_from_wait): Update.
15882 * target.h (struct thread_resume): Use unsigned long for THREAD.
15883 (struct target_ops): Use unsigned long for arguments to attach and
15884 thread_alive.
15885
dcdb98d2
DJ
158862005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
15887
15888 * acinclude.m4: Include bfd/bfd.m4 directly.
15889 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
15890 <agriffis@toolchain.org>.
15891 * aclocal.m4, configure: Regenerated.
15892
bec39cab
AC
158932005-01-07 Andrew Cagney <cagney@gnu.org>
15894
15895 * configure.ac: Rename configure.in, require autoconf 2.59.
15896 * configure: Re-generate.
15897
434c4c77
DJ
158982004-12-08 Daniel Jacobowitz <dan@debian.org>
15899
15900 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
15901 LIBS when finished.
15902 * aclocal.m4: Regenerated.
15903 * configure: Regenerated.
15904
db1d3e1b
AS
159052004-11-21 Andreas Schwab <schwab@suse.de>
15906
15907 * linux-m68k-low.c (m68k_num_gregs): Define.
15908 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
15909 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
15910 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
15911 (m68k_breakpoint_at): New. Add to the_low_target.
15912
15913 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
15914 srv_linux_thread_db to yes.
15915
43360365
JB
159162004-10-20 Joel Brobecker <brobecker@gnat.com>
15917
15918 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
15919 (ARCH_SET_FS): Likewise.
15920 (ARCH_GET_FS): Likewise.
15921 (ARCH_GET_GS): Likewise.
15922
fd500816
DJ
159232004-10-16 Daniel Jacobowitz <dan@debian.org>
15924
15925 * linux-i386-low.c (ps_get_thread_area): New.
15926 * linux-x86-64-low.c (ps_get_thread_area): New.
15927 * linux-low.c: Include <sys/syscall.h>.
15928 (linux_kill_one_process): Don't kill the first thread here.
15929 (linux_kill): Kill the first thread here.
15930 (kill_lwp): New function.
15931 (send_sigstop, linux_send_signal): Use it.
15932 * proc-service.c: Clean up #ifdefs.
15933 (fpregset_info): Delete.
15934 (ps_lgetregs): Update and enable implementation.
15935 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
15936 implementations.
15937 * remote-utils.c (struct sym_cache, symbol_cache): New.
15938 (input_interrupt): Print a clearer message.
15939 (async_io_enabled): New variable.
15940 (enable_async_io, disable_async_io): Use it. Update comments.
15941 (look_up_one_symbol): Use the symbol cache.
15942 * thread-db.c (thread_db_look_up_symbols): New function.
15943 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
15944
f6de3c42
DJ
159452004-10-16 Daniel Jacobowitz <dan@debian.org>
15946
15947 * configure.in: Test for -rdynamic.
15948 * configure: Regenerated.
15949 * Makefile (INTERNAL_LDFLAGS): New.
15950 (gdbserver, gdbreplay): Use it.
15951
2c0fc042
AC
159522004-09-02 Andrew Cagney <cagney@gnu.org>
15953
15954 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
15955
075b3282
DJ
159562004-03-23 Daniel Jacobowitz <drow@mvista.com>
15957
15958 * linux-low.c (linux_wait): Clear all_processes list also.
15959
fa6a77dc
DJ
159602004-03-12 Daniel Jacobowitz <drow@mvista.com>
15961
15962 * linux-low.c: Include <errno.h>. Remove extern declaration of
15963 errno.
15964
6d782a97
DJ
159652004-03-12 Daniel Jacobowitz <drow@mvista.com>
15966
15967 * gdbreplay.c, server.h, utils.c: Update copyright years.
15968
3a7fb99b
DJ
159692004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
15970
15971 * server.c (main): Print child status or termination signal from
15972 variable 'signal', not 'sig'.
15973
c3e735a6
DJ
159742004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
15975
15976 * linux-low.c (linux_read_memory): Change return type to
15977 int. Check for and return error from ptrace().
15978 * target.c (read_inferior_memory): Change return type to int. Pass
15979 back return status from the_target->read_memory().
15980 * target.h (struct target_ops): Adapt *read_memory() prototype.
15981 Update comment.
15982 (read_inferior_memory): Adapt prototype.
15983 * server.c (main): Return an error packet if
15984 read_inferior_memory() returns an error.
15985
a59d1c82
DJ
159862004-03-04 Daniel Jacobowitz <drow@mvista.com>
15987
15988 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
15989 Unify with other clean targets.
15990
dc3f8883
DJ
159912004-02-29 Daniel Jacobowitz <drow@mvista.com>
15992
15993 * server.c (handle_v_cont): Call set_desired_inferior.
15994
89a208da
DJ
159952004-02-29 Daniel Jacobowitz <drow@mvista.com>
15996
15997 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
15998
62ea82f5
DJ
159992004-02-29 Daniel Jacobowitz <drow@mvista.com>
16000
16001 * linux-low.c (linux_wait): Unblock async I/O.
16002 (linux_resume): Block and enable async I/O.
16003 * remote-utils.c (block_async_io, unblock_async_io): New functions.
16004 * server.h (block_async_io, unblock_async_io): Add prototypes.
16005
6910d122
DJ
160062004-02-29 Daniel Jacobowitz <drow@mvista.com>
16007
16008 * remote-utils.c (remote_open): Print a status notice after
16009 opening a TCP port.
16010 * server.c (attach_inferior): Print a status notice after
16011 attaching.
16012
160132004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
16014
16015 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
16016
c89dc5d4
DJ
160172004-02-26 Daniel Jacobowitz <drow@mvista.com>
16018
16019 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
16020 error packet.
16021 * server.c, target.h: Update copyright years.
16022
4b8dad4a
RM
160232004-02-25 Roland McGrath <roland@redhat.com>
16024
16025 * target.h (struct target_ops): New member `read_auxv'.
16026 * server.c (handle_query): Handle qPart:auxv:read: query using that.
16027 * linux-low.c (linux_read_auxv): New function.
16028 (linux_target_ops): Initialize `read_auxv' member to that.
16029
d7446758
JB
160302004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
16031
16032 Committed by Jim Blandy <jimb@redhat.com>.
16033
16034 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 16035 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
16036 instead of GPR_SIZE to distiguish s390 and s390x targets.
16037
5544ad89
DJ
160382004-01-31 Daniel Jacobowitz <drow@mvista.com>
16039
16040 * linux-low.c: Update copyright year.
16041 (check_removed_breakpoint): Clear pending_is_breakpoint.
16042 (linux_set_resume_request, linux_queue_one_thread)
16043 (resume_status_pending_p): New functions.
16044 (linux_continue_one_thread): Use process->resume.
16045 (linux_resume): Only resume threads if there are no pending events.
16046 * linux-low.h (struct process_info): Add resume request
16047 pointer.
16048
2a68b70e
DJ
160492004-01-30 Daniel Jacobowitz <drow@mvista.com>
16050
16051 * regcache.c (new_register_cache): Clear the allocated register
16052 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
16053
64386c31
DJ
160542003-10-13 Daniel Jacobowitz <drow@mvista.com>
16055
16056 * linux-low.c (linux_resume): Take a struct thread_resume *
16057 argument.
16058 (linux_wait): Update call.
16059 (resume_ptr): New static variable.
16060 (linux_continue_one_thread): Renamed from
16061 linux_continue_one_process. Use resume_ptr.
16062 (linux_resume): Use linux_continue_one_thread.
16063 * server.c (handle_v_cont, handle_v_requests): New functions.
16064 (myresume): New function.
16065 (main): Handle 'v' case.
16066 * target.h (struct thread_resume): New type.
16067 (struct target_ops): Change argument of "resume" to struct
16068 thread_resume *.
16069 (myresume): Delete macro.
16070
c938e9b0
L
160712003-08-08 H.J. Lu <hongjiu.lu@intel.com>
16072
16073 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
16074 (uninstall): Support DESTDIR.
16075
7f313d07
BC
16076Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
16077
16078 * configure.srv: Add xscale*linux copy of arm*linux entry.
16079
3b2fc2ea
DJ
160802003-07-24 Daniel Jacobowitz <drow@mvista.com>
16081
16082 * linux-arm-low.c (arm_reinsert_addr): New function.
16083 (the_low_target): Add arm_reinsert_addr.
16084
1c0a559e
MK
160852003-07-08 Mark Kettenis <kettenis@gnu.org>
16086
16087 * mem-break.c: Remove whitespace at end of file.
16088
43d5792c
DJ
160892003-06-28 Daniel Jacobowitz <drow@mvista.com>
16090
16091 * configure.in: Check whether we need to prototype strerror.
16092 * server.h: Optionally prototype strerror.
16093 * gdbreplay.c (perror_with_name): Use strerror.
16094 * linux-low.c (linux_attach_lwp): Use strerror.
16095 * utils.c (perror_with_name): Use strerror.
16096 * config.in, configure: Regenerated.
16097
c8a86edf
DJ
160982003-06-28 Daniel Jacobowitz <drow@mvista.com>
16099
16100 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
16101 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
16102
73d37363
DJ
161032003-06-20 Daniel Jacobowitz <drow@mvista.com>
16104
16105 * Makefile.in (SFILES): Update.
16106 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
16107 low-sun3.c: Remove files.
16108
6ad8ae5c
DJ
161092003-06-17 Daniel Jacobowitz <drow@mvista.com>
16110
16111 * linux-low.c: Move comment to linux_thread_alive where it belonged.
16112 (linux_detach_one_process, linux_detach): New functions.
16113 (linux_target_ops): Add linux_detach.
16114 * server.c (main): Handle 'D' packet.
16115 * target.h (struct target_ops): Add "detach" member.
16116 (detach_inferior): Define.
16117
1581182a
MK
161182003-06-13 Mark Kettenis <kettenis@gnu.org>
16119
16120 From Kelley Cook <kelleycook@wideopenwest.com>:
16121 * configure.srv: Accept i[34567]86 variants.
16122
e5379b03
DJ
161232003-06-05 Daniel Jacobowitz <drow@mvista.com>
16124
16125 * linux-low.c (linux_wait_for_event): Correct comment typos.
16126 (linux_resume_one_process): Call check_removed_breakpoint.
16127 (linux_send_signal): New function.
16128 (linux_target_ops): Add linux_send_signal.
16129 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
16130 of kill.
16131 * target.h (struct target_ops): Add send_signal.
16132
2ff29de4
JB
161332003-05-29 Jim Blandy <jimb@redhat.com>
16134
16135 * linux-low.c (usr_store_inferior_registers): Transfer buf in
16136 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
16137 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
16138 away part of the register's value.
16139
254787d4
DJ
161402003-03-26 Daniel Jacobowitz <drow@mvista.com>
16141
16142 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
16143 (linux_wait_for_event, linux_init_signals): Likewise.
16144
94e10508
DJ
161452003-03-17 Daniel Jacobowitz <drow@mvista.com>
16146
16147 * configure.in: Check for stdlib.h.
16148 * configure: Regenerated.
16149 * config.in: Regenerated.
16150
4c0711e0
DJ
161512003-01-04 Andreas Schwab <schwab@suse.de>
16152
16153 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
16154
ef66e766
AC
161552003-01-02 Andrew Cagney <ac131313@redhat.com>
16156
16157 * Makefile.in: Remove obsolete code.
16158
a1358604
DJ
161592002-11-20 Daniel Jacobowitz <drow@mvista.com>
16160
16161 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
16162 defined(PT_FPR0_HI).
16163
23ce3b1c
DJ
161642002-11-17 Stuart Hughes <seh@zee2.com>
16165
16166 * linux-arm-low.c (arm_num_regs): Increase.
16167 (arm_regmap): Include status register.
16168
161692002-11-17 Daniel Jacobowitz <drow@mvista.com>
16170
16171 * linux-low.c (register_addr): Remove incorrect -1 check.
16172
a9fa9f7d
DJ
161732002-08-29 Daniel Jacobowitz <drow@mvista.com>
16174
16175 * linux-low.c (linux_create_inferior): Call setpgid. Return
16176 the new PID.
16177 (unstopped_p, linux_signal_pid): Remove.
16178 (linux_target_ops): Remove linux_signal_pid.
16179 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
16180 global instead of target method.
16181 * target.h (struct target_ops): Remove signal_pid. Update comment
16182 for create_inferior.
16183 * server.c (signal_pid): New variable.
16184 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 16185 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
16186 (attach_inferior): Set signal_pid.
16187
17574093
DJ
161882002-08-23 Daniel Jacobowitz <drow@mvista.com>
16189
16190 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
16191
161922002-08-20 Jim Blandy <jimb@redhat.com>
16193
16194 * Makefile.in (LDFLAGS): Allow the configure script to establish a
16195 default for this.
16196
161972002-08-01 Andrew Cagney <cagney@redhat.com>
16198
16199 * Makefile.in: Make chill references obsolete.
16200
162012002-07-24 Kevin Buettner <kevinb@redhat.com>
16202
16203 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
16204 * configure: Regenerate.
16205 * config.in: Regenerate.
16206
162072002-07-09 David O'Brien <obrien@FreeBSD.org>
16208
16209 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
16210 (perror_with_name, remote_close, remote_open, expect, play): Static.
16211
162122002-07-04 Michal Ludvig <mludvig@suse.cz>
16213
4b8dad4a 16214 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
16215 byte offsets instead of an array of indexes.
16216 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
16217
162182002-06-13 Daniel Jacobowitz <drow@mvista.com>
16219
16220 * regcache.c: Add comment.
16221
162222002-06-11 Daniel Jacobowitz <drow@mvista.com>
16223
16224 * thread-db.c: New file.
16225 * proc-service.c: New file.
16226 * acinclude.m4: New file.
16227 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
16228 proc-service.o, and thread-db.o.
16229 (linux-low.o): Add USE_THREAD_DB.
16230 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
16231 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
16232 * aclocal.m4: Regenerated.
16233 * config.in: Regenerated.
16234 * configure: Regenerated.
16235 * configure.in: Check for proc_service.h, sys/procfs.h,
16236 thread_db.h, and linux/elf.h headrs.
16237 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
16238 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
16239 Check for -lthread_db and thread support.
16240 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
16241 PowerPC, and SuperH.
16242 * i387-fp.c: Constify arguments.
16243 * i387-fp.h: Likewise.
16244 * inferiors.c: (struct thread_info): Renamed from
16245 `struct inferior_info'. Remove PID member. Use generic inferior
16246 list header. All uses updated.
16247 (inferiors, signal_pid): Removed.
16248 (all_threads): New variable.
16249 (get_thread): Define.
16250 (add_inferior_to_list): New function.
16251 (for_each_inferior): New function.
16252 (change_inferior_id): New function.
16253 (add_inferior): Removed.
16254 (remove_inferior): New function.
16255 (add_thread): New function.
16256 (free_one_thread): New function.
16257 (remove_thread): New function.
16258 (clear_inferiors): Use for_each_inferior and free_one_thread.
16259 (find_inferior): New function.
16260 (find_inferior_id): New function.
16261 (inferior_target_data): Update argument type.
16262 (set_inferior_target_data): Likewise.
16263 (inferior_regcache_data): Likewise.
16264 (set_inferior_regcache_data): Likewise.
16265 * linux-low.c (linux_bp_reinsert): Remove.
16266 (all_processes, stopping_threads, using_thrads)
16267 (struct pending_signals, debug_threads, pid_of): New.
16268 (inferior_pid): Replace with macro.
16269 (struct inferior_linux_data): Remove.
16270 (get_stop_pc, add_process): New functions.
16271 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
16272 Use add_process and add_thread.
16273 (linux_attach_lwp): New function, based on old linux_attach. Use
16274 add_process and add_thread. Set stop_expected for new threads.
16275 (linux_attach): New function.
16276 (linux_kill_one_process): New function.
16277 (linux_kill): Kill all LWPs.
16278 (linux_thread_alive): Use find_inferior_id.
16279 (check_removed_breakpoints, status_pending_p): New functions.
16280 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
16281 Update. Use WNOHANG. Wait for cloned processes also. Update process
16282 struct for the found process.
16283 (linux_wait_for_event): New function.
16284 (linux_wait): Use it. Support LWPs.
16285 (send_sigstop, wait_for_sigstop, stop_all_processes)
16286 (linux_resume_one_process, linux_continue_one_process): New functions.
16287 (linux_resume): Support LWPs.
16288 (REGISTER_RAW_SIZE): Remove.
16289 (fetch_register): Use register_size instead. Call supply_register.
16290 (usr_store_inferior_registers): Likewise. Call collect_register.
16291 Fix recursive case.
16292 (regsets_fetch_inferior_registers): Improve error message.
16293 (regsets_store_inferior_registers): Add debugging.
16294 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
16295 (unstopped_p, linux_signal_pid): New functions.
16296 (linux_target_ops): Add linux_signal_pid.
16297 (linux_init_signals): New function.
16298 (initialize_low): Call it. Initialize using_threads.
16299 * regcache.c (inferior_regcache_data): Add valid
16300 flag.
16301 (get_regcache): Fetch registers lazily. Add fetch argument
16302 and update all callers.
16303 (regcache_invalidate_one, regcache_invalidate): New
16304 functions.
16305 (new_register_cache): Renamed from create_register_cache.
16306 Return the new regcache.
16307 (free_register_cache): Change argument to a void *.
16308 (registers_to_string, registers_from_string): Call get_regcache
16309 with fetch flag set.
16310 (register_data): Make static. Pass fetch flag to get_regcache.
16311 (supply_register): Call get_regcache with fetch flag clear.
16312 (collect_register): Call get_regcache with fetch flag set.
16313 (collect_register_as_string): New function.
16314 * regcache.h: Update.
16315 * remote-utils.c (putpkt): Flush after debug output and use
16316 stderr.
16317 Handle input interrupts while waiting for an ACK.
16318 (input_interrupt): Use signal_pid method.
16319 (getpkt): Flush after debug output and use stderr.
16320 (outreg): Use collect_register_as_string.
16321 (new_thread_notify, dead_thread_notify): New functions.
16322 (prepare_resume_reply): Check using_threads. Set thread_from_wait
16323 and general_thread.
16324 (look_up_one_symbol): Flush after debug output.
16325 * server.c (step_thread, server_waiting): New variables.
16326 (start_inferior): Don't use signal_pid. Update call to mywait.
16327 (attach_inferior): Update call to mywait.
16328 (handle_query): Handle qfThreadInfo and qsThreadInfo.
16329 (main): Don't fetch/store registers explicitly. Use
16330 set_desired_inferior. Support proposed ``Hs'' packet. Update
16331 calls to mywait.
16332 * server.h: Update.
16333 (struct inferior_list, struct_inferior_list_entry): New.
16334 * target.c (set_desired_inferior): New.
16335 (write_inferior_memory): Constify.
16336 (mywait): New function.
16337 * target.h: Update.
16338 (struct target_ops): New signal_pid method.
16339 (mywait): Removed macro, added prototype.
16340
16341 * linux-low.h (regset_func): Removed.
16342 (regset_fill_func, regset_store_func): New.
16343 (enum regset_type): New.
16344 (struct regset_info): Add type field. Use new operation types.
16345 (struct linux_target_ops): stop_pc renamed to get_pc.
16346 Add decr_pc_after_break and breakpoint_at.
16347 (get_process, get_thread_proess, get_process_thread)
16348 (strut process_info, all_processes, linux_attach_lwp)
16349 (thread_db_init): New.
16350
16351 * linux-arm-low.c (arm_get_pc, arm_set_pc,
16352 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
16353 (the_low_target): Add new members.
16354 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
16355 (i386_store_fpxregset): Constify.
16356 (target_regsets): Add new kind identifier.
16357 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
16358 (i386_set_pc): Add debugging.
16359 (i386_breakpoint_at): New function.
16360 (the_low_target): Add new members.
16361 * linux-mips-low.c (mips_get_pc, mips_set_pc)
16362 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
16363 (mips_breakpoint_at): New.
16364 (the_low_target): Add new members.
16365 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
16366 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
16367 (the_low_target): Add new members.
16368 * linux-sh-low.c (sh_get_pc, sh_set_pc)
16369 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
16370 (the_low_target): Add new members.
16371 * linux-x86-64-low.c (target_regsets): Add new kind
16372 identifier.
16373
163742002-05-15 Daniel Jacobowitz <drow@mvista.com>
16375
16376 From Martin Pool <mbp@samba.org>:
16377 * server.c (gdbserver_usage): New function.
16378 (main): Call it.
16379
163802002-05-14 Daniel Jacobowitz <drow@mvista.com>
16381
16382 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
16383 stop_at -> stop_pc.
16384
163852002-05-04 Andrew Cagney <ac131313@redhat.com>
16386
16387 * Makefile.in: Remove obsolete code.
16388
163892002-04-24 Michal Ludvig <mludvig@suse.cz>
16390
16391 * linux-low.c (regsets_fetch_inferior_registers),
16392 (regsets_store_inferior_registers): Removed cast to int from
16393 ptrace() calls.
16394 * regcache.h: Added declaration of struct inferior_info.
16395
163962002-04-20 Daniel Jacobowitz <drow@mvista.com>
16397
16398 * inferiors.c (struct inferior_info): Add regcache_data.
16399 (add_inferior): Call create_register_cache.
16400 (clear_inferiors): Call free_register_cache.
16401 (inferior_regcache_data, set_inferior_regcache_data): New functions.
16402 * regcache.c (struct inferior_regcache_data): New.
16403 (registers): Remove.
16404 (get_regcache): New function.
16405 (create_register_cache, free_register_cache): New functions.
16406 (set_register_cache): Don't initialize the register cache here.
16407 (registers_to_string, registers_from_string, register_data): Call
16408 get_regcache.
16409 * regcache.h: Add prototypes.
16410 * server.h: Likewise.
16411
164122002-04-20 Daniel Jacobowitz <drow@mvista.com>
16413
16414 * mem-break.c: New file.
16415 * mem-break.h: New file.
16416 * Makefile.in: Add mem-break.o rule; update server.h
16417 dependencies.
16418 * inferiors.c (struct inferior_info): Add target_data
16419 member.
16420 (clear_inferiors): Free target_data member if set.
16421 (inferior_target_data, set_inferior_target_data): New functions.
16422 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
16423 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
16424 * linux-low.c (linux_bp_reinsert): New variable.
16425 (struct inferior_linux_data): New.
16426 (linux_create_inferior): Use set_inferior_target_data.
16427 (linux_attach): Likewise. Call add_inferior.
16428 (linux_wait_for_one_inferior): New function.
16429 (linux_wait): Call it.
16430 (linux_write_memory): Add const.
16431 (initialize_low): Call set_breakpoint_data.
16432 * linux-low.h (struct linux_target_ops): Add breakpoint
16433 handling members.
16434 * server.c (attach_inferior): Remove extra add_inferior
16435 call.
16436 * server.h: Include mem-break.h. Update inferior.c
16437 prototypes.
16438 * target.c (read_inferior_memory)
16439 (write_inferior_memory): New functions.
16440 * target.h (read_inferior_memory)
16441 (write_inferior_memory): Change macros to prototypes.
16442 (struct target_ops): Update comments. Add const to write_memory
16443 definition.
16444
164452002-04-11 Daniel Jacobowitz <drow@mvista.com>
16446
16447 * linux-low.c (usr_store_inferior_registers): Support
16448 registers which are allowed to fail to store.
16449 * linux-low.h (linux_target_ops): Likewise.
16450 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
16451 (ppc_cannot_store_register): FPSCR may not be storable.
16452
164532002-04-09 Daniel Jacobowitz <drow@mvista.com>
16454
16455 * server.h: Include <string.h> if HAVE_STRING_H.
16456 * ChangeLog: Correct paths in last ChangeLog entry.
16457
164582002-04-09 Daniel Jacobowitz <drow@mvista.com>
16459
16460 * linux-low.h: Remove obsolete prototypes.
16461 (struct linux_target_ops): New.
16462 (extern the_low_target): New.
16463 * linux-low.c (num_regs, regmap): Remove declarations.
16464 (register_addr): Use the_low_target explicitly.
16465 (fetch_register): Likewise.
16466 (usr_fetch_inferior_registers): Likewise.
16467 (usr_store_inferior_registers): Likewise.
16468 * linux-arm-low.c (num_regs): Remove.
16469 (arm_num_regs): Define.
16470 (arm_regmap): Renamed from regmap, made static.
16471 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
16472 made static.
16473 (arm_cannot_store_register): Renamed from cannot_store_register,
16474 made static.
16475 (the_low_target): New.
16476 * linux-i386-low.c (num_regs): Remove.
16477 (i386_num_regs): Define.
16478 (i386_regmap): Renamed from regmap, made static.
16479 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
16480 made static.
16481 (i386_cannot_store_register): Renamed from cannot_store_register,
16482 made static.
16483 (the_low_target): New.
16484 * linux-ia64-low.c (num_regs): Remove.
16485 (ia64_num_regs): Define.
16486 (ia64_regmap): Renamed from regmap, made static.
16487 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
16488 made static.
16489 (ia64_cannot_store_register): Renamed from cannot_store_register,
16490 made static.
16491 (the_low_target): New.
16492 * linux-m68k-low.c (num_regs): Remove.
16493 (m68k_num_regs): Define.
16494 (m68k_regmap): Renamed from regmap, made static.
16495 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
16496 made static.
16497 (m68k_cannot_store_register): Renamed from cannot_store_register,
16498 made static.
16499 (the_low_target): New.
16500 * linux-mips-low.c (num_regs): Remove.
16501 (mips_num_regs): Define.
16502 (mips_regmap): Renamed from regmap, made static.
16503 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
16504 made static.
16505 (mips_cannot_store_register): Renamed from cannot_store_register,
16506 made static.
16507 (the_low_target): New.
16508 * linux-ppc-low.c (num_regs): Remove.
16509 (ppc_num_regs): Define.
16510 (ppc_regmap): Renamed from regmap, made static.
16511 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
16512 made static.
16513 (ppc_cannot_store_register): Renamed from cannot_store_register,
16514 made static.
16515 (the_low_target): New.
16516 * linux-s390-low.c (num_regs): Remove.
16517 (s390_num_regs): Define.
16518 (s390_regmap): Renamed from regmap, made static.
16519 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
16520 made static.
16521 (s390_cannot_store_register): Renamed from cannot_store_register,
16522 made static.
16523 (the_low_target): New.
16524 * linux-sh-low.c (num_regs): Remove.
16525 (sh_num_regs): Define.
16526 (sh_regmap): Renamed from regmap, made static.
16527 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
16528 made static.
16529 (sh_cannot_store_register): Renamed from cannot_store_register,
16530 made static.
16531 (the_low_target): New.
16532 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
16533 (the_low_target): New.
16534
165352002-04-09 Daniel Jacobowitz <drow@mvista.com>
16536
16537 * Makefile.in: Add stamp-h target.
16538 * configure.in: Create stamp-h.
16539 * configure: Regenerated.
16540
165412002-04-09 Daniel Jacobowitz <drow@mvista.com>
16542
16543 * inferiors.c: New file.
16544 * target.c: New file.
16545 * target.h: New file.
16546 * Makefile.in: Add target.o and inferiors.o. Update
16547 dependencies.
16548 * linux-low.c (inferior_pid): New static variable,
16549 moved from server.c.
16550 (linux_create_inferior): Renamed from create_inferior.
16551 Call add_inferior. Return 0 on success instead of a PID.
16552 (linux_attach): Renamed from myattach.
16553 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
16554 (linux_thread_alive): Renamed from mythread_alive.
16555 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
16556 child dies.
16557 (linux_resume): Renamed from myresume. Add missing ``return 0''.
16558 (regsets_store_inferior_registers): Correct error message.
16559 Add missing ``return 0''.
16560 (linux_fetch_registers): Renamed from fetch_inferior_registers.
16561 (linux_store_registers): Renamed from store_inferior_registers.
16562 (linux_read_memory): Renamed from read_inferior_memory.
16563 (linux_write_memory): Renamed from write_inferior_memory.
16564 (linux_target_ops): New structure.
16565 (initialize_low): Call set_target_ops ().
16566 * remote-utils.c (unhexify): New function.
16567 (hexify): New function.
16568 (input_interrupt): Send signals to ``signal_pid''.
16569 * server.c (inferior_pid): Remove.
16570 (start_inferior): Update create_inferior call.
16571 (attach_inferior): Call add_inferior.
16572 (handle_query): New function.
16573 (main): Call handle_query for `q' packets.
16574 * server.h: Include "target.h". Remove obsolete prototypes.
16575 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
16576
165772002-04-09 Daniel Jacobowitz <drow@mvista.com>
16578
16579 * Makefile.in: Add WARN_CFLAGS. Update configury
16580 dependencies.
16581 * configure.in: Check for <string.h>
16582 * configure: Regenerate.
16583 * config.in: Regenerate.
16584 * gdbreplay.c: Include needed system headers.
16585 (remote_open): Remove strchr prototype.
16586 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
16587 * regcache.c (supply_register): Change buf argument to const void *.
16588 (supply_register_by_name): Likewise.
16589 (collect_register): Change buf argument to void *.
16590 (collect_register_by_name): Likewise.
16591 * regcache.h: Add missing prototypes.
16592 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
16593 * server.c (handle_query): New function.
16594 (attached): New static variable, moved out of main.
16595 (main): Quiet longjmp clobber warnings.
16596 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
16597 * utils.c (error): Remove NORETURN.
16598 (fatal): Likewise.
This page took 2.448744 seconds and 4 git commands to generate.